fix(ux): compatiable herf for the classical ui button component

feat/web-bi-client^2
charlie 2024-03-01 17:25:49 +08:00 committed by Andelf
parent 9c2cea030b
commit f5bf5a4bfb
1 changed files with 5 additions and 0 deletions

View File

@ -1046,6 +1046,11 @@
button-props)
icon (when icon (shui-ui/tabler-icon icon icon-props))
href? (not (string/blank? href))
text (cond
href? [:a {:href href :target "_blank"
:style {:color "inherit"}} text]
:else text)
children [icon text]]
(shui-ui/button props children)))