@nordhealth/components 1.0.0-beta.7 → 1.0.0-beta.8
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 +830 -830
- package/lib/Banner.js +1 -1
- package/lib/Banner.js.map +1 -1
- package/lib/bundle.js +6 -6
- package/lib/bundle.js.map +1 -1
- package/package.json +3 -3
package/custom-elements.json
CHANGED
|
@@ -462,363 +462,247 @@
|
|
|
462
462
|
},
|
|
463
463
|
{
|
|
464
464
|
"kind": "javascript-module",
|
|
465
|
-
"path": "src/
|
|
465
|
+
"path": "src/button/Button.ts",
|
|
466
466
|
"declarations": [
|
|
467
467
|
{
|
|
468
468
|
"kind": "class",
|
|
469
|
-
"description": "
|
|
470
|
-
"name": "
|
|
469
|
+
"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.",
|
|
470
|
+
"name": "Button",
|
|
471
471
|
"slots": [
|
|
472
472
|
{
|
|
473
|
-
"description": "
|
|
473
|
+
"description": "The button content",
|
|
474
474
|
"name": ""
|
|
475
|
-
}
|
|
476
|
-
],
|
|
477
|
-
"members": [
|
|
478
|
-
{
|
|
479
|
-
"kind": "field",
|
|
480
|
-
"name": "variant",
|
|
481
|
-
"type": {
|
|
482
|
-
"text": "\"info\" | \"danger\" | \"success\" | \"warning\""
|
|
483
|
-
},
|
|
484
|
-
"default": "\"info\"",
|
|
485
|
-
"description": "The style variant of the banner.",
|
|
486
|
-
"attribute": "variant",
|
|
487
|
-
"reflects": true
|
|
488
475
|
},
|
|
489
476
|
{
|
|
490
|
-
"
|
|
491
|
-
"name": "
|
|
492
|
-
|
|
493
|
-
"text": "boolean"
|
|
494
|
-
},
|
|
495
|
-
"privacy": "private",
|
|
496
|
-
"static": true,
|
|
497
|
-
"default": "false",
|
|
498
|
-
"inheritedFrom": {
|
|
499
|
-
"name": "DraftComponentMixin",
|
|
500
|
-
"module": "src/common/mixins/DraftComponentMixin.ts"
|
|
501
|
-
}
|
|
502
|
-
}
|
|
503
|
-
],
|
|
504
|
-
"attributes": [
|
|
505
|
-
{
|
|
506
|
-
"name": "variant",
|
|
507
|
-
"type": {
|
|
508
|
-
"text": "\"info\" | \"danger\" | \"success\" | \"warning\""
|
|
509
|
-
},
|
|
510
|
-
"default": "\"info\"",
|
|
511
|
-
"description": "The style variant of the banner.",
|
|
512
|
-
"fieldName": "variant"
|
|
513
|
-
}
|
|
514
|
-
],
|
|
515
|
-
"mixins": [
|
|
477
|
+
"description": "Used to place content before button text. Typically used for icons.",
|
|
478
|
+
"name": "before"
|
|
479
|
+
},
|
|
516
480
|
{
|
|
517
|
-
"
|
|
518
|
-
"
|
|
481
|
+
"description": "Used to place content after button text. Typically used for icons.",
|
|
482
|
+
"name": "after"
|
|
519
483
|
}
|
|
520
484
|
],
|
|
521
|
-
"superclass": {
|
|
522
|
-
"name": "LitElement",
|
|
523
|
-
"package": "lit"
|
|
524
|
-
},
|
|
525
|
-
"status": "draft",
|
|
526
|
-
"category": "feedback",
|
|
527
|
-
"tagName": "nord-banner",
|
|
528
|
-
"customElement": true
|
|
529
|
-
}
|
|
530
|
-
],
|
|
531
|
-
"exports": [
|
|
532
|
-
{
|
|
533
|
-
"kind": "js",
|
|
534
|
-
"name": "default",
|
|
535
|
-
"declaration": {
|
|
536
|
-
"name": "Banner",
|
|
537
|
-
"module": "src/banner/Banner.ts"
|
|
538
|
-
}
|
|
539
|
-
},
|
|
540
|
-
{
|
|
541
|
-
"kind": "custom-element-definition",
|
|
542
|
-
"name": "nord-banner",
|
|
543
|
-
"declaration": {
|
|
544
|
-
"name": "Banner",
|
|
545
|
-
"module": "src/banner/Banner.ts"
|
|
546
|
-
}
|
|
547
|
-
}
|
|
548
|
-
],
|
|
549
|
-
"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"
|
|
550
|
-
},
|
|
551
|
-
{
|
|
552
|
-
"kind": "javascript-module",
|
|
553
|
-
"path": "src/calendar/Calendar.ts",
|
|
554
|
-
"declarations": [
|
|
555
|
-
{
|
|
556
|
-
"kind": "class",
|
|
557
|
-
"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.",
|
|
558
|
-
"name": "Calendar",
|
|
559
485
|
"members": [
|
|
560
486
|
{
|
|
561
487
|
"kind": "field",
|
|
562
|
-
"name": "
|
|
563
|
-
"type": {
|
|
564
|
-
"text": "string"
|
|
565
|
-
},
|
|
566
|
-
"privacy": "private",
|
|
567
|
-
"default": "\"dialog-header\""
|
|
568
|
-
},
|
|
569
|
-
{
|
|
570
|
-
"kind": "field",
|
|
571
|
-
"name": "monthSelectNode",
|
|
572
|
-
"type": {
|
|
573
|
-
"text": "HTMLElement"
|
|
574
|
-
},
|
|
575
|
-
"privacy": "private"
|
|
576
|
-
},
|
|
577
|
-
{
|
|
578
|
-
"kind": "field",
|
|
579
|
-
"name": "focusedDayNode",
|
|
580
|
-
"type": {
|
|
581
|
-
"text": "HTMLButtonElement"
|
|
582
|
-
},
|
|
583
|
-
"privacy": "private"
|
|
584
|
-
},
|
|
585
|
-
{
|
|
586
|
-
"kind": "field",
|
|
587
|
-
"name": "direction",
|
|
588
|
-
"privacy": "private",
|
|
589
|
-
"default": "new DirectionController(this)"
|
|
590
|
-
},
|
|
591
|
-
{
|
|
592
|
-
"kind": "field",
|
|
593
|
-
"name": "swipe",
|
|
594
|
-
"privacy": "private",
|
|
595
|
-
"default": "new SwipeController(this, {\n matchesGesture: isHorizontalSwipe,\n onSwipeEnd: ({ distX }) => this.addMonths(distX < 0 ? 1 : -1),\n })"
|
|
596
|
-
},
|
|
597
|
-
{
|
|
598
|
-
"kind": "field",
|
|
599
|
-
"name": "shortcuts",
|
|
488
|
+
"name": "buttonRef",
|
|
600
489
|
"privacy": "private"
|
|
601
490
|
},
|
|
602
491
|
{
|
|
603
492
|
"kind": "field",
|
|
604
|
-
"name": "
|
|
605
|
-
"type": {
|
|
606
|
-
"text": "Intl.DateTimeFormat"
|
|
607
|
-
},
|
|
493
|
+
"name": "lightDom",
|
|
608
494
|
"privacy": "private",
|
|
609
|
-
"
|
|
495
|
+
"default": "new LightDomController(this, {\n render: () => this.renderLightDom(),\n })"
|
|
610
496
|
},
|
|
611
497
|
{
|
|
612
498
|
"kind": "field",
|
|
613
|
-
"name": "
|
|
499
|
+
"name": "variant",
|
|
614
500
|
"type": {
|
|
615
|
-
"text": "
|
|
501
|
+
"text": "\"default\" | \"primary\" | \"dashed\" | \"plain\" | \"danger\""
|
|
616
502
|
},
|
|
617
|
-
"default": "
|
|
503
|
+
"default": "\"default\"",
|
|
504
|
+
"description": "The style variant of the button.",
|
|
505
|
+
"attribute": "variant",
|
|
506
|
+
"reflects": true
|
|
618
507
|
},
|
|
619
508
|
{
|
|
620
509
|
"kind": "field",
|
|
621
|
-
"name": "
|
|
510
|
+
"name": "type",
|
|
622
511
|
"type": {
|
|
623
|
-
"text": "
|
|
512
|
+
"text": "\"button\" | \"submit\" | \"reset\""
|
|
624
513
|
},
|
|
625
|
-
"default": "\"\"",
|
|
626
|
-
"description": "The
|
|
627
|
-
"attribute": "
|
|
514
|
+
"default": "\"submit\"",
|
|
515
|
+
"description": "The type of the button.",
|
|
516
|
+
"attribute": "type",
|
|
517
|
+
"reflects": true
|
|
628
518
|
},
|
|
629
519
|
{
|
|
630
520
|
"kind": "field",
|
|
631
|
-
"name": "
|
|
521
|
+
"name": "size",
|
|
632
522
|
"type": {
|
|
633
|
-
"text": "
|
|
523
|
+
"text": "\"s\" | \"m\" | \"l\""
|
|
634
524
|
},
|
|
635
|
-
"
|
|
636
|
-
"
|
|
525
|
+
"default": "\"m\"",
|
|
526
|
+
"description": "The size of the button.\nThis affects font-size and padding.",
|
|
527
|
+
"attribute": "size",
|
|
528
|
+
"reflects": true
|
|
637
529
|
},
|
|
638
530
|
{
|
|
639
531
|
"kind": "field",
|
|
640
|
-
"name": "
|
|
532
|
+
"name": "href",
|
|
641
533
|
"type": {
|
|
642
|
-
"text": "string"
|
|
534
|
+
"text": "string | undefined"
|
|
643
535
|
},
|
|
644
|
-
"
|
|
645
|
-
"
|
|
646
|
-
"
|
|
536
|
+
"description": "When provided, renders the button as a link,\nwith its href attribute set to the given value.",
|
|
537
|
+
"attribute": "href",
|
|
538
|
+
"reflects": true
|
|
647
539
|
},
|
|
648
540
|
{
|
|
649
541
|
"kind": "field",
|
|
650
|
-
"name": "
|
|
542
|
+
"name": "download",
|
|
651
543
|
"type": {
|
|
652
|
-
"text": "
|
|
544
|
+
"text": "boolean"
|
|
653
545
|
},
|
|
654
|
-
"default": "
|
|
655
|
-
"description": "
|
|
656
|
-
"attribute": "
|
|
546
|
+
"default": "false",
|
|
547
|
+
"description": "When provided together with a href property, the button will\ntrigger a file download instead of a page visit.",
|
|
548
|
+
"attribute": "download"
|
|
657
549
|
},
|
|
658
550
|
{
|
|
659
551
|
"kind": "field",
|
|
660
|
-
"name": "
|
|
552
|
+
"name": "target",
|
|
661
553
|
"type": {
|
|
662
|
-
"text": "
|
|
554
|
+
"text": "\"_self\" | \"_blank\" | \"_parent\" | \"_top\""
|
|
663
555
|
},
|
|
664
|
-
"default": "
|
|
665
|
-
"description": "
|
|
556
|
+
"default": "\"_self\"",
|
|
557
|
+
"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.",
|
|
558
|
+
"attribute": "target",
|
|
559
|
+
"reflects": true
|
|
666
560
|
},
|
|
667
561
|
{
|
|
668
562
|
"kind": "field",
|
|
669
|
-
"name": "
|
|
563
|
+
"name": "expand",
|
|
670
564
|
"type": {
|
|
671
565
|
"text": "boolean"
|
|
672
566
|
},
|
|
673
|
-
"
|
|
674
|
-
"
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
"kind": "field",
|
|
678
|
-
"name": "focusedDay",
|
|
679
|
-
"privacy": "private",
|
|
680
|
-
"default": "new Date()"
|
|
567
|
+
"default": "false",
|
|
568
|
+
"description": "Controls whether the button expands to fill the width of its container.",
|
|
569
|
+
"attribute": "expand",
|
|
570
|
+
"reflects": true
|
|
681
571
|
},
|
|
682
572
|
{
|
|
683
573
|
"kind": "method",
|
|
684
|
-
"name": "
|
|
574
|
+
"name": "renderLink",
|
|
575
|
+
"privacy": "private",
|
|
685
576
|
"parameters": [
|
|
686
577
|
{
|
|
687
|
-
"name": "
|
|
688
|
-
"optional": true,
|
|
578
|
+
"name": "innards",
|
|
689
579
|
"type": {
|
|
690
|
-
"text": "
|
|
580
|
+
"text": "TemplateResult"
|
|
691
581
|
}
|
|
692
582
|
}
|
|
693
|
-
]
|
|
694
|
-
|
|
695
|
-
{
|
|
696
|
-
"kind": "method",
|
|
697
|
-
"name": "createDateFormatter",
|
|
698
|
-
"privacy": "private"
|
|
699
|
-
},
|
|
700
|
-
{
|
|
701
|
-
"kind": "field",
|
|
702
|
-
"name": "handleDaySelect",
|
|
703
|
-
"privacy": "private"
|
|
583
|
+
],
|
|
584
|
+
"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."
|
|
704
585
|
},
|
|
705
586
|
{
|
|
706
587
|
"kind": "method",
|
|
707
|
-
"name": "
|
|
588
|
+
"name": "renderButton",
|
|
708
589
|
"privacy": "private",
|
|
709
590
|
"parameters": [
|
|
710
591
|
{
|
|
711
|
-
"name": "
|
|
592
|
+
"name": "innards",
|
|
712
593
|
"type": {
|
|
713
|
-
"text": "
|
|
594
|
+
"text": "TemplateResult"
|
|
714
595
|
}
|
|
715
596
|
}
|
|
716
597
|
]
|
|
717
598
|
},
|
|
718
599
|
{
|
|
719
600
|
"kind": "method",
|
|
720
|
-
"name": "
|
|
721
|
-
"privacy": "private"
|
|
722
|
-
"parameters": [
|
|
723
|
-
{
|
|
724
|
-
"name": "months",
|
|
725
|
-
"type": {
|
|
726
|
-
"text": "number"
|
|
727
|
-
}
|
|
728
|
-
}
|
|
729
|
-
]
|
|
601
|
+
"name": "renderLightDom",
|
|
602
|
+
"privacy": "private"
|
|
730
603
|
},
|
|
731
604
|
{
|
|
732
605
|
"kind": "method",
|
|
733
|
-
"name": "
|
|
734
|
-
"privacy": "private",
|
|
735
|
-
"parameters": [
|
|
736
|
-
{
|
|
737
|
-
"name": "years",
|
|
738
|
-
"type": {
|
|
739
|
-
"text": "number"
|
|
740
|
-
}
|
|
741
|
-
}
|
|
742
|
-
]
|
|
743
|
-
},
|
|
744
|
-
{
|
|
745
|
-
"kind": "method",
|
|
746
|
-
"name": "startOfWeek",
|
|
747
|
-
"privacy": "private"
|
|
748
|
-
},
|
|
749
|
-
{
|
|
750
|
-
"kind": "method",
|
|
751
|
-
"name": "endOfWeek",
|
|
606
|
+
"name": "handleClick",
|
|
752
607
|
"privacy": "private"
|
|
753
608
|
},
|
|
754
609
|
{
|
|
755
|
-
"kind": "
|
|
756
|
-
"name": "
|
|
757
|
-
"
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
"kind": "method",
|
|
769
|
-
"name": "setYear",
|
|
770
|
-
"privacy": "private",
|
|
771
|
-
"parameters": [
|
|
772
|
-
{
|
|
773
|
-
"name": "year",
|
|
774
|
-
"type": {
|
|
775
|
-
"text": "number"
|
|
776
|
-
}
|
|
777
|
-
}
|
|
778
|
-
]
|
|
610
|
+
"kind": "field",
|
|
611
|
+
"name": "disabled",
|
|
612
|
+
"type": {
|
|
613
|
+
"text": "boolean"
|
|
614
|
+
},
|
|
615
|
+
"default": "false",
|
|
616
|
+
"description": "Makes the component disabled. This prevents users from\nbeing able to interact with the component, and conveys\nits inactive state to assistive technologies.",
|
|
617
|
+
"attribute": "disabled",
|
|
618
|
+
"reflects": true,
|
|
619
|
+
"inheritedFrom": {
|
|
620
|
+
"name": "InputMixin",
|
|
621
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
622
|
+
}
|
|
779
623
|
},
|
|
780
624
|
{
|
|
781
|
-
"kind": "
|
|
782
|
-
"name": "
|
|
783
|
-
"
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
625
|
+
"kind": "field",
|
|
626
|
+
"name": "name",
|
|
627
|
+
"type": {
|
|
628
|
+
"text": "string | undefined"
|
|
629
|
+
},
|
|
630
|
+
"description": "The name of the form component.",
|
|
631
|
+
"attribute": "name",
|
|
632
|
+
"inheritedFrom": {
|
|
633
|
+
"name": "InputMixin",
|
|
634
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
635
|
+
}
|
|
792
636
|
},
|
|
793
637
|
{
|
|
794
638
|
"kind": "field",
|
|
795
|
-
"name": "
|
|
796
|
-
"
|
|
639
|
+
"name": "value",
|
|
640
|
+
"type": {
|
|
641
|
+
"text": "string"
|
|
642
|
+
},
|
|
643
|
+
"default": "\"\"",
|
|
644
|
+
"description": "The value of the form component.",
|
|
645
|
+
"attribute": "value",
|
|
646
|
+
"inheritedFrom": {
|
|
647
|
+
"name": "InputMixin",
|
|
648
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
649
|
+
}
|
|
797
650
|
},
|
|
798
651
|
{
|
|
799
652
|
"kind": "field",
|
|
800
|
-
"name": "
|
|
801
|
-
"privacy": "
|
|
653
|
+
"name": "form",
|
|
654
|
+
"privacy": "protected",
|
|
655
|
+
"description": "Gets the form, if any, associated with the form element.",
|
|
656
|
+
"inheritedFrom": {
|
|
657
|
+
"name": "InputMixin",
|
|
658
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
659
|
+
}
|
|
802
660
|
},
|
|
803
661
|
{
|
|
804
662
|
"kind": "field",
|
|
805
|
-
"name": "
|
|
806
|
-
"privacy": "
|
|
663
|
+
"name": "focusableRef",
|
|
664
|
+
"privacy": "protected",
|
|
665
|
+
"inheritedFrom": {
|
|
666
|
+
"name": "FocusableMixin",
|
|
667
|
+
"module": "src/common/mixins/FocusableMixin.ts"
|
|
668
|
+
}
|
|
807
669
|
},
|
|
808
670
|
{
|
|
809
|
-
"kind": "
|
|
810
|
-
"name": "
|
|
811
|
-
"
|
|
671
|
+
"kind": "method",
|
|
672
|
+
"name": "focus",
|
|
673
|
+
"parameters": [
|
|
674
|
+
{
|
|
675
|
+
"name": "options",
|
|
676
|
+
"optional": true,
|
|
677
|
+
"type": {
|
|
678
|
+
"text": "FocusOptions"
|
|
679
|
+
},
|
|
680
|
+
"description": "An object which controls aspects of the focusing process."
|
|
681
|
+
}
|
|
682
|
+
],
|
|
683
|
+
"description": "Programmatically move focus to the component.",
|
|
684
|
+
"inheritedFrom": {
|
|
685
|
+
"name": "FocusableMixin",
|
|
686
|
+
"module": "src/common/mixins/FocusableMixin.ts"
|
|
687
|
+
}
|
|
812
688
|
},
|
|
813
689
|
{
|
|
814
|
-
"kind": "
|
|
815
|
-
"name": "
|
|
816
|
-
"
|
|
690
|
+
"kind": "method",
|
|
691
|
+
"name": "blur",
|
|
692
|
+
"description": "Programmatically remove focus from the component.",
|
|
693
|
+
"inheritedFrom": {
|
|
694
|
+
"name": "FocusableMixin",
|
|
695
|
+
"module": "src/common/mixins/FocusableMixin.ts"
|
|
696
|
+
}
|
|
817
697
|
},
|
|
818
698
|
{
|
|
819
|
-
"kind": "
|
|
820
|
-
"name": "
|
|
821
|
-
"
|
|
699
|
+
"kind": "method",
|
|
700
|
+
"name": "click",
|
|
701
|
+
"description": "Programmatically simulates a click on the component.",
|
|
702
|
+
"inheritedFrom": {
|
|
703
|
+
"name": "FocusableMixin",
|
|
704
|
+
"module": "src/common/mixins/FocusableMixin.ts"
|
|
705
|
+
}
|
|
822
706
|
},
|
|
823
707
|
{
|
|
824
708
|
"kind": "field",
|
|
@@ -837,42 +721,115 @@
|
|
|
837
721
|
],
|
|
838
722
|
"attributes": [
|
|
839
723
|
{
|
|
840
|
-
"name": "
|
|
724
|
+
"name": "variant",
|
|
841
725
|
"type": {
|
|
842
|
-
"text": "
|
|
726
|
+
"text": "\"default\" | \"primary\" | \"dashed\" | \"plain\" | \"danger\""
|
|
843
727
|
},
|
|
844
|
-
"default": "\"\"",
|
|
845
|
-
"description": "The
|
|
846
|
-
"fieldName": "
|
|
728
|
+
"default": "\"default\"",
|
|
729
|
+
"description": "The style variant of the button.",
|
|
730
|
+
"fieldName": "variant"
|
|
847
731
|
},
|
|
848
732
|
{
|
|
849
|
-
"name": "
|
|
733
|
+
"name": "type",
|
|
850
734
|
"type": {
|
|
851
|
-
"text": "
|
|
735
|
+
"text": "\"button\" | \"submit\" | \"reset\""
|
|
852
736
|
},
|
|
853
|
-
"
|
|
854
|
-
"
|
|
737
|
+
"default": "\"submit\"",
|
|
738
|
+
"description": "The type of the button.",
|
|
739
|
+
"fieldName": "type"
|
|
855
740
|
},
|
|
856
741
|
{
|
|
857
|
-
"name": "
|
|
742
|
+
"name": "size",
|
|
858
743
|
"type": {
|
|
859
|
-
"text": "
|
|
744
|
+
"text": "\"s\" | \"m\" | \"l\""
|
|
860
745
|
},
|
|
861
|
-
"default": "\"\"",
|
|
862
|
-
"description": "
|
|
863
|
-
"fieldName": "
|
|
746
|
+
"default": "\"m\"",
|
|
747
|
+
"description": "The size of the button.\nThis affects font-size and padding.",
|
|
748
|
+
"fieldName": "size"
|
|
864
749
|
},
|
|
865
750
|
{
|
|
866
|
-
"name": "
|
|
751
|
+
"name": "href",
|
|
752
|
+
"type": {
|
|
753
|
+
"text": "string | undefined"
|
|
754
|
+
},
|
|
755
|
+
"description": "When provided, renders the button as a link,\nwith its href attribute set to the given value.",
|
|
756
|
+
"fieldName": "href"
|
|
757
|
+
},
|
|
758
|
+
{
|
|
759
|
+
"name": "download",
|
|
760
|
+
"type": {
|
|
761
|
+
"text": "boolean"
|
|
762
|
+
},
|
|
763
|
+
"default": "false",
|
|
764
|
+
"description": "When provided together with a href property, the button will\ntrigger a file download instead of a page visit.",
|
|
765
|
+
"fieldName": "download"
|
|
766
|
+
},
|
|
767
|
+
{
|
|
768
|
+
"name": "target",
|
|
769
|
+
"type": {
|
|
770
|
+
"text": "\"_self\" | \"_blank\" | \"_parent\" | \"_top\""
|
|
771
|
+
},
|
|
772
|
+
"default": "\"_self\"",
|
|
773
|
+
"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.",
|
|
774
|
+
"fieldName": "target"
|
|
775
|
+
},
|
|
776
|
+
{
|
|
777
|
+
"name": "expand",
|
|
778
|
+
"type": {
|
|
779
|
+
"text": "boolean"
|
|
780
|
+
},
|
|
781
|
+
"default": "false",
|
|
782
|
+
"description": "Controls whether the button expands to fill the width of its container.",
|
|
783
|
+
"fieldName": "expand"
|
|
784
|
+
},
|
|
785
|
+
{
|
|
786
|
+
"name": "disabled",
|
|
787
|
+
"type": {
|
|
788
|
+
"text": "boolean"
|
|
789
|
+
},
|
|
790
|
+
"default": "false",
|
|
791
|
+
"description": "Makes the component disabled. This prevents users from\nbeing able to interact with the component, and conveys\nits inactive state to assistive technologies.",
|
|
792
|
+
"fieldName": "disabled",
|
|
793
|
+
"inheritedFrom": {
|
|
794
|
+
"name": "InputMixin",
|
|
795
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
796
|
+
}
|
|
797
|
+
},
|
|
798
|
+
{
|
|
799
|
+
"name": "name",
|
|
800
|
+
"type": {
|
|
801
|
+
"text": "string | undefined"
|
|
802
|
+
},
|
|
803
|
+
"description": "The name of the form component.",
|
|
804
|
+
"fieldName": "name",
|
|
805
|
+
"inheritedFrom": {
|
|
806
|
+
"name": "InputMixin",
|
|
807
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
808
|
+
}
|
|
809
|
+
},
|
|
810
|
+
{
|
|
811
|
+
"name": "value",
|
|
867
812
|
"type": {
|
|
868
813
|
"text": "string"
|
|
869
814
|
},
|
|
870
815
|
"default": "\"\"",
|
|
871
|
-
"description": "
|
|
872
|
-
"fieldName": "
|
|
816
|
+
"description": "The value of the form component.",
|
|
817
|
+
"fieldName": "value",
|
|
818
|
+
"inheritedFrom": {
|
|
819
|
+
"name": "InputMixin",
|
|
820
|
+
"module": "src/common/mixins/InputMixin.ts"
|
|
821
|
+
}
|
|
873
822
|
}
|
|
874
823
|
],
|
|
875
824
|
"mixins": [
|
|
825
|
+
{
|
|
826
|
+
"name": "InputMixin",
|
|
827
|
+
"module": "/src/common/mixins/InputMixin.js"
|
|
828
|
+
},
|
|
829
|
+
{
|
|
830
|
+
"name": "FocusableMixin",
|
|
831
|
+
"module": "/src/common/mixins/FocusableMixin.js"
|
|
832
|
+
},
|
|
876
833
|
{
|
|
877
834
|
"name": "DraftComponentMixin",
|
|
878
835
|
"module": "/src/common/mixins/DraftComponentMixin.js"
|
|
@@ -883,8 +840,8 @@
|
|
|
883
840
|
"package": "lit"
|
|
884
841
|
},
|
|
885
842
|
"status": "draft",
|
|
886
|
-
"category": "
|
|
887
|
-
"tagName": "nord-
|
|
843
|
+
"category": "action",
|
|
844
|
+
"tagName": "nord-button",
|
|
888
845
|
"customElement": true
|
|
889
846
|
}
|
|
890
847
|
],
|
|
@@ -893,383 +850,292 @@
|
|
|
893
850
|
"kind": "js",
|
|
894
851
|
"name": "default",
|
|
895
852
|
"declaration": {
|
|
896
|
-
"name": "
|
|
897
|
-
"module": "src/
|
|
853
|
+
"name": "Button",
|
|
854
|
+
"module": "src/button/Button.ts"
|
|
898
855
|
}
|
|
899
856
|
},
|
|
900
857
|
{
|
|
901
858
|
"kind": "custom-element-definition",
|
|
902
|
-
"name": "nord-
|
|
859
|
+
"name": "nord-button",
|
|
903
860
|
"declaration": {
|
|
904
|
-
"name": "
|
|
905
|
-
"module": "src/
|
|
861
|
+
"name": "Button",
|
|
862
|
+
"module": "src/button/Button.ts"
|
|
906
863
|
}
|
|
907
864
|
}
|
|
908
865
|
],
|
|
909
|
-
"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
|
|
866
|
+
"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 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 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\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"
|
|
910
867
|
},
|
|
911
868
|
{
|
|
912
869
|
"kind": "javascript-module",
|
|
913
|
-
"path": "src/calendar/
|
|
870
|
+
"path": "src/calendar/Calendar.ts",
|
|
914
871
|
"declarations": [
|
|
915
872
|
{
|
|
916
873
|
"kind": "class",
|
|
917
|
-
"description": "",
|
|
918
|
-
"name": "
|
|
874
|
+
"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.",
|
|
875
|
+
"name": "Calendar",
|
|
919
876
|
"members": [
|
|
920
877
|
{
|
|
921
878
|
"kind": "field",
|
|
922
|
-
"name": "
|
|
879
|
+
"name": "dialogLabelId",
|
|
923
880
|
"type": {
|
|
924
881
|
"text": "string"
|
|
925
882
|
},
|
|
926
|
-
"
|
|
927
|
-
"default": "\"
|
|
883
|
+
"privacy": "private",
|
|
884
|
+
"default": "\"dialog-header\""
|
|
928
885
|
},
|
|
929
886
|
{
|
|
930
887
|
"kind": "field",
|
|
931
|
-
"name": "
|
|
888
|
+
"name": "monthSelectNode",
|
|
932
889
|
"type": {
|
|
933
|
-
"text": "
|
|
890
|
+
"text": "HTMLElement"
|
|
934
891
|
},
|
|
935
|
-
"
|
|
936
|
-
}
|
|
937
|
-
],
|
|
938
|
-
"superclass": {
|
|
939
|
-
"name": "NordEvent",
|
|
940
|
-
"module": "/src/common/events.js"
|
|
941
|
-
}
|
|
942
|
-
}
|
|
943
|
-
],
|
|
944
|
-
"exports": [
|
|
945
|
-
{
|
|
946
|
-
"kind": "js",
|
|
947
|
-
"name": "DateSelectEvent",
|
|
948
|
-
"declaration": {
|
|
949
|
-
"name": "DateSelectEvent",
|
|
950
|
-
"module": "src/calendar/DateSelectEvent.ts"
|
|
951
|
-
}
|
|
952
|
-
}
|
|
953
|
-
],
|
|
954
|
-
"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"
|
|
955
|
-
},
|
|
956
|
-
{
|
|
957
|
-
"kind": "javascript-module",
|
|
958
|
-
"path": "src/calendar/calendar-localization.ts",
|
|
959
|
-
"declarations": [
|
|
960
|
-
{
|
|
961
|
-
"kind": "variable",
|
|
962
|
-
"name": "localization",
|
|
963
|
-
"type": {
|
|
964
|
-
"text": "CalendarLocalizedText"
|
|
965
|
-
},
|
|
966
|
-
"default": "{\n prevMonthLabel: \"Previous month\",\n nextMonthLabel: \"Next month\",\n monthSelectLabel: \"Month\",\n yearSelectLabel: \"Year\",\n calendarHeading: \"Choose a date\",\n dayNames: [\"Sunday\", \"Monday\", \"Tuesday\", \"Wednesday\", \"Thursday\", \"Friday\", \"Saturday\"],\n monthNames: [\n \"January\",\n \"February\",\n \"March\",\n \"April\",\n \"May\",\n \"June\",\n \"July\",\n \"August\",\n \"September\",\n \"October\",\n \"November\",\n \"December\",\n ],\n monthNamesShort: [\"Jan\", \"Feb\", \"Mar\", \"Apr\", \"May\", \"Jun\", \"Jul\", \"Aug\", \"Sep\", \"Oct\", \"Nov\", \"Dec\"],\n locale: \"en-GB\",\n}"
|
|
967
|
-
}
|
|
968
|
-
],
|
|
969
|
-
"exports": [
|
|
970
|
-
{
|
|
971
|
-
"kind": "js",
|
|
972
|
-
"name": "default",
|
|
973
|
-
"declaration": {
|
|
974
|
-
"name": "localization",
|
|
975
|
-
"module": "src/calendar/calendar-localization.ts"
|
|
976
|
-
}
|
|
977
|
-
}
|
|
978
|
-
],
|
|
979
|
-
"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"
|
|
980
|
-
},
|
|
981
|
-
{
|
|
982
|
-
"kind": "javascript-module",
|
|
983
|
-
"path": "src/calendar/month-view.ts",
|
|
984
|
-
"declarations": [
|
|
985
|
-
{
|
|
986
|
-
"kind": "function",
|
|
987
|
-
"name": "dayView",
|
|
988
|
-
"parameters": [
|
|
989
|
-
{
|
|
990
|
-
"name": "{\n focusedDay,\n today,\n day,\n onDaySelect,\n onKeyboardNavigation,\n disabled,\n inRange,\n isSelected,\n dateFormatter,\n}",
|
|
991
|
-
"type": {
|
|
992
|
-
"text": "DatePickerDayProps"
|
|
993
|
-
}
|
|
994
|
-
}
|
|
995
|
-
]
|
|
996
|
-
},
|
|
997
|
-
{
|
|
998
|
-
"kind": "function",
|
|
999
|
-
"name": "monthView",
|
|
1000
|
-
"parameters": [
|
|
892
|
+
"privacy": "private"
|
|
893
|
+
},
|
|
1001
894
|
{
|
|
1002
|
-
"
|
|
895
|
+
"kind": "field",
|
|
896
|
+
"name": "focusedDayNode",
|
|
1003
897
|
"type": {
|
|
1004
|
-
"text": "
|
|
1005
|
-
}
|
|
1006
|
-
|
|
1007
|
-
]
|
|
1008
|
-
}
|
|
1009
|
-
],
|
|
1010
|
-
"exports": [
|
|
1011
|
-
{
|
|
1012
|
-
"kind": "js",
|
|
1013
|
-
"name": "dayView",
|
|
1014
|
-
"declaration": {
|
|
1015
|
-
"name": "dayView",
|
|
1016
|
-
"module": "src/calendar/month-view.ts"
|
|
1017
|
-
}
|
|
1018
|
-
},
|
|
1019
|
-
{
|
|
1020
|
-
"kind": "js",
|
|
1021
|
-
"name": "monthView",
|
|
1022
|
-
"declaration": {
|
|
1023
|
-
"name": "monthView",
|
|
1024
|
-
"module": "src/calendar/month-view.ts"
|
|
1025
|
-
}
|
|
1026
|
-
}
|
|
1027
|
-
],
|
|
1028
|
-
"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"
|
|
1029
|
-
},
|
|
1030
|
-
{
|
|
1031
|
-
"kind": "javascript-module",
|
|
1032
|
-
"path": "src/button/Button.ts",
|
|
1033
|
-
"declarations": [
|
|
1034
|
-
{
|
|
1035
|
-
"kind": "class",
|
|
1036
|
-
"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.",
|
|
1037
|
-
"name": "Button",
|
|
1038
|
-
"slots": [
|
|
1039
|
-
{
|
|
1040
|
-
"description": "The button content",
|
|
1041
|
-
"name": ""
|
|
898
|
+
"text": "HTMLButtonElement"
|
|
899
|
+
},
|
|
900
|
+
"privacy": "private"
|
|
1042
901
|
},
|
|
1043
902
|
{
|
|
1044
|
-
"
|
|
1045
|
-
"name": "
|
|
903
|
+
"kind": "field",
|
|
904
|
+
"name": "direction",
|
|
905
|
+
"privacy": "private",
|
|
906
|
+
"default": "new DirectionController(this)"
|
|
1046
907
|
},
|
|
1047
908
|
{
|
|
1048
|
-
"
|
|
1049
|
-
"name": "
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
909
|
+
"kind": "field",
|
|
910
|
+
"name": "swipe",
|
|
911
|
+
"privacy": "private",
|
|
912
|
+
"default": "new SwipeController(this, {\n matchesGesture: isHorizontalSwipe,\n onSwipeEnd: ({ distX }) => this.addMonths(distX < 0 ? 1 : -1),\n })"
|
|
913
|
+
},
|
|
1053
914
|
{
|
|
1054
915
|
"kind": "field",
|
|
1055
|
-
"name": "
|
|
916
|
+
"name": "shortcuts",
|
|
1056
917
|
"privacy": "private"
|
|
1057
918
|
},
|
|
1058
919
|
{
|
|
1059
920
|
"kind": "field",
|
|
1060
|
-
"name": "
|
|
921
|
+
"name": "dateFormatShort",
|
|
922
|
+
"type": {
|
|
923
|
+
"text": "Intl.DateTimeFormat"
|
|
924
|
+
},
|
|
1061
925
|
"privacy": "private",
|
|
1062
|
-
"
|
|
926
|
+
"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"
|
|
1063
927
|
},
|
|
1064
928
|
{
|
|
1065
929
|
"kind": "field",
|
|
1066
|
-
"name": "
|
|
930
|
+
"name": "localization",
|
|
1067
931
|
"type": {
|
|
1068
|
-
"text": "
|
|
932
|
+
"text": "CalendarLocalizedText"
|
|
1069
933
|
},
|
|
1070
|
-
"default": "
|
|
1071
|
-
"description": "The style variant of the button.",
|
|
1072
|
-
"attribute": "variant",
|
|
1073
|
-
"reflects": true
|
|
934
|
+
"default": "localization"
|
|
1074
935
|
},
|
|
1075
936
|
{
|
|
1076
937
|
"kind": "field",
|
|
1077
|
-
"name": "
|
|
938
|
+
"name": "value",
|
|
1078
939
|
"type": {
|
|
1079
|
-
"text": "
|
|
940
|
+
"text": "string"
|
|
1080
941
|
},
|
|
1081
|
-
"default": "\"
|
|
1082
|
-
"description": "The
|
|
1083
|
-
"attribute": "
|
|
1084
|
-
"reflects": true
|
|
942
|
+
"default": "\"\"",
|
|
943
|
+
"description": "The selected date on the calendar. Must be in IS0-8601 format: YYYY-MM-DD.",
|
|
944
|
+
"attribute": "value"
|
|
1085
945
|
},
|
|
1086
946
|
{
|
|
1087
947
|
"kind": "field",
|
|
1088
|
-
"name": "
|
|
948
|
+
"name": "firstDayOfWeek",
|
|
1089
949
|
"type": {
|
|
1090
|
-
"text": "
|
|
950
|
+
"text": "DaysOfWeek"
|
|
1091
951
|
},
|
|
1092
|
-
"
|
|
1093
|
-
"
|
|
1094
|
-
"attribute": "size",
|
|
1095
|
-
"reflects": true
|
|
952
|
+
"description": "Which day is considered first day of the week? `0` for Sunday, `1` for Monday, etc.\nDefault is Monday.",
|
|
953
|
+
"attribute": "firstDayOfWeek"
|
|
1096
954
|
},
|
|
1097
955
|
{
|
|
1098
956
|
"kind": "field",
|
|
1099
|
-
"name": "
|
|
957
|
+
"name": "min",
|
|
1100
958
|
"type": {
|
|
1101
|
-
"text": "string
|
|
959
|
+
"text": "string"
|
|
1102
960
|
},
|
|
1103
|
-
"
|
|
1104
|
-
"
|
|
1105
|
-
"
|
|
961
|
+
"default": "\"\"",
|
|
962
|
+
"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.",
|
|
963
|
+
"attribute": "min"
|
|
1106
964
|
},
|
|
1107
965
|
{
|
|
1108
966
|
"kind": "field",
|
|
1109
|
-
"name": "
|
|
967
|
+
"name": "max",
|
|
1110
968
|
"type": {
|
|
1111
|
-
"text": "
|
|
969
|
+
"text": "string"
|
|
1112
970
|
},
|
|
1113
|
-
"default": "
|
|
1114
|
-
"description": "
|
|
1115
|
-
"attribute": "
|
|
971
|
+
"default": "\"\"",
|
|
972
|
+
"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.",
|
|
973
|
+
"attribute": "max"
|
|
1116
974
|
},
|
|
1117
975
|
{
|
|
1118
976
|
"kind": "field",
|
|
1119
|
-
"name": "
|
|
977
|
+
"name": "isDateDisabled",
|
|
1120
978
|
"type": {
|
|
1121
|
-
"text": "
|
|
979
|
+
"text": "DateDisabledPredicate"
|
|
1122
980
|
},
|
|
1123
|
-
"default": "
|
|
1124
|
-
"description": "
|
|
1125
|
-
"attribute": "target",
|
|
1126
|
-
"reflects": true
|
|
981
|
+
"default": "isDateDisabled",
|
|
982
|
+
"description": "Controls which days are disabled and therefore disallowed.\nFor example, this can be used to disallow selection of weekends."
|
|
1127
983
|
},
|
|
1128
984
|
{
|
|
1129
985
|
"kind": "field",
|
|
1130
|
-
"name": "
|
|
986
|
+
"name": "activeFocus",
|
|
1131
987
|
"type": {
|
|
1132
988
|
"text": "boolean"
|
|
1133
989
|
},
|
|
1134
|
-
"
|
|
1135
|
-
"
|
|
1136
|
-
"attribute": "expand",
|
|
1137
|
-
"reflects": true
|
|
990
|
+
"privacy": "private",
|
|
991
|
+
"default": "false"
|
|
1138
992
|
},
|
|
1139
993
|
{
|
|
1140
|
-
"kind": "
|
|
1141
|
-
"name": "
|
|
994
|
+
"kind": "field",
|
|
995
|
+
"name": "focusedDay",
|
|
1142
996
|
"privacy": "private",
|
|
1143
|
-
"
|
|
1144
|
-
{
|
|
1145
|
-
"name": "innards",
|
|
1146
|
-
"type": {
|
|
1147
|
-
"text": "TemplateResult"
|
|
1148
|
-
}
|
|
1149
|
-
}
|
|
1150
|
-
],
|
|
1151
|
-
"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."
|
|
997
|
+
"default": "new Date()"
|
|
1152
998
|
},
|
|
1153
999
|
{
|
|
1154
1000
|
"kind": "method",
|
|
1155
|
-
"name": "
|
|
1156
|
-
"privacy": "private",
|
|
1001
|
+
"name": "focus",
|
|
1157
1002
|
"parameters": [
|
|
1158
1003
|
{
|
|
1159
|
-
"name": "
|
|
1004
|
+
"name": "options",
|
|
1005
|
+
"optional": true,
|
|
1160
1006
|
"type": {
|
|
1161
|
-
"text": "
|
|
1007
|
+
"text": "FocusOptions & { target: \"day\" | \"month\" }"
|
|
1162
1008
|
}
|
|
1163
1009
|
}
|
|
1164
1010
|
]
|
|
1165
1011
|
},
|
|
1166
1012
|
{
|
|
1167
1013
|
"kind": "method",
|
|
1168
|
-
"name": "
|
|
1014
|
+
"name": "createDateFormatter",
|
|
1169
1015
|
"privacy": "private"
|
|
1170
1016
|
},
|
|
1171
1017
|
{
|
|
1172
|
-
"kind": "
|
|
1173
|
-
"name": "
|
|
1018
|
+
"kind": "field",
|
|
1019
|
+
"name": "handleDaySelect",
|
|
1174
1020
|
"privacy": "private"
|
|
1175
1021
|
},
|
|
1176
1022
|
{
|
|
1177
|
-
"kind": "
|
|
1178
|
-
"name": "
|
|
1179
|
-
"
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
"module": "src/common/mixins/InputMixin.ts"
|
|
1189
|
-
}
|
|
1023
|
+
"kind": "method",
|
|
1024
|
+
"name": "addDays",
|
|
1025
|
+
"privacy": "private",
|
|
1026
|
+
"parameters": [
|
|
1027
|
+
{
|
|
1028
|
+
"name": "days",
|
|
1029
|
+
"type": {
|
|
1030
|
+
"text": "number"
|
|
1031
|
+
}
|
|
1032
|
+
}
|
|
1033
|
+
]
|
|
1190
1034
|
},
|
|
1191
1035
|
{
|
|
1192
|
-
"kind": "
|
|
1193
|
-
"name": "
|
|
1194
|
-
"
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1036
|
+
"kind": "method",
|
|
1037
|
+
"name": "addMonths",
|
|
1038
|
+
"privacy": "private",
|
|
1039
|
+
"parameters": [
|
|
1040
|
+
{
|
|
1041
|
+
"name": "months",
|
|
1042
|
+
"type": {
|
|
1043
|
+
"text": "number"
|
|
1044
|
+
}
|
|
1045
|
+
}
|
|
1046
|
+
]
|
|
1203
1047
|
},
|
|
1204
1048
|
{
|
|
1205
|
-
"kind": "
|
|
1206
|
-
"name": "
|
|
1207
|
-
"
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
}
|
|
1049
|
+
"kind": "method",
|
|
1050
|
+
"name": "addYears",
|
|
1051
|
+
"privacy": "private",
|
|
1052
|
+
"parameters": [
|
|
1053
|
+
{
|
|
1054
|
+
"name": "years",
|
|
1055
|
+
"type": {
|
|
1056
|
+
"text": "number"
|
|
1057
|
+
}
|
|
1058
|
+
}
|
|
1059
|
+
]
|
|
1217
1060
|
},
|
|
1218
1061
|
{
|
|
1219
|
-
"kind": "
|
|
1220
|
-
"name": "
|
|
1221
|
-
"privacy": "
|
|
1222
|
-
"description": "Gets the form, if any, associated with the form element.",
|
|
1223
|
-
"inheritedFrom": {
|
|
1224
|
-
"name": "InputMixin",
|
|
1225
|
-
"module": "src/common/mixins/InputMixin.ts"
|
|
1226
|
-
}
|
|
1062
|
+
"kind": "method",
|
|
1063
|
+
"name": "startOfWeek",
|
|
1064
|
+
"privacy": "private"
|
|
1227
1065
|
},
|
|
1228
1066
|
{
|
|
1229
|
-
"kind": "
|
|
1230
|
-
"name": "
|
|
1231
|
-
"privacy": "
|
|
1232
|
-
"inheritedFrom": {
|
|
1233
|
-
"name": "FocusableMixin",
|
|
1234
|
-
"module": "src/common/mixins/FocusableMixin.ts"
|
|
1235
|
-
}
|
|
1067
|
+
"kind": "method",
|
|
1068
|
+
"name": "endOfWeek",
|
|
1069
|
+
"privacy": "private"
|
|
1236
1070
|
},
|
|
1237
1071
|
{
|
|
1238
1072
|
"kind": "method",
|
|
1239
|
-
"name": "
|
|
1073
|
+
"name": "setMonth",
|
|
1074
|
+
"privacy": "private",
|
|
1240
1075
|
"parameters": [
|
|
1241
1076
|
{
|
|
1242
|
-
"name": "
|
|
1243
|
-
"optional": true,
|
|
1077
|
+
"name": "month",
|
|
1244
1078
|
"type": {
|
|
1245
|
-
"text": "
|
|
1246
|
-
}
|
|
1247
|
-
"description": "An object which controls aspects of the focusing process."
|
|
1079
|
+
"text": "number"
|
|
1080
|
+
}
|
|
1248
1081
|
}
|
|
1249
|
-
]
|
|
1250
|
-
"description": "Programmatically move focus to the component.",
|
|
1251
|
-
"inheritedFrom": {
|
|
1252
|
-
"name": "FocusableMixin",
|
|
1253
|
-
"module": "src/common/mixins/FocusableMixin.ts"
|
|
1254
|
-
}
|
|
1082
|
+
]
|
|
1255
1083
|
},
|
|
1256
1084
|
{
|
|
1257
1085
|
"kind": "method",
|
|
1258
|
-
"name": "
|
|
1259
|
-
"
|
|
1260
|
-
"
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1086
|
+
"name": "setYear",
|
|
1087
|
+
"privacy": "private",
|
|
1088
|
+
"parameters": [
|
|
1089
|
+
{
|
|
1090
|
+
"name": "year",
|
|
1091
|
+
"type": {
|
|
1092
|
+
"text": "number"
|
|
1093
|
+
}
|
|
1094
|
+
}
|
|
1095
|
+
]
|
|
1264
1096
|
},
|
|
1265
1097
|
{
|
|
1266
1098
|
"kind": "method",
|
|
1267
|
-
"name": "
|
|
1268
|
-
"
|
|
1269
|
-
"
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1099
|
+
"name": "setFocusedDay",
|
|
1100
|
+
"privacy": "private",
|
|
1101
|
+
"parameters": [
|
|
1102
|
+
{
|
|
1103
|
+
"name": "day",
|
|
1104
|
+
"type": {
|
|
1105
|
+
"text": "Date"
|
|
1106
|
+
}
|
|
1107
|
+
}
|
|
1108
|
+
]
|
|
1109
|
+
},
|
|
1110
|
+
{
|
|
1111
|
+
"kind": "field",
|
|
1112
|
+
"name": "handleMonthSelect",
|
|
1113
|
+
"privacy": "private"
|
|
1114
|
+
},
|
|
1115
|
+
{
|
|
1116
|
+
"kind": "field",
|
|
1117
|
+
"name": "handleYearSelect",
|
|
1118
|
+
"privacy": "private"
|
|
1119
|
+
},
|
|
1120
|
+
{
|
|
1121
|
+
"kind": "field",
|
|
1122
|
+
"name": "handleNextMonthClick",
|
|
1123
|
+
"privacy": "private"
|
|
1124
|
+
},
|
|
1125
|
+
{
|
|
1126
|
+
"kind": "field",
|
|
1127
|
+
"name": "handlePreviousMonthClick",
|
|
1128
|
+
"privacy": "private"
|
|
1129
|
+
},
|
|
1130
|
+
{
|
|
1131
|
+
"kind": "field",
|
|
1132
|
+
"name": "enableActiveFocus",
|
|
1133
|
+
"privacy": "private"
|
|
1134
|
+
},
|
|
1135
|
+
{
|
|
1136
|
+
"kind": "field",
|
|
1137
|
+
"name": "disableActiveFocus",
|
|
1138
|
+
"privacy": "private"
|
|
1273
1139
|
},
|
|
1274
1140
|
{
|
|
1275
1141
|
"kind": "field",
|
|
@@ -1288,115 +1154,249 @@
|
|
|
1288
1154
|
],
|
|
1289
1155
|
"attributes": [
|
|
1290
1156
|
{
|
|
1291
|
-
"name": "
|
|
1157
|
+
"name": "value",
|
|
1292
1158
|
"type": {
|
|
1293
|
-
"text": "
|
|
1159
|
+
"text": "string"
|
|
1294
1160
|
},
|
|
1295
|
-
"default": "\"
|
|
1296
|
-
"description": "The
|
|
1297
|
-
"fieldName": "
|
|
1161
|
+
"default": "\"\"",
|
|
1162
|
+
"description": "The selected date on the calendar. Must be in IS0-8601 format: YYYY-MM-DD.",
|
|
1163
|
+
"fieldName": "value"
|
|
1298
1164
|
},
|
|
1299
1165
|
{
|
|
1300
|
-
"name": "
|
|
1166
|
+
"name": "firstDayOfWeek",
|
|
1301
1167
|
"type": {
|
|
1302
|
-
"text": "
|
|
1168
|
+
"text": "DaysOfWeek"
|
|
1303
1169
|
},
|
|
1304
|
-
"
|
|
1305
|
-
"
|
|
1306
|
-
"fieldName": "type"
|
|
1170
|
+
"description": "Which day is considered first day of the week? `0` for Sunday, `1` for Monday, etc.\nDefault is Monday.",
|
|
1171
|
+
"fieldName": "firstDayOfWeek"
|
|
1307
1172
|
},
|
|
1308
1173
|
{
|
|
1309
|
-
"name": "
|
|
1174
|
+
"name": "min",
|
|
1310
1175
|
"type": {
|
|
1311
|
-
"text": "
|
|
1176
|
+
"text": "string"
|
|
1312
1177
|
},
|
|
1313
|
-
"default": "\"
|
|
1314
|
-
"description": "
|
|
1315
|
-
"fieldName": "
|
|
1178
|
+
"default": "\"\"",
|
|
1179
|
+
"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.",
|
|
1180
|
+
"fieldName": "min"
|
|
1316
1181
|
},
|
|
1317
1182
|
{
|
|
1318
|
-
"name": "
|
|
1183
|
+
"name": "max",
|
|
1319
1184
|
"type": {
|
|
1320
|
-
"text": "string
|
|
1185
|
+
"text": "string"
|
|
1321
1186
|
},
|
|
1322
|
-
"
|
|
1323
|
-
"
|
|
1324
|
-
|
|
1187
|
+
"default": "\"\"",
|
|
1188
|
+
"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.",
|
|
1189
|
+
"fieldName": "max"
|
|
1190
|
+
}
|
|
1191
|
+
],
|
|
1192
|
+
"mixins": [
|
|
1325
1193
|
{
|
|
1326
|
-
"name": "
|
|
1194
|
+
"name": "DraftComponentMixin",
|
|
1195
|
+
"module": "/src/common/mixins/DraftComponentMixin.js"
|
|
1196
|
+
}
|
|
1197
|
+
],
|
|
1198
|
+
"superclass": {
|
|
1199
|
+
"name": "LitElement",
|
|
1200
|
+
"package": "lit"
|
|
1201
|
+
},
|
|
1202
|
+
"status": "draft",
|
|
1203
|
+
"category": "list",
|
|
1204
|
+
"tagName": "nord-calendar",
|
|
1205
|
+
"customElement": true
|
|
1206
|
+
}
|
|
1207
|
+
],
|
|
1208
|
+
"exports": [
|
|
1209
|
+
{
|
|
1210
|
+
"kind": "js",
|
|
1211
|
+
"name": "default",
|
|
1212
|
+
"declaration": {
|
|
1213
|
+
"name": "Calendar",
|
|
1214
|
+
"module": "src/calendar/Calendar.ts"
|
|
1215
|
+
}
|
|
1216
|
+
},
|
|
1217
|
+
{
|
|
1218
|
+
"kind": "custom-element-definition",
|
|
1219
|
+
"name": "nord-calendar",
|
|
1220
|
+
"declaration": {
|
|
1221
|
+
"name": "Calendar",
|
|
1222
|
+
"module": "src/calendar/Calendar.ts"
|
|
1223
|
+
}
|
|
1224
|
+
}
|
|
1225
|
+
],
|
|
1226
|
+
"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"
|
|
1227
|
+
},
|
|
1228
|
+
{
|
|
1229
|
+
"kind": "javascript-module",
|
|
1230
|
+
"path": "src/calendar/DateSelectEvent.ts",
|
|
1231
|
+
"declarations": [
|
|
1232
|
+
{
|
|
1233
|
+
"kind": "class",
|
|
1234
|
+
"description": "",
|
|
1235
|
+
"name": "DateSelectEvent",
|
|
1236
|
+
"members": [
|
|
1237
|
+
{
|
|
1238
|
+
"kind": "field",
|
|
1239
|
+
"name": "eventName",
|
|
1327
1240
|
"type": {
|
|
1328
|
-
"text": "
|
|
1241
|
+
"text": "string"
|
|
1329
1242
|
},
|
|
1330
|
-
"
|
|
1331
|
-
"
|
|
1332
|
-
"fieldName": "download"
|
|
1243
|
+
"static": true,
|
|
1244
|
+
"default": "\"nord-select\""
|
|
1333
1245
|
},
|
|
1334
1246
|
{
|
|
1335
|
-
"
|
|
1247
|
+
"kind": "field",
|
|
1248
|
+
"name": "date",
|
|
1336
1249
|
"type": {
|
|
1337
|
-
"text": "
|
|
1250
|
+
"text": "Date"
|
|
1338
1251
|
},
|
|
1339
|
-
"default": "
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1252
|
+
"default": "date"
|
|
1253
|
+
}
|
|
1254
|
+
],
|
|
1255
|
+
"superclass": {
|
|
1256
|
+
"name": "NordEvent",
|
|
1257
|
+
"module": "/src/common/events.js"
|
|
1258
|
+
}
|
|
1259
|
+
}
|
|
1260
|
+
],
|
|
1261
|
+
"exports": [
|
|
1262
|
+
{
|
|
1263
|
+
"kind": "js",
|
|
1264
|
+
"name": "DateSelectEvent",
|
|
1265
|
+
"declaration": {
|
|
1266
|
+
"name": "DateSelectEvent",
|
|
1267
|
+
"module": "src/calendar/DateSelectEvent.ts"
|
|
1268
|
+
}
|
|
1269
|
+
}
|
|
1270
|
+
],
|
|
1271
|
+
"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"
|
|
1272
|
+
},
|
|
1273
|
+
{
|
|
1274
|
+
"kind": "javascript-module",
|
|
1275
|
+
"path": "src/calendar/calendar-localization.ts",
|
|
1276
|
+
"declarations": [
|
|
1277
|
+
{
|
|
1278
|
+
"kind": "variable",
|
|
1279
|
+
"name": "localization",
|
|
1280
|
+
"type": {
|
|
1281
|
+
"text": "CalendarLocalizedText"
|
|
1282
|
+
},
|
|
1283
|
+
"default": "{\n prevMonthLabel: \"Previous month\",\n nextMonthLabel: \"Next month\",\n monthSelectLabel: \"Month\",\n yearSelectLabel: \"Year\",\n calendarHeading: \"Choose a date\",\n dayNames: [\"Sunday\", \"Monday\", \"Tuesday\", \"Wednesday\", \"Thursday\", \"Friday\", \"Saturday\"],\n monthNames: [\n \"January\",\n \"February\",\n \"March\",\n \"April\",\n \"May\",\n \"June\",\n \"July\",\n \"August\",\n \"September\",\n \"October\",\n \"November\",\n \"December\",\n ],\n monthNamesShort: [\"Jan\", \"Feb\", \"Mar\", \"Apr\", \"May\", \"Jun\", \"Jul\", \"Aug\", \"Sep\", \"Oct\", \"Nov\", \"Dec\"],\n locale: \"en-GB\",\n}"
|
|
1284
|
+
}
|
|
1285
|
+
],
|
|
1286
|
+
"exports": [
|
|
1287
|
+
{
|
|
1288
|
+
"kind": "js",
|
|
1289
|
+
"name": "default",
|
|
1290
|
+
"declaration": {
|
|
1291
|
+
"name": "localization",
|
|
1292
|
+
"module": "src/calendar/calendar-localization.ts"
|
|
1293
|
+
}
|
|
1294
|
+
}
|
|
1295
|
+
],
|
|
1296
|
+
"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"
|
|
1297
|
+
},
|
|
1298
|
+
{
|
|
1299
|
+
"kind": "javascript-module",
|
|
1300
|
+
"path": "src/calendar/month-view.ts",
|
|
1301
|
+
"declarations": [
|
|
1302
|
+
{
|
|
1303
|
+
"kind": "function",
|
|
1304
|
+
"name": "dayView",
|
|
1305
|
+
"parameters": [
|
|
1306
|
+
{
|
|
1307
|
+
"name": "{\n focusedDay,\n today,\n day,\n onDaySelect,\n onKeyboardNavigation,\n disabled,\n inRange,\n isSelected,\n dateFormatter,\n}",
|
|
1308
|
+
"type": {
|
|
1309
|
+
"text": "DatePickerDayProps"
|
|
1310
|
+
}
|
|
1311
|
+
}
|
|
1312
|
+
]
|
|
1313
|
+
},
|
|
1314
|
+
{
|
|
1315
|
+
"kind": "function",
|
|
1316
|
+
"name": "monthView",
|
|
1317
|
+
"parameters": [
|
|
1318
|
+
{
|
|
1319
|
+
"name": "{\n onFocusIn,\n onFocusOut,\n selectedDate,\n focusedDate,\n labelledById,\n localization,\n firstDayOfWeek,\n min,\n max,\n dateFormatter,\n isDateDisabled,\n onDateSelect,\n onKeyboardNavigation,\n}",
|
|
1320
|
+
"type": {
|
|
1321
|
+
"text": "MonthViewArgs"
|
|
1322
|
+
}
|
|
1323
|
+
}
|
|
1324
|
+
]
|
|
1325
|
+
}
|
|
1326
|
+
],
|
|
1327
|
+
"exports": [
|
|
1328
|
+
{
|
|
1329
|
+
"kind": "js",
|
|
1330
|
+
"name": "dayView",
|
|
1331
|
+
"declaration": {
|
|
1332
|
+
"name": "dayView",
|
|
1333
|
+
"module": "src/calendar/month-view.ts"
|
|
1334
|
+
}
|
|
1335
|
+
},
|
|
1336
|
+
{
|
|
1337
|
+
"kind": "js",
|
|
1338
|
+
"name": "monthView",
|
|
1339
|
+
"declaration": {
|
|
1340
|
+
"name": "monthView",
|
|
1341
|
+
"module": "src/calendar/month-view.ts"
|
|
1342
|
+
}
|
|
1343
|
+
}
|
|
1344
|
+
],
|
|
1345
|
+
"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"
|
|
1346
|
+
},
|
|
1347
|
+
{
|
|
1348
|
+
"kind": "javascript-module",
|
|
1349
|
+
"path": "src/banner/Banner.ts",
|
|
1350
|
+
"declarations": [
|
|
1351
|
+
{
|
|
1352
|
+
"kind": "class",
|
|
1353
|
+
"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.",
|
|
1354
|
+
"name": "Banner",
|
|
1355
|
+
"slots": [
|
|
1343
1356
|
{
|
|
1344
|
-
"
|
|
1357
|
+
"description": "default slot",
|
|
1358
|
+
"name": ""
|
|
1359
|
+
}
|
|
1360
|
+
],
|
|
1361
|
+
"members": [
|
|
1362
|
+
{
|
|
1363
|
+
"kind": "field",
|
|
1364
|
+
"name": "variant",
|
|
1345
1365
|
"type": {
|
|
1346
|
-
"text": "
|
|
1366
|
+
"text": "\"info\" | \"danger\" | \"success\" | \"warning\""
|
|
1347
1367
|
},
|
|
1348
|
-
"default": "
|
|
1349
|
-
"description": "
|
|
1350
|
-
"
|
|
1368
|
+
"default": "\"info\"",
|
|
1369
|
+
"description": "The style variant of the banner.",
|
|
1370
|
+
"attribute": "variant",
|
|
1371
|
+
"reflects": true
|
|
1351
1372
|
},
|
|
1352
1373
|
{
|
|
1353
|
-
"
|
|
1374
|
+
"kind": "field",
|
|
1375
|
+
"name": "_warningLogged",
|
|
1354
1376
|
"type": {
|
|
1355
1377
|
"text": "boolean"
|
|
1356
1378
|
},
|
|
1379
|
+
"privacy": "private",
|
|
1380
|
+
"static": true,
|
|
1357
1381
|
"default": "false",
|
|
1358
|
-
"description": "Makes the component disabled. This prevents users from\nbeing able to interact with the component, and conveys\nits inactive state to assistive technologies.",
|
|
1359
|
-
"fieldName": "disabled",
|
|
1360
|
-
"inheritedFrom": {
|
|
1361
|
-
"name": "InputMixin",
|
|
1362
|
-
"module": "src/common/mixins/InputMixin.ts"
|
|
1363
|
-
}
|
|
1364
|
-
},
|
|
1365
|
-
{
|
|
1366
|
-
"name": "name",
|
|
1367
|
-
"type": {
|
|
1368
|
-
"text": "string | undefined"
|
|
1369
|
-
},
|
|
1370
|
-
"description": "The name of the form component.",
|
|
1371
|
-
"fieldName": "name",
|
|
1372
1382
|
"inheritedFrom": {
|
|
1373
|
-
"name": "
|
|
1374
|
-
"module": "src/common/mixins/
|
|
1383
|
+
"name": "DraftComponentMixin",
|
|
1384
|
+
"module": "src/common/mixins/DraftComponentMixin.ts"
|
|
1375
1385
|
}
|
|
1376
|
-
}
|
|
1386
|
+
}
|
|
1387
|
+
],
|
|
1388
|
+
"attributes": [
|
|
1377
1389
|
{
|
|
1378
|
-
"name": "
|
|
1390
|
+
"name": "variant",
|
|
1379
1391
|
"type": {
|
|
1380
|
-
"text": "
|
|
1392
|
+
"text": "\"info\" | \"danger\" | \"success\" | \"warning\""
|
|
1381
1393
|
},
|
|
1382
|
-
"default": "\"\"",
|
|
1383
|
-
"description": "The
|
|
1384
|
-
"fieldName": "
|
|
1385
|
-
"inheritedFrom": {
|
|
1386
|
-
"name": "InputMixin",
|
|
1387
|
-
"module": "src/common/mixins/InputMixin.ts"
|
|
1388
|
-
}
|
|
1394
|
+
"default": "\"info\"",
|
|
1395
|
+
"description": "The style variant of the banner.",
|
|
1396
|
+
"fieldName": "variant"
|
|
1389
1397
|
}
|
|
1390
1398
|
],
|
|
1391
1399
|
"mixins": [
|
|
1392
|
-
{
|
|
1393
|
-
"name": "InputMixin",
|
|
1394
|
-
"module": "/src/common/mixins/InputMixin.js"
|
|
1395
|
-
},
|
|
1396
|
-
{
|
|
1397
|
-
"name": "FocusableMixin",
|
|
1398
|
-
"module": "/src/common/mixins/FocusableMixin.js"
|
|
1399
|
-
},
|
|
1400
1400
|
{
|
|
1401
1401
|
"name": "DraftComponentMixin",
|
|
1402
1402
|
"module": "/src/common/mixins/DraftComponentMixin.js"
|
|
@@ -1407,8 +1407,8 @@
|
|
|
1407
1407
|
"package": "lit"
|
|
1408
1408
|
},
|
|
1409
1409
|
"status": "draft",
|
|
1410
|
-
"category": "
|
|
1411
|
-
"tagName": "nord-
|
|
1410
|
+
"category": "feedback",
|
|
1411
|
+
"tagName": "nord-banner",
|
|
1412
1412
|
"customElement": true
|
|
1413
1413
|
}
|
|
1414
1414
|
],
|
|
@@ -1417,20 +1417,20 @@
|
|
|
1417
1417
|
"kind": "js",
|
|
1418
1418
|
"name": "default",
|
|
1419
1419
|
"declaration": {
|
|
1420
|
-
"name": "
|
|
1421
|
-
"module": "src/
|
|
1420
|
+
"name": "Banner",
|
|
1421
|
+
"module": "src/banner/Banner.ts"
|
|
1422
1422
|
}
|
|
1423
1423
|
},
|
|
1424
1424
|
{
|
|
1425
1425
|
"kind": "custom-element-definition",
|
|
1426
|
-
"name": "nord-
|
|
1426
|
+
"name": "nord-banner",
|
|
1427
1427
|
"declaration": {
|
|
1428
|
-
"name": "
|
|
1429
|
-
"module": "src/
|
|
1428
|
+
"name": "Banner",
|
|
1429
|
+
"module": "src/banner/Banner.ts"
|
|
1430
1430
|
}
|
|
1431
1431
|
}
|
|
1432
1432
|
],
|
|
1433
|
-
"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
|
|
1433
|
+
"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"
|
|
1434
1434
|
},
|
|
1435
1435
|
{
|
|
1436
1436
|
"kind": "javascript-module",
|
|
@@ -8875,61 +8875,237 @@
|
|
|
8875
8875
|
"name": "VisuallyHidden",
|
|
8876
8876
|
"slots": [
|
|
8877
8877
|
{
|
|
8878
|
-
"description": "The visually hidden content.",
|
|
8879
|
-
"name": ""
|
|
8880
|
-
}
|
|
8881
|
-
],
|
|
8882
|
-
"members": [
|
|
8878
|
+
"description": "The visually hidden content.",
|
|
8879
|
+
"name": ""
|
|
8880
|
+
}
|
|
8881
|
+
],
|
|
8882
|
+
"members": [
|
|
8883
|
+
{
|
|
8884
|
+
"kind": "field",
|
|
8885
|
+
"name": "_warningLogged",
|
|
8886
|
+
"type": {
|
|
8887
|
+
"text": "boolean"
|
|
8888
|
+
},
|
|
8889
|
+
"privacy": "private",
|
|
8890
|
+
"static": true,
|
|
8891
|
+
"default": "false",
|
|
8892
|
+
"inheritedFrom": {
|
|
8893
|
+
"name": "DraftComponentMixin",
|
|
8894
|
+
"module": "src/common/mixins/DraftComponentMixin.ts"
|
|
8895
|
+
}
|
|
8896
|
+
}
|
|
8897
|
+
],
|
|
8898
|
+
"mixins": [
|
|
8899
|
+
{
|
|
8900
|
+
"name": "DraftComponentMixin",
|
|
8901
|
+
"module": "/src/common/mixins/DraftComponentMixin.js"
|
|
8902
|
+
}
|
|
8903
|
+
],
|
|
8904
|
+
"superclass": {
|
|
8905
|
+
"name": "LitElement",
|
|
8906
|
+
"package": "lit"
|
|
8907
|
+
},
|
|
8908
|
+
"status": "draft",
|
|
8909
|
+
"category": "text",
|
|
8910
|
+
"tagName": "nord-visually-hidden",
|
|
8911
|
+
"customElement": true
|
|
8912
|
+
}
|
|
8913
|
+
],
|
|
8914
|
+
"exports": [
|
|
8915
|
+
{
|
|
8916
|
+
"kind": "js",
|
|
8917
|
+
"name": "default",
|
|
8918
|
+
"declaration": {
|
|
8919
|
+
"name": "VisuallyHidden",
|
|
8920
|
+
"module": "src/visually-hidden/VisuallyHidden.ts"
|
|
8921
|
+
}
|
|
8922
|
+
},
|
|
8923
|
+
{
|
|
8924
|
+
"kind": "custom-element-definition",
|
|
8925
|
+
"name": "nord-visually-hidden",
|
|
8926
|
+
"declaration": {
|
|
8927
|
+
"name": "VisuallyHidden",
|
|
8928
|
+
"module": "src/visually-hidden/VisuallyHidden.ts"
|
|
8929
|
+
}
|
|
8930
|
+
}
|
|
8931
|
+
],
|
|
8932
|
+
"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 hide text visually from the screen, but keep it available to assistive technologies, such as screen readers.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for hiding interactive content.\n\n</div>\n"
|
|
8933
|
+
},
|
|
8934
|
+
{
|
|
8935
|
+
"kind": "javascript-module",
|
|
8936
|
+
"path": "src/common/directives/cond.ts",
|
|
8937
|
+
"declarations": [
|
|
8938
|
+
{
|
|
8939
|
+
"kind": "variable",
|
|
8940
|
+
"name": "cond"
|
|
8941
|
+
}
|
|
8942
|
+
],
|
|
8943
|
+
"exports": [
|
|
8944
|
+
{
|
|
8945
|
+
"kind": "js",
|
|
8946
|
+
"name": "cond",
|
|
8947
|
+
"declaration": {
|
|
8948
|
+
"name": "cond",
|
|
8949
|
+
"module": "src/common/directives/cond.ts"
|
|
8950
|
+
}
|
|
8951
|
+
}
|
|
8952
|
+
]
|
|
8953
|
+
},
|
|
8954
|
+
{
|
|
8955
|
+
"kind": "javascript-module",
|
|
8956
|
+
"path": "src/common/directives/wrapIf.ts",
|
|
8957
|
+
"declarations": [
|
|
8958
|
+
{
|
|
8959
|
+
"kind": "function",
|
|
8960
|
+
"name": "wrapIf",
|
|
8961
|
+
"return": {
|
|
8962
|
+
"type": {
|
|
8963
|
+
"text": "TInner"
|
|
8964
|
+
}
|
|
8965
|
+
},
|
|
8966
|
+
"parameters": [
|
|
8967
|
+
{
|
|
8968
|
+
"name": "condition",
|
|
8969
|
+
"type": {
|
|
8970
|
+
"text": "false"
|
|
8971
|
+
}
|
|
8972
|
+
},
|
|
8973
|
+
{
|
|
8974
|
+
"name": "inner",
|
|
8975
|
+
"type": {
|
|
8976
|
+
"text": "() => TInner"
|
|
8977
|
+
}
|
|
8978
|
+
},
|
|
8979
|
+
{
|
|
8980
|
+
"name": "wrapper",
|
|
8981
|
+
"type": {
|
|
8982
|
+
"text": "(inner: TInner) => TWrapper"
|
|
8983
|
+
}
|
|
8984
|
+
}
|
|
8985
|
+
]
|
|
8986
|
+
},
|
|
8987
|
+
{
|
|
8988
|
+
"kind": "function",
|
|
8989
|
+
"name": "wrapIf",
|
|
8990
|
+
"return": {
|
|
8991
|
+
"type": {
|
|
8992
|
+
"text": "TWrapper"
|
|
8993
|
+
}
|
|
8994
|
+
},
|
|
8995
|
+
"parameters": [
|
|
8996
|
+
{
|
|
8997
|
+
"name": "condition",
|
|
8998
|
+
"type": {
|
|
8999
|
+
"text": "true"
|
|
9000
|
+
}
|
|
9001
|
+
},
|
|
9002
|
+
{
|
|
9003
|
+
"name": "inner",
|
|
9004
|
+
"type": {
|
|
9005
|
+
"text": "() => TInner"
|
|
9006
|
+
}
|
|
9007
|
+
},
|
|
9008
|
+
{
|
|
9009
|
+
"name": "wrapper",
|
|
9010
|
+
"type": {
|
|
9011
|
+
"text": "(inner: TInner) => TWrapper"
|
|
9012
|
+
}
|
|
9013
|
+
}
|
|
9014
|
+
]
|
|
9015
|
+
},
|
|
9016
|
+
{
|
|
9017
|
+
"kind": "function",
|
|
9018
|
+
"name": "wrapIf",
|
|
9019
|
+
"return": {
|
|
9020
|
+
"type": {
|
|
9021
|
+
"text": "TInner | TWrapper"
|
|
9022
|
+
}
|
|
9023
|
+
},
|
|
9024
|
+
"parameters": [
|
|
9025
|
+
{
|
|
9026
|
+
"name": "condition",
|
|
9027
|
+
"type": {
|
|
9028
|
+
"text": "unknown"
|
|
9029
|
+
}
|
|
9030
|
+
},
|
|
9031
|
+
{
|
|
9032
|
+
"name": "inner",
|
|
9033
|
+
"type": {
|
|
9034
|
+
"text": "() => TInner"
|
|
9035
|
+
}
|
|
9036
|
+
},
|
|
9037
|
+
{
|
|
9038
|
+
"name": "wrapper",
|
|
9039
|
+
"type": {
|
|
9040
|
+
"text": "(inner: TInner) => TWrapper"
|
|
9041
|
+
}
|
|
9042
|
+
}
|
|
9043
|
+
]
|
|
9044
|
+
},
|
|
9045
|
+
{
|
|
9046
|
+
"kind": "function",
|
|
9047
|
+
"name": "wrapIf",
|
|
9048
|
+
"parameters": [
|
|
9049
|
+
{
|
|
9050
|
+
"name": "condition",
|
|
9051
|
+
"type": {
|
|
9052
|
+
"text": "any"
|
|
9053
|
+
}
|
|
9054
|
+
},
|
|
8883
9055
|
{
|
|
8884
|
-
"
|
|
8885
|
-
"name": "_warningLogged",
|
|
9056
|
+
"name": "inner",
|
|
8886
9057
|
"type": {
|
|
8887
|
-
"text": "
|
|
8888
|
-
},
|
|
8889
|
-
"privacy": "private",
|
|
8890
|
-
"static": true,
|
|
8891
|
-
"default": "false",
|
|
8892
|
-
"inheritedFrom": {
|
|
8893
|
-
"name": "DraftComponentMixin",
|
|
8894
|
-
"module": "src/common/mixins/DraftComponentMixin.ts"
|
|
9058
|
+
"text": "() => TInner"
|
|
8895
9059
|
}
|
|
8896
|
-
}
|
|
8897
|
-
],
|
|
8898
|
-
"mixins": [
|
|
9060
|
+
},
|
|
8899
9061
|
{
|
|
8900
|
-
"name": "
|
|
8901
|
-
"
|
|
9062
|
+
"name": "wrapper",
|
|
9063
|
+
"type": {
|
|
9064
|
+
"text": "(innards: TInner) => TWrapper"
|
|
9065
|
+
}
|
|
8902
9066
|
}
|
|
8903
9067
|
],
|
|
8904
|
-
"
|
|
8905
|
-
"
|
|
8906
|
-
|
|
8907
|
-
|
|
8908
|
-
|
|
8909
|
-
"category": "text",
|
|
8910
|
-
"tagName": "nord-visually-hidden",
|
|
8911
|
-
"customElement": true
|
|
9068
|
+
"return": {
|
|
9069
|
+
"type": {
|
|
9070
|
+
"text": ""
|
|
9071
|
+
}
|
|
9072
|
+
}
|
|
8912
9073
|
}
|
|
8913
9074
|
],
|
|
8914
9075
|
"exports": [
|
|
8915
9076
|
{
|
|
8916
9077
|
"kind": "js",
|
|
8917
|
-
"name": "
|
|
9078
|
+
"name": "wrapIf",
|
|
8918
9079
|
"declaration": {
|
|
8919
|
-
"name": "
|
|
8920
|
-
"module": "src/
|
|
9080
|
+
"name": "wrapIf",
|
|
9081
|
+
"module": "src/common/directives/wrapIf.ts"
|
|
8921
9082
|
}
|
|
8922
9083
|
},
|
|
8923
9084
|
{
|
|
8924
|
-
"kind": "
|
|
8925
|
-
"name": "
|
|
9085
|
+
"kind": "js",
|
|
9086
|
+
"name": "wrapIf",
|
|
8926
9087
|
"declaration": {
|
|
8927
|
-
"name": "
|
|
8928
|
-
"module": "src/
|
|
9088
|
+
"name": "wrapIf",
|
|
9089
|
+
"module": "src/common/directives/wrapIf.ts"
|
|
9090
|
+
}
|
|
9091
|
+
},
|
|
9092
|
+
{
|
|
9093
|
+
"kind": "js",
|
|
9094
|
+
"name": "wrapIf",
|
|
9095
|
+
"declaration": {
|
|
9096
|
+
"name": "wrapIf",
|
|
9097
|
+
"module": "src/common/directives/wrapIf.ts"
|
|
9098
|
+
}
|
|
9099
|
+
},
|
|
9100
|
+
{
|
|
9101
|
+
"kind": "js",
|
|
9102
|
+
"name": "wrapIf",
|
|
9103
|
+
"declaration": {
|
|
9104
|
+
"name": "wrapIf",
|
|
9105
|
+
"module": "src/common/directives/wrapIf.ts"
|
|
8929
9106
|
}
|
|
8930
9107
|
}
|
|
8931
|
-
]
|
|
8932
|
-
"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 hide text visually from the screen, but keep it available to assistive technologies, such as screen readers.\n\n</div>\n<div class=\"n-usage n-usage-dont\">\n\n### Don’t\n\n- Don’t use for hiding interactive content.\n\n</div>\n"
|
|
9108
|
+
]
|
|
8933
9109
|
},
|
|
8934
9110
|
{
|
|
8935
9111
|
"kind": "javascript-module",
|
|
@@ -9645,182 +9821,6 @@
|
|
|
9645
9821
|
}
|
|
9646
9822
|
]
|
|
9647
9823
|
},
|
|
9648
|
-
{
|
|
9649
|
-
"kind": "javascript-module",
|
|
9650
|
-
"path": "src/common/directives/cond.ts",
|
|
9651
|
-
"declarations": [
|
|
9652
|
-
{
|
|
9653
|
-
"kind": "variable",
|
|
9654
|
-
"name": "cond"
|
|
9655
|
-
}
|
|
9656
|
-
],
|
|
9657
|
-
"exports": [
|
|
9658
|
-
{
|
|
9659
|
-
"kind": "js",
|
|
9660
|
-
"name": "cond",
|
|
9661
|
-
"declaration": {
|
|
9662
|
-
"name": "cond",
|
|
9663
|
-
"module": "src/common/directives/cond.ts"
|
|
9664
|
-
}
|
|
9665
|
-
}
|
|
9666
|
-
]
|
|
9667
|
-
},
|
|
9668
|
-
{
|
|
9669
|
-
"kind": "javascript-module",
|
|
9670
|
-
"path": "src/common/directives/wrapIf.ts",
|
|
9671
|
-
"declarations": [
|
|
9672
|
-
{
|
|
9673
|
-
"kind": "function",
|
|
9674
|
-
"name": "wrapIf",
|
|
9675
|
-
"return": {
|
|
9676
|
-
"type": {
|
|
9677
|
-
"text": "TInner"
|
|
9678
|
-
}
|
|
9679
|
-
},
|
|
9680
|
-
"parameters": [
|
|
9681
|
-
{
|
|
9682
|
-
"name": "condition",
|
|
9683
|
-
"type": {
|
|
9684
|
-
"text": "false"
|
|
9685
|
-
}
|
|
9686
|
-
},
|
|
9687
|
-
{
|
|
9688
|
-
"name": "inner",
|
|
9689
|
-
"type": {
|
|
9690
|
-
"text": "() => TInner"
|
|
9691
|
-
}
|
|
9692
|
-
},
|
|
9693
|
-
{
|
|
9694
|
-
"name": "wrapper",
|
|
9695
|
-
"type": {
|
|
9696
|
-
"text": "(inner: TInner) => TWrapper"
|
|
9697
|
-
}
|
|
9698
|
-
}
|
|
9699
|
-
]
|
|
9700
|
-
},
|
|
9701
|
-
{
|
|
9702
|
-
"kind": "function",
|
|
9703
|
-
"name": "wrapIf",
|
|
9704
|
-
"return": {
|
|
9705
|
-
"type": {
|
|
9706
|
-
"text": "TWrapper"
|
|
9707
|
-
}
|
|
9708
|
-
},
|
|
9709
|
-
"parameters": [
|
|
9710
|
-
{
|
|
9711
|
-
"name": "condition",
|
|
9712
|
-
"type": {
|
|
9713
|
-
"text": "true"
|
|
9714
|
-
}
|
|
9715
|
-
},
|
|
9716
|
-
{
|
|
9717
|
-
"name": "inner",
|
|
9718
|
-
"type": {
|
|
9719
|
-
"text": "() => TInner"
|
|
9720
|
-
}
|
|
9721
|
-
},
|
|
9722
|
-
{
|
|
9723
|
-
"name": "wrapper",
|
|
9724
|
-
"type": {
|
|
9725
|
-
"text": "(inner: TInner) => TWrapper"
|
|
9726
|
-
}
|
|
9727
|
-
}
|
|
9728
|
-
]
|
|
9729
|
-
},
|
|
9730
|
-
{
|
|
9731
|
-
"kind": "function",
|
|
9732
|
-
"name": "wrapIf",
|
|
9733
|
-
"return": {
|
|
9734
|
-
"type": {
|
|
9735
|
-
"text": "TInner | TWrapper"
|
|
9736
|
-
}
|
|
9737
|
-
},
|
|
9738
|
-
"parameters": [
|
|
9739
|
-
{
|
|
9740
|
-
"name": "condition",
|
|
9741
|
-
"type": {
|
|
9742
|
-
"text": "unknown"
|
|
9743
|
-
}
|
|
9744
|
-
},
|
|
9745
|
-
{
|
|
9746
|
-
"name": "inner",
|
|
9747
|
-
"type": {
|
|
9748
|
-
"text": "() => TInner"
|
|
9749
|
-
}
|
|
9750
|
-
},
|
|
9751
|
-
{
|
|
9752
|
-
"name": "wrapper",
|
|
9753
|
-
"type": {
|
|
9754
|
-
"text": "(inner: TInner) => TWrapper"
|
|
9755
|
-
}
|
|
9756
|
-
}
|
|
9757
|
-
]
|
|
9758
|
-
},
|
|
9759
|
-
{
|
|
9760
|
-
"kind": "function",
|
|
9761
|
-
"name": "wrapIf",
|
|
9762
|
-
"parameters": [
|
|
9763
|
-
{
|
|
9764
|
-
"name": "condition",
|
|
9765
|
-
"type": {
|
|
9766
|
-
"text": "any"
|
|
9767
|
-
}
|
|
9768
|
-
},
|
|
9769
|
-
{
|
|
9770
|
-
"name": "inner",
|
|
9771
|
-
"type": {
|
|
9772
|
-
"text": "() => TInner"
|
|
9773
|
-
}
|
|
9774
|
-
},
|
|
9775
|
-
{
|
|
9776
|
-
"name": "wrapper",
|
|
9777
|
-
"type": {
|
|
9778
|
-
"text": "(innards: TInner) => TWrapper"
|
|
9779
|
-
}
|
|
9780
|
-
}
|
|
9781
|
-
],
|
|
9782
|
-
"return": {
|
|
9783
|
-
"type": {
|
|
9784
|
-
"text": ""
|
|
9785
|
-
}
|
|
9786
|
-
}
|
|
9787
|
-
}
|
|
9788
|
-
],
|
|
9789
|
-
"exports": [
|
|
9790
|
-
{
|
|
9791
|
-
"kind": "js",
|
|
9792
|
-
"name": "wrapIf",
|
|
9793
|
-
"declaration": {
|
|
9794
|
-
"name": "wrapIf",
|
|
9795
|
-
"module": "src/common/directives/wrapIf.ts"
|
|
9796
|
-
}
|
|
9797
|
-
},
|
|
9798
|
-
{
|
|
9799
|
-
"kind": "js",
|
|
9800
|
-
"name": "wrapIf",
|
|
9801
|
-
"declaration": {
|
|
9802
|
-
"name": "wrapIf",
|
|
9803
|
-
"module": "src/common/directives/wrapIf.ts"
|
|
9804
|
-
}
|
|
9805
|
-
},
|
|
9806
|
-
{
|
|
9807
|
-
"kind": "js",
|
|
9808
|
-
"name": "wrapIf",
|
|
9809
|
-
"declaration": {
|
|
9810
|
-
"name": "wrapIf",
|
|
9811
|
-
"module": "src/common/directives/wrapIf.ts"
|
|
9812
|
-
}
|
|
9813
|
-
},
|
|
9814
|
-
{
|
|
9815
|
-
"kind": "js",
|
|
9816
|
-
"name": "wrapIf",
|
|
9817
|
-
"declaration": {
|
|
9818
|
-
"name": "wrapIf",
|
|
9819
|
-
"module": "src/common/directives/wrapIf.ts"
|
|
9820
|
-
}
|
|
9821
|
-
}
|
|
9822
|
-
]
|
|
9823
|
-
},
|
|
9824
9824
|
{
|
|
9825
9825
|
"kind": "javascript-module",
|
|
9826
9826
|
"path": "src/common/mixins/DraftComponentMixin.ts",
|