@alfadocs/ui-kit 0.60.0 → 0.63.0
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/dist/_chunks/finished-terminal-VjZ_-eDD.js +122 -0
- package/dist/_chunks/pdf-viewer-chMpwpA4.js +979 -0
- package/dist/_chunks/{sign-document-BmAT0kKD.js → sign-document--nr5cxsB.js} +2 -2
- package/dist/_chunks/signature-field-DbhbpLha.js +190 -0
- package/dist/_chunks/use-countdown-Yd6ts0_a.js +26 -0
- package/dist/agent-catalog.json +15 -1
- package/dist/components/finished-terminal/finished-terminal.d.ts +55 -0
- package/dist/components/finished-terminal/index.d.ts +3 -0
- package/dist/components/finished-terminal/index.js +5 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/pdf-viewer/index.js +1 -1
- package/dist/components/pdf-viewer/pdf-viewer.d.ts +7 -0
- package/dist/components/sign-document/index.js +1 -1
- package/dist/components/signature-field/index.js +1 -1
- package/dist/components/signature-field/signature-field.d.ts +8 -0
- package/dist/hooks/index.js +79 -99
- package/dist/i18n/locales/ar.d.ts +5 -0
- package/dist/i18n/locales/ar.js +5 -0
- package/dist/i18n/locales/de.d.ts +5 -0
- package/dist/i18n/locales/de.js +5 -0
- package/dist/i18n/locales/el.d.ts +5 -0
- package/dist/i18n/locales/el.js +5 -0
- package/dist/i18n/locales/en.d.ts +5 -0
- package/dist/i18n/locales/en.js +5 -0
- package/dist/i18n/locales/es.d.ts +5 -0
- package/dist/i18n/locales/es.js +5 -0
- package/dist/i18n/locales/fr.d.ts +5 -0
- package/dist/i18n/locales/fr.js +5 -0
- package/dist/i18n/locales/hi.d.ts +5 -0
- package/dist/i18n/locales/hi.js +5 -0
- package/dist/i18n/locales/it.d.ts +5 -0
- package/dist/i18n/locales/it.js +5 -0
- package/dist/i18n/locales/ja.d.ts +5 -0
- package/dist/i18n/locales/ja.js +5 -0
- package/dist/i18n/locales/nl.d.ts +5 -0
- package/dist/i18n/locales/nl.js +5 -0
- package/dist/i18n/locales/pl.d.ts +5 -0
- package/dist/i18n/locales/pl.js +5 -0
- package/dist/i18n/locales/pt.d.ts +5 -0
- package/dist/i18n/locales/pt.js +5 -0
- package/dist/i18n/locales/ro.d.ts +5 -0
- package/dist/i18n/locales/ro.js +5 -0
- package/dist/i18n/locales/ru.d.ts +5 -0
- package/dist/i18n/locales/ru.js +5 -0
- package/dist/i18n/locales/sq.d.ts +5 -0
- package/dist/i18n/locales/sq.js +5 -0
- package/dist/i18n/locales/sv.d.ts +5 -0
- package/dist/i18n/locales/sv.js +5 -0
- package/dist/i18n/locales/tr.d.ts +5 -0
- package/dist/i18n/locales/tr.js +5 -0
- package/dist/i18n/locales/zh.d.ts +5 -0
- package/dist/i18n/locales/zh.js +5 -0
- package/dist/index.js +299 -297
- package/dist/locales/ar.json +5 -0
- package/dist/locales/de.json +5 -0
- package/dist/locales/el.json +5 -0
- package/dist/locales/en.json +5 -0
- package/dist/locales/es.json +5 -0
- package/dist/locales/fr.json +5 -0
- package/dist/locales/hi.json +5 -0
- package/dist/locales/it.json +5 -0
- package/dist/locales/ja.json +5 -0
- package/dist/locales/nl.json +5 -0
- package/dist/locales/pl.json +5 -0
- package/dist/locales/pt.json +5 -0
- package/dist/locales/ro.json +5 -0
- package/dist/locales/ru.json +5 -0
- package/dist/locales/sq.json +5 -0
- package/dist/locales/sv.json +5 -0
- package/dist/locales/tr.json +5 -0
- package/dist/locales/zh.json +5 -0
- package/dist/tokens.css +1 -1
- package/package.json +7 -1
- package/dist/_chunks/pdf-viewer-XxWdtKfD.js +0 -965
- package/dist/_chunks/signature-field-DhscKdgk.js +0 -152
|
@@ -1,152 +0,0 @@
|
|
|
1
|
-
import { jsx as e, jsxs as g, Fragment as f } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as k } from "react";
|
|
3
|
-
import { c as N } from "./index-D2ZczOXr.js";
|
|
4
|
-
import { useTranslation as y } from "react-i18next";
|
|
5
|
-
import { S as C } from "./spinner-OjQNn8oN.js";
|
|
6
|
-
import { C as _ } from "./check-DPdL_Sm7.js";
|
|
7
|
-
import { c as T } from "./createLucideIcon-CrFbzy84.js";
|
|
8
|
-
/**
|
|
9
|
-
* @license lucide-react v1.8.0 - ISC
|
|
10
|
-
*
|
|
11
|
-
* This source code is licensed under the ISC license.
|
|
12
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
13
|
-
*/
|
|
14
|
-
const w = [
|
|
15
|
-
["path", { d: "M13 21h8", key: "1jsn5i" }],
|
|
16
|
-
[
|
|
17
|
-
"path",
|
|
18
|
-
{
|
|
19
|
-
d: "M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",
|
|
20
|
-
key: "1a8usu"
|
|
21
|
-
}
|
|
22
|
-
]
|
|
23
|
-
], S = T("pen-line", w), $ = N(
|
|
24
|
-
[
|
|
25
|
-
// Overlay fields are always absolutely positioned within the
|
|
26
|
-
// renderPageOverlay box; the percent geometry rides the inline style.
|
|
27
|
-
"ds:absolute",
|
|
28
|
-
"ds:inline-flex ds:items-center ds:justify-center ds:gap-[var(--spacing-xs)]",
|
|
29
|
-
"ds:[min-block-size:var(--min-target-size)] ds:[min-inline-size:var(--min-target-size)]",
|
|
30
|
-
"ds:ps-[var(--spacing-sm)] ds:pe-[var(--spacing-sm)]",
|
|
31
|
-
"ds:rounded-[var(--radius-sm)]",
|
|
32
|
-
"ds:text-[length:var(--font-size-sm)] ds:font-medium",
|
|
33
|
-
"ds:transition-colors ds:duration-[var(--animation-duration)] ds:motion-reduce:transition-none",
|
|
34
|
-
"ds:focus-visible:outline-[length:var(--focus-ring-width)]",
|
|
35
|
-
"ds:focus-visible:outline-solid",
|
|
36
|
-
"ds:focus-visible:outline-[var(--ring)]",
|
|
37
|
-
"ds:focus-visible:outline-offset-[length:var(--focus-ring-offset)]",
|
|
38
|
-
"ds:forced-colors:focus-visible:outline-[CanvasText]",
|
|
39
|
-
"ds:aria-disabled:cursor-not-allowed"
|
|
40
|
-
].join(" "),
|
|
41
|
-
{
|
|
42
|
-
variants: {
|
|
43
|
-
state: {
|
|
44
|
-
unsigned: [
|
|
45
|
-
"ds:cursor-pointer",
|
|
46
|
-
"ds:border ds:border-dashed ds:border-[color:var(--ring)]",
|
|
47
|
-
"ds:bg-[color-mix(in_srgb,var(--info)_8%,transparent)]",
|
|
48
|
-
"ds:text-[var(--foreground)]",
|
|
49
|
-
"ds:hover:bg-[color-mix(in_srgb,var(--info)_16%,transparent)]",
|
|
50
|
-
"ds:forced-colors:border-[CanvasText]"
|
|
51
|
-
].join(" "),
|
|
52
|
-
signing: [
|
|
53
|
-
"ds:cursor-progress",
|
|
54
|
-
"ds:border ds:border-dashed ds:border-[color:var(--border)]",
|
|
55
|
-
"ds:bg-[var(--muted)]",
|
|
56
|
-
"ds:text-[var(--muted-foreground)]",
|
|
57
|
-
"ds:forced-colors:border-[CanvasText]"
|
|
58
|
-
].join(" "),
|
|
59
|
-
signed: [
|
|
60
|
-
"ds:cursor-pointer ds:overflow-hidden",
|
|
61
|
-
"ds:p-[var(--spacing-xs)]",
|
|
62
|
-
"ds:border ds:border-solid ds:border-[color:var(--success)]",
|
|
63
|
-
"ds:bg-[color-mix(in_srgb,var(--success)_8%,transparent)]",
|
|
64
|
-
"ds:text-[var(--foreground)]",
|
|
65
|
-
"ds:forced-colors:border-[CanvasText]"
|
|
66
|
-
].join(" ")
|
|
67
|
-
}
|
|
68
|
-
},
|
|
69
|
-
defaultVariants: { state: "unsigned" }
|
|
70
|
-
}
|
|
71
|
-
), L = k(
|
|
72
|
-
({
|
|
73
|
-
state: s = "unsigned",
|
|
74
|
-
insetInlineStart: o,
|
|
75
|
-
insetBlockStart: a,
|
|
76
|
-
inlineSize: t,
|
|
77
|
-
blockSize: l,
|
|
78
|
-
onActivate: d,
|
|
79
|
-
signedImageSrc: c,
|
|
80
|
-
label: r,
|
|
81
|
-
disabled: m = !1,
|
|
82
|
-
id: v,
|
|
83
|
-
className: p,
|
|
84
|
-
...b
|
|
85
|
-
}, h) => {
|
|
86
|
-
const { t: i } = y(), u = m || s === "signing", n = {};
|
|
87
|
-
o !== void 0 && (n.insetInlineStart = `${o}%`), a !== void 0 && (n.insetBlockStart = `${a}%`), t !== void 0 && (n.inlineSize = `${t}%`), l !== void 0 && (n.blockSize = `${l}%`);
|
|
88
|
-
const x = r ?? i("signatureField.prompt"), z = s === "signing" ? r ? i("signatureField.signingNamed", { label: r }) : i("signatureField.signing") : s === "signed" ? r ? i("signatureField.signedNamed", { label: r }) : i("signatureField.signed") : r ?? i("signatureField.unsigned");
|
|
89
|
-
function F(j) {
|
|
90
|
-
if (u) {
|
|
91
|
-
j.preventDefault();
|
|
92
|
-
return;
|
|
93
|
-
}
|
|
94
|
-
d == null || d();
|
|
95
|
-
}
|
|
96
|
-
return /* @__PURE__ */ e(
|
|
97
|
-
"button",
|
|
98
|
-
{
|
|
99
|
-
ref: h,
|
|
100
|
-
type: "button",
|
|
101
|
-
...b,
|
|
102
|
-
"data-component": "signature-field",
|
|
103
|
-
"data-component-id": v,
|
|
104
|
-
"data-state": s,
|
|
105
|
-
"aria-label": z,
|
|
106
|
-
"aria-disabled": u || void 0,
|
|
107
|
-
"aria-busy": s === "signing" || void 0,
|
|
108
|
-
onClick: F,
|
|
109
|
-
className: [$({ state: s }), p].filter(Boolean).join(" "),
|
|
110
|
-
style: n,
|
|
111
|
-
children: s === "signing" ? (
|
|
112
|
-
// Decorative: the button's aria-label + aria-busy are the single
|
|
113
|
-
// source of the status announcement, so the Spinner's own
|
|
114
|
-
// role="status" live region is hidden from assistive tech.
|
|
115
|
-
/* @__PURE__ */ e("span", { "aria-hidden": "true", children: /* @__PURE__ */ e(C, { size: "sm", label: i("signatureField.signing") }) })
|
|
116
|
-
) : s === "signed" ? c ? /* @__PURE__ */ e(
|
|
117
|
-
"img",
|
|
118
|
-
{
|
|
119
|
-
src: c,
|
|
120
|
-
alt: "",
|
|
121
|
-
"aria-hidden": "true",
|
|
122
|
-
className: "ds:block-size-full ds:inline-size-full ds:object-contain"
|
|
123
|
-
}
|
|
124
|
-
) : /* @__PURE__ */ g(f, { children: [
|
|
125
|
-
/* @__PURE__ */ e(
|
|
126
|
-
_,
|
|
127
|
-
{
|
|
128
|
-
"aria-hidden": "true",
|
|
129
|
-
className: "ds:block-size-4 ds:inline-size-4 ds:text-[var(--success)]"
|
|
130
|
-
}
|
|
131
|
-
),
|
|
132
|
-
/* @__PURE__ */ e("span", { children: i("signatureField.signed") })
|
|
133
|
-
] }) : /* @__PURE__ */ g(f, { children: [
|
|
134
|
-
/* @__PURE__ */ e(
|
|
135
|
-
S,
|
|
136
|
-
{
|
|
137
|
-
"aria-hidden": "true",
|
|
138
|
-
className: "ds:block-size-4 ds:inline-size-4"
|
|
139
|
-
}
|
|
140
|
-
),
|
|
141
|
-
/* @__PURE__ */ e("span", { children: x })
|
|
142
|
-
] })
|
|
143
|
-
}
|
|
144
|
-
);
|
|
145
|
-
}
|
|
146
|
-
);
|
|
147
|
-
L.displayName = "SignatureField";
|
|
148
|
-
export {
|
|
149
|
-
L as S,
|
|
150
|
-
$ as s
|
|
151
|
-
};
|
|
152
|
-
//# sourceMappingURL=signature-field-DhscKdgk.js.map
|