dibk-design 0.4.45 → 0.4.48
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/LICENSE +674 -674
- package/README.md +3 -3
- package/dist/components/Accordion.md +15 -15
- package/dist/components/Accordion.module.scss +205 -205
- package/dist/components/Button.md +75 -75
- package/dist/components/Button.module.scss +232 -232
- package/dist/components/CheckBoxIcon.md +38 -38
- package/dist/components/CheckBoxIcon.module.scss +62 -62
- package/dist/components/CheckBoxInput.md +58 -58
- package/dist/components/CheckBoxInput.module.scss +24 -24
- package/dist/components/CheckBoxListItem.md +82 -82
- package/dist/components/CheckBoxListItem.module.scss +71 -71
- package/dist/components/Container.js +64 -0
- package/dist/components/Container.md +7 -0
- package/dist/components/Container.module.scss +10 -0
- package/dist/components/ContentBox.md +46 -46
- package/dist/components/ContentBox.module.scss +116 -116
- package/dist/components/Dialog.md +5 -5
- package/dist/components/Dialog.module.scss +78 -78
- package/dist/components/DragAndDropFileInput.js +8 -4
- package/dist/components/DragAndDropFileInput.md +13 -13
- package/dist/components/DragAndDropFileInput.module.scss +36 -45
- package/dist/components/ErrorMessage.js +80 -0
- package/dist/components/ErrorMessage.md +15 -0
- package/dist/components/ErrorMessage.module.scss +16 -0
- package/dist/components/Footer.js +3 -3
- package/dist/components/Footer.md +7 -7
- package/dist/components/Footer.module.scss +20 -11
- package/dist/components/Header.md +11 -11
- package/dist/components/Header.module.scss +64 -64
- package/dist/components/InputField.js +6 -11
- package/dist/components/InputField.md +41 -41
- package/dist/components/InputField.module.scss +81 -95
- package/dist/components/Label.md +9 -9
- package/dist/components/Label.module.scss +16 -16
- package/dist/components/List.md +10 -10
- package/dist/components/List.module.scss +18 -18
- package/dist/components/LoadingAnimation.md +5 -5
- package/dist/components/LoadingAnimation.module.scss +26 -26
- package/dist/components/NavigationBar.md +42 -42
- package/dist/components/NavigationBar.module.scss +176 -176
- package/dist/components/NavigationBarListItem.md +15 -15
- package/dist/components/Paper.md +9 -9
- package/dist/components/Paper.module.scss +18 -18
- package/dist/components/ProgressBar.js +31 -0
- package/dist/components/ProgressBar.md +13 -0
- package/dist/components/ProgressBar.module.scss +37 -0
- package/dist/components/RadioButtonIcon.js +101 -101
- package/dist/components/RadioButtonIcon.md +41 -41
- package/dist/components/RadioButtonIcon.module.scss +44 -44
- package/dist/components/RadioButtonInput.js +97 -97
- package/dist/components/RadioButtonInput.md +32 -32
- package/dist/components/RadioButtonInput.module.scss +26 -26
- package/dist/components/RadioButtonListItem.md +70 -70
- package/dist/components/RadioButtonListItem.module.scss +71 -71
- package/dist/components/Select.js +6 -11
- package/dist/components/Select.md +28 -28
- package/dist/components/Select.module.scss +86 -100
- package/dist/components/Textarea.js +6 -11
- package/dist/components/Textarea.md +27 -27
- package/dist/components/Textarea.module.scss +58 -72
- package/dist/components/Theme.md +12 -12
- package/dist/components/Theme.module.scss +76 -76
- package/dist/components/WizardNavigation/Step.module.scss +75 -75
- package/dist/components/WizardNavigation.md +84 -84
- package/dist/components/WizardNavigation.module.scss +3 -3
- package/dist/fonts/Altis-Light.svg +326 -326
- package/dist/fonts/open-sans-v27-latin-ext_latin-300.svg +346 -346
- package/dist/fonts/open-sans-v27-latin-ext_latin-300italic.svg +377 -377
- package/dist/fonts/open-sans-v27-latin-ext_latin-700.svg +349 -349
- package/dist/fonts/open-sans-v27-latin-ext_latin-700italic.svg +379 -379
- package/dist/fonts/open-sans-v27-latin-ext_latin-italic.svg +379 -379
- package/dist/fonts/open-sans-v27-latin-ext_latin-regular.svg +349 -349
- package/dist/images/dibk-logo-mobile.svg +91 -91
- package/dist/images/dibk-logo.svg +991 -991
- package/dist/images/spinner.svg +56 -56
- package/dist/index.js +24 -0
- package/dist/style/abstracts/_all.scss +1 -1
- package/dist/style/abstracts/mixins/_all.scss +12 -12
- package/dist/style/abstracts/mixins/_animation.scss +6 -6
- package/dist/style/abstracts/mixins/_appearance.scss +5 -5
- package/dist/style/abstracts/mixins/_border-radius.scss +31 -31
- package/dist/style/abstracts/mixins/_box-shadow.scss +5 -5
- package/dist/style/abstracts/mixins/_box-sizing.scss +5 -5
- package/dist/style/abstracts/mixins/_calc.scss +5 -5
- package/dist/style/abstracts/mixins/_keyframes.scss +14 -14
- package/dist/style/abstracts/mixins/_opacity.scss +5 -5
- package/dist/style/abstracts/mixins/_placeholder.scss +17 -17
- package/dist/style/abstracts/mixins/_scrollbar.scss +26 -26
- package/dist/style/abstracts/mixins/_transform.scss +6 -6
- package/dist/style/abstracts/mixins/_transition.scss +34 -34
- package/dist/style/abstracts/variables/_all.scss +2 -2
- package/dist/style/abstracts/variables/_colors.scss +28 -29
- package/dist/style/abstracts/variables/_typography.scss +1 -1
- package/dist/style/abstracts/variables/_viewports.scss +14 -14
- package/dist/style/base/_all.scss +1 -1
- package/dist/style/base/_reset.scss +15 -15
- package/dist/style/base/_typography.scss +6 -6
- package/dist/style/base/fonts.css +95 -95
- package/dist/style/global.scss +3 -3
- package/dist/style/layout/_containers.scss +9 -9
- package/package.json +43 -43
|
@@ -1,58 +1,58 @@
|
|
|
1
|
-
Checkbox input example:
|
|
2
|
-
|
|
3
|
-
```js
|
|
4
|
-
<div className="flex">
|
|
5
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-1" checked={true}>
|
|
6
|
-
<span>Label for checked checkbox</span>
|
|
7
|
-
</CheckBoxInput>
|
|
8
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-2" checked={true} disabled={true}>
|
|
9
|
-
<span>Label for checked disabled checkbox</span>
|
|
10
|
-
</CheckBoxInput>
|
|
11
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-3">
|
|
12
|
-
<span>Label for unchecked checkbox</span>
|
|
13
|
-
</CheckBoxInput>
|
|
14
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-4" checked={true} contentOnly={true}>
|
|
15
|
-
<span>Checked checkbox with content only</span>
|
|
16
|
-
</CheckBoxInput>
|
|
17
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-5" contentOnly={true}>
|
|
18
|
-
<span>Unchecked checkbox with content only</span>
|
|
19
|
-
</CheckBoxInput>
|
|
20
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-6" checked={true} checkmarkCharacter="✕">
|
|
21
|
-
<span>Label for checked checkbox with custom checkmark</span>
|
|
22
|
-
</CheckBoxInput>
|
|
23
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-7" checked={true} checkmarkCharacter="✕" expandable={true}>
|
|
24
|
-
<span>Label for checkbox with aria-expanded true</span>
|
|
25
|
-
</CheckBoxInput>
|
|
26
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-8" checked={false} checkmarkCharacter="✕" expandable={true}>
|
|
27
|
-
<span>Label for checkbox with aria-expanded false</span>
|
|
28
|
-
</CheckBoxInput>
|
|
29
|
-
|
|
30
|
-
</div>
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
Themed Checkbox input example:
|
|
35
|
-
|
|
36
|
-
```js
|
|
37
|
-
import customTheme from 'data/customTheme';
|
|
38
|
-
<div className="flex">
|
|
39
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkBoxInput-1" checked={true} theme={customTheme}>
|
|
40
|
-
<span>Label for checked checkbox</span>
|
|
41
|
-
</CheckBoxInput>
|
|
42
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkBoxInput-2" checked={true} disabled={true} theme={customTheme}>
|
|
43
|
-
<span>Label for checked disabled checkbox</span>
|
|
44
|
-
</CheckBoxInput>
|
|
45
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkBoxInput-3" theme={customTheme}>
|
|
46
|
-
<span>Label for unchecked checkbox</span>
|
|
47
|
-
</CheckBoxInput>
|
|
48
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkBoxInput-4" checked={true} contentOnly={true} theme={customTheme}>
|
|
49
|
-
<span>Checked checkbox with content only</span>
|
|
50
|
-
</CheckBoxInput>
|
|
51
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkBoxInput-5" contentOnly={true} theme={customTheme}>
|
|
52
|
-
<span>Unchecked checkbox with content only</span>
|
|
53
|
-
</CheckBoxInput>
|
|
54
|
-
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="themed-checkBoxInput-6" checked={true} checkmarkCharacter="✕" theme={customTheme}>
|
|
55
|
-
<span>Label for checked checkbox with custom checkmark</span>
|
|
56
|
-
</CheckBoxInput>
|
|
57
|
-
</div>
|
|
58
|
-
```
|
|
1
|
+
Checkbox input example:
|
|
2
|
+
|
|
3
|
+
```js
|
|
4
|
+
<div className="flex">
|
|
5
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-1" checked={true}>
|
|
6
|
+
<span>Label for checked checkbox</span>
|
|
7
|
+
</CheckBoxInput>
|
|
8
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-2" checked={true} disabled={true}>
|
|
9
|
+
<span>Label for checked disabled checkbox</span>
|
|
10
|
+
</CheckBoxInput>
|
|
11
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-3">
|
|
12
|
+
<span>Label for unchecked checkbox</span>
|
|
13
|
+
</CheckBoxInput>
|
|
14
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-4" checked={true} contentOnly={true}>
|
|
15
|
+
<span>Checked checkbox with content only</span>
|
|
16
|
+
</CheckBoxInput>
|
|
17
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-5" contentOnly={true}>
|
|
18
|
+
<span>Unchecked checkbox with content only</span>
|
|
19
|
+
</CheckBoxInput>
|
|
20
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-6" checked={true} checkmarkCharacter="✕">
|
|
21
|
+
<span>Label for checked checkbox with custom checkmark</span>
|
|
22
|
+
</CheckBoxInput>
|
|
23
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-7" checked={true} checkmarkCharacter="✕" expandable={true}>
|
|
24
|
+
<span>Label for checkbox with aria-expanded true</span>
|
|
25
|
+
</CheckBoxInput>
|
|
26
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="checkBoxInput-8" checked={false} checkmarkCharacter="✕" expandable={true}>
|
|
27
|
+
<span>Label for checkbox with aria-expanded false</span>
|
|
28
|
+
</CheckBoxInput>
|
|
29
|
+
|
|
30
|
+
</div>
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
Themed Checkbox input example:
|
|
35
|
+
|
|
36
|
+
```js
|
|
37
|
+
import customTheme from 'data/customTheme';
|
|
38
|
+
<div className="flex">
|
|
39
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkBoxInput-1" checked={true} theme={customTheme}>
|
|
40
|
+
<span>Label for checked checkbox</span>
|
|
41
|
+
</CheckBoxInput>
|
|
42
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkBoxInput-2" checked={true} disabled={true} theme={customTheme}>
|
|
43
|
+
<span>Label for checked disabled checkbox</span>
|
|
44
|
+
</CheckBoxInput>
|
|
45
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkBoxInput-3" theme={customTheme}>
|
|
46
|
+
<span>Label for unchecked checkbox</span>
|
|
47
|
+
</CheckBoxInput>
|
|
48
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkBoxInput-4" checked={true} contentOnly={true} theme={customTheme}>
|
|
49
|
+
<span>Checked checkbox with content only</span>
|
|
50
|
+
</CheckBoxInput>
|
|
51
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkBoxInput-5" contentOnly={true} theme={customTheme}>
|
|
52
|
+
<span>Unchecked checkbox with content only</span>
|
|
53
|
+
</CheckBoxInput>
|
|
54
|
+
<CheckBoxInput onChange={()=>{console.log('onchange')}} name="checkbox" id="themed-checkBoxInput-6" checked={true} checkmarkCharacter="✕" theme={customTheme}>
|
|
55
|
+
<span>Label for checked checkbox with custom checkmark</span>
|
|
56
|
+
</CheckBoxInput>
|
|
57
|
+
</div>
|
|
58
|
+
```
|
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
@import "../style/global.scss";
|
|
2
|
-
|
|
3
|
-
:local(.checkBoxInput) {
|
|
4
|
-
display: flex;
|
|
5
|
-
margin-right: 1em;
|
|
6
|
-
|
|
7
|
-
&:not(:local(.contentOnly)):not(:local(.disabled)) {
|
|
8
|
-
cursor: pointer;
|
|
9
|
-
input {
|
|
10
|
-
cursor: pointer;
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
&:local(.hasErrors) {
|
|
15
|
-
span {
|
|
16
|
-
color: #9d2024;
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
input[type="checkbox"] {
|
|
21
|
-
opacity: 0;
|
|
22
|
-
position: absolute;
|
|
23
|
-
}
|
|
24
|
-
}
|
|
1
|
+
@import "../style/global.scss";
|
|
2
|
+
|
|
3
|
+
:local(.checkBoxInput) {
|
|
4
|
+
display: flex;
|
|
5
|
+
margin-right: 1em;
|
|
6
|
+
|
|
7
|
+
&:not(:local(.contentOnly)):not(:local(.disabled)) {
|
|
8
|
+
cursor: pointer;
|
|
9
|
+
input {
|
|
10
|
+
cursor: pointer;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
&:local(.hasErrors) {
|
|
15
|
+
span {
|
|
16
|
+
color: #9d2024;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
input[type="checkbox"] {
|
|
21
|
+
opacity: 0;
|
|
22
|
+
position: absolute;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
@@ -1,82 +1,82 @@
|
|
|
1
|
-
Check box list item example:
|
|
2
|
-
|
|
3
|
-
```js
|
|
4
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="checkboxListItem-1">
|
|
5
|
-
Label for checked checkbox
|
|
6
|
-
</CheckBoxListItem>
|
|
7
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="checkbox" id="checkboxListItem-2">
|
|
8
|
-
Label for unchecked checkbox
|
|
9
|
-
</CheckBoxListItem>
|
|
10
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="checkboxListItem-3" contentOnly={true}>
|
|
11
|
-
Label for checked checkbox with content only
|
|
12
|
-
</CheckBoxListItem>
|
|
13
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="checkbox" id="checkboxListItem-4" contentOnly={true}>
|
|
14
|
-
Label for unchecked checkbox with content only
|
|
15
|
-
</CheckBoxListItem>
|
|
16
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="checkboxListItem-5" checkmarkCharacter="✕">
|
|
17
|
-
Label for checked checkbox with custom checkmark
|
|
18
|
-
</CheckBoxListItem>
|
|
19
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="checkboxListItem-6" disabled={true}>
|
|
20
|
-
Label for disabled checked checkbox
|
|
21
|
-
</CheckBoxListItem>
|
|
22
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="checkbox" id="checkboxListItem-7" disabled={true}>
|
|
23
|
-
Label for disabled unchecked checkbox
|
|
24
|
-
</CheckBoxListItem>
|
|
25
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="checkboxListItem-8" checkmarkCharacter="✕" disabled={true}>
|
|
26
|
-
Label for disabled checked checkbox with custom checkmark
|
|
27
|
-
</CheckBoxListItem>
|
|
28
|
-
```
|
|
29
|
-
|
|
30
|
-
Compact check box list item example:
|
|
31
|
-
|
|
32
|
-
```js
|
|
33
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="compact-checkboxListItem-1" compact>
|
|
34
|
-
Label for checked checkbox
|
|
35
|
-
</CheckBoxListItem>
|
|
36
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="checkbox" id="compact-checkboxListItem-2" compact>
|
|
37
|
-
Label for unchecked checkbox
|
|
38
|
-
</CheckBoxListItem>
|
|
39
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="compact-checkboxListItem-3" contentOnly={true} compact>
|
|
40
|
-
Label for checked checkbox with content only
|
|
41
|
-
</CheckBoxListItem>
|
|
42
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="checkbox" id="compact-checkboxListItem-4" contentOnly={true} compact>
|
|
43
|
-
Label for unchecked checkbox with content only
|
|
44
|
-
</CheckBoxListItem>
|
|
45
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="compact-checkboxListItem-5" compact hasErrors>
|
|
46
|
-
Label for checked checkbox with error
|
|
47
|
-
</CheckBoxListItem>
|
|
48
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="checkbox" id="compact-checkboxListItem-6" compact hasErrors>
|
|
49
|
-
Label for unchecked checkbox with error
|
|
50
|
-
</CheckBoxListItem>
|
|
51
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="compact-checkboxListItem-7" compact checkmarkCharacter="✕">
|
|
52
|
-
Label for checked checkbox with custom checkmark
|
|
53
|
-
</CheckBoxListItem>
|
|
54
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="compact-checkboxListItem-8" compact disabled={true}>
|
|
55
|
-
Label for disabled checked checkbox
|
|
56
|
-
</CheckBoxListItem>
|
|
57
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="compact-checkboxListItem-9" compact hasErrors disabled={true}>
|
|
58
|
-
Label for disabled checked checkbox with error
|
|
59
|
-
</CheckBoxListItem>
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
Themed Check box list item example:
|
|
63
|
-
```js
|
|
64
|
-
import customTheme from 'data/customTheme';
|
|
65
|
-
<React.Fragment>
|
|
66
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="themed-checkbox" id="themed-checkboxListItem-1" theme={customTheme}>
|
|
67
|
-
Label for checked checkbox
|
|
68
|
-
</CheckBoxListItem>
|
|
69
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkboxListItem-2" theme={customTheme}>
|
|
70
|
-
Label for unchecked checkbox
|
|
71
|
-
</CheckBoxListItem>
|
|
72
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="themed-checkbox" id="themed-checkboxListItem-3" contentOnly={true} theme={customTheme}>
|
|
73
|
-
Label for checked checkbox with content only
|
|
74
|
-
</CheckBoxListItem>
|
|
75
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkboxListItem-4" contentOnly={true} theme={customTheme}>
|
|
76
|
-
Label for unchecked checkbox with content only
|
|
77
|
-
</CheckBoxListItem>
|
|
78
|
-
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="themed-checkbox" id="themed-checkboxListItem-5" checkmarkCharacter="✕" theme={customTheme}>
|
|
79
|
-
Label for checked checkbox with custom checkmark
|
|
80
|
-
</CheckBoxListItem>
|
|
81
|
-
</React.Fragment>
|
|
82
|
-
```
|
|
1
|
+
Check box list item example:
|
|
2
|
+
|
|
3
|
+
```js
|
|
4
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="checkboxListItem-1">
|
|
5
|
+
Label for checked checkbox
|
|
6
|
+
</CheckBoxListItem>
|
|
7
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="checkbox" id="checkboxListItem-2">
|
|
8
|
+
Label for unchecked checkbox
|
|
9
|
+
</CheckBoxListItem>
|
|
10
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="checkboxListItem-3" contentOnly={true}>
|
|
11
|
+
Label for checked checkbox with content only
|
|
12
|
+
</CheckBoxListItem>
|
|
13
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="checkbox" id="checkboxListItem-4" contentOnly={true}>
|
|
14
|
+
Label for unchecked checkbox with content only
|
|
15
|
+
</CheckBoxListItem>
|
|
16
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="checkboxListItem-5" checkmarkCharacter="✕">
|
|
17
|
+
Label for checked checkbox with custom checkmark
|
|
18
|
+
</CheckBoxListItem>
|
|
19
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="checkboxListItem-6" disabled={true}>
|
|
20
|
+
Label for disabled checked checkbox
|
|
21
|
+
</CheckBoxListItem>
|
|
22
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="checkbox" id="checkboxListItem-7" disabled={true}>
|
|
23
|
+
Label for disabled unchecked checkbox
|
|
24
|
+
</CheckBoxListItem>
|
|
25
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="checkboxListItem-8" checkmarkCharacter="✕" disabled={true}>
|
|
26
|
+
Label for disabled checked checkbox with custom checkmark
|
|
27
|
+
</CheckBoxListItem>
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
Compact check box list item example:
|
|
31
|
+
|
|
32
|
+
```js
|
|
33
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="compact-checkboxListItem-1" compact>
|
|
34
|
+
Label for checked checkbox
|
|
35
|
+
</CheckBoxListItem>
|
|
36
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="checkbox" id="compact-checkboxListItem-2" compact>
|
|
37
|
+
Label for unchecked checkbox
|
|
38
|
+
</CheckBoxListItem>
|
|
39
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="compact-checkboxListItem-3" contentOnly={true} compact>
|
|
40
|
+
Label for checked checkbox with content only
|
|
41
|
+
</CheckBoxListItem>
|
|
42
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="checkbox" id="compact-checkboxListItem-4" contentOnly={true} compact>
|
|
43
|
+
Label for unchecked checkbox with content only
|
|
44
|
+
</CheckBoxListItem>
|
|
45
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="compact-checkboxListItem-5" compact hasErrors>
|
|
46
|
+
Label for checked checkbox with error
|
|
47
|
+
</CheckBoxListItem>
|
|
48
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="checkbox" id="compact-checkboxListItem-6" compact hasErrors>
|
|
49
|
+
Label for unchecked checkbox with error
|
|
50
|
+
</CheckBoxListItem>
|
|
51
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="compact-checkboxListItem-7" compact checkmarkCharacter="✕">
|
|
52
|
+
Label for checked checkbox with custom checkmark
|
|
53
|
+
</CheckBoxListItem>
|
|
54
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="compact-checkboxListItem-8" compact disabled={true}>
|
|
55
|
+
Label for disabled checked checkbox
|
|
56
|
+
</CheckBoxListItem>
|
|
57
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="checkbox" id="compact-checkboxListItem-9" compact hasErrors disabled={true}>
|
|
58
|
+
Label for disabled checked checkbox with error
|
|
59
|
+
</CheckBoxListItem>
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
Themed Check box list item example:
|
|
63
|
+
```js
|
|
64
|
+
import customTheme from 'data/customTheme';
|
|
65
|
+
<React.Fragment>
|
|
66
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="themed-checkbox" id="themed-checkboxListItem-1" theme={customTheme}>
|
|
67
|
+
Label for checked checkbox
|
|
68
|
+
</CheckBoxListItem>
|
|
69
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkboxListItem-2" theme={customTheme}>
|
|
70
|
+
Label for unchecked checkbox
|
|
71
|
+
</CheckBoxListItem>
|
|
72
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="themed-checkbox" id="themed-checkboxListItem-3" contentOnly={true} theme={customTheme}>
|
|
73
|
+
Label for checked checkbox with content only
|
|
74
|
+
</CheckBoxListItem>
|
|
75
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} name="themed-checkbox" id="themed-checkboxListItem-4" contentOnly={true} theme={customTheme}>
|
|
76
|
+
Label for unchecked checkbox with content only
|
|
77
|
+
</CheckBoxListItem>
|
|
78
|
+
<CheckBoxListItem onChange={()=>{console.log('onchange')}} checked={true} name="themed-checkbox" id="themed-checkboxListItem-5" checkmarkCharacter="✕" theme={customTheme}>
|
|
79
|
+
Label for checked checkbox with custom checkmark
|
|
80
|
+
</CheckBoxListItem>
|
|
81
|
+
</React.Fragment>
|
|
82
|
+
```
|
|
@@ -1,71 +1,71 @@
|
|
|
1
|
-
@import "../style/global.scss";
|
|
2
|
-
|
|
3
|
-
:local(.checkBoxListItem) {
|
|
4
|
-
@include box-sizing(content-box);
|
|
5
|
-
@include border-radius(5px);
|
|
6
|
-
@include transition(all 0.1s ease-in-out);
|
|
7
|
-
display: -webkit-box;
|
|
8
|
-
display: -webkit-flex;
|
|
9
|
-
display: -ms-flexbox;
|
|
10
|
-
display: flex;
|
|
11
|
-
-webkit-align-items: flex-start;
|
|
12
|
-
-webkit-box-align: flex-start;
|
|
13
|
-
-ms-flex-align: flex-start;
|
|
14
|
-
align-items: flex-start;
|
|
15
|
-
cursor: pointer;
|
|
16
|
-
font-family: $default-font;
|
|
17
|
-
position: relative;
|
|
18
|
-
font-size: 17px;
|
|
19
|
-
color: #000;
|
|
20
|
-
|
|
21
|
-
&:not(:local(.contentOnly)):not(:local(.compact)) {
|
|
22
|
-
@include box-shadow(0 0 2px $color-dark-blue);
|
|
23
|
-
background: white;
|
|
24
|
-
margin-bottom: 10px;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
&:local(.contentOnly) {
|
|
28
|
-
cursor: auto;
|
|
29
|
-
label {
|
|
30
|
-
cursor: auto;
|
|
31
|
-
padding: 5px 10px;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
&:local(.disabled) {
|
|
36
|
-
label {
|
|
37
|
-
cursor: auto;
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
&:local(.checked):not(:local(.contentOnly)):not(:local(.compact)):not(:local(.disabled)) {
|
|
42
|
-
@include box-shadow(0 0 0 1px $color-dark-blue, 0 0 4px 0 $color-dark-blue);
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
&:not(:local(.checked)):not(:local(.contentOnly)):not(:local(.compact)):not(:local(.disabled)):hover {
|
|
46
|
-
@include box-shadow(0 0 6px $color-dark-blue);
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
&:focus {
|
|
50
|
-
outline-color: #54acb8;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
label {
|
|
54
|
-
width: 100%;
|
|
55
|
-
padding: 10px;
|
|
56
|
-
margin: 0;
|
|
57
|
-
cursor: pointer;
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
&:local(.compact) {
|
|
61
|
-
display: table;
|
|
62
|
-
label {
|
|
63
|
-
padding: 6px 4px;
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
input[type="checkbox"] {
|
|
68
|
-
opacity: 0;
|
|
69
|
-
position: absolute;
|
|
70
|
-
}
|
|
71
|
-
}
|
|
1
|
+
@import "../style/global.scss";
|
|
2
|
+
|
|
3
|
+
:local(.checkBoxListItem) {
|
|
4
|
+
@include box-sizing(content-box);
|
|
5
|
+
@include border-radius(5px);
|
|
6
|
+
@include transition(all 0.1s ease-in-out);
|
|
7
|
+
display: -webkit-box;
|
|
8
|
+
display: -webkit-flex;
|
|
9
|
+
display: -ms-flexbox;
|
|
10
|
+
display: flex;
|
|
11
|
+
-webkit-align-items: flex-start;
|
|
12
|
+
-webkit-box-align: flex-start;
|
|
13
|
+
-ms-flex-align: flex-start;
|
|
14
|
+
align-items: flex-start;
|
|
15
|
+
cursor: pointer;
|
|
16
|
+
font-family: $default-font;
|
|
17
|
+
position: relative;
|
|
18
|
+
font-size: 17px;
|
|
19
|
+
color: #000;
|
|
20
|
+
|
|
21
|
+
&:not(:local(.contentOnly)):not(:local(.compact)) {
|
|
22
|
+
@include box-shadow(0 0 2px $color-dark-blue);
|
|
23
|
+
background: white;
|
|
24
|
+
margin-bottom: 10px;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
&:local(.contentOnly) {
|
|
28
|
+
cursor: auto;
|
|
29
|
+
label {
|
|
30
|
+
cursor: auto;
|
|
31
|
+
padding: 5px 10px;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
&:local(.disabled) {
|
|
36
|
+
label {
|
|
37
|
+
cursor: auto;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
&:local(.checked):not(:local(.contentOnly)):not(:local(.compact)):not(:local(.disabled)) {
|
|
42
|
+
@include box-shadow(0 0 0 1px $color-dark-blue, 0 0 4px 0 $color-dark-blue);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
&:not(:local(.checked)):not(:local(.contentOnly)):not(:local(.compact)):not(:local(.disabled)):hover {
|
|
46
|
+
@include box-shadow(0 0 6px $color-dark-blue);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
&:focus {
|
|
50
|
+
outline-color: #54acb8;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
label {
|
|
54
|
+
width: 100%;
|
|
55
|
+
padding: 10px;
|
|
56
|
+
margin: 0;
|
|
57
|
+
cursor: pointer;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
&:local(.compact) {
|
|
61
|
+
display: table;
|
|
62
|
+
label {
|
|
63
|
+
padding: 6px 4px;
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
input[type="checkbox"] {
|
|
68
|
+
opacity: 0;
|
|
69
|
+
position: absolute;
|
|
70
|
+
}
|
|
71
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
+
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.default = void 0;
|
|
9
|
+
|
|
10
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
+
|
|
12
|
+
var _ContainerModule = _interopRequireDefault(require("./Container.module.scss"));
|
|
13
|
+
|
|
14
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
15
|
+
|
|
16
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
17
|
+
|
|
18
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
19
|
+
|
|
20
|
+
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
21
|
+
|
|
22
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
23
|
+
|
|
24
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
25
|
+
|
|
26
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
27
|
+
|
|
28
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
29
|
+
|
|
30
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
31
|
+
|
|
32
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
33
|
+
|
|
34
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
35
|
+
|
|
36
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
37
|
+
|
|
38
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
39
|
+
|
|
40
|
+
var Container = /*#__PURE__*/function (_Component) {
|
|
41
|
+
_inherits(Container, _Component);
|
|
42
|
+
|
|
43
|
+
var _super = _createSuper(Container);
|
|
44
|
+
|
|
45
|
+
function Container() {
|
|
46
|
+
_classCallCheck(this, Container);
|
|
47
|
+
|
|
48
|
+
return _super.apply(this, arguments);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
_createClass(Container, [{
|
|
52
|
+
key: "render",
|
|
53
|
+
value: function render() {
|
|
54
|
+
return /*#__PURE__*/_react.default.createElement("div", {
|
|
55
|
+
className: _ContainerModule.default.container
|
|
56
|
+
}, this.props.children);
|
|
57
|
+
}
|
|
58
|
+
}]);
|
|
59
|
+
|
|
60
|
+
return Container;
|
|
61
|
+
}(_react.Component);
|
|
62
|
+
|
|
63
|
+
var _default = Container;
|
|
64
|
+
exports.default = _default;
|