@tapizlabs/ui 0.2.4 → 0.2.6

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.
package/CHANGELOG.md CHANGED
@@ -14,3 +14,18 @@ The format is based on Keep a Changelog and the package follows Semantic Version
14
14
  - shared `Button` accepts icon component references in addition to rendered nodes
15
15
  - shared `ConfirmDialog` supports both `description` and compatibility `message` props
16
16
  - consumer apps are now migrated to shared theme, fonts, and shared UI primitives
17
+
18
+ ## [0.2.6] - 2026-06-12
19
+
20
+ ### Fixed
21
+ - `PasswordInput` inner input no longer renders its own focus signal bar; the wrapper's `focus-within` signal stays at the field's left edge even when the wrapper has extra padding (e.g. `pl-10` for an inline icon)
22
+
23
+ ## [0.2.5] - 2026-06-12
24
+
25
+ ### Fixed
26
+ - `PasswordInput` reveal toggle now works: an Eye/EyeOff icon button switches the input between password and text (previously a static "Show" label with no behavior)
27
+
28
+ ## [0.2.4] - 2026-06-12
29
+
30
+ ### Added
31
+ - `theme.css`: `html.theme-switching` transition guard — apps add the class on `<html>` during a theme toggle (and remove it a frame later) to switch the theme instantly instead of per-element transition lag
package/dist/index.d.ts CHANGED
@@ -1173,7 +1173,8 @@ interface FileDropzoneProps extends Omit<InputHTMLAttributes<HTMLInputElement>,
1173
1173
  declare function FileDropzone({ title, description, actionLabel, className, ...props }: FileDropzoneProps): react.JSX.Element;
1174
1174
 
1175
1175
  interface PasswordInputProps extends Omit<InputHTMLAttributes<HTMLInputElement>, "type"> {
1176
- revealLabel?: ReactNode;
1176
+ /** Accessible label for the reveal toggle. */
1177
+ revealLabel?: string;
1177
1178
  }
1178
1179
  declare function PasswordInput({ revealLabel, className, ...props }: PasswordInputProps): react.JSX.Element;
1179
1180
 
package/dist/index.js CHANGED
@@ -3046,19 +3046,42 @@ function FileDropzone({ title = "Drop files here", description, actionLabel = "B
3046
3046
  }
3047
3047
 
3048
3048
  // src/components/forms/PasswordInput.tsx
3049
+ import { useState as useState7 } from "react";
3049
3050
  import { jsx as jsx97, jsxs as jsxs74 } from "react/jsx-runtime";
3050
- function PasswordInput({ revealLabel = "Show", className = "", ...props }) {
3051
- return /* @__PURE__ */ jsxs74("div", { className: `flex border border-[var(--tapiz-border-strong)] bg-[var(--tapiz-bg-surface)] focus-within:border-[var(--tapiz-border-focus)] focus-within:shadow-[inset_3px_0_0_0_var(--tapiz-signal)] ${className}`, children: [
3052
- /* @__PURE__ */ jsx97(
3053
- "input",
3054
- {
3055
- ...props,
3056
- type: "password",
3057
- className: "min-w-0 flex-1 border-0 bg-transparent px-3 py-2 text-sm text-[var(--tapiz-text-primary)] outline-none"
3058
- }
3059
- ),
3060
- /* @__PURE__ */ jsx97("button", { type: "button", className: "border-l border-[var(--tapiz-border-subtle)] px-3 font-mono text-xs text-[var(--tapiz-text-muted)]", tabIndex: -1, children: revealLabel })
3061
- ] });
3051
+ function PasswordInput({
3052
+ revealLabel = "Show password",
3053
+ className = "",
3054
+ ...props
3055
+ }) {
3056
+ const [visible, setVisible] = useState7(false);
3057
+ return /* @__PURE__ */ jsxs74(
3058
+ "div",
3059
+ {
3060
+ className: `flex border border-[var(--tapiz-border-strong)] bg-[var(--tapiz-bg-surface)] focus-within:border-[var(--tapiz-border-focus)] focus-within:shadow-[inset_3px_0_0_0_var(--tapiz-signal)] ${className}`,
3061
+ children: [
3062
+ /* @__PURE__ */ jsx97(
3063
+ "input",
3064
+ {
3065
+ ...props,
3066
+ type: visible ? "text" : "password",
3067
+ className: "min-w-0 flex-1 border-0 bg-transparent px-3 py-2 text-sm text-[var(--tapiz-text-primary)] outline-none focus:shadow-none!"
3068
+ }
3069
+ ),
3070
+ /* @__PURE__ */ jsx97(
3071
+ "button",
3072
+ {
3073
+ type: "button",
3074
+ "aria-label": revealLabel,
3075
+ "aria-pressed": visible,
3076
+ onClick: () => setVisible((v) => !v),
3077
+ tabIndex: -1,
3078
+ className: "grid place-items-center px-3 text-[var(--tapiz-text-muted)] transition-colors hover:text-[var(--tapiz-text-primary)]",
3079
+ children: visible ? /* @__PURE__ */ jsx97(EyeOff, { size: 15 }) : /* @__PURE__ */ jsx97(Eye, { size: 15 })
3080
+ }
3081
+ )
3082
+ ]
3083
+ }
3084
+ );
3062
3085
  }
3063
3086
 
3064
3087
  // src/components/forms/TextareaCounter.tsx