DEV: Set priorities on user tips (#29176)

Currently the topic timeline tip appears before the suggested topics one only due to a small implementation detail in the latter.

This ensures that tips appear in the expected order when more than one of these components is rendered at the same time.
This commit is contained in:
Jarek Radosz 2024-10-14 09:54:01 +02:00 committed by GitHub
parent bf773e70bd
commit a3ea2886dc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 4 additions and 0 deletions

View File

@ -64,6 +64,7 @@ export default class Notifications extends Component {
@titleText={{i18n "user_tips.first_notification.title"}} @titleText={{i18n "user_tips.first_notification.title"}}
@contentText={{i18n "user_tips.first_notification.content"}} @contentText={{i18n "user_tips.first_notification.content"}}
@showSkipButton={{true}} @showSkipButton={{true}}
@priority={{40}}
/> />
{{/if}} {{/if}}

View File

@ -12,6 +12,7 @@
@titleText={{i18n "user_tips.suggested_topics.title"}} @titleText={{i18n "user_tips.suggested_topics.title"}}
@contentText={{i18n "user_tips.suggested_topics.content"}} @contentText={{i18n "user_tips.suggested_topics.content"}}
@placement="top-start" @placement="top-start"
@priority={{10}}
/> />
{{/unless}} {{/unless}}

View File

@ -97,6 +97,7 @@
@triggerSelector=".notifications-button" @triggerSelector=".notifications-button"
@titleText={{i18n "user_tips.topic_notification_levels.title"}} @titleText={{i18n "user_tips.topic_notification_levels.title"}}
@contentText={{i18n "user_tips.topic_notification_levels.content"}} @contentText={{i18n "user_tips.topic_notification_levels.content"}}
@priority={{20}}
/> />
{{/if}} {{/if}}

View File

@ -67,6 +67,7 @@
@contentText={{i18n "user_tips.topic_timeline.content"}} @contentText={{i18n "user_tips.topic_timeline.content"}}
@placement="left" @placement="left"
@triggerSelector=".timeline-scrollarea-wrapper" @triggerSelector=".timeline-scrollarea-wrapper"
@priority={{30}}
/> />
<div class="timeline-scrollarea-wrapper"> <div class="timeline-scrollarea-wrapper">