@tangible/ui 0.2.44 → 0.2.46

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. package/components/ColorPicker/ColorPicker.js +1 -1
  2. package/components/GradientPicker/GradientPicker.js +1 -1
  3. package/components/PasswordInput/PasswordInput.d.ts +7 -0
  4. package/components/PasswordInput/PasswordInput.js +64 -0
  5. package/components/PasswordInput/index.d.ts +3 -0
  6. package/components/PasswordInput/index.js +2 -0
  7. package/components/PasswordInput/types.d.ts +45 -0
  8. package/components/PasswordInput/types.js +6 -0
  9. package/components/SecretInput/SecretInput.js +10 -33
  10. package/components/Tooltip/Tooltip.d.ts +1 -1
  11. package/components/Tooltip/Tooltip.js +302 -19
  12. package/components/Tooltip/types.d.ts +30 -0
  13. package/components/index.d.ts +2 -0
  14. package/components/index.js +1 -0
  15. package/figma-tokens.json +1 -1
  16. package/icons/icons.svg +1 -1
  17. package/icons/sprite-version.js +1 -1
  18. package/icons/sprite.php +1 -1
  19. package/package.json +5 -1
  20. package/skills/building-with-tui/SKILL.md +9 -3
  21. package/styles/all.css +1 -1
  22. package/styles/all.expanded.css +51 -0
  23. package/styles/all.expanded.unlayered.css +51 -0
  24. package/styles/all.unlayered.css +1 -1
  25. package/styles/components/_bundle.scss +5 -1
  26. package/styles/components/password-input.scss +24 -0
  27. package/styles/components/secret-input.scss +1 -65
  28. package/styles/system/_reveal.scss +82 -0
  29. package/styles/system/index.scss +1 -0
  30. package/tui-manifest.json +93 -2
  31. package/utils/reveal/RevealToggle.d.ts +32 -0
  32. package/utils/reveal/RevealToggle.js +57 -0
  33. package/utils/reveal/index.d.ts +3 -0
  34. package/utils/reveal/index.js +4 -0
  35. package/utils/reveal/useReveal.d.ts +26 -0
  36. package/utils/reveal/useReveal.js +55 -0
@@ -317,6 +317,9 @@
317
317
  --tui-overlap-stack-border-color
318
318
  */
319
319
  /* @tui-tokens
320
+ --tui-password-input-button-radius
321
+ */
322
+ /* @tui-tokens
320
323
  --tui-pager-gap
321
324
  --tui-pager-nav-gap
322
325
  --tui-pager-item-border
@@ -6928,6 +6931,54 @@
6928
6931
  border-end-end-radius: var(--tui-pager-item-radius, var(--tui-radius-md));
6929
6932
  }
6930
6933
  }
6934
+ :where(.tui-interface) .tui-password-input__reveal {
6935
+ display: inline-flex;
6936
+ align-items: center;
6937
+ justify-content: center;
6938
+ flex: none;
6939
+ min-inline-size: 1.5rem;
6940
+ min-block-size: 1.5rem;
6941
+ padding: 0.1875em;
6942
+ margin-block: calc(-1 * var(--_py, var(--tui-spacing-xxs)));
6943
+ border: 0;
6944
+ border-radius: var(--tui-password-input-button-radius, var(--tui-radius-full, 999px));
6945
+ background: transparent;
6946
+ color: var(--tui-color-fg-secondary);
6947
+ cursor: pointer;
6948
+ line-height: 0;
6949
+ transition-duration: var(--tui-motion-duration);
6950
+ transition-timing-function: var(--tui-motion-timing);
6951
+ transition-property: color, background-color, outline-color;
6952
+ }
6953
+ :where(.tui-interface) .tui-password-input__reveal .tui-icon {
6954
+ font-size: 1.125em;
6955
+ }
6956
+ @media (hover: hover) {
6957
+ :where(.tui-interface) .tui-password-input__reveal:hover {
6958
+ color: var(--tui-color-fg);
6959
+ }
6960
+ }
6961
+ :where(.tui-interface) .tui-password-input__reveal:focus-visible {
6962
+ color: var(--tui-color-fg);
6963
+ outline: var(--tui-focus-ring-width) solid var(--tui-focus-ring-color);
6964
+ outline-offset: var(--tui-focus-ring-offset);
6965
+ }
6966
+ :where(.tui-interface) .tui-password-input__reveal[data-revealed=true] {
6967
+ background-color: var(--tui-color-fill-subtle);
6968
+ color: var(--tui-color-fg);
6969
+ }
6970
+ @media (forced-colors: active) {
6971
+ :where(.tui-interface) .tui-password-input__reveal {
6972
+ color: ButtonText;
6973
+ }
6974
+ :where(.tui-interface) .tui-password-input__reveal[data-revealed=true] {
6975
+ background-color: Highlight;
6976
+ color: HighlightText;
6977
+ }
6978
+ :where(.tui-interface) .tui-password-input__reveal:focus-visible {
6979
+ outline-color: Highlight;
6980
+ }
6981
+ }
6931
6982
  :where(.tui-interface) .tui-popover {
6932
6983
  --_bg: var(--tui-popover-bg, var(--tui-color-bg-elevated));
6933
6984
  --_fg: var(--tui-popover-fg, var(--tui-color-fg));
@@ -317,6 +317,9 @@
317
317
  --tui-overlap-stack-border-color
318
318
  */
319
319
  /* @tui-tokens
320
+ --tui-password-input-button-radius
321
+ */
322
+ /* @tui-tokens
320
323
  --tui-pager-gap
321
324
  --tui-pager-nav-gap
322
325
  --tui-pager-item-border
@@ -6928,6 +6931,54 @@
6928
6931
  border-end-end-radius: var(--tui-pager-item-radius, var(--tui-radius-md));
6929
6932
  }
6930
6933
  }
6934
+ :where(.tui-interface) .tui-password-input__reveal {
6935
+ display: inline-flex;
6936
+ align-items: center;
6937
+ justify-content: center;
6938
+ flex: none;
6939
+ min-inline-size: 1.5rem;
6940
+ min-block-size: 1.5rem;
6941
+ padding: 0.1875em;
6942
+ margin-block: calc(-1 * var(--_py, var(--tui-spacing-xxs)));
6943
+ border: 0;
6944
+ border-radius: var(--tui-password-input-button-radius, var(--tui-radius-full, 999px));
6945
+ background: transparent;
6946
+ color: var(--tui-color-fg-secondary);
6947
+ cursor: pointer;
6948
+ line-height: 0;
6949
+ transition-duration: var(--tui-motion-duration);
6950
+ transition-timing-function: var(--tui-motion-timing);
6951
+ transition-property: color, background-color, outline-color;
6952
+ }
6953
+ :where(.tui-interface) .tui-password-input__reveal .tui-icon {
6954
+ font-size: 1.125em;
6955
+ }
6956
+ @media (hover: hover) {
6957
+ :where(.tui-interface) .tui-password-input__reveal:hover {
6958
+ color: var(--tui-color-fg);
6959
+ }
6960
+ }
6961
+ :where(.tui-interface) .tui-password-input__reveal:focus-visible {
6962
+ color: var(--tui-color-fg);
6963
+ outline: var(--tui-focus-ring-width) solid var(--tui-focus-ring-color);
6964
+ outline-offset: var(--tui-focus-ring-offset);
6965
+ }
6966
+ :where(.tui-interface) .tui-password-input__reveal[data-revealed=true] {
6967
+ background-color: var(--tui-color-fill-subtle);
6968
+ color: var(--tui-color-fg);
6969
+ }
6970
+ @media (forced-colors: active) {
6971
+ :where(.tui-interface) .tui-password-input__reveal {
6972
+ color: ButtonText;
6973
+ }
6974
+ :where(.tui-interface) .tui-password-input__reveal[data-revealed=true] {
6975
+ background-color: Highlight;
6976
+ color: HighlightText;
6977
+ }
6978
+ :where(.tui-interface) .tui-password-input__reveal:focus-visible {
6979
+ outline-color: Highlight;
6980
+ }
6981
+ }
6931
6982
  :where(.tui-interface) .tui-popover {
6932
6983
  --_bg: var(--tui-popover-bg, var(--tui-color-bg-elevated));
6933
6984
  --_fg: var(--tui-popover-fg, var(--tui-color-fg));