-
Notifications
You must be signed in to change notification settings - Fork 987
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
chore: remove colors/dark? method from colors file and update uses #17202
Conversation
Jenkins BuildsClick to see older builds (32)
|
fe641f0
to
f3d35b2
Compare
@@ -296,10 +296,6 @@ | |||
(let [theme (or override-theme (theme/get-theme))] | |||
(if (= theme :light) light dark)))) | |||
|
|||
(defn dark? |
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.
🎯 removed this method. Imo it is odd to mix the colors and theming functionality/mechanisms like this. We should keep them separate in implementation and uses.
src/status_im2/common/resources.cljs
Outdated
@@ -88,6 +119,8 @@ | |||
(js/require "../resources/videos2/generating_keys_02.mp4") | |||
(js/require "../resources/videos2/generating_keys_03.mp4")]}) | |||
|
|||
|
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.
uff, will adjust empty lines
@@ -97,5 +130,5 @@ | |||
(get ui k)) | |||
|
|||
(defn get-themed-image |
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.
this method previously needed both keys, to me it seems better to use one key and have the themed options defined in the map. 👍 / 👎 ?
@@ -65,13 +69,17 @@ | |||
:style style/authors-list}]]) | |||
|
|||
(defn reaction-authors |
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.
it seems this file has many components exported. at the very least we should mark the defn
s that are not intended to be used outside as private to avoid later misuses. Or alternatively it is easier if each file has one exported component (view
).
([] (navbar nil))) | ||
|
||
(defn statusbar | ||
([dark?] | ||
(let [style (if (or dark? (colors/dark?)) :light :dark)] | ||
(let [style (if (or dark? (quo.theme/get-theme)) :light :dark)] |
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.
uses of (quo.theme/get-theme)
are temporary as I will address this properly in a separate pr. there's more pieces involved to change navigation code wrt to theming
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.
Shouldn't we change the condition to (or dark? (= :dark (quo.theme/get-theme)))
since we are replacing (colors/dark?)
with (quo.theme/get-theme)
?
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.
yep, thanks! :)
src/status_im2/navigation/roots.cljs
Outdated
@@ -94,7 +95,7 @@ | |||
:children [{:component {:name :shell-stack | |||
:id :shell-stack | |||
:options (options/default-root | |||
(if (colors/dark?) :light :dark))}}]}}} | |||
(if (quo.theme/get-theme) :light :dark))}}]}}} |
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.
same here 👍
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.
(= :dark (quo.theme/get-theme))
?
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.
yes you are right, thanks @ajayesivan!
f3d35b2
to
cc7b769
Compare
cc7b769
to
d4b7e74
Compare
37% of end-end tests have passed
Failed tests (27)Click to expandClass TestOneToOneChatMultipleSharedDevicesNewUiTwo:
Class TestCommunityOneDeviceMerged:
Class TestCommunityMultipleDeviceMerged:
Class TestOneToOneChatMultipleSharedDevicesNewUi:
Class TestActivityMultipleDevicePRTwo:
Class TestCommunityMultipleDeviceMergedTwo:
Class TestGroupChatMultipleDeviceMergedNewUI:
Passed tests (16)Click to expandClass TestActivityCenterContactRequestMultipleDevicePR:
Class TestOneToOneChatMultipleSharedDevicesNewUiTwo:
Class TestCommunityOneDeviceMerged:
Class TestActivityMultipleDevicePRTwo:
Class TestCommunityMultipleDeviceMergedTwo:
Class TestGroupChatMultipleDeviceMergedNewUI:
Class TestActivityMultipleDevicePR:
|
@J-Son89 can you please resolve the conflicts and rebase the PR? |
d4b7e74
to
e917496
Compare
rebased 👍 |
f46ce9f
to
61766b6
Compare
61766b6
to
4d5a3cf
Compare
60% of end-end tests have passed
Failed tests (17)Click to expandClass TestGroupChatMultipleDeviceMergedNewUI:
Class TestCommunityMultipleDeviceMerged:
Class TestCommunityOneDeviceMerged:
Class TestOneToOneChatMultipleSharedDevicesNewUi:
Class TestCommunityMultipleDeviceMergedTwo:
Passed tests (26)Click to expandClass TestOneToOneChatMultipleSharedDevicesNewUiTwo:
Class TestActivityCenterContactRequestMultipleDevicePR:
Class TestGroupChatMultipleDeviceMergedNewUI:
Class TestCommunityMultipleDeviceMerged:
Class TestCommunityOneDeviceMerged:
Class TestActivityMultipleDevicePRTwo:
Class TestCommunityMultipleDeviceMergedTwo:
Class TestActivityMultipleDevicePR:
|
Hi @J-Son89. unfortunately, the issue is still reproduced in e2e |
4d5a3cf
to
7a0c5c9
Compare
@VolodLytvynenko - found the issue. I could reproduce it by long pressing on reaction buttons in chat. I have since fixed this issue. it was a simple fix in the code. apologies about that! |
74% of end-end tests have passed
Failed tests (11)Click to expandClass TestActivityMultipleDevicePR:
Class TestCommunityOneDeviceMerged:
Class TestOneToOneChatMultipleSharedDevicesNewUi:
Class TestCommunityMultipleDeviceMergedTwo:
Class TestCommunityMultipleDeviceMerged:
Class TestGroupChatMultipleDeviceMergedNewUI:
Class TestOneToOneChatMultipleSharedDevicesNewUiTwo:
Passed tests (32)Click to expandClass TestActivityCenterContactRequestMultipleDevicePR:
Class TestActivityMultipleDevicePRTwo:
Class TestCommunityOneDeviceMerged:
Class TestOneToOneChatMultipleSharedDevicesNewUi:
Class TestCommunityMultipleDeviceMergedTwo:
Class TestCommunityMultipleDeviceMerged:
Class TestGroupChatMultipleDeviceMergedNewUI:
Class TestOneToOneChatMultipleSharedDevicesNewUiTwo:
|
100% of end-end tests have passed
Passed tests (3)Click to expandClass TestActivityMultipleDevicePR:
Class TestCommunityMultipleDeviceMerged:
|
@J-Son89 Thank you for the fixes. No issues from my side anymore @Francesca-G could you take a look?
|
@VolodLytvynenko should we tag @pedro-et here to check these since Franchesca is off this week? |
Hi @J-Son89 you are right. PR can be merged. No need for design review in this case |
7a0c5c9
to
df49d72
Compare
@@ -126,7 +126,7 @@ | |||
(defn change-shell-status-bar-style | |||
[] | |||
(rf/dispatch [:change-shell-status-bar-style | |||
(if (or (colors/dark?) | |||
(if (or (quo.theme/get-theme) |
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.
(= :dark (quo.theme/get-theme))
?
btw, quo.theme also has dark?
function
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.
whoops, yes this needs to be updated! good spot @Parveshdhull
a continuation of: #16400
This pr removes the function
colors/dark?
as (imo) we should keep theming and colors seprate in functionality.There is no real functional changes here or UI changes. Everything changed is internal mechansims.
Also I adjusted the theme resources to be a little easier to use, i.e we only reference one key and pass theme as a prop to this method. I will leave a comment on this in pr
To test:
A few components have been adjusted:
Quo title input
https://www.figma.com/file/WQZcp6S0EnzxdTL4taoKDv/Design-System-for-Mobile?type=design&node-id=18490-198563&mode=design&t=OgIHdFbuaBLD9th1-4
Quo - Key card component - no uses in application
Quo record audio buttons -
Additionally a few of the chat screens are updated here.
The jump to page