@nldd/design-system 0.16.2 → 0.17.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -1
- package/custom-elements.json +1376 -415
- package/dist/components/components.js +1438 -356
- package/dist/components/content/blockquote/blockquote.d.ts +11 -1
- package/dist/components/content/blockquote/blockquote.d.ts.map +1 -1
- package/dist/components/content/blockquote/blockquote.js +39 -0
- package/dist/components/content/blockquote/blockquote.js.map +1 -1
- package/dist/components/content/blockquote/blockquote.styles.d.ts.map +1 -1
- package/dist/components/content/blockquote/blockquote.styles.js +42 -1
- package/dist/components/content/blockquote/blockquote.styles.js.map +1 -1
- package/dist/components/content/icon/icon-gallery-status.d.ts.map +1 -1
- package/dist/components/content/icon/icon-gallery-status.js +7 -0
- package/dist/components/content/icon/icon-gallery-status.js.map +1 -1
- package/dist/components/content/icon/icon-registry.js +393 -393
- package/dist/components/content/icon/icon-registry.js.map +1 -1
- package/dist/components/content/icon/icon.template.js +1 -1
- package/dist/components/content/text/text.d.ts +21 -3
- package/dist/components/content/text/text.d.ts.map +1 -1
- package/dist/components/content/text/text.js +41 -1
- package/dist/components/content/text/text.js.map +1 -1
- package/dist/components/content/text/text.styles.d.ts +2 -1
- package/dist/components/content/text/text.styles.d.ts.map +1 -1
- package/dist/components/content/text/text.styles.js +88 -2
- package/dist/components/content/text/text.styles.js.map +1 -1
- package/dist/components/content/title/title.d.ts +1 -3
- package/dist/components/content/title/title.d.ts.map +1 -1
- package/dist/components/content/title/title.js +5 -79
- package/dist/components/content/title/title.js.map +1 -1
- package/dist/components/{decorate-CtaxGuuh.js → decorate-D2HtKmpx.js} +1 -1
- package/dist/components/{defer-focus-CC5RVvh6.js → defer-focus-JRj1EYUV.js} +2 -2
- package/dist/components/{dev-checks-a7fZ6hgC.js → dev-checks-BPjCXw_r.js} +109 -12
- package/dist/components/icon-DU_IMj2t.js +968 -0
- package/dist/components/{icon-button-DJPpMxWn.js → icon-button-BgeikVnm.js} +3 -3
- package/dist/components/index.d.ts +2 -1
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +2 -1
- package/dist/components/index.js.map +1 -1
- package/dist/components/inputs/one-time-code-field/one-time-code-field.d.ts +172 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-field.d.ts.map +1 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-field.js +447 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-field.js.map +1 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-field.styles.d.ts +2 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-field.styles.d.ts.map +1 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-field.styles.js +188 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-field.styles.js.map +1 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-field.template.d.ts +4 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-field.template.d.ts.map +1 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-field.template.js +64 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-field.template.js.map +1 -0
- package/dist/components/inputs/search-field/search-field.d.ts +4 -2
- package/dist/components/inputs/search-field/search-field.d.ts.map +1 -1
- package/dist/components/inputs/search-field/search-field.js +5 -4
- package/dist/components/inputs/search-field/search-field.js.map +1 -1
- package/dist/components/inputs/search-field/search-field.template.d.ts.map +1 -1
- package/dist/components/inputs/search-field/search-field.template.js +4 -3
- package/dist/components/inputs/search-field/search-field.template.js.map +1 -1
- package/dist/components/inputs/text-field/text-field.d.ts +14 -0
- package/dist/components/inputs/text-field/text-field.d.ts.map +1 -1
- package/dist/components/inputs/text-field/text-field.js +51 -1
- package/dist/components/inputs/text-field/text-field.js.map +1 -1
- package/dist/components/inputs/text-field/text-field.styles.d.ts.map +1 -1
- package/dist/components/inputs/text-field/text-field.styles.js +21 -1
- package/dist/components/inputs/text-field/text-field.styles.js.map +1 -1
- package/dist/components/inputs/text-field/text-field.template.d.ts.map +1 -1
- package/dist/components/inputs/text-field/text-field.template.js +5 -0
- package/dist/components/inputs/text-field/text-field.template.js.map +1 -1
- package/dist/components/{just-in-time-education.i18n-S05IOgqk.js → just-in-time-education.i18n-eCghRteQ.js} +10 -10
- package/dist/components/layout/{task-board/task-board-column.d.ts → column-board/column-board-column.d.ts} +5 -5
- package/dist/components/layout/column-board/column-board-column.d.ts.map +1 -0
- package/dist/components/layout/{task-board/task-board-column.js → column-board/column-board-column.js} +34 -34
- package/dist/components/layout/column-board/column-board-column.js.map +1 -0
- package/dist/components/layout/column-board/column-board-column.template.d.ts +3 -0
- package/dist/components/layout/column-board/column-board-column.template.d.ts.map +1 -0
- package/dist/components/layout/{task-board/task-board-column.template.js → column-board/column-board-column.template.js} +10 -10
- package/dist/components/layout/column-board/column-board-column.template.js.map +1 -0
- package/dist/components/layout/{task-board/task-board.d.ts → column-board/column-board.d.ts} +21 -21
- package/dist/components/layout/column-board/column-board.d.ts.map +1 -0
- package/dist/components/layout/column-board/column-board.i18n.d.ts +11 -0
- package/dist/components/layout/column-board/column-board.i18n.d.ts.map +1 -0
- package/dist/components/layout/column-board/column-board.i18n.js +10 -0
- package/dist/components/layout/column-board/column-board.i18n.js.map +1 -0
- package/dist/components/layout/{task-board/task-board.js → column-board/column-board.js} +43 -43
- package/dist/components/layout/column-board/column-board.js.map +1 -0
- package/dist/components/layout/column-board/column-board.styles.d.ts +3 -0
- package/dist/components/layout/column-board/column-board.styles.d.ts.map +1 -0
- package/dist/components/layout/column-board/column-board.styles.js +260 -0
- package/dist/components/layout/column-board/column-board.styles.js.map +1 -0
- package/dist/components/layout/column-board/column-board.template.d.ts +3 -0
- package/dist/components/layout/column-board/column-board.template.d.ts.map +1 -0
- package/dist/components/layout/{task-board/task-board.template.js → column-board/column-board.template.js} +5 -5
- package/dist/components/layout/column-board/column-board.template.js.map +1 -0
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.d.ts +5 -2
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.d.ts.map +1 -1
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.js +15 -3
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.js.map +1 -1
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.styles.d.ts.map +1 -1
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.styles.js +5 -0
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.styles.js.map +1 -1
- package/dist/components/{nl.generated-CUo20aPV.js → nl.generated-B0pvf8VH.js} +2 -2
- package/dist/components/status-and-feedback/status-bar/status-bar.d.ts +12 -1
- package/dist/components/status-and-feedback/status-bar/status-bar.d.ts.map +1 -1
- package/dist/components/status-and-feedback/status-bar/status-bar.js +32 -1
- package/dist/components/status-and-feedback/status-bar/status-bar.js.map +1 -1
- package/dist/components/status-and-feedback/status-bar/status-bar.styles.d.ts.map +1 -1
- package/dist/components/status-and-feedback/status-bar/status-bar.styles.js +59 -0
- package/dist/components/status-and-feedback/status-bar/status-bar.styles.js.map +1 -1
- package/dist/components/status-and-feedback/status-bar/status-bar.template.d.ts.map +1 -1
- package/dist/components/status-and-feedback/status-bar/status-bar.template.js +4 -1
- package/dist/components/status-and-feedback/status-bar/status-bar.template.js.map +1 -1
- package/dist/components/status-and-feedback/step-bar/step-bar.d.ts +15 -8
- package/dist/components/status-and-feedback/step-bar/step-bar.d.ts.map +1 -1
- package/dist/components/status-and-feedback/step-bar/step-bar.js +30 -12
- package/dist/components/status-and-feedback/step-bar/step-bar.js.map +1 -1
- package/dist/components/status-and-feedback/step-bar/step-bar.styles.d.ts +7 -2
- package/dist/components/status-and-feedback/step-bar/step-bar.styles.d.ts.map +1 -1
- package/dist/components/status-and-feedback/step-bar/step-bar.styles.js +31 -19
- package/dist/components/status-and-feedback/step-bar/step-bar.styles.js.map +1 -1
- package/dist/components/{visibility-mixin-CwMutpAK.js → visibility-mixin-Dti3xE8R.js} +1 -1
- package/dist/nldd.min.js +2256 -1815
- package/dist/translations/en-US.js +7 -7
- package/dist/translations/en-US.js.map +1 -1
- package/dist/translations/fy.js +7 -7
- package/dist/translations/fy.js.map +1 -1
- package/dist/translations/nl.generated.d.ts +7 -7
- package/dist/translations/nl.generated.js +2 -2
- package/dist/translations/nl.generated.js.map +1 -1
- package/dist/translations/pap-AW.js +7 -7
- package/dist/translations/pap-AW.js.map +1 -1
- package/dist/translations/pap-CW.js +7 -7
- package/dist/translations/pap-CW.js.map +1 -1
- package/dist/types/vue.d.ts +129 -50
- package/dist/utilities/custom-font-size.d.ts +19 -0
- package/dist/utilities/custom-font-size.d.ts.map +1 -0
- package/dist/utilities/custom-font-size.js +90 -0
- package/dist/utilities/custom-font-size.js.map +1 -0
- package/dist/utilities/dev-checks.d.ts +7 -0
- package/dist/utilities/dev-checks.d.ts.map +1 -1
- package/dist/utilities/dev-checks.js +23 -0
- package/dist/utilities/dev-checks.js.map +1 -1
- package/dist/utilities/dev-rules.generated.d.ts.map +1 -1
- package/dist/utilities/dev-rules.generated.js +94 -14
- package/dist/utilities/dev-rules.generated.js.map +1 -1
- package/dist/utilities/file-drag-and-drop.js +1 -1
- package/dist/utilities/file-drag-and-drop.js.map +1 -1
- package/dist/utilities/status-bar-change.d.ts +7 -0
- package/dist/utilities/status-bar-change.d.ts.map +1 -0
- package/dist/utilities/status-bar-change.js +7 -0
- package/dist/utilities/status-bar-change.js.map +1 -0
- package/lint/data.generated.json +1 -1
- package/package.json +9 -5
- package/dist/components/icon-Bkdlj87q.js +0 -968
- package/dist/components/layout/task-board/task-board-column.d.ts.map +0 -1
- package/dist/components/layout/task-board/task-board-column.js.map +0 -1
- package/dist/components/layout/task-board/task-board-column.template.d.ts +0 -3
- package/dist/components/layout/task-board/task-board-column.template.d.ts.map +0 -1
- package/dist/components/layout/task-board/task-board-column.template.js.map +0 -1
- package/dist/components/layout/task-board/task-board.d.ts.map +0 -1
- package/dist/components/layout/task-board/task-board.i18n.d.ts +0 -11
- package/dist/components/layout/task-board/task-board.i18n.d.ts.map +0 -1
- package/dist/components/layout/task-board/task-board.i18n.js +0 -10
- package/dist/components/layout/task-board/task-board.i18n.js.map +0 -1
- package/dist/components/layout/task-board/task-board.js.map +0 -1
- package/dist/components/layout/task-board/task-board.styles.d.ts +0 -3
- package/dist/components/layout/task-board/task-board.styles.d.ts.map +0 -1
- package/dist/components/layout/task-board/task-board.styles.js +0 -260
- package/dist/components/layout/task-board/task-board.styles.js.map +0 -1
- package/dist/components/layout/task-board/task-board.template.d.ts +0 -3
- package/dist/components/layout/task-board/task-board.template.d.ts.map +0 -1
- package/dist/components/layout/task-board/task-board.template.js.map +0 -1
|
@@ -30,6 +30,16 @@ var devRules = [
|
|
|
30
30
|
"context": "nldd-bar-split-view",
|
|
31
31
|
"report": ":has(> :not([slot]))"
|
|
32
32
|
},
|
|
33
|
+
{
|
|
34
|
+
"id": "blockquote-custom-size-invalid",
|
|
35
|
+
"message": "This is not a size the quote can use, so it keeps its own size at this breakpoint. Use a length such as \"32px\" or \"2rem\", not a keyword.",
|
|
36
|
+
"context": "nldd-blockquote:state(invalid-custom-size)"
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"id": "blockquote-custom-size-no-effect",
|
|
40
|
+
"message": "This custom size is smaller than the quote's own size at this breakpoint and shows at that size.",
|
|
41
|
+
"context": "nldd-blockquote:state(custom-size-below-floor)"
|
|
42
|
+
},
|
|
33
43
|
{
|
|
34
44
|
"id": "button-bar-no-toggle-button",
|
|
35
45
|
"message": "The bar is one surface for actions, and a selected toggle breaks it. Use nldd-toggle-button-group for a row of toggles, or nldd-segmented-control for one choice out of a few.",
|
|
@@ -111,6 +121,28 @@ var devRules = [
|
|
|
111
121
|
"message": "The collection is a list and makes each child a list item, but this child has a role of its own, which would be lost. It stays as it is, so the list now holds something that is no list item. Put the content in an nldd-card, or wrap it in a div.",
|
|
112
122
|
"context": "nldd-collection > :not([slot]):is(a, article, aside, button, details, dialog, fieldset, figure, footer, form, h1, h2, h3, h4, h5, h6, header, img, li, main, nav, ol, section, table, ul, [role]:not([role=\"\"]):not([role=\"listitem\"]))"
|
|
113
123
|
},
|
|
124
|
+
{
|
|
125
|
+
"id": "column-board-column-needs-name",
|
|
126
|
+
"message": "nldd-column-board-column needs `text` or `accessible-label`; it is what a screen reader hears when an item moves to it.",
|
|
127
|
+
"context": "nldd-column-board-column",
|
|
128
|
+
"assert": "[text]:not([text=\"\"]), [accessible-label]:not([accessible-label=\"\"])",
|
|
129
|
+
"properties": ["text", "accessibleLabel"]
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
"id": "column-board-column-tag-renamed",
|
|
133
|
+
"message": "`nldd-task-board-column` is now `nldd-column-board-column`. Rename the tag, its import and its class, here and on every page.",
|
|
134
|
+
"context": "nldd-task-board-column"
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
"id": "column-board-move-item-invalid",
|
|
138
|
+
"message": "moveItem() needs an item in one of the board's columns and a column of the board.",
|
|
139
|
+
"context": "nldd-column-board:state(invalid-move)"
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
"id": "column-board-tag-renamed",
|
|
143
|
+
"message": "`nldd-task-board` is now `nldd-column-board`. Rename the tag, its import and its class, here and on every page.",
|
|
144
|
+
"context": "nldd-task-board"
|
|
145
|
+
},
|
|
114
146
|
{
|
|
115
147
|
"id": "combo-box-needs-name",
|
|
116
148
|
"message": "nldd-combo-box needs `accessible-label` or a labeled nldd-form-field around it, or it has no accessible name.",
|
|
@@ -151,7 +183,7 @@ var devRules = [
|
|
|
151
183
|
"id": "form-field-needs-input",
|
|
152
184
|
"message": "nldd-form-field holds no form input, so the label cannot name anything or move focus into it.",
|
|
153
185
|
"context": "nldd-form-field[label]:not([label=\"\"]):has(> :not(nldd-form-field-help-text))",
|
|
154
|
-
"assert": ":has(:is(input, nldd-checkbox, nldd-checkbox-field, nldd-code-editor, nldd-combo-box, nldd-date-field, nldd-date-picker, nldd-dropdown, nldd-file-field, nldd-multi-line-text-field, nldd-number-field, nldd-password-field, nldd-radio-button, nldd-radio-button-field, nldd-radio-button-group, nldd-search-field, nldd-segmented-control, nldd-slider, nldd-stepper, nldd-swatch-picker, nldd-switch, nldd-switch-field, nldd-text-editor, nldd-text-field, nldd-time-field, nldd-time-picker, nldd-toggle-button, nldd-toggle-button-group, nldd-token-field, select, textarea)), :state(has-input)",
|
|
186
|
+
"assert": ":has(:is(input, nldd-checkbox, nldd-checkbox-field, nldd-code-editor, nldd-combo-box, nldd-date-field, nldd-date-picker, nldd-dropdown, nldd-file-field, nldd-multi-line-text-field, nldd-number-field, nldd-one-time-code-field, nldd-password-field, nldd-radio-button, nldd-radio-button-field, nldd-radio-button-group, nldd-search-field, nldd-segmented-control, nldd-slider, nldd-stepper, nldd-swatch-picker, nldd-switch, nldd-switch-field, nldd-text-editor, nldd-text-field, nldd-time-field, nldd-time-picker, nldd-toggle-button, nldd-toggle-button-group, nldd-token-field, select, textarea)), :state(has-input)",
|
|
155
187
|
"properties": []
|
|
156
188
|
},
|
|
157
189
|
{
|
|
@@ -450,6 +482,21 @@ var devRules = [
|
|
|
450
482
|
"assert": "[accessible-label]:not([accessible-label=\"\"])",
|
|
451
483
|
"properties": ["accessibleLabel"]
|
|
452
484
|
},
|
|
485
|
+
{
|
|
486
|
+
"id": "one-time-code-field-format-invalid",
|
|
487
|
+
"message": "`format` needs a `#` for each box, such as `###-###`; without one the field ignores it.",
|
|
488
|
+
"context": "nldd-one-time-code-field[format]:not([format=\"\"]):not([format*=\"#\"])"
|
|
489
|
+
},
|
|
490
|
+
{
|
|
491
|
+
"id": "one-time-code-field-length-no-effect",
|
|
492
|
+
"message": "`format` sets the length, so `length` does nothing here. Remove `length`.",
|
|
493
|
+
"context": "nldd-one-time-code-field[format*=\"#\"][length]:not([length=\"\"])"
|
|
494
|
+
},
|
|
495
|
+
{
|
|
496
|
+
"id": "one-time-code-field-uppercase-no-effect",
|
|
497
|
+
"message": "`uppercase` only does something with `type=\"alphanumeric\"`; a numeric code has no letters. Remove it, or set the type.",
|
|
498
|
+
"context": "nldd-one-time-code-field[uppercase]:not([type=\"alphanumeric\"])"
|
|
499
|
+
},
|
|
453
500
|
{
|
|
454
501
|
"id": "page-footer-goes-in-page",
|
|
455
502
|
"message": "nldd-page-footer has its own slot on nldd-page and sets its own width and spacing.",
|
|
@@ -514,6 +561,11 @@ var devRules = [
|
|
|
514
561
|
"message": "Move the `href` or `button` to a segment: both together put a control in a control.",
|
|
515
562
|
"context": "nldd-list-item:is([href]:not([href=\"\"]), [button]):has(> nldd-list-item-segment)"
|
|
516
563
|
},
|
|
564
|
+
{
|
|
565
|
+
"id": "search-field-show-search-button-renamed",
|
|
566
|
+
"message": "The `show-search-button` attribute is now `search-button`, which also takes the appearance of the button. Rename it here and on every other nldd-search-field.",
|
|
567
|
+
"context": "nldd-search-field[show-search-button]"
|
|
568
|
+
},
|
|
517
569
|
{
|
|
518
570
|
"id": "segmented-control-needs-name",
|
|
519
571
|
"message": "nldd-segmented-control needs `accessible-label`, `accessible-labeled-by` or a labeled nldd-form-field around it, or it has no accessible name.",
|
|
@@ -717,16 +769,14 @@ var devRules = [
|
|
|
717
769
|
"context": "nldd-tag:state(unnamed)"
|
|
718
770
|
},
|
|
719
771
|
{
|
|
720
|
-
"id": "
|
|
721
|
-
"message": "
|
|
722
|
-
"context": "nldd-
|
|
723
|
-
"assert": "[text]:not([text=\"\"]), [accessible-label]:not([accessible-label=\"\"])",
|
|
724
|
-
"properties": ["text", "accessibleLabel"]
|
|
772
|
+
"id": "text-custom-size-invalid",
|
|
773
|
+
"message": "This is not a size the text can use, so it keeps its size from `size` at this breakpoint. Use a length such as \"96px\" or \"6rem\", not a keyword.",
|
|
774
|
+
"context": "nldd-text:state(invalid-custom-size)"
|
|
725
775
|
},
|
|
726
776
|
{
|
|
727
|
-
"id": "
|
|
728
|
-
"message": "
|
|
729
|
-
"context": "nldd-
|
|
777
|
+
"id": "text-custom-size-no-effect",
|
|
778
|
+
"message": "This custom size is smaller than `display-1` at this breakpoint and shows as `display-1`. Use `size` for text up to `display-1`.",
|
|
779
|
+
"context": "nldd-text:state(custom-size-below-floor)"
|
|
730
780
|
},
|
|
731
781
|
{
|
|
732
782
|
"id": "text-editor-command-not-found",
|
|
@@ -738,11 +788,26 @@ var devRules = [
|
|
|
738
788
|
"message": "The query of this typeahead is not a valid regular expression; the default is used.",
|
|
739
789
|
"context": "nldd-text-editor:state(invalid-typeahead-query)"
|
|
740
790
|
},
|
|
791
|
+
{
|
|
792
|
+
"id": "text-field-button-size-no-effect",
|
|
793
|
+
"message": "The button in the `button` slot has a size of its own, but the field sets it: `sm` in a field of `md`, `xs` in one of `sm`. Leave the size off the button.",
|
|
794
|
+
"context": "nldd-text-field:state(own-button-size-overwritten)"
|
|
795
|
+
},
|
|
741
796
|
{
|
|
742
797
|
"id": "text-field-no-keyboard-with-type",
|
|
743
798
|
"message": "`keyboard` contradicts `type`, which already raises a keyboard of its own. Drop one of the two.",
|
|
744
799
|
"context": "nldd-text-field:state(keyboard-contradicts-type)"
|
|
745
800
|
},
|
|
801
|
+
{
|
|
802
|
+
"id": "text-line-height-no-effect",
|
|
803
|
+
"message": "`line-height` belongs to the body sizes; a display size has its own line height. Remove it.",
|
|
804
|
+
"context": "nldd-text[size^=\"display-\"][line-height]:not([line-height=\"\"])"
|
|
805
|
+
},
|
|
806
|
+
{
|
|
807
|
+
"id": "text-weight-no-effect",
|
|
808
|
+
"message": "`weight` belongs to the body sizes; a display size has its own weight. Remove it.",
|
|
809
|
+
"context": "nldd-text[size^=\"display-\"][weight]:not([weight=\"\"])"
|
|
810
|
+
},
|
|
746
811
|
{
|
|
747
812
|
"id": "title-custom-size-invalid",
|
|
748
813
|
"message": "This is not a size the title can use, so it keeps its size from the scale at this breakpoint. Use a length such as \"96px\" or \"6rem\", not a keyword.",
|
|
@@ -1059,8 +1124,8 @@ var devRules = [
|
|
|
1059
1124
|
},
|
|
1060
1125
|
{
|
|
1061
1126
|
"id": "invalid-value-text-size",
|
|
1062
|
-
"message": "`size` on nldd-text takes: lg, md, sm, xs, xxs.",
|
|
1063
|
-
"context": "nldd-text[size]:not([size=\"lg\"], [size=\"md\"], [size=\"sm\"], [size=\"xs\"], [size=\"xxs\"], nldd-toolbar *, nldd-button-bar *, nldd-button-group *, nldd-list-item *, nldd-avatar-group *, nldd-notification *)"
|
|
1127
|
+
"message": "`size` on nldd-text takes: display-1, display-2, display-3, display-4, display-5, display-6, lg, md, sm, xs, xxs.",
|
|
1128
|
+
"context": "nldd-text[size]:not([size=\"display-1\"], [size=\"display-2\"], [size=\"display-3\"], [size=\"display-4\"], [size=\"display-5\"], [size=\"display-6\"], [size=\"lg\"], [size=\"md\"], [size=\"sm\"], [size=\"xs\"], [size=\"xxs\"], nldd-toolbar *, nldd-button-bar *, nldd-button-group *, nldd-list-item *, nldd-avatar-group *, nldd-notification *)"
|
|
1064
1129
|
},
|
|
1065
1130
|
{
|
|
1066
1131
|
"id": "invalid-value-text-weight",
|
|
@@ -1182,6 +1247,16 @@ var devRules = [
|
|
|
1182
1247
|
"message": "`size` on nldd-number-field takes: md, sm.",
|
|
1183
1248
|
"context": "nldd-number-field[size]:not([size=\"md\"], [size=\"sm\"], nldd-toolbar *, nldd-button-bar *, nldd-button-group *, nldd-list-item *, nldd-avatar-group *, nldd-notification *)"
|
|
1184
1249
|
},
|
|
1250
|
+
{
|
|
1251
|
+
"id": "invalid-value-one-time-code-field-size",
|
|
1252
|
+
"message": "`size` on nldd-one-time-code-field takes: lg, md, sm.",
|
|
1253
|
+
"context": "nldd-one-time-code-field[size]:not([size=\"lg\"], [size=\"md\"], [size=\"sm\"], nldd-toolbar *, nldd-button-bar *, nldd-button-group *, nldd-list-item *, nldd-avatar-group *, nldd-notification *)"
|
|
1254
|
+
},
|
|
1255
|
+
{
|
|
1256
|
+
"id": "invalid-value-one-time-code-field-type",
|
|
1257
|
+
"message": "`type` on nldd-one-time-code-field takes: alphanumeric, numeric.",
|
|
1258
|
+
"context": "nldd-one-time-code-field[type]:not([type=\"alphanumeric\"], [type=\"numeric\"])"
|
|
1259
|
+
},
|
|
1185
1260
|
{
|
|
1186
1261
|
"id": "invalid-value-password-field-size",
|
|
1187
1262
|
"message": "`size` on nldd-password-field takes: md, sm.",
|
|
@@ -1202,6 +1277,11 @@ var devRules = [
|
|
|
1202
1277
|
"message": "`size` on nldd-search-field takes: md, sm.",
|
|
1203
1278
|
"context": "nldd-search-field[size]:not([size=\"md\"], [size=\"sm\"], nldd-toolbar *, nldd-button-bar *, nldd-button-group *, nldd-list-item *, nldd-avatar-group *, nldd-notification *)"
|
|
1204
1279
|
},
|
|
1280
|
+
{
|
|
1281
|
+
"id": "invalid-value-search-field-search-button",
|
|
1282
|
+
"message": "`search-button` on nldd-search-field takes: accent-filled, neutral-tinted.",
|
|
1283
|
+
"context": "nldd-search-field[search-button]:not([search-button=\"\"], [search-button=\"accent-filled\"], [search-button=\"neutral-tinted\"])"
|
|
1284
|
+
},
|
|
1205
1285
|
{
|
|
1206
1286
|
"id": "invalid-value-segmented-control-item-appearance",
|
|
1207
1287
|
"message": "`appearance` on nldd-segmented-control-item takes: neutral-base, neutral-tinted.",
|
|
@@ -2576,10 +2656,26 @@ function createReporter() {
|
|
|
2576
2656
|
}
|
|
2577
2657
|
/** A translation has no element to state a fact on, so this one reports itself. */
|
|
2578
2658
|
async function checkTranslationKeys(keys) {
|
|
2579
|
-
const { nl } = await import("./nl.generated-
|
|
2659
|
+
const { nl } = await import("./nl.generated-B0pvf8VH.js");
|
|
2580
2660
|
const unknown = keys.filter((key) => !(key in nl));
|
|
2581
2661
|
if (unknown.length > 0) console.warn(`[nldd] setTranslations: no component knows ${unknown.join(", ")}.`);
|
|
2582
2662
|
}
|
|
2663
|
+
/** The keyframes of fouc.css, which only that stylesheet puts on the body. */
|
|
2664
|
+
var FOUC_GUARD = "nldd-fouc-reveal";
|
|
2665
|
+
/**
|
|
2666
|
+
* Whether a page that shows components lacks the FOUC guard. The guard is a
|
|
2667
|
+
* stylesheet, which no element can state a fact about, so this reads the body.
|
|
2668
|
+
*/
|
|
2669
|
+
function lacksFoucGuard(root = document.body) {
|
|
2670
|
+
const { body } = document;
|
|
2671
|
+
if (!body || !root) return false;
|
|
2672
|
+
if (![...root.querySelectorAll("*")].some((element) => element.localName.startsWith("nldd-"))) return false;
|
|
2673
|
+
return !getComputedStyle(body).animationName.split(",").map((name) => name.trim()).includes(FOUC_GUARD);
|
|
2674
|
+
}
|
|
2675
|
+
/** Like a translation, the guard has no element to state a fact on, so this one reports itself. */
|
|
2676
|
+
function checkFoucGuard() {
|
|
2677
|
+
if (lacksFoucGuard()) console.warn("[nldd] fouc.css: this page has no FOUC guard, so components show unstyled until they load. Import '@nldd/design-system/styles', which includes it, or '@nldd/design-system/styles/fouc' on its own.");
|
|
2678
|
+
}
|
|
2583
2679
|
var started = false;
|
|
2584
2680
|
function startDevChecks() {
|
|
2585
2681
|
if (started || typeof MutationObserver === "undefined") return;
|
|
@@ -2600,5 +2696,6 @@ function startDevChecks() {
|
|
|
2600
2696
|
if (!document.hidden) report(stateRules);
|
|
2601
2697
|
}, RECHECK_MS);
|
|
2602
2698
|
schedule();
|
|
2699
|
+
setTimeout(checkFoucGuard, SETTLE_MS);
|
|
2603
2700
|
}
|
|
2604
2701
|
export { checkTranslationKeys, startDevChecks };
|