fix(ui): render polished SSR-safe component variants

This commit is contained in:
2026-07-20 15:55:38 +05:30
parent 944f83d3f4
commit 54f5309fca
260 changed files with 917 additions and 348 deletions
+1 -1
View File
@@ -7,5 +7,5 @@ component SearchButton {
disabled = false
class = ""
}
view { <span class="wire-catalog-action {class}"><a data-show="href" href="{href}" class="wire-btn wire-btn--{variant}">{label}<slot /></a><button data-show="!href" type="{type}" disabled="{disabled}" class="wire-btn wire-btn--{variant}">{label}<slot /></button></span> }
view { <span class="wire-catalog-action {class}">{#if href}<a href="{href}" class="wire-btn wire-btn--{variant}">{label}<slot /></a>{:else}<button type="{type}" disabled="{disabled}" class="wire-btn wire-btn--{variant}">{label}<slot /></button>{/if}</span> }
}