2021-04-13 06:51:54 +02:00
|
|
|
import {$t} from "./i18n";
|
2021-03-25 22:35:45 +01:00
|
|
|
import {page_params} from "./page_params";
|
2021-03-25 21:38:40 +01:00
|
|
|
|
2020-02-21 14:26:11 +01:00
|
|
|
/*
|
|
|
|
This file contains translations between the integer values used in
|
|
|
|
the Zulip API to describe values in dropdowns, radio buttons, and
|
|
|
|
similar widgets and the user-facing strings that should be used to
|
|
|
|
describe them, as well as data details like sort orders that may
|
|
|
|
be useful for some widgets.
|
|
|
|
|
|
|
|
We plan to eventually transition much of this file to have a more
|
|
|
|
standard format and then to be populated using data sent from the
|
|
|
|
Zulip server in `page_params`, so that the data is available for
|
|
|
|
other parts of the ecosystem to use (including the mobile apps and
|
|
|
|
API documentation) without a ton of copying.
|
|
|
|
*/
|
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const demote_inactive_streams_values = {
|
2020-02-21 14:26:11 +01:00
|
|
|
automatic: {
|
|
|
|
code: 1,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Automatic"}),
|
2020-02-21 14:26:11 +01:00
|
|
|
},
|
|
|
|
always: {
|
|
|
|
code: 2,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Always"}),
|
2020-02-21 14:26:11 +01:00
|
|
|
},
|
|
|
|
never: {
|
|
|
|
code: 3,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Never"}),
|
2020-02-21 14:26:11 +01:00
|
|
|
},
|
|
|
|
};
|
|
|
|
|
2021-03-10 13:56:10 +01:00
|
|
|
export const default_view_values = {
|
|
|
|
recent_topics: {
|
|
|
|
code: "recent_topics",
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Recent topics"}),
|
2021-03-10 13:56:10 +01:00
|
|
|
},
|
|
|
|
all_messages: {
|
|
|
|
code: "all_messages",
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "All messages"}),
|
2021-03-10 13:56:10 +01:00
|
|
|
},
|
|
|
|
};
|
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const color_scheme_values = {
|
2020-05-16 13:13:59 +02:00
|
|
|
automatic: {
|
|
|
|
code: 1,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Automatic"}),
|
2020-05-16 13:13:59 +02:00
|
|
|
},
|
|
|
|
night: {
|
|
|
|
code: 2,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Night mode"}),
|
2020-05-16 13:13:59 +02:00
|
|
|
},
|
|
|
|
day: {
|
|
|
|
code: 3,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Day mode"}),
|
2020-05-16 13:13:59 +02:00
|
|
|
},
|
|
|
|
};
|
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const twenty_four_hour_time_values = {
|
2020-02-21 14:26:11 +01:00
|
|
|
twenty_four_hour_clock: {
|
|
|
|
value: true,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "24-hour clock (17:00)"}),
|
2020-02-21 14:26:11 +01:00
|
|
|
},
|
|
|
|
twelve_hour_clock: {
|
|
|
|
value: false,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "12-hour clock (5:00 PM)"}),
|
2020-02-21 14:26:11 +01:00
|
|
|
},
|
|
|
|
};
|
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const get_all_display_settings = () => ({
|
2020-02-21 14:26:11 +01:00
|
|
|
settings: {
|
|
|
|
user_display_settings: [
|
|
|
|
"dense_mode",
|
|
|
|
"high_contrast_mode",
|
|
|
|
"left_side_userlist",
|
|
|
|
"starred_message_counts",
|
|
|
|
"fluid_layout_width",
|
|
|
|
],
|
|
|
|
},
|
|
|
|
render_only: {
|
|
|
|
high_contrast_mode: page_params.development_environment,
|
|
|
|
dense_mode: page_params.development_environment,
|
|
|
|
},
|
|
|
|
});
|
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const email_address_visibility_values = {
|
2020-02-21 20:46:35 +01:00
|
|
|
everyone: {
|
|
|
|
code: 1,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Admins, members, and guests"}),
|
2020-02-21 20:46:35 +01:00
|
|
|
},
|
2021-03-26 20:38:59 +01:00
|
|
|
// // Backend support for this configuration is not available yet.
|
2020-02-21 20:46:35 +01:00
|
|
|
// admins_and_members: {
|
|
|
|
// code: 2,
|
2021-04-10 10:09:54 +02:00
|
|
|
// description: $t({defaultMessage: "Members and admins"}),
|
2020-02-21 20:46:35 +01:00
|
|
|
// },
|
|
|
|
admins_only: {
|
|
|
|
code: 3,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Admins only"}),
|
2020-02-21 20:46:35 +01:00
|
|
|
},
|
2020-03-07 01:15:34 +01:00
|
|
|
nobody: {
|
|
|
|
code: 4,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Nobody"}),
|
2020-03-07 01:15:34 +01:00
|
|
|
},
|
2020-02-21 20:46:35 +01:00
|
|
|
};
|
2020-02-21 20:58:17 +01:00
|
|
|
|
2021-04-28 20:39:24 +02:00
|
|
|
export const common_policy_values = {
|
2020-02-21 20:58:17 +01:00
|
|
|
by_admins_only: {
|
|
|
|
order: 1,
|
|
|
|
code: 2,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Admins"}),
|
2020-02-21 20:58:17 +01:00
|
|
|
},
|
2021-04-21 21:43:27 +02:00
|
|
|
by_moderators_only: {
|
2020-02-21 20:58:17 +01:00
|
|
|
order: 2,
|
2021-04-21 21:43:27 +02:00
|
|
|
code: 4,
|
|
|
|
description: $t({defaultMessage: "Admins and moderators"}),
|
|
|
|
},
|
|
|
|
by_full_members: {
|
|
|
|
order: 3,
|
2020-02-21 20:58:17 +01:00
|
|
|
code: 3,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Admins and full members"}),
|
2020-02-21 20:58:17 +01:00
|
|
|
},
|
|
|
|
by_members: {
|
2021-04-21 21:43:27 +02:00
|
|
|
order: 4,
|
2020-02-21 20:58:17 +01:00
|
|
|
code: 1,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Admins and members"}),
|
2020-02-21 20:58:17 +01:00
|
|
|
},
|
|
|
|
};
|
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const user_group_edit_policy_values = {
|
2020-02-21 21:40:29 +01:00
|
|
|
by_admins_only: {
|
|
|
|
order: 1,
|
|
|
|
code: 2,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Admins"}),
|
2020-02-21 21:40:29 +01:00
|
|
|
},
|
|
|
|
by_members: {
|
|
|
|
order: 2,
|
|
|
|
code: 1,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Admins and members"}),
|
2020-02-21 21:40:29 +01:00
|
|
|
},
|
|
|
|
};
|
2020-02-21 21:42:27 +01:00
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const private_message_policy_values = {
|
2020-02-21 21:42:27 +01:00
|
|
|
by_anyone: {
|
|
|
|
order: 1,
|
|
|
|
code: 1,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Admins, members, and guests"}),
|
2020-02-21 21:42:27 +01:00
|
|
|
},
|
|
|
|
disabled: {
|
|
|
|
order: 2,
|
|
|
|
code: 2,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Private messages disabled"}),
|
2020-02-21 21:42:27 +01:00
|
|
|
},
|
|
|
|
};
|
2020-02-21 21:45:34 +01:00
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const wildcard_mention_policy_values = {
|
2020-09-14 19:26:42 +02:00
|
|
|
by_everyone: {
|
|
|
|
order: 1,
|
|
|
|
code: 1,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Admins, members and guests"}),
|
2020-09-14 19:26:42 +02:00
|
|
|
},
|
|
|
|
by_members: {
|
|
|
|
order: 2,
|
|
|
|
code: 2,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Admins and members"}),
|
2020-09-14 19:26:42 +02:00
|
|
|
},
|
|
|
|
by_full_members: {
|
|
|
|
order: 3,
|
|
|
|
code: 3,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Admins and full members"}),
|
2020-09-14 19:26:42 +02:00
|
|
|
},
|
2021-05-02 10:11:02 +02:00
|
|
|
by_moderators_only: {
|
|
|
|
order: 4,
|
|
|
|
code: 7,
|
|
|
|
description: $t({defaultMessage: "Admins and moderators"}),
|
|
|
|
},
|
2020-09-14 19:26:42 +02:00
|
|
|
// Until we add stream administrators, we mislabel this choice
|
|
|
|
// (which we intend to be the long-term default) as "Admins only"
|
|
|
|
// and don't offer the long-term "Admins only" option.
|
|
|
|
by_stream_admins_only: {
|
2021-05-02 10:11:02 +02:00
|
|
|
order: 5,
|
2020-09-14 19:26:42 +02:00
|
|
|
code: 4,
|
2021-04-10 10:09:54 +02:00
|
|
|
// description: $t({defaultMessage: "Organization and stream admins"}),
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Admins only"}),
|
2020-09-14 19:26:42 +02:00
|
|
|
},
|
|
|
|
// by_admins_only: {
|
|
|
|
// order: 5,
|
|
|
|
// code: 5,
|
2021-04-10 10:09:54 +02:00
|
|
|
// description: $t({defaultMessage: "Admins only"}),
|
2020-09-14 19:26:42 +02:00
|
|
|
// },
|
|
|
|
nobody: {
|
|
|
|
order: 6,
|
|
|
|
code: 6,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Nobody"}),
|
2020-09-14 19:26:42 +02:00
|
|
|
},
|
|
|
|
};
|
|
|
|
|
2020-02-09 05:23:25 +01:00
|
|
|
const time_limit_dropdown_values = new Map([
|
2020-07-15 00:34:28 +02:00
|
|
|
[
|
|
|
|
"any_time",
|
|
|
|
{
|
2021-04-13 06:51:54 +02:00
|
|
|
text: $t({defaultMessage: "Any time"}),
|
2020-07-15 00:34:28 +02:00
|
|
|
seconds: 0,
|
|
|
|
},
|
|
|
|
],
|
|
|
|
[
|
|
|
|
"never",
|
|
|
|
{
|
2021-04-13 06:51:54 +02:00
|
|
|
text: $t({defaultMessage: "Never"}),
|
2020-07-15 00:34:28 +02:00
|
|
|
},
|
|
|
|
],
|
|
|
|
[
|
|
|
|
"upto_two_min",
|
|
|
|
{
|
2021-04-13 06:51:54 +02:00
|
|
|
text: $t(
|
|
|
|
{defaultMessage: "Up to {time_limit} after posting"},
|
|
|
|
{time_limit: $t({defaultMessage: "2 minutes"})},
|
|
|
|
),
|
2020-07-15 00:34:28 +02:00
|
|
|
seconds: 2 * 60,
|
|
|
|
},
|
|
|
|
],
|
|
|
|
[
|
|
|
|
"upto_ten_min",
|
|
|
|
{
|
2021-04-13 06:51:54 +02:00
|
|
|
text: $t(
|
|
|
|
{defaultMessage: "Up to {time_limit} after posting"},
|
|
|
|
{time_limit: $t({defaultMessage: "10 minutes"})},
|
|
|
|
),
|
2020-07-15 00:34:28 +02:00
|
|
|
seconds: 10 * 60,
|
|
|
|
},
|
|
|
|
],
|
|
|
|
[
|
|
|
|
"upto_one_hour",
|
|
|
|
{
|
2021-04-13 06:51:54 +02:00
|
|
|
text: $t(
|
|
|
|
{defaultMessage: "Up to {time_limit} after posting"},
|
|
|
|
{time_limit: $t({defaultMessage: "1 hour"})},
|
|
|
|
),
|
2020-07-15 00:34:28 +02:00
|
|
|
seconds: 60 * 60,
|
|
|
|
},
|
|
|
|
],
|
|
|
|
[
|
|
|
|
"upto_one_day",
|
|
|
|
{
|
2021-04-13 06:51:54 +02:00
|
|
|
text: $t(
|
|
|
|
{defaultMessage: "Up to {time_limit} after posting"},
|
|
|
|
{time_limit: $t({defaultMessage: "1 day"})},
|
|
|
|
),
|
2020-07-15 00:34:28 +02:00
|
|
|
seconds: 24 * 60 * 60,
|
|
|
|
},
|
|
|
|
],
|
|
|
|
[
|
|
|
|
"upto_one_week",
|
|
|
|
{
|
2021-04-13 06:51:54 +02:00
|
|
|
text: $t(
|
|
|
|
{defaultMessage: "Up to {time_limit} after posting"},
|
|
|
|
{time_limit: $t({defaultMessage: "1 week"})},
|
|
|
|
),
|
2020-07-15 00:34:28 +02:00
|
|
|
seconds: 7 * 24 * 60 * 60,
|
|
|
|
},
|
|
|
|
],
|
|
|
|
[
|
|
|
|
"custom_limit",
|
|
|
|
{
|
2021-04-13 06:51:54 +02:00
|
|
|
text: $t({defaultMessage: "Up to N minutes after posting"}),
|
2020-07-15 00:34:28 +02:00
|
|
|
},
|
|
|
|
],
|
2020-02-09 05:23:25 +01:00
|
|
|
]);
|
2021-02-10 17:14:06 +01:00
|
|
|
export const msg_edit_limit_dropdown_values = time_limit_dropdown_values;
|
|
|
|
export const msg_delete_limit_dropdown_values = time_limit_dropdown_values;
|
|
|
|
export const retain_message_forever = -1;
|
2020-03-28 18:03:43 +01:00
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const user_role_values = {
|
2020-05-29 16:12:09 +02:00
|
|
|
guest: {
|
|
|
|
code: 600,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Guest"}),
|
2020-05-29 16:12:09 +02:00
|
|
|
},
|
|
|
|
member: {
|
|
|
|
code: 400,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Member"}),
|
2020-05-29 16:12:09 +02:00
|
|
|
},
|
2021-04-22 21:07:51 +02:00
|
|
|
moderator: {
|
|
|
|
code: 300,
|
|
|
|
description: $t({defaultMessage: "Moderator"}),
|
|
|
|
},
|
2020-05-29 16:12:09 +02:00
|
|
|
admin: {
|
|
|
|
code: 200,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Administrator"}),
|
2020-05-29 16:12:09 +02:00
|
|
|
},
|
2020-06-03 23:30:34 +02:00
|
|
|
owner: {
|
|
|
|
code: 100,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Owner"}),
|
2020-06-03 23:30:34 +02:00
|
|
|
},
|
2020-05-29 16:12:09 +02:00
|
|
|
};
|
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
const user_role_array = Object.values(user_role_values);
|
|
|
|
export const user_role_map = new Map(user_role_array.map((role) => [role.code, role.description]));
|
2020-06-23 15:32:18 +02:00
|
|
|
|
2020-03-28 18:03:43 +01:00
|
|
|
// NOTIFICATIONS
|
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const general_notifications_table_labels = {
|
2020-04-01 19:43:34 +02:00
|
|
|
realm: [
|
|
|
|
/* An array of notification settings of any category like
|
2020-07-15 00:34:28 +02:00
|
|
|
* `stream_notification_settings` which makes a single row of
|
|
|
|
* "Notification triggers" table should follow this order
|
|
|
|
*/
|
|
|
|
"visual",
|
|
|
|
"audio",
|
|
|
|
"mobile",
|
|
|
|
"email",
|
|
|
|
"all_mentions",
|
2020-04-01 19:43:34 +02:00
|
|
|
],
|
|
|
|
stream: {
|
2021-04-13 06:51:54 +02:00
|
|
|
is_muted: $t({defaultMessage: "Mute stream"}),
|
|
|
|
desktop_notifications: $t({defaultMessage: "Visual desktop notifications"}),
|
|
|
|
audible_notifications: $t({defaultMessage: "Audible desktop notifications"}),
|
|
|
|
push_notifications: $t({defaultMessage: "Mobile notifications"}),
|
|
|
|
email_notifications: $t({defaultMessage: "Email notifications"}),
|
|
|
|
pin_to_top: $t({defaultMessage: "Pin stream to top of left sidebar"}),
|
|
|
|
wildcard_mentions_notify: $t({defaultMessage: "Notifications for @all/@everyone mentions"}),
|
2020-04-01 19:43:34 +02:00
|
|
|
},
|
|
|
|
};
|
2020-03-28 18:03:43 +01:00
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const stream_specific_notification_settings = [
|
2020-03-28 18:03:43 +01:00
|
|
|
"desktop_notifications",
|
|
|
|
"audible_notifications",
|
|
|
|
"push_notifications",
|
|
|
|
"email_notifications",
|
|
|
|
"wildcard_mentions_notify",
|
|
|
|
];
|
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const stream_notification_settings = [
|
2020-03-28 18:03:43 +01:00
|
|
|
"enable_stream_desktop_notifications",
|
|
|
|
"enable_stream_audible_notifications",
|
|
|
|
"enable_stream_push_notifications",
|
|
|
|
"enable_stream_email_notifications",
|
|
|
|
"wildcard_mentions_notify",
|
|
|
|
];
|
|
|
|
|
|
|
|
const pm_mention_notification_settings = [
|
|
|
|
"enable_desktop_notifications",
|
|
|
|
"enable_sounds",
|
|
|
|
"enable_offline_push_notifications",
|
|
|
|
"enable_offline_email_notifications",
|
|
|
|
];
|
|
|
|
|
2020-07-15 00:34:28 +02:00
|
|
|
const desktop_notification_settings = ["pm_content_in_desktop_notifications"];
|
2020-03-28 18:03:43 +01:00
|
|
|
|
2020-07-15 00:34:28 +02:00
|
|
|
const mobile_notification_settings = ["enable_online_push_notifications"];
|
2020-03-28 18:03:43 +01:00
|
|
|
|
|
|
|
const email_notification_settings = [
|
|
|
|
"enable_digest_emails",
|
|
|
|
"enable_login_emails",
|
|
|
|
"message_content_in_email_notifications",
|
|
|
|
"realm_name_in_notifications",
|
2021-04-28 00:25:27 +02:00
|
|
|
"enable_marketing_emails",
|
2020-03-28 18:03:43 +01:00
|
|
|
];
|
|
|
|
|
2020-07-15 00:34:28 +02:00
|
|
|
const presence_notification_settings = ["presence_enabled"];
|
2020-05-01 20:39:26 +02:00
|
|
|
|
2020-03-28 18:03:43 +01:00
|
|
|
const other_notification_settings = desktop_notification_settings.concat(
|
|
|
|
["desktop_icon_count_display"],
|
|
|
|
mobile_notification_settings,
|
|
|
|
email_notification_settings,
|
2020-05-01 20:39:26 +02:00
|
|
|
presence_notification_settings,
|
2020-07-02 02:16:03 +02:00
|
|
|
["notification_sound"],
|
2020-03-28 18:03:43 +01:00
|
|
|
);
|
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const all_notification_settings = other_notification_settings.concat(
|
2020-03-28 18:03:43 +01:00
|
|
|
pm_mention_notification_settings,
|
2021-02-10 17:14:06 +01:00
|
|
|
stream_notification_settings,
|
2020-03-28 18:03:43 +01:00
|
|
|
);
|
|
|
|
|
2021-03-22 12:33:58 +01:00
|
|
|
export function get_notifications_table_row_data(notify_settings) {
|
|
|
|
return general_notifications_table_labels.realm.map((column, index) => {
|
|
|
|
const setting_name = notify_settings[index];
|
|
|
|
if (setting_name === undefined) {
|
|
|
|
return {
|
|
|
|
setting_name: "",
|
|
|
|
is_disabled: true,
|
|
|
|
is_checked: false,
|
|
|
|
};
|
|
|
|
}
|
|
|
|
const checkbox = {
|
|
|
|
setting_name,
|
|
|
|
is_disabled: false,
|
|
|
|
};
|
|
|
|
if (column === "mobile") {
|
|
|
|
checkbox.is_disabled = !page_params.realm_push_notifications_enabled;
|
|
|
|
}
|
|
|
|
checkbox.is_checked = page_params[setting_name];
|
|
|
|
return checkbox;
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
2021-02-10 17:14:06 +01:00
|
|
|
export const all_notifications = () => ({
|
2020-03-28 18:03:43 +01:00
|
|
|
general_settings: [
|
|
|
|
{
|
2021-04-13 06:51:54 +02:00
|
|
|
label: $t({defaultMessage: "Streams"}),
|
2021-03-22 12:33:58 +01:00
|
|
|
notification_settings: get_notifications_table_row_data(stream_notification_settings),
|
2020-03-28 18:03:43 +01:00
|
|
|
},
|
|
|
|
{
|
2021-04-13 06:51:54 +02:00
|
|
|
label: $t({defaultMessage: "PMs, mentions, and alerts"}),
|
2021-03-22 12:33:58 +01:00
|
|
|
notification_settings: get_notifications_table_row_data(
|
2020-07-15 00:34:28 +02:00
|
|
|
pm_mention_notification_settings,
|
|
|
|
),
|
2020-03-28 18:03:43 +01:00
|
|
|
},
|
|
|
|
],
|
|
|
|
settings: {
|
2020-07-20 22:18:43 +02:00
|
|
|
desktop_notification_settings,
|
|
|
|
mobile_notification_settings,
|
|
|
|
email_notification_settings,
|
|
|
|
presence_notification_settings,
|
2020-03-28 18:03:43 +01:00
|
|
|
},
|
|
|
|
show_push_notifications_tooltip: {
|
|
|
|
push_notifications: !page_params.realm_push_notifications_enabled,
|
|
|
|
enable_online_push_notifications: !page_params.realm_push_notifications_enabled,
|
|
|
|
},
|
|
|
|
});
|
2020-09-26 13:10:36 +02:00
|
|
|
|
2021-03-22 13:14:33 +01:00
|
|
|
export const desktop_icon_count_display_values = {
|
|
|
|
messages: {
|
|
|
|
code: 1,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "All unreads"}),
|
2021-03-22 13:14:33 +01:00
|
|
|
},
|
|
|
|
notifiable: {
|
|
|
|
code: 2,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "Private messages and mentions"}),
|
2021-03-22 13:14:33 +01:00
|
|
|
},
|
|
|
|
none: {
|
|
|
|
code: 3,
|
2021-04-13 06:51:54 +02:00
|
|
|
description: $t({defaultMessage: "None"}),
|
2021-03-22 13:14:33 +01:00
|
|
|
},
|
|
|
|
};
|