@postenbring/hedwig-react 0.0.3 → 0.0.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/dist/accordion/accordion-item-content.d.mts +9 -0
- package/dist/accordion/accordion-item-content.d.ts +9 -0
- package/dist/accordion/accordion-item-content.js +98 -0
- package/dist/accordion/accordion-item-content.mjs +8 -0
- package/dist/accordion/accordion-item-trigger.d.mts +9 -0
- package/dist/accordion/accordion-item-trigger.d.ts +9 -0
- package/dist/accordion/accordion-item-trigger.js +108 -0
- package/dist/accordion/accordion-item-trigger.mjs +8 -0
- package/dist/accordion/accordion-item.d.mts +15 -0
- package/dist/accordion/accordion-item.d.ts +15 -0
- package/dist/accordion/accordion-item.js +116 -0
- package/dist/accordion/accordion-item.mjs +8 -0
- package/dist/accordion/accordion.d.mts +28 -0
- package/dist/accordion/accordion.d.ts +28 -0
- package/dist/accordion/accordion.js +93 -0
- package/dist/accordion/accordion.mjs +8 -0
- package/dist/accordion/index.d.mts +6 -0
- package/dist/accordion/index.d.ts +6 -0
- package/dist/accordion/index.js +217 -0
- package/dist/accordion/index.mjs +21 -0
- package/dist/badge/badge.d.mts +28 -0
- package/dist/badge/badge.d.ts +28 -0
- package/dist/badge/badge.js +103 -0
- package/dist/badge/badge.mjs +13 -0
- package/dist/badge/index.d.mts +3 -0
- package/dist/badge/index.d.ts +3 -0
- package/dist/badge/index.js +109 -0
- package/dist/badge/index.mjs +14 -0
- package/dist/box/box.d.mts +36 -0
- package/dist/box/box.d.ts +36 -0
- package/dist/box/box.js +131 -0
- package/dist/box/box.mjs +9 -0
- package/dist/box/index.d.mts +3 -0
- package/dist/box/index.d.ts +3 -0
- package/dist/box/index.js +137 -0
- package/dist/box/index.mjs +10 -0
- package/dist/button/button.d.mts +37 -0
- package/dist/button/button.d.ts +37 -0
- package/dist/button/button.js +103 -0
- package/dist/button/button.mjs +9 -0
- package/dist/button/index.d.mts +3 -37
- package/dist/button/index.d.ts +3 -37
- package/dist/button/index.js +9 -21
- package/dist/button/index.mjs +3 -1
- package/dist/chunk-2V6SWZ5G.mjs +16 -0
- package/dist/chunk-4XWB4ZSR.mjs +6 -0
- package/dist/chunk-7F7QB4D5.mjs +50 -0
- package/dist/chunk-AYGPUYPZ.mjs +5 -0
- package/dist/chunk-B3PZUFG2.mjs +40 -0
- package/dist/chunk-CYW3DUD2.mjs +5 -0
- package/dist/chunk-EKFYWUBE.mjs +36 -0
- package/dist/chunk-EX4U7YZF.mjs +83 -0
- package/dist/chunk-FUJQIYOF.mjs +37 -0
- package/dist/chunk-GSPFHK2Z.mjs +55 -0
- package/dist/chunk-ID5KKZMK.mjs +5 -0
- package/dist/chunk-IOOSUX5O.mjs +6 -0
- package/dist/chunk-IWDN3WGQ.mjs +47 -0
- package/dist/chunk-IWV4FFE3.mjs +35 -0
- package/dist/chunk-KBVDBI2L.mjs +59 -0
- package/dist/chunk-LNYNZ4EG.mjs +40 -0
- package/dist/chunk-NMSLCM2K.mjs +18 -0
- package/dist/chunk-O3NMR6GE.mjs +53 -0
- package/dist/chunk-PCKWBORI.mjs +5 -0
- package/dist/chunk-VZNNGRKM.mjs +5 -0
- package/dist/chunk-X3OAJSS2.mjs +41 -0
- package/dist/index.d.mts +15 -27
- package/dist/index.d.ts +15 -27
- package/dist/index.js +443 -29
- package/dist/index.mjs +69 -43
- package/dist/input/input.d.mts +13 -0
- package/dist/input/input.d.ts +13 -0
- package/dist/input/input.js +109 -0
- package/dist/input/input.mjs +51 -0
- package/dist/link/index.d.mts +3 -0
- package/dist/link/index.d.ts +3 -0
- package/dist/link/index.js +94 -0
- package/dist/link/index.mjs +8 -0
- package/dist/link/link.d.mts +26 -0
- package/dist/link/link.d.ts +26 -0
- package/dist/link/link.js +88 -0
- package/dist/link/link.mjs +7 -0
- package/dist/list/description-list.d.mts +32 -0
- package/dist/list/description-list.d.ts +32 -0
- package/dist/list/description-list.js +89 -0
- package/dist/list/description-list.mjs +13 -0
- package/dist/list/index.d.mts +5 -0
- package/dist/list/index.d.ts +5 -0
- package/dist/list/index.js +144 -0
- package/dist/list/index.mjs +22 -0
- package/dist/list/link-list.d.mts +13 -0
- package/dist/list/link-list.d.ts +13 -0
- package/dist/list/link-list.js +102 -0
- package/dist/list/link-list.mjs +8 -0
- package/dist/list/list.d.mts +25 -0
- package/dist/list/list.d.ts +25 -0
- package/dist/list/list.js +95 -0
- package/dist/list/list.mjs +9 -0
- package/dist/message/index.d.mts +4 -0
- package/dist/message/index.d.ts +4 -0
- package/dist/message/index.js +162 -0
- package/dist/message/index.mjs +9 -0
- package/dist/message/message.d.mts +16 -0
- package/dist/message/message.d.ts +16 -0
- package/dist/message/message.js +155 -0
- package/dist/message/message.mjs +8 -0
- package/dist/utils-BfZsjuFH.d.mts +17 -0
- package/dist/utils-BfZsjuFH.d.ts +17 -0
- package/package.json +17 -17
- package/dist/chunk-ZPSTPWVB.mjs +0 -103
package/dist/index.mjs
CHANGED
|
@@ -1,49 +1,75 @@
|
|
|
1
|
+
import "./chunk-IOOSUX5O.mjs";
|
|
2
|
+
import {
|
|
3
|
+
LinkList
|
|
4
|
+
} from "./chunk-NMSLCM2K.mjs";
|
|
5
|
+
import {
|
|
6
|
+
OrderedList,
|
|
7
|
+
UnorderedList
|
|
8
|
+
} from "./chunk-IWDN3WGQ.mjs";
|
|
9
|
+
import "./chunk-4XWB4ZSR.mjs";
|
|
10
|
+
import {
|
|
11
|
+
Message
|
|
12
|
+
} from "./chunk-EKFYWUBE.mjs";
|
|
13
|
+
import "./chunk-ID5KKZMK.mjs";
|
|
14
|
+
import {
|
|
15
|
+
Box,
|
|
16
|
+
BoxCloseButton
|
|
17
|
+
} from "./chunk-EX4U7YZF.mjs";
|
|
18
|
+
import "./chunk-VZNNGRKM.mjs";
|
|
1
19
|
import {
|
|
2
20
|
PrimaryButton,
|
|
3
|
-
SecondaryButton
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
} from "./chunk-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
[`hds-link--${size}`]: size !== "medium"
|
|
37
|
-
}),
|
|
38
|
-
ref: anchorRef
|
|
39
|
-
}, rest), {
|
|
40
|
-
children
|
|
41
|
-
})
|
|
42
|
-
);
|
|
43
|
-
}
|
|
44
|
-
Link.displayName = "Link";
|
|
21
|
+
SecondaryButton
|
|
22
|
+
} from "./chunk-GSPFHK2Z.mjs";
|
|
23
|
+
import "./chunk-AYGPUYPZ.mjs";
|
|
24
|
+
import {
|
|
25
|
+
Link
|
|
26
|
+
} from "./chunk-X3OAJSS2.mjs";
|
|
27
|
+
import {
|
|
28
|
+
DescriptionDetails,
|
|
29
|
+
DescriptionList,
|
|
30
|
+
DescriptionTerm
|
|
31
|
+
} from "./chunk-B3PZUFG2.mjs";
|
|
32
|
+
import "./chunk-PCKWBORI.mjs";
|
|
33
|
+
import {
|
|
34
|
+
AccordionContent
|
|
35
|
+
} from "./chunk-LNYNZ4EG.mjs";
|
|
36
|
+
import {
|
|
37
|
+
AccordionTrigger
|
|
38
|
+
} from "./chunk-7F7QB4D5.mjs";
|
|
39
|
+
import {
|
|
40
|
+
AccordionItem
|
|
41
|
+
} from "./chunk-KBVDBI2L.mjs";
|
|
42
|
+
import {
|
|
43
|
+
Accordion
|
|
44
|
+
} from "./chunk-IWV4FFE3.mjs";
|
|
45
|
+
import "./chunk-2V6SWZ5G.mjs";
|
|
46
|
+
import "./chunk-CYW3DUD2.mjs";
|
|
47
|
+
import {
|
|
48
|
+
Badge,
|
|
49
|
+
DarkBadge,
|
|
50
|
+
WarningBadge,
|
|
51
|
+
WhiteBadge
|
|
52
|
+
} from "./chunk-O3NMR6GE.mjs";
|
|
53
|
+
import "./chunk-FUJQIYOF.mjs";
|
|
45
54
|
export {
|
|
55
|
+
Accordion,
|
|
56
|
+
AccordionContent,
|
|
57
|
+
AccordionItem,
|
|
58
|
+
AccordionTrigger,
|
|
59
|
+
Badge,
|
|
60
|
+
Box,
|
|
61
|
+
BoxCloseButton,
|
|
62
|
+
DarkBadge,
|
|
63
|
+
DescriptionDetails,
|
|
64
|
+
DescriptionList,
|
|
65
|
+
DescriptionTerm,
|
|
46
66
|
Link,
|
|
67
|
+
LinkList,
|
|
68
|
+
Message,
|
|
69
|
+
OrderedList,
|
|
47
70
|
PrimaryButton,
|
|
48
|
-
SecondaryButton
|
|
71
|
+
SecondaryButton,
|
|
72
|
+
UnorderedList,
|
|
73
|
+
WarningBadge,
|
|
74
|
+
WhiteBadge
|
|
49
75
|
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
interface InputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, "children"> {
|
|
5
|
+
id?: string;
|
|
6
|
+
variant?: "default" | "white" | "lined";
|
|
7
|
+
errorMessage?: React.ReactNode;
|
|
8
|
+
labelProps?: React.LabelHTMLAttributes<HTMLLabelElement>;
|
|
9
|
+
label: React.ReactNode;
|
|
10
|
+
}
|
|
11
|
+
declare function Input({ variant, errorMessage, labelProps, label, id, ...rest }: InputProps): react_jsx_runtime.JSX.Element;
|
|
12
|
+
|
|
13
|
+
export { Input, type InputProps };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
interface InputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, "children"> {
|
|
5
|
+
id?: string;
|
|
6
|
+
variant?: "default" | "white" | "lined";
|
|
7
|
+
errorMessage?: React.ReactNode;
|
|
8
|
+
labelProps?: React.LabelHTMLAttributes<HTMLLabelElement>;
|
|
9
|
+
label: React.ReactNode;
|
|
10
|
+
}
|
|
11
|
+
declare function Input({ variant, errorMessage, labelProps, label, id, ...rest }: InputProps): react_jsx_runtime.JSX.Element;
|
|
12
|
+
|
|
13
|
+
export { Input, type InputProps };
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __defProps = Object.defineProperties;
|
|
5
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
7
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
8
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
9
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
10
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
11
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
12
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
13
|
+
var __spreadValues = (a, b) => {
|
|
14
|
+
for (var prop in b || (b = {}))
|
|
15
|
+
if (__hasOwnProp.call(b, prop))
|
|
16
|
+
__defNormalProp(a, prop, b[prop]);
|
|
17
|
+
if (__getOwnPropSymbols)
|
|
18
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
19
|
+
if (__propIsEnum.call(b, prop))
|
|
20
|
+
__defNormalProp(a, prop, b[prop]);
|
|
21
|
+
}
|
|
22
|
+
return a;
|
|
23
|
+
};
|
|
24
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
25
|
+
var __objRest = (source, exclude) => {
|
|
26
|
+
var target = {};
|
|
27
|
+
for (var prop in source)
|
|
28
|
+
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
29
|
+
target[prop] = source[prop];
|
|
30
|
+
if (source != null && __getOwnPropSymbols)
|
|
31
|
+
for (var prop of __getOwnPropSymbols(source)) {
|
|
32
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
33
|
+
target[prop] = source[prop];
|
|
34
|
+
}
|
|
35
|
+
return target;
|
|
36
|
+
};
|
|
37
|
+
var __export = (target, all) => {
|
|
38
|
+
for (var name in all)
|
|
39
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
40
|
+
};
|
|
41
|
+
var __copyProps = (to, from, except, desc) => {
|
|
42
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
43
|
+
for (let key of __getOwnPropNames(from))
|
|
44
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
45
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
46
|
+
}
|
|
47
|
+
return to;
|
|
48
|
+
};
|
|
49
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
50
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
51
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
52
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
53
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
54
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
55
|
+
mod
|
|
56
|
+
));
|
|
57
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
58
|
+
|
|
59
|
+
// src/input/input.tsx
|
|
60
|
+
var input_exports = {};
|
|
61
|
+
__export(input_exports, {
|
|
62
|
+
Input: () => Input
|
|
63
|
+
});
|
|
64
|
+
module.exports = __toCommonJS(input_exports);
|
|
65
|
+
var React = __toESM(require("react"));
|
|
66
|
+
var import_clsx = require("clsx");
|
|
67
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
68
|
+
function Input(_a) {
|
|
69
|
+
var _b = _a, {
|
|
70
|
+
variant = "default",
|
|
71
|
+
errorMessage,
|
|
72
|
+
labelProps,
|
|
73
|
+
label,
|
|
74
|
+
id
|
|
75
|
+
} = _b, rest = __objRest(_b, [
|
|
76
|
+
"variant",
|
|
77
|
+
"errorMessage",
|
|
78
|
+
"labelProps",
|
|
79
|
+
"label",
|
|
80
|
+
"id"
|
|
81
|
+
]);
|
|
82
|
+
const errorMessageId = React.useId();
|
|
83
|
+
const inputId = React.useId();
|
|
84
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
85
|
+
"div",
|
|
86
|
+
{
|
|
87
|
+
className: (0, import_clsx.clsx)("hds-input", {
|
|
88
|
+
[`hds-input--${variant}`]: variant,
|
|
89
|
+
"hds-input--error": errorMessage
|
|
90
|
+
}),
|
|
91
|
+
children: [
|
|
92
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", __spreadProps(__spreadValues({ className: "hds-input__label" }, labelProps), { htmlFor: id || inputId, children: label })),
|
|
93
|
+
!!errorMessage && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "hds-input__error-message", id: errorMessageId, children: errorMessage }),
|
|
94
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
95
|
+
"input",
|
|
96
|
+
__spreadProps(__spreadValues({}, rest), {
|
|
97
|
+
"aria-describedby": errorMessageId,
|
|
98
|
+
className: "hds-input__input",
|
|
99
|
+
id: id || inputId
|
|
100
|
+
})
|
|
101
|
+
)
|
|
102
|
+
]
|
|
103
|
+
}
|
|
104
|
+
);
|
|
105
|
+
}
|
|
106
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
107
|
+
0 && (module.exports = {
|
|
108
|
+
Input
|
|
109
|
+
});
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import {
|
|
2
|
+
__objRest,
|
|
3
|
+
__spreadProps,
|
|
4
|
+
__spreadValues
|
|
5
|
+
} from "../chunk-FUJQIYOF.mjs";
|
|
6
|
+
|
|
7
|
+
// src/input/input.tsx
|
|
8
|
+
import * as React from "react";
|
|
9
|
+
import { clsx } from "clsx";
|
|
10
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
11
|
+
function Input(_a) {
|
|
12
|
+
var _b = _a, {
|
|
13
|
+
variant = "default",
|
|
14
|
+
errorMessage,
|
|
15
|
+
labelProps,
|
|
16
|
+
label,
|
|
17
|
+
id
|
|
18
|
+
} = _b, rest = __objRest(_b, [
|
|
19
|
+
"variant",
|
|
20
|
+
"errorMessage",
|
|
21
|
+
"labelProps",
|
|
22
|
+
"label",
|
|
23
|
+
"id"
|
|
24
|
+
]);
|
|
25
|
+
const errorMessageId = React.useId();
|
|
26
|
+
const inputId = React.useId();
|
|
27
|
+
return /* @__PURE__ */ jsxs(
|
|
28
|
+
"div",
|
|
29
|
+
{
|
|
30
|
+
className: clsx("hds-input", {
|
|
31
|
+
[`hds-input--${variant}`]: variant,
|
|
32
|
+
"hds-input--error": errorMessage
|
|
33
|
+
}),
|
|
34
|
+
children: [
|
|
35
|
+
/* @__PURE__ */ jsx("label", __spreadProps(__spreadValues({ className: "hds-input__label" }, labelProps), { htmlFor: id || inputId, children: label })),
|
|
36
|
+
!!errorMessage && /* @__PURE__ */ jsx("span", { className: "hds-input__error-message", id: errorMessageId, children: errorMessage }),
|
|
37
|
+
/* @__PURE__ */ jsx(
|
|
38
|
+
"input",
|
|
39
|
+
__spreadProps(__spreadValues({}, rest), {
|
|
40
|
+
"aria-describedby": errorMessageId,
|
|
41
|
+
className: "hds-input__input",
|
|
42
|
+
id: id || inputId
|
|
43
|
+
})
|
|
44
|
+
)
|
|
45
|
+
]
|
|
46
|
+
}
|
|
47
|
+
);
|
|
48
|
+
}
|
|
49
|
+
export {
|
|
50
|
+
Input
|
|
51
|
+
};
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __defProps = Object.defineProperties;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
6
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
8
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
10
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
11
|
+
var __spreadValues = (a, b) => {
|
|
12
|
+
for (var prop in b || (b = {}))
|
|
13
|
+
if (__hasOwnProp.call(b, prop))
|
|
14
|
+
__defNormalProp(a, prop, b[prop]);
|
|
15
|
+
if (__getOwnPropSymbols)
|
|
16
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
17
|
+
if (__propIsEnum.call(b, prop))
|
|
18
|
+
__defNormalProp(a, prop, b[prop]);
|
|
19
|
+
}
|
|
20
|
+
return a;
|
|
21
|
+
};
|
|
22
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
23
|
+
var __objRest = (source, exclude) => {
|
|
24
|
+
var target = {};
|
|
25
|
+
for (var prop in source)
|
|
26
|
+
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
27
|
+
target[prop] = source[prop];
|
|
28
|
+
if (source != null && __getOwnPropSymbols)
|
|
29
|
+
for (var prop of __getOwnPropSymbols(source)) {
|
|
30
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
31
|
+
target[prop] = source[prop];
|
|
32
|
+
}
|
|
33
|
+
return target;
|
|
34
|
+
};
|
|
35
|
+
var __export = (target, all) => {
|
|
36
|
+
for (var name in all)
|
|
37
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
38
|
+
};
|
|
39
|
+
var __copyProps = (to, from, except, desc) => {
|
|
40
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
41
|
+
for (let key of __getOwnPropNames(from))
|
|
42
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
43
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
44
|
+
}
|
|
45
|
+
return to;
|
|
46
|
+
};
|
|
47
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
48
|
+
|
|
49
|
+
// src/link/index.tsx
|
|
50
|
+
var link_exports = {};
|
|
51
|
+
__export(link_exports, {
|
|
52
|
+
Link: () => Link
|
|
53
|
+
});
|
|
54
|
+
module.exports = __toCommonJS(link_exports);
|
|
55
|
+
var import_fonts = require("@postenbring/hedwig-tokens/tokens-output/css/fonts.css");
|
|
56
|
+
var import_tokens = require("@postenbring/hedwig-tokens/tokens-output/css/tokens.css");
|
|
57
|
+
var import_base = require("@postenbring/hedwig-css/dist/base.css");
|
|
58
|
+
var import_link = require("@postenbring/hedwig-css/dist/link.css");
|
|
59
|
+
|
|
60
|
+
// src/link/link.tsx
|
|
61
|
+
var import_clsx = require("clsx");
|
|
62
|
+
var import_typed_classname = require("@postenbring/hedwig-css/typed-classname/index.mjs");
|
|
63
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
64
|
+
function Link(_a) {
|
|
65
|
+
var _b = _a, {
|
|
66
|
+
children,
|
|
67
|
+
variant = "underline",
|
|
68
|
+
size = "medium",
|
|
69
|
+
anchorRef
|
|
70
|
+
} = _b, rest = __objRest(_b, [
|
|
71
|
+
"children",
|
|
72
|
+
"variant",
|
|
73
|
+
"size",
|
|
74
|
+
"anchorRef"
|
|
75
|
+
]);
|
|
76
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
77
|
+
"a",
|
|
78
|
+
__spreadProps(__spreadValues({
|
|
79
|
+
className: (0, import_clsx.clsx)(
|
|
80
|
+
(0, import_typed_classname.t)("hds-link"),
|
|
81
|
+
variant !== "underline" && (0, import_typed_classname.t)(`hds-link--${variant}`),
|
|
82
|
+
size !== "medium" && (0, import_typed_classname.t)(`hds-link--${size}`)
|
|
83
|
+
),
|
|
84
|
+
ref: anchorRef
|
|
85
|
+
}, rest), {
|
|
86
|
+
children
|
|
87
|
+
})
|
|
88
|
+
);
|
|
89
|
+
}
|
|
90
|
+
Link.displayName = "Link";
|
|
91
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
92
|
+
0 && (module.exports = {
|
|
93
|
+
Link
|
|
94
|
+
});
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
interface LinkProps extends React.AnchorHTMLAttributes<HTMLAnchorElement> {
|
|
5
|
+
/**
|
|
6
|
+
* The visual style of the link
|
|
7
|
+
*/
|
|
8
|
+
variant?: "underline" | "solid" | "inverted" | "no-underline";
|
|
9
|
+
/**
|
|
10
|
+
* Font size of the link
|
|
11
|
+
*/
|
|
12
|
+
size?: "small" | "medium" | "large";
|
|
13
|
+
children: React.ReactNode;
|
|
14
|
+
anchorRef?: React.ForwardedRef<HTMLAnchorElement>;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* ## TODO
|
|
18
|
+
*
|
|
19
|
+
* - [ ] Handle button styling
|
|
20
|
+
*/
|
|
21
|
+
declare function Link({ children, variant, size, anchorRef, ...rest }: LinkProps): react_jsx_runtime.JSX.Element;
|
|
22
|
+
declare namespace Link {
|
|
23
|
+
var displayName: string;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export { Link, type LinkProps };
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
interface LinkProps extends React.AnchorHTMLAttributes<HTMLAnchorElement> {
|
|
5
|
+
/**
|
|
6
|
+
* The visual style of the link
|
|
7
|
+
*/
|
|
8
|
+
variant?: "underline" | "solid" | "inverted" | "no-underline";
|
|
9
|
+
/**
|
|
10
|
+
* Font size of the link
|
|
11
|
+
*/
|
|
12
|
+
size?: "small" | "medium" | "large";
|
|
13
|
+
children: React.ReactNode;
|
|
14
|
+
anchorRef?: React.ForwardedRef<HTMLAnchorElement>;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* ## TODO
|
|
18
|
+
*
|
|
19
|
+
* - [ ] Handle button styling
|
|
20
|
+
*/
|
|
21
|
+
declare function Link({ children, variant, size, anchorRef, ...rest }: LinkProps): react_jsx_runtime.JSX.Element;
|
|
22
|
+
declare namespace Link {
|
|
23
|
+
var displayName: string;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export { Link, type LinkProps };
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __defProps = Object.defineProperties;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
6
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
8
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
10
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
11
|
+
var __spreadValues = (a, b) => {
|
|
12
|
+
for (var prop in b || (b = {}))
|
|
13
|
+
if (__hasOwnProp.call(b, prop))
|
|
14
|
+
__defNormalProp(a, prop, b[prop]);
|
|
15
|
+
if (__getOwnPropSymbols)
|
|
16
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
17
|
+
if (__propIsEnum.call(b, prop))
|
|
18
|
+
__defNormalProp(a, prop, b[prop]);
|
|
19
|
+
}
|
|
20
|
+
return a;
|
|
21
|
+
};
|
|
22
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
23
|
+
var __objRest = (source, exclude) => {
|
|
24
|
+
var target = {};
|
|
25
|
+
for (var prop in source)
|
|
26
|
+
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
27
|
+
target[prop] = source[prop];
|
|
28
|
+
if (source != null && __getOwnPropSymbols)
|
|
29
|
+
for (var prop of __getOwnPropSymbols(source)) {
|
|
30
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
31
|
+
target[prop] = source[prop];
|
|
32
|
+
}
|
|
33
|
+
return target;
|
|
34
|
+
};
|
|
35
|
+
var __export = (target, all) => {
|
|
36
|
+
for (var name in all)
|
|
37
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
38
|
+
};
|
|
39
|
+
var __copyProps = (to, from, except, desc) => {
|
|
40
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
41
|
+
for (let key of __getOwnPropNames(from))
|
|
42
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
43
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
44
|
+
}
|
|
45
|
+
return to;
|
|
46
|
+
};
|
|
47
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
48
|
+
|
|
49
|
+
// src/link/link.tsx
|
|
50
|
+
var link_exports = {};
|
|
51
|
+
__export(link_exports, {
|
|
52
|
+
Link: () => Link
|
|
53
|
+
});
|
|
54
|
+
module.exports = __toCommonJS(link_exports);
|
|
55
|
+
var import_clsx = require("clsx");
|
|
56
|
+
var import_typed_classname = require("@postenbring/hedwig-css/typed-classname/index.mjs");
|
|
57
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
58
|
+
function Link(_a) {
|
|
59
|
+
var _b = _a, {
|
|
60
|
+
children,
|
|
61
|
+
variant = "underline",
|
|
62
|
+
size = "medium",
|
|
63
|
+
anchorRef
|
|
64
|
+
} = _b, rest = __objRest(_b, [
|
|
65
|
+
"children",
|
|
66
|
+
"variant",
|
|
67
|
+
"size",
|
|
68
|
+
"anchorRef"
|
|
69
|
+
]);
|
|
70
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
71
|
+
"a",
|
|
72
|
+
__spreadProps(__spreadValues({
|
|
73
|
+
className: (0, import_clsx.clsx)(
|
|
74
|
+
(0, import_typed_classname.t)("hds-link"),
|
|
75
|
+
variant !== "underline" && (0, import_typed_classname.t)(`hds-link--${variant}`),
|
|
76
|
+
size !== "medium" && (0, import_typed_classname.t)(`hds-link--${size}`)
|
|
77
|
+
),
|
|
78
|
+
ref: anchorRef
|
|
79
|
+
}, rest), {
|
|
80
|
+
children
|
|
81
|
+
})
|
|
82
|
+
);
|
|
83
|
+
}
|
|
84
|
+
Link.displayName = "Link";
|
|
85
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
86
|
+
0 && (module.exports = {
|
|
87
|
+
Link
|
|
88
|
+
});
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { HTMLAttributes, ReactNode } from 'react';
|
|
3
|
+
|
|
4
|
+
type DescriptionDetailsProps = DLDTProps;
|
|
5
|
+
type DescriptionTermProps = DLDTProps;
|
|
6
|
+
interface DLDTProps extends HTMLAttributes<HTMLBaseElement> {
|
|
7
|
+
children: ReactNode;
|
|
8
|
+
}
|
|
9
|
+
interface DescriptionListProps extends HTMLAttributes<HTMLDListElement> {
|
|
10
|
+
/**
|
|
11
|
+
* Either `DescriptionDetails` or `DescriptionTerm` elements
|
|
12
|
+
*/
|
|
13
|
+
children: ReactNode;
|
|
14
|
+
/**
|
|
15
|
+
* Direction of the description list
|
|
16
|
+
*/
|
|
17
|
+
variant?: "vertical" | "horizontal";
|
|
18
|
+
}
|
|
19
|
+
declare function DescriptionDetails({ children, ...rest }: DescriptionDetailsProps): react_jsx_runtime.JSX.Element;
|
|
20
|
+
declare namespace DescriptionDetails {
|
|
21
|
+
var displayName: string;
|
|
22
|
+
}
|
|
23
|
+
declare function DescriptionTerm({ children, ...rest }: DescriptionTermProps): react_jsx_runtime.JSX.Element;
|
|
24
|
+
declare namespace DescriptionTerm {
|
|
25
|
+
var displayName: string;
|
|
26
|
+
}
|
|
27
|
+
declare function DescriptionList({ variant, ...rest }: DescriptionListProps): react_jsx_runtime.JSX.Element;
|
|
28
|
+
declare namespace DescriptionList {
|
|
29
|
+
var displayName: string;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export { DescriptionDetails, type DescriptionDetailsProps, DescriptionList, type DescriptionListProps, DescriptionTerm, type DescriptionTermProps, DescriptionList as default };
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { HTMLAttributes, ReactNode } from 'react';
|
|
3
|
+
|
|
4
|
+
type DescriptionDetailsProps = DLDTProps;
|
|
5
|
+
type DescriptionTermProps = DLDTProps;
|
|
6
|
+
interface DLDTProps extends HTMLAttributes<HTMLBaseElement> {
|
|
7
|
+
children: ReactNode;
|
|
8
|
+
}
|
|
9
|
+
interface DescriptionListProps extends HTMLAttributes<HTMLDListElement> {
|
|
10
|
+
/**
|
|
11
|
+
* Either `DescriptionDetails` or `DescriptionTerm` elements
|
|
12
|
+
*/
|
|
13
|
+
children: ReactNode;
|
|
14
|
+
/**
|
|
15
|
+
* Direction of the description list
|
|
16
|
+
*/
|
|
17
|
+
variant?: "vertical" | "horizontal";
|
|
18
|
+
}
|
|
19
|
+
declare function DescriptionDetails({ children, ...rest }: DescriptionDetailsProps): react_jsx_runtime.JSX.Element;
|
|
20
|
+
declare namespace DescriptionDetails {
|
|
21
|
+
var displayName: string;
|
|
22
|
+
}
|
|
23
|
+
declare function DescriptionTerm({ children, ...rest }: DescriptionTermProps): react_jsx_runtime.JSX.Element;
|
|
24
|
+
declare namespace DescriptionTerm {
|
|
25
|
+
var displayName: string;
|
|
26
|
+
}
|
|
27
|
+
declare function DescriptionList({ variant, ...rest }: DescriptionListProps): react_jsx_runtime.JSX.Element;
|
|
28
|
+
declare namespace DescriptionList {
|
|
29
|
+
var displayName: string;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export { DescriptionDetails, type DescriptionDetailsProps, DescriptionList, type DescriptionListProps, DescriptionTerm, type DescriptionTermProps, DescriptionList as default };
|