fix(text-picker): apply user-picked color to gallery previews

The text-picker gallery (Initials / Abbreviated / Custom) called the
`icon` fn without `:color? true`, so the SVG text rendered with
default theme foreground instead of the user's chosen color — visible
mismatch where the page-icon next to the page title showed the new
color, but the preview tiles in the picker stayed white/themed.

Same fix as the Custom-tab Text tile (commit 63c7236f74). The icon
fn only wraps its output in `.ls-icon-color-wrap` when `:color? true`,
and the wrapper's `style: color: ...` is what makes the SVG's
`fill: currentColor` resolve to the chosen color.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
scheinriese
2026-05-21 22:35:34 +02:00
parent 82788debf9
commit efabc8ee3f

View File

@@ -6544,7 +6544,11 @@
(persist!))}
[:div.text-picker-gallery-preview
(if display-text
(icon (build-icon display-text) {:size 36})
;; `:color? true` wraps the SVG in `.ls-icon-color-wrap`
;; so the gallery preview's text picks up the user's
;; chosen color via `currentColor` (same fix as the
;; Custom-tab Text tile in custom-tab-cp).
(icon (build-icon display-text) {:size 36 :color? true})
(shui/tabler-icon "pencil" {:size 20}))]
[:span.text-picker-gallery-label label]]))]