@12-apps/ui 6.19.1 → 6.20.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/NATIVE.md +6 -1
- package/dist/_internal/components/data-display/AsyncStateContainer/AsyncStateContainer.js +8 -7
- package/dist/_internal/components/data-display/Avatar/Avatar.base.js +1 -0
- package/dist/_internal/components/data-display/Avatar/Avatar.base.js.map +1 -0
- package/dist/_internal/components/data-display/Avatar/Avatar.helpers.js +14 -0
- package/dist/_internal/components/data-display/Avatar/Avatar.helpers.js.map +1 -0
- package/dist/_internal/components/data-display/Avatar/Avatar.js +8 -2
- package/dist/_internal/components/data-display/Avatar/Avatar.metrics.js +52 -0
- package/dist/_internal/components/data-display/Avatar/Avatar.metrics.js.map +1 -0
- package/dist/_internal/components/data-display/Avatar/Avatar.view.js +6 -1
- package/dist/_internal/components/data-display/Badge/Badge.animations.js +6 -1
- package/dist/_internal/components/data-display/Badge/Badge.base.js +1 -0
- package/dist/_internal/components/data-display/Badge/Badge.base.js.map +1 -0
- package/dist/_internal/components/data-display/Badge/Badge.helpers.js +3 -1
- package/dist/_internal/components/data-display/Badge/Badge.js +12 -6
- package/dist/_internal/components/data-display/Badge/Badge.metrics.js +64 -0
- package/dist/_internal/components/data-display/Badge/Badge.metrics.js.map +1 -0
- package/dist/_internal/components/data-display/Badge/Badge.styles.js +8 -3
- package/dist/_internal/components/data-display/Badge/Badge.variants.js +6 -1
- package/dist/_internal/components/data-display/Badge/BadgeContent.js +9 -4
- package/dist/_internal/components/data-display/CardKit/CardKebab.js +3 -3
- package/dist/_internal/components/data-display/CardKit/use-remove-confirm.js +4 -4
- package/dist/_internal/components/data-display/CardKit/use-row-confirm.js +4 -4
- package/dist/_internal/components/data-display/Carousel/Carousel.js +2 -2
- package/dist/_internal/components/data-display/Chart/Chart.js +3 -3
- package/dist/_internal/components/data-display/Chart/SpecChart.js +6 -6
- package/dist/_internal/components/data-display/Chart/chart-renderers.js +2 -2
- package/dist/_internal/components/data-display/Chart/chart-spec.js +2 -2
- package/dist/_internal/components/data-display/Chip/Chip.base.js +1 -0
- package/dist/_internal/components/data-display/Chip/Chip.base.js.map +1 -0
- package/dist/_internal/components/data-display/Chip/Chip.helpers.js +3 -9
- package/dist/_internal/components/data-display/Chip/Chip.js +4 -2
- package/dist/_internal/components/data-display/Chip/Chip.metrics.js +32 -0
- package/dist/_internal/components/data-display/Chip/Chip.metrics.js.map +1 -0
- package/dist/_internal/components/data-display/Chip/Chip.styles.js +16 -0
- package/dist/_internal/components/data-display/Chip/Chip.styles.js.map +1 -0
- package/dist/_internal/components/data-display/DataGrid/DataGrid.js +3 -3
- package/dist/_internal/components/data-display/DataViews/DataViewsGrid.js +43 -43
- package/dist/_internal/components/data-display/DataViews/DataViewsTableBase.js +54 -54
- package/dist/_internal/components/data-display/DataViews/DeleteViewDialog.js +3 -3
- package/dist/_internal/components/data-display/DataViews/ManageViewsDialog.js +5 -5
- package/dist/_internal/components/data-display/DataViews/SaveViewModal.js +5 -5
- package/dist/_internal/components/data-display/DataViews/base-card.js +4 -3
- package/dist/_internal/components/data-display/DataViews/base-list-card-geometry.js +5 -4
- package/dist/_internal/components/data-display/DataViews/base-list-card-slots.js +1 -1
- package/dist/_internal/components/data-display/DataViews/base-list-card.js +7 -6
- package/dist/_internal/components/data-display/DataViews/card-surface.js +7 -2
- package/dist/_internal/components/data-display/DataViews/data-views-category-pill.js +15 -15
- package/dist/_internal/components/data-display/DataViews/data-views-columns.js +4 -4
- package/dist/_internal/components/data-display/DataViews/data-views-display-panel.js +4 -4
- package/dist/_internal/components/data-display/DataViews/data-views-empty.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-export.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-filter-panel.js +16 -16
- package/dist/_internal/components/data-display/DataViews/data-views-grid-bodies.js +9 -9
- package/dist/_internal/components/data-display/DataViews/data-views-grid-helpers.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-grid-parts.js +40 -40
- package/dist/_internal/components/data-display/DataViews/data-views-inline-bar.js +20 -20
- package/dist/_internal/components/data-display/DataViews/data-views-more-fields.js +4 -4
- package/dist/_internal/components/data-display/DataViews/data-views-more-filters.js +7 -7
- package/dist/_internal/components/data-display/DataViews/data-views-pagination.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-select-all-strip.js +3 -3
- package/dist/_internal/components/data-display/DataViews/data-views-shell-toolbar.js +12 -12
- package/dist/_internal/components/data-display/DataViews/data-views-table-parts.js +13 -13
- package/dist/_internal/components/data-display/DataViews/data-views-toolbar.js +11 -11
- package/dist/_internal/components/data-display/DataViews/data-views-view-nav.js +3 -3
- package/dist/_internal/components/data-display/DataViews/list-card-rails.js +1 -1
- package/dist/_internal/components/data-display/DataViews/use-data-views-state.js +6 -6
- package/dist/_internal/components/data-display/DataViews/use-saved-views-controller.js +2 -2
- package/dist/_internal/components/data-display/EmptyState/EmptyState.js +2 -2
- package/dist/_internal/components/data-display/HoverCard/HoverCard.js +3 -3
- package/dist/_internal/components/data-display/LazyImage/LazyImage.js +6 -4
- package/dist/_internal/components/data-display/Lightbox/Lightbox.js +5 -5
- package/dist/_internal/components/data-display/LoadingState/LoadingState.js +5 -4
- package/dist/_internal/components/data-display/MapPreview/MapLayers.js +2 -2
- package/dist/_internal/components/data-display/MapPreview/MapPreview.js +4 -4
- package/dist/_internal/components/data-display/Progress/Progress.base.js +1 -0
- package/dist/_internal/components/data-display/Progress/Progress.base.js.map +1 -0
- package/dist/_internal/components/data-display/Progress/Progress.helpers.js +5 -1
- package/dist/_internal/components/data-display/Progress/Progress.js +8 -3
- package/dist/_internal/components/data-display/Progress/Progress.metrics.js +52 -0
- package/dist/_internal/components/data-display/Progress/Progress.metrics.js.map +1 -0
- package/dist/_internal/components/data-display/Progress/Progress.styles.js +6 -1
- package/dist/_internal/components/data-display/SectionOnboarding/SectionOnboarding.js +3 -3
- package/dist/_internal/components/data-display/Sheet/Sheet.js +2 -2
- package/dist/_internal/components/data-display/StatCard/StatCard.js +6 -4
- package/dist/_internal/components/data-display/Table/Table.js +3 -3
- package/dist/_internal/components/data-display/index.js +63 -56
- package/dist/_internal/components/feedback/ConfirmAction/ConfirmButton.js +3 -3
- package/dist/_internal/components/feedback/TutorialOverlay/TutorialOverlay.js +2 -2
- package/dist/_internal/components/feedback/index.js +8 -8
- package/dist/_internal/components/form/AddressAutocomplete/AddressAutocomplete.hooks.js +3 -3
- package/dist/_internal/components/form/AddressAutocomplete/AddressAutocomplete.js +7 -7
- package/dist/_internal/components/form/AddressAutocomplete/AddressAutocompleteField.js +3 -3
- package/dist/_internal/components/form/Autocomplete/Autocomplete.js +2 -2
- package/dist/_internal/components/form/Button/Button.js +2 -2
- package/dist/_internal/components/form/Calendar/Calendar.js +4 -4
- package/dist/_internal/components/form/Calendar/CalendarDayCell.js +2 -2
- package/dist/_internal/components/form/Calendar/CalendarMonth.js +3 -3
- package/dist/_internal/components/form/CategorySelect/CategoryPanel.js +5 -5
- package/dist/_internal/components/form/CategorySelect/CategoryPanelList.js +3 -3
- package/dist/_internal/components/form/CategorySelect/CategoryRows.js +2 -2
- package/dist/_internal/components/form/CategorySelect/CategorySelect.js +10 -10
- package/dist/_internal/components/form/CepField/CepField.js +3 -3
- package/dist/_internal/components/form/CodeEditor/CodeEditor.js +3 -3
- package/dist/_internal/components/form/DateRangePicker/DateRangePicker.js +7 -7
- package/dist/_internal/components/form/Input/Input.js +2 -2
- package/dist/_internal/components/form/Menubar/Menubar.js +2 -2
- package/dist/_internal/components/form/RichTextEditor/RichTextEditor.js +2 -2
- package/dist/_internal/components/form/index.js +28 -28
- package/dist/_internal/components/form/total-form/Fields/CategoryField.js +11 -11
- package/dist/_internal/components/form/total-form/Fields/CepField.js +4 -4
- package/dist/_internal/components/form/total-form/Fields/TextField.js +3 -3
- package/dist/_internal/components/form/total-form/Fields/index.js +21 -21
- package/dist/_internal/components/form/total-form/SubmitButton.js +3 -3
- package/dist/_internal/components/index.js +123 -116
- package/dist/_internal/components/layout/ScrollArea/ScrollArea.js +2 -2
- package/dist/_internal/components/layout/SettingsLayout/SettingsLayout.js +4 -4
- package/dist/_internal/components/layout/SettingsLayout/SettingsPanel.js +2 -2
- package/dist/_internal/components/layout/Skeleton/Skeleton.base.js +1 -0
- package/dist/_internal/components/layout/Skeleton/Skeleton.base.js.map +1 -0
- package/dist/_internal/components/layout/Skeleton/Skeleton.helpers.js +5 -3
- package/dist/_internal/components/layout/Skeleton/Skeleton.js +5 -3
- package/dist/_internal/components/layout/Skeleton/Skeleton.metrics.js +36 -0
- package/dist/_internal/components/layout/Skeleton/Skeleton.metrics.js.map +1 -0
- package/dist/_internal/components/layout/Skeleton/Skeleton.styles.js +2 -1
- package/dist/_internal/components/layout/index.js +16 -15
- package/dist/_internal/components/navigation/AppHeader/AppHeader.details.js +5 -5
- package/dist/_internal/components/navigation/NavigationMenu/NavigationMegaSection.js +2 -2
- package/dist/_internal/components/navigation/NavigationMenu/NavigationMenu.js +4 -4
- package/dist/_internal/components/navigation/NavigationMenu/NavigationStandardBody.js +2 -2
- package/dist/_internal/components/navigation/Pagination/Pagination.js +2 -2
- package/dist/_internal/components/navigation/Tabs/Tabs.js +2 -2
- package/dist/_internal/components/navigation/index.js +16 -16
- package/dist/_internal/components/utility/InstallPrompt/InstallPrompt.js +2 -2
- package/dist/_internal/components/utility/index.js +2 -2
- package/dist/_internal/icons/Icon.js +2 -2
- package/dist/_internal/icons/paths.generated.js +1 -1
- package/dist/_internal/platform/animation.js +31 -0
- package/dist/_internal/platform/animation.js.map +1 -0
- package/dist/_internal/platform/web-keys.js +10 -0
- package/dist/_internal/platform/web-keys.js.map +1 -0
- package/dist/_internal/social-login-button/social-login-button.js +3 -3
- package/dist/_internal/tokens/mui-type.js +2 -1
- package/dist/_internal/tokens/mui-type.js.map +1 -1
- package/dist/_internal/user-avatar/user-avatar.js +7 -5
- package/dist/charts.js +11 -11
- package/dist/{chunk-P7FQUGED.js → chunk-23FCBIUN.js} +8 -8
- package/dist/{chunk-SL4NFGOL.js → chunk-24BUCMQA.js} +4 -4
- package/dist/{chunk-4SXZSSVV.js → chunk-2EKALM6P.js} +3 -3
- package/dist/{chunk-ZRFRU545.js → chunk-2ZDTGI5V.js} +7 -7
- package/dist/{chunk-HR7YTBR7.js → chunk-3AOOI2NR.js} +4 -4
- package/dist/chunk-3ZVUNSFF.js +32 -0
- package/dist/chunk-3ZVUNSFF.js.map +1 -0
- package/dist/{chunk-KKYW3LU7.js → chunk-47UD6DZ4.js} +2 -2
- package/dist/{chunk-ZOUWHGV3.js → chunk-4MGFUPQT.js} +4 -4
- package/dist/{chunk-LYNJJV2X.js → chunk-4SQFO4GW.js} +58 -40
- package/dist/chunk-4SQFO4GW.js.map +1 -0
- package/dist/{chunk-4FRZDSRD.js → chunk-4WK2RTVY.js} +3 -3
- package/dist/{chunk-HAFE43QJ.js → chunk-5JEOLUWJ.js} +6 -2
- package/dist/chunk-5JEOLUWJ.js.map +1 -0
- package/dist/{chunk-LDE4ELB5.js → chunk-5ZF3VASA.js} +7 -7
- package/dist/{chunk-JE6RZ5L6.js → chunk-5ZOJLYD2.js} +4 -4
- package/dist/{chunk-MMZAGB64.js → chunk-6C5D6O3D.js} +4 -2
- package/dist/chunk-6C5D6O3D.js.map +1 -0
- package/dist/{chunk-E5ZHW4I5.js → chunk-6IUTT6BK.js} +3 -3
- package/dist/{chunk-WPR2HS5B.js → chunk-74EZ565M.js} +8 -8
- package/dist/{chunk-BVZVH3ZN.js → chunk-74OZ5KVR.js} +5 -5
- package/dist/{chunk-PMS3H3OO.js → chunk-76GZ55IC.js} +7 -7
- package/dist/{chunk-QIV73V2X.js → chunk-7BYFC2MR.js} +36 -28
- package/dist/chunk-7BYFC2MR.js.map +1 -0
- package/dist/{chunk-DLFOEXUP.js → chunk-7EESF76V.js} +2 -2
- package/dist/{chunk-HKZHEK3Z.js → chunk-7JWXLDRH.js} +3 -3
- package/dist/{chunk-OR7UH2ZQ.js → chunk-7P2HZLEG.js} +3 -3
- package/dist/{chunk-6DXYCXH4.js → chunk-7RZ4WOQW.js} +2 -2
- package/dist/{chunk-EMNGIYH6.js → chunk-7TZ6OC5T.js} +5 -5
- package/dist/{chunk-HXYXDQ7U.js → chunk-7WDPC46N.js} +4 -2
- package/dist/chunk-7WDPC46N.js.map +1 -0
- package/dist/{chunk-CDJPDZCA.js → chunk-AEGX66N7.js} +2 -2
- package/dist/{chunk-65DLYC4S.js → chunk-AVGTTWTE.js} +4 -4
- package/dist/{chunk-C6XESZ3R.js → chunk-B2A4DG77.js} +6 -6
- package/dist/{chunk-VOOPGAQO.js → chunk-B7BZAIHL.js} +2 -2
- package/dist/{chunk-DZN3JF5E.js → chunk-BBC4KT5G.js} +4 -4
- package/dist/chunk-BF4FYOAR.js +23 -0
- package/dist/chunk-BF4FYOAR.js.map +1 -0
- package/dist/{chunk-FWCUELBU.js → chunk-BILE3A7F.js} +2 -2
- package/dist/{chunk-UEJQQVP2.js → chunk-BLT5ZBVL.js} +4 -4
- package/dist/chunk-BRMGHMYB.js +45 -0
- package/dist/chunk-BRMGHMYB.js.map +1 -0
- package/dist/{chunk-ISSJNFJV.js → chunk-C52BELLW.js} +2 -2
- package/dist/{chunk-BPYPUEM5.js → chunk-CZJLWCEG.js} +2 -2
- package/dist/{chunk-WZUNBSS7.js → chunk-DVUPIVI2.js} +4 -4
- package/dist/chunk-E46PG577.js +78 -0
- package/dist/chunk-E46PG577.js.map +1 -0
- package/dist/{chunk-L6KEVPXN.js → chunk-E4FGKZID.js} +20 -9
- package/dist/chunk-E4FGKZID.js.map +1 -0
- package/dist/{chunk-EXJBPKGW.js → chunk-EGRFMPGD.js} +4 -4
- package/dist/{chunk-XFUNJYFT.js → chunk-EPNUVSNK.js} +7 -7
- package/dist/{chunk-H2EQVMU3.js → chunk-EX3PSZLV.js} +2 -2
- package/dist/{chunk-4Q7HWRR2.js → chunk-EZSEAYYT.js} +52 -72
- package/dist/chunk-EZSEAYYT.js.map +1 -0
- package/dist/{chunk-LIOVN5IM.js → chunk-F2DOTCF3.js} +2 -2
- package/dist/chunk-FAITHWIO.js +73 -0
- package/dist/chunk-FAITHWIO.js.map +1 -0
- package/dist/{chunk-64IEKEMQ.js → chunk-FGLV6BXQ.js} +4 -4
- package/dist/{chunk-L65LF6LN.js → chunk-FP4R47TM.js} +2 -2
- package/dist/{chunk-NQHOHQCY.js → chunk-FPWB5ILF.js} +16 -8
- package/dist/chunk-FPWB5ILF.js.map +1 -0
- package/dist/{chunk-7AR2R7TV.js → chunk-G5ZVD5IJ.js} +4 -4
- package/dist/{chunk-SHQWIDD5.js → chunk-GJQYM3PM.js} +4 -4
- package/dist/{chunk-7WL24VNI.js → chunk-HDNK7BAX.js} +5 -5
- package/dist/{chunk-X5MPHXG5.js → chunk-HEG7JIBM.js} +4 -4
- package/dist/{chunk-HKFMPEXJ.js → chunk-HI2OFZSZ.js} +17 -10
- package/dist/chunk-HI2OFZSZ.js.map +1 -0
- package/dist/{chunk-ZIOCRSHU.js → chunk-HSAH5QUQ.js} +3 -3
- package/dist/{chunk-B443IIQG.js → chunk-IE7ISTLQ.js} +4 -4
- package/dist/{chunk-NFHS77NE.js → chunk-IH4CX43Q.js} +2 -2
- package/dist/{chunk-72UYVJBQ.js → chunk-IJIT5HQP.js} +2 -2
- package/dist/{chunk-KPQAPQH6.js → chunk-J2KSG754.js} +10 -8
- package/dist/chunk-J2KSG754.js.map +1 -0
- package/dist/{chunk-AP4FLCLA.js → chunk-J54WH74M.js} +4 -4
- package/dist/{chunk-5HOJSVQH.js → chunk-JB7JE4QZ.js} +2 -2
- package/dist/{chunk-QJJUTBKZ.js → chunk-KQ74QU55.js} +2 -2
- package/dist/chunk-KU6VHNRV.js +68 -0
- package/dist/chunk-KU6VHNRV.js.map +1 -0
- package/dist/chunk-KVEHH4SA.js +85 -0
- package/dist/chunk-KVEHH4SA.js.map +1 -0
- package/dist/{chunk-YLDS5FOQ.js → chunk-KZSKI2R3.js} +2 -2
- package/dist/{chunk-IIOEQRXX.js → chunk-LAHDFBDE.js} +2 -2
- package/dist/{chunk-BUDXR3EV.js → chunk-LKVIZNUM.js} +5 -5
- package/dist/{chunk-OAXAF4VY.js → chunk-LMJBINWN.js} +12 -12
- package/dist/{chunk-SFAP5EH5.js → chunk-LUMF63BM.js} +4 -4
- package/dist/{chunk-KADJNWTQ.js → chunk-LZRURORY.js} +3 -3
- package/dist/{chunk-CLNTJM3F.js → chunk-M7OHXNLF.js} +2 -2
- package/dist/{chunk-UXQW6ZIN.js → chunk-MBYO2F4Y.js} +5 -5
- package/dist/{chunk-ZHEJLUCX.js → chunk-MHV5Y5MR.js} +30 -17
- package/dist/chunk-MHV5Y5MR.js.map +1 -0
- package/dist/{chunk-MCRIT46W.js → chunk-MY5VNNSP.js} +4 -4
- package/dist/{chunk-XELVDPKL.js → chunk-NFAKRI4S.js} +4 -4
- package/dist/{chunk-KSF7TLXH.js → chunk-NHSMLVNC.js} +6 -6
- package/dist/{chunk-ES2RN7YV.js → chunk-NRUYYGDZ.js} +2 -2
- package/dist/{chunk-ZGEBIC5X.js → chunk-OLVZ6TOV.js} +13 -9
- package/dist/chunk-OLVZ6TOV.js.map +1 -0
- package/dist/{chunk-MQUU2XZB.js → chunk-OQFSYMHJ.js} +2 -2
- package/dist/{chunk-M3RIC6JI.js → chunk-OQXOYHIV.js} +4 -4
- package/dist/{chunk-PC3ZFERM.js → chunk-PC5FFEIY.js} +2 -2
- package/dist/{chunk-SOHDPFOB.js → chunk-PHCSPHDH.js} +2 -2
- package/dist/{chunk-OZWQNFG6.js → chunk-PODGTNXS.js} +3 -3
- package/dist/{chunk-IPE5FFFD.js → chunk-PUBPZOQJ.js} +2 -2
- package/dist/{chunk-GBFGZJB5.js → chunk-Q4NOI2CR.js} +5 -5
- package/dist/{chunk-IRDGC7FK.js → chunk-QZWKC3AP.js} +13 -7
- package/dist/chunk-QZWKC3AP.js.map +1 -0
- package/dist/{chunk-GOWBYHYW.js → chunk-R6SBP5M5.js} +4 -4
- package/dist/{chunk-DTKMBI7B.js → chunk-R7MX5KPJ.js} +4 -4
- package/dist/{chunk-NECUCG2S.js → chunk-RQDN4BN5.js} +14 -14
- package/dist/{chunk-5SYD23V4.js → chunk-SKZHOWTS.js} +4 -4
- package/dist/{chunk-Y6KPZQPI.js → chunk-SOCKK67R.js} +4 -4
- package/dist/{chunk-GCJLMX63.js → chunk-VCTKJHXD.js} +2 -2
- package/dist/{chunk-QZPNQWS2.js → chunk-VEFDL77X.js} +2 -2
- package/dist/{chunk-WEH5TCPE.js → chunk-VJFH2AXT.js} +8 -8
- package/dist/{chunk-S7HRED4D.js → chunk-VLHGBFR6.js} +3 -3
- package/dist/{chunk-RLC46NIW.js → chunk-VMNSGE2G.js} +3 -1
- package/dist/chunk-VMNSGE2G.js.map +1 -0
- package/dist/{chunk-HP2ODXNA.js → chunk-VR5HDUBK.js} +2 -2
- package/dist/{chunk-RBGOGTT2.js → chunk-W2UTDN4T.js} +4 -4
- package/dist/{chunk-N4WANJI3.js → chunk-WBVHRLIS.js} +4 -4
- package/dist/{chunk-XXJRT6BP.js → chunk-WMALDOF5.js} +4 -4
- package/dist/{chunk-MHFJBNDP.js → chunk-WO52KYSU.js} +8 -8
- package/dist/{chunk-ZBOFBRZC.js → chunk-WX7VWW3W.js} +2 -2
- package/dist/{chunk-J4W4TQPC.js → chunk-X24P3ZYW.js} +6 -6
- package/dist/{chunk-X2J6MRJW.js → chunk-YFHIESMD.js} +2 -2
- package/dist/{chunk-72NOM3O2.js → chunk-YK2PETUP.js} +2 -2
- package/dist/{chunk-CRNQVWIT.js → chunk-Z4GWXTZV.js} +4 -4
- package/dist/{chunk-SG6VULKS.js → chunk-ZEBJT5JZ.js} +3 -3
- package/dist/chunk-ZEG2LNBY.js +68 -0
- package/dist/chunk-ZEG2LNBY.js.map +1 -0
- package/dist/{chunk-JZKOJZ6V.js → chunk-ZOW2CCMO.js} +26 -25
- package/dist/chunk-ZOW2CCMO.js.map +1 -0
- package/dist/{chunk-3HWL4AW4.js → chunk-ZTF5C2GA.js} +22 -10
- package/dist/chunk-ZTF5C2GA.js.map +1 -0
- package/dist/data-display/AsyncStateContainer.js +8 -7
- package/dist/data-display/Avatar.js +8 -2
- package/dist/data-display/Badge.js +12 -6
- package/dist/data-display/CardKit.js +7 -7
- package/dist/data-display/Carousel.js +2 -2
- package/dist/data-display/Chart.js +11 -11
- package/dist/data-display/Chip.js +4 -2
- package/dist/data-display/DataGrid.js +3 -3
- package/dist/data-display/DataViews.js +66 -65
- package/dist/data-display/EmptyState.js +2 -2
- package/dist/data-display/HoverCard.js +3 -3
- package/dist/data-display/LazyImage.js +6 -4
- package/dist/data-display/Lightbox.js +5 -5
- package/dist/data-display/LoadingState.js +5 -4
- package/dist/data-display/MapPreview.js +4 -4
- package/dist/data-display/Progress.js +8 -3
- package/dist/data-display/SectionOnboarding.js +3 -3
- package/dist/data-display/Sheet.js +2 -2
- package/dist/data-display/StatCard.js +6 -4
- package/dist/data-display/Table.js +3 -3
- package/dist/feedback/ConfirmAction.js +6 -6
- package/dist/feedback/TutorialOverlay.js +2 -2
- package/dist/form/AddressAutocomplete.js +7 -7
- package/dist/form/Autocomplete.js +2 -2
- package/dist/form/Button.js +2 -2
- package/dist/form/Calendar.js +4 -4
- package/dist/form/CategorySelect.js +10 -10
- package/dist/form/CepField.js +3 -3
- package/dist/form/CodeEditor.js +3 -3
- package/dist/form/DateRangePicker.js +7 -7
- package/dist/form/Input.js +2 -2
- package/dist/form/Menubar.js +2 -2
- package/dist/form/RichTextEditor.js +2 -2
- package/dist/form/total-form.js +30 -30
- package/dist/icons.js +2 -2
- package/dist/layout/ContentToolbar.js +10 -10
- package/dist/layout/ScrollArea.js +2 -2
- package/dist/layout/SettingsLayout.js +6 -6
- package/dist/layout/Skeleton.js +5 -3
- package/dist/native/chunks/{chunk-V4DQTC5L.js → chunk-HSIND52T.js} +3 -2
- package/dist/native/chunks/chunk-HSIND52T.js.map +1 -0
- package/dist/native/chunks/chunk-MLQIOKQZ.js +30 -0
- package/dist/native/chunks/chunk-MLQIOKQZ.js.map +1 -0
- package/dist/native/chunks/{chunk-YQGNMAJN.js → chunk-Q52IDAF2.js} +6 -4
- package/dist/native/chunks/chunk-Q52IDAF2.js.map +1 -0
- package/dist/native/data-display/Alert.js +7 -7
- package/dist/native/data-display/Avatar.js +451 -0
- package/dist/native/data-display/Avatar.js.map +1 -0
- package/dist/native/data-display/Badge.js +418 -0
- package/dist/native/data-display/Badge.js.map +1 -0
- package/dist/native/data-display/Chip.js +374 -0
- package/dist/native/data-display/Chip.js.map +1 -0
- package/dist/native/data-display/EmptyState.js +9 -9
- package/dist/native/data-display/ErrorState.js +9 -9
- package/dist/native/data-display/LoadingState.js +4 -4
- package/dist/native/data-display/Progress.js +432 -0
- package/dist/native/data-display/Progress.js.map +1 -0
- package/dist/native/icons.js +2 -2
- package/dist/native/layout/Skeleton.js +214 -0
- package/dist/native/layout/Skeleton.js.map +1 -0
- package/dist/navigation/AppHeader.js +9 -9
- package/dist/navigation/NavigationMenu.js +4 -4
- package/dist/navigation/Pagination.js +2 -2
- package/dist/navigation/Tabs.js +2 -2
- package/dist/social-login-button.js +3 -3
- package/dist/types/components/data-display/Avatar/Avatar.base.d.ts +87 -0
- package/dist/types/components/data-display/Avatar/Avatar.base.d.ts.map +1 -0
- package/dist/types/components/data-display/Avatar/Avatar.d.ts.map +1 -1
- package/dist/types/components/data-display/Avatar/Avatar.helpers.d.ts +37 -0
- package/dist/types/components/data-display/Avatar/Avatar.helpers.d.ts.map +1 -0
- package/dist/types/components/data-display/Avatar/Avatar.metrics.d.ts +113 -0
- package/dist/types/components/data-display/Avatar/Avatar.metrics.d.ts.map +1 -0
- package/dist/types/components/data-display/Avatar/Avatar.types.d.ts +4 -68
- package/dist/types/components/data-display/Avatar/Avatar.types.d.ts.map +1 -1
- package/dist/types/components/data-display/Avatar/Avatar.view.d.ts +2 -2
- package/dist/types/components/data-display/Avatar/Avatar.view.d.ts.map +1 -1
- package/dist/types/components/data-display/Avatar/index.d.ts +1 -1
- package/dist/types/components/data-display/Avatar/index.d.ts.map +1 -1
- package/dist/types/components/data-display/Badge/Badge.animations.d.ts.map +1 -1
- package/dist/types/components/data-display/Badge/Badge.base.d.ts +101 -0
- package/dist/types/components/data-display/Badge/Badge.base.d.ts.map +1 -0
- package/dist/types/components/data-display/Badge/Badge.d.ts.map +1 -1
- package/dist/types/components/data-display/Badge/Badge.helpers.d.ts +10 -4
- package/dist/types/components/data-display/Badge/Badge.helpers.d.ts.map +1 -1
- package/dist/types/components/data-display/Badge/Badge.metrics.d.ts +111 -0
- package/dist/types/components/data-display/Badge/Badge.metrics.d.ts.map +1 -0
- package/dist/types/components/data-display/Badge/Badge.styles.d.ts +1 -4
- package/dist/types/components/data-display/Badge/Badge.styles.d.ts.map +1 -1
- package/dist/types/components/data-display/Badge/Badge.types.d.ts +4 -81
- package/dist/types/components/data-display/Badge/Badge.types.d.ts.map +1 -1
- package/dist/types/components/data-display/Badge/Badge.variants.d.ts.map +1 -1
- package/dist/types/components/data-display/Badge/BadgeContent.d.ts.map +1 -1
- package/dist/types/components/data-display/Badge/index.d.ts +1 -1
- package/dist/types/components/data-display/Badge/index.d.ts.map +1 -1
- package/dist/types/components/data-display/Chip/Chip.base.d.ts +81 -0
- package/dist/types/components/data-display/Chip/Chip.base.d.ts.map +1 -0
- package/dist/types/components/data-display/Chip/Chip.d.ts.map +1 -1
- package/dist/types/components/data-display/Chip/Chip.helpers.d.ts +14 -28
- package/dist/types/components/data-display/Chip/Chip.helpers.d.ts.map +1 -1
- package/dist/types/components/data-display/Chip/Chip.metrics.d.ts +61 -0
- package/dist/types/components/data-display/Chip/Chip.metrics.d.ts.map +1 -0
- package/dist/types/components/data-display/Chip/Chip.styles.d.ts +30 -0
- package/dist/types/components/data-display/Chip/Chip.styles.d.ts.map +1 -0
- package/dist/types/components/data-display/Chip/Chip.types.d.ts +4 -67
- package/dist/types/components/data-display/Chip/Chip.types.d.ts.map +1 -1
- package/dist/types/components/data-display/Chip/index.d.ts +1 -1
- package/dist/types/components/data-display/Chip/index.d.ts.map +1 -1
- package/dist/types/components/data-display/Progress/Progress.base.d.ts +72 -0
- package/dist/types/components/data-display/Progress/Progress.base.d.ts.map +1 -0
- package/dist/types/components/data-display/Progress/Progress.d.ts.map +1 -1
- package/dist/types/components/data-display/Progress/Progress.helpers.d.ts +15 -3
- package/dist/types/components/data-display/Progress/Progress.helpers.d.ts.map +1 -1
- package/dist/types/components/data-display/Progress/Progress.metrics.d.ts +91 -0
- package/dist/types/components/data-display/Progress/Progress.metrics.d.ts.map +1 -0
- package/dist/types/components/data-display/Progress/Progress.styles.d.ts.map +1 -1
- package/dist/types/components/data-display/Progress/Progress.types.d.ts +4 -48
- package/dist/types/components/data-display/Progress/Progress.types.d.ts.map +1 -1
- package/dist/types/components/data-display/Progress/index.d.ts +1 -1
- package/dist/types/components/data-display/Progress/index.d.ts.map +1 -1
- package/dist/types/components/layout/Skeleton/Skeleton.base.d.ts +37 -0
- package/dist/types/components/layout/Skeleton/Skeleton.base.d.ts.map +1 -0
- package/dist/types/components/layout/Skeleton/Skeleton.d.ts.map +1 -1
- package/dist/types/components/layout/Skeleton/Skeleton.helpers.d.ts +13 -3
- package/dist/types/components/layout/Skeleton/Skeleton.helpers.d.ts.map +1 -1
- package/dist/types/components/layout/Skeleton/Skeleton.metrics.d.ts +68 -0
- package/dist/types/components/layout/Skeleton/Skeleton.metrics.d.ts.map +1 -0
- package/dist/types/components/layout/Skeleton/Skeleton.styles.d.ts +1 -1
- package/dist/types/components/layout/Skeleton/Skeleton.styles.d.ts.map +1 -1
- package/dist/types/components/layout/Skeleton/Skeleton.types.d.ts +5 -15
- package/dist/types/components/layout/Skeleton/Skeleton.types.d.ts.map +1 -1
- package/dist/types/components/layout/Skeleton/index.d.ts +1 -1
- package/dist/types/components/layout/Skeleton/index.d.ts.map +1 -1
- package/dist/types/icons/paths.generated.d.ts +2 -0
- package/dist/types/icons/paths.generated.d.ts.map +1 -1
- package/dist/types/platform/animation.d.ts +14 -0
- package/dist/types/platform/animation.d.ts.map +1 -0
- package/dist/types/platform/web-keys.d.ts +25 -0
- package/dist/types/platform/web-keys.d.ts.map +1 -0
- package/dist/types/tokens/mui-type.d.ts +1 -1
- package/dist/types/tokens/mui-type.d.ts.map +1 -1
- package/dist/types-native/components/data-display/Avatar/Avatar.base.d.ts +87 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.base.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.helpers.d.ts +37 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.helpers.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.look.native.d.ts +25 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.look.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.metrics.d.ts +113 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.metrics.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.native.d.ts +19 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.parts.native.d.ts +69 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.parts.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.types.native.d.ts +24 -0
- package/dist/types-native/components/data-display/Avatar/Avatar.types.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Avatar/index.native.d.ts +3 -0
- package/dist/types-native/components/data-display/Avatar/index.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Badge/Badge.base.d.ts +101 -0
- package/dist/types-native/components/data-display/Badge/Badge.base.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Badge/Badge.helpers.d.ts +19 -0
- package/dist/types-native/components/data-display/Badge/Badge.helpers.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Badge/Badge.look.native.d.ts +31 -0
- package/dist/types-native/components/data-display/Badge/Badge.look.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Badge/Badge.metrics.d.ts +111 -0
- package/dist/types-native/components/data-display/Badge/Badge.metrics.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Badge/Badge.native.d.ts +10 -0
- package/dist/types-native/components/data-display/Badge/Badge.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Badge/Badge.types.native.d.ts +8 -0
- package/dist/types-native/components/data-display/Badge/Badge.types.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Badge/BadgeContent.native.d.ts +20 -0
- package/dist/types-native/components/data-display/Badge/BadgeContent.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Badge/index.native.d.ts +3 -0
- package/dist/types-native/components/data-display/Badge/index.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Chip/Chip.base.d.ts +81 -0
- package/dist/types-native/components/data-display/Chip/Chip.base.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Chip/Chip.helpers.d.ts +22 -0
- package/dist/types-native/components/data-display/Chip/Chip.helpers.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Chip/Chip.look.native.d.ts +29 -0
- package/dist/types-native/components/data-display/Chip/Chip.look.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Chip/Chip.metrics.d.ts +61 -0
- package/dist/types-native/components/data-display/Chip/Chip.metrics.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Chip/Chip.native.d.ts +11 -0
- package/dist/types-native/components/data-display/Chip/Chip.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Chip/Chip.types.native.d.ts +20 -0
- package/dist/types-native/components/data-display/Chip/Chip.types.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Chip/index.native.d.ts +3 -0
- package/dist/types-native/components/data-display/Chip/index.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Progress/Progress.base.d.ts +72 -0
- package/dist/types-native/components/data-display/Progress/Progress.base.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Progress/Progress.helpers.d.ts +18 -0
- package/dist/types-native/components/data-display/Progress/Progress.helpers.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Progress/Progress.look.native.d.ts +28 -0
- package/dist/types-native/components/data-display/Progress/Progress.look.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Progress/Progress.metrics.d.ts +91 -0
- package/dist/types-native/components/data-display/Progress/Progress.metrics.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Progress/Progress.native.d.ts +10 -0
- package/dist/types-native/components/data-display/Progress/Progress.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Progress/Progress.types.native.d.ts +8 -0
- package/dist/types-native/components/data-display/Progress/Progress.types.native.d.ts.map +1 -0
- package/dist/types-native/components/data-display/Progress/index.native.d.ts +3 -0
- package/dist/types-native/components/data-display/Progress/index.native.d.ts.map +1 -0
- package/dist/types-native/components/layout/Skeleton/Skeleton.base.d.ts +37 -0
- package/dist/types-native/components/layout/Skeleton/Skeleton.base.d.ts.map +1 -0
- package/dist/types-native/components/layout/Skeleton/Skeleton.helpers.d.ts +16 -0
- package/dist/types-native/components/layout/Skeleton/Skeleton.helpers.d.ts.map +1 -0
- package/dist/types-native/components/layout/Skeleton/Skeleton.metrics.d.ts +68 -0
- package/dist/types-native/components/layout/Skeleton/Skeleton.metrics.d.ts.map +1 -0
- package/dist/types-native/components/layout/Skeleton/Skeleton.native.d.ts +38 -0
- package/dist/types-native/components/layout/Skeleton/Skeleton.native.d.ts.map +1 -0
- package/dist/types-native/components/layout/Skeleton/Skeleton.types.native.d.ts +8 -0
- package/dist/types-native/components/layout/Skeleton/Skeleton.types.native.d.ts.map +1 -0
- package/dist/types-native/components/layout/Skeleton/index.native.d.ts +3 -0
- package/dist/types-native/components/layout/Skeleton/index.native.d.ts.map +1 -0
- package/dist/types-native/icons/paths.generated.d.ts +2 -0
- package/dist/types-native/icons/paths.generated.d.ts.map +1 -1
- package/dist/types-native/platform/animation.d.ts +14 -0
- package/dist/types-native/platform/animation.d.ts.map +1 -0
- package/dist/types-native/platform/web-keys.d.ts +25 -0
- package/dist/types-native/platform/web-keys.d.ts.map +1 -0
- package/dist/types-native/tokens/mui-type.d.ts +1 -1
- package/dist/types-native/tokens/mui-type.d.ts.map +1 -1
- package/dist/user-avatar.js +7 -5
- package/dist/utility/InstallPrompt.js +2 -2
- package/package.json +21 -1
- package/src/components/data-display/Avatar/Avatar.base.ts +108 -0
- package/src/components/data-display/Avatar/Avatar.helpers.ts +54 -0
- package/src/components/data-display/Avatar/Avatar.look.native.ts +123 -0
- package/src/components/data-display/Avatar/Avatar.metrics.ts +111 -0
- package/src/components/data-display/Avatar/Avatar.native.tsx +190 -0
- package/src/components/data-display/Avatar/Avatar.parts.native.tsx +243 -0
- package/src/components/data-display/Avatar/Avatar.tsx +34 -36
- package/src/components/data-display/Avatar/Avatar.types.native.ts +39 -0
- package/src/components/data-display/Avatar/Avatar.types.ts +12 -81
- package/src/components/data-display/Avatar/Avatar.view.tsx +61 -41
- package/src/components/data-display/Avatar/NATIVE-NOTES.md +11 -0
- package/src/components/data-display/Avatar/index.native.ts +10 -0
- package/src/components/data-display/Avatar/index.ts +8 -1
- package/src/components/data-display/Badge/Badge.animations.ts +11 -9
- package/src/components/data-display/Badge/Badge.base.ts +138 -0
- package/src/components/data-display/Badge/Badge.helpers.ts +18 -7
- package/src/components/data-display/Badge/Badge.look.native.ts +174 -0
- package/src/components/data-display/Badge/Badge.metrics.ts +116 -0
- package/src/components/data-display/Badge/Badge.native.tsx +212 -0
- package/src/components/data-display/Badge/Badge.styles.ts +63 -74
- package/src/components/data-display/Badge/Badge.tsx +12 -6
- package/src/components/data-display/Badge/Badge.types.native.ts +16 -0
- package/src/components/data-display/Badge/Badge.types.ts +27 -113
- package/src/components/data-display/Badge/Badge.variants.ts +20 -9
- package/src/components/data-display/Badge/BadgeContent.native.tsx +78 -0
- package/src/components/data-display/Badge/BadgeContent.tsx +8 -8
- package/src/components/data-display/Badge/NATIVE-NOTES.md +11 -0
- package/src/components/data-display/Badge/index.native.ts +8 -0
- package/src/components/data-display/Badge/index.ts +7 -1
- package/src/components/data-display/Chip/Chip.base.ts +99 -0
- package/src/components/data-display/Chip/Chip.helpers.ts +49 -0
- package/src/components/data-display/Chip/Chip.look.native.ts +163 -0
- package/src/components/data-display/Chip/Chip.metrics.ts +102 -0
- package/src/components/data-display/Chip/Chip.native.tsx +269 -0
- package/src/components/data-display/Chip/{Chip.helpers.tsx → Chip.styles.tsx} +23 -51
- package/src/components/data-display/Chip/Chip.tsx +10 -11
- package/src/components/data-display/Chip/Chip.types.native.ts +28 -0
- package/src/components/data-display/Chip/Chip.types.ts +5 -84
- package/src/components/data-display/Chip/NATIVE-NOTES.md +10 -0
- package/src/components/data-display/Chip/chip.md +1 -1
- package/src/components/data-display/Chip/index.native.ts +8 -0
- package/src/components/data-display/Chip/index.ts +1 -1
- package/src/components/data-display/Progress/NATIVE-NOTES.md +10 -0
- package/src/components/data-display/Progress/Progress.base.ts +86 -0
- package/src/components/data-display/Progress/Progress.helpers.ts +29 -8
- package/src/components/data-display/Progress/Progress.look.native.ts +111 -0
- package/src/components/data-display/Progress/Progress.metrics.ts +101 -0
- package/src/components/data-display/Progress/Progress.native.tsx +387 -0
- package/src/components/data-display/Progress/Progress.styles.ts +31 -17
- package/src/components/data-display/Progress/Progress.tsx +7 -6
- package/src/components/data-display/Progress/Progress.types.native.ts +11 -0
- package/src/components/data-display/Progress/Progress.types.ts +6 -58
- package/src/components/data-display/Progress/index.native.ts +7 -0
- package/src/components/data-display/Progress/index.ts +6 -1
- package/src/components/layout/Skeleton/NATIVE-NOTES.md +8 -0
- package/src/components/layout/Skeleton/Skeleton.base.ts +37 -0
- package/src/components/layout/Skeleton/Skeleton.helpers.ts +24 -8
- package/src/components/layout/Skeleton/Skeleton.metrics.ts +81 -0
- package/src/components/layout/Skeleton/Skeleton.native.tsx +271 -0
- package/src/components/layout/Skeleton/Skeleton.styles.ts +25 -25
- package/src/components/layout/Skeleton/Skeleton.tsx +9 -5
- package/src/components/layout/Skeleton/Skeleton.types.native.ts +16 -0
- package/src/components/layout/Skeleton/Skeleton.types.ts +13 -16
- package/src/components/layout/Skeleton/index.native.ts +8 -0
- package/src/components/layout/Skeleton/index.ts +7 -1
- package/src/icons/glyphs.json +2 -0
- package/src/icons/paths.generated.ts +2 -0
- package/src/platform/animation.ts +53 -0
- package/src/platform/web-keys.ts +28 -0
- package/src/tokens/mui-type.ts +2 -1
- package/dist/chunk-3HWL4AW4.js.map +0 -1
- package/dist/chunk-4Q7HWRR2.js.map +0 -1
- package/dist/chunk-FS4X3VDA.js +0 -78
- package/dist/chunk-FS4X3VDA.js.map +0 -1
- package/dist/chunk-HAFE43QJ.js.map +0 -1
- package/dist/chunk-HKFMPEXJ.js.map +0 -1
- package/dist/chunk-HXYXDQ7U.js.map +0 -1
- package/dist/chunk-IRDGC7FK.js.map +0 -1
- package/dist/chunk-JZKOJZ6V.js.map +0 -1
- package/dist/chunk-KPQAPQH6.js.map +0 -1
- package/dist/chunk-L6KEVPXN.js.map +0 -1
- package/dist/chunk-LYNJJV2X.js.map +0 -1
- package/dist/chunk-MMZAGB64.js.map +0 -1
- package/dist/chunk-NQHOHQCY.js.map +0 -1
- package/dist/chunk-QIV73V2X.js.map +0 -1
- package/dist/chunk-RLC46NIW.js.map +0 -1
- package/dist/chunk-ZGEBIC5X.js.map +0 -1
- package/dist/chunk-ZHEJLUCX.js.map +0 -1
- package/dist/native/chunks/chunk-V4DQTC5L.js.map +0 -1
- package/dist/native/chunks/chunk-YQGNMAJN.js.map +0 -1
- /package/dist/{chunk-P7FQUGED.js.map → chunk-23FCBIUN.js.map} +0 -0
- /package/dist/{chunk-SL4NFGOL.js.map → chunk-24BUCMQA.js.map} +0 -0
- /package/dist/{chunk-4SXZSSVV.js.map → chunk-2EKALM6P.js.map} +0 -0
- /package/dist/{chunk-ZRFRU545.js.map → chunk-2ZDTGI5V.js.map} +0 -0
- /package/dist/{chunk-HR7YTBR7.js.map → chunk-3AOOI2NR.js.map} +0 -0
- /package/dist/{chunk-KKYW3LU7.js.map → chunk-47UD6DZ4.js.map} +0 -0
- /package/dist/{chunk-ZOUWHGV3.js.map → chunk-4MGFUPQT.js.map} +0 -0
- /package/dist/{chunk-4FRZDSRD.js.map → chunk-4WK2RTVY.js.map} +0 -0
- /package/dist/{chunk-LDE4ELB5.js.map → chunk-5ZF3VASA.js.map} +0 -0
- /package/dist/{chunk-JE6RZ5L6.js.map → chunk-5ZOJLYD2.js.map} +0 -0
- /package/dist/{chunk-E5ZHW4I5.js.map → chunk-6IUTT6BK.js.map} +0 -0
- /package/dist/{chunk-WPR2HS5B.js.map → chunk-74EZ565M.js.map} +0 -0
- /package/dist/{chunk-BVZVH3ZN.js.map → chunk-74OZ5KVR.js.map} +0 -0
- /package/dist/{chunk-PMS3H3OO.js.map → chunk-76GZ55IC.js.map} +0 -0
- /package/dist/{chunk-DLFOEXUP.js.map → chunk-7EESF76V.js.map} +0 -0
- /package/dist/{chunk-HKZHEK3Z.js.map → chunk-7JWXLDRH.js.map} +0 -0
- /package/dist/{chunk-OR7UH2ZQ.js.map → chunk-7P2HZLEG.js.map} +0 -0
- /package/dist/{chunk-6DXYCXH4.js.map → chunk-7RZ4WOQW.js.map} +0 -0
- /package/dist/{chunk-EMNGIYH6.js.map → chunk-7TZ6OC5T.js.map} +0 -0
- /package/dist/{chunk-CDJPDZCA.js.map → chunk-AEGX66N7.js.map} +0 -0
- /package/dist/{chunk-65DLYC4S.js.map → chunk-AVGTTWTE.js.map} +0 -0
- /package/dist/{chunk-C6XESZ3R.js.map → chunk-B2A4DG77.js.map} +0 -0
- /package/dist/{chunk-VOOPGAQO.js.map → chunk-B7BZAIHL.js.map} +0 -0
- /package/dist/{chunk-DZN3JF5E.js.map → chunk-BBC4KT5G.js.map} +0 -0
- /package/dist/{chunk-FWCUELBU.js.map → chunk-BILE3A7F.js.map} +0 -0
- /package/dist/{chunk-UEJQQVP2.js.map → chunk-BLT5ZBVL.js.map} +0 -0
- /package/dist/{chunk-ISSJNFJV.js.map → chunk-C52BELLW.js.map} +0 -0
- /package/dist/{chunk-BPYPUEM5.js.map → chunk-CZJLWCEG.js.map} +0 -0
- /package/dist/{chunk-WZUNBSS7.js.map → chunk-DVUPIVI2.js.map} +0 -0
- /package/dist/{chunk-EXJBPKGW.js.map → chunk-EGRFMPGD.js.map} +0 -0
- /package/dist/{chunk-XFUNJYFT.js.map → chunk-EPNUVSNK.js.map} +0 -0
- /package/dist/{chunk-H2EQVMU3.js.map → chunk-EX3PSZLV.js.map} +0 -0
- /package/dist/{chunk-LIOVN5IM.js.map → chunk-F2DOTCF3.js.map} +0 -0
- /package/dist/{chunk-64IEKEMQ.js.map → chunk-FGLV6BXQ.js.map} +0 -0
- /package/dist/{chunk-L65LF6LN.js.map → chunk-FP4R47TM.js.map} +0 -0
- /package/dist/{chunk-7AR2R7TV.js.map → chunk-G5ZVD5IJ.js.map} +0 -0
- /package/dist/{chunk-SHQWIDD5.js.map → chunk-GJQYM3PM.js.map} +0 -0
- /package/dist/{chunk-7WL24VNI.js.map → chunk-HDNK7BAX.js.map} +0 -0
- /package/dist/{chunk-X5MPHXG5.js.map → chunk-HEG7JIBM.js.map} +0 -0
- /package/dist/{chunk-ZIOCRSHU.js.map → chunk-HSAH5QUQ.js.map} +0 -0
- /package/dist/{chunk-B443IIQG.js.map → chunk-IE7ISTLQ.js.map} +0 -0
- /package/dist/{chunk-NFHS77NE.js.map → chunk-IH4CX43Q.js.map} +0 -0
- /package/dist/{chunk-72UYVJBQ.js.map → chunk-IJIT5HQP.js.map} +0 -0
- /package/dist/{chunk-AP4FLCLA.js.map → chunk-J54WH74M.js.map} +0 -0
- /package/dist/{chunk-5HOJSVQH.js.map → chunk-JB7JE4QZ.js.map} +0 -0
- /package/dist/{chunk-QJJUTBKZ.js.map → chunk-KQ74QU55.js.map} +0 -0
- /package/dist/{chunk-YLDS5FOQ.js.map → chunk-KZSKI2R3.js.map} +0 -0
- /package/dist/{chunk-IIOEQRXX.js.map → chunk-LAHDFBDE.js.map} +0 -0
- /package/dist/{chunk-BUDXR3EV.js.map → chunk-LKVIZNUM.js.map} +0 -0
- /package/dist/{chunk-OAXAF4VY.js.map → chunk-LMJBINWN.js.map} +0 -0
- /package/dist/{chunk-SFAP5EH5.js.map → chunk-LUMF63BM.js.map} +0 -0
- /package/dist/{chunk-KADJNWTQ.js.map → chunk-LZRURORY.js.map} +0 -0
- /package/dist/{chunk-CLNTJM3F.js.map → chunk-M7OHXNLF.js.map} +0 -0
- /package/dist/{chunk-UXQW6ZIN.js.map → chunk-MBYO2F4Y.js.map} +0 -0
- /package/dist/{chunk-MCRIT46W.js.map → chunk-MY5VNNSP.js.map} +0 -0
- /package/dist/{chunk-XELVDPKL.js.map → chunk-NFAKRI4S.js.map} +0 -0
- /package/dist/{chunk-KSF7TLXH.js.map → chunk-NHSMLVNC.js.map} +0 -0
- /package/dist/{chunk-ES2RN7YV.js.map → chunk-NRUYYGDZ.js.map} +0 -0
- /package/dist/{chunk-MQUU2XZB.js.map → chunk-OQFSYMHJ.js.map} +0 -0
- /package/dist/{chunk-M3RIC6JI.js.map → chunk-OQXOYHIV.js.map} +0 -0
- /package/dist/{chunk-PC3ZFERM.js.map → chunk-PC5FFEIY.js.map} +0 -0
- /package/dist/{chunk-SOHDPFOB.js.map → chunk-PHCSPHDH.js.map} +0 -0
- /package/dist/{chunk-OZWQNFG6.js.map → chunk-PODGTNXS.js.map} +0 -0
- /package/dist/{chunk-IPE5FFFD.js.map → chunk-PUBPZOQJ.js.map} +0 -0
- /package/dist/{chunk-GBFGZJB5.js.map → chunk-Q4NOI2CR.js.map} +0 -0
- /package/dist/{chunk-GOWBYHYW.js.map → chunk-R6SBP5M5.js.map} +0 -0
- /package/dist/{chunk-DTKMBI7B.js.map → chunk-R7MX5KPJ.js.map} +0 -0
- /package/dist/{chunk-NECUCG2S.js.map → chunk-RQDN4BN5.js.map} +0 -0
- /package/dist/{chunk-5SYD23V4.js.map → chunk-SKZHOWTS.js.map} +0 -0
- /package/dist/{chunk-Y6KPZQPI.js.map → chunk-SOCKK67R.js.map} +0 -0
- /package/dist/{chunk-GCJLMX63.js.map → chunk-VCTKJHXD.js.map} +0 -0
- /package/dist/{chunk-QZPNQWS2.js.map → chunk-VEFDL77X.js.map} +0 -0
- /package/dist/{chunk-WEH5TCPE.js.map → chunk-VJFH2AXT.js.map} +0 -0
- /package/dist/{chunk-S7HRED4D.js.map → chunk-VLHGBFR6.js.map} +0 -0
- /package/dist/{chunk-HP2ODXNA.js.map → chunk-VR5HDUBK.js.map} +0 -0
- /package/dist/{chunk-RBGOGTT2.js.map → chunk-W2UTDN4T.js.map} +0 -0
- /package/dist/{chunk-N4WANJI3.js.map → chunk-WBVHRLIS.js.map} +0 -0
- /package/dist/{chunk-XXJRT6BP.js.map → chunk-WMALDOF5.js.map} +0 -0
- /package/dist/{chunk-MHFJBNDP.js.map → chunk-WO52KYSU.js.map} +0 -0
- /package/dist/{chunk-ZBOFBRZC.js.map → chunk-WX7VWW3W.js.map} +0 -0
- /package/dist/{chunk-J4W4TQPC.js.map → chunk-X24P3ZYW.js.map} +0 -0
- /package/dist/{chunk-X2J6MRJW.js.map → chunk-YFHIESMD.js.map} +0 -0
- /package/dist/{chunk-72NOM3O2.js.map → chunk-YK2PETUP.js.map} +0 -0
- /package/dist/{chunk-CRNQVWIT.js.map → chunk-Z4GWXTZV.js.map} +0 -0
- /package/dist/{chunk-SG6VULKS.js.map → chunk-ZEBJT5JZ.js.map} +0 -0
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import type { BadgePosition, BadgeSize } from './Badge.base';
|
|
2
|
+
import { contrastText, type UiPaletteColor, type UiTheme } from '../../../tokens/theme';
|
|
3
|
+
import type { ColorValue } from '../../../tokens/vocabulary';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* THE NUMBERS BOTH `Badge` RENDERERS DRAW WITH.
|
|
7
|
+
*
|
|
8
|
+
* `Badge.styles.ts` / `Badge.variants.ts` (web, emotion over MUI's `Badge`) and
|
|
9
|
+
* `Badge.native.tsx` (React Native) read this one table: the five chips, the
|
|
10
|
+
* dot inside them, the ten variants' alphas and borders, and the keyframes.
|
|
11
|
+
* The web turns the px into rem and the padding into a shorthand; native uses
|
|
12
|
+
* the numbers.
|
|
13
|
+
*/
|
|
14
|
+
export interface BadgeSizeMetrics {
|
|
15
|
+
minWidth: number;
|
|
16
|
+
height: number;
|
|
17
|
+
/** The content's type size, in px. */
|
|
18
|
+
fontSize: number;
|
|
19
|
+
/** The chip's side padding, in px. `padding: '0 Npx'` on the web. */
|
|
20
|
+
paddingHorizontal: number;
|
|
21
|
+
dotSize: number;
|
|
22
|
+
/** A leading icon's own type size, in px. */
|
|
23
|
+
iconSize: number;
|
|
24
|
+
/** The close glyph's type size, in px. `xl` falls back to `lg`, as the web does. */
|
|
25
|
+
closeIconSize: number;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export const BADGE_SIZES: Record<BadgeSize, BadgeSizeMetrics> = {
|
|
29
|
+
xs: { minWidth: 14, height: 14, fontSize: 8, paddingHorizontal: 3, dotSize: 6, iconSize: 10, closeIconSize: 8 },
|
|
30
|
+
sm: { minWidth: 16, height: 16, fontSize: 10, paddingHorizontal: 4, dotSize: 8, iconSize: 12, closeIconSize: 10 },
|
|
31
|
+
md: { minWidth: 20, height: 20, fontSize: 12, paddingHorizontal: 6, dotSize: 10, iconSize: 14, closeIconSize: 12 },
|
|
32
|
+
lg: { minWidth: 24, height: 24, fontSize: 14, paddingHorizontal: 8, dotSize: 12, iconSize: 16, closeIconSize: 14 },
|
|
33
|
+
xl: { minWidth: 28, height: 28, fontSize: 16, paddingHorizontal: 10, dotSize: 14, iconSize: 18, closeIconSize: 14 },
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
/** The chip's own type weight, its tracking, and the paper ring around it. */
|
|
37
|
+
export const BADGE_FONT_WEIGHT = 600;
|
|
38
|
+
export const BADGE_DESTRUCTIVE_FONT_WEIGHT = 700;
|
|
39
|
+
export const BADGE_LETTER_SPACING_EM = 0.025;
|
|
40
|
+
export const BADGE_BORDER_WIDTH = 2;
|
|
41
|
+
/** Between the icon, the content and the close button. */
|
|
42
|
+
export const BADGE_CONTENT_GAP = 2;
|
|
43
|
+
|
|
44
|
+
/* ── The ten variants' washes ─────────────────────────────────────────────── */
|
|
45
|
+
|
|
46
|
+
export const GLASS_BACKGROUND_ALPHA = 0.1;
|
|
47
|
+
export const GLASS_BORDER_ALPHA = 0.2;
|
|
48
|
+
export const GLASS_BLUR_PX = 10;
|
|
49
|
+
export const GLASS_SATURATE = 2;
|
|
50
|
+
export const GLASS_INSET_HIGHLIGHT_ALPHA = 0.1;
|
|
51
|
+
export const OUTLINE_BORDER_WIDTH = 2;
|
|
52
|
+
export const SECONDARY_BACKGROUND_ALPHA = 0.15;
|
|
53
|
+
export const SECONDARY_BORDER_ALPHA = 0.3;
|
|
54
|
+
|
|
55
|
+
/* ── Emphasis and animation ───────────────────────────────────────────────── */
|
|
56
|
+
|
|
57
|
+
/** `glow` without `pulse`: a 15px halo, brighter under the pointer. */
|
|
58
|
+
export const GLOW = { blur: 15, spread: 3, alpha: 0.5, hoverBlur: 20, hoverSpread: 4, hoverAlpha: 0.6, brightness: 1.1 } as const;
|
|
59
|
+
/** `glow` WITH `pulse`: the halo breathes between these two. */
|
|
60
|
+
export const GLOW_PULSE = { fromBlur: 5, fromSpread: 2, fromAlpha: 0.4, toBlur: 20, toSpread: 4, toAlpha: 0.8 } as const;
|
|
61
|
+
/** MUI-free `pulseAnimation`: 1 → 1.2 → 1 while the opacity dips to 0.7. */
|
|
62
|
+
export const PULSE = { durationMs: 2000, scale: 1.2, opacity: 0.7 } as const;
|
|
63
|
+
/** `bounceAnimation`: up 8px at 40%, 4px at 60%, over one second. */
|
|
64
|
+
export const BOUNCE = { durationMs: 1000, lift: 8, secondLift: 4, scale: 1.05, secondScale: 1.02 } as const;
|
|
65
|
+
/** `fadeInScaleAnimation`: in from half size, overshooting to 1.1. */
|
|
66
|
+
export const FADE_IN_SCALE = { durationMs: 400, from: 0.5, overshoot: 1.1 } as const;
|
|
67
|
+
/** The shimmer sweep, and the white it is made of. */
|
|
68
|
+
export const SHIMMER = { durationMs: 3000, alpha: 0.4 } as const;
|
|
69
|
+
/** How long the mount animation is held before the flag clears. */
|
|
70
|
+
export const MOUNT_ANIMATION_MS = 1000;
|
|
71
|
+
/** MUI's `Zoom` on close, and the wait before the caller is told. */
|
|
72
|
+
export const CLOSE_DELAY_MS = 300;
|
|
73
|
+
/** `transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1)` on the chip. */
|
|
74
|
+
export const BADGE_TRANSITION_MS = 300;
|
|
75
|
+
export const BADGE_TRANSITION_EASING = 'cubic-bezier(0.4, 0, 0.2, 1)';
|
|
76
|
+
/** The chip grows a tenth under the pointer. */
|
|
77
|
+
export const HOVER_SCALE = 1.1;
|
|
78
|
+
|
|
79
|
+
/* ── Placement ────────────────────────────────────────────────────────────── */
|
|
80
|
+
|
|
81
|
+
export interface BadgeAnchor {
|
|
82
|
+
vertical: 'top' | 'bottom';
|
|
83
|
+
horizontal: 'left' | 'right';
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
const BADGE_ANCHORS: Record<BadgePosition, BadgeAnchor> = {
|
|
87
|
+
'top-right': { vertical: 'top', horizontal: 'right' },
|
|
88
|
+
'top-left': { vertical: 'top', horizontal: 'left' },
|
|
89
|
+
'bottom-right': { vertical: 'bottom', horizontal: 'right' },
|
|
90
|
+
'bottom-left': { vertical: 'bottom', horizontal: 'left' },
|
|
91
|
+
};
|
|
92
|
+
|
|
93
|
+
/**
|
|
94
|
+
* Falls back to `top-right` for anything outside the union, as the web's own
|
|
95
|
+
* `positionMap[position] || positionMap['top-right']` did. Splitting on `-`
|
|
96
|
+
* instead would hand MUI a half-undefined `anchorOrigin` for, say, `middle`.
|
|
97
|
+
*/
|
|
98
|
+
export const badgeAnchor = (position: BadgePosition): BadgeAnchor =>
|
|
99
|
+
BADGE_ANCHORS[position] ?? BADGE_ANCHORS['top-right'];
|
|
100
|
+
|
|
101
|
+
/**
|
|
102
|
+
* `neutral` has no palette slot of its own in MUI, so `Badge.styles.ts` draws
|
|
103
|
+
* it from three greys; `danger` is MUI's `error`, which is what the shared
|
|
104
|
+
* theme calls `danger`. Same colours here.
|
|
105
|
+
*/
|
|
106
|
+
export function badgePalette(theme: UiTheme, color: ColorValue): UiPaletteColor {
|
|
107
|
+
if (color === 'neutral') {
|
|
108
|
+
return {
|
|
109
|
+
main: theme.palette.grey[600],
|
|
110
|
+
light: theme.palette.grey[400],
|
|
111
|
+
dark: theme.palette.grey[800],
|
|
112
|
+
contrastText: contrastText(theme.palette.grey[600]),
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
return theme.palette[color];
|
|
116
|
+
}
|
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { Animated, Easing, Platform, StyleSheet, View, type ViewStyle } from 'react-native';
|
|
3
|
+
|
|
4
|
+
import {
|
|
5
|
+
badgeContentOf,
|
|
6
|
+
formatCount,
|
|
7
|
+
makeBadgeTestId,
|
|
8
|
+
resolveBadgeProps,
|
|
9
|
+
type ResolvedBadgeProps,
|
|
10
|
+
} from './Badge.helpers';
|
|
11
|
+
import { badgeAnchorStyle, badgeBoxStyle } from './Badge.look.native';
|
|
12
|
+
import {
|
|
13
|
+
BOUNCE,
|
|
14
|
+
CLOSE_DELAY_MS,
|
|
15
|
+
FADE_IN_SCALE,
|
|
16
|
+
PULSE,
|
|
17
|
+
} from './Badge.metrics';
|
|
18
|
+
import { BadgeContent } from './BadgeContent.native';
|
|
19
|
+
import type { BadgeProps } from './Badge.types.native';
|
|
20
|
+
import { webAria } from '../../../platform/aria';
|
|
21
|
+
import { resolveTestId } from '../../../platform/test-id';
|
|
22
|
+
import { useLoopedProgress } from '../../../platform/animation';
|
|
23
|
+
import { useUiTheme } from '../../../provider/use-ui-theme.native';
|
|
24
|
+
|
|
25
|
+
const nativeDriver = Platform.OS !== 'web';
|
|
26
|
+
type AnimatedStyle = Animated.WithAnimatedValue<ViewStyle>;
|
|
27
|
+
|
|
28
|
+
/** MUI's `pulseAnimation`: 1 → 1.2 → 1 while the opacity dips, every two seconds. */
|
|
29
|
+
function usePulseStyle(enabled: boolean): AnimatedStyle | null {
|
|
30
|
+
const progress = useLoopedProgress(enabled, {
|
|
31
|
+
durationMs: PULSE.durationMs,
|
|
32
|
+
easing: Easing.inOut(Easing.ease),
|
|
33
|
+
});
|
|
34
|
+
if (!enabled) return null;
|
|
35
|
+
return {
|
|
36
|
+
opacity: progress.interpolate({ inputRange: [0, 0.7, 1], outputRange: [1, PULSE.opacity, 1] }),
|
|
37
|
+
transform: [
|
|
38
|
+
{ scale: progress.interpolate({ inputRange: [0, 0.7, 1], outputRange: [1, PULSE.scale, 1] }) },
|
|
39
|
+
],
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
/** A 0→1 progress that runs once on mount, for the entrance keyframes. */
|
|
44
|
+
function useEntrance(enabled: boolean, durationMs: number): Animated.Value {
|
|
45
|
+
const progress = React.useRef(new Animated.Value(enabled ? 0 : 1)).current;
|
|
46
|
+
React.useEffect(() => {
|
|
47
|
+
if (!enabled) return undefined;
|
|
48
|
+
progress.setValue(0);
|
|
49
|
+
const timing = Animated.timing(progress, {
|
|
50
|
+
toValue: 1,
|
|
51
|
+
duration: durationMs,
|
|
52
|
+
easing: Easing.out(Easing.ease),
|
|
53
|
+
useNativeDriver: nativeDriver,
|
|
54
|
+
});
|
|
55
|
+
timing.start();
|
|
56
|
+
return () => timing.stop();
|
|
57
|
+
}, [enabled, durationMs, progress]);
|
|
58
|
+
return progress;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/** `bounceAnimation` when asked for, else `fadeInScaleAnimation`; neither when neither. */
|
|
62
|
+
function useEntranceStyle(animate: boolean, bounce: boolean): AnimatedStyle | null {
|
|
63
|
+
const progress = useEntrance(animate || bounce, bounce ? BOUNCE.durationMs : FADE_IN_SCALE.durationMs);
|
|
64
|
+
if (bounce) {
|
|
65
|
+
return {
|
|
66
|
+
transform: [
|
|
67
|
+
{
|
|
68
|
+
translateY: progress.interpolate({
|
|
69
|
+
inputRange: [0, 0.2, 0.4, 0.5, 0.6, 0.8, 1],
|
|
70
|
+
outputRange: [0, 0, -BOUNCE.lift, 0, -BOUNCE.secondLift, 0, 0],
|
|
71
|
+
}),
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
scale: progress.interpolate({
|
|
75
|
+
inputRange: [0, 0.2, 0.4, 0.5, 0.6, 0.8, 1],
|
|
76
|
+
outputRange: [1, 1, BOUNCE.scale, 1, BOUNCE.secondScale, 1, 1],
|
|
77
|
+
}),
|
|
78
|
+
},
|
|
79
|
+
],
|
|
80
|
+
};
|
|
81
|
+
}
|
|
82
|
+
if (!animate) return null;
|
|
83
|
+
return {
|
|
84
|
+
opacity: progress.interpolate({ inputRange: [0, 1], outputRange: [0, 1] }),
|
|
85
|
+
transform: [
|
|
86
|
+
{
|
|
87
|
+
scale: progress.interpolate({
|
|
88
|
+
inputRange: [0, 0.5, 1],
|
|
89
|
+
outputRange: [FADE_IN_SCALE.from, FADE_IN_SCALE.overshoot, 1],
|
|
90
|
+
}),
|
|
91
|
+
},
|
|
92
|
+
],
|
|
93
|
+
};
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
/** MUI's `Zoom` on close: out over 300ms, then the caller is told. */
|
|
97
|
+
function useCloseZoom(onClose?: () => void): { style: AnimatedStyle; close: () => void } {
|
|
98
|
+
const progress = React.useRef(new Animated.Value(1)).current;
|
|
99
|
+
const close = React.useCallback(() => {
|
|
100
|
+
Animated.timing(progress, {
|
|
101
|
+
toValue: 0,
|
|
102
|
+
duration: CLOSE_DELAY_MS,
|
|
103
|
+
easing: Easing.out(Easing.ease),
|
|
104
|
+
useNativeDriver: nativeDriver,
|
|
105
|
+
}).start(({ finished }) => {
|
|
106
|
+
if (finished) onClose?.();
|
|
107
|
+
});
|
|
108
|
+
}, [onClose, progress]);
|
|
109
|
+
return { style: { opacity: progress, transform: [{ scale: progress }] }, close };
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
interface ChipContent {
|
|
113
|
+
content: React.ReactNode;
|
|
114
|
+
/** A count that formatted away leaves nothing worth showing. */
|
|
115
|
+
hidden: boolean;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
/** What the chip shows, and whether there is anything to show at all. */
|
|
119
|
+
function chipContent(resolved: ResolvedBadgeProps<BadgeProps>): ChipContent {
|
|
120
|
+
const { variant, max, showZero, invisible, icon, closable } = resolved;
|
|
121
|
+
const raw = badgeContentOf(resolved);
|
|
122
|
+
const content = variant === 'count' ? formatCount(raw, { max, showZero }) : raw;
|
|
123
|
+
// The web hides the chip only when the whole run assembles to nothing
|
|
124
|
+
// (`buildBadgeContent` returns null on an empty `parts`), so a zero count
|
|
125
|
+
// still draws while an icon or a close button is left to draw with it.
|
|
126
|
+
const hasOtherParts = Boolean(icon) || Boolean(closable);
|
|
127
|
+
return {
|
|
128
|
+
content,
|
|
129
|
+
hidden:
|
|
130
|
+
Boolean(invisible) ||
|
|
131
|
+
(variant === 'count' && content === null && !showZero && !hasOtherParts),
|
|
132
|
+
};
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
/**
|
|
136
|
+
* The native `Badge`: MUI's chip anchored off a corner of whatever it is
|
|
137
|
+
* attached to, with the same ten variants, five sizes and content run.
|
|
138
|
+
*/
|
|
139
|
+
export const Badge = React.forwardRef<View, BadgeProps>((rawProps, ref) => {
|
|
140
|
+
const resolved = resolveBadgeProps(rawProps);
|
|
141
|
+
const {
|
|
142
|
+
variant,
|
|
143
|
+
size,
|
|
144
|
+
color,
|
|
145
|
+
glow,
|
|
146
|
+
pulse,
|
|
147
|
+
animate,
|
|
148
|
+
bounce,
|
|
149
|
+
max: _max,
|
|
150
|
+
showZero: _showZero,
|
|
151
|
+
position,
|
|
152
|
+
invisible,
|
|
153
|
+
closable,
|
|
154
|
+
onClose,
|
|
155
|
+
icon,
|
|
156
|
+
children,
|
|
157
|
+
style,
|
|
158
|
+
'aria-label': ariaLabel,
|
|
159
|
+
'aria-live': ariaLive = 'polite',
|
|
160
|
+
'aria-atomic': ariaAtomic = true,
|
|
161
|
+
'data-testid': _domTestId,
|
|
162
|
+
testID: _testID,
|
|
163
|
+
dataTestId: _dataTestId,
|
|
164
|
+
content: _content,
|
|
165
|
+
badgeContent: _badgeContent,
|
|
166
|
+
shimmer: _shimmer,
|
|
167
|
+
...rest
|
|
168
|
+
} = resolved;
|
|
169
|
+
const theme = useUiTheme();
|
|
170
|
+
const badgeId = resolveTestId(resolved);
|
|
171
|
+
const idFor = makeBadgeTestId(badgeId);
|
|
172
|
+
const pulseStyle = usePulseStyle(pulse && !invisible);
|
|
173
|
+
const entrance = useEntranceStyle(animate && !bounce, bounce);
|
|
174
|
+
const zoom = useCloseZoom(onClose);
|
|
175
|
+
|
|
176
|
+
const { content, hidden } = chipContent(resolved);
|
|
177
|
+
|
|
178
|
+
return (
|
|
179
|
+
<View ref={ref} testID={badgeId || 'badge'} style={[styles.anchor, style]} {...rest}>
|
|
180
|
+
{children}
|
|
181
|
+
{hidden ? null : (
|
|
182
|
+
<View style={badgeAnchorStyle(position)}>
|
|
183
|
+
<Animated.View
|
|
184
|
+
testID={idFor('content-wrapper')}
|
|
185
|
+
aria-label={ariaLabel}
|
|
186
|
+
aria-live={ariaLive}
|
|
187
|
+
{...webAria({ 'aria-atomic': ariaAtomic ? 'true' : 'false' })}
|
|
188
|
+
style={[badgeBoxStyle(theme, { variant, size, color, glow }), entrance, pulseStyle, zoom.style]}
|
|
189
|
+
>
|
|
190
|
+
<BadgeContent
|
|
191
|
+
variant={variant}
|
|
192
|
+
size={size}
|
|
193
|
+
color={color}
|
|
194
|
+
icon={icon}
|
|
195
|
+
closable={closable}
|
|
196
|
+
content={content}
|
|
197
|
+
idFor={idFor}
|
|
198
|
+
onClose={zoom.close}
|
|
199
|
+
/>
|
|
200
|
+
</Animated.View>
|
|
201
|
+
</View>
|
|
202
|
+
)}
|
|
203
|
+
</View>
|
|
204
|
+
);
|
|
205
|
+
});
|
|
206
|
+
|
|
207
|
+
Badge.displayName = 'Badge';
|
|
208
|
+
|
|
209
|
+
const styles = StyleSheet.create({
|
|
210
|
+
/** MUI's badge root: `inline-flex`, with the chip positioned against it. */
|
|
211
|
+
anchor: { position: 'relative', alignSelf: 'flex-start', flexDirection: 'row' },
|
|
212
|
+
});
|
|
@@ -7,8 +7,25 @@ import {
|
|
|
7
7
|
glowPulseAnimation,
|
|
8
8
|
pulseAnimation,
|
|
9
9
|
shimmerAnimation } from './Badge.animations';
|
|
10
|
+
import {
|
|
11
|
+
BADGE_BORDER_WIDTH,
|
|
12
|
+
BADGE_CONTENT_GAP,
|
|
13
|
+
BADGE_FONT_WEIGHT,
|
|
14
|
+
BADGE_LETTER_SPACING_EM,
|
|
15
|
+
BADGE_SIZES,
|
|
16
|
+
BADGE_TRANSITION_EASING,
|
|
17
|
+
BADGE_TRANSITION_MS,
|
|
18
|
+
BOUNCE,
|
|
19
|
+
FADE_IN_SCALE,
|
|
20
|
+
GLOW,
|
|
21
|
+
HOVER_SCALE,
|
|
22
|
+
PULSE,
|
|
23
|
+
SHIMMER,
|
|
24
|
+
badgeAnchor,
|
|
25
|
+
} from './Badge.metrics';
|
|
10
26
|
import { badgeVariantStyles } from './Badge.variants';
|
|
11
27
|
import type { BadgeSize, BadgeVariant } from './Badge.types';
|
|
28
|
+
import { px } from '../../../tokens/theme';
|
|
12
29
|
|
|
13
30
|
export type BadgePalette = {
|
|
14
31
|
main: string;
|
|
@@ -37,67 +54,39 @@ const getColorFromTheme = (theme: Theme, color: string) => {
|
|
|
37
54
|
return colorMap[color] || theme.palette.primary;
|
|
38
55
|
};
|
|
39
56
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
57
|
+
// Derived from the shared metrics, not restated: the native `Badge` reads the
|
|
58
|
+
// same table, so the two renderers cannot disagree on a chip.
|
|
59
|
+
const sizeMap: Record<
|
|
60
|
+
BadgeSize,
|
|
61
|
+
{
|
|
62
|
+
minWidth: number;
|
|
63
|
+
height: number;
|
|
64
|
+
fontSize: string;
|
|
65
|
+
padding: string;
|
|
66
|
+
dotSize: number;
|
|
67
|
+
iconSize: string;
|
|
68
|
+
}
|
|
69
|
+
> = Object.fromEntries(
|
|
70
|
+
Object.entries(BADGE_SIZES).map(([size, metrics]) => [
|
|
71
|
+
size,
|
|
43
72
|
{
|
|
44
|
-
minWidth:
|
|
45
|
-
height:
|
|
46
|
-
fontSize:
|
|
47
|
-
padding:
|
|
48
|
-
dotSize:
|
|
49
|
-
iconSize:
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
padding: '0 3px',
|
|
57
|
-
dotSize: 6,
|
|
58
|
-
iconSize: '0.625rem' },
|
|
59
|
-
sm: {
|
|
60
|
-
minWidth: 16,
|
|
61
|
-
height: 16,
|
|
62
|
-
fontSize: '0.625rem',
|
|
63
|
-
padding: '0 4px',
|
|
64
|
-
dotSize: 8,
|
|
65
|
-
iconSize: '0.75rem' },
|
|
66
|
-
md: {
|
|
67
|
-
minWidth: 20,
|
|
68
|
-
height: 20,
|
|
69
|
-
fontSize: '0.75rem',
|
|
70
|
-
padding: '0 6px',
|
|
71
|
-
dotSize: 10,
|
|
72
|
-
iconSize: '0.875rem' },
|
|
73
|
-
lg: {
|
|
74
|
-
minWidth: 24,
|
|
75
|
-
height: 24,
|
|
76
|
-
fontSize: '0.875rem',
|
|
77
|
-
padding: '0 8px',
|
|
78
|
-
dotSize: 12,
|
|
79
|
-
iconSize: '1rem' },
|
|
80
|
-
xl: {
|
|
81
|
-
minWidth: 28,
|
|
82
|
-
height: 28,
|
|
83
|
-
fontSize: '1rem',
|
|
84
|
-
padding: '0 10px',
|
|
85
|
-
dotSize: 14,
|
|
86
|
-
iconSize: '1.125rem' } };
|
|
87
|
-
|
|
88
|
-
return sizeMap[size] || sizeMap.md;
|
|
89
|
-
};
|
|
73
|
+
minWidth: metrics.minWidth,
|
|
74
|
+
height: metrics.height,
|
|
75
|
+
fontSize: px(metrics.fontSize),
|
|
76
|
+
padding: `0 ${metrics.paddingHorizontal}px`,
|
|
77
|
+
dotSize: metrics.dotSize,
|
|
78
|
+
iconSize: px(metrics.iconSize),
|
|
79
|
+
},
|
|
80
|
+
]),
|
|
81
|
+
) as Record<
|
|
82
|
+
BadgeSize,
|
|
83
|
+
{ minWidth: number; height: number; fontSize: string; padding: string; dotSize: number; iconSize: string }
|
|
84
|
+
>;
|
|
90
85
|
|
|
91
|
-
export const
|
|
92
|
-
const positionMap: Record<string, { vertical: 'top' | 'bottom'; horizontal: 'left' | 'right' }> =
|
|
93
|
-
{
|
|
94
|
-
'top-right': { vertical: 'top', horizontal: 'right' },
|
|
95
|
-
'top-left': { vertical: 'top', horizontal: 'left' },
|
|
96
|
-
'bottom-right': { vertical: 'bottom', horizontal: 'right' },
|
|
97
|
-
'bottom-left': { vertical: 'bottom', horizontal: 'left' } };
|
|
86
|
+
export const getSizeStyles = (size: BadgeSize) => sizeMap[size] || sizeMap.md;
|
|
98
87
|
|
|
99
|
-
|
|
100
|
-
|
|
88
|
+
export const getAnchorOrigin = (position: string) =>
|
|
89
|
+
badgeAnchor((position || 'top-right') as Parameters<typeof badgeAnchor>[0]);
|
|
101
90
|
|
|
102
91
|
// Exactly one variant applies, so a lookup replaces ten mutually exclusive
|
|
103
92
|
// spreads inside the style object.
|
|
@@ -127,21 +116,21 @@ const badgeLightingStyles = ({
|
|
|
127
116
|
// Glow effect
|
|
128
117
|
...(glow &&
|
|
129
118
|
!pulse && {
|
|
130
|
-
boxShadow: `0 0
|
|
131
|
-
filter:
|
|
119
|
+
boxShadow: `0 0 ${GLOW.blur}px ${GLOW.spread}px ${alpha(colorPalette.main, GLOW.alpha)}`,
|
|
120
|
+
filter: `brightness(${GLOW.brightness})`,
|
|
132
121
|
'&:hover': {
|
|
133
|
-
boxShadow: `0 0
|
|
122
|
+
boxShadow: `0 0 ${GLOW.hoverBlur}px ${GLOW.hoverSpread}px ${alpha(colorPalette.main, GLOW.hoverAlpha)}` } }),
|
|
134
123
|
|
|
135
124
|
// Pulse animation
|
|
136
125
|
...(pulse &&
|
|
137
126
|
!glow && {
|
|
138
|
-
animation: `${pulseAnimation}
|
|
127
|
+
animation: `${pulseAnimation} ${PULSE.durationMs / 1000}s ease-in-out infinite` }),
|
|
139
128
|
|
|
140
129
|
// Both glow and pulse
|
|
141
130
|
...(glow &&
|
|
142
131
|
pulse && {
|
|
143
|
-
animation: `${glowPulseAnimation}
|
|
144
|
-
filter:
|
|
132
|
+
animation: `${glowPulseAnimation} ${PULSE.durationMs / 1000}s ease-in-out infinite, ${pulseAnimation} ${PULSE.durationMs / 1000}s ease-in-out infinite`,
|
|
133
|
+
filter: `brightness(${GLOW.brightness})`,
|
|
145
134
|
}),
|
|
146
135
|
|
|
147
136
|
});
|
|
@@ -166,11 +155,11 @@ const badgeAnimationStyles = ({
|
|
|
166
155
|
}): CSSObject => ({
|
|
167
156
|
...(animate &&
|
|
168
157
|
!bounce && {
|
|
169
|
-
animation: `${fadeInScaleAnimation}
|
|
158
|
+
animation: `${fadeInScaleAnimation} ${FADE_IN_SCALE.durationMs / 1000}s cubic-bezier(0.68, -0.55, 0.265, 1.55)` }),
|
|
170
159
|
|
|
171
160
|
// Bounce animation
|
|
172
161
|
...(bounce && {
|
|
173
|
-
animation: `${bounceAnimation}
|
|
162
|
+
animation: `${bounceAnimation} ${BOUNCE.durationMs / 1000}s ease-in-out` }),
|
|
174
163
|
|
|
175
164
|
// Shimmer effect
|
|
176
165
|
...(shimmer && {
|
|
@@ -191,10 +180,10 @@ const badgeAnimationStyles = ({
|
|
|
191
180
|
background: `linear-gradient(
|
|
192
181
|
90deg,
|
|
193
182
|
transparent,
|
|
194
|
-
${alpha(theme.palette.common.white,
|
|
183
|
+
${alpha(theme.palette.common.white, SHIMMER.alpha)},
|
|
195
184
|
transparent
|
|
196
185
|
)`,
|
|
197
|
-
animation: `${shimmerAnimation}
|
|
186
|
+
animation: `${shimmerAnimation} ${SHIMMER.durationMs / 1000}s infinite` } }) });
|
|
198
187
|
|
|
199
188
|
// The badge chip's own styling, lifted out so the styled() callback just
|
|
200
189
|
// forwards its props.
|
|
@@ -228,10 +217,10 @@ export const badgeStyles = ({
|
|
|
228
217
|
return {
|
|
229
218
|
'--glow-color': rgbValuesOf(colorPalette.main),
|
|
230
219
|
'& .MuiBadge-badge': {
|
|
231
|
-
transition:
|
|
232
|
-
fontWeight:
|
|
233
|
-
border:
|
|
234
|
-
letterSpacing:
|
|
220
|
+
transition: `all ${BADGE_TRANSITION_MS / 1000}s ${BADGE_TRANSITION_EASING}`,
|
|
221
|
+
fontWeight: BADGE_FONT_WEIGHT,
|
|
222
|
+
border: `${BADGE_BORDER_WIDTH}px solid ${theme.palette.background.paper}`,
|
|
223
|
+
letterSpacing: `${BADGE_LETTER_SPACING_EM}em`,
|
|
235
224
|
textTransform:
|
|
236
225
|
customVariant === 'gradient' || customVariant === 'glass' ? 'uppercase' : 'none',
|
|
237
226
|
willChange: 'transform, opacity',
|
|
@@ -249,7 +238,7 @@ export const badgeStyles = ({
|
|
|
249
238
|
paddingLeft: sizeStyles.padding.split(' ')[1],
|
|
250
239
|
display: 'inline-flex',
|
|
251
240
|
alignItems: 'center',
|
|
252
|
-
gap:
|
|
241
|
+
gap: `${BADGE_CONTENT_GAP}px`,
|
|
253
242
|
}),
|
|
254
243
|
|
|
255
244
|
// Animation on mount
|
|
@@ -265,6 +254,6 @@ export const badgeStyles = ({
|
|
|
265
254
|
...badgeLightingStyles({ glow, pulse, colorPalette }),
|
|
266
255
|
|
|
267
256
|
'&:not(.MuiBadge-dot):hover': {
|
|
268
|
-
transform:
|
|
257
|
+
transform: `scale(${HOVER_SCALE})`,
|
|
269
258
|
zIndex: 1 } } };
|
|
270
259
|
}
|
|
@@ -13,7 +13,9 @@ import {
|
|
|
13
13
|
resolveBadgeProps } from './Badge.helpers';
|
|
14
14
|
import type { ResolvedBadgeProps } from './Badge.helpers';
|
|
15
15
|
import { buildBadgeContent } from './BadgeContent';
|
|
16
|
+
import { CLOSE_DELAY_MS, MOUNT_ANIMATION_MS } from './Badge.metrics';
|
|
16
17
|
import type { BadgeProps, BadgeSize, BadgeVariant } from './Badge.types';
|
|
18
|
+
import { resolveTestId } from '../../../platform/test-id';
|
|
17
19
|
export type { BadgeProps } from './Badge.types';
|
|
18
20
|
|
|
19
21
|
// Define pulse animation
|
|
@@ -63,8 +65,6 @@ const StyledBadge = styled(MuiBadge, {
|
|
|
63
65
|
hasIcon });
|
|
64
66
|
});
|
|
65
67
|
|
|
66
|
-
const CLOSE_DELAY_MS = 300;
|
|
67
|
-
const ANIMATION_MS = 1000;
|
|
68
68
|
|
|
69
69
|
// A one-shot flag so bounce/animate run on mount and then stop.
|
|
70
70
|
const useMountAnimation = (enabled: boolean) => {
|
|
@@ -74,7 +74,7 @@ const useMountAnimation = (enabled: boolean) => {
|
|
|
74
74
|
if (!enabled) return;
|
|
75
75
|
|
|
76
76
|
setIsAnimating(true);
|
|
77
|
-
const timer = window.setTimeout(() => setIsAnimating(false),
|
|
77
|
+
const timer = window.setTimeout(() => setIsAnimating(false), MOUNT_ANIMATION_MS);
|
|
78
78
|
return () => window.clearTimeout(timer);
|
|
79
79
|
}, [enabled]);
|
|
80
80
|
|
|
@@ -84,7 +84,7 @@ const useMountAnimation = (enabled: boolean) => {
|
|
|
84
84
|
// The chip itself. Local because StyledBadge cannot cross a module boundary
|
|
85
85
|
// (TS2742).
|
|
86
86
|
const BadgeSurface: React.FC<
|
|
87
|
-
ResolvedBadgeProps & {
|
|
87
|
+
ResolvedBadgeProps<BadgeProps> & {
|
|
88
88
|
innerRef: React.Ref<HTMLSpanElement>;
|
|
89
89
|
isVisible: boolean;
|
|
90
90
|
isAnimating: boolean;
|
|
@@ -150,7 +150,11 @@ export const Badge = React.forwardRef<HTMLSpanElement, BadgeProps>((componentPro
|
|
|
150
150
|
'aria-label': ariaLabel,
|
|
151
151
|
'aria-live': ariaLive = 'polite',
|
|
152
152
|
'aria-atomic': ariaAtomic = true,
|
|
153
|
-
'data-testid':
|
|
153
|
+
'data-testid': _domTestId,
|
|
154
|
+
// The house and React Native spellings of the same id; they name the
|
|
155
|
+
// component on both sides and must not reach the DOM as attributes.
|
|
156
|
+
testID: _testID,
|
|
157
|
+
dataTestId: _dataTestId,
|
|
154
158
|
className: _className,
|
|
155
159
|
content: _content,
|
|
156
160
|
badgeContent: _badgeContent,
|
|
@@ -167,13 +171,14 @@ export const Badge = React.forwardRef<HTMLSpanElement, BadgeProps>((componentPro
|
|
|
167
171
|
window.setTimeout(() => onClose?.(), CLOSE_DELAY_MS);
|
|
168
172
|
};
|
|
169
173
|
|
|
174
|
+
const badgeId = resolveTestId(resolved);
|
|
170
175
|
const rawContent = badgeContentOf(resolved);
|
|
171
176
|
const finalBadgeContent = buildBadgeContent({
|
|
172
177
|
variant,
|
|
173
178
|
size,
|
|
174
179
|
icon,
|
|
175
180
|
closable,
|
|
176
|
-
dataTestId,
|
|
181
|
+
dataTestId: badgeId,
|
|
177
182
|
baseContent: variant === 'count' ? formatCount(rawContent, { max, showZero }) : rawContent,
|
|
178
183
|
onClose: handleClose });
|
|
179
184
|
|
|
@@ -184,6 +189,7 @@ export const Badge = React.forwardRef<HTMLSpanElement, BadgeProps>((componentPro
|
|
|
184
189
|
return (
|
|
185
190
|
<BadgeSurface
|
|
186
191
|
{...resolved}
|
|
192
|
+
data-testid={badgeId}
|
|
187
193
|
innerRef={ref}
|
|
188
194
|
isVisible={isVisible}
|
|
189
195
|
isAnimating={isAnimating}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { StyleProp, ViewProps, ViewStyle } from 'react-native';
|
|
2
|
+
|
|
3
|
+
import type { BadgeBaseProps } from './Badge.base';
|
|
4
|
+
|
|
5
|
+
export type {
|
|
6
|
+
BadgeBaseProps,
|
|
7
|
+
BadgePosition,
|
|
8
|
+
BadgeSize,
|
|
9
|
+
BadgeVariant,
|
|
10
|
+
} from './Badge.base';
|
|
11
|
+
|
|
12
|
+
/** The native `Badge`: the shared contract, plus a `View`'s own props. */
|
|
13
|
+
export type BadgeProps = BadgeBaseProps &
|
|
14
|
+
Omit<ViewProps, keyof BadgeBaseProps | 'style'> & {
|
|
15
|
+
style?: StyleProp<ViewStyle>;
|
|
16
|
+
};
|