feat(components/button): prizmButton without text should appear like [prizmIconButton] #2361#2429
feat(components/button): prizmButton without text should appear like [prizmIconButton] #2361#2429ickisIckis wants to merge 7 commits intomainfrom
Conversation
…[prizmIconButton] #2361
|
Visit the preview URL for this PR (updated for commit fa13ca4): https://prizm-v4--pr2429-feat-button-icon-236-2h9w4tuo.web.app (expires Tue, 01 Apr 2025 13:17:10 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 Sign: 7c62ed8dbabf5e2d6b2084ca9e107cc206d30dbd |
|
prizmIconButton можно депрекеитить? така как функционал одинаковый? |
тоже появилась такая мысль, в дизайне у нас есть две сущности сейчас. надо проговорить это с @PrizmDS |
bd3dfc3 to
5859b32
Compare
5859b32 to
ebf9a0d
Compare
AleksandrSibiakov
left a comment
There was a problem hiding this comment.
Думаю проверять все поддерево через mutationobserver (в контексте кнопок) - перебор. Достаточно чекать только пробельные символы в TextNode дочернем (покрыть недостающий :empty функционал). А то потом не сможем отказаться от этой имплементации, когда выйдет CSS4, т.к. это будет Breaking Change
| const el = node as HTMLElement; | ||
|
|
||
| const style = window.getComputedStyle(el); | ||
| if (style.display === 'none' || style.visibility === 'hidden') { |
There was a problem hiding this comment.
visibility: hidden резервирует место в dom - может не стоит включать в проверку?

feat(components/button): prizmButton without text should appear like [prizmIconButton] #2361 special thanks to @AleksandrSibiakov for help with solution
fix(components/switcher): switcher with only icon should not render extra button #2412
refactor(helpers/has-value): robust content detection added
resolved #2361
resolved #2412