@tapizlabs/ui 0.2.3 → 0.2.5
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 +10 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.js +35 -12
- package/dist/index.js.map +1 -1
- package/dist/theme.css +7 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -14,3 +14,13 @@ 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.5] - 2026-06-12
|
|
19
|
+
|
|
20
|
+
### Fixed
|
|
21
|
+
- `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)
|
|
22
|
+
|
|
23
|
+
## [0.2.4] - 2026-06-12
|
|
24
|
+
|
|
25
|
+
### Added
|
|
26
|
+
- `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
|
-
|
|
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({
|
|
3051
|
-
|
|
3052
|
-
|
|
3053
|
-
|
|
3054
|
-
|
|
3055
|
-
|
|
3056
|
-
|
|
3057
|
-
|
|
3058
|
-
|
|
3059
|
-
|
|
3060
|
-
|
|
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"
|
|
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
|