dso-toolkit 56.1.0 → 58.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.
Files changed (30) hide show
  1. package/CHANGELOG.md +39 -0
  2. package/dist/dso-icons.svg +155 -147
  3. package/dist/dso.css +444 -703
  4. package/package.json +1 -1
  5. package/src/components/accordion/accordion.scss +20 -7
  6. package/src/components/accordion/accordion.variables.scss +2 -0
  7. package/src/components/alert/alert.mixins.scss +2 -2
  8. package/src/components/button/button.mixins.scss +12 -5
  9. package/src/components/button/button.scss +0 -54
  10. package/src/components/button/button.variables.scss +2 -22
  11. package/src/components/button/readme.md +3 -3
  12. package/src/components/button-row/button-row.scss +0 -2
  13. package/src/components/dropdown-menu/dropdown-menu.mixins.scss +2 -4
  14. package/src/components/dropdown-menu/dropdown-menu.scss +6 -12
  15. package/src/components/form/form-buttons/form-buttons.scss +1 -2
  16. package/src/components/form/form-groups/files/form-group-files.scss +0 -4
  17. package/src/components/highlight-box/highlight-box.mixins.scss +2 -4
  18. package/src/components/info/info.mixins.scss +4 -4
  19. package/src/components/list/list.scss +32 -0
  20. package/src/components/list/readme.md +7 -0
  21. package/src/components/list-button/list-button.scss +3 -3
  22. package/src/components/modal/modal.mixins.scss +95 -59
  23. package/src/components/modal/modal.scss +12 -12
  24. package/src/components/navbar/_index.scss +1 -0
  25. package/src/components/navbar/navbar.mixins.scss +101 -0
  26. package/src/components/navbar/navbar.scss +6 -88
  27. package/src/components/shopping-cart/shopping-cart.scss +1 -2
  28. package/src/components/table/table.scss +1 -2
  29. package/src/global/spacing.scss +30 -0
  30. package/src/variables/zindex.scss +1 -1
@@ -19,46 +19,58 @@
19
19
  }
20
20
 
21
21
  @mixin root() {
22
- bottom: 0;
23
- height: 100%;
24
- left: 0;
25
- position: fixed;
26
- right: 0;
27
- top: 0;
28
- z-index: zindex.$modal;
22
+ // dialog
23
+ // ------
24
+ // overwrite UA styles:
25
+ overflow: visible;
26
+ padding: 0;
27
+ border: 0;
28
+
29
+ &::backdrop {
30
+ background-color: fade-out(modal-variables.$backdrop-bg, modal-variables.$backdrop-opacity);
31
+ }
29
32
 
30
33
  .dso-dialog {
31
- animation: 1s ease-out 0s 1 slideInFromTop;
34
+ max-inline-size: modal-variables.$max-width;
35
+
32
36
  background-color: modal-variables.$content-bg;
33
- box-shadow: 0 #{units.$u1} #{units.$u3} 0 rgba(25, 25, 25, 0.4);
34
- margin-left: auto;
35
- margin-right: auto;
36
- margin-top: clamp(#{units.$u5}, 15vh, 15vh);
37
- max-width: modal-variables.$max-width;
37
+
38
38
  opacity: 1;
39
+
40
+ box-shadow: 0 #{units.$u1} #{units.$u3} 0 rgba(25, 25, 25, 0.4);
41
+ animation: 1s ease-out 0s 1 slideInFromTop;
39
42
  }
40
43
 
41
44
  .dso-header {
42
- border-bottom: 1px solid modal-variables.$border-color;
43
- padding: modal-variables.$header-padding;
44
45
  position: relative;
45
46
 
47
+ padding: modal-variables.$header-padding;
48
+
49
+ border-block-end: 1px solid modal-variables.$border-color;
50
+
46
51
  h2 {
47
- color: colors.$bosgroen;
52
+ max-inline-size: calc(100% - #{units.$u3});
53
+
48
54
  margin: 0;
49
- max-width: calc(100% - #{units.$u3});
55
+
56
+ color: colors.$bosgroen;
50
57
  }
51
58
 
52
59
  .dso-close {
60
+ position: absolute;
61
+ inset-block-start: units.$u2;
62
+ inset-inline-end: 13px;
63
+
64
+ block-size: modal-variables.$close-icon-size;
65
+ inline-size: modal-variables.$close-icon-size;
66
+
67
+ padding: 0;
68
+
53
69
  background-color: transparent;
70
+
54
71
  border: 0;
55
- height: modal-variables.$close-icon-size;
56
- padding: 0;
57
- position: absolute;
58
- right: 13px;
72
+
59
73
  text-align: center;
60
- top: units.$u2;
61
- width: modal-variables.$close-icon-size;
62
74
  }
63
75
  }
64
76
 
@@ -68,10 +80,11 @@
68
80
 
69
81
  @include rich-content.children();
70
82
 
71
- height: calc(100% - #{modal-variables.$body-padding * 2 + units.$u4} - 1.5rem);
72
- max-height: calc(#{modal-variables.$max-height} - #{$dso-body-unavailable-height + units.$u4} - 1.5em);
73
- min-height: 1.5rem;
83
+ block-size: calc(100% - #{modal-variables.$body-padding * 2 + units.$u4} - 1.5rem);
84
+ max-block-size: calc(#{modal-variables.$max-height} - #{$dso-body-unavailable-height + units.$u4} - 1.5em);
85
+ min-block-size: 1.5rem;
74
86
  overflow-x: auto;
87
+
75
88
  padding: modal-variables.$body-padding;
76
89
  }
77
90
 
@@ -79,9 +92,9 @@
79
92
  $dso-body-unavailable-height: (2 * modal-variables.$header-padding) +
80
93
  (modal-variables.$footer-button-height + modal-variables.$footer-padding);
81
94
 
82
- height: calc(100% - #{modal-variables.$body-padding * 2 + units.$u4} - 1.5rem);
83
- max-height: calc(#{modal-variables.$max-height} - #{$dso-body-unavailable-height + units.$u4} - 1.5em);
84
- min-height: modal-variables.$body-min-height;
95
+ block-size: calc(100% - #{modal-variables.$body-padding * 2 + units.$u4} - 1.5rem);
96
+ max-block-size: calc(#{modal-variables.$max-height} - #{$dso-body-unavailable-height + units.$u4} - 1.5em);
97
+ min-block-size: modal-variables.$body-min-height;
85
98
 
86
99
  .dso-body {
87
100
  @include rich-content.children();
@@ -90,47 +103,56 @@
90
103
  }
91
104
  }
92
105
 
106
+ .dso-body {
107
+ &:focus-visible {
108
+ outline: none;
109
+ }
110
+ }
111
+
93
112
  .dso-footer {
94
113
  @include modal-wide-buttons();
95
114
 
96
- min-height: modal-variables.$footer-button-height + modal-variables.$footer-padding;
115
+ min-block-size: modal-variables.$footer-button-height + modal-variables.$footer-padding;
116
+
97
117
  padding: calc(modal-variables.$footer-padding / 2) modal-variables.$footer-padding;
98
- text-align: right;
118
+
119
+ text-align: end;
99
120
  }
100
121
 
101
122
  @media screen and (min-width: media-query-breakpoints.$screen-sm-min) {
102
123
  .dso-footer {
103
124
  #{button.$button-adjacent-secondary} {
104
- margin-left: units.$u2;
125
+ margin-inline-start: units.$u2;
105
126
  }
106
127
 
107
128
  #{button.$button-adjacent-tertiary} {
108
- margin-left: 0;
129
+ margin-inline-start: 0;
109
130
  }
110
131
  }
111
132
  }
112
133
 
113
134
  @media screen and (max-width: media-query-breakpoints.$screen-xs-max) {
114
135
  .dso-dialog {
115
- max-width: 100%;
116
- margin-top: 0;
136
+ max-inline-size: 100%;
137
+
138
+ margin-block-start: 0;
117
139
  }
118
140
 
119
141
  .dso-footer {
120
142
  #{button.$button-adjacent} {
121
- margin-left: 0;
143
+ margin-inline-start: 0;
122
144
  }
123
145
 
124
146
  button {
147
+ inline-size: 100%;
148
+
125
149
  text-align: center;
126
- width: 100%;
127
150
 
128
151
  + button {
129
- margin-top: units.$u1;
152
+ margin-block-start: units.$u1;
130
153
  }
131
154
 
132
- &.dso-tertiary,
133
- &.btn-link {
155
+ &.dso-tertiary {
134
156
  &,
135
157
  span {
136
158
  float: none;
@@ -143,16 +165,17 @@
143
165
  // special query for height
144
166
  @media screen and (max-height: modal-variables.$small-modal-vh) {
145
167
  .dso-dialog {
146
- margin-bottom: units.$u1;
147
- margin-top: units.$u1;
148
- min-height: modal-variables.$min-modal-height;
168
+ min-block-size: modal-variables.$min-modal-height;
169
+
170
+ margin-block-start: units.$u1;
171
+ margin-block-end: units.$u1;
149
172
  }
150
173
 
151
174
  .dso-header {
152
175
  padding: #{units.$u1} #{units.$u2};
153
176
 
154
177
  .dso-close {
155
- top: units.$u1;
178
+ inset-block-start: units.$u1;
156
179
  }
157
180
  }
158
181
 
@@ -161,8 +184,9 @@
161
184
  }
162
185
 
163
186
  .dso-footer {
164
- min-height: auto;
187
+ min-block-size: auto;
165
188
  overflow: auto;
189
+
166
190
  padding: modal-variables.$footer-padding-small-modal-vh modal-variables.$footer-padding;
167
191
  }
168
192
  }
@@ -171,19 +195,19 @@
171
195
  @mixin modal-wide-buttons() {
172
196
  @media screen and (max-width: media-query-breakpoints.$screen-xs-max) {
173
197
  #{button.$button-adjacent} {
174
- margin-left: 0;
198
+ margin-inline-start: 0;
175
199
  }
176
200
 
177
201
  button {
202
+ inline-size: 100%;
203
+
178
204
  text-align: center;
179
- width: 100%;
180
205
 
181
206
  + button {
182
- margin-top: units.$u1;
207
+ margin-block-start: units.$u1;
183
208
  }
184
209
 
185
- &.dso-tertiary,
186
- &.btn-link {
210
+ &.dso-tertiary {
187
211
  &,
188
212
  span {
189
213
  float: none;
@@ -193,13 +217,25 @@
193
217
  }
194
218
  }
195
219
 
196
- @mixin overlay() {
197
- background-color: fade-out(modal-variables.$backdrop-bg, modal-variables.$backdrop-opacity);
198
- bottom: 0;
199
- display: block;
200
- left: 0;
201
- position: fixed;
202
- right: 0;
203
- top: 0;
204
- z-index: zindex.$modal-background-overlay;
220
+ @mixin fullscreen() {
221
+ inline-size: 100dvi;
222
+ block-size: 100dvb;
223
+
224
+ .dso-dialog {
225
+ display: flex;
226
+ flex-direction: column;
227
+
228
+ max-inline-size: 100%;
229
+ block-size: 100%;
230
+
231
+ > dso-scrollable {
232
+ flex-grow: 1;
233
+
234
+ max-block-size: unset;
235
+ }
236
+ }
237
+
238
+ .dso-footer {
239
+ flex-shrink: 0;
240
+ }
205
241
  }
@@ -9,12 +9,6 @@
9
9
  body.dso-modal-open {
10
10
  @media screen and (min-width: media-query-breakpoints.$screen-sm-min) {
11
11
  overflow: hidden;
12
-
13
- &::before {
14
- @include modal.overlay();
15
-
16
- content: "";
17
- }
18
12
  }
19
13
 
20
14
  @media screen and (max-width: media-query-breakpoints.$screen-xs-max) {
@@ -29,6 +23,10 @@ body.dso-modal-open {
29
23
  .dso-modal {
30
24
  @include modal.root();
31
25
 
26
+ &.dso-fullscreen {
27
+ @include modal.fullscreen();
28
+ }
29
+
32
30
  .dso-close {
33
31
  &::before {
34
32
  @include di.base("times");
@@ -40,26 +38,28 @@ body.dso-modal-open {
40
38
  }
41
39
 
42
40
  .dso-footer {
43
- .dso-tertiary,
44
- .btn-link {
41
+ .dso-tertiary {
45
42
  float: left;
46
43
  line-height: calc(1.5em - 1px);
47
44
  padding: button.$vertical-padding 0;
48
45
  position: relative;
49
46
  }
50
47
  }
48
+
49
+ @media screen and (max-width: media-query-breakpoints.$screen-xs-min) {
50
+ @include modal.fullscreen();
51
+ }
51
52
  }
52
53
 
53
54
  dso-modal {
54
- *[slot="body"] {
55
+ [slot="body"] {
55
56
  @include rich-content.children();
56
57
  }
57
58
 
58
- div[slot="footer"] {
59
+ [slot="footer"] {
59
60
  @include modal.modal-wide-buttons();
60
61
 
61
- .dso-tertiary,
62
- .btn-link {
62
+ .dso-tertiary {
63
63
  float: left;
64
64
  line-height: calc(1.5em - 1px);
65
65
  padding: button.$vertical-padding 0;
@@ -1 +1,2 @@
1
+ @forward "navbar.mixins";
1
2
  @forward "navbar.variables";
@@ -0,0 +1,101 @@
1
+ @use "../../variables/units";
2
+ @use "../../variables/colors";
3
+ @use "../../variables/typography";
4
+ @use "../../variables/media-query-breakpoints";
5
+ @use "../anchor";
6
+ @use "./navbar.variables.scss" as navbar;
7
+
8
+ @mixin root() {
9
+ .dso-navbar {
10
+ min-height: units.$u4;
11
+
12
+ .dso-navbar-header {
13
+ float: left;
14
+ }
15
+
16
+ .dso-navbar-toggle {
17
+ border-radius: 4px;
18
+ min-width: auto;
19
+ padding: #{units.$padding-base-vertical - 1} 0;
20
+
21
+ dso-icon,
22
+ svg.di {
23
+ margin-left: units.$u1;
24
+ margin-right: units.$u1;
25
+ }
26
+
27
+ @media screen and (min-width: media-query-breakpoints.$screen-md-min) {
28
+ display: none;
29
+ }
30
+ }
31
+ }
32
+
33
+ .dso-nav {
34
+ list-style: none;
35
+ margin-bottom: 0;
36
+ padding-left: 0;
37
+
38
+ > li {
39
+ > a,
40
+ > button {
41
+ display: block;
42
+
43
+ &,
44
+ &:hover,
45
+ &:focus,
46
+ &:visited {
47
+ color: colors.$bosgroen;
48
+ }
49
+ }
50
+
51
+ &.dso-active,
52
+ &.is-active {
53
+ > a,
54
+ > button {
55
+ @include nav-item-border(navbar.$selected-color);
56
+
57
+ font-weight: bold;
58
+ }
59
+ }
60
+ }
61
+
62
+ &.dso-nav-main {
63
+ > li {
64
+ display: inline-block;
65
+
66
+ > a,
67
+ > button {
68
+ @include anchor.reverse();
69
+
70
+ font-size: 1.25em;
71
+ line-height: 1;
72
+ margin-top: units.$u1;
73
+ padding: units.$u1 units.$u2 #{units.$u1 - 1px};
74
+ }
75
+ }
76
+ }
77
+
78
+ &.dso-nav-sub {
79
+ > li {
80
+ display: inline-block;
81
+
82
+ > a,
83
+ > button {
84
+ @include anchor.reverse();
85
+
86
+ font-size: typography.$root-font-size-base;
87
+ margin-top: (units.$u1 * 0.5);
88
+ padding: (units.$u1 * 0.5) units.$u1 #{units.$u1 * 0.5 - 1px};
89
+ }
90
+ }
91
+ }
92
+ }
93
+ }
94
+
95
+ @mixin nav-item-border($color) {
96
+ border-bottom: 4px solid $color;
97
+ }
98
+
99
+ @mixin nav-border() {
100
+ border-bottom: 1px solid colors.$grijs-20;
101
+ }
@@ -1,21 +1,10 @@
1
- @use "../../variables/units";
2
- @use "../../variables/colors";
3
- @use "../../variables/typography";
4
1
  @use "../../variables/media-query-breakpoints";
5
- @use "../anchor";
6
- @use "../navbar";
7
2
 
8
- @mixin nav-item-border($color) {
9
- border-bottom: 4px solid $color;
10
- }
3
+ @use "./navbar.mixins" as navbar;
11
4
 
12
- .dso-navbar {
13
- min-height: units.$u4;
14
-
15
- .dso-navbar-header {
16
- float: left;
17
- }
5
+ @include navbar.root();
18
6
 
7
+ .dso-navbar {
19
8
  @media screen and (max-width: media-query-breakpoints.$screen-sm-max) {
20
9
  clear: left;
21
10
 
@@ -33,88 +22,17 @@
33
22
  }
34
23
  }
35
24
  }
36
-
37
- .dso-navbar-toggle {
38
- border-radius: 4px;
39
- min-width: auto;
40
- padding: #{units.$padding-base-vertical - 1} 0;
41
-
42
- dso-icon,
43
- svg.di {
44
- margin-left: units.$u1;
45
- margin-right: units.$u1;
46
- }
47
-
48
- @media screen and (min-width: media-query-breakpoints.$screen-md-min) {
49
- display: none;
50
- }
51
- }
52
-
53
- #state-switch:checked ~ .toolkit-example & > .dso-nav {
54
- display: block;
55
- }
56
25
  }
57
26
 
58
27
  .dso-nav {
59
- list-style: none;
60
- margin-bottom: 0;
61
- padding-left: 0;
62
-
63
28
  @media screen and (min-width: media-query-breakpoints.$screen-sm-min) {
64
- border-bottom: 1px solid colors.$grijs-20;
65
- }
66
-
67
- > li {
68
- > a {
69
- display: block;
70
-
71
- &,
72
- &:hover,
73
- &:focus,
74
- &:visited {
75
- color: colors.$bosgroen;
76
- }
77
- }
78
-
79
- &.dso-active,
80
- &.is-active {
81
- > a {
82
- @include nav-item-border(navbar.$selected-color);
83
-
84
- font-weight: bold;
85
- }
86
- }
29
+ @include navbar.nav-border();
87
30
  }
88
31
 
89
32
  &.dso-nav-main {
90
33
  > li {
91
- display: block;
92
-
93
- @media screen and (min-width: media-query-breakpoints.$screen-sm-min) {
94
- display: inline-block;
95
- }
96
-
97
- > a {
98
- @include anchor.reverse();
99
-
100
- font-size: 1.25em;
101
- line-height: 1;
102
- margin-top: units.$u1;
103
- padding: units.$u1 units.$u2 #{units.$u1 - 1px};
104
- }
105
- }
106
- }
107
-
108
- &.dso-nav-sub {
109
- > li {
110
- display: inline-block;
111
-
112
- > a {
113
- @include anchor.reverse();
114
-
115
- font-size: typography.$root-font-size-base;
116
- margin-top: (units.$u1 * 0.5);
117
- padding: (units.$u1 * 0.5) units.$u1 #{units.$u1 * 0.5 - 1px};
34
+ @media screen and (max-width: media-query-breakpoints.$screen-xs-max) {
35
+ display: block;
118
36
  }
119
37
  }
120
38
  }
@@ -178,8 +178,7 @@
178
178
  }
179
179
 
180
180
  // demo
181
- .dso-secondary,
182
- .btn-default {
181
+ .dso-secondary {
183
182
  font-size: 16px;
184
183
  padding: 6px 12px;
185
184
  }
@@ -41,8 +41,7 @@ table.table,
41
41
  max-width: 100%;
42
42
  width: 100%;
43
43
 
44
- .dso-tertiary,
45
- .btn-link {
44
+ .dso-tertiary {
46
45
  position: relative;
47
46
  top: -2px;
48
47
  white-space: nowrap; // stylelint-disable-line declaration-property-value-disallowed-list -- These actions are always accomponied by icons, we always want the icon next to the text
@@ -1,18 +1,25 @@
1
1
  @use "../variables/units.scss";
2
2
 
3
3
  // Create space between action list and form buttons
4
+ // -------------------------------------------------
4
5
  // To Do: integrate this with things to come within this file.
5
6
  :where(dso-action-list) + :where(.dso-form-buttons) {
6
7
  margin-block-start: units.$vertical-spacing-xlarge;
7
8
  }
8
9
 
9
10
  // Original spacing of dso-button-row
11
+ // ----------------------------------
10
12
  // To Do: re-evaluate vertical rhythm
11
13
  :where(.dso-button-row) {
12
14
  margin-block: units.$u2 units.$u4;
15
+
16
+ &:last-child {
17
+ margin-block-end: 0;
18
+ }
13
19
  }
14
20
 
15
21
  // within dso-highlight-box, create space for dso-button-row when preceded and/or followed by other elements
22
+ // ---------------------------------------------------------------------------------------------------------
16
23
  // To Do: integrate this with things to come within this file, and remove the wildcard!
17
24
  :where(dso-highlight-box),
18
25
  :where(.dso-highlight-box) {
@@ -25,3 +32,26 @@
25
32
  margin-block-start: units.$vertical-spacing-medium;
26
33
  }
27
34
  }
35
+
36
+ // TEMP fix for excessive whitespace within the accordion rich content
37
+ // To do: a more permanent solution for vertical rhythm!
38
+ .dso-accordion-section {
39
+ // specificity increase necessary..
40
+ &.dso-accordion-default,
41
+ &.dso-accordion-compact,
42
+ &.dso-accordion-neutral,
43
+ &.dso-accordion-compact-black {
44
+ .dso-rich-content {
45
+ ul ul {
46
+ margin-block-end: 0;
47
+ }
48
+ > :first-child {
49
+ margin-block-start: 0;
50
+ }
51
+
52
+ > :last-child {
53
+ margin-block-end: 0;
54
+ }
55
+ }
56
+ }
57
+ }
@@ -1,5 +1,5 @@
1
1
  $viewer-grid-sizing-buttons: -1;
2
- $viewer-grid-map-panel: 100;
2
+ $viewer-grid-main-panel: 100;
3
3
 
4
4
  $datepicker: 100;
5
5
  $datepicker-dialog: 210;