@postenbring/hedwig-react 0.0.6 → 0.0.9
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/accordion/accordion-item-content.js +3 -4
- package/dist/accordion/accordion-item-content.mjs +1 -1
- package/dist/accordion/accordion-item-trigger.js +26 -13
- package/dist/accordion/accordion-item-trigger.mjs +1 -1
- package/dist/accordion/accordion-item.js +3 -4
- package/dist/accordion/accordion-item.mjs +1 -1
- package/dist/accordion/accordion.js +1 -2
- package/dist/accordion/accordion.mjs +1 -1
- package/dist/accordion/index.js +35 -25
- package/dist/accordion/index.mjs +5 -5
- package/dist/badge/badge.js +10 -4
- package/dist/badge/badge.mjs +1 -1
- package/dist/badge/index.js +12 -6
- package/dist/badge/index.mjs +2 -2
- package/dist/box/box.d.mts +2 -2
- package/dist/box/box.d.ts +2 -2
- package/dist/box/box.js +8 -9
- package/dist/box/box.mjs +1 -1
- package/dist/box/index.js +10 -11
- package/dist/box/index.mjs +2 -2
- package/dist/button/button.d.mts +14 -14
- package/dist/button/button.d.ts +14 -14
- package/dist/button/button.js +59 -38
- package/dist/button/button.mjs +3 -1
- package/dist/button/index.d.mts +2 -2
- package/dist/button/index.d.ts +2 -2
- package/dist/button/index.js +61 -40
- package/dist/button/index.mjs +4 -2
- package/dist/chunk-2QSL2PSS.mjs +63 -0
- package/dist/chunk-5NDZ66M6.mjs +5 -0
- package/dist/chunk-6AW5BEDP.mjs +21 -0
- package/dist/{chunk-B3PZUFG2.mjs → chunk-6XSKLHN6.mjs} +15 -6
- package/dist/chunk-BJANCH4F.mjs +5 -0
- package/dist/{chunk-NMSLCM2K.mjs → chunk-DQ2OO6EW.mjs} +1 -1
- package/dist/chunk-ENRMC5K7.mjs +75 -0
- package/dist/{chunk-IWV4FFE3.mjs → chunk-GMGUONH5.mjs} +2 -3
- package/dist/{chunk-LNYNZ4EG.mjs → chunk-J7U4Z726.mjs} +3 -4
- package/dist/{chunk-KBVDBI2L.mjs → chunk-L7DYK6OS.mjs} +3 -4
- package/dist/{chunk-O3NMR6GE.mjs → chunk-MNSMCSAR.mjs} +11 -5
- package/dist/chunk-N3EFZW7T.mjs +5 -0
- package/dist/{chunk-IOOSUX5O.mjs → chunk-QOVAYDPH.mjs} +2 -2
- package/dist/chunk-R55SMUE7.mjs +5 -0
- package/dist/{chunk-EX4U7YZF.mjs → chunk-RXUPE4MM.mjs} +8 -9
- package/dist/{chunk-IWDN3WGQ.mjs → chunk-STKOYB5H.mjs} +13 -7
- package/dist/chunk-TES7CVGU.mjs +34 -0
- package/dist/chunk-X4D24ZRP.mjs +63 -0
- package/dist/chunk-XJ44O3HY.mjs +58 -0
- package/dist/chunk-Z36ETKOZ.mjs +5 -0
- package/dist/index.d.mts +5 -4
- package/dist/index.d.ts +5 -4
- package/dist/index.js +235 -155
- package/dist/index.mjs +32 -25
- package/dist/input/index.d.mts +3 -0
- package/dist/input/index.d.ts +3 -0
- package/dist/input/index.js +121 -0
- package/dist/input/index.mjs +13 -0
- package/dist/input/input.d.mts +1 -1
- package/dist/input/input.d.ts +1 -1
- package/dist/input/input.js +13 -7
- package/dist/input/input.mjs +3 -47
- package/dist/link/index.d.mts +1 -1
- package/dist/link/index.d.ts +1 -1
- package/dist/link/index.js +22 -29
- package/dist/link/index.mjs +2 -2
- package/dist/link/link.d.mts +2 -10
- package/dist/link/link.d.ts +2 -10
- package/dist/link/link.js +20 -27
- package/dist/link/link.mjs +1 -1
- package/dist/list/description-list.d.mts +1 -1
- package/dist/list/description-list.d.ts +1 -1
- package/dist/list/description-list.js +14 -5
- package/dist/list/description-list.mjs +1 -1
- package/dist/list/index.js +28 -13
- package/dist/list/index.mjs +8 -8
- package/dist/list/link-list.js +12 -6
- package/dist/list/link-list.mjs +2 -2
- package/dist/list/list.js +12 -6
- package/dist/list/list.mjs +1 -1
- package/dist/message/index.d.mts +14 -2
- package/dist/message/index.d.ts +14 -2
- package/dist/message/index.js +51 -16
- package/dist/message/index.mjs +10 -5
- package/dist/message/message.d.mts +3 -1
- package/dist/message/message.d.ts +3 -1
- package/dist/message/message.js +42 -14
- package/dist/message/message.mjs +8 -4
- package/package.json +3 -5
- package/dist/chunk-4XWB4ZSR.mjs +0 -6
- package/dist/chunk-7F7QB4D5.mjs +0 -50
- package/dist/chunk-AYGPUYPZ.mjs +0 -5
- package/dist/chunk-CYW3DUD2.mjs +0 -5
- package/dist/chunk-EKFYWUBE.mjs +0 -36
- package/dist/chunk-GSPFHK2Z.mjs +0 -55
- package/dist/chunk-ID5KKZMK.mjs +0 -5
- package/dist/chunk-PCKWBORI.mjs +0 -5
- package/dist/chunk-VZNNGRKM.mjs +0 -5
- package/dist/chunk-X3OAJSS2.mjs +0 -41
package/dist/chunk-7F7QB4D5.mjs
DELETED
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
AccordionItemContext
|
|
3
|
-
} from "./chunk-2V6SWZ5G.mjs";
|
|
4
|
-
import {
|
|
5
|
-
__objRest,
|
|
6
|
-
__spreadProps,
|
|
7
|
-
__spreadValues
|
|
8
|
-
} from "./chunk-FUJQIYOF.mjs";
|
|
9
|
-
|
|
10
|
-
// src/accordion/accordion-item-trigger.tsx
|
|
11
|
-
import { forwardRef, useContext } from "react";
|
|
12
|
-
import { t } from "@postenbring/hedwig-css/typed-classname/index.mjs";
|
|
13
|
-
import { clsx } from "clsx";
|
|
14
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
15
|
-
function FaArrowDownButNotReally() {
|
|
16
|
-
return /* @__PURE__ */ jsx("span", { children: "v " });
|
|
17
|
-
}
|
|
18
|
-
function FaArrowUpButNotReally() {
|
|
19
|
-
return /* @__PURE__ */ jsx("span", { children: "^ " });
|
|
20
|
-
}
|
|
21
|
-
var AccordionTrigger = forwardRef((_a, ref) => {
|
|
22
|
-
var _b = _a, { as: Component = "button", children, className, onClick } = _b, rest = __objRest(_b, ["as", "children", "className", "onClick"]);
|
|
23
|
-
const itemContext = useContext(AccordionItemContext);
|
|
24
|
-
if (itemContext === null) {
|
|
25
|
-
return null;
|
|
26
|
-
}
|
|
27
|
-
const expandOrCollapse = (e) => {
|
|
28
|
-
itemContext.setOpen(!itemContext.open);
|
|
29
|
-
onClick && onClick(e);
|
|
30
|
-
};
|
|
31
|
-
return /* @__PURE__ */ jsx(
|
|
32
|
-
Component,
|
|
33
|
-
__spreadProps(__spreadValues({}, rest), {
|
|
34
|
-
"aria-expanded": itemContext.open,
|
|
35
|
-
className: clsx(t("hds-accordion-item-trigger"), className),
|
|
36
|
-
onClick: expandOrCollapse,
|
|
37
|
-
ref,
|
|
38
|
-
type: "button",
|
|
39
|
-
children: /* @__PURE__ */ jsxs("span", { children: [
|
|
40
|
-
/* @__PURE__ */ jsx("div", { className: clsx(t("hds-accordion-item-trigger--icon")), children: itemContext.open ? /* @__PURE__ */ jsx(FaArrowUpButNotReally, {}) : /* @__PURE__ */ jsx(FaArrowDownButNotReally, {}) }),
|
|
41
|
-
children
|
|
42
|
-
] })
|
|
43
|
-
})
|
|
44
|
-
);
|
|
45
|
-
});
|
|
46
|
-
AccordionTrigger.displayName = "AccordionTrigger";
|
|
47
|
-
|
|
48
|
-
export {
|
|
49
|
-
AccordionTrigger
|
|
50
|
-
};
|
package/dist/chunk-AYGPUYPZ.mjs
DELETED
package/dist/chunk-CYW3DUD2.mjs
DELETED
package/dist/chunk-EKFYWUBE.mjs
DELETED
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
Box
|
|
3
|
-
} from "./chunk-EX4U7YZF.mjs";
|
|
4
|
-
import {
|
|
5
|
-
__objRest,
|
|
6
|
-
__spreadProps,
|
|
7
|
-
__spreadValues
|
|
8
|
-
} from "./chunk-FUJQIYOF.mjs";
|
|
9
|
-
|
|
10
|
-
// src/message/message.tsx
|
|
11
|
-
import { forwardRef } from "react";
|
|
12
|
-
import { clsx } from "clsx";
|
|
13
|
-
import { t } from "@postenbring/hedwig-css/typed-classname/index.mjs";
|
|
14
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
15
|
-
var Message = forwardRef(
|
|
16
|
-
(_a, ref) => {
|
|
17
|
-
var _b = _a, { children, className, variant = "success", icon, iconClassName } = _b, rest = __objRest(_b, ["children", "className", "variant", "icon", "iconClassName"]);
|
|
18
|
-
return /* @__PURE__ */ jsxs(
|
|
19
|
-
Box,
|
|
20
|
-
__spreadProps(__spreadValues({
|
|
21
|
-
className: clsx(t(`hds-message`), t(`hds-message--${variant}`), className),
|
|
22
|
-
ref
|
|
23
|
-
}, rest), {
|
|
24
|
-
children: [
|
|
25
|
-
variant === "neutral" && /* @__PURE__ */ jsx("div", { className: clsx(t("hds-message--neutral__icon"), iconClassName), children: icon }),
|
|
26
|
-
children
|
|
27
|
-
]
|
|
28
|
-
})
|
|
29
|
-
);
|
|
30
|
-
}
|
|
31
|
-
);
|
|
32
|
-
Message.displayName = "Message";
|
|
33
|
-
|
|
34
|
-
export {
|
|
35
|
-
Message
|
|
36
|
-
};
|
package/dist/chunk-GSPFHK2Z.mjs
DELETED
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
__objRest,
|
|
3
|
-
__spreadProps,
|
|
4
|
-
__spreadValues
|
|
5
|
-
} from "./chunk-FUJQIYOF.mjs";
|
|
6
|
-
|
|
7
|
-
// src/button/button.tsx
|
|
8
|
-
import { clsx } from "clsx";
|
|
9
|
-
import { t } from "@postenbring/hedwig-css/typed-classname/index.mjs";
|
|
10
|
-
import { jsx } from "react/jsx-runtime";
|
|
11
|
-
function BaseButton(_a) {
|
|
12
|
-
var _b = _a, {
|
|
13
|
-
children,
|
|
14
|
-
variant,
|
|
15
|
-
size = "medium",
|
|
16
|
-
fullWidth = false,
|
|
17
|
-
fill = "contained",
|
|
18
|
-
buttonRef
|
|
19
|
-
} = _b, rest = __objRest(_b, [
|
|
20
|
-
"children",
|
|
21
|
-
"variant",
|
|
22
|
-
"size",
|
|
23
|
-
"fullWidth",
|
|
24
|
-
"fill",
|
|
25
|
-
"buttonRef"
|
|
26
|
-
]);
|
|
27
|
-
return /* @__PURE__ */ jsx(
|
|
28
|
-
"button",
|
|
29
|
-
__spreadProps(__spreadValues({
|
|
30
|
-
className: clsx(t("hds-button"), t(`hds-button--${size}`), {
|
|
31
|
-
[t(`hds-button--${variant}`)]: fill === "contained",
|
|
32
|
-
[t(`hds-button--outline-${variant}`)]: fill === "outlined",
|
|
33
|
-
[t("hds-button--full")]: fullWidth === true,
|
|
34
|
-
[t("hds-button--mobile-full")]: fullWidth === "mobile"
|
|
35
|
-
}),
|
|
36
|
-
ref: buttonRef
|
|
37
|
-
}, rest), {
|
|
38
|
-
children
|
|
39
|
-
})
|
|
40
|
-
);
|
|
41
|
-
}
|
|
42
|
-
BaseButton.displayName = "BaseButton";
|
|
43
|
-
function PrimaryButton(props) {
|
|
44
|
-
return /* @__PURE__ */ jsx(BaseButton, __spreadProps(__spreadValues({}, props), { variant: "primary" }));
|
|
45
|
-
}
|
|
46
|
-
PrimaryButton.displayName = "PrimaryButton";
|
|
47
|
-
function SecondaryButton(props) {
|
|
48
|
-
return /* @__PURE__ */ jsx(BaseButton, __spreadProps(__spreadValues({}, props), { variant: "secondary" }));
|
|
49
|
-
}
|
|
50
|
-
SecondaryButton.displayName = "SecondaryButton";
|
|
51
|
-
|
|
52
|
-
export {
|
|
53
|
-
PrimaryButton,
|
|
54
|
-
SecondaryButton
|
|
55
|
-
};
|
package/dist/chunk-ID5KKZMK.mjs
DELETED
package/dist/chunk-PCKWBORI.mjs
DELETED
package/dist/chunk-VZNNGRKM.mjs
DELETED
package/dist/chunk-X3OAJSS2.mjs
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
__objRest,
|
|
3
|
-
__spreadProps,
|
|
4
|
-
__spreadValues
|
|
5
|
-
} from "./chunk-FUJQIYOF.mjs";
|
|
6
|
-
|
|
7
|
-
// src/link/link.tsx
|
|
8
|
-
import { clsx } from "clsx";
|
|
9
|
-
import { t } from "@postenbring/hedwig-css/typed-classname/index.mjs";
|
|
10
|
-
import { jsx } from "react/jsx-runtime";
|
|
11
|
-
function Link(_a) {
|
|
12
|
-
var _b = _a, {
|
|
13
|
-
children,
|
|
14
|
-
variant = "underline",
|
|
15
|
-
size = "medium",
|
|
16
|
-
anchorRef
|
|
17
|
-
} = _b, rest = __objRest(_b, [
|
|
18
|
-
"children",
|
|
19
|
-
"variant",
|
|
20
|
-
"size",
|
|
21
|
-
"anchorRef"
|
|
22
|
-
]);
|
|
23
|
-
return /* @__PURE__ */ jsx(
|
|
24
|
-
"a",
|
|
25
|
-
__spreadProps(__spreadValues({
|
|
26
|
-
className: clsx(
|
|
27
|
-
t("hds-link"),
|
|
28
|
-
variant !== "underline" && t(`hds-link--${variant}`),
|
|
29
|
-
size !== "medium" && t(`hds-link--${size}`)
|
|
30
|
-
),
|
|
31
|
-
ref: anchorRef
|
|
32
|
-
}, rest), {
|
|
33
|
-
children
|
|
34
|
-
})
|
|
35
|
-
);
|
|
36
|
-
}
|
|
37
|
-
Link.displayName = "Link";
|
|
38
|
-
|
|
39
|
-
export {
|
|
40
|
-
Link
|
|
41
|
-
};
|