diff --git a/web/src/util.ts b/web/src/util.ts index 93551228bf..142b48dade 100644 --- a/web/src/util.ts +++ b/web/src/util.ts @@ -456,7 +456,12 @@ export function format_array_as_list_with_highlighted_elements( ): string { // If Intl.ListFormat is not supported if (Intl.ListFormat === undefined) { - return array.map((item) => `${Handlebars.Utils.escapeExpression(item)}`).join(", "); + return array + .map( + (item) => + `${Handlebars.Utils.escapeExpression(item)}`, + ) + .join(", "); } // Use Intl.ListFormat to format the array as a Internationalized list. @@ -469,7 +474,7 @@ export function format_array_as_list_with_highlighted_elements( // items), and literals (commas, etc.). We need to // HTML-escape the elements, but not the literals. if (part.type === "element") { - return `${Handlebars.Utils.escapeExpression(part.value)}`; + return `${Handlebars.Utils.escapeExpression(part.value)}`; } return part.value; }) diff --git a/web/styles/app_components.css b/web/styles/app_components.css index 4e003783ee..fef69e25fa 100644 --- a/web/styles/app_components.css +++ b/web/styles/app_components.css @@ -59,6 +59,10 @@ kbd { font-weight: 300; } +.highlighted-element { + font-weight: 600; +} + .inline-block { display: inline-block; } diff --git a/web/templates/modal_banner/unsubscribed_participants_warning_banner.hbs b/web/templates/modal_banner/unsubscribed_participants_warning_banner.hbs index 901f01dac6..7e74939978 100644 --- a/web/templates/modal_banner/unsubscribed_participants_warning_banner.hbs +++ b/web/templates/modal_banner/unsubscribed_participants_warning_banner.hbs @@ -4,20 +4,20 @@ {{#tr}} Message sender is not subscribed to  . {{#*inline "z-user-names"}}({{{unsubscribed_participant_formatted_names_list}}}){{/inline}} - {{#*inline "z-stream"}}{{> ../inline_decorated_channel_name stream=stream show_colored_icon=true}}{{/inline}} + {{#*inline "z-stream"}}{{> ../inline_decorated_channel_name stream=stream show_colored_icon=true}}{{/inline}} {{/tr}} {{else if few_unsubscribed_participants}} {{#tr}} Some topic participants are not subscribed to  . {{#*inline "z-user-names"}}({{{unsubscribed_participant_formatted_names_list}}}){{/inline}} - {{#*inline "z-stream"}}{{> ../inline_decorated_channel_name stream=stream show_colored_icon=true}}{{/inline}} + {{#*inline "z-stream"}}{{> ../inline_decorated_channel_name stream=stream show_colored_icon=true}}{{/inline}} {{/tr}} {{else}} {{#tr}} {unsubscribed_participants_count} topic participants are not subscribed to  . - {{#*inline "z-stream"}}{{> ../inline_decorated_channel_name stream=stream show_colored_icon=true}}{{/inline}} + {{#*inline "z-stream"}}{{> ../inline_decorated_channel_name stream=stream show_colored_icon=true}}{{/inline}} {{/tr}} {{/if}}

diff --git a/web/tests/util.test.cjs b/web/tests/util.test.cjs index 8081ccf4d9..79fa28e2af 100644 --- a/web/tests/util.test.cjs +++ b/web/tests/util.test.cjs @@ -369,7 +369,7 @@ run_test("format_array_as_list", () => { ); assert.equal( util.format_array_as_list_with_highlighted_elements(array, "long", "conjunction"), - "apple, banana, and orange", + 'apple, banana, and orange', ); // Conjunction format @@ -391,7 +391,7 @@ run_test("format_array_as_list", () => { ); assert.equal( util.format_array_as_list_with_highlighted_elements(array, "long", "conjunction"), - "apple, banana, orange", + 'apple, banana, orange', ); assert.equal(