@developer-overheid-nl/don-register-components 1.2.0 → 1.3.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/CHANGELOG.md +130 -85
- package/LICENSE.md +291 -291
- package/README.md +20 -20
- package/package.json +5 -7
- package/src/alert/Alert.tsx +19 -19
- package/src/alert/styles.module.css +3 -3
- package/src/alignBox/AlignBox.tsx +114 -114
- package/src/alignBox/styles.module.css +110 -110
- package/src/amountLabel/AmountLabel.tsx +16 -16
- package/src/amountLabel/styles.module.css +11 -11
- package/src/analytics/PiwikPro.tsx +94 -94
- package/src/analytics/index.ts +1 -1
- package/src/article/Article.tsx +10 -10
- package/src/badgeList/BadgeList.tsx +34 -26
- package/src/badgeList/styles.module.css +37 -24
- package/src/block/Block.tsx +35 -35
- package/src/block/styles.module.css +29 -29
- package/src/button/Button.tsx +3 -3
- package/src/cardAsLink/CardAsLink.tsx +21 -21
- package/src/cardAsLink/styles.module.css +23 -23
- package/src/cardsList/CardsList.tsx +56 -54
- package/src/cardsList/styles.module.css +19 -19
- package/src/client.ts +7 -7
- package/src/container/Container.tsx +10 -10
- package/src/container/styles.module.css +28 -28
- package/src/copyButton/CopyButton.tsx +39 -39
- package/src/copyButton/styles.module.css +13 -13
- package/src/dataBadgeLink/DataBadgeLink.tsx +53 -53
- package/src/dataBadgeLink/styles.module.css +89 -69
- package/src/dataSummary/DataSummary.tsx +22 -22
- package/src/dataSummary/DataSummaryItem.tsx +21 -21
- package/src/dataSummary/styles.module.css +75 -75
- package/src/facetFilters/FacetFilters.tsx +419 -313
- package/src/facetFilters/styles.module.css +3 -3
- package/src/fieldset/FieldSet.tsx +3 -3
- package/src/filters/Filters.tsx +116 -115
- package/src/filters/styles.module.css +26 -26
- package/src/footer/Footer.tsx +76 -76
- package/src/footer/styles.module.css +103 -103
- package/src/formFieldCheckboxGroup/FormFieldCheckboxGroup.tsx +16 -16
- package/src/formFieldCheckboxGroup/styles.module.css +5 -5
- package/src/formFieldCheckboxOption/FormFieldCheckboxOption.tsx +26 -26
- package/src/formFieldCheckboxOption/styles.module.css +22 -22
- package/src/formFieldLabel/FormFieldLabel.tsx +23 -23
- package/src/formFieldRadioGroup/FormFieldRadioGroup.tsx +13 -13
- package/src/formFieldRadioGroup/styles.module.css +5 -5
- package/src/formFieldRadioOption/FormFieldRadioOption.tsx +75 -75
- package/src/formFieldRadioOption/styles.module.css +49 -49
- package/src/formFieldSwitch/FormFieldSwitch.tsx +79 -79
- package/src/formFieldSwitch/styles.module.css +32 -32
- package/src/formFieldTextInput/FormFieldTextInput.tsx +3 -3
- package/src/header/Header.tsx +137 -137
- package/src/header/styles.module.css +71 -71
- package/src/heading/Heading.tsx +15 -15
- package/src/headingGroup/HeadingGroup.tsx +48 -48
- package/src/headingGroup/styles.module.css +3 -3
- package/src/i18n.ts +25 -25
- package/src/iconBadge/IconBadge.tsx +35 -35
- package/src/iconBadge/getAppearance.ts +53 -53
- package/src/iconBadge/styles.module.css +19 -19
- package/src/iconsSprite/Icon.tsx +17 -17
- package/src/iconsSprite/IconsSprite.tsx +5 -5
- package/src/index.ts +107 -106
- package/src/infoButton/InfoButton.tsx +45 -45
- package/src/infoButton/styles.module.css +43 -43
- package/src/link/Link.tsx +10 -10
- package/src/markdown/Markdown.tsx +42 -42
- package/src/overlay/Overlay.tsx +18 -18
- package/src/overlay/styles.module.css +15 -15
- package/src/pagination/Pagination.tsx +267 -144
- package/src/pagination/styles.module.css +28 -13
- package/src/paragraph/Paragraph.tsx +24 -24
- package/src/paragraph/styles.module.css +6 -6
- package/src/pillBadge/PillBadge.examples.tsx +107 -107
- package/src/pillBadge/PillBadge.tsx +51 -51
- package/src/pillBadge/styles.module.css +214 -214
- package/src/readOnlyTextInput/ReadOnlyTextInput.tsx +24 -24
- package/src/readOnlyTextInput/styles.module.css +19 -19
- package/src/scoreBadge/ScoreBadge.tsx +133 -133
- package/src/search/Search.tsx +82 -66
- package/src/search/styles.module.css +39 -39
- package/src/siteLogo/SiteLogo.tsx +24 -24
- package/src/switch/Switch.tsx +86 -86
- package/src/switch/styles.module.css +7 -7
- package/src/toolTip/ToolTip.tsx +55 -55
- package/src/toolTip/styles.module.css +49 -48
- package/src/topNavigation/TopNavigation.tsx +67 -67
- package/src/topNavigation/styles.module.css +54 -54
- package/tsconfig.json +121 -121
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
import clsx from "clsx";
|
|
2
|
-
import type { HTMLProps } from "react";
|
|
3
|
-
import Icon from "../iconsSprite/Icon";
|
|
4
|
-
import styles from "./styles.module.css";
|
|
5
|
-
|
|
6
|
-
export interface IconBadgeProps extends HTMLProps<HTMLSpanElement> {
|
|
7
|
-
name: string;
|
|
8
|
-
appearance?: string;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
* @deprecated API Register specific component (and not used anymore)
|
|
13
|
-
*/
|
|
14
|
-
export default function IconBadge(props: IconBadgeProps) {
|
|
15
|
-
const { className, name, appearance, ...restProps } = props;
|
|
16
|
-
const iconClassName = `don-icon don-icon-${name} ${className || ""}`.trim();
|
|
17
|
-
|
|
18
|
-
return (
|
|
19
|
-
<span
|
|
20
|
-
className={clsx(
|
|
21
|
-
"utrecht-data-badge",
|
|
22
|
-
`utrecht-data-badge--${appearance || name}`,
|
|
23
|
-
styles,
|
|
24
|
-
)}
|
|
25
|
-
{...restProps}
|
|
26
|
-
>
|
|
27
|
-
<Icon
|
|
28
|
-
width="1.5rem"
|
|
29
|
-
height="1.5rem"
|
|
30
|
-
className={`${iconClassName}`}
|
|
31
|
-
name={name}
|
|
32
|
-
/>
|
|
33
|
-
</span>
|
|
34
|
-
);
|
|
35
|
-
}
|
|
1
|
+
import clsx from "clsx";
|
|
2
|
+
import type { HTMLProps } from "react";
|
|
3
|
+
import Icon from "../iconsSprite/Icon";
|
|
4
|
+
import styles from "./styles.module.css";
|
|
5
|
+
|
|
6
|
+
export interface IconBadgeProps extends HTMLProps<HTMLSpanElement> {
|
|
7
|
+
name: string;
|
|
8
|
+
appearance?: string;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* @deprecated API Register specific component (and not used anymore)
|
|
13
|
+
*/
|
|
14
|
+
export default function IconBadge(props: IconBadgeProps) {
|
|
15
|
+
const { className, name, appearance, ...restProps } = props;
|
|
16
|
+
const iconClassName = `don-icon don-icon-${name} ${className || ""}`.trim();
|
|
17
|
+
|
|
18
|
+
return (
|
|
19
|
+
<span
|
|
20
|
+
className={clsx(
|
|
21
|
+
"utrecht-data-badge",
|
|
22
|
+
`utrecht-data-badge--${appearance || name}`,
|
|
23
|
+
styles,
|
|
24
|
+
)}
|
|
25
|
+
{...restProps}
|
|
26
|
+
>
|
|
27
|
+
<Icon
|
|
28
|
+
width="1.5rem"
|
|
29
|
+
height="1.5rem"
|
|
30
|
+
className={`${iconClassName}`}
|
|
31
|
+
name={name}
|
|
32
|
+
/>
|
|
33
|
+
</span>
|
|
34
|
+
);
|
|
35
|
+
}
|
|
@@ -1,53 +1,53 @@
|
|
|
1
|
-
/* biome-ignore-all lint: is deprecated and refactored */
|
|
2
|
-
type status = "active" | "deprecated" | "sunset" | "retired";
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* @deprecated API Register specific function (moved and refactored to `apps/api-register/src/components/`)
|
|
6
|
-
*/
|
|
7
|
-
export function getDate(object?: Partial<Record<"status" | status, any>>) {
|
|
8
|
-
if (!object) return;
|
|
9
|
-
|
|
10
|
-
const keys = Object.keys(object);
|
|
11
|
-
const statuses: status[] = ["deprecated", "sunset"];
|
|
12
|
-
let date;
|
|
13
|
-
|
|
14
|
-
statuses.forEach((status) => {
|
|
15
|
-
if (keys.includes(status) && object[status]) {
|
|
16
|
-
date = object[status];
|
|
17
|
-
}
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
return (
|
|
21
|
-
date &&
|
|
22
|
-
new Date(date).toLocaleDateString("nl-NL", {
|
|
23
|
-
year: "numeric",
|
|
24
|
-
month: "long",
|
|
25
|
-
day: "numeric",
|
|
26
|
-
})
|
|
27
|
-
);
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
/**
|
|
31
|
-
* @deprecated API Register specific function (moved and refactored to `apps/api-register/src/components/`)
|
|
32
|
-
*/
|
|
33
|
-
export default function getAppearance(
|
|
34
|
-
object?: Partial<Record<"status" | status, any>>,
|
|
35
|
-
) {
|
|
36
|
-
if (!object) return;
|
|
37
|
-
|
|
38
|
-
const keys = Object.keys(object);
|
|
39
|
-
const statuses: status[] = ["active", "deprecated", "sunset", "retired"];
|
|
40
|
-
let appearance;
|
|
41
|
-
|
|
42
|
-
statuses.forEach((status) => {
|
|
43
|
-
if (keys.includes(status) && object[status]) {
|
|
44
|
-
// If upcoming status is more serious than current status, use that one
|
|
45
|
-
appearance =
|
|
46
|
-
statuses.indexOf(status) > statuses.indexOf(object.status)
|
|
47
|
-
? status
|
|
48
|
-
: object.status;
|
|
49
|
-
}
|
|
50
|
-
});
|
|
51
|
-
|
|
52
|
-
return appearance;
|
|
53
|
-
}
|
|
1
|
+
/* biome-ignore-all lint: is deprecated and refactored */
|
|
2
|
+
type status = "active" | "deprecated" | "sunset" | "retired";
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* @deprecated API Register specific function (moved and refactored to `apps/api-register/src/components/`)
|
|
6
|
+
*/
|
|
7
|
+
export function getDate(object?: Partial<Record<"status" | status, any>>) {
|
|
8
|
+
if (!object) return;
|
|
9
|
+
|
|
10
|
+
const keys = Object.keys(object);
|
|
11
|
+
const statuses: status[] = ["deprecated", "sunset"];
|
|
12
|
+
let date;
|
|
13
|
+
|
|
14
|
+
statuses.forEach((status) => {
|
|
15
|
+
if (keys.includes(status) && object[status]) {
|
|
16
|
+
date = object[status];
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
return (
|
|
21
|
+
date &&
|
|
22
|
+
new Date(date).toLocaleDateString("nl-NL", {
|
|
23
|
+
year: "numeric",
|
|
24
|
+
month: "long",
|
|
25
|
+
day: "numeric",
|
|
26
|
+
})
|
|
27
|
+
);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* @deprecated API Register specific function (moved and refactored to `apps/api-register/src/components/`)
|
|
32
|
+
*/
|
|
33
|
+
export default function getAppearance(
|
|
34
|
+
object?: Partial<Record<"status" | status, any>>,
|
|
35
|
+
) {
|
|
36
|
+
if (!object) return;
|
|
37
|
+
|
|
38
|
+
const keys = Object.keys(object);
|
|
39
|
+
const statuses: status[] = ["active", "deprecated", "sunset", "retired"];
|
|
40
|
+
let appearance;
|
|
41
|
+
|
|
42
|
+
statuses.forEach((status) => {
|
|
43
|
+
if (keys.includes(status) && object[status]) {
|
|
44
|
+
// If upcoming status is more serious than current status, use that one
|
|
45
|
+
appearance =
|
|
46
|
+
statuses.indexOf(status) > statuses.indexOf(object.status)
|
|
47
|
+
? status
|
|
48
|
+
: object.status;
|
|
49
|
+
}
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
return appearance;
|
|
53
|
+
}
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
:global(.utrecht-data-badge--active) {
|
|
2
|
-
--utrecht-data-badge-background-color: var(--rhc-color-groen-100);
|
|
3
|
-
--utrecht-data-badge-color: var(--rhc-color-groen-500);
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
:global(.utrecht-data-badge--deprecated) {
|
|
7
|
-
--utrecht-data-badge-background-color: var(--rhc-color-donkergeel-100);
|
|
8
|
-
--utrecht-data-badge-color: var(--rhc-color-donkergeel-500);
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
:global(.utrecht-data-badge--sunset) {
|
|
12
|
-
--utrecht-data-badge-background-color: var(--rhc-color-oranje-100);
|
|
13
|
-
--utrecht-data-badge-color: var(--rhc-color-oranje-500);
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
:global(.utrecht-data-badge--retired) {
|
|
17
|
-
--utrecht-data-badge-background-color: var(--rhc-color-rood-100);
|
|
18
|
-
--utrecht-data-badge-color: var(--rhc-color-rood-500);
|
|
19
|
-
}
|
|
1
|
+
:global(.utrecht-data-badge--active) {
|
|
2
|
+
--utrecht-data-badge-background-color: var(--rhc-color-groen-100);
|
|
3
|
+
--utrecht-data-badge-color: var(--rhc-color-groen-500);
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
:global(.utrecht-data-badge--deprecated) {
|
|
7
|
+
--utrecht-data-badge-background-color: var(--rhc-color-donkergeel-100);
|
|
8
|
+
--utrecht-data-badge-color: var(--rhc-color-donkergeel-500);
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
:global(.utrecht-data-badge--sunset) {
|
|
12
|
+
--utrecht-data-badge-background-color: var(--rhc-color-oranje-100);
|
|
13
|
+
--utrecht-data-badge-color: var(--rhc-color-oranje-500);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
:global(.utrecht-data-badge--retired) {
|
|
17
|
+
--utrecht-data-badge-background-color: var(--rhc-color-rood-100);
|
|
18
|
+
--utrecht-data-badge-color: var(--rhc-color-rood-500);
|
|
19
|
+
}
|
package/src/iconsSprite/Icon.tsx
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
export default function Icon(props: React.HTMLProps<SVGSVGElement>) {
|
|
2
|
-
const { className, name, ...restProps } = props;
|
|
3
|
-
const iconClassName = `don-icon don-icon-${name} ${className || ""}`.trim();
|
|
4
|
-
|
|
5
|
-
return (
|
|
6
|
-
<svg
|
|
7
|
-
width="1rem"
|
|
8
|
-
height="1rem"
|
|
9
|
-
className={`${iconClassName}`}
|
|
10
|
-
role={props.role || "img"}
|
|
11
|
-
aria-label={props["aria-label"]}
|
|
12
|
-
{...restProps}
|
|
13
|
-
>
|
|
14
|
-
<use href={`#icon-${name}`} />
|
|
15
|
-
</svg>
|
|
16
|
-
);
|
|
17
|
-
}
|
|
1
|
+
export default function Icon(props: React.HTMLProps<SVGSVGElement>) {
|
|
2
|
+
const { className, name, ...restProps } = props;
|
|
3
|
+
const iconClassName = `don-icon don-icon-${name} ${className || ""}`.trim();
|
|
4
|
+
|
|
5
|
+
return (
|
|
6
|
+
<svg
|
|
7
|
+
width="1rem"
|
|
8
|
+
height="1rem"
|
|
9
|
+
className={`${iconClassName}`}
|
|
10
|
+
role={props.role || "img"}
|
|
11
|
+
aria-label={props["aria-label"]}
|
|
12
|
+
{...restProps}
|
|
13
|
+
>
|
|
14
|
+
<use href={`#icon-${name}`} />
|
|
15
|
+
</svg>
|
|
16
|
+
);
|
|
17
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Sprite } from "@developer-overheid-nl/proprietary/icons";
|
|
2
|
-
|
|
3
|
-
export default function IconsSprite() {
|
|
4
|
-
return <Sprite />;
|
|
5
|
-
}
|
|
1
|
+
import { Sprite } from "@developer-overheid-nl/proprietary/icons";
|
|
2
|
+
|
|
3
|
+
export default function IconsSprite() {
|
|
4
|
+
return <Sprite />;
|
|
5
|
+
}
|
package/src/index.ts
CHANGED
|
@@ -1,106 +1,107 @@
|
|
|
1
|
-
// Barrel export for all components
|
|
2
|
-
export { type AlertProps, default as Alert } from "./alert/Alert";
|
|
3
|
-
export { type AlignBoxProps, default as AlignBox } from "./alignBox/AlignBox";
|
|
4
|
-
export { default as Article } from "./article/Article";
|
|
5
|
-
export {
|
|
6
|
-
type BadgeListProps,
|
|
7
|
-
default as BadgeList,
|
|
8
|
-
} from "./badgeList/BadgeList";
|
|
9
|
-
export { type BlockProps, default as Block } from "./block/Block";
|
|
10
|
-
export { default as Button } from "./button/Button";
|
|
11
|
-
export {
|
|
12
|
-
type CardAsLinksProps,
|
|
13
|
-
default as CardAsLink,
|
|
14
|
-
} from "./cardAsLink/CardAsLink";
|
|
15
|
-
export {
|
|
16
|
-
CardsListItem,
|
|
17
|
-
type CardsListItemProps,
|
|
18
|
-
type CardsListProps,
|
|
19
|
-
default as CardsList,
|
|
20
|
-
} from "./cardsList/CardsList";
|
|
21
|
-
export { default as Container } from "./container/Container";
|
|
22
|
-
export { default as CopyButton } from "./copyButton/CopyButton"; // client component
|
|
23
|
-
export {
|
|
24
|
-
type DataBadgeLinkProps,
|
|
25
|
-
default as DataBadgeLink,
|
|
26
|
-
} from "./dataBadgeLink/DataBadgeLink";
|
|
27
|
-
export {
|
|
28
|
-
type DataSummaryProps,
|
|
29
|
-
default as DataSummary,
|
|
30
|
-
} from "./dataSummary/DataSummary";
|
|
31
|
-
export {
|
|
32
|
-
type DataSummaryItemProps,
|
|
33
|
-
default as DataSummaryItem,
|
|
34
|
-
} from "./dataSummary/DataSummaryItem";
|
|
35
|
-
export {
|
|
36
|
-
default as FacetFilters,
|
|
37
|
-
type FacetFiltersProps,
|
|
38
|
-
type FilterData,
|
|
39
|
-
getSelectedFilters,
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
export { default as
|
|
43
|
-
export {
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
export { default as
|
|
50
|
-
export { default as
|
|
51
|
-
export { default as
|
|
52
|
-
export { default as
|
|
53
|
-
export { default as
|
|
54
|
-
export { default as
|
|
55
|
-
export { default as
|
|
56
|
-
export {
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
export {
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
export { default as
|
|
72
|
-
export {
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
export {
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
type
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
export {
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
export {
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
export {
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
export { default as
|
|
99
|
-
export { default as
|
|
100
|
-
export { default as
|
|
101
|
-
export {
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
1
|
+
// Barrel export for all components
|
|
2
|
+
export { type AlertProps, default as Alert } from "./alert/Alert";
|
|
3
|
+
export { type AlignBoxProps, default as AlignBox } from "./alignBox/AlignBox";
|
|
4
|
+
export { default as Article } from "./article/Article";
|
|
5
|
+
export {
|
|
6
|
+
type BadgeListProps,
|
|
7
|
+
default as BadgeList,
|
|
8
|
+
} from "./badgeList/BadgeList";
|
|
9
|
+
export { type BlockProps, default as Block } from "./block/Block";
|
|
10
|
+
export { default as Button } from "./button/Button";
|
|
11
|
+
export {
|
|
12
|
+
type CardAsLinksProps,
|
|
13
|
+
default as CardAsLink,
|
|
14
|
+
} from "./cardAsLink/CardAsLink";
|
|
15
|
+
export {
|
|
16
|
+
CardsListItem,
|
|
17
|
+
type CardsListItemProps,
|
|
18
|
+
type CardsListProps,
|
|
19
|
+
default as CardsList,
|
|
20
|
+
} from "./cardsList/CardsList";
|
|
21
|
+
export { default as Container } from "./container/Container";
|
|
22
|
+
export { default as CopyButton } from "./copyButton/CopyButton"; // client component
|
|
23
|
+
export {
|
|
24
|
+
type DataBadgeLinkProps,
|
|
25
|
+
default as DataBadgeLink,
|
|
26
|
+
} from "./dataBadgeLink/DataBadgeLink";
|
|
27
|
+
export {
|
|
28
|
+
type DataSummaryProps,
|
|
29
|
+
default as DataSummary,
|
|
30
|
+
} from "./dataSummary/DataSummary";
|
|
31
|
+
export {
|
|
32
|
+
type DataSummaryItemProps,
|
|
33
|
+
default as DataSummaryItem,
|
|
34
|
+
} from "./dataSummary/DataSummaryItem";
|
|
35
|
+
export {
|
|
36
|
+
default as FacetFilters,
|
|
37
|
+
type FacetFiltersProps,
|
|
38
|
+
type FilterData,
|
|
39
|
+
getSelectedFilters,
|
|
40
|
+
getSelectedFiltersMap,
|
|
41
|
+
} from "./facetFilters/FacetFilters";
|
|
42
|
+
export { default as Fieldset } from "./fieldset/FieldSet";
|
|
43
|
+
export { default as Filters } from "./filters/Filters";
|
|
44
|
+
export {
|
|
45
|
+
type ColumnProps,
|
|
46
|
+
default as Footer,
|
|
47
|
+
type FooterProps,
|
|
48
|
+
} from "./footer/Footer";
|
|
49
|
+
export { default as FormFieldCheckboxGroup } from "./formFieldCheckboxGroup/FormFieldCheckboxGroup";
|
|
50
|
+
export { default as FormFieldCheckboxOption } from "./formFieldCheckboxOption/FormFieldCheckboxOption";
|
|
51
|
+
export { default as FormFieldLabel } from "./formFieldLabel/FormFieldLabel";
|
|
52
|
+
export { default as FormFieldRadioGroup } from "./formFieldRadioGroup/FormFieldRadioGroup";
|
|
53
|
+
export { default as FormFieldRadioOption } from "./formFieldRadioOption/FormFieldRadioOption";
|
|
54
|
+
export { default as FormFieldSwitch } from "./formFieldSwitch/FormFieldSwitch";
|
|
55
|
+
export { default as FormFieldTextInput } from "./formFieldTextInput/FormFieldTextInput";
|
|
56
|
+
export { default as Header, type HeaderProps } from "./header/Header";
|
|
57
|
+
export {
|
|
58
|
+
clampHeadingLevel,
|
|
59
|
+
default as Heading,
|
|
60
|
+
type HeadingProps,
|
|
61
|
+
} from "./heading/Heading";
|
|
62
|
+
export {
|
|
63
|
+
default as HeadingGroup,
|
|
64
|
+
type HeadingGroupProps,
|
|
65
|
+
} from "./headingGroup/HeadingGroup";
|
|
66
|
+
export { default as getAppearance, getDate } from "./iconBadge/getAppearance";
|
|
67
|
+
export {
|
|
68
|
+
default as IconBadge,
|
|
69
|
+
type IconBadgeProps,
|
|
70
|
+
} from "./iconBadge/IconBadge";
|
|
71
|
+
export { default as Icon } from "./iconsSprite/Icon";
|
|
72
|
+
export { default as IconsSprite } from "./iconsSprite/IconsSprite";
|
|
73
|
+
export {
|
|
74
|
+
default as InfoButton,
|
|
75
|
+
type InfoButtonProps,
|
|
76
|
+
} from "./infoButton/InfoButton";
|
|
77
|
+
export { default as Link } from "./link/Link";
|
|
78
|
+
export {
|
|
79
|
+
default as Markdown,
|
|
80
|
+
type HeadingLevels,
|
|
81
|
+
type MarkdownProps,
|
|
82
|
+
} from "./markdown/Markdown";
|
|
83
|
+
export { default as Overlay } from "./overlay/Overlay";
|
|
84
|
+
export {
|
|
85
|
+
default as Pagination,
|
|
86
|
+
type PaginationProps,
|
|
87
|
+
} from "./pagination/Pagination";
|
|
88
|
+
export { default as Paragraph } from "./paragraph/Paragraph";
|
|
89
|
+
export {
|
|
90
|
+
default as PillBadge,
|
|
91
|
+
type PillBadgeProps,
|
|
92
|
+
} from "./pillBadge/PillBadge";
|
|
93
|
+
export { default as ReadOnlyTextInput } from "./readOnlyTextInput/ReadOnlyTextInput";
|
|
94
|
+
export {
|
|
95
|
+
default as ScoreBadge,
|
|
96
|
+
type ScoreBadgeProps,
|
|
97
|
+
} from "./scoreBadge/ScoreBadge";
|
|
98
|
+
export { default as Search, type SearchProps } from "./search/Search";
|
|
99
|
+
export { default as SiteLogo } from "./siteLogo/SiteLogo";
|
|
100
|
+
export { default as Switch, type SwitchProps } from "./switch/Switch";
|
|
101
|
+
export { default as ToolTip } from "./toolTip/ToolTip";
|
|
102
|
+
export {
|
|
103
|
+
default as TopNavigation,
|
|
104
|
+
type NavBarItem,
|
|
105
|
+
processNavBarItems,
|
|
106
|
+
type TopNavigationProps,
|
|
107
|
+
} from "./topNavigation/TopNavigation";
|
|
@@ -1,45 +1,45 @@
|
|
|
1
|
-
import clsx from "clsx";
|
|
2
|
-
import type { ButtonHTMLAttributes, HTMLProps } from "react";
|
|
3
|
-
import Icon from "../iconsSprite/Icon";
|
|
4
|
-
import styles from "./styles.module.css";
|
|
5
|
-
|
|
6
|
-
export interface InfoButtonProps extends HTMLProps<HTMLButtonElement> {
|
|
7
|
-
iconSize?: "small" | "default" | "large";
|
|
8
|
-
iconColor?: "default" | "current";
|
|
9
|
-
type?: ButtonHTMLAttributes<HTMLButtonElement>["type"];
|
|
10
|
-
commandfor?: string;
|
|
11
|
-
command?:
|
|
12
|
-
| "show-modal"
|
|
13
|
-
| "close"
|
|
14
|
-
| "request-close"
|
|
15
|
-
| "show-popover"
|
|
16
|
-
| "hide-popover"
|
|
17
|
-
| "toggle-popover"
|
|
18
|
-
| `--${string}`;
|
|
19
|
-
interestfor?: string;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
const InfoButton = (props: InfoButtonProps) => {
|
|
23
|
-
const {
|
|
24
|
-
iconSize = "default",
|
|
25
|
-
iconColor = "default",
|
|
26
|
-
type = "button",
|
|
27
|
-
...restProps
|
|
28
|
-
} = props;
|
|
29
|
-
|
|
30
|
-
return (
|
|
31
|
-
<button
|
|
32
|
-
className={clsx(
|
|
33
|
-
styles.infoButton,
|
|
34
|
-
styles[`${iconSize}Size`],
|
|
35
|
-
styles[`${iconColor}Color`],
|
|
36
|
-
)}
|
|
37
|
-
type={type}
|
|
38
|
-
{...restProps}
|
|
39
|
-
>
|
|
40
|
-
<Icon name="info" />
|
|
41
|
-
</button>
|
|
42
|
-
);
|
|
43
|
-
};
|
|
44
|
-
|
|
45
|
-
export default InfoButton;
|
|
1
|
+
import clsx from "clsx";
|
|
2
|
+
import type { ButtonHTMLAttributes, HTMLProps } from "react";
|
|
3
|
+
import Icon from "../iconsSprite/Icon";
|
|
4
|
+
import styles from "./styles.module.css";
|
|
5
|
+
|
|
6
|
+
export interface InfoButtonProps extends HTMLProps<HTMLButtonElement> {
|
|
7
|
+
iconSize?: "small" | "default" | "large";
|
|
8
|
+
iconColor?: "default" | "current";
|
|
9
|
+
type?: ButtonHTMLAttributes<HTMLButtonElement>["type"];
|
|
10
|
+
commandfor?: string;
|
|
11
|
+
command?:
|
|
12
|
+
| "show-modal"
|
|
13
|
+
| "close"
|
|
14
|
+
| "request-close"
|
|
15
|
+
| "show-popover"
|
|
16
|
+
| "hide-popover"
|
|
17
|
+
| "toggle-popover"
|
|
18
|
+
| `--${string}`;
|
|
19
|
+
interestfor?: string;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
const InfoButton = (props: InfoButtonProps) => {
|
|
23
|
+
const {
|
|
24
|
+
iconSize = "default",
|
|
25
|
+
iconColor = "default",
|
|
26
|
+
type = "button",
|
|
27
|
+
...restProps
|
|
28
|
+
} = props;
|
|
29
|
+
|
|
30
|
+
return (
|
|
31
|
+
<button
|
|
32
|
+
className={clsx(
|
|
33
|
+
styles.infoButton,
|
|
34
|
+
styles[`${iconSize}Size`],
|
|
35
|
+
styles[`${iconColor}Color`],
|
|
36
|
+
)}
|
|
37
|
+
type={type}
|
|
38
|
+
{...restProps}
|
|
39
|
+
>
|
|
40
|
+
<Icon name="info" />
|
|
41
|
+
</button>
|
|
42
|
+
);
|
|
43
|
+
};
|
|
44
|
+
|
|
45
|
+
export default InfoButton;
|
|
@@ -1,43 +1,43 @@
|
|
|
1
|
-
:root {
|
|
2
|
-
--don-info-button-color: var(--rhc-color-hemelblauw-500);
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
.infoButton {
|
|
6
|
-
display: grid;
|
|
7
|
-
place-content: center;
|
|
8
|
-
padding: 0;
|
|
9
|
-
margin: 0;
|
|
10
|
-
appearance: none;
|
|
11
|
-
cursor: pointer;
|
|
12
|
-
background: none;
|
|
13
|
-
border: none;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.defaultColor {
|
|
17
|
-
color: var(--don-info-button-color, currentColor);
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
.currentColor {
|
|
21
|
-
color: currentColor;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
.smallSize {
|
|
25
|
-
svg {
|
|
26
|
-
width: 1rem;
|
|
27
|
-
height: 1rem;
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
.defaultSize {
|
|
32
|
-
svg {
|
|
33
|
-
width: 1.5rem;
|
|
34
|
-
height: 1.5rem;
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
.largeSize {
|
|
39
|
-
svg {
|
|
40
|
-
width: 2rem;
|
|
41
|
-
height: 2rem;
|
|
42
|
-
}
|
|
43
|
-
}
|
|
1
|
+
:root {
|
|
2
|
+
--don-info-button-color: var(--rhc-color-hemelblauw-500);
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.infoButton {
|
|
6
|
+
display: grid;
|
|
7
|
+
place-content: center;
|
|
8
|
+
padding: 0;
|
|
9
|
+
margin: 0;
|
|
10
|
+
appearance: none;
|
|
11
|
+
cursor: pointer;
|
|
12
|
+
background: none;
|
|
13
|
+
border: none;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.defaultColor {
|
|
17
|
+
color: var(--don-info-button-color, currentColor);
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.currentColor {
|
|
21
|
+
color: currentColor;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.smallSize {
|
|
25
|
+
svg {
|
|
26
|
+
width: 1rem;
|
|
27
|
+
height: 1rem;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.defaultSize {
|
|
32
|
+
svg {
|
|
33
|
+
width: 1.5rem;
|
|
34
|
+
height: 1.5rem;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.largeSize {
|
|
39
|
+
svg {
|
|
40
|
+
width: 2rem;
|
|
41
|
+
height: 2rem;
|
|
42
|
+
}
|
|
43
|
+
}
|