@nordhealth/components 3.7.0 → 3.9.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 (44) hide show
  1. package/custom-elements.json +1830 -1735
  2. package/lib/Avatar.js +1 -1
  3. package/lib/Avatar.js.map +1 -1
  4. package/lib/{Calendar-38b5ce2b.js → Calendar-3170b9d4.js} +2 -2
  5. package/lib/{Calendar-38b5ce2b.js.map → Calendar-3170b9d4.js.map} +1 -1
  6. package/lib/Calendar.js +1 -1
  7. package/lib/Checkbox.js +1 -1
  8. package/lib/Checkbox.js.map +1 -1
  9. package/lib/DatePicker.js +1 -1
  10. package/lib/DatePicker.js.map +1 -1
  11. package/lib/Drawer.js +1 -1
  12. package/lib/Drawer.js.map +1 -1
  13. package/lib/Footer.js +2 -0
  14. package/lib/Footer.js.map +1 -0
  15. package/lib/Header.js +1 -1
  16. package/lib/Header.js.map +1 -1
  17. package/lib/Layout.js +1 -1
  18. package/lib/Layout.js.map +1 -1
  19. package/lib/Message.js.map +1 -1
  20. package/lib/Modal.js +1 -1
  21. package/lib/Modal.js.map +1 -1
  22. package/lib/Notification.js +1 -1
  23. package/lib/Notification.js.map +1 -1
  24. package/lib/NotificationGroup.js +1 -1
  25. package/lib/NotificationGroup.js.map +1 -1
  26. package/lib/TopBar.js +1 -1
  27. package/lib/TopBar.js.map +1 -1
  28. package/lib/bundle.js +1 -1
  29. package/lib/bundle.js.map +1 -1
  30. package/lib/index.js +1 -1
  31. package/lib/src/avatar/Avatar.d.ts +1 -0
  32. package/lib/src/drawer/Drawer.d.ts +1 -0
  33. package/lib/src/footer/Footer.d.ts +25 -0
  34. package/lib/src/footer/Footer.test.d.ts +3 -0
  35. package/lib/src/index.d.ts +1 -0
  36. package/lib/src/layout/Layout.d.ts +7 -1
  37. package/lib/src/layout/Layout.test.d.ts +2 -0
  38. package/lib/src/message/Message.d.ts +1 -1
  39. package/lib/src/modal/Modal.d.ts +1 -0
  40. package/lib/src/notification/Notification.d.ts +1 -1
  41. package/lib/src/notification-group/NotificationGroup.d.ts +2 -4
  42. package/package.json +5 -5
  43. package/lib/DraftComponentMixin-9e4b7b34.js +0 -2
  44. package/lib/DraftComponentMixin-9e4b7b34.js.map +0 -1
@@ -430,6 +430,14 @@
430
430
  "name": "default",
431
431
  "module": "\"./top-bar/TopBar.js\""
432
432
  }
433
+ },
434
+ {
435
+ "kind": "js",
436
+ "name": "Footer",
437
+ "declaration": {
438
+ "name": "default",
439
+ "module": "\"./footer/Footer.js\""
440
+ }
433
441
  }
434
442
  ]
435
443
  },
@@ -456,6 +464,11 @@
456
464
  "description": "Controls the box shadow for the avatar.",
457
465
  "name": "--n-avatar-box-shadow",
458
466
  "default": "none"
467
+ },
468
+ {
469
+ "description": "Controls the color of the avatar’s text and icon, using [color tokens](/tokens/#color).",
470
+ "name": "--n-avatar-text-color",
471
+ "default": "var(--n-color-text-on-accent)"
459
472
  }
460
473
  ],
461
474
  "members": [
@@ -628,6 +641,91 @@
628
641
  }
629
642
  ]
630
643
  },
644
+ {
645
+ "kind": "javascript-module",
646
+ "path": "src/banner/Banner.ts",
647
+ "declarations": [
648
+ {
649
+ "kind": "class",
650
+ "description": "Banner informs users about important changes or conditions in the\ninterface. Use this component if you need to communicate to users\nin a prominent way.",
651
+ "name": "Banner",
652
+ "cssProperties": [
653
+ {
654
+ "description": "Controls how rounded the corners are, using [border radius tokens](/tokens/#border-radius).",
655
+ "name": "--n-banner-border-radius",
656
+ "default": "var(--n-border-radius)"
657
+ },
658
+ {
659
+ "description": "Controls the surrounding shadow, using [box shadow tokens](/tokens/#box-shadow).",
660
+ "name": "--n-banner-box-shadow",
661
+ "default": "var(--n-box-shadow-card)"
662
+ }
663
+ ],
664
+ "slots": [
665
+ {
666
+ "description": "default slot",
667
+ "name": ""
668
+ }
669
+ ],
670
+ "members": [
671
+ {
672
+ "kind": "field",
673
+ "name": "variant",
674
+ "type": {
675
+ "text": "\"info\" | \"danger\" | \"success\" | \"warning\""
676
+ },
677
+ "default": "\"info\"",
678
+ "description": "The style variant of the banner.",
679
+ "attribute": "variant",
680
+ "reflects": true
681
+ }
682
+ ],
683
+ "attributes": [
684
+ {
685
+ "name": "variant",
686
+ "type": {
687
+ "text": "\"info\" | \"danger\" | \"success\" | \"warning\""
688
+ },
689
+ "default": "\"info\"",
690
+ "description": "The style variant of the banner.",
691
+ "fieldName": "variant"
692
+ }
693
+ ],
694
+ "superclass": {
695
+ "name": "LitElement",
696
+ "package": "lit"
697
+ },
698
+ "localization": [],
699
+ "status": "ready",
700
+ "category": "feedback",
701
+ "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use this component if you need to communicate in a prominent way.\n- Place banner at the top of the section it applies to.\n- Use for highlighting errors and success statuses.\n- Put banner close to the context it’s referring to.\n- Move focus to the banner if it’s relevant to the current workflow.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Move focus to banner if it appears on page load.\n- Use for highlighting general content or as a banner.\n- Use to replace an error page.\n\n</div>\n\n---\n\n## Content guidelines\n\nBanner content should be clear, accurate and easy to understand:\n\n<div class=\"n-usage n-usage-do\">We’re experiencing an incident. Please see our status page for more details.</div>\n<div class=\"n-usage n-usage-dont\">There was an error.</div>\n\nWhen writing banner content, always write it in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">We’re experiencing an incident.</div>\n<div class=\"n-usage n-usage-dont\">We’re Experiencing An Incident.</div>\n\nAlways end in punctuation:\n\n<div class=\"n-usage n-usage-do\">We’re experiencing an incident.</div>\n<div class=\"n-usage n-usage-dont\">We’re experiencing an incident</div>\n",
702
+ "examples": [],
703
+ "dependencies": [
704
+ "icon"
705
+ ],
706
+ "tagName": "nord-banner",
707
+ "customElement": true
708
+ }
709
+ ],
710
+ "exports": [
711
+ {
712
+ "kind": "js",
713
+ "name": "default",
714
+ "declaration": {
715
+ "name": "Banner",
716
+ "module": "src/banner/Banner.ts"
717
+ }
718
+ },
719
+ {
720
+ "kind": "custom-element-definition",
721
+ "name": "nord-banner",
722
+ "declaration": {
723
+ "name": "Banner",
724
+ "module": "src/banner/Banner.ts"
725
+ }
726
+ }
727
+ ]
728
+ },
631
729
  {
632
730
  "kind": "javascript-module",
633
731
  "path": "src/badge/Badge.ts",
@@ -1330,91 +1428,6 @@
1330
1428
  }
1331
1429
  ]
1332
1430
  },
1333
- {
1334
- "kind": "javascript-module",
1335
- "path": "src/banner/Banner.ts",
1336
- "declarations": [
1337
- {
1338
- "kind": "class",
1339
- "description": "Banner informs users about important changes or conditions in the\ninterface. Use this component if you need to communicate to users\nin a prominent way.",
1340
- "name": "Banner",
1341
- "cssProperties": [
1342
- {
1343
- "description": "Controls how rounded the corners are, using [border radius tokens](/tokens/#border-radius).",
1344
- "name": "--n-banner-border-radius",
1345
- "default": "var(--n-border-radius)"
1346
- },
1347
- {
1348
- "description": "Controls the surrounding shadow, using [box shadow tokens](/tokens/#box-shadow).",
1349
- "name": "--n-banner-box-shadow",
1350
- "default": "var(--n-box-shadow-card)"
1351
- }
1352
- ],
1353
- "slots": [
1354
- {
1355
- "description": "default slot",
1356
- "name": ""
1357
- }
1358
- ],
1359
- "members": [
1360
- {
1361
- "kind": "field",
1362
- "name": "variant",
1363
- "type": {
1364
- "text": "\"info\" | \"danger\" | \"success\" | \"warning\""
1365
- },
1366
- "default": "\"info\"",
1367
- "description": "The style variant of the banner.",
1368
- "attribute": "variant",
1369
- "reflects": true
1370
- }
1371
- ],
1372
- "attributes": [
1373
- {
1374
- "name": "variant",
1375
- "type": {
1376
- "text": "\"info\" | \"danger\" | \"success\" | \"warning\""
1377
- },
1378
- "default": "\"info\"",
1379
- "description": "The style variant of the banner.",
1380
- "fieldName": "variant"
1381
- }
1382
- ],
1383
- "superclass": {
1384
- "name": "LitElement",
1385
- "package": "lit"
1386
- },
1387
- "localization": [],
1388
- "status": "ready",
1389
- "category": "feedback",
1390
- "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use this component if you need to communicate in a prominent way.\n- Place banner at the top of the section it applies to.\n- Use for highlighting errors and success statuses.\n- Put banner close to the context it’s referring to.\n- Move focus to the banner if it’s relevant to the current workflow.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Move focus to banner if it appears on page load.\n- Use for highlighting general content or as a banner.\n- Use to replace an error page.\n\n</div>\n\n---\n\n## Content guidelines\n\nBanner content should be clear, accurate and easy to understand:\n\n<div class=\"n-usage n-usage-do\">We’re experiencing an incident. Please see our status page for more details.</div>\n<div class=\"n-usage n-usage-dont\">There was an error.</div>\n\nWhen writing banner content, always write it in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">We’re experiencing an incident.</div>\n<div class=\"n-usage n-usage-dont\">We’re Experiencing An Incident.</div>\n\nAlways end in punctuation:\n\n<div class=\"n-usage n-usage-do\">We’re experiencing an incident.</div>\n<div class=\"n-usage n-usage-dont\">We’re experiencing an incident</div>\n",
1391
- "examples": [],
1392
- "dependencies": [
1393
- "icon"
1394
- ],
1395
- "tagName": "nord-banner",
1396
- "customElement": true
1397
- }
1398
- ],
1399
- "exports": [
1400
- {
1401
- "kind": "js",
1402
- "name": "default",
1403
- "declaration": {
1404
- "name": "Banner",
1405
- "module": "src/banner/Banner.ts"
1406
- }
1407
- },
1408
- {
1409
- "kind": "custom-element-definition",
1410
- "name": "nord-banner",
1411
- "declaration": {
1412
- "name": "Banner",
1413
- "module": "src/banner/Banner.ts"
1414
- }
1415
- }
1416
- ]
1417
- },
1418
1431
  {
1419
1432
  "kind": "javascript-module",
1420
1433
  "path": "src/calendar/Calendar.ts",
@@ -6024,7 +6037,9 @@
6024
6037
  "category": "structure",
6025
6038
  "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use for displaying contextual actions or information. For example, when clicking on a table row.\n- Use when you don’t want to block users from completing their task in the main view of an application.\n- Always include a header that summarizes the actions and information in the drawer.\n- Should be closeable through actions like “Done” and “Close”.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t put cards inside the drawer. Consider using the [divider](/components/divider/) component to break up sections instead.\n- Don’t reset the drawer’s state when closed if used for settings or filters. Settings should persist.\n- Don’t open from within another drawer. Only one drawer can be open at a time.\n- Don’t use for presenting a small amount of content or an actions menu, use the [popout](/components/popout/) or [dropdown](/components/dropdown/) component instead.\n\n</div>\n\n---\n\n## Additional considerations\n\n- You can customize the width of the component using `--n-layout-drawer-inline-size` CSS Custom Property that is offered on [Layout component](/components/layout/).\n",
6026
6039
  "examples": [],
6027
- "dependencies": [],
6040
+ "dependencies": [
6041
+ "footer"
6042
+ ],
6028
6043
  "tagName": "nord-drawer",
6029
6044
  "customElement": true
6030
6045
  }
@@ -6793,6 +6808,94 @@
6793
6808
  }
6794
6809
  ]
6795
6810
  },
6811
+ {
6812
+ "kind": "javascript-module",
6813
+ "path": "src/footer/Footer.ts",
6814
+ "declarations": [
6815
+ {
6816
+ "kind": "class",
6817
+ "description": "The footer is a block of designated space for providing additional information or actions that are positioned below the main content.",
6818
+ "name": "Footer",
6819
+ "cssProperties": [
6820
+ {
6821
+ "description": "Controls the inline padding around the footer’s main slot, using [spacing tokens](/tokens/#space).",
6822
+ "name": "--n-footer-padding-inline",
6823
+ "default": "var(--n-space-l)"
6824
+ },
6825
+ {
6826
+ "description": "Controls the box shadow of the footer, using [box shadow tokens](/tokens/#box-shadow).",
6827
+ "name": "--n-footer-box-shadow",
6828
+ "default": "var(--n-box-shadow-header)"
6829
+ },
6830
+ {
6831
+ "description": "Controls the background color of the footer, using [color tokens](/tokens/#color).",
6832
+ "name": "--n-footer-background-color",
6833
+ "default": "var(--n-color-surface)"
6834
+ }
6835
+ ],
6836
+ "slots": [
6837
+ {
6838
+ "description": "The footer content.",
6839
+ "name": ""
6840
+ }
6841
+ ],
6842
+ "members": [
6843
+ {
6844
+ "kind": "field",
6845
+ "name": "size",
6846
+ "type": {
6847
+ "text": "\"m\" | \"s\""
6848
+ },
6849
+ "default": "\"m\"",
6850
+ "description": "Controls the size of the footer component.",
6851
+ "attribute": "size",
6852
+ "reflects": true
6853
+ }
6854
+ ],
6855
+ "attributes": [
6856
+ {
6857
+ "name": "size",
6858
+ "type": {
6859
+ "text": "\"m\" | \"s\""
6860
+ },
6861
+ "default": "\"m\"",
6862
+ "description": "Controls the size of the footer component.",
6863
+ "fieldName": "size"
6864
+ }
6865
+ ],
6866
+ "superclass": {
6867
+ "name": "LitElement",
6868
+ "package": "lit"
6869
+ },
6870
+ "localization": [],
6871
+ "status": "draft",
6872
+ "category": "structure",
6873
+ "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use the footer component to show actions for a stepped workflow.\n- Use the footer component to provide additional information or actions that are positioned below the main content.\n- The footer component can also be used within Nord to provide a layer of actions or information at the bottom of a component. It’s currently used internally in the [modal](/components/modal/) and [drawer components](/components/drawer/).\n- When using the footer component within the [layout component](/components/layout/?example=footer), you can make the footer sticky by using the provided `stickyFooter` property of the layout component. [View an example](/components/layout/?example=footer).\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t overcrowd the footer with too many actions or information.\n- Don’t nest the footer deeply and restrict its available space.\n- Don’t add large amounts of content or long paragraphs. Aim for actions that are short and concise.\n\n</div>\n\n---\n\n## Content guidelines\n\nFooter action labels should be clear, accurate and predictable. It should be possible for the user to understand what will happen when they click a button:\n\n<div class=\"n-usage n-usage-do\">Create client</div>\n<div class=\"n-usage n-usage-dont\">Click here</div>\n\nWhen writing button labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">My tasks</div>\n<div class=\"n-usage n-usage-dont\">My Tasks</div>\n\nAvoid unnecessary words and articles in button labels, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Add item</div>\n<div class=\"n-usage n-usage-dont\">Add an item</div>\n",
6874
+ "examples": [],
6875
+ "dependencies": [],
6876
+ "tagName": "nord-footer",
6877
+ "customElement": true
6878
+ }
6879
+ ],
6880
+ "exports": [
6881
+ {
6882
+ "kind": "js",
6883
+ "name": "default",
6884
+ "declaration": {
6885
+ "name": "Footer",
6886
+ "module": "src/footer/Footer.ts"
6887
+ }
6888
+ },
6889
+ {
6890
+ "kind": "custom-element-definition",
6891
+ "name": "nord-footer",
6892
+ "declaration": {
6893
+ "name": "Footer",
6894
+ "module": "src/footer/Footer.ts"
6895
+ }
6896
+ }
6897
+ ]
6898
+ },
6796
6899
  {
6797
6900
  "kind": "javascript-module",
6798
6901
  "path": "src/header/Header.ts",
@@ -6876,1147 +6979,1096 @@
6876
6979
  },
6877
6980
  {
6878
6981
  "kind": "javascript-module",
6879
- "path": "src/icon/Icon.ts",
6982
+ "path": "src/input/Input.ts",
6880
6983
  "declarations": [
6881
6984
  {
6882
6985
  "kind": "class",
6883
- "description": "Icons are used to provide additional meaning or in places where text label doesn’t fit.\nIcon component allows you to display an icon from the Nordicons library.",
6884
- "name": "Icon",
6885
- "slots": [
6986
+ "description": "Inputs are used to allow users to provide text input when the expected input is short.\nAs well as plain text, Input supports various types of text, including passwords and numbers.",
6987
+ "name": "Input",
6988
+ "cssProperties": [
6886
6989
  {
6887
- "description": "The default slot used for placing a custom SVG icon.",
6888
- "name": ""
6990
+ "description": "Controls the inline size, or width, of the input.",
6991
+ "name": "--n-input-inline-size",
6992
+ "default": "240px"
6993
+ },
6994
+ {
6995
+ "description": "Controls the background of the input, using our [color tokens](/tokens/#color).",
6996
+ "name": "--n-input-background",
6997
+ "default": "var(--n-color-active)"
6998
+ },
6999
+ {
7000
+ "description": "Controls the text color of the input, using our [color tokens](/tokens/#color).",
7001
+ "name": "--n-input-color",
7002
+ "default": "var(--n-color-text)"
7003
+ },
7004
+ {
7005
+ "description": "Controls the border color of the input, using our [color tokens](/tokens/#color).",
7006
+ "name": "--n-input-border-color",
7007
+ "default": "var(--n-color-border-strong)"
7008
+ },
7009
+ {
7010
+ "description": "Controls how rounded the corners are, using [border radius tokens](/tokens/#border-radius).",
7011
+ "name": "--n-input-border-radius",
7012
+ "default": "var(--n-border-radius-s)"
7013
+ },
7014
+ {
7015
+ "description": "Controls the alignment of text within the input itself.",
7016
+ "name": "--n-input-text-align",
7017
+ "default": "start"
7018
+ }
7019
+ ],
7020
+ "slots": [
7021
+ {
7022
+ "description": "Use when a label requires more than plain text.",
7023
+ "name": "label"
7024
+ },
7025
+ {
7026
+ "description": "Optional slot that holds hint text for the input.",
7027
+ "name": "hint"
7028
+ },
7029
+ {
7030
+ "description": "Optional slot that holds error text for the input.",
7031
+ "name": "error"
7032
+ },
7033
+ {
7034
+ "description": "Optional slot used to place an icon or prefix at the start of the input.",
7035
+ "name": "start"
7036
+ },
7037
+ {
7038
+ "description": "Optional slot used to place an icon or suffix at the end of the input.",
7039
+ "name": "end"
6889
7040
  }
6890
7041
  ],
6891
7042
  "members": [
6892
7043
  {
6893
7044
  "kind": "field",
6894
- "name": "manager",
7045
+ "name": "startSlot",
7046
+ "type": {
7047
+ "text": "HTMLSlotElement"
7048
+ },
7049
+ "privacy": "private"
7050
+ },
7051
+ {
7052
+ "kind": "field",
7053
+ "name": "endSlot",
7054
+ "type": {
7055
+ "text": "HTMLSlotElement"
7056
+ },
7057
+ "privacy": "private"
7058
+ },
7059
+ {
7060
+ "kind": "field",
7061
+ "name": "startObserver",
6895
7062
  "privacy": "private",
6896
- "static": true,
6897
- "default": "new IconManager()"
7063
+ "default": "new ResizeController(this, () => this.startSlot)"
6898
7064
  },
6899
7065
  {
6900
- "kind": "method",
6901
- "name": "registerResolver",
6902
- "static": true,
6903
- "parameters": [
6904
- {
6905
- "name": "resolver",
6906
- "type": {
6907
- "text": "IconResolver"
6908
- },
6909
- "description": "The resolver function to register."
6910
- }
6911
- ],
6912
- "description": "Register a custom icon resolver, which accepts the icon name as an parameter, and returns an SVG string.\nCan return a string synchronously, or a promise of a string.\nBy default, will load icons from the Nord CDN."
7066
+ "kind": "field",
7067
+ "name": "endObserver",
7068
+ "privacy": "private",
7069
+ "default": "new ResizeController(this, () => this.endSlot)"
6913
7070
  },
6914
7071
  {
6915
- "kind": "method",
6916
- "name": "registerIcon",
6917
- "static": true,
6918
- "return": {
6919
- "type": {
6920
- "text": "void"
6921
- }
7072
+ "kind": "field",
7073
+ "name": "direction",
7074
+ "privacy": "private",
7075
+ "default": "new DirectionController(this)"
7076
+ },
7077
+ {
7078
+ "kind": "field",
7079
+ "name": "type",
7080
+ "type": {
7081
+ "text": "\"text\" | \"email\" | \"password\" | \"tel\" | \"url\" | \"search\" | \"number\" | \"unit\""
6922
7082
  },
6923
- "parameters": [
6924
- {
6925
- "name": "icon",
6926
- "type": {
6927
- "text": "{ title: string; default: string }"
6928
- },
6929
- "description": "An object representing the icon to be registered, where \"title\" is the icon's name, and \"default\" is the SVG string.\nThis is intended to be used in cases where you import an icon's entire ES module and register it directly."
6930
- }
6931
- ],
6932
- "description": "Register an individual icon so it can be rendered synchronously, to avoid loading over the network."
7083
+ "default": "\"text\"",
7084
+ "description": "The type of the input.",
7085
+ "attribute": "type",
7086
+ "reflects": true
6933
7087
  },
6934
7088
  {
6935
- "kind": "method",
6936
- "name": "registerIcon",
6937
- "static": true,
6938
- "return": {
6939
- "type": {
6940
- "text": "void"
6941
- }
7089
+ "kind": "field",
7090
+ "name": "expand",
7091
+ "type": {
7092
+ "text": "boolean"
6942
7093
  },
6943
- "parameters": [
6944
- {
6945
- "name": "name",
6946
- "type": {
6947
- "text": "string"
6948
- },
6949
- "description": "The name of the icon to be registered."
6950
- },
6951
- {
6952
- "name": "icon",
6953
- "type": {
6954
- "text": "string"
6955
- },
6956
- "description": "The SVG string for the icon."
6957
- }
6958
- ],
6959
- "description": "Register an individual icon so it can be rendered synchronously, to avoid loading over the network."
7094
+ "default": "false",
7095
+ "description": "Controls whether the input expands to fill the width of its container.",
7096
+ "attribute": "expand",
7097
+ "reflects": true
7098
+ },
7099
+ {
7100
+ "kind": "field",
7101
+ "name": "disallowPattern",
7102
+ "type": {
7103
+ "text": "string | undefined"
7104
+ },
7105
+ "default": "undefined",
7106
+ "description": "Optionally disallow certain characters from being used inside the input, using a regex pattern.",
7107
+ "attribute": "disallow-pattern",
7108
+ "reflects": true
6960
7109
  },
6961
7110
  {
6962
7111
  "kind": "method",
6963
- "name": "registerIcon",
6964
- "static": true,
7112
+ "name": "handleKeydown",
7113
+ "privacy": "private",
6965
7114
  "parameters": [
6966
7115
  {
6967
- "name": "iconOrName",
6968
- "type": {
6969
- "text": "string | { title: string; default: string }"
6970
- },
6971
- "description": "The name of the icon to be registered or an object representing the icon to be registered, where \"title\" is the icon's name, and \"default\" is the SVG string."
6972
- },
6973
- {
6974
- "name": "icon",
6975
- "optional": true,
7116
+ "name": "e",
6976
7117
  "type": {
6977
- "text": "string"
6978
- },
6979
- "description": "The SVG string for the icon."
7118
+ "text": "KeyboardEvent"
7119
+ }
6980
7120
  }
6981
- ],
6982
- "description": "Register an individual icon so it can be rendered synchronously, to avoid loading over the network."
7121
+ ]
6983
7122
  },
6984
7123
  {
6985
7124
  "kind": "field",
6986
- "name": "name",
6987
- "type": {
6988
- "text": "string"
6989
- },
6990
- "default": "\"\"",
6991
- "description": "The name of the icon to display, as defined by [nordicons](/nordicons/).",
6992
- "attribute": "name",
6993
- "reflects": true
7125
+ "name": "handleInputChange",
7126
+ "privacy": "private"
6994
7127
  },
6995
7128
  {
6996
7129
  "kind": "field",
6997
7130
  "name": "size",
6998
7131
  "type": {
6999
- "text": "\"xxs\" | \"xs\" | \"s\" | \"m\" | \"l\" | \"xl\" | \"xxl\" | undefined"
7132
+ "text": "\"s\" | \"m\" | \"l\""
7000
7133
  },
7001
- "description": "The size of the icon.",
7134
+ "default": "\"m\"",
7135
+ "description": "The size of the component.",
7002
7136
  "attribute": "size",
7003
- "reflects": true
7137
+ "reflects": true,
7138
+ "inheritedFrom": {
7139
+ "name": "SizeMixin",
7140
+ "module": "src/common/mixins/SizeMixin.ts"
7141
+ }
7004
7142
  },
7005
7143
  {
7006
7144
  "kind": "field",
7007
- "name": "color",
7145
+ "name": "labelSlot",
7146
+ "privacy": "protected",
7147
+ "default": "new SlotController(this, \"label\")",
7148
+ "inheritedFrom": {
7149
+ "name": "FormAssociatedMixin",
7150
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7151
+ }
7152
+ },
7153
+ {
7154
+ "kind": "field",
7155
+ "name": "errorSlot",
7156
+ "privacy": "protected",
7157
+ "default": "new SlotController(this, \"error\")",
7158
+ "inheritedFrom": {
7159
+ "name": "FormAssociatedMixin",
7160
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7161
+ }
7162
+ },
7163
+ {
7164
+ "kind": "field",
7165
+ "name": "hintSlot",
7166
+ "privacy": "protected",
7167
+ "default": "new SlotController(this, \"hint\")",
7168
+ "inheritedFrom": {
7169
+ "name": "FormAssociatedMixin",
7170
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7171
+ }
7172
+ },
7173
+ {
7174
+ "kind": "field",
7175
+ "name": "formData",
7176
+ "privacy": "protected",
7177
+ "default": "new FormDataController(this, { value: () => this.formValue })",
7178
+ "inheritedFrom": {
7179
+ "name": "FormAssociatedMixin",
7180
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7181
+ }
7182
+ },
7183
+ {
7184
+ "kind": "field",
7185
+ "name": "formValue",
7186
+ "privacy": "protected",
7187
+ "readonly": true,
7188
+ "inheritedFrom": {
7189
+ "name": "FormAssociatedMixin",
7190
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7191
+ }
7192
+ },
7193
+ {
7194
+ "kind": "field",
7195
+ "name": "inputId",
7008
7196
  "type": {
7009
- "text": "string | undefined"
7197
+ "text": "string"
7010
7198
  },
7011
- "description": "The color of the icon.\nCan accept any valid CSS color value, including custom properties.",
7012
- "attribute": "color",
7013
- "reflects": true
7199
+ "privacy": "protected",
7200
+ "default": "\"input\"",
7201
+ "inheritedFrom": {
7202
+ "name": "FormAssociatedMixin",
7203
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7204
+ }
7014
7205
  },
7015
7206
  {
7016
7207
  "kind": "field",
7017
- "name": "label",
7208
+ "name": "errorId",
7018
7209
  "type": {
7019
- "text": "string | undefined"
7210
+ "text": "string"
7020
7211
  },
7021
- "description": "An accessible label for the icon.\nIf no label is supplied, the icon is hidden from assistive technology.",
7022
- "attribute": "label",
7023
- "reflects": true
7212
+ "privacy": "protected",
7213
+ "default": "\"error\"",
7214
+ "inheritedFrom": {
7215
+ "name": "FormAssociatedMixin",
7216
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7217
+ }
7024
7218
  },
7025
7219
  {
7026
7220
  "kind": "field",
7027
- "name": "svg",
7221
+ "name": "hintId",
7028
7222
  "type": {
7029
7223
  "text": "string"
7030
7224
  },
7031
- "privacy": "private",
7032
- "default": "\"\""
7225
+ "privacy": "protected",
7226
+ "default": "\"hint\"",
7227
+ "inheritedFrom": {
7228
+ "name": "FormAssociatedMixin",
7229
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7230
+ }
7033
7231
  },
7034
7232
  {
7035
- "kind": "method",
7036
- "name": "handleNameChange",
7037
- "privacy": "protected"
7038
- }
7039
- ],
7040
- "attributes": [
7041
- {
7042
- "name": "name",
7233
+ "kind": "field",
7234
+ "name": "label",
7043
7235
  "type": {
7044
7236
  "text": "string"
7045
7237
  },
7046
7238
  "default": "\"\"",
7047
- "description": "The name of the icon to display, as defined by [nordicons](/nordicons/).",
7048
- "fieldName": "name"
7239
+ "description": "Label for the input.",
7240
+ "attribute": "label",
7241
+ "inheritedFrom": {
7242
+ "name": "FormAssociatedMixin",
7243
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7244
+ }
7049
7245
  },
7050
7246
  {
7051
- "name": "size",
7247
+ "kind": "field",
7248
+ "name": "hint",
7052
7249
  "type": {
7053
- "text": "\"xxs\" | \"xs\" | \"s\" | \"m\" | \"l\" | \"xl\" | \"xxl\" | undefined"
7250
+ "text": "string | undefined"
7054
7251
  },
7055
- "description": "The size of the icon.",
7056
- "fieldName": "size"
7252
+ "description": "Optional hint text to be displayed with the input. Alternatively use the hint slot.",
7253
+ "attribute": "hint",
7254
+ "inheritedFrom": {
7255
+ "name": "FormAssociatedMixin",
7256
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7257
+ }
7057
7258
  },
7058
7259
  {
7059
- "name": "color",
7260
+ "kind": "field",
7261
+ "name": "hideLabel",
7262
+ "type": {
7263
+ "text": "boolean"
7264
+ },
7265
+ "default": "false",
7266
+ "description": "Visually hide the label, but still show it to assistive technologies like screen readers.",
7267
+ "attribute": "hide-label",
7268
+ "inheritedFrom": {
7269
+ "name": "FormAssociatedMixin",
7270
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7271
+ }
7272
+ },
7273
+ {
7274
+ "kind": "field",
7275
+ "name": "placeholder",
7060
7276
  "type": {
7061
7277
  "text": "string | undefined"
7062
7278
  },
7063
- "description": "The color of the icon.\nCan accept any valid CSS color value, including custom properties.",
7064
- "fieldName": "color"
7279
+ "description": "Placeholder text to display within the input.",
7280
+ "attribute": "placeholder",
7281
+ "inheritedFrom": {
7282
+ "name": "FormAssociatedMixin",
7283
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7284
+ }
7065
7285
  },
7066
7286
  {
7067
- "name": "label",
7287
+ "kind": "field",
7288
+ "name": "error",
7068
7289
  "type": {
7069
7290
  "text": "string | undefined"
7070
7291
  },
7071
- "description": "An accessible label for the icon.\nIf no label is supplied, the icon is hidden from assistive technology.",
7072
- "fieldName": "label"
7073
- }
7074
- ],
7075
- "superclass": {
7076
- "name": "LitElement",
7077
- "package": "lit"
7078
- },
7079
- "localization": [],
7080
- "status": "ready",
7081
- "category": "image",
7082
- "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<nord-button href=\"/nordicons/\" variant=\"primary\">View Nordicons</nord-button>\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use to provide additional meaning in addition to a text label.\n- Use to help users who have difficulties with reading and attention.\n- Use in places where text label doesn’t fit (remember to add an accessible label for the icon).\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for decorative purposes alone.\n- Don’t use when a button’s action is already clear based on the text label.\n- Don’t use the same icon for differing purposes, as users will come to associate icons with specific types of actions.\n\n</div>\n\n---\n\n## Additional considerations\n\n- Icon components are hidden from assistive technologies by default.\n- Use `label` property to give an accessible label for the icon and to make it visible to assistive technologies.\n",
7083
- "examples": [],
7084
- "dependencies": [],
7085
- "tagName": "nord-icon",
7086
- "customElement": true
7087
- }
7088
- ],
7089
- "exports": [
7090
- {
7091
- "kind": "js",
7092
- "name": "default",
7093
- "declaration": {
7094
- "name": "Icon",
7095
- "module": "src/icon/Icon.ts"
7096
- }
7097
- },
7098
- {
7099
- "kind": "custom-element-definition",
7100
- "name": "nord-icon",
7101
- "declaration": {
7102
- "name": "Icon",
7103
- "module": "src/icon/Icon.ts"
7104
- }
7105
- }
7106
- ]
7107
- },
7108
- {
7109
- "kind": "javascript-module",
7110
- "path": "src/icon/IconManager.ts",
7111
- "declarations": [
7112
- {
7113
- "kind": "class",
7114
- "description": "",
7115
- "name": "IconManager",
7116
- "members": [
7292
+ "description": "Optional error to be shown with the input. Alternatively use the error slot.",
7293
+ "attribute": "error",
7294
+ "inheritedFrom": {
7295
+ "name": "FormAssociatedMixin",
7296
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7297
+ }
7298
+ },
7117
7299
  {
7118
7300
  "kind": "field",
7119
- "name": "cache",
7120
- "privacy": "private",
7121
- "default": "new Map<string, string | Promise<string>>()"
7301
+ "name": "required",
7302
+ "type": {
7303
+ "text": "boolean"
7304
+ },
7305
+ "default": "false",
7306
+ "description": "Determines whether the input is required or not.\nAn input marked as required will be announced as such to users of assistive technology.\nWhen using this property you need to also set “novalidate” attribute on a form element to prevent browser from displaying its own validation errors.",
7307
+ "attribute": "required",
7308
+ "inheritedFrom": {
7309
+ "name": "FormAssociatedMixin",
7310
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7311
+ }
7122
7312
  },
7123
7313
  {
7124
7314
  "kind": "field",
7125
- "name": "resolver",
7315
+ "name": "hideRequired",
7126
7316
  "type": {
7127
- "text": "IconResolver"
7317
+ "text": "boolean"
7318
+ },
7319
+ "default": "false",
7320
+ "description": "Visually hide the required indicator, but still show\nrequired attribute to assistive technologies like screen readers.",
7321
+ "attribute": "hide-required",
7322
+ "inheritedFrom": {
7323
+ "name": "FormAssociatedMixin",
7324
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7128
7325
  }
7129
7326
  },
7130
7327
  {
7131
7328
  "kind": "method",
7132
- "name": "resolve",
7329
+ "name": "handleInput",
7330
+ "privacy": "protected",
7133
7331
  "parameters": [
7134
7332
  {
7135
- "name": "name",
7333
+ "name": "e",
7136
7334
  "type": {
7137
- "text": "string"
7335
+ "text": "Event"
7138
7336
  }
7139
- },
7337
+ }
7338
+ ],
7339
+ "inheritedFrom": {
7340
+ "name": "FormAssociatedMixin",
7341
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7342
+ }
7343
+ },
7344
+ {
7345
+ "kind": "method",
7346
+ "name": "handleChange",
7347
+ "privacy": "protected",
7348
+ "parameters": [
7140
7349
  {
7141
- "name": "onResolved",
7350
+ "name": "e",
7142
7351
  "type": {
7143
- "text": "(svg: string) => void"
7352
+ "text": "Event"
7144
7353
  }
7145
7354
  }
7146
- ]
7355
+ ],
7356
+ "inheritedFrom": {
7357
+ "name": "FormAssociatedMixin",
7358
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7359
+ }
7147
7360
  },
7148
7361
  {
7149
7362
  "kind": "method",
7150
- "name": "registerIcon",
7363
+ "name": "renderLabel",
7364
+ "privacy": "protected",
7151
7365
  "parameters": [
7152
7366
  {
7153
- "name": "iconOrName",
7154
- "type": {
7155
- "text": "string | { title: string; default: string }"
7156
- }
7157
- },
7158
- {
7159
- "name": "icon",
7367
+ "name": "additionalContent",
7160
7368
  "optional": true,
7161
7369
  "type": {
7162
- "text": "string"
7370
+ "text": "TemplateResult"
7163
7371
  }
7164
7372
  }
7165
- ]
7373
+ ],
7374
+ "inheritedFrom": {
7375
+ "name": "FormAssociatedMixin",
7376
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7377
+ }
7166
7378
  },
7167
7379
  {
7168
7380
  "kind": "method",
7169
- "name": "clear"
7170
- }
7171
- ]
7172
- }
7173
- ],
7174
- "exports": [
7175
- {
7176
- "kind": "js",
7177
- "name": "IconManager",
7178
- "declaration": {
7179
- "name": "IconManager",
7180
- "module": "src/icon/IconManager.ts"
7181
- }
7182
- }
7183
- ]
7184
- },
7185
- {
7186
- "kind": "javascript-module",
7187
- "path": "src/input/Input.ts",
7188
- "declarations": [
7189
- {
7190
- "kind": "class",
7191
- "description": "Inputs are used to allow users to provide text input when the expected input is short.\nAs well as plain text, Input supports various types of text, including passwords and numbers.",
7192
- "name": "Input",
7193
- "cssProperties": [
7194
- {
7195
- "description": "Controls the inline size, or width, of the input.",
7196
- "name": "--n-input-inline-size",
7197
- "default": "240px"
7198
- },
7199
- {
7200
- "description": "Controls the background of the input, using our [color tokens](/tokens/#color).",
7201
- "name": "--n-input-background",
7202
- "default": "var(--n-color-active)"
7203
- },
7204
- {
7205
- "description": "Controls the text color of the input, using our [color tokens](/tokens/#color).",
7206
- "name": "--n-input-color",
7207
- "default": "var(--n-color-text)"
7208
- },
7209
- {
7210
- "description": "Controls the border color of the input, using our [color tokens](/tokens/#color).",
7211
- "name": "--n-input-border-color",
7212
- "default": "var(--n-color-border-strong)"
7213
- },
7214
- {
7215
- "description": "Controls how rounded the corners are, using [border radius tokens](/tokens/#border-radius).",
7216
- "name": "--n-input-border-radius",
7217
- "default": "var(--n-border-radius-s)"
7218
- },
7219
- {
7220
- "description": "Controls the alignment of text within the input itself.",
7221
- "name": "--n-input-text-align",
7222
- "default": "start"
7223
- }
7224
- ],
7225
- "slots": [
7226
- {
7227
- "description": "Use when a label requires more than plain text.",
7228
- "name": "label"
7381
+ "name": "renderError",
7382
+ "privacy": "protected",
7383
+ "inheritedFrom": {
7384
+ "name": "FormAssociatedMixin",
7385
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7386
+ }
7229
7387
  },
7230
7388
  {
7231
- "description": "Optional slot that holds hint text for the input.",
7232
- "name": "hint"
7389
+ "kind": "method",
7390
+ "name": "getDescribedBy",
7391
+ "privacy": "protected",
7392
+ "inheritedFrom": {
7393
+ "name": "FormAssociatedMixin",
7394
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7395
+ }
7233
7396
  },
7234
7397
  {
7235
- "description": "Optional slot that holds error text for the input.",
7236
- "name": "error"
7398
+ "kind": "method",
7399
+ "name": "getInvalid",
7400
+ "privacy": "protected",
7401
+ "inheritedFrom": {
7402
+ "name": "FormAssociatedMixin",
7403
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7404
+ }
7237
7405
  },
7238
7406
  {
7239
- "description": "Optional slot used to place an icon or prefix at the start of the input.",
7240
- "name": "start"
7407
+ "kind": "field",
7408
+ "name": "hasHint",
7409
+ "privacy": "protected",
7410
+ "readonly": true,
7411
+ "inheritedFrom": {
7412
+ "name": "FormAssociatedMixin",
7413
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7414
+ }
7241
7415
  },
7242
- {
7243
- "description": "Optional slot used to place an icon or suffix at the end of the input.",
7244
- "name": "end"
7245
- }
7246
- ],
7247
- "members": [
7248
7416
  {
7249
7417
  "kind": "field",
7250
- "name": "startSlot",
7251
- "type": {
7252
- "text": "HTMLSlotElement"
7253
- },
7254
- "privacy": "private"
7418
+ "name": "hasError",
7419
+ "privacy": "protected",
7420
+ "readonly": true,
7421
+ "inheritedFrom": {
7422
+ "name": "FormAssociatedMixin",
7423
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7424
+ }
7255
7425
  },
7256
7426
  {
7257
7427
  "kind": "field",
7258
- "name": "endSlot",
7428
+ "name": "autocomplete",
7259
7429
  "type": {
7260
- "text": "HTMLSlotElement"
7430
+ "text": "AutocompleteAttribute"
7261
7431
  },
7262
- "privacy": "private"
7263
- },
7264
- {
7265
- "kind": "field",
7266
- "name": "startObserver",
7267
- "privacy": "private",
7268
- "default": "new ResizeController(this, () => this.startSlot)"
7269
- },
7270
- {
7271
- "kind": "field",
7272
- "name": "endObserver",
7273
- "privacy": "private",
7274
- "default": "new ResizeController(this, () => this.endSlot)"
7275
- },
7276
- {
7277
- "kind": "field",
7278
- "name": "direction",
7279
- "privacy": "private",
7280
- "default": "new DirectionController(this)"
7432
+ "default": "\"off\"",
7433
+ "description": "Specifies the data type of the field, so that the browser may attempt to fill out the field automatically on behalf of the user.",
7434
+ "attribute": "autocomplete",
7435
+ "inheritedFrom": {
7436
+ "name": "AutocompleteMixin",
7437
+ "module": "src/common/mixins/AutocompleteMixin.ts"
7438
+ }
7281
7439
  },
7282
7440
  {
7283
7441
  "kind": "field",
7284
- "name": "type",
7442
+ "name": "readonly",
7285
7443
  "type": {
7286
- "text": "\"text\" | \"email\" | \"password\" | \"tel\" | \"url\" | \"search\" | \"number\" | \"unit\""
7444
+ "text": "boolean"
7287
7445
  },
7288
- "default": "\"text\"",
7289
- "description": "The type of the input.",
7290
- "attribute": "type",
7291
- "reflects": true
7446
+ "default": "false",
7447
+ "description": "Makes the component readonly, so that it is not editable.\nReadonly differs from disabled in that readonly fields are still focusable and will be submitted with a form.",
7448
+ "attribute": "readonly",
7449
+ "reflects": true,
7450
+ "inheritedFrom": {
7451
+ "name": "ReadonlyMixin",
7452
+ "module": "src/common/mixins/ReadonlyMixin.ts"
7453
+ }
7292
7454
  },
7293
7455
  {
7294
7456
  "kind": "field",
7295
- "name": "expand",
7457
+ "name": "disabled",
7296
7458
  "type": {
7297
7459
  "text": "boolean"
7298
7460
  },
7299
7461
  "default": "false",
7300
- "description": "Controls whether the input expands to fill the width of its container.",
7301
- "attribute": "expand",
7302
- "reflects": true
7462
+ "description": "Makes the component disabled. This prevents users from\nbeing able to interact with the component, and conveys\nits inactive state to assistive technologies.",
7463
+ "attribute": "disabled",
7464
+ "reflects": true,
7465
+ "inheritedFrom": {
7466
+ "name": "InputMixin",
7467
+ "module": "src/common/mixins/InputMixin.ts"
7468
+ }
7303
7469
  },
7304
7470
  {
7305
7471
  "kind": "field",
7306
- "name": "disallowPattern",
7472
+ "name": "name",
7307
7473
  "type": {
7308
7474
  "text": "string | undefined"
7309
7475
  },
7310
- "default": "undefined",
7311
- "description": "Optionally disallow certain characters from being used inside the input, using a regex pattern.",
7312
- "attribute": "disallow-pattern",
7313
- "reflects": true
7476
+ "description": "The name of the form component.",
7477
+ "attribute": "name",
7478
+ "inheritedFrom": {
7479
+ "name": "InputMixin",
7480
+ "module": "src/common/mixins/InputMixin.ts"
7481
+ }
7314
7482
  },
7315
7483
  {
7316
- "kind": "method",
7317
- "name": "handleKeydown",
7318
- "privacy": "private",
7319
- "parameters": [
7320
- {
7321
- "name": "e",
7322
- "type": {
7323
- "text": "KeyboardEvent"
7324
- }
7325
- }
7326
- ]
7484
+ "kind": "field",
7485
+ "name": "value",
7486
+ "type": {
7487
+ "text": "string"
7488
+ },
7489
+ "default": "\"\"",
7490
+ "description": "The value of the form component.",
7491
+ "attribute": "value",
7492
+ "inheritedFrom": {
7493
+ "name": "InputMixin",
7494
+ "module": "src/common/mixins/InputMixin.ts"
7495
+ }
7327
7496
  },
7328
7497
  {
7329
7498
  "kind": "field",
7330
- "name": "handleInputChange",
7331
- "privacy": "private"
7499
+ "name": "formAncestor",
7500
+ "type": {
7501
+ "text": "HTMLFormElement | null"
7502
+ },
7503
+ "privacy": "private",
7504
+ "default": "null",
7505
+ "inheritedFrom": {
7506
+ "name": "InputMixin",
7507
+ "module": "src/common/mixins/InputMixin.ts"
7508
+ }
7332
7509
  },
7333
7510
  {
7334
7511
  "kind": "field",
7335
- "name": "size",
7512
+ "name": "_formId",
7336
7513
  "type": {
7337
- "text": "\"s\" | \"m\" | \"l\""
7514
+ "text": "string | undefined"
7338
7515
  },
7339
- "default": "\"m\"",
7340
- "description": "The size of the component.",
7341
- "attribute": "size",
7342
- "reflects": true,
7516
+ "privacy": "protected",
7343
7517
  "inheritedFrom": {
7344
- "name": "SizeMixin",
7345
- "module": "src/common/mixins/SizeMixin.ts"
7518
+ "name": "InputMixin",
7519
+ "module": "src/common/mixins/InputMixin.ts"
7346
7520
  }
7347
7521
  },
7348
7522
  {
7349
7523
  "kind": "field",
7350
- "name": "labelSlot",
7351
- "privacy": "protected",
7352
- "default": "new SlotController(this, \"label\")",
7524
+ "name": "form",
7525
+ "type": {
7526
+ "text": "HTMLFormElement | null"
7527
+ },
7528
+ "description": "Gets the form, if any, associated with the form element.\nThe setter accepts a string, which is the id of the form.",
7529
+ "attribute": "form",
7353
7530
  "inheritedFrom": {
7354
- "name": "FormAssociatedMixin",
7355
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7531
+ "name": "InputMixin",
7532
+ "module": "src/common/mixins/InputMixin.ts"
7356
7533
  }
7357
7534
  },
7358
7535
  {
7359
7536
  "kind": "field",
7360
- "name": "errorSlot",
7537
+ "name": "focusableRef",
7361
7538
  "privacy": "protected",
7362
- "default": "new SlotController(this, \"error\")",
7363
7539
  "inheritedFrom": {
7364
- "name": "FormAssociatedMixin",
7365
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7540
+ "name": "FocusableMixin",
7541
+ "module": "src/common/mixins/FocusableMixin.ts"
7366
7542
  }
7367
7543
  },
7368
7544
  {
7369
- "kind": "field",
7370
- "name": "hintSlot",
7371
- "privacy": "protected",
7372
- "default": "new SlotController(this, \"hint\")",
7545
+ "kind": "method",
7546
+ "name": "focus",
7547
+ "parameters": [
7548
+ {
7549
+ "name": "options",
7550
+ "optional": true,
7551
+ "type": {
7552
+ "text": "FocusOptions"
7553
+ },
7554
+ "description": "An object which controls aspects of the focusing process."
7555
+ }
7556
+ ],
7557
+ "description": "Programmatically move focus to the component.",
7373
7558
  "inheritedFrom": {
7374
- "name": "FormAssociatedMixin",
7375
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7559
+ "name": "FocusableMixin",
7560
+ "module": "src/common/mixins/FocusableMixin.ts"
7376
7561
  }
7377
7562
  },
7378
7563
  {
7379
- "kind": "field",
7380
- "name": "formData",
7381
- "privacy": "protected",
7382
- "default": "new FormDataController(this, { value: () => this.formValue })",
7564
+ "kind": "method",
7565
+ "name": "blur",
7566
+ "description": "Programmatically remove focus from the component.",
7383
7567
  "inheritedFrom": {
7384
- "name": "FormAssociatedMixin",
7385
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7568
+ "name": "FocusableMixin",
7569
+ "module": "src/common/mixins/FocusableMixin.ts"
7386
7570
  }
7387
7571
  },
7388
7572
  {
7389
- "kind": "field",
7390
- "name": "formValue",
7391
- "privacy": "protected",
7392
- "readonly": true,
7573
+ "kind": "method",
7574
+ "name": "click",
7575
+ "description": "Programmatically simulates a click on the component.",
7393
7576
  "inheritedFrom": {
7394
- "name": "FormAssociatedMixin",
7395
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7577
+ "name": "FocusableMixin",
7578
+ "module": "src/common/mixins/FocusableMixin.ts"
7396
7579
  }
7580
+ }
7581
+ ],
7582
+ "attributes": [
7583
+ {
7584
+ "name": "type",
7585
+ "type": {
7586
+ "text": "\"text\" | \"email\" | \"password\" | \"tel\" | \"url\" | \"search\" | \"number\" | \"unit\""
7587
+ },
7588
+ "default": "\"text\"",
7589
+ "description": "The type of the input.",
7590
+ "fieldName": "type"
7397
7591
  },
7398
7592
  {
7399
- "kind": "field",
7400
- "name": "inputId",
7593
+ "name": "expand",
7401
7594
  "type": {
7402
- "text": "string"
7595
+ "text": "boolean"
7403
7596
  },
7404
- "privacy": "protected",
7405
- "default": "\"input\"",
7406
- "inheritedFrom": {
7407
- "name": "FormAssociatedMixin",
7408
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7409
- }
7597
+ "default": "false",
7598
+ "description": "Controls whether the input expands to fill the width of its container.",
7599
+ "fieldName": "expand"
7410
7600
  },
7411
7601
  {
7412
- "kind": "field",
7413
- "name": "errorId",
7602
+ "name": "disallow-pattern",
7414
7603
  "type": {
7415
- "text": "string"
7604
+ "text": "string | undefined"
7416
7605
  },
7417
- "privacy": "protected",
7418
- "default": "\"error\"",
7419
- "inheritedFrom": {
7420
- "name": "FormAssociatedMixin",
7421
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7422
- }
7606
+ "default": "undefined",
7607
+ "description": "Optionally disallow certain characters from being used inside the input, using a regex pattern.",
7608
+ "resolveInitializer": {
7609
+ "module": "src/input/Input.ts"
7610
+ },
7611
+ "fieldName": "disallowPattern"
7423
7612
  },
7424
7613
  {
7425
- "kind": "field",
7426
- "name": "hintId",
7614
+ "name": "size",
7427
7615
  "type": {
7428
- "text": "string"
7616
+ "text": "\"s\" | \"m\" | \"l\""
7429
7617
  },
7430
- "privacy": "protected",
7431
- "default": "\"hint\"",
7618
+ "default": "\"m\"",
7619
+ "description": "The size of the component.",
7620
+ "fieldName": "size",
7432
7621
  "inheritedFrom": {
7433
- "name": "FormAssociatedMixin",
7434
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7622
+ "name": "SizeMixin",
7623
+ "module": "src/common/mixins/SizeMixin.ts"
7435
7624
  }
7436
7625
  },
7437
7626
  {
7438
- "kind": "field",
7439
7627
  "name": "label",
7440
7628
  "type": {
7441
7629
  "text": "string"
7442
7630
  },
7443
7631
  "default": "\"\"",
7444
7632
  "description": "Label for the input.",
7445
- "attribute": "label",
7633
+ "fieldName": "label",
7446
7634
  "inheritedFrom": {
7447
7635
  "name": "FormAssociatedMixin",
7448
7636
  "module": "src/common/mixins/FormAssociatedMixin.ts"
7449
7637
  }
7450
7638
  },
7451
7639
  {
7452
- "kind": "field",
7453
7640
  "name": "hint",
7454
7641
  "type": {
7455
7642
  "text": "string | undefined"
7456
7643
  },
7457
7644
  "description": "Optional hint text to be displayed with the input. Alternatively use the hint slot.",
7458
- "attribute": "hint",
7645
+ "fieldName": "hint",
7459
7646
  "inheritedFrom": {
7460
7647
  "name": "FormAssociatedMixin",
7461
7648
  "module": "src/common/mixins/FormAssociatedMixin.ts"
7462
7649
  }
7463
7650
  },
7464
7651
  {
7465
- "kind": "field",
7466
- "name": "hideLabel",
7652
+ "name": "hide-label",
7467
7653
  "type": {
7468
7654
  "text": "boolean"
7469
7655
  },
7470
7656
  "default": "false",
7471
7657
  "description": "Visually hide the label, but still show it to assistive technologies like screen readers.",
7472
- "attribute": "hide-label",
7658
+ "fieldName": "hideLabel",
7473
7659
  "inheritedFrom": {
7474
7660
  "name": "FormAssociatedMixin",
7475
7661
  "module": "src/common/mixins/FormAssociatedMixin.ts"
7476
7662
  }
7477
7663
  },
7478
7664
  {
7479
- "kind": "field",
7480
7665
  "name": "placeholder",
7481
7666
  "type": {
7482
7667
  "text": "string | undefined"
7483
7668
  },
7484
7669
  "description": "Placeholder text to display within the input.",
7485
- "attribute": "placeholder",
7670
+ "fieldName": "placeholder",
7486
7671
  "inheritedFrom": {
7487
7672
  "name": "FormAssociatedMixin",
7488
7673
  "module": "src/common/mixins/FormAssociatedMixin.ts"
7489
7674
  }
7490
7675
  },
7491
7676
  {
7492
- "kind": "field",
7493
7677
  "name": "error",
7494
7678
  "type": {
7495
7679
  "text": "string | undefined"
7496
7680
  },
7497
7681
  "description": "Optional error to be shown with the input. Alternatively use the error slot.",
7498
- "attribute": "error",
7682
+ "fieldName": "error",
7499
7683
  "inheritedFrom": {
7500
7684
  "name": "FormAssociatedMixin",
7501
7685
  "module": "src/common/mixins/FormAssociatedMixin.ts"
7502
7686
  }
7503
7687
  },
7504
7688
  {
7505
- "kind": "field",
7506
7689
  "name": "required",
7507
7690
  "type": {
7508
7691
  "text": "boolean"
7509
7692
  },
7510
7693
  "default": "false",
7511
7694
  "description": "Determines whether the input is required or not.\nAn input marked as required will be announced as such to users of assistive technology.\nWhen using this property you need to also set “novalidate” attribute on a form element to prevent browser from displaying its own validation errors.",
7512
- "attribute": "required",
7695
+ "fieldName": "required",
7513
7696
  "inheritedFrom": {
7514
7697
  "name": "FormAssociatedMixin",
7515
7698
  "module": "src/common/mixins/FormAssociatedMixin.ts"
7516
7699
  }
7517
7700
  },
7518
7701
  {
7519
- "kind": "field",
7520
- "name": "hideRequired",
7702
+ "name": "hide-required",
7521
7703
  "type": {
7522
7704
  "text": "boolean"
7523
7705
  },
7524
7706
  "default": "false",
7525
7707
  "description": "Visually hide the required indicator, but still show\nrequired attribute to assistive technologies like screen readers.",
7526
- "attribute": "hide-required",
7527
- "inheritedFrom": {
7528
- "name": "FormAssociatedMixin",
7529
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7530
- }
7531
- },
7532
- {
7533
- "kind": "method",
7534
- "name": "handleInput",
7535
- "privacy": "protected",
7536
- "parameters": [
7537
- {
7538
- "name": "e",
7539
- "type": {
7540
- "text": "Event"
7541
- }
7542
- }
7543
- ],
7544
- "inheritedFrom": {
7545
- "name": "FormAssociatedMixin",
7546
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7547
- }
7548
- },
7549
- {
7550
- "kind": "method",
7551
- "name": "handleChange",
7552
- "privacy": "protected",
7553
- "parameters": [
7554
- {
7555
- "name": "e",
7556
- "type": {
7557
- "text": "Event"
7558
- }
7559
- }
7560
- ],
7561
- "inheritedFrom": {
7562
- "name": "FormAssociatedMixin",
7563
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7564
- }
7565
- },
7566
- {
7567
- "kind": "method",
7568
- "name": "renderLabel",
7569
- "privacy": "protected",
7570
- "parameters": [
7571
- {
7572
- "name": "additionalContent",
7573
- "optional": true,
7574
- "type": {
7575
- "text": "TemplateResult"
7576
- }
7577
- }
7578
- ],
7579
- "inheritedFrom": {
7580
- "name": "FormAssociatedMixin",
7581
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7582
- }
7583
- },
7584
- {
7585
- "kind": "method",
7586
- "name": "renderError",
7587
- "privacy": "protected",
7588
- "inheritedFrom": {
7589
- "name": "FormAssociatedMixin",
7590
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7591
- }
7592
- },
7593
- {
7594
- "kind": "method",
7595
- "name": "getDescribedBy",
7596
- "privacy": "protected",
7597
- "inheritedFrom": {
7598
- "name": "FormAssociatedMixin",
7599
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7600
- }
7601
- },
7602
- {
7603
- "kind": "method",
7604
- "name": "getInvalid",
7605
- "privacy": "protected",
7606
- "inheritedFrom": {
7607
- "name": "FormAssociatedMixin",
7608
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7609
- }
7610
- },
7611
- {
7612
- "kind": "field",
7613
- "name": "hasHint",
7614
- "privacy": "protected",
7615
- "readonly": true,
7616
- "inheritedFrom": {
7617
- "name": "FormAssociatedMixin",
7618
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7619
- }
7620
- },
7621
- {
7622
- "kind": "field",
7623
- "name": "hasError",
7624
- "privacy": "protected",
7625
- "readonly": true,
7708
+ "fieldName": "hideRequired",
7626
7709
  "inheritedFrom": {
7627
7710
  "name": "FormAssociatedMixin",
7628
7711
  "module": "src/common/mixins/FormAssociatedMixin.ts"
7629
7712
  }
7630
7713
  },
7631
7714
  {
7632
- "kind": "field",
7633
7715
  "name": "autocomplete",
7634
7716
  "type": {
7635
7717
  "text": "AutocompleteAttribute"
7636
7718
  },
7637
7719
  "default": "\"off\"",
7638
7720
  "description": "Specifies the data type of the field, so that the browser may attempt to fill out the field automatically on behalf of the user.",
7639
- "attribute": "autocomplete",
7721
+ "fieldName": "autocomplete",
7640
7722
  "inheritedFrom": {
7641
7723
  "name": "AutocompleteMixin",
7642
7724
  "module": "src/common/mixins/AutocompleteMixin.ts"
7643
7725
  }
7644
7726
  },
7645
7727
  {
7646
- "kind": "field",
7647
7728
  "name": "readonly",
7648
7729
  "type": {
7649
7730
  "text": "boolean"
7650
7731
  },
7651
7732
  "default": "false",
7652
7733
  "description": "Makes the component readonly, so that it is not editable.\nReadonly differs from disabled in that readonly fields are still focusable and will be submitted with a form.",
7653
- "attribute": "readonly",
7654
- "reflects": true,
7734
+ "fieldName": "readonly",
7655
7735
  "inheritedFrom": {
7656
7736
  "name": "ReadonlyMixin",
7657
7737
  "module": "src/common/mixins/ReadonlyMixin.ts"
7658
7738
  }
7659
7739
  },
7660
7740
  {
7661
- "kind": "field",
7662
7741
  "name": "disabled",
7663
7742
  "type": {
7664
7743
  "text": "boolean"
7665
7744
  },
7666
7745
  "default": "false",
7667
7746
  "description": "Makes the component disabled. This prevents users from\nbeing able to interact with the component, and conveys\nits inactive state to assistive technologies.",
7668
- "attribute": "disabled",
7669
- "reflects": true,
7747
+ "fieldName": "disabled",
7670
7748
  "inheritedFrom": {
7671
7749
  "name": "InputMixin",
7672
7750
  "module": "src/common/mixins/InputMixin.ts"
7673
7751
  }
7674
7752
  },
7675
7753
  {
7676
- "kind": "field",
7677
7754
  "name": "name",
7678
7755
  "type": {
7679
7756
  "text": "string | undefined"
7680
7757
  },
7681
7758
  "description": "The name of the form component.",
7682
- "attribute": "name",
7759
+ "fieldName": "name",
7683
7760
  "inheritedFrom": {
7684
7761
  "name": "InputMixin",
7685
7762
  "module": "src/common/mixins/InputMixin.ts"
7686
7763
  }
7687
7764
  },
7688
7765
  {
7689
- "kind": "field",
7690
7766
  "name": "value",
7691
7767
  "type": {
7692
7768
  "text": "string"
7693
7769
  },
7694
7770
  "default": "\"\"",
7695
7771
  "description": "The value of the form component.",
7696
- "attribute": "value",
7772
+ "fieldName": "value",
7697
7773
  "inheritedFrom": {
7698
7774
  "name": "InputMixin",
7699
7775
  "module": "src/common/mixins/InputMixin.ts"
7700
7776
  }
7701
7777
  },
7702
7778
  {
7703
- "kind": "field",
7704
- "name": "formAncestor",
7779
+ "name": "form",
7705
7780
  "type": {
7706
7781
  "text": "HTMLFormElement | null"
7707
7782
  },
7708
- "privacy": "private",
7709
- "default": "null",
7783
+ "description": "Gets the form, if any, associated with the form element.\nThe setter accepts a string, which is the id of the form.",
7784
+ "fieldName": "form",
7710
7785
  "inheritedFrom": {
7711
7786
  "name": "InputMixin",
7712
7787
  "module": "src/common/mixins/InputMixin.ts"
7713
7788
  }
7789
+ }
7790
+ ],
7791
+ "mixins": [
7792
+ {
7793
+ "name": "SizeMixin",
7794
+ "module": "/src/common/mixins/SizeMixin.js"
7714
7795
  },
7715
7796
  {
7716
- "kind": "field",
7717
- "name": "_formId",
7797
+ "name": "FormAssociatedMixin",
7798
+ "module": "/src/common/mixins/FormAssociatedMixin.js"
7799
+ },
7800
+ {
7801
+ "name": "AutocompleteMixin",
7802
+ "module": "/src/common/mixins/AutocompleteMixin.js"
7803
+ },
7804
+ {
7805
+ "name": "ReadonlyMixin",
7806
+ "module": "/src/common/mixins/ReadonlyMixin.js"
7807
+ },
7808
+ {
7809
+ "name": "InputMixin",
7810
+ "module": "/src/common/mixins/InputMixin.js"
7811
+ },
7812
+ {
7813
+ "name": "FocusableMixin",
7814
+ "module": "/src/common/mixins/FocusableMixin.js"
7815
+ }
7816
+ ],
7817
+ "superclass": {
7818
+ "name": "LitElement",
7819
+ "package": "lit"
7820
+ },
7821
+ "localization": [],
7822
+ "status": "ready",
7823
+ "category": "form",
7824
+ "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use to provide a text input where the expected input is short.\n- Use to only ask for information that’s really needed. Hide optional fields by default if possible or have them shown with a lower priority.\n- Use help text and placeholder to provide additional, non-critical instructions.\n- Validate input as soon as users have finished interacting with them (but not before).\n- Where necessary, label the input as “Optional” when you need to request input that’s not required.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use when the expected text input is long. Use textarea component instead.\n- Don’t use the placeholder to provide information that’s required to use the input. Hint text should be used for this purpose instead.\n\n</div>\n\n---\n\n## Content guidelines\n\nInput labels act as a title for the text field. Labels should typically be short and in noun form:\n\n<div class=\"n-usage n-usage-do\">Company name</div>\n<div class=\"n-usage n-usage-dont\">What is your company name?</div>\n\nWhen writing input labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">Company name</div>\n<div class=\"n-usage n-usage-dont\">Company Name</div>\n\nWhen an input isn’t part of a form and is placed individually on a page, you could provide the input label as a call to action:\n\n<div class=\"n-usage n-usage-do\">Leave a comment</div>\n<div class=\"n-usage n-usage-dont\">Comment</div>\n\nDo not use colons in input label:\n\n<div class=\"n-usage n-usage-do\">First name</div>\n<div class=\"n-usage n-usage-dont\">First name:</div>\n\n---\n\n## Types\n\nThis section describes the different input types, their purpose, and when to use each type.\n\n| Name | Purpose |\n| ---------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------ |\n| `text` | The default and most common variant. Displayed as a single-line text field. Line-breaks are automatically removed from the input value. |\n| `email` | A field for editing an email address. Looks similar to a text input, but has validation parameters and relevant keyboard for devices with dynamic keyboards. |\n| `password` | A single-line text field where the value is obscured. This type will alert user if a site is not secure. |\n| `tel` | A field for entering a telephone number. Displays a number keypad on mobile devices. |\n| `url` | A field variant that is used to let the user enter and edit an URL. |\n| `search` | A single-line text field for entering search strings. |\n| `number` | Used to let the user enter a number. |\n\n## Icon usage in input\n\nEach [input size](/components/input/?example=size) has a recommended icon size. The medium input uses the `s` icon size, the small input uses the `xs` icon size, and the large input uses the `m` icon size. The icon will adjust size automatically based on the button size, so you will get the correct behavior by default. However, this can be overridden by explicitly setting a size on the icon.\n",
7825
+ "examples": [],
7826
+ "dependencies": [
7827
+ "icon"
7828
+ ],
7829
+ "tagName": "nord-input",
7830
+ "customElement": true,
7831
+ "events": [
7832
+ {
7833
+ "name": "input",
7718
7834
  "type": {
7719
- "text": "string | undefined"
7835
+ "text": "NordEvent"
7720
7836
  },
7721
- "privacy": "protected",
7837
+ "description": "Fired as the user types into the input.",
7722
7838
  "inheritedFrom": {
7723
- "name": "InputMixin",
7724
- "module": "src/common/mixins/InputMixin.ts"
7839
+ "name": "FormAssociatedMixin",
7840
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7725
7841
  }
7726
7842
  },
7727
7843
  {
7728
- "kind": "field",
7729
- "name": "form",
7844
+ "name": "change",
7730
7845
  "type": {
7731
- "text": "HTMLFormElement | null"
7846
+ "text": "NordEvent"
7732
7847
  },
7733
- "description": "Gets the form, if any, associated with the form element.\nThe setter accepts a string, which is the id of the form.",
7734
- "attribute": "form",
7848
+ "description": "Fired whenever the input's value is changed via user interaction.",
7735
7849
  "inheritedFrom": {
7736
- "name": "InputMixin",
7737
- "module": "src/common/mixins/InputMixin.ts"
7850
+ "name": "FormAssociatedMixin",
7851
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
7738
7852
  }
7739
- },
7853
+ }
7854
+ ]
7855
+ }
7856
+ ],
7857
+ "exports": [
7858
+ {
7859
+ "kind": "js",
7860
+ "name": "default",
7861
+ "declaration": {
7862
+ "name": "Input",
7863
+ "module": "src/input/Input.ts"
7864
+ }
7865
+ },
7866
+ {
7867
+ "kind": "custom-element-definition",
7868
+ "name": "nord-input",
7869
+ "declaration": {
7870
+ "name": "Input",
7871
+ "module": "src/input/Input.ts"
7872
+ }
7873
+ }
7874
+ ]
7875
+ },
7876
+ {
7877
+ "kind": "javascript-module",
7878
+ "path": "src/icon/Icon.ts",
7879
+ "declarations": [
7880
+ {
7881
+ "kind": "class",
7882
+ "description": "Icons are used to provide additional meaning or in places where text label doesn’t fit.\nIcon component allows you to display an icon from the Nordicons library.",
7883
+ "name": "Icon",
7884
+ "slots": [
7885
+ {
7886
+ "description": "The default slot used for placing a custom SVG icon.",
7887
+ "name": ""
7888
+ }
7889
+ ],
7890
+ "members": [
7740
7891
  {
7741
7892
  "kind": "field",
7742
- "name": "focusableRef",
7743
- "privacy": "protected",
7744
- "inheritedFrom": {
7745
- "name": "FocusableMixin",
7746
- "module": "src/common/mixins/FocusableMixin.ts"
7747
- }
7893
+ "name": "manager",
7894
+ "privacy": "private",
7895
+ "static": true,
7896
+ "default": "new IconManager()"
7748
7897
  },
7749
7898
  {
7750
7899
  "kind": "method",
7751
- "name": "focus",
7900
+ "name": "registerResolver",
7901
+ "static": true,
7752
7902
  "parameters": [
7753
7903
  {
7754
- "name": "options",
7755
- "optional": true,
7904
+ "name": "resolver",
7756
7905
  "type": {
7757
- "text": "FocusOptions"
7906
+ "text": "IconResolver"
7758
7907
  },
7759
- "description": "An object which controls aspects of the focusing process."
7908
+ "description": "The resolver function to register."
7760
7909
  }
7761
7910
  ],
7762
- "description": "Programmatically move focus to the component.",
7763
- "inheritedFrom": {
7764
- "name": "FocusableMixin",
7765
- "module": "src/common/mixins/FocusableMixin.ts"
7766
- }
7767
- },
7768
- {
7769
- "kind": "method",
7770
- "name": "blur",
7771
- "description": "Programmatically remove focus from the component.",
7772
- "inheritedFrom": {
7773
- "name": "FocusableMixin",
7774
- "module": "src/common/mixins/FocusableMixin.ts"
7775
- }
7911
+ "description": "Register a custom icon resolver, which accepts the icon name as an parameter, and returns an SVG string.\nCan return a string synchronously, or a promise of a string.\nBy default, will load icons from the Nord CDN."
7776
7912
  },
7777
7913
  {
7778
7914
  "kind": "method",
7779
- "name": "click",
7780
- "description": "Programmatically simulates a click on the component.",
7781
- "inheritedFrom": {
7782
- "name": "FocusableMixin",
7783
- "module": "src/common/mixins/FocusableMixin.ts"
7784
- }
7785
- }
7786
- ],
7787
- "attributes": [
7788
- {
7789
- "name": "type",
7790
- "type": {
7791
- "text": "\"text\" | \"email\" | \"password\" | \"tel\" | \"url\" | \"search\" | \"number\" | \"unit\""
7792
- },
7793
- "default": "\"text\"",
7794
- "description": "The type of the input.",
7795
- "fieldName": "type"
7796
- },
7797
- {
7798
- "name": "expand",
7799
- "type": {
7800
- "text": "boolean"
7915
+ "name": "registerIcon",
7916
+ "static": true,
7917
+ "return": {
7918
+ "type": {
7919
+ "text": "void"
7920
+ }
7801
7921
  },
7802
- "default": "false",
7803
- "description": "Controls whether the input expands to fill the width of its container.",
7804
- "fieldName": "expand"
7922
+ "parameters": [
7923
+ {
7924
+ "name": "icon",
7925
+ "type": {
7926
+ "text": "{ title: string; default: string }"
7927
+ },
7928
+ "description": "An object representing the icon to be registered, where \"title\" is the icon's name, and \"default\" is the SVG string.\nThis is intended to be used in cases where you import an icon's entire ES module and register it directly."
7929
+ }
7930
+ ],
7931
+ "description": "Register an individual icon so it can be rendered synchronously, to avoid loading over the network."
7805
7932
  },
7806
7933
  {
7807
- "name": "disallow-pattern",
7808
- "type": {
7809
- "text": "string | undefined"
7810
- },
7811
- "default": "undefined",
7812
- "description": "Optionally disallow certain characters from being used inside the input, using a regex pattern.",
7813
- "resolveInitializer": {
7814
- "module": "src/input/Input.ts"
7934
+ "kind": "method",
7935
+ "name": "registerIcon",
7936
+ "static": true,
7937
+ "return": {
7938
+ "type": {
7939
+ "text": "void"
7940
+ }
7815
7941
  },
7816
- "fieldName": "disallowPattern"
7942
+ "parameters": [
7943
+ {
7944
+ "name": "name",
7945
+ "type": {
7946
+ "text": "string"
7947
+ },
7948
+ "description": "The name of the icon to be registered."
7949
+ },
7950
+ {
7951
+ "name": "icon",
7952
+ "type": {
7953
+ "text": "string"
7954
+ },
7955
+ "description": "The SVG string for the icon."
7956
+ }
7957
+ ],
7958
+ "description": "Register an individual icon so it can be rendered synchronously, to avoid loading over the network."
7817
7959
  },
7818
7960
  {
7819
- "name": "size",
7820
- "type": {
7821
- "text": "\"s\" | \"m\" | \"l\""
7822
- },
7823
- "default": "\"m\"",
7824
- "description": "The size of the component.",
7825
- "fieldName": "size",
7826
- "inheritedFrom": {
7827
- "name": "SizeMixin",
7828
- "module": "src/common/mixins/SizeMixin.ts"
7829
- }
7961
+ "kind": "method",
7962
+ "name": "registerIcon",
7963
+ "static": true,
7964
+ "parameters": [
7965
+ {
7966
+ "name": "iconOrName",
7967
+ "type": {
7968
+ "text": "string | { title: string; default: string }"
7969
+ },
7970
+ "description": "The name of the icon to be registered or an object representing the icon to be registered, where \"title\" is the icon's name, and \"default\" is the SVG string."
7971
+ },
7972
+ {
7973
+ "name": "icon",
7974
+ "optional": true,
7975
+ "type": {
7976
+ "text": "string"
7977
+ },
7978
+ "description": "The SVG string for the icon."
7979
+ }
7980
+ ],
7981
+ "description": "Register an individual icon so it can be rendered synchronously, to avoid loading over the network."
7830
7982
  },
7831
7983
  {
7832
- "name": "label",
7984
+ "kind": "field",
7985
+ "name": "name",
7833
7986
  "type": {
7834
7987
  "text": "string"
7835
7988
  },
7836
7989
  "default": "\"\"",
7837
- "description": "Label for the input.",
7838
- "fieldName": "label",
7839
- "inheritedFrom": {
7840
- "name": "FormAssociatedMixin",
7841
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7842
- }
7843
- },
7844
- {
7845
- "name": "hint",
7846
- "type": {
7847
- "text": "string | undefined"
7848
- },
7849
- "description": "Optional hint text to be displayed with the input. Alternatively use the hint slot.",
7850
- "fieldName": "hint",
7851
- "inheritedFrom": {
7852
- "name": "FormAssociatedMixin",
7853
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7854
- }
7990
+ "description": "The name of the icon to display, as defined by [nordicons](/nordicons/).",
7991
+ "attribute": "name",
7992
+ "reflects": true
7855
7993
  },
7856
7994
  {
7857
- "name": "hide-label",
7995
+ "kind": "field",
7996
+ "name": "size",
7858
7997
  "type": {
7859
- "text": "boolean"
7998
+ "text": "\"xxs\" | \"xs\" | \"s\" | \"m\" | \"l\" | \"xl\" | \"xxl\" | undefined"
7860
7999
  },
7861
- "default": "false",
7862
- "description": "Visually hide the label, but still show it to assistive technologies like screen readers.",
7863
- "fieldName": "hideLabel",
7864
- "inheritedFrom": {
7865
- "name": "FormAssociatedMixin",
7866
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7867
- }
8000
+ "description": "The size of the icon.",
8001
+ "attribute": "size",
8002
+ "reflects": true
7868
8003
  },
7869
8004
  {
7870
- "name": "placeholder",
8005
+ "kind": "field",
8006
+ "name": "color",
7871
8007
  "type": {
7872
8008
  "text": "string | undefined"
7873
8009
  },
7874
- "description": "Placeholder text to display within the input.",
7875
- "fieldName": "placeholder",
7876
- "inheritedFrom": {
7877
- "name": "FormAssociatedMixin",
7878
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7879
- }
8010
+ "description": "The color of the icon.\nCan accept any valid CSS color value, including custom properties.",
8011
+ "attribute": "color",
8012
+ "reflects": true
7880
8013
  },
7881
8014
  {
7882
- "name": "error",
8015
+ "kind": "field",
8016
+ "name": "label",
7883
8017
  "type": {
7884
8018
  "text": "string | undefined"
7885
8019
  },
7886
- "description": "Optional error to be shown with the input. Alternatively use the error slot.",
7887
- "fieldName": "error",
7888
- "inheritedFrom": {
7889
- "name": "FormAssociatedMixin",
7890
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7891
- }
7892
- },
7893
- {
7894
- "name": "required",
7895
- "type": {
7896
- "text": "boolean"
7897
- },
7898
- "default": "false",
7899
- "description": "Determines whether the input is required or not.\nAn input marked as required will be announced as such to users of assistive technology.\nWhen using this property you need to also set “novalidate” attribute on a form element to prevent browser from displaying its own validation errors.",
7900
- "fieldName": "required",
7901
- "inheritedFrom": {
7902
- "name": "FormAssociatedMixin",
7903
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7904
- }
8020
+ "description": "An accessible label for the icon.\nIf no label is supplied, the icon is hidden from assistive technology.",
8021
+ "attribute": "label",
8022
+ "reflects": true
7905
8023
  },
7906
8024
  {
7907
- "name": "hide-required",
8025
+ "kind": "field",
8026
+ "name": "svg",
7908
8027
  "type": {
7909
- "text": "boolean"
8028
+ "text": "string"
7910
8029
  },
7911
- "default": "false",
7912
- "description": "Visually hide the required indicator, but still show\nrequired attribute to assistive technologies like screen readers.",
7913
- "fieldName": "hideRequired",
7914
- "inheritedFrom": {
7915
- "name": "FormAssociatedMixin",
7916
- "module": "src/common/mixins/FormAssociatedMixin.ts"
7917
- }
8030
+ "privacy": "private",
8031
+ "default": "\"\""
7918
8032
  },
7919
8033
  {
7920
- "name": "autocomplete",
7921
- "type": {
7922
- "text": "AutocompleteAttribute"
7923
- },
7924
- "default": "\"off\"",
7925
- "description": "Specifies the data type of the field, so that the browser may attempt to fill out the field automatically on behalf of the user.",
7926
- "fieldName": "autocomplete",
7927
- "inheritedFrom": {
7928
- "name": "AutocompleteMixin",
7929
- "module": "src/common/mixins/AutocompleteMixin.ts"
7930
- }
7931
- },
8034
+ "kind": "method",
8035
+ "name": "handleNameChange",
8036
+ "privacy": "protected"
8037
+ }
8038
+ ],
8039
+ "attributes": [
7932
8040
  {
7933
- "name": "readonly",
8041
+ "name": "name",
7934
8042
  "type": {
7935
- "text": "boolean"
8043
+ "text": "string"
7936
8044
  },
7937
- "default": "false",
7938
- "description": "Makes the component readonly, so that it is not editable.\nReadonly differs from disabled in that readonly fields are still focusable and will be submitted with a form.",
7939
- "fieldName": "readonly",
7940
- "inheritedFrom": {
7941
- "name": "ReadonlyMixin",
7942
- "module": "src/common/mixins/ReadonlyMixin.ts"
7943
- }
8045
+ "default": "\"\"",
8046
+ "description": "The name of the icon to display, as defined by [nordicons](/nordicons/).",
8047
+ "fieldName": "name"
7944
8048
  },
7945
8049
  {
7946
- "name": "disabled",
8050
+ "name": "size",
7947
8051
  "type": {
7948
- "text": "boolean"
8052
+ "text": "\"xxs\" | \"xs\" | \"s\" | \"m\" | \"l\" | \"xl\" | \"xxl\" | undefined"
7949
8053
  },
7950
- "default": "false",
7951
- "description": "Makes the component disabled. This prevents users from\nbeing able to interact with the component, and conveys\nits inactive state to assistive technologies.",
7952
- "fieldName": "disabled",
7953
- "inheritedFrom": {
7954
- "name": "InputMixin",
7955
- "module": "src/common/mixins/InputMixin.ts"
7956
- }
8054
+ "description": "The size of the icon.",
8055
+ "fieldName": "size"
7957
8056
  },
7958
8057
  {
7959
- "name": "name",
8058
+ "name": "color",
7960
8059
  "type": {
7961
8060
  "text": "string | undefined"
7962
8061
  },
7963
- "description": "The name of the form component.",
7964
- "fieldName": "name",
7965
- "inheritedFrom": {
7966
- "name": "InputMixin",
7967
- "module": "src/common/mixins/InputMixin.ts"
7968
- }
7969
- },
7970
- {
7971
- "name": "value",
7972
- "type": {
7973
- "text": "string"
7974
- },
7975
- "default": "\"\"",
7976
- "description": "The value of the form component.",
7977
- "fieldName": "value",
7978
- "inheritedFrom": {
7979
- "name": "InputMixin",
7980
- "module": "src/common/mixins/InputMixin.ts"
7981
- }
8062
+ "description": "The color of the icon.\nCan accept any valid CSS color value, including custom properties.",
8063
+ "fieldName": "color"
7982
8064
  },
7983
8065
  {
7984
- "name": "form",
8066
+ "name": "label",
7985
8067
  "type": {
7986
- "text": "HTMLFormElement | null"
8068
+ "text": "string | undefined"
7987
8069
  },
7988
- "description": "Gets the form, if any, associated with the form element.\nThe setter accepts a string, which is the id of the form.",
7989
- "fieldName": "form",
7990
- "inheritedFrom": {
7991
- "name": "InputMixin",
7992
- "module": "src/common/mixins/InputMixin.ts"
7993
- }
7994
- }
7995
- ],
7996
- "mixins": [
7997
- {
7998
- "name": "SizeMixin",
7999
- "module": "/src/common/mixins/SizeMixin.js"
8000
- },
8001
- {
8002
- "name": "FormAssociatedMixin",
8003
- "module": "/src/common/mixins/FormAssociatedMixin.js"
8004
- },
8005
- {
8006
- "name": "AutocompleteMixin",
8007
- "module": "/src/common/mixins/AutocompleteMixin.js"
8008
- },
8009
- {
8010
- "name": "ReadonlyMixin",
8011
- "module": "/src/common/mixins/ReadonlyMixin.js"
8012
- },
8013
- {
8014
- "name": "InputMixin",
8015
- "module": "/src/common/mixins/InputMixin.js"
8016
- },
8017
- {
8018
- "name": "FocusableMixin",
8019
- "module": "/src/common/mixins/FocusableMixin.js"
8070
+ "description": "An accessible label for the icon.\nIf no label is supplied, the icon is hidden from assistive technology.",
8071
+ "fieldName": "label"
8020
8072
  }
8021
8073
  ],
8022
8074
  "superclass": {
@@ -8025,36 +8077,95 @@
8025
8077
  },
8026
8078
  "localization": [],
8027
8079
  "status": "ready",
8028
- "category": "form",
8029
- "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use to provide a text input where the expected input is short.\n- Use to only ask for information that’s really needed. Hide optional fields by default if possible or have them shown with a lower priority.\n- Use help text and placeholder to provide additional, non-critical instructions.\n- Validate input as soon as users have finished interacting with them (but not before).\n- Where necessary, label the input as “Optional” when you need to request input that’s not required.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use when the expected text input is long. Use textarea component instead.\n- Don’t use the placeholder to provide information that’s required to use the input. Hint text should be used for this purpose instead.\n\n</div>\n\n---\n\n## Content guidelines\n\nInput labels act as a title for the text field. Labels should typically be short and in noun form:\n\n<div class=\"n-usage n-usage-do\">Company name</div>\n<div class=\"n-usage n-usage-dont\">What is your company name?</div>\n\nWhen writing input labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">Company name</div>\n<div class=\"n-usage n-usage-dont\">Company Name</div>\n\nWhen an input isn’t part of a form and is placed individually on a page, you could provide the input label as a call to action:\n\n<div class=\"n-usage n-usage-do\">Leave a comment</div>\n<div class=\"n-usage n-usage-dont\">Comment</div>\n\nDo not use colons in input label:\n\n<div class=\"n-usage n-usage-do\">First name</div>\n<div class=\"n-usage n-usage-dont\">First name:</div>\n\n---\n\n## Types\n\nThis section describes the different input types, their purpose, and when to use each type.\n\n| Name | Purpose |\n| ---------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------ |\n| `text` | The default and most common variant. Displayed as a single-line text field. Line-breaks are automatically removed from the input value. |\n| `email` | A field for editing an email address. Looks similar to a text input, but has validation parameters and relevant keyboard for devices with dynamic keyboards. |\n| `password` | A single-line text field where the value is obscured. This type will alert user if a site is not secure. |\n| `tel` | A field for entering a telephone number. Displays a number keypad on mobile devices. |\n| `url` | A field variant that is used to let the user enter and edit an URL. |\n| `search` | A single-line text field for entering search strings. |\n| `number` | Used to let the user enter a number. |\n\n## Icon usage in input\n\nEach [input size](/components/input/?example=size) has a recommended icon size. The medium input uses the `s` icon size, the small input uses the `xs` icon size, and the large input uses the `m` icon size. The icon will adjust size automatically based on the button size, so you will get the correct behavior by default. However, this can be overridden by explicitly setting a size on the icon.\n",
8080
+ "category": "image",
8081
+ "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<nord-button href=\"/nordicons/\" variant=\"primary\">View Nordicons</nord-button>\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use to provide additional meaning in addition to a text label.\n- Use to help users who have difficulties with reading and attention.\n- Use in places where text label doesn’t fit (remember to add an accessible label for the icon).\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for decorative purposes alone.\n- Don’t use when a button’s action is already clear based on the text label.\n- Don’t use the same icon for differing purposes, as users will come to associate icons with specific types of actions.\n\n</div>\n\n---\n\n## Additional considerations\n\n- Icon components are hidden from assistive technologies by default.\n- Use `label` property to give an accessible label for the icon and to make it visible to assistive technologies.\n",
8030
8082
  "examples": [],
8031
- "dependencies": [
8032
- "icon"
8033
- ],
8034
- "tagName": "nord-input",
8035
- "customElement": true,
8036
- "events": [
8083
+ "dependencies": [],
8084
+ "tagName": "nord-icon",
8085
+ "customElement": true
8086
+ }
8087
+ ],
8088
+ "exports": [
8089
+ {
8090
+ "kind": "js",
8091
+ "name": "default",
8092
+ "declaration": {
8093
+ "name": "Icon",
8094
+ "module": "src/icon/Icon.ts"
8095
+ }
8096
+ },
8097
+ {
8098
+ "kind": "custom-element-definition",
8099
+ "name": "nord-icon",
8100
+ "declaration": {
8101
+ "name": "Icon",
8102
+ "module": "src/icon/Icon.ts"
8103
+ }
8104
+ }
8105
+ ]
8106
+ },
8107
+ {
8108
+ "kind": "javascript-module",
8109
+ "path": "src/icon/IconManager.ts",
8110
+ "declarations": [
8111
+ {
8112
+ "kind": "class",
8113
+ "description": "",
8114
+ "name": "IconManager",
8115
+ "members": [
8037
8116
  {
8038
- "name": "input",
8039
- "type": {
8040
- "text": "NordEvent"
8041
- },
8042
- "description": "Fired as the user types into the input.",
8043
- "inheritedFrom": {
8044
- "name": "FormAssociatedMixin",
8045
- "module": "src/common/mixins/FormAssociatedMixin.ts"
8046
- }
8117
+ "kind": "field",
8118
+ "name": "cache",
8119
+ "privacy": "private",
8120
+ "default": "new Map<string, string | Promise<string>>()"
8047
8121
  },
8048
8122
  {
8049
- "name": "change",
8123
+ "kind": "field",
8124
+ "name": "resolver",
8050
8125
  "type": {
8051
- "text": "NordEvent"
8052
- },
8053
- "description": "Fired whenever the input's value is changed via user interaction.",
8054
- "inheritedFrom": {
8055
- "name": "FormAssociatedMixin",
8056
- "module": "src/common/mixins/FormAssociatedMixin.ts"
8126
+ "text": "IconResolver"
8057
8127
  }
8128
+ },
8129
+ {
8130
+ "kind": "method",
8131
+ "name": "resolve",
8132
+ "parameters": [
8133
+ {
8134
+ "name": "name",
8135
+ "type": {
8136
+ "text": "string"
8137
+ }
8138
+ },
8139
+ {
8140
+ "name": "onResolved",
8141
+ "type": {
8142
+ "text": "(svg: string) => void"
8143
+ }
8144
+ }
8145
+ ]
8146
+ },
8147
+ {
8148
+ "kind": "method",
8149
+ "name": "registerIcon",
8150
+ "parameters": [
8151
+ {
8152
+ "name": "iconOrName",
8153
+ "type": {
8154
+ "text": "string | { title: string; default: string }"
8155
+ }
8156
+ },
8157
+ {
8158
+ "name": "icon",
8159
+ "optional": true,
8160
+ "type": {
8161
+ "text": "string"
8162
+ }
8163
+ }
8164
+ ]
8165
+ },
8166
+ {
8167
+ "kind": "method",
8168
+ "name": "clear"
8058
8169
  }
8059
8170
  ]
8060
8171
  }
@@ -8062,18 +8173,10 @@
8062
8173
  "exports": [
8063
8174
  {
8064
8175
  "kind": "js",
8065
- "name": "default",
8066
- "declaration": {
8067
- "name": "Input",
8068
- "module": "src/input/Input.ts"
8069
- }
8070
- },
8071
- {
8072
- "kind": "custom-element-definition",
8073
- "name": "nord-input",
8176
+ "name": "IconManager",
8074
8177
  "declaration": {
8075
- "name": "Input",
8076
- "module": "src/input/Input.ts"
8178
+ "name": "IconManager",
8179
+ "module": "src/icon/IconManager.ts"
8077
8180
  }
8078
8181
  }
8079
8182
  ]
@@ -8117,9 +8220,13 @@
8117
8220
  "name": "top-bar"
8118
8221
  },
8119
8222
  {
8120
- "description": "Used to place content inside the header section.",
8223
+ "description": "Used to place content inside the header section. This slot can be made sticky by utilizing the `sticky` property on the layout component.",
8121
8224
  "name": "header"
8122
8225
  },
8226
+ {
8227
+ "description": "Used to place content inside the footer section. This slot can be made sticky by utilizing the `stickyFooter` property on the layout component.",
8228
+ "name": "footer"
8229
+ },
8123
8230
  {
8124
8231
  "description": "Used to place additional content/details relating to a selected item.",
8125
8232
  "name": "drawer"
@@ -8162,6 +8269,12 @@
8162
8269
  "privacy": "private",
8163
8270
  "default": "new SlotController(this, \"header\")"
8164
8271
  },
8272
+ {
8273
+ "kind": "field",
8274
+ "name": "footerSlot",
8275
+ "privacy": "private",
8276
+ "default": "new SlotController(this, \"footer\")"
8277
+ },
8165
8278
  {
8166
8279
  "kind": "field",
8167
8280
  "name": "direction",
@@ -8274,6 +8387,17 @@
8274
8387
  "attribute": "sticky",
8275
8388
  "reflects": true
8276
8389
  },
8390
+ {
8391
+ "kind": "field",
8392
+ "name": "stickyFooter",
8393
+ "type": {
8394
+ "text": "boolean"
8395
+ },
8396
+ "default": "false",
8397
+ "description": "Controls whether the layout's footer has sticky positioning.",
8398
+ "attribute": "sticky-footer",
8399
+ "reflects": true
8400
+ },
8277
8401
  {
8278
8402
  "kind": "field",
8279
8403
  "name": "isNarrow",
@@ -8518,6 +8642,15 @@
8518
8642
  "default": "false",
8519
8643
  "description": "Controls whether the layout's header has sticky positioning.",
8520
8644
  "fieldName": "sticky"
8645
+ },
8646
+ {
8647
+ "name": "sticky-footer",
8648
+ "type": {
8649
+ "text": "boolean"
8650
+ },
8651
+ "default": "false",
8652
+ "description": "Controls whether the layout's footer has sticky positioning.",
8653
+ "fieldName": "stickyFooter"
8521
8654
  }
8522
8655
  ],
8523
8656
  "superclass": {
@@ -8962,7 +9095,7 @@
8962
9095
  "description": "Label for the unread messages."
8963
9096
  }
8964
9097
  ],
8965
- "status": "draft",
9098
+ "status": "new",
8966
9099
  "category": "action",
8967
9100
  "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Messages should always perform an action when clicked.\n- The click action should navigate to a new page or provide more detail about the message.\n- Mark unread messages as read on user interaction.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t slot other components inside a message.\n\n</div>\n\n---\n\n## Content guidelines\n\nMessage content should be clear, accurate and easy to understand:\n\n<div class=\"n-usage n-usage-do\">Ariel Salminen arrived to clinic with Pixie cat.</div>\n<div class=\"n-usage n-usage-dont\">Patient arrived</div>\n\nWhen writing the message content, be concise. Keep content to 1 to 2 sentence:\n\n<div class=\"n-usage n-usage-do\">You’ve reached the limit of 30 users included in your plan. Upgrade to add more.</div>\n<div class=\"n-usage n-usage-dont\">You have reached the user limit. Your clinic can only have a maximum of 30 users. To add more users, remove users you no longer need or upgrade your plan to add more.</div>\n\nWhen writing the notification content, always write it in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">Ariel Salminen arrived to clinic with Pixie cat.</div>\n<div class=\"n-usage n-usage-dont\">Ariel Salminen Arrived To Clinic With Pixie Cat.</div>\n\nAlways end in punctuation:\n\n<div class=\"n-usage n-usage-do\">Ariel Salminen arrived to clinic with Pixie cat.</div>\n<div class=\"n-usage n-usage-dont\">Ariel Salminen arrived to clinic with Pixie cat</div>\n\nAvoid all caps for messages:\n\n<div class=\"n-usage n-usage-do\">Nina Williams arrived to clinic with Norfryd</div>\n<div class=\"n-usage n-usage-dont\">NINA WILLIAMS ARRIVED TO CLINIC WITH NORFRYD</div>\n",
8968
9101
  "examples": [],
@@ -9258,7 +9391,8 @@
9258
9391
  "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use for confirmations and conditional changes.\n- Use when the user is required to take an action.\n- Use when you need to display content that temporarily blocks interactions with the main view of an application.\n- Use when you need to ask a confirmation from a user before proceeding.\n- Use for important warnings, as a way to prevent or correct critical errors.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for nonessential information that is not related to the current userflow.\n- Don’t use when the modal requires additional information for decision making that is unavailable in the modal itself.\n- Don’t open a modal window on top of another modal.\n\n</div>\n\n---\n\n## Content guidelines\n\nModal title should be clear, accurate and predictable. Always lead with a strong verb that encourages action. To provide enough context to user, use the {verb} + {noun} content formula:\n\n<div class=\"n-usage n-usage-do\">Edit patient</div>\n<div class=\"n-usage n-usage-dont\">Edit the patient called John Doe</div>\n<div class=\"n-usage n-usage-do\">Discard changes?</div>\n<div class=\"n-usage n-usage-dont\">Discard?</div>\n<div class=\"n-usage n-usage-do\">Delete patient?</div>\n<div class=\"n-usage n-usage-dont\">Are you sure you want to delete this patent?</div>\n\nWhen writing modal titles, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">New appointment</div>\n<div class=\"n-usage n-usage-dont\">New Appointment</div>\n\nAvoid unnecessary words and articles in modal titles, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Change theme</div>\n<div class=\"n-usage n-usage-dont\">Change the theme</div>\n\nAvoid ending in punctuation:\n\n<div class=\"n-usage n-usage-do\">Edit patient</div>\n<div class=\"n-usage n-usage-dont\">Edit patient.</div>\n\n---\n\n## Focus behaviour\n\n- Use the `autofocus` attribute to set the initial focus to the first location that accepts user input.\n- If it is a transactional modal without form inputs, then `autofocus` should be set on the primary button in the modal footer. This is for efficiency since most users will simply dismiss the dialog as soon as they have read the message.\n- If the modal contains a form, use `autofocus` in the first form field.\n- Focus remains trapped inside the modal dialog until it is closed.\n- For more examples and best practices, please see [WAI-ARIA Authoring Practices Modal Dialog Example](https://www.w3.org/TR/2017/NOTE-wai-aria-practices-1.1-20171214/examples/dialog-modal/dialog.html).\n",
9259
9392
  "examples": [],
9260
9393
  "dependencies": [
9261
- "icon"
9394
+ "icon",
9395
+ "footer"
9262
9396
  ],
9263
9397
  "tagName": "nord-modal",
9264
9398
  "customElement": true
@@ -9928,98 +10062,6 @@
9928
10062
  }
9929
10063
  ]
9930
10064
  },
9931
- {
9932
- "kind": "javascript-module",
9933
- "path": "src/navigation/Navigation.ts",
9934
- "declarations": [
9935
- {
9936
- "kind": "class",
9937
- "description": "Navigation is used to display the primary navigation in the sidebar\nof an application. Navigation includes a list of links that users\nuse to move between sections of the application.",
9938
- "name": "Navigation",
9939
- "cssProperties": [
9940
- {
9941
- "description": "Controls the background color of the navigation element.",
9942
- "name": "--n-navigation-background-color",
9943
- "default": "var(--n-color-nav-surface)"
9944
- }
9945
- ],
9946
- "slots": [
9947
- {
9948
- "description": "The main section of the sidebar, for holding nav components.",
9949
- "name": ""
9950
- },
9951
- {
9952
- "description": "The top section of the sidebar.",
9953
- "name": "header"
9954
- },
9955
- {
9956
- "description": "The bottom section of the sidebar.",
9957
- "name": "footer"
9958
- }
9959
- ],
9960
- "members": [
9961
- {
9962
- "kind": "field",
9963
- "name": "headerSlot",
9964
- "privacy": "private",
9965
- "default": "new SlotController(this, \"header\")"
9966
- },
9967
- {
9968
- "kind": "field",
9969
- "name": "events",
9970
- "privacy": "private",
9971
- "default": "new EventController(this)"
9972
- },
9973
- {
9974
- "kind": "field",
9975
- "name": "allowItemsToRemainOpen",
9976
- "type": {
9977
- "text": "boolean"
9978
- },
9979
- "privacy": "private",
9980
- "default": "false"
9981
- },
9982
- {
9983
- "kind": "field",
9984
- "name": "handleActivate",
9985
- "privacy": "private"
9986
- }
9987
- ],
9988
- "superclass": {
9989
- "name": "LitElement",
9990
- "package": "lit"
9991
- },
9992
- "localization": [],
9993
- "status": "ready",
9994
- "category": "navigation",
9995
- "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use for primary navigation items that perform an action when clicked. Each action should navigate to a URL or trigger another action like a modal overlay.\n- Group navigation items into navigation groups based on related categories.\n- Use group headings to clarify the category of a section.\n- Use icons for all top level navigation items.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t place a `<nav>` element inside the navigation component, as it already contains one internally.\n\n</div>\n\n---\n\n## Content guidelines\n\nWhen writing navigation item labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">My tasks</div>\n<div class=\"n-usage n-usage-dont\">My Tasks</div>\n\nAvoid unnecessary words and articles in item labels, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Change theme</div>\n<div class=\"n-usage n-usage-dont\">Change the theme</div>\n\nAvoid ending item labels in punctuation:\n\n<div class=\"n-usage n-usage-do\">Switch user</div>\n<div class=\"n-usage n-usage-dont\">Switch user.</div>\n\nUse as few words as possible to describe each item label:\n\n<div class=\"n-usage n-usage-do\">Payments</div>\n<div class=\"n-usage n-usage-dont\">Payments in your clinic</div>\n\nAvoid all caps for item labels and group titles:\n\n<div class=\"n-usage n-usage-do\">Dashboard</div>\n<div class=\"n-usage n-usage-dont\">DASHBOARD</div>\n",
9996
- "examples": [],
9997
- "dependencies": [
9998
- "nav-item"
9999
- ],
10000
- "tagName": "nord-navigation",
10001
- "customElement": true
10002
- }
10003
- ],
10004
- "exports": [
10005
- {
10006
- "kind": "js",
10007
- "name": "default",
10008
- "declaration": {
10009
- "name": "Navigation",
10010
- "module": "src/navigation/Navigation.ts"
10011
- }
10012
- },
10013
- {
10014
- "kind": "custom-element-definition",
10015
- "name": "nord-navigation",
10016
- "declaration": {
10017
- "name": "Navigation",
10018
- "module": "src/navigation/Navigation.ts"
10019
- }
10020
- }
10021
- ]
10022
- },
10023
10065
  {
10024
10066
  "kind": "javascript-module",
10025
10067
  "path": "src/notification/Notification.ts",
@@ -10075,20 +10117,6 @@
10075
10117
  "name": "NotificationMixin",
10076
10118
  "module": "src/common/mixins/NotificationMixin.ts"
10077
10119
  }
10078
- },
10079
- {
10080
- "kind": "field",
10081
- "name": "_warningLogged",
10082
- "type": {
10083
- "text": "boolean"
10084
- },
10085
- "privacy": "private",
10086
- "static": true,
10087
- "default": "false",
10088
- "inheritedFrom": {
10089
- "name": "DraftComponentMixin",
10090
- "module": "src/common/mixins/DraftComponentMixin.ts"
10091
- }
10092
10120
  }
10093
10121
  ],
10094
10122
  "events": [
@@ -10108,10 +10136,6 @@
10108
10136
  {
10109
10137
  "name": "NotificationMixin",
10110
10138
  "module": "/src/common/mixins/NotificationMixin.js"
10111
- },
10112
- {
10113
- "name": "DraftComponentMixin",
10114
- "module": "/src/common/mixins/DraftComponentMixin.js"
10115
10139
  }
10116
10140
  ],
10117
10141
  "superclass": {
@@ -10124,7 +10148,7 @@
10124
10148
  "description": "Accessible label for the dismiss button."
10125
10149
  }
10126
10150
  ],
10127
- "status": "draft",
10151
+ "status": "new",
10128
10152
  "category": "feedback",
10129
10153
  "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use for short messages that describe the purpose of the notification.\n- Use for important updates that require user action/attention.\n- Provide a single call to action within the notification.\n- Use in combination with [Notification group](../notification-group/) so that notifications get styled and positioned correctly.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for transient or unimportant messages. Consider using a [Toast](/components/toast) instead.\n- Don't remove a notification until a user has explicitly dismissed, or acted on the notification.\n- Don’t use for error messages unless absolutely necessary. Try to favor a [Banner](/components/banner/) for error messaging instead.\n\n</div>\n\n---\n\n## Content guidelines\n\nNotification content should be clear, accurate and easy to understand:\n\n<div class=\"n-usage n-usage-do\">Ariel Salminen arrived to clinic with Pixie cat.</div>\n<div class=\"n-usage n-usage-dont\">Patient arrived</div>\n\nWhen writing the notification content, be concise. Keep content to 1 to 2 sentence:\n\n<div class=\"n-usage n-usage-do\">You’ve reached the limit of 30 users included in your plan. Upgrade to add more.</div>\n<div class=\"n-usage n-usage-dont\">You have reached the user limit. Your clinic can only have a maximum of 30 users. To add more users, remove users you no longer need or upgrade your plan to add more.</div>\n\nWhen writing the notification content, always write it in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">Ariel Salminen arrived to clinic with Pixie cat.</div>\n<div class=\"n-usage n-usage-dont\">Ariel Salminen Arrived To Clinic With Pixie Cat.</div>\n\nAlways end in punctuation:\n\n<div class=\"n-usage n-usage-do\">Ariel Salminen arrived to clinic with Pixie cat.</div>\n<div class=\"n-usage n-usage-dont\">Ariel Salminen arrived to clinic with Pixie cat</div>\n\nAction link labels in notifications should be clear, accurate and predictable. It should be possible for the user to understand what will happen when they click a button:\n\n<div class=\"n-usage n-usage-do\">Start consultation</div>\n<div class=\"n-usage n-usage-dont\">Click here</div>\n\nWhen writing action link labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">Start consultation</div>\n<div class=\"n-usage n-usage-dont\">Start Consultation</div>\n\nAvoid unnecessary words and articles in action link labels, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Add item</div>\n<div class=\"n-usage n-usage-dont\">Add an item</div>\n",
10130
10154
  "examples": [],
@@ -10181,38 +10205,59 @@
10181
10205
  },
10182
10206
  {
10183
10207
  "kind": "javascript-module",
10184
- "path": "src/notification-group/NotificationGroup.ts",
10208
+ "path": "src/navigation/Navigation.ts",
10185
10209
  "declarations": [
10186
10210
  {
10187
10211
  "kind": "class",
10188
- "description": "Notification group is used to position and style a group of notifications.",
10189
- "name": "NotificationGroup",
10212
+ "description": "Navigation is used to display the primary navigation in the sidebar\nof an application. Navigation includes a list of links that users\nuse to move between sections of the application.",
10213
+ "name": "Navigation",
10214
+ "cssProperties": [
10215
+ {
10216
+ "description": "Controls the background color of the navigation element.",
10217
+ "name": "--n-navigation-background-color",
10218
+ "default": "var(--n-color-nav-surface)"
10219
+ }
10220
+ ],
10190
10221
  "slots": [
10191
10222
  {
10192
- "description": "Default slot in which to place notifications.",
10223
+ "description": "The main section of the sidebar, for holding nav components.",
10193
10224
  "name": ""
10225
+ },
10226
+ {
10227
+ "description": "The top section of the sidebar.",
10228
+ "name": "header"
10229
+ },
10230
+ {
10231
+ "description": "The bottom section of the sidebar.",
10232
+ "name": "footer"
10194
10233
  }
10195
10234
  ],
10196
10235
  "members": [
10197
10236
  {
10198
10237
  "kind": "field",
10199
- "name": "_warningLogged",
10238
+ "name": "headerSlot",
10239
+ "privacy": "private",
10240
+ "default": "new SlotController(this, \"header\")"
10241
+ },
10242
+ {
10243
+ "kind": "field",
10244
+ "name": "events",
10245
+ "privacy": "private",
10246
+ "default": "new EventController(this)"
10247
+ },
10248
+ {
10249
+ "kind": "field",
10250
+ "name": "allowItemsToRemainOpen",
10200
10251
  "type": {
10201
10252
  "text": "boolean"
10202
10253
  },
10203
10254
  "privacy": "private",
10204
- "static": true,
10205
- "default": "false",
10206
- "inheritedFrom": {
10207
- "name": "DraftComponentMixin",
10208
- "module": "src/common/mixins/DraftComponentMixin.ts"
10209
- }
10210
- }
10211
- ],
10212
- "mixins": [
10255
+ "default": "false"
10256
+ },
10213
10257
  {
10214
- "name": "DraftComponentMixin",
10215
- "module": "/src/common/mixins/DraftComponentMixin.js"
10258
+ "kind": "field",
10259
+ "name": "handleActivate",
10260
+ "privacy": "private"
10216
10261
  }
10217
10262
  ],
10218
10263
  "superclass": {
@@ -10220,12 +10265,14 @@
10220
10265
  "package": "lit"
10221
10266
  },
10222
10267
  "localization": [],
10223
- "status": "draft",
10224
- "category": "feedback",
10225
- "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use in combination with [Notification](/components/notification/) so that notifications get styled and positioned correctly.\n- Add as close to the start of your main content area as possible.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for grouping anything other than notification components\n\n</div>\n\n---\n\n## Content guidelines\n\nNotification content should be clear, accurate and easy to understand:\n\n<div class=\"n-usage n-usage-do\">Ariel Salminen arrived to clinic with Pixie cat.</div>\n<div class=\"n-usage n-usage-dont\">Patient arrived</div>\n\nWhen writing the notification content, be concise. Keep content to 1 to 2 sentence:\n\n<div class=\"n-usage n-usage-do\">Youve reached the limit of 30 users included in your plan. Upgrade to add more.</div>\n<div class=\"n-usage n-usage-dont\">You have reached the user limit. Your clinic can only have a maximum of 30 users. To add more users, remove users you no longer need or upgrade your plan to add more.</div>\n\nWhen writing the notification content, always write it in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">Ariel Salminen arrived to clinic with Pixie cat.</div>\n<div class=\"n-usage n-usage-dont\">Ariel Salminen Arrived To Clinic With Pixie Cat.</div>\n\nAlways end in punctuation:\n\n<div class=\"n-usage n-usage-do\">Ariel Salminen arrived to clinic with Pixie cat.</div>\n<div class=\"n-usage n-usage-dont\">Ariel Salminen arrived to clinic with Pixie cat</div>\n\nAction link labels in notifications should be clear, accurate and predictable. It should be possible for the user to understand what will happen when they click a button:\n\n<div class=\"n-usage n-usage-do\">Start consultation</div>\n<div class=\"n-usage n-usage-dont\">Click here</div>\n\nWhen writing action link labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">Start consultation</div>\n<div class=\"n-usage n-usage-dont\">Start Consultation</div>\n\nAvoid unnecessary words and articles in action link labels, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Add item</div>\n<div class=\"n-usage n-usage-dont\">Add an item</div>\n",
10268
+ "status": "ready",
10269
+ "category": "navigation",
10270
+ "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use for primary navigation items that perform an action when clicked. Each action should navigate to a URL or trigger another action like a modal overlay.\n- Group navigation items into navigation groups based on related categories.\n- Use group headings to clarify the category of a section.\n- Use icons for all top level navigation items.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Dont place a `<nav>` element inside the navigation component, as it already contains one internally.\n\n</div>\n\n---\n\n## Content guidelines\n\nWhen writing navigation item labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">My tasks</div>\n<div class=\"n-usage n-usage-dont\">My Tasks</div>\n\nAvoid unnecessary words and articles in item labels, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Change theme</div>\n<div class=\"n-usage n-usage-dont\">Change the theme</div>\n\nAvoid ending item labels in punctuation:\n\n<div class=\"n-usage n-usage-do\">Switch user</div>\n<div class=\"n-usage n-usage-dont\">Switch user.</div>\n\nUse as few words as possible to describe each item label:\n\n<div class=\"n-usage n-usage-do\">Payments</div>\n<div class=\"n-usage n-usage-dont\">Payments in your clinic</div>\n\nAvoid all caps for item labels and group titles:\n\n<div class=\"n-usage n-usage-do\">Dashboard</div>\n<div class=\"n-usage n-usage-dont\">DASHBOARD</div>\n",
10226
10271
  "examples": [],
10227
- "dependencies": [],
10228
- "tagName": "nord-notification-group",
10272
+ "dependencies": [
10273
+ "nav-item"
10274
+ ],
10275
+ "tagName": "nord-navigation",
10229
10276
  "customElement": true
10230
10277
  }
10231
10278
  ],
@@ -10234,16 +10281,16 @@
10234
10281
  "kind": "js",
10235
10282
  "name": "default",
10236
10283
  "declaration": {
10237
- "name": "NotificationGroup",
10238
- "module": "src/notification-group/NotificationGroup.ts"
10284
+ "name": "Navigation",
10285
+ "module": "src/navigation/Navigation.ts"
10239
10286
  }
10240
10287
  },
10241
10288
  {
10242
10289
  "kind": "custom-element-definition",
10243
- "name": "nord-notification-group",
10290
+ "name": "nord-navigation",
10244
10291
  "declaration": {
10245
- "name": "NotificationGroup",
10246
- "module": "src/notification-group/NotificationGroup.ts"
10292
+ "name": "Navigation",
10293
+ "module": "src/navigation/Navigation.ts"
10247
10294
  }
10248
10295
  }
10249
10296
  ]
@@ -10591,6 +10638,54 @@
10591
10638
  }
10592
10639
  ]
10593
10640
  },
10641
+ {
10642
+ "kind": "javascript-module",
10643
+ "path": "src/notification-group/NotificationGroup.ts",
10644
+ "declarations": [
10645
+ {
10646
+ "kind": "class",
10647
+ "description": "Notification group is used to position and style a group of notifications.",
10648
+ "name": "NotificationGroup",
10649
+ "slots": [
10650
+ {
10651
+ "description": "Default slot in which to place notifications.",
10652
+ "name": ""
10653
+ }
10654
+ ],
10655
+ "members": [],
10656
+ "superclass": {
10657
+ "name": "LitElement",
10658
+ "package": "lit"
10659
+ },
10660
+ "localization": [],
10661
+ "status": "new",
10662
+ "category": "feedback",
10663
+ "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use in combination with [Notification](/components/notification/) so that notifications get styled and positioned correctly.\n- Add as close to the start of your main content area as possible.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for grouping anything other than notification components\n\n</div>\n\n---\n\n## Content guidelines\n\nNotification content should be clear, accurate and easy to understand:\n\n<div class=\"n-usage n-usage-do\">Ariel Salminen arrived to clinic with Pixie cat.</div>\n<div class=\"n-usage n-usage-dont\">Patient arrived</div>\n\nWhen writing the notification content, be concise. Keep content to 1 to 2 sentence:\n\n<div class=\"n-usage n-usage-do\">You’ve reached the limit of 30 users included in your plan. Upgrade to add more.</div>\n<div class=\"n-usage n-usage-dont\">You have reached the user limit. Your clinic can only have a maximum of 30 users. To add more users, remove users you no longer need or upgrade your plan to add more.</div>\n\nWhen writing the notification content, always write it in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">Ariel Salminen arrived to clinic with Pixie cat.</div>\n<div class=\"n-usage n-usage-dont\">Ariel Salminen Arrived To Clinic With Pixie Cat.</div>\n\nAlways end in punctuation:\n\n<div class=\"n-usage n-usage-do\">Ariel Salminen arrived to clinic with Pixie cat.</div>\n<div class=\"n-usage n-usage-dont\">Ariel Salminen arrived to clinic with Pixie cat</div>\n\nAction link labels in notifications should be clear, accurate and predictable. It should be possible for the user to understand what will happen when they click a button:\n\n<div class=\"n-usage n-usage-do\">Start consultation</div>\n<div class=\"n-usage n-usage-dont\">Click here</div>\n\nWhen writing action link labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">Start consultation</div>\n<div class=\"n-usage n-usage-dont\">Start Consultation</div>\n\nAvoid unnecessary words and articles in action link labels, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Add item</div>\n<div class=\"n-usage n-usage-dont\">Add an item</div>\n",
10664
+ "examples": [],
10665
+ "dependencies": [],
10666
+ "tagName": "nord-notification-group",
10667
+ "customElement": true
10668
+ }
10669
+ ],
10670
+ "exports": [
10671
+ {
10672
+ "kind": "js",
10673
+ "name": "default",
10674
+ "declaration": {
10675
+ "name": "NotificationGroup",
10676
+ "module": "src/notification-group/NotificationGroup.ts"
10677
+ }
10678
+ },
10679
+ {
10680
+ "kind": "custom-element-definition",
10681
+ "name": "nord-notification-group",
10682
+ "declaration": {
10683
+ "name": "NotificationGroup",
10684
+ "module": "src/notification-group/NotificationGroup.ts"
10685
+ }
10686
+ }
10687
+ ]
10688
+ },
10594
10689
  {
10595
10690
  "kind": "javascript-module",
10596
10691
  "path": "src/progress-bar/ProgressBar.ts",
@@ -10706,214 +10801,28 @@
10706
10801
  "fieldName": "value"
10707
10802
  },
10708
10803
  {
10709
- "name": "max",
10710
- "type": {
10711
- "text": "number"
10712
- },
10713
- "default": "100",
10714
- "description": "Describes how much work the task indicated by the progress element requires.\nThe max attribute, if present, must have a value greater than 0 and be a\nvalid floating point number.",
10715
- "fieldName": "max"
10716
- },
10717
- {
10718
- "name": "label",
10719
- "type": {
10720
- "text": "string"
10721
- },
10722
- "default": "\"Current progress\"",
10723
- "description": "Accessible label for the progress indicator. Visually hidden, but shown\nfor assistive technology.",
10724
- "fieldName": "label"
10725
- }
10726
- ],
10727
- "mixins": [
10728
- {
10729
- "name": "FocusableMixin",
10730
- "module": "/src/common/mixins/FocusableMixin.js"
10731
- }
10732
- ],
10733
- "superclass": {
10734
- "name": "LitElement",
10735
- "package": "lit"
10736
- },
10737
- "localization": [],
10738
- "status": "ready",
10739
- "category": "feedback",
10740
- "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use to show the completion status of an ongoing task.\n- Use progress bar when you can determine the percentage of the completed task at any time.\n- Always provide an accessible label when using Progress Bar.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use in constrained spaces indicating indeterminate loading state, see [Spinner](/components/spinner/) instead.\n\n</div>\n",
10741
- "examples": [],
10742
- "dependencies": [],
10743
- "tagName": "nord-progress-bar",
10744
- "customElement": true
10745
- }
10746
- ],
10747
- "exports": [
10748
- {
10749
- "kind": "js",
10750
- "name": "default",
10751
- "declaration": {
10752
- "name": "ProgressBar",
10753
- "module": "src/progress-bar/ProgressBar.ts"
10754
- }
10755
- },
10756
- {
10757
- "kind": "custom-element-definition",
10758
- "name": "nord-progress-bar",
10759
- "declaration": {
10760
- "name": "ProgressBar",
10761
- "module": "src/progress-bar/ProgressBar.ts"
10762
- }
10763
- }
10764
- ]
10765
- },
10766
- {
10767
- "kind": "javascript-module",
10768
- "path": "src/qrcode/Qrcode.ts",
10769
- "declarations": [
10770
- {
10771
- "kind": "class",
10772
- "description": "QR Code component is used for providing information or links\nto users which they can quickly scan with their smartphone.",
10773
- "name": "Qrcode",
10774
- "members": [
10775
- {
10776
- "kind": "field",
10777
- "name": "canvas",
10778
- "type": {
10779
- "text": "HTMLElement"
10780
- },
10781
- "privacy": "private"
10782
- },
10783
- {
10784
- "kind": "field",
10785
- "name": "computed",
10786
- "type": {
10787
- "text": "HTMLElement"
10788
- },
10789
- "privacy": "private"
10790
- },
10791
- {
10792
- "kind": "field",
10793
- "name": "value",
10794
- "type": {
10795
- "text": "string"
10796
- },
10797
- "default": "\"\"",
10798
- "description": "The value of the QR Code, most commonly an URL.",
10799
- "attribute": "value",
10800
- "reflects": true
10801
- },
10802
- {
10803
- "kind": "field",
10804
- "name": "label",
10805
- "type": {
10806
- "text": "string"
10807
- },
10808
- "default": "\"\"",
10809
- "description": "Label used by assistive technology. If unspecified, the value will\nbe used instead.",
10810
- "attribute": "label",
10811
- "reflects": true
10812
- },
10813
- {
10814
- "kind": "field",
10815
- "name": "size",
10816
- "type": {
10817
- "text": "number"
10818
- },
10819
- "default": "128",
10820
- "description": "The size of the rendered QR Code in pixels.",
10821
- "attribute": "size",
10822
- "reflects": true
10823
- },
10824
- {
10825
- "kind": "field",
10826
- "name": "color",
10827
- "type": {
10828
- "text": "string"
10829
- },
10830
- "default": "\"var(--n-color-text)\"",
10831
- "description": "The fill color of the QR Code.\nCan accept any valid CSS color value, including custom properties.",
10832
- "attribute": "color",
10833
- "reflects": true
10834
- },
10835
- {
10836
- "kind": "field",
10837
- "name": "background",
10838
- "type": {
10839
- "text": "string"
10840
- },
10841
- "default": "\"var(--n-color-surface)\"",
10842
- "description": "The background color of the QR Code.\nCan accept any valid CSS color value, including custom properties.",
10843
- "attribute": "background",
10844
- "reflects": true
10845
- },
10846
- {
10847
- "kind": "field",
10848
- "name": "correction",
10849
- "type": {
10850
- "text": "\"L\" | \"M\" | \"Q\" | \"H\""
10851
- },
10852
- "default": "\"H\"",
10853
- "description": "Error correction level makes the QR Code bigger and helps users to\nscan it without issues. L, M, Q and H values will use 7%, 15%, 25%\nand 30% of the QR code for error correction respectively.",
10854
- "attribute": "correction",
10855
- "reflects": true
10856
- },
10857
- {
10858
- "kind": "method",
10859
- "name": "generate",
10860
- "privacy": "private"
10861
- }
10862
- ],
10863
- "attributes": [
10864
- {
10865
- "name": "value",
10866
- "type": {
10867
- "text": "string"
10868
- },
10869
- "default": "\"\"",
10870
- "description": "The value of the QR Code, most commonly an URL.",
10871
- "fieldName": "value"
10872
- },
10873
- {
10874
- "name": "label",
10875
- "type": {
10876
- "text": "string"
10877
- },
10878
- "default": "\"\"",
10879
- "description": "Label used by assistive technology. If unspecified, the value will\nbe used instead.",
10880
- "fieldName": "label"
10881
- },
10882
- {
10883
- "name": "size",
10884
- "type": {
10885
- "text": "number"
10886
- },
10887
- "default": "128",
10888
- "description": "The size of the rendered QR Code in pixels.",
10889
- "fieldName": "size"
10890
- },
10891
- {
10892
- "name": "color",
10893
- "type": {
10894
- "text": "string"
10895
- },
10896
- "default": "\"var(--n-color-text)\"",
10897
- "description": "The fill color of the QR Code.\nCan accept any valid CSS color value, including custom properties.",
10898
- "fieldName": "color"
10899
- },
10900
- {
10901
- "name": "background",
10804
+ "name": "max",
10902
10805
  "type": {
10903
- "text": "string"
10806
+ "text": "number"
10904
10807
  },
10905
- "default": "\"var(--n-color-surface)\"",
10906
- "description": "The background color of the QR Code.\nCan accept any valid CSS color value, including custom properties.",
10907
- "fieldName": "background"
10808
+ "default": "100",
10809
+ "description": "Describes how much work the task indicated by the progress element requires.\nThe max attribute, if present, must have a value greater than 0 and be a\nvalid floating point number.",
10810
+ "fieldName": "max"
10908
10811
  },
10909
10812
  {
10910
- "name": "correction",
10813
+ "name": "label",
10911
10814
  "type": {
10912
- "text": "\"L\" | \"M\" | \"Q\" | \"H\""
10815
+ "text": "string"
10913
10816
  },
10914
- "default": "\"H\"",
10915
- "description": "Error correction level makes the QR Code bigger and helps users to\nscan it without issues. L, M, Q and H values will use 7%, 15%, 25%\nand 30% of the QR code for error correction respectively.",
10916
- "fieldName": "correction"
10817
+ "default": "\"Current progress\"",
10818
+ "description": "Accessible label for the progress indicator. Visually hidden, but shown\nfor assistive technology.",
10819
+ "fieldName": "label"
10820
+ }
10821
+ ],
10822
+ "mixins": [
10823
+ {
10824
+ "name": "FocusableMixin",
10825
+ "module": "/src/common/mixins/FocusableMixin.js"
10917
10826
  }
10918
10827
  ],
10919
10828
  "superclass": {
@@ -10922,12 +10831,11 @@
10922
10831
  },
10923
10832
  "localization": [],
10924
10833
  "status": "ready",
10925
- "category": "image",
10926
- "displayName": "QR Code",
10927
- "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use to allow people to access information on their smartphone without the need to type.\n- Always provide an alternative way to access the same information.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t hide important information behind a QR Code only.\n\n</div>\n",
10834
+ "category": "feedback",
10835
+ "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use to show the completion status of an ongoing task.\n- Use progress bar when you can determine the percentage of the completed task at any time.\n- Always provide an accessible label when using Progress Bar.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use in constrained spaces indicating indeterminate loading state, see [Spinner](/components/spinner/) instead.\n\n</div>\n",
10928
10836
  "examples": [],
10929
10837
  "dependencies": [],
10930
- "tagName": "nord-qrcode",
10838
+ "tagName": "nord-progress-bar",
10931
10839
  "customElement": true
10932
10840
  }
10933
10841
  ],
@@ -10936,51 +10844,63 @@
10936
10844
  "kind": "js",
10937
10845
  "name": "default",
10938
10846
  "declaration": {
10939
- "name": "Qrcode",
10940
- "module": "src/qrcode/Qrcode.ts"
10847
+ "name": "ProgressBar",
10848
+ "module": "src/progress-bar/ProgressBar.ts"
10941
10849
  }
10942
10850
  },
10943
10851
  {
10944
10852
  "kind": "custom-element-definition",
10945
- "name": "nord-qrcode",
10853
+ "name": "nord-progress-bar",
10946
10854
  "declaration": {
10947
- "name": "Qrcode",
10948
- "module": "src/qrcode/Qrcode.ts"
10855
+ "name": "ProgressBar",
10856
+ "module": "src/progress-bar/ProgressBar.ts"
10949
10857
  }
10950
10858
  }
10951
10859
  ]
10952
10860
  },
10953
10861
  {
10954
10862
  "kind": "javascript-module",
10955
- "path": "src/radio/Radio.ts",
10863
+ "path": "src/select/Select.ts",
10956
10864
  "declarations": [
10957
10865
  {
10958
10866
  "kind": "class",
10959
- "description": "Radio buttons are graphical user interface elements that allow user to choose only one option from\na predefined set of mutually exclusive options.",
10960
- "name": "Radio",
10867
+ "description": "Select lets users choose one option from an options menu.\nConsider using select when you have 5 or more options to choose from.",
10868
+ "name": "Select",
10869
+ "cssProperties": [
10870
+ {
10871
+ "description": "Controls the block size, or height, of the select using our [spacing tokens](/tokens/#space).",
10872
+ "name": "--n-select-block-size",
10873
+ "default": "var(--n-space-xl)"
10874
+ }
10875
+ ],
10961
10876
  "slots": [
10877
+ {
10878
+ "description": "Default slot for holding <option> elements.",
10879
+ "name": ""
10880
+ },
10962
10881
  {
10963
10882
  "description": "Use when a label requires more than plain text.",
10964
10883
  "name": "label"
10965
10884
  },
10966
10885
  {
10967
- "description": "Optional slot that holds hint text for the input.",
10886
+ "description": "Use when a hint requires more than plain text.",
10968
10887
  "name": "hint"
10969
10888
  },
10970
10889
  {
10971
10890
  "description": "Optional slot that holds error text for the input.",
10972
10891
  "name": "error"
10892
+ },
10893
+ {
10894
+ "description": "Used to place an icon at the start of select.",
10895
+ "name": "icon"
10973
10896
  }
10974
10897
  ],
10975
10898
  "members": [
10976
10899
  {
10977
10900
  "kind": "field",
10978
- "name": "inputId",
10979
- "type": {
10980
- "text": "string"
10981
- },
10901
+ "name": "formValue",
10982
10902
  "privacy": "protected",
10983
- "default": "\"input\"",
10903
+ "readonly": true,
10984
10904
  "inheritedFrom": {
10985
10905
  "name": "FormAssociatedMixin",
10986
10906
  "module": "src/common/mixins/FormAssociatedMixin.ts"
@@ -10988,12 +10908,18 @@
10988
10908
  },
10989
10909
  {
10990
10910
  "kind": "field",
10991
- "name": "hintId",
10911
+ "name": "defaultSlot",
10912
+ "privacy": "private",
10913
+ "default": "new SlotController(this)"
10914
+ },
10915
+ {
10916
+ "kind": "field",
10917
+ "name": "inputId",
10992
10918
  "type": {
10993
10919
  "text": "string"
10994
10920
  },
10995
10921
  "privacy": "protected",
10996
- "default": "\"hint\"",
10922
+ "default": "\"select\"",
10997
10923
  "inheritedFrom": {
10998
10924
  "name": "FormAssociatedMixin",
10999
10925
  "module": "src/common/mixins/FormAssociatedMixin.ts"
@@ -11001,33 +10927,72 @@
11001
10927
  },
11002
10928
  {
11003
10929
  "kind": "field",
11004
- "name": "errorId",
10930
+ "name": "expand",
11005
10931
  "type": {
11006
- "text": "string"
10932
+ "text": "boolean"
11007
10933
  },
11008
- "privacy": "protected",
11009
- "default": "\"error\"",
11010
- "inheritedFrom": {
11011
- "name": "FormAssociatedMixin",
11012
- "module": "src/common/mixins/FormAssociatedMixin.ts"
11013
- }
10934
+ "default": "false",
10935
+ "description": "Controls whether the select expands to fill the width of its container.",
10936
+ "attribute": "expand",
10937
+ "reflects": true
11014
10938
  },
11015
10939
  {
11016
10940
  "kind": "field",
11017
- "name": "hintSlot",
11018
- "privacy": "protected",
11019
- "default": "new LightSlotController(this, {\n slotName: \"hint\",\n render: () => (this.hint ? html`<div slot=\"hint-internal\" id=${this.hintId}>${this.hint}</div>` : nothing),\n syncLightDom: element => {\n element.id = this.hintId\n },\n })",
11020
- "description": "For accessibility reasons, we render some parts of the component to the light DOM.",
10941
+ "name": "options",
10942
+ "privacy": "private",
10943
+ "readonly": true
10944
+ },
10945
+ {
10946
+ "kind": "method",
10947
+ "name": "getButtonText",
10948
+ "privacy": "private",
10949
+ "return": {
10950
+ "type": {
10951
+ "text": "string"
10952
+ }
10953
+ },
10954
+ "parameters": [
10955
+ {
10956
+ "name": "options",
10957
+ "type": {
10958
+ "text": "HTMLOptionElement[]"
10959
+ }
10960
+ }
10961
+ ]
10962
+ },
10963
+ {
10964
+ "kind": "method",
10965
+ "name": "renderOption",
10966
+ "privacy": "private",
10967
+ "parameters": [
10968
+ {
10969
+ "name": "option",
10970
+ "type": {
10971
+ "text": "HTMLOptionElement"
10972
+ }
10973
+ }
10974
+ ]
10975
+ },
10976
+ {
10977
+ "kind": "field",
10978
+ "name": "size",
10979
+ "type": {
10980
+ "text": "\"s\" | \"m\" | \"l\""
10981
+ },
10982
+ "default": "\"m\"",
10983
+ "description": "The size of the component.",
10984
+ "attribute": "size",
10985
+ "reflects": true,
11021
10986
  "inheritedFrom": {
11022
- "name": "FormAssociatedMixin",
11023
- "module": "src/common/mixins/FormAssociatedMixin.ts"
10987
+ "name": "SizeMixin",
10988
+ "module": "src/common/mixins/SizeMixin.ts"
11024
10989
  }
11025
10990
  },
11026
10991
  {
11027
10992
  "kind": "field",
11028
10993
  "name": "labelSlot",
11029
10994
  "privacy": "protected",
11030
- "default": "new LightSlotController(this, {\n slotName: \"label\",\n render: () => (this.label ? html`<label slot=\"label-internal\" for=${this.inputId}>${this.label}</label>` : nothing),\n syncLightDom: element => {\n if (!isLabel(element)) {\n // eslint-disable-next-line no-console\n console.warn(`NORD: Only <label> elements should be placed in radio's \"label\" slot`)\n } else {\n element.htmlFor = this.inputId\n }\n },\n })",
10995
+ "default": "new SlotController(this, \"label\")",
11031
10996
  "inheritedFrom": {
11032
10997
  "name": "FormAssociatedMixin",
11033
10998
  "module": "src/common/mixins/FormAssociatedMixin.ts"
@@ -11037,7 +11002,7 @@
11037
11002
  "kind": "field",
11038
11003
  "name": "errorSlot",
11039
11004
  "privacy": "protected",
11040
- "default": "new LightSlotController(this, {\n slotName: \"error\",\n render: () => (this.error ? html`<div slot=\"error-internal\" id=${this.errorId}>${this.error}</div>` : nothing),\n syncLightDom: element => {\n element.id = this.hintId\n },\n })",
11005
+ "default": "new SlotController(this, \"error\")",
11041
11006
  "inheritedFrom": {
11042
11007
  "name": "FormAssociatedMixin",
11043
11008
  "module": "src/common/mixins/FormAssociatedMixin.ts"
@@ -11045,15 +11010,19 @@
11045
11010
  },
11046
11011
  {
11047
11012
  "kind": "field",
11048
- "name": "inputSlot",
11013
+ "name": "hintSlot",
11049
11014
  "privacy": "protected",
11050
- "default": "new LightDomController(this, {\n render: () =>\n html`\n <input\n slot=\"input\"\n @blur=${this.handleBlur}\n @focus=${this.handleFocus}\n ${ref(this.focusableRef)}\n class=\"n-input\"\n id=${this.inputId}\n type=\"radio\"\n name=${cond(this.name)}\n .value=${cond(this.value)}\n .checked=${this.checked}\n ?disabled=${this.disabled}\n ?required=${this.required}\n aria-describedby=${cond(this.getDescribedBy())}\n aria-invalid=${cond(this.getInvalid())}\n form=${cond(this._formId)}\n />\n `,\n })"
11015
+ "default": "new SlotController(this, \"hint\")",
11016
+ "inheritedFrom": {
11017
+ "name": "FormAssociatedMixin",
11018
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
11019
+ }
11051
11020
  },
11052
11021
  {
11053
11022
  "kind": "field",
11054
- "name": "formValue",
11023
+ "name": "formData",
11055
11024
  "privacy": "protected",
11056
- "readonly": true,
11025
+ "default": "new FormDataController(this, { value: () => this.formValue })",
11057
11026
  "inheritedFrom": {
11058
11027
  "name": "FormAssociatedMixin",
11059
11028
  "module": "src/common/mixins/FormAssociatedMixin.ts"
@@ -11061,50 +11030,12 @@
11061
11030
  },
11062
11031
  {
11063
11032
  "kind": "field",
11064
- "name": "checked",
11033
+ "name": "errorId",
11065
11034
  "type": {
11066
- "text": "boolean"
11035
+ "text": "string"
11067
11036
  },
11068
- "default": "false",
11069
- "description": "Controls whether the checkbox is checked or not.",
11070
- "attribute": "checked",
11071
- "reflects": true
11072
- },
11073
- {
11074
- "kind": "method",
11075
- "name": "handleCheckedChange",
11076
- "privacy": "protected",
11077
- "parameters": [
11078
- {
11079
- "name": "previousChecked",
11080
- "type": {
11081
- "text": "boolean"
11082
- }
11083
- }
11084
- ]
11085
- },
11086
- {
11087
- "kind": "method",
11088
- "name": "uncheckSiblings",
11089
- "privacy": "private"
11090
- },
11091
- {
11092
- "kind": "method",
11093
- "name": "handleChange",
11094
11037
  "privacy": "protected",
11095
- "parameters": [
11096
- {
11097
- "name": "e",
11098
- "type": {
11099
- "text": "Event"
11100
- }
11101
- }
11102
- ],
11103
- "return": {
11104
- "type": {
11105
- "text": "void"
11106
- }
11107
- },
11038
+ "default": "\"error\"",
11108
11039
  "inheritedFrom": {
11109
11040
  "name": "FormAssociatedMixin",
11110
11041
  "module": "src/common/mixins/FormAssociatedMixin.ts"
@@ -11112,19 +11043,12 @@
11112
11043
  },
11113
11044
  {
11114
11045
  "kind": "field",
11115
- "name": "handleBlur",
11116
- "privacy": "private"
11117
- },
11118
- {
11119
- "kind": "field",
11120
- "name": "handleFocus",
11121
- "privacy": "private"
11122
- },
11123
- {
11124
- "kind": "field",
11125
- "name": "formData",
11046
+ "name": "hintId",
11047
+ "type": {
11048
+ "text": "string"
11049
+ },
11126
11050
  "privacy": "protected",
11127
- "default": "new FormDataController(this, { value: () => this.formValue })",
11051
+ "default": "\"hint\"",
11128
11052
  "inheritedFrom": {
11129
11053
  "name": "FormAssociatedMixin",
11130
11054
  "module": "src/common/mixins/FormAssociatedMixin.ts"
@@ -11242,6 +11166,23 @@
11242
11166
  "module": "src/common/mixins/FormAssociatedMixin.ts"
11243
11167
  }
11244
11168
  },
11169
+ {
11170
+ "kind": "method",
11171
+ "name": "handleChange",
11172
+ "privacy": "protected",
11173
+ "parameters": [
11174
+ {
11175
+ "name": "e",
11176
+ "type": {
11177
+ "text": "Event"
11178
+ }
11179
+ }
11180
+ ],
11181
+ "inheritedFrom": {
11182
+ "name": "FormAssociatedMixin",
11183
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
11184
+ }
11185
+ },
11245
11186
  {
11246
11187
  "kind": "method",
11247
11188
  "name": "renderLabel",
@@ -11303,8 +11244,22 @@
11303
11244
  "privacy": "protected",
11304
11245
  "readonly": true,
11305
11246
  "inheritedFrom": {
11306
- "name": "FormAssociatedMixin",
11307
- "module": "src/common/mixins/FormAssociatedMixin.ts"
11247
+ "name": "FormAssociatedMixin",
11248
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
11249
+ }
11250
+ },
11251
+ {
11252
+ "kind": "field",
11253
+ "name": "autocomplete",
11254
+ "type": {
11255
+ "text": "AutocompleteAttribute"
11256
+ },
11257
+ "default": "\"off\"",
11258
+ "description": "Specifies the data type of the field, so that the browser may attempt to fill out the field automatically on behalf of the user.",
11259
+ "attribute": "autocomplete",
11260
+ "inheritedFrom": {
11261
+ "name": "AutocompleteMixin",
11262
+ "module": "src/common/mixins/AutocompleteMixin.ts"
11308
11263
  }
11309
11264
  },
11310
11265
  {
@@ -11436,13 +11391,26 @@
11436
11391
  ],
11437
11392
  "attributes": [
11438
11393
  {
11439
- "name": "checked",
11394
+ "name": "expand",
11440
11395
  "type": {
11441
11396
  "text": "boolean"
11442
11397
  },
11443
11398
  "default": "false",
11444
- "description": "Controls whether the checkbox is checked or not.",
11445
- "fieldName": "checked"
11399
+ "description": "Controls whether the select expands to fill the width of its container.",
11400
+ "fieldName": "expand"
11401
+ },
11402
+ {
11403
+ "name": "size",
11404
+ "type": {
11405
+ "text": "\"s\" | \"m\" | \"l\""
11406
+ },
11407
+ "default": "\"m\"",
11408
+ "description": "The size of the component.",
11409
+ "fieldName": "size",
11410
+ "inheritedFrom": {
11411
+ "name": "SizeMixin",
11412
+ "module": "src/common/mixins/SizeMixin.ts"
11413
+ }
11446
11414
  },
11447
11415
  {
11448
11416
  "name": "label",
@@ -11532,6 +11500,19 @@
11532
11500
  "module": "src/common/mixins/FormAssociatedMixin.ts"
11533
11501
  }
11534
11502
  },
11503
+ {
11504
+ "name": "autocomplete",
11505
+ "type": {
11506
+ "text": "AutocompleteAttribute"
11507
+ },
11508
+ "default": "\"off\"",
11509
+ "description": "Specifies the data type of the field, so that the browser may attempt to fill out the field automatically on behalf of the user.",
11510
+ "fieldName": "autocomplete",
11511
+ "inheritedFrom": {
11512
+ "name": "AutocompleteMixin",
11513
+ "module": "src/common/mixins/AutocompleteMixin.ts"
11514
+ }
11515
+ },
11535
11516
  {
11536
11517
  "name": "disabled",
11537
11518
  "type": {
@@ -11550,51 +11531,272 @@
11550
11531
  "type": {
11551
11532
  "text": "string | undefined"
11552
11533
  },
11553
- "description": "The name of the form component.",
11554
- "fieldName": "name",
11555
- "inheritedFrom": {
11556
- "name": "InputMixin",
11557
- "module": "src/common/mixins/InputMixin.ts"
11558
- }
11534
+ "description": "The name of the form component.",
11535
+ "fieldName": "name",
11536
+ "inheritedFrom": {
11537
+ "name": "InputMixin",
11538
+ "module": "src/common/mixins/InputMixin.ts"
11539
+ }
11540
+ },
11541
+ {
11542
+ "name": "value",
11543
+ "type": {
11544
+ "text": "string"
11545
+ },
11546
+ "default": "\"\"",
11547
+ "description": "The value of the form component.",
11548
+ "fieldName": "value",
11549
+ "inheritedFrom": {
11550
+ "name": "InputMixin",
11551
+ "module": "src/common/mixins/InputMixin.ts"
11552
+ }
11553
+ },
11554
+ {
11555
+ "name": "form",
11556
+ "type": {
11557
+ "text": "HTMLFormElement | null"
11558
+ },
11559
+ "description": "Gets the form, if any, associated with the form element.\nThe setter accepts a string, which is the id of the form.",
11560
+ "fieldName": "form",
11561
+ "inheritedFrom": {
11562
+ "name": "InputMixin",
11563
+ "module": "src/common/mixins/InputMixin.ts"
11564
+ }
11565
+ }
11566
+ ],
11567
+ "mixins": [
11568
+ {
11569
+ "name": "SizeMixin",
11570
+ "module": "/src/common/mixins/SizeMixin.js"
11571
+ },
11572
+ {
11573
+ "name": "FormAssociatedMixin",
11574
+ "module": "/src/common/mixins/FormAssociatedMixin.js"
11575
+ },
11576
+ {
11577
+ "name": "AutocompleteMixin",
11578
+ "module": "/src/common/mixins/AutocompleteMixin.js"
11579
+ },
11580
+ {
11581
+ "name": "InputMixin",
11582
+ "module": "/src/common/mixins/InputMixin.js"
11583
+ },
11584
+ {
11585
+ "name": "FocusableMixin",
11586
+ "module": "/src/common/mixins/FocusableMixin.js"
11587
+ }
11588
+ ],
11589
+ "superclass": {
11590
+ "name": "LitElement",
11591
+ "package": "lit"
11592
+ },
11593
+ "localization": [],
11594
+ "status": "ready",
11595
+ "category": "form",
11596
+ "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use to let a user choose one option from an options menu.\n- Use when you have more than 6 options to choose from.\n- Use when you don’t know how many options there will be.\n- Use hint text and placeholder to provide additional, non-critical instructions.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don't use a select if you have less than 6 options to choose from. Consider using radio components instead, if you have enough space to allow it. \n\n</div>\n\n---\n\n## Content guidelines\n\nSelect labels act as a title for the select field. Labels should typically be short and in noun&nbsp;form:\n\n<div class=\"n-usage n-usage-do\">Company name</div>\n<div class=\"n-usage n-usage-dont\">What is your company name?</div>\n\nWhen writing select labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">Company name</div>\n<div class=\"n-usage n-usage-dont\">Company Name</div>\n\nDo not use colons in select labels:\n\n<div class=\"n-usage n-usage-do\">Choose organization</div>\n<div class=\"n-usage n-usage-dont\">Choose organization:</div>\n",
11597
+ "examples": [],
11598
+ "dependencies": [
11599
+ "button",
11600
+ "icon"
11601
+ ],
11602
+ "tagName": "nord-select",
11603
+ "customElement": true,
11604
+ "events": [
11605
+ {
11606
+ "name": "input",
11607
+ "type": {
11608
+ "text": "NordEvent"
11609
+ },
11610
+ "description": "Fired as the user types into the input.",
11611
+ "inheritedFrom": {
11612
+ "name": "FormAssociatedMixin",
11613
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
11614
+ }
11615
+ },
11616
+ {
11617
+ "name": "change",
11618
+ "type": {
11619
+ "text": "NordEvent"
11620
+ },
11621
+ "description": "Fired whenever the input's value is changed via user interaction.",
11622
+ "inheritedFrom": {
11623
+ "name": "FormAssociatedMixin",
11624
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
11625
+ }
11626
+ }
11627
+ ]
11628
+ }
11629
+ ],
11630
+ "exports": [
11631
+ {
11632
+ "kind": "js",
11633
+ "name": "default",
11634
+ "declaration": {
11635
+ "name": "Select",
11636
+ "module": "src/select/Select.ts"
11637
+ }
11638
+ },
11639
+ {
11640
+ "kind": "custom-element-definition",
11641
+ "name": "nord-select",
11642
+ "declaration": {
11643
+ "name": "Select",
11644
+ "module": "src/select/Select.ts"
11645
+ }
11646
+ }
11647
+ ]
11648
+ },
11649
+ {
11650
+ "kind": "javascript-module",
11651
+ "path": "src/qrcode/Qrcode.ts",
11652
+ "declarations": [
11653
+ {
11654
+ "kind": "class",
11655
+ "description": "QR Code component is used for providing information or links\nto users which they can quickly scan with their smartphone.",
11656
+ "name": "Qrcode",
11657
+ "members": [
11658
+ {
11659
+ "kind": "field",
11660
+ "name": "canvas",
11661
+ "type": {
11662
+ "text": "HTMLElement"
11663
+ },
11664
+ "privacy": "private"
11665
+ },
11666
+ {
11667
+ "kind": "field",
11668
+ "name": "computed",
11669
+ "type": {
11670
+ "text": "HTMLElement"
11671
+ },
11672
+ "privacy": "private"
11673
+ },
11674
+ {
11675
+ "kind": "field",
11676
+ "name": "value",
11677
+ "type": {
11678
+ "text": "string"
11679
+ },
11680
+ "default": "\"\"",
11681
+ "description": "The value of the QR Code, most commonly an URL.",
11682
+ "attribute": "value",
11683
+ "reflects": true
11684
+ },
11685
+ {
11686
+ "kind": "field",
11687
+ "name": "label",
11688
+ "type": {
11689
+ "text": "string"
11690
+ },
11691
+ "default": "\"\"",
11692
+ "description": "Label used by assistive technology. If unspecified, the value will\nbe used instead.",
11693
+ "attribute": "label",
11694
+ "reflects": true
11695
+ },
11696
+ {
11697
+ "kind": "field",
11698
+ "name": "size",
11699
+ "type": {
11700
+ "text": "number"
11701
+ },
11702
+ "default": "128",
11703
+ "description": "The size of the rendered QR Code in pixels.",
11704
+ "attribute": "size",
11705
+ "reflects": true
11706
+ },
11707
+ {
11708
+ "kind": "field",
11709
+ "name": "color",
11710
+ "type": {
11711
+ "text": "string"
11712
+ },
11713
+ "default": "\"var(--n-color-text)\"",
11714
+ "description": "The fill color of the QR Code.\nCan accept any valid CSS color value, including custom properties.",
11715
+ "attribute": "color",
11716
+ "reflects": true
11717
+ },
11718
+ {
11719
+ "kind": "field",
11720
+ "name": "background",
11721
+ "type": {
11722
+ "text": "string"
11723
+ },
11724
+ "default": "\"var(--n-color-surface)\"",
11725
+ "description": "The background color of the QR Code.\nCan accept any valid CSS color value, including custom properties.",
11726
+ "attribute": "background",
11727
+ "reflects": true
11728
+ },
11729
+ {
11730
+ "kind": "field",
11731
+ "name": "correction",
11732
+ "type": {
11733
+ "text": "\"L\" | \"M\" | \"Q\" | \"H\""
11734
+ },
11735
+ "default": "\"H\"",
11736
+ "description": "Error correction level makes the QR Code bigger and helps users to\nscan it without issues. L, M, Q and H values will use 7%, 15%, 25%\nand 30% of the QR code for error correction respectively.",
11737
+ "attribute": "correction",
11738
+ "reflects": true
11739
+ },
11740
+ {
11741
+ "kind": "method",
11742
+ "name": "generate",
11743
+ "privacy": "private"
11744
+ }
11745
+ ],
11746
+ "attributes": [
11747
+ {
11748
+ "name": "value",
11749
+ "type": {
11750
+ "text": "string"
11751
+ },
11752
+ "default": "\"\"",
11753
+ "description": "The value of the QR Code, most commonly an URL.",
11754
+ "fieldName": "value"
11559
11755
  },
11560
11756
  {
11561
- "name": "value",
11757
+ "name": "label",
11562
11758
  "type": {
11563
11759
  "text": "string"
11564
11760
  },
11565
11761
  "default": "\"\"",
11566
- "description": "The value of the form component.",
11567
- "fieldName": "value",
11568
- "inheritedFrom": {
11569
- "name": "InputMixin",
11570
- "module": "src/common/mixins/InputMixin.ts"
11571
- }
11762
+ "description": "Label used by assistive technology. If unspecified, the value will\nbe used instead.",
11763
+ "fieldName": "label"
11572
11764
  },
11573
11765
  {
11574
- "name": "form",
11766
+ "name": "size",
11575
11767
  "type": {
11576
- "text": "HTMLFormElement | null"
11768
+ "text": "number"
11577
11769
  },
11578
- "description": "Gets the form, if any, associated with the form element.\nThe setter accepts a string, which is the id of the form.",
11579
- "fieldName": "form",
11580
- "inheritedFrom": {
11581
- "name": "InputMixin",
11582
- "module": "src/common/mixins/InputMixin.ts"
11583
- }
11584
- }
11585
- ],
11586
- "mixins": [
11770
+ "default": "128",
11771
+ "description": "The size of the rendered QR Code in pixels.",
11772
+ "fieldName": "size"
11773
+ },
11587
11774
  {
11588
- "name": "FormAssociatedMixin",
11589
- "module": "/src/common/mixins/FormAssociatedMixin.js"
11775
+ "name": "color",
11776
+ "type": {
11777
+ "text": "string"
11778
+ },
11779
+ "default": "\"var(--n-color-text)\"",
11780
+ "description": "The fill color of the QR Code.\nCan accept any valid CSS color value, including custom properties.",
11781
+ "fieldName": "color"
11590
11782
  },
11591
11783
  {
11592
- "name": "InputMixin",
11593
- "module": "/src/common/mixins/InputMixin.js"
11784
+ "name": "background",
11785
+ "type": {
11786
+ "text": "string"
11787
+ },
11788
+ "default": "\"var(--n-color-surface)\"",
11789
+ "description": "The background color of the QR Code.\nCan accept any valid CSS color value, including custom properties.",
11790
+ "fieldName": "background"
11594
11791
  },
11595
11792
  {
11596
- "name": "FocusableMixin",
11597
- "module": "/src/common/mixins/FocusableMixin.js"
11793
+ "name": "correction",
11794
+ "type": {
11795
+ "text": "\"L\" | \"M\" | \"Q\" | \"H\""
11796
+ },
11797
+ "default": "\"H\"",
11798
+ "description": "Error correction level makes the QR Code bigger and helps users to\nscan it without issues. L, M, Q and H values will use 7%, 15%, 25%\nand 30% of the QR code for error correction respectively.",
11799
+ "fieldName": "correction"
11598
11800
  }
11599
11801
  ],
11600
11802
  "superclass": {
@@ -11603,36 +11805,13 @@
11603
11805
  },
11604
11806
  "localization": [],
11605
11807
  "status": "ready",
11606
- "category": "form",
11607
- "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use a radio component when users can only select one option from a list.\n- Favour radios over a select component when there are a small number of options. This reduces the number of clicks a user has to make, increasing efficiency.\n- Radio buttons are grouped by their `name` attribute. Therefore, it is crucial that the same `name` is used for a group of radios.\n- Give each radio within a group a unique `value`.\n- Radios **must** be used in combination with a fieldset component.\n- In most cases, a stack component should be used to layout a group of radio buttons.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t place interactive content (buttons, links etc) inside the label.\n- Don’t use when a user can select more than one option. In this case, use a checkbox instead.\n- Don’t use for “accepting terms of service” and similar functionality. Use a checkbox instead.\n- When you have more than 10 options to choose from. Consider using a select instead.\n\n</div>\n\n---\n\n## Content guidelines\n\nRadio button labels should be clear, accurate and predictable. It should be possible for the user to understand what they are enabling or disabling:\n\n<div class=\"n-usage n-usage-do\">User settings</div>\n<div class=\"n-usage n-usage-dont\">Option 1</div>\n\nWhen writing radio button labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">My tasks</div>\n<div class=\"n-usage n-usage-dont\">My Tasks</div>\n\nAvoid ending in punctuation if it’s a single sentence, word, or a fragment:\n\n<div class=\"n-usage n-usage-do\">Blue</div>\n<div class=\"n-usage n-usage-dont\">Blue.</div>\n\nDo not use commas or semicolons at the end of each line\n\n<div class=\"n-usage n-usage-do\">Patient</div>\n<div class=\"n-usage n-usage-dont\">Patient;</div>\n\n---\n\n## Additional considerations\n\n- Hint text can be used to offer further information or explanation for an option.\n- Once a radio has been selected, users cannot return to having no radios selected without refreshing their browser window. Therefore, you should include \"None of the above\" or \"I do not know\" if they are valid options.\n- In most cases, radio buttons should be stacked vertically. However, radio buttons can be stacked horizontally when there are only two options with short labels. An example might be a yes/no question.\n",
11808
+ "category": "image",
11809
+ "displayName": "QR Code",
11810
+ "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use to allow people to access information on their smartphone without the need to type.\n- Always provide an alternative way to access the same information.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t hide important information behind a QR Code only.\n\n</div>\n",
11608
11811
  "examples": [],
11609
11812
  "dependencies": [],
11610
- "tagName": "nord-radio",
11611
- "customElement": true,
11612
- "events": [
11613
- {
11614
- "name": "input",
11615
- "type": {
11616
- "text": "NordEvent"
11617
- },
11618
- "description": "Fired as the user types into the input.",
11619
- "inheritedFrom": {
11620
- "name": "FormAssociatedMixin",
11621
- "module": "src/common/mixins/FormAssociatedMixin.ts"
11622
- }
11623
- },
11624
- {
11625
- "name": "change",
11626
- "type": {
11627
- "text": "NordEvent"
11628
- },
11629
- "description": "Fired whenever the input's value is changed via user interaction.",
11630
- "inheritedFrom": {
11631
- "name": "FormAssociatedMixin",
11632
- "module": "src/common/mixins/FormAssociatedMixin.ts"
11633
- }
11634
- }
11635
- ]
11813
+ "tagName": "nord-qrcode",
11814
+ "customElement": true
11636
11815
  }
11637
11816
  ],
11638
11817
  "exports": [
@@ -11640,16 +11819,16 @@
11640
11819
  "kind": "js",
11641
11820
  "name": "default",
11642
11821
  "declaration": {
11643
- "name": "Radio",
11644
- "module": "src/radio/Radio.ts"
11822
+ "name": "Qrcode",
11823
+ "module": "src/qrcode/Qrcode.ts"
11645
11824
  }
11646
11825
  },
11647
11826
  {
11648
11827
  "kind": "custom-element-definition",
11649
- "name": "nord-radio",
11828
+ "name": "nord-qrcode",
11650
11829
  "declaration": {
11651
- "name": "Radio",
11652
- "module": "src/radio/Radio.ts"
11830
+ "name": "Qrcode",
11831
+ "module": "src/qrcode/Qrcode.ts"
11653
11832
  }
11654
11833
  }
11655
11834
  ]
@@ -12468,47 +12647,35 @@
12468
12647
  },
12469
12648
  {
12470
12649
  "kind": "javascript-module",
12471
- "path": "src/select/Select.ts",
12650
+ "path": "src/radio/Radio.ts",
12472
12651
  "declarations": [
12473
12652
  {
12474
12653
  "kind": "class",
12475
- "description": "Select lets users choose one option from an options menu.\nConsider using select when you have 5 or more options to choose from.",
12476
- "name": "Select",
12477
- "cssProperties": [
12478
- {
12479
- "description": "Controls the block size, or height, of the select using our [spacing tokens](/tokens/#space).",
12480
- "name": "--n-select-block-size",
12481
- "default": "var(--n-space-xl)"
12482
- }
12483
- ],
12654
+ "description": "Radio buttons are graphical user interface elements that allow user to choose only one option from\na predefined set of mutually exclusive options.",
12655
+ "name": "Radio",
12484
12656
  "slots": [
12485
- {
12486
- "description": "Default slot for holding <option> elements.",
12487
- "name": ""
12488
- },
12489
12657
  {
12490
12658
  "description": "Use when a label requires more than plain text.",
12491
12659
  "name": "label"
12492
12660
  },
12493
12661
  {
12494
- "description": "Use when a hint requires more than plain text.",
12662
+ "description": "Optional slot that holds hint text for the input.",
12495
12663
  "name": "hint"
12496
12664
  },
12497
12665
  {
12498
12666
  "description": "Optional slot that holds error text for the input.",
12499
12667
  "name": "error"
12500
- },
12501
- {
12502
- "description": "Used to place an icon at the start of select.",
12503
- "name": "icon"
12504
12668
  }
12505
12669
  ],
12506
12670
  "members": [
12507
12671
  {
12508
12672
  "kind": "field",
12509
- "name": "formValue",
12673
+ "name": "inputId",
12674
+ "type": {
12675
+ "text": "string"
12676
+ },
12510
12677
  "privacy": "protected",
12511
- "readonly": true,
12678
+ "default": "\"input\"",
12512
12679
  "inheritedFrom": {
12513
12680
  "name": "FormAssociatedMixin",
12514
12681
  "module": "src/common/mixins/FormAssociatedMixin.ts"
@@ -12516,18 +12683,12 @@
12516
12683
  },
12517
12684
  {
12518
12685
  "kind": "field",
12519
- "name": "defaultSlot",
12520
- "privacy": "private",
12521
- "default": "new SlotController(this)"
12522
- },
12523
- {
12524
- "kind": "field",
12525
- "name": "inputId",
12686
+ "name": "hintId",
12526
12687
  "type": {
12527
12688
  "text": "string"
12528
12689
  },
12529
12690
  "privacy": "protected",
12530
- "default": "\"select\"",
12691
+ "default": "\"hint\"",
12531
12692
  "inheritedFrom": {
12532
12693
  "name": "FormAssociatedMixin",
12533
12694
  "module": "src/common/mixins/FormAssociatedMixin.ts"
@@ -12535,92 +12696,110 @@
12535
12696
  },
12536
12697
  {
12537
12698
  "kind": "field",
12538
- "name": "expand",
12699
+ "name": "errorId",
12539
12700
  "type": {
12540
- "text": "boolean"
12701
+ "text": "string"
12541
12702
  },
12542
- "default": "false",
12543
- "description": "Controls whether the select expands to fill the width of its container.",
12544
- "attribute": "expand",
12545
- "reflects": true
12703
+ "privacy": "protected",
12704
+ "default": "\"error\"",
12705
+ "inheritedFrom": {
12706
+ "name": "FormAssociatedMixin",
12707
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
12708
+ }
12546
12709
  },
12547
12710
  {
12548
12711
  "kind": "field",
12549
- "name": "options",
12550
- "privacy": "private",
12551
- "readonly": true
12552
- },
12553
- {
12554
- "kind": "method",
12555
- "name": "getButtonText",
12556
- "privacy": "private",
12557
- "return": {
12558
- "type": {
12559
- "text": "string"
12560
- }
12561
- },
12562
- "parameters": [
12563
- {
12564
- "name": "options",
12565
- "type": {
12566
- "text": "HTMLOptionElement[]"
12567
- }
12568
- }
12569
- ]
12712
+ "name": "hintSlot",
12713
+ "privacy": "protected",
12714
+ "default": "new LightSlotController(this, {\n slotName: \"hint\",\n render: () => (this.hint ? html`<div slot=\"hint-internal\" id=${this.hintId}>${this.hint}</div>` : nothing),\n syncLightDom: element => {\n element.id = this.hintId\n },\n })",
12715
+ "description": "For accessibility reasons, we render some parts of the component to the light DOM.",
12716
+ "inheritedFrom": {
12717
+ "name": "FormAssociatedMixin",
12718
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
12719
+ }
12570
12720
  },
12571
12721
  {
12572
- "kind": "method",
12573
- "name": "renderOption",
12574
- "privacy": "private",
12575
- "parameters": [
12576
- {
12577
- "name": "option",
12578
- "type": {
12579
- "text": "HTMLOptionElement"
12580
- }
12581
- }
12582
- ]
12722
+ "kind": "field",
12723
+ "name": "labelSlot",
12724
+ "privacy": "protected",
12725
+ "default": "new LightSlotController(this, {\n slotName: \"label\",\n render: () => (this.label ? html`<label slot=\"label-internal\" for=${this.inputId}>${this.label}</label>` : nothing),\n syncLightDom: element => {\n if (!isLabel(element)) {\n // eslint-disable-next-line no-console\n console.warn(`NORD: Only <label> elements should be placed in radio's \"label\" slot`)\n } else {\n element.htmlFor = this.inputId\n }\n },\n })",
12726
+ "inheritedFrom": {
12727
+ "name": "FormAssociatedMixin",
12728
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
12729
+ }
12583
12730
  },
12584
12731
  {
12585
12732
  "kind": "field",
12586
- "name": "size",
12587
- "type": {
12588
- "text": "\"s\" | \"m\" | \"l\""
12589
- },
12590
- "default": "\"m\"",
12591
- "description": "The size of the component.",
12592
- "attribute": "size",
12593
- "reflects": true,
12733
+ "name": "errorSlot",
12734
+ "privacy": "protected",
12735
+ "default": "new LightSlotController(this, {\n slotName: \"error\",\n render: () => (this.error ? html`<div slot=\"error-internal\" id=${this.errorId}>${this.error}</div>` : nothing),\n syncLightDom: element => {\n element.id = this.hintId\n },\n })",
12594
12736
  "inheritedFrom": {
12595
- "name": "SizeMixin",
12596
- "module": "src/common/mixins/SizeMixin.ts"
12737
+ "name": "FormAssociatedMixin",
12738
+ "module": "src/common/mixins/FormAssociatedMixin.ts"
12597
12739
  }
12598
12740
  },
12599
12741
  {
12600
12742
  "kind": "field",
12601
- "name": "labelSlot",
12743
+ "name": "inputSlot",
12602
12744
  "privacy": "protected",
12603
- "default": "new SlotController(this, \"label\")",
12745
+ "default": "new LightDomController(this, {\n render: () =>\n html`\n <input\n slot=\"input\"\n @blur=${this.handleBlur}\n @focus=${this.handleFocus}\n ${ref(this.focusableRef)}\n class=\"n-input\"\n id=${this.inputId}\n type=\"radio\"\n name=${cond(this.name)}\n .value=${cond(this.value)}\n .checked=${this.checked}\n ?disabled=${this.disabled}\n ?required=${this.required}\n aria-describedby=${cond(this.getDescribedBy())}\n aria-invalid=${cond(this.getInvalid())}\n form=${cond(this._formId)}\n />\n `,\n })"
12746
+ },
12747
+ {
12748
+ "kind": "field",
12749
+ "name": "formValue",
12750
+ "privacy": "protected",
12751
+ "readonly": true,
12604
12752
  "inheritedFrom": {
12605
12753
  "name": "FormAssociatedMixin",
12606
12754
  "module": "src/common/mixins/FormAssociatedMixin.ts"
12607
12755
  }
12608
12756
  },
12609
12757
  {
12610
- "kind": "field",
12611
- "name": "errorSlot",
12612
- "privacy": "protected",
12613
- "default": "new SlotController(this, \"error\")",
12614
- "inheritedFrom": {
12615
- "name": "FormAssociatedMixin",
12616
- "module": "src/common/mixins/FormAssociatedMixin.ts"
12617
- }
12758
+ "kind": "field",
12759
+ "name": "checked",
12760
+ "type": {
12761
+ "text": "boolean"
12762
+ },
12763
+ "default": "false",
12764
+ "description": "Controls whether the checkbox is checked or not.",
12765
+ "attribute": "checked",
12766
+ "reflects": true
12767
+ },
12768
+ {
12769
+ "kind": "method",
12770
+ "name": "handleCheckedChange",
12771
+ "privacy": "protected",
12772
+ "parameters": [
12773
+ {
12774
+ "name": "previousChecked",
12775
+ "type": {
12776
+ "text": "boolean"
12777
+ }
12778
+ }
12779
+ ]
12780
+ },
12781
+ {
12782
+ "kind": "method",
12783
+ "name": "uncheckSiblings",
12784
+ "privacy": "private"
12618
12785
  },
12619
12786
  {
12620
- "kind": "field",
12621
- "name": "hintSlot",
12787
+ "kind": "method",
12788
+ "name": "handleChange",
12622
12789
  "privacy": "protected",
12623
- "default": "new SlotController(this, \"hint\")",
12790
+ "parameters": [
12791
+ {
12792
+ "name": "e",
12793
+ "type": {
12794
+ "text": "Event"
12795
+ }
12796
+ }
12797
+ ],
12798
+ "return": {
12799
+ "type": {
12800
+ "text": "void"
12801
+ }
12802
+ },
12624
12803
  "inheritedFrom": {
12625
12804
  "name": "FormAssociatedMixin",
12626
12805
  "module": "src/common/mixins/FormAssociatedMixin.ts"
@@ -12628,35 +12807,19 @@
12628
12807
  },
12629
12808
  {
12630
12809
  "kind": "field",
12631
- "name": "formData",
12632
- "privacy": "protected",
12633
- "default": "new FormDataController(this, { value: () => this.formValue })",
12634
- "inheritedFrom": {
12635
- "name": "FormAssociatedMixin",
12636
- "module": "src/common/mixins/FormAssociatedMixin.ts"
12637
- }
12810
+ "name": "handleBlur",
12811
+ "privacy": "private"
12638
12812
  },
12639
12813
  {
12640
12814
  "kind": "field",
12641
- "name": "errorId",
12642
- "type": {
12643
- "text": "string"
12644
- },
12645
- "privacy": "protected",
12646
- "default": "\"error\"",
12647
- "inheritedFrom": {
12648
- "name": "FormAssociatedMixin",
12649
- "module": "src/common/mixins/FormAssociatedMixin.ts"
12650
- }
12815
+ "name": "handleFocus",
12816
+ "privacy": "private"
12651
12817
  },
12652
12818
  {
12653
12819
  "kind": "field",
12654
- "name": "hintId",
12655
- "type": {
12656
- "text": "string"
12657
- },
12820
+ "name": "formData",
12658
12821
  "privacy": "protected",
12659
- "default": "\"hint\"",
12822
+ "default": "new FormDataController(this, { value: () => this.formValue })",
12660
12823
  "inheritedFrom": {
12661
12824
  "name": "FormAssociatedMixin",
12662
12825
  "module": "src/common/mixins/FormAssociatedMixin.ts"
@@ -12774,23 +12937,6 @@
12774
12937
  "module": "src/common/mixins/FormAssociatedMixin.ts"
12775
12938
  }
12776
12939
  },
12777
- {
12778
- "kind": "method",
12779
- "name": "handleChange",
12780
- "privacy": "protected",
12781
- "parameters": [
12782
- {
12783
- "name": "e",
12784
- "type": {
12785
- "text": "Event"
12786
- }
12787
- }
12788
- ],
12789
- "inheritedFrom": {
12790
- "name": "FormAssociatedMixin",
12791
- "module": "src/common/mixins/FormAssociatedMixin.ts"
12792
- }
12793
- },
12794
12940
  {
12795
12941
  "kind": "method",
12796
12942
  "name": "renderLabel",
@@ -12856,20 +13002,6 @@
12856
13002
  "module": "src/common/mixins/FormAssociatedMixin.ts"
12857
13003
  }
12858
13004
  },
12859
- {
12860
- "kind": "field",
12861
- "name": "autocomplete",
12862
- "type": {
12863
- "text": "AutocompleteAttribute"
12864
- },
12865
- "default": "\"off\"",
12866
- "description": "Specifies the data type of the field, so that the browser may attempt to fill out the field automatically on behalf of the user.",
12867
- "attribute": "autocomplete",
12868
- "inheritedFrom": {
12869
- "name": "AutocompleteMixin",
12870
- "module": "src/common/mixins/AutocompleteMixin.ts"
12871
- }
12872
- },
12873
13005
  {
12874
13006
  "kind": "field",
12875
13007
  "name": "disabled",
@@ -12999,26 +13131,13 @@
12999
13131
  ],
13000
13132
  "attributes": [
13001
13133
  {
13002
- "name": "expand",
13134
+ "name": "checked",
13003
13135
  "type": {
13004
13136
  "text": "boolean"
13005
13137
  },
13006
13138
  "default": "false",
13007
- "description": "Controls whether the select expands to fill the width of its container.",
13008
- "fieldName": "expand"
13009
- },
13010
- {
13011
- "name": "size",
13012
- "type": {
13013
- "text": "\"s\" | \"m\" | \"l\""
13014
- },
13015
- "default": "\"m\"",
13016
- "description": "The size of the component.",
13017
- "fieldName": "size",
13018
- "inheritedFrom": {
13019
- "name": "SizeMixin",
13020
- "module": "src/common/mixins/SizeMixin.ts"
13021
- }
13139
+ "description": "Controls whether the checkbox is checked or not.",
13140
+ "fieldName": "checked"
13022
13141
  },
13023
13142
  {
13024
13143
  "name": "label",
@@ -13108,19 +13227,6 @@
13108
13227
  "module": "src/common/mixins/FormAssociatedMixin.ts"
13109
13228
  }
13110
13229
  },
13111
- {
13112
- "name": "autocomplete",
13113
- "type": {
13114
- "text": "AutocompleteAttribute"
13115
- },
13116
- "default": "\"off\"",
13117
- "description": "Specifies the data type of the field, so that the browser may attempt to fill out the field automatically on behalf of the user.",
13118
- "fieldName": "autocomplete",
13119
- "inheritedFrom": {
13120
- "name": "AutocompleteMixin",
13121
- "module": "src/common/mixins/AutocompleteMixin.ts"
13122
- }
13123
- },
13124
13230
  {
13125
13231
  "name": "disabled",
13126
13232
  "type": {
@@ -13173,18 +13279,10 @@
13173
13279
  }
13174
13280
  ],
13175
13281
  "mixins": [
13176
- {
13177
- "name": "SizeMixin",
13178
- "module": "/src/common/mixins/SizeMixin.js"
13179
- },
13180
13282
  {
13181
13283
  "name": "FormAssociatedMixin",
13182
13284
  "module": "/src/common/mixins/FormAssociatedMixin.js"
13183
13285
  },
13184
- {
13185
- "name": "AutocompleteMixin",
13186
- "module": "/src/common/mixins/AutocompleteMixin.js"
13187
- },
13188
13286
  {
13189
13287
  "name": "InputMixin",
13190
13288
  "module": "/src/common/mixins/InputMixin.js"
@@ -13201,13 +13299,10 @@
13201
13299
  "localization": [],
13202
13300
  "status": "ready",
13203
13301
  "category": "form",
13204
- "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use to let a user choose one option from an options menu.\n- Use when you have more than 6 options to choose from.\n- Use when you don’t know how many options there will be.\n- Use hint text and placeholder to provide additional, non-critical instructions.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don't use a select if you have less than 6 options to choose from. Consider using radio components instead, if you have enough space to allow it. \n\n</div>\n\n---\n\n## Content guidelines\n\nSelect labels act as a title for the select field. Labels should typically be short and in noun&nbsp;form:\n\n<div class=\"n-usage n-usage-do\">Company name</div>\n<div class=\"n-usage n-usage-dont\">What is your company name?</div>\n\nWhen writing select labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">Company name</div>\n<div class=\"n-usage n-usage-dont\">Company Name</div>\n\nDo not use colons in select labels:\n\n<div class=\"n-usage n-usage-do\">Choose organization</div>\n<div class=\"n-usage n-usage-dont\">Choose organization:</div>\n",
13302
+ "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use a radio component when users can only select one option from a list.\n- Favour radios over a select component when there are a small number of options. This reduces the number of clicks a user has to make, increasing efficiency.\n- Radio buttons are grouped by their `name` attribute. Therefore, it is crucial that the same `name` is used for a group of radios.\n- Give each radio within a group a unique `value`.\n- Radios **must** be used in combination with a fieldset component.\n- In most cases, a stack component should be used to layout a group of radio buttons.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Dont place interactive content (buttons, links etc) inside the label.\n- Don’t use when a user can select more than one option. In this case, use a checkbox instead.\n- Don’t use for “accepting terms of service” and similar functionality. Use a checkbox instead.\n- When you have more than 10 options to choose from. Consider using a select instead.\n\n</div>\n\n---\n\n## Content guidelines\n\nRadio button labels should be clear, accurate and predictable. It should be possible for the user to understand what they are enabling or disabling:\n\n<div class=\"n-usage n-usage-do\">User settings</div>\n<div class=\"n-usage n-usage-dont\">Option 1</div>\n\nWhen writing radio button labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">My tasks</div>\n<div class=\"n-usage n-usage-dont\">My Tasks</div>\n\nAvoid ending in punctuation if it’s a single sentence, word, or a fragment:\n\n<div class=\"n-usage n-usage-do\">Blue</div>\n<div class=\"n-usage n-usage-dont\">Blue.</div>\n\nDo not use commas or semicolons at the end of each line\n\n<div class=\"n-usage n-usage-do\">Patient</div>\n<div class=\"n-usage n-usage-dont\">Patient;</div>\n\n---\n\n## Additional considerations\n\n- Hint text can be used to offer further information or explanation for an option.\n- Once a radio has been selected, users cannot return to having no radios selected without refreshing their browser window. Therefore, you should include \"None of the above\" or \"I do not know\" if they are valid options.\n- In most cases, radio buttons should be stacked vertically. However, radio buttons can be stacked horizontally when there are only two options with short labels. An example might be a yes/no question.\n",
13205
13303
  "examples": [],
13206
- "dependencies": [
13207
- "button",
13208
- "icon"
13209
- ],
13210
- "tagName": "nord-select",
13304
+ "dependencies": [],
13305
+ "tagName": "nord-radio",
13211
13306
  "customElement": true,
13212
13307
  "events": [
13213
13308
  {
@@ -13240,16 +13335,16 @@
13240
13335
  "kind": "js",
13241
13336
  "name": "default",
13242
13337
  "declaration": {
13243
- "name": "Select",
13244
- "module": "src/select/Select.ts"
13338
+ "name": "Radio",
13339
+ "module": "src/radio/Radio.ts"
13245
13340
  }
13246
13341
  },
13247
13342
  {
13248
13343
  "kind": "custom-element-definition",
13249
- "name": "nord-select",
13344
+ "name": "nord-radio",
13250
13345
  "declaration": {
13251
- "name": "Select",
13252
- "module": "src/select/Select.ts"
13346
+ "name": "Radio",
13347
+ "module": "src/radio/Radio.ts"
13253
13348
  }
13254
13349
  }
13255
13350
  ]
@@ -13344,69 +13439,164 @@
13344
13439
  "name": "Spinner",
13345
13440
  "cssProperties": [
13346
13441
  {
13347
- "description": "Controls the color the spinner.",
13348
- "name": "--n-spinner-color",
13349
- "default": "var(--n-color-accent)"
13442
+ "description": "Controls the color the spinner.",
13443
+ "name": "--n-spinner-color",
13444
+ "default": "var(--n-color-accent)"
13445
+ }
13446
+ ],
13447
+ "members": [
13448
+ {
13449
+ "kind": "field",
13450
+ "name": "size",
13451
+ "type": {
13452
+ "text": "\"xs\" | \"s\" | \"m\" | \"l\" | \"xl\" | \"xxl\""
13453
+ },
13454
+ "default": "\"m\"",
13455
+ "description": "The size of the spinner.",
13456
+ "attribute": "size",
13457
+ "reflects": true
13458
+ },
13459
+ {
13460
+ "kind": "field",
13461
+ "name": "color",
13462
+ "type": {
13463
+ "text": "string | undefined"
13464
+ },
13465
+ "description": "The color of the spinner.\nCan accept any valid CSS color value, including custom properties.\nTakes precedence over the `--n-spinner-color` CSS custom property.",
13466
+ "attribute": "color",
13467
+ "reflects": true
13468
+ },
13469
+ {
13470
+ "kind": "field",
13471
+ "name": "label",
13472
+ "type": {
13473
+ "text": "string | undefined"
13474
+ },
13475
+ "description": "An accessible label for the spinner.\nIf no label is supplied, the spinner is hidden from assistive technology.",
13476
+ "attribute": "label",
13477
+ "reflects": true
13478
+ }
13479
+ ],
13480
+ "attributes": [
13481
+ {
13482
+ "name": "size",
13483
+ "type": {
13484
+ "text": "\"xs\" | \"s\" | \"m\" | \"l\" | \"xl\" | \"xxl\""
13485
+ },
13486
+ "default": "\"m\"",
13487
+ "description": "The size of the spinner.",
13488
+ "fieldName": "size"
13489
+ },
13490
+ {
13491
+ "name": "color",
13492
+ "type": {
13493
+ "text": "string | undefined"
13494
+ },
13495
+ "description": "The color of the spinner.\nCan accept any valid CSS color value, including custom properties.\nTakes precedence over the `--n-spinner-color` CSS custom property.",
13496
+ "fieldName": "color"
13497
+ },
13498
+ {
13499
+ "name": "label",
13500
+ "type": {
13501
+ "text": "string | undefined"
13502
+ },
13503
+ "description": "An accessible label for the spinner.\nIf no label is supplied, the spinner is hidden from assistive technology.",
13504
+ "fieldName": "label"
13505
+ }
13506
+ ],
13507
+ "superclass": {
13508
+ "name": "LitElement",
13509
+ "package": "lit"
13510
+ },
13511
+ "localization": [],
13512
+ "status": "ready",
13513
+ "category": "feedback",
13514
+ "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use for indicating users that their action is being processed.\n- Use the label property to provide an accessible label for the spinner. If no label is supplied, the spinner is hidden from assistive technology.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use to show progress. Favor a progress bar instead.\n\n</div>\n",
13515
+ "examples": [],
13516
+ "dependencies": [],
13517
+ "tagName": "nord-spinner",
13518
+ "customElement": true
13519
+ }
13520
+ ],
13521
+ "exports": [
13522
+ {
13523
+ "kind": "js",
13524
+ "name": "default",
13525
+ "declaration": {
13526
+ "name": "Spinner",
13527
+ "module": "src/spinner/Spinner.ts"
13528
+ }
13529
+ },
13530
+ {
13531
+ "kind": "custom-element-definition",
13532
+ "name": "nord-spinner",
13533
+ "declaration": {
13534
+ "name": "Spinner",
13535
+ "module": "src/spinner/Spinner.ts"
13536
+ }
13537
+ }
13538
+ ]
13539
+ },
13540
+ {
13541
+ "kind": "javascript-module",
13542
+ "path": "src/tab/Tab.ts",
13543
+ "declarations": [
13544
+ {
13545
+ "kind": "class",
13546
+ "description": "The interactive tab button for use within the tab group component.",
13547
+ "name": "Tab",
13548
+ "cssProperties": [
13549
+ {
13550
+ "description": "Controls the text color of the tab, using our [color tokens](/tokens/#color).",
13551
+ "name": "--n-tab-color",
13552
+ "default": "var(--n-color-text-weak)"
13553
+ },
13554
+ {
13555
+ "description": "Controls the font weight of the tab, using our [font tokens](/tokens/#font).",
13556
+ "name": "--n-tab-font-weight",
13557
+ "default": "var(--n-font-weight)"
13558
+ }
13559
+ ],
13560
+ "slots": [
13561
+ {
13562
+ "description": "The tab button content.",
13563
+ "name": ""
13350
13564
  }
13351
13565
  ],
13352
13566
  "members": [
13353
13567
  {
13354
13568
  "kind": "field",
13355
- "name": "size",
13356
- "type": {
13357
- "text": "\"xs\" | \"s\" | \"m\" | \"l\" | \"xl\" | \"xxl\""
13358
- },
13359
- "default": "\"m\"",
13360
- "description": "The size of the spinner.",
13361
- "attribute": "size",
13362
- "reflects": true
13569
+ "name": "defaultSlot",
13570
+ "privacy": "private",
13571
+ "default": "new SlotController(this)"
13363
13572
  },
13364
13573
  {
13365
13574
  "kind": "field",
13366
- "name": "color",
13575
+ "name": "selected",
13367
13576
  "type": {
13368
- "text": "string | undefined"
13577
+ "text": "boolean"
13369
13578
  },
13370
- "description": "The color of the spinner.\nCan accept any valid CSS color value, including custom properties.\nTakes precedence over the `--n-spinner-color` CSS custom property.",
13371
- "attribute": "color",
13579
+ "default": "false",
13580
+ "description": "Whether the tab item is selected",
13581
+ "attribute": "selected",
13372
13582
  "reflects": true
13373
13583
  },
13374
13584
  {
13375
- "kind": "field",
13376
- "name": "label",
13377
- "type": {
13378
- "text": "string | undefined"
13379
- },
13380
- "description": "An accessible label for the spinner.\nIf no label is supplied, the spinner is hidden from assistive technology.",
13381
- "attribute": "label",
13382
- "reflects": true
13585
+ "kind": "method",
13586
+ "name": "handleSelectionChange",
13587
+ "privacy": "protected",
13588
+ "description": "Apply accessible attributes and values to the tab button.\nObserve the selected property if it changes"
13383
13589
  }
13384
13590
  ],
13385
13591
  "attributes": [
13386
13592
  {
13387
- "name": "size",
13388
- "type": {
13389
- "text": "\"xs\" | \"s\" | \"m\" | \"l\" | \"xl\" | \"xxl\""
13390
- },
13391
- "default": "\"m\"",
13392
- "description": "The size of the spinner.",
13393
- "fieldName": "size"
13394
- },
13395
- {
13396
- "name": "color",
13397
- "type": {
13398
- "text": "string | undefined"
13399
- },
13400
- "description": "The color of the spinner.\nCan accept any valid CSS color value, including custom properties.\nTakes precedence over the `--n-spinner-color` CSS custom property.",
13401
- "fieldName": "color"
13402
- },
13403
- {
13404
- "name": "label",
13593
+ "name": "selected",
13405
13594
  "type": {
13406
- "text": "string | undefined"
13595
+ "text": "boolean"
13407
13596
  },
13408
- "description": "An accessible label for the spinner.\nIf no label is supplied, the spinner is hidden from assistive technology.",
13409
- "fieldName": "label"
13597
+ "default": "false",
13598
+ "description": "Whether the tab item is selected",
13599
+ "fieldName": "selected"
13410
13600
  }
13411
13601
  ],
13412
13602
  "superclass": {
@@ -13415,11 +13605,11 @@
13415
13605
  },
13416
13606
  "localization": [],
13417
13607
  "status": "ready",
13418
- "category": "feedback",
13419
- "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use for indicating users that their action is being processed.\n- Use the label property to provide an accessible label for the spinner. If no label is supplied, the spinner is hidden from assistive technology.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use to show progress. Favor a progress bar instead.\n\n</div>\n",
13608
+ "category": "navigation",
13609
+ "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use the tab component within the tab group component.\n- Use the `selected` option to signify if the tab is selected.\n- Use text, icons and other non-interactive content within the tab.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use tabs to navigate to other pages. Use navigation or links instead.\n- Don't use the tab component outside of the tab group component.\n- Don't add interactive elements, such as buttons and links, inside the tab component.\n\n</div>\n\n---\n\n## Content guidelines\n\nWhen writing tab labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">My tasks</div>\n<div class=\"n-usage n-usage-dont\">My Tasks</div>\n\nAvoid unnecessary words and articles in tab labels, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Dashboard</div>\n<div class=\"n-usage n-usage-dont\">The dashboard</div>\n\nAvoid ending tab labels in punctuation:\n\n<div class=\"n-usage n-usage-do\">Patients</div>\n<div class=\"n-usage n-usage-dont\">Patients.</div>\n\nUse as few words as possible to describe each tab label:\n\n<div class=\"n-usage n-usage-do\">Payments</div>\n<div class=\"n-usage n-usage-dont\">Payments in your clinic</div>\n\nAvoid all caps for tab labels:\n\n<div class=\"n-usage n-usage-do\">Dashboard</div>\n<div class=\"n-usage n-usage-dont\">DASHBOARD</div>\n\n---\n\n## Additional considerations\n\n- If the content contained within the tabs UI has significance or is important for the user to see, consider using a different form of presentation that doesn't obscure it.\n- If there is a particular section you wish to show out of order of the tabs UI itself consider using the `selected` option to select the tab but prevent the order of the tabs being affected.\n",
13420
13610
  "examples": [],
13421
13611
  "dependencies": [],
13422
- "tagName": "nord-spinner",
13612
+ "tagName": "nord-tab",
13423
13613
  "customElement": true
13424
13614
  }
13425
13615
  ],
@@ -13428,16 +13618,16 @@
13428
13618
  "kind": "js",
13429
13619
  "name": "default",
13430
13620
  "declaration": {
13431
- "name": "Spinner",
13432
- "module": "src/spinner/Spinner.ts"
13621
+ "name": "Tab",
13622
+ "module": "src/tab/Tab.ts"
13433
13623
  }
13434
13624
  },
13435
13625
  {
13436
13626
  "kind": "custom-element-definition",
13437
- "name": "nord-spinner",
13627
+ "name": "nord-tab",
13438
13628
  "declaration": {
13439
- "name": "Spinner",
13440
- "module": "src/spinner/Spinner.ts"
13629
+ "name": "Tab",
13630
+ "module": "src/tab/Tab.ts"
13441
13631
  }
13442
13632
  }
13443
13633
  ]
@@ -13598,101 +13788,6 @@
13598
13788
  }
13599
13789
  ]
13600
13790
  },
13601
- {
13602
- "kind": "javascript-module",
13603
- "path": "src/tab/Tab.ts",
13604
- "declarations": [
13605
- {
13606
- "kind": "class",
13607
- "description": "The interactive tab button for use within the tab group component.",
13608
- "name": "Tab",
13609
- "cssProperties": [
13610
- {
13611
- "description": "Controls the text color of the tab, using our [color tokens](/tokens/#color).",
13612
- "name": "--n-tab-color",
13613
- "default": "var(--n-color-text-weak)"
13614
- },
13615
- {
13616
- "description": "Controls the font weight of the tab, using our [font tokens](/tokens/#font).",
13617
- "name": "--n-tab-font-weight",
13618
- "default": "var(--n-font-weight)"
13619
- }
13620
- ],
13621
- "slots": [
13622
- {
13623
- "description": "The tab button content.",
13624
- "name": ""
13625
- }
13626
- ],
13627
- "members": [
13628
- {
13629
- "kind": "field",
13630
- "name": "defaultSlot",
13631
- "privacy": "private",
13632
- "default": "new SlotController(this)"
13633
- },
13634
- {
13635
- "kind": "field",
13636
- "name": "selected",
13637
- "type": {
13638
- "text": "boolean"
13639
- },
13640
- "default": "false",
13641
- "description": "Whether the tab item is selected",
13642
- "attribute": "selected",
13643
- "reflects": true
13644
- },
13645
- {
13646
- "kind": "method",
13647
- "name": "handleSelectionChange",
13648
- "privacy": "protected",
13649
- "description": "Apply accessible attributes and values to the tab button.\nObserve the selected property if it changes"
13650
- }
13651
- ],
13652
- "attributes": [
13653
- {
13654
- "name": "selected",
13655
- "type": {
13656
- "text": "boolean"
13657
- },
13658
- "default": "false",
13659
- "description": "Whether the tab item is selected",
13660
- "fieldName": "selected"
13661
- }
13662
- ],
13663
- "superclass": {
13664
- "name": "LitElement",
13665
- "package": "lit"
13666
- },
13667
- "localization": [],
13668
- "status": "ready",
13669
- "category": "navigation",
13670
- "readme": "## Usage\n\nThis section includes guidelines for designers and developers about the usage of this component in different contexts.\n\n<div class=\"n-usage n-usage-do\">\n\n### Do\n\n- Use the tab component within the tab group component.\n- Use the `selected` option to signify if the tab is selected.\n- Use text, icons and other non-interactive content within the tab.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use tabs to navigate to other pages. Use navigation or links instead.\n- Don't use the tab component outside of the tab group component.\n- Don't add interactive elements, such as buttons and links, inside the tab component.\n\n</div>\n\n---\n\n## Content guidelines\n\nWhen writing tab labels, always write them in sentence case, not title case. The first word should be capitalized and the rest lowercase (unless a proper noun):\n\n<div class=\"n-usage n-usage-do\">My tasks</div>\n<div class=\"n-usage n-usage-dont\">My Tasks</div>\n\nAvoid unnecessary words and articles in tab labels, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Dashboard</div>\n<div class=\"n-usage n-usage-dont\">The dashboard</div>\n\nAvoid ending tab labels in punctuation:\n\n<div class=\"n-usage n-usage-do\">Patients</div>\n<div class=\"n-usage n-usage-dont\">Patients.</div>\n\nUse as few words as possible to describe each tab label:\n\n<div class=\"n-usage n-usage-do\">Payments</div>\n<div class=\"n-usage n-usage-dont\">Payments in your clinic</div>\n\nAvoid all caps for tab labels:\n\n<div class=\"n-usage n-usage-do\">Dashboard</div>\n<div class=\"n-usage n-usage-dont\">DASHBOARD</div>\n\n---\n\n## Additional considerations\n\n- If the content contained within the tabs UI has significance or is important for the user to see, consider using a different form of presentation that doesn't obscure it.\n- If there is a particular section you wish to show out of order of the tabs UI itself consider using the `selected` option to select the tab but prevent the order of the tabs being affected.\n",
13671
- "examples": [],
13672
- "dependencies": [],
13673
- "tagName": "nord-tab",
13674
- "customElement": true
13675
- }
13676
- ],
13677
- "exports": [
13678
- {
13679
- "kind": "js",
13680
- "name": "default",
13681
- "declaration": {
13682
- "name": "Tab",
13683
- "module": "src/tab/Tab.ts"
13684
- }
13685
- },
13686
- {
13687
- "kind": "custom-element-definition",
13688
- "name": "nord-tab",
13689
- "declaration": {
13690
- "name": "Tab",
13691
- "module": "src/tab/Tab.ts"
13692
- }
13693
- }
13694
- ]
13695
- },
13696
13791
  {
13697
13792
  "kind": "javascript-module",
13698
13793
  "path": "src/tab-group/TabGroup.ts",
@@ -16346,6 +16441,41 @@
16346
16441
  }
16347
16442
  ]
16348
16443
  },
16444
+ {
16445
+ "kind": "javascript-module",
16446
+ "path": "src/common/decorators/observe.ts",
16447
+ "declarations": [
16448
+ {
16449
+ "kind": "function",
16450
+ "name": "observe",
16451
+ "parameters": [
16452
+ {
16453
+ "name": "propertyName",
16454
+ "type": {
16455
+ "text": "string"
16456
+ }
16457
+ },
16458
+ {
16459
+ "name": "lifecycle",
16460
+ "default": "\"update\"",
16461
+ "type": {
16462
+ "text": "ObserveLifecycle"
16463
+ }
16464
+ }
16465
+ ]
16466
+ }
16467
+ ],
16468
+ "exports": [
16469
+ {
16470
+ "kind": "js",
16471
+ "name": "observe",
16472
+ "declaration": {
16473
+ "name": "observe",
16474
+ "module": "src/common/decorators/observe.ts"
16475
+ }
16476
+ }
16477
+ ]
16478
+ },
16349
16479
  {
16350
16480
  "kind": "javascript-module",
16351
16481
  "path": "src/common/controllers/BroadcastChannelController.ts",
@@ -17622,41 +17752,6 @@
17622
17752
  }
17623
17753
  ]
17624
17754
  },
17625
- {
17626
- "kind": "javascript-module",
17627
- "path": "src/common/decorators/observe.ts",
17628
- "declarations": [
17629
- {
17630
- "kind": "function",
17631
- "name": "observe",
17632
- "parameters": [
17633
- {
17634
- "name": "propertyName",
17635
- "type": {
17636
- "text": "string"
17637
- }
17638
- },
17639
- {
17640
- "name": "lifecycle",
17641
- "default": "\"update\"",
17642
- "type": {
17643
- "text": "ObserveLifecycle"
17644
- }
17645
- }
17646
- ]
17647
- }
17648
- ],
17649
- "exports": [
17650
- {
17651
- "kind": "js",
17652
- "name": "observe",
17653
- "declaration": {
17654
- "name": "observe",
17655
- "module": "src/common/decorators/observe.ts"
17656
- }
17657
- }
17658
- ]
17659
- },
17660
17755
  {
17661
17756
  "kind": "javascript-module",
17662
17757
  "path": "src/common/directives/cond.ts",