@nysds/components 1.19.3-alpha-1 → 1.19.4
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 +1243 -203
- package/dist/.vscode/vscode.html-custom-data.json +13 -13
- package/dist/custom-elements.json +1243 -203
- package/dist/nys-icon.library-r6nNUTzA.js +696 -0
- package/dist/nys-icon.library-r6nNUTzA.js.map +1 -0
- package/dist/nysds.es.js +2746 -2617
- package/dist/nysds.es.js.map +1 -1
- package/dist/nysds.js +757 -155
- package/dist/nysds.js.map +1 -1
- package/dist/packages/nys-accordion/src/nys-accordion.d.ts +35 -6
- package/dist/packages/nys-accordion/src/nys-accordionitem.d.ts +8 -3
- package/dist/packages/nys-alert/src/nys-alert.d.ts +81 -4
- package/dist/packages/nys-avatar/src/nys-avatar.d.ts +44 -4
- package/dist/packages/nys-backtotop/src/nys-backtotop.d.ts +70 -3
- package/dist/packages/nys-badge/src/nys-badge.d.ts +54 -4
- package/dist/packages/nys-breadcrumbs/src/nys-breadcrumbs.d.ts +75 -7
- package/dist/packages/nys-button/src/nys-button.d.ts +62 -7
- package/dist/packages/nys-checkbox/src/nys-checkbox.d.ts +5 -7
- package/dist/packages/nys-checkbox/src/nys-checkboxgroup.d.ts +75 -1
- package/dist/packages/nys-combobox/src/nys-combobox.d.ts +164 -0
- package/dist/packages/nys-datepicker/src/nys-datepicker.d.ts +64 -8
- package/dist/packages/nys-divider/src/nys-divider.d.ts +24 -1
- package/dist/packages/nys-dropdownmenu/src/nys-dropdownmenu.d.ts +19 -12
- package/dist/packages/nys-dropdownmenu/src/nys-dropdownmenuitem.d.ts +0 -10
- package/dist/packages/nys-errormessage/src/nys-errormessage.d.ts +10 -0
- package/dist/packages/nys-fileinput/src/nys-fileinput.d.ts +94 -4
- package/dist/packages/nys-globalfooter/src/nys-globalfooter.d.ts +50 -7
- package/dist/packages/nys-globalheader/src/nys-globalheader.d.ts +65 -4
- package/dist/packages/nys-icon/src/icon-cache.d.ts +11 -4
- package/dist/packages/nys-icon/src/icon-library-registry.d.ts +33 -16
- package/dist/packages/nys-icon/src/index.d.ts +2 -2
- package/dist/packages/nys-icon/src/nys-icon.d.ts +83 -6
- package/dist/packages/nys-label/src/nys-label.d.ts +32 -2
- package/dist/packages/nys-modal/src/nys-modal.d.ts +130 -5
- package/dist/packages/nys-pagination/src/nys-pagination.d.ts +11 -1
- package/dist/packages/nys-radiobutton/src/nys-radiobutton.d.ts +4 -3
- package/dist/packages/nys-radiobutton/src/nys-radiogroup.d.ts +74 -1
- package/dist/packages/nys-select/src/nys-option.d.ts +0 -8
- package/dist/packages/nys-select/src/nys-select.d.ts +141 -10
- package/dist/packages/nys-skipnav/src/nys-skipnav.d.ts +2 -2
- package/dist/packages/nys-stepper/src/nys-step.d.ts +0 -13
- package/dist/packages/nys-stepper/src/nys-stepper.d.ts +119 -69
- package/dist/packages/nys-tab/src/nys-tab.d.ts +17 -8
- package/dist/packages/nys-tab/src/nys-tabgroup.d.ts +170 -35
- package/dist/packages/nys-tab/src/nys-tabpanel.d.ts +13 -22
- package/dist/packages/nys-table/src/nys-table.d.ts +80 -1
- package/dist/packages/nys-textarea/src/nys-textarea.d.ts +52 -5
- package/dist/packages/nys-textinput/src/nys-textinput.d.ts +63 -9
- package/dist/packages/nys-toggle/src/nys-toggle.d.ts +40 -4
- package/dist/packages/nys-tooltip/src/nys-tooltip.d.ts +38 -6
- package/dist/packages/nys-unavfooter/src/nys-unavfooter.d.ts +10 -2
- package/dist/packages/nys-unavheader/src/nys-unavheader.d.ts +54 -8
- package/dist/packages/nys-video/src/nys-video.d.ts +65 -3
- package/package.json +11 -5
- package/packages/react/NysBreadcrumbs.d.ts +1 -1
- package/packages/react/NysButton.d.ts +2 -1
- package/packages/react/NysDropdownMenu.d.ts +1 -1
- package/packages/react/NysFileinput.d.ts +24 -2
- package/packages/react/NysFileinput.js +8 -1
- package/packages/react/NysGlobalHeader.d.ts +6 -1
- package/packages/react/NysLabel.d.ts +4 -1
- package/packages/react/NysTabgroup.d.ts +5 -4
- package/packages/react/NysTable.d.ts +1 -1
- package/packages/react/NysTabpanel.d.ts +11 -4
- package/packages/react/NysTextarea.d.ts +1 -1
- package/packages/react/NysUnavHeader.d.ts +11 -1
- package/packages/react/NysUnavHeader.js +15 -1
- package/packages/react/nysds-jsx.d.ts +64 -19
|
@@ -158,13 +158,18 @@
|
|
|
158
158
|
"summary": "Container for accordion items with optional single-select and bordered styling.",
|
|
159
159
|
"examples": [
|
|
160
160
|
{
|
|
161
|
-
"title": "Basic
|
|
162
|
-
"code": "<nys-accordion>\n<nys-accordionitem heading=\"
|
|
161
|
+
"title": "Basic",
|
|
162
|
+
"code": "<nys-accordion>\n<nys-accordionitem id=\"accordionId1\" heading=\"How do I renew my passport or apply for a new one?\">\n<p>\nYou can apply for or renew a U.S. passport through the U.S. Department\nof State. Some renewals can be done by mail.\n</p>\n<div style=\"display: flex; gap: 0.5rem; font-size: 1rem;\">\n<a href=\"https://www.ny.gov\" target=\"_blank\">Check your registration</a>\n<a href=\"https://www.ny.gov\" target=\"_blank\">Fill out application</a>\n</div>\n</nys-accordionitem>\n<nys-accordionitem id=\"accordionId2\" heading=\"How can I find out if I’m registered to vote?\">\n<p>You can check your registration status, update your information, or find out how to register through the National Association of Secretaries of State.</p>\n</nys-accordionitem>\n</nys-accordion>",
|
|
163
163
|
"lang": "html"
|
|
164
164
|
},
|
|
165
165
|
{
|
|
166
|
-
"title": "Single
|
|
167
|
-
"code": "<nys-accordion singleSelect
|
|
166
|
+
"title": "Single Select",
|
|
167
|
+
"code": "<nys-accordion singleSelect>\n<nys-accordionitem heading=\"FAQ 1\">Answer 1</nys-accordionitem>\n<nys-accordionitem heading=\"FAQ 2\">Answer 2</nys-accordionitem>\n</nys-accordion>",
|
|
168
|
+
"lang": "html"
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
"title": "Bordered",
|
|
172
|
+
"code": "<nys-accordion bordered>\n<nys-accordionitem heading=\"We are a group of accordions\">\n<p>Stronger together! Learn more at\n<a href=\"https://www.ny.gov\" target=\"_blank\">ny.gov</a>\n</p>\n</nys-accordionitem>\n<nys-accordionitem heading=\"Liberty Ipsum: Bridges & Boroughs\">\n<p>Empire ipsum dolor sit amet, across the Brooklyn Bridge to Central Park, consectetur adipiscing elit.</p>\n</nys-accordionitem>\n<nys-accordionitem heading=\"Hudson Ipsum: Riverfront Stories\">\n<p>From the banks of the Hudson to the peaks of the Adirondacks, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.</p>\n</nys-accordionitem>\n</nys-accordion>",
|
|
168
173
|
"lang": "html"
|
|
169
174
|
}
|
|
170
175
|
]
|
|
@@ -351,7 +356,7 @@
|
|
|
351
356
|
"examples": [
|
|
352
357
|
{
|
|
353
358
|
"title": "Expanded item",
|
|
354
|
-
"code": "<nys-accordionitem heading=\"How do I apply?\" expanded>\n<p>Visit ny.gov and complete the online application.</p>\n</nys-accordionitem>",
|
|
359
|
+
"code": "<nys-accordion>\n<nys-accordionitem heading=\"How do I apply?\" expanded>\n<p>Visit ny.gov and complete the online application.</p>\n</nys-accordionitem>\n<nys-accordionitem heading=\"What documents do I need?\">\n<p>You will need a valid ID and proof of residency.</p>\n</nys-accordionitem>\n</nys-accordion>",
|
|
355
360
|
"lang": "html"
|
|
356
361
|
}
|
|
357
362
|
]
|
|
@@ -724,13 +729,64 @@
|
|
|
724
729
|
"summary": "Alert for contextual feedback with semantic types and live region support.",
|
|
725
730
|
"examples": [
|
|
726
731
|
{
|
|
727
|
-
"title": "
|
|
728
|
-
"code": "<nys-alert
|
|
732
|
+
"title": "Basic",
|
|
733
|
+
"code": "<nys-alert heading=\"This is a heading\"></nys-alert>",
|
|
734
|
+
"lang": "html"
|
|
735
|
+
},
|
|
736
|
+
{
|
|
737
|
+
"title": "Text",
|
|
738
|
+
"code": "<nys-alert\nheading=\"This is a heading\"\ntext=\"This is additional information passed in through the text property\"\n></nys-alert>",
|
|
739
|
+
"lang": "html"
|
|
740
|
+
},
|
|
741
|
+
{
|
|
742
|
+
"title": "Rich Text",
|
|
743
|
+
"code": "<nys-alert heading=\"Rich Text\">\n<p>This is a custom alert with <strong>HTML content</strong> passed in through the slot.</p>\n<a href=\"https://www.ny.gov/\" target=\"_blank\">Learn more about our accessibility services</a>\n</nys-alert>",
|
|
744
|
+
"lang": "html"
|
|
745
|
+
},
|
|
746
|
+
{
|
|
747
|
+
"title": "Info Type",
|
|
748
|
+
"code": "<nys-alert type=\"info\" heading=\"Info alert type\"></nys-alert>",
|
|
749
|
+
"lang": "html"
|
|
750
|
+
},
|
|
751
|
+
{
|
|
752
|
+
"title": "Success Type",
|
|
753
|
+
"code": "<nys-alert type=\"success\" heading=\"Success alert type\"></nys-alert>",
|
|
754
|
+
"lang": "html"
|
|
755
|
+
},
|
|
756
|
+
{
|
|
757
|
+
"title": "Warning Type",
|
|
758
|
+
"code": "<nys-alert type=\"warning\" heading=\"Warning alert type\"></nys-alert>",
|
|
759
|
+
"lang": "html"
|
|
760
|
+
},
|
|
761
|
+
{
|
|
762
|
+
"title": "Danger Type",
|
|
763
|
+
"code": "<nys-alert type=\"danger\" heading=\"Danger alert type\"></nys-alert>",
|
|
764
|
+
"lang": "html"
|
|
765
|
+
},
|
|
766
|
+
{
|
|
767
|
+
"title": "Emergency Type",
|
|
768
|
+
"code": "<nys-alert type=\"emergency\" heading=\"Emergency alert type\"></nys-alert>",
|
|
769
|
+
"lang": "html"
|
|
770
|
+
},
|
|
771
|
+
{
|
|
772
|
+
"title": "Dismissible",
|
|
773
|
+
"code": "<nys-alert heading=\"This alert is dismisable\" text=\"Close it by clicking on the X in the corner.\" dismissible>\n</nys-alert>",
|
|
774
|
+
"lang": "html"
|
|
775
|
+
},
|
|
776
|
+
{
|
|
777
|
+
"title": "Duration",
|
|
778
|
+
"code": "<nys-alert heading=\"Disappearing alert\" text=\"This alert will disappear after 3 seconds.\" duration=\"3000\"></nys-alert>",
|
|
779
|
+
"lang": "html",
|
|
780
|
+
"render": "<nys-button\nclass=\"nys-margin-b-100\"\nlabel=\"Show alert\"\nonclick=\"document.body.appendChild(Object.assign(document.createElement('nys-alert'), {heading: 'Disappearing alert', text: 'This alert will disappear after 3 seconds.', duration: 3000}))\"\n></nys-button>"
|
|
781
|
+
},
|
|
782
|
+
{
|
|
783
|
+
"title": "Custom Icon",
|
|
784
|
+
"code": "<nys-alert\ntype=\"emergency\"\nheading=\"Winter storm warning: Dec 10th, 2024.\"\ntext=\"A major snowfall is expected across the state of New York for the weekend of Dec 7th. Stay home if possible and use extreme caution when driving.\"\nicon=\"ac_unit\">\n</nys-alert>",
|
|
729
785
|
"lang": "html"
|
|
730
786
|
},
|
|
731
787
|
{
|
|
732
|
-
"title": "
|
|
733
|
-
"code": "<nys-alert
|
|
788
|
+
"title": "Action Links",
|
|
789
|
+
"code": "<nys-alert\nheading=\"Alert with links\"\nprimaryLabel=\"{primaryAction}\"\nsecondaryLabel=\"{secondaryAction}\"\nprimaryAction=\"https://www.ny.gov/\"\nsecondaryAction=\"https://www.ny.gov/\"\n></nys-alert>",
|
|
734
790
|
"lang": "html"
|
|
735
791
|
}
|
|
736
792
|
]
|
|
@@ -1026,13 +1082,44 @@
|
|
|
1026
1082
|
"summary": "User avatar with image, initials, or icon fallback and contrast-aware colors.",
|
|
1027
1083
|
"examples": [
|
|
1028
1084
|
{
|
|
1029
|
-
"title": "
|
|
1030
|
-
"code": "<nys-avatar
|
|
1085
|
+
"title": "Basic",
|
|
1086
|
+
"code": "<nys-avatar ariaLabel=\"User avatar\"></nys-avatar>",
|
|
1031
1087
|
"lang": "html"
|
|
1032
1088
|
},
|
|
1033
1089
|
{
|
|
1034
|
-
"title": "
|
|
1035
|
-
"code": "<nys-avatar
|
|
1090
|
+
"title": "Image",
|
|
1091
|
+
"code": "<nys-avatar\nimage=\"path/to/img.png\"\nariaLabel=\"Jane Smith\"\n></nys-avatar>",
|
|
1092
|
+
"lang": "html",
|
|
1093
|
+
"render": "<nys-avatar\nimage=\"https://images.unsplash.com/photo-1523712999610-f77fbcfc3843?q=80&w=2070&auto=format&fit=crop&ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D\"\nariaLabel=\"Jane Smith\"\n></nys-avatar>"
|
|
1094
|
+
},
|
|
1095
|
+
{
|
|
1096
|
+
"title": "Initials",
|
|
1097
|
+
"code": "<nys-avatar initials=\"JS\" ariaLabel=\"Jane Smith\"></nys-avatar>",
|
|
1098
|
+
"lang": "html"
|
|
1099
|
+
},
|
|
1100
|
+
{
|
|
1101
|
+
"title": "Icon",
|
|
1102
|
+
"code": "<nys-avatar icon=\"account_circle\"></nys-avatar>",
|
|
1103
|
+
"lang": "html"
|
|
1104
|
+
},
|
|
1105
|
+
{
|
|
1106
|
+
"title": "Interactive",
|
|
1107
|
+
"code": "<nys-avatar interactive></nys-avatar>",
|
|
1108
|
+
"lang": "html"
|
|
1109
|
+
},
|
|
1110
|
+
{
|
|
1111
|
+
"title": "Disabled",
|
|
1112
|
+
"code": "<nys-avatar disabled></nys-avatar>",
|
|
1113
|
+
"lang": "html"
|
|
1114
|
+
},
|
|
1115
|
+
{
|
|
1116
|
+
"title": "Custom Background Color",
|
|
1117
|
+
"code": "<nys-avatar color=\"var(--nys-color-red-500)\" interactive></nys-avatar>",
|
|
1118
|
+
"lang": "html"
|
|
1119
|
+
},
|
|
1120
|
+
{
|
|
1121
|
+
"title": "Lazy Loading",
|
|
1122
|
+
"code": "<nys-avatar lazy></nys-avatar>",
|
|
1036
1123
|
"lang": "html"
|
|
1037
1124
|
}
|
|
1038
1125
|
]
|
|
@@ -1182,14 +1269,16 @@
|
|
|
1182
1269
|
"summary": "Floating back-to-top button with auto-show behavior, smooth scroll, and focus management.",
|
|
1183
1270
|
"examples": [
|
|
1184
1271
|
{
|
|
1185
|
-
"title": "
|
|
1272
|
+
"title": "Basic",
|
|
1186
1273
|
"code": "<footer>\n<nys-backtotop></nys-backtotop>\n<!-- Other footer content -->\n</footer>",
|
|
1187
|
-
"lang": "html"
|
|
1274
|
+
"lang": "html",
|
|
1275
|
+
"render": "<style>\ncode {\nwhite-space: nowrap;\npadding: var(--nys-space-1px) var(--nys-space-2px);\nborder-radius: var(--nys-radius-md);\ncolor: var(--nys-color-red-600);\nbackground: var(--nys-color-neutral-10);\nfont-size: var(--nys-font-size-sm);\n}\n</style>\n<nys-unavheader hideTranslate hideSearch></nys-unavheader>\n<nys-globalheader appName=\"Back to Top Example\"></nys-globalheader>\n<main style=\"padding: 0 2rem\">\n<h1>Sample Content on page</h1>\n<p>\nThis is a sample content area used to demonstrate the functionality of\nthe Back to Top button. In an actual application,\n<code>nys-backtotop</code> would not be visible until the user scrolls\ndown the page.\n</p>\n</main>\n<footer>\n<nys-backtotop visible></nys-backtotop>\n<nys-unavfooter></nys-unavfooter>\n</footer>"
|
|
1188
1276
|
},
|
|
1189
1277
|
{
|
|
1190
|
-
"title": "
|
|
1191
|
-
"code": "<nys-backtotop
|
|
1192
|
-
"lang": "html"
|
|
1278
|
+
"title": "Left",
|
|
1279
|
+
"code": "<footer>\n<nys-backtotop position=\"left\"></nys-backtotop>\n<!-- Other footer content -->\n</footer>",
|
|
1280
|
+
"lang": "html",
|
|
1281
|
+
"render": "<style>\ncode {\nwhite-space: nowrap;\npadding: var(--nys-space-1px) var(--nys-space-2px);\nborder-radius: var(--nys-radius-md);\ncolor: var(--nys-color-red-600);\nbackground: var(--nys-color-neutral-10);\nfont-size: var(--nys-font-size-sm);\n}\nnys-button {\nposition: fixed;\nbottom: 1rem;\nright: 1rem;\n--_nys-button-border-radius: var(--nys-radius-round);\n}\n</style>\n<nys-unavheader hideTranslate hideSearch></nys-unavheader>\n<nys-globalheader appName=\"Back to Top Example\"></nys-globalheader>\n<main style=\"padding: 0 2rem\">\n<h1>Sample Content on page</h1>\n<p>\nThis is a sample content area used to demonstrate the functionality of\nthe Back to Top button. In an actual application,\n<code>nys-backtotop</code> would not be visible until the user scrolls\ndown the page.\n</p>\n</main>\n<footer>\n<nys-backtotop visible position=\"left\"></nys-backtotop>\n<nys-button prefixIcon=\"sms\" variant=\"outline\" label=\"Chat with us\" size=\"sm\"></nys-button>\n<nys-unavfooter></nys-unavfooter>\n</footer>"
|
|
1193
1282
|
}
|
|
1194
1283
|
]
|
|
1195
1284
|
}
|
|
@@ -1494,13 +1583,63 @@
|
|
|
1494
1583
|
"summary": "Compact label for status, counts, or categorization with semantic styling.",
|
|
1495
1584
|
"examples": [
|
|
1496
1585
|
{
|
|
1497
|
-
"title": "
|
|
1498
|
-
"code": "<nys-badge
|
|
1586
|
+
"title": "Basic",
|
|
1587
|
+
"code": "<nys-badge label=\"Basic badge\"></nys-badge>",
|
|
1588
|
+
"lang": "html"
|
|
1589
|
+
},
|
|
1590
|
+
{
|
|
1591
|
+
"title": "Error Intent",
|
|
1592
|
+
"code": "<nys-badge label=\"Error\" intent=\"error\" prefixIcon></nys-badge>",
|
|
1593
|
+
"lang": "html"
|
|
1594
|
+
},
|
|
1595
|
+
{
|
|
1596
|
+
"title": "Warning Intent",
|
|
1597
|
+
"code": "<nys-badge label=\"Warning\" intent=\"warning\" prefixIcon></nys-badge>",
|
|
1598
|
+
"lang": "html"
|
|
1599
|
+
},
|
|
1600
|
+
{
|
|
1601
|
+
"title": "Success Intent",
|
|
1602
|
+
"code": "<nys-badge label=\"Success\" intent=\"success\" prefixIcon></nys-badge>",
|
|
1603
|
+
"lang": "html"
|
|
1604
|
+
},
|
|
1605
|
+
{
|
|
1606
|
+
"title": "Strong Neutral",
|
|
1607
|
+
"code": "<nys-badge variant=\"strong\" label=\"Neutral\" prefixIcon></nys-badge>",
|
|
1608
|
+
"lang": "html"
|
|
1609
|
+
},
|
|
1610
|
+
{
|
|
1611
|
+
"title": "Strong Error",
|
|
1612
|
+
"code": "<nys-badge variant=\"strong\" label=\"Error\" intent=\"error\" prefixIcon></nys-badge>",
|
|
1613
|
+
"lang": "html"
|
|
1614
|
+
},
|
|
1615
|
+
{
|
|
1616
|
+
"title": "Strong Warning",
|
|
1617
|
+
"code": "<nys-badge variant=\"strong\" label=\"Warning\" intent=\"warning\" prefixIcon></nys-badge>",
|
|
1618
|
+
"lang": "html"
|
|
1619
|
+
},
|
|
1620
|
+
{
|
|
1621
|
+
"title": "Strong Success",
|
|
1622
|
+
"code": "<nys-badge variant=\"strong\" label=\"Success\" intent=\"success\" prefixIcon></nys-badge>",
|
|
1623
|
+
"lang": "html"
|
|
1624
|
+
},
|
|
1625
|
+
{
|
|
1626
|
+
"title": "Custom Prefix Icon",
|
|
1627
|
+
"code": "<nys-badge label=\"Custom prefixIcon\" prefixIcon=\"check\"></nys-badge>",
|
|
1628
|
+
"lang": "html"
|
|
1629
|
+
},
|
|
1630
|
+
{
|
|
1631
|
+
"title": "Custom Suffix Icon",
|
|
1632
|
+
"code": "<nys-badge label=\"Custom suffixIcon\" suffixIcon=\"check\"></nys-badge>",
|
|
1633
|
+
"lang": "html"
|
|
1634
|
+
},
|
|
1635
|
+
{
|
|
1636
|
+
"title": "Size Small",
|
|
1637
|
+
"code": "<nys-badge label=\"Small\" size=\"sm\"></nys-badge>",
|
|
1499
1638
|
"lang": "html"
|
|
1500
1639
|
},
|
|
1501
1640
|
{
|
|
1502
|
-
"title": "
|
|
1503
|
-
"code": "<nys-badge
|
|
1641
|
+
"title": "Screen reader text",
|
|
1642
|
+
"code": "<nys-badge intent=\"warning\" label=\"Caution\" prefixIcon srText=\"concern\"></nys-badge>",
|
|
1504
1643
|
"lang": "html"
|
|
1505
1644
|
}
|
|
1506
1645
|
]
|
|
@@ -1546,11 +1685,11 @@
|
|
|
1546
1685
|
"declarations": [
|
|
1547
1686
|
{
|
|
1548
1687
|
"kind": "class",
|
|
1549
|
-
"description": "A breadcrumb navigation trail composed of `
|
|
1688
|
+
"description": "A breadcrumb navigation trail composed of `li` elements.\nCollapses when the trail exceeds 5 items on desktop or 3 items on mobile,\nshowing the first, last, and item before the current page, with an ellipsis to expand.\nA single item renders as a back-to-parent link instead of a trail.",
|
|
1550
1689
|
"name": "NysBreadcrumbs",
|
|
1551
1690
|
"slots": [
|
|
1552
1691
|
{
|
|
1553
|
-
"description": "One or more `
|
|
1692
|
+
"description": "One or more `li` elements defining the trail.",
|
|
1554
1693
|
"name": ""
|
|
1555
1694
|
}
|
|
1556
1695
|
],
|
|
@@ -1580,7 +1719,7 @@
|
|
|
1580
1719
|
"kind": "field",
|
|
1581
1720
|
"name": "size",
|
|
1582
1721
|
"type": {
|
|
1583
|
-
"text": "\"sm\" | \"md\"
|
|
1722
|
+
"text": "\"sm\" | \"md\""
|
|
1584
1723
|
},
|
|
1585
1724
|
"default": "\"md\"",
|
|
1586
1725
|
"description": "Controls the visual size of the breadcrumb text and spacing: `sm` for dense layouts, `md` (default) for standard use.",
|
|
@@ -1803,7 +1942,7 @@
|
|
|
1803
1942
|
{
|
|
1804
1943
|
"name": "size",
|
|
1805
1944
|
"type": {
|
|
1806
|
-
"text": "\"sm\" | \"md\"
|
|
1945
|
+
"text": "\"sm\" | \"md\""
|
|
1807
1946
|
},
|
|
1808
1947
|
"default": "\"md\"",
|
|
1809
1948
|
"description": "Controls the visual size of the breadcrumb text and spacing: `sm` for dense layouts, `md` (default) for standard use.",
|
|
@@ -1860,19 +1999,44 @@
|
|
|
1860
1999
|
"summary": "Breadcrumb navigation trail with responsive collapse support.",
|
|
1861
2000
|
"examples": [
|
|
1862
2001
|
{
|
|
1863
|
-
"title": "
|
|
1864
|
-
"code": "<nys-breadcrumbs>\n<ol>\n<li><a href=\"/\">Home</a></li>\n<li><a href=\"/services\">Services</a></li>\n
|
|
2002
|
+
"title": "Basic",
|
|
2003
|
+
"code": "<nys-breadcrumbs>\n<ol>\n<li><a href=\"/\">Home</a></li>\n<li><a href=\"/services\">Services</a></li>\n</ol>\n</nys-breadcrumbs>",
|
|
1865
2004
|
"lang": "html"
|
|
1866
2005
|
},
|
|
1867
2006
|
{
|
|
1868
|
-
"title": "
|
|
1869
|
-
"code": "<nys-breadcrumbs>\n<ol>\n<li><a href=\"/\">Home</a></li>\n<li><a href=\"/services\">Services</a></li>\n</ol>\n</nys-breadcrumbs>",
|
|
2007
|
+
"title": "Current page",
|
|
2008
|
+
"code": "<nys-breadcrumbs>\n<ol>\n<li><a href=\"/\">Home</a></li>\n<li><a href=\"/services\">Services</a></li>\n<li>Current Page</li>\n</ol>\n</nys-breadcrumbs>",
|
|
1870
2009
|
"lang": "html"
|
|
1871
2010
|
},
|
|
1872
2011
|
{
|
|
1873
|
-
"title": "Single item
|
|
2012
|
+
"title": "Single item list",
|
|
1874
2013
|
"code": "<nys-breadcrumbs>\n<ol>\n<li><a href=\"/services\">Services</a></li>\n</ol>\n</nys-breadcrumbs>",
|
|
1875
2014
|
"lang": "html"
|
|
2015
|
+
},
|
|
2016
|
+
{
|
|
2017
|
+
"title": "Long list",
|
|
2018
|
+
"code": "<nys-breadcrumbs>\n<ol>\n<li><a href=\"/\">Home</a></li>\n<li><a href=\"/government\">Government</a></li>\n<li><a href=\"/government/agencies\">Agencies</a></li>\n<li><a href=\"/government/agencies/parks\">Parks & Recreation</a></li>\n<li><a href=\"/parks/state-parks\">State Parks</a></li>\n<li><a href=\"/parks/state-parks/delaware\">Delaware Region</a></li>\n<li><a href=\"/parks/state-parks/delaware/water-gap\">Delaware Water Gap</a></li>\n<li>Trail Conditions</li>\n</ol>\n</nys-breadcrumbs>",
|
|
2019
|
+
"lang": "html"
|
|
2020
|
+
},
|
|
2021
|
+
{
|
|
2022
|
+
"title": "Size small",
|
|
2023
|
+
"code": "<nys-breadcrumbs size=\"sm\">\n<ol>\n<li><a href=\"/\">Home</a></li>\n<li><a href=\"/government\">Government</a></li>\n<li><a href=\"/government/agencies\">Agencies</a></li>\n<li>Parks & Recreation</li>\n</ol>\n</nys-breadcrumbs>",
|
|
2024
|
+
"lang": "html"
|
|
2025
|
+
},
|
|
2026
|
+
{
|
|
2027
|
+
"title": "Back to parent (mobile)",
|
|
2028
|
+
"code": "<nys-breadcrumbs backToParent>\n<ol>\n<li><a href=\"/\">Home</a></li>\n<li><a href=\"/government\">Government</a></li>\n<li><a href=\"/government/agencies\">Agencies</a></li>\n<li><a href=\"/government/agencies/parks\">Parks & Recreation</a></li>\n<li><a href=\"/parks/state-parks\">State Parks</a></li>\n<li><a href=\"/parks/state-parks/delaware\">Delaware Region</a></li>\n<li><a href=\"/parks/state-parks/delaware/water-gap\">Delaware Water Gap</a></li>\n<li>Trail Conditions</li>\n</ol>\n</nys-breadcrumbs>",
|
|
2029
|
+
"lang": "html"
|
|
2030
|
+
},
|
|
2031
|
+
{
|
|
2032
|
+
"title": "Background bar",
|
|
2033
|
+
"code": "<nys-breadcrumbs backgroundBar>\n<ol>\n<li><a href=\"/\">Home</a></li>\n<li><a href=\"/services\">Services</a></li>\n<li><a href=\"/tickets\">Ticket System</a></li>\n<li>Del Water Gap</li>\n</ol>\n</nys-breadcrumbs>",
|
|
2034
|
+
"lang": "html"
|
|
2035
|
+
},
|
|
2036
|
+
{
|
|
2037
|
+
"title": "Disabled",
|
|
2038
|
+
"code": "<nys-breadcrumbs disabled>\n<ol>\n<li><a href=\"/\">Home</a></li>\n<li><a href=\"/services\">Services</a></li>\n<li><a href=\"/tickets\">Ticket System</a></li>\n<li>Del Water Gap</li>\n</ol>\n</nys-breadcrumbs>",
|
|
2039
|
+
"lang": "html"
|
|
1876
2040
|
}
|
|
1877
2041
|
]
|
|
1878
2042
|
}
|
|
@@ -1958,6 +2122,10 @@
|
|
|
1958
2122
|
}
|
|
1959
2123
|
],
|
|
1960
2124
|
"slots": [
|
|
2125
|
+
{
|
|
2126
|
+
"description": "Button label text. Use as fallback when `label` prop is not provided.",
|
|
2127
|
+
"name": ""
|
|
2128
|
+
},
|
|
1961
2129
|
{
|
|
1962
2130
|
"description": "Icon before label. Not shown for `text` variant.",
|
|
1963
2131
|
"name": "prefix-icon"
|
|
@@ -2227,6 +2395,15 @@
|
|
|
2227
2395
|
"privacy": "private",
|
|
2228
2396
|
"default": "false"
|
|
2229
2397
|
},
|
|
2398
|
+
{
|
|
2399
|
+
"kind": "field",
|
|
2400
|
+
"name": "_hasCircleSlot",
|
|
2401
|
+
"type": {
|
|
2402
|
+
"text": "boolean"
|
|
2403
|
+
},
|
|
2404
|
+
"privacy": "private",
|
|
2405
|
+
"default": "false"
|
|
2406
|
+
},
|
|
2230
2407
|
{
|
|
2231
2408
|
"kind": "field",
|
|
2232
2409
|
"name": "formAssociated",
|
|
@@ -2269,6 +2446,19 @@
|
|
|
2269
2446
|
}
|
|
2270
2447
|
]
|
|
2271
2448
|
},
|
|
2449
|
+
{
|
|
2450
|
+
"kind": "method",
|
|
2451
|
+
"name": "_onCircleSlotChange",
|
|
2452
|
+
"privacy": "private",
|
|
2453
|
+
"parameters": [
|
|
2454
|
+
{
|
|
2455
|
+
"name": "e",
|
|
2456
|
+
"type": {
|
|
2457
|
+
"text": "Event"
|
|
2458
|
+
}
|
|
2459
|
+
}
|
|
2460
|
+
]
|
|
2461
|
+
},
|
|
2272
2462
|
{
|
|
2273
2463
|
"kind": "method",
|
|
2274
2464
|
"name": "_manageFormAction",
|
|
@@ -2579,18 +2769,38 @@
|
|
|
2579
2769
|
"summary": "Button for actions and CTAs with variants, sizes, and icon support.",
|
|
2580
2770
|
"examples": [
|
|
2581
2771
|
{
|
|
2582
|
-
"title": "Basic
|
|
2583
|
-
"code": "<nys-button label=\"
|
|
2772
|
+
"title": "Basic",
|
|
2773
|
+
"code": "<nys-button label=\"Button\" variant=\"filled\"></nys-button>",
|
|
2774
|
+
"lang": "html"
|
|
2775
|
+
},
|
|
2776
|
+
{
|
|
2777
|
+
"title": "Variant Outline",
|
|
2778
|
+
"code": "<nys-button label=\"Button\" variant=\"outline\"></nys-button>",
|
|
2584
2779
|
"lang": "html"
|
|
2585
2780
|
},
|
|
2586
2781
|
{
|
|
2587
|
-
"title": "
|
|
2588
|
-
"code": "<nys-button label=\"
|
|
2782
|
+
"title": "Variant Ghost",
|
|
2783
|
+
"code": "<nys-button label=\"Button\" variant=\"ghost\"></nys-button>",
|
|
2589
2784
|
"lang": "html"
|
|
2590
2785
|
},
|
|
2591
2786
|
{
|
|
2592
|
-
"title": "
|
|
2593
|
-
"code": "<nys-button label=\"
|
|
2787
|
+
"title": "Variant Text",
|
|
2788
|
+
"code": "<nys-button label=\"Button\" variant=\"text\"></nys-button>",
|
|
2789
|
+
"lang": "html"
|
|
2790
|
+
},
|
|
2791
|
+
{
|
|
2792
|
+
"title": "Prefix Icon",
|
|
2793
|
+
"code": "<nys-button label=\"Previous\" prefixIcon=\"chevron_left\"></nys-button>",
|
|
2794
|
+
"lang": "html"
|
|
2795
|
+
},
|
|
2796
|
+
{
|
|
2797
|
+
"title": "Suffix Icon",
|
|
2798
|
+
"code": "<nys-button label=\"Next\" suffixIcon=\"chevron_right\"></nys-button>",
|
|
2799
|
+
"lang": "html"
|
|
2800
|
+
},
|
|
2801
|
+
{
|
|
2802
|
+
"title": "Slotted Icons",
|
|
2803
|
+
"code": "<nys-button label=\"Slotted icons\">\n<nys-icon color=\"#db117d\" slot=\"prefix-icon\" name=\"chevron_left\"></nys-icon>\n<nys-icon color=\"#db117d\" slot=\"suffix-icon\" name=\"chevron_right\"></nys-icon>\n</nys-button>",
|
|
2594
2804
|
"lang": "html"
|
|
2595
2805
|
},
|
|
2596
2806
|
{
|
|
@@ -2599,12 +2809,38 @@
|
|
|
2599
2809
|
"lang": "html"
|
|
2600
2810
|
},
|
|
2601
2811
|
{
|
|
2602
|
-
"title": "
|
|
2812
|
+
"title": "Size Small",
|
|
2813
|
+
"code": "<nys-button label=\"Small\" size=\"sm\"></nys-button>",
|
|
2814
|
+
"lang": "html"
|
|
2815
|
+
},
|
|
2816
|
+
{
|
|
2817
|
+
"title": "Size Large",
|
|
2818
|
+
"code": "<nys-button label=\"Large\" size=\"lg\"></nys-button>",
|
|
2819
|
+
"lang": "html"
|
|
2820
|
+
},
|
|
2821
|
+
{
|
|
2822
|
+
"title": "Full width",
|
|
2823
|
+
"code": "<nys-button label=\"Full width\" fullWidth></nys-button>",
|
|
2824
|
+
"lang": "html"
|
|
2825
|
+
},
|
|
2826
|
+
{
|
|
2827
|
+
"title": "Inverted",
|
|
2828
|
+
"code": "<nys-button label=\"Inverted\" inverted></nys-button>",
|
|
2829
|
+
"lang": "html",
|
|
2830
|
+
"render": "<div style=\"background: #1b1b1b; padding: 1rem;\">\n<nys-button label=\"Inverted\" inverted></nys-button>\n</div>"
|
|
2831
|
+
},
|
|
2832
|
+
{
|
|
2833
|
+
"title": "Disabled",
|
|
2834
|
+
"code": "<nys-button label=\"Disabled\" disabled></nys-button>",
|
|
2835
|
+
"lang": "html"
|
|
2836
|
+
},
|
|
2837
|
+
{
|
|
2838
|
+
"title": "Href",
|
|
2603
2839
|
"code": "<nys-button label=\"Visit NY.gov\" href=\"https://www.ny.gov/\" target=\"_blank\" suffixIcon=\"open_in_new\"></nys-button>",
|
|
2604
2840
|
"lang": "html"
|
|
2605
2841
|
},
|
|
2606
2842
|
{
|
|
2607
|
-
"title": "
|
|
2843
|
+
"title": "Type",
|
|
2608
2844
|
"code": "<nys-button type=\"submit\" label=\"Save Changes\" variant=\"filled\"></nys-button>",
|
|
2609
2845
|
"lang": "html"
|
|
2610
2846
|
}
|
|
@@ -2970,6 +3206,11 @@
|
|
|
2970
3206
|
"name": "_hasDescription",
|
|
2971
3207
|
"readonly": true
|
|
2972
3208
|
},
|
|
3209
|
+
{
|
|
3210
|
+
"kind": "field",
|
|
3211
|
+
"name": "_isStandalone",
|
|
3212
|
+
"readonly": true
|
|
3213
|
+
},
|
|
2973
3214
|
{
|
|
2974
3215
|
"kind": "field",
|
|
2975
3216
|
"name": "_handleMobileQuery",
|
|
@@ -3272,13 +3513,13 @@
|
|
|
3272
3513
|
"summary": "Checkbox for binary choices or multi-select options.",
|
|
3273
3514
|
"examples": [
|
|
3274
3515
|
{
|
|
3275
|
-
"title": "Single
|
|
3276
|
-
"code": "<nys-checkbox label=\"I agree to the terms\" name=\"terms\"
|
|
3516
|
+
"title": "Single",
|
|
3517
|
+
"code": "<nys-checkbox label=\"I agree to the terms\" name=\"terms\"></nys-checkbox>",
|
|
3277
3518
|
"lang": "html"
|
|
3278
3519
|
},
|
|
3279
3520
|
{
|
|
3280
|
-
"title": "
|
|
3281
|
-
"code": "<nys-
|
|
3521
|
+
"title": "Preselected",
|
|
3522
|
+
"code": "<nys-checkbox label=\"I agree to the terms\" name=\"terms\" checked></nys-checkbox>",
|
|
3282
3523
|
"lang": "html"
|
|
3283
3524
|
}
|
|
3284
3525
|
]
|
|
@@ -3791,9 +4032,54 @@
|
|
|
3791
4032
|
"summary": "Container for grouping checkboxes as a single form control.",
|
|
3792
4033
|
"examples": [
|
|
3793
4034
|
{
|
|
3794
|
-
"title": "Basic
|
|
4035
|
+
"title": "Basic",
|
|
4036
|
+
"code": "<nys-checkboxgroup label=\"Select landmarks\" required>\n<nys-checkbox name=\"landmarks\" value=\"adirondacks\" label=\"Adirondacks\"></nys-checkbox>\n<nys-checkbox name=\"landmarks\" value=\"niagara\" label=\"Niagara Falls\"></nys-checkbox>\n</nys-checkboxgroup>",
|
|
4037
|
+
"lang": "html"
|
|
4038
|
+
},
|
|
4039
|
+
{
|
|
4040
|
+
"title": "Tile",
|
|
4041
|
+
"code": "<nys-checkboxgroup label=\"Select landmarks\" tile>\n<nys-checkbox name=\"landmarks\" value=\"adirondacks\" label=\"Adirondacks\"></nys-checkbox>\n<nys-checkbox name=\"landmarks\" value=\"niagara\" label=\"Niagara Falls\"></nys-checkbox>\n</nys-checkboxgroup>",
|
|
4042
|
+
"lang": "html"
|
|
4043
|
+
},
|
|
4044
|
+
{
|
|
4045
|
+
"title": "Required",
|
|
3795
4046
|
"code": "<nys-checkboxgroup label=\"Select landmarks\" required>\n<nys-checkbox name=\"landmarks\" value=\"adirondacks\" label=\"Adirondacks\"></nys-checkbox>\n<nys-checkbox name=\"landmarks\" value=\"niagara\" label=\"Niagara Falls\"></nys-checkbox>\n</nys-checkboxgroup>",
|
|
3796
4047
|
"lang": "html"
|
|
4048
|
+
},
|
|
4049
|
+
{
|
|
4050
|
+
"title": "Optional",
|
|
4051
|
+
"code": "<nys-checkboxgroup label=\"Select landmarks\" optional>\n<nys-checkbox name=\"landmarks\" value=\"adirondacks\" label=\"Adirondacks\"></nys-checkbox>\n<nys-checkbox name=\"landmarks\" value=\"niagara\" label=\"Niagara Falls\"></nys-checkbox>\n</nys-checkboxgroup>",
|
|
4052
|
+
"lang": "html"
|
|
4053
|
+
},
|
|
4054
|
+
{
|
|
4055
|
+
"title": "Disabled",
|
|
4056
|
+
"code": "<nys-checkboxgroup label=\"Select landmarks\">\n<nys-checkbox name=\"landmarks\" value=\"adirondacks\" label=\"Adirondacks\" disabled></nys-checkbox>\n<nys-checkbox name=\"landmarks\" value=\"niagara\" label=\"Niagara Falls\" disabled></nys-checkbox>\n</nys-checkboxgroup>",
|
|
4057
|
+
"lang": "html"
|
|
4058
|
+
},
|
|
4059
|
+
{
|
|
4060
|
+
"title": "Size Small",
|
|
4061
|
+
"code": "<nys-checkboxgroup label=\"Select landmarks\" size=\"sm\">\n<nys-checkbox name=\"landmarks\" value=\"adirondacks\" label=\"Adirondacks\"></nys-checkbox>\n<nys-checkbox name=\"landmarks\" value=\"niagara\" label=\"Niagara Falls\"></nys-checkbox>\n</nys-checkboxgroup>",
|
|
4062
|
+
"lang": "html"
|
|
4063
|
+
},
|
|
4064
|
+
{
|
|
4065
|
+
"title": "Other Option",
|
|
4066
|
+
"code": "<nys-checkboxgroup label=\"Select landmarks\">\n<nys-checkbox name=\"landmarks\" value=\"adirondacks\" label=\"Adirondacks\"></nys-checkbox>\n<nys-checkbox name=\"landmarks\" value=\"niagara\" label=\"Niagara Falls\"></nys-checkbox>\n<nys-checkbox name=\"landmarks\" value=\"\" label=\"Other\" other></nys-checkbox>\n</nys-checkboxgroup>",
|
|
4067
|
+
"lang": "html"
|
|
4068
|
+
},
|
|
4069
|
+
{
|
|
4070
|
+
"title": "Error Message",
|
|
4071
|
+
"code": "<nys-checkboxgroup label=\"Select landmarks\" showError errorMessage=\"Please select at least one landmark\">\n<nys-checkbox name=\"landmarks\" value=\"adirondacks\" label=\"Adirondacks\"></nys-checkbox>\n<nys-checkbox name=\"landmarks\" value=\"niagara\" label=\"Niagara Falls\"></nys-checkbox>\n</nys-checkboxgroup>",
|
|
4072
|
+
"lang": "html"
|
|
4073
|
+
},
|
|
4074
|
+
{
|
|
4075
|
+
"title": "Description",
|
|
4076
|
+
"code": "<nys-checkboxgroup label=\"Select landmarks\" description=\"Choose wisely, you can only pick one.\">\n<nys-checkbox name=\"landmarks\" value=\"adirondacks\" label=\"Adirondacks\"></nys-checkbox>\n<nys-checkbox name=\"landmarks\" value=\"niagara\" label=\"Niagara Falls\"></nys-checkbox>\n</nys-checkboxgroup>",
|
|
4077
|
+
"lang": "html"
|
|
4078
|
+
},
|
|
4079
|
+
{
|
|
4080
|
+
"title": "Description Slot",
|
|
4081
|
+
"code": "<nys-checkboxgroup label=\"Select landmarks\">\n<div slot=\"description\">Your <strong>ABSOLUTE</strong> favorite one.</div>\n<nys-checkbox name=\"landmarks\" value=\"adirondacks\" label=\"Adirondacks\"></nys-checkbox>\n<nys-checkbox name=\"landmarks\" value=\"niagara\" label=\"Niagara Falls\"></nys-checkbox>\n</nys-checkboxgroup>",
|
|
4082
|
+
"lang": "html"
|
|
3797
4083
|
}
|
|
3798
4084
|
]
|
|
3799
4085
|
}
|
|
@@ -4520,6 +4806,67 @@
|
|
|
4520
4806
|
"name": "LitElement",
|
|
4521
4807
|
"package": "lit"
|
|
4522
4808
|
},
|
|
4809
|
+
"examples": [
|
|
4810
|
+
{
|
|
4811
|
+
"title": "Basic",
|
|
4812
|
+
"code": "<nys-combobox label=\"Select your favorite fruit\">\n<option value=\"apple\">Apple</option>\n<option value=\"banana\">Banana</option>\n<option value=\"cherry\">Cherry</option>\n<option value=\"date\">Date</option>\n<option value=\"elderberry\">Elderberry</option>\n<option value=\"fig\">Fig</option>\n<option value=\"grape\">Grape</option>\n<option value=\"honeydew\">Honeydew</option>\n<option value=\"kiwi\">Kiwi</option>\n<option value=\"lemon\">Lemon</option>\n<option value=\"mango\">Mango</option>\n<option value=\"nectarine\">Nectarine</option>\n<option value=\"orange\">Orange</option>\n<option value=\"papaya\">Papaya</option>\n<option value=\"quince\">Quince</option>\n<option value=\"raspberry\">Raspberry</option>\n<option value=\"strawberry\">Strawberry</option>\n<option value=\"tangerine\">Tangerine</option>\n<option value=\"watermelon\">Watermelon</option>\n</nys-combobox>",
|
|
4813
|
+
"lang": "html"
|
|
4814
|
+
},
|
|
4815
|
+
{
|
|
4816
|
+
"title": "Default Value",
|
|
4817
|
+
"code": "<nys-combobox label=\"Select your favorite fruit\" value=\"mango\">\n<option value=\"apple\">Apple</option>\n<option value=\"banana\">Banana</option>\n<option value=\"mango\" selected>Mango</option>\n<option value=\"orange\">Orange</option>\n<option value=\"strawberry\">Strawberry</option>\n</nys-combobox>",
|
|
4818
|
+
"lang": "html"
|
|
4819
|
+
},
|
|
4820
|
+
{
|
|
4821
|
+
"title": "Option Group",
|
|
4822
|
+
"code": "<nys-combobox label=\"Select a fruit\" description=\"Fruits organized by category\">\n<optgroup label=\"Citrus\">\n<option value=\"lemon\">Lemon</option>\n<option value=\"lime\">Lime</option>\n<option value=\"orange\">Orange</option>\n<option value=\"grapefruit\">Grapefruit</option>\n<option value=\"tangerine\">Tangerine</option>\n</optgroup>\n<optgroup label=\"Berries\">\n<option value=\"strawberry\">Strawberry</option>\n<option value=\"blueberry\">Blueberry</option>\n<option value=\"raspberry\">Raspberry</option>\n<option value=\"blackberry\">Blackberry</option>\n<option value=\"cranberry\">Cranberry</option>\n</optgroup>\n<optgroup label=\"Tropical\">\n<option value=\"mango\">Mango</option>\n<option value=\"pineapple\">Pineapple</option>\n<option value=\"papaya\">Papaya</option>\n<option value=\"coconut\">Coconut</option>\n<option value=\"passionfruit\">Passionfruit</option>\n</optgroup>\n<optgroup label=\"Stone Fruits\">\n<option value=\"peach\">Peach</option>\n<option value=\"plum\">Plum</option>\n<option value=\"cherry\">Cherry</option>\n<option value=\"apricot\">Apricot</option>\n<option value=\"nectarine\">Nectarine</option>\n</optgroup>\n</nys-combobox>",
|
|
4823
|
+
"lang": "html"
|
|
4824
|
+
},
|
|
4825
|
+
{
|
|
4826
|
+
"title": "Disabled",
|
|
4827
|
+
"code": "<nys-combobox label=\"Select your favorite fruit\" disabled>\n<option value=\"apple\">Apple</option>\n<option value=\"banana\">Banana</option>\n<option value=\"orange\">Orange</option>\n<option value=\"strawberry\">Strawberry</option>\n</nys-combobox>",
|
|
4828
|
+
"lang": "html"
|
|
4829
|
+
},
|
|
4830
|
+
{
|
|
4831
|
+
"title": "Required",
|
|
4832
|
+
"code": "<nys-combobox label=\"Select your favorite fruit\" required>\n<option value=\"apple\">Apple</option>\n<option value=\"banana\">Banana</option>\n<option value=\"orange\">Orange</option>\n<option value=\"strawberry\">Strawberry</option>\n</nys-combobox>",
|
|
4833
|
+
"lang": "html"
|
|
4834
|
+
},
|
|
4835
|
+
{
|
|
4836
|
+
"title": "Optional",
|
|
4837
|
+
"code": "<nys-combobox label=\"Select your favorite fruit\" optional>\n<option value=\"apple\">Apple</option>\n<option value=\"banana\">Banana</option>\n<option value=\"orange\">Orange</option>\n<option value=\"strawberry\">Strawberry</option>\n</nys-combobox>",
|
|
4838
|
+
"lang": "html"
|
|
4839
|
+
},
|
|
4840
|
+
{
|
|
4841
|
+
"title": "Width Medium",
|
|
4842
|
+
"code": "<nys-combobox label=\"Select your favorite fruit\" width=\"md\">\n<option value=\"apple\">Apple</option>\n<option value=\"banana\">Banana</option>\n<option value=\"orange\">Orange</option>\n<option value=\"strawberry\">Strawberry</option>\n</nys-combobox>",
|
|
4843
|
+
"lang": "html"
|
|
4844
|
+
},
|
|
4845
|
+
{
|
|
4846
|
+
"title": "Width Large",
|
|
4847
|
+
"code": "<nys-combobox label=\"Select your favorite fruit\" width=\"lg\">\n<option value=\"apple\">Apple</option>\n<option value=\"banana\">Banana</option>\n<option value=\"orange\">Orange</option>\n<option value=\"strawberry\">Strawberry</option>\n</nys-combobox>",
|
|
4848
|
+
"lang": "html"
|
|
4849
|
+
},
|
|
4850
|
+
{
|
|
4851
|
+
"title": "Description",
|
|
4852
|
+
"code": "```html\n<nys-combobox label=\"Select your favorite fruit\" description=\"Choose from the list of available fruits.\">\n<option value=\"apple\">Apple</option>\n<option value=\"banana\">Banana</option>\n<option value=\"orange\">Orange</option>\n<option value=\"strawberry\">Strawberry</option>\n</nys-combobox>\n```d"
|
|
4853
|
+
},
|
|
4854
|
+
{
|
|
4855
|
+
"title": "Description Slot",
|
|
4856
|
+
"code": "<nys-combobox label=\"Select your favorite fruit\">\n<label slot=\"description\">This is a description slot</label>\n<option value=\"apple\">Apple</option>\n<option value=\"banana\">Banana</option>\n<option value=\"orange\">Orange</option>\n<option value=\"strawberry\">Strawberry</option>\n</nys-combobox>",
|
|
4857
|
+
"lang": "html"
|
|
4858
|
+
},
|
|
4859
|
+
{
|
|
4860
|
+
"title": "Error Message",
|
|
4861
|
+
"code": "<nys-combobox label=\"Select your favorite fruit\" showError errorMessage=\"Please select a fruit\">\n<option value=\"apple\">Apple</option>\n<option value=\"banana\">Banana</option>\n<option value=\"orange\">Orange</option>\n<option value=\"strawberry\">Strawberry</option>\n</nys-combobox>",
|
|
4862
|
+
"lang": "html"
|
|
4863
|
+
},
|
|
4864
|
+
{
|
|
4865
|
+
"title": "Disabled Options",
|
|
4866
|
+
"code": "<nys-combobox label=\"Select your favorite fruit\" description=\"Some fruits are out of season\">\n<option value=\"apple\">Apple</option>\n<option value=\"banana\">Banana</option>\n<option value=\"cherry\" disabled>Cherry (Out of season)</option>\n<option value=\"mango\">Mango</option>\n<option value=\"strawberry\" disabled>Strawberry (Out of season)</option>\n<option value=\"orange\">Orange</option>\n</nys-combobox>",
|
|
4867
|
+
"lang": "html"
|
|
4868
|
+
}
|
|
4869
|
+
],
|
|
4523
4870
|
"tagName": "nys-combobox",
|
|
4524
4871
|
"customElement": true
|
|
4525
4872
|
}
|
|
@@ -5326,23 +5673,53 @@
|
|
|
5326
5673
|
"summary": "Date picker with calendar popup and native fallback.",
|
|
5327
5674
|
"examples": [
|
|
5328
5675
|
{
|
|
5329
|
-
"title": "Basic
|
|
5330
|
-
"code": "<nys-datepicker
|
|
5676
|
+
"title": "Basic",
|
|
5677
|
+
"code": "<nys-datepicker\nid=\"my-datepicker\"\nname=\"my-datepicker\"\nlabel=\"Schedule an appointment\"\ndescription=\"Enter in MM/DD/YYYY format\"\n></nys-datepicker>",
|
|
5331
5678
|
"lang": "html"
|
|
5332
5679
|
},
|
|
5333
5680
|
{
|
|
5334
|
-
"title": "
|
|
5681
|
+
"title": "Width Large",
|
|
5335
5682
|
"code": "<nys-datepicker\nlabel=\"Event Date\"\ndescription=\"Select the date of your event\"\nwidth=\"lg\">\n</nys-datepicker>",
|
|
5336
5683
|
"lang": "html"
|
|
5337
5684
|
},
|
|
5338
5685
|
{
|
|
5339
|
-
"title": "
|
|
5340
|
-
"code": "<nys-datepicker\nlabel=\"
|
|
5686
|
+
"title": "Width Full",
|
|
5687
|
+
"code": "<nys-datepicker\nlabel=\"Event Date\"\ndescription=\"Select the date of your event\"\nwidth=\"full\">\n</nys-datepicker>",
|
|
5688
|
+
"lang": "html"
|
|
5689
|
+
},
|
|
5690
|
+
{
|
|
5691
|
+
"title": "Custom Start Date",
|
|
5692
|
+
"code": "<nys-datepicker\nlabel=\"Appointment\"\nstartDate=\"2024-01-01\">\n</nys-datepicker>",
|
|
5693
|
+
"lang": "html"
|
|
5694
|
+
},
|
|
5695
|
+
{
|
|
5696
|
+
"title": "Without Buttons",
|
|
5697
|
+
"code": "<nys-datepicker\nlabel=\"Appointment\"\nhideTodayButton\nhideClearButton>\n</nys-datepicker>",
|
|
5698
|
+
"lang": "html"
|
|
5699
|
+
},
|
|
5700
|
+
{
|
|
5701
|
+
"title": "Error Message",
|
|
5702
|
+
"code": "<nys-datepicker\nlabel=\"Start Date\"\nshowError\nerrorMessage=\"Please select a valid start date\">\n</nys-datepicker>",
|
|
5703
|
+
"lang": "html"
|
|
5704
|
+
},
|
|
5705
|
+
{
|
|
5706
|
+
"title": "Date Range",
|
|
5707
|
+
"code": "<nys-datepicker\nlabel=\"Select a date\"\ndescription=\"Only dates within April 4/5/2026 - 7/15/2026 are selectable\"\nminDate=\"2026-04-05\"\nmaxDate=\"2026-07-15\">\n</nys-datepicker>",
|
|
5341
5708
|
"lang": "html"
|
|
5342
5709
|
},
|
|
5343
5710
|
{
|
|
5344
|
-
"title": "
|
|
5345
|
-
"code": "<nys-datepicker\nlabel=\"
|
|
5711
|
+
"title": "Disabled",
|
|
5712
|
+
"code": "<nys-datepicker\nlabel=\"Disabled datepicker\"\ndisabled\nvalue=\"2025-01-15\">\n</nys-datepicker>",
|
|
5713
|
+
"lang": "html"
|
|
5714
|
+
},
|
|
5715
|
+
{
|
|
5716
|
+
"title": "Required",
|
|
5717
|
+
"code": "<nys-datepicker\nlabel=\"Start Date\"\nrequired>\n</nys-datepicker>",
|
|
5718
|
+
"lang": "html"
|
|
5719
|
+
},
|
|
5720
|
+
{
|
|
5721
|
+
"title": "Optional",
|
|
5722
|
+
"code": "<nys-datepicker\nlabel=\"Start Date\"\noptional>\n</nys-datepicker>",
|
|
5346
5723
|
"lang": "html"
|
|
5347
5724
|
}
|
|
5348
5725
|
]
|
|
@@ -5459,9 +5836,20 @@
|
|
|
5459
5836
|
"summary": "Horizontal divider for visual separation of content sections.",
|
|
5460
5837
|
"examples": [
|
|
5461
5838
|
{
|
|
5462
|
-
"title": "Basic
|
|
5839
|
+
"title": "Basic",
|
|
5463
5840
|
"code": "<p>Section one content</p>\n<nys-divider></nys-divider>\n<p>Section two content</p>",
|
|
5464
5841
|
"lang": "html"
|
|
5842
|
+
},
|
|
5843
|
+
{
|
|
5844
|
+
"title": "Inverted",
|
|
5845
|
+
"code": "<p>Section one content</p>\n<nys-divider inverted></nys-divider>\n<p>Section two content</p>",
|
|
5846
|
+
"lang": "html",
|
|
5847
|
+
"render": "<div style=\"display: flex; flex-direction: column; background-color: var(--nys-color-ink, #1b1b1b); color: var(--nys-color-ink-reverse, #fff); padding: var(--nys-space-200, 16px);\">\n<p>Section one content</p>\n<nys-divider inverted></nys-divider>\n<p>Section two content</p>\n</div>"
|
|
5848
|
+
},
|
|
5849
|
+
{
|
|
5850
|
+
"title": "Subtle",
|
|
5851
|
+
"code": "<p>Section one content</p>\n<nys-divider subtle></nys-divider>\n<p>Section two content</p>",
|
|
5852
|
+
"lang": "html"
|
|
5465
5853
|
}
|
|
5466
5854
|
]
|
|
5467
5855
|
}
|
|
@@ -5514,7 +5902,7 @@
|
|
|
5514
5902
|
"declarations": [
|
|
5515
5903
|
{
|
|
5516
5904
|
"kind": "class",
|
|
5517
|
-
"description": "",
|
|
5905
|
+
"description": "Dropdown menus enable users to select an action from a list of options.\nThey’re commonly used to save space by grouping related actions, or to provide actions in a confined space.",
|
|
5518
5906
|
"name": "NysDropdownMenu",
|
|
5519
5907
|
"members": [
|
|
5520
5908
|
{
|
|
@@ -5891,7 +6279,16 @@
|
|
|
5891
6279
|
"package": "lit"
|
|
5892
6280
|
},
|
|
5893
6281
|
"tagName": "nys-dropdownmenu",
|
|
5894
|
-
"customElement": true
|
|
6282
|
+
"customElement": true,
|
|
6283
|
+
"summary": "Action menu with auto-positioning, keyboard support, and screen reader integration.",
|
|
6284
|
+
"examples": [
|
|
6285
|
+
{
|
|
6286
|
+
"title": "Basic",
|
|
6287
|
+
"code": "<nys-button id=\"my-trigger-id\" label=\"Open Menu\"></nys-button>\n<nys-dropdownmenu id=\"my-dropdownmenu\" for=\"my-trigger-id\">\n<nys-dropdownmenuitem label=\"Profile\" href=\"/profile\"></nys-dropdownmenuitem>\n<nys-dropdownmenuitem label=\"Repositories & Github Pages\" href=\"/repos\"></nys-dropdownmenuitem>\n<nys-dropdownmenuitem label=\"Organizations\" href=\"/organizations\"></nys-dropdownmenuitem>\n<nys-dropdownmenuitem label=\"Sign out\" href=\"/logout\"></nys-dropdownmenuitem>\n</nys-dropdownmenu>\n</div>",
|
|
6288
|
+
"lang": "html",
|
|
6289
|
+
"render": "<div style=\"margin: 200px; display: flex; justify-content: center; align-items: center;\">\n<nys-button id=\"my-trigger-id\" label=\"Open Menu\"></nys-button>\n<nys-dropdownmenu id=\"my-dropdownmenu\" for=\"my-trigger-id\">\n<nys-dropdownmenuitem label=\"Profile\" href=\"/profile\"></nys-dropdownmenuitem>\n<nys-dropdownmenuitem label=\"Repositories & Github Pages\" href=\"/repos\"></nys-dropdownmenuitem>\n<nys-dropdownmenuitem label=\"Organizations\" href=\"/organizations\"></nys-dropdownmenuitem>\n<nys-dropdownmenuitem label=\"Sign out\" href=\"/logout\"></nys-dropdownmenuitem>\n</nys-dropdownmenu>\n</div>"
|
|
6290
|
+
}
|
|
6291
|
+
]
|
|
5895
6292
|
}
|
|
5896
6293
|
],
|
|
5897
6294
|
"exports": [
|
|
@@ -6070,19 +6467,7 @@
|
|
|
6070
6467
|
},
|
|
6071
6468
|
"tagName": "nys-dropdownmenuitem",
|
|
6072
6469
|
"customElement": true,
|
|
6073
|
-
"summary": "Dropdown item to display label and provide href link."
|
|
6074
|
-
"examples": [
|
|
6075
|
-
{
|
|
6076
|
-
"title": "Basic item",
|
|
6077
|
-
"code": "<nys-dropdownmenuitem label=\"Edit\" link=\"/edit\"></nys-dropdownmenuitem>",
|
|
6078
|
-
"lang": "html"
|
|
6079
|
-
},
|
|
6080
|
-
{
|
|
6081
|
-
"title": "Disabled item",
|
|
6082
|
-
"code": "<nys-dropdownmenuitem label=\"Delete\" link=\"/delete\" disabled></nys-dropdownmenuitem>",
|
|
6083
|
-
"lang": "html"
|
|
6084
|
-
}
|
|
6085
|
-
]
|
|
6470
|
+
"summary": "Dropdown item to display label and provide href link."
|
|
6086
6471
|
}
|
|
6087
6472
|
],
|
|
6088
6473
|
"exports": [
|
|
@@ -6219,7 +6604,19 @@
|
|
|
6219
6604
|
},
|
|
6220
6605
|
"tagName": "nys-errormessage",
|
|
6221
6606
|
"customElement": true,
|
|
6222
|
-
"summary": "Internal error message display with icon and ARIA alert support."
|
|
6607
|
+
"summary": "Internal error message display with icon and ARIA alert support.",
|
|
6608
|
+
"examples": [
|
|
6609
|
+
{
|
|
6610
|
+
"title": "Basic",
|
|
6611
|
+
"code": "<nys-errormessage showError errorMessage=\"This is an error message\"></nys-errormessage>",
|
|
6612
|
+
"lang": "html"
|
|
6613
|
+
},
|
|
6614
|
+
{
|
|
6615
|
+
"title": "Divider",
|
|
6616
|
+
"code": "<nys-errormessage showError errorMessage=\"This is an error message\" showDivider></nys-errormessage>",
|
|
6617
|
+
"lang": "html"
|
|
6618
|
+
}
|
|
6619
|
+
]
|
|
6223
6620
|
}
|
|
6224
6621
|
],
|
|
6225
6622
|
"exports": [
|
|
@@ -6262,7 +6659,7 @@
|
|
|
6262
6659
|
"declarations": [
|
|
6263
6660
|
{
|
|
6264
6661
|
"kind": "class",
|
|
6265
|
-
"description": "A file input for uploading files with support for multiple files, drag-and-drop, and progress tracking.\nValidates file types via magic bytes (not just extension). Form-associated via ElementInternals.\n\nUse for document uploads, image uploads, or any file submission. Enable `dropzone` for drag-and-drop UI.",
|
|
6662
|
+
"description": "A file input for uploading files with support for multiple files, drag-and-drop, and progress tracking.\nValidates file types via magic bytes (not just extension). Form-associated via ElementInternals.\n\nUse for document uploads, image uploads, or any file submission. Enable `dropzone` for drag-and-drop UI.\n\nRead or write the current selection via the `files` (`File[]`) and `value` (`File | null`)\nproperties — useful for rehydrating state or binding from a framework form model.\nSetting them is silent (does not emit `nys-change`).",
|
|
6266
6663
|
"name": "NysFileinput",
|
|
6267
6664
|
"slots": [
|
|
6268
6665
|
{
|
|
@@ -6458,6 +6855,41 @@
|
|
|
6458
6855
|
"privacy": "private",
|
|
6459
6856
|
"default": "[]"
|
|
6460
6857
|
},
|
|
6858
|
+
{
|
|
6859
|
+
"kind": "field",
|
|
6860
|
+
"name": "files",
|
|
6861
|
+
"type": {
|
|
6862
|
+
"text": "File[]"
|
|
6863
|
+
},
|
|
6864
|
+
"description": "The currently selected files. Read to get the current selection; set to\nreplace it (e.g. rehydrating state after navigation, or binding from a\nframework form model). Property-only — a `File[]` cannot round-trip through\nan HTML attribute. Setting this is silent (does not emit `nys-change`),\nmatching native input behavior and avoiding feedback loops in two-way bindings."
|
|
6865
|
+
},
|
|
6866
|
+
{
|
|
6867
|
+
"kind": "field",
|
|
6868
|
+
"name": "value",
|
|
6869
|
+
"type": {
|
|
6870
|
+
"text": "File | null"
|
|
6871
|
+
},
|
|
6872
|
+
"description": "Single-file convenience accessor (parity with `nys-textinput`'s `value`).\nReads the first selected file (or `null`); setting replaces the selection."
|
|
6873
|
+
},
|
|
6874
|
+
{
|
|
6875
|
+
"kind": "method",
|
|
6876
|
+
"name": "setFiles",
|
|
6877
|
+
"privacy": "public",
|
|
6878
|
+
"return": {
|
|
6879
|
+
"type": {
|
|
6880
|
+
"text": "Promise<void>"
|
|
6881
|
+
}
|
|
6882
|
+
},
|
|
6883
|
+
"parameters": [
|
|
6884
|
+
{
|
|
6885
|
+
"name": "incoming",
|
|
6886
|
+
"type": {
|
|
6887
|
+
"text": "File[]"
|
|
6888
|
+
}
|
|
6889
|
+
}
|
|
6890
|
+
],
|
|
6891
|
+
"description": "Programmatically set the selection and await async validation/processing.\nSame as assigning `files`, but resolves once every file has finished its\nmagic-byte validation and read — use when you need to read `checkValidity()`\nor the settled selection immediately after."
|
|
6892
|
+
},
|
|
6461
6893
|
{
|
|
6462
6894
|
"kind": "field",
|
|
6463
6895
|
"name": "_dragActive",
|
|
@@ -6605,6 +7037,19 @@
|
|
|
6605
7037
|
}
|
|
6606
7038
|
]
|
|
6607
7039
|
},
|
|
7040
|
+
{
|
|
7041
|
+
"kind": "method",
|
|
7042
|
+
"name": "_handleBlur",
|
|
7043
|
+
"privacy": "private",
|
|
7044
|
+
"parameters": [
|
|
7045
|
+
{
|
|
7046
|
+
"name": "e",
|
|
7047
|
+
"type": {
|
|
7048
|
+
"text": "FocusEvent"
|
|
7049
|
+
}
|
|
7050
|
+
}
|
|
7051
|
+
]
|
|
7052
|
+
},
|
|
6608
7053
|
{
|
|
6609
7054
|
"kind": "method",
|
|
6610
7055
|
"name": "_dispatchChangeEvent",
|
|
@@ -6693,6 +7138,13 @@
|
|
|
6693
7138
|
}
|
|
6694
7139
|
],
|
|
6695
7140
|
"events": [
|
|
7141
|
+
{
|
|
7142
|
+
"name": "nys-blur",
|
|
7143
|
+
"type": {
|
|
7144
|
+
"text": "Event"
|
|
7145
|
+
},
|
|
7146
|
+
"description": "Fired when focus leaves the component. Triggers validation."
|
|
7147
|
+
},
|
|
6696
7148
|
{
|
|
6697
7149
|
"name": "nys-change",
|
|
6698
7150
|
"type": {
|
|
@@ -6872,13 +7324,48 @@
|
|
|
6872
7324
|
"summary": "File input with drag-and-drop, validation, and progress tracking.",
|
|
6873
7325
|
"examples": [
|
|
6874
7326
|
{
|
|
6875
|
-
"title": "
|
|
6876
|
-
"code": "<nys-fileinput
|
|
7327
|
+
"title": "Basic",
|
|
7328
|
+
"code": "<nys-fileinput\nlabel=\"Upload a file\"\n></nys-fileinput>",
|
|
7329
|
+
"lang": "html"
|
|
7330
|
+
},
|
|
7331
|
+
{
|
|
7332
|
+
"title": "Dropzone",
|
|
7333
|
+
"code": "<nys-fileinput\nlabel=\"Upload a file\"\ndropzone\n></nys-fileinput>",
|
|
7334
|
+
"lang": "html"
|
|
7335
|
+
},
|
|
7336
|
+
{
|
|
7337
|
+
"title": "Multiple",
|
|
7338
|
+
"code": "<nys-fileinput\nlabel=\"Upload a file\"\nmultiple\n></nys-fileinput>",
|
|
7339
|
+
"lang": "html"
|
|
7340
|
+
},
|
|
7341
|
+
{
|
|
7342
|
+
"title": "Accepted Filetypes",
|
|
7343
|
+
"code": "<nys-fileinput\nlabel=\"Upload a file\"\ndescription=\"Accepted file types: .jpg, .png, .pdf\"\naccept=\"image/png, image/jpeg, .pdf\"\n></nys-fileinput>",
|
|
7344
|
+
"lang": "html"
|
|
7345
|
+
},
|
|
7346
|
+
{
|
|
7347
|
+
"title": "Width Large",
|
|
7348
|
+
"code": "<nys-fileinput\nlabel=\"Upload a file\"\nwidth=\"lg\"\n></nys-fileinput>",
|
|
7349
|
+
"lang": "html"
|
|
7350
|
+
},
|
|
7351
|
+
{
|
|
7352
|
+
"title": "Width Large Dropzone",
|
|
7353
|
+
"code": "<nys-fileinput\nlabel=\"Upload a file\"\nwidth=\"lg\"\ndropzone\n></nys-fileinput>",
|
|
7354
|
+
"lang": "html"
|
|
7355
|
+
},
|
|
7356
|
+
{
|
|
7357
|
+
"title": "Disabled",
|
|
7358
|
+
"code": "<nys-fileinput\nlabel=\"Upload a file\"\ndisabled\n></nys-fileinput>",
|
|
6877
7359
|
"lang": "html"
|
|
6878
7360
|
},
|
|
6879
7361
|
{
|
|
6880
|
-
"title": "
|
|
6881
|
-
"code": "<nys-fileinput
|
|
7362
|
+
"title": "Description",
|
|
7363
|
+
"code": "<nys-fileinput\nlabel=\"Upload a file\"\ndescription=\"Make sure the file is not blurry and readable\"\n></nys-fileinput>",
|
|
7364
|
+
"lang": "html"
|
|
7365
|
+
},
|
|
7366
|
+
{
|
|
7367
|
+
"title": "Description Slot",
|
|
7368
|
+
"code": "<nys-fileinput label=\"Upload a file\">\n<div slot=\"description\">Make sure the file is <strong>legible</strong></div>\n</nys-fileinput>",
|
|
6882
7369
|
"lang": "html"
|
|
6883
7370
|
}
|
|
6884
7371
|
]
|
|
@@ -7215,8 +7702,28 @@
|
|
|
7215
7702
|
"summary": "Agency footer with auto-layout for contact info and link sections.",
|
|
7216
7703
|
"examples": [
|
|
7217
7704
|
{
|
|
7218
|
-
"title": "
|
|
7219
|
-
"code": "<nys-globalfooter
|
|
7705
|
+
"title": "Basic",
|
|
7706
|
+
"code": "<nys-globalfooter agencyName=\"Office of Information Technology Services\"></nys-globalfooter>",
|
|
7707
|
+
"lang": "html"
|
|
7708
|
+
},
|
|
7709
|
+
{
|
|
7710
|
+
"title": "Homepage Link",
|
|
7711
|
+
"code": "<nys-globalfooter\nagencyName=\"Office of Information Technology Services\"\nhomepageLink=\"https://its.ny.gov\"\n></nys-globalfooter>",
|
|
7712
|
+
"lang": "html"
|
|
7713
|
+
},
|
|
7714
|
+
{
|
|
7715
|
+
"title": "Menu Links",
|
|
7716
|
+
"code": "<nys-globalfooter agencyName=\"Office of Information Technology Services\">\n<ul>\n<li><a href=\"https://its.ny.gov\">ITS Home</a></li>\n<li><a href=\"https://its.ny.gov/about-us\">About ITS</a></li>\n</ul>\n</nys-globalfooter>",
|
|
7717
|
+
"lang": "html"
|
|
7718
|
+
},
|
|
7719
|
+
{
|
|
7720
|
+
"title": "Column Links",
|
|
7721
|
+
"code": "<nys-globalfooter agencyName=\"Office of Information Technology Services\">\n<ul>\n<li>\n<span>About</span>\n<ul>\n<li><a href=\"https://its.ny.gov/about-us\">About ITS</a></li>\n<li><a href=\"https://its.ny.gov/contact-us\">Contact</a></li>\n<li><a href=\"https://its.ny.gov/policies\">Policies</a></li>\n</ul>\n</li>\n<li>\n<span>Resources</span>\n<ul>\n<li><a href=\"https://its.ny.gov/resources\">Developer Tools</a></li>\n<li><a href=\"https://its.ny.gov/accessibility\">Accessibility</a></li>\n<li><a href=\"https://its.ny.gov/privacy\">Privacy</a></li>\n</ul>\n</li>\n</ul>\n</nys-globalfooter>",
|
|
7722
|
+
"lang": "html"
|
|
7723
|
+
},
|
|
7724
|
+
{
|
|
7725
|
+
"title": "Subheading",
|
|
7726
|
+
"code": "<nys-globalfooter\nagencyName=\"Office of Information Technology Services\"\nagencySubheading=\"Innovating Technology for a Better New York\"\n></nys-globalfooter>",
|
|
7220
7727
|
"lang": "html"
|
|
7221
7728
|
}
|
|
7222
7729
|
]
|
|
@@ -7268,6 +7775,10 @@
|
|
|
7268
7775
|
{
|
|
7269
7776
|
"description": "Navigation content (typically `<ul>` with `<li><a>` links). Auto-sanitized.",
|
|
7270
7777
|
"name": ""
|
|
7778
|
+
},
|
|
7779
|
+
{
|
|
7780
|
+
"description": "User-account controls (e.g. profile link, settings, log-out button) shown in the header.",
|
|
7781
|
+
"name": "user-actions"
|
|
7271
7782
|
}
|
|
7272
7783
|
],
|
|
7273
7784
|
"members": [
|
|
@@ -7308,7 +7819,7 @@
|
|
|
7308
7819
|
"text": "boolean"
|
|
7309
7820
|
},
|
|
7310
7821
|
"default": "false",
|
|
7311
|
-
"description": "
|
|
7822
|
+
"description": "Displays the NYS brand mark in the header. Off by default.\n\nEnable only for internal, state-employee (back-office) applications that omit\n`nys-unavheader`. Any resident-facing app — even one requiring login — should\nkeep `nys-unavheader` for trust and leave this off.",
|
|
7312
7823
|
"attribute": "nysLogo"
|
|
7313
7824
|
},
|
|
7314
7825
|
{
|
|
@@ -7436,7 +7947,7 @@
|
|
|
7436
7947
|
"text": "boolean"
|
|
7437
7948
|
},
|
|
7438
7949
|
"default": "false",
|
|
7439
|
-
"description": "
|
|
7950
|
+
"description": "Displays the NYS brand mark in the header. Off by default.\n\nEnable only for internal, state-employee (back-office) applications that omit\n`nys-unavheader`. Any resident-facing app — even one requiring login — should\nkeep `nys-unavheader` for trust and leave this off.",
|
|
7440
7951
|
"fieldName": "nysLogo",
|
|
7441
7952
|
"propName": "nyslogo"
|
|
7442
7953
|
}
|
|
@@ -7450,8 +7961,38 @@
|
|
|
7450
7961
|
"summary": "Agency header with navigation, mobile menu, and active link highlighting.",
|
|
7451
7962
|
"examples": [
|
|
7452
7963
|
{
|
|
7453
|
-
"title": "Basic
|
|
7454
|
-
"code": "<nys-globalheader appName=\"
|
|
7964
|
+
"title": "Basic",
|
|
7965
|
+
"code": "<nys-globalheader appName=\"User Registration Form\" agencyName=\"Office of Information Technology Services\"></nys-globalheader>",
|
|
7966
|
+
"lang": "html"
|
|
7967
|
+
},
|
|
7968
|
+
{
|
|
7969
|
+
"title": "Homepage Link",
|
|
7970
|
+
"code": "<nys-globalheader\nagencyName=\"Office of Information Technology Services\"\nhomepageLink=\"https://its.ny.gov\"\n></nys-globalheader>",
|
|
7971
|
+
"lang": "html"
|
|
7972
|
+
},
|
|
7973
|
+
{
|
|
7974
|
+
"title": "Only Agency Name",
|
|
7975
|
+
"code": "<nys-globalheader agencyName=\"Office of Information Technology Services\"></nys-globalheader>",
|
|
7976
|
+
"lang": "html"
|
|
7977
|
+
},
|
|
7978
|
+
{
|
|
7979
|
+
"title": "Only App Name",
|
|
7980
|
+
"code": "<nys-globalheader appName=\"User Registration Form\"></nys-globalheader>",
|
|
7981
|
+
"lang": "html"
|
|
7982
|
+
},
|
|
7983
|
+
{
|
|
7984
|
+
"title": "With Links",
|
|
7985
|
+
"code": "<nys-globalheader agencyName=\"Office of Information Technology Services\">\n<ul>\n<li><a href=\"https://its.ny.gov/services\">Services</a></li>\n<li><a href=\"https://its.ny.gov/get-help\">Help Center</a></li>\n<li><a href=\"https://its.ny.gov/cybersecurity\">Cybersecurity</a></li>\n<li><a href=\"https://its.ny.gov/policies\">Policies and Laws</a></li>\n<li><a href=\"https://its.ny.gov/procurement\">Procurement</a></li>\n<li><a href=\"https://its.ny.gov/about-us\">About Us</a></li>\n</ul>\n</nys-globalheader>",
|
|
7986
|
+
"lang": "html"
|
|
7987
|
+
},
|
|
7988
|
+
{
|
|
7989
|
+
"title": "User Actions",
|
|
7990
|
+
"code": "<nys-globalheader agencyName=\"Office of Information Technology Services\">\n<nys-button slot=\"user-actions\" label=\"Log out\">\n<nys-avatar\nslot=\"prefix-icon\"\nariaLabel=\"User avatar\"\ninitials=\"NY\"\n></nys-avatar>\n</nys-button>\n</nys-globalheader>\n<nys-dropdownmenu id=\"dropdownmenu\" for=\"my-action-slot\">\n<nys-dropdownmenuitem label=\"Profile\" href=\"/profile\"></nys-dropdownmenuitem>\n<nys-dropdownmenuitem label=\"Repositories & Github Pages\" href=\"/repos\"></nys-dropdownmenuitem>\n<nys-dropdownmenuitem label=\"Organizations\" href=\"/organizations\" disabled></nys-dropdownmenuitem>\n<nys-dropdownmenuitem label=\"Sign out\" href=\"/logout\"></nys-dropdownmenuitem>\n</nys-dropdownmenu>",
|
|
7991
|
+
"lang": "html"
|
|
7992
|
+
},
|
|
7993
|
+
{
|
|
7994
|
+
"title": "With NYS Logo",
|
|
7995
|
+
"code": "<nys-globalheader nysLogo appName=\"Admin Dashboard\"></nys-globalheader>",
|
|
7455
7996
|
"lang": "html"
|
|
7456
7997
|
}
|
|
7457
7998
|
]
|
|
@@ -7497,7 +8038,7 @@
|
|
|
7497
8038
|
}
|
|
7498
8039
|
}
|
|
7499
8040
|
],
|
|
7500
|
-
"description": "Clear one or all
|
|
8041
|
+
"description": "Clear one URL entry, or all cached icons (URL and inline) when no URL is given."
|
|
7501
8042
|
},
|
|
7502
8043
|
{
|
|
7503
8044
|
"kind": "function",
|
|
@@ -7516,6 +8057,24 @@
|
|
|
7516
8057
|
}
|
|
7517
8058
|
],
|
|
7518
8059
|
"description": "Fetch and parse an SVG from a URL. Returns a cloned SVGElement (safe for multiple consumers)."
|
|
8060
|
+
},
|
|
8061
|
+
{
|
|
8062
|
+
"kind": "function",
|
|
8063
|
+
"name": "parseIcon",
|
|
8064
|
+
"return": {
|
|
8065
|
+
"type": {
|
|
8066
|
+
"text": "SVGElement"
|
|
8067
|
+
}
|
|
8068
|
+
},
|
|
8069
|
+
"parameters": [
|
|
8070
|
+
{
|
|
8071
|
+
"name": "source",
|
|
8072
|
+
"type": {
|
|
8073
|
+
"text": "string"
|
|
8074
|
+
}
|
|
8075
|
+
}
|
|
8076
|
+
],
|
|
8077
|
+
"description": "Parse an inline SVG source string. Results are cached by source content,\nso repeated renders of the same icon sanitize/parse once. Returns a\ncloned SVGElement (safe for multiple consumers)."
|
|
7519
8078
|
}
|
|
7520
8079
|
],
|
|
7521
8080
|
"exports": [
|
|
@@ -7534,6 +8093,14 @@
|
|
|
7534
8093
|
"name": "fetchIcon",
|
|
7535
8094
|
"module": "packages/nys-icon/src/icon-cache.ts"
|
|
7536
8095
|
}
|
|
8096
|
+
},
|
|
8097
|
+
{
|
|
8098
|
+
"kind": "js",
|
|
8099
|
+
"name": "parseIcon",
|
|
8100
|
+
"declaration": {
|
|
8101
|
+
"name": "parseIcon",
|
|
8102
|
+
"module": "packages/nys-icon/src/icon-cache.ts"
|
|
8103
|
+
}
|
|
7537
8104
|
}
|
|
7538
8105
|
]
|
|
7539
8106
|
},
|
|
@@ -7581,7 +8148,7 @@
|
|
|
7581
8148
|
}
|
|
7582
8149
|
}
|
|
7583
8150
|
],
|
|
7584
|
-
"description": "Register or replace a named icon library. All watching icons using this library will redraw.",
|
|
8151
|
+
"description": "Register or replace a named icon library. All watching icons using this library will redraw.\n\nIntended for custom/external libraries — the standard NYSDS set is\nbuilt in and needs no registration. Registering under `\"default\"`\nreplaces the built-in set (escape hatch).",
|
|
7585
8152
|
"examples": [
|
|
7586
8153
|
{
|
|
7587
8154
|
"title": "Register a Font Awesome library with a custom resolver:",
|
|
@@ -7721,6 +8288,14 @@
|
|
|
7721
8288
|
"module": "./icon-cache"
|
|
7722
8289
|
}
|
|
7723
8290
|
},
|
|
8291
|
+
{
|
|
8292
|
+
"kind": "js",
|
|
8293
|
+
"name": "getIconLibrary",
|
|
8294
|
+
"declaration": {
|
|
8295
|
+
"name": "getIconLibrary",
|
|
8296
|
+
"module": "./icon-library-registry"
|
|
8297
|
+
}
|
|
8298
|
+
},
|
|
7724
8299
|
{
|
|
7725
8300
|
"kind": "js",
|
|
7726
8301
|
"name": "IconLibrary",
|
|
@@ -7729,6 +8304,14 @@
|
|
|
7729
8304
|
"module": "./icon-library-registry"
|
|
7730
8305
|
}
|
|
7731
8306
|
},
|
|
8307
|
+
{
|
|
8308
|
+
"kind": "js",
|
|
8309
|
+
"name": "IconResolution",
|
|
8310
|
+
"declaration": {
|
|
8311
|
+
"name": "IconResolution",
|
|
8312
|
+
"module": "./icon-library-registry"
|
|
8313
|
+
}
|
|
8314
|
+
},
|
|
7732
8315
|
{
|
|
7733
8316
|
"kind": "js",
|
|
7734
8317
|
"name": "registerIconLibrary",
|
|
@@ -7978,19 +8561,51 @@
|
|
|
7978
8561
|
"summary": "SVG icon with swappable library support, size, rotation, and color options.",
|
|
7979
8562
|
"examples": [
|
|
7980
8563
|
{
|
|
7981
|
-
"title": "Basic
|
|
7982
|
-
"code": "<nys-icon name=\"check_circle\"
|
|
8564
|
+
"title": "Basic",
|
|
8565
|
+
"code": "<nys-icon name=\"check_circle\"></nys-icon>",
|
|
8566
|
+
"lang": "html"
|
|
8567
|
+
},
|
|
8568
|
+
{
|
|
8569
|
+
"title": "ARIA Label",
|
|
8570
|
+
"code": "<nys-icon\nname=\"edit_square\"\nariaLabel=\"Edit content\"\n></nys-icon>",
|
|
8571
|
+
"lang": "html"
|
|
8572
|
+
},
|
|
8573
|
+
{
|
|
8574
|
+
"title": "Size relative",
|
|
8575
|
+
"code": "<nys-icon\nname=\"edit_square\"\nsize=\"4xl\"\n></nys-icon>",
|
|
8576
|
+
"lang": "html"
|
|
8577
|
+
},
|
|
8578
|
+
{
|
|
8579
|
+
"title": "Size literal",
|
|
8580
|
+
"code": "<nys-icon\nname=\"edit_square\"\nsize=\"24\"\n></nys-icon>",
|
|
8581
|
+
"lang": "html"
|
|
8582
|
+
},
|
|
8583
|
+
{
|
|
8584
|
+
"title": "Color",
|
|
8585
|
+
"code": "<nys-icon\nname=\"edit_square\"\ncolor=\"#db117d\"\n></nys-icon>",
|
|
7983
8586
|
"lang": "html"
|
|
7984
8587
|
},
|
|
7985
8588
|
{
|
|
7986
|
-
"title": "
|
|
7987
|
-
"code": "<nys-icon
|
|
8589
|
+
"title": "Rotate",
|
|
8590
|
+
"code": "<nys-icon\nname=\"edit_square\"\nrotate=\"20\"\n></nys-icon>",
|
|
7988
8591
|
"lang": "html"
|
|
7989
8592
|
},
|
|
7990
8593
|
{
|
|
7991
|
-
"title": "
|
|
7992
|
-
"code": "<nys-icon
|
|
8594
|
+
"title": "Flip",
|
|
8595
|
+
"code": "<nys-icon\nname=\"edit_square\"\nflip=\"vertical\"\n></nys-icon>",
|
|
7993
8596
|
"lang": "html"
|
|
8597
|
+
},
|
|
8598
|
+
{
|
|
8599
|
+
"title": "External Library - Font Awesome",
|
|
8600
|
+
"code": "<nys-icon name=\"heart\" library=\"fa\"></nys-icon>",
|
|
8601
|
+
"lang": "html",
|
|
8602
|
+
"render": "<nys-icon name=\"heart\" library=\"fa\"></nys-icon>\n<script data-scope=\"module\">\nregisterIconLibrary(\"fa\", {\nresolver: (name) =>\n`https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@6/svgs/solid/${name}.svg`,\nmutator: (svg) => {\nsvg.setAttribute(\"fill\", \"currentColor\");\n},\n});\n</script>"
|
|
8603
|
+
},
|
|
8604
|
+
{
|
|
8605
|
+
"title": "External Library - Material",
|
|
8606
|
+
"code": "<nys-icon name=\"favorite\" library=\"material\"></nys-icon>",
|
|
8607
|
+
"lang": "html",
|
|
8608
|
+
"render": "<nys-icon name=\"favorite\" library=\"material\"></nys-icon>\n<script data-scope=\"module\">\nregisterIconLibrary(\"material\", {\nresolver: (name) =>\n`https://fonts.gstatic.com/s/i/short-term/release/materialsymbolsoutlined/${name}/default/24px.svg`,\nmutator: (svg) => {\nsvg.setAttribute(\"fill\", \"currentColor\");\n},\n});\n</script>"
|
|
7994
8609
|
}
|
|
7995
8610
|
]
|
|
7996
8611
|
}
|
|
@@ -8187,9 +8802,40 @@
|
|
|
8187
8802
|
"name": "LitElement",
|
|
8188
8803
|
"package": "lit"
|
|
8189
8804
|
},
|
|
8805
|
+
"examples": [
|
|
8806
|
+
{
|
|
8807
|
+
"title": "Basic",
|
|
8808
|
+
"code": "<nys-label label=\"This is a basic nys-label\"></nys-label>",
|
|
8809
|
+
"lang": "html"
|
|
8810
|
+
},
|
|
8811
|
+
{
|
|
8812
|
+
"title": "Required",
|
|
8813
|
+
"code": "<nys-label label=\"This form is required\" flag=\"required\"></nys-label>",
|
|
8814
|
+
"lang": "html"
|
|
8815
|
+
},
|
|
8816
|
+
{
|
|
8817
|
+
"title": "Optional",
|
|
8818
|
+
"code": "<nys-label label=\"This form is required\" flag=\"optional\"></nys-label>",
|
|
8819
|
+
"lang": "html"
|
|
8820
|
+
},
|
|
8821
|
+
{
|
|
8822
|
+
"title": "Description",
|
|
8823
|
+
"code": "<nys-label label=\"Label Text\" description=\"Description text\"></nys-label>",
|
|
8824
|
+
"lang": "html"
|
|
8825
|
+
},
|
|
8826
|
+
{
|
|
8827
|
+
"title": "Description Slot",
|
|
8828
|
+
"code": "<nys-label label=\"Label Text\">\n<p slot=\"description\">Rich text description passed in <strong>HERE</strong></p>\n</nys-label>",
|
|
8829
|
+
"lang": "html"
|
|
8830
|
+
},
|
|
8831
|
+
{
|
|
8832
|
+
"title": "With Tooltip",
|
|
8833
|
+
"code": "<nys-label id=\"label-id\" label=\"This label has a tooltip\"></nys-label>\n<nys-tooltip for=\"label-id\" text=\"Tooltip text in here\"></nys-tooltip>",
|
|
8834
|
+
"lang": "html"
|
|
8835
|
+
}
|
|
8836
|
+
],
|
|
8190
8837
|
"tagName": "nys-label",
|
|
8191
|
-
"customElement": true
|
|
8192
|
-
"summary": "Internal label component for form fields with flag and tooltip support."
|
|
8838
|
+
"customElement": true
|
|
8193
8839
|
}
|
|
8194
8840
|
],
|
|
8195
8841
|
"exports": [
|
|
@@ -8528,9 +9174,28 @@
|
|
|
8528
9174
|
"summary": "Accessible modal dialog with focus trap, keyboard support, and action slots.",
|
|
8529
9175
|
"examples": [
|
|
8530
9176
|
{
|
|
8531
|
-
"title": "Basic
|
|
8532
|
-
"code": "<nys-modal
|
|
8533
|
-
"lang": "html"
|
|
9177
|
+
"title": "Basic",
|
|
9178
|
+
"code": "<nys-modal\nid=\"modal1\"\nheading=\"Update Available\"\n>\n<p>\nWould you like to install the latest version? Albany ipsum dolor sit\nEmpire, Hudson consectetur Adirondack elit, sed do MetroCard tempor\nincididunt ut Capitol et Broadway magna Niagara. Ut enim ad Erie\nveniam, quis nostrud Catskill ullamco Bronx nisi ut LongIsland ex ea\nCuomo consequat.\n</p>\n</nys-modal>",
|
|
9179
|
+
"lang": "html",
|
|
9180
|
+
"render": "<div id=\"modal-wrapper1\">\n<nys-button label=\"Open Modal\" onclick=\"document.querySelector('.modal1').open = true; document.getElementById('modal-wrapper1').style.padding = '100px 0'\"></nys-button>\n<nys-modal\nclass=\"modal1\"\nid=\"modal1\"\nheading=\"Update Available\"\n>\n<p>\nWould you like to install the latest version? Albany ipsum dolor sit\nEmpire, Hudson consectetur Adirondack elit, sed do MetroCard tempor\nincididunt ut Capitol et Broadway magna Niagara. Ut enim ad Erie\nveniam, quis nostrud Catskill ullamco Bronx nisi ut LongIsland ex ea\nCuomo consequat.\n</p>\n</nys-modal>\n</div>"
|
|
9181
|
+
},
|
|
9182
|
+
{
|
|
9183
|
+
"title": "Subheading",
|
|
9184
|
+
"code": "<nys-modal\nid=\"modal-subheading\"\nheading=\"Before you continue\"\nsubheading=\"Your progress has been saved automatically.\"\n>\n<p>You can safely leave this page and return later to pick up where you left off.</p>\n</nys-modal>",
|
|
9185
|
+
"lang": "html",
|
|
9186
|
+
"render": "<div id=\"modal-wrapper-subheading\">\n<nys-button label=\"Open Modal\" onclick=\"document.querySelector('.modal-subheading').open = true; document.getElementById('modal-wrapper-subheading').style.padding = '100px 0'\"></nys-button>\n<nys-modal\nclass=\"modal-subheading\"\nid=\"modal-subheading\"\nheading=\"Before you continue\"\nsubheading=\"Your progress has been saved automatically.\"\n>\n<p>You can safely leave this page and return later to pick up where you left off.</p>\n</nys-modal>\n</div>"
|
|
9187
|
+
},
|
|
9188
|
+
{
|
|
9189
|
+
"title": "Actions Slot",
|
|
9190
|
+
"code": "<nys-modal id=\"modal3\" heading=\"Update password?\">\n<p>\nWould you like to install the latest version? Albany ipsum dolor sit\nEmpire, Hudson consectetur Adirondack elit, sed do MetroCard tempor\nincididunt ut Capitol et Broadway magna Niagara. Ut enim ad Erie\nveniam, quis nostrud Catskill ullamco Bronx nisi ut LongIsland ex ea\nCuomo consequat.\n</p>\n<div slot=\"actions\">\n<nys-button label=\"Not now\" variant=\"outline\"></nys-button>\n<nys-button label=\"Update\"></nys-button>\n</div>\n</nys-modal>",
|
|
9191
|
+
"lang": "html",
|
|
9192
|
+
"render": "<div id=\"modal-wrapper3\">\n<nys-button label=\"Open Modal\" onclick=\"document.querySelector('.modal3').open = true; document.getElementById('modal-wrapper3').style.padding = '100px 0'\"></nys-button>\n<nys-modal\nclass=\"modal3\"\nid=\"modal3\"\nheading=\"Update password?\"\n>\n<p>\nWould you like to install the latest version? Albany ipsum dolor sit\nEmpire, Hudson consectetur Adirondack elit, sed do MetroCard tempor\nincididunt ut Capitol et Broadway magna Niagara. Ut enim ad Erie\nveniam, quis nostrud Catskill ullamco Bronx nisi ut LongIsland ex ea\nCuomo consequat.\n</p>\n<div slot=\"actions\">\n<nys-button label=\"Not now\" variant=\"outline\" onclick=\"document.querySelector('.modal3').open = false; document.getElementById('modal-wrapper3').style.padding = '0'\"></nys-button>\n<nys-button label=\"Update\" onclick=\"alert('Mock Alert: Changes saved!'); document.querySelector('.modal3').open = false; document.getElementById('modal-wrapper3').style.padding = '0'\"></nys-button>\n</div>\n</nys-modal>\n</div>"
|
|
9193
|
+
},
|
|
9194
|
+
{
|
|
9195
|
+
"title": "Mandatory Action",
|
|
9196
|
+
"code": "<nys-modal\nid=\"modal4\"\nheading=\"There is no way to X out of here\"\nsubheading=\"Don't use this prop unless you add in the actions slot so the user does not get stuck in here.\"\nmandatory\n>\n<div slot=\"actions\">\n<nys-button label=\"Get me out\"></nys-button>\n</div>\n</nys-modal>",
|
|
9197
|
+
"lang": "html",
|
|
9198
|
+
"render": "<div id=\"modal-wrapper4\">\n<nys-button label=\"Open Modal\" onclick=\"document.querySelector('.modal4').open = true; document.getElementById('modal-wrapper4').style.padding = '100px 0'\"></nys-button>\n<nys-modal\nclass=\"modal4\"\nid=\"modal4\"\nheading=\"There is no way to X out of here\"\nsubheading=\"Don't use this prop unless you add in the actions slot so the user does not get stuck in here.\"\nmandatory\n>\n<div slot=\"actions\">\n<nys-button label=\"Get me out\" onclick=\"alert('Ok, ok. You can go now.'); document.querySelector('.modal4').open = false; document.getElementById('modal-wrapper4').style.padding = '0'\"></nys-button>\n</div>\n</nys-modal>\n</div>"
|
|
8534
9199
|
}
|
|
8535
9200
|
]
|
|
8536
9201
|
}
|
|
@@ -8742,9 +9407,19 @@
|
|
|
8742
9407
|
"summary": "Page navigation with numbered links, prev/next buttons, and responsive layout.",
|
|
8743
9408
|
"examples": [
|
|
8744
9409
|
{
|
|
8745
|
-
"title": "Basic
|
|
9410
|
+
"title": "Basic",
|
|
9411
|
+
"code": "<nys-pagination currentPage=\"5\" totalPages=\"10\"></nys-pagination>",
|
|
9412
|
+
"lang": "html"
|
|
9413
|
+
},
|
|
9414
|
+
{
|
|
9415
|
+
"title": "First Page",
|
|
8746
9416
|
"code": "<nys-pagination currentPage=\"1\" totalPages=\"10\"></nys-pagination>",
|
|
8747
9417
|
"lang": "html"
|
|
9418
|
+
},
|
|
9419
|
+
{
|
|
9420
|
+
"title": "Last Page",
|
|
9421
|
+
"code": "<nys-pagination currentPage=\"10\" totalPages=\"10\"></nys-pagination>",
|
|
9422
|
+
"lang": "html"
|
|
8748
9423
|
}
|
|
8749
9424
|
]
|
|
8750
9425
|
}
|
|
@@ -9101,8 +9776,8 @@
|
|
|
9101
9776
|
"summary": "Radio button for single selection from mutually exclusive options. This is a READONLY data component.",
|
|
9102
9777
|
"examples": [
|
|
9103
9778
|
{
|
|
9104
|
-
"title": "
|
|
9105
|
-
"code": "<nys-radiogroup label=\"Select borough\"
|
|
9779
|
+
"title": "Pre-selected",
|
|
9780
|
+
"code": "<nys-radiogroup label=\"Select borough\">\n<nys-radiobutton name=\"borough\" value=\"bronx\" label=\"The Bronx\" checked></nys-radiobutton>\n<nys-radiobutton name=\"borough\" value=\"brooklyn\" label=\"Brooklyn\"></nys-radiobutton>\n</nys-radiogroup>",
|
|
9106
9781
|
"lang": "html"
|
|
9107
9782
|
}
|
|
9108
9783
|
]
|
|
@@ -9734,9 +10409,54 @@
|
|
|
9734
10409
|
"summary": "Container for grouping radio buttons as a single form control.",
|
|
9735
10410
|
"examples": [
|
|
9736
10411
|
{
|
|
9737
|
-
"title": "Basic
|
|
10412
|
+
"title": "Basic",
|
|
9738
10413
|
"code": "<nys-radiogroup label=\"Select borough\" required>\n<nys-radiobutton name=\"borough\" value=\"bronx\" label=\"The Bronx\"></nys-radiobutton>\n<nys-radiobutton name=\"borough\" value=\"brooklyn\" label=\"Brooklyn\"></nys-radiobutton>\n<nys-radiobutton name=\"borough\" value=\"manhattan\" label=\"Manhattan\"></nys-radiobutton>\n</nys-radiogroup>",
|
|
9739
10414
|
"lang": "html"
|
|
10415
|
+
},
|
|
10416
|
+
{
|
|
10417
|
+
"title": "Tile",
|
|
10418
|
+
"code": "<nys-radiogroup label=\"Select borough\" tile>\n<nys-radiobutton name=\"borough\" value=\"bronx\" label=\"The Bronx\"></nys-radiobutton>\n<nys-radiobutton name=\"borough\" value=\"brooklyn\" label=\"Brooklyn\"></nys-radiobutton>\n</nys-radiogroup>",
|
|
10419
|
+
"lang": "html"
|
|
10420
|
+
},
|
|
10421
|
+
{
|
|
10422
|
+
"title": "Required",
|
|
10423
|
+
"code": "<nys-radiogroup label=\"Select borough\" required>\n<nys-radiobutton name=\"borough\" value=\"bronx\" label=\"The Bronx\"></nys-radiobutton>\n<nys-radiobutton name=\"borough\" value=\"brooklyn\" label=\"Brooklyn\"></nys-radiobutton>\n</nys-radiogroup>",
|
|
10424
|
+
"lang": "html"
|
|
10425
|
+
},
|
|
10426
|
+
{
|
|
10427
|
+
"title": "Optional",
|
|
10428
|
+
"code": "<nys-radiogroup label=\"Select borough\" optional>\n<nys-radiobutton name=\"borough\" value=\"bronx\" label=\"The Bronx\"></nys-radiobutton>\n<nys-radiobutton name=\"borough\" value=\"brooklyn\" label=\"Brooklyn\"></nys-radiobutton>\n</nys-radiogroup>",
|
|
10429
|
+
"lang": "html"
|
|
10430
|
+
},
|
|
10431
|
+
{
|
|
10432
|
+
"title": "Disabled",
|
|
10433
|
+
"code": "<nys-radiogroup label=\"Select borough\">\n<nys-radiobutton name=\"borough\" value=\"bronx\" label=\"The Bronx\" disabled></nys-radiobutton>\n<nys-radiobutton name=\"borough\" value=\"brooklyn\" label=\"Brooklyn\" disabled></nys-radiobutton>\n</nys-radiogroup>",
|
|
10434
|
+
"lang": "html"
|
|
10435
|
+
},
|
|
10436
|
+
{
|
|
10437
|
+
"title": "Size Small",
|
|
10438
|
+
"code": "<nys-radiogroup label=\"Select borough\" size=\"sm\">\n<nys-radiobutton name=\"borough\" value=\"bronx\" label=\"The Bronx\"></nys-radiobutton>\n<nys-radiobutton name=\"borough\" value=\"brooklyn\" label=\"Brooklyn\"></nys-radiobutton>\n</nys-radiogroup>",
|
|
10439
|
+
"lang": "html"
|
|
10440
|
+
},
|
|
10441
|
+
{
|
|
10442
|
+
"title": "Other Option",
|
|
10443
|
+
"code": "<nys-radiogroup label=\"Select borough\">\n<nys-radiobutton name=\"borough\" value=\"bronx\" label=\"The Bronx\"></nys-radiobutton>\n<nys-radiobutton name=\"borough\" value=\"\" label=\"Other\" other></nys-radiobutton>\n</nys-radiogroup>",
|
|
10444
|
+
"lang": "html"
|
|
10445
|
+
},
|
|
10446
|
+
{
|
|
10447
|
+
"title": "Error Message",
|
|
10448
|
+
"code": "<nys-radiogroup label=\"Select borough\" showError errorMessage=\"Please select a borough\">\n<nys-radiobutton name=\"borough\" value=\"bronx\" label=\"The Bronx\"></nys-radiobutton>\n<nys-radiobutton name=\"borough\" value=\"brooklyn\" label=\"Brooklyn\"></nys-radiobutton>\n</nys-radiogroup>",
|
|
10449
|
+
"lang": "html"
|
|
10450
|
+
},
|
|
10451
|
+
{
|
|
10452
|
+
"title": "Description",
|
|
10453
|
+
"code": "<nys-radiogroup label=\"Select borough\" description=\"Your primary residence in NYC.\">\n<nys-radiobutton name=\"borough\" value=\"bronx\" label=\"The Bronx\"></nys-radiobutton>\n<nys-radiobutton name=\"borough\" value=\"brooklyn\" label=\"Brooklyn\"></nys-radiobutton>\n</nys-radiogroup>",
|
|
10454
|
+
"lang": "html"
|
|
10455
|
+
},
|
|
10456
|
+
{
|
|
10457
|
+
"title": "Description Slot",
|
|
10458
|
+
"code": "<nys-radiogroup label=\"Select borough\">\n<div slot=\"description\">Your primary <strong>residence</strong> in NYC.</div>\n<nys-radiobutton name=\"borough\" value=\"bronx\" label=\"The Bronx\"></nys-radiobutton>\n<nys-radiobutton name=\"borough\" value=\"brooklyn\" label=\"Brooklyn\"></nys-radiobutton>\n</nys-radiogroup>",
|
|
10459
|
+
"lang": "html"
|
|
9740
10460
|
}
|
|
9741
10461
|
]
|
|
9742
10462
|
}
|
|
@@ -9910,14 +10630,7 @@
|
|
|
9910
10630
|
},
|
|
9911
10631
|
"tagName": "nys-option",
|
|
9912
10632
|
"customElement": true,
|
|
9913
|
-
"summary": "Option item for nys-select dropdown."
|
|
9914
|
-
"examples": [
|
|
9915
|
-
{
|
|
9916
|
-
"title": "Basic options",
|
|
9917
|
-
"code": "<nys-select>\n<nys-option value=\"ny\">New York</nys-option>\n<nys-option value=\"ca\" disabled>California</nys-option>\n</nys-select>",
|
|
9918
|
-
"lang": "html"
|
|
9919
|
-
}
|
|
9920
|
-
]
|
|
10633
|
+
"summary": "Option item for nys-select dropdown."
|
|
9921
10634
|
}
|
|
9922
10635
|
],
|
|
9923
10636
|
"exports": [
|
|
@@ -10414,14 +11127,63 @@
|
|
|
10414
11127
|
"summary": "Dropdown select for choosing one option from a list.",
|
|
10415
11128
|
"examples": [
|
|
10416
11129
|
{
|
|
10417
|
-
"title": "Basic
|
|
10418
|
-
"code": "<nys-select label=\"Select borough\">\n<option value=\"bronx\"
|
|
11130
|
+
"title": "Basic",
|
|
11131
|
+
"code": "<nys-select label=\"Select your favorite borough\" id=\"borough\">\n<option value=\"bronx\" label=\"The Bronx\"></option>\n<option value=\"brooklyn\" label=\"Brooklyn\"></option>\n<option value=\"manhattan\" label=\"Manhattan\"></option>\n<option value=\"staten_island\" label=\"Staten Island\"></option>\n<option value=\"queens\" label=\"Queens\"></option>\n</nys-select>",
|
|
11132
|
+
"lang": "html"
|
|
11133
|
+
},
|
|
11134
|
+
{
|
|
11135
|
+
"title": "Default value",
|
|
11136
|
+
"code": "<nys-select label=\"Select your favorite borough\" id=\"borough\">\n<option value=\"bronx\" label=\"The Bronx\"></option>\n<option value=\"brooklyn\" label=\"Brooklyn\" selected></option>\n<option value=\"manhattan\" label=\"Manhattan\"></option>\n<option value=\"staten_island\" label=\"Staten Island\"></option>\n<option value=\"queens\" label=\"Queens\"></option>\n</nys-select>",
|
|
11137
|
+
"lang": "html"
|
|
11138
|
+
},
|
|
11139
|
+
{
|
|
11140
|
+
"title": "Option Group",
|
|
11141
|
+
"code": "<nys-select\nlabel=\"Which New York State service are you contacting us about?\"\ndescription=\"This is for demo purposes and the list might not be exhaustive.\"\n>\n<optgroup label=\"Transportation Services\">\n<option value=\"mta\">MTA / Public Transit</option>\n<option value=\"dmv\">Department of Motor Vehicles (DMV)</option>\n<option value=\"highway\">Highway Maintenance</option>\n</optgroup>\n<optgroup label=\"Health & Human Services\">\n<option value=\"medicaid\">Medicaid / Health Insurance</option>\n<option value=\"mental-health\">Mental Health Support</option>\n<option value=\"child-family\">Child and Family Services</option>\n</optgroup>\n<optgroup label=\"Public Safety\">\n<option value=\"state-police\">State Police</option>\n<option value=\"emergency-management\">Emergency Management</option>\n<option value=\"fire-safety\">Fire Safety</option>\n</optgroup>\n<optgroup label=\"Environment & Energy\">\n<option value=\"environmental-conservation\">\nEnvironmental Conservation\n</option>\n<option value=\"clean-energy\">Clean Energy Programs</option>\n<option value=\"waste-management\">Waste Management</option>\n</optgroup>\n</nys-select>",
|
|
11142
|
+
"lang": "html"
|
|
11143
|
+
},
|
|
11144
|
+
{
|
|
11145
|
+
"title": "Disabled",
|
|
11146
|
+
"code": "<nys-select label=\"Select your favorite borough\" id=\"borough\" disabled>\n<option value=\"bronx\" label=\"The Bronx\"></option>\n<option value=\"brooklyn\" label=\"Brooklyn\"></option>\n<option value=\"manhattan\" label=\"Manhattan\"></option>\n<option value=\"staten_island\" label=\"Staten Island\"></option>\n<option value=\"queens\" label=\"Queens\"></option>\n</nys-select>",
|
|
11147
|
+
"lang": "html"
|
|
11148
|
+
},
|
|
11149
|
+
{
|
|
11150
|
+
"title": "Disabled Option",
|
|
11151
|
+
"code": "<nys-select label=\"Select your favorite borough\" id=\"borough\">\n<option value=\"bronx\" label=\"The Bronx\"></option>\n<option value=\"brooklyn\" label=\"Brooklyn\"></option>\n<option value=\"manhattan\" label=\"Manhattan\"></option>\n<option value=\"staten_island\" label=\"Staten Island\" disabled></option>\n<option value=\"queens\" label=\"Queens\" disabled></option>\n</nys-select>",
|
|
11152
|
+
"lang": "html"
|
|
11153
|
+
},
|
|
11154
|
+
{
|
|
11155
|
+
"title": "Required",
|
|
11156
|
+
"code": "<nys-select label=\"Select your favorite borough\" id=\"borough\" required>\n<option value=\"bronx\" label=\"The Bronx\"></option>\n<option value=\"brooklyn\" label=\"Brooklyn\"></option>\n<option value=\"manhattan\" label=\"Manhattan\"></option>\n<option value=\"staten_island\" label=\"Staten Island\"></option>\n<option value=\"queens\" label=\"Queens\"></option>\n</nys-select>",
|
|
11157
|
+
"lang": "html"
|
|
11158
|
+
},
|
|
11159
|
+
{
|
|
11160
|
+
"title": "Optional",
|
|
11161
|
+
"code": "<nys-select label=\"Select your favorite borough\" id=\"borough\" optional>\n<option value=\"bronx\" label=\"The Bronx\"></option>\n<option value=\"brooklyn\" label=\"Brooklyn\"></option>\n<option value=\"manhattan\" label=\"Manhattan\"></option>\n<option value=\"staten_island\" label=\"Staten Island\"></option>\n<option value=\"queens\" label=\"Queens\"></option>\n</nys-select>",
|
|
11162
|
+
"lang": "html"
|
|
11163
|
+
},
|
|
11164
|
+
{
|
|
11165
|
+
"title": "Width small",
|
|
11166
|
+
"code": "<nys-select label=\"Select your favorite borough\" id=\"borough\" width=\"sm\">\n<option value=\"bronx\" label=\"The Bronx\"></option>\n<option value=\"brooklyn\" label=\"Brooklyn\"></option>\n<option value=\"manhattan\" label=\"Manhattan\"></option>\n<option value=\"staten_island\" label=\"Staten Island\"></option>\n<option value=\"queens\" label=\"Queens\"></option>\n</nys-select>",
|
|
11167
|
+
"lang": "html"
|
|
11168
|
+
},
|
|
11169
|
+
{
|
|
11170
|
+
"title": "Width medium",
|
|
11171
|
+
"code": "<nys-select label=\"Select your favorite borough\" id=\"borough\" width=\"md\">\n<option value=\"bronx\" label=\"The Bronx\"></option>\n<option value=\"brooklyn\" label=\"Brooklyn\"></option>\n<option value=\"manhattan\" label=\"Manhattan\"></option>\n<option value=\"staten_island\" label=\"Staten Island\"></option>\n<option value=\"queens\" label=\"Queens\"></option>\n</nys-select>",
|
|
11172
|
+
"lang": "html"
|
|
11173
|
+
},
|
|
11174
|
+
{
|
|
11175
|
+
"title": "Width large",
|
|
11176
|
+
"code": "<nys-select label=\"Select your favorite borough\" id=\"borough\" width=\"lg\">\n<option value=\"bronx\" label=\"The Bronx\"></option>\n<option value=\"brooklyn\" label=\"Brooklyn\"></option>\n<option value=\"manhattan\" label=\"Manhattan\"></option>\n<option value=\"staten_island\" label=\"Staten Island\"></option>\n<option value=\"queens\" label=\"Queens\"></option>\n</nys-select>",
|
|
10419
11177
|
"lang": "html"
|
|
10420
11178
|
},
|
|
10421
11179
|
{
|
|
10422
|
-
"title": "
|
|
10423
|
-
"code": "<nys-select label=\"Select
|
|
11180
|
+
"title": "Slotted Description",
|
|
11181
|
+
"code": "<nys-select label=\"Select your favorite borough\" id=\"borough\">\n<label slot=\"description\">This is a slotted description</label>\n<option value=\"bronx\" label=\"The Bronx\"></option>\n<option value=\"brooklyn\" label=\"Brooklyn\"></option>\n<option value=\"manhattan\" label=\"Manhattan\"></option>\n<option value=\"staten_island\" label=\"Staten Island\"></option>\n<option value=\"queens\" label=\"Queens\"></option>\n</nys-select>",
|
|
10424
11182
|
"lang": "html"
|
|
11183
|
+
},
|
|
11184
|
+
{
|
|
11185
|
+
"title": "Error Message",
|
|
11186
|
+
"code": "<nys-select label=\"Select your favorite borough\" id=\"borough\" errorMessage=\"You did not select a borough\" showError>\n<option value=\"bronx\" label=\"The Bronx\"></option>\n<option value=\"brooklyn\" label=\"Brooklyn\"></option>\n<option value=\"manhattan\" label=\"Manhattan\"></option>\n<option value=\"staten_island\" label=\"Staten Island\"></option>\n<option value=\"queens\" label=\"Queens\"></option>\n</nys-select>"
|
|
10425
11187
|
}
|
|
10426
11188
|
]
|
|
10427
11189
|
}
|
|
@@ -10538,13 +11300,13 @@
|
|
|
10538
11300
|
"summary": "Skip navigation link for keyboard accessibility. Hidden until focused.",
|
|
10539
11301
|
"examples": [
|
|
10540
11302
|
{
|
|
10541
|
-
"title": "
|
|
10542
|
-
"code": "<nys-skipnav></nys-skipnav
|
|
11303
|
+
"title": "Basic",
|
|
11304
|
+
"code": "<nys-skipnav></nys-skipnav>",
|
|
10543
11305
|
"lang": "html"
|
|
10544
11306
|
},
|
|
10545
11307
|
{
|
|
10546
11308
|
"title": "Custom target",
|
|
10547
|
-
"code": "<nys-skipnav href=\"#content-area\"></nys-skipnav>",
|
|
11309
|
+
"code": "<nys-skipnav href=\"#content-area\"></nys-skipnav>\n<p id=\"content-area\">...</p>",
|
|
10548
11310
|
"lang": "html"
|
|
10549
11311
|
}
|
|
10550
11312
|
]
|
|
@@ -10732,19 +11494,7 @@
|
|
|
10732
11494
|
},
|
|
10733
11495
|
"tagName": "nys-step",
|
|
10734
11496
|
"customElement": true,
|
|
10735
|
-
"summary": "Individual step for use within nys-stepper with navigation support."
|
|
10736
|
-
"examples": [
|
|
10737
|
-
{
|
|
10738
|
-
"title": "Step with page navigation",
|
|
10739
|
-
"code": "<nys-step label=\"Personal Info\" href=\"/step-1\"></nys-step>",
|
|
10740
|
-
"lang": "html"
|
|
10741
|
-
},
|
|
10742
|
-
{
|
|
10743
|
-
"title": "Step with SPA navigation (no href)",
|
|
10744
|
-
"code": "step.addEventListener('nys-step-click', (e) => {\ne.preventDefault(); // no href set, but good practice\nshowStepContent(e.detail.label);\n});",
|
|
10745
|
-
"lang": "js"
|
|
10746
|
-
}
|
|
10747
|
-
]
|
|
11497
|
+
"summary": "Individual step for use within nys-stepper with navigation support."
|
|
10748
11498
|
}
|
|
10749
11499
|
],
|
|
10750
11500
|
"exports": [
|
|
@@ -10955,24 +11705,16 @@
|
|
|
10955
11705
|
"summary": "Multi-step progress indicator with navigation and mobile-friendly compact view.",
|
|
10956
11706
|
"examples": [
|
|
10957
11707
|
{
|
|
10958
|
-
"title": "Basic
|
|
10959
|
-
"code": "<nys-stepper label=\"
|
|
10960
|
-
"lang": "html"
|
|
10961
|
-
|
|
10962
|
-
{
|
|
10963
|
-
"title": "Grid layout with sidebar placement",
|
|
10964
|
-
"code": "<div class=\"nys-grid-container\">\n<div class=\"nys-grid-row\">\n<nys-stepper label=\"Application\" class=\"nys-grid-col-12 nys-desktop:nys-grid-col-3\">\n<nys-step label=\"Personal Info\"></nys-step>\n<nys-step label=\"Contact\" current></nys-step>\n<nys-step label=\"Review\"></nys-step>\n</nys-stepper>\n<main class=\"nys-grid-col-12 nys-desktop:nys-grid-col-9\" id=\"main-content\">\n<!-- Form content for current step -->\n<nys-textinput label=\"Email\" required></nys-textinput>\n<nys-textinput label=\"Phone\"></nys-textinput>\n</main>\n</div>\n</div>",
|
|
10965
|
-
"lang": "html"
|
|
10966
|
-
},
|
|
10967
|
-
{
|
|
10968
|
-
"title": "Navigation buttons in actions slot",
|
|
10969
|
-
"code": "<nys-stepper label=\"Application\">\n<nys-step label=\"Step 1\"></nys-step>\n<nys-step label=\"Step 2\" current></nys-step>\n<nys-step label=\"Step 3\"></nys-step>\n<div slot=\"actions\">\n<nys-button label=\"Save and Exit\" variant=\"outline\" size=\"sm\" fullWidth></nys-button>\n</div>\n</nys-stepper>",
|
|
10970
|
-
"lang": "html"
|
|
11708
|
+
"title": "Basic",
|
|
11709
|
+
"code": "<div class=\"nys-grid-row\">\n<nys-stepper\nid=\"stepper\"\nname=\"stepper\"\nlabel=\"Register for Design System Office Hours\"\nclass=\"nys-desktop:nys-grid-col-3\"\n>\n<nys-step label=\"Personal Details\" href=\"/nys-stepper/personal.html\"></nys-step>\n<nys-step label=\"Team Info\" selected href=\"/nys-stepper/team.html\"></nys-step>\n<nys-step label=\"Usage Survey\" current href=\"/nys-stepper/survey.html\"></nys-step>\n<nys-step label=\"Newsletter Opt-In\" href=\"/nys-stepper/newsletter.html\"></nys-step>\n<div slot=\"actions\">\n<nys-button variant=\"outline\" label=\"Save & Exit\" fullWidth></nys-button>\n</div>\n</nys-stepper>\n<div class=\"nys-desktop:nys-grid-col-9\" id=\"nys-stepper-content\">\nLoading...\n</div>\n</div>",
|
|
11710
|
+
"lang": "html",
|
|
11711
|
+
"render": "<div class=\"nys-grid-row\">\n<nys-stepper\nid=\"stepper\"\nname=\"stepper\"\nlabel=\"Register for Design System Office Hours\"\nclass=\"nys-desktop:nys-grid-col-3\"\n>\n<nys-step label=\"Personal Details\" href=\"/nys-stepper/personal.html\"></nys-step>\n<nys-step label=\"Team Info\" selected href=\"/nys-stepper/team.html\"></nys-step>\n<nys-step label=\"Usage Survey\" current href=\"/nys-stepper/survey.html\"></nys-step>\n<nys-step label=\"Newsletter Opt-In\" href=\"/nys-stepper/newsletter.html\"></nys-step>\n</nys-stepper>\n<div class=\"nys-desktop:nys-grid-col-9\" id=\"nys-stepper-content\">\nLoading...\n</div>\n</div>\n<script>\ndocument.addEventListener(\"DOMContentLoaded\", async () => {\nconst stepper = document.querySelector(\"nys-stepper\");\nif (stepper?.updateComplete) await stepper.updateComplete;\nconst selectedStep = document.querySelector(\"nys-step[selected]\");\nconst href = selectedStep?.getAttribute(\"href\");\nif (!href) return;\nconst res = await fetch(href);\nif (!res.ok) return;\nconst container = document.querySelector(\"#nys-stepper-content\");\nif (container) container.innerHTML = await res.text();\n});\n\ndocument.addEventListener(\"nys-step-click\", async (e) => {\nconst href = e.detail?.href;\nif (!href) return;\ne.preventDefault();\nconst res = await fetch(href);\nif (!res.ok) return;\nconst container = document.querySelector(\"#nys-stepper-content\");\nif (container) container.innerHTML = await res.text();\n});\n</script>"
|
|
10971
11712
|
},
|
|
10972
11713
|
{
|
|
10973
|
-
"title": "
|
|
10974
|
-
"code": "
|
|
10975
|
-
"lang": "
|
|
11714
|
+
"title": "Actions slot",
|
|
11715
|
+
"code": "<div class=\"nys-grid-row\">\n<nys-stepper\nid=\"stepper\"\nname=\"stepper\"\nlabel=\"Register for Design System Office Hours\"\nclass=\"nys-desktop:nys-grid-col-3\"\n>\n<nys-step label=\"Personal Details\" href=\"/nys-stepper/personal.html\"></nys-step>\n<nys-step label=\"Team Info\" selected href=\"/nys-stepper/team.html\"></nys-step>\n<nys-step label=\"Usage Survey\" current href=\"/nys-stepper/survey.html\"></nys-step>\n<nys-step label=\"Newsletter Opt-In\" href=\"/nys-stepper/newsletter.html\"></nys-step>\n<div slot=\"actions\">\n<nys-button variant=\"outline\" label=\"Save & Exit\" fullWidth></nys-button>\n</div>\n</nys-stepper>\n<div class=\"nys-desktop:nys-grid-col-9\" id=\"nys-stepper-content\">\nLoading...\n</div>\n</div>",
|
|
11716
|
+
"lang": "html",
|
|
11717
|
+
"render": "<div class=\"nys-grid-row\">\n<nys-stepper\nid=\"stepper\"\nname=\"stepper\"\nlabel=\"Register for Design System Office Hours\"\nclass=\"nys-desktop:nys-grid-col-3\"\n>\n<nys-step label=\"Personal Details\" href=\"/nys-stepper/personal.html\"></nys-step>\n<nys-step label=\"Team Info\" selected href=\"/nys-stepper/team.html\"></nys-step>\n<nys-step label=\"Usage Survey\" current href=\"/nys-stepper/survey.html\"></nys-step>\n<nys-step label=\"Newsletter Opt-In\" href=\"/nys-stepper/newsletter.html\"></nys-step>\n<div slot=\"actions\">\n<nys-button variant=\"outline\" label=\"Save & Exit\" fullWidth></nys-button>\n</div>\n</nys-stepper>\n<div class=\"nys-desktop:nys-grid-col-9\" id=\"nys-stepper-content\">\nLoading...\n</div>\n</div>\n<script>\ndocument.addEventListener(\"DOMContentLoaded\", async () => {\nconst stepper = document.querySelector(\"nys-stepper\");\nif (stepper?.updateComplete) await stepper.updateComplete;\nconst selectedStep = document.querySelector(\"nys-step[selected]\");\nconst href = selectedStep?.getAttribute(\"href\");\nif (!href) return;\nconst res = await fetch(href);\nif (!res.ok) return;\nconst container = document.querySelector(\"#nys-stepper-content\");\nif (container) container.innerHTML = await res.text();\n});\n\ndocument.addEventListener(\"nys-step-click\", async (e) => {\nconst href = e.detail?.href;\nif (!href) return;\ne.preventDefault();\nconst res = await fetch(href);\nif (!res.ok) return;\nconst container = document.querySelector(\"#nys-stepper-content\");\nif (container) container.innerHTML = await res.text();\n});\n</script>"
|
|
10976
11718
|
}
|
|
10977
11719
|
]
|
|
10978
11720
|
}
|
|
@@ -11212,8 +11954,13 @@
|
|
|
11212
11954
|
"customElement": true,
|
|
11213
11955
|
"examples": [
|
|
11214
11956
|
{
|
|
11215
|
-
"title": "
|
|
11216
|
-
"code": "
|
|
11957
|
+
"title": "Disabled",
|
|
11958
|
+
"code": "<nys-tabgroup name=\"Account Settings\">\n<nys-tab label=\"Profile\"></nys-tab>\n<nys-tab label=\"Security\"></nys-tab>\n<nys-tab label=\"Notifications\" disabled></nys-tab>\n<nys-tabpanel><p>Manage your profile information.</p></nys-tabpanel>\n<nys-tabpanel><p>Update your password and 2FA settings.</p></nys-tabpanel>\n<nys-tabpanel><p>Notification preferences (coming soon).</p></nys-tabpanel>\n</nys-tabgroup>",
|
|
11959
|
+
"lang": "html"
|
|
11960
|
+
},
|
|
11961
|
+
{
|
|
11962
|
+
"title": "Preselected",
|
|
11963
|
+
"code": "<nys-tabgroup name=\"Reports\">\n<nys-tab label=\"Summary\"></nys-tab>\n<nys-tab label=\"Details\" selected></nys-tab>\n<nys-tabpanel><p>Summary view</p></nys-tabpanel>\n<nys-tabpanel><p>Detailed view (shown by default)</p></nys-tabpanel>\n</nys-tabgroup>",
|
|
11217
11964
|
"lang": "html"
|
|
11218
11965
|
}
|
|
11219
11966
|
]
|
|
@@ -11244,11 +11991,11 @@
|
|
|
11244
11991
|
"declarations": [
|
|
11245
11992
|
{
|
|
11246
11993
|
"kind": "class",
|
|
11247
|
-
"description": "`<nys-tabgroup>` is the container for `<nys-tab>` and `<nys-tabpanel>`\nelements.\n\nAccepts tabs and panels as flat light-DOM children in any order (interleaved\nor grouped). On slot change,
|
|
11994
|
+
"description": "`<nys-tabgroup>` is the container for `<nys-tab>` and `<nys-tabpanel>`\nelements.\n\nAccepts tabs and panels as flat light-DOM children in any order (interleaved\nor grouped). On slot change, each child is assigned `slot=\"tab\"` or\n`slot=\"panel\"` so it is projected into the correct shadow-DOM container\nwhile remaining in the light DOM, ARIA relationships are wired, and the\nfirst selected (or first) tab is activated.\n\nScroll shadows are rendered on either side of the tab list and toggled via\n`ResizeObserver` and a `scroll` listener so they accurately reflect whether\noverflow content exists in each direction.\n\nKeyboard navigation follows the\nhttps://www.w3.org/WAI/ARIA/apg/patterns/tabs/ ARIA Tabs Pattern:\n- Arrow keys move focus without changing selection.\n- Enter / Space confirm selection on the focused tab.",
|
|
11248
11995
|
"name": "NysTabgroup",
|
|
11249
11996
|
"slots": [
|
|
11250
11997
|
{
|
|
11251
|
-
"description": "Accepts `<nys-tab>` and `<nys-tabpanel>` children.
|
|
11998
|
+
"description": "Accepts `<nys-tab>` and `<nys-tabpanel>` children. On `slotchange` they are assigned `slot=\"tab\"` / `slot=\"panel\"` and projected into the tablist and panel containers; they stay in the light DOM. Any other children remain in the default slot, rendered below the panels.",
|
|
11252
11999
|
"name": ""
|
|
11253
12000
|
}
|
|
11254
12001
|
],
|
|
@@ -11330,7 +12077,7 @@
|
|
|
11330
12077
|
"text": ""
|
|
11331
12078
|
}
|
|
11332
12079
|
},
|
|
11333
|
-
"description": "Returns all `<nys-tab>`
|
|
12080
|
+
"description": "Returns all `<nys-tab>` light-DOM children in DOM order.\n\nTabs are projected into the shadow-DOM tablist via the `tab` slot but\nremain light-DOM children of the group, so they stay reachable by consumer\nCSS and JavaScript."
|
|
11334
12081
|
},
|
|
11335
12082
|
{
|
|
11336
12083
|
"kind": "method",
|
|
@@ -11341,7 +12088,34 @@
|
|
|
11341
12088
|
"text": ""
|
|
11342
12089
|
}
|
|
11343
12090
|
},
|
|
11344
|
-
"description": "Returns
|
|
12091
|
+
"description": "Returns the `<nys-tabpanel>` light-DOM children ordered to align with\n`_getTabs()` — i.e. `panels[i]` is the panel paired with `tabs[i]`.\n\nPairing honors explicit `aria-labelledby` references first, then falls\nback to source order for the remaining panels. See _pairPanels."
|
|
12092
|
+
},
|
|
12093
|
+
{
|
|
12094
|
+
"kind": "method",
|
|
12095
|
+
"name": "_pairPanels",
|
|
12096
|
+
"privacy": "private",
|
|
12097
|
+
"return": {
|
|
12098
|
+
"type": {
|
|
12099
|
+
"text": ""
|
|
12100
|
+
}
|
|
12101
|
+
},
|
|
12102
|
+
"parameters": [
|
|
12103
|
+
{
|
|
12104
|
+
"name": "tabs",
|
|
12105
|
+
"type": {
|
|
12106
|
+
"text": "HTMLElement[]"
|
|
12107
|
+
},
|
|
12108
|
+
"description": "Ordered `<nys-tab>` elements."
|
|
12109
|
+
},
|
|
12110
|
+
{
|
|
12111
|
+
"name": "panels",
|
|
12112
|
+
"type": {
|
|
12113
|
+
"text": "HTMLElement[]"
|
|
12114
|
+
},
|
|
12115
|
+
"description": "`<nys-tabpanel>` elements in source order."
|
|
12116
|
+
}
|
|
12117
|
+
],
|
|
12118
|
+
"description": "Orders `panels` to align 1:1 with `tabs`.\n\nA panel is paired with a tab when its `aria-labelledby` matches that tab's\n`id`; explicit references win over position. Panels without a reference\nfill the remaining tab slots in source order. Any panels whose reference\ndoes not resolve to a tab are appended at the end.\n\nIdempotent: after `_applySelection` writes `aria-labelledby` onto every\npanel, re-running this yields the same order."
|
|
11345
12119
|
},
|
|
11346
12120
|
{
|
|
11347
12121
|
"kind": "method",
|
|
@@ -11378,24 +12152,15 @@
|
|
|
11378
12152
|
"description": "Single source of truth for ARIA wiring, `tabindex`, and panel visibility.\n\nFor each index `i`:\n- Sets `selected` / removes `selected` attribute on `tabs[i]`.\n- Sets `aria-controls` on `tabs[i]` to the `id` of `panels[i]`.\n- Sets `aria-labelledby` on `panels[i]` to the `id` of `tabs[i]`.\n- Removes `hidden` from `panels[selectedIndex]`; adds it to all others.\n\nMust be called any time the selected tab changes (initial render and\nsubsequent user interactions)."
|
|
11379
12153
|
},
|
|
11380
12154
|
{
|
|
11381
|
-
"kind": "
|
|
11382
|
-
"name": "
|
|
12155
|
+
"kind": "field",
|
|
12156
|
+
"name": "_syncChildren",
|
|
11383
12157
|
"privacy": "private",
|
|
12158
|
+
"description": "Handles `slotchange` and keeps the tabs/panels wired without ever removing\nthem from the light DOM.\n\nConsumers author `<nys-tab>` / `<nys-tabpanel>` as flat children with no\n`slot` attribute. This assigns `slot=\"tab\"` / `slot=\"panel\"` so each is\nprojected into the correct shadow-DOM container while remaining a\nlight-DOM child of the group (reachable by consumer CSS/JS). Any other\nchildren (e.g. a footnote `<p>`) are left untouched in the default slot.\n\nReads all current light-DOM children on every call (rather than a single\nslot's assigned nodes), so it is robust to dynamic additions/removals and\nidempotent: setting the `slot` attributes triggers further `slotchange`\nevents, but once the attributes are stable no more mutations occur and the\ncascade settles.\n\nAfter (re)assignment, `_applySelection` is called honoring the first tab\nthat already has a `selected` attribute, or index `0` if none is found.",
|
|
11384
12159
|
"return": {
|
|
11385
12160
|
"type": {
|
|
11386
12161
|
"text": ""
|
|
11387
12162
|
}
|
|
11388
|
-
}
|
|
11389
|
-
"parameters": [
|
|
11390
|
-
{
|
|
11391
|
-
"name": "e",
|
|
11392
|
-
"type": {
|
|
11393
|
-
"text": "Event"
|
|
11394
|
-
},
|
|
11395
|
-
"description": "The `Event` fired by the `<slot>` element on slot change."
|
|
11396
|
-
}
|
|
11397
|
-
],
|
|
11398
|
-
"description": "Handles `slotchange` on the default slot.\n\nIterates over all assigned elements and moves each `<nys-tab>` into\n`.nys-tabgroup__tabs` and each `<nys-tabpanel>` into\n`.nys-tabgroup__panels`. If a panel has an `aria-labelledby` attribute,\nit is explicitly paired with the tab it references; otherwise panels are\npaired with tabs by index order. After sorting, calls `_applySelection`\nusing the first element that already has a `selected` attribute, or\nindex `0` if none is found."
|
|
12163
|
+
}
|
|
11399
12164
|
},
|
|
11400
12165
|
{
|
|
11401
12166
|
"kind": "method",
|
|
@@ -11475,13 +12240,24 @@
|
|
|
11475
12240
|
"customElement": true,
|
|
11476
12241
|
"examples": [
|
|
11477
12242
|
{
|
|
11478
|
-
"title": "
|
|
11479
|
-
"code": "<nys-tabgroup
|
|
12243
|
+
"title": "Basic",
|
|
12244
|
+
"code": "<nys-tabgroup>\n<nys-tab label=\"Marcy\"></nys-tab>\n<nys-tab label=\"Algonquin\"></nys-tab>\n<nys-tab label=\"Haystack\"></nys-tab>\n// rest of tabs\n<nys-tabpanel\n>Mount Marcy is the tallest peak in the Adirondacks. It has an elevation\nof 5344 feet with 3166 feet of elevation gain. The roundtrip hike to the\ntop is 14.8 miles and is an out-and-back route.\n</nys-tabpanel>\n<nys-tabpanel\n>Algonquin Peak is the 2nd tallest peak in the Adirondacks. It has an\nelevation of 5114 feet with 3050 feet of elevation gain. The roundtrip\nhike to the top is 7.8 miles and is an out-and-back route.</nys-tabpanel\n>\n<nys-tabpanel\n>Mount Haystack is the 3rd tallest peak in the Adirondacks. It has an\nelevation of 4960 feet with 4000 feet of elevation gain. The roundtrip\nhike to the top is 16.4 miles and is an out-and-back\nroute.</nys-tabpanel\n>\n// rest of tab panel content\n</nys-tabgroup>",
|
|
12245
|
+
"lang": "html",
|
|
12246
|
+
"render": "<nys-tabgroup>\n<nys-tab label=\"Marcy\"></nys-tab>\n<nys-tab label=\"Algonquin\"></nys-tab>\n<nys-tab label=\"Haystack\"></nys-tab>\n<nys-tab label=\"Skylight\" id=\"tab4\"></nys-tab>\n<nys-tab label=\"Whiteface\" id=\"tab5\"></nys-tab>\n<nys-tabpanel\n>Mount Marcy is the tallest peak in the Adirondacks. It has an elevation\nof 5344 feet with 3166 feet of elevation gain. The roundtrip hike to the\ntop is 14.8 miles and is an out-and-back route.\n</nys-tabpanel>\n<nys-tabpanel\n>Algonquin Peak is the 2nd tallest peak in the Adirondacks. It has an\nelevation of 5114 feet with 3050 feet of elevation gain. The roundtrip\nhike to the top is 7.8 miles and is an out-and-back route.</nys-tabpanel\n>\n<nys-tabpanel\n>Mount Haystack is the 3rd tallest peak in the Adirondacks. It has an\nelevation of 4960 feet with 4000 feet of elevation gain. The roundtrip\nhike to the top is 16.4 miles and is an out-and-back\nroute.</nys-tabpanel\n>\n<nys-tabpanel\n>Mount Skylight is the 4th tallest peak in the Adirondacks. It has an\nelevation of 4926 feet with 5100 feet of elevation gain. The roundtrip\nhike to the top is 16 miles and is an out-and-back route.</nys-tabpanel\n>\n<nys-tabpanel\n>Whiteface is the 5th tallest peak in the Adirondacks. It has an\nelevation of 4867 feet with 3050 feet of elevation gain. The roundtrip\nhike to the top is 7.2 miles and is an out-and-back route.</nys-tabpanel\n>\n<p style=\"padding: 1rem;\">\n<strong>Note:</strong> The content in the tab panels was gathered from\n<a href=\"https://www.lakeplacid.com/do/outdoors/summerfall/hiking\"\n>lakeplacid.com</a\n>\nand may not be completely accurate. This is meant to be a demo of how\nthe component works, not a hiking guide.\n</p>\n</nys-tabgroup>"
|
|
12247
|
+
},
|
|
12248
|
+
{
|
|
12249
|
+
"title": "Explicit Ordering",
|
|
12250
|
+
"code": "<nys-tabgroup id=\"explicit-ordering\">\n<nys-tab label=\"1st Tab\" id=\"tab1\"></nys-tab>\n<nys-tab label=\"2nd Tab\" id=\"tab2\"></nys-tab>\n<nys-tab label=\"3rd Tab\" id=\"tab3\"></nys-tab>\n<nys-tabpanel aria-labelledby=\"tab2\">Content for tab 2</nys-tabpanel>\n<nys-tabpanel aria-labelledby=\"tab3\">Content for tab 3</nys-tabpanel>\n<nys-tabpanel aria-labelledby=\"tab1\">Content for tab 1</nys-tabpanel>\n</nys-tabgroup>",
|
|
11480
12251
|
"lang": "html"
|
|
11481
12252
|
},
|
|
11482
12253
|
{
|
|
11483
|
-
"title": "
|
|
11484
|
-
"code": "<nys-tabgroup
|
|
12254
|
+
"title": "JS in tabpanel",
|
|
12255
|
+
"code": "<nys-tabgroup>\n<nys-tab label=\"Tab 1\"></nys-tab>\n<nys-tab label=\"Tab 2\"></nys-tab>\n<nys-tabpanel>\n<p>Content for tab 1</p>\n</nys-tabpanel>\n<nys-tabpanel>\n<p>Content for tab 2</p>\n</nys-tabpanel>\n</nys-tabgroup>\n<script>\nconst tabgroup = document.querySelector(\"nys-tabgroup\");\nconst panels = tabgroup.querySelectorAll(\"nys-tabpanel\");\npanels[0].innerHTML += \"<p>Added via JS</p>\";\n</script>",
|
|
12256
|
+
"lang": "html"
|
|
12257
|
+
},
|
|
12258
|
+
{
|
|
12259
|
+
"title": "Custom Styling",
|
|
12260
|
+
"code": "<style>\nnys-tabpanel {\n--_nys-tabpanel-background-color: var(--nys-color-theme-faint);\nborder: solid 2px var(--nys-color-theme-strong);\n--nys-button-background-color: var(--nys-color-success);\n}\n</style>\n<nys-tabgroup>\n<nys-tab label=\"Tab 1\"></nys-tab>\n<nys-tab label=\"Tab 2\"></nys-tab>\n<nys-tabpanel>\n<p>Content for tab 1</p>\n<nys-button>Click me</nys-button>\n</nys-tabpanel>\n<nys-tabpanel>\n<p>Content for tab 2</p>\n</nys-tabpanel>\n</nys-tabgroup>",
|
|
11485
12261
|
"lang": "html"
|
|
11486
12262
|
}
|
|
11487
12263
|
]
|
|
@@ -11512,11 +12288,11 @@
|
|
|
11512
12288
|
"declarations": [
|
|
11513
12289
|
{
|
|
11514
12290
|
"kind": "class",
|
|
11515
|
-
"description": "`<nys-tabpanel>` is a content panel paired with a `<nys-tab>` inside a\n`<nys-tabgroup>`.\n\nPairing is determined by render order: the Nth `<nys-tabpanel>` child of a\n`<nys-tabgroup>` corresponds to the Nth `<nys-tab>` child
|
|
12291
|
+
"description": "`<nys-tabpanel>` is a content panel paired with a `<nys-tab>` inside a\n`<nys-tabgroup>`.\n\nPairing is determined by render order: the Nth `<nys-tabpanel>` child of a\n`<nys-tabgroup>` corresponds to the Nth `<nys-tab>` child (or by explicit\n`aria-labelledby`). `aria-labelledby` and the `hidden` attribute are managed\nexternally by `<nys-tabgroup>` via `_applySelection`; do not set them\ndirectly.\n\nThe panel container is styled from the light DOM (`nys-tabpanel.light.scss`,\nadopted on the document) rather than a shadow-DOM wrapper. This keeps the\nslotted panel content in the light DOM — reachable by consumer CSS and\nJavaScript — and lets consumers override the panel's own styling (e.g.\n`nys-tabpanel { padding: 0 }`), which a shadow wrapper would prevent.",
|
|
11516
12292
|
"name": "NysTabpanel",
|
|
11517
12293
|
"slots": [
|
|
11518
12294
|
{
|
|
11519
|
-
"description": "Default slot for panel content. Rendered
|
|
12295
|
+
"description": "Default slot for panel content. Rendered directly under the host, which is the scrollable, focusable (`tabindex=\"0\"`) `role=\"tabpanel\"` region.",
|
|
11520
12296
|
"name": ""
|
|
11521
12297
|
}
|
|
11522
12298
|
],
|
|
@@ -11551,14 +12327,7 @@
|
|
|
11551
12327
|
"package": "lit"
|
|
11552
12328
|
},
|
|
11553
12329
|
"tagName": "nys-tabpanel",
|
|
11554
|
-
"customElement": true
|
|
11555
|
-
"examples": [
|
|
11556
|
-
{
|
|
11557
|
-
"title": "Panel content is wrapped by `<nys-tabpanel>`.",
|
|
11558
|
-
"code": "<!-- Panels are paired by position with <nys-tab> elements in the same <nys-tabgroup>. -->\n<nys-tabgroup name=\"Steps\">\n<nys-tab label=\"Step 1\"></nys-tab>\n<nys-tab label=\"Step 2\"></nys-tab>\n<nys-tabpanel>\n<h2>Step 1: Enter your information</h2>\n<p>Fill out the form below.</p>\n</nys-tabpanel>\n<nys-tabpanel>\n<h2>Step 2: Review and submit</h2>\n<p>Confirm your details before submitting.</p>\n</nys-tabpanel>\n</nys-tabgroup>",
|
|
11559
|
-
"lang": "html"
|
|
11560
|
-
}
|
|
11561
|
-
]
|
|
12330
|
+
"customElement": true
|
|
11562
12331
|
}
|
|
11563
12332
|
],
|
|
11564
12333
|
"exports": [
|
|
@@ -11605,7 +12374,7 @@
|
|
|
11605
12374
|
"name": "NysTable",
|
|
11606
12375
|
"slots": [
|
|
11607
12376
|
{
|
|
11608
|
-
"description": "Accepts a `<table>` element. Only the first table is
|
|
12377
|
+
"description": "Accepts a `<table>` element. Only the first table is used. The table is enhanced in place and stays in the light DOM (projected through a slot, never cloned), so embedded components remain interactive and reachable by consumer CSS/JS. Its cell styling is applied from `nys-table.light.scss`, adopted once onto `document.adoptedStyleSheets`.",
|
|
11609
12378
|
"name": ""
|
|
11610
12379
|
}
|
|
11611
12380
|
],
|
|
@@ -11706,12 +12475,63 @@
|
|
|
11706
12475
|
"privacy": "private",
|
|
11707
12476
|
"default": "null"
|
|
11708
12477
|
},
|
|
12478
|
+
{
|
|
12479
|
+
"kind": "field",
|
|
12480
|
+
"name": "_enhancing",
|
|
12481
|
+
"type": {
|
|
12482
|
+
"text": "boolean"
|
|
12483
|
+
},
|
|
12484
|
+
"privacy": "private",
|
|
12485
|
+
"default": "false"
|
|
12486
|
+
},
|
|
11709
12487
|
{
|
|
11710
12488
|
"kind": "method",
|
|
11711
|
-
"name": "
|
|
12489
|
+
"name": "_getSlottedTable",
|
|
11712
12490
|
"privacy": "private",
|
|
12491
|
+
"return": {
|
|
12492
|
+
"type": {
|
|
12493
|
+
"text": "HTMLTableElement | undefined"
|
|
12494
|
+
}
|
|
12495
|
+
},
|
|
11713
12496
|
"description": "****************** Functions *******************"
|
|
11714
12497
|
},
|
|
12498
|
+
{
|
|
12499
|
+
"kind": "method",
|
|
12500
|
+
"name": "_observeTable",
|
|
12501
|
+
"privacy": "private",
|
|
12502
|
+
"parameters": [
|
|
12503
|
+
{
|
|
12504
|
+
"name": "table",
|
|
12505
|
+
"type": {
|
|
12506
|
+
"text": "HTMLTableElement"
|
|
12507
|
+
}
|
|
12508
|
+
}
|
|
12509
|
+
]
|
|
12510
|
+
},
|
|
12511
|
+
{
|
|
12512
|
+
"kind": "method",
|
|
12513
|
+
"name": "_withObserverPaused",
|
|
12514
|
+
"privacy": "private",
|
|
12515
|
+
"parameters": [
|
|
12516
|
+
{
|
|
12517
|
+
"name": "table",
|
|
12518
|
+
"type": {
|
|
12519
|
+
"text": "HTMLTableElement"
|
|
12520
|
+
}
|
|
12521
|
+
},
|
|
12522
|
+
{
|
|
12523
|
+
"name": "fn",
|
|
12524
|
+
"type": {
|
|
12525
|
+
"text": "() => void"
|
|
12526
|
+
}
|
|
12527
|
+
}
|
|
12528
|
+
]
|
|
12529
|
+
},
|
|
12530
|
+
{
|
|
12531
|
+
"kind": "method",
|
|
12532
|
+
"name": "_handleSlotChange",
|
|
12533
|
+
"privacy": "private"
|
|
12534
|
+
},
|
|
11715
12535
|
{
|
|
11716
12536
|
"kind": "method",
|
|
11717
12537
|
"name": "_setupMutationObserver",
|
|
@@ -11923,6 +12743,33 @@
|
|
|
11923
12743
|
"name": "LitElement",
|
|
11924
12744
|
"package": "lit"
|
|
11925
12745
|
},
|
|
12746
|
+
"examples": [
|
|
12747
|
+
{
|
|
12748
|
+
"title": "Basic",
|
|
12749
|
+
"code": "<nys-table id=\"table1\" name=\"table1\">\n<table>\n<caption>New York State High Peaks and Popular Hikes</caption>\n<tr><th>Mountain</th><th>Peak Height (ft)</th><th>Hike Name</th></tr>\n<tr><td>Marcy</td><td>5,344</td><td>Van Hoevenberg Trail</td></tr>\n<tr><td>Algonquin</td><td>5,114</td><td>Northeast Trail</td></tr>\n<tr><td>Haystack</td><td>4,960</td><td>Johns Brook Trail</td></tr>\n<tr><td>Skylight</td><td>4,926</td><td>Lake Tear Trail</td></tr>\n<tr><td>Whiteface</td><td>4,867</td><td>Whiteface Mountain Trail</td></tr>\n</table>\n</nys-table>",
|
|
12750
|
+
"lang": "html"
|
|
12751
|
+
},
|
|
12752
|
+
{
|
|
12753
|
+
"title": "Striped",
|
|
12754
|
+
"code": "<nys-table id=\"table2\" name=\"table2\" striped>\n<table>\n<caption>New York State High Peaks and Popular Hikes</caption>\n<tr><th>Mountain</th><th>Peak Height (ft)</th><th>Hike Name</th></tr>\n<tr><td>Marcy</td><td>5,344</td><td>Van Hoevenberg Trail</td></tr>\n<tr><td>Haystack</td><td>4,960</td><td>Johns Brook Trail</td></tr>\n<tr><td>Skylight</td><td>4,926</td><td>Lake Tear Trail</td></tr>\n<tr><td>Whiteface</td><td>4,867</td><td>Whiteface Mountain Trail</td></tr>\n</table>\n</nys-table>",
|
|
12755
|
+
"lang": "html"
|
|
12756
|
+
},
|
|
12757
|
+
{
|
|
12758
|
+
"title": "Bordered",
|
|
12759
|
+
"code": "<nys-table id=\"table3\" name=\"table3\" bordered>\n<table>\n<caption>New York State High Peaks and Popular Hikes</caption>\n<tr><th>Mountain</th><th>Peak Height (ft)</th><th>Hike Name</th></tr>\n<tr><td>Marcy</td><td>5,344</td><td>Van Hoevenberg Trail</td></tr>\n<tr><td>Haystack</td><td>4,960</td><td>Johns Brook Trail</td></tr>\n<tr><td>Skylight</td><td>4,926</td><td>Lake Tear Trail</td></tr>\n<tr><td>Whiteface</td><td>4,867</td><td>Whiteface Mountain Trail</td></tr>\n</table>\n</nys-table>",
|
|
12760
|
+
"lang": "html"
|
|
12761
|
+
},
|
|
12762
|
+
{
|
|
12763
|
+
"title": "Sortable",
|
|
12764
|
+
"code": "<nys-table id=\"table4\" name=\"table4\" sortable>\n<table>\n<caption>New York State High Peaks and Popular Hikes</caption>\n<tr><th>Mountain</th><th>Peak Height (ft)</th><th>Hike Name</th></tr>\n<tr><td>Marcy</td><td>5,344</td><td>Van Hoevenberg Trail</td></tr>\n<tr><td>Haystack</td><td>4,960</td><td>Johns Brook Trail</td></tr>\n<tr><td>Skylight</td><td>4,926</td><td>Lake Tear Trail</td></tr>\n<tr><td>Whiteface</td><td>4,867</td><td>Whiteface Mountain Trail</td></tr>\n</table>\n</nys-table>",
|
|
12765
|
+
"lang": "html"
|
|
12766
|
+
},
|
|
12767
|
+
{
|
|
12768
|
+
"title": "Downloadable",
|
|
12769
|
+
"code": "<nys-table id=\"table5\" name=\"table5\" download=\"path/to/downloadable/version/of/table.filetype\">\n<table>\n<caption>New York State High Peaks and Popular Hikes</caption>\n<tr><th>Mountain</th><th>Peak Height (ft)</th><th>Hike Name</th></tr>\n<tr><td>Marcy</td><td>5,344</td><td>Van Hoevenberg Trail</td></tr>\n<tr><td>Haystack</td><td>4,960</td><td>Johns Brook Trail</td></tr>\n<tr><td>Skylight</td><td>4,926</td><td>Lake Tear Trail</td></tr>\n<tr><td>Whiteface</td><td>4,867</td><td>Whiteface Mountain Trail</td></tr>\n</table>\n</nys-table>",
|
|
12770
|
+
"lang": "html"
|
|
12771
|
+
}
|
|
12772
|
+
],
|
|
11926
12773
|
"tagName": "nys-table",
|
|
11927
12774
|
"customElement": true
|
|
11928
12775
|
}
|
|
@@ -12065,7 +12912,7 @@
|
|
|
12065
12912
|
"text": "boolean"
|
|
12066
12913
|
},
|
|
12067
12914
|
"default": "false",
|
|
12068
|
-
"description": "Makes textarea
|
|
12915
|
+
"description": "Makes textarea readonly but focusable.",
|
|
12069
12916
|
"attribute": "readonly",
|
|
12070
12917
|
"reflects": true
|
|
12071
12918
|
},
|
|
@@ -12435,7 +13282,7 @@
|
|
|
12435
13282
|
"text": "boolean"
|
|
12436
13283
|
},
|
|
12437
13284
|
"default": "false",
|
|
12438
|
-
"description": "Makes textarea
|
|
13285
|
+
"description": "Makes textarea readonly but focusable.",
|
|
12439
13286
|
"fieldName": "readonly",
|
|
12440
13287
|
"propName": "readonly"
|
|
12441
13288
|
},
|
|
@@ -12559,13 +13406,58 @@
|
|
|
12559
13406
|
"summary": "Multi-line text input for comments, descriptions, and feedback.",
|
|
12560
13407
|
"examples": [
|
|
12561
13408
|
{
|
|
12562
|
-
"title": "Basic
|
|
12563
|
-
"code": "<nys-textarea label=\"Comments\"
|
|
13409
|
+
"title": "Basic",
|
|
13410
|
+
"code": "<nys-textarea label=\"Comments\"></nys-textarea>",
|
|
13411
|
+
"lang": "html"
|
|
13412
|
+
},
|
|
13413
|
+
{
|
|
13414
|
+
"title": "Disabled",
|
|
13415
|
+
"code": "<nys-textarea label=\"Comments\" disabled></nys-textarea>",
|
|
13416
|
+
"lang": "html"
|
|
13417
|
+
},
|
|
13418
|
+
{
|
|
13419
|
+
"title": "Readonly",
|
|
13420
|
+
"code": "<nys-textarea label=\"Comments\" readonly value=\"You can see me but not edit me\"></nys-textarea>",
|
|
13421
|
+
"lang": "html"
|
|
13422
|
+
},
|
|
13423
|
+
{
|
|
13424
|
+
"title": "Required",
|
|
13425
|
+
"code": "<nys-textarea label=\"Describe the incident\" required></nys-textarea>",
|
|
12564
13426
|
"lang": "html"
|
|
12565
13427
|
},
|
|
12566
13428
|
{
|
|
12567
|
-
"title": "
|
|
12568
|
-
"code": "<nys-textarea label=\"
|
|
13429
|
+
"title": "Optional",
|
|
13430
|
+
"code": "<nys-textarea label=\"Comments\" optional></nys-textarea>",
|
|
13431
|
+
"lang": "html"
|
|
13432
|
+
},
|
|
13433
|
+
{
|
|
13434
|
+
"title": "Max length",
|
|
13435
|
+
"code": "<nys-textarea label=\"Comments\" maxlength=\"100\"></nys-textarea>",
|
|
13436
|
+
"lang": "html"
|
|
13437
|
+
},
|
|
13438
|
+
{
|
|
13439
|
+
"title": "Width Small",
|
|
13440
|
+
"code": "<nys-textarea label=\"Comments\" width=\"sm\"></nys-textarea>",
|
|
13441
|
+
"lang": "html"
|
|
13442
|
+
},
|
|
13443
|
+
{
|
|
13444
|
+
"title": "Width Medium",
|
|
13445
|
+
"code": "<nys-textarea label=\"Comments\" width=\"md\"></nys-textarea>",
|
|
13446
|
+
"lang": "html"
|
|
13447
|
+
},
|
|
13448
|
+
{
|
|
13449
|
+
"title": "Width Large",
|
|
13450
|
+
"code": "<nys-textarea label=\"Comments\" width=\"lg\"></nys-textarea>",
|
|
13451
|
+
"lang": "html"
|
|
13452
|
+
},
|
|
13453
|
+
{
|
|
13454
|
+
"title": "Description",
|
|
13455
|
+
"code": "<nys-textarea label=\"Describe the incident\" description=\"Please provide details\"></nys-textarea>",
|
|
13456
|
+
"lang": "html"
|
|
13457
|
+
},
|
|
13458
|
+
{
|
|
13459
|
+
"title": "Description Slot",
|
|
13460
|
+
"code": "<nys-textarea label=\"Describe the incident\">\n<div slot=\"description\">Please provide details</div>\n</nys-textarea>",
|
|
12569
13461
|
"lang": "html"
|
|
12570
13462
|
}
|
|
12571
13463
|
]
|
|
@@ -13348,23 +14240,68 @@
|
|
|
13348
14240
|
"summary": "Text input for short single-line data with validation and masking support.",
|
|
13349
14241
|
"examples": [
|
|
13350
14242
|
{
|
|
13351
|
-
"title": "Basic
|
|
13352
|
-
"code": "<nys-textinput label=\"Full Name\"
|
|
14243
|
+
"title": "Basic",
|
|
14244
|
+
"code": "<nys-textinput label=\"Full Name\"></nys-textinput>",
|
|
14245
|
+
"lang": "html"
|
|
14246
|
+
},
|
|
14247
|
+
{
|
|
14248
|
+
"title": "Disabled",
|
|
14249
|
+
"code": "<nys-textinput label=\"Email Address\" disabled></nys-textinput>",
|
|
14250
|
+
"lang": "html"
|
|
14251
|
+
},
|
|
14252
|
+
{
|
|
14253
|
+
"title": "Readonly",
|
|
14254
|
+
"code": "<nys-textinput label=\"Email Address\" readonly value=\"You can see me but not edit me\"></nys-textinput>",
|
|
13353
14255
|
"lang": "html"
|
|
13354
14256
|
},
|
|
13355
14257
|
{
|
|
13356
|
-
"title": "Required
|
|
13357
|
-
"code": "<nys-textinput
|
|
14258
|
+
"title": "Required",
|
|
14259
|
+
"code": "<nys-textinput label=\"Email Address\" required></nys-textinput>",
|
|
13358
14260
|
"lang": "html"
|
|
13359
14261
|
},
|
|
13360
14262
|
{
|
|
13361
|
-
"title": "
|
|
13362
|
-
"code": "<nys-textinput
|
|
14263
|
+
"title": "Optional",
|
|
14264
|
+
"code": "<nys-textinput label=\"Email Address\" optional></nys-textinput>",
|
|
13363
14265
|
"lang": "html"
|
|
13364
14266
|
},
|
|
13365
14267
|
{
|
|
13366
|
-
"title": "
|
|
13367
|
-
"code": "<nys-textinput
|
|
14268
|
+
"title": "Width Small",
|
|
14269
|
+
"code": "<nys-textinput label=\"Zip Code\" width=\"sm\"></nys-textinput>",
|
|
14270
|
+
"lang": "html"
|
|
14271
|
+
},
|
|
14272
|
+
{
|
|
14273
|
+
"title": "Width Medium",
|
|
14274
|
+
"code": "<nys-textinput label=\"City\" width=\"md\"></nys-textinput>",
|
|
14275
|
+
"lang": "html"
|
|
14276
|
+
},
|
|
14277
|
+
{
|
|
14278
|
+
"title": "Width Large",
|
|
14279
|
+
"code": "<nys-textinput label=\"Email Address\" width=\"lg\"></nys-textinput>",
|
|
14280
|
+
"lang": "html"
|
|
14281
|
+
},
|
|
14282
|
+
{
|
|
14283
|
+
"title": "Description",
|
|
14284
|
+
"code": "<nys-textinput label=\"Email Address\" description=\"Only valid ny.gov emails are accepted.\"></nys-textinput>",
|
|
14285
|
+
"lang": "html"
|
|
14286
|
+
},
|
|
14287
|
+
{
|
|
14288
|
+
"title": "Description Slot",
|
|
14289
|
+
"code": "<nys-textinput label=\"Email Address\">\n<div slot=\"description\">Only valid <strong>ny.gov</strong> emails are accepted.</div>\n</nys-textinput>",
|
|
14290
|
+
"lang": "html"
|
|
14291
|
+
},
|
|
14292
|
+
{
|
|
14293
|
+
"title": "Masking",
|
|
14294
|
+
"code": "<nys-textinput type=\"tel\" label=\"Phone Number\">\n<div slot=\"description\">Some types, such as <code>tel</code> have automatic masking available.</div>\n</nys-textinput>",
|
|
14295
|
+
"lang": "html"
|
|
14296
|
+
},
|
|
14297
|
+
{
|
|
14298
|
+
"title": "Max Min Values",
|
|
14299
|
+
"code": "<nys-textinput type=\"number\" label=\"Age\" min=\"18\" max=\"99\" width=\"sm\"></nys-textinput>",
|
|
14300
|
+
"lang": "html"
|
|
14301
|
+
},
|
|
14302
|
+
{
|
|
14303
|
+
"title": "Suffix Button",
|
|
14304
|
+
"code": "<nys-textinput id=\"search-demo\" type=\"search\" placeholder=\"Search\">\n<nys-button\nslot=\"endButton\"\nariaLabel=\"Search\"\nprefixIcon=\"search\"\nonclick=\"alert('searching for: ' + document.getElementById('search-demo').value)\"\n></nys-button>\n</nys-textinput>",
|
|
13368
14305
|
"lang": "html"
|
|
13369
14306
|
}
|
|
13370
14307
|
]
|
|
@@ -13760,13 +14697,38 @@
|
|
|
13760
14697
|
"summary": "Toggle switch for binary settings with immediate effect.",
|
|
13761
14698
|
"examples": [
|
|
13762
14699
|
{
|
|
13763
|
-
"title": "Basic
|
|
13764
|
-
"code": "<nys-toggle label=\"Enable notifications\" name=\"notifications\"></nys-toggle>",
|
|
14700
|
+
"title": "Basic",
|
|
14701
|
+
"code": "<nys-toggle label=\"Enable notifications\" name=\"notifications\" value=\"enabled-notifications\"></nys-toggle>",
|
|
13765
14702
|
"lang": "html"
|
|
13766
14703
|
},
|
|
13767
14704
|
{
|
|
13768
|
-
"title": "
|
|
13769
|
-
"code": "<nys-toggle label=\"Dark
|
|
14705
|
+
"title": "Checked",
|
|
14706
|
+
"code": "<nys-toggle label=\"Dark Mode\" name=\"theme\" value=\"dark\" checked></nys-toggle>",
|
|
14707
|
+
"lang": "html"
|
|
14708
|
+
},
|
|
14709
|
+
{
|
|
14710
|
+
"title": "Disabled",
|
|
14711
|
+
"code": "<nys-toggle label=\"Opt Out of emails\" name=\"toggle-switch\" value=\"emails\" disabled></nys-toggle>",
|
|
14712
|
+
"lang": "html"
|
|
14713
|
+
},
|
|
14714
|
+
{
|
|
14715
|
+
"title": "Hide Icon",
|
|
14716
|
+
"code": "<nys-toggle label=\"No icon on the toggle knob\" name=\"icon\" value=\"no-icon\" noIcon></nys-toggle>",
|
|
14717
|
+
"lang": "html"
|
|
14718
|
+
},
|
|
14719
|
+
{
|
|
14720
|
+
"title": "Size small",
|
|
14721
|
+
"code": "<nys-toggle label=\"Tiny but mighty\" name=\"sm-size\" value=\"sm-size\" size=\"sm\"></nys-toggle>",
|
|
14722
|
+
"lang": "html"
|
|
14723
|
+
},
|
|
14724
|
+
{
|
|
14725
|
+
"title": "Description",
|
|
14726
|
+
"code": "<nys-toggle\nlabel=\"Opt Out of emails\"\ndescription=\"An email address is recommended to be on file for contact information.\"\nname=\"toggle-switch\"\nvalue=\"emails\"\n></nys-toggle>",
|
|
14727
|
+
"lang": "html"
|
|
14728
|
+
},
|
|
14729
|
+
{
|
|
14730
|
+
"title": "Description Slot",
|
|
14731
|
+
"code": "<nys-toggle\nlabel=\"Opt Out of emails\"\nname=\"toggle-switch\"\nvalue=\"emails\"\n>\n<p slot=\"description\">We <strong>REALLY</strong> encourage you to keep emails enabled for contact purposes.</p>\n</nys-toggle>",
|
|
13770
14732
|
"lang": "html"
|
|
13771
14733
|
}
|
|
13772
14734
|
]
|
|
@@ -14180,13 +15142,18 @@
|
|
|
14180
15142
|
"summary": "Contextual tooltip with auto-positioning, keyboard support, and screen reader integration.",
|
|
14181
15143
|
"examples": [
|
|
14182
15144
|
{
|
|
14183
|
-
"title": "
|
|
14184
|
-
"code": "<nys-
|
|
15145
|
+
"title": "Basic",
|
|
15146
|
+
"code": "<div style=\"display: flex; justify-content: center; gap: 5px; padding: 40px;\">\n<nys-tooltip for=\"my-button\" text=\"I am a tooltip.\"></nys-tooltip>\n<nys-button id=\"my-button\" label=\"Hover Me\"></nys-button>\n</div>",
|
|
15147
|
+
"lang": "html"
|
|
15148
|
+
},
|
|
15149
|
+
{
|
|
15150
|
+
"title": "Position",
|
|
15151
|
+
"code": "<div style=\"display: flex; justify-content: center; gap: 5px; padding: 40px;\">\n<p>Hover over the icon</p>\n<nys-tooltip\nfor=\"my-icon2\"\ntext=\"I am a tooltip.\"\nposition=\"right\"\n>\n</nys-tooltip>\n<nys-icon id=\"my-icon2\" name=\"info\" size=\"3xl\"></nys-icon>\n</div>",
|
|
14185
15152
|
"lang": "html"
|
|
14186
15153
|
},
|
|
14187
15154
|
{
|
|
14188
|
-
"title": "
|
|
14189
|
-
"code": "<
|
|
15155
|
+
"title": "Inverted",
|
|
15156
|
+
"code": "<div style=\"background-color: #1b1b1b; color: #ffffff; padding: 40px; display: flex; gap: 5px\">\n<p>Hover over the icon</p>\n<nys-tooltip\nfor=\"my-tooltip3\"\ntext=\"I am a tooltip.\"\ninverted\n>\n</nys-tooltip>\n<nys-icon id=\"my-tooltip3\" name=\"info\" size=\"3xl\"></nys-icon>\n</div>",
|
|
14190
15157
|
"lang": "html"
|
|
14191
15158
|
}
|
|
14192
15159
|
]
|
|
@@ -14251,8 +15218,8 @@
|
|
|
14251
15218
|
"summary": "Universal NYS footer with logo and statewide links. Required site-wide.",
|
|
14252
15219
|
"examples": [
|
|
14253
15220
|
{
|
|
14254
|
-
"title": "
|
|
14255
|
-
"code": "<nys-
|
|
15221
|
+
"title": "Basic",
|
|
15222
|
+
"code": "<nys-unavfooter></nys-unavfooter>",
|
|
14256
15223
|
"lang": "html"
|
|
14257
15224
|
}
|
|
14258
15225
|
]
|
|
@@ -14298,7 +15265,7 @@
|
|
|
14298
15265
|
"declarations": [
|
|
14299
15266
|
{
|
|
14300
15267
|
"kind": "class",
|
|
14301
|
-
"description": "",
|
|
15268
|
+
"description": "Universal NYS header with trust bar, logo, search, and language translation. Required on all NYS sites.\n\nPlace as the first element in `<body>`. Includes \"official site\" trust indicator, NY.gov logo,\nsite search (searches ny.gov), and 14-language translation dropdown. Use `hideSearch` or `hideTranslate`\nto remove features if not applicable.",
|
|
14302
15269
|
"name": "NysUnavHeader",
|
|
14303
15270
|
"members": [
|
|
14304
15271
|
{
|
|
@@ -14474,6 +15441,16 @@
|
|
|
14474
15441
|
]
|
|
14475
15442
|
}
|
|
14476
15443
|
],
|
|
15444
|
+
"events": [
|
|
15445
|
+
{
|
|
15446
|
+
"description": "Fired when a language is selected. Detail: `{language: {code, label, url?}}`. Cancelable; `preventDefault()` overrides the default Smartling redirect.",
|
|
15447
|
+
"name": "nys-language-select"
|
|
15448
|
+
},
|
|
15449
|
+
{
|
|
15450
|
+
"description": "Fired when a search is submitted. Detail: `{query}`. Cancelable; `preventDefault()` overrides the default search redirect.",
|
|
15451
|
+
"name": "nys-search-submit"
|
|
15452
|
+
}
|
|
15453
|
+
],
|
|
14477
15454
|
"attributes": [
|
|
14478
15455
|
{
|
|
14479
15456
|
"name": "trustbarVisible",
|
|
@@ -14561,7 +15538,40 @@
|
|
|
14561
15538
|
"package": "lit"
|
|
14562
15539
|
},
|
|
14563
15540
|
"tagName": "nys-unavheader",
|
|
14564
|
-
"customElement": true
|
|
15541
|
+
"customElement": true,
|
|
15542
|
+
"summary": "Universal NYS header with trust bar, search, and translation. Required site-wide.",
|
|
15543
|
+
"examples": [
|
|
15544
|
+
{
|
|
15545
|
+
"title": "Basic",
|
|
15546
|
+
"code": "<nys-unavheader></nys-unavheader>",
|
|
15547
|
+
"lang": "html"
|
|
15548
|
+
},
|
|
15549
|
+
{
|
|
15550
|
+
"title": "Hide search",
|
|
15551
|
+
"code": "<nys-unavheader hideSearch></nys-unavheader>",
|
|
15552
|
+
"lang": "html"
|
|
15553
|
+
},
|
|
15554
|
+
{
|
|
15555
|
+
"title": "Hide translate",
|
|
15556
|
+
"code": "<nys-unavheader hideTranslate></nys-unavheader>",
|
|
15557
|
+
"lang": "html"
|
|
15558
|
+
},
|
|
15559
|
+
{
|
|
15560
|
+
"title": "Custom Search URL",
|
|
15561
|
+
"code": "<nys-unavheader searchUrl=\"https://designsystem.ny.gov/search/?q=\"></nys-unavheader>",
|
|
15562
|
+
"lang": "html"
|
|
15563
|
+
},
|
|
15564
|
+
{
|
|
15565
|
+
"title": "Custom Language List",
|
|
15566
|
+
"code": "<nys-unavheader id=\"my-header\"></nys-unavheader>\n<script>\nconst header = document.querySelector('#my-header');\nheader.languages = [\n{ code: 'en', label: 'English' },\n{ code: 'es', label: 'Español' , url: '\"https://ny.gov/?lang=es\"'},\n{ code: 'fr', label: 'Français', url: '\"https://ny.gov/?lang=fr\"'},\n];\n</script>",
|
|
15567
|
+
"lang": "html"
|
|
15568
|
+
},
|
|
15569
|
+
{
|
|
15570
|
+
"title": "Custom Language List JS",
|
|
15571
|
+
"code": "<nys-unavheader id=\"my-header2\"></nys-unavheader>\n<script>\ndocument.querySelector('#my-header2').addEventListener('nys-language-select', (event) => {\nevent.preventDefault();\nconst selectedLanguage = event.detail.language.label;\n});\n</script>",
|
|
15572
|
+
"lang": "html"
|
|
15573
|
+
}
|
|
15574
|
+
]
|
|
14565
15575
|
}
|
|
14566
15576
|
],
|
|
14567
15577
|
"exports": [
|
|
@@ -14886,8 +15896,38 @@
|
|
|
14886
15896
|
"summary": "YouTube video player with thumbnail preview and accessibility announcements.",
|
|
14887
15897
|
"examples": [
|
|
14888
15898
|
{
|
|
14889
|
-
"title": "Basic
|
|
14890
|
-
"code": "<nys-video\nvideourl=\"https://www.youtube.com/watch?v=
|
|
15899
|
+
"title": "Basic",
|
|
15900
|
+
"code": "<nys-video\nvideourl=\"https://www.youtube.com/watch?v=TBfFzt0150Q\"\ntitleText=\"IT'S a Tech Podcast, Episode 3: Human-Centered Design\"\n></nys-video>",
|
|
15901
|
+
"lang": "html"
|
|
15902
|
+
},
|
|
15903
|
+
{
|
|
15904
|
+
"title": "Thumbnail",
|
|
15905
|
+
"code": "<nys-video\nvideourl=\"https://www.youtube.com/watch?v=TBfFzt0150Q\"\ntitleText=\"IT'S a Tech Podcast, Episode 3: Human-Centered Design\"\nthumbnail=\"https://designsystem.ny.gov/assets/img/homepage-grid-3.svg\"\n></nys-video>",
|
|
15906
|
+
"lang": "html"
|
|
15907
|
+
},
|
|
15908
|
+
{
|
|
15909
|
+
"title": "Autoplay",
|
|
15910
|
+
"code": "<nys-video\nvideourl=\"https://www.youtube.com/watch?v=TBfFzt0150Q\"\ntitleText=\"IT'S a Tech Podcast, Episode 3: Human-Centered Design\"\nautoplay\n></nys-video>",
|
|
15911
|
+
"lang": "html"
|
|
15912
|
+
},
|
|
15913
|
+
{
|
|
15914
|
+
"title": "Start Time",
|
|
15915
|
+
"code": "<nys-video\nvideourl=\"https://www.youtube.com/watch?v=TBfFzt0150Q\"\ntitleText=\"IT'S a Tech Podcast, Episode 3: Human-Centered Design\"\nstarttime=\"43\"\n></nys-video>",
|
|
15916
|
+
"lang": "html"
|
|
15917
|
+
},
|
|
15918
|
+
{
|
|
15919
|
+
"title": "Disabled",
|
|
15920
|
+
"code": "<nys-video\nvideourl=\"https://www.youtube.com/watch?v=TBfFzt0150Q\"\ntitleText=\"IT'S a Tech Podcast, Episode 3: Human-Centered Design\"\ndisabled\n></nys-video>",
|
|
15921
|
+
"lang": "html"
|
|
15922
|
+
},
|
|
15923
|
+
{
|
|
15924
|
+
"title": "Size full",
|
|
15925
|
+
"code": "<nys-video\nsize=\"full\"\nvideourl=\"https://www.youtube.com/watch?v=TBfFzt0150Q\"\ntitleText=\"Small (width: 320-439px)\"\n></nys-video>",
|
|
15926
|
+
"lang": "html"
|
|
15927
|
+
},
|
|
15928
|
+
{
|
|
15929
|
+
"title": "Size small",
|
|
15930
|
+
"code": "<nys-video\nsize=\"sm\"\nvideourl=\"https://www.youtube.com/watch?v=TBfFzt0150Q\"\ntitleText=\"Small (width: 320-439px)\"\n></nys-video>",
|
|
14891
15931
|
"lang": "html"
|
|
14892
15932
|
}
|
|
14893
15933
|
]
|