@kakadu/components 1.5.2 → 1.6.1
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/build/components/button-tooltip.js +1 -1
- package/build/components/button-tooltip.mjs +1 -1
- package/build/components/button.js +1 -1
- package/build/components/button.mjs +1 -1
- package/build/components/card.js +1 -1
- package/build/components/card.mjs +6 -6
- package/build/components/collapsible.d.ts +5 -0
- package/build/components/datum.js +1 -1
- package/build/components/datum.mjs +7 -7
- package/build/components/icon-button.js +1 -1
- package/build/components/icon-button.mjs +9 -9
- package/build/components/input.d.ts +27 -0
- package/build/components/modal.js +1 -1
- package/build/components/modal.mjs +1 -1
- package/build/components/notice.js +1 -1
- package/build/components/notice.mjs +6 -6
- package/build/components/text-button.js +1 -1
- package/build/components/text-button.mjs +10 -10
- package/build/components.css +1 -1
- package/build/icon-CRXHH3In.js +1 -0
- package/build/icon-Dz2YJAPU.mjs +184 -0
- package/build/icons/icon.d.ts +1 -0
- package/build/icons/icon.js +1 -1
- package/build/icons/icon.mjs +22 -157
- package/build/icons/sparkle.d.ts +2 -0
- package/build/index.d.ts +73 -69
- package/build/index.js +2 -1
- package/build/index.mjs +354 -174
- package/build/theme.d.ts +1 -1
- package/build/theme.js +1 -1
- package/build/theme.mjs +5 -5
- package/package.json +2 -2
- package/readme.md +3 -3
package/build/index.mjs
CHANGED
|
@@ -1,176 +1,356 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { default as
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
6
|
-
import { default as
|
|
7
|
-
import { default as
|
|
8
|
-
import { default as
|
|
9
|
-
import
|
|
10
|
-
import { default as
|
|
11
|
-
import
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import { default as
|
|
16
|
-
import { default as
|
|
17
|
-
import { default as
|
|
18
|
-
import { default as
|
|
19
|
-
import { default as
|
|
20
|
-
import { default as
|
|
21
|
-
import { default as
|
|
22
|
-
import { default as
|
|
23
|
-
import
|
|
24
|
-
import {
|
|
25
|
-
import { default as
|
|
26
|
-
import
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import
|
|
30
|
-
import
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
import {
|
|
37
|
-
import { default as
|
|
38
|
-
import { default as
|
|
39
|
-
import { default as
|
|
40
|
-
import { default as
|
|
41
|
-
import { default as
|
|
42
|
-
import { default as
|
|
43
|
-
import { default as
|
|
44
|
-
import { default as
|
|
45
|
-
import { default as
|
|
46
|
-
import { default as
|
|
47
|
-
import { default as
|
|
48
|
-
import { default as
|
|
49
|
-
import { default as
|
|
50
|
-
import { default as
|
|
51
|
-
import { default as
|
|
52
|
-
import { default as
|
|
53
|
-
import { default as
|
|
54
|
-
import { default as
|
|
55
|
-
import { default as
|
|
56
|
-
import { default as
|
|
57
|
-
import { default as
|
|
58
|
-
import { default as
|
|
59
|
-
import { default as
|
|
60
|
-
import { default as
|
|
61
|
-
import { default as
|
|
62
|
-
import { default as
|
|
1
|
+
import { buttonResetStyles as ce, overflowProtectionStyles as U } from "./theme.mjs";
|
|
2
|
+
import { FontFamilyHead as We, darkBackgroundColor as $e, effectStyles as Oe, font as Ue, lightBackgroundColor as ze, nonInteractiveEffectStyles as Qe, default as qe } from "./theme.mjs";
|
|
3
|
+
import { default as Xe, ariaTextStyles as Ye } from "./components/aria-text.mjs";
|
|
4
|
+
import ie from "./components/atom.mjs";
|
|
5
|
+
import { defaultAtomElementType as _e } from "./components/atom.mjs";
|
|
6
|
+
import { default as tt } from "./components/bankid-logo.mjs";
|
|
7
|
+
import { default as at } from "./components/box.mjs";
|
|
8
|
+
import { default as nt, ButtonVariant as st, buttonDangerStyles as lt, buttonSecondaryStyles as ct, buttonSuccessStyles as it, buttonWarningStyles as dt } from "./components/button.mjs";
|
|
9
|
+
import de from "./components/button-tooltip.mjs";
|
|
10
|
+
import { default as ft } from "./components/card.mjs";
|
|
11
|
+
import G from "./components/click-ripples.mjs";
|
|
12
|
+
import { j as e } from "./jsx-runtime-B4hRZ52C.mjs";
|
|
13
|
+
import { useRef as v, useState as b, useEffect as z, useId as Q, useLayoutEffect as ue, useMemo as D, useCallback as S } from "react";
|
|
14
|
+
import { cx as c } from "@kuma-ui/core";
|
|
15
|
+
import { default as mt } from "./components/datum.mjs";
|
|
16
|
+
import { default as kt } from "./components/dnb-logo.mjs";
|
|
17
|
+
import { default as gt } from "./components/dot.mjs";
|
|
18
|
+
import { default as St, FlexAlignment as vt } from "./components/flex.mjs";
|
|
19
|
+
import { default as jt, FooterLinkItem as Nt } from "./components/footer.mjs";
|
|
20
|
+
import { default as Tt } from "./components/gauge.mjs";
|
|
21
|
+
import { default as Bt } from "./components/gjensidige-logo.mjs";
|
|
22
|
+
import { default as wt } from "./components/header.mjs";
|
|
23
|
+
import V from "./components/hover-gradient.mjs";
|
|
24
|
+
import { normalBlendStyles as Ht } from "./components/hover-gradient.mjs";
|
|
25
|
+
import { default as Pt, IconButtonVariant as At } from "./components/icon-button.mjs";
|
|
26
|
+
import fe from "./icons/chevron-up.mjs";
|
|
27
|
+
import { I as F, S as pe } from "./icon-Dz2YJAPU.mjs";
|
|
28
|
+
import { a as Gt, i as Dt } from "./icon-Dz2YJAPU.mjs";
|
|
29
|
+
import K from "./utilities/copy-to-clipboard.mjs";
|
|
30
|
+
import W from "./components/text-button.mjs";
|
|
31
|
+
import { TextButtonVariant as Ft } from "./components/text-button.mjs";
|
|
32
|
+
import { Span as w, Paragraph as $ } from "./components/text.mjs";
|
|
33
|
+
import { AnchorHeading as Wt, Heading as $t, Hero as Ot, Label as Ut, default as zt, spanStyles as Qt, textShadowStyles as qt } from "./components/text.mjs";
|
|
34
|
+
import { useCreateNotification as me } from "./components/notification.mjs";
|
|
35
|
+
import { default as Xt, NotificationProvider as Yt } from "./components/notification.mjs";
|
|
36
|
+
import { NoticeType as xe } from "./components/notice.mjs";
|
|
37
|
+
import { default as _t } from "./components/notice.mjs";
|
|
38
|
+
import { default as to } from "./components/kakadu-guide-icon.mjs";
|
|
39
|
+
import { default as ao, KakaduGuideLogoSvg as ro, KakaduGuideLogoVariant as no } from "./components/kakadu-guide-logo.mjs";
|
|
40
|
+
import { default as lo } from "./components/kakadu-index-logo.mjs";
|
|
41
|
+
import { default as io } from "./components/kakadu-logo.mjs";
|
|
42
|
+
import { default as fo, useModal as po, useModalContext as mo } from "./components/modal.mjs";
|
|
43
|
+
import { default as ko } from "./components/moving-gradients.mjs";
|
|
44
|
+
import { default as go } from "./components/moving-stars.mjs";
|
|
45
|
+
import { default as So, useRevealer as vo } from "./components/revealer.mjs";
|
|
46
|
+
import { default as jo, SeparatorLabel as No, SmallSeparator as Lo, VerticalSeparator as To } from "./components/separator.mjs";
|
|
47
|
+
import { default as Bo, SkeletonInstance as Eo } from "./components/skeleton.mjs";
|
|
48
|
+
import { default as Co } from "./components/sparebank1-logo.mjs";
|
|
49
|
+
import { RevealSpinner as Mo, default as Po } from "./components/spinner.mjs";
|
|
50
|
+
import { default as Ro } from "./components/sto-logo.mjs";
|
|
51
|
+
import { default as Do } from "./components/storebrand-logo.mjs";
|
|
52
|
+
import { default as Fo, getThemePreference as Ko, setThemePreference as Wo, themePreferences as $o, useIsDarkMode as Oo, useIsLightMode as Uo, useTheme as zo } from "./components/theme-setter.mjs";
|
|
53
|
+
import { default as qo } from "./components/veil.mjs";
|
|
54
|
+
import { default as Xo, WrapperWidth as Yo } from "./components/wrapper.mjs";
|
|
55
|
+
import { default as _o } from "./icons/arrow-down.mjs";
|
|
56
|
+
import { default as ta } from "./icons/caret-down.mjs";
|
|
57
|
+
import { default as aa } from "./icons/caret-right.mjs";
|
|
58
|
+
import { default as na } from "./icons/check.mjs";
|
|
59
|
+
import { default as la } from "./icons/chevron-down.mjs";
|
|
60
|
+
import { default as ia } from "./icons/chrome-browser-logo.mjs";
|
|
61
|
+
import { default as ua } from "./icons/copy.mjs";
|
|
62
|
+
import { default as pa } from "./icons/edit.mjs";
|
|
63
|
+
import { default as xa } from "./icons/edge-browser-logo.mjs";
|
|
64
|
+
import { default as ha } from "./icons/exclamation-triangle.mjs";
|
|
65
|
+
import { default as ya } from "./icons/kakadu-guide.mjs";
|
|
66
|
+
import { default as va } from "./icons/kakadu-guide-glyph.mjs";
|
|
67
|
+
import { default as ja } from "./icons/menu.mjs";
|
|
68
|
+
import { default as La } from "./icons/plus.mjs";
|
|
69
|
+
import { default as Ia } from "./icons/test.mjs";
|
|
70
|
+
import { default as Ea } from "./icons/times.mjs";
|
|
71
|
+
import { default as Ca } from "./hooks/use-media-query.mjs";
|
|
72
|
+
import { default as Ma } from "./utilities/generate-random-id.mjs";
|
|
73
|
+
import { default as Aa } from "./utilities/scale.mjs";
|
|
74
|
+
function ke({
|
|
75
|
+
as: i,
|
|
76
|
+
isCollapsed: a = !0,
|
|
77
|
+
children: s,
|
|
78
|
+
className: r,
|
|
79
|
+
...h
|
|
80
|
+
}) {
|
|
81
|
+
const t = v(null), [f, l] = b();
|
|
82
|
+
return z(() => {
|
|
83
|
+
if (a)
|
|
84
|
+
l(0);
|
|
85
|
+
else {
|
|
86
|
+
const m = t.current;
|
|
87
|
+
m && l(m.scrollHeight ?? 0);
|
|
88
|
+
}
|
|
89
|
+
}, [a]), /* @__PURE__ */ e.jsx(ie, { as: i ?? "div", ...h, "aria-hidden": a, style: {
|
|
90
|
+
height: f,
|
|
91
|
+
opacity: a ? 0 : 1
|
|
92
|
+
}, className: c("kakadu-components-2223449868", r), children: /* @__PURE__ */ e.jsx("div", { ref: t, className: "kakadu-components-3857562328", children: s }) });
|
|
93
|
+
}
|
|
94
|
+
const he = "kakadu-components-2065792067", ge = "kakadu-components-3551118672", j = "kakadu-components-2161641266", q = "kakadu-components-628401705", ye = c(q, "kakadu-components-3245407458"), Se = c(q, "kakadu-components-1117160492");
|
|
95
|
+
function ve({
|
|
96
|
+
as: i,
|
|
97
|
+
className: a,
|
|
98
|
+
...s
|
|
99
|
+
}) {
|
|
100
|
+
return /* @__PURE__ */ e.jsx(w, { as: i ?? "span", ...s, className: c("kakadu-components-3574036749", a) });
|
|
101
|
+
}
|
|
102
|
+
function J({
|
|
103
|
+
label: i,
|
|
104
|
+
error: a,
|
|
105
|
+
errorId: s,
|
|
106
|
+
warning: r,
|
|
107
|
+
warningId: h,
|
|
108
|
+
footnote: t,
|
|
109
|
+
attachments: f,
|
|
110
|
+
className: l,
|
|
111
|
+
children: m,
|
|
112
|
+
...n
|
|
113
|
+
}) {
|
|
114
|
+
const x = !!a, k = !!r, p = !!t;
|
|
115
|
+
return /* @__PURE__ */ e.jsxs("label", { ...n, className: c(he, l), children: [
|
|
116
|
+
/* @__PURE__ */ e.jsx(w, { className: c(U, ge), children: /* @__PURE__ */ e.jsx("span", { children: i }) }),
|
|
117
|
+
/* @__PURE__ */ e.jsxs("span", { className: "kakadu-components-448077930", children: [
|
|
118
|
+
m,
|
|
119
|
+
p ? /* @__PURE__ */ e.jsx(ve, { className: "kakadu-components-3258753754", children: t }) : null,
|
|
120
|
+
f
|
|
121
|
+
] }),
|
|
122
|
+
x ? /* @__PURE__ */ e.jsx($, { id: s, className: ye, children: a instanceof Error ? a.message : a }) : k ? /* @__PURE__ */ e.jsx($, { id: h, className: Se, children: r instanceof Error ? r.message : r }) : null
|
|
123
|
+
] });
|
|
124
|
+
}
|
|
125
|
+
function De({
|
|
126
|
+
label: i,
|
|
127
|
+
options: a,
|
|
128
|
+
error: s,
|
|
129
|
+
warning: r,
|
|
130
|
+
footnote: h,
|
|
131
|
+
className: t,
|
|
132
|
+
...f
|
|
133
|
+
}) {
|
|
134
|
+
const l = Q(), m = `${l}-error`, n = `${l}-warning`, x = !!s, k = !!r;
|
|
135
|
+
return /* @__PURE__ */ e.jsxs(J, { label: i, error: s, warning: r, footnote: h, children: [
|
|
136
|
+
/* @__PURE__ */ e.jsx("select", { ...f, "aria-invalid": x, "data-warning": k, "aria-describedby": x ? m : k ? n : void 0, className: c(j, "kakadu-components-709108872", t), children: a.map((p) => /* @__PURE__ */ e.jsx("option", { value: p.value, children: p.label }, p.value)) }),
|
|
137
|
+
/* @__PURE__ */ e.jsx(fe, { className: "kakadu-components-1616393393" })
|
|
138
|
+
] });
|
|
139
|
+
}
|
|
140
|
+
const be = 36, O = "kakadu-components-4233741488";
|
|
141
|
+
function Ve({
|
|
142
|
+
type: i,
|
|
143
|
+
label: a,
|
|
144
|
+
error: s,
|
|
145
|
+
warning: r,
|
|
146
|
+
footnote: h,
|
|
147
|
+
suggestion: t,
|
|
148
|
+
hasCopyButton: f,
|
|
149
|
+
hasClearButton: l,
|
|
150
|
+
isMultiline: m,
|
|
151
|
+
onChange: n,
|
|
152
|
+
className: x,
|
|
153
|
+
...k
|
|
154
|
+
}) {
|
|
155
|
+
const p = v(null), N = v(null), L = v(null), C = me(), H = Q(), X = `${H}-error`, Y = `${H}-warning`, {
|
|
156
|
+
value: y
|
|
157
|
+
} = k, [Z, M] = b(""), d = y ?? Z, [_, ee] = b(), te = i === "textarea" || !!m;
|
|
158
|
+
ue(() => {
|
|
159
|
+
typeof d == "string" && L.current && ee(L.current.scrollHeight);
|
|
160
|
+
}, [d]);
|
|
161
|
+
const T = D(() => typeof d == "string" ? `${d} `.split(`
|
|
162
|
+
`) : [], [d]), oe = D(() => T.length, [T]), I = !!s, B = !!r, P = I ? X : B ? Y : void 0;
|
|
163
|
+
z(() => {
|
|
164
|
+
M(typeof y == "string" ? y : "");
|
|
165
|
+
}, [y]);
|
|
166
|
+
const A = S((o) => {
|
|
167
|
+
const {
|
|
168
|
+
value: u
|
|
169
|
+
} = o.target;
|
|
170
|
+
M(u), n == null || n(u, o);
|
|
171
|
+
}, [n]), ae = S(() => {
|
|
172
|
+
typeof d == "string" && (K(d), C({
|
|
173
|
+
type: xe.success,
|
|
174
|
+
children: "Copied to clipboard."
|
|
175
|
+
}));
|
|
176
|
+
}, [d, C]), re = S(() => {
|
|
177
|
+
var u;
|
|
178
|
+
const o = N.current ?? p.current;
|
|
179
|
+
if (n && o) {
|
|
180
|
+
const g = (u = Object.getOwnPropertyDescriptor(o instanceof HTMLTextAreaElement ? HTMLTextAreaElement.prototype : HTMLInputElement.prototype, "value")) == null ? void 0 : u.set;
|
|
181
|
+
if (g) {
|
|
182
|
+
g.call(o, "");
|
|
183
|
+
const E = new Event("input", {
|
|
184
|
+
bubbles: !0
|
|
185
|
+
});
|
|
186
|
+
o.dispatchEvent(E), o.focus();
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
}, [n]), [ne, se] = b(""), R = !!t && ne !== t, le = S(() => {
|
|
190
|
+
var u;
|
|
191
|
+
const o = N.current ?? p.current;
|
|
192
|
+
if (t && n && o) {
|
|
193
|
+
const g = (u = Object.getOwnPropertyDescriptor(o instanceof HTMLTextAreaElement ? HTMLTextAreaElement.prototype : HTMLInputElement.prototype, "value")) == null ? void 0 : u.set;
|
|
194
|
+
if (g) {
|
|
195
|
+
g.call(o, t);
|
|
196
|
+
const E = new Event("input", {
|
|
197
|
+
bubbles: !0
|
|
198
|
+
});
|
|
199
|
+
o.dispatchEvent(E), o.focus();
|
|
200
|
+
} else
|
|
201
|
+
K(t);
|
|
202
|
+
se(t);
|
|
203
|
+
}
|
|
204
|
+
}, [t, n]);
|
|
205
|
+
return /* @__PURE__ */ e.jsxs(J, { label: a, error: s, warning: r, footnote: h, attachments: /* @__PURE__ */ e.jsx(ke, { isCollapsed: !R, children: R ? /* @__PURE__ */ e.jsxs("button", { type: "button", className: c(ce, U, "kakadu-components-2355856341"), onClick: le, children: [
|
|
206
|
+
/* @__PURE__ */ e.jsx(de, { label: "Apply suggestion" }),
|
|
207
|
+
/* @__PURE__ */ e.jsx(pe, { width: 13, height: 13, className: "kakadu-components-1021263934" }),
|
|
208
|
+
/* @__PURE__ */ e.jsx(w, { className: "kakadu-components-1585874956", children: t }),
|
|
209
|
+
/* @__PURE__ */ e.jsx(G, { className: "kakadu-components-3448565402" }),
|
|
210
|
+
/* @__PURE__ */ e.jsx(V, {})
|
|
211
|
+
] }) : null }), style: {
|
|
212
|
+
"--button-padding": `${be * ((f ? 1 : 0) + (l ? 1 : 0))}px`
|
|
213
|
+
}, children: [
|
|
214
|
+
/* @__PURE__ */ e.jsxs("div", { className: "kakadu-components-3146929190", children: [
|
|
215
|
+
te ? /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
|
|
216
|
+
/* @__PURE__ */ e.jsxs("span", { ref: L, "aria-hidden": !0, className: c(j, x, "kakadu-components-2033521835"), children: [
|
|
217
|
+
T.map((o, u) => (
|
|
218
|
+
// eslint-disable-next-line react/no-array-index-key
|
|
219
|
+
/* @__PURE__ */ e.jsxs("span", { children: [
|
|
220
|
+
o,
|
|
221
|
+
oe > 1 ? /* @__PURE__ */ e.jsx("br", {}) : null
|
|
222
|
+
] }, u)
|
|
223
|
+
)),
|
|
224
|
+
" "
|
|
225
|
+
] }),
|
|
226
|
+
/* @__PURE__ */ e.jsx("textarea", { ...k, ref: N, rows: 1, "aria-invalid": I, "data-warning": B, "aria-describedby": P, value: d, className: c(j, x, "kakadu-components-2119524139"), style: {
|
|
227
|
+
minHeight: _
|
|
228
|
+
}, onChange: A })
|
|
229
|
+
] }) : /* @__PURE__ */ e.jsx("input", { ...k, ref: p, type: i ?? "text", value: d, "aria-invalid": I, "data-warning": B, "aria-describedby": P, className: c(j, x), onChange: A }),
|
|
230
|
+
/* @__PURE__ */ e.jsx(G, { className: "kakadu-components-1614211948" }),
|
|
231
|
+
/* @__PURE__ */ e.jsx(V, { className: "kakadu-components-1041647916" })
|
|
232
|
+
] }),
|
|
233
|
+
f || l ? /* @__PURE__ */ e.jsxs("div", { className: "kakadu-components-131986363", children: [
|
|
234
|
+
f ? /* @__PURE__ */ e.jsx(W, { iconLeft: F.copy, label: "Copy", tooltip: "Copy", className: O, onClick: ae }) : null,
|
|
235
|
+
l ? /* @__PURE__ */ e.jsx(W, { iconLeft: F.times, label: "Clear", tooltip: "Clear", className: O, onClick: re }) : null
|
|
236
|
+
] }) : null
|
|
237
|
+
] });
|
|
238
|
+
}
|
|
63
239
|
export {
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
240
|
+
Wt as AnchorHeading,
|
|
241
|
+
Xe as AriaText,
|
|
242
|
+
_o as ArrowDown,
|
|
243
|
+
ie as Atom,
|
|
244
|
+
tt as BankidLogo,
|
|
245
|
+
at as Box,
|
|
246
|
+
nt as Button,
|
|
247
|
+
de as ButtonTooltip,
|
|
248
|
+
st as ButtonVariant,
|
|
249
|
+
ft as Card,
|
|
250
|
+
ta as CaretDown,
|
|
251
|
+
aa as CaretRight,
|
|
252
|
+
na as Check,
|
|
253
|
+
la as ChevronDown,
|
|
254
|
+
fe as ChevronUp,
|
|
255
|
+
ia as ChromeBrowserLogo,
|
|
256
|
+
G as ClickRipples,
|
|
257
|
+
ke as Collapsible,
|
|
258
|
+
ua as Copy,
|
|
259
|
+
mt as Datum,
|
|
260
|
+
kt as DnbLogo,
|
|
261
|
+
gt as Dot,
|
|
262
|
+
xa as EdgeBrowserLogo,
|
|
263
|
+
pa as Edit,
|
|
264
|
+
ha as ExclamationTriangle,
|
|
265
|
+
St as Flex,
|
|
266
|
+
vt as FlexAlignment,
|
|
267
|
+
We as FontFamilyHead,
|
|
268
|
+
jt as Footer,
|
|
269
|
+
Nt as FooterLinkItem,
|
|
270
|
+
Tt as Gauge,
|
|
271
|
+
Bt as GjensidigeLogo,
|
|
272
|
+
wt as Header,
|
|
273
|
+
$t as Heading,
|
|
274
|
+
Ot as Hero,
|
|
275
|
+
V as HoverGradient,
|
|
276
|
+
Gt as Icon,
|
|
277
|
+
Pt as IconButton,
|
|
278
|
+
At as IconButtonVariant,
|
|
279
|
+
F as IconType,
|
|
280
|
+
Ve as Input,
|
|
281
|
+
ya as KakaduGuide,
|
|
282
|
+
va as KakaduGuideGlyph,
|
|
283
|
+
to as KakaduGuideIcon,
|
|
284
|
+
ao as KakaduGuideLogo,
|
|
285
|
+
ro as KakaduGuideLogoSvg,
|
|
286
|
+
no as KakaduGuideLogoVariant,
|
|
287
|
+
lo as KakaduIndexLogo,
|
|
288
|
+
io as KakaduLogo,
|
|
289
|
+
Ut as Label,
|
|
290
|
+
ja as Menu,
|
|
291
|
+
fo as Modal,
|
|
292
|
+
ko as MovingGradients,
|
|
293
|
+
go as MovingStars,
|
|
294
|
+
_t as Notice,
|
|
295
|
+
xe as NoticeType,
|
|
296
|
+
Xt as Notification,
|
|
297
|
+
Yt as NotificationProvider,
|
|
298
|
+
$ as Paragraph,
|
|
299
|
+
La as Plus,
|
|
300
|
+
Mo as RevealSpinner,
|
|
301
|
+
So as Revealer,
|
|
302
|
+
De as Select,
|
|
303
|
+
jo as Separator,
|
|
304
|
+
No as SeparatorLabel,
|
|
305
|
+
Bo as Skeleton,
|
|
306
|
+
Eo as SkeletonInstance,
|
|
307
|
+
Lo as SmallSeparator,
|
|
308
|
+
w as Span,
|
|
309
|
+
Co as Sparebank1Logo,
|
|
310
|
+
Po as Spinner,
|
|
311
|
+
Ro as StoLogo,
|
|
312
|
+
Do as StorebrandLogo,
|
|
313
|
+
Ia as Test,
|
|
314
|
+
zt as Text,
|
|
315
|
+
W as TextButton,
|
|
316
|
+
Ft as TextButtonVariant,
|
|
317
|
+
Fo as ThemeSetter,
|
|
318
|
+
Ea as Times,
|
|
319
|
+
qo as Veil,
|
|
320
|
+
To as VerticalSeparator,
|
|
321
|
+
Xo as Wrapper,
|
|
322
|
+
Yo as WrapperWidth,
|
|
323
|
+
Ye as ariaTextStyles,
|
|
324
|
+
lt as buttonDangerStyles,
|
|
325
|
+
ce as buttonResetStyles,
|
|
326
|
+
ct as buttonSecondaryStyles,
|
|
327
|
+
it as buttonSuccessStyles,
|
|
328
|
+
dt as buttonWarningStyles,
|
|
329
|
+
K as copyToClipboard,
|
|
330
|
+
$e as darkBackgroundColor,
|
|
331
|
+
_e as defaultAtomElementType,
|
|
332
|
+
Oe as effectStyles,
|
|
333
|
+
ye as errorParagraph,
|
|
334
|
+
Ue as font,
|
|
335
|
+
Ma as generateRandomId,
|
|
336
|
+
Ko as getThemePreference,
|
|
337
|
+
Dt as iconShadowStyles,
|
|
338
|
+
ze as lightBackgroundColor,
|
|
339
|
+
Qe as nonInteractiveEffectStyles,
|
|
340
|
+
Ht as normalBlendStyles,
|
|
341
|
+
U as overflowProtectionStyles,
|
|
342
|
+
Aa as scale,
|
|
343
|
+
Wo as setThemePreference,
|
|
344
|
+
Qt as spanStyles,
|
|
345
|
+
qt as textShadowStyles,
|
|
346
|
+
qe as theme,
|
|
347
|
+
$o as themePreferences,
|
|
348
|
+
me as useCreateNotification,
|
|
349
|
+
Oo as useIsDarkMode,
|
|
350
|
+
Uo as useIsLightMode,
|
|
351
|
+
Ca as useMediaQuery,
|
|
352
|
+
po as useModal,
|
|
353
|
+
mo as useModalContext,
|
|
354
|
+
vo as useRevealer,
|
|
355
|
+
zo as useTheme
|
|
176
356
|
};
|
package/build/theme.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ export declare const font: {
|
|
|
11
11
|
crossorigin: boolean;
|
|
12
12
|
})[];
|
|
13
13
|
};
|
|
14
|
-
export declare function
|
|
14
|
+
export declare function FontFamilyHead(): import("react/jsx-runtime").JSX.Element;
|
|
15
15
|
declare const theme: string;
|
|
16
16
|
export default theme;
|
|
17
17
|
export declare const overflowProtectionStyles: string;
|
package/build/theme.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("./jsx-runtime-BB_1_6y_.js"),r=require("@kuma-ui/core"),c="#f8fafc",a="#0c0d12",e={family:"Inter, sans-serif",stylesheet:"https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap",preconnect:[{url:"https://fonts.googleapis.com"},{url:"https://fonts.gstatic.com",crossorigin:!0}]};function l(){return t.jsxRuntimeExports.jsxs(t.jsxRuntimeExports.Fragment,{children:[e.preconnect.map(({url:o,crossorigin:
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("./jsx-runtime-BB_1_6y_.js"),r=require("@kuma-ui/core"),c="#f8fafc",a="#0c0d12",e={family:"Inter, sans-serif",stylesheet:"https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap",preconnect:[{url:"https://fonts.googleapis.com"},{url:"https://fonts.gstatic.com",crossorigin:!0}]};function l(){return t.jsxRuntimeExports.jsxs(t.jsxRuntimeExports.Fragment,{children:[e.preconnect.map(({url:o,crossorigin:n})=>t.jsxRuntimeExports.jsx("link",{href:o,rel:"preconnect",crossOrigin:n?"anonymous":void 0},o)),t.jsxRuntimeExports.jsx("link",{href:e.stylesheet,rel:"stylesheet"})]})}const i="kakadu-components-2006849853",u="kakadu-components-4178476647",f="kakadu-components-216224454",s="kakadu-components-352310015",m=r.cx(s,"kakadu-components-1119532724");exports.FontFamilyHead=l;exports.buttonResetStyles=f;exports.darkBackgroundColor=a;exports.default=i;exports.effectStyles=s;exports.font=e;exports.lightBackgroundColor=c;exports.nonInteractiveEffectStyles=m;exports.overflowProtectionStyles=u;
|
package/build/theme.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { j as t } from "./jsx-runtime-B4hRZ52C.mjs";
|
|
2
2
|
import { cx as n } from "@kuma-ui/core";
|
|
3
|
-
const
|
|
3
|
+
const l = "#f8fafc", i = "#0c0d12", s = {
|
|
4
4
|
family: "Inter, sans-serif",
|
|
5
5
|
stylesheet: "https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap",
|
|
6
6
|
preconnect: [{
|
|
@@ -19,15 +19,15 @@ function f() {
|
|
|
19
19
|
/* @__PURE__ */ t.jsx("link", { href: s.stylesheet, rel: "stylesheet" })
|
|
20
20
|
] });
|
|
21
21
|
}
|
|
22
|
-
const p = "kakadu-components-
|
|
22
|
+
const p = "kakadu-components-2006849853", m = "kakadu-components-4178476647", k = "kakadu-components-216224454", c = "kakadu-components-352310015", u = n(c, "kakadu-components-1119532724");
|
|
23
23
|
export {
|
|
24
|
-
f as
|
|
24
|
+
f as FontFamilyHead,
|
|
25
25
|
k as buttonResetStyles,
|
|
26
|
-
|
|
26
|
+
i as darkBackgroundColor,
|
|
27
27
|
p as default,
|
|
28
28
|
c as effectStyles,
|
|
29
29
|
s as font,
|
|
30
|
-
|
|
30
|
+
l as lightBackgroundColor,
|
|
31
31
|
u as nonInteractiveEffectStyles,
|
|
32
32
|
m as overflowProtectionStyles
|
|
33
33
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kakadu/components",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.1",
|
|
4
4
|
"description": "Kakadu components library",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"main": "./build/index.js",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"test": "vitest run",
|
|
31
31
|
"test:watch": "vitest",
|
|
32
32
|
"test:coverage": "vitest run --coverage",
|
|
33
|
-
"prepublishOnly": "npm test && npm run build",
|
|
33
|
+
"prepublishOnly": "npm run lint && npm test && npm run build",
|
|
34
34
|
"chromatic": "npx chromatic --project-token=chpt_52149863cf0ae20"
|
|
35
35
|
},
|
|
36
36
|
"exports": {
|
package/readme.md
CHANGED
|
@@ -35,19 +35,19 @@ export default function App({Component, pageProps}: AppProps) {
|
|
|
35
35
|
}
|
|
36
36
|
```
|
|
37
37
|
|
|
38
|
-
Then, in your `_document.tsx` (or equivalent), import the `theme` class name and the `
|
|
38
|
+
Then, in your `_document.tsx` (or equivalent), import the `theme` class name and the `FontFamilyHead`:
|
|
39
39
|
|
|
40
40
|
```tsx
|
|
41
41
|
import React from 'react';
|
|
42
42
|
import Document, {Html, Head, Main, NextScript} from 'next/document';
|
|
43
|
-
import {theme,
|
|
43
|
+
import {theme, FontFamilyHead} from '@kakadu/components';
|
|
44
44
|
|
|
45
45
|
export default class CustomDocument extends Document {
|
|
46
46
|
render() {
|
|
47
47
|
return (
|
|
48
48
|
<Html suppressHydrationWarning className={theme}>
|
|
49
49
|
<Head>
|
|
50
|
-
<
|
|
50
|
+
<FontFamilyHead />
|
|
51
51
|
</Head>
|
|
52
52
|
|
|
53
53
|
<body>
|