Commit 892c347
committed
refactor(search, apps): improve state management and UI consistency
This commit refines the search logic, enhances the filtering mechanism in the apps feature, and cleans up UI-related imports and annotations.
- **feat(search)**: Updated `OnClearClick` action to reset repositories, loading states, and error messages in addition to clearing the query.
- **fix(search)**: Corrected `totalCount` calculation in `SearchViewModel` to ensure it reflects the actual size of the updated repository list.
- **feat(apps)**: Optimized `filterApps` by extracting the filtering logic into `computeFilteredApps` and ensured the filtered list is updated when app status or progress changes.
- **refactor(apps)**: Fixed `ExpressiveCard` modifier application in `AppCard` to ensure correct layout behavior.
- **refactor(search)**: Cleaned up unused imports and `OptIn` annotations for `ExperimentalMaterial3Api` and `ExperimentalFoundationApi`.
- **chore**: Replaced wildcard imports with explicit imports in `SearchRoot.kt` for better clarity.1 parent 97c7155 commit 892c347
4 files changed
Lines changed: 34 additions & 24 deletions
File tree
- feature
- apps/presentation/src/commonMain/kotlin/zed/rainxch/apps/presentation
- search/presentation/src/commonMain/kotlin/zed/rainxch/search/presentation
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
374 | 374 | | |
375 | 375 | | |
376 | 376 | | |
377 | | - | |
| 377 | + | |
378 | 378 | | |
379 | | - | |
| 379 | + | |
380 | 380 | | |
381 | 381 | | |
382 | 382 | | |
| |||
Lines changed: 18 additions & 16 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
208 | 208 | | |
209 | 209 | | |
210 | 210 | | |
211 | | - | |
212 | | - | |
213 | | - | |
214 | | - | |
215 | | - | |
216 | | - | |
217 | | - | |
218 | | - | |
219 | | - | |
220 | | - | |
221 | | - | |
222 | | - | |
223 | | - | |
224 | | - | |
225 | | - | |
226 | | - | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
227 | 214 | | |
228 | 215 | | |
| 216 | + | |
229 | 217 | | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
230 | 227 | | |
231 | 228 | | |
| 229 | + | |
232 | 230 | | |
233 | 231 | | |
234 | 232 | | |
| |||
566 | 564 | | |
567 | 565 | | |
568 | 566 | | |
| 567 | + | |
| 568 | + | |
569 | 569 | | |
570 | 570 | | |
571 | 571 | | |
| |||
580 | 580 | | |
581 | 581 | | |
582 | 582 | | |
| 583 | + | |
| 584 | + | |
583 | 585 | | |
584 | 586 | | |
585 | 587 | | |
| |||
Lines changed: 6 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
4 | 3 | | |
5 | 4 | | |
6 | 5 | | |
| |||
59 | 58 | | |
60 | 59 | | |
61 | 60 | | |
62 | | - | |
63 | 61 | | |
64 | 62 | | |
65 | 63 | | |
| |||
71 | 69 | | |
72 | 70 | | |
73 | 71 | | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
74 | 77 | | |
75 | 78 | | |
76 | 79 | | |
| |||
120 | 123 | | |
121 | 124 | | |
122 | 125 | | |
123 | | - | |
| 126 | + | |
124 | 127 | | |
125 | 128 | | |
126 | 129 | | |
| |||
382 | 385 | | |
383 | 386 | | |
384 | 387 | | |
385 | | - | |
386 | 388 | | |
387 | 389 | | |
388 | 390 | | |
| |||
Lines changed: 8 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
226 | 226 | | |
227 | 227 | | |
228 | 228 | | |
229 | | - | |
| 229 | + | |
230 | 230 | | |
231 | 231 | | |
232 | 232 | | |
| |||
362 | 362 | | |
363 | 363 | | |
364 | 364 | | |
365 | | - | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
366 | 372 | | |
367 | 373 | | |
368 | 374 | | |
| |||
0 commit comments