dibk-design 6.5.2 → 7.0.0
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/components/Accordion.js +4 -4
- package/dist/components/Accordion.module.scss +25 -18
- package/dist/components/Button.js +11 -14
- package/dist/components/Button.module.scss +79 -66
- package/dist/components/CheckBoxIcon.js +2 -2
- package/dist/components/CheckBoxIcon.module.scss +17 -10
- package/dist/components/CheckBoxInput.js +2 -2
- package/dist/components/CheckBoxInput.module.scss +5 -4
- package/dist/components/CheckBoxList.js +4 -5
- package/dist/components/CheckBoxList.module.scss +3 -2
- package/dist/components/CheckBoxListItem.js +1 -1
- package/dist/components/CheckBoxListItem.module.scss +17 -9
- package/dist/components/Container.js +2 -3
- package/dist/components/Container.module.scss +5 -3
- package/dist/components/ContentBox.js +2 -3
- package/dist/components/ContentBox.module.scss +16 -11
- package/dist/components/DescriptionDetails.js +1 -1
- package/dist/components/DescriptionDetails.module.scss +3 -2
- package/dist/components/DescriptionList.js +2 -2
- package/dist/components/DescriptionList.module.scss +0 -2
- package/dist/components/DescriptionTerm.js +1 -1
- package/dist/components/DescriptionTerm.module.scss +3 -2
- package/dist/components/Dialog.js +4 -5
- package/dist/components/Dialog.module.scss +14 -9
- package/dist/components/DragAndDropFileInput.js +6 -7
- package/dist/components/DragAndDropFileInput.module.scss +9 -5
- package/dist/components/ErrorBox.js +1 -1
- package/dist/components/ErrorBox.module.scss +12 -8
- package/dist/components/ErrorMessage.js +4 -6
- package/dist/components/ErrorMessage.module.scss +5 -3
- package/dist/components/Footer.js +1 -1
- package/dist/components/Footer.module.scss +3 -2
- package/dist/components/Header.js +6 -7
- package/dist/components/Header.module.scss +14 -11
- package/dist/components/InfoBox.js +1 -1
- package/dist/components/InfoBox.module.scss +7 -4
- package/dist/components/InputField.js +8 -10
- package/dist/components/InputField.module.scss +19 -13
- package/dist/components/Label.js +3 -4
- package/dist/components/Label.module.scss +3 -2
- package/dist/components/Lead.js +1 -1
- package/dist/components/Lead.module.scss +5 -3
- package/dist/components/List.js +3 -3
- package/dist/components/List.module.scss +0 -2
- package/dist/components/ListItem.js +1 -1
- package/dist/components/ListItem.module.scss +3 -2
- package/dist/components/LoadingAnimation.js +1 -1
- package/dist/components/LoadingAnimation.module.scss +5 -3
- package/dist/components/NavigationBar.js +9 -10
- package/dist/components/NavigationBar.module.scss +66 -57
- package/dist/components/NavigationBarListItem.js +1 -1
- package/dist/components/PDF.scss +14 -6
- package/dist/components/Paper.js +2 -2
- package/dist/components/Paper.module.scss +3 -2
- package/dist/components/ProgressBar.js +2 -2
- package/dist/components/ProgressBar.module.scss +8 -4
- package/dist/components/RadioButtonIcon.js +2 -2
- package/dist/components/RadioButtonIcon.module.scss +18 -10
- package/dist/components/RadioButtonInput.js +2 -2
- package/dist/components/RadioButtonInput.module.scss +5 -4
- package/dist/components/RadioButtonList.js +4 -5
- package/dist/components/RadioButtonList.module.scss +3 -2
- package/dist/components/RadioButtonListItem.js +1 -1
- package/dist/components/RadioButtonListItem.module.scss +17 -9
- package/dist/components/Select.js +9 -10
- package/dist/components/Select.module.scss +24 -16
- package/dist/components/Table.js +3 -3
- package/dist/components/Table.module.scss +10 -8
- package/dist/components/Textarea.js +7 -8
- package/dist/components/Textarea.module.scss +21 -13
- package/dist/components/Theme.js +2 -2
- package/dist/components/Theme.module.scss +29 -27
- package/dist/components/ThemeProvider.js +2 -2
- package/dist/components/ThemeProvider.module.scss +7 -5
- package/dist/components/ToggleNavigationButton.js +1 -1
- package/dist/components/ToggleNavigationButton.module.scss +11 -8
- package/dist/components/WizardNavigation/Step.js +1 -1
- package/dist/components/WizardNavigation/Step.module.scss +27 -24
- package/dist/components/WizardNavigation.js +4 -5
- package/dist/components/WizardNavigation.module.scss +3 -2
- package/dist/functions/helpers.js +11 -15
- package/dist/functions/theme.js +3 -3
- package/dist/index.js +1 -1
- package/dist/style/base/_typography.scss +5 -2
- package/dist/style/layout/_containers.scss +3 -1
- package/dist/style/pdf.css +3 -0
- package/dist/style/pdf.css.map +1 -1
- package/package.json +16 -15
- package/dist/style/abstracts/_all.scss +0 -2
- package/dist/style/abstracts/mixins/_all.scss +0 -12
- package/dist/style/abstracts/variables/_all.scss +0 -5
- package/dist/style/base/_all.scss +0 -3
- package/dist/style/global.scss +0 -3
- package/dist/style/layout/_all.scss +0 -1
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
|
|
1
|
+
// Variables
|
|
2
|
+
@use "../style/abstracts/variables/colors";
|
|
3
|
+
@use "../style/abstracts/variables/typography";
|
|
2
4
|
|
|
3
5
|
@keyframes messageIn {
|
|
4
6
|
0% {
|
|
@@ -10,12 +12,12 @@
|
|
|
10
12
|
.errorMessage {
|
|
11
13
|
display: flex;
|
|
12
14
|
align-items: center;
|
|
13
|
-
font-family:
|
|
15
|
+
font-family: typography.$default-font;
|
|
14
16
|
font-size: 16px;
|
|
15
17
|
font-weight: 400;
|
|
16
18
|
line-height: 24px;
|
|
17
19
|
letter-spacing: 0.01em;
|
|
18
|
-
color:
|
|
20
|
+
color: colors.$color-error;
|
|
19
21
|
margin: 4px 0 0;
|
|
20
22
|
animation: 1000ms cubic-bezier(0.22, 1, 0.36, 1) 0s 1 normal none running messageIn;
|
|
21
23
|
.errorSign {
|
|
@@ -7,7 +7,7 @@ exports.default = void 0;
|
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _Container = _interopRequireDefault(require("./Container"));
|
|
9
9
|
var _FooterModule = _interopRequireDefault(require("./Footer.module.scss"));
|
|
10
|
-
function _interopRequireDefault(
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
11
|
const Footer = props => {
|
|
12
12
|
return _react.default.createElement("footer", {
|
|
13
13
|
className: _FooterModule.default.footer
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
// Variables
|
|
2
|
+
@use "../style/abstracts/variables/colors";
|
|
2
3
|
|
|
3
4
|
.footer {
|
|
4
|
-
background-color: var(--color-primary,
|
|
5
|
+
background-color: var(--color-primary, colors.$color-primary);
|
|
5
6
|
padding: 16px 0;
|
|
6
7
|
text-align: right;
|
|
7
8
|
* {
|
|
@@ -8,21 +8,20 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
8
8
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
9
|
var _HeaderModule = _interopRequireDefault(require("./Header.module.scss"));
|
|
10
10
|
var _helpers = require("../functions/helpers");
|
|
11
|
-
function _interopRequireDefault(
|
|
11
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
12
|
const Header = props => {
|
|
13
|
-
var _props$htmlTag, _props$label, _props$content;
|
|
14
13
|
const bigClass = props.big ? _HeaderModule.default.bigHeader : "";
|
|
15
|
-
const htmlTag =
|
|
14
|
+
const htmlTag = props.htmlTag?.length ? props.htmlTag : `h${props.size}`;
|
|
16
15
|
const headerClass = _HeaderModule.default.header;
|
|
17
|
-
const headerSizeClass = _HeaderModule.default[
|
|
16
|
+
const headerSizeClass = _HeaderModule.default[`size-${props.size}`];
|
|
18
17
|
let headerElement = _react.default.createElement(htmlTag, {
|
|
19
18
|
className: (0, _helpers.classNameArrayToClassNameString)([headerClass, headerSizeClass, bigClass]),
|
|
20
19
|
id: props.id || null,
|
|
21
20
|
htmlFor: props.htmlFor || null,
|
|
22
|
-
style: props
|
|
23
|
-
"--label": "
|
|
21
|
+
style: props?.label?.length ? {
|
|
22
|
+
"--label": `"${props.label}"`
|
|
24
23
|
} : null
|
|
25
|
-
}, !!
|
|
24
|
+
}, !!props.content?.length ? props.content : props.children);
|
|
26
25
|
return _react.default.createElement("div", {
|
|
27
26
|
className: _HeaderModule.default.headerContainer
|
|
28
27
|
}, " ", headerElement, " ");
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
// Variables
|
|
2
|
+
@use "../style/abstracts/variables/colors";
|
|
3
|
+
@use "../style/abstracts/variables/typography";
|
|
4
|
+
@use "../style/abstracts/variables/viewports";
|
|
2
5
|
|
|
3
6
|
.headerContainer {
|
|
4
7
|
.header {
|
|
@@ -6,27 +9,27 @@
|
|
|
6
9
|
font-weight: normal;
|
|
7
10
|
line-height: 1.4;
|
|
8
11
|
font-style: normal;
|
|
9
|
-
color: var(--color-heading-text,
|
|
12
|
+
color: var(--color-heading-text, colors.$color-heading-text);
|
|
10
13
|
&.size-1 {
|
|
11
|
-
font-family:
|
|
14
|
+
font-family: typography.$default-font;
|
|
12
15
|
font-style: normal;
|
|
13
16
|
font-size: 28px;
|
|
14
17
|
font-weight: 600;
|
|
15
18
|
line-height: 36px;
|
|
16
19
|
letter-spacing: 0px;
|
|
17
20
|
&.bigHeader {
|
|
18
|
-
font-family:
|
|
21
|
+
font-family: typography.$default-font;
|
|
19
22
|
font-size: 40px;
|
|
20
23
|
line-height: 1.2;
|
|
21
24
|
overflow: hidden;
|
|
22
25
|
text-overflow: ellipsis;
|
|
23
|
-
@media only screen and (min-width:
|
|
26
|
+
@media only screen and (min-width: viewports.$screen-sm) {
|
|
24
27
|
font-size: 50px;
|
|
25
28
|
}
|
|
26
29
|
}
|
|
27
30
|
}
|
|
28
31
|
&.size-2 {
|
|
29
|
-
font-family:
|
|
32
|
+
font-family: typography.$default-font;
|
|
30
33
|
font-style: normal;
|
|
31
34
|
font-size: 22px;
|
|
32
35
|
font-weight: 600;
|
|
@@ -34,7 +37,7 @@
|
|
|
34
37
|
letter-spacing: 0px;
|
|
35
38
|
}
|
|
36
39
|
&.size-3 {
|
|
37
|
-
font-family:
|
|
40
|
+
font-family: typography.$default-font;
|
|
38
41
|
font-style: normal;
|
|
39
42
|
font-size: 18px;
|
|
40
43
|
font-weight: 600;
|
|
@@ -42,7 +45,7 @@
|
|
|
42
45
|
letter-spacing: 0px;
|
|
43
46
|
}
|
|
44
47
|
&.size-4 {
|
|
45
|
-
font-family:
|
|
48
|
+
font-family: typography.$default-font;
|
|
46
49
|
font-style: italic;
|
|
47
50
|
font-size: 17px;
|
|
48
51
|
font-weight: normal;
|
|
@@ -50,7 +53,7 @@
|
|
|
50
53
|
letter-spacing: 0px;
|
|
51
54
|
}
|
|
52
55
|
&.size-5 {
|
|
53
|
-
font-family:
|
|
56
|
+
font-family: typography.$default-font;
|
|
54
57
|
font-style: normal;
|
|
55
58
|
font-size: 15px;
|
|
56
59
|
font-weight: 600;
|
|
@@ -61,13 +64,13 @@
|
|
|
61
64
|
&::before {
|
|
62
65
|
content: var(--label);
|
|
63
66
|
display: block;
|
|
64
|
-
font-family:
|
|
67
|
+
font-family: typography.$default-font;
|
|
65
68
|
font-size: 12px;
|
|
66
69
|
font-weight: 600;
|
|
67
70
|
line-height: 18px;
|
|
68
71
|
letter-spacing: 0px;
|
|
69
72
|
text-transform: uppercase;
|
|
70
|
-
color: var(--color-heading-text,
|
|
73
|
+
color: var(--color-heading-text, colors.$color-heading-text);
|
|
71
74
|
opacity: 0.75;
|
|
72
75
|
margin-bottom: 0.3em;
|
|
73
76
|
}
|
|
@@ -7,7 +7,7 @@ exports.default = void 0;
|
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _InfoBoxModule = _interopRequireDefault(require("./InfoBox.module.scss"));
|
|
9
9
|
var _infoSign = _interopRequireDefault(require("../assets/svg/info-sign.svg?url"));
|
|
10
|
-
function _interopRequireDefault(
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
11
|
const InfoBox = props => {
|
|
12
12
|
return _react.default.createElement("div", {
|
|
13
13
|
className: _InfoBoxModule.default.infoBox
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
// Variables
|
|
2
|
+
@use "../style/abstracts/variables/colors";
|
|
3
|
+
@use "../style/abstracts/variables/typography";
|
|
4
|
+
@use "../style/abstracts/variables/viewports";
|
|
2
5
|
|
|
3
6
|
@keyframes messageIn {
|
|
4
7
|
0% {
|
|
@@ -9,9 +12,9 @@
|
|
|
9
12
|
|
|
10
13
|
.infoBox {
|
|
11
14
|
background-color: #fff;
|
|
12
|
-
border: 1px solid var(--color-secondary-light,
|
|
15
|
+
border: 1px solid var(--color-secondary-light, colors.$color-secondary-light);
|
|
13
16
|
padding: 24px 24px 24px calc(1.2em + 48px);
|
|
14
|
-
font-family:
|
|
17
|
+
font-family: typography.$default-font;
|
|
15
18
|
animation: 1000ms cubic-bezier(0.22, 1, 0.36, 1) 0s 1 normal none running messageIn;
|
|
16
19
|
position: relative;
|
|
17
20
|
.infoSign {
|
|
@@ -31,7 +34,7 @@
|
|
|
31
34
|
font-weight: 500;
|
|
32
35
|
line-height: 1.3;
|
|
33
36
|
margin: 0;
|
|
34
|
-
@media only screen and (min-width:
|
|
37
|
+
@media only screen and (min-width: viewports.$screen-sm) {
|
|
35
38
|
font-size: 24px;
|
|
36
39
|
}
|
|
37
40
|
}
|
|
@@ -13,27 +13,25 @@ var _generators = require("../functions/generators");
|
|
|
13
13
|
var _helpers = require("../functions/helpers");
|
|
14
14
|
var _asterisk = _interopRequireDefault(require("../assets/svg/asterisk.svg?url"));
|
|
15
15
|
var _InputFieldModule = _interopRequireDefault(require("./InputField.module.scss"));
|
|
16
|
-
function _interopRequireDefault(
|
|
16
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
17
17
|
const InputField = props => {
|
|
18
|
-
var _props$width;
|
|
19
18
|
const formatDate = inputDate => {
|
|
20
19
|
if (!inputDate) {
|
|
21
20
|
return null;
|
|
22
21
|
}
|
|
23
22
|
const date = new Date(inputDate);
|
|
24
23
|
const year = date.getFullYear();
|
|
25
|
-
const month = date.getMonth() + 1 < 10 ?
|
|
26
|
-
const day = date.getDate() < 10 ?
|
|
27
|
-
return
|
|
24
|
+
const month = date.getMonth() + 1 < 10 ? `0${date.getMonth() + 1}` : date.getMonth() + 1;
|
|
25
|
+
const day = date.getDate() < 10 ? `0${date.getDate()}` : date.getDate();
|
|
26
|
+
return `${day}.${month}.${year}`;
|
|
28
27
|
};
|
|
29
28
|
const renderValueAsText = (value, defaultContent) => {
|
|
30
29
|
return props.type === "date" ? value ? formatDate(value) : defaultContent : value ? value : defaultContent;
|
|
31
30
|
};
|
|
32
31
|
const getErrorElementId = () => {
|
|
33
|
-
return
|
|
32
|
+
return `${props.id}-errorMessage`;
|
|
34
33
|
};
|
|
35
34
|
const getInputElementProps = (defaultValue, defaultKey, styleRules) => {
|
|
36
|
-
var _props$errorMessage, _props$ariaDescribed;
|
|
37
35
|
return {
|
|
38
36
|
name: props.name,
|
|
39
37
|
readOnly: props.readOnly,
|
|
@@ -42,7 +40,7 @@ const InputField = props => {
|
|
|
42
40
|
type: props.type,
|
|
43
41
|
role: props.role,
|
|
44
42
|
id: props.id,
|
|
45
|
-
key: defaultKey ||
|
|
43
|
+
key: defaultKey || `${props.id}-${(0, _generators.generateRandomString)(6)}`,
|
|
46
44
|
min: props.min || null,
|
|
47
45
|
max: props.max || null,
|
|
48
46
|
onChange: props.onChange,
|
|
@@ -50,7 +48,7 @@ const InputField = props => {
|
|
|
50
48
|
[defaultValue ? "defaultValue" : "value"]: defaultValue || props.value,
|
|
51
49
|
placeholder: props.placeholder || null,
|
|
52
50
|
className: props.hasErrors ? _InputFieldModule.default.hasErrors : null,
|
|
53
|
-
"aria-describedby": props.hasErrors && !!
|
|
51
|
+
"aria-describedby": props.hasErrors && !!props.errorMessage?.length ? getErrorElementId() : !!props["aria-describedby"]?.length ? props["aria-describedby"] : null,
|
|
54
52
|
"aria-invalid": props.hasErrors ? "true" : null,
|
|
55
53
|
"aria-autocomplete": props["aria-autocomplete"] || null,
|
|
56
54
|
style: styleRules
|
|
@@ -59,7 +57,7 @@ const InputField = props => {
|
|
|
59
57
|
const defaultValue = props.defaultValue ? props.defaultValue : props.value || null;
|
|
60
58
|
const defaultKey = props.elementKey || null;
|
|
61
59
|
const styleRules = {
|
|
62
|
-
...(
|
|
60
|
+
...(props.width?.length && {
|
|
63
61
|
maxWidth: props.width
|
|
64
62
|
})
|
|
65
63
|
};
|
|
@@ -1,4 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
// Mixins
|
|
2
|
+
@use "../style/abstracts/mixins/appearance";
|
|
3
|
+
@use "../style/abstracts/mixins/border-radius";
|
|
4
|
+
@use "../style/abstracts/mixins/box-shadow";
|
|
5
|
+
|
|
6
|
+
// Variables
|
|
7
|
+
@use "../style/abstracts/variables/colors";
|
|
2
8
|
|
|
3
9
|
.inputField {
|
|
4
10
|
font-size: 18px;
|
|
@@ -17,9 +23,9 @@
|
|
|
17
23
|
}
|
|
18
24
|
input,
|
|
19
25
|
&.file span.input {
|
|
20
|
-
@include appearance(none);
|
|
21
|
-
@include border-radius(0);
|
|
22
|
-
@include box-shadow(none);
|
|
26
|
+
@include appearance.appearance(none);
|
|
27
|
+
@include border-radius.border-radius(0);
|
|
28
|
+
@include box-shadow.box-shadow(none);
|
|
23
29
|
height: 54px;
|
|
24
30
|
width: 100%;
|
|
25
31
|
display: block;
|
|
@@ -27,36 +33,36 @@
|
|
|
27
33
|
margin-bottom: 0;
|
|
28
34
|
background-color: #fff;
|
|
29
35
|
box-shadow: none;
|
|
30
|
-
color:
|
|
36
|
+
color: colors.$color-default-text;
|
|
31
37
|
font-family: inherit;
|
|
32
38
|
font-size: 18px;
|
|
33
39
|
box-sizing: border-box;
|
|
34
|
-
border: 1px solid var(--color-primary,
|
|
40
|
+
border: 1px solid var(--color-primary, colors.$color-primary);
|
|
35
41
|
|
|
36
42
|
&:hover {
|
|
37
|
-
border-color: var(--color-primary,
|
|
43
|
+
border-color: var(--color-primary, colors.$color-primary);
|
|
38
44
|
}
|
|
39
45
|
|
|
40
46
|
&:focus {
|
|
41
|
-
border-color: var(--color-primary,
|
|
42
|
-
outline:
|
|
47
|
+
border-color: var(--color-primary, colors.$color-primary);
|
|
48
|
+
outline: colors.$color-focus solid 3px;
|
|
43
49
|
}
|
|
44
50
|
|
|
45
51
|
&[disabled],
|
|
46
52
|
&[readonly] {
|
|
47
|
-
background-color: var(--color-secondary-x-light,
|
|
53
|
+
background-color: var(--color-secondary-x-light, colors.$color-secondary-x-light);
|
|
48
54
|
cursor: default;
|
|
49
55
|
}
|
|
50
56
|
|
|
51
57
|
&.hasErrors {
|
|
52
|
-
border-color: var(--color-error,
|
|
58
|
+
border-color: var(--color-error, colors.$color-error);
|
|
53
59
|
&:focus {
|
|
54
|
-
border-color: var(--color-error,
|
|
60
|
+
border-color: var(--color-error, colors.$color-error);
|
|
55
61
|
outline-color: #b8565d;
|
|
56
62
|
}
|
|
57
63
|
&[disabled],
|
|
58
64
|
&[readonly] {
|
|
59
|
-
background-color: var(--color-secondary-x-light,
|
|
65
|
+
background-color: var(--color-secondary-x-light, colors.$color-secondary-x-light);
|
|
60
66
|
cursor: default;
|
|
61
67
|
border-color: #afaba8;
|
|
62
68
|
}
|
package/dist/components/Label.js
CHANGED
|
@@ -7,17 +7,16 @@ exports.default = void 0;
|
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
9
|
var _LabelModule = _interopRequireDefault(require("./Label.module.scss"));
|
|
10
|
-
function _interopRequireDefault(
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
11
|
const Label = props => {
|
|
12
|
-
var _props$htmlTag;
|
|
13
12
|
let labelProps = {
|
|
14
13
|
...props
|
|
15
14
|
};
|
|
16
|
-
const htmlTag =
|
|
15
|
+
const htmlTag = props.htmlTag?.length ? props.htmlTag : "label";
|
|
17
16
|
delete labelProps.inline;
|
|
18
17
|
delete labelProps.normalCursor;
|
|
19
18
|
delete labelProps.htmlTag;
|
|
20
|
-
const className =
|
|
19
|
+
const className = `${_LabelModule.default.label} ${props.inline ? _LabelModule.default.inline : ""} ${props.normalCursor ? _LabelModule.default.normalCursor : ""}`;
|
|
21
20
|
const labelElement = _react.default.createElement(htmlTag, {
|
|
22
21
|
...labelProps,
|
|
23
22
|
className,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
// Variables
|
|
2
|
+
@use "../style/abstracts/variables/typography";
|
|
2
3
|
|
|
3
4
|
.label {
|
|
4
5
|
color: #000;
|
|
@@ -7,7 +8,7 @@
|
|
|
7
8
|
font-weight: bold;
|
|
8
9
|
line-height: 1.2;
|
|
9
10
|
margin-bottom: 2px;
|
|
10
|
-
font-family:
|
|
11
|
+
font-family: typography.$default-font;
|
|
11
12
|
overflow-wrap: break-word;
|
|
12
13
|
&.inline {
|
|
13
14
|
display: inline-block;
|
package/dist/components/Lead.js
CHANGED
|
@@ -7,7 +7,7 @@ exports.default = void 0;
|
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
9
|
var _LeadModule = _interopRequireDefault(require("./Lead.module.scss"));
|
|
10
|
-
function _interopRequireDefault(
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
11
|
const Lead = _ref => {
|
|
12
12
|
let {
|
|
13
13
|
id,
|
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
|
|
1
|
+
// Variables
|
|
2
|
+
@use "../style/abstracts/variables/colors";
|
|
3
|
+
@use "../style/abstracts/variables/typography";
|
|
2
4
|
|
|
3
5
|
.lead {
|
|
4
|
-
font-family:
|
|
6
|
+
font-family: typography.$default-font;
|
|
5
7
|
font-size: 18px;
|
|
6
8
|
font-weight: 400;
|
|
7
9
|
line-height: 26px;
|
|
8
10
|
letter-spacing: 0.01em;
|
|
9
11
|
margin: 0 0 24px;
|
|
10
|
-
color: var(--color-heading-text,
|
|
12
|
+
color: var(--color-heading-text, colors.$color-heading-text);
|
|
11
13
|
}
|
package/dist/components/List.js
CHANGED
|
@@ -8,14 +8,14 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
8
8
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
9
|
var _helpers = require("../functions/helpers");
|
|
10
10
|
var _ListModule = _interopRequireDefault(require("./List.module.scss"));
|
|
11
|
-
function _interopRequireDefault(
|
|
11
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
12
|
const List = props => {
|
|
13
13
|
const renderChildElements = childElements => {
|
|
14
14
|
const childElementsthroughFragments = (0, _helpers.cloneThroughFragments)(childElements);
|
|
15
15
|
return childElementsthroughFragments.map((childElement, index) => {
|
|
16
16
|
const childElementCopy = _react.default.cloneElement(childElement, {
|
|
17
17
|
compact: props.compact,
|
|
18
|
-
key:
|
|
18
|
+
key: `listItem-${index}`
|
|
19
19
|
});
|
|
20
20
|
return childElementCopy;
|
|
21
21
|
});
|
|
@@ -25,7 +25,7 @@ const List = props => {
|
|
|
25
25
|
const defaultListStyle = props.ordered ? "decimal" : "disc";
|
|
26
26
|
const scssValueProperty = "--listStyle";
|
|
27
27
|
let listElement = _react.default.createElement(listType, {
|
|
28
|
-
className:
|
|
28
|
+
className: `${_ListModule.default.list} ${!!props.compact ? _ListModule.default.compact : ""}`,
|
|
29
29
|
style: {
|
|
30
30
|
[scssValueProperty]: props.listStyle || defaultListStyle
|
|
31
31
|
}
|
|
@@ -8,7 +8,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
8
8
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
9
|
var _helpers = require("../functions/helpers");
|
|
10
10
|
var _ListItemModule = _interopRequireDefault(require("./ListItem.module.scss"));
|
|
11
|
-
function _interopRequireDefault(
|
|
11
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
12
|
const ListItem = _ref => {
|
|
13
13
|
let {
|
|
14
14
|
compact,
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
// Variables
|
|
2
|
+
@use "../style/abstracts/variables/colors";
|
|
2
3
|
|
|
3
4
|
.listItem {
|
|
4
5
|
line-height: 1.6;
|
|
5
|
-
color: var(--color-form-element,
|
|
6
|
+
color: var(--color-form-element, colors.$color-form-element);
|
|
6
7
|
&.compact {
|
|
7
8
|
line-height: 1.4;
|
|
8
9
|
}
|
|
@@ -7,7 +7,7 @@ exports.default = void 0;
|
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
9
|
var _LoadingAnimationModule = _interopRequireDefault(require("./LoadingAnimation.module.scss"));
|
|
10
|
-
function _interopRequireDefault(
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
11
|
const LoadingAnimation = props => {
|
|
12
12
|
return _react.default.createElement("div", {
|
|
13
13
|
className: props.fixed ? _LoadingAnimationModule.default.loadingAnimation + " " + _LoadingAnimationModule.default.fixed : _LoadingAnimationModule.default.loadingAnimation
|
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
// Mixins
|
|
2
|
+
@use "../style/abstracts/mixins/box-shadow";
|
|
3
|
+
@use "../style/abstracts/mixins/calc";
|
|
2
4
|
|
|
3
5
|
.loadingAnimation {
|
|
4
|
-
@include box-shadow(0 8px 17px 0 rgba(0, 0, 0, 0.2));
|
|
6
|
+
@include box-shadow.box-shadow(0 8px 17px 0 rgba(0, 0, 0, 0.2));
|
|
5
7
|
z-index: 6;
|
|
6
8
|
background-repeat: no-repeat;
|
|
7
9
|
background-position: 50% 15px;
|
|
@@ -14,7 +16,7 @@
|
|
|
14
16
|
display: block;
|
|
15
17
|
text-align: center;
|
|
16
18
|
&.fixed {
|
|
17
|
-
@include calc(left, "50% - 100px");
|
|
19
|
+
@include calc.calc(left, "50% - 100px");
|
|
18
20
|
top: 40%;
|
|
19
21
|
margin: auto;
|
|
20
22
|
position: fixed;
|
|
@@ -12,12 +12,11 @@ var _helpers = require("../functions/helpers");
|
|
|
12
12
|
var _dibkLogoMobile = _interopRequireDefault(require("../assets/svg/dibk-logo-mobile.svg?url"));
|
|
13
13
|
var _dibkLogo = _interopRequireDefault(require("../assets/svg/dibk-logo.svg?url"));
|
|
14
14
|
var _NavigationBarModule = _interopRequireDefault(require("./NavigationBar.module.scss"));
|
|
15
|
-
function _interopRequireDefault(
|
|
15
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
16
16
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
17
17
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
18
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (
|
|
18
|
+
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
19
19
|
const NavigationBar = props => {
|
|
20
|
-
var _props$primaryListIte, _props$secondaryListI, _props$mainContentId;
|
|
21
20
|
const [active, setActive] = (0, _react.useState)(false);
|
|
22
21
|
const toggleList = () => {
|
|
23
22
|
setActive(!active);
|
|
@@ -44,7 +43,7 @@ const NavigationBar = props => {
|
|
|
44
43
|
});
|
|
45
44
|
}
|
|
46
45
|
});
|
|
47
|
-
return !!
|
|
46
|
+
return !!listItems?.length && _react.default.createElement("ul", {
|
|
48
47
|
className: _NavigationBarModule.default.primaryList
|
|
49
48
|
}, listItems);
|
|
50
49
|
};
|
|
@@ -56,7 +55,7 @@ const NavigationBar = props => {
|
|
|
56
55
|
theme: props.theme
|
|
57
56
|
});
|
|
58
57
|
});
|
|
59
|
-
return !!
|
|
58
|
+
return !!listItems?.length && _react.default.createElement("ul", {
|
|
60
59
|
className: _NavigationBarModule.default.secondaryList
|
|
61
60
|
}, listItems);
|
|
62
61
|
};
|
|
@@ -67,7 +66,7 @@ const NavigationBar = props => {
|
|
|
67
66
|
if (logoLink && logoLinkTitle) {
|
|
68
67
|
return "";
|
|
69
68
|
} else if (themeLogo && themeAppName) {
|
|
70
|
-
return
|
|
69
|
+
return `${themeAppName} logo`;
|
|
71
70
|
} else {
|
|
72
71
|
return "DIBK logo";
|
|
73
72
|
}
|
|
@@ -92,12 +91,12 @@ const NavigationBar = props => {
|
|
|
92
91
|
title: logoLinkTitle
|
|
93
92
|
}), renderLogoElement()) : renderLogoElement();
|
|
94
93
|
};
|
|
95
|
-
const hasListItems = !!
|
|
94
|
+
const hasListItems = !!props.primaryListItems?.length || !!props.secondaryListItems?.length;
|
|
96
95
|
return _react.default.createElement("div", {
|
|
97
96
|
className: (0, _helpers.classNameArrayToClassNameString)([props.compact && _NavigationBarModule.default.compact, _NavigationBarModule.default.navigationBarContainer])
|
|
98
|
-
},
|
|
97
|
+
}, props.mainContentId?.length && _react.default.createElement("a", {
|
|
99
98
|
id: "main-content-link",
|
|
100
|
-
href:
|
|
99
|
+
href: `#${props.mainContentId}`,
|
|
101
100
|
className: _NavigationBarModule.default.mainContentLink
|
|
102
101
|
}, _react.default.createElement("span", {
|
|
103
102
|
id: "main-content-link-text"
|
|
@@ -109,7 +108,7 @@ const NavigationBar = props => {
|
|
|
109
108
|
className: _NavigationBarModule.default.childElements
|
|
110
109
|
}, props.children), hasListItems && _react.default.createElement("button", {
|
|
111
110
|
type: "button",
|
|
112
|
-
className:
|
|
111
|
+
className: `${_NavigationBarModule.default.menuToggle} ${active ? _NavigationBarModule.default.active : ""}`,
|
|
113
112
|
onClick: () => toggleList(),
|
|
114
113
|
"aria-expanded": active ? "true" : "false",
|
|
115
114
|
"aria-controls": "main-menu-dropdown"
|