-
Notifications
You must be signed in to change notification settings - Fork 710
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Replace KResponsiveWindow mixin by useKResponsiveWindow composable #11321
Comments
Note that the current version of |
If you'd like to contribute, please don't ask for an assignment of this issue, but rather in a sub-issue. |
Hey @MisRob, I was participating in HactoberFest. |
Hello @thesujai, I will reach out back in a few days in regards to Hactoberfest |
Okay @MisRob |
@thesujai Answered here #11356 (comment) |
Summary
We extensively use
KResponsiveWindow
(provides reactive window's size information) as mixin in Kolibri. The latest version of Kolibri Design System (KDS) installed on the Kolibri'sdevelop
branch offers better alternative,useKResponsiveWindow
composable. This issue encapsulates a group of issues whose common goal is to completely get rid ofKResponsiveWindow
mixin in favor of usinguseKResponsiveWindow
composable in the whole Kolibri.Note that the ways we import the mixin in our files are not always consistent, for example you may see:
import responsiveWindowMixin from 'kolibri.coreVue.mixins.responsiveWindowMixin';
import KResponsiveWindowMixin from 'kolibri-design-system/lib/KResponsiveWindowMixin';
You can use Vue Devtools and codebase search to find out pages that need to be previewed in the app based on the components/files you're modifying. Please test your changes before opening a pull request (see acceptance criteria).
Acceptance criteria (for each one of the issues listed below)
useKResponsiveWindow
composable is used instead ofKResponsiveWindow
mixin in an area specified by a sub-issueKResponsiveWindow
(windowIsSmall
,windowBreakpoint
, etc., see the full list here) are imported fromuseKResponsiveWindow
composable in a file whereKResponsiveWindow
mixin is being removedKResponsiveWindow
mixin used for (for example, using different styling for mobile devices) is manually tested and still works as expected withuseKResponsiveWindow
composableReferences
KResponsiveWindow
documentation page. Also see the "Usage" section to understand both approaches.KResponsiveWindow
mixin in Kolibri:kolibri/kolibri/plugins/learn/assets/src/views/LearningActivityBar.vue
Line 197 in b38ad51
kolibri/kolibri/plugins/learn/assets/src/views/LearningActivityBar.vue
Line 422 in b38ad51
useKResponsiveWindow
composable in Kolibri:kolibri/kolibri/core/assets/src/views/Navbar/NavbarLink.vue
Line 31 in b38ad51
kolibri/kolibri/core/assets/src/views/Navbar/NavbarLink.vue
Line 7 in b38ad51
Sub-issues
Sub-issues
The text was updated successfully, but these errors were encountered: