-
Notifications
You must be signed in to change notification settings - Fork 299
Closed
Labels
DEV: frontendcommunity-contribution-in-progresshelp wantedOpen source contributors welcomeOpen source contributors welcome
Description
🙂 Looking for an issue? Welcome! This issue is open for contribution. If this is the first time you’re requesting an issue, please:
- Read Contributing guidelines carefully. Pay extra attention to Using generative AI. Pull requests and comments that don’t follow the guidelines won’t be answered.
- Confirm that you’ve read the guidelines in your comment.
Sub-issue of #5060.
Complexity: Medium
Summary
Migrate the offline alert bar in Settings from Vuetify to Kolibri Design System.
shared/views/OfflineText that is built with Vuetify components is used for the banner. To remove this dependency from SettingsIndex, create a new shared/views/StudioOfflineAlert component that doesn't use Vuetify. Then use StudioOfflineAlert in SettingsIndex instead of OfflineText. Do not modify shared/views/OfflineText or how it's used in other areas of the codebase.
StudioOfflineAlert requirements
- Expected usage example:
// SettingsIndex.vue
<StudioOfflineAlert :offset="112" />- Visually same output as
OfflineText - Sticky behavior is same
offsetprop is same- Internal logic related to
offlinemappedstateandlibraryModeis same - Other than above, implementation doesn't map exactly to that of
OfflineText, and is limited only to logic that is needed in Settings:- No need for
indicatorandofflineTextprops and related logic - Shows as bar by default so
toolbarprop is not needed
- No need for
- Use
KTransitionincomponent-vertical-slide-out-inmode for transition. - Use
token.surfacefor bar background color OfflineTexthas several markup, a11y, and visual problems. Avoid them inStudioOfflineAlertby ensuring:- It renders as
<div>, not<nav> - On all screen sizes, alert text doesn't overflow the bar area
- On all screen sizes, it is positioned below the main navigation without any gap
- Announce appearance and disappearance of the alert to screen reader users via
useKLiveRegion. When the alert appears, send polite messageYou seem to be offline. Your changes will be saved once your connection is back.When the alert disappears, send polite messageYou are back online.Messages need to be translated.
- It renders as
How to get there
- Login as
user@a.comwith passworda - Go to Settings
- Turn on / off offline mode in browser development tools
Guidance
- Read the project this issue is part of
Out of Scope
- Do not refactor any other areas of the codebase
- Do not modify
OfflineText
Expected UI/UX changes
- Except bugfixes listed above that will be resolved by the new component, none.
Acceptance criteria
General
- The specification above is followed.
- Except for "Expected UI/UX changes," there are no functional or visual differences in user experience.
- All user interactions are manually tested with no regressions.
- Pull request includes screenshots.
a11y and i18n
See the project's "Guidance" for useful references.
- Implementation meets a11y standards
- All components are LTR and RTL compliant
- All user-facing strings are translated properly
- The
notranslateclass been added to elements that shouldn't be translated by Google Chrome's automatic translation feature (e.g. user-generated text) - Mobile experience is reasonable
Unit tests
- If there is a unit test suite already, it is meaningfully updated (even if tests don't fail)
- If there is no unit test suite, a new one is created. Do not use obsolete
@vue/test-utilsapproach. Instead, use Vue Testing Library.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
DEV: frontendcommunity-contribution-in-progresshelp wantedOpen source contributors welcomeOpen source contributors welcome

