@punica/components 0.0.0-stage → 2.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +48 -0
- package/LICENSE +21 -0
- package/README.md +139 -2
- package/bin/punica-components.mjs +138 -0
- package/custom-elements.json +38745 -0
- package/dist/ai/index.d.ts +39 -0
- package/dist/ai/index.mjs +615 -0
- package/dist/ai/node.d.ts +5 -0
- package/dist/ai/node.mjs +625 -0
- package/dist/esm/chunks/chunk-25RFU6B5.js +25 -0
- package/dist/esm/chunks/chunk-2EK3PZFT.js +179 -0
- package/dist/esm/chunks/chunk-2KBDCVUH.js +20 -0
- package/dist/esm/chunks/chunk-2NCRRDPI.js +151 -0
- package/dist/esm/chunks/chunk-33GO7Z32.js +40 -0
- package/dist/esm/chunks/chunk-36BKRO3B.js +281 -0
- package/dist/esm/chunks/chunk-3DWJAU5S.js +607 -0
- package/dist/esm/chunks/chunk-3GOFXBR7.js +61 -0
- package/dist/esm/chunks/chunk-3H5QEUFO.js +21 -0
- package/dist/esm/chunks/chunk-3NHCLXYC.js +6 -0
- package/dist/esm/chunks/chunk-3NQ2RVWE.js +36 -0
- package/dist/esm/chunks/chunk-3SYFLID6.js +20 -0
- package/dist/esm/chunks/chunk-3TK5BG5K.js +322 -0
- package/dist/esm/chunks/chunk-3WLKVJO4.js +36 -0
- package/dist/esm/chunks/chunk-427DCAZS.js +49 -0
- package/dist/esm/chunks/chunk-4446KGJH.js +67 -0
- package/dist/esm/chunks/chunk-45UR4HAQ.js +128 -0
- package/dist/esm/chunks/chunk-46P3CPXM.js +81 -0
- package/dist/esm/chunks/chunk-4C3AUANN.js +271 -0
- package/dist/esm/chunks/chunk-4RURT4SK.js +142 -0
- package/dist/esm/chunks/chunk-4XJKCJQG.js +166 -0
- package/dist/esm/chunks/chunk-5PKJV3JP.js +61 -0
- package/dist/esm/chunks/chunk-5SSKNOUZ.js +141 -0
- package/dist/esm/chunks/chunk-5XB5CUJU.js +18 -0
- package/dist/esm/chunks/chunk-5XQX7D2B.js +27 -0
- package/dist/esm/chunks/chunk-6A5Q3TR2.js +73 -0
- package/dist/esm/chunks/chunk-6HE2DQS5.js +29 -0
- package/dist/esm/chunks/chunk-6IWDX7AR.js +32 -0
- package/dist/esm/chunks/chunk-6LO2ITXI.js +138 -0
- package/dist/esm/chunks/chunk-6NSNMUZE.js +36 -0
- package/dist/esm/chunks/chunk-6UQOC4YG.js +61 -0
- package/dist/esm/chunks/chunk-72ANEBJJ.js +138 -0
- package/dist/esm/chunks/chunk-7JTOYPC7.js +24 -0
- package/dist/esm/chunks/chunk-7O3D52ZO.js +27 -0
- package/dist/esm/chunks/chunk-7UN7TAOI.js +39 -0
- package/dist/esm/chunks/chunk-7WEISIJL.js +123 -0
- package/dist/esm/chunks/chunk-7YAUHJR2.js +225 -0
- package/dist/esm/chunks/chunk-7ZT7WUEL.js +35 -0
- package/dist/esm/chunks/chunk-ALU2KZWS.js +177 -0
- package/dist/esm/chunks/chunk-AMVMOCUW.js +81 -0
- package/dist/esm/chunks/chunk-APPQS53K.js +81 -0
- package/dist/esm/chunks/chunk-AVTATVAG.js +410 -0
- package/dist/esm/chunks/chunk-AZMUP33Z.js +56 -0
- package/dist/esm/chunks/chunk-B32J3O2V.js +21 -0
- package/dist/esm/chunks/chunk-B7YCX5VB.js +38 -0
- package/dist/esm/chunks/chunk-BBSDD7DS.js +55 -0
- package/dist/esm/chunks/chunk-BC657356.js +93 -0
- package/dist/esm/chunks/chunk-BFRWXGP4.js +44 -0
- package/dist/esm/chunks/chunk-BYZADSVQ.js +49 -0
- package/dist/esm/chunks/chunk-CDXX27FL.js +28 -0
- package/dist/esm/chunks/chunk-CKI34FQL.js +166 -0
- package/dist/esm/chunks/chunk-CNT47W5N.js +60 -0
- package/dist/esm/chunks/chunk-CU3RW3AS.js +515 -0
- package/dist/esm/chunks/chunk-CZ3R7GRW.js +73 -0
- package/dist/esm/chunks/chunk-DLEJ74RA.js +18 -0
- package/dist/esm/chunks/chunk-DPOPZQ7A.js +150 -0
- package/dist/esm/chunks/chunk-DYXHKPQU.js +18 -0
- package/dist/esm/chunks/chunk-E3XOZZSK.js +77 -0
- package/dist/esm/chunks/chunk-EJLQD3FS.js +89 -0
- package/dist/esm/chunks/chunk-ELY5HYAI.js +45 -0
- package/dist/esm/chunks/chunk-ELY5NJBV.js +152 -0
- package/dist/esm/chunks/chunk-EWIF3VBH.js +45 -0
- package/dist/esm/chunks/chunk-F2OASWR4.js +79 -0
- package/dist/esm/chunks/chunk-F4ODKLNS.js +62 -0
- package/dist/esm/chunks/chunk-F5HKSUTX.js +127 -0
- package/dist/esm/chunks/chunk-FFH6CIAJ.js +208 -0
- package/dist/esm/chunks/chunk-FFLBSXWE.js +21 -0
- package/dist/esm/chunks/chunk-FNTBMCUQ.js +184 -0
- package/dist/esm/chunks/chunk-FYSNICNC.js +71 -0
- package/dist/esm/chunks/chunk-G2QRQLP5.js +18 -0
- package/dist/esm/chunks/chunk-G36PG2LK.js +27 -0
- package/dist/esm/chunks/chunk-G5LARXMF.js +73 -0
- package/dist/esm/chunks/chunk-GQLNLUQX.js +42 -0
- package/dist/esm/chunks/chunk-GRWYCZQZ.js +73 -0
- package/dist/esm/chunks/chunk-GSXWSHYU.js +304 -0
- package/dist/esm/chunks/chunk-GVH32USX.js +48 -0
- package/dist/esm/chunks/chunk-GW3IYQNO.js +271 -0
- package/dist/esm/chunks/chunk-H4Q2HHZA.js +151 -0
- package/dist/esm/chunks/chunk-HDHVTBGS.js +330 -0
- package/dist/esm/chunks/chunk-HK6DEJO3.js +74 -0
- package/dist/esm/chunks/chunk-HUMTZKOD.js +114 -0
- package/dist/esm/chunks/chunk-HW2CN2JV.js +118 -0
- package/dist/esm/chunks/chunk-I6WGYC6M.js +50 -0
- package/dist/esm/chunks/chunk-ICGI6UOP.js +28 -0
- package/dist/esm/chunks/chunk-IYZKVVEX.js +285 -0
- package/dist/esm/chunks/chunk-J4HTWL4Q.js +34 -0
- package/dist/esm/chunks/chunk-J6FXZP6E.js +99 -0
- package/dist/esm/chunks/chunk-JTIBDZBU.js +392 -0
- package/dist/esm/chunks/chunk-K2OIQJ36.js +23 -0
- package/dist/esm/chunks/chunk-K5D5UHVI.js +99 -0
- package/dist/esm/chunks/chunk-K753LIJX.js +157 -0
- package/dist/esm/chunks/chunk-KV4Y5ZP5.js +105 -0
- package/dist/esm/chunks/chunk-KVWZQINH.js +44 -0
- package/dist/esm/chunks/chunk-LKKKFYM4.js +106 -0
- package/dist/esm/chunks/chunk-LKPOFLSP.js +337 -0
- package/dist/esm/chunks/chunk-LSDTMST7.js +6 -0
- package/dist/esm/chunks/chunk-LUASZ5NH.js +271 -0
- package/dist/esm/chunks/chunk-LUPYODQN.js +54 -0
- package/dist/esm/chunks/chunk-M3HQENQG.js +93 -0
- package/dist/esm/chunks/chunk-MCHPBSW4.js +155 -0
- package/dist/esm/chunks/chunk-MDEV5WIN.js +25 -0
- package/dist/esm/chunks/chunk-MF2ASALV.js +194 -0
- package/dist/esm/chunks/chunk-MIUSZNAX.js +62 -0
- package/dist/esm/chunks/chunk-NINGLTB2.js +194 -0
- package/dist/esm/chunks/chunk-NLFUTVKG.js +158 -0
- package/dist/esm/chunks/chunk-NNCGUKTM.js +44 -0
- package/dist/esm/chunks/chunk-NSCGX5GB.js +408 -0
- package/dist/esm/chunks/chunk-NTIMVMDT.js +51 -0
- package/dist/esm/chunks/chunk-OBUW2HDW.js +99 -0
- package/dist/esm/chunks/chunk-OKRRNW3E.js +202 -0
- package/dist/esm/chunks/chunk-PGWADMK3.js +198 -0
- package/dist/esm/chunks/chunk-PMGKVE2V.js +30 -0
- package/dist/esm/chunks/chunk-PMLVGWVZ.js +80 -0
- package/dist/esm/chunks/chunk-PXECURYJ.js +78 -0
- package/dist/esm/chunks/chunk-Q2766HFS.js +34 -0
- package/dist/esm/chunks/chunk-Q62K7757.js +22 -0
- package/dist/esm/chunks/chunk-Q7JNV3UN.js +192 -0
- package/dist/esm/chunks/chunk-QRJKBLYH.js +43 -0
- package/dist/esm/chunks/chunk-QRZWLIUQ.js +551 -0
- package/dist/esm/chunks/chunk-RKF3ZNBC.js +25 -0
- package/dist/esm/chunks/chunk-RMJM6NWT.js +58 -0
- package/dist/esm/chunks/chunk-ROTG34TD.js +81 -0
- package/dist/esm/chunks/chunk-RQ2NYS2W.js +51 -0
- package/dist/esm/chunks/chunk-RX5HOB7L.js +187 -0
- package/dist/esm/chunks/chunk-RYOY6CGB.js +174 -0
- package/dist/esm/chunks/chunk-S2P6I4PF.js +191 -0
- package/dist/esm/chunks/chunk-SCSGRIQM.js +27 -0
- package/dist/esm/chunks/chunk-SENDWPHS.js +115 -0
- package/dist/esm/chunks/chunk-SFY6NIVM.js +106 -0
- package/dist/esm/chunks/chunk-SHEACXCO.js +67 -0
- package/dist/esm/chunks/chunk-SII4GAN2.js +302 -0
- package/dist/esm/chunks/chunk-SIUUXS2M.js +172 -0
- package/dist/esm/chunks/chunk-SLXOGLX4.js +39 -0
- package/dist/esm/chunks/chunk-ST7UASSS.js +43 -0
- package/dist/esm/chunks/chunk-SUNHM3W2.js +211 -0
- package/dist/esm/chunks/chunk-SWTIN4AS.js +43 -0
- package/dist/esm/chunks/chunk-T2FH4DTZ.js +163 -0
- package/dist/esm/chunks/chunk-TK5H2DLW.js +157 -0
- package/dist/esm/chunks/chunk-U3SSEG6P.js +31 -0
- package/dist/esm/chunks/chunk-UNQEQ3F2.js +118 -0
- package/dist/esm/chunks/chunk-UP3ZQ5S6.js +155 -0
- package/dist/esm/chunks/chunk-UQFS4FAE.js +80 -0
- package/dist/esm/chunks/chunk-UZXXUKV6.js +124 -0
- package/dist/esm/chunks/chunk-VF4NHXZG.js +33 -0
- package/dist/esm/chunks/chunk-VIGFMBQW.js +337 -0
- package/dist/esm/chunks/chunk-VJBXT6L2.js +86 -0
- package/dist/esm/chunks/chunk-VM4IKZDR.js +211 -0
- package/dist/esm/chunks/chunk-VPCWI2SH.js +18 -0
- package/dist/esm/chunks/chunk-VR225VA6.js +29 -0
- package/dist/esm/chunks/chunk-WEGQW4SS.js +285 -0
- package/dist/esm/chunks/chunk-WHXEETCS.js +80 -0
- package/dist/esm/chunks/chunk-X2XT4SYI.js +71 -0
- package/dist/esm/chunks/chunk-X6Y3S66P.js +91 -0
- package/dist/esm/chunks/chunk-XBFOPEHZ.js +86 -0
- package/dist/esm/chunks/chunk-XE74KQOC.js +18 -0
- package/dist/esm/chunks/chunk-XNMQ4SC7.js +95 -0
- package/dist/esm/chunks/chunk-XWPDELI6.js +53 -0
- package/dist/esm/chunks/chunk-XWZPKK2I.js +6 -0
- package/dist/esm/chunks/chunk-XZSAOJUV.js +83 -0
- package/dist/esm/chunks/chunk-Y5BQXWLM.js +58 -0
- package/dist/esm/chunks/chunk-Y5HOTHVK.js +22 -0
- package/dist/esm/chunks/chunk-Y7B65FYJ.js +336 -0
- package/dist/esm/chunks/chunk-YIAEOUGS.js +46 -0
- package/dist/esm/chunks/chunk-YKL6MAIV.js +208 -0
- package/dist/esm/chunks/chunk-YPH3G6P7.js +125 -0
- package/dist/esm/chunks/chunk-YSGWORUD.js +36 -0
- package/dist/esm/chunks/chunk-ZB7DQSJK.js +204 -0
- package/dist/esm/chunks/chunk-ZC7JPIL7.js +182 -0
- package/dist/esm/chunks/chunk-ZGBBW7U4.js +35 -0
- package/dist/esm/chunks/chunk-ZIQREEEI.js +210 -0
- package/dist/esm/chunks/chunk-ZJ3UIJ46.js +30 -0
- package/dist/esm/chunks/chunk-ZK6JTE6K.js +826 -0
- package/dist/esm/chunks/chunk-ZPIJWNFB.js +150 -0
- package/dist/esm/chunks/chunk-ZQVI42RW.js +136 -0
- package/dist/esm/chunks/chunk-ZWP6KATC.js +25 -0
- package/dist/esm/chunks/chunk-ZY5YHMTQ.js +88 -0
- package/dist/esm/components/accordion/accordion.js +8 -0
- package/dist/esm/components/accordion/accordionGroup.js +7 -0
- package/dist/esm/components/agenda/agenda.js +9 -0
- package/dist/esm/components/alert/alert.js +8 -0
- package/dist/esm/components/alertDialog/alertDialog.js +14 -0
- package/dist/esm/components/appBar/appBar.js +7 -0
- package/dist/esm/components/appShell/appShell.js +11 -0
- package/dist/esm/components/aspectRatio/aspectRatio.js +7 -0
- package/dist/esm/components/autocomplete/autocomplete.js +14 -0
- package/dist/esm/components/avatar/avatar.js +7 -0
- package/dist/esm/components/avatarGroup/avatarGroup.js +11 -0
- package/dist/esm/components/badge/badge.js +7 -0
- package/dist/esm/components/banner/banner.js +9 -0
- package/dist/esm/components/blockquote/blockquote.js +7 -0
- package/dist/esm/components/bottomSheet/bottomSheet.js +9 -0
- package/dist/esm/components/box/box.js +7 -0
- package/dist/esm/components/breadcrumbs/breadcrumbItem.js +8 -0
- package/dist/esm/components/breadcrumbs/breadcrumbs.js +11 -0
- package/dist/esm/components/button/button.js +8 -0
- package/dist/esm/components/buttonGroup/buttonGroup.js +7 -0
- package/dist/esm/components/calendar/calendar.js +12 -0
- package/dist/esm/components/calendar/dates.js +44 -0
- package/dist/esm/components/card/card.js +7 -0
- package/dist/esm/components/card/cardActions.js +7 -0
- package/dist/esm/components/card/cardContent.js +7 -0
- package/dist/esm/components/card/cardHeader.js +7 -0
- package/dist/esm/components/card/cardMedia.js +7 -0
- package/dist/esm/components/carousel/carousel.js +9 -0
- package/dist/esm/components/carousel/carouselItem.js +7 -0
- package/dist/esm/components/center/center.js +7 -0
- package/dist/esm/components/chat/chatComposer.js +9 -0
- package/dist/esm/components/chat/chatDictationButton.js +8 -0
- package/dist/esm/components/chat/chatLayout.js +9 -0
- package/dist/esm/components/chat/chatMessage.js +9 -0
- package/dist/esm/components/chat/chatMessageBubble.js +7 -0
- package/dist/esm/components/chat/chatMessageList.js +8 -0
- package/dist/esm/components/chat/chatMessageMetadata.js +7 -0
- package/dist/esm/components/chat/chatSystemMessage.js +7 -0
- package/dist/esm/components/chat/chatToolCall.js +9 -0
- package/dist/esm/components/chat/chatToolCalls.js +8 -0
- package/dist/esm/components/chat/slots.js +6 -0
- package/dist/esm/components/checkbox/checkbox.js +9 -0
- package/dist/esm/components/checkboxGroup/checkboxGroup.js +10 -0
- package/dist/esm/components/chip/chip.js +8 -0
- package/dist/esm/components/citation/citation.js +11 -0
- package/dist/esm/components/code/code.js +7 -0
- package/dist/esm/components/codeBlock/codeBlock.js +8 -0
- package/dist/esm/components/collapsible/collapsible.js +7 -0
- package/dist/esm/components/commandPalette/commandGroup.js +7 -0
- package/dist/esm/components/commandPalette/commandItem.js +7 -0
- package/dist/esm/components/commandPalette/commandPalette.js +10 -0
- package/dist/esm/components/complexSelector/complexOption.js +9 -0
- package/dist/esm/components/complexSelector/complexSelector.js +16 -0
- package/dist/esm/components/complexSelector/optionGroup.js +7 -0
- package/dist/esm/components/container/container.js +7 -0
- package/dist/esm/components/contextMenu/contextMenu.js +12 -0
- package/dist/esm/components/datePicker/datePicker.js +15 -0
- package/dist/esm/components/dateRangeInput/dateRangeInput.js +15 -0
- package/dist/esm/components/dateTimeInput/dateTimeInput.js +18 -0
- package/dist/esm/components/dialog/dialog.js +11 -0
- package/dist/esm/components/dialog/dialogContent.js +7 -0
- package/dist/esm/components/dialog/dialogFooter.js +7 -0
- package/dist/esm/components/dialog/dialogHeader.js +7 -0
- package/dist/esm/components/dialog/modalSurface.js +8 -0
- package/dist/esm/components/divider/divider.js +7 -0
- package/dist/esm/components/drawer/drawer.js +10 -0
- package/dist/esm/components/emptyState/emptyState.js +7 -0
- package/dist/esm/components/field/field.js +7 -0
- package/dist/esm/components/fileInput/fileInput.js +9 -0
- package/dist/esm/components/formLayout/formLayout.js +7 -0
- package/dist/esm/components/grid/col.js +7 -0
- package/dist/esm/components/grid/row.js +7 -0
- package/dist/esm/components/heading/heading.js +7 -0
- package/dist/esm/components/hidden/hidden.js +7 -0
- package/dist/esm/components/hoverCard/hoverCard.js +9 -0
- package/dist/esm/components/icon/icon.js +8 -0
- package/dist/esm/components/iconButton/iconButton.js +8 -0
- package/dist/esm/components/infoTip/infoTip.js +10 -0
- package/dist/esm/components/input/input.js +9 -0
- package/dist/esm/components/inputGroup/inputGroup.js +9 -0
- package/dist/esm/components/inputGroup/inputGroupText.js +7 -0
- package/dist/esm/components/kbd/kbd.js +7 -0
- package/dist/esm/components/lightbox/lightbox.js +10 -0
- package/dist/esm/components/link/link.js +8 -0
- package/dist/esm/components/listView/list.js +7 -0
- package/dist/esm/components/listView/listItem.js +7 -0
- package/dist/esm/components/listbox/listbox.js +9 -0
- package/dist/esm/components/listbox/listboxItem.js +8 -0
- package/dist/esm/components/markdown/markdown.js +9 -0
- package/dist/esm/components/markdown/parser.js +9 -0
- package/dist/esm/components/markdown/url.js +6 -0
- package/dist/esm/components/menu/menu.js +11 -0
- package/dist/esm/components/menu/menuCheckboxItem.js +9 -0
- package/dist/esm/components/menu/menuDivider.js +7 -0
- package/dist/esm/components/menu/menuGroup.js +7 -0
- package/dist/esm/components/menu/menuItem.js +8 -0
- package/dist/esm/components/menu/menuRadioGroup.js +7 -0
- package/dist/esm/components/menu/menuRadioItem.js +9 -0
- package/dist/esm/components/metadataList/metadataList.js +9 -0
- package/dist/esm/components/metadataList/metadataListItem.js +8 -0
- package/dist/esm/components/mobileNav/mobileNav.js +10 -0
- package/dist/esm/components/numberInput/numberInput.js +9 -0
- package/dist/esm/components/outline/outline.js +8 -0
- package/dist/esm/components/overflowList/overflowList.js +11 -0
- package/dist/esm/components/pagination/pagination.js +8 -0
- package/dist/esm/components/paper/paper.js +7 -0
- package/dist/esm/components/popover/popover.js +9 -0
- package/dist/esm/components/powerSearch/powerSearch.js +14 -0
- package/dist/esm/components/progressBar/progressBar.js +7 -0
- package/dist/esm/components/qrCode/qrCode.js +9 -0
- package/dist/esm/components/radio/radio.js +7 -0
- package/dist/esm/components/radio/radioGroup.js +10 -0
- package/dist/esm/components/scrollArea/scrollArea.js +8 -0
- package/dist/esm/components/section/section.js +8 -0
- package/dist/esm/components/segmentedControl/segmentedControl.js +12 -0
- package/dist/esm/components/segmentedControl/segmentedControlItem.js +7 -0
- package/dist/esm/components/select/field.js +18 -0
- package/dist/esm/components/select/option.js +8 -0
- package/dist/esm/components/select/select.js +14 -0
- package/dist/esm/components/selectableCard/selectableCard.js +9 -0
- package/dist/esm/components/selectableCard/selectableCardGroup.js +13 -0
- package/dist/esm/components/sideNav/sideNav.js +9 -0
- package/dist/esm/components/sideNav/sideNavItem.js +9 -0
- package/dist/esm/components/sideNav/sideNavSection.js +8 -0
- package/dist/esm/components/skeleton/skeleton.js +7 -0
- package/dist/esm/components/slider/slider.js +9 -0
- package/dist/esm/components/spinner/spinner.js +7 -0
- package/dist/esm/components/split/split.js +8 -0
- package/dist/esm/components/splitButton/splitButton.js +12 -0
- package/dist/esm/components/stack/stack.js +7 -0
- package/dist/esm/components/statusDot/statusDot.js +7 -0
- package/dist/esm/components/stepper/step.js +8 -0
- package/dist/esm/components/stepper/stepper.js +7 -0
- package/dist/esm/components/switch/switch.js +8 -0
- package/dist/esm/components/tab/tab.js +7 -0
- package/dist/esm/components/tab/tabPanel.js +7 -0
- package/dist/esm/components/tab/tabs.js +8 -0
- package/dist/esm/components/table/table.js +7 -0
- package/dist/esm/components/table/tableBody.js +7 -0
- package/dist/esm/components/table/tableCell.js +7 -0
- package/dist/esm/components/table/tableFooter.js +7 -0
- package/dist/esm/components/table/tableHeader.js +7 -0
- package/dist/esm/components/table/tableHeaderCell.js +8 -0
- package/dist/esm/components/table/tableRow.js +7 -0
- package/dist/esm/components/table/tableSelectionToolbar.js +8 -0
- package/dist/esm/components/text/text.js +7 -0
- package/dist/esm/components/textarea/textarea.js +8 -0
- package/dist/esm/components/thumbnail/thumbnail.js +8 -0
- package/dist/esm/components/timePicker/timePicker.js +15 -0
- package/dist/esm/components/timer/timer.js +7 -0
- package/dist/esm/components/timestamp/timestamp.js +7 -0
- package/dist/esm/components/toast/toast.js +8 -0
- package/dist/esm/components/toast/toaster.js +12 -0
- package/dist/esm/components/toggleButton/toggleButton.js +8 -0
- package/dist/esm/components/toggleButtonGroup/toggleButtonGroup.js +10 -0
- package/dist/esm/components/tokenizer/tokenizer.js +14 -0
- package/dist/esm/components/toolbar/toolbar.js +8 -0
- package/dist/esm/components/tooltip/tooltip.js +9 -0
- package/dist/esm/components/topNav/topNav.js +11 -0
- package/dist/esm/components/topNav/topNavItem.js +11 -0
- package/dist/esm/components/topNav/topNavMegaMenu.js +7 -0
- package/dist/esm/components/topNav/topNavMegaMenuCard.js +8 -0
- package/dist/esm/components/topNav/topNavMegaMenuGroup.js +7 -0
- package/dist/esm/components/topNav/topNavMegaMenuItem.js +7 -0
- package/dist/esm/components/tree/tree.js +8 -0
- package/dist/esm/components/tree/treeItem.js +8 -0
- package/dist/esm/components/virtualList/virtualList.js +7 -0
- package/dist/esm/components/virtualTable/virtualTable.js +9 -0
- package/dist/esm/components/visuallyHidden/visuallyHidden.js +7 -0
- package/dist/esm/core/a11y.js +22 -0
- package/dist/esm/core/element.js +14 -0
- package/dist/esm/core/form.js +6 -0
- package/dist/esm/core/overlay.js +8 -0
- package/dist/esm/index.js +779 -0
- package/dist/llms-full.txt +8903 -0
- package/dist/llms.txt +288 -0
- package/dist/punica-components.min.js +14283 -0
- package/dist/tokens.css +158 -0
- package/dist/types/index.d.ts +6762 -0
- package/dist/types/react.d.ts +1914 -0
- package/dist/vscode.css-custom-data.json +3892 -0
- package/dist/vscode.html-custom-data.json +6912 -0
- package/dist/web-types.json +12404 -0
- package/docs/MIGRATION-2.0.md +112 -0
- package/docs/contract.md +130 -0
- package/docs/migration/chat.md +309 -0
- package/docs/migration/content.md +806 -0
- package/docs/migration/data.md +140 -0
- package/docs/migration/display.md +625 -0
- package/docs/migration/form-basic.md +262 -0
- package/docs/migration/navigation.md +368 -0
- package/docs/migration/overlays.md +261 -0
- package/docs/migration/pickers.md +194 -0
- package/package.json +135 -4
- package/scripts/codemod-2.0.mjs +50 -0
- package/scripts/codemod-rules.mjs +102 -0
- package/skills/punica-components/SKILL.md +48 -0
|
@@ -0,0 +1,625 @@
|
|
|
1
|
+
# Display and layout: 1.x → 2.0
|
|
2
|
+
|
|
3
|
+
Thirty-five elements in thirty folders. Twenty-four replace a 1.x element,
|
|
4
|
+
eleven are new. One table per element; `—` in the 1.x column means the
|
|
5
|
+
thing did not exist, in the 2.0 column that it is gone.
|
|
6
|
+
|
|
7
|
+
What changed everywhere, and is not repeated in each table:
|
|
8
|
+
|
|
9
|
+
- Every element is an ES module on `PunicaElement`. Nothing registers on a
|
|
10
|
+
global and nothing needs the 1.x `PunicaBase` script loaded first.
|
|
11
|
+
- Attributes are kebab-case and booleans follow HTML: `fullwidth` is
|
|
12
|
+
`full-width`, and `disabled="false"` is still disabled.
|
|
13
|
+
- Roles and ARIA state are set through `ElementInternals`. 1.x wrote `role`
|
|
14
|
+
and `aria-*` attributes on the host; 2.0 leaves the host's attributes to
|
|
15
|
+
you. Read `el.internals.role` in a test.
|
|
16
|
+
- No element writes an inline style on its host. 1.x `color="#f00"` on an
|
|
17
|
+
avatar, a progress line or a typography wrote `style="..."`; 2.0 `color`
|
|
18
|
+
takes a palette name only (`primary | secondary | error | warning | info |
|
|
19
|
+
success | neutral`), and anything else is a custom property.
|
|
20
|
+
- No attribute value reaches a stylesheet as text. Numbers are parsed, names
|
|
21
|
+
are matched by attribute selectors, lengths are checked with
|
|
22
|
+
`CSS.supports`, and the result is set through the CSSOM on a sheet of the
|
|
23
|
+
instance.
|
|
24
|
+
- Tokens are `--punica-*` (see the token map in [`MIGRATION-2.0.md`](../MIGRATION-2.0.md#tokens)). Every
|
|
25
|
+
component custom property is `--punica-<element>-<property>`.
|
|
26
|
+
- `left`/`right` are gone: placement names and styles are logical.
|
|
27
|
+
|
|
28
|
+
## Removed elements
|
|
29
|
+
|
|
30
|
+
| 1.x | 2.0 |
|
|
31
|
+
|---|---|
|
|
32
|
+
| `punica-alert-icon`, `punica-alert-content`, `punica-alert-action` | Slots of `punica-alert`: `icon`, default, `actions` |
|
|
33
|
+
| `punica-progress-line` | `punica-progress-bar` |
|
|
34
|
+
| `punica-typography` | `punica-heading` for `variant="headline1..6"`, `punica-text` for the rest |
|
|
35
|
+
|
|
36
|
+
---
|
|
37
|
+
|
|
38
|
+
## punica-alert
|
|
39
|
+
|
|
40
|
+
`alert/alert.js`.
|
|
41
|
+
|
|
42
|
+
| | 1.x | 2.0 |
|
|
43
|
+
|---|---|---|
|
|
44
|
+
| Tag | `punica-alert` with `punica-alert-icon`, `punica-alert-content`, `punica-alert-action` children | `punica-alert` alone |
|
|
45
|
+
| Attribute | `severity`: `error \| info \| success \| warning` | `color`: the same four plus `primary \| secondary \| neutral`; `info` by default |
|
|
46
|
+
| Attribute | `variant`: `standard \| outlined \| filled` | `variant`: `tinted \| outlined \| filled`; `tinted` (the old `standard`) by default |
|
|
47
|
+
| Attribute | — | `dismissible`: shows a close button |
|
|
48
|
+
| Attribute | — | `label-close`: name of the close button, `Close` |
|
|
49
|
+
| Property | `variant`, `severity` | `variant`, `color`, `dismissible`, `labelClose` |
|
|
50
|
+
| Method | — | `dismiss()`: what the close button does |
|
|
51
|
+
| Event | — | `punica-dismiss`, detail `{}`, cancelable. Unless prevented the alert sets `hidden` on itself |
|
|
52
|
+
| Slot | default (the three child elements) | default: the message |
|
|
53
|
+
| Slot | `punica-alert-icon` | `icon`. Empty, it shows the glyph of the colour (`info`, `success`, `warning`, `error`) |
|
|
54
|
+
| Slot | `punica-alert-action` | `actions` |
|
|
55
|
+
| Part | — | `icon` (the default glyph), `content`, `actions`, `close` |
|
|
56
|
+
| Role | none | `alert` for `error` and `warning`, `status` otherwise |
|
|
57
|
+
| Custom property | `--alert-border-radius` | `--punica-alert-radius` |
|
|
58
|
+
| Custom property | `--alert-padding` | `--punica-alert-padding` |
|
|
59
|
+
| Custom property | — | `--punica-alert-gap` |
|
|
60
|
+
| Removed | The tinted variant drew the message in the palette's main colour on its light tint | It draws `-dark` on `-light`, which meets 4.5:1 |
|
|
61
|
+
| Removed | `:host[class*='variant-outlined']`, a selector that never matched, so outlined had no border | Outlined has a border in the accent |
|
|
62
|
+
|
|
63
|
+
## punica-banner (new)
|
|
64
|
+
|
|
65
|
+
`banner/banner.js`. A page-level message bar. It extends `PunicaAlert`: the
|
|
66
|
+
attributes, slots, parts, close button, role and event are the alert's.
|
|
67
|
+
|
|
68
|
+
| | 2.0 |
|
|
69
|
+
|---|---|
|
|
70
|
+
| Attribute | `color`, `variant`, `dismissible`, `label-close`, as on `punica-alert` |
|
|
71
|
+
| Method | `dismiss()` |
|
|
72
|
+
| Event | `punica-dismiss`, detail `{}`, cancelable |
|
|
73
|
+
| Slot | default, `icon`, `actions` |
|
|
74
|
+
| Part | `icon`, `content`, `actions`, `close` |
|
|
75
|
+
| Role | `alert` for `error` and `warning`, `status` otherwise |
|
|
76
|
+
| Custom property | `--punica-banner-padding` |
|
|
77
|
+
| Custom property | `--punica-banner-max-width`: caps the message so a wide bar reads as a centred line |
|
|
78
|
+
| Layout | Full inline size, square corners, a line on the block-end edge only, content centred |
|
|
79
|
+
|
|
80
|
+
## punica-avatar
|
|
81
|
+
|
|
82
|
+
`avatar/avatar.js`.
|
|
83
|
+
|
|
84
|
+
| | 1.x | 2.0 |
|
|
85
|
+
|---|---|---|
|
|
86
|
+
| Tag | `punica-avatar` | `punica-avatar` |
|
|
87
|
+
| Attribute | — | `src`: the picture. 1.x took a slotted `<img>` |
|
|
88
|
+
| Attribute | — | `name`: gives the initials (first letter of the first and last word, upper-cased in the element's language) while the picture is missing or fails, and the accessible name |
|
|
89
|
+
| Attribute | — | `label`, `alt`: accessible name; `label` wins over `alt`, which wins over `name` |
|
|
90
|
+
| Attribute | `variant`: `rounded \| circular` | `shape`: `circle \| square`; `circle` by default. 1.x had no default, so an avatar with no `variant` was a square |
|
|
91
|
+
| Attribute | — | `size`: `small \| medium \| large` (28, 36, 44 px); 1.x was 36 px only |
|
|
92
|
+
| Attribute | `color`: a palette name or any CSS colour, written to `style` | `color`: a palette name; `neutral` by default |
|
|
93
|
+
| Slot | default: an `<img>` or text | default: shown only with no picture and no name, for an icon |
|
|
94
|
+
| Slot | — | `status`: a mark at the block-end inline-end corner, outside the clip |
|
|
95
|
+
| Part | — | `base`, `image`, `initials`, `status` |
|
|
96
|
+
| State | — | `image`, `initials` |
|
|
97
|
+
| Role | none | `img` with the name when there is one |
|
|
98
|
+
| Custom property | — | `--punica-avatar-size`, `--punica-avatar-radius`, `--punica-avatar-background`, `--punica-avatar-color` |
|
|
99
|
+
| Removed | A slotted `<img>` filling the avatar | Use `src`. A slotted element still shows as the fallback but is not stretched |
|
|
100
|
+
| Removed | Any CSS colour in `color` | `--punica-avatar-background` |
|
|
101
|
+
|
|
102
|
+
## punica-badge
|
|
103
|
+
|
|
104
|
+
`badge/badge.js`.
|
|
105
|
+
|
|
106
|
+
| | 1.x | 2.0 |
|
|
107
|
+
|---|---|---|
|
|
108
|
+
| Tag | `punica-badge` | `punica-badge` |
|
|
109
|
+
| Attribute | `badgecontent`: a number | `content`: a number or a short text |
|
|
110
|
+
| Attribute | `max`: 9 by default; a count equal to `max` already read `9+` | `max`: 99 by default; only a count above `max` reads `99+` |
|
|
111
|
+
| Attribute | `size`: `small` drew a dot, `medium` a count; with neither nothing sized | `dot`: boolean. A count is the default |
|
|
112
|
+
| Attribute | — | `show-zero`: a count of 0 is hidden without it |
|
|
113
|
+
| Attribute | `color`: `primary \| error \| info \| warning \| success`; no background without it | `color`: the full palette; `primary` by default |
|
|
114
|
+
| Attribute | — | `placement`: `block-start-inline-end` (default) `\| block-start-inline-start \| block-end-inline-end \| block-end-inline-start`; mirrored in RTL |
|
|
115
|
+
| Attribute | — | `label`: what assistive technology reads in place of the bare count |
|
|
116
|
+
| Property | `badgecontent` (number) | `content` (string), `showZero` |
|
|
117
|
+
| Slot | default | default; with nothing slotted the badge sits in the text line |
|
|
118
|
+
| Part | `badge-content` | `badge` |
|
|
119
|
+
| State | — | `standalone` |
|
|
120
|
+
| Custom property | — | `--punica-badge-background`, `--punica-badge-color`, `--punica-badge-size`, `--punica-badge-dot-size` |
|
|
121
|
+
| Formatting | `innerText = count` | `Intl.NumberFormat` in the element's language |
|
|
122
|
+
| Fixed | The template was appended again on every connect | Cloned once |
|
|
123
|
+
|
|
124
|
+
## punica-box
|
|
125
|
+
|
|
126
|
+
`box/box.js`.
|
|
127
|
+
|
|
128
|
+
| | 1.x | 2.0 |
|
|
129
|
+
|---|---|---|
|
|
130
|
+
| Tag | `punica-box` | `punica-box` |
|
|
131
|
+
| Attribute | `border`, `rounded`, `error` | The same |
|
|
132
|
+
| Attribute | `fullwidth`, `fullheight` | `full-width`, `full-height` |
|
|
133
|
+
| Attribute | — | `padding`: a step of the spacing scale (`16` → `--punica-space-16`); anything else is ignored |
|
|
134
|
+
| Property | `fullwidth`, `fullheight` | `fullWidth`, `fullHeight`, `padding` (number) |
|
|
135
|
+
| Slot | default | default |
|
|
136
|
+
| Custom property | `--box-border-radius` | `--punica-box-radius` |
|
|
137
|
+
| Custom property | — | `--punica-box-border-color`, `--punica-box-padding` |
|
|
138
|
+
| Fixed | The template was appended again on every connect | Cloned once |
|
|
139
|
+
|
|
140
|
+
## punica-card
|
|
141
|
+
|
|
142
|
+
`card/card.js`.
|
|
143
|
+
|
|
144
|
+
| | 1.x | 2.0 |
|
|
145
|
+
|---|---|---|
|
|
146
|
+
| Tag | `punica-card` | `punica-card` |
|
|
147
|
+
| Attribute | `rounded` | — ; a card is rounded. `--punica-card-radius: 0` squares it |
|
|
148
|
+
| Attribute | `fullwidth` | — ; a card is `display: block` (1.x was `inline-block`) |
|
|
149
|
+
| Attribute | — | `variant`: `elevated \| outlined \| filled`; `elevated` by default. 1.x had no shadow and no border |
|
|
150
|
+
| Attribute | — | `interactive`: the whole card is one native `<button>` |
|
|
151
|
+
| Attribute | — | `href`, `target`, `rel`: with `interactive`, the card is one native `<a>`. `noopener` is added for `_blank`; a `javascript:` URL is dropped and the card stays a button |
|
|
152
|
+
| Attribute | — | `disabled`: for an interactive card |
|
|
153
|
+
| Attribute | — | `label`: accessible name of an interactive card |
|
|
154
|
+
| Method | — | `focus()`, `click()` reach the inner control of an interactive card |
|
|
155
|
+
| Event | — | none of its own; the native `click` passes through |
|
|
156
|
+
| Slot | default | default |
|
|
157
|
+
| Part | — | `base`: the `div`, `button` or `a` |
|
|
158
|
+
| Custom property | `--card-border-radius` | `--punica-card-radius` |
|
|
159
|
+
| Custom property | `--card-background-color` | `--punica-card-background` |
|
|
160
|
+
| Custom property | — | `--punica-card-shadow`, `--punica-card-border-color` |
|
|
161
|
+
|
|
162
|
+
## punica-card-header
|
|
163
|
+
|
|
164
|
+
`card/cardHeader.js`.
|
|
165
|
+
|
|
166
|
+
| | 1.x | 2.0 |
|
|
167
|
+
|---|---|---|
|
|
168
|
+
| Tag | `punica-card-header` | `punica-card-header` |
|
|
169
|
+
| Slot | default | default: the title |
|
|
170
|
+
| Slot | — | `subtitle`, `start`, `end` |
|
|
171
|
+
| Part | — | `title`, `subtitle` |
|
|
172
|
+
| Custom property | — | `--punica-card-header-padding`, `--punica-card-header-gap` |
|
|
173
|
+
| Layout | A padded block | A row: `start`, title over subtitle, `end` |
|
|
174
|
+
|
|
175
|
+
## punica-card-content
|
|
176
|
+
|
|
177
|
+
`card/cardContent.js`.
|
|
178
|
+
|
|
179
|
+
| | 1.x | 2.0 |
|
|
180
|
+
|---|---|---|
|
|
181
|
+
| Tag | `punica-card-content` | `punica-card-content` |
|
|
182
|
+
| Slot | default | default |
|
|
183
|
+
| Custom property | — | `--punica-card-content-padding` |
|
|
184
|
+
|
|
185
|
+
## punica-card-actions
|
|
186
|
+
|
|
187
|
+
`card/cardActions.js`.
|
|
188
|
+
|
|
189
|
+
| | 1.x | 2.0 |
|
|
190
|
+
|---|---|---|
|
|
191
|
+
| Tag | `punica-card-actions` | `punica-card-actions` |
|
|
192
|
+
| Attribute | — | `align`: `start \| end \| between`; `end` by default, as in 1.x |
|
|
193
|
+
| Slot | default | default |
|
|
194
|
+
| Custom property | — | `--punica-card-actions-padding`, `--punica-card-actions-gap` (8 px; 1.x was 4 px) |
|
|
195
|
+
| Layout | `nowrap` | Wraps |
|
|
196
|
+
|
|
197
|
+
## punica-card-media
|
|
198
|
+
|
|
199
|
+
`card/cardMedia.js`.
|
|
200
|
+
|
|
201
|
+
| | 1.x | 2.0 |
|
|
202
|
+
|---|---|---|
|
|
203
|
+
| Tag | `punica-card-media` | `punica-card-media` |
|
|
204
|
+
| Slot | default: an `<img>` | default: an `<img>`, `<video>` or `<picture>` |
|
|
205
|
+
| Custom property | — | `--punica-card-media-height`, `--punica-card-media-fit` |
|
|
206
|
+
|
|
207
|
+
## punica-chip
|
|
208
|
+
|
|
209
|
+
`chip/chip.js`.
|
|
210
|
+
|
|
211
|
+
| | 1.x | 2.0 |
|
|
212
|
+
|---|---|---|
|
|
213
|
+
| Tag | `punica-chip` | `punica-chip` |
|
|
214
|
+
| Attribute | `color`: `default \| primary \| error \| info \| success \| warning` | `color`: the palette; `default` is now `neutral` |
|
|
215
|
+
| Attribute | `variant`: `filled \| outlined` | The same |
|
|
216
|
+
| Attribute | `size`: `small \| medium` | The same |
|
|
217
|
+
| Attribute | — | `removable`: shows a remove button |
|
|
218
|
+
| Attribute | — | `label-remove`: name of the remove button, read before the chip's text; `Remove` |
|
|
219
|
+
| Attribute | — | `selectable`: the chip is a native toggle button with `aria-pressed` |
|
|
220
|
+
| Attribute | — | `selected` |
|
|
221
|
+
| Attribute | — | `disabled` |
|
|
222
|
+
| Method | — | `focus()` |
|
|
223
|
+
| Event | — | `punica-change`, detail `{ selected }`, when the user toggles a selectable chip |
|
|
224
|
+
| Event | — | `punica-dismiss`, detail `{}`, cancelable, from the remove button or Delete / Backspace on the chip. Unless prevented the chip sets `hidden` on itself |
|
|
225
|
+
| Slot | default | default |
|
|
226
|
+
| Slot | `delete`: your own delete control | — ; use `removable` |
|
|
227
|
+
| Slot | — | `start` |
|
|
228
|
+
| Part | — | `base`, `label`, `remove` |
|
|
229
|
+
| State | — | `selected` |
|
|
230
|
+
| Custom property | — | `--punica-chip-height`, `--punica-chip-padding`, `--punica-chip-radius` |
|
|
231
|
+
| Removed | `size`, `color` and `variant` were written onto the host as attributes on connect | Defaults live in the stylesheet; the host's attributes are yours |
|
|
232
|
+
|
|
233
|
+
## punica-container
|
|
234
|
+
|
|
235
|
+
`container/container.js`.
|
|
236
|
+
|
|
237
|
+
| | 1.x | 2.0 |
|
|
238
|
+
|---|---|---|
|
|
239
|
+
| Tag | `punica-container` | `punica-container` |
|
|
240
|
+
| Attribute | `maxwidth`: `xs \| sm \| md \| lg \| xl`; no limit without it | `max-width`: `sm \| md \| lg \| xl \| full`; `lg` by default. `full` is the old "no attribute" |
|
|
241
|
+
| Attribute | `disablegutters` | `gutters`: `none \| small \| medium \| large`; `medium` by default |
|
|
242
|
+
| Property | `maxwidth`, `disablegutters` | `maxWidth`, `gutters` |
|
|
243
|
+
| Slot | default | default |
|
|
244
|
+
| Custom property | — | `--punica-container-max-width`, `--punica-container-gutter` |
|
|
245
|
+
| Removed | `maxwidth="xs"` (444 px) | `--punica-container-max-width: 444px` |
|
|
246
|
+
| Removed | The limit applied only from its own breakpoint up | It always applies |
|
|
247
|
+
|
|
248
|
+
## punica-divider
|
|
249
|
+
|
|
250
|
+
`divider/divider.js`.
|
|
251
|
+
|
|
252
|
+
| | 1.x | 2.0 |
|
|
253
|
+
|---|---|---|
|
|
254
|
+
| Tag | `punica-divider` | `punica-divider` |
|
|
255
|
+
| Attribute | `orientation`: `horizontal \| vertical`, written onto the host on connect | `orientation`; `horizontal` by default, nothing written |
|
|
256
|
+
| Attribute | `flexItem`: observed in camelCase, so it never fired | — ; `--punica-divider-spacing` is the margin it meant |
|
|
257
|
+
| Attribute | — | `decorative`: `role=presentation` |
|
|
258
|
+
| Attribute | — | `inset`: indents both inline ends |
|
|
259
|
+
| Slot | — | default: a label in the middle of the line |
|
|
260
|
+
| Part | — | `line`, `label` |
|
|
261
|
+
| State | — | `labelled` |
|
|
262
|
+
| Role | none | `separator` with `aria-orientation`, named by the label |
|
|
263
|
+
| Custom property | — | `--punica-divider-color`, `--punica-divider-width`, `--punica-divider-spacing`, `--punica-divider-inset` |
|
|
264
|
+
|
|
265
|
+
## punica-row
|
|
266
|
+
|
|
267
|
+
`grid/row.js` (1.x `grid/gridRow.js`).
|
|
268
|
+
|
|
269
|
+
| | 1.x | 2.0 |
|
|
270
|
+
|---|---|---|
|
|
271
|
+
| Tag | `punica-row` | `punica-row` |
|
|
272
|
+
| Attribute | `spacing`, in units of 8 px | `spacing`: a number 0 to 64, in units of 8 px |
|
|
273
|
+
| Attribute | `rowspacing`, `columnspacing` | `row-spacing`, `column-spacing` |
|
|
274
|
+
| Attribute | `direction`: any `flex-direction` text | `direction`: `row \| row-reverse \| column \| column-reverse` |
|
|
275
|
+
| Attribute | `justifycontent`: any `justify-content` text | `justify`: `start \| center \| end \| between \| around \| evenly` |
|
|
276
|
+
| Attribute | `alignitems`: any `align-items` text | `align`: `start \| center \| end \| stretch \| baseline` |
|
|
277
|
+
| Attribute | `wrap`: any `flex-wrap` text | `wrap`: `wrap \| nowrap \| wrap-reverse`; `wrap` by default |
|
|
278
|
+
| Attribute | `justifyitems`, `aligncontent` | — |
|
|
279
|
+
| Attribute | `fullheight` | `full-height` |
|
|
280
|
+
| Property | lower-case names | `rowSpacing`, `columnSpacing`, `fullHeight` |
|
|
281
|
+
| Slot | default | default |
|
|
282
|
+
| Custom property | `--row-spacing`, `--column-spacing`, `--columns` and five more, written into a `<style>` | `--punica-row-row-gap`, `--punica-row-column-gap`, `--punica-row-columns` |
|
|
283
|
+
| Fixed | Attribute values were interpolated into `<style>` text | Numbers are parsed and range-checked, keywords are matched by attribute selectors |
|
|
284
|
+
| Changed | — | The row is a size container (`container-type: inline-size`): its columns answer to the row's width. In a shrink-to-fit parent give the row an inline size |
|
|
285
|
+
|
|
286
|
+
## punica-col
|
|
287
|
+
|
|
288
|
+
`grid/col.js` (1.x `grid/gridCol.js`).
|
|
289
|
+
|
|
290
|
+
| | 1.x | 2.0 |
|
|
291
|
+
|---|---|---|
|
|
292
|
+
| Tag | `punica-col` | `punica-col` |
|
|
293
|
+
| Attribute | `xs`, `sm`, `md`, `lg`, `xl`: any text, written into a `<style>` | The same names; an integer 1 to 12, anything else is ignored |
|
|
294
|
+
| Attribute | `size` (a getter with no effect) | — |
|
|
295
|
+
| Breakpoints | Viewport media queries at 0 / 600 / 900 / 1200 / 1536 px | Container queries on the row at the same widths |
|
|
296
|
+
| Behaviour | A column with no span had `flex-grow: 0` | It shares the space left on its line |
|
|
297
|
+
| Slot | default | default |
|
|
298
|
+
| Fixed | A new `<style>` per attribute change, built from attribute text | Private custom properties on a sheet of the instance |
|
|
299
|
+
|
|
300
|
+
## punica-hidden
|
|
301
|
+
|
|
302
|
+
`hidden/hidden.js`.
|
|
303
|
+
|
|
304
|
+
| | 1.x | 2.0 |
|
|
305
|
+
|---|---|---|
|
|
306
|
+
| Tag | `punica-hidden` | `punica-hidden` |
|
|
307
|
+
| Attribute | `direction="up"` with `breakPoint` | `above`: hidden from that breakpoint up |
|
|
308
|
+
| Attribute | `direction="down"` with `breakPoint` | `below`: hidden under that breakpoint |
|
|
309
|
+
| Attribute | — | `only`: hidden from that breakpoint to the next |
|
|
310
|
+
| Breakpoints | `xs` 444, `sm` 600, `md` 900, `lg` 1200, `xl` 1536 px | `xs` 0, `sm` 600, `md` 900, `lg` 1200, `xl` 1536 px |
|
|
311
|
+
| Mechanism | A `matchMedia` listener that mounted or emptied the shadow root | Media queries in the stylesheet; the element is `display: contents` or `display: none` |
|
|
312
|
+
| Fixed | `breakPoint` was observed in camelCase and never fired; the media listener was never removed | No listener exists |
|
|
313
|
+
| Changed | The content was removed from the tree | The content stays in the DOM, undrawn and out of the accessibility tree |
|
|
314
|
+
|
|
315
|
+
## punica-icon
|
|
316
|
+
|
|
317
|
+
`icon/icon.js`.
|
|
318
|
+
|
|
319
|
+
| | 1.x | 2.0 |
|
|
320
|
+
|---|---|---|
|
|
321
|
+
| Tag | `punica-icon` | `punica-icon` |
|
|
322
|
+
| Attribute | — | `name`: a glyph of `src/core/icons.js` (`chevronDown`, `chevronUp`, `chevronEnd`, `chevronStart`, `close`, `check`, `minus`, `plus`, `search`, `calendar`, `clock`, `more`, `info`, `warning`, `error`, `success`, `upload`, `copy`). An unknown name draws nothing |
|
|
323
|
+
| Attribute | — | `label`: the icon is `role=img` with that name. Without it the icon is hidden from assistive technology |
|
|
324
|
+
| Attribute | `size`: `xsmall \| small \| medium \| large \| xlarge \| 2xlarge` | The same |
|
|
325
|
+
| Attribute | `color`: `primary` and `secondary` pointed at tokens that did not exist | `color`: the palette |
|
|
326
|
+
| Slot | default: an icon-font element or an SVG | The same; still works |
|
|
327
|
+
| Part | — | `icon`: the SVG of a named glyph |
|
|
328
|
+
| Custom property | — | `--punica-icon-size`, `--punica-icon-color` |
|
|
329
|
+
|
|
330
|
+
## punica-paper
|
|
331
|
+
|
|
332
|
+
`paper/paper.js`.
|
|
333
|
+
|
|
334
|
+
| | 1.x | 2.0 |
|
|
335
|
+
|---|---|---|
|
|
336
|
+
| Tag | `punica-paper` | `punica-paper` |
|
|
337
|
+
| Attribute | `rounded` | `radius`: `none \| small \| medium \| large \| full`; `medium` by default, so a paper is rounded unless `radius="none"` |
|
|
338
|
+
| Attribute | — | `elevation`: 0 to 5, the shadow tokens `xs` to `xl`; 0 by default |
|
|
339
|
+
| Attribute | — | `variant`: `elevated \| outlined` |
|
|
340
|
+
| Attribute | — | `padding`: a step of the spacing scale |
|
|
341
|
+
| Attribute | `class` (observed) | — |
|
|
342
|
+
| Slot | default | default |
|
|
343
|
+
| Custom property | `--paper-border-radius` | `--punica-paper-radius` |
|
|
344
|
+
| Custom property | `--paper-padding` | `--punica-paper-padding` |
|
|
345
|
+
| Custom property | — | `--punica-paper-background`, `--punica-paper-shadow` |
|
|
346
|
+
| Fixed | The template was appended again on every connect | Cloned once |
|
|
347
|
+
|
|
348
|
+
## punica-progress-bar
|
|
349
|
+
|
|
350
|
+
`progressBar/progressBar.js` (1.x `progressLine/progressLine.js`).
|
|
351
|
+
|
|
352
|
+
| | 1.x | 2.0 |
|
|
353
|
+
|---|---|---|
|
|
354
|
+
| Tag | `punica-progress-line` | `punica-progress-bar` |
|
|
355
|
+
| Attribute | — | `value`: 0 to `max`. Without it the bar is indeterminate, which is all 1.x could be |
|
|
356
|
+
| Attribute | — | `max`: 100 by default |
|
|
357
|
+
| Attribute | — | `label`: accessible name |
|
|
358
|
+
| Attribute | `height`: any CSS text, written to `style` | `size`: `small \| medium \| large` (2, 4, 8 px) |
|
|
359
|
+
| Attribute | `color`: any CSS colour, written to `style` | `color`: the palette |
|
|
360
|
+
| Attribute | — | `show-value`: the percentage beside the bar, formatted by `Intl.NumberFormat` in the element's language |
|
|
361
|
+
| Part | — | `track`, `indicator`, `value` |
|
|
362
|
+
| State | — | `indeterminate` |
|
|
363
|
+
| Role | none | `progressbar` with `aria-valuemin`, `-max`, `-now`, `-valuetext` |
|
|
364
|
+
| Custom property | `--progress-height` | `--punica-progress-bar-height` |
|
|
365
|
+
| Custom property | `--progress-color` | `--punica-progress-bar-color` |
|
|
366
|
+
| Custom property | `--progress-bg` | `--punica-progress-bar-track-color` |
|
|
367
|
+
| Custom property | `--indeterminate-duration` | — |
|
|
368
|
+
| Motion | Always sweeps | Under reduced motion a full bar fades in and out |
|
|
369
|
+
| Fixed | The template was appended again on every connect | Cloned once |
|
|
370
|
+
|
|
371
|
+
## punica-qr-code
|
|
372
|
+
|
|
373
|
+
`qrCode/qrCode.js`.
|
|
374
|
+
|
|
375
|
+
| | 1.x | 2.0 |
|
|
376
|
+
|---|---|---|
|
|
377
|
+
| Tag | `punica-qr-code` | `punica-qr-code` |
|
|
378
|
+
| Attribute | `value` | `value`, encoded as UTF-8 |
|
|
379
|
+
| Attribute | `size`: any number | `size`: px, 16 to 4096; 128 by default (1.x 256, which only set a canvas of fixed 232 px) |
|
|
380
|
+
| Attribute | — | `error-correction`: `L \| M \| Q \| H`; `M` by default |
|
|
381
|
+
| Attribute | — | `label`: accessible name; the value itself without it |
|
|
382
|
+
| Attribute | `background`, `foreground`: any CSS colour | — ; custom properties |
|
|
383
|
+
| Export | — | `qrMatrix(text, level)`: the symbol as rows of booleans, or `null` when the text does not fit |
|
|
384
|
+
| Rendering | A `<canvas>` | One SVG `<path>`, sharp at any size |
|
|
385
|
+
| Part | — | `base` |
|
|
386
|
+
| State | — | `empty` |
|
|
387
|
+
| Role | none | `img` |
|
|
388
|
+
| Custom property | — | `--punica-qr-code-size`, `--punica-qr-code-foreground`, `--punica-qr-code-background` |
|
|
389
|
+
| Fixed | **1.x did not encode anything.** It drew three finder patterns and two timing lines on a fixed 21×21 grid whatever the value, so no scanner could read it | A full encoder: byte mode, versions 1 to 40, Reed–Solomon error correction, the eight masks scored by the standard's penalty rules. The test suite reads the output back with the platform `BarcodeDetector` |
|
|
390
|
+
| Fixed | A new canvas was appended on every connect | One SVG |
|
|
391
|
+
|
|
392
|
+
## punica-skeleton
|
|
393
|
+
|
|
394
|
+
`skeleton/skeleton.js`.
|
|
395
|
+
|
|
396
|
+
| | 1.x | 2.0 |
|
|
397
|
+
|---|---|---|
|
|
398
|
+
| Tag | `punica-skeleton` | `punica-skeleton` |
|
|
399
|
+
| Attribute | `variant`: `text \| circular` | `variant`: `text \| circle \| rect`; `text` by default |
|
|
400
|
+
| Attribute | `width`, `height`: any text, written to `style` | `width`, `height`: one CSS length the browser accepts (`CSS.supports('width', v)`); anything else is ignored |
|
|
401
|
+
| Attribute | `rounded` | — ; `--punica-skeleton-radius` |
|
|
402
|
+
| Attribute | — | `lines`: 1 to 50 bars for `text`; the last of several is 60 % wide |
|
|
403
|
+
| Slot | default | — |
|
|
404
|
+
| Part | — | `line` |
|
|
405
|
+
| Accessibility | none | Hidden from assistive technology |
|
|
406
|
+
| Custom property | — | `--punica-skeleton-color`, `--punica-skeleton-radius` |
|
|
407
|
+
| Motion | Always pulses | Still under reduced motion |
|
|
408
|
+
|
|
409
|
+
## punica-toolbar
|
|
410
|
+
|
|
411
|
+
`toolbar/toolbar.js`.
|
|
412
|
+
|
|
413
|
+
| | 1.x | 2.0 |
|
|
414
|
+
|---|---|---|
|
|
415
|
+
| Tag | `punica-toolbar` | `punica-toolbar` |
|
|
416
|
+
| Attribute | `variant`: `dense \| regular` (48, 64 px) | `size`: `small \| medium \| large` (48, 64, 80 px); `medium` by default |
|
|
417
|
+
| Attribute | `disablegutters` | — ; `--punica-toolbar-padding: 0` |
|
|
418
|
+
| Attribute | — | `label`: accessible name |
|
|
419
|
+
| Attribute | — | `orientation`: `horizontal \| vertical` |
|
|
420
|
+
| Slot | default | default, `start`, `end` |
|
|
421
|
+
| Part | — | `content` |
|
|
422
|
+
| Role | `role="div"`, which is not a role | `toolbar`, with `aria-orientation` |
|
|
423
|
+
| Keyboard | none | One tab stop. Arrow keys along the orientation (mirrored in RTL), Home and End move between the enabled controls of all three slots; a text field keeps its own arrow keys |
|
|
424
|
+
| Custom property | — | `--punica-toolbar-size`, `--punica-toolbar-padding`, `--punica-toolbar-gap` |
|
|
425
|
+
| Changed | — | The toolbar sets `tabindex` on its controls (roving tabindex) |
|
|
426
|
+
|
|
427
|
+
## punica-app-bar
|
|
428
|
+
|
|
429
|
+
`appBar/appBar.js`.
|
|
430
|
+
|
|
431
|
+
| | 1.x | 2.0 |
|
|
432
|
+
|---|---|---|
|
|
433
|
+
| Tag | `punica-app-bar` | `punica-app-bar` |
|
|
434
|
+
| Attribute | `position`: `fixed \| absolute \| sticky \| static \| relative`; `fixed` by default | `position`: `static \| sticky \| fixed`; `static` by default |
|
|
435
|
+
| Attribute | `color`: the palette, `transparent`, `inherit`; `primary` by default | `color`: the palette; `primary` by default. `neutral` is the surface colour with a line under it |
|
|
436
|
+
| Slot | default | default, `start`, `end` |
|
|
437
|
+
| Part | — | `content` |
|
|
438
|
+
| Role | `role="header"`, which is not a role | `banner` |
|
|
439
|
+
| Layout | A column | A row: `start`, content (fills), `end` |
|
|
440
|
+
| Stacking | `z-index: 1000` | `--punica-z-sticky` / `--punica-z-fixed` |
|
|
441
|
+
| Custom property | — | `--punica-app-bar-background`, `--punica-app-bar-color`, `--punica-app-bar-shadow`, `--punica-app-bar-padding`, `--punica-app-bar-gap` |
|
|
442
|
+
| Removed | `position="absolute"`, `position="relative"` | Position the host yourself |
|
|
443
|
+
| Removed | `color="transparent"`, `color="inherit"` | `--punica-app-bar-background` |
|
|
444
|
+
| Removed | A fixed bar was pinned to the right edge only (`left: auto; right: 0`) | It spans the inline axis |
|
|
445
|
+
|
|
446
|
+
## punica-heading
|
|
447
|
+
|
|
448
|
+
`heading/heading.js`. Replaces `punica-typography variant="headline1..6"`.
|
|
449
|
+
|
|
450
|
+
| | 1.x (`punica-typography`) | 2.0 |
|
|
451
|
+
|---|---|---|
|
|
452
|
+
| Tag | `punica-typography` | `punica-heading` |
|
|
453
|
+
| Attribute | `variant="headline1"` … `headline6` set both the size and `aria-level` | `level`: 1 to 6, the rank in the outline; 2 by default and for anything else |
|
|
454
|
+
| Attribute | — | `size`: `xsmall \| small \| medium \| large \| xlarge \| 2xlarge`, independent of the level. Unset, it follows the level: 34, 24, 20, 18, 16, 14 px |
|
|
455
|
+
| Attribute | `truncate="N"` | `truncate`: boolean, one line with an ellipsis |
|
|
456
|
+
| Attribute | `textalign`: `left \| right \| center \| justify` | `align`: `start \| center \| end \| justify` |
|
|
457
|
+
| Attribute | `fontweight`, `whitespace`, `color` | — ; `--punica-heading-font-weight`, `--punica-heading-color` |
|
|
458
|
+
| Slot | default | default |
|
|
459
|
+
| Role | `role` and `aria-level` attributes written on connect, never updated | `heading` and the level through internals, kept in step |
|
|
460
|
+
| Custom property | — | `--punica-heading-font-size`, `--punica-heading-font-weight`, `--punica-heading-line-height`, `--punica-heading-color` |
|
|
461
|
+
| Changed | `headline1` was 6rem, `headline2` 3.75rem, `headline3` 3rem | The scale tops out at 2.125rem; set `--punica-heading-font-size` for display type |
|
|
462
|
+
|
|
463
|
+
## punica-text
|
|
464
|
+
|
|
465
|
+
`text/text.js`. Replaces the other variants of `punica-typography`.
|
|
466
|
+
|
|
467
|
+
| | 1.x (`punica-typography`) | 2.0 |
|
|
468
|
+
|---|---|---|
|
|
469
|
+
| Tag | `punica-typography` | `punica-text` |
|
|
470
|
+
| Attribute | `variant`: `subtitle1 \| subtitle2 \| body1 \| body2 \| button \| caption \| overline`, `body1` written onto the host on connect | `variant`: `body \| caption \| label \| overline \| code`; `body` by default, nothing written |
|
|
471
|
+
| Attribute | — | `size`: `small \| medium \| large`; `body2` and `subtitle2` are `size="small"` |
|
|
472
|
+
| Attribute | `fontweight`: `thin \| regular \| medium \| semi-bold \| bold \| extra-bold` | `weight`: the same plus `light` |
|
|
473
|
+
| Attribute | `textalign`: `left \| right \| center \| justify` | `align`: `start \| center \| end \| justify` |
|
|
474
|
+
| Attribute | `color`: a palette name or any CSS colour, written to `style` | `color`: the palette plus `muted`; inherited by default |
|
|
475
|
+
| Attribute | `truncate="N"`, written into a `<style>` on connect and never updated | `truncate`: lines before the ellipsis, an integer 1 to 99; the bare attribute is one line. Anything else is ignored |
|
|
476
|
+
| Attribute | `whitespace` | — ; set `white-space` on the host |
|
|
477
|
+
| Attribute | — | `block`: lays out as a block. 1.x body text was always a block; 2.0 text is inline unless `block`, `align` or `truncate` is set |
|
|
478
|
+
| Slot | default | default |
|
|
479
|
+
| State | — | `truncated` |
|
|
480
|
+
| Custom property | — | `--punica-text-font-size`, `--punica-text-line-height` |
|
|
481
|
+
| Removed | `variant="button"` | `variant="label"`, or a `punica-button` |
|
|
482
|
+
| Fixed | `truncate` went into a style string as it was | It is parsed to an integer and set through the CSSOM |
|
|
483
|
+
| Fixed | The template was appended again on every connect | Cloned once |
|
|
484
|
+
|
|
485
|
+
---
|
|
486
|
+
|
|
487
|
+
## New elements
|
|
488
|
+
|
|
489
|
+
### punica-spinner
|
|
490
|
+
|
|
491
|
+
`spinner/spinner.js`.
|
|
492
|
+
|
|
493
|
+
| | 2.0 |
|
|
494
|
+
|---|---|
|
|
495
|
+
| Attribute | `size`: `small \| medium \| large` (16, 24, 40 px) |
|
|
496
|
+
| Attribute | `color`: the palette; `primary` by default |
|
|
497
|
+
| Attribute | `label`: accessible name, `Loading` by default |
|
|
498
|
+
| Attribute | `decorative`: hidden from assistive technology |
|
|
499
|
+
| Part | `base` |
|
|
500
|
+
| Role | `progressbar` with no value, named by `label` |
|
|
501
|
+
| Custom property | `--punica-spinner-size`, `--punica-spinner-color`, `--punica-spinner-track-color`, `--punica-spinner-width` |
|
|
502
|
+
| Motion | Under reduced motion the ring stands still and fades in and out |
|
|
503
|
+
|
|
504
|
+
### punica-link
|
|
505
|
+
|
|
506
|
+
`link/link.js`. A native `<a part="base">` in the shadow root, with
|
|
507
|
+
`delegatesFocus`.
|
|
508
|
+
|
|
509
|
+
| | 2.0 |
|
|
510
|
+
|---|---|
|
|
511
|
+
| Attribute | `href`. A `javascript:` or `vbscript:` URL is dropped |
|
|
512
|
+
| Attribute | `target`, `download`, as on `<a>` |
|
|
513
|
+
| Attribute | `rel`; `noopener` is added for `target="_blank"` |
|
|
514
|
+
| Attribute | `variant`: `default \| subtle` (the surrounding text colour) |
|
|
515
|
+
| Attribute | `color`: the palette; `primary` by default |
|
|
516
|
+
| Attribute | `underline`: `always \| hover \| none`; `always` by default |
|
|
517
|
+
| Attribute | `external`: an icon after the text and a visually hidden text |
|
|
518
|
+
| Attribute | `label-external`: that text, `external link` by default |
|
|
519
|
+
| Attribute | `disabled`: no `href`, `aria-disabled="true"`, out of the tab order |
|
|
520
|
+
| Attribute | `label`: accessible name, for a link with no text |
|
|
521
|
+
| Method | `focus()`, `click()` |
|
|
522
|
+
| Event | none of its own; the native `click` passes through |
|
|
523
|
+
| Slot | default |
|
|
524
|
+
| Part | `base`, `external-icon` |
|
|
525
|
+
| Custom property | `--punica-link-color`, `--punica-link-color-hover` |
|
|
526
|
+
|
|
527
|
+
### punica-kbd
|
|
528
|
+
|
|
529
|
+
`kbd/kbd.js`. A native `<kbd>` holding one `<kbd>` per key.
|
|
530
|
+
|
|
531
|
+
| | 2.0 |
|
|
532
|
+
|---|---|
|
|
533
|
+
| Attribute | `keys`: keys joined by `+` (`Mod+Shift+K`). `Mod` is ⌘ on Apple platforms and `label-mod` elsewhere; a trailing `++` is the plus key |
|
|
534
|
+
| Attribute | `label-mod`: what `Mod` reads as off Apple platforms, `Ctrl` by default |
|
|
535
|
+
| Slot | default: one key, when `keys` is not set |
|
|
536
|
+
| Part | `base`, `key` |
|
|
537
|
+
| Custom property | `--punica-kbd-background`, `--punica-kbd-border-color`, `--punica-kbd-radius` |
|
|
538
|
+
| Platform | Read from `navigator.userAgentData?.platform \|\| navigator.platform` on every connect |
|
|
539
|
+
|
|
540
|
+
### punica-status-dot
|
|
541
|
+
|
|
542
|
+
`statusDot/statusDot.js`.
|
|
543
|
+
|
|
544
|
+
| | 2.0 |
|
|
545
|
+
|---|---|
|
|
546
|
+
| Attribute | `color`: the palette; `neutral` by default |
|
|
547
|
+
| Attribute | `pulse`: a ring pulses around the disc; still under reduced motion |
|
|
548
|
+
| Attribute | `label`: the dot is `role=img` with that name. Without it the dot is hidden from assistive technology |
|
|
549
|
+
| Part | `base` |
|
|
550
|
+
| Custom property | `--punica-status-dot-size` (6 px), `--punica-status-dot-color` |
|
|
551
|
+
|
|
552
|
+
### punica-empty-state
|
|
553
|
+
|
|
554
|
+
`emptyState/emptyState.js`.
|
|
555
|
+
|
|
556
|
+
| | 2.0 |
|
|
557
|
+
|---|---|
|
|
558
|
+
| Attribute | `heading`: the one line that says what is missing |
|
|
559
|
+
| Attribute | `heading-level`: 1 to 6; 3 by default |
|
|
560
|
+
| Attribute | `size`: `panel \| section`; `panel` fills and centres in its container, `section` is compact |
|
|
561
|
+
| Slot | default: the description |
|
|
562
|
+
| Slot | `icon`, `actions` |
|
|
563
|
+
| Part | `icon`, `heading`, `description`, `actions` |
|
|
564
|
+
| Custom property | `--punica-empty-state-padding`, `--punica-empty-state-gap`, `--punica-empty-state-max-width`, `--punica-empty-state-icon-size` |
|
|
565
|
+
|
|
566
|
+
### punica-visually-hidden
|
|
567
|
+
|
|
568
|
+
`visuallyHidden/visuallyHidden.js`.
|
|
569
|
+
|
|
570
|
+
| | 2.0 |
|
|
571
|
+
|---|---|
|
|
572
|
+
| Attribute | `focusable`: the content shows while focus is inside it, for a skip link |
|
|
573
|
+
| Slot | default |
|
|
574
|
+
|
|
575
|
+
### punica-aspect-ratio
|
|
576
|
+
|
|
577
|
+
`aspectRatio/aspectRatio.js`.
|
|
578
|
+
|
|
579
|
+
| | 2.0 |
|
|
580
|
+
|---|---|
|
|
581
|
+
| Attribute | `ratio`: `inline/block` as two positive numbers (`16/9`), or one number; `1/1` by default and for anything else |
|
|
582
|
+
| Slot | default; the content fills the box |
|
|
583
|
+
| Custom property | `--punica-aspect-ratio-fit`: `object-fit` of the content, `cover` |
|
|
584
|
+
|
|
585
|
+
### punica-stack
|
|
586
|
+
|
|
587
|
+
`stack/stack.js`.
|
|
588
|
+
|
|
589
|
+
| | 2.0 |
|
|
590
|
+
|---|---|
|
|
591
|
+
| Attribute | `direction`: `vertical \| horizontal`; `vertical` by default |
|
|
592
|
+
| Attribute | `gap`: a step of the spacing scale (`16` → `--punica-space-16`); 8 by default, anything off the scale is ignored |
|
|
593
|
+
| Attribute | `align`: `start \| center \| end \| stretch \| baseline` |
|
|
594
|
+
| Attribute | `justify`: `start \| center \| end \| between \| around \| evenly` |
|
|
595
|
+
| Attribute | `wrap`: boolean |
|
|
596
|
+
| Attribute | `divider`: a line between children |
|
|
597
|
+
| Slot | default |
|
|
598
|
+
| Custom property | `--punica-stack-gap`, `--punica-stack-divider-color` |
|
|
599
|
+
|
|
600
|
+
### punica-center
|
|
601
|
+
|
|
602
|
+
`center/center.js`.
|
|
603
|
+
|
|
604
|
+
| | 2.0 |
|
|
605
|
+
|---|---|
|
|
606
|
+
| Attribute | `axis`: `both \| inline \| block`; `both` by default |
|
|
607
|
+
| Attribute | `inline`: an inline box as wide as its content |
|
|
608
|
+
| Slot | default |
|
|
609
|
+
|
|
610
|
+
### punica-scroll-area
|
|
611
|
+
|
|
612
|
+
`scrollArea/scrollArea.js`. Give the element a `block-size` or
|
|
613
|
+
`max-block-size` (an `inline-size` when horizontal) to scroll within.
|
|
614
|
+
|
|
615
|
+
| | 2.0 |
|
|
616
|
+
|---|---|
|
|
617
|
+
| Attribute | `orientation`: `vertical \| horizontal \| both`; `vertical` by default |
|
|
618
|
+
| Attribute | `label`: accessible name; the scrolling box is then `role=region` |
|
|
619
|
+
| Property | `viewport` (read-only): the scrolling box, for `scrollTo()` and scroll listeners |
|
|
620
|
+
| Slot | default |
|
|
621
|
+
| Part | `viewport`, `shadow-start`, `shadow-end` |
|
|
622
|
+
| State | `scrollable`, `scroll-start`, `scroll-end` |
|
|
623
|
+
| Keyboard | While the content overflows and holds nothing focusable, the viewport has `tabindex="0"` so arrow keys and Page Up / Down scroll it |
|
|
624
|
+
| Custom property | `--punica-scroll-area-shadow-size`, `--punica-scroll-area-shadow-color`, `--punica-scroll-area-thumb-color` |
|
|
625
|
+
| Shadows | Scroll-driven animations where the browser has them (`animation-timeline` and `timeline-scope`); elsewhere the states above drive them. With `orientation="both"` only the block axis has shadows |
|