From 520ad654a765489f436557bc9db93beeab04d994 Mon Sep 17 00:00:00 2001 From: Alan Guo Xiang Tan Date: Wed, 24 Apr 2024 14:03:28 +0800 Subject: [PATCH] DEV: Migrate small_links to new objects setting type This commit migrates the `small_links` theme setting to `type: objects`. Since https://github.com/discourse/discourse/commit/a440e15291e98a866f80a6566d5ec0597ab77e2e, we have started to support objects typed theme setting so we are switching this theme component to use it instead as it provides a much better UX for configuring the settings required for the theme component. --- .../discourse/components/custom-footer.hbs | 7 ++- .../discourse/components/custom-footer.js | 18 -------- locales/en.yml | 18 +++++--- .../0003-migrate-small-links-setting.js | 33 ++++++++++++++ settings.yml | 39 ++++++++++++++-- .../0003-migrate-small-links-setting-test.js | 44 +++++++++++++++++++ 6 files changed, 129 insertions(+), 30 deletions(-) create mode 100644 migrations/settings/0003-migrate-small-links-setting.js create mode 100644 test/unit/migrations/settings/0003-migrate-small-links-setting-test.js diff --git a/javascripts/discourse/components/custom-footer.hbs b/javascripts/discourse/components/custom-footer.hbs index 8451be8..9b4f4f1 100644 --- a/javascripts/discourse/components/custom-footer.hbs +++ b/javascripts/discourse/components/custom-footer.hbs @@ -47,13 +47,12 @@