From 2dce45e040e288eae2ba8e8bb9a7d92025dcf7d3 Mon Sep 17 00:00:00 2001 From: Jen Jones Arnesen Date: Fri, 13 Dec 2024 10:37:18 +0100 Subject: [PATCH] fix: use string pluralization and remove unneeded style --- i18n/en.pot | 10 ++++++---- src/pages/view/SlideshowFiltersInfo.js | 6 ++++-- src/pages/view/styles/SlideshowControlbar.module.css | 3 +-- 3 files changed, 11 insertions(+), 8 deletions(-) diff --git a/i18n/en.pot b/i18n/en.pot index c70e08f33..cfa753310 100644 --- a/i18n/en.pot +++ b/i18n/en.pot @@ -5,8 +5,8 @@ msgstr "" "Content-Type: text/plain; charset=utf-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1)\n" -"POT-Creation-Date: 2024-12-12T16:07:57.017Z\n" -"PO-Revision-Date: 2024-12-12T16:07:57.018Z\n" +"POT-Creation-Date: 2024-12-13T09:34:43.221Z\n" +"PO-Revision-Date: 2024-12-13T09:34:43.221Z\n" msgid "Untitled dashboard" msgstr "Untitled dashboard" @@ -490,8 +490,10 @@ msgstr "No, cancel" msgid "Yes, remove filters" msgstr "Yes, remove filters" -msgid "{{totalFilterCount}} filters active" -msgstr "{{totalFilterCount}} filters active" +msgid "{{count}} filters active" +msgid_plural "{{count}} filters active" +msgstr[0] "{{count}} filter active" +msgstr[1] "{{count}} filters active" msgid "The dashboard couldn't be made available offline. Try again." msgstr "The dashboard couldn't be made available offline. Try again." diff --git a/src/pages/view/SlideshowFiltersInfo.js b/src/pages/view/SlideshowFiltersInfo.js index c89790553..97ec32020 100644 --- a/src/pages/view/SlideshowFiltersInfo.js +++ b/src/pages/view/SlideshowFiltersInfo.js @@ -53,8 +53,10 @@ export const SlideshowFiltersInfo = () => { className={styles.filterButton} onClick={() => setIsOpen(true)} > - {i18n.t('{{totalFilterCount}} filters active', { - totalFilterCount, + {i18n.t('{{count}} filters active', { + count: totalFilterCount, + defaultValue: '{{count}} filter active', + defaultValue_plural: '{{count}} filters active', })} {isOpen && ( diff --git a/src/pages/view/styles/SlideshowControlbar.module.css b/src/pages/view/styles/SlideshowControlbar.module.css index 3ad2a293a..b7ac47c2c 100644 --- a/src/pages/view/styles/SlideshowControlbar.module.css +++ b/src/pages/view/styles/SlideshowControlbar.module.css @@ -15,7 +15,7 @@ .end { display: flex; align-items: center; - width: calc(100% / 3); + inline-size: calc(100% / 3); } .start { @@ -55,7 +55,6 @@ .controls { padding: 4px; - border-radius: 5px; display: flex; align-items: center; justify-content: center;