-
Notifications
You must be signed in to change notification settings - Fork 984
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
Implement static loading skeleton #16474
Conversation
@@ -67,7 +67,6 @@ | |||
[status-im2.contexts.quo-preview.notifications.toast :as toast] | |||
[status-im2.contexts.quo-preview.onboarding.small-option-card :as small-option-card] | |||
[status-im2.contexts.quo-preview.password.tips :as tips] | |||
[status-im2.contexts.quo-preview.posts-and-attachments.messages-skeleton :as messages-skeleton] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably outdated, currently just a blank screen. Animated skeleton will be part of new preview screen
Jenkins Builds
|
91% of end-end tests have passed
Not executed tests (1)Failed tests (3)Click to expandClass TestGroupChatMultipleDeviceMergedNewUI:
Class TestCommunityMultipleDeviceMerged:
Class TestOneToOneChatMultipleSharedDevicesNewUi:
Passed tests (30)Click to expandClass TestActivityMultipleDevicePR:
Class TestActivityCenterContactRequestMultipleDevicePR:
Class TestGroupChatMultipleDeviceMergedNewUI:
Class TestCommunityMultipleDeviceMerged:
Class TestOneToOneChatMultipleSharedDevicesNewUi:
Class TestCommunityOneDeviceMerged:
|
^{:key index} | ||
[skeleton-item (mod index 4) content color]))])) | ||
|
||
(def view (theme/with-theme internal-view)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🙌
src/quo2/core.cljs
Outdated
@@ -113,6 +114,7 @@ | |||
(def checkbox quo2.components.selectors.selectors.view/checkbox) | |||
(def filter quo2.components.selectors.filter.view/view) | |||
(def skeleton quo2.components.loaders.skeleton/skeleton) | |||
(def static-skeleton quo2.components.loaders.skeleton.view/view) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could you make a loaders section and move it to that? same for other loaders
in this file!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Parveshdhull - Thank you for the PR!
I found that the skeleton works only on Light mode
and Dark mode + blur
. Is this expected? I believe this is not the case. Correct me if i'm wrong.
Light Mode | Light Mode + Blur | Dark Mode | Dark Mode + Blur |
---|---|---|---|
|
||
(defn content-view | ||
[{:keys [type index content color]}] | ||
(let [{:keys [width height margin-bottom margin-top]} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
margin-top
is not in constants/content-dimensions
.
:content content | ||
:color color})}])]]) | ||
|
||
(defn internal-view |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Small Improvement: Updating internal-view
as private would prevent using it without theme context.
{:label "Blur?" | ||
:key :blur? | ||
:type :boolean} | ||
{:label "Animated?" ;; Not implemented yet |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it fine to not have this option until the animation is implemented?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great, nice work @Parveshdhull!
Consider adding a few component spec test if possible too. 👍
01fa31f
to
d87b706
Compare
Hi @smohamedjavid and @J-Son89, Thank you very much for reviewing PR.
Thanks for spotting it. The problem was in the preview screen itself. It was using the same color as the loading skeleton in dark mode. |
fixes: #16473
Summary
PR implements a loading skeleton as per Figma design parameters and also adds missing content types.
PR just adds a static loading skeleton, animation of the loading skeleton will be implemented separately.
Once the animation is implemented we can remove the current implementation, until then we have to keep both.
(will create an issue for that)
Testing
Manual testing doesn't require, PR just implements the quo2 component.
status: ready