diff --git a/.eslintrc b/.eslintrc index c98654dde43..c2cef78b8ad 100644 --- a/.eslintrc +++ b/.eslintrc @@ -3,6 +3,7 @@ "rules": { "discourse-ember/global-ember": "error", "eol-last": "error", - "no-restricted-globals": "off" + "no-restricted-globals": "off", + "no-restricted-imports": ["error", { "paths": ["I18n"] }] } } diff --git a/app/assets/javascripts/admin/addon/components/ace-editor.js b/app/assets/javascripts/admin/addon/components/ace-editor.js index c14d4f3d531..22c901096fd 100644 --- a/app/assets/javascripts/admin/addon/components/ace-editor.js +++ b/app/assets/javascripts/admin/addon/components/ace-editor.js @@ -6,7 +6,7 @@ import $ from "jquery"; import loadScript from "discourse/lib/load-script"; import getURL from "discourse-common/lib/get-url"; import { bind } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; const COLOR_VARS_REGEX = /\$(primary|secondary|tertiary|quaternary|header_background|header_primary|highlight|danger|success|love)(\s|;|-(low|medium|high))/g; diff --git a/app/assets/javascripts/admin/addon/components/admin-backups-logs.js b/app/assets/javascripts/admin/addon/components/admin-backups-logs.js index ef6771a2751..ce0306a5b2c 100644 --- a/app/assets/javascripts/admin/addon/components/admin-backups-logs.js +++ b/app/assets/javascripts/admin/addon/components/admin-backups-logs.js @@ -3,7 +3,7 @@ import { scheduleOnce } from "@ember/runloop"; import { classNames } from "@ember-decorators/component"; import { observes, on } from "@ember-decorators/object"; import discourseDebounce from "discourse-common/lib/debounce"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; @classNames("admin-backups-logs") export default class AdminBackupsLogs extends Component { diff --git a/app/assets/javascripts/admin/addon/components/admin-penalty-post-action.js b/app/assets/javascripts/admin/addon/components/admin-penalty-post-action.js index f27d1d55614..050dc6b438a 100644 --- a/app/assets/javascripts/admin/addon/components/admin-penalty-post-action.js +++ b/app/assets/javascripts/admin/addon/components/admin-penalty-post-action.js @@ -4,7 +4,7 @@ import { equal } from "@ember/object/computed"; import discourseComputed, { afterRender, } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; const ACTIONS = ["delete", "delete_replies", "edit", "none"]; diff --git a/app/assets/javascripts/admin/addon/components/admin-penalty-reason.js b/app/assets/javascripts/admin/addon/components/admin-penalty-reason.js index 726dcbec8db..b3ccd658759 100644 --- a/app/assets/javascripts/admin/addon/components/admin-penalty-reason.js +++ b/app/assets/javascripts/admin/addon/components/admin-penalty-reason.js @@ -3,7 +3,7 @@ import { action } from "@ember/object"; import { equal } from "@ember/object/computed"; import { tagName } from "@ember-decorators/component"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; const CUSTOM_REASON_KEY = "custom"; diff --git a/app/assets/javascripts/admin/addon/components/admin-report-storage-stats.js b/app/assets/javascripts/admin/addon/components/admin-report-storage-stats.js index 56a726cb7e6..9a9c9b61ad2 100644 --- a/app/assets/javascripts/admin/addon/components/admin-report-storage-stats.js +++ b/app/assets/javascripts/admin/addon/components/admin-report-storage-stats.js @@ -3,7 +3,7 @@ import { alias } from "@ember/object/computed"; import { classNames } from "@ember-decorators/component"; import { setting } from "discourse/lib/computed"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; @classNames("admin-report-storage-stats") export default class AdminReportStorageStats extends Component { diff --git a/app/assets/javascripts/admin/addon/components/admin-report.js b/app/assets/javascripts/admin/addon/components/admin-report.js index 74fff51553e..c6bcbc748a1 100644 --- a/app/assets/javascripts/admin/addon/components/admin-report.js +++ b/app/assets/javascripts/admin/addon/components/admin-report.js @@ -10,8 +10,8 @@ import ReportLoader from "discourse/lib/reports-loader"; import { isTesting } from "discourse-common/config/environment"; import { makeArray } from "discourse-common/lib/helpers"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import Report, { DAILY_LIMIT_DAYS, SCHEMA_VERSION } from "admin/models/report"; -import I18n from "I18n"; const TABLE_OPTIONS = { perPage: 8, diff --git a/app/assets/javascripts/admin/addon/components/admin-theme-editor.js b/app/assets/javascripts/admin/addon/components/admin-theme-editor.js index 7489a0dbf1a..a5e30f26c81 100644 --- a/app/assets/javascripts/admin/addon/components/admin-theme-editor.js +++ b/app/assets/javascripts/admin/addon/components/admin-theme-editor.js @@ -4,7 +4,7 @@ import { next } from "@ember/runloop"; import { fmt } from "discourse/lib/computed"; import { isDocumentRTL } from "discourse/lib/text-direction"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminThemeEditor extends Component { warning = null; diff --git a/app/assets/javascripts/admin/addon/components/admin-user-field-item.js b/app/assets/javascripts/admin/addon/components/admin-user-field-item.js index 08b0b869a82..c92191226a5 100644 --- a/app/assets/javascripts/admin/addon/components/admin-user-field-item.js +++ b/app/assets/javascripts/admin/addon/components/admin-user-field-item.js @@ -6,8 +6,8 @@ import { popupAjaxError } from "discourse/lib/ajax-error"; import { i18n, propertyEqual } from "discourse/lib/computed"; import { bufferedProperty } from "discourse/mixins/buffered-content"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import UserField from "admin/models/user-field"; -import I18n from "I18n"; export default Component.extend(bufferedProperty("userField"), { tagName: "", diff --git a/app/assets/javascripts/admin/addon/components/admin-watched-word.js b/app/assets/javascripts/admin/addon/components/admin-watched-word.js index 25775acac01..8cfce402eb5 100644 --- a/app/assets/javascripts/admin/addon/components/admin-watched-word.js +++ b/app/assets/javascripts/admin/addon/components/admin-watched-word.js @@ -4,7 +4,7 @@ import { alias, equal } from "@ember/object/computed"; import { inject as service } from "@ember/service"; import { classNames } from "@ember-decorators/component"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; @classNames("watched-word") export default class AdminWatchedWord extends Component { diff --git a/app/assets/javascripts/admin/addon/components/email-styles-editor.js b/app/assets/javascripts/admin/addon/components/email-styles-editor.js index b6d2347c562..a709ba15ace 100644 --- a/app/assets/javascripts/admin/addon/components/email-styles-editor.js +++ b/app/assets/javascripts/admin/addon/components/email-styles-editor.js @@ -3,7 +3,7 @@ import { action, computed } from "@ember/object"; import { reads } from "@ember/object/computed"; import { inject as service } from "@ember/service"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class EmailStylesEditor extends Component { @service dialog; diff --git a/app/assets/javascripts/admin/addon/components/embeddable-host.js b/app/assets/javascripts/admin/addon/components/embeddable-host.js index 759009c69ac..4f45a7143b5 100644 --- a/app/assets/javascripts/admin/addon/components/embeddable-host.js +++ b/app/assets/javascripts/admin/addon/components/embeddable-host.js @@ -8,7 +8,7 @@ import { popupAjaxError } from "discourse/lib/ajax-error"; import { bufferedProperty } from "discourse/mixins/buffered-content"; import Category from "discourse/models/category"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; @tagName("tr") export default class EmbeddableHost extends Component.extend( diff --git a/app/assets/javascripts/admin/addon/components/emoji-value-list.js b/app/assets/javascripts/admin/addon/components/emoji-value-list.js index fc6e78d9039..b788ecefc00 100644 --- a/app/assets/javascripts/admin/addon/components/emoji-value-list.js +++ b/app/assets/javascripts/admin/addon/components/emoji-value-list.js @@ -5,7 +5,7 @@ import { classNameBindings } from "@ember-decorators/component"; import { emojiUrlFor } from "discourse/lib/text"; import discourseLater from "discourse-common/lib/later"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; @classNameBindings(":value-list", ":emoji-list") export default class EmojiValueList extends Component { diff --git a/app/assets/javascripts/admin/addon/components/form-template/form.js b/app/assets/javascripts/admin/addon/components/form-template/form.js index ddfd5d27b42..73d0e020716 100644 --- a/app/assets/javascripts/admin/addon/components/form-template/form.js +++ b/app/assets/javascripts/admin/addon/components/form-template/form.js @@ -3,10 +3,10 @@ import { tracked } from "@glimmer/tracking"; import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import { popupAjaxError } from "discourse/lib/ajax-error"; +import I18n from "discourse-i18n"; import FormTemplateValidationOptionsModal from "admin/components/modal/form-template-validation-options"; import { templateFormFields } from "admin/lib/template-form-fields"; import FormTemplate from "admin/models/form-template"; -import I18n from "I18n"; export default class FormTemplateForm extends Component { @service router; diff --git a/app/assets/javascripts/admin/addon/components/form-template/row-item.js b/app/assets/javascripts/admin/addon/components/form-template/row-item.js index f95df2bb5ce..d5bcf6b4202 100644 --- a/app/assets/javascripts/admin/addon/components/form-template/row-item.js +++ b/app/assets/javascripts/admin/addon/components/form-template/row-item.js @@ -3,7 +3,7 @@ import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import { ajax } from "discourse/lib/ajax"; import { popupAjaxError } from "discourse/lib/ajax-error"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class FormTemplateRowItem extends Component { @service router; diff --git a/app/assets/javascripts/admin/addon/components/ip-lookup.js b/app/assets/javascripts/admin/addon/components/ip-lookup.js index 284c1d58704..e4145c67479 100644 --- a/app/assets/javascripts/admin/addon/components/ip-lookup.js +++ b/app/assets/javascripts/admin/addon/components/ip-lookup.js @@ -8,8 +8,8 @@ import { popupAjaxError } from "discourse/lib/ajax-error"; import copyText from "discourse/lib/copy-text"; import discourseLater from "discourse-common/lib/later"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import AdminUser from "admin/models/admin-user"; -import I18n from "I18n"; @classNames("ip-lookup") export default class IpLookup extends Component { diff --git a/app/assets/javascripts/admin/addon/components/modal/badge-preview.js b/app/assets/javascripts/admin/addon/components/modal/badge-preview.js index 136f85b0248..0139fe4f356 100644 --- a/app/assets/javascripts/admin/addon/components/modal/badge-preview.js +++ b/app/assets/javascripts/admin/addon/components/modal/badge-preview.js @@ -1,6 +1,6 @@ import Component from "@glimmer/component"; import { escapeExpression } from "discourse/lib/utilities"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class BadgePreview extends Component { get processedSample() { diff --git a/app/assets/javascripts/admin/addon/components/modal/delete-posts-confirmation.js b/app/assets/javascripts/admin/addon/components/modal/delete-posts-confirmation.js index 62d8dadfe35..6dafd58a7e7 100644 --- a/app/assets/javascripts/admin/addon/components/modal/delete-posts-confirmation.js +++ b/app/assets/javascripts/admin/addon/components/modal/delete-posts-confirmation.js @@ -1,6 +1,6 @@ import Component from "@glimmer/component"; import { tracked } from "@glimmer/tracking"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class DeletePostsConfirmation extends Component { @tracked value; diff --git a/app/assets/javascripts/admin/addon/components/modal/delete-user-posts-progress.js b/app/assets/javascripts/admin/addon/components/modal/delete-user-posts-progress.js index 6738dc68450..91aa4ca22b6 100644 --- a/app/assets/javascripts/admin/addon/components/modal/delete-user-posts-progress.js +++ b/app/assets/javascripts/admin/addon/components/modal/delete-user-posts-progress.js @@ -2,8 +2,8 @@ import Component from "@glimmer/component"; import { tracked } from "@glimmer/tracking"; import { action } from "@ember/object"; import { extractError } from "discourse/lib/ajax-error"; +import I18n from "discourse-i18n"; import AdminUser from "admin/models/admin-user"; -import I18n from "I18n"; export default class DeleteUserPostsProgress extends Component { @tracked deletedPosts = 0; diff --git a/app/assets/javascripts/admin/addon/components/modal/edit-badge-groupings.js b/app/assets/javascripts/admin/addon/components/modal/edit-badge-groupings.js index 0201af67cad..daf70300138 100644 --- a/app/assets/javascripts/admin/addon/components/modal/edit-badge-groupings.js +++ b/app/assets/javascripts/admin/addon/components/modal/edit-badge-groupings.js @@ -5,7 +5,7 @@ import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import { TrackedArray } from "@ember-compat/tracked-built-ins"; import { ajax } from "discourse/lib/ajax"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class EditBadgeGroupings extends Component { @service dialog; diff --git a/app/assets/javascripts/admin/addon/components/modal/form-template-validation-options.js b/app/assets/javascripts/admin/addon/components/modal/form-template-validation-options.js index de4e76be51b..d740398246d 100644 --- a/app/assets/javascripts/admin/addon/components/modal/form-template-validation-options.js +++ b/app/assets/javascripts/admin/addon/components/modal/form-template-validation-options.js @@ -1,5 +1,5 @@ import Component from "@glimmer/component"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; const TABLE_HEADER_KEYS = ["key", "type", "description"]; const VALIDATION_KEYS = ["required", "minimum", "maximum", "pattern", "type"]; diff --git a/app/assets/javascripts/admin/addon/components/modal/install-theme.js b/app/assets/javascripts/admin/addon/components/modal/install-theme.js index 9b67bc0954a..29dc28c3ece 100644 --- a/app/assets/javascripts/admin/addon/components/modal/install-theme.js +++ b/app/assets/javascripts/admin/addon/components/modal/install-theme.js @@ -5,8 +5,8 @@ import { inject as service } from "@ember/service"; import { ajax } from "discourse/lib/ajax"; import { popupAjaxError } from "discourse/lib/ajax-error"; import { POPULAR_THEMES } from "discourse-common/lib/popular-themes"; +import I18n from "discourse-i18n"; import { COMPONENTS, THEMES } from "admin/models/theme"; -import I18n from "I18n"; const MIN_NAME_LENGTH = 4; diff --git a/app/assets/javascripts/admin/addon/components/modal/merge-users-confirmation.js b/app/assets/javascripts/admin/addon/components/modal/merge-users-confirmation.js index 3e3e3f995c6..1aff4f7fe68 100644 --- a/app/assets/javascripts/admin/addon/components/modal/merge-users-confirmation.js +++ b/app/assets/javascripts/admin/addon/components/modal/merge-users-confirmation.js @@ -1,6 +1,6 @@ import Component from "@glimmer/component"; import { tracked } from "@glimmer/tracking"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class MergeUsersConfirmation extends Component { @tracked value; diff --git a/app/assets/javascripts/admin/addon/components/modal/merge-users-progress.js b/app/assets/javascripts/admin/addon/components/modal/merge-users-progress.js index 4bda6e935ec..244f5292edd 100644 --- a/app/assets/javascripts/admin/addon/components/modal/merge-users-progress.js +++ b/app/assets/javascripts/admin/addon/components/modal/merge-users-progress.js @@ -3,7 +3,7 @@ import { tracked } from "@glimmer/tracking"; import { inject as service } from "@ember/service"; import DiscourseURL from "discourse/lib/url"; import { bind } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class MergeUsersProgress extends Component { @service messageBus; diff --git a/app/assets/javascripts/admin/addon/components/modal/penalize-user.js b/app/assets/javascripts/admin/addon/components/modal/penalize-user.js index 6c7b6acd397..8f270d5c333 100644 --- a/app/assets/javascripts/admin/addon/components/modal/penalize-user.js +++ b/app/assets/javascripts/admin/addon/components/modal/penalize-user.js @@ -4,7 +4,7 @@ import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import { isEmpty } from "@ember/utils"; import { extractError } from "discourse/lib/ajax-error"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class PenalizeUser extends Component { @service dialog; diff --git a/app/assets/javascripts/admin/addon/components/modal/reseed.js b/app/assets/javascripts/admin/addon/components/modal/reseed.js index 193987a2362..601528f295c 100644 --- a/app/assets/javascripts/admin/addon/components/modal/reseed.js +++ b/app/assets/javascripts/admin/addon/components/modal/reseed.js @@ -3,7 +3,7 @@ import { tracked } from "@glimmer/tracking"; import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import { ajax } from "discourse/lib/ajax"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class Reseed extends Component { @service dialog; diff --git a/app/assets/javascripts/admin/addon/components/modal/start-backup.js b/app/assets/javascripts/admin/addon/components/modal/start-backup.js index 5b1f4ae1c98..dc9c78e3193 100644 --- a/app/assets/javascripts/admin/addon/components/modal/start-backup.js +++ b/app/assets/javascripts/admin/addon/components/modal/start-backup.js @@ -2,7 +2,7 @@ import Component from "@glimmer/component"; import { tracked } from "@glimmer/tracking"; import { action } from "@ember/object"; import { inject as service } from "@ember/service"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class StartBackup extends Component { @service siteSettings; diff --git a/app/assets/javascripts/admin/addon/components/permalink-form.js b/app/assets/javascripts/admin/addon/components/permalink-form.js index 2c0f5cbd102..db886c149aa 100644 --- a/app/assets/javascripts/admin/addon/components/permalink-form.js +++ b/app/assets/javascripts/admin/addon/components/permalink-form.js @@ -5,8 +5,8 @@ import { inject as service } from "@ember/service"; import { tagName } from "@ember-decorators/component"; import { fmt } from "discourse/lib/computed"; import discourseComputed, { bind } from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import Permalink from "admin/models/permalink"; -import I18n from "I18n"; @tagName("") export default class PermalinkForm extends Component { diff --git a/app/assets/javascripts/admin/addon/components/screened-ip-address-form.js b/app/assets/javascripts/admin/addon/components/screened-ip-address-form.js index ef6c077d2a5..23cc0331016 100644 --- a/app/assets/javascripts/admin/addon/components/screened-ip-address-form.js +++ b/app/assets/javascripts/admin/addon/components/screened-ip-address-form.js @@ -4,8 +4,8 @@ import { schedule } from "@ember/runloop"; import { inject as service } from "@ember/service"; import { classNames, tagName } from "@ember-decorators/component"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import ScreenedIpAddress from "admin/models/screened-ip-address"; -import I18n from "I18n"; /** A form to create an IP address that will be blocked or allowed. diff --git a/app/assets/javascripts/admin/addon/components/secret-value-list.js b/app/assets/javascripts/admin/addon/components/secret-value-list.js index de1b5bdb080..2a1d73e9595 100644 --- a/app/assets/javascripts/admin/addon/components/secret-value-list.js +++ b/app/assets/javascripts/admin/addon/components/secret-value-list.js @@ -3,7 +3,7 @@ import { action, set } from "@ember/object"; import { isEmpty } from "@ember/utils"; import { classNameBindings } from "@ember-decorators/component"; import { on } from "@ember-decorators/object"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; @classNameBindings(":value-list", ":secret-value-list") export default class SecretValueList extends Component { diff --git a/app/assets/javascripts/admin/addon/components/tags-uploader.js b/app/assets/javascripts/admin/addon/components/tags-uploader.js index 3ffabd91f49..c8644f4d293 100644 --- a/app/assets/javascripts/admin/addon/components/tags-uploader.js +++ b/app/assets/javascripts/admin/addon/components/tags-uploader.js @@ -2,7 +2,7 @@ import Component from "@ember/component"; import { alias } from "@ember/object/computed"; import { inject as service } from "@ember/service"; import UppyUploadMixin from "discourse/mixins/uppy-upload"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class TagsUploader extends Component.extend(UppyUploadMixin) { @service dialog; diff --git a/app/assets/javascripts/admin/addon/components/theme-settings-editor.js b/app/assets/javascripts/admin/addon/components/theme-settings-editor.js index d1d20d89659..b4e235ec8ff 100644 --- a/app/assets/javascripts/admin/addon/components/theme-settings-editor.js +++ b/app/assets/javascripts/admin/addon/components/theme-settings-editor.js @@ -3,7 +3,7 @@ import { tracked } from "@glimmer/tracking"; import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import { ajax } from "discourse/lib/ajax"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class ThemeSettingsEditor extends Component { @service dialog; diff --git a/app/assets/javascripts/admin/addon/components/theme-upload-add.js b/app/assets/javascripts/admin/addon/components/theme-upload-add.js index dcb35fb2d1c..737d2c3a215 100644 --- a/app/assets/javascripts/admin/addon/components/theme-upload-add.js +++ b/app/assets/javascripts/admin/addon/components/theme-upload-add.js @@ -4,7 +4,7 @@ import { action } from "@ember/object"; import { isEmpty } from "@ember/utils"; import { ajax } from "discourse/lib/ajax"; import { extractError } from "discourse/lib/ajax-error"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; const THEME_FIELD_VARIABLE_TYPE_IDS = [2, 3, 4]; const SCSS_VARIABLE_NAMES = [ diff --git a/app/assets/javascripts/admin/addon/components/watched-word-form.js b/app/assets/javascripts/admin/addon/components/watched-word-form.js index 1dd28884351..0589d4b094d 100644 --- a/app/assets/javascripts/admin/addon/components/watched-word-form.js +++ b/app/assets/javascripts/admin/addon/components/watched-word-form.js @@ -7,8 +7,8 @@ import { isEmpty } from "@ember/utils"; import { classNames, tagName } from "@ember-decorators/component"; import { observes } from "@ember-decorators/object"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import WatchedWord from "admin/models/watched-word"; -import I18n from "I18n"; @tagName("form") @classNames("watched-word-form") diff --git a/app/assets/javascripts/admin/addon/components/watched-word-uploader.js b/app/assets/javascripts/admin/addon/components/watched-word-uploader.js index f76e3eeb429..c88fd512dd8 100644 --- a/app/assets/javascripts/admin/addon/components/watched-word-uploader.js +++ b/app/assets/javascripts/admin/addon/components/watched-word-uploader.js @@ -3,7 +3,7 @@ import { alias } from "@ember/object/computed"; import { classNames } from "@ember-decorators/component"; import { dialog } from "discourse/lib/uploads"; import UppyUploadMixin from "discourse/mixins/uppy-upload"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; @classNames("watched-words-uploader") export default class WatchedWordUploader extends Component.extend( diff --git a/app/assets/javascripts/admin/addon/components/webhook-event-chooser.js b/app/assets/javascripts/admin/addon/components/webhook-event-chooser.js index 652bdef4c85..0e585776cb9 100644 --- a/app/assets/javascripts/admin/addon/components/webhook-event-chooser.js +++ b/app/assets/javascripts/admin/addon/components/webhook-event-chooser.js @@ -1,5 +1,5 @@ import Component from "@glimmer/component"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class WebhookEventChooser extends Component { get details() { diff --git a/app/assets/javascripts/admin/addon/components/webhook-event.js b/app/assets/javascripts/admin/addon/components/webhook-event.js index d2658e9171d..23cbd614810 100644 --- a/app/assets/javascripts/admin/addon/components/webhook-event.js +++ b/app/assets/javascripts/admin/addon/components/webhook-event.js @@ -5,7 +5,7 @@ import { inject as service } from "@ember/service"; import { ajax } from "discourse/lib/ajax"; import { popupAjaxError } from "discourse/lib/ajax-error"; import { ensureJSON, plainJSON, prettyJSON } from "discourse/lib/formatter"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class WebhookEvent extends Component { @service dialog; diff --git a/app/assets/javascripts/admin/addon/components/webhook-status.js b/app/assets/javascripts/admin/addon/components/webhook-status.js index 258dca54cce..7dc0450708a 100644 --- a/app/assets/javascripts/admin/addon/components/webhook-status.js +++ b/app/assets/javascripts/admin/addon/components/webhook-status.js @@ -1,5 +1,5 @@ import Component from "@glimmer/component"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class WebhookStatus extends Component { iconNames = ["far-circle", "times-circle", "circle", "circle"]; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-api-keys-new.js b/app/assets/javascripts/admin/addon/controllers/admin-api-keys-new.js index 5b7114a7da5..bcbed3832fa 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-api-keys-new.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-api-keys-new.js @@ -6,7 +6,7 @@ import { isBlank } from "@ember/utils"; import { ajax } from "discourse/lib/ajax"; import { popupAjaxError } from "discourse/lib/ajax-error"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; import ApiKeyUrlsModal from "../components/modal/api-key-urls"; export default class AdminApiKeysNewController extends Controller { diff --git a/app/assets/javascripts/admin/addon/controllers/admin-backups-index.js b/app/assets/javascripts/admin/addon/controllers/admin-backups-index.js index d2aafd751c0..faca085d0ff 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-backups-index.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-backups-index.js @@ -5,7 +5,7 @@ import { inject as service } from "@ember/service"; import { ajax } from "discourse/lib/ajax"; import { i18n, setting } from "discourse/lib/computed"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminBackupsIndexController extends Controller { @service dialog; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-badges/award.js b/app/assets/javascripts/admin/addon/controllers/admin-badges/award.js index 68b64e1c3d3..23fc8659fbf 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-badges/award.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-badges/award.js @@ -4,7 +4,7 @@ import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import { ajax } from "discourse/lib/ajax"; import { extractError } from "discourse/lib/ajax-error"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminBadgesAwardController extends Controller { @service dialog; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-badges/show.js b/app/assets/javascripts/admin/addon/controllers/admin-badges/show.js index 1d80b3b1a39..fed172d20da 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-badges/show.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-badges/show.js @@ -7,7 +7,7 @@ import { observes } from "@ember-decorators/object"; import { popupAjaxError } from "discourse/lib/ajax-error"; import { bufferedProperty } from "discourse/mixins/buffered-content"; import getURL from "discourse-common/lib/get-url"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; const IMAGE = "image"; const ICON = "icon"; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-customize-colors-show.js b/app/assets/javascripts/admin/addon/controllers/admin-customize-colors-show.js index b29fd43becc..fc2424e3771 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-customize-colors-show.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-customize-colors-show.js @@ -3,7 +3,7 @@ import { action, computed } from "@ember/object"; import { inject as service } from "@ember/service"; import { clipboardCopy } from "discourse/lib/utilities"; import discourseLater from "discourse-common/lib/later"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminCustomizeColorsShowController extends Controller { @service dialog; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-customize-colors.js b/app/assets/javascripts/admin/addon/controllers/admin-customize-colors.js index 32bcb54eacf..daf3bdc698a 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-customize-colors.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-customize-colors.js @@ -2,8 +2,8 @@ import Controller from "@ember/controller"; import EmberObject, { action } from "@ember/object"; import { inject as service } from "@ember/service"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import ColorSchemeSelectBaseModal from "admin/components/modal/color-scheme-select-base"; -import I18n from "I18n"; export default class AdminCustomizeColorsController extends Controller { @service router; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-customize-email-style-edit.js b/app/assets/javascripts/admin/addon/controllers/admin-customize-email-style-edit.js index 0665bfd19a0..0f8e123131f 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-customize-email-style-edit.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-customize-email-style-edit.js @@ -2,7 +2,7 @@ import Controller from "@ember/controller"; import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminCustomizeEmailStyleEditController extends Controller { @service dialog; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-customize-email-templates-edit.js b/app/assets/javascripts/admin/addon/controllers/admin-customize-email-templates-edit.js index 65b016b04ed..9fcf1f8b3c7 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-customize-email-templates-edit.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-customize-email-templates-edit.js @@ -4,7 +4,7 @@ import { inject as service } from "@ember/service"; import { popupAjaxError } from "discourse/lib/ajax-error"; import { bufferedProperty } from "discourse/mixins/buffered-content"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminCustomizeEmailTemplatesEditController extends Controller.extend( bufferedProperty("emailTemplate") diff --git a/app/assets/javascripts/admin/addon/controllers/admin-customize-themes-edit.js b/app/assets/javascripts/admin/addon/controllers/admin-customize-themes-edit.js index 37ee5b04d2a..273489f7090 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-customize-themes-edit.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-customize-themes-edit.js @@ -3,7 +3,7 @@ import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import { url } from "discourse/lib/computed"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminCustomizeThemesEditController extends Controller { @service router; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-customize-themes-show.js b/app/assets/javascripts/admin/addon/controllers/admin-customize-themes-show.js index 54a91fed0d1..70997e56d08 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-customize-themes-show.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-customize-themes-show.js @@ -12,10 +12,10 @@ import { popupAjaxError } from "discourse/lib/ajax-error"; import { url } from "discourse/lib/computed"; import { makeArray } from "discourse-common/lib/helpers"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import ThemeSettingsEditor from "admin/components/theme-settings-editor"; import { COMPONENTS, THEMES } from "admin/models/theme"; import ThemeSettings from "admin/models/theme-settings"; -import I18n from "I18n"; import ThemeUploadAddModal from "../components/theme-upload-add"; const THEME_UPLOAD_VAR = 2; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-dashboard-general.js b/app/assets/javascripts/admin/addon/controllers/admin-dashboard-general.js index c8cc2e855f8..dcc8deca526 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-dashboard-general.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-dashboard-general.js @@ -5,10 +5,10 @@ import { setting } from "discourse/lib/computed"; import getURL from "discourse-common/lib/get-url"; import { makeArray } from "discourse-common/lib/helpers"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import PeriodComputationMixin from "admin/mixins/period-computation"; import AdminDashboard from "admin/models/admin-dashboard"; import Report from "admin/models/report"; -import I18n from "I18n"; import CustomDateRangeModal from "../components/modal/custom-date-range"; function staticReport(reportType) { diff --git a/app/assets/javascripts/admin/addon/controllers/admin-email-index.js b/app/assets/javascripts/admin/addon/controllers/admin-email-index.js index c09562b7bb8..ea56a60257a 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-email-index.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-email-index.js @@ -6,7 +6,7 @@ import { htmlSafe } from "@ember/template"; import { observes } from "@ember-decorators/object"; import { ajax } from "discourse/lib/ajax"; import { escapeExpression } from "discourse/lib/utilities"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminEmailIndexController extends Controller { @service dialog; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-emojis.js b/app/assets/javascripts/admin/addon/controllers/admin-emojis.js index 723369579e4..c72f827ede8 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-emojis.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-emojis.js @@ -3,7 +3,7 @@ import EmberObject, { action, computed } from "@ember/object"; import { sort } from "@ember/object/computed"; import { inject as service } from "@ember/service"; import { ajax } from "discourse/lib/ajax"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; const ALL_FILTER = "all"; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-logs-screened-ip-addresses.js b/app/assets/javascripts/admin/addon/controllers/admin-logs-screened-ip-addresses.js index 5259954d9eb..87af372d57d 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-logs-screened-ip-addresses.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-logs-screened-ip-addresses.js @@ -6,8 +6,8 @@ import { exportEntity } from "discourse/lib/export-csv"; import { outputExportResult } from "discourse/lib/export-result"; import { INPUT_DELAY } from "discourse-common/config/environment"; import discourseDebounce from "discourse-common/lib/debounce"; +import I18n from "discourse-i18n"; import ScreenedIpAddress from "admin/models/screened-ip-address"; -import I18n from "I18n"; export default class AdminLogsScreenedIpAddressesController extends Controller { @service dialog; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-logs-staff-action-logs.js b/app/assets/javascripts/admin/addon/controllers/admin-logs-staff-action-logs.js index 3726563ef83..abaf440883f 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-logs-staff-action-logs.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-logs-staff-action-logs.js @@ -5,7 +5,7 @@ import { inject as service } from "@ember/service"; import { exportEntity } from "discourse/lib/export-csv"; import { outputExportResult } from "discourse/lib/export-result"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; import StaffActionLogDetailsModal from "../components/modal/staff-action-log-details"; import ThemeChangeModal from "../components/modal/theme-change"; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-permalinks.js b/app/assets/javascripts/admin/addon/controllers/admin-permalinks.js index b13fde101f3..65c53a62cf0 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-permalinks.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-permalinks.js @@ -6,8 +6,8 @@ import { observes } from "@ember-decorators/object"; import { clipboardCopy } from "discourse/lib/utilities"; import { INPUT_DELAY } from "discourse-common/config/environment"; import discourseDebounce from "discourse-common/lib/debounce"; +import I18n from "discourse-i18n"; import Permalink from "admin/models/permalink"; -import I18n from "I18n"; export default class AdminPermalinksController extends Controller { @service dialog; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-search-logs-index.js b/app/assets/javascripts/admin/addon/controllers/admin-search-logs-index.js index 57b4be3ca0c..697638f6ede 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-search-logs-index.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-search-logs-index.js @@ -1,5 +1,5 @@ import Controller from "@ember/controller"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export const DEFAULT_PERIOD = "yearly"; export default class AdminSearchLogsIndexController extends Controller { diff --git a/app/assets/javascripts/admin/addon/controllers/admin-search-logs-term.js b/app/assets/javascripts/admin/addon/controllers/admin-search-logs-term.js index f4732ebb599..3a79d133191 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-search-logs-term.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-search-logs-term.js @@ -1,6 +1,6 @@ import Controller from "@ember/controller"; +import I18n from "discourse-i18n"; import { DEFAULT_PERIOD } from "admin/controllers/admin-search-logs-index"; -import I18n from "I18n"; export default class AdminSearchLogsTermController extends Controller { loading = false; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-site-settings.js b/app/assets/javascripts/admin/addon/controllers/admin-site-settings.js index a0a23f11b66..579e01fb204 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-site-settings.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-site-settings.js @@ -6,7 +6,7 @@ import { isEmpty } from "@ember/utils"; import { observes } from "@ember-decorators/object"; import { INPUT_DELAY } from "discourse-common/config/environment"; import { debounce } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminSiteSettingsController extends Controller { @service router; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-site-text-edit.js b/app/assets/javascripts/admin/addon/controllers/admin-site-text-edit.js index 059a7c2619f..b18dbd3eb7d 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-site-text-edit.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-site-text-edit.js @@ -4,7 +4,7 @@ import { inject as service } from "@ember/service"; import { popupAjaxError } from "discourse/lib/ajax-error"; import { bufferedProperty } from "discourse/mixins/buffered-content"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default Controller.extend(bufferedProperty("siteText"), { dialog: service(), diff --git a/app/assets/javascripts/admin/addon/controllers/admin-user-badges.js b/app/assets/javascripts/admin/addon/controllers/admin-user-badges.js index 4e59bf625af..774d4de4466 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-user-badges.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-user-badges.js @@ -7,7 +7,7 @@ import { popupAjaxError } from "discourse/lib/ajax-error"; import { grantableBadges } from "discourse/lib/grant-badge-utils"; import UserBadge from "discourse/models/user-badge"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminUserBadgesController extends Controller { @service dialog; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-user-fields.js b/app/assets/javascripts/admin/addon/controllers/admin-user-fields.js index a37f210f08b..f3624d86cc7 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-user-fields.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-user-fields.js @@ -3,7 +3,7 @@ import { action } from "@ember/object"; import { gte, sort } from "@ember/object/computed"; import { inject as service } from "@ember/service"; import { popupAjaxError } from "discourse/lib/ajax-error"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; const MAX_FIELDS = 30; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-user-index.js b/app/assets/javascripts/admin/addon/controllers/admin-user-index.js index 391dd59bf59..2f29082bb5a 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-user-index.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-user-index.js @@ -10,8 +10,8 @@ import DiscourseURL, { userPath } from "discourse/lib/url"; import CanCheckEmails from "discourse/mixins/can-check-emails"; import getURL from "discourse-common/lib/get-url"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import AdminUser from "admin/models/admin-user"; -import I18n from "I18n"; import DeletePostsConfirmationModal from "../components/modal/delete-posts-confirmation"; import DeleteUserPostsProgressModal from "../components/modal/delete-user-posts-progress"; import MergeUsersConfirmationModal from "../components/modal/merge-users-confirmation"; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-users-list-show.js b/app/assets/javascripts/admin/addon/controllers/admin-users-list-show.js index af41a29024e..3d529f25c91 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-users-list-show.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-users-list-show.js @@ -6,8 +6,8 @@ import CanCheckEmails from "discourse/mixins/can-check-emails"; import { INPUT_DELAY } from "discourse-common/config/environment"; import discourseDebounce from "discourse-common/lib/debounce"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import AdminUser from "admin/models/admin-user"; -import I18n from "I18n"; export default class AdminUsersListShowController extends Controller.extend( CanCheckEmails diff --git a/app/assets/javascripts/admin/addon/controllers/admin-watched-words-action.js b/app/assets/javascripts/admin/addon/controllers/admin-watched-words-action.js index a126943233f..abf42b39876 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-watched-words-action.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-watched-words-action.js @@ -6,9 +6,9 @@ import { inject as service } from "@ember/service"; import { ajax } from "discourse/lib/ajax"; import { fmt } from "discourse/lib/computed"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import WatchedWordTestModal from "admin/components/modal/watched-word-test"; import WatchedWord from "admin/models/watched-word"; -import I18n from "I18n"; export default class AdminWatchedWordsActionController extends Controller { @service dialog; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-web-hooks-edit.js b/app/assets/javascripts/admin/addon/controllers/admin-web-hooks-edit.js index 97a5ff00b78..995ad777751 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-web-hooks-edit.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-web-hooks-edit.js @@ -5,7 +5,7 @@ import { inject as service } from "@ember/service"; import { isEmpty } from "@ember/utils"; import { popupAjaxError } from "discourse/lib/ajax-error"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminWebHooksEditController extends Controller { @service dialog; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-web-hooks-index.js b/app/assets/javascripts/admin/addon/controllers/admin-web-hooks-index.js index caa1fc5ff54..c7c9420d654 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-web-hooks-index.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-web-hooks-index.js @@ -3,7 +3,7 @@ import { action } from "@ember/object"; import { alias } from "@ember/object/computed"; import { inject as service } from "@ember/service"; import { popupAjaxError } from "discourse/lib/ajax-error"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminWebHooksIndexController extends Controller { @service dialog; diff --git a/app/assets/javascripts/admin/addon/controllers/admin-web-hooks-show.js b/app/assets/javascripts/admin/addon/controllers/admin-web-hooks-show.js index 41b8852c9de..411f592d0b1 100644 --- a/app/assets/javascripts/admin/addon/controllers/admin-web-hooks-show.js +++ b/app/assets/javascripts/admin/addon/controllers/admin-web-hooks-show.js @@ -2,7 +2,7 @@ import Controller, { inject as controller } from "@ember/controller"; import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import { popupAjaxError } from "discourse/lib/ajax-error"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminWebHooksShowController extends Controller { @service dialog; diff --git a/app/assets/javascripts/admin/addon/helpers/human-size.js b/app/assets/javascripts/admin/addon/helpers/human-size.js index 5d97883aaad..79f74ecfae7 100644 --- a/app/assets/javascripts/admin/addon/helpers/human-size.js +++ b/app/assets/javascripts/admin/addon/helpers/human-size.js @@ -1,4 +1,4 @@ import { htmlHelper } from "discourse-common/lib/helpers"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default htmlHelper((size) => I18n.toHumanSize(size)); diff --git a/app/assets/javascripts/admin/addon/helpers/post-action-title.js b/app/assets/javascripts/admin/addon/helpers/post-action-title.js index 9a1d213d93d..916d62e5d2d 100644 --- a/app/assets/javascripts/admin/addon/helpers/post-action-title.js +++ b/app/assets/javascripts/admin/addon/helpers/post-action-title.js @@ -1,5 +1,5 @@ import Helper from "@ember/component/helper"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; function postActionTitle([id, nameKey]) { let title = I18n.t(`admin.flags.short_names.${nameKey}`, { diff --git a/app/assets/javascripts/admin/addon/lib/template-form-fields.js b/app/assets/javascripts/admin/addon/lib/template-form-fields.js index de092acc8c0..2af3b9c10c6 100644 --- a/app/assets/javascripts/admin/addon/lib/template-form-fields.js +++ b/app/assets/javascripts/admin/addon/lib/template-form-fields.js @@ -1,4 +1,4 @@ -import I18n from "I18n"; +import I18n from "discourse-i18n"; export const templateFormFields = [ { diff --git a/app/assets/javascripts/admin/addon/mixins/setting-component.js b/app/assets/javascripts/admin/addon/mixins/setting-component.js index f60fef0654c..53fce908e7f 100644 --- a/app/assets/javascripts/admin/addon/mixins/setting-component.js +++ b/app/assets/javascripts/admin/addon/mixins/setting-component.js @@ -10,7 +10,7 @@ import { ajax } from "discourse/lib/ajax"; import { fmt, propertyNotEqual } from "discourse/lib/computed"; import { splitString } from "discourse/lib/utilities"; import discourseComputed, { bind } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; import SiteSettingDefaultCategoriesModal from "../components/modal/site-setting-default-categories"; const CUSTOM_TYPES = [ diff --git a/app/assets/javascripts/admin/addon/mixins/setting-object.js b/app/assets/javascripts/admin/addon/mixins/setting-object.js index 05ce6daee46..cdef6bc128c 100644 --- a/app/assets/javascripts/admin/addon/mixins/setting-object.js +++ b/app/assets/javascripts/admin/addon/mixins/setting-object.js @@ -3,7 +3,7 @@ import { readOnly } from "@ember/object/computed"; import Mixin from "@ember/object/mixin"; import { isPresent } from "@ember/utils"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default Mixin.create({ @discourseComputed("value", "default") diff --git a/app/assets/javascripts/admin/addon/models/admin-plugin.js b/app/assets/javascripts/admin/addon/models/admin-plugin.js index 71c0ec2adb4..4dea352f6ff 100644 --- a/app/assets/javascripts/admin/addon/models/admin-plugin.js +++ b/app/assets/javascripts/admin/addon/models/admin-plugin.js @@ -1,5 +1,5 @@ import { tracked } from "@glimmer/tracking"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminPlugin { static create(args = {}) { diff --git a/app/assets/javascripts/admin/addon/models/admin-user.js b/app/assets/javascripts/admin/addon/models/admin-user.js index f95dff4374d..79489398db6 100644 --- a/app/assets/javascripts/admin/addon/models/admin-user.js +++ b/app/assets/javascripts/admin/addon/models/admin-user.js @@ -8,7 +8,7 @@ import Group from "discourse/models/group"; import User from "discourse/models/user"; import getURL from "discourse-common/lib/get-url"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminUser extends User { static find(user_id) { diff --git a/app/assets/javascripts/admin/addon/models/color-scheme-color.js b/app/assets/javascripts/admin/addon/models/color-scheme-color.js index 92a5ae185dc..84498e180f1 100644 --- a/app/assets/javascripts/admin/addon/models/color-scheme-color.js +++ b/app/assets/javascripts/admin/addon/models/color-scheme-color.js @@ -2,7 +2,7 @@ import EmberObject from "@ember/object"; import { observes, on } from "@ember-decorators/object"; import { propertyNotEqual } from "discourse/lib/computed"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class ColorSchemeColor extends EmberObject { // Whether the current value is different than Discourse's default color scheme. diff --git a/app/assets/javascripts/admin/addon/models/color-scheme.js b/app/assets/javascripts/admin/addon/models/color-scheme.js index faf52813a67..73d2820efdb 100644 --- a/app/assets/javascripts/admin/addon/models/color-scheme.js +++ b/app/assets/javascripts/admin/addon/models/color-scheme.js @@ -4,8 +4,8 @@ import EmberObject from "@ember/object"; import { not } from "@ember/object/computed"; import { ajax } from "discourse/lib/ajax"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import ColorSchemeColor from "admin/models/color-scheme-color"; -import I18n from "I18n"; class ColorSchemes extends ArrayProxy {} diff --git a/app/assets/javascripts/admin/addon/models/flag-type.js b/app/assets/javascripts/admin/addon/models/flag-type.js index ea0cf9890e8..7e1eb60daf8 100644 --- a/app/assets/javascripts/admin/addon/models/flag-type.js +++ b/app/assets/javascripts/admin/addon/models/flag-type.js @@ -1,6 +1,6 @@ import RestModel from "discourse/models/rest"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class FlagType extends RestModel { @discourseComputed("id") diff --git a/app/assets/javascripts/admin/addon/models/report.js b/app/assets/javascripts/admin/addon/models/report.js index c0a87fb3109..512c68c8583 100644 --- a/app/assets/javascripts/admin/addon/models/report.js +++ b/app/assets/javascripts/admin/addon/models/report.js @@ -13,7 +13,7 @@ import { import getURL from "discourse-common/lib/get-url"; import { makeArray } from "discourse-common/lib/helpers"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; // Change this line each time report format change // and you want to ensure cache is reset diff --git a/app/assets/javascripts/admin/addon/models/screened-email.js b/app/assets/javascripts/admin/addon/models/screened-email.js index 5d7f2ead3fb..da3cb900523 100644 --- a/app/assets/javascripts/admin/addon/models/screened-email.js +++ b/app/assets/javascripts/admin/addon/models/screened-email.js @@ -1,7 +1,7 @@ import EmberObject from "@ember/object"; import { ajax } from "discourse/lib/ajax"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class ScreenedEmail extends EmberObject { static findAll() { diff --git a/app/assets/javascripts/admin/addon/models/screened-ip-address.js b/app/assets/javascripts/admin/addon/models/screened-ip-address.js index 606d37941bc..450c7ad57c7 100644 --- a/app/assets/javascripts/admin/addon/models/screened-ip-address.js +++ b/app/assets/javascripts/admin/addon/models/screened-ip-address.js @@ -2,7 +2,7 @@ import EmberObject from "@ember/object"; import { equal } from "@ember/object/computed"; import { ajax } from "discourse/lib/ajax"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class ScreenedIpAddress extends EmberObject { static findAll(filter) { diff --git a/app/assets/javascripts/admin/addon/models/screened-url.js b/app/assets/javascripts/admin/addon/models/screened-url.js index a0e022b44cb..74a14395c51 100644 --- a/app/assets/javascripts/admin/addon/models/screened-url.js +++ b/app/assets/javascripts/admin/addon/models/screened-url.js @@ -1,7 +1,7 @@ import EmberObject from "@ember/object"; import { ajax } from "discourse/lib/ajax"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class ScreenedUrl extends EmberObject { static findAll() { diff --git a/app/assets/javascripts/admin/addon/models/site-setting.js b/app/assets/javascripts/admin/addon/models/site-setting.js index a625cb5979b..1a36aa2a022 100644 --- a/app/assets/javascripts/admin/addon/models/site-setting.js +++ b/app/assets/javascripts/admin/addon/models/site-setting.js @@ -1,8 +1,8 @@ import EmberObject from "@ember/object"; import { ajax } from "discourse/lib/ajax"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import Setting from "admin/mixins/setting-object"; -import I18n from "I18n"; export default class SiteSetting extends EmberObject.extend(Setting) { static findAll() { diff --git a/app/assets/javascripts/admin/addon/models/staff-action-log.js b/app/assets/javascripts/admin/addon/models/staff-action-log.js index bead05a14f3..f208451a07a 100644 --- a/app/assets/javascripts/admin/addon/models/staff-action-log.js +++ b/app/assets/javascripts/admin/addon/models/staff-action-log.js @@ -2,8 +2,8 @@ import { ajax } from "discourse/lib/ajax"; import { escapeExpression } from "discourse/lib/utilities"; import RestModel from "discourse/models/rest"; import discourseComputed from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import AdminUser from "admin/models/admin-user"; -import I18n from "I18n"; function format(label, value, escape = true) { return value diff --git a/app/assets/javascripts/admin/addon/models/theme.js b/app/assets/javascripts/admin/addon/models/theme.js index f1257f20252..c6eda044fba 100644 --- a/app/assets/javascripts/admin/addon/models/theme.js +++ b/app/assets/javascripts/admin/addon/models/theme.js @@ -4,7 +4,7 @@ import { isBlank, isEmpty } from "@ember/utils"; import { popupAjaxError } from "discourse/lib/ajax-error"; import RestModel from "discourse/models/rest"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; const THEME_UPLOAD_VAR = 2; const FIELDS_IDS = [0, 1, 5]; diff --git a/app/assets/javascripts/admin/addon/models/watched-word.js b/app/assets/javascripts/admin/addon/models/watched-word.js index 78ce16bb9f9..e27fe142e48 100644 --- a/app/assets/javascripts/admin/addon/models/watched-word.js +++ b/app/assets/javascripts/admin/addon/models/watched-word.js @@ -1,6 +1,6 @@ import EmberObject from "@ember/object"; import { ajax } from "discourse/lib/ajax"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class WatchedWord extends EmberObject { static findAll() { diff --git a/app/assets/javascripts/admin/addon/routes/admin-backups.js b/app/assets/javascripts/admin/addon/routes/admin-backups.js index 63a047fb61a..cca9d5f015a 100644 --- a/app/assets/javascripts/admin/addon/routes/admin-backups.js +++ b/app/assets/javascripts/admin/addon/routes/admin-backups.js @@ -7,10 +7,10 @@ import User from "discourse/models/user"; import DiscourseRoute from "discourse/routes/discourse"; import getURL from "discourse-common/lib/get-url"; import { bind } from "discourse-common/utils/decorators"; +import I18n from "discourse-i18n"; import StartBackupModal from "admin/components/modal/start-backup"; import Backup from "admin/models/backup"; import BackupStatus from "admin/models/backup-status"; -import I18n from "I18n"; const LOG_CHANNEL = "/admin/backups/logs"; diff --git a/app/assets/javascripts/admin/addon/routes/admin-badges.js b/app/assets/javascripts/admin/addon/routes/admin-badges.js index b61a933eaf8..15040ae4b16 100644 --- a/app/assets/javascripts/admin/addon/routes/admin-badges.js +++ b/app/assets/javascripts/admin/addon/routes/admin-badges.js @@ -2,7 +2,7 @@ import { ajax } from "discourse/lib/ajax"; import Badge from "discourse/models/badge"; import BadgeGrouping from "discourse/models/badge-grouping"; import DiscourseRoute from "discourse/routes/discourse"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminBadgesRoute extends DiscourseRoute { _json = null; diff --git a/app/assets/javascripts/admin/addon/routes/admin-badges/show.js b/app/assets/javascripts/admin/addon/routes/admin-badges/show.js index b35669a663d..a124490e662 100644 --- a/app/assets/javascripts/admin/addon/routes/admin-badges/show.js +++ b/app/assets/javascripts/admin/addon/routes/admin-badges/show.js @@ -3,7 +3,7 @@ import Route from "@ember/routing/route"; import { inject as service } from "@ember/service"; import { ajax } from "discourse/lib/ajax"; import Badge from "discourse/models/badge"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; import BadgePreviewModal from "../../components/modal/badge-preview"; import EditBadgeGroupingsModal from "../../components/modal/edit-badge-groupings"; diff --git a/app/assets/javascripts/admin/addon/routes/admin-customize-email-style-edit.js b/app/assets/javascripts/admin/addon/routes/admin-customize-email-style-edit.js index 8d7c82775fa..a625b7e4c2a 100644 --- a/app/assets/javascripts/admin/addon/routes/admin-customize-email-style-edit.js +++ b/app/assets/javascripts/admin/addon/routes/admin-customize-email-style-edit.js @@ -1,7 +1,7 @@ import { action } from "@ember/object"; import Route from "@ember/routing/route"; import { inject as service } from "@ember/service"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminCustomizeEmailStyleEditRoute extends Route { @service dialog; diff --git a/app/assets/javascripts/admin/addon/routes/admin-customize-themes-edit.js b/app/assets/javascripts/admin/addon/routes/admin-customize-themes-edit.js index f1dedf2d146..663e497fe04 100644 --- a/app/assets/javascripts/admin/addon/routes/admin-customize-themes-edit.js +++ b/app/assets/javascripts/admin/addon/routes/admin-customize-themes-edit.js @@ -1,7 +1,7 @@ import { action } from "@ember/object"; import Route from "@ember/routing/route"; import { inject as service } from "@ember/service"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminCustomizeThemesEditRoute extends Route { @service dialog; diff --git a/app/assets/javascripts/admin/addon/routes/admin-customize-themes-show.js b/app/assets/javascripts/admin/addon/routes/admin-customize-themes-show.js index 4033d81aa27..d07b1ca68aa 100644 --- a/app/assets/javascripts/admin/addon/routes/admin-customize-themes-show.js +++ b/app/assets/javascripts/admin/addon/routes/admin-customize-themes-show.js @@ -2,8 +2,8 @@ import { action } from "@ember/object"; import Route from "@ember/routing/route"; import { inject as service } from "@ember/service"; import { scrollTop } from "discourse/mixins/scroll-top"; +import I18n from "discourse-i18n"; import { COMPONENTS, THEMES } from "admin/models/theme"; -import I18n from "I18n"; export default class AdminCustomizeThemesShowRoute extends Route { @service dialog; diff --git a/app/assets/javascripts/admin/addon/routes/admin-customize-themes.js b/app/assets/javascripts/admin/addon/routes/admin-customize-themes.js index ec86d4215b3..9a94480c277 100644 --- a/app/assets/javascripts/admin/addon/routes/admin-customize-themes.js +++ b/app/assets/javascripts/admin/addon/routes/admin-customize-themes.js @@ -2,7 +2,7 @@ import { action } from "@ember/object"; import Route from "@ember/routing/route"; import { next } from "@ember/runloop"; import { inject as service } from "@ember/service"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; import InstallThemeModal from "../components/modal/install-theme"; export default class AdminCustomizeThemesRoute extends Route { diff --git a/app/assets/javascripts/admin/addon/routes/admin-site-settings-category.js b/app/assets/javascripts/admin/addon/routes/admin-site-settings-category.js index bb90f8e34f2..32215571e82 100644 --- a/app/assets/javascripts/admin/addon/routes/admin-site-settings-category.js +++ b/app/assets/javascripts/admin/addon/routes/admin-site-settings-category.js @@ -1,6 +1,6 @@ import EmberObject from "@ember/object"; import DiscourseRoute from "discourse/routes/discourse"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminSiteSettingsCategoryRoute extends DiscourseRoute { model(params) { diff --git a/app/assets/javascripts/admin/addon/routes/admin-watched-words-action.js b/app/assets/javascripts/admin/addon/routes/admin-watched-words-action.js index f37e2ce6f59..d960000747c 100644 --- a/app/assets/javascripts/admin/addon/routes/admin-watched-words-action.js +++ b/app/assets/javascripts/admin/addon/routes/admin-watched-words-action.js @@ -1,6 +1,6 @@ import EmberObject from "@ember/object"; import DiscourseRoute from "discourse/routes/discourse"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminWatchedWordsActionRoute extends DiscourseRoute { model(params) { diff --git a/app/assets/javascripts/admin/addon/routes/admin.js b/app/assets/javascripts/admin/addon/routes/admin.js index 0d1e8d6f8ba..87ccb1a888c 100644 --- a/app/assets/javascripts/admin/addon/routes/admin.js +++ b/app/assets/javascripts/admin/addon/routes/admin.js @@ -1,5 +1,5 @@ import DiscourseRoute from "discourse/routes/discourse"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class AdminRoute extends DiscourseRoute { titleToken() { diff --git a/app/assets/javascripts/admin/addon/services/admin-tools.js b/app/assets/javascripts/admin/addon/services/admin-tools.js index 0dc7fbd6966..71c8955b1b7 100644 --- a/app/assets/javascripts/admin/addon/services/admin-tools.js +++ b/app/assets/javascripts/admin/addon/services/admin-tools.js @@ -4,9 +4,9 @@ import Service, { inject as service } from "@ember/service"; import { htmlSafe } from "@ember/template"; import { Promise } from "rsvp"; import { ajax } from "discourse/lib/ajax"; +import I18n from "discourse-i18n"; import PenalizeUserModal from "admin/components/modal/penalize-user"; import AdminUser from "admin/models/admin-user"; -import I18n from "I18n"; // A service that can act as a bridge between the front end Discourse application // and the admin application. Use this if you need front end code to access admin diff --git a/app/assets/javascripts/discourse-common/addon/helpers/bound-i18n.js b/app/assets/javascripts/discourse-common/addon/helpers/bound-i18n.js index 681e24ddd2c..a0e7d062f9e 100644 --- a/app/assets/javascripts/discourse-common/addon/helpers/bound-i18n.js +++ b/app/assets/javascripts/discourse-common/addon/helpers/bound-i18n.js @@ -1,5 +1,5 @@ import { htmlSafe } from "@ember/template"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default function boundI18n(key, options) { return htmlSafe(I18n.t(key, options)); diff --git a/app/assets/javascripts/discourse-common/addon/helpers/i18n.js b/app/assets/javascripts/discourse-common/addon/helpers/i18n.js index 04a8ffddba0..a6da3b4eec9 100644 --- a/app/assets/javascripts/discourse-common/addon/helpers/i18n.js +++ b/app/assets/javascripts/discourse-common/addon/helpers/i18n.js @@ -1,5 +1,5 @@ import { registerUnbound } from "discourse-common/lib/helpers"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default function i18n(key, params) { return I18n.t(key, params); diff --git a/app/assets/javascripts/discourse-common/addon/lib/icon-library.js b/app/assets/javascripts/discourse-common/addon/lib/icon-library.js index f165968c8e6..a1a64b08c94 100644 --- a/app/assets/javascripts/discourse-common/addon/lib/icon-library.js +++ b/app/assets/javascripts/discourse-common/addon/lib/icon-library.js @@ -3,7 +3,7 @@ import { isDevelopment } from "discourse-common/config/environment"; import attributeHook from "discourse-common/lib/attribute-hook"; import deprecated from "discourse-common/lib/deprecated"; import escape from "discourse-common/lib/escape"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; const SVG_NAMESPACE = "http://www.w3.org/2000/svg"; let _renderers = []; diff --git a/app/assets/javascripts/discourse/app/components/auth-token-dropdown.js b/app/assets/javascripts/discourse/app/components/auth-token-dropdown.js index bf3f2d02748..ca8e39efa9e 100644 --- a/app/assets/javascripts/discourse/app/components/auth-token-dropdown.js +++ b/app/assets/javascripts/discourse/app/components/auth-token-dropdown.js @@ -1,5 +1,5 @@ import { computed } from "@ember/object"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; import DropdownSelectBoxComponent from "select-kit/components/dropdown-select-box"; export default DropdownSelectBoxComponent.extend({ diff --git a/app/assets/javascripts/discourse/app/components/avatar-uploader.js b/app/assets/javascripts/discourse/app/components/avatar-uploader.js index b0e5b474de0..ed17fa11442 100644 --- a/app/assets/javascripts/discourse/app/components/avatar-uploader.js +++ b/app/assets/javascripts/discourse/app/components/avatar-uploader.js @@ -3,7 +3,7 @@ import { action } from "@ember/object"; import { isBlank } from "@ember/utils"; import UppyUploadMixin from "discourse/mixins/uppy-upload"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default Component.extend(UppyUploadMixin, { type: "avatar", diff --git a/app/assets/javascripts/discourse/app/components/badge-selector.js b/app/assets/javascripts/discourse/app/components/badge-selector.js index 0384c2dd6d5..3495cd50b5c 100644 --- a/app/assets/javascripts/discourse/app/components/badge-selector.js +++ b/app/assets/javascripts/discourse/app/components/badge-selector.js @@ -6,7 +6,7 @@ import discourseComputed, { observes, on, } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default Component.extend({ @discourseComputed("placeholderKey") diff --git a/app/assets/javascripts/discourse/app/components/badge-title.js b/app/assets/javascripts/discourse/app/components/badge-title.js index 6ed9c9501bc..f48c2272498 100644 --- a/app/assets/javascripts/discourse/app/components/badge-title.js +++ b/app/assets/javascripts/discourse/app/components/badge-title.js @@ -2,7 +2,7 @@ import Component from "@ember/component"; import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import { ajax } from "discourse/lib/ajax"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default Component.extend({ dialog: service(), diff --git a/app/assets/javascripts/discourse/app/components/bookmark-actions-dropdown.js b/app/assets/javascripts/discourse/app/components/bookmark-actions-dropdown.js index 7cac9bd4f2c..db614d75395 100644 --- a/app/assets/javascripts/discourse/app/components/bookmark-actions-dropdown.js +++ b/app/assets/javascripts/discourse/app/components/bookmark-actions-dropdown.js @@ -1,6 +1,6 @@ import { action } from "@ember/object"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; import DropdownSelectBoxComponent from "select-kit/components/dropdown-select-box"; const ACTION_REMOVE = "remove"; diff --git a/app/assets/javascripts/discourse/app/components/bookmark-icon.js b/app/assets/javascripts/discourse/app/components/bookmark-icon.js index 76e13877fcc..351304b5d73 100644 --- a/app/assets/javascripts/discourse/app/components/bookmark-icon.js +++ b/app/assets/javascripts/discourse/app/components/bookmark-icon.js @@ -6,7 +6,7 @@ import { NO_REMINDER_ICON, WITH_REMINDER_ICON, } from "discourse/models/bookmark"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class BookmarkIcon extends Component { tagName = ""; diff --git a/app/assets/javascripts/discourse/app/components/bookmark-list.js b/app/assets/javascripts/discourse/app/components/bookmark-list.js index e7e17485494..7795eb6500d 100644 --- a/app/assets/javascripts/discourse/app/components/bookmark-list.js +++ b/app/assets/javascripts/discourse/app/components/bookmark-list.js @@ -9,7 +9,7 @@ import { openLinkInNewTab, shouldOpenInNewTab, } from "discourse/lib/click-track"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default Component.extend({ dialog: service(), diff --git a/app/assets/javascripts/discourse/app/components/bootstrap-mode-notice.js b/app/assets/javascripts/discourse/app/components/bootstrap-mode-notice.js index 7b731ea484d..a9ec0474375 100644 --- a/app/assets/javascripts/discourse/app/components/bootstrap-mode-notice.js +++ b/app/assets/javascripts/discourse/app/components/bootstrap-mode-notice.js @@ -4,7 +4,7 @@ import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import DiscourseURL from "discourse/lib/url"; import getURL from "discourse-common/lib/get-url"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class BootstrapModeNotice extends Component { @service siteSettings; diff --git a/app/assets/javascripts/discourse/app/components/bulk-actions/notification-level.js b/app/assets/javascripts/discourse/app/components/bulk-actions/notification-level.js index c04e1f3bd0f..e5c67dddc25 100644 --- a/app/assets/javascripts/discourse/app/components/bulk-actions/notification-level.js +++ b/app/assets/javascripts/discourse/app/components/bulk-actions/notification-level.js @@ -2,7 +2,7 @@ import Component from "@glimmer/component"; import { action } from "@ember/object"; import { empty } from "@ember/object/computed"; import { topicLevels } from "discourse/lib/notification-levels"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; // Support for changing the notification level of various topics export default class NotificationLevel extends Component { diff --git a/app/assets/javascripts/discourse/app/components/bulk-group-member-dropdown.js b/app/assets/javascripts/discourse/app/components/bulk-group-member-dropdown.js index 2d9de62ca7a..9a96a9d80b4 100644 --- a/app/assets/javascripts/discourse/app/components/bulk-group-member-dropdown.js +++ b/app/assets/javascripts/discourse/app/components/bulk-group-member-dropdown.js @@ -1,5 +1,5 @@ import { computed } from "@ember/object"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; import DropdownSelectBoxComponent from "select-kit/components/dropdown-select-box"; export default DropdownSelectBoxComponent.extend({ diff --git a/app/assets/javascripts/discourse/app/components/calendar-date-time-input.js b/app/assets/javascripts/discourse/app/components/calendar-date-time-input.js index e758ea28fe8..44b4b94003e 100644 --- a/app/assets/javascripts/discourse/app/components/calendar-date-time-input.js +++ b/app/assets/javascripts/discourse/app/components/calendar-date-time-input.js @@ -5,7 +5,7 @@ import { action } from "@ember/object"; import { isEmpty } from "@ember/utils"; import { Promise } from "rsvp"; import loadScript from "discourse/lib/load-script"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class CalendarDateTimeInput extends Component { _timeFormat = this.args.timeFormat || "HH:mm:ss"; diff --git a/app/assets/javascripts/discourse/app/components/category-permission-row.js b/app/assets/javascripts/discourse/app/components/category-permission-row.js index 4b7d8d7b406..b7a80a193e3 100644 --- a/app/assets/javascripts/discourse/app/components/category-permission-row.js +++ b/app/assets/javascripts/discourse/app/components/category-permission-row.js @@ -3,7 +3,7 @@ import { action } from "@ember/object"; import { alias, equal } from "@ember/object/computed"; import PermissionType from "discourse/models/permission-type"; import discourseComputed, { observes } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; const EVERYONE = "everyone"; diff --git a/app/assets/javascripts/discourse/app/components/color-picker-choice.js b/app/assets/javascripts/discourse/app/components/color-picker-choice.js index 0da584de48f..36a0bfd441a 100644 --- a/app/assets/javascripts/discourse/app/components/color-picker-choice.js +++ b/app/assets/javascripts/discourse/app/components/color-picker-choice.js @@ -1,7 +1,7 @@ import Component from "@ember/component"; import { htmlSafe } from "@ember/template"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default Component.extend({ tagName: "button", diff --git a/app/assets/javascripts/discourse/app/components/composer-action-title.js b/app/assets/javascripts/discourse/app/components/composer-action-title.js index 684957921ec..09e78efc4ab 100644 --- a/app/assets/javascripts/discourse/app/components/composer-action-title.js +++ b/app/assets/javascripts/discourse/app/components/composer-action-title.js @@ -12,7 +12,7 @@ import { import escape from "discourse-common/lib/escape"; import { iconHTML } from "discourse-common/lib/icon-library"; import discourseComputed from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; const TITLES = { [PRIVATE_MESSAGE]: "topic.private_message", diff --git a/app/assets/javascripts/discourse/app/components/composer-editor.js b/app/assets/javascripts/discourse/app/components/composer-editor.js index 45db29d68cb..d89ab32a60a 100644 --- a/app/assets/javascripts/discourse/app/components/composer-editor.js +++ b/app/assets/javascripts/discourse/app/components/composer-editor.js @@ -43,7 +43,7 @@ import discourseComputed, { observes, on, } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; // original string `![image|foo=bar|690x220, 50%|bar=baz](upload://1TjaobgKObzpU7xRMw2HuUc87vO.png "image title")` // group 1 `image|foo=bar` diff --git a/app/assets/javascripts/discourse/app/components/composer-messages.js b/app/assets/javascripts/discourse/app/components/composer-messages.js index 8587f83898f..57bf1a5f996 100644 --- a/app/assets/javascripts/discourse/app/components/composer-messages.js +++ b/app/assets/javascripts/discourse/app/components/composer-messages.js @@ -8,7 +8,7 @@ import { ajax } from "discourse/lib/ajax"; import LinkLookup from "discourse/lib/link-lookup"; import { INPUT_DELAY } from "discourse-common/config/environment"; import { debounce } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; let _messagesCache = {}; diff --git a/app/assets/javascripts/discourse/app/components/composer-save-button.js b/app/assets/javascripts/discourse/app/components/composer-save-button.js index e2e8a2cae38..10525e55e65 100644 --- a/app/assets/javascripts/discourse/app/components/composer-save-button.js +++ b/app/assets/javascripts/discourse/app/components/composer-save-button.js @@ -1,6 +1,6 @@ import Component from "@glimmer/component"; import { translateModKey } from "discourse/lib/utilities"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class ComposerSaveButton extends Component { get translatedTitle() { diff --git a/app/assets/javascripts/discourse/app/components/composer-title.js b/app/assets/javascripts/discourse/app/components/composer-title.js index 251e686dad7..a2a54c038e4 100644 --- a/app/assets/javascripts/discourse/app/components/composer-title.js +++ b/app/assets/javascripts/discourse/app/components/composer-title.js @@ -9,7 +9,7 @@ import putCursorAtEnd from "discourse/lib/put-cursor-at-end"; import { isTesting } from "discourse-common/config/environment"; import discourseDebounce from "discourse-common/lib/debounce"; import discourseComputed, { observes } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default Component.extend({ classNames: ["title-input"], diff --git a/app/assets/javascripts/discourse/app/components/conditional-loading-section.js b/app/assets/javascripts/discourse/app/components/conditional-loading-section.js index c3dc936c49e..903bb472881 100644 --- a/app/assets/javascripts/discourse/app/components/conditional-loading-section.js +++ b/app/assets/javascripts/discourse/app/components/conditional-loading-section.js @@ -1,5 +1,5 @@ import Component from "@ember/component"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default Component.extend({ classNames: ["conditional-loading-section"], diff --git a/app/assets/javascripts/discourse/app/components/count-i18n.js b/app/assets/javascripts/discourse/app/components/count-i18n.js index 87c43c0e0e8..265c7a989c1 100644 --- a/app/assets/javascripts/discourse/app/components/count-i18n.js +++ b/app/assets/javascripts/discourse/app/components/count-i18n.js @@ -1,6 +1,6 @@ import Component from "@ember/component"; import { htmlSafe } from "@ember/template"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default Component.extend({ tagName: "span", diff --git a/app/assets/javascripts/discourse/app/components/d-button.gjs b/app/assets/javascripts/discourse/app/components/d-button.gjs index 1a8175fea2e..91bee03d9dd 100644 --- a/app/assets/javascripts/discourse/app/components/d-button.gjs +++ b/app/assets/javascripts/discourse/app/components/d-button.gjs @@ -8,7 +8,7 @@ import concatClass from "discourse/helpers/concat-class"; import DiscourseURL from "discourse/lib/url"; import icon from "discourse-common/helpers/d-icon"; import deprecated from "discourse-common/lib/deprecated"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; import or from "truth-helpers/helpers/or"; const ACTION_AS_STRING_DEPRECATION_ARGS = [ diff --git a/app/assets/javascripts/discourse/app/components/d-document.js b/app/assets/javascripts/discourse/app/components/d-document.js index 3b58bd491c0..b2ca38a565f 100644 --- a/app/assets/javascripts/discourse/app/components/d-document.js +++ b/app/assets/javascripts/discourse/app/components/d-document.js @@ -3,7 +3,7 @@ import { inject as service } from "@ember/service"; import { setLogoffCallback } from "discourse/lib/ajax"; import logout from "discourse/lib/logout"; import { bind } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; let pluginCounterFunctions = []; export function addPluginDocumentTitleCounter(counterFunction) { diff --git a/app/assets/javascripts/discourse/app/components/d-editor.js b/app/assets/javascripts/discourse/app/components/d-editor.js index 6971c757dfa..0f0fc1bcbd3 100644 --- a/app/assets/javascripts/discourse/app/components/d-editor.js +++ b/app/assets/javascripts/discourse/app/components/d-editor.js @@ -40,7 +40,7 @@ import discourseComputed, { observes, on, } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; function getButtonLabel(labelKey, defaultLabel) { // use the Font Awesome icon if the label matches the default diff --git a/app/assets/javascripts/discourse/app/components/d-modal-legacy.js b/app/assets/javascripts/discourse/app/components/d-modal-legacy.js index ac12c31cea0..ac97bffdbbf 100644 --- a/app/assets/javascripts/discourse/app/components/d-modal-legacy.js +++ b/app/assets/javascripts/discourse/app/components/d-modal-legacy.js @@ -7,7 +7,7 @@ import { next, schedule } from "@ember/runloop"; import { inject as service } from "@ember/service"; import { disableImplicitInjections } from "discourse/lib/implicit-injections"; import { bind } from "discourse-common/utils/decorators"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; @disableImplicitInjections export default class DModal extends Component { diff --git a/app/assets/javascripts/discourse/app/components/d-toggle-switch.gjs b/app/assets/javascripts/discourse/app/components/d-toggle-switch.gjs index 1a548d26438..0285e1a2874 100644 --- a/app/assets/javascripts/discourse/app/components/d-toggle-switch.gjs +++ b/app/assets/javascripts/discourse/app/components/d-toggle-switch.gjs @@ -1,6 +1,6 @@ import Component from "@glimmer/component"; import icon from "discourse-common/helpers/d-icon"; -import I18n from "I18n"; +import I18n from "discourse-i18n"; export default class DToggleSwitch extends Component {