Commit 5bbb021
authored
Remove redundant hardcoded sizes on Compose design icons (#6478)
* refactor(compose): drop redundant 20dp hardcoded sizes on design icons
Removes Modifier.size(20.dp) from Icon call sites that paint a 20dp
intrinsic stream_design_ic_* drawable. The size is redundant because
Icon falls back to the painter's intrinsic size when no size modifier
is applied, and removing it lets integrators override the drawable
file to drive the rendered size.
Touched: ComposerCancelIcon, AudioRecordAttachmentContent
PlaybackToggleButton, UnsupportedAttachmentContent, VideoPlaybackControls
play/pause toggle, AddMembersScreen back arrow.
* refactor(compose): drop redundant 20dp sizes on poll icons
Removes Modifier.size(20.dp) from poll-feature icons painted with 20dp
intrinsic drawables: PollAnswers add-answer button, PollOptionList
remove and error icons, PollSwitchList StepperButton minus/plus icons.
* refactor(compose): drop redundant 20dp sizes in media gallery preview
Removes Modifier.size(20.dp) from the share/cancel-share and photos
icons in MediaGalleryPreviewScreen, and from the option-row icon in
MediaGalleryPreviewOptionsMenu. Every painter consumed by these call
sites is a 20dp intrinsic stream_design_ic_* drawable, so the size
modifier was redundant.
* refactor(compose): drop redundant 20dp sizes in ContextualMenuItem
Removes Modifier.size(20.dp) from both leadingIcon and trailingIcon
Icons in ContextualMenuItem. Every caller (message action options,
the in-file MenuItem preview) passes a 20dp intrinsic
stream_design_ic_* drawable, so the hardcoded size was redundant and
blocked integrator drawable overrides from propagating.
* refactor(compose): drop redundant 20dp size on MessageFailedIcon
The MessageFailedIcon factory paints a 20dp intrinsic
stream_design_ic_exclamation_circle_fill, so the .size(20.dp) injected
into MessageFailedIconParams.modifier by callers was redundant.
Removes it from the two MessageContainer call sites and the
PollMessageContent call site.1 parent bcc03be commit 5bbb021
13 files changed
Lines changed: 0 additions & 25 deletions
File tree
- stream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui
- attachments
- content
- preview
- internal
- channel/info
- components
- common
- messages
- poll
- messages
- attachments/poll
- list
Lines changed: 0 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
300 | 300 | | |
301 | 301 | | |
302 | 302 | | |
303 | | - | |
304 | 303 | | |
305 | 304 | | |
306 | 305 | | |
| |||
Lines changed: 0 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
24 | | - | |
25 | 24 | | |
26 | 25 | | |
27 | 26 | | |
| |||
32 | 31 | | |
33 | 32 | | |
34 | 33 | | |
35 | | - | |
36 | 34 | | |
37 | 35 | | |
38 | 36 | | |
| |||
80 | 78 | | |
81 | 79 | | |
82 | 80 | | |
83 | | - | |
84 | 81 | | |
85 | 82 | | |
86 | 83 | | |
| |||
Lines changed: 0 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
25 | | - | |
26 | 25 | | |
27 | 26 | | |
28 | 27 | | |
| |||
37 | 36 | | |
38 | 37 | | |
39 | 38 | | |
40 | | - | |
41 | 39 | | |
42 | 40 | | |
43 | 41 | | |
| |||
132 | 130 | | |
133 | 131 | | |
134 | 132 | | |
135 | | - | |
136 | 133 | | |
137 | 134 | | |
138 | 135 | | |
| |||
Lines changed: 0 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
873 | 873 | | |
874 | 874 | | |
875 | 875 | | |
876 | | - | |
877 | 876 | | |
878 | 877 | | |
879 | 878 | | |
| |||
949 | 948 | | |
950 | 949 | | |
951 | 950 | | |
952 | | - | |
953 | 951 | | |
954 | 952 | | |
955 | 953 | | |
| |||
Lines changed: 0 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
114 | 114 | | |
115 | 115 | | |
116 | 116 | | |
117 | | - | |
118 | 117 | | |
119 | 118 | | |
120 | 119 | | |
| |||
Lines changed: 0 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
179 | 179 | | |
180 | 180 | | |
181 | 181 | | |
182 | | - | |
183 | 182 | | |
184 | 183 | | |
185 | 184 | | |
| |||
Lines changed: 0 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
22 | | - | |
23 | 22 | | |
24 | 23 | | |
25 | 24 | | |
| |||
52 | 51 | | |
53 | 52 | | |
54 | 53 | | |
55 | | - | |
56 | 54 | | |
57 | 55 | | |
58 | 56 | | |
| |||
Lines changed: 0 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
29 | 28 | | |
30 | 29 | | |
31 | 30 | | |
| |||
96 | 95 | | |
97 | 96 | | |
98 | 97 | | |
99 | | - | |
100 | 98 | | |
101 | 99 | | |
102 | 100 | | |
| |||
114 | 112 | | |
115 | 113 | | |
116 | 114 | | |
117 | | - | |
118 | 115 | | |
119 | 116 | | |
120 | 117 | | |
| |||
Lines changed: 0 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
160 | 160 | | |
161 | 161 | | |
162 | 162 | | |
163 | | - | |
164 | 163 | | |
165 | 164 | | |
166 | 165 | | |
| |||
Lines changed: 0 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
58 | 58 | | |
59 | 59 | | |
60 | 60 | | |
61 | | - | |
62 | 61 | | |
63 | 62 | | |
64 | 63 | | |
| |||
156 | 155 | | |
157 | 156 | | |
158 | 157 | | |
159 | | - | |
160 | 158 | | |
161 | 159 | | |
162 | 160 | | |
| |||
0 commit comments