discourse/app/assets/javascripts/admin/addon/controllers
Ted Johansson 9915236e42
FEATURE: Warn about outdated translation overrides in admin dashboard (#22384)
This PR adds a feature to help admins stay up-to-date with their translations. We already have protections preventing admins from problems when they update their overrides. This change adds some protection in the other direction (where translations change in core due to an upgrade) by creating a notice for admins when defaults have changed.

Terms:

- In the case where Discourse core changes the default translation, the translation override is considered "outdated".
- In the case above where interpolation keys were changed from the ones the override is using, it is considered "invalid".
- If none of the above applies, the override is considered "up to date".

How does it work?

There are a few pieces that makes this work:

- When an admin creates or updates a translation override, we store the original translation at the time of write. (This is used to detect changes later on.)
- There is a background job that runs once every day and checks for outdated and invalid overrides, and marks them as such.
- When there are any outdated or invalid overrides, a notice is shown in admin dashboard with a link to the text customization page.

Known limitations

The link from the dashboard links to the default locale text customization page. Given there might be invalid overrides in multiple languages, I'm not sure what we could do here. Consideration for future improvement.
2023-07-10 10:06:40 +08:00
..
admin-badges DEV: Add native class shims for `on`/`observes` decorators 2023-02-22 09:32:48 +00:00
modals DEV: Create posts from form templates (#21980) 2023-06-08 12:49:18 -07:00
admin-api-keys-index.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-api-keys-new.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-api-keys-show.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-api-keys.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-backups-index.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-backups-logs.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-backups.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-badges.js DEV: Update `/admin/badges` to modern Ember patterns (#17672) 2022-08-03 10:12:17 +01:00
admin-customize-colors-show.js DEV: update yes/no confirmation dialogs (#18181) 2022-09-14 11:06:56 -04:00
admin-customize-colors.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-customize-email-style-edit.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-customize-email-templates-edit.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-customize-email-templates.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-customize-form-templates-index.js DEV: Create form templates (#20189) 2023-02-08 11:21:39 -08:00
admin-customize-robots-txt.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-customize-themes-edit.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-customize-themes-show.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-customize-themes.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-dashboard-general.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-dashboard-moderation.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-dashboard-reports.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-dashboard.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-email-advanced-test.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-email-bounced.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-email-index.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-email-logs.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-email-preview-digest.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-email-received.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-email-rejected.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-email-sent.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-email-skipped.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-embedding.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-emojis.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-logs-screened-emails.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-logs-screened-ip-addresses.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-logs-screened-urls.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-logs-staff-action-logs.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-permalinks.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-plugins.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-reports-show.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-search-logs-index.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-search-logs-term.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-site-settings-category.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-site-settings.js FEATURE: Fuzzy search in site settings and raise limit to 100 matches (#21572) 2023-05-16 18:23:05 +10:00
admin-site-text-edit.js FEATURE: Show available interpolation keys when overriding translations (#22220) 2023-06-28 19:03:04 +08:00
admin-site-text-index.js FEATURE: Warn about outdated translation overrides in admin dashboard (#22384) 2023-07-10 10:06:40 +08:00
admin-user-badges.js FIX: Badge granting recursion error (#20750) 2023-03-20 21:07:21 +00:00
admin-user-fields.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-user-index.js DEV: Allow HTML errors whenever a popup is generated (#20989) 2023-04-06 10:00:54 -05:00
admin-user.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-users-list-show.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-watched-words-action.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-watched-words.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-web-hooks-edit.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-web-hooks-index.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-web-hooks-show.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin-web-hooks.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00
admin.js DEV: Update admin controllers to native class syntax (#20674) 2023-03-15 09:42:12 +00:00