@nordhealth/components 1.11.0 → 1.11.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/custom-elements.json +1270 -1270
- package/lib/Badge.js +1 -1
- package/lib/Badge.js.map +1 -1
- package/lib/Calendar-8b474799.js +2 -0
- package/lib/{Calendar-2797d956.js.map → Calendar-8b474799.js.map} +1 -1
- package/lib/Calendar.js +1 -1
- package/lib/DatePicker.js +1 -1
- package/lib/DatePicker.js.map +1 -1
- package/lib/Layout.js +1 -1
- package/lib/Layout.js.map +1 -1
- package/lib/Select.js +1 -1
- package/lib/Select.js.map +1 -1
- package/lib/TabGroup.js +1 -1
- package/lib/TabGroup.js.map +1 -1
- package/lib/Table.js +1 -1
- package/lib/Table.js.map +1 -1
- package/lib/bundle.js +6 -6
- package/lib/bundle.js.map +1 -1
- package/lib/index.js +1 -1
- package/package.json +5 -5
- package/lib/Calendar-2797d956.js +0 -2
package/custom-elements.json
CHANGED
|
@@ -505,194 +505,140 @@
|
|
|
505
505
|
},
|
|
506
506
|
{
|
|
507
507
|
"kind": "javascript-module",
|
|
508
|
-
"path": "src/
|
|
508
|
+
"path": "src/calendar/Calendar.ts",
|
|
509
509
|
"declarations": [
|
|
510
510
|
{
|
|
511
511
|
"kind": "class",
|
|
512
|
-
"description": "
|
|
513
|
-
"name": "
|
|
514
|
-
"slots": [
|
|
515
|
-
{
|
|
516
|
-
"description": "default slot",
|
|
517
|
-
"name": ""
|
|
518
|
-
}
|
|
519
|
-
],
|
|
512
|
+
"description": "Calendar allows user to pick a date. It comes with built-in\nfunctionality that allows you to set a minimum and a maximum allowed date.\nPlease note that the date must be passed in ISO-8601 format.",
|
|
513
|
+
"name": "Calendar",
|
|
520
514
|
"members": [
|
|
521
515
|
{
|
|
522
516
|
"kind": "field",
|
|
523
|
-
"name": "
|
|
517
|
+
"name": "dialogLabelId",
|
|
524
518
|
"type": {
|
|
525
|
-
"text": "
|
|
519
|
+
"text": "string"
|
|
526
520
|
},
|
|
527
|
-
"
|
|
528
|
-
"
|
|
529
|
-
|
|
530
|
-
"reflects": true
|
|
531
|
-
}
|
|
532
|
-
],
|
|
533
|
-
"attributes": [
|
|
521
|
+
"privacy": "private",
|
|
522
|
+
"default": "\"dialog-header\""
|
|
523
|
+
},
|
|
534
524
|
{
|
|
535
|
-
"
|
|
525
|
+
"kind": "field",
|
|
526
|
+
"name": "monthSelectNode",
|
|
536
527
|
"type": {
|
|
537
|
-
"text": "
|
|
528
|
+
"text": "HTMLElement"
|
|
538
529
|
},
|
|
539
|
-
"
|
|
540
|
-
|
|
541
|
-
"fieldName": "variant"
|
|
542
|
-
}
|
|
543
|
-
],
|
|
544
|
-
"superclass": {
|
|
545
|
-
"name": "LitElement",
|
|
546
|
-
"package": "lit"
|
|
547
|
-
},
|
|
548
|
-
"status": "ready",
|
|
549
|
-
"category": "feedback",
|
|
550
|
-
"displayName": null,
|
|
551
|
-
"tagName": "nord-banner",
|
|
552
|
-
"customElement": true
|
|
553
|
-
}
|
|
554
|
-
],
|
|
555
|
-
"exports": [
|
|
556
|
-
{
|
|
557
|
-
"kind": "js",
|
|
558
|
-
"name": "default",
|
|
559
|
-
"declaration": {
|
|
560
|
-
"name": "Banner",
|
|
561
|
-
"module": "src/banner/Banner.ts"
|
|
562
|
-
}
|
|
563
|
-
},
|
|
564
|
-
{
|
|
565
|
-
"kind": "custom-element-definition",
|
|
566
|
-
"name": "nord-banner",
|
|
567
|
-
"declaration": {
|
|
568
|
-
"name": "Banner",
|
|
569
|
-
"module": "src/banner/Banner.ts"
|
|
570
|
-
}
|
|
571
|
-
}
|
|
572
|
-
],
|
|
573
|
-
"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"
|
|
574
|
-
},
|
|
575
|
-
{
|
|
576
|
-
"kind": "javascript-module",
|
|
577
|
-
"path": "src/button/Button.ts",
|
|
578
|
-
"declarations": [
|
|
579
|
-
{
|
|
580
|
-
"kind": "class",
|
|
581
|
-
"description": "Buttons are used for interface actions. Primary style should be\nused only once per section for main call-to-action, while other\nstyles can appear more frequently.",
|
|
582
|
-
"name": "Button",
|
|
583
|
-
"slots": [
|
|
530
|
+
"privacy": "private"
|
|
531
|
+
},
|
|
584
532
|
{
|
|
585
|
-
"
|
|
586
|
-
"name": ""
|
|
533
|
+
"kind": "field",
|
|
534
|
+
"name": "focusedDayNode",
|
|
535
|
+
"type": {
|
|
536
|
+
"text": "HTMLButtonElement"
|
|
537
|
+
},
|
|
538
|
+
"privacy": "private"
|
|
587
539
|
},
|
|
588
540
|
{
|
|
589
|
-
"
|
|
590
|
-
"name": "
|
|
541
|
+
"kind": "field",
|
|
542
|
+
"name": "direction",
|
|
543
|
+
"privacy": "private",
|
|
544
|
+
"default": "new DirectionController(this)"
|
|
591
545
|
},
|
|
592
546
|
{
|
|
593
|
-
"
|
|
594
|
-
"name": "
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
547
|
+
"kind": "field",
|
|
548
|
+
"name": "swipe",
|
|
549
|
+
"privacy": "private",
|
|
550
|
+
"default": "new SwipeController(this, {\n matchesGesture: isHorizontalSwipe,\n onSwipeEnd: ({ distX }) => this.addMonths(distX < 0 ? 1 : -1),\n })"
|
|
551
|
+
},
|
|
598
552
|
{
|
|
599
553
|
"kind": "field",
|
|
600
|
-
"name": "
|
|
554
|
+
"name": "shortcuts",
|
|
601
555
|
"privacy": "private"
|
|
602
556
|
},
|
|
603
557
|
{
|
|
604
558
|
"kind": "field",
|
|
605
|
-
"name": "
|
|
559
|
+
"name": "localize",
|
|
606
560
|
"privacy": "private",
|
|
607
|
-
"default": "new
|
|
561
|
+
"default": "new LocalizeController<\"nord-calendar\">(this, {\n onLangChange: () => this.handleLangChange(),\n })"
|
|
608
562
|
},
|
|
609
563
|
{
|
|
610
564
|
"kind": "field",
|
|
611
|
-
"name": "
|
|
565
|
+
"name": "dateFormatShort",
|
|
566
|
+
"type": {
|
|
567
|
+
"text": "Intl.DateTimeFormat"
|
|
568
|
+
},
|
|
612
569
|
"privacy": "private",
|
|
613
|
-
"
|
|
570
|
+
"description": "Whilst dateAdapter is used for handling the formatting/parsing dates in the input,\nthese are used to format dates exclusively for the benefit of screen readers.\n\nWe prefer DateTimeFormat over date.toLocaleDateString, as the former has\nbetter performance when formatting large number of dates. See:\nhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleDateString#Performance"
|
|
614
571
|
},
|
|
615
572
|
{
|
|
616
573
|
"kind": "field",
|
|
617
|
-
"name": "
|
|
574
|
+
"name": "monthNames",
|
|
618
575
|
"type": {
|
|
619
|
-
"text": "
|
|
576
|
+
"text": "string[]"
|
|
620
577
|
},
|
|
621
|
-
"
|
|
622
|
-
"description": "The style variant of the button.",
|
|
623
|
-
"attribute": "variant",
|
|
624
|
-
"reflects": true
|
|
578
|
+
"privacy": "private"
|
|
625
579
|
},
|
|
626
580
|
{
|
|
627
581
|
"kind": "field",
|
|
628
|
-
"name": "
|
|
582
|
+
"name": "monthNamesShort",
|
|
629
583
|
"type": {
|
|
630
|
-
"text": "
|
|
584
|
+
"text": "string[]"
|
|
631
585
|
},
|
|
632
|
-
"
|
|
633
|
-
"description": "The type of the button.",
|
|
634
|
-
"attribute": "type",
|
|
635
|
-
"reflects": true
|
|
586
|
+
"privacy": "private"
|
|
636
587
|
},
|
|
637
588
|
{
|
|
638
589
|
"kind": "field",
|
|
639
|
-
"name": "
|
|
590
|
+
"name": "dayNames",
|
|
640
591
|
"type": {
|
|
641
|
-
"text": "
|
|
592
|
+
"text": "string[]"
|
|
642
593
|
},
|
|
643
|
-
"
|
|
644
|
-
"description": "The size of the button.\nThis affects font-size and padding.",
|
|
645
|
-
"attribute": "size",
|
|
646
|
-
"reflects": true
|
|
594
|
+
"privacy": "private"
|
|
647
595
|
},
|
|
648
596
|
{
|
|
649
597
|
"kind": "field",
|
|
650
|
-
"name": "
|
|
598
|
+
"name": "dayNamesShort",
|
|
651
599
|
"type": {
|
|
652
|
-
"text": "
|
|
600
|
+
"text": "string[]"
|
|
653
601
|
},
|
|
654
|
-
"privacy": "private"
|
|
655
|
-
"attribute": "aria-expanded"
|
|
602
|
+
"privacy": "private"
|
|
656
603
|
},
|
|
657
604
|
{
|
|
658
605
|
"kind": "field",
|
|
659
|
-
"name": "
|
|
606
|
+
"name": "value",
|
|
660
607
|
"type": {
|
|
661
|
-
"text": "
|
|
608
|
+
"text": "string"
|
|
662
609
|
},
|
|
663
|
-
"
|
|
664
|
-
"
|
|
610
|
+
"default": "\"\"",
|
|
611
|
+
"description": "The selected date on the calendar. Must be in IS0-8601 format: YYYY-MM-DD.",
|
|
612
|
+
"attribute": "value"
|
|
665
613
|
},
|
|
666
614
|
{
|
|
667
615
|
"kind": "field",
|
|
668
|
-
"name": "
|
|
616
|
+
"name": "firstDayOfWeek",
|
|
669
617
|
"type": {
|
|
670
|
-
"text": "
|
|
618
|
+
"text": "DaysOfWeek"
|
|
671
619
|
},
|
|
672
|
-
"description": "
|
|
673
|
-
"attribute": "
|
|
674
|
-
"reflects": true
|
|
620
|
+
"description": "Which day is considered first day of the week? `0` for Sunday, `1` for Monday, etc.\nDefault is Monday.",
|
|
621
|
+
"attribute": "firstDayOfWeek"
|
|
675
622
|
},
|
|
676
623
|
{
|
|
677
624
|
"kind": "field",
|
|
678
|
-
"name": "
|
|
625
|
+
"name": "min",
|
|
679
626
|
"type": {
|
|
680
|
-
"text": "
|
|
627
|
+
"text": "string"
|
|
681
628
|
},
|
|
682
|
-
"default": "
|
|
683
|
-
"description": "
|
|
684
|
-
"attribute": "
|
|
629
|
+
"default": "\"\"",
|
|
630
|
+
"description": "Minimum date allowed to be picked. Must be in IS0-8601 format: YYYY-MM-DD.\nThis setting can be used alone or together with the max property.",
|
|
631
|
+
"attribute": "min"
|
|
685
632
|
},
|
|
686
633
|
{
|
|
687
634
|
"kind": "field",
|
|
688
|
-
"name": "
|
|
635
|
+
"name": "max",
|
|
689
636
|
"type": {
|
|
690
|
-
"text": "
|
|
637
|
+
"text": "string"
|
|
691
638
|
},
|
|
692
|
-
"default": "\"
|
|
693
|
-
"description": "
|
|
694
|
-
"attribute": "
|
|
695
|
-
"reflects": true
|
|
639
|
+
"default": "\"\"",
|
|
640
|
+
"description": "Maximum date allowed to be picked. Must be in IS0-8601 format: YYYY-MM-DD.\nThis setting can be used alone or together with the min property.",
|
|
641
|
+
"attribute": "max"
|
|
696
642
|
},
|
|
697
643
|
{
|
|
698
644
|
"kind": "field",
|
|
@@ -701,288 +647,417 @@
|
|
|
701
647
|
"text": "boolean"
|
|
702
648
|
},
|
|
703
649
|
"default": "false",
|
|
704
|
-
"description": "Controls whether the
|
|
650
|
+
"description": "Controls whether the calendar expands to fill the width of its container.",
|
|
705
651
|
"attribute": "expand",
|
|
706
652
|
"reflects": true
|
|
707
653
|
},
|
|
708
654
|
{
|
|
709
|
-
"kind": "
|
|
710
|
-
"name": "
|
|
655
|
+
"kind": "field",
|
|
656
|
+
"name": "isDateDisabled",
|
|
657
|
+
"type": {
|
|
658
|
+
"text": "DateDisabledPredicate"
|
|
659
|
+
},
|
|
660
|
+
"default": "isDateDisabled",
|
|
661
|
+
"description": "Controls which days are disabled and therefore disallowed.\nFor example, this can be used to disallow selection of weekends."
|
|
662
|
+
},
|
|
663
|
+
{
|
|
664
|
+
"kind": "field",
|
|
665
|
+
"name": "activeFocus",
|
|
666
|
+
"type": {
|
|
667
|
+
"text": "boolean"
|
|
668
|
+
},
|
|
669
|
+
"privacy": "private",
|
|
670
|
+
"default": "false"
|
|
671
|
+
},
|
|
672
|
+
{
|
|
673
|
+
"kind": "field",
|
|
674
|
+
"name": "focusedDay",
|
|
711
675
|
"privacy": "private",
|
|
676
|
+
"default": "new Date()"
|
|
677
|
+
},
|
|
678
|
+
{
|
|
679
|
+
"kind": "method",
|
|
680
|
+
"name": "focus",
|
|
712
681
|
"parameters": [
|
|
713
682
|
{
|
|
714
|
-
"name": "
|
|
683
|
+
"name": "options",
|
|
684
|
+
"optional": true,
|
|
715
685
|
"type": {
|
|
716
|
-
"text": "
|
|
717
|
-
}
|
|
686
|
+
"text": "FocusOptions & { target: \"day\" | \"month\" }"
|
|
687
|
+
},
|
|
688
|
+
"description": "An object which controls aspects of the focusing process."
|
|
718
689
|
}
|
|
719
690
|
],
|
|
720
|
-
"description": "
|
|
691
|
+
"description": "Programmatically move focus to the calendar."
|
|
721
692
|
},
|
|
722
693
|
{
|
|
723
694
|
"kind": "method",
|
|
724
|
-
"name": "
|
|
725
|
-
"privacy": "
|
|
726
|
-
"parameters": [
|
|
727
|
-
{
|
|
728
|
-
"name": "innards",
|
|
729
|
-
"type": {
|
|
730
|
-
"text": "TemplateResult"
|
|
731
|
-
}
|
|
732
|
-
}
|
|
733
|
-
]
|
|
695
|
+
"name": "handleValueChange",
|
|
696
|
+
"privacy": "protected"
|
|
734
697
|
},
|
|
735
698
|
{
|
|
736
699
|
"kind": "method",
|
|
737
|
-
"name": "
|
|
700
|
+
"name": "handleFocusedDayChange",
|
|
701
|
+
"privacy": "protected"
|
|
702
|
+
},
|
|
703
|
+
{
|
|
704
|
+
"kind": "method",
|
|
705
|
+
"name": "handleLangChange",
|
|
738
706
|
"privacy": "private"
|
|
739
707
|
},
|
|
740
708
|
{
|
|
741
709
|
"kind": "field",
|
|
742
|
-
"name": "
|
|
710
|
+
"name": "handleDaySelect",
|
|
743
711
|
"privacy": "private"
|
|
744
712
|
},
|
|
745
713
|
{
|
|
746
714
|
"kind": "method",
|
|
747
|
-
"name": "
|
|
715
|
+
"name": "addDays",
|
|
748
716
|
"privacy": "private",
|
|
749
717
|
"parameters": [
|
|
750
718
|
{
|
|
751
|
-
"name": "
|
|
719
|
+
"name": "days",
|
|
752
720
|
"type": {
|
|
753
|
-
"text": "
|
|
721
|
+
"text": "number"
|
|
754
722
|
}
|
|
755
723
|
}
|
|
756
724
|
]
|
|
757
725
|
},
|
|
758
726
|
{
|
|
759
727
|
"kind": "method",
|
|
760
|
-
"name": "
|
|
728
|
+
"name": "addMonths",
|
|
761
729
|
"privacy": "private",
|
|
762
|
-
"
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
"default": "false",
|
|
771
|
-
"description": "Makes the component disabled. This prevents users from\nbeing able to interact with the component, and conveys\nits inactive state to assistive technologies.",
|
|
772
|
-
"attribute": "disabled",
|
|
773
|
-
"reflects": true,
|
|
774
|
-
"inheritedFrom": {
|
|
775
|
-
"name": "InputMixin",
|
|
776
|
-
"module": "src/common/mixins/InputMixin.ts"
|
|
777
|
-
}
|
|
778
|
-
},
|
|
779
|
-
{
|
|
780
|
-
"kind": "field",
|
|
781
|
-
"name": "name",
|
|
782
|
-
"type": {
|
|
783
|
-
"text": "string | undefined"
|
|
784
|
-
},
|
|
785
|
-
"description": "The name of the form component.",
|
|
786
|
-
"attribute": "name",
|
|
787
|
-
"inheritedFrom": {
|
|
788
|
-
"name": "InputMixin",
|
|
789
|
-
"module": "src/common/mixins/InputMixin.ts"
|
|
790
|
-
}
|
|
730
|
+
"parameters": [
|
|
731
|
+
{
|
|
732
|
+
"name": "months",
|
|
733
|
+
"type": {
|
|
734
|
+
"text": "number"
|
|
735
|
+
}
|
|
736
|
+
}
|
|
737
|
+
]
|
|
791
738
|
},
|
|
792
739
|
{
|
|
793
|
-
"kind": "
|
|
794
|
-
"name": "
|
|
795
|
-
"
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
}
|
|
740
|
+
"kind": "method",
|
|
741
|
+
"name": "addYears",
|
|
742
|
+
"privacy": "private",
|
|
743
|
+
"parameters": [
|
|
744
|
+
{
|
|
745
|
+
"name": "years",
|
|
746
|
+
"type": {
|
|
747
|
+
"text": "number"
|
|
748
|
+
}
|
|
749
|
+
}
|
|
750
|
+
]
|
|
805
751
|
},
|
|
806
752
|
{
|
|
807
|
-
"kind": "
|
|
808
|
-
"name": "
|
|
809
|
-
"
|
|
810
|
-
"inheritedFrom": {
|
|
811
|
-
"name": "InputMixin",
|
|
812
|
-
"module": "src/common/mixins/InputMixin.ts"
|
|
813
|
-
}
|
|
753
|
+
"kind": "method",
|
|
754
|
+
"name": "startOfWeek",
|
|
755
|
+
"privacy": "private"
|
|
814
756
|
},
|
|
815
757
|
{
|
|
816
|
-
"kind": "
|
|
817
|
-
"name": "
|
|
818
|
-
"privacy": "
|
|
819
|
-
"inheritedFrom": {
|
|
820
|
-
"name": "FocusableMixin",
|
|
821
|
-
"module": "src/common/mixins/FocusableMixin.ts"
|
|
822
|
-
}
|
|
758
|
+
"kind": "method",
|
|
759
|
+
"name": "endOfWeek",
|
|
760
|
+
"privacy": "private"
|
|
823
761
|
},
|
|
824
762
|
{
|
|
825
763
|
"kind": "method",
|
|
826
|
-
"name": "
|
|
764
|
+
"name": "setMonth",
|
|
765
|
+
"privacy": "private",
|
|
827
766
|
"parameters": [
|
|
828
767
|
{
|
|
829
|
-
"name": "
|
|
830
|
-
"optional": true,
|
|
768
|
+
"name": "month",
|
|
831
769
|
"type": {
|
|
832
|
-
"text": "
|
|
833
|
-
}
|
|
834
|
-
"description": "An object which controls aspects of the focusing process."
|
|
770
|
+
"text": "number"
|
|
771
|
+
}
|
|
835
772
|
}
|
|
836
|
-
]
|
|
837
|
-
"description": "Programmatically move focus to the component.",
|
|
838
|
-
"inheritedFrom": {
|
|
839
|
-
"name": "FocusableMixin",
|
|
840
|
-
"module": "src/common/mixins/FocusableMixin.ts"
|
|
841
|
-
}
|
|
773
|
+
]
|
|
842
774
|
},
|
|
843
775
|
{
|
|
844
776
|
"kind": "method",
|
|
845
|
-
"name": "
|
|
846
|
-
"
|
|
847
|
-
"
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
777
|
+
"name": "setYear",
|
|
778
|
+
"privacy": "private",
|
|
779
|
+
"parameters": [
|
|
780
|
+
{
|
|
781
|
+
"name": "year",
|
|
782
|
+
"type": {
|
|
783
|
+
"text": "number"
|
|
784
|
+
}
|
|
785
|
+
}
|
|
786
|
+
]
|
|
851
787
|
},
|
|
852
788
|
{
|
|
853
789
|
"kind": "method",
|
|
854
|
-
"name": "
|
|
855
|
-
"
|
|
856
|
-
"
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
790
|
+
"name": "setFocusedDay",
|
|
791
|
+
"privacy": "private",
|
|
792
|
+
"parameters": [
|
|
793
|
+
{
|
|
794
|
+
"name": "day",
|
|
795
|
+
"type": {
|
|
796
|
+
"text": "Date"
|
|
797
|
+
}
|
|
798
|
+
}
|
|
799
|
+
]
|
|
800
|
+
},
|
|
863
801
|
{
|
|
864
|
-
"
|
|
865
|
-
"
|
|
866
|
-
|
|
867
|
-
},
|
|
868
|
-
"default": "\"default\"",
|
|
869
|
-
"description": "The style variant of the button.",
|
|
870
|
-
"fieldName": "variant"
|
|
802
|
+
"kind": "field",
|
|
803
|
+
"name": "handleMonthSelect",
|
|
804
|
+
"privacy": "private"
|
|
871
805
|
},
|
|
872
806
|
{
|
|
873
|
-
"
|
|
874
|
-
"
|
|
875
|
-
|
|
876
|
-
},
|
|
877
|
-
"default": "\"submit\"",
|
|
878
|
-
"description": "The type of the button.",
|
|
879
|
-
"fieldName": "type"
|
|
807
|
+
"kind": "field",
|
|
808
|
+
"name": "handleYearSelect",
|
|
809
|
+
"privacy": "private"
|
|
880
810
|
},
|
|
881
811
|
{
|
|
882
|
-
"
|
|
883
|
-
"
|
|
884
|
-
|
|
885
|
-
},
|
|
886
|
-
"default": "\"m\"",
|
|
887
|
-
"description": "The size of the button.\nThis affects font-size and padding.",
|
|
888
|
-
"fieldName": "size"
|
|
812
|
+
"kind": "field",
|
|
813
|
+
"name": "handleNextMonthClick",
|
|
814
|
+
"privacy": "private"
|
|
889
815
|
},
|
|
890
816
|
{
|
|
891
|
-
"
|
|
892
|
-
"
|
|
893
|
-
|
|
894
|
-
},
|
|
895
|
-
"fieldName": "accessibleExpanded"
|
|
817
|
+
"kind": "field",
|
|
818
|
+
"name": "handlePreviousMonthClick",
|
|
819
|
+
"privacy": "private"
|
|
896
820
|
},
|
|
897
821
|
{
|
|
898
|
-
"
|
|
899
|
-
"
|
|
900
|
-
|
|
901
|
-
},
|
|
902
|
-
"fieldName": "accessibleHasPopup"
|
|
822
|
+
"kind": "field",
|
|
823
|
+
"name": "enableActiveFocus",
|
|
824
|
+
"privacy": "private"
|
|
903
825
|
},
|
|
904
826
|
{
|
|
905
|
-
"
|
|
827
|
+
"kind": "field",
|
|
828
|
+
"name": "disableActiveFocus",
|
|
829
|
+
"privacy": "private"
|
|
830
|
+
}
|
|
831
|
+
],
|
|
832
|
+
"events": [
|
|
833
|
+
{
|
|
834
|
+
"name": "nord-focus-date",
|
|
906
835
|
"type": {
|
|
907
|
-
"text": "
|
|
836
|
+
"text": "DateSelectEvent"
|
|
908
837
|
},
|
|
909
|
-
"description": "
|
|
910
|
-
"fieldName": "href"
|
|
838
|
+
"description": "Dispatched when the calendar's focused date changes."
|
|
911
839
|
},
|
|
912
840
|
{
|
|
913
|
-
"name": "download",
|
|
914
841
|
"type": {
|
|
915
|
-
"text": "
|
|
842
|
+
"text": "DateSelectEvent"
|
|
916
843
|
},
|
|
917
|
-
"
|
|
918
|
-
"
|
|
919
|
-
|
|
920
|
-
|
|
844
|
+
"description": "Dispatched when a date is selected and the value changes.",
|
|
845
|
+
"name": "change"
|
|
846
|
+
}
|
|
847
|
+
],
|
|
848
|
+
"attributes": [
|
|
921
849
|
{
|
|
922
|
-
"name": "
|
|
850
|
+
"name": "value",
|
|
923
851
|
"type": {
|
|
924
|
-
"text": "
|
|
852
|
+
"text": "string"
|
|
925
853
|
},
|
|
926
|
-
"default": "\"
|
|
927
|
-
"description": "
|
|
928
|
-
"fieldName": "
|
|
854
|
+
"default": "\"\"",
|
|
855
|
+
"description": "The selected date on the calendar. Must be in IS0-8601 format: YYYY-MM-DD.",
|
|
856
|
+
"fieldName": "value"
|
|
929
857
|
},
|
|
930
858
|
{
|
|
931
|
-
"name": "
|
|
859
|
+
"name": "firstDayOfWeek",
|
|
932
860
|
"type": {
|
|
933
|
-
"text": "
|
|
861
|
+
"text": "DaysOfWeek"
|
|
934
862
|
},
|
|
935
|
-
"
|
|
936
|
-
"
|
|
937
|
-
"fieldName": "expand"
|
|
863
|
+
"description": "Which day is considered first day of the week? `0` for Sunday, `1` for Monday, etc.\nDefault is Monday.",
|
|
864
|
+
"fieldName": "firstDayOfWeek"
|
|
938
865
|
},
|
|
939
866
|
{
|
|
940
|
-
"name": "
|
|
867
|
+
"name": "min",
|
|
941
868
|
"type": {
|
|
942
|
-
"text": "
|
|
869
|
+
"text": "string"
|
|
943
870
|
},
|
|
944
|
-
"default": "
|
|
945
|
-
"description": "
|
|
946
|
-
"fieldName": "
|
|
947
|
-
"inheritedFrom": {
|
|
948
|
-
"name": "InputMixin",
|
|
949
|
-
"module": "src/common/mixins/InputMixin.ts"
|
|
950
|
-
}
|
|
871
|
+
"default": "\"\"",
|
|
872
|
+
"description": "Minimum date allowed to be picked. Must be in IS0-8601 format: YYYY-MM-DD.\nThis setting can be used alone or together with the max property.",
|
|
873
|
+
"fieldName": "min"
|
|
951
874
|
},
|
|
952
875
|
{
|
|
953
|
-
"name": "
|
|
876
|
+
"name": "max",
|
|
954
877
|
"type": {
|
|
955
|
-
"text": "string
|
|
878
|
+
"text": "string"
|
|
956
879
|
},
|
|
957
|
-
"
|
|
958
|
-
"
|
|
959
|
-
"
|
|
960
|
-
"name": "InputMixin",
|
|
961
|
-
"module": "src/common/mixins/InputMixin.ts"
|
|
962
|
-
}
|
|
880
|
+
"default": "\"\"",
|
|
881
|
+
"description": "Maximum date allowed to be picked. Must be in IS0-8601 format: YYYY-MM-DD.\nThis setting can be used alone or together with the min property.",
|
|
882
|
+
"fieldName": "max"
|
|
963
883
|
},
|
|
964
884
|
{
|
|
965
|
-
"name": "
|
|
885
|
+
"name": "expand",
|
|
966
886
|
"type": {
|
|
967
|
-
"text": "
|
|
887
|
+
"text": "boolean"
|
|
968
888
|
},
|
|
969
|
-
"default": "
|
|
970
|
-
"description": "
|
|
971
|
-
"fieldName": "
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
889
|
+
"default": "false",
|
|
890
|
+
"description": "Controls whether the calendar expands to fill the width of its container.",
|
|
891
|
+
"fieldName": "expand"
|
|
892
|
+
}
|
|
893
|
+
],
|
|
894
|
+
"superclass": {
|
|
895
|
+
"name": "LitElement",
|
|
896
|
+
"package": "lit"
|
|
897
|
+
},
|
|
898
|
+
"status": "ready",
|
|
899
|
+
"category": "list",
|
|
900
|
+
"displayName": null,
|
|
901
|
+
"tagName": "nord-calendar",
|
|
902
|
+
"customElement": true
|
|
903
|
+
}
|
|
904
|
+
],
|
|
905
|
+
"exports": [
|
|
906
|
+
{
|
|
907
|
+
"kind": "js",
|
|
908
|
+
"name": "default",
|
|
909
|
+
"declaration": {
|
|
910
|
+
"name": "Calendar",
|
|
911
|
+
"module": "src/calendar/Calendar.ts"
|
|
912
|
+
}
|
|
913
|
+
},
|
|
914
|
+
{
|
|
915
|
+
"kind": "custom-element-definition",
|
|
916
|
+
"name": "nord-calendar",
|
|
917
|
+
"declaration": {
|
|
918
|
+
"name": "Calendar",
|
|
919
|
+
"module": "src/calendar/Calendar.ts"
|
|
920
|
+
}
|
|
921
|
+
}
|
|
922
|
+
],
|
|
923
|
+
"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 when the user needs to choose a single date or a date range.\n- Close calendar after a single date is selected, unless a range with a start and end date is required.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for entering date of birth. Use input component instead.\n- Don’t use for choosing a date that is over 10 years in the future or the past.\n\n</div>\n\n---\n\n## Keyboard accessibility\n\nCalendar component is built to closely follow [W3C Date Picker Dialog example](https://www.w3.org/TR/wai-aria-practices/examples/dialog-modal/datepicker-dialog.html) with some small exceptions to e.g. better support iOS VoiceOver and Android TalkBack.\n\n### Month/year buttons\n\n- `Space, Enter`: Changes the month and/or year displayed.\n\n### Calendar grid\n\n- `Space, Enter`: Selects a date.\n- `Arrow up`: Moves focus to the same day of the previous week.\n- `Arrow down`: Moves focus to the same day of the next week.\n- `Arrow right`: Moves focus to the next day. In right-to-left languages, moves focus to the previous day.\n- `Arrow left`: Moves focus to the previous day. In right-to-left languages, moves focus to the next day.\n- `Home`: Moves focus to the first day (e.g Monday) of the current week.\n- `End`: Moves focus to the last day (e.g. Sunday) of the current week.\n- `Page Up`: Changes the grid of dates to the previous month and sets focus on the same day of the same week.\n- `Shift + Page Up`: Changes the grid of dates to the previous year and sets focus on the same day of the same week.\n- `Page Down`: Changes the grid of dates to the next month and sets focus on the same day of the same week.\n- `Shift + Page Down`: Changes the grid of dates to the next year and sets focus on the same day of the same week.\n"
|
|
924
|
+
},
|
|
925
|
+
{
|
|
926
|
+
"kind": "javascript-module",
|
|
927
|
+
"path": "src/calendar/DateSelectEvent.ts",
|
|
928
|
+
"declarations": [
|
|
929
|
+
{
|
|
930
|
+
"kind": "class",
|
|
931
|
+
"description": "",
|
|
932
|
+
"name": "DateSelectEvent",
|
|
933
|
+
"superclass": {
|
|
934
|
+
"name": "NordEvent",
|
|
935
|
+
"module": "/src/common/events.js"
|
|
936
|
+
}
|
|
937
|
+
}
|
|
938
|
+
],
|
|
939
|
+
"exports": [
|
|
940
|
+
{
|
|
941
|
+
"kind": "js",
|
|
942
|
+
"name": "DateSelectEvent",
|
|
943
|
+
"declaration": {
|
|
944
|
+
"name": "DateSelectEvent",
|
|
945
|
+
"module": "src/calendar/DateSelectEvent.ts"
|
|
946
|
+
}
|
|
947
|
+
}
|
|
948
|
+
],
|
|
949
|
+
"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 when the user needs to choose a single date or a date range.\n- Close calendar after a single date is selected, unless a range with a start and end date is required.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for entering date of birth. Use input component instead.\n- Don’t use for choosing a date that is over 10 years in the future or the past.\n\n</div>\n\n---\n\n## Keyboard accessibility\n\nCalendar component is built to closely follow [W3C Date Picker Dialog example](https://www.w3.org/TR/wai-aria-practices/examples/dialog-modal/datepicker-dialog.html) with some small exceptions to e.g. better support iOS VoiceOver and Android TalkBack.\n\n### Month/year buttons\n\n- `Space, Enter`: Changes the month and/or year displayed.\n\n### Calendar grid\n\n- `Space, Enter`: Selects a date.\n- `Arrow up`: Moves focus to the same day of the previous week.\n- `Arrow down`: Moves focus to the same day of the next week.\n- `Arrow right`: Moves focus to the next day. In right-to-left languages, moves focus to the previous day.\n- `Arrow left`: Moves focus to the previous day. In right-to-left languages, moves focus to the next day.\n- `Home`: Moves focus to the first day (e.g Monday) of the current week.\n- `End`: Moves focus to the last day (e.g. Sunday) of the current week.\n- `Page Up`: Changes the grid of dates to the previous month and sets focus on the same day of the same week.\n- `Shift + Page Up`: Changes the grid of dates to the previous year and sets focus on the same day of the same week.\n- `Page Down`: Changes the grid of dates to the next month and sets focus on the same day of the same week.\n- `Shift + Page Down`: Changes the grid of dates to the next year and sets focus on the same day of the same week.\n"
|
|
950
|
+
},
|
|
951
|
+
{
|
|
952
|
+
"kind": "javascript-module",
|
|
953
|
+
"path": "src/calendar/localization.ts",
|
|
954
|
+
"declarations": [
|
|
955
|
+
{
|
|
956
|
+
"kind": "variable",
|
|
957
|
+
"name": "calendarLocalization",
|
|
958
|
+
"type": {
|
|
959
|
+
"text": "object"
|
|
960
|
+
},
|
|
961
|
+
"default": "{\n prevMonthLabel: \"Previous month\",\n nextMonthLabel: \"Next month\",\n monthSelectLabel: \"Month\",\n yearSelectLabel: \"Year\",\n}"
|
|
962
|
+
}
|
|
963
|
+
],
|
|
964
|
+
"exports": [
|
|
965
|
+
{
|
|
966
|
+
"kind": "js",
|
|
967
|
+
"name": "default",
|
|
968
|
+
"declaration": {
|
|
969
|
+
"name": "calendarLocalization",
|
|
970
|
+
"module": "src/calendar/localization.ts"
|
|
971
|
+
}
|
|
972
|
+
}
|
|
973
|
+
],
|
|
974
|
+
"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 when the user needs to choose a single date or a date range.\n- Close calendar after a single date is selected, unless a range with a start and end date is required.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for entering date of birth. Use input component instead.\n- Don’t use for choosing a date that is over 10 years in the future or the past.\n\n</div>\n\n---\n\n## Keyboard accessibility\n\nCalendar component is built to closely follow [W3C Date Picker Dialog example](https://www.w3.org/TR/wai-aria-practices/examples/dialog-modal/datepicker-dialog.html) with some small exceptions to e.g. better support iOS VoiceOver and Android TalkBack.\n\n### Month/year buttons\n\n- `Space, Enter`: Changes the month and/or year displayed.\n\n### Calendar grid\n\n- `Space, Enter`: Selects a date.\n- `Arrow up`: Moves focus to the same day of the previous week.\n- `Arrow down`: Moves focus to the same day of the next week.\n- `Arrow right`: Moves focus to the next day. In right-to-left languages, moves focus to the previous day.\n- `Arrow left`: Moves focus to the previous day. In right-to-left languages, moves focus to the next day.\n- `Home`: Moves focus to the first day (e.g Monday) of the current week.\n- `End`: Moves focus to the last day (e.g. Sunday) of the current week.\n- `Page Up`: Changes the grid of dates to the previous month and sets focus on the same day of the same week.\n- `Shift + Page Up`: Changes the grid of dates to the previous year and sets focus on the same day of the same week.\n- `Page Down`: Changes the grid of dates to the next month and sets focus on the same day of the same week.\n- `Shift + Page Down`: Changes the grid of dates to the next year and sets focus on the same day of the same week.\n"
|
|
975
|
+
},
|
|
976
|
+
{
|
|
977
|
+
"kind": "javascript-module",
|
|
978
|
+
"path": "src/calendar/month-view.ts",
|
|
979
|
+
"declarations": [
|
|
980
|
+
{
|
|
981
|
+
"kind": "function",
|
|
982
|
+
"name": "dayView",
|
|
983
|
+
"parameters": [
|
|
984
|
+
{
|
|
985
|
+
"name": "{\n focusedDay,\n today,\n day,\n onDaySelect,\n onKeyboardNavigation,\n disabled,\n inRange,\n isSelected,\n dateFormatter,\n}",
|
|
986
|
+
"type": {
|
|
987
|
+
"text": "DatePickerDayProps"
|
|
988
|
+
}
|
|
989
|
+
}
|
|
990
|
+
]
|
|
991
|
+
},
|
|
992
|
+
{
|
|
993
|
+
"kind": "function",
|
|
994
|
+
"name": "monthView",
|
|
995
|
+
"parameters": [
|
|
996
|
+
{
|
|
997
|
+
"name": "{\n onFocusIn,\n onFocusOut,\n selectedDate,\n focusedDate,\n labelledById,\n dayNames,\n dayNamesShort,\n firstDayOfWeek,\n min,\n max,\n dateFormatter,\n isDateDisabled,\n onDateSelect,\n onKeyboardNavigation,\n}",
|
|
998
|
+
"type": {
|
|
999
|
+
"text": "MonthViewArgs"
|
|
975
1000
|
}
|
|
976
1001
|
}
|
|
1002
|
+
]
|
|
1003
|
+
}
|
|
1004
|
+
],
|
|
1005
|
+
"exports": [
|
|
1006
|
+
{
|
|
1007
|
+
"kind": "js",
|
|
1008
|
+
"name": "dayView",
|
|
1009
|
+
"declaration": {
|
|
1010
|
+
"name": "dayView",
|
|
1011
|
+
"module": "src/calendar/month-view.ts"
|
|
1012
|
+
}
|
|
1013
|
+
},
|
|
1014
|
+
{
|
|
1015
|
+
"kind": "js",
|
|
1016
|
+
"name": "monthView",
|
|
1017
|
+
"declaration": {
|
|
1018
|
+
"name": "monthView",
|
|
1019
|
+
"module": "src/calendar/month-view.ts"
|
|
1020
|
+
}
|
|
1021
|
+
}
|
|
1022
|
+
],
|
|
1023
|
+
"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 when the user needs to choose a single date or a date range.\n- Close calendar after a single date is selected, unless a range with a start and end date is required.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for entering date of birth. Use input component instead.\n- Don’t use for choosing a date that is over 10 years in the future or the past.\n\n</div>\n\n---\n\n## Keyboard accessibility\n\nCalendar component is built to closely follow [W3C Date Picker Dialog example](https://www.w3.org/TR/wai-aria-practices/examples/dialog-modal/datepicker-dialog.html) with some small exceptions to e.g. better support iOS VoiceOver and Android TalkBack.\n\n### Month/year buttons\n\n- `Space, Enter`: Changes the month and/or year displayed.\n\n### Calendar grid\n\n- `Space, Enter`: Selects a date.\n- `Arrow up`: Moves focus to the same day of the previous week.\n- `Arrow down`: Moves focus to the same day of the next week.\n- `Arrow right`: Moves focus to the next day. In right-to-left languages, moves focus to the previous day.\n- `Arrow left`: Moves focus to the previous day. In right-to-left languages, moves focus to the next day.\n- `Home`: Moves focus to the first day (e.g Monday) of the current week.\n- `End`: Moves focus to the last day (e.g. Sunday) of the current week.\n- `Page Up`: Changes the grid of dates to the previous month and sets focus on the same day of the same week.\n- `Shift + Page Up`: Changes the grid of dates to the previous year and sets focus on the same day of the same week.\n- `Page Down`: Changes the grid of dates to the next month and sets focus on the same day of the same week.\n- `Shift + Page Down`: Changes the grid of dates to the next year and sets focus on the same day of the same week.\n"
|
|
1024
|
+
},
|
|
1025
|
+
{
|
|
1026
|
+
"kind": "javascript-module",
|
|
1027
|
+
"path": "src/banner/Banner.ts",
|
|
1028
|
+
"declarations": [
|
|
1029
|
+
{
|
|
1030
|
+
"kind": "class",
|
|
1031
|
+
"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.",
|
|
1032
|
+
"name": "Banner",
|
|
1033
|
+
"slots": [
|
|
1034
|
+
{
|
|
1035
|
+
"description": "default slot",
|
|
1036
|
+
"name": ""
|
|
1037
|
+
}
|
|
977
1038
|
],
|
|
978
|
-
"
|
|
1039
|
+
"members": [
|
|
979
1040
|
{
|
|
980
|
-
"
|
|
981
|
-
"
|
|
982
|
-
|
|
1041
|
+
"kind": "field",
|
|
1042
|
+
"name": "variant",
|
|
1043
|
+
"type": {
|
|
1044
|
+
"text": "\"info\" | \"danger\" | \"success\" | \"warning\""
|
|
1045
|
+
},
|
|
1046
|
+
"default": "\"info\"",
|
|
1047
|
+
"description": "The style variant of the banner.",
|
|
1048
|
+
"attribute": "variant",
|
|
1049
|
+
"reflects": true
|
|
1050
|
+
}
|
|
1051
|
+
],
|
|
1052
|
+
"attributes": [
|
|
983
1053
|
{
|
|
984
|
-
"name": "
|
|
985
|
-
"
|
|
1054
|
+
"name": "variant",
|
|
1055
|
+
"type": {
|
|
1056
|
+
"text": "\"info\" | \"danger\" | \"success\" | \"warning\""
|
|
1057
|
+
},
|
|
1058
|
+
"default": "\"info\"",
|
|
1059
|
+
"description": "The style variant of the banner.",
|
|
1060
|
+
"fieldName": "variant"
|
|
986
1061
|
}
|
|
987
1062
|
],
|
|
988
1063
|
"superclass": {
|
|
@@ -990,9 +1065,9 @@
|
|
|
990
1065
|
"package": "lit"
|
|
991
1066
|
},
|
|
992
1067
|
"status": "ready",
|
|
993
|
-
"category": "
|
|
1068
|
+
"category": "feedback",
|
|
994
1069
|
"displayName": null,
|
|
995
|
-
"tagName": "nord-
|
|
1070
|
+
"tagName": "nord-banner",
|
|
996
1071
|
"customElement": true
|
|
997
1072
|
}
|
|
998
1073
|
],
|
|
@@ -1001,20 +1076,20 @@
|
|
|
1001
1076
|
"kind": "js",
|
|
1002
1077
|
"name": "default",
|
|
1003
1078
|
"declaration": {
|
|
1004
|
-
"name": "
|
|
1005
|
-
"module": "src/
|
|
1079
|
+
"name": "Banner",
|
|
1080
|
+
"module": "src/banner/Banner.ts"
|
|
1006
1081
|
}
|
|
1007
1082
|
},
|
|
1008
1083
|
{
|
|
1009
1084
|
"kind": "custom-element-definition",
|
|
1010
|
-
"name": "nord-
|
|
1085
|
+
"name": "nord-banner",
|
|
1011
1086
|
"declaration": {
|
|
1012
|
-
"name": "
|
|
1013
|
-
"module": "src/
|
|
1087
|
+
"name": "Banner",
|
|
1088
|
+
"module": "src/banner/Banner.ts"
|
|
1014
1089
|
}
|
|
1015
1090
|
}
|
|
1016
1091
|
],
|
|
1017
|
-
"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-
|
|
1092
|
+
"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"
|
|
1018
1093
|
},
|
|
1019
1094
|
{
|
|
1020
1095
|
"kind": "javascript-module",
|
|
@@ -1087,140 +1162,125 @@
|
|
|
1087
1162
|
},
|
|
1088
1163
|
{
|
|
1089
1164
|
"kind": "javascript-module",
|
|
1090
|
-
"path": "src/
|
|
1165
|
+
"path": "src/button/Button.ts",
|
|
1091
1166
|
"declarations": [
|
|
1092
1167
|
{
|
|
1093
1168
|
"kind": "class",
|
|
1094
|
-
"description": "
|
|
1095
|
-
"name": "
|
|
1096
|
-
"
|
|
1169
|
+
"description": "Buttons are used for interface actions. Primary style should be\nused only once per section for main call-to-action, while other\nstyles can appear more frequently.",
|
|
1170
|
+
"name": "Button",
|
|
1171
|
+
"slots": [
|
|
1097
1172
|
{
|
|
1098
|
-
"
|
|
1099
|
-
"name": "
|
|
1100
|
-
"type": {
|
|
1101
|
-
"text": "string"
|
|
1102
|
-
},
|
|
1103
|
-
"privacy": "private",
|
|
1104
|
-
"default": "\"dialog-header\""
|
|
1173
|
+
"description": "The button content",
|
|
1174
|
+
"name": ""
|
|
1105
1175
|
},
|
|
1106
1176
|
{
|
|
1107
|
-
"
|
|
1108
|
-
"name": "
|
|
1109
|
-
"type": {
|
|
1110
|
-
"text": "HTMLElement"
|
|
1111
|
-
},
|
|
1112
|
-
"privacy": "private"
|
|
1177
|
+
"description": "Used to place content at the start of button text. Typically used for icons.",
|
|
1178
|
+
"name": "start"
|
|
1113
1179
|
},
|
|
1180
|
+
{
|
|
1181
|
+
"description": "Used to place content at the end of button text. Typically used for icons.",
|
|
1182
|
+
"name": "end"
|
|
1183
|
+
}
|
|
1184
|
+
],
|
|
1185
|
+
"members": [
|
|
1114
1186
|
{
|
|
1115
1187
|
"kind": "field",
|
|
1116
|
-
"name": "
|
|
1117
|
-
"type": {
|
|
1118
|
-
"text": "HTMLButtonElement"
|
|
1119
|
-
},
|
|
1188
|
+
"name": "buttonRef",
|
|
1120
1189
|
"privacy": "private"
|
|
1121
1190
|
},
|
|
1122
1191
|
{
|
|
1123
1192
|
"kind": "field",
|
|
1124
|
-
"name": "
|
|
1193
|
+
"name": "events",
|
|
1125
1194
|
"privacy": "private",
|
|
1126
|
-
"default": "new
|
|
1195
|
+
"default": "new EventController(this)"
|
|
1127
1196
|
},
|
|
1128
1197
|
{
|
|
1129
1198
|
"kind": "field",
|
|
1130
|
-
"name": "
|
|
1199
|
+
"name": "lightDom",
|
|
1131
1200
|
"privacy": "private",
|
|
1132
|
-
"default": "new
|
|
1133
|
-
},
|
|
1134
|
-
{
|
|
1135
|
-
"kind": "field",
|
|
1136
|
-
"name": "shortcuts",
|
|
1137
|
-
"privacy": "private"
|
|
1201
|
+
"default": "new LightDomController(this, {\n render: () => this.renderLightDom(),\n })"
|
|
1138
1202
|
},
|
|
1139
1203
|
{
|
|
1140
1204
|
"kind": "field",
|
|
1141
|
-
"name": "
|
|
1142
|
-
"
|
|
1143
|
-
|
|
1205
|
+
"name": "variant",
|
|
1206
|
+
"type": {
|
|
1207
|
+
"text": "\"default\" | \"primary\" | \"dashed\" | \"plain\" | \"danger\" | \"switch\""
|
|
1208
|
+
},
|
|
1209
|
+
"default": "\"default\"",
|
|
1210
|
+
"description": "The style variant of the button.",
|
|
1211
|
+
"attribute": "variant",
|
|
1212
|
+
"reflects": true
|
|
1144
1213
|
},
|
|
1145
1214
|
{
|
|
1146
1215
|
"kind": "field",
|
|
1147
|
-
"name": "
|
|
1148
|
-
"type": {
|
|
1149
|
-
"text": "Intl.DateTimeFormat"
|
|
1150
|
-
},
|
|
1151
|
-
"privacy": "private",
|
|
1152
|
-
"description": "Whilst dateAdapter is used for handling the formatting/parsing dates in the input,\nthese are used to format dates exclusively for the benefit of screen readers.\n\nWe prefer DateTimeFormat over date.toLocaleDateString, as the former has\nbetter performance when formatting large number of dates. See:\nhttps://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleDateString#Performance"
|
|
1153
|
-
},
|
|
1154
|
-
{
|
|
1155
|
-
"kind": "field",
|
|
1156
|
-
"name": "monthNames",
|
|
1157
|
-
"type": {
|
|
1158
|
-
"text": "string[]"
|
|
1159
|
-
},
|
|
1160
|
-
"privacy": "private"
|
|
1161
|
-
},
|
|
1162
|
-
{
|
|
1163
|
-
"kind": "field",
|
|
1164
|
-
"name": "monthNamesShort",
|
|
1216
|
+
"name": "type",
|
|
1165
1217
|
"type": {
|
|
1166
|
-
"text": "
|
|
1218
|
+
"text": "\"button\" | \"submit\" | \"reset\""
|
|
1167
1219
|
},
|
|
1168
|
-
"
|
|
1220
|
+
"default": "\"submit\"",
|
|
1221
|
+
"description": "The type of the button.",
|
|
1222
|
+
"attribute": "type",
|
|
1223
|
+
"reflects": true
|
|
1169
1224
|
},
|
|
1170
1225
|
{
|
|
1171
1226
|
"kind": "field",
|
|
1172
|
-
"name": "
|
|
1227
|
+
"name": "size",
|
|
1173
1228
|
"type": {
|
|
1174
|
-
"text": "
|
|
1229
|
+
"text": "\"s\" | \"m\" | \"l\""
|
|
1175
1230
|
},
|
|
1176
|
-
"
|
|
1231
|
+
"default": "\"m\"",
|
|
1232
|
+
"description": "The size of the button.\nThis affects font-size and padding.",
|
|
1233
|
+
"attribute": "size",
|
|
1234
|
+
"reflects": true
|
|
1177
1235
|
},
|
|
1178
1236
|
{
|
|
1179
1237
|
"kind": "field",
|
|
1180
|
-
"name": "
|
|
1238
|
+
"name": "accessibleExpanded",
|
|
1181
1239
|
"type": {
|
|
1182
|
-
"text": "
|
|
1240
|
+
"text": "\"true\" | \"false\" | undefined"
|
|
1183
1241
|
},
|
|
1184
|
-
"privacy": "private"
|
|
1242
|
+
"privacy": "private",
|
|
1243
|
+
"attribute": "aria-expanded"
|
|
1185
1244
|
},
|
|
1186
1245
|
{
|
|
1187
1246
|
"kind": "field",
|
|
1188
|
-
"name": "
|
|
1247
|
+
"name": "accessibleHasPopup",
|
|
1189
1248
|
"type": {
|
|
1190
|
-
"text": "
|
|
1249
|
+
"text": "| \"false\"\n | \"true\"\n | \"menu\"\n | \"listbox\"\n | \"tree\"\n | \"grid\"\n | \"dialog\" | undefined"
|
|
1191
1250
|
},
|
|
1192
|
-
"
|
|
1193
|
-
"
|
|
1194
|
-
"attribute": "value"
|
|
1251
|
+
"privacy": "private",
|
|
1252
|
+
"attribute": "aria-haspopup"
|
|
1195
1253
|
},
|
|
1196
1254
|
{
|
|
1197
1255
|
"kind": "field",
|
|
1198
|
-
"name": "
|
|
1256
|
+
"name": "href",
|
|
1199
1257
|
"type": {
|
|
1200
|
-
"text": "
|
|
1258
|
+
"text": "string | undefined"
|
|
1201
1259
|
},
|
|
1202
|
-
"description": "
|
|
1203
|
-
"attribute": "
|
|
1260
|
+
"description": "When provided, renders the button as a link,\nwith its href attribute set to the given value.",
|
|
1261
|
+
"attribute": "href",
|
|
1262
|
+
"reflects": true
|
|
1204
1263
|
},
|
|
1205
1264
|
{
|
|
1206
1265
|
"kind": "field",
|
|
1207
|
-
"name": "
|
|
1266
|
+
"name": "download",
|
|
1208
1267
|
"type": {
|
|
1209
|
-
"text": "
|
|
1268
|
+
"text": "boolean"
|
|
1210
1269
|
},
|
|
1211
|
-
"default": "
|
|
1212
|
-
"description": "
|
|
1213
|
-
"attribute": "
|
|
1270
|
+
"default": "false",
|
|
1271
|
+
"description": "When provided together with a href property, the button will\ntrigger a file download instead of a page visit.",
|
|
1272
|
+
"attribute": "download"
|
|
1214
1273
|
},
|
|
1215
1274
|
{
|
|
1216
1275
|
"kind": "field",
|
|
1217
|
-
"name": "
|
|
1276
|
+
"name": "target",
|
|
1218
1277
|
"type": {
|
|
1219
|
-
"text": "
|
|
1278
|
+
"text": "\"_self\" | \"_blank\" | \"_parent\" | \"_top\""
|
|
1220
1279
|
},
|
|
1221
|
-
"default": "\"\"",
|
|
1222
|
-
"description": "
|
|
1223
|
-
"attribute": "
|
|
1280
|
+
"default": "\"_self\"",
|
|
1281
|
+
"description": "When provided together with a href property, determines where\nto open the linked URL. The keywords have special meanings for\nwhere to load the URL: “_self” means the current browsing context,\n“_blank” usually a new tab but users can configure browsers this to\nopen a new window instead, “_parent” means the parent browsing\ncontext of the current one, but if no parent exists, behaves as\n_self, and finally “top” means the topmost browsing context.",
|
|
1282
|
+
"attribute": "target",
|
|
1283
|
+
"reflects": true
|
|
1224
1284
|
},
|
|
1225
1285
|
{
|
|
1226
1286
|
"kind": "field",
|
|
@@ -1229,239 +1289,231 @@
|
|
|
1229
1289
|
"text": "boolean"
|
|
1230
1290
|
},
|
|
1231
1291
|
"default": "false",
|
|
1232
|
-
"description": "Controls whether the
|
|
1292
|
+
"description": "Controls whether the button expands to fill the width of its container.",
|
|
1233
1293
|
"attribute": "expand",
|
|
1234
1294
|
"reflects": true
|
|
1235
1295
|
},
|
|
1236
|
-
{
|
|
1237
|
-
"kind": "field",
|
|
1238
|
-
"name": "isDateDisabled",
|
|
1239
|
-
"type": {
|
|
1240
|
-
"text": "DateDisabledPredicate"
|
|
1241
|
-
},
|
|
1242
|
-
"default": "isDateDisabled",
|
|
1243
|
-
"description": "Controls which days are disabled and therefore disallowed.\nFor example, this can be used to disallow selection of weekends."
|
|
1244
|
-
},
|
|
1245
|
-
{
|
|
1246
|
-
"kind": "field",
|
|
1247
|
-
"name": "activeFocus",
|
|
1248
|
-
"type": {
|
|
1249
|
-
"text": "boolean"
|
|
1250
|
-
},
|
|
1251
|
-
"privacy": "private",
|
|
1252
|
-
"default": "false"
|
|
1253
|
-
},
|
|
1254
|
-
{
|
|
1255
|
-
"kind": "field",
|
|
1256
|
-
"name": "focusedDay",
|
|
1257
|
-
"privacy": "private",
|
|
1258
|
-
"default": "new Date()"
|
|
1259
|
-
},
|
|
1260
|
-
{
|
|
1261
|
-
"kind": "method",
|
|
1262
|
-
"name": "focus",
|
|
1263
|
-
"parameters": [
|
|
1264
|
-
{
|
|
1265
|
-
"name": "options",
|
|
1266
|
-
"optional": true,
|
|
1267
|
-
"type": {
|
|
1268
|
-
"text": "FocusOptions & { target: \"day\" | \"month\" }"
|
|
1269
|
-
},
|
|
1270
|
-
"description": "An object which controls aspects of the focusing process."
|
|
1271
|
-
}
|
|
1272
|
-
],
|
|
1273
|
-
"description": "Programmatically move focus to the calendar."
|
|
1274
|
-
},
|
|
1275
|
-
{
|
|
1276
|
-
"kind": "method",
|
|
1277
|
-
"name": "handleValueChange",
|
|
1278
|
-
"privacy": "protected"
|
|
1279
|
-
},
|
|
1280
|
-
{
|
|
1281
|
-
"kind": "method",
|
|
1282
|
-
"name": "handleFocusedDayChange",
|
|
1283
|
-
"privacy": "protected"
|
|
1284
|
-
},
|
|
1285
|
-
{
|
|
1286
|
-
"kind": "method",
|
|
1287
|
-
"name": "handleLangChange",
|
|
1288
|
-
"privacy": "private"
|
|
1289
|
-
},
|
|
1290
|
-
{
|
|
1291
|
-
"kind": "field",
|
|
1292
|
-
"name": "handleDaySelect",
|
|
1293
|
-
"privacy": "private"
|
|
1294
|
-
},
|
|
1295
|
-
{
|
|
1296
|
-
"kind": "method",
|
|
1297
|
-
"name": "addDays",
|
|
1298
|
-
"privacy": "private",
|
|
1299
|
-
"parameters": [
|
|
1300
|
-
{
|
|
1301
|
-
"name": "days",
|
|
1302
|
-
"type": {
|
|
1303
|
-
"text": "number"
|
|
1304
|
-
}
|
|
1305
|
-
}
|
|
1306
|
-
]
|
|
1307
|
-
},
|
|
1308
1296
|
{
|
|
1309
1297
|
"kind": "method",
|
|
1310
|
-
"name": "
|
|
1298
|
+
"name": "renderLink",
|
|
1311
1299
|
"privacy": "private",
|
|
1312
1300
|
"parameters": [
|
|
1313
1301
|
{
|
|
1314
|
-
"name": "
|
|
1302
|
+
"name": "innards",
|
|
1315
1303
|
"type": {
|
|
1316
|
-
"text": "
|
|
1304
|
+
"text": "TemplateResult"
|
|
1317
1305
|
}
|
|
1318
1306
|
}
|
|
1319
|
-
]
|
|
1307
|
+
],
|
|
1308
|
+
"description": "We jump through some hoops here to ensure the link is treated correctly when \"disabled\".\nLinks cannot be disabled natively, so we need to rely on some aria magic to get the correct semantics.\nAlong with the advice in the article below, we also set tabindex to \"-1\", so it is taken out of tab order."
|
|
1320
1309
|
},
|
|
1321
1310
|
{
|
|
1322
1311
|
"kind": "method",
|
|
1323
|
-
"name": "
|
|
1312
|
+
"name": "renderButton",
|
|
1324
1313
|
"privacy": "private",
|
|
1325
1314
|
"parameters": [
|
|
1326
1315
|
{
|
|
1327
|
-
"name": "
|
|
1316
|
+
"name": "innards",
|
|
1328
1317
|
"type": {
|
|
1329
|
-
"text": "
|
|
1318
|
+
"text": "TemplateResult"
|
|
1330
1319
|
}
|
|
1331
1320
|
}
|
|
1332
1321
|
]
|
|
1333
1322
|
},
|
|
1334
1323
|
{
|
|
1335
1324
|
"kind": "method",
|
|
1336
|
-
"name": "
|
|
1325
|
+
"name": "renderLightDom",
|
|
1337
1326
|
"privacy": "private"
|
|
1338
1327
|
},
|
|
1339
1328
|
{
|
|
1340
|
-
"kind": "
|
|
1341
|
-
"name": "
|
|
1329
|
+
"kind": "field",
|
|
1330
|
+
"name": "handleOuterClick",
|
|
1342
1331
|
"privacy": "private"
|
|
1343
1332
|
},
|
|
1344
1333
|
{
|
|
1345
1334
|
"kind": "method",
|
|
1346
|
-
"name": "
|
|
1335
|
+
"name": "handleClick",
|
|
1347
1336
|
"privacy": "private",
|
|
1348
1337
|
"parameters": [
|
|
1349
1338
|
{
|
|
1350
|
-
"name": "
|
|
1339
|
+
"name": "e",
|
|
1351
1340
|
"type": {
|
|
1352
|
-
"text": "
|
|
1341
|
+
"text": "Event"
|
|
1353
1342
|
}
|
|
1354
1343
|
}
|
|
1355
1344
|
]
|
|
1356
1345
|
},
|
|
1357
1346
|
{
|
|
1358
1347
|
"kind": "method",
|
|
1359
|
-
"name": "
|
|
1348
|
+
"name": "handleProxyChange",
|
|
1360
1349
|
"privacy": "private",
|
|
1361
|
-
"
|
|
1362
|
-
{
|
|
1363
|
-
"name": "year",
|
|
1364
|
-
"type": {
|
|
1365
|
-
"text": "number"
|
|
1366
|
-
}
|
|
1367
|
-
}
|
|
1368
|
-
]
|
|
1350
|
+
"description": "React/Vue etc may remove our proxy button when updating button text, since they are unaware of its existence.\nSo we listen for a slotchange event, and if the element is no longer connected to the DOM we add it back in."
|
|
1369
1351
|
},
|
|
1370
1352
|
{
|
|
1371
|
-
"kind": "
|
|
1372
|
-
"name": "
|
|
1373
|
-
"
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1353
|
+
"kind": "field",
|
|
1354
|
+
"name": "disabled",
|
|
1355
|
+
"type": {
|
|
1356
|
+
"text": "boolean"
|
|
1357
|
+
},
|
|
1358
|
+
"default": "false",
|
|
1359
|
+
"description": "Makes the component disabled. This prevents users from\nbeing able to interact with the component, and conveys\nits inactive state to assistive technologies.",
|
|
1360
|
+
"attribute": "disabled",
|
|
1361
|
+
"reflects": true,
|
|
1362
|
+
"inheritedFrom": {
|
|
1363
|
+
"name": "InputMixin",
|
|
1364
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
1365
|
+
}
|
|
1382
1366
|
},
|
|
1383
1367
|
{
|
|
1384
1368
|
"kind": "field",
|
|
1385
|
-
"name": "
|
|
1386
|
-
"
|
|
1369
|
+
"name": "name",
|
|
1370
|
+
"type": {
|
|
1371
|
+
"text": "string | undefined"
|
|
1372
|
+
},
|
|
1373
|
+
"description": "The name of the form component.",
|
|
1374
|
+
"attribute": "name",
|
|
1375
|
+
"inheritedFrom": {
|
|
1376
|
+
"name": "InputMixin",
|
|
1377
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
1378
|
+
}
|
|
1387
1379
|
},
|
|
1388
1380
|
{
|
|
1389
1381
|
"kind": "field",
|
|
1390
|
-
"name": "
|
|
1391
|
-
"
|
|
1382
|
+
"name": "value",
|
|
1383
|
+
"type": {
|
|
1384
|
+
"text": "string"
|
|
1385
|
+
},
|
|
1386
|
+
"default": "\"\"",
|
|
1387
|
+
"description": "The value of the form component.",
|
|
1388
|
+
"attribute": "value",
|
|
1389
|
+
"inheritedFrom": {
|
|
1390
|
+
"name": "InputMixin",
|
|
1391
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
1392
|
+
}
|
|
1392
1393
|
},
|
|
1393
1394
|
{
|
|
1394
1395
|
"kind": "field",
|
|
1395
|
-
"name": "
|
|
1396
|
-
"
|
|
1396
|
+
"name": "form",
|
|
1397
|
+
"description": "Gets the form, if any, associated with the form element.",
|
|
1398
|
+
"inheritedFrom": {
|
|
1399
|
+
"name": "InputMixin",
|
|
1400
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
1401
|
+
}
|
|
1397
1402
|
},
|
|
1398
1403
|
{
|
|
1399
1404
|
"kind": "field",
|
|
1400
|
-
"name": "
|
|
1401
|
-
"privacy": "
|
|
1405
|
+
"name": "focusableRef",
|
|
1406
|
+
"privacy": "protected",
|
|
1407
|
+
"inheritedFrom": {
|
|
1408
|
+
"name": "FocusableMixin",
|
|
1409
|
+
"module": "src/common/mixins/FocusableMixin.ts"
|
|
1410
|
+
}
|
|
1402
1411
|
},
|
|
1403
1412
|
{
|
|
1404
|
-
"kind": "
|
|
1405
|
-
"name": "
|
|
1406
|
-
"
|
|
1413
|
+
"kind": "method",
|
|
1414
|
+
"name": "focus",
|
|
1415
|
+
"parameters": [
|
|
1416
|
+
{
|
|
1417
|
+
"name": "options",
|
|
1418
|
+
"optional": true,
|
|
1419
|
+
"type": {
|
|
1420
|
+
"text": "FocusOptions"
|
|
1421
|
+
},
|
|
1422
|
+
"description": "An object which controls aspects of the focusing process."
|
|
1423
|
+
}
|
|
1424
|
+
],
|
|
1425
|
+
"description": "Programmatically move focus to the component.",
|
|
1426
|
+
"inheritedFrom": {
|
|
1427
|
+
"name": "FocusableMixin",
|
|
1428
|
+
"module": "src/common/mixins/FocusableMixin.ts"
|
|
1429
|
+
}
|
|
1407
1430
|
},
|
|
1408
1431
|
{
|
|
1409
|
-
"kind": "
|
|
1410
|
-
"name": "
|
|
1411
|
-
"
|
|
1432
|
+
"kind": "method",
|
|
1433
|
+
"name": "blur",
|
|
1434
|
+
"description": "Programmatically remove focus from the component.",
|
|
1435
|
+
"inheritedFrom": {
|
|
1436
|
+
"name": "FocusableMixin",
|
|
1437
|
+
"module": "src/common/mixins/FocusableMixin.ts"
|
|
1438
|
+
}
|
|
1439
|
+
},
|
|
1440
|
+
{
|
|
1441
|
+
"kind": "method",
|
|
1442
|
+
"name": "click",
|
|
1443
|
+
"description": "Programmatically simulates a click on the component.",
|
|
1444
|
+
"inheritedFrom": {
|
|
1445
|
+
"name": "FocusableMixin",
|
|
1446
|
+
"module": "src/common/mixins/FocusableMixin.ts"
|
|
1447
|
+
}
|
|
1412
1448
|
}
|
|
1413
1449
|
],
|
|
1414
|
-
"
|
|
1450
|
+
"attributes": [
|
|
1415
1451
|
{
|
|
1416
|
-
"name": "
|
|
1452
|
+
"name": "variant",
|
|
1417
1453
|
"type": {
|
|
1418
|
-
"text": "
|
|
1454
|
+
"text": "\"default\" | \"primary\" | \"dashed\" | \"plain\" | \"danger\" | \"switch\""
|
|
1419
1455
|
},
|
|
1420
|
-
"
|
|
1456
|
+
"default": "\"default\"",
|
|
1457
|
+
"description": "The style variant of the button.",
|
|
1458
|
+
"fieldName": "variant"
|
|
1421
1459
|
},
|
|
1422
1460
|
{
|
|
1461
|
+
"name": "type",
|
|
1423
1462
|
"type": {
|
|
1424
|
-
"text": "
|
|
1463
|
+
"text": "\"button\" | \"submit\" | \"reset\""
|
|
1425
1464
|
},
|
|
1426
|
-
"
|
|
1427
|
-
"
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
"attributes": [
|
|
1465
|
+
"default": "\"submit\"",
|
|
1466
|
+
"description": "The type of the button.",
|
|
1467
|
+
"fieldName": "type"
|
|
1468
|
+
},
|
|
1431
1469
|
{
|
|
1432
|
-
"name": "
|
|
1470
|
+
"name": "size",
|
|
1433
1471
|
"type": {
|
|
1434
|
-
"text": "
|
|
1472
|
+
"text": "\"s\" | \"m\" | \"l\""
|
|
1435
1473
|
},
|
|
1436
|
-
"default": "\"\"",
|
|
1437
|
-
"description": "The
|
|
1438
|
-
"fieldName": "
|
|
1474
|
+
"default": "\"m\"",
|
|
1475
|
+
"description": "The size of the button.\nThis affects font-size and padding.",
|
|
1476
|
+
"fieldName": "size"
|
|
1439
1477
|
},
|
|
1440
1478
|
{
|
|
1441
|
-
"name": "
|
|
1479
|
+
"name": "aria-expanded",
|
|
1442
1480
|
"type": {
|
|
1443
|
-
"text": "
|
|
1481
|
+
"text": "\"true\" | \"false\" | undefined"
|
|
1444
1482
|
},
|
|
1445
|
-
"
|
|
1446
|
-
"fieldName": "firstDayOfWeek"
|
|
1483
|
+
"fieldName": "accessibleExpanded"
|
|
1447
1484
|
},
|
|
1448
1485
|
{
|
|
1449
|
-
"name": "
|
|
1486
|
+
"name": "aria-haspopup",
|
|
1450
1487
|
"type": {
|
|
1451
|
-
"text": "
|
|
1488
|
+
"text": "| \"false\"\n | \"true\"\n | \"menu\"\n | \"listbox\"\n | \"tree\"\n | \"grid\"\n | \"dialog\" | undefined"
|
|
1452
1489
|
},
|
|
1453
|
-
"
|
|
1454
|
-
"description": "Minimum date allowed to be picked. Must be in IS0-8601 format: YYYY-MM-DD.\nThis setting can be used alone or together with the max property.",
|
|
1455
|
-
"fieldName": "min"
|
|
1490
|
+
"fieldName": "accessibleHasPopup"
|
|
1456
1491
|
},
|
|
1457
1492
|
{
|
|
1458
|
-
"name": "
|
|
1493
|
+
"name": "href",
|
|
1459
1494
|
"type": {
|
|
1460
|
-
"text": "string"
|
|
1495
|
+
"text": "string | undefined"
|
|
1461
1496
|
},
|
|
1462
|
-
"
|
|
1463
|
-
"
|
|
1464
|
-
|
|
1497
|
+
"description": "When provided, renders the button as a link,\nwith its href attribute set to the given value.",
|
|
1498
|
+
"fieldName": "href"
|
|
1499
|
+
},
|
|
1500
|
+
{
|
|
1501
|
+
"name": "download",
|
|
1502
|
+
"type": {
|
|
1503
|
+
"text": "boolean"
|
|
1504
|
+
},
|
|
1505
|
+
"default": "false",
|
|
1506
|
+
"description": "When provided together with a href property, the button will\ntrigger a file download instead of a page visit.",
|
|
1507
|
+
"fieldName": "download"
|
|
1508
|
+
},
|
|
1509
|
+
{
|
|
1510
|
+
"name": "target",
|
|
1511
|
+
"type": {
|
|
1512
|
+
"text": "\"_self\" | \"_blank\" | \"_parent\" | \"_top\""
|
|
1513
|
+
},
|
|
1514
|
+
"default": "\"_self\"",
|
|
1515
|
+
"description": "When provided together with a href property, determines where\nto open the linked URL. The keywords have special meanings for\nwhere to load the URL: “_self” means the current browsing context,\n“_blank” usually a new tab but users can configure browsers this to\nopen a new window instead, “_parent” means the parent browsing\ncontext of the current one, but if no parent exists, behaves as\n_self, and finally “top” means the topmost browsing context.",
|
|
1516
|
+
"fieldName": "target"
|
|
1465
1517
|
},
|
|
1466
1518
|
{
|
|
1467
1519
|
"name": "expand",
|
|
@@ -1469,140 +1521,88 @@
|
|
|
1469
1521
|
"text": "boolean"
|
|
1470
1522
|
},
|
|
1471
1523
|
"default": "false",
|
|
1472
|
-
"description": "Controls whether the
|
|
1524
|
+
"description": "Controls whether the button expands to fill the width of its container.",
|
|
1473
1525
|
"fieldName": "expand"
|
|
1474
|
-
}
|
|
1475
|
-
],
|
|
1476
|
-
"superclass": {
|
|
1477
|
-
"name": "LitElement",
|
|
1478
|
-
"package": "lit"
|
|
1479
|
-
},
|
|
1480
|
-
"status": "ready",
|
|
1481
|
-
"category": "list",
|
|
1482
|
-
"displayName": null,
|
|
1483
|
-
"tagName": "nord-calendar",
|
|
1484
|
-
"customElement": true
|
|
1485
|
-
}
|
|
1486
|
-
],
|
|
1487
|
-
"exports": [
|
|
1488
|
-
{
|
|
1489
|
-
"kind": "js",
|
|
1490
|
-
"name": "default",
|
|
1491
|
-
"declaration": {
|
|
1492
|
-
"name": "Calendar",
|
|
1493
|
-
"module": "src/calendar/Calendar.ts"
|
|
1494
|
-
}
|
|
1495
|
-
},
|
|
1496
|
-
{
|
|
1497
|
-
"kind": "custom-element-definition",
|
|
1498
|
-
"name": "nord-calendar",
|
|
1499
|
-
"declaration": {
|
|
1500
|
-
"name": "Calendar",
|
|
1501
|
-
"module": "src/calendar/Calendar.ts"
|
|
1502
|
-
}
|
|
1503
|
-
}
|
|
1504
|
-
],
|
|
1505
|
-
"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 when the user needs to choose a single date or a date range.\n- Close calendar after a single date is selected, unless a range with a start and end date is required.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for entering date of birth. Use input component instead.\n- Don’t use for choosing a date that is over 10 years in the future or the past.\n\n</div>\n\n---\n\n## Keyboard accessibility\n\nCalendar component is built to closely follow [W3C Date Picker Dialog example](https://www.w3.org/TR/wai-aria-practices/examples/dialog-modal/datepicker-dialog.html) with some small exceptions to e.g. better support iOS VoiceOver and Android TalkBack.\n\n### Month/year buttons\n\n- `Space, Enter`: Changes the month and/or year displayed.\n\n### Calendar grid\n\n- `Space, Enter`: Selects a date.\n- `Arrow up`: Moves focus to the same day of the previous week.\n- `Arrow down`: Moves focus to the same day of the next week.\n- `Arrow right`: Moves focus to the next day. In right-to-left languages, moves focus to the previous day.\n- `Arrow left`: Moves focus to the previous day. In right-to-left languages, moves focus to the next day.\n- `Home`: Moves focus to the first day (e.g Monday) of the current week.\n- `End`: Moves focus to the last day (e.g. Sunday) of the current week.\n- `Page Up`: Changes the grid of dates to the previous month and sets focus on the same day of the same week.\n- `Shift + Page Up`: Changes the grid of dates to the previous year and sets focus on the same day of the same week.\n- `Page Down`: Changes the grid of dates to the next month and sets focus on the same day of the same week.\n- `Shift + Page Down`: Changes the grid of dates to the next year and sets focus on the same day of the same week.\n"
|
|
1506
|
-
},
|
|
1507
|
-
{
|
|
1508
|
-
"kind": "javascript-module",
|
|
1509
|
-
"path": "src/calendar/DateSelectEvent.ts",
|
|
1510
|
-
"declarations": [
|
|
1511
|
-
{
|
|
1512
|
-
"kind": "class",
|
|
1513
|
-
"description": "",
|
|
1514
|
-
"name": "DateSelectEvent",
|
|
1515
|
-
"superclass": {
|
|
1516
|
-
"name": "NordEvent",
|
|
1517
|
-
"module": "/src/common/events.js"
|
|
1518
|
-
}
|
|
1519
|
-
}
|
|
1520
|
-
],
|
|
1521
|
-
"exports": [
|
|
1522
|
-
{
|
|
1523
|
-
"kind": "js",
|
|
1524
|
-
"name": "DateSelectEvent",
|
|
1525
|
-
"declaration": {
|
|
1526
|
-
"name": "DateSelectEvent",
|
|
1527
|
-
"module": "src/calendar/DateSelectEvent.ts"
|
|
1528
|
-
}
|
|
1529
|
-
}
|
|
1530
|
-
],
|
|
1531
|
-
"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 when the user needs to choose a single date or a date range.\n- Close calendar after a single date is selected, unless a range with a start and end date is required.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for entering date of birth. Use input component instead.\n- Don’t use for choosing a date that is over 10 years in the future or the past.\n\n</div>\n\n---\n\n## Keyboard accessibility\n\nCalendar component is built to closely follow [W3C Date Picker Dialog example](https://www.w3.org/TR/wai-aria-practices/examples/dialog-modal/datepicker-dialog.html) with some small exceptions to e.g. better support iOS VoiceOver and Android TalkBack.\n\n### Month/year buttons\n\n- `Space, Enter`: Changes the month and/or year displayed.\n\n### Calendar grid\n\n- `Space, Enter`: Selects a date.\n- `Arrow up`: Moves focus to the same day of the previous week.\n- `Arrow down`: Moves focus to the same day of the next week.\n- `Arrow right`: Moves focus to the next day. In right-to-left languages, moves focus to the previous day.\n- `Arrow left`: Moves focus to the previous day. In right-to-left languages, moves focus to the next day.\n- `Home`: Moves focus to the first day (e.g Monday) of the current week.\n- `End`: Moves focus to the last day (e.g. Sunday) of the current week.\n- `Page Up`: Changes the grid of dates to the previous month and sets focus on the same day of the same week.\n- `Shift + Page Up`: Changes the grid of dates to the previous year and sets focus on the same day of the same week.\n- `Page Down`: Changes the grid of dates to the next month and sets focus on the same day of the same week.\n- `Shift + Page Down`: Changes the grid of dates to the next year and sets focus on the same day of the same week.\n"
|
|
1532
|
-
},
|
|
1533
|
-
{
|
|
1534
|
-
"kind": "javascript-module",
|
|
1535
|
-
"path": "src/calendar/localization.ts",
|
|
1536
|
-
"declarations": [
|
|
1537
|
-
{
|
|
1538
|
-
"kind": "variable",
|
|
1539
|
-
"name": "calendarLocalization",
|
|
1540
|
-
"type": {
|
|
1541
|
-
"text": "object"
|
|
1542
|
-
},
|
|
1543
|
-
"default": "{\n prevMonthLabel: \"Previous month\",\n nextMonthLabel: \"Next month\",\n monthSelectLabel: \"Month\",\n yearSelectLabel: \"Year\",\n}"
|
|
1544
|
-
}
|
|
1545
|
-
],
|
|
1546
|
-
"exports": [
|
|
1547
|
-
{
|
|
1548
|
-
"kind": "js",
|
|
1549
|
-
"name": "default",
|
|
1550
|
-
"declaration": {
|
|
1551
|
-
"name": "calendarLocalization",
|
|
1552
|
-
"module": "src/calendar/localization.ts"
|
|
1553
|
-
}
|
|
1554
|
-
}
|
|
1555
|
-
],
|
|
1556
|
-
"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 when the user needs to choose a single date or a date range.\n- Close calendar after a single date is selected, unless a range with a start and end date is required.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for entering date of birth. Use input component instead.\n- Don’t use for choosing a date that is over 10 years in the future or the past.\n\n</div>\n\n---\n\n## Keyboard accessibility\n\nCalendar component is built to closely follow [W3C Date Picker Dialog example](https://www.w3.org/TR/wai-aria-practices/examples/dialog-modal/datepicker-dialog.html) with some small exceptions to e.g. better support iOS VoiceOver and Android TalkBack.\n\n### Month/year buttons\n\n- `Space, Enter`: Changes the month and/or year displayed.\n\n### Calendar grid\n\n- `Space, Enter`: Selects a date.\n- `Arrow up`: Moves focus to the same day of the previous week.\n- `Arrow down`: Moves focus to the same day of the next week.\n- `Arrow right`: Moves focus to the next day. In right-to-left languages, moves focus to the previous day.\n- `Arrow left`: Moves focus to the previous day. In right-to-left languages, moves focus to the next day.\n- `Home`: Moves focus to the first day (e.g Monday) of the current week.\n- `End`: Moves focus to the last day (e.g. Sunday) of the current week.\n- `Page Up`: Changes the grid of dates to the previous month and sets focus on the same day of the same week.\n- `Shift + Page Up`: Changes the grid of dates to the previous year and sets focus on the same day of the same week.\n- `Page Down`: Changes the grid of dates to the next month and sets focus on the same day of the same week.\n- `Shift + Page Down`: Changes the grid of dates to the next year and sets focus on the same day of the same week.\n"
|
|
1557
|
-
},
|
|
1558
|
-
{
|
|
1559
|
-
"kind": "javascript-module",
|
|
1560
|
-
"path": "src/calendar/month-view.ts",
|
|
1561
|
-
"declarations": [
|
|
1562
|
-
{
|
|
1563
|
-
"kind": "function",
|
|
1564
|
-
"name": "dayView",
|
|
1565
|
-
"parameters": [
|
|
1526
|
+
},
|
|
1566
1527
|
{
|
|
1567
|
-
"name": "
|
|
1528
|
+
"name": "disabled",
|
|
1568
1529
|
"type": {
|
|
1569
|
-
"text": "
|
|
1530
|
+
"text": "boolean"
|
|
1531
|
+
},
|
|
1532
|
+
"default": "false",
|
|
1533
|
+
"description": "Makes the component disabled. This prevents users from\nbeing able to interact with the component, and conveys\nits inactive state to assistive technologies.",
|
|
1534
|
+
"fieldName": "disabled",
|
|
1535
|
+
"inheritedFrom": {
|
|
1536
|
+
"name": "InputMixin",
|
|
1537
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
1570
1538
|
}
|
|
1571
|
-
}
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1539
|
+
},
|
|
1540
|
+
{
|
|
1541
|
+
"name": "name",
|
|
1542
|
+
"type": {
|
|
1543
|
+
"text": "string | undefined"
|
|
1544
|
+
},
|
|
1545
|
+
"description": "The name of the form component.",
|
|
1546
|
+
"fieldName": "name",
|
|
1547
|
+
"inheritedFrom": {
|
|
1548
|
+
"name": "InputMixin",
|
|
1549
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
1550
|
+
}
|
|
1551
|
+
},
|
|
1578
1552
|
{
|
|
1579
|
-
"name": "
|
|
1553
|
+
"name": "value",
|
|
1580
1554
|
"type": {
|
|
1581
|
-
"text": "
|
|
1555
|
+
"text": "string"
|
|
1556
|
+
},
|
|
1557
|
+
"default": "\"\"",
|
|
1558
|
+
"description": "The value of the form component.",
|
|
1559
|
+
"fieldName": "value",
|
|
1560
|
+
"inheritedFrom": {
|
|
1561
|
+
"name": "InputMixin",
|
|
1562
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
1582
1563
|
}
|
|
1583
1564
|
}
|
|
1584
|
-
]
|
|
1565
|
+
],
|
|
1566
|
+
"mixins": [
|
|
1567
|
+
{
|
|
1568
|
+
"name": "InputMixin",
|
|
1569
|
+
"module": "/src/common/mixins/InputMixin.js"
|
|
1570
|
+
},
|
|
1571
|
+
{
|
|
1572
|
+
"name": "FocusableMixin",
|
|
1573
|
+
"module": "/src/common/mixins/FocusableMixin.js"
|
|
1574
|
+
}
|
|
1575
|
+
],
|
|
1576
|
+
"superclass": {
|
|
1577
|
+
"name": "LitElement",
|
|
1578
|
+
"package": "lit"
|
|
1579
|
+
},
|
|
1580
|
+
"status": "ready",
|
|
1581
|
+
"category": "action",
|
|
1582
|
+
"displayName": null,
|
|
1583
|
+
"tagName": "nord-button",
|
|
1584
|
+
"customElement": true
|
|
1585
1585
|
}
|
|
1586
1586
|
],
|
|
1587
1587
|
"exports": [
|
|
1588
1588
|
{
|
|
1589
1589
|
"kind": "js",
|
|
1590
|
-
"name": "
|
|
1590
|
+
"name": "default",
|
|
1591
1591
|
"declaration": {
|
|
1592
|
-
"name": "
|
|
1593
|
-
"module": "src/
|
|
1592
|
+
"name": "Button",
|
|
1593
|
+
"module": "src/button/Button.ts"
|
|
1594
1594
|
}
|
|
1595
1595
|
},
|
|
1596
1596
|
{
|
|
1597
|
-
"kind": "
|
|
1598
|
-
"name": "
|
|
1597
|
+
"kind": "custom-element-definition",
|
|
1598
|
+
"name": "nord-button",
|
|
1599
1599
|
"declaration": {
|
|
1600
|
-
"name": "
|
|
1601
|
-
"module": "src/
|
|
1600
|
+
"name": "Button",
|
|
1601
|
+
"module": "src/button/Button.ts"
|
|
1602
1602
|
}
|
|
1603
1603
|
}
|
|
1604
1604
|
],
|
|
1605
|
-
"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-
|
|
1605
|
+
"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- Only use one primary button per section, as a main call-to-action.\n- Use clear and accurate labels.\n- Use established button colors appropriately. For example, only use a danger button style for an action that’s difficult or impossible to undo.\n- Prioritize the most important actions. Too many buttons will cause confusion.\n- Be consistent with positioning of buttons in the user interface.\n- Use strong, actionable verbs in labels such as “Add”, “Close”, “Cancel”, or “Save”.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don't use a primary button in every row of a table.\n- Don’t use buttons to link to other pages. Use regular link or a plain style instead where necessary.\n- Don’t use buttons for navigation where the link appears within or following a sentence.\n- Don’t use labels such as “Read more”, “Click here” or “More”.\n\n</div>\n\n---\n\n## Content guidelines\n\nButton 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\">View user settings</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\n---\n\n## Variants\n\nThis section describes the different component variants, their purpose, and when to use each variant.\n\n| Name | Purpose |\n| ---------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `default` | Default style is the most common button variant. Only switch to another variant if you need to adjust the visual weight of the element. |\n| `primary` | Primary style is reserved for main call-to-actions. Should be used only once per content area or panel, e.g. for a “Save” action. |\n| `dashed` | Dashed style should be used for actions that trigger filtering. |\n| `danger` | Danger style should be used for actions that delete data or otherwise make it hard to undo the action. |\n| `plain` | Used for less important or less common actions. Can be also used for linking to other pages. |\n| `disabled` | Used for actions that aren’t currently available or not available anymore. Also prevents users from being able to interact with the component, and conveys its inactive state to assistive technologies. |\n| `switch` | Switch style is reserved for the clinic switcher in the top left corner of an application. |\n\n---\n\n## Additional considerations\n\n- Users of assistive technology expect a button to submit data or do an action. If you need the button to navigate into another view, use the `href` property which will output `<a>` tag instead of a `<button>`.\n- When you need to disable a button, use `disabled` property as it conveys this information correctly to assistive technologies like screen readers.\n- Button component provides 3 size variants; small, medium and large. The large size should only be used for marketing purposes or on areas such as an empty space/content notice.\n"
|
|
1606
1606
|
},
|
|
1607
1607
|
{
|
|
1608
1608
|
"kind": "javascript-module",
|
|
@@ -7859,21 +7859,228 @@
|
|
|
7859
7859
|
"fieldName": "href"
|
|
7860
7860
|
},
|
|
7861
7861
|
{
|
|
7862
|
-
"name": "badge",
|
|
7862
|
+
"name": "badge",
|
|
7863
|
+
"type": {
|
|
7864
|
+
"text": "string | undefined"
|
|
7865
|
+
},
|
|
7866
|
+
"description": "Allows you to add a notification badge with a number next to the nav item.",
|
|
7867
|
+
"fieldName": "badge"
|
|
7868
|
+
},
|
|
7869
|
+
{
|
|
7870
|
+
"name": "open",
|
|
7871
|
+
"type": {
|
|
7872
|
+
"text": "boolean"
|
|
7873
|
+
},
|
|
7874
|
+
"default": "false",
|
|
7875
|
+
"description": "When the nav items contains a subnav, controls whether the section is expanded or not.\nNote: this is only used if you have nested navigation using the \"subnav\" slot.",
|
|
7876
|
+
"fieldName": "open"
|
|
7877
|
+
}
|
|
7878
|
+
],
|
|
7879
|
+
"mixins": [
|
|
7880
|
+
{
|
|
7881
|
+
"name": "FocusableMixin",
|
|
7882
|
+
"module": "/src/common/mixins/FocusableMixin.js"
|
|
7883
|
+
}
|
|
7884
|
+
],
|
|
7885
|
+
"superclass": {
|
|
7886
|
+
"name": "LitElement",
|
|
7887
|
+
"package": "lit"
|
|
7888
|
+
},
|
|
7889
|
+
"status": "ready",
|
|
7890
|
+
"category": "navigation",
|
|
7891
|
+
"displayName": null,
|
|
7892
|
+
"tagName": "nord-nav-item",
|
|
7893
|
+
"customElement": true
|
|
7894
|
+
}
|
|
7895
|
+
],
|
|
7896
|
+
"exports": [
|
|
7897
|
+
{
|
|
7898
|
+
"kind": "js",
|
|
7899
|
+
"name": "default",
|
|
7900
|
+
"declaration": {
|
|
7901
|
+
"name": "NavItem",
|
|
7902
|
+
"module": "src/nav-item/NavItem.ts"
|
|
7903
|
+
}
|
|
7904
|
+
},
|
|
7905
|
+
{
|
|
7906
|
+
"kind": "custom-element-definition",
|
|
7907
|
+
"name": "nord-nav-item",
|
|
7908
|
+
"declaration": {
|
|
7909
|
+
"name": "NavItem",
|
|
7910
|
+
"module": "src/nav-item/NavItem.ts"
|
|
7911
|
+
}
|
|
7912
|
+
}
|
|
7913
|
+
],
|
|
7914
|
+
"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- 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 use navigation item outside of navigation group and navigation components.\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"
|
|
7915
|
+
},
|
|
7916
|
+
{
|
|
7917
|
+
"kind": "javascript-module",
|
|
7918
|
+
"path": "src/navigation/Navigation.ts",
|
|
7919
|
+
"declarations": [
|
|
7920
|
+
{
|
|
7921
|
+
"kind": "class",
|
|
7922
|
+
"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.",
|
|
7923
|
+
"name": "Navigation",
|
|
7924
|
+
"slots": [
|
|
7925
|
+
{
|
|
7926
|
+
"description": "The main section of the sidebar, for holding nav components.",
|
|
7927
|
+
"name": ""
|
|
7928
|
+
},
|
|
7929
|
+
{
|
|
7930
|
+
"description": "The top section of the sidebar.",
|
|
7931
|
+
"name": "header"
|
|
7932
|
+
},
|
|
7933
|
+
{
|
|
7934
|
+
"description": "The bottom section of the sidebar.",
|
|
7935
|
+
"name": "footer"
|
|
7936
|
+
}
|
|
7937
|
+
],
|
|
7938
|
+
"members": [],
|
|
7939
|
+
"superclass": {
|
|
7940
|
+
"name": "LitElement",
|
|
7941
|
+
"package": "lit"
|
|
7942
|
+
},
|
|
7943
|
+
"status": "ready",
|
|
7944
|
+
"category": "navigation",
|
|
7945
|
+
"displayName": null,
|
|
7946
|
+
"tagName": "nord-navigation",
|
|
7947
|
+
"customElement": true
|
|
7948
|
+
}
|
|
7949
|
+
],
|
|
7950
|
+
"exports": [
|
|
7951
|
+
{
|
|
7952
|
+
"kind": "js",
|
|
7953
|
+
"name": "default",
|
|
7954
|
+
"declaration": {
|
|
7955
|
+
"name": "Navigation",
|
|
7956
|
+
"module": "src/navigation/Navigation.ts"
|
|
7957
|
+
}
|
|
7958
|
+
},
|
|
7959
|
+
{
|
|
7960
|
+
"kind": "custom-element-definition",
|
|
7961
|
+
"name": "nord-navigation",
|
|
7962
|
+
"declaration": {
|
|
7963
|
+
"name": "Navigation",
|
|
7964
|
+
"module": "src/navigation/Navigation.ts"
|
|
7965
|
+
}
|
|
7966
|
+
}
|
|
7967
|
+
],
|
|
7968
|
+
"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"
|
|
7969
|
+
},
|
|
7970
|
+
{
|
|
7971
|
+
"kind": "javascript-module",
|
|
7972
|
+
"path": "src/progress-bar/ProgressBar.ts",
|
|
7973
|
+
"declarations": [
|
|
7974
|
+
{
|
|
7975
|
+
"kind": "class",
|
|
7976
|
+
"description": "Progress Bar is used to visually represent the completion\nof a task or process. It shows how much of the task has\nbeen completed and how much is still left.",
|
|
7977
|
+
"name": "ProgressBar",
|
|
7978
|
+
"members": [
|
|
7979
|
+
{
|
|
7980
|
+
"kind": "field",
|
|
7981
|
+
"name": "value",
|
|
7982
|
+
"type": {
|
|
7983
|
+
"text": "number | undefined"
|
|
7984
|
+
},
|
|
7985
|
+
"description": "Specifies how much of the task has been completed. Must be a valid floating\npoint number between 0 and max, or between 0 and 100 if max is omitted. If\nthere is no value, the progress bar is indeterminate; this indicates that\nan activity is ongoing with no indication of how long it’s expected to take.",
|
|
7986
|
+
"attribute": "value",
|
|
7987
|
+
"reflects": true
|
|
7988
|
+
},
|
|
7989
|
+
{
|
|
7990
|
+
"kind": "field",
|
|
7991
|
+
"name": "max",
|
|
7992
|
+
"type": {
|
|
7993
|
+
"text": "number"
|
|
7994
|
+
},
|
|
7995
|
+
"default": "100",
|
|
7996
|
+
"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.",
|
|
7997
|
+
"attribute": "max",
|
|
7998
|
+
"reflects": true
|
|
7999
|
+
},
|
|
8000
|
+
{
|
|
8001
|
+
"kind": "field",
|
|
8002
|
+
"name": "label",
|
|
8003
|
+
"type": {
|
|
8004
|
+
"text": "string"
|
|
8005
|
+
},
|
|
8006
|
+
"default": "\"Current progress\"",
|
|
8007
|
+
"description": "Accessible label for the progress indicator. Visually hidden, but shown\nfor assistive technology.",
|
|
8008
|
+
"attribute": "label",
|
|
8009
|
+
"reflects": true
|
|
8010
|
+
},
|
|
8011
|
+
{
|
|
8012
|
+
"kind": "field",
|
|
8013
|
+
"name": "focusableRef",
|
|
8014
|
+
"privacy": "protected",
|
|
8015
|
+
"inheritedFrom": {
|
|
8016
|
+
"name": "FocusableMixin",
|
|
8017
|
+
"module": "src/common/mixins/FocusableMixin.ts"
|
|
8018
|
+
}
|
|
8019
|
+
},
|
|
8020
|
+
{
|
|
8021
|
+
"kind": "method",
|
|
8022
|
+
"name": "focus",
|
|
8023
|
+
"parameters": [
|
|
8024
|
+
{
|
|
8025
|
+
"name": "options",
|
|
8026
|
+
"optional": true,
|
|
8027
|
+
"type": {
|
|
8028
|
+
"text": "FocusOptions"
|
|
8029
|
+
},
|
|
8030
|
+
"description": "An object which controls aspects of the focusing process."
|
|
8031
|
+
}
|
|
8032
|
+
],
|
|
8033
|
+
"description": "Programmatically move focus to the component.",
|
|
8034
|
+
"inheritedFrom": {
|
|
8035
|
+
"name": "FocusableMixin",
|
|
8036
|
+
"module": "src/common/mixins/FocusableMixin.ts"
|
|
8037
|
+
}
|
|
8038
|
+
},
|
|
8039
|
+
{
|
|
8040
|
+
"kind": "method",
|
|
8041
|
+
"name": "blur",
|
|
8042
|
+
"description": "Programmatically remove focus from the component.",
|
|
8043
|
+
"inheritedFrom": {
|
|
8044
|
+
"name": "FocusableMixin",
|
|
8045
|
+
"module": "src/common/mixins/FocusableMixin.ts"
|
|
8046
|
+
}
|
|
8047
|
+
},
|
|
8048
|
+
{
|
|
8049
|
+
"kind": "method",
|
|
8050
|
+
"name": "click",
|
|
8051
|
+
"description": "Programmatically simulates a click on the component.",
|
|
8052
|
+
"inheritedFrom": {
|
|
8053
|
+
"name": "FocusableMixin",
|
|
8054
|
+
"module": "src/common/mixins/FocusableMixin.ts"
|
|
8055
|
+
}
|
|
8056
|
+
}
|
|
8057
|
+
],
|
|
8058
|
+
"attributes": [
|
|
8059
|
+
{
|
|
8060
|
+
"name": "value",
|
|
8061
|
+
"type": {
|
|
8062
|
+
"text": "number | undefined"
|
|
8063
|
+
},
|
|
8064
|
+
"description": "Specifies how much of the task has been completed. Must be a valid floating\npoint number between 0 and max, or between 0 and 100 if max is omitted. If\nthere is no value, the progress bar is indeterminate; this indicates that\nan activity is ongoing with no indication of how long it’s expected to take.",
|
|
8065
|
+
"fieldName": "value"
|
|
8066
|
+
},
|
|
8067
|
+
{
|
|
8068
|
+
"name": "max",
|
|
7863
8069
|
"type": {
|
|
7864
|
-
"text": "
|
|
8070
|
+
"text": "number"
|
|
7865
8071
|
},
|
|
7866
|
-
"
|
|
7867
|
-
"
|
|
8072
|
+
"default": "100",
|
|
8073
|
+
"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.",
|
|
8074
|
+
"fieldName": "max"
|
|
7868
8075
|
},
|
|
7869
8076
|
{
|
|
7870
|
-
"name": "
|
|
8077
|
+
"name": "label",
|
|
7871
8078
|
"type": {
|
|
7872
|
-
"text": "
|
|
8079
|
+
"text": "string"
|
|
7873
8080
|
},
|
|
7874
|
-
"default": "
|
|
7875
|
-
"description": "
|
|
7876
|
-
"fieldName": "
|
|
8081
|
+
"default": "\"Current progress\"",
|
|
8082
|
+
"description": "Accessible label for the progress indicator. Visually hidden, but shown\nfor assistive technology.",
|
|
8083
|
+
"fieldName": "label"
|
|
7877
8084
|
}
|
|
7878
8085
|
],
|
|
7879
8086
|
"mixins": [
|
|
@@ -7886,64 +8093,10 @@
|
|
|
7886
8093
|
"name": "LitElement",
|
|
7887
8094
|
"package": "lit"
|
|
7888
8095
|
},
|
|
7889
|
-
"status": "
|
|
7890
|
-
"category": "
|
|
7891
|
-
"displayName": null,
|
|
7892
|
-
"tagName": "nord-nav-item",
|
|
7893
|
-
"customElement": true
|
|
7894
|
-
}
|
|
7895
|
-
],
|
|
7896
|
-
"exports": [
|
|
7897
|
-
{
|
|
7898
|
-
"kind": "js",
|
|
7899
|
-
"name": "default",
|
|
7900
|
-
"declaration": {
|
|
7901
|
-
"name": "NavItem",
|
|
7902
|
-
"module": "src/nav-item/NavItem.ts"
|
|
7903
|
-
}
|
|
7904
|
-
},
|
|
7905
|
-
{
|
|
7906
|
-
"kind": "custom-element-definition",
|
|
7907
|
-
"name": "nord-nav-item",
|
|
7908
|
-
"declaration": {
|
|
7909
|
-
"name": "NavItem",
|
|
7910
|
-
"module": "src/nav-item/NavItem.ts"
|
|
7911
|
-
}
|
|
7912
|
-
}
|
|
7913
|
-
],
|
|
7914
|
-
"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- 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 use navigation item outside of navigation group and navigation components.\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"
|
|
7915
|
-
},
|
|
7916
|
-
{
|
|
7917
|
-
"kind": "javascript-module",
|
|
7918
|
-
"path": "src/navigation/Navigation.ts",
|
|
7919
|
-
"declarations": [
|
|
7920
|
-
{
|
|
7921
|
-
"kind": "class",
|
|
7922
|
-
"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.",
|
|
7923
|
-
"name": "Navigation",
|
|
7924
|
-
"slots": [
|
|
7925
|
-
{
|
|
7926
|
-
"description": "The main section of the sidebar, for holding nav components.",
|
|
7927
|
-
"name": ""
|
|
7928
|
-
},
|
|
7929
|
-
{
|
|
7930
|
-
"description": "The top section of the sidebar.",
|
|
7931
|
-
"name": "header"
|
|
7932
|
-
},
|
|
7933
|
-
{
|
|
7934
|
-
"description": "The bottom section of the sidebar.",
|
|
7935
|
-
"name": "footer"
|
|
7936
|
-
}
|
|
7937
|
-
],
|
|
7938
|
-
"members": [],
|
|
7939
|
-
"superclass": {
|
|
7940
|
-
"name": "LitElement",
|
|
7941
|
-
"package": "lit"
|
|
7942
|
-
},
|
|
7943
|
-
"status": "ready",
|
|
7944
|
-
"category": "navigation",
|
|
8096
|
+
"status": "new",
|
|
8097
|
+
"category": "feedback",
|
|
7945
8098
|
"displayName": null,
|
|
7946
|
-
"tagName": "nord-
|
|
8099
|
+
"tagName": "nord-progress-bar",
|
|
7947
8100
|
"customElement": true
|
|
7948
8101
|
}
|
|
7949
8102
|
],
|
|
@@ -7952,20 +8105,20 @@
|
|
|
7952
8105
|
"kind": "js",
|
|
7953
8106
|
"name": "default",
|
|
7954
8107
|
"declaration": {
|
|
7955
|
-
"name": "
|
|
7956
|
-
"module": "src/
|
|
8108
|
+
"name": "ProgressBar",
|
|
8109
|
+
"module": "src/progress-bar/ProgressBar.ts"
|
|
7957
8110
|
}
|
|
7958
8111
|
},
|
|
7959
8112
|
{
|
|
7960
8113
|
"kind": "custom-element-definition",
|
|
7961
|
-
"name": "nord-
|
|
8114
|
+
"name": "nord-progress-bar",
|
|
7962
8115
|
"declaration": {
|
|
7963
|
-
"name": "
|
|
7964
|
-
"module": "src/
|
|
8116
|
+
"name": "ProgressBar",
|
|
8117
|
+
"module": "src/progress-bar/ProgressBar.ts"
|
|
7965
8118
|
}
|
|
7966
8119
|
}
|
|
7967
8120
|
],
|
|
7968
|
-
"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
|
|
8121
|
+
"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"
|
|
7969
8122
|
},
|
|
7970
8123
|
{
|
|
7971
8124
|
"kind": "javascript-module",
|
|
@@ -8103,229 +8256,76 @@
|
|
|
8103
8256
|
"description": "Get the position of the element toggling the popout\nand position the popout underneath it, taking into account the optional placement."
|
|
8104
8257
|
},
|
|
8105
8258
|
{
|
|
8106
|
-
"kind": "field",
|
|
8107
|
-
"name": "toggleOpen",
|
|
8108
|
-
"privacy": "private",
|
|
8109
|
-
"description": "Toggle the popout open or closed using state.\nUpdating the position to underneath the target button before the popout is opened."
|
|
8110
|
-
},
|
|
8111
|
-
{
|
|
8112
|
-
"kind": "method",
|
|
8113
|
-
"name": "getToggle",
|
|
8114
|
-
"privacy": "private"
|
|
8115
|
-
},
|
|
8116
|
-
{
|
|
8117
|
-
"kind": "field",
|
|
8118
|
-
"name": "handleMediaQueryChange",
|
|
8119
|
-
"privacy": "private",
|
|
8120
|
-
"description": "Update the smallViewport flag to switch between \"sheet\" and \"floating\".\nautoUpdate is needed when a viewport gets larger and the popout is open."
|
|
8121
|
-
}
|
|
8122
|
-
],
|
|
8123
|
-
"events": [
|
|
8124
|
-
{
|
|
8125
|
-
"name": "open",
|
|
8126
|
-
"type": {
|
|
8127
|
-
"text": "NordEvent"
|
|
8128
|
-
},
|
|
8129
|
-
"description": "Dispatched when the popout is opened."
|
|
8130
|
-
},
|
|
8131
|
-
{
|
|
8132
|
-
"name": "close",
|
|
8133
|
-
"type": {
|
|
8134
|
-
"text": "NordEvent"
|
|
8135
|
-
},
|
|
8136
|
-
"description": "Dispatched when the popout is closed."
|
|
8137
|
-
}
|
|
8138
|
-
],
|
|
8139
|
-
"attributes": [
|
|
8140
|
-
{
|
|
8141
|
-
"name": "align",
|
|
8142
|
-
"type": {
|
|
8143
|
-
"text": "\"start\" | \"end\""
|
|
8144
|
-
},
|
|
8145
|
-
"default": "\"start\"",
|
|
8146
|
-
"description": "Set the alignment of the popout in relation to the toggle depending on the position.\n`start` will align the left of the popout to the left of the toggle.\n`end` will align the right of the popout to the right of the toggle.\nA popout with a set position of `inline-start` or `inline-end` will switch\n`start` and `end` to the top and bottom of the popout respectively.",
|
|
8147
|
-
"fieldName": "align"
|
|
8148
|
-
},
|
|
8149
|
-
{
|
|
8150
|
-
"name": "position",
|
|
8151
|
-
"type": {
|
|
8152
|
-
"text": "\"block-end\" | \"block-start\" | \"inline-start\" | \"inline-end\""
|
|
8153
|
-
},
|
|
8154
|
-
"default": "\"block-end\"",
|
|
8155
|
-
"description": "Set the position of the popout in relation to the toggle.\nOptions follow logical properties.\n`block-start` and `block-end` referring to top and bottom respectively,\n`inline-start` and `inline-end` referring to left and right respectively.",
|
|
8156
|
-
"fieldName": "position"
|
|
8157
|
-
},
|
|
8158
|
-
{
|
|
8159
|
-
"name": "id",
|
|
8160
|
-
"type": {
|
|
8161
|
-
"text": "string"
|
|
8162
|
-
},
|
|
8163
|
-
"default": "\"\"",
|
|
8164
|
-
"description": "The id for the active element to reference via aria-controls.",
|
|
8165
|
-
"fieldName": "id"
|
|
8166
|
-
}
|
|
8167
|
-
],
|
|
8168
|
-
"superclass": {
|
|
8169
|
-
"name": "LitElement",
|
|
8170
|
-
"package": "lit"
|
|
8171
|
-
},
|
|
8172
|
-
"status": "ready",
|
|
8173
|
-
"category": "overlay",
|
|
8174
|
-
"displayName": null,
|
|
8175
|
-
"tagName": "nord-popout",
|
|
8176
|
-
"customElement": true
|
|
8177
|
-
}
|
|
8178
|
-
],
|
|
8179
|
-
"exports": [
|
|
8180
|
-
{
|
|
8181
|
-
"kind": "js",
|
|
8182
|
-
"name": "default",
|
|
8183
|
-
"declaration": {
|
|
8184
|
-
"name": "Popout",
|
|
8185
|
-
"module": "src/popout/Popout.ts"
|
|
8186
|
-
}
|
|
8187
|
-
},
|
|
8188
|
-
{
|
|
8189
|
-
"kind": "custom-element-definition",
|
|
8190
|
-
"name": "nord-popout",
|
|
8191
|
-
"declaration": {
|
|
8192
|
-
"name": "Popout",
|
|
8193
|
-
"module": "src/popout/Popout.ts"
|
|
8194
|
-
}
|
|
8195
|
-
}
|
|
8196
|
-
],
|
|
8197
|
-
"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- Always position popout next to the button or other interface element that toggles it.\n- Use a popout to contain controls or information that doesn’t need to be shown immediately.\n- Use a popout to contain items that will most likely not fit into the current view.\n- Use a clearly labelled button to reveal the popout.\n- Use the appropriate `aria-haspopup` and `role` attributes for both the toggle button and containing items. Please refer to the [MDN documentation on both role values](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-haspopup#values) and [child role values](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-haspopup#associated_roles).\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t hide information inside a popout that is imperative to using the current view.\n- Don’t obscure other controls that are important with the popout.\n- Don’t allow the popout to be obscured by other controls or the outer bounds of the current view.\n</div>\n\n---\n\n## Content guidelines\n\nIf a popout contains actions, they should be always written 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\">Create user</div>\n<div class=\"n-usage n-usage-dont\">Create User</div>\n\nPopout actions should always lead with a strong verb that encourages action. Use the `{verb}+{noun}` format except in the case of common actions like Save, Close or Cancel:\n\n<div class=\"n-usage n-usage-do\">Edit row</div>\n<div class=\"n-usage n-usage-dont\">Editing options</div>\n\nAvoid unnecessary words and articles in popout actions, 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 popout actions 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\nAvoid all caps for popout actions:\n\n<div class=\"n-usage n-usage-do\">Rename</div>\n<div class=\"n-usage n-usage-dont\">RENAME</div>\n\n---\n\n## Additional considerations\n\n- The popout component is a containing component, only providing a way to reveal and hide controls by using a single button.\n"
|
|
8198
|
-
},
|
|
8199
|
-
{
|
|
8200
|
-
"kind": "javascript-module",
|
|
8201
|
-
"path": "src/progress-bar/ProgressBar.ts",
|
|
8202
|
-
"declarations": [
|
|
8203
|
-
{
|
|
8204
|
-
"kind": "class",
|
|
8205
|
-
"description": "Progress Bar is used to visually represent the completion\nof a task or process. It shows how much of the task has\nbeen completed and how much is still left.",
|
|
8206
|
-
"name": "ProgressBar",
|
|
8207
|
-
"members": [
|
|
8208
|
-
{
|
|
8209
|
-
"kind": "field",
|
|
8210
|
-
"name": "value",
|
|
8211
|
-
"type": {
|
|
8212
|
-
"text": "number | undefined"
|
|
8213
|
-
},
|
|
8214
|
-
"description": "Specifies how much of the task has been completed. Must be a valid floating\npoint number between 0 and max, or between 0 and 100 if max is omitted. If\nthere is no value, the progress bar is indeterminate; this indicates that\nan activity is ongoing with no indication of how long it’s expected to take.",
|
|
8215
|
-
"attribute": "value",
|
|
8216
|
-
"reflects": true
|
|
8217
|
-
},
|
|
8218
|
-
{
|
|
8219
|
-
"kind": "field",
|
|
8220
|
-
"name": "max",
|
|
8221
|
-
"type": {
|
|
8222
|
-
"text": "number"
|
|
8223
|
-
},
|
|
8224
|
-
"default": "100",
|
|
8225
|
-
"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.",
|
|
8226
|
-
"attribute": "max",
|
|
8227
|
-
"reflects": true
|
|
8228
|
-
},
|
|
8229
|
-
{
|
|
8230
|
-
"kind": "field",
|
|
8231
|
-
"name": "label",
|
|
8232
|
-
"type": {
|
|
8233
|
-
"text": "string"
|
|
8234
|
-
},
|
|
8235
|
-
"default": "\"Current progress\"",
|
|
8236
|
-
"description": "Accessible label for the progress indicator. Visually hidden, but shown\nfor assistive technology.",
|
|
8237
|
-
"attribute": "label",
|
|
8238
|
-
"reflects": true
|
|
8239
|
-
},
|
|
8240
|
-
{
|
|
8241
|
-
"kind": "field",
|
|
8242
|
-
"name": "focusableRef",
|
|
8243
|
-
"privacy": "protected",
|
|
8244
|
-
"inheritedFrom": {
|
|
8245
|
-
"name": "FocusableMixin",
|
|
8246
|
-
"module": "src/common/mixins/FocusableMixin.ts"
|
|
8247
|
-
}
|
|
8248
|
-
},
|
|
8249
|
-
{
|
|
8250
|
-
"kind": "method",
|
|
8251
|
-
"name": "focus",
|
|
8252
|
-
"parameters": [
|
|
8253
|
-
{
|
|
8254
|
-
"name": "options",
|
|
8255
|
-
"optional": true,
|
|
8256
|
-
"type": {
|
|
8257
|
-
"text": "FocusOptions"
|
|
8258
|
-
},
|
|
8259
|
-
"description": "An object which controls aspects of the focusing process."
|
|
8260
|
-
}
|
|
8261
|
-
],
|
|
8262
|
-
"description": "Programmatically move focus to the component.",
|
|
8263
|
-
"inheritedFrom": {
|
|
8264
|
-
"name": "FocusableMixin",
|
|
8265
|
-
"module": "src/common/mixins/FocusableMixin.ts"
|
|
8266
|
-
}
|
|
8267
|
-
},
|
|
8268
|
-
{
|
|
8269
|
-
"kind": "method",
|
|
8270
|
-
"name": "blur",
|
|
8271
|
-
"description": "Programmatically remove focus from the component.",
|
|
8272
|
-
"inheritedFrom": {
|
|
8273
|
-
"name": "FocusableMixin",
|
|
8274
|
-
"module": "src/common/mixins/FocusableMixin.ts"
|
|
8275
|
-
}
|
|
8259
|
+
"kind": "field",
|
|
8260
|
+
"name": "toggleOpen",
|
|
8261
|
+
"privacy": "private",
|
|
8262
|
+
"description": "Toggle the popout open or closed using state.\nUpdating the position to underneath the target button before the popout is opened."
|
|
8276
8263
|
},
|
|
8277
8264
|
{
|
|
8278
8265
|
"kind": "method",
|
|
8279
|
-
"name": "
|
|
8280
|
-
"
|
|
8281
|
-
|
|
8282
|
-
|
|
8283
|
-
|
|
8284
|
-
|
|
8266
|
+
"name": "getToggle",
|
|
8267
|
+
"privacy": "private"
|
|
8268
|
+
},
|
|
8269
|
+
{
|
|
8270
|
+
"kind": "field",
|
|
8271
|
+
"name": "handleMediaQueryChange",
|
|
8272
|
+
"privacy": "private",
|
|
8273
|
+
"description": "Update the smallViewport flag to switch between \"sheet\" and \"floating\".\nautoUpdate is needed when a viewport gets larger and the popout is open."
|
|
8274
|
+
}
|
|
8275
|
+
],
|
|
8276
|
+
"events": [
|
|
8277
|
+
{
|
|
8278
|
+
"name": "open",
|
|
8279
|
+
"type": {
|
|
8280
|
+
"text": "NordEvent"
|
|
8281
|
+
},
|
|
8282
|
+
"description": "Dispatched when the popout is opened."
|
|
8283
|
+
},
|
|
8284
|
+
{
|
|
8285
|
+
"name": "close",
|
|
8286
|
+
"type": {
|
|
8287
|
+
"text": "NordEvent"
|
|
8288
|
+
},
|
|
8289
|
+
"description": "Dispatched when the popout is closed."
|
|
8285
8290
|
}
|
|
8286
8291
|
],
|
|
8287
8292
|
"attributes": [
|
|
8288
8293
|
{
|
|
8289
|
-
"name": "
|
|
8294
|
+
"name": "align",
|
|
8290
8295
|
"type": {
|
|
8291
|
-
"text": "
|
|
8296
|
+
"text": "\"start\" | \"end\""
|
|
8292
8297
|
},
|
|
8293
|
-
"
|
|
8294
|
-
"
|
|
8298
|
+
"default": "\"start\"",
|
|
8299
|
+
"description": "Set the alignment of the popout in relation to the toggle depending on the position.\n`start` will align the left of the popout to the left of the toggle.\n`end` will align the right of the popout to the right of the toggle.\nA popout with a set position of `inline-start` or `inline-end` will switch\n`start` and `end` to the top and bottom of the popout respectively.",
|
|
8300
|
+
"fieldName": "align"
|
|
8295
8301
|
},
|
|
8296
8302
|
{
|
|
8297
|
-
"name": "
|
|
8303
|
+
"name": "position",
|
|
8298
8304
|
"type": {
|
|
8299
|
-
"text": "
|
|
8305
|
+
"text": "\"block-end\" | \"block-start\" | \"inline-start\" | \"inline-end\""
|
|
8300
8306
|
},
|
|
8301
|
-
"default": "
|
|
8302
|
-
"description": "
|
|
8303
|
-
"fieldName": "
|
|
8307
|
+
"default": "\"block-end\"",
|
|
8308
|
+
"description": "Set the position of the popout in relation to the toggle.\nOptions follow logical properties.\n`block-start` and `block-end` referring to top and bottom respectively,\n`inline-start` and `inline-end` referring to left and right respectively.",
|
|
8309
|
+
"fieldName": "position"
|
|
8304
8310
|
},
|
|
8305
8311
|
{
|
|
8306
|
-
"name": "
|
|
8312
|
+
"name": "id",
|
|
8307
8313
|
"type": {
|
|
8308
8314
|
"text": "string"
|
|
8309
8315
|
},
|
|
8310
|
-
"default": "\"
|
|
8311
|
-
"description": "
|
|
8312
|
-
"fieldName": "
|
|
8313
|
-
}
|
|
8314
|
-
],
|
|
8315
|
-
"mixins": [
|
|
8316
|
-
{
|
|
8317
|
-
"name": "FocusableMixin",
|
|
8318
|
-
"module": "/src/common/mixins/FocusableMixin.js"
|
|
8316
|
+
"default": "\"\"",
|
|
8317
|
+
"description": "The id for the active element to reference via aria-controls.",
|
|
8318
|
+
"fieldName": "id"
|
|
8319
8319
|
}
|
|
8320
8320
|
],
|
|
8321
8321
|
"superclass": {
|
|
8322
8322
|
"name": "LitElement",
|
|
8323
8323
|
"package": "lit"
|
|
8324
8324
|
},
|
|
8325
|
-
"status": "
|
|
8326
|
-
"category": "
|
|
8325
|
+
"status": "ready",
|
|
8326
|
+
"category": "overlay",
|
|
8327
8327
|
"displayName": null,
|
|
8328
|
-
"tagName": "nord-
|
|
8328
|
+
"tagName": "nord-popout",
|
|
8329
8329
|
"customElement": true
|
|
8330
8330
|
}
|
|
8331
8331
|
],
|
|
@@ -8334,20 +8334,20 @@
|
|
|
8334
8334
|
"kind": "js",
|
|
8335
8335
|
"name": "default",
|
|
8336
8336
|
"declaration": {
|
|
8337
|
-
"name": "
|
|
8338
|
-
"module": "src/
|
|
8337
|
+
"name": "Popout",
|
|
8338
|
+
"module": "src/popout/Popout.ts"
|
|
8339
8339
|
}
|
|
8340
8340
|
},
|
|
8341
8341
|
{
|
|
8342
8342
|
"kind": "custom-element-definition",
|
|
8343
|
-
"name": "nord-
|
|
8343
|
+
"name": "nord-popout",
|
|
8344
8344
|
"declaration": {
|
|
8345
|
-
"name": "
|
|
8346
|
-
"module": "src/
|
|
8345
|
+
"name": "Popout",
|
|
8346
|
+
"module": "src/popout/Popout.ts"
|
|
8347
8347
|
}
|
|
8348
8348
|
}
|
|
8349
8349
|
],
|
|
8350
|
-
"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
|
|
8350
|
+
"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- Always position popout next to the button or other interface element that toggles it.\n- Use a popout to contain controls or information that doesn’t need to be shown immediately.\n- Use a popout to contain items that will most likely not fit into the current view.\n- Use a clearly labelled button to reveal the popout.\n- Use the appropriate `aria-haspopup` and `role` attributes for both the toggle button and containing items. Please refer to the [MDN documentation on both role values](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-haspopup#values) and [child role values](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-haspopup#associated_roles).\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t hide information inside a popout that is imperative to using the current view.\n- Don’t obscure other controls that are important with the popout.\n- Don’t allow the popout to be obscured by other controls or the outer bounds of the current view.\n</div>\n\n---\n\n## Content guidelines\n\nIf a popout contains actions, they should be always written 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\">Create user</div>\n<div class=\"n-usage n-usage-dont\">Create User</div>\n\nPopout actions should always lead with a strong verb that encourages action. Use the `{verb}+{noun}` format except in the case of common actions like Save, Close or Cancel:\n\n<div class=\"n-usage n-usage-do\">Edit row</div>\n<div class=\"n-usage n-usage-dont\">Editing options</div>\n\nAvoid unnecessary words and articles in popout actions, 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 popout actions 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\nAvoid all caps for popout actions:\n\n<div class=\"n-usage n-usage-do\">Rename</div>\n<div class=\"n-usage n-usage-dont\">RENAME</div>\n\n---\n\n## Additional considerations\n\n- The popout component is a containing component, only providing a way to reveal and hide controls by using a single button.\n"
|
|
8351
8351
|
},
|
|
8352
8352
|
{
|
|
8353
8353
|
"kind": "javascript-module",
|
|
@@ -9834,88 +9834,6 @@
|
|
|
9834
9834
|
],
|
|
9835
9835
|
"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 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"
|
|
9836
9836
|
},
|
|
9837
|
-
{
|
|
9838
|
-
"kind": "javascript-module",
|
|
9839
|
-
"path": "src/skeleton/Skeleton.ts",
|
|
9840
|
-
"declarations": [
|
|
9841
|
-
{
|
|
9842
|
-
"kind": "class",
|
|
9843
|
-
"description": "Skeletons are used to provide a low fidelity representation of content\nbefore it appears in a view. This improves the perceived loading time\nfor our users.",
|
|
9844
|
-
"name": "Skeleton",
|
|
9845
|
-
"members": [
|
|
9846
|
-
{
|
|
9847
|
-
"kind": "field",
|
|
9848
|
-
"name": "effect",
|
|
9849
|
-
"type": {
|
|
9850
|
-
"text": "\"pulse\" | \"sheen\" | \"none\""
|
|
9851
|
-
},
|
|
9852
|
-
"default": "\"none\"",
|
|
9853
|
-
"description": "Determines which animation effect the skeleton will use.",
|
|
9854
|
-
"attribute": "effect"
|
|
9855
|
-
},
|
|
9856
|
-
{
|
|
9857
|
-
"kind": "field",
|
|
9858
|
-
"name": "_warningLogged",
|
|
9859
|
-
"type": {
|
|
9860
|
-
"text": "boolean"
|
|
9861
|
-
},
|
|
9862
|
-
"privacy": "private",
|
|
9863
|
-
"static": true,
|
|
9864
|
-
"default": "false",
|
|
9865
|
-
"inheritedFrom": {
|
|
9866
|
-
"name": "DraftComponentMixin",
|
|
9867
|
-
"module": "src/common/mixins/DraftComponentMixin.ts"
|
|
9868
|
-
}
|
|
9869
|
-
}
|
|
9870
|
-
],
|
|
9871
|
-
"attributes": [
|
|
9872
|
-
{
|
|
9873
|
-
"name": "effect",
|
|
9874
|
-
"type": {
|
|
9875
|
-
"text": "\"pulse\" | \"sheen\" | \"none\""
|
|
9876
|
-
},
|
|
9877
|
-
"default": "\"none\"",
|
|
9878
|
-
"description": "Determines which animation effect the skeleton will use.",
|
|
9879
|
-
"fieldName": "effect"
|
|
9880
|
-
}
|
|
9881
|
-
],
|
|
9882
|
-
"mixins": [
|
|
9883
|
-
{
|
|
9884
|
-
"name": "DraftComponentMixin",
|
|
9885
|
-
"module": "/src/common/mixins/DraftComponentMixin.js"
|
|
9886
|
-
}
|
|
9887
|
-
],
|
|
9888
|
-
"superclass": {
|
|
9889
|
-
"name": "LitElement",
|
|
9890
|
-
"package": "lit"
|
|
9891
|
-
},
|
|
9892
|
-
"status": "draft",
|
|
9893
|
-
"category": "feedback",
|
|
9894
|
-
"displayName": null,
|
|
9895
|
-
"tagName": "nord-skeleton",
|
|
9896
|
-
"customElement": true
|
|
9897
|
-
}
|
|
9898
|
-
],
|
|
9899
|
-
"exports": [
|
|
9900
|
-
{
|
|
9901
|
-
"kind": "js",
|
|
9902
|
-
"name": "default",
|
|
9903
|
-
"declaration": {
|
|
9904
|
-
"name": "Skeleton",
|
|
9905
|
-
"module": "src/skeleton/Skeleton.ts"
|
|
9906
|
-
}
|
|
9907
|
-
},
|
|
9908
|
-
{
|
|
9909
|
-
"kind": "custom-element-definition",
|
|
9910
|
-
"name": "nord-skeleton",
|
|
9911
|
-
"declaration": {
|
|
9912
|
-
"name": "Skeleton",
|
|
9913
|
-
"module": "src/skeleton/Skeleton.ts"
|
|
9914
|
-
}
|
|
9915
|
-
}
|
|
9916
|
-
],
|
|
9917
|
-
"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 skeleton component for dynamic content only.\n- Use to give the user an indication of what the page layout will be like once loaded.\n- Mimick the actual layout using multiple Skeleton components.\n- Use `aria-busy=\"true\"` to indicate which area on the screen is currently loading and remove it or set it to `false` once loaded.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use Skeleton component for static content.\n- Don’t show placeholder content after Skeleton disappears that will change when the page fully loads.\n\n</div>\n"
|
|
9918
|
-
},
|
|
9919
9837
|
{
|
|
9920
9838
|
"kind": "javascript-module",
|
|
9921
9839
|
"path": "src/spinner/Spinner.ts",
|
|
@@ -10008,12 +9926,94 @@
|
|
|
10008
9926
|
"kind": "custom-element-definition",
|
|
10009
9927
|
"name": "nord-spinner",
|
|
10010
9928
|
"declaration": {
|
|
10011
|
-
"name": "Spinner",
|
|
10012
|
-
"module": "src/spinner/Spinner.ts"
|
|
9929
|
+
"name": "Spinner",
|
|
9930
|
+
"module": "src/spinner/Spinner.ts"
|
|
9931
|
+
}
|
|
9932
|
+
}
|
|
9933
|
+
],
|
|
9934
|
+
"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"
|
|
9935
|
+
},
|
|
9936
|
+
{
|
|
9937
|
+
"kind": "javascript-module",
|
|
9938
|
+
"path": "src/skeleton/Skeleton.ts",
|
|
9939
|
+
"declarations": [
|
|
9940
|
+
{
|
|
9941
|
+
"kind": "class",
|
|
9942
|
+
"description": "Skeletons are used to provide a low fidelity representation of content\nbefore it appears in a view. This improves the perceived loading time\nfor our users.",
|
|
9943
|
+
"name": "Skeleton",
|
|
9944
|
+
"members": [
|
|
9945
|
+
{
|
|
9946
|
+
"kind": "field",
|
|
9947
|
+
"name": "effect",
|
|
9948
|
+
"type": {
|
|
9949
|
+
"text": "\"pulse\" | \"sheen\" | \"none\""
|
|
9950
|
+
},
|
|
9951
|
+
"default": "\"none\"",
|
|
9952
|
+
"description": "Determines which animation effect the skeleton will use.",
|
|
9953
|
+
"attribute": "effect"
|
|
9954
|
+
},
|
|
9955
|
+
{
|
|
9956
|
+
"kind": "field",
|
|
9957
|
+
"name": "_warningLogged",
|
|
9958
|
+
"type": {
|
|
9959
|
+
"text": "boolean"
|
|
9960
|
+
},
|
|
9961
|
+
"privacy": "private",
|
|
9962
|
+
"static": true,
|
|
9963
|
+
"default": "false",
|
|
9964
|
+
"inheritedFrom": {
|
|
9965
|
+
"name": "DraftComponentMixin",
|
|
9966
|
+
"module": "src/common/mixins/DraftComponentMixin.ts"
|
|
9967
|
+
}
|
|
9968
|
+
}
|
|
9969
|
+
],
|
|
9970
|
+
"attributes": [
|
|
9971
|
+
{
|
|
9972
|
+
"name": "effect",
|
|
9973
|
+
"type": {
|
|
9974
|
+
"text": "\"pulse\" | \"sheen\" | \"none\""
|
|
9975
|
+
},
|
|
9976
|
+
"default": "\"none\"",
|
|
9977
|
+
"description": "Determines which animation effect the skeleton will use.",
|
|
9978
|
+
"fieldName": "effect"
|
|
9979
|
+
}
|
|
9980
|
+
],
|
|
9981
|
+
"mixins": [
|
|
9982
|
+
{
|
|
9983
|
+
"name": "DraftComponentMixin",
|
|
9984
|
+
"module": "/src/common/mixins/DraftComponentMixin.js"
|
|
9985
|
+
}
|
|
9986
|
+
],
|
|
9987
|
+
"superclass": {
|
|
9988
|
+
"name": "LitElement",
|
|
9989
|
+
"package": "lit"
|
|
9990
|
+
},
|
|
9991
|
+
"status": "draft",
|
|
9992
|
+
"category": "feedback",
|
|
9993
|
+
"displayName": null,
|
|
9994
|
+
"tagName": "nord-skeleton",
|
|
9995
|
+
"customElement": true
|
|
9996
|
+
}
|
|
9997
|
+
],
|
|
9998
|
+
"exports": [
|
|
9999
|
+
{
|
|
10000
|
+
"kind": "js",
|
|
10001
|
+
"name": "default",
|
|
10002
|
+
"declaration": {
|
|
10003
|
+
"name": "Skeleton",
|
|
10004
|
+
"module": "src/skeleton/Skeleton.ts"
|
|
10005
|
+
}
|
|
10006
|
+
},
|
|
10007
|
+
{
|
|
10008
|
+
"kind": "custom-element-definition",
|
|
10009
|
+
"name": "nord-skeleton",
|
|
10010
|
+
"declaration": {
|
|
10011
|
+
"name": "Skeleton",
|
|
10012
|
+
"module": "src/skeleton/Skeleton.ts"
|
|
10013
10013
|
}
|
|
10014
10014
|
}
|
|
10015
10015
|
],
|
|
10016
|
-
"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
|
|
10016
|
+
"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 skeleton component for dynamic content only.\n- Use to give the user an indication of what the page layout will be like once loaded.\n- Mimick the actual layout using multiple Skeleton components.\n- Use `aria-busy=\"true\"` to indicate which area on the screen is currently loading and remove it or set it to `false` once loaded.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use Skeleton component for static content.\n- Don’t show placeholder content after Skeleton disappears that will change when the page fully loads.\n\n</div>\n"
|
|
10017
10017
|
},
|
|
10018
10018
|
{
|
|
10019
10019
|
"kind": "javascript-module",
|
|
@@ -11354,7 +11354,259 @@
|
|
|
11354
11354
|
}
|
|
11355
11355
|
}
|
|
11356
11356
|
],
|
|
11357
|
-
"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 text input where the expected input is long.\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 short. Use input component instead.\n\n</div>\n\n---\n\n## Content guidelines\n\nTextarea 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 textarea 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\">Provide description</div>\n<div class=\"n-usage n-usage-dont\">Provide Description</div>\n\nWhen a textarea isn’t part of a form and is placed individually on a page, you could provide the textarea 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 textarea labels:\n\n<div class=\"n-usage n-usage-do\">Provide description</div>\n<div class=\"n-usage n-usage-dont\">Provide description:</div>\n"
|
|
11357
|
+
"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 text input where the expected input is long.\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 short. Use input component instead.\n\n</div>\n\n---\n\n## Content guidelines\n\nTextarea 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 textarea 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\">Provide description</div>\n<div class=\"n-usage n-usage-dont\">Provide Description</div>\n\nWhen a textarea isn’t part of a form and is placed individually on a page, you could provide the textarea 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 textarea labels:\n\n<div class=\"n-usage n-usage-do\">Provide description</div>\n<div class=\"n-usage n-usage-dont\">Provide description:</div>\n"
|
|
11358
|
+
},
|
|
11359
|
+
{
|
|
11360
|
+
"kind": "javascript-module",
|
|
11361
|
+
"path": "src/toast/Toast.ts",
|
|
11362
|
+
"declarations": [
|
|
11363
|
+
{
|
|
11364
|
+
"kind": "class",
|
|
11365
|
+
"description": "Toasts are non-disruptive messages that appear in the interface\nto provide quick, at-a-glance feedback on the outcome of an action.",
|
|
11366
|
+
"name": "Toast",
|
|
11367
|
+
"slots": [
|
|
11368
|
+
{
|
|
11369
|
+
"description": "Default slot used for the toast text/message.",
|
|
11370
|
+
"name": ""
|
|
11371
|
+
}
|
|
11372
|
+
],
|
|
11373
|
+
"members": [
|
|
11374
|
+
{
|
|
11375
|
+
"kind": "field",
|
|
11376
|
+
"name": "timeoutId",
|
|
11377
|
+
"type": {
|
|
11378
|
+
"text": "ReturnType<typeof setTimeout> | undefined"
|
|
11379
|
+
},
|
|
11380
|
+
"privacy": "private"
|
|
11381
|
+
},
|
|
11382
|
+
{
|
|
11383
|
+
"kind": "field",
|
|
11384
|
+
"name": "events",
|
|
11385
|
+
"privacy": "private",
|
|
11386
|
+
"default": "new EventController(this)"
|
|
11387
|
+
},
|
|
11388
|
+
{
|
|
11389
|
+
"kind": "field",
|
|
11390
|
+
"name": "toast",
|
|
11391
|
+
"type": {
|
|
11392
|
+
"text": "HTMLElement"
|
|
11393
|
+
},
|
|
11394
|
+
"privacy": "private"
|
|
11395
|
+
},
|
|
11396
|
+
{
|
|
11397
|
+
"kind": "field",
|
|
11398
|
+
"name": "dismissed",
|
|
11399
|
+
"type": {
|
|
11400
|
+
"text": "boolean"
|
|
11401
|
+
},
|
|
11402
|
+
"privacy": "private",
|
|
11403
|
+
"default": "false"
|
|
11404
|
+
},
|
|
11405
|
+
{
|
|
11406
|
+
"kind": "field",
|
|
11407
|
+
"name": "variant",
|
|
11408
|
+
"type": {
|
|
11409
|
+
"text": "\"default\" | \"danger\""
|
|
11410
|
+
},
|
|
11411
|
+
"default": "\"default\"",
|
|
11412
|
+
"description": "The style variant of the toast.",
|
|
11413
|
+
"attribute": "variant",
|
|
11414
|
+
"reflects": true
|
|
11415
|
+
},
|
|
11416
|
+
{
|
|
11417
|
+
"kind": "field",
|
|
11418
|
+
"name": "autoDismiss",
|
|
11419
|
+
"type": {
|
|
11420
|
+
"text": "number"
|
|
11421
|
+
},
|
|
11422
|
+
"default": "10000",
|
|
11423
|
+
"description": "Timeout in milliseconds before the toast is automatically dismissed.",
|
|
11424
|
+
"attribute": "auto-dismiss"
|
|
11425
|
+
},
|
|
11426
|
+
{
|
|
11427
|
+
"kind": "method",
|
|
11428
|
+
"name": "dismiss",
|
|
11429
|
+
"description": "Programmatically dismiss the toast.\nThe returned promise resolves when toast's exit animation is complete."
|
|
11430
|
+
},
|
|
11431
|
+
{
|
|
11432
|
+
"kind": "method",
|
|
11433
|
+
"name": "handleAutoDismissChange",
|
|
11434
|
+
"privacy": "protected"
|
|
11435
|
+
},
|
|
11436
|
+
{
|
|
11437
|
+
"kind": "field",
|
|
11438
|
+
"name": "_warningLogged",
|
|
11439
|
+
"type": {
|
|
11440
|
+
"text": "boolean"
|
|
11441
|
+
},
|
|
11442
|
+
"privacy": "private",
|
|
11443
|
+
"static": true,
|
|
11444
|
+
"default": "false",
|
|
11445
|
+
"inheritedFrom": {
|
|
11446
|
+
"name": "DraftComponentMixin",
|
|
11447
|
+
"module": "src/common/mixins/DraftComponentMixin.ts"
|
|
11448
|
+
}
|
|
11449
|
+
}
|
|
11450
|
+
],
|
|
11451
|
+
"events": [
|
|
11452
|
+
{
|
|
11453
|
+
"name": "dismiss",
|
|
11454
|
+
"type": {
|
|
11455
|
+
"text": "NordEvent"
|
|
11456
|
+
},
|
|
11457
|
+
"description": "Fired when the toast is dismissed (via user action or auto-dismiss), and its exit animation has completed. This event should be used to remove the dismissed toast from the DOM."
|
|
11458
|
+
}
|
|
11459
|
+
],
|
|
11460
|
+
"attributes": [
|
|
11461
|
+
{
|
|
11462
|
+
"name": "variant",
|
|
11463
|
+
"type": {
|
|
11464
|
+
"text": "\"default\" | \"danger\""
|
|
11465
|
+
},
|
|
11466
|
+
"default": "\"default\"",
|
|
11467
|
+
"description": "The style variant of the toast.",
|
|
11468
|
+
"fieldName": "variant"
|
|
11469
|
+
},
|
|
11470
|
+
{
|
|
11471
|
+
"name": "auto-dismiss",
|
|
11472
|
+
"type": {
|
|
11473
|
+
"text": "number"
|
|
11474
|
+
},
|
|
11475
|
+
"default": "10000",
|
|
11476
|
+
"description": "Timeout in milliseconds before the toast is automatically dismissed.",
|
|
11477
|
+
"fieldName": "autoDismiss"
|
|
11478
|
+
}
|
|
11479
|
+
],
|
|
11480
|
+
"mixins": [
|
|
11481
|
+
{
|
|
11482
|
+
"name": "DraftComponentMixin",
|
|
11483
|
+
"module": "/src/common/mixins/DraftComponentMixin.js"
|
|
11484
|
+
}
|
|
11485
|
+
],
|
|
11486
|
+
"superclass": {
|
|
11487
|
+
"name": "LitElement",
|
|
11488
|
+
"package": "lit"
|
|
11489
|
+
},
|
|
11490
|
+
"status": "draft",
|
|
11491
|
+
"category": "feedback",
|
|
11492
|
+
"displayName": null,
|
|
11493
|
+
"tagName": "nord-toast",
|
|
11494
|
+
"customElement": true
|
|
11495
|
+
}
|
|
11496
|
+
],
|
|
11497
|
+
"exports": [
|
|
11498
|
+
{
|
|
11499
|
+
"kind": "js",
|
|
11500
|
+
"name": "default",
|
|
11501
|
+
"declaration": {
|
|
11502
|
+
"name": "Toast",
|
|
11503
|
+
"module": "src/toast/Toast.ts"
|
|
11504
|
+
}
|
|
11505
|
+
},
|
|
11506
|
+
{
|
|
11507
|
+
"kind": "custom-element-definition",
|
|
11508
|
+
"name": "nord-toast",
|
|
11509
|
+
"declaration": {
|
|
11510
|
+
"name": "Toast",
|
|
11511
|
+
"module": "src/toast/Toast.ts"
|
|
11512
|
+
}
|
|
11513
|
+
}
|
|
11514
|
+
],
|
|
11515
|
+
"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 confirm an action taken by a user.\n- Use for ephemeral status updates.\n- Use in combination with [Toast group](../toast-group/) so that toasts get styled and announced to screen readers correctly.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use toasts for critical information that user needs to act on.\n- Don’t rely on users seeing toasts. Toasts are transient and should not be used for critical messages.\n- Don’t place interactive content in toasts. Assistive technology like screen readers will not convey any semantics when announcing toast messages.\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\nToast content should be clear, accurate and easy to understand:\n\n<div class=\"n-usage n-usage-do\">Message sent</div>\n<div class=\"n-usage n-usage-dont\">Your message has been sent</div>\n\nWhen writing the toast content, use the {noun} + {verb} content formula:\n\n<div class=\"n-usage n-usage-do\">Patient created</div>\n<div class=\"n-usage n-usage-dont\">Your patient has been successfully updated</div>\n\nUse a maximum of 3 words when writing the toast content:\n\n<div class=\"n-usage n-usage-do\">Product updated</div>\n<div class=\"n-usage n-usage-dont\">Your product was updated just now</div>\n\nWhen writing the toast 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\">Message sent</div>\n<div class=\"n-usage n-usage-dont\">Message Sent</div>\n\nAvoid unnecessary words and articles in the toast content, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Changes saved</div>\n<div class=\"n-usage n-usage-dont\">The changes were saved</div>\n\nNever end in punctuation:\n\n<div class=\"n-usage n-usage-do\">Message sent</div>\n<div class=\"n-usage n-usage-dont\">Message sent.</div>\n\n---\n\n## Additional considerations\n\n- Toasts are complicated from an accessibility perspective. Whilst they are a convenient UI pattern for messaging, they present difficulties for keyboard or screen reader users. Therefore careful consideration should be given as to whether a toast is the correct choice.\n- If the message cannot be conveyed in 3 words or less, consider re-wording. If the message cannot be shortened any further, consider choosing a different pattern than toast.\n"
|
|
11516
|
+
},
|
|
11517
|
+
{
|
|
11518
|
+
"kind": "javascript-module",
|
|
11519
|
+
"path": "src/toast-group/ToastGroup.ts",
|
|
11520
|
+
"declarations": [
|
|
11521
|
+
{
|
|
11522
|
+
"kind": "class",
|
|
11523
|
+
"description": "Toast group is used to position and style a group of toasts, whilst ensuring they are announced by screen readers.",
|
|
11524
|
+
"name": "ToastGroup",
|
|
11525
|
+
"slots": [
|
|
11526
|
+
{
|
|
11527
|
+
"description": "Default slot in which to place toasts.",
|
|
11528
|
+
"name": ""
|
|
11529
|
+
}
|
|
11530
|
+
],
|
|
11531
|
+
"members": [
|
|
11532
|
+
{
|
|
11533
|
+
"kind": "method",
|
|
11534
|
+
"name": "addToast",
|
|
11535
|
+
"parameters": [
|
|
11536
|
+
{
|
|
11537
|
+
"name": "text",
|
|
11538
|
+
"type": {
|
|
11539
|
+
"text": "string"
|
|
11540
|
+
},
|
|
11541
|
+
"description": "The text/message of the toast."
|
|
11542
|
+
},
|
|
11543
|
+
{
|
|
11544
|
+
"name": "options",
|
|
11545
|
+
"default": "{}",
|
|
11546
|
+
"type": {
|
|
11547
|
+
"text": "ToastOptions"
|
|
11548
|
+
},
|
|
11549
|
+
"description": "An optional object for configuring the toast's `variant` and `autoDismiss`."
|
|
11550
|
+
}
|
|
11551
|
+
],
|
|
11552
|
+
"description": "Convenience method for creating and adding a toast to the group.",
|
|
11553
|
+
"return": {
|
|
11554
|
+
"type": {
|
|
11555
|
+
"text": ""
|
|
11556
|
+
}
|
|
11557
|
+
}
|
|
11558
|
+
},
|
|
11559
|
+
{
|
|
11560
|
+
"kind": "field",
|
|
11561
|
+
"name": "_warningLogged",
|
|
11562
|
+
"type": {
|
|
11563
|
+
"text": "boolean"
|
|
11564
|
+
},
|
|
11565
|
+
"privacy": "private",
|
|
11566
|
+
"static": true,
|
|
11567
|
+
"default": "false",
|
|
11568
|
+
"inheritedFrom": {
|
|
11569
|
+
"name": "DraftComponentMixin",
|
|
11570
|
+
"module": "src/common/mixins/DraftComponentMixin.ts"
|
|
11571
|
+
}
|
|
11572
|
+
}
|
|
11573
|
+
],
|
|
11574
|
+
"mixins": [
|
|
11575
|
+
{
|
|
11576
|
+
"name": "DraftComponentMixin",
|
|
11577
|
+
"module": "/src/common/mixins/DraftComponentMixin.js"
|
|
11578
|
+
}
|
|
11579
|
+
],
|
|
11580
|
+
"superclass": {
|
|
11581
|
+
"name": "LitElement",
|
|
11582
|
+
"package": "lit"
|
|
11583
|
+
},
|
|
11584
|
+
"status": "draft",
|
|
11585
|
+
"category": "feedback",
|
|
11586
|
+
"displayName": null,
|
|
11587
|
+
"tagName": "nord-toast-group",
|
|
11588
|
+
"customElement": true
|
|
11589
|
+
}
|
|
11590
|
+
],
|
|
11591
|
+
"exports": [
|
|
11592
|
+
{
|
|
11593
|
+
"kind": "js",
|
|
11594
|
+
"name": "default",
|
|
11595
|
+
"declaration": {
|
|
11596
|
+
"name": "ToastGroup",
|
|
11597
|
+
"module": "src/toast-group/ToastGroup.ts"
|
|
11598
|
+
}
|
|
11599
|
+
},
|
|
11600
|
+
{
|
|
11601
|
+
"kind": "custom-element-definition",
|
|
11602
|
+
"name": "nord-toast-group",
|
|
11603
|
+
"declaration": {
|
|
11604
|
+
"name": "ToastGroup",
|
|
11605
|
+
"module": "src/toast-group/ToastGroup.ts"
|
|
11606
|
+
}
|
|
11607
|
+
}
|
|
11608
|
+
],
|
|
11609
|
+
"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 [Toast](/components/toast/) so that toasts get styled and announced to screen readers correctly.\n- Add as close to the bottom of the document as possible, ideally near the body closing tag, to maintain correct stacking order.\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 toast components\n\n</div>\n\n---\n\n## Content guidelines\n\nToast content should be clear, accurate and understandable by the user:\n\n<div class=\"n-usage n-usage-do\">Message sent</div>\n<div class=\"n-usage n-usage-dont\">Your message has been sent</div>\n\nWhen writing the toast content, use the {noun} + {verb} content formula:\n\n<div class=\"n-usage n-usage-do\">Patient created</div>\n<div class=\"n-usage n-usage-dont\">Your patient has been successfully updated</div>\n\nUse a maximum of 3 words when writing the toast content:\n\n<div class=\"n-usage n-usage-do\">Product updated</div>\n<div class=\"n-usage n-usage-dont\">Your product was updated just now</div>\n\nWhen writing the toast 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\">Message sent</div>\n<div class=\"n-usage n-usage-dont\">Message Sent</div>\n\nAvoid unnecessary words and articles in the toast content, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Changes saved</div>\n<div class=\"n-usage n-usage-dont\">The changes were saved</div>\n\nNever end in punctuation:\n\n<div class=\"n-usage n-usage-do\">Message sent</div>\n<div class=\"n-usage n-usage-dont\">Message sent.</div>\n\n---\n\n## Additional considerations\n\n- Toasts are complicated from an accessibility perspective. Whilst they are a convenient UI pattern for messaging, they present difficulties for keyboard or screen reader users. Therefore careful consideration should be given as to whether a toast is the correct choice.\n- If the message cannot be conveyed in 3 words or less, consider re-wording. If the message cannot be shortened any further, consider choosing a different pattern than toast.\n"
|
|
11358
11610
|
},
|
|
11359
11611
|
{
|
|
11360
11612
|
"kind": "javascript-module",
|
|
@@ -14716,258 +14968,6 @@
|
|
|
14716
14968
|
}
|
|
14717
14969
|
}
|
|
14718
14970
|
]
|
|
14719
|
-
},
|
|
14720
|
-
{
|
|
14721
|
-
"kind": "javascript-module",
|
|
14722
|
-
"path": "src/toast-group/ToastGroup.ts",
|
|
14723
|
-
"declarations": [
|
|
14724
|
-
{
|
|
14725
|
-
"kind": "class",
|
|
14726
|
-
"description": "Toast group is used to position and style a group of toasts, whilst ensuring they are announced by screen readers.",
|
|
14727
|
-
"name": "ToastGroup",
|
|
14728
|
-
"slots": [
|
|
14729
|
-
{
|
|
14730
|
-
"description": "Default slot in which to place toasts.",
|
|
14731
|
-
"name": ""
|
|
14732
|
-
}
|
|
14733
|
-
],
|
|
14734
|
-
"members": [
|
|
14735
|
-
{
|
|
14736
|
-
"kind": "method",
|
|
14737
|
-
"name": "addToast",
|
|
14738
|
-
"parameters": [
|
|
14739
|
-
{
|
|
14740
|
-
"name": "text",
|
|
14741
|
-
"type": {
|
|
14742
|
-
"text": "string"
|
|
14743
|
-
},
|
|
14744
|
-
"description": "The text/message of the toast."
|
|
14745
|
-
},
|
|
14746
|
-
{
|
|
14747
|
-
"name": "options",
|
|
14748
|
-
"default": "{}",
|
|
14749
|
-
"type": {
|
|
14750
|
-
"text": "ToastOptions"
|
|
14751
|
-
},
|
|
14752
|
-
"description": "An optional object for configuring the toast's `variant` and `autoDismiss`."
|
|
14753
|
-
}
|
|
14754
|
-
],
|
|
14755
|
-
"description": "Convenience method for creating and adding a toast to the group.",
|
|
14756
|
-
"return": {
|
|
14757
|
-
"type": {
|
|
14758
|
-
"text": ""
|
|
14759
|
-
}
|
|
14760
|
-
}
|
|
14761
|
-
},
|
|
14762
|
-
{
|
|
14763
|
-
"kind": "field",
|
|
14764
|
-
"name": "_warningLogged",
|
|
14765
|
-
"type": {
|
|
14766
|
-
"text": "boolean"
|
|
14767
|
-
},
|
|
14768
|
-
"privacy": "private",
|
|
14769
|
-
"static": true,
|
|
14770
|
-
"default": "false",
|
|
14771
|
-
"inheritedFrom": {
|
|
14772
|
-
"name": "DraftComponentMixin",
|
|
14773
|
-
"module": "src/common/mixins/DraftComponentMixin.ts"
|
|
14774
|
-
}
|
|
14775
|
-
}
|
|
14776
|
-
],
|
|
14777
|
-
"mixins": [
|
|
14778
|
-
{
|
|
14779
|
-
"name": "DraftComponentMixin",
|
|
14780
|
-
"module": "/src/common/mixins/DraftComponentMixin.js"
|
|
14781
|
-
}
|
|
14782
|
-
],
|
|
14783
|
-
"superclass": {
|
|
14784
|
-
"name": "LitElement",
|
|
14785
|
-
"package": "lit"
|
|
14786
|
-
},
|
|
14787
|
-
"status": "draft",
|
|
14788
|
-
"category": "feedback",
|
|
14789
|
-
"displayName": null,
|
|
14790
|
-
"tagName": "nord-toast-group",
|
|
14791
|
-
"customElement": true
|
|
14792
|
-
}
|
|
14793
|
-
],
|
|
14794
|
-
"exports": [
|
|
14795
|
-
{
|
|
14796
|
-
"kind": "js",
|
|
14797
|
-
"name": "default",
|
|
14798
|
-
"declaration": {
|
|
14799
|
-
"name": "ToastGroup",
|
|
14800
|
-
"module": "src/toast-group/ToastGroup.ts"
|
|
14801
|
-
}
|
|
14802
|
-
},
|
|
14803
|
-
{
|
|
14804
|
-
"kind": "custom-element-definition",
|
|
14805
|
-
"name": "nord-toast-group",
|
|
14806
|
-
"declaration": {
|
|
14807
|
-
"name": "ToastGroup",
|
|
14808
|
-
"module": "src/toast-group/ToastGroup.ts"
|
|
14809
|
-
}
|
|
14810
|
-
}
|
|
14811
|
-
],
|
|
14812
|
-
"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 [Toast](/components/toast/) so that toasts get styled and announced to screen readers correctly.\n- Add as close to the bottom of the document as possible, ideally near the body closing tag, to maintain correct stacking order.\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 toast components\n\n</div>\n\n---\n\n## Content guidelines\n\nToast content should be clear, accurate and understandable by the user:\n\n<div class=\"n-usage n-usage-do\">Message sent</div>\n<div class=\"n-usage n-usage-dont\">Your message has been sent</div>\n\nWhen writing the toast content, use the {noun} + {verb} content formula:\n\n<div class=\"n-usage n-usage-do\">Patient created</div>\n<div class=\"n-usage n-usage-dont\">Your patient has been successfully updated</div>\n\nUse a maximum of 3 words when writing the toast content:\n\n<div class=\"n-usage n-usage-do\">Product updated</div>\n<div class=\"n-usage n-usage-dont\">Your product was updated just now</div>\n\nWhen writing the toast 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\">Message sent</div>\n<div class=\"n-usage n-usage-dont\">Message Sent</div>\n\nAvoid unnecessary words and articles in the toast content, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Changes saved</div>\n<div class=\"n-usage n-usage-dont\">The changes were saved</div>\n\nNever end in punctuation:\n\n<div class=\"n-usage n-usage-do\">Message sent</div>\n<div class=\"n-usage n-usage-dont\">Message sent.</div>\n\n---\n\n## Additional considerations\n\n- Toasts are complicated from an accessibility perspective. Whilst they are a convenient UI pattern for messaging, they present difficulties for keyboard or screen reader users. Therefore careful consideration should be given as to whether a toast is the correct choice.\n- If the message cannot be conveyed in 3 words or less, consider re-wording. If the message cannot be shortened any further, consider choosing a different pattern than toast.\n"
|
|
14813
|
-
},
|
|
14814
|
-
{
|
|
14815
|
-
"kind": "javascript-module",
|
|
14816
|
-
"path": "src/toast/Toast.ts",
|
|
14817
|
-
"declarations": [
|
|
14818
|
-
{
|
|
14819
|
-
"kind": "class",
|
|
14820
|
-
"description": "Toasts are non-disruptive messages that appear in the interface\nto provide quick, at-a-glance feedback on the outcome of an action.",
|
|
14821
|
-
"name": "Toast",
|
|
14822
|
-
"slots": [
|
|
14823
|
-
{
|
|
14824
|
-
"description": "Default slot used for the toast text/message.",
|
|
14825
|
-
"name": ""
|
|
14826
|
-
}
|
|
14827
|
-
],
|
|
14828
|
-
"members": [
|
|
14829
|
-
{
|
|
14830
|
-
"kind": "field",
|
|
14831
|
-
"name": "timeoutId",
|
|
14832
|
-
"type": {
|
|
14833
|
-
"text": "ReturnType<typeof setTimeout> | undefined"
|
|
14834
|
-
},
|
|
14835
|
-
"privacy": "private"
|
|
14836
|
-
},
|
|
14837
|
-
{
|
|
14838
|
-
"kind": "field",
|
|
14839
|
-
"name": "events",
|
|
14840
|
-
"privacy": "private",
|
|
14841
|
-
"default": "new EventController(this)"
|
|
14842
|
-
},
|
|
14843
|
-
{
|
|
14844
|
-
"kind": "field",
|
|
14845
|
-
"name": "toast",
|
|
14846
|
-
"type": {
|
|
14847
|
-
"text": "HTMLElement"
|
|
14848
|
-
},
|
|
14849
|
-
"privacy": "private"
|
|
14850
|
-
},
|
|
14851
|
-
{
|
|
14852
|
-
"kind": "field",
|
|
14853
|
-
"name": "dismissed",
|
|
14854
|
-
"type": {
|
|
14855
|
-
"text": "boolean"
|
|
14856
|
-
},
|
|
14857
|
-
"privacy": "private",
|
|
14858
|
-
"default": "false"
|
|
14859
|
-
},
|
|
14860
|
-
{
|
|
14861
|
-
"kind": "field",
|
|
14862
|
-
"name": "variant",
|
|
14863
|
-
"type": {
|
|
14864
|
-
"text": "\"default\" | \"danger\""
|
|
14865
|
-
},
|
|
14866
|
-
"default": "\"default\"",
|
|
14867
|
-
"description": "The style variant of the toast.",
|
|
14868
|
-
"attribute": "variant",
|
|
14869
|
-
"reflects": true
|
|
14870
|
-
},
|
|
14871
|
-
{
|
|
14872
|
-
"kind": "field",
|
|
14873
|
-
"name": "autoDismiss",
|
|
14874
|
-
"type": {
|
|
14875
|
-
"text": "number"
|
|
14876
|
-
},
|
|
14877
|
-
"default": "10000",
|
|
14878
|
-
"description": "Timeout in milliseconds before the toast is automatically dismissed.",
|
|
14879
|
-
"attribute": "auto-dismiss"
|
|
14880
|
-
},
|
|
14881
|
-
{
|
|
14882
|
-
"kind": "method",
|
|
14883
|
-
"name": "dismiss",
|
|
14884
|
-
"description": "Programmatically dismiss the toast.\nThe returned promise resolves when toast's exit animation is complete."
|
|
14885
|
-
},
|
|
14886
|
-
{
|
|
14887
|
-
"kind": "method",
|
|
14888
|
-
"name": "handleAutoDismissChange",
|
|
14889
|
-
"privacy": "protected"
|
|
14890
|
-
},
|
|
14891
|
-
{
|
|
14892
|
-
"kind": "field",
|
|
14893
|
-
"name": "_warningLogged",
|
|
14894
|
-
"type": {
|
|
14895
|
-
"text": "boolean"
|
|
14896
|
-
},
|
|
14897
|
-
"privacy": "private",
|
|
14898
|
-
"static": true,
|
|
14899
|
-
"default": "false",
|
|
14900
|
-
"inheritedFrom": {
|
|
14901
|
-
"name": "DraftComponentMixin",
|
|
14902
|
-
"module": "src/common/mixins/DraftComponentMixin.ts"
|
|
14903
|
-
}
|
|
14904
|
-
}
|
|
14905
|
-
],
|
|
14906
|
-
"events": [
|
|
14907
|
-
{
|
|
14908
|
-
"name": "dismiss",
|
|
14909
|
-
"type": {
|
|
14910
|
-
"text": "NordEvent"
|
|
14911
|
-
},
|
|
14912
|
-
"description": "Fired when the toast is dismissed (via user action or auto-dismiss), and its exit animation has completed. This event should be used to remove the dismissed toast from the DOM."
|
|
14913
|
-
}
|
|
14914
|
-
],
|
|
14915
|
-
"attributes": [
|
|
14916
|
-
{
|
|
14917
|
-
"name": "variant",
|
|
14918
|
-
"type": {
|
|
14919
|
-
"text": "\"default\" | \"danger\""
|
|
14920
|
-
},
|
|
14921
|
-
"default": "\"default\"",
|
|
14922
|
-
"description": "The style variant of the toast.",
|
|
14923
|
-
"fieldName": "variant"
|
|
14924
|
-
},
|
|
14925
|
-
{
|
|
14926
|
-
"name": "auto-dismiss",
|
|
14927
|
-
"type": {
|
|
14928
|
-
"text": "number"
|
|
14929
|
-
},
|
|
14930
|
-
"default": "10000",
|
|
14931
|
-
"description": "Timeout in milliseconds before the toast is automatically dismissed.",
|
|
14932
|
-
"fieldName": "autoDismiss"
|
|
14933
|
-
}
|
|
14934
|
-
],
|
|
14935
|
-
"mixins": [
|
|
14936
|
-
{
|
|
14937
|
-
"name": "DraftComponentMixin",
|
|
14938
|
-
"module": "/src/common/mixins/DraftComponentMixin.js"
|
|
14939
|
-
}
|
|
14940
|
-
],
|
|
14941
|
-
"superclass": {
|
|
14942
|
-
"name": "LitElement",
|
|
14943
|
-
"package": "lit"
|
|
14944
|
-
},
|
|
14945
|
-
"status": "draft",
|
|
14946
|
-
"category": "feedback",
|
|
14947
|
-
"displayName": null,
|
|
14948
|
-
"tagName": "nord-toast",
|
|
14949
|
-
"customElement": true
|
|
14950
|
-
}
|
|
14951
|
-
],
|
|
14952
|
-
"exports": [
|
|
14953
|
-
{
|
|
14954
|
-
"kind": "js",
|
|
14955
|
-
"name": "default",
|
|
14956
|
-
"declaration": {
|
|
14957
|
-
"name": "Toast",
|
|
14958
|
-
"module": "src/toast/Toast.ts"
|
|
14959
|
-
}
|
|
14960
|
-
},
|
|
14961
|
-
{
|
|
14962
|
-
"kind": "custom-element-definition",
|
|
14963
|
-
"name": "nord-toast",
|
|
14964
|
-
"declaration": {
|
|
14965
|
-
"name": "Toast",
|
|
14966
|
-
"module": "src/toast/Toast.ts"
|
|
14967
|
-
}
|
|
14968
|
-
}
|
|
14969
|
-
],
|
|
14970
|
-
"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 confirm an action taken by a user.\n- Use for ephemeral status updates.\n- Use in combination with [Toast group](../toast-group/) so that toasts get styled and announced to screen readers correctly.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use toasts for critical information that user needs to act on.\n- Don’t rely on users seeing toasts. Toasts are transient and should not be used for critical messages.\n- Don’t place interactive content in toasts. Assistive technology like screen readers will not convey any semantics when announcing toast messages.\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\nToast content should be clear, accurate and easy to understand:\n\n<div class=\"n-usage n-usage-do\">Message sent</div>\n<div class=\"n-usage n-usage-dont\">Your message has been sent</div>\n\nWhen writing the toast content, use the {noun} + {verb} content formula:\n\n<div class=\"n-usage n-usage-do\">Patient created</div>\n<div class=\"n-usage n-usage-dont\">Your patient has been successfully updated</div>\n\nUse a maximum of 3 words when writing the toast content:\n\n<div class=\"n-usage n-usage-do\">Product updated</div>\n<div class=\"n-usage n-usage-dont\">Your product was updated just now</div>\n\nWhen writing the toast 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\">Message sent</div>\n<div class=\"n-usage n-usage-dont\">Message Sent</div>\n\nAvoid unnecessary words and articles in the toast content, such as “the”, “an” or “a”:\n\n<div class=\"n-usage n-usage-do\">Changes saved</div>\n<div class=\"n-usage n-usage-dont\">The changes were saved</div>\n\nNever end in punctuation:\n\n<div class=\"n-usage n-usage-do\">Message sent</div>\n<div class=\"n-usage n-usage-dont\">Message sent.</div>\n\n---\n\n## Additional considerations\n\n- Toasts are complicated from an accessibility perspective. Whilst they are a convenient UI pattern for messaging, they present difficulties for keyboard or screen reader users. Therefore careful consideration should be given as to whether a toast is the correct choice.\n- If the message cannot be conveyed in 3 words or less, consider re-wording. If the message cannot be shortened any further, consider choosing a different pattern than toast.\n"
|
|
14971
14971
|
}
|
|
14972
14972
|
]
|
|
14973
14973
|
}
|