@conduction/components 2.2.22 → 2.2.23

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.
Files changed (167) hide show
  1. package/.prettierrc +30 -30
  2. package/README.md +1 -0
  3. package/lib/components/Pagination/Pagination.d.ts +14 -14
  4. package/lib/components/Pagination/Pagination.js +12 -12
  5. package/lib/components/badgeCounter/BadgeCounter.d.ts +8 -8
  6. package/lib/components/badgeCounter/BadgeCounter.js +4 -4
  7. package/lib/components/badgeCounter/BadgeCounter.module.css +27 -27
  8. package/lib/components/card/cardHeader/CardHeader.d.ts +4 -4
  9. package/lib/components/card/cardHeader/CardHeader.js +14 -14
  10. package/lib/components/card/cardWrapper/CardWrapper.d.ts +2 -2
  11. package/lib/components/card/cardWrapper/CardWrapper.js +6 -6
  12. package/lib/components/card/detailsCard/DetailsCard.d.ts +14 -14
  13. package/lib/components/card/detailsCard/DetailsCard.js +11 -11
  14. package/lib/components/card/downloadCard/DownloadCard.d.ts +11 -11
  15. package/lib/components/card/downloadCard/DownloadCard.js +9 -9
  16. package/lib/components/card/horizontalImageCard/HorizontalImageCard.d.ts +13 -13
  17. package/lib/components/card/horizontalImageCard/HorizontalImageCard.js +10 -10
  18. package/lib/components/card/imageAndDetailsCard/ImageAndDetailsCard.d.ts +14 -14
  19. package/lib/components/card/imageAndDetailsCard/ImageAndDetailsCard.js +10 -10
  20. package/lib/components/card/index.d.ts +8 -8
  21. package/lib/components/card/index.js +8 -8
  22. package/lib/components/card/infoCard/InfoCard.d.ts +8 -8
  23. package/lib/components/card/infoCard/InfoCard.js +6 -6
  24. package/lib/components/card/infoCard/InfoCard.module.css +26 -26
  25. package/lib/components/card/richContentCard/RichContentCard.d.ts +19 -19
  26. package/lib/components/card/richContentCard/RichContentCard.js +16 -15
  27. package/lib/components/card/richContentCard/RichContentCard.module.css +93 -103
  28. package/lib/components/codeBlock/CodeBlock.d.ts +6 -6
  29. package/lib/components/codeBlock/CodeBlock.js +3 -3
  30. package/lib/components/codeBlock/CodeBlock.module.css +6 -6
  31. package/lib/components/container/Container.d.ts +6 -6
  32. package/lib/components/container/Container.js +4 -4
  33. package/lib/components/denhaag-wrappers/breadcrumbs/Breadcrumbs.css +222 -222
  34. package/lib/components/denhaag-wrappers/breadcrumbs/Breadcrumbs.d.ts +17 -17
  35. package/lib/components/denhaag-wrappers/breadcrumbs/Breadcrumbs.js +20 -20
  36. package/lib/components/denhaag-wrappers/pagination/Pagination.css +120 -120
  37. package/lib/components/denhaag-wrappers/pagination/Pagination.d.ts +9 -9
  38. package/lib/components/denhaag-wrappers/pagination/Pagination.js +15 -15
  39. package/lib/components/editableTableRow/EditableTableRow.d.ts +14 -14
  40. package/lib/components/editableTableRow/EditableTableRow.js +31 -31
  41. package/lib/components/editableTableRow/EditableTableRow.module.css +25 -25
  42. package/lib/components/formFields/checkbox/Checkbox.module.css +7 -7
  43. package/lib/components/formFields/checkbox/checkbox.d.ts +9 -9
  44. package/lib/components/formFields/checkbox/checkbox.js +3 -3
  45. package/lib/components/formFields/createKeyValue/CreateKeyValue.d.ts +23 -23
  46. package/lib/components/formFields/createKeyValue/CreateKeyValue.js +40 -40
  47. package/lib/components/formFields/date/Date.d.ts +12 -12
  48. package/lib/components/formFields/date/Date.js +10 -10
  49. package/lib/components/formFields/date/Date.module.css +12 -12
  50. package/lib/components/formFields/errorMessage/ErrorMessage.d.ts +5 -5
  51. package/lib/components/formFields/errorMessage/ErrorMessage.js +3 -3
  52. package/lib/components/formFields/index.d.ts +7 -7
  53. package/lib/components/formFields/index.js +7 -7
  54. package/lib/components/formFields/input.d.ts +22 -22
  55. package/lib/components/formFields/input.js +12 -12
  56. package/lib/components/formFields/radio.d.ts +9 -9
  57. package/lib/components/formFields/radio.js +3 -3
  58. package/lib/components/formFields/select/select.d.ts +24 -24
  59. package/lib/components/formFields/select/select.js +74 -74
  60. package/lib/components/formFields/textarea.d.ts +10 -10
  61. package/lib/components/formFields/textarea.js +4 -4
  62. package/lib/components/formFields/types.d.ts +6 -6
  63. package/lib/components/formFields/types.js +1 -1
  64. package/lib/components/horizontalOverflowWrapper/HorizontalOverflowWrapper.d.ts +10 -10
  65. package/lib/components/horizontalOverflowWrapper/HorizontalOverflowWrapper.js +36 -36
  66. package/lib/components/imageDivider/ImageDivider.d.ts +7 -7
  67. package/lib/components/imageDivider/ImageDivider.js +6 -6
  68. package/lib/components/imageDivider/imageDivider.module.css +5 -5
  69. package/lib/components/jumbotron/Jumbotron.d.ts +23 -23
  70. package/lib/components/jumbotron/Jumbotron.js +34 -34
  71. package/lib/components/logo/Logo.d.ts +8 -8
  72. package/lib/components/logo/Logo.js +9 -10
  73. package/lib/components/logo/Logo.module.css +31 -15
  74. package/lib/components/metaIcon/MetaIcon.d.ts +7 -7
  75. package/lib/components/metaIcon/MetaIcon.js +3 -3
  76. package/lib/components/metaIcon/MetaIcon.module.css +29 -29
  77. package/lib/components/notificationPopUp/NotificationPopUp.d.ts +26 -26
  78. package/lib/components/notificationPopUp/NotificationPopUp.js +32 -32
  79. package/lib/components/privateRoute/PrivateRoute.d.ts +6 -6
  80. package/lib/components/privateRoute/PrivateRoute.js +15 -15
  81. package/lib/components/quoteWrapper/QuoteWrapper.d.ts +7 -7
  82. package/lib/components/quoteWrapper/QuoteWrapper.js +5 -5
  83. package/lib/components/quoteWrapper/QuoteWrapper.module.css +12 -12
  84. package/lib/components/tabs/Tabs.d.ts +5 -5
  85. package/lib/components/tabs/Tabs.js +49 -49
  86. package/lib/components/tag/Tag.d.ts +10 -10
  87. package/lib/components/tag/Tag.js +6 -6
  88. package/lib/components/tag/Tag.module.css +44 -44
  89. package/lib/components/toolTip/ToolTip.d.ts +14 -14
  90. package/lib/components/toolTip/ToolTip.js +14 -14
  91. package/lib/components/topNav/index.d.ts +3 -3
  92. package/lib/components/topNav/index.js +3 -3
  93. package/lib/components/topNav/primaryTopNav/PrimaryTopNav.d.ts +39 -39
  94. package/lib/components/topNav/primaryTopNav/PrimaryTopNav.js +23 -23
  95. package/lib/components/topNav/secondaryTopNav/SecondaryTopNav.d.ts +12 -12
  96. package/lib/components/topNav/secondaryTopNav/SecondaryTopNav.js +7 -7
  97. package/lib/index.d.ts +28 -28
  98. package/lib/index.js +21 -21
  99. package/package.json +1 -1
  100. package/src/components/badgeCounter/BadgeCounter.module.css +27 -27
  101. package/src/components/card/infoCard/InfoCard.module.css +26 -26
  102. package/src/components/codeBlock/CodeBlock.module.css +6 -6
  103. package/src/components/denhaag-wrappers/breadcrumbs/Breadcrumbs.css +222 -222
  104. package/src/components/formFields/checkbox/Checkbox.module.css +7 -7
  105. package/src/components/formFields/date/Date.module.css +12 -12
  106. package/src/components/imageDivider/imageDivider.module.css +5 -5
  107. package/src/components/logo/Logo.module.css +31 -15
  108. package/src/components/logo/Logo.tsx +12 -16
  109. package/src/components/metaIcon/MetaIcon.module.css +29 -29
  110. package/src/components/quoteWrapper/QuoteWrapper.module.css +12 -12
  111. package/src/components/tag/Tag.module.css +44 -44
  112. package/src/components/topNav/index.ts +4 -4
  113. package/src/custom.d.ts +4 -4
  114. package/src/index.ts +2 -3
  115. package/lib/components/htmlParser/ParsedHTML.d.ts +0 -10
  116. package/lib/components/htmlParser/ParsedHTML.js +0 -17
  117. package/lib/components/htmlParser/ParsedHTML.module.css +0 -7
  118. package/lib/components/htmlParser/parser/alert/getAlert.d.ts +0 -1
  119. package/lib/components/htmlParser/parser/alert/getAlert.js +0 -18
  120. package/lib/components/htmlParser/parser/alert/getAlert.module.css +0 -28
  121. package/lib/components/htmlParser/parser/anchor/getAnchor.d.ts +0 -2
  122. package/lib/components/htmlParser/parser/anchor/getAnchor.js +0 -74
  123. package/lib/components/htmlParser/parser/code/getCode.d.ts +0 -1
  124. package/lib/components/htmlParser/parser/code/getCode.js +0 -11
  125. package/lib/components/htmlParser/parser/getBlockquote/getBlockquote.d.ts +0 -1
  126. package/lib/components/htmlParser/parser/getBlockquote/getBlockquote.js +0 -6
  127. package/lib/components/htmlParser/parser/header/getHeader.d.ts +0 -1
  128. package/lib/components/htmlParser/parser/header/getHeader.js +0 -15
  129. package/lib/components/htmlParser/parser/image/getImage.d.ts +0 -1
  130. package/lib/components/htmlParser/parser/image/getImage.js +0 -28
  131. package/lib/components/htmlParser/parser/list/getList.d.ts +0 -1
  132. package/lib/components/htmlParser/parser/list/getList.js +0 -12
  133. package/lib/components/htmlParser/parser/list/getList.module.css +0 -3
  134. package/lib/components/htmlParser/parser/listItem/getListItem.d.ts +0 -1
  135. package/lib/components/htmlParser/parser/listItem/getListItem.js +0 -12
  136. package/lib/components/htmlParser/parser/paragraph/getParagraph.d.ts +0 -1
  137. package/lib/components/htmlParser/parser/paragraph/getParagraph.js +0 -6
  138. package/lib/components/htmlParser/parser/svg/getSvg.d.ts +0 -1
  139. package/lib/components/htmlParser/parser/svg/getSvg.js +0 -8
  140. package/lib/components/htmlParser/parser/table/getTable.d.ts +0 -1
  141. package/lib/components/htmlParser/parser/table/getTable.js +0 -7
  142. package/lib/components/htmlParser/parser/table/getTable.module.css +0 -3
  143. package/lib/components/htmlParser/parser/tableBody/getTableBody.d.ts +0 -1
  144. package/lib/components/htmlParser/parser/tableBody/getTableBody.js +0 -7
  145. package/lib/components/htmlParser/parser/tableBody/getTableBody.module.css +0 -3
  146. package/lib/components/htmlParser/parser/tableCell/getTableCell.d.ts +0 -1
  147. package/lib/components/htmlParser/parser/tableCell/getTableCell.js +0 -7
  148. package/lib/components/htmlParser/parser/tableCell/getTableCell.module.css +0 -3
  149. package/lib/components/htmlParser/parser/tableHeader/getTableHeader.d.ts +0 -1
  150. package/lib/components/htmlParser/parser/tableHeader/getTableHeader.js +0 -7
  151. package/lib/components/htmlParser/parser/tableHeader/getTableHeader.module.css +0 -28
  152. package/lib/components/htmlParser/parser/tableHeaderCell/getTableHeaderCell.d.ts +0 -1
  153. package/lib/components/htmlParser/parser/tableHeaderCell/getTableHeaderCell.js +0 -6
  154. package/lib/components/htmlParser/parser/tableRow/getTableRow.d.ts +0 -1
  155. package/lib/components/htmlParser/parser/tableRow/getTableRow.js +0 -7
  156. package/lib/components/htmlParser/parser/tableRow/getTableRow.module.css +0 -29
  157. package/lib/components/htmlParser/parser/useHtmlParser.d.ts +0 -5
  158. package/lib/components/htmlParser/parser/useHtmlParser.js +0 -78
  159. package/lib/components/htmlParser/useGitHubDirectories.d.ts +0 -10
  160. package/lib/components/htmlParser/useGitHubDirectories.js +0 -31
  161. package/lib/components/statusSteps/StatusSteps.d.ts +0 -13
  162. package/lib/components/statusSteps/StatusSteps.js +0 -5
  163. package/lib/components/tableWrapper/TableWrapper.d.ts +0 -4
  164. package/lib/components/tableWrapper/TableWrapper.js +0 -30
  165. package/lib/components/tableWrapper/TableWrapper.module.css +0 -67
  166. package/lib/custom.d copy.d.ts +0 -5
  167. package/lib/custom.d copy.js +0 -1
@@ -1,120 +1,120 @@
1
- .denhaag-pagination {
2
- --denhaag-pagination-align: center;
3
-
4
- align-items: center;
5
- display: flex;
6
- flex-direction: row;
7
- justify-content: var(--denhaag-pagination-align);
8
- }
9
-
10
- @media (min-width: 640px) {
11
- .denhaag-pagination,
12
- .denhaag-pagination--start {
13
- --denhaag-pagination-align: flex-start;
14
- }
15
-
16
- .denhaag-pagination--center {
17
- --denhaag-pagination-align: center;
18
- }
19
-
20
- .denhaag-pagination--end {
21
- --denhaag-pagination-align: end;
22
- }
23
- }
24
-
25
- .denhaag-pagination__links {
26
- display: flex;
27
- flex-direction: row;
28
- }
29
-
30
- .denhaag-pagination__link {
31
- aspect-ratio: 1 / 1;
32
- align-items: center;
33
- background-color: var(--denhaag-pagination-background-color, transparent);
34
- border: 0;
35
- border-radius: var(
36
- --denhaag-pagination-border-radius,
37
- var(--denhaag-border-radius)
38
- );
39
- color: var(--denhaag-pagination-color, var(--denhaag-pagination-link-color));
40
- display: flex;
41
- height: var(--denhaag-pagination-size);
42
- justify-content: center;
43
- line-height: 1.5;
44
- position: relative;
45
- text-align: center;
46
- text-decoration: none;
47
- width: var(--denhaag-pagination-size);
48
- font-style: normal;
49
- font-weight: var(--denhaag-pagination-font-weight);
50
- font-size: var(--denhaag-pagination-font-size);
51
- }
52
-
53
- .denhaag-pagination__link:hover,
54
- .denhaag-pagination__link--hover {
55
- --denhaag-pagination-color: var(--denhaag-pagination-link-hover-color);
56
- cursor: pointer;
57
- }
58
-
59
- .denhaag-pagination__link:focus,
60
- .denhaag-pagination__link--focus {
61
- outline: var(--denhaag-link-focus-outline);
62
- border-radius: 0;
63
- }
64
-
65
- .denhaag-pagination__link:disabled,
66
- .denhaag-pagination__link--disabled {
67
- --denhaag-pagination-color: var(--denhaag-pagination-link-disabled-color);
68
-
69
- pointer-events: none;
70
- }
71
-
72
- .denhaag-pagination__link--arrow {
73
- --denhaag-pagination-size: var(--denhaag-pagination-arrow-size);
74
- --denhaag-pagination-font-size: var(--denhaag-pagination-arrow-font-size);
75
- }
76
-
77
- [dir="rtl"] .denhaag-pagination__link--arrow {
78
- transform: scaleX(-1);
79
- }
80
-
81
- .denhaag-pagination__link + .denhaag-pagination__links,
82
- .denhaag-pagination__links + .denhaag-pagination__link {
83
- margin-inline-start: var(--denhaag-pagination-margin-inline, 10px);
84
- }
85
-
86
- .denhaag-pagination__link:not(:first-child):not(:last-child):not(.denhaag-pagination__link--current):not([rel]) {
87
- overflow: hidden;
88
- pointer-events: none;
89
- text-indent: calc(var(--denhaag-pagination-size) * 2);
90
- }
91
-
92
- .denhaag-pagination__link:not(:first-child):not(:last-child):not(.denhaag-pagination__link--current):not([rel])::before {
93
- content: "...";
94
- left: calc(50% - 7px);
95
- line-height: 0;
96
- position: absolute;
97
- text-indent: 0;
98
- vertical-align: baseline;
99
- }
100
-
101
- .denhaag-pagination__link--current {
102
- --denhaag-pagination-color: var(--denhaag-pagination-link-current-color);
103
- --denhaag-pagination-font-weight: var(
104
- --denhaag-pagination-link-current-font-weight
105
- );
106
- }
107
-
108
- .denhaag-pagination__link--current.denhaag-pagination__link:disabled,
109
- .denhaag-pagination__link--current.denhaag-pagination__link--disabled {
110
- --denhaag-pagination-color: var(
111
- --denhaag-pagination-link-current-disabled-color
112
- );
113
- --denhaag-pagination-background-color: var(
114
- --denhaag-pagination-link-current-disabled-background-color
115
- );
116
- }
117
-
118
- .denhaag-pagination .denhaag-icon {
119
- font-size: inherit;
120
- }
1
+ .denhaag-pagination {
2
+ --denhaag-pagination-align: center;
3
+
4
+ align-items: center;
5
+ display: flex;
6
+ flex-direction: row;
7
+ justify-content: var(--denhaag-pagination-align);
8
+ }
9
+
10
+ @media (min-width: 640px) {
11
+ .denhaag-pagination,
12
+ .denhaag-pagination--start {
13
+ --denhaag-pagination-align: flex-start;
14
+ }
15
+
16
+ .denhaag-pagination--center {
17
+ --denhaag-pagination-align: center;
18
+ }
19
+
20
+ .denhaag-pagination--end {
21
+ --denhaag-pagination-align: end;
22
+ }
23
+ }
24
+
25
+ .denhaag-pagination__links {
26
+ display: flex;
27
+ flex-direction: row;
28
+ }
29
+
30
+ .denhaag-pagination__link {
31
+ aspect-ratio: 1 / 1;
32
+ align-items: center;
33
+ background-color: var(--denhaag-pagination-background-color, transparent);
34
+ border: 0;
35
+ border-radius: var(
36
+ --denhaag-pagination-border-radius,
37
+ var(--denhaag-border-radius)
38
+ );
39
+ color: var(--denhaag-pagination-color, var(--denhaag-pagination-link-color));
40
+ display: flex;
41
+ height: var(--denhaag-pagination-size);
42
+ justify-content: center;
43
+ line-height: 1.5;
44
+ position: relative;
45
+ text-align: center;
46
+ text-decoration: none;
47
+ width: var(--denhaag-pagination-size);
48
+ font-style: normal;
49
+ font-weight: var(--denhaag-pagination-font-weight);
50
+ font-size: var(--denhaag-pagination-font-size);
51
+ }
52
+
53
+ .denhaag-pagination__link:hover,
54
+ .denhaag-pagination__link--hover {
55
+ --denhaag-pagination-color: var(--denhaag-pagination-link-hover-color);
56
+ cursor: pointer;
57
+ }
58
+
59
+ .denhaag-pagination__link:focus,
60
+ .denhaag-pagination__link--focus {
61
+ outline: var(--denhaag-link-focus-outline);
62
+ border-radius: 0;
63
+ }
64
+
65
+ .denhaag-pagination__link:disabled,
66
+ .denhaag-pagination__link--disabled {
67
+ --denhaag-pagination-color: var(--denhaag-pagination-link-disabled-color);
68
+
69
+ pointer-events: none;
70
+ }
71
+
72
+ .denhaag-pagination__link--arrow {
73
+ --denhaag-pagination-size: var(--denhaag-pagination-arrow-size);
74
+ --denhaag-pagination-font-size: var(--denhaag-pagination-arrow-font-size);
75
+ }
76
+
77
+ [dir="rtl"] .denhaag-pagination__link--arrow {
78
+ transform: scaleX(-1);
79
+ }
80
+
81
+ .denhaag-pagination__link + .denhaag-pagination__links,
82
+ .denhaag-pagination__links + .denhaag-pagination__link {
83
+ margin-inline-start: var(--denhaag-pagination-margin-inline, 10px);
84
+ }
85
+
86
+ .denhaag-pagination__link:not(:first-child):not(:last-child):not(.denhaag-pagination__link--current):not([rel]) {
87
+ overflow: hidden;
88
+ pointer-events: none;
89
+ text-indent: calc(var(--denhaag-pagination-size) * 2);
90
+ }
91
+
92
+ .denhaag-pagination__link:not(:first-child):not(:last-child):not(.denhaag-pagination__link--current):not([rel])::before {
93
+ content: "...";
94
+ left: calc(50% - 7px);
95
+ line-height: 0;
96
+ position: absolute;
97
+ text-indent: 0;
98
+ vertical-align: baseline;
99
+ }
100
+
101
+ .denhaag-pagination__link--current {
102
+ --denhaag-pagination-color: var(--denhaag-pagination-link-current-color);
103
+ --denhaag-pagination-font-weight: var(
104
+ --denhaag-pagination-link-current-font-weight
105
+ );
106
+ }
107
+
108
+ .denhaag-pagination__link--current.denhaag-pagination__link:disabled,
109
+ .denhaag-pagination__link--current.denhaag-pagination__link--disabled {
110
+ --denhaag-pagination-color: var(
111
+ --denhaag-pagination-link-current-disabled-color
112
+ );
113
+ --denhaag-pagination-background-color: var(
114
+ --denhaag-pagination-link-current-disabled-background-color
115
+ );
116
+ }
117
+
118
+ .denhaag-pagination .denhaag-icon {
119
+ font-size: inherit;
120
+ }
@@ -1,9 +1,9 @@
1
- /// <reference types="react" />
2
- import "./Pagination.css";
3
- interface PaginationProps {
4
- pages: number;
5
- currentPage: number;
6
- setPage: (page: number) => any;
7
- }
8
- export declare const Pagination: ({ pages, currentPage, setPage }: PaginationProps) => JSX.Element;
9
- export {};
1
+ /// <reference types="react" />
2
+ import "./Pagination.css";
3
+ interface PaginationProps {
4
+ pages: number;
5
+ currentPage: number;
6
+ setPage: (page: number) => any;
7
+ }
8
+ export declare const Pagination: ({ pages, currentPage, setPage }: PaginationProps) => JSX.Element;
9
+ export {};
@@ -1,15 +1,15 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import clsx from "clsx";
3
- import "./Pagination.css";
4
- export const Pagination = ({ pages, currentPage, setPage }) => {
5
- return (_jsxs("nav", { className: "denhaag-pagination", children: [_jsx(PreviousButton, { previousPage: currentPage > 1 ? currentPage - 1 : undefined, ...{ setPage } }), _jsx("span", { className: "denhaag-pagination__links", role: "group", children: Array.from({ length: pages }, (_, i) => i + 1).map((page, idx) => (_jsx(Link, { ...{ page }, current: page === currentPage, ...{ setPage } }, idx))) }), _jsx(NextButton, { nextPage: currentPage < pages ? currentPage + 1 : undefined, ...{ setPage } })] }));
6
- };
7
- const Link = ({ page, current, setPage }) => {
8
- return (_jsx("a", { "aria-current": current && "page", "aria-label": `Page ${page}`, className: clsx("denhaag-pagination__link", current && "denhaag-pagination__link--current"), onClick: () => setPage(page), children: page }));
9
- };
10
- const PreviousButton = ({ previousPage, setPage }) => {
11
- return (_jsx("a", { "aria-label": "Previous page", className: clsx("denhaag-pagination__link denhaag-pagination__link--arrow", !previousPage && "denhaag-pagination__link--disabled"), onClick: () => previousPage && setPage(previousPage), rel: "prev", children: _jsx("svg", { "aria-hidden": "true", className: "denhaag-icon", fill: "none", height: "1em", viewBox: "0 0 7 12", width: "1em", xmlns: "http://www.w3.org/2000/svg", children: _jsx("path", { d: "M4.9921 10.8143C5.36382 11.1914 5.97222 11.1914 6.34393 10.8143C6.7079 10.4451 6.70822 9.8521 6.34466 9.48248L3.36315 6.45123C2.98039 6.06209 2.98039 5.43791 3.36315 5.04877L6.34466 2.01752C6.70822 1.6479 6.7079 1.05492 6.34394 0.685696C5.97222 0.308599 5.36382 0.308599 4.9921 0.685695L0.692003 5.04799C0.308224 5.43732 0.308224 6.06268 0.692003 6.45201L4.9921 10.8143Z", fill: "currentColor" }) }) }));
12
- };
13
- const NextButton = ({ nextPage, setPage }) => {
14
- return (_jsx("a", { "aria-label": "Next page", className: clsx("denhaag-pagination__link denhaag-pagination__link--arrow", !nextPage && "denhaag-pagination__link--disabled"), onClick: () => nextPage && setPage(nextPage), rel: "next", children: _jsx("svg", { "aria-hidden": "true", className: "denhaag-icon", fill: "none", height: "1em", viewBox: "0 0 7 12", width: "1em", xmlns: "http://www.w3.org/2000/svg", children: _jsx("path", { d: "M2.0079 1.1857C1.63618 0.8086 1.02778 0.8086 0.656065 1.18569V1.18569C0.292103 1.55492 0.291779 2.1479 0.655339 2.51752L3.63685 5.54877C4.01961 5.93791 4.01961 6.56209 3.63686 6.95123L0.655339 9.98248C0.291779 10.3521 0.292102 10.9451 0.656065 11.3143V11.3143C1.02778 11.6914 1.63618 11.6914 2.0079 11.3143L6.308 6.95201C6.69178 6.56268 6.69178 5.93732 6.308 5.54799L2.0079 1.1857Z", fill: "currentColor" }) }) }));
15
- };
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import clsx from "clsx";
3
+ import "./Pagination.css";
4
+ export const Pagination = ({ pages, currentPage, setPage }) => {
5
+ return (_jsxs("nav", { className: "denhaag-pagination", children: [_jsx(PreviousButton, { previousPage: currentPage > 1 ? currentPage - 1 : undefined, ...{ setPage } }), _jsx("span", { className: "denhaag-pagination__links", role: "group", children: Array.from({ length: pages }, (_, i) => i + 1).map((page, idx) => (_jsx(Link, { ...{ page }, current: page === currentPage, ...{ setPage } }, idx))) }), _jsx(NextButton, { nextPage: currentPage < pages ? currentPage + 1 : undefined, ...{ setPage } })] }));
6
+ };
7
+ const Link = ({ page, current, setPage }) => {
8
+ return (_jsx("a", { "aria-current": current && "page", "aria-label": `Page ${page}`, className: clsx("denhaag-pagination__link", current && "denhaag-pagination__link--current"), onClick: () => setPage(page), children: page }));
9
+ };
10
+ const PreviousButton = ({ previousPage, setPage }) => {
11
+ return (_jsx("a", { "aria-label": "Previous page", className: clsx("denhaag-pagination__link denhaag-pagination__link--arrow", !previousPage && "denhaag-pagination__link--disabled"), onClick: () => previousPage && setPage(previousPage), rel: "prev", children: _jsx("svg", { "aria-hidden": "true", className: "denhaag-icon", fill: "none", height: "1em", viewBox: "0 0 7 12", width: "1em", xmlns: "http://www.w3.org/2000/svg", children: _jsx("path", { d: "M4.9921 10.8143C5.36382 11.1914 5.97222 11.1914 6.34393 10.8143C6.7079 10.4451 6.70822 9.8521 6.34466 9.48248L3.36315 6.45123C2.98039 6.06209 2.98039 5.43791 3.36315 5.04877L6.34466 2.01752C6.70822 1.6479 6.7079 1.05492 6.34394 0.685696C5.97222 0.308599 5.36382 0.308599 4.9921 0.685695L0.692003 5.04799C0.308224 5.43732 0.308224 6.06268 0.692003 6.45201L4.9921 10.8143Z", fill: "currentColor" }) }) }));
12
+ };
13
+ const NextButton = ({ nextPage, setPage }) => {
14
+ return (_jsx("a", { "aria-label": "Next page", className: clsx("denhaag-pagination__link denhaag-pagination__link--arrow", !nextPage && "denhaag-pagination__link--disabled"), onClick: () => nextPage && setPage(nextPage), rel: "next", children: _jsx("svg", { "aria-hidden": "true", className: "denhaag-icon", fill: "none", height: "1em", viewBox: "0 0 7 12", width: "1em", xmlns: "http://www.w3.org/2000/svg", children: _jsx("path", { d: "M2.0079 1.1857C1.63618 0.8086 1.02778 0.8086 0.656065 1.18569V1.18569C0.292103 1.55492 0.291779 2.1479 0.655339 2.51752L3.63685 5.54877C4.01961 5.93791 4.01961 6.56209 3.63686 6.95123L0.655339 9.98248C0.291779 10.3521 0.292102 10.9451 0.656065 11.3143V11.3143C1.02778 11.6914 1.63618 11.6914 2.0079 11.3143L6.308 6.95201C6.69178 6.56268 6.69178 5.93732 6.308 5.54799L2.0079 1.1857Z", fill: "currentColor" }) }) }));
15
+ };
@@ -1,14 +1,14 @@
1
- /// <reference types="react" />
2
- interface InputTypes {
3
- inputType: "text" | "email";
4
- }
5
- interface EditableTableRowProps {
6
- thead: string;
7
- value: string;
8
- saveLabel: string;
9
- cancelLabel: string;
10
- editLabel: string;
11
- handleSave: (value: any) => void;
12
- }
13
- export declare const EditableTableRow: ({ thead, value, inputType, editLabel, cancelLabel, saveLabel, handleSave, }: EditableTableRowProps & InputTypes) => JSX.Element;
14
- export {};
1
+ /// <reference types="react" />
2
+ interface InputTypes {
3
+ inputType: "text" | "email";
4
+ }
5
+ interface EditableTableRowProps {
6
+ thead: string;
7
+ value: string;
8
+ saveLabel: string;
9
+ cancelLabel: string;
10
+ editLabel: string;
11
+ handleSave: (value: any) => void;
12
+ }
13
+ export declare const EditableTableRow: ({ thead, value, inputType, editLabel, cancelLabel, saveLabel, handleSave, }: EditableTableRowProps & InputTypes) => JSX.Element;
14
+ export {};
@@ -1,31 +1,31 @@
1
- import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
- import { TableCell, TableHeader, TableRow } from "@gemeente-denhaag/table";
3
- import * as styles from "./EditableTableRow.module.css";
4
- import * as React from "react";
5
- import { Link } from "@gemeente-denhaag/link";
6
- import { CheckedIcon, CloseIcon, EditIcon } from "@gemeente-denhaag/icons";
7
- import { useForm } from "react-hook-form";
8
- import { InputEmail, InputText } from "../formFields";
9
- export const EditableTableRow = ({ thead, value, inputType, editLabel, cancelLabel, saveLabel, handleSave, }) => {
10
- const [editing, setEditing] = React.useState(false);
11
- return (_jsxs(TableRow, { children: [_jsx(TableHeader, { className: styles.th, children: thead }), editing && _jsx(EditingTableRow, { ...{ value, inputType, handleSave, setEditing, saveLabel, cancelLabel } }), !editing && _jsx(RegularTableRow, { ...{ value, setEditing, editLabel } })] }));
12
- };
13
- const RegularTableRow = ({ value, editLabel, setEditing }) => {
14
- return (_jsxs(_Fragment, { children: [_jsx(TableCell, { children: value }), _jsx(TableCell, { children: _jsx("div", { className: styles.editButton, onClick: () => setEditing(true), children: _jsx(Link, { icon: _jsx(EditIcon, {}), iconAlign: "start", children: editLabel }) }) })] }));
15
- };
16
- const EditingTableRow = ({ value, setEditing, handleSave, inputType, saveLabel, cancelLabel, }) => {
17
- const { register, handleSubmit, formState: { errors }, } = useForm();
18
- const onSubmit = (data) => {
19
- handleSave(data.value);
20
- setEditing(false);
21
- };
22
- return (_jsxs(_Fragment, { children: [_jsx(TableCell, { children: _jsxs("form", { onSubmit: handleSubmit(onSubmit), children: [_jsx(FormField, { ...{ inputType, value, register, errors } }), _jsxs("div", { className: styles.editButtonsContainer, children: [_jsx("button", { type: "submit", className: styles.submit, children: _jsx(Link, { icon: _jsx(CheckedIcon, {}), iconAlign: "start", children: saveLabel }) }), _jsx("div", { onClick: () => setEditing(false), children: _jsx(Link, { icon: _jsx(CloseIcon, {}), iconAlign: "start", className: styles.cancel, children: cancelLabel }) })] })] }) }), _jsx(TableCell, {})] }));
23
- };
24
- const FormField = ({ inputType, value, register, errors }) => {
25
- switch (inputType) {
26
- case "email":
27
- return _jsx(InputEmail, { defaultValue: value, ...{ register, errors }, name: "value", validation: { required: true } });
28
- case "text":
29
- return _jsx(InputText, { defaultValue: value, ...{ register, errors }, name: "value", validation: { required: true } });
30
- }
31
- };
1
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
+ import { TableCell, TableHeader, TableRow } from "@gemeente-denhaag/table";
3
+ import * as styles from "./EditableTableRow.module.css";
4
+ import * as React from "react";
5
+ import { Link } from "@gemeente-denhaag/link";
6
+ import { CheckedIcon, CloseIcon, EditIcon } from "@gemeente-denhaag/icons";
7
+ import { useForm } from "react-hook-form";
8
+ import { InputEmail, InputText } from "../formFields";
9
+ export const EditableTableRow = ({ thead, value, inputType, editLabel, cancelLabel, saveLabel, handleSave, }) => {
10
+ const [editing, setEditing] = React.useState(false);
11
+ return (_jsxs(TableRow, { children: [_jsx(TableHeader, { className: styles.th, children: thead }), editing && _jsx(EditingTableRow, { ...{ value, inputType, handleSave, setEditing, saveLabel, cancelLabel } }), !editing && _jsx(RegularTableRow, { ...{ value, setEditing, editLabel } })] }));
12
+ };
13
+ const RegularTableRow = ({ value, editLabel, setEditing }) => {
14
+ return (_jsxs(_Fragment, { children: [_jsx(TableCell, { children: value }), _jsx(TableCell, { children: _jsx("div", { className: styles.editButton, onClick: () => setEditing(true), children: _jsx(Link, { icon: _jsx(EditIcon, {}), iconAlign: "start", children: editLabel }) }) })] }));
15
+ };
16
+ const EditingTableRow = ({ value, setEditing, handleSave, inputType, saveLabel, cancelLabel, }) => {
17
+ const { register, handleSubmit, formState: { errors }, } = useForm();
18
+ const onSubmit = (data) => {
19
+ handleSave(data.value);
20
+ setEditing(false);
21
+ };
22
+ return (_jsxs(_Fragment, { children: [_jsx(TableCell, { children: _jsxs("form", { onSubmit: handleSubmit(onSubmit), children: [_jsx(FormField, { ...{ inputType, value, register, errors } }), _jsxs("div", { className: styles.editButtonsContainer, children: [_jsx("button", { type: "submit", className: styles.submit, children: _jsx(Link, { icon: _jsx(CheckedIcon, {}), iconAlign: "start", children: saveLabel }) }), _jsx("div", { onClick: () => setEditing(false), children: _jsx(Link, { icon: _jsx(CloseIcon, {}), iconAlign: "start", className: styles.cancel, children: cancelLabel }) })] })] }) }), _jsx(TableCell, {})] }));
23
+ };
24
+ const FormField = ({ inputType, value, register, errors }) => {
25
+ switch (inputType) {
26
+ case "email":
27
+ return _jsx(InputEmail, { defaultValue: value, ...{ register, errors }, name: "value", validation: { required: true } });
28
+ case "text":
29
+ return _jsx(InputText, { defaultValue: value, ...{ register, errors }, name: "value", validation: { required: true } });
30
+ }
31
+ };
@@ -1,25 +1,25 @@
1
- .th {
2
- width: 35%;
3
- }
4
-
5
- .cancel {
6
- color: var(--skeleton-color-grey-3) !important;
7
- }
8
-
9
- .editButtonsContainer {
10
- display: flex;
11
- margin-block-start: var(--skeleton-size-xs);
12
- }
13
-
14
- .editButtonsContainer > *:not(:last-child) {
15
- margin-inline-end: var(--skeleton-size-md);
16
- }
17
-
18
- .submit {
19
- all: unset;
20
- }
21
-
22
- .editButton {
23
- display: flex;
24
- justify-content: flex-end;
25
- }
1
+ .th {
2
+ width: 35%;
3
+ }
4
+
5
+ .cancel {
6
+ color: var(--skeleton-color-grey-3) !important;
7
+ }
8
+
9
+ .editButtonsContainer {
10
+ display: flex;
11
+ margin-block-start: var(--skeleton-size-xs);
12
+ }
13
+
14
+ .editButtonsContainer > *:not(:last-child) {
15
+ margin-inline-end: var(--skeleton-size-md);
16
+ }
17
+
18
+ .submit {
19
+ all: unset;
20
+ }
21
+
22
+ .editButton {
23
+ display: flex;
24
+ justify-content: flex-end;
25
+ }
@@ -1,7 +1,7 @@
1
- .container {
2
- user-select: none;
3
- }
4
-
5
- .container:hover {
6
- cursor: pointer;
7
- }
1
+ .container {
2
+ user-select: none;
3
+ }
4
+
5
+ .container:hover {
6
+ cursor: pointer;
7
+ }
@@ -1,9 +1,9 @@
1
- /// <reference types="react" />
2
- import { IReactHookFormProps } from "./../types";
3
- export interface ICheckboxProps {
4
- label: string;
5
- name: string;
6
- defaultChecked?: boolean;
7
- disabled?: boolean;
8
- }
9
- export declare const InputCheckbox: ({ name, validation, register, label, defaultChecked, disabled, }: ICheckboxProps & IReactHookFormProps) => JSX.Element;
1
+ /// <reference types="react" />
2
+ import { IReactHookFormProps } from "./../types";
3
+ export interface ICheckboxProps {
4
+ label: string;
5
+ name: string;
6
+ defaultChecked?: boolean;
7
+ disabled?: boolean;
8
+ }
9
+ export declare const InputCheckbox: ({ name, validation, register, label, defaultChecked, disabled, }: ICheckboxProps & IReactHookFormProps) => JSX.Element;
@@ -1,3 +1,3 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import * as styles from "./Checkbox.module.css";
3
- export const InputCheckbox = ({ name, validation, register, label, defaultChecked, disabled, }) => (_jsxs("div", { className: styles.container, children: [_jsx("input", { type: "checkbox", id: `checkbox${name}`, ...{ defaultChecked, disabled }, ...register(name, { ...validation }) }), _jsx("label", { htmlFor: `checkbox${name}`, children: label })] }));
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import * as styles from "./Checkbox.module.css";
3
+ export const InputCheckbox = ({ name, validation, register, label, defaultChecked, disabled, }) => (_jsxs("div", { className: styles.container, children: [_jsx("input", { type: "checkbox", id: `checkbox${name}`, ...{ defaultChecked, disabled }, ...register(name, { ...validation }) }), _jsx("label", { htmlFor: `checkbox${name}`, children: label })] }));
@@ -1,23 +1,23 @@
1
- /// <reference types="react" />
2
- import { Control, FieldValues } from "react-hook-form";
3
- import { IReactHookFormProps } from "../types";
4
- /**
5
- * Export KeyValue input component (wrapped in FormFieldGroup)
6
- */
7
- interface CreateKeyValueProps {
8
- name: string;
9
- control: Control<FieldValues, any>;
10
- defaultValue?: IKeyValue[];
11
- disabled?: boolean;
12
- copyValue?: {
13
- canCopy: boolean;
14
- onCopied?: () => any;
15
- };
16
- hideErrorMessage?: boolean;
17
- }
18
- export interface IKeyValue {
19
- key: string;
20
- value: string;
21
- }
22
- export declare const CreateKeyValue: ({ name, errors, control, validation, defaultValue, disabled, copyValue, hideErrorMessage, }: CreateKeyValueProps & IReactHookFormProps) => JSX.Element;
23
- export {};
1
+ /// <reference types="react" />
2
+ import { Control, FieldValues } from "react-hook-form";
3
+ import { IReactHookFormProps } from "../types";
4
+ /**
5
+ * Export KeyValue input component (wrapped in FormFieldGroup)
6
+ */
7
+ interface CreateKeyValueProps {
8
+ name: string;
9
+ control: Control<FieldValues, any>;
10
+ defaultValue?: IKeyValue[];
11
+ disabled?: boolean;
12
+ copyValue?: {
13
+ canCopy: boolean;
14
+ onCopied?: () => any;
15
+ };
16
+ hideErrorMessage?: boolean;
17
+ }
18
+ export interface IKeyValue {
19
+ key: string;
20
+ value: string;
21
+ }
22
+ export declare const CreateKeyValue: ({ name, errors, control, validation, defaultValue, disabled, copyValue, hideErrorMessage, }: CreateKeyValueProps & IReactHookFormProps) => JSX.Element;
23
+ export {};
@@ -1,40 +1,40 @@
1
- import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
- import * as React from "react";
3
- import * as styles from "./CreateKeyValue.module.css";
4
- import { Controller } from "react-hook-form";
5
- import { Table, TableBody, TableCell, TableHeaderCell, TableHeader, TableRow, Textbox, Button, } from "@utrecht/component-library-react/dist/css-module";
6
- import clsx from "clsx";
7
- import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
8
- import { faCopy, faTrash } from "@fortawesome/free-solid-svg-icons";
9
- import { ErrorMessage } from "../errorMessage/ErrorMessage";
10
- export const CreateKeyValue = ({ name, errors, control, validation, defaultValue, disabled, copyValue, hideErrorMessage, }) => {
11
- return (_jsx(Controller, { ...{ control, name, errors }, rules: validation, render: ({ field: { onChange } }) => {
12
- return (_jsxs(_Fragment, { children: [_jsx(KeyValueComponent, { handleChange: onChange, ...{ defaultValue, errors, disabled, copyValue } }), errors[name] && !hideErrorMessage && _jsx(ErrorMessage, { message: errors[name].message })] }));
13
- } }));
14
- };
15
- const KeyValueComponent = ({ defaultValue, handleChange, disabled, copyValue, }) => {
16
- const [currentKey, setCurrentKey] = React.useState("");
17
- const [currentValue, setCurrentValue] = React.useState("");
18
- const [keyValues, setKeyValues] = React.useState(defaultValue ?? []);
19
- const [currentCopyIdx, setCurrentCopyIdx] = React.useState();
20
- const currentKeyRef = React.useRef(null);
21
- const currentValueRef = React.useRef(null);
22
- const handleCreate = () => {
23
- const keyValue = { key: currentKey, value: currentValue };
24
- setCurrentKey("");
25
- setCurrentValue("");
26
- setKeyValues([...keyValues, keyValue]);
27
- };
28
- const handleCopyToClipboard = (value, id) => {
29
- navigator.clipboard.writeText(value);
30
- setCurrentCopyIdx(id);
31
- copyValue?.onCopied && copyValue.onCopied();
32
- };
33
- React.useEffect(() => {
34
- defaultValue && setKeyValues(defaultValue);
35
- }, [defaultValue]);
36
- React.useEffect(() => {
37
- handleChange(keyValues);
38
- }, [keyValues]);
39
- return (_jsxs("div", { className: styles.keyValue, children: [keyValues && (_jsxs(Table, { className: styles.table, children: [_jsx(TableHeader, { className: styles.tableHeader, children: _jsxs(TableRow, { children: [_jsx(TableHeaderCell, { children: "Key" }), _jsx(TableHeaderCell, { children: "Value" }), _jsx(TableHeaderCell, {})] }) }), _jsx(TableBody, { children: keyValues.map((keyValue, idx) => (_jsxs(TableRow, { children: [_jsx(TableCell, { children: keyValue.key }), _jsx(TableCell, { children: keyValue.value }), _jsx(TableCell, { children: _jsxs("div", { className: styles.buttonsContainer, children: [copyValue && (_jsx(Button, { ...{ disabled }, onClick: () => handleCopyToClipboard(keyValue.value, idx), appearance: currentCopyIdx === idx ? "secondary-action-button" : "primary-action-button", children: _jsx(FontAwesomeIcon, { icon: faCopy }) })), _jsx(Button, { ...{ disabled }, onClick: () => setKeyValues(keyValues.filter((_keyValue) => _keyValue !== keyValue)), className: clsx(styles.deleteButton), children: _jsx(FontAwesomeIcon, { icon: faTrash }) })] }) })] }, `${keyValue.key}${keyValue.value}${idx}`))) })] })), _jsxs("div", { className: styles.form, children: [_jsx(Textbox, { type: "text", placeholder: "Key", value: currentKey, ref: currentKeyRef, onChange: (e) => setCurrentKey(e.target.value), ...{ disabled } }), _jsx(Textbox, { type: "text", placeholder: "Value", value: currentValue, ref: currentValueRef, onChange: (e) => setCurrentValue(e.target.value), ...{ disabled } }), _jsx(Button, { onClick: handleCreate, disabled: !currentKey || !currentValue || disabled, children: "Add" })] })] }));
40
- };
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import * as React from "react";
3
+ import * as styles from "./CreateKeyValue.module.css";
4
+ import { Controller } from "react-hook-form";
5
+ import { Table, TableBody, TableCell, TableHeaderCell, TableHeader, TableRow, Textbox, Button, } from "@utrecht/component-library-react/dist/css-module";
6
+ import clsx from "clsx";
7
+ import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
8
+ import { faCopy, faTrash } from "@fortawesome/free-solid-svg-icons";
9
+ import { ErrorMessage } from "../errorMessage/ErrorMessage";
10
+ export const CreateKeyValue = ({ name, errors, control, validation, defaultValue, disabled, copyValue, hideErrorMessage, }) => {
11
+ return (_jsx(Controller, { ...{ control, name, errors }, rules: validation, render: ({ field: { onChange } }) => {
12
+ return (_jsxs(_Fragment, { children: [_jsx(KeyValueComponent, { handleChange: onChange, ...{ defaultValue, errors, disabled, copyValue } }), errors[name] && !hideErrorMessage && _jsx(ErrorMessage, { message: errors[name].message })] }));
13
+ } }));
14
+ };
15
+ const KeyValueComponent = ({ defaultValue, handleChange, disabled, copyValue, }) => {
16
+ const [currentKey, setCurrentKey] = React.useState("");
17
+ const [currentValue, setCurrentValue] = React.useState("");
18
+ const [keyValues, setKeyValues] = React.useState(defaultValue ?? []);
19
+ const [currentCopyIdx, setCurrentCopyIdx] = React.useState();
20
+ const currentKeyRef = React.useRef(null);
21
+ const currentValueRef = React.useRef(null);
22
+ const handleCreate = () => {
23
+ const keyValue = { key: currentKey, value: currentValue };
24
+ setCurrentKey("");
25
+ setCurrentValue("");
26
+ setKeyValues([...keyValues, keyValue]);
27
+ };
28
+ const handleCopyToClipboard = (value, id) => {
29
+ navigator.clipboard.writeText(value);
30
+ setCurrentCopyIdx(id);
31
+ copyValue?.onCopied && copyValue.onCopied();
32
+ };
33
+ React.useEffect(() => {
34
+ defaultValue && setKeyValues(defaultValue);
35
+ }, [defaultValue]);
36
+ React.useEffect(() => {
37
+ handleChange(keyValues);
38
+ }, [keyValues]);
39
+ return (_jsxs("div", { className: styles.keyValue, children: [keyValues && (_jsxs(Table, { className: styles.table, children: [_jsx(TableHeader, { className: styles.tableHeader, children: _jsxs(TableRow, { children: [_jsx(TableHeaderCell, { children: "Key" }), _jsx(TableHeaderCell, { children: "Value" }), _jsx(TableHeaderCell, {})] }) }), _jsx(TableBody, { children: keyValues.map((keyValue, idx) => (_jsxs(TableRow, { children: [_jsx(TableCell, { children: keyValue.key }), _jsx(TableCell, { children: keyValue.value }), _jsx(TableCell, { children: _jsxs("div", { className: styles.buttonsContainer, children: [copyValue && (_jsx(Button, { ...{ disabled }, onClick: () => handleCopyToClipboard(keyValue.value, idx), appearance: currentCopyIdx === idx ? "secondary-action-button" : "primary-action-button", children: _jsx(FontAwesomeIcon, { icon: faCopy }) })), _jsx(Button, { ...{ disabled }, onClick: () => setKeyValues(keyValues.filter((_keyValue) => _keyValue !== keyValue)), className: clsx(styles.deleteButton), children: _jsx(FontAwesomeIcon, { icon: faTrash }) })] }) })] }, `${keyValue.key}${keyValue.value}${idx}`))) })] })), _jsxs("div", { className: styles.form, children: [_jsx(Textbox, { type: "text", placeholder: "Key", value: currentKey, ref: currentKeyRef, onChange: (e) => setCurrentKey(e.target.value), ...{ disabled } }), _jsx(Textbox, { type: "text", placeholder: "Value", value: currentValue, ref: currentValueRef, onChange: (e) => setCurrentValue(e.target.value), ...{ disabled } }), _jsx(Button, { onClick: handleCreate, disabled: !currentKey || !currentValue || disabled, children: "Add" })] })] }));
40
+ };