diff --git a/app/assets/javascripts/discourse/app/components/bootstrap-mode-notice.hbs b/app/assets/javascripts/discourse/app/components/bootstrap-mode-notice.hbs index 1b42599be43..3078dc4c160 100644 --- a/app/assets/javascripts/discourse/app/components/bootstrap-mode-notice.hbs +++ b/app/assets/javascripts/discourse/app/components/bootstrap-mode-notice.hbs @@ -5,12 +5,7 @@ {{did-insert this.setupUserTip}} > {{#if this.showUserTip}} - + {{else}}
@@ -18,7 +13,7 @@ {{i18n "user_tips.admin_guide.title"}}
- {{i18n "user_tips.admin_guide.content"}} + {{i18n "user_tips.admin_guide.content_no_url"}}
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 7ff6a5d61c6..128aff7fab0 100644 --- a/app/assets/javascripts/discourse/app/components/bootstrap-mode-notice.js +++ b/app/assets/javascripts/discourse/app/components/bootstrap-mode-notice.js @@ -1,7 +1,9 @@ +import getURL from "discourse-common/lib/get-url"; import { action } from "@ember/object"; import { inject as service } from "@ember/service"; import Component from "@glimmer/component"; import { tracked } from "@glimmer/tracking"; +import I18n from "I18n"; import DiscourseURL from "discourse/lib/url"; export default class BootstrapModeNotice extends Component { @@ -22,4 +24,14 @@ export default class BootstrapModeNotice extends Component { `/t/-/${this.siteSettings.admin_quick_start_topic_id}` ); } + + get adminGuideUrl() { + return getURL(`/t/-/${this.siteSettings.admin_quick_start_topic_id}`); + } + + get userTipContent() { + return I18n.t("user_tips.admin_guide.content", { + admin_guide_url: this.adminGuideUrl, + }); + } } diff --git a/app/assets/javascripts/discourse/app/components/user-tip.js b/app/assets/javascripts/discourse/app/components/user-tip.js index 27e3d78fb44..9684bf54618 100644 --- a/app/assets/javascripts/discourse/app/components/user-tip.js +++ b/app/assets/javascripts/discourse/app/components/user-tip.js @@ -29,7 +29,8 @@ export default class UserTip extends Component { this.currentUser.showUserTip({ id, titleText: I18n.t(`user_tips.${id}.title`), - contentText: content || I18n.t(`user_tips.${id}.content`), + contentHtml: content, + contentText: I18n.t(`user_tips.${id}.content`), buttonLabel, buttonIcon, reference: diff --git a/app/assets/javascripts/discourse/app/lib/user-tips.js b/app/assets/javascripts/discourse/app/lib/user-tips.js index 79295fe9f39..6a58bb06229 100644 --- a/app/assets/javascripts/discourse/app/lib/user-tips.js +++ b/app/assets/javascripts/discourse/app/lib/user-tips.js @@ -90,7 +90,9 @@ export function showUserTip(options) { options.content || `
${escape(options.titleText)}
-
${escape(options.contentText)}
+
${ + options.contentHtml || escape(options.contentText) + }
diff --git a/app/assets/stylesheets/common/base/user-tips.scss b/app/assets/stylesheets/common/base/user-tips.scss index 73d168d2dc7..ea432faabfe 100644 --- a/app/assets/stylesheets/common/base/user-tips.scss +++ b/app/assets/stylesheets/common/base/user-tips.scss @@ -45,6 +45,11 @@ &__content { margin-top: 0.25em; + + a { + color: var(--secondary); + text-decoration: underline; + } } &__buttons { diff --git a/config/locales/client.en.yml b/config/locales/client.en.yml index 39438309736..da297da8fa7 100644 --- a/config/locales/client.en.yml +++ b/config/locales/client.en.yml @@ -1933,8 +1933,8 @@ en: admin_guide: title: "Welcome to your new site!" - content: "Read the admin guide to continue building your site and community." - button: "Let's go!" + content: "Read the admin guide to continue building your site and community." + content_no_url: "Read the admin guide to continue building your site and community." loading: "Loading..." errors: