@okta/odyssey-contribution-tooling 1.48.0 → 1.50.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 +8 -0
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +2 -2
- package/dist/appswitcher/admin-app-default.svg +0 -6
- package/dist/appswitcher/admin-app-selected.svg +0 -6
- package/dist/appswitcher/aerial-default.svg +0 -7
- package/dist/appswitcher/aerial-selected.svg +0 -7
- package/dist/appswitcher/okta-dashboard-default.svg +0 -7
- package/dist/appswitcher/okta-dashboard-selected.svg +0 -7
- package/dist/appswitcher/privileged-access-default.svg +0 -4
- package/dist/appswitcher/privileged-access-selected.svg +0 -4
- package/dist/appswitcher/workflows-default.svg +0 -5
- package/dist/appswitcher/workflows-selected.svg +0 -5
- package/dist/assets/Accordion-MTHvu5cR.js +0 -1
- package/dist/assets/Accordion.stories-DniSJ38i.js +0 -85
- package/dist/assets/AccordionSummary-Byc6MkHu.js +0 -1
- package/dist/assets/AlertTitle-BDkgiA29.js +0 -1
- package/dist/assets/AppSwitcher-mUx_f1r6.js +0 -21
- package/dist/assets/AppSwitcher.stories-CENgxWSC.js +0 -100
- package/dist/assets/AppTile _labs_.stories-B5BjKm0o.js +0 -136
- package/dist/assets/ArrowDropDown-Dnrg-0Q8.js +0 -1
- package/dist/assets/ArrowRight-BquvVn3D.js +0 -1
- package/dist/assets/Autocomplete-Bh3XRXMy.js +0 -1
- package/dist/assets/Autocomplete-CknstIK_.js +0 -1
- package/dist/assets/Autocomplete.stories-DNDWoB5E.js +0 -316
- package/dist/assets/Badge-DFZYqSZN.js +0 -11
- package/dist/assets/Banner-25ZggH76.js +0 -1
- package/dist/assets/Banner.stories-Dz37neYC.js +0 -74
- package/dist/assets/BaseButton-Cd1oZPsh.js +0 -11
- package/dist/assets/BaseMenuButton-DCwowxQ6.js +0 -1
- package/dist/assets/Box-B-R2QRDU.js +0 -1
- package/dist/assets/Box-B6KmU4_J.js +0 -1
- package/dist/assets/Box-B92Cdrku.js +0 -11
- package/dist/assets/Box.stories-BCtoarqr.js +0 -38
- package/dist/assets/Breadcrumbs-BGJJeoxM.js +0 -6
- package/dist/assets/Breadcrumbs.stories-BTEZLo9U.js +0 -79
- package/dist/assets/Bug-Z3X3t5xp.js +0 -1
- package/dist/assets/Button-BvUGu5Sm.js +0 -1
- package/dist/assets/Button-DPUOjyZy.js +0 -11
- package/dist/assets/Button.stories-CLRsJ0J2.js +0 -271
- package/dist/assets/ButtonBase-CrcIXP69.js +0 -74
- package/dist/assets/Calendar-DnwsjheN.js +0 -1
- package/dist/assets/Callout-qkeUDNKn.js +0 -1
- package/dist/assets/Callout.stories-DVWATUoj.js +0 -105
- package/dist/assets/Card-DL97TZJd.js +0 -1
- package/dist/assets/Card-DqLPNu4w.js +0 -8
- package/dist/assets/Card.stories-ROWJyBI0.js +0 -56
- package/dist/assets/CardActionArea-BaL2GhSM.js +0 -1
- package/dist/assets/CardActions-C1bW_Jqo.js +0 -1
- package/dist/assets/Checkbox-OauVZWc5.js +0 -1
- package/dist/assets/Checkbox-eGdyySzm.js +0 -1
- package/dist/assets/Checkbox.stories-DwmuFw2j.js +0 -96
- package/dist/assets/CheckboxGroup-BQ5GiUey.js +0 -1
- package/dist/assets/CheckboxGroup.stories-BbHNliqq.js +0 -92
- package/dist/assets/ChevronRight-BLkvXBUf.js +0 -1
- package/dist/assets/ChevronUp-Br-QC-XK.js +0 -1
- package/dist/assets/Chip-B9WkuA4b.js +0 -1
- package/dist/assets/CircularProgress-AX8KCiV6.js +0 -28
- package/dist/assets/CircularProgress-DxY3QwHW.js +0 -1
- package/dist/assets/CircularProgress.stories-a_Rse-5m.js +0 -44
- package/dist/assets/Clock-8HOQy_d4.js +0 -1
- package/dist/assets/Close-BjXKhBr_.js +0 -1
- package/dist/assets/Code Styling Guidelines-BkGO8zp-.js +0 -14
- package/dist/assets/Collapse-DtQCvyEw.js +0 -1
- package/dist/assets/Color-YHDXOIA2-CcoN0wsl.js +0 -1
- package/dist/assets/CssBaseline-CI1_OCUX.js +0 -191
- package/dist/assets/CssBaseline.stories-BSLs5ScZ.js +0 -364
- package/dist/assets/Custom Theming-WlDJkwzT.js +0 -135
- package/dist/assets/Custom Theming.stories-Kx3noLIn.js +0 -95
- package/dist/assets/DataFilters _labs_-BIYE5QJU.js +0 -55
- package/dist/assets/DataFilters _labs_.stories-BdV81MCI.js +0 -31
- package/dist/assets/DataFilters-KxLw7hL5.js +0 -1
- package/dist/assets/DataTable _labs_-D_W9CY5T.js +0 -41
- package/dist/assets/DataTable _labs_.stories-CTl54dDN.js +0 -21
- package/dist/assets/DataTable-BJQ8WkUd.js +0 -21
- package/dist/assets/DataTable-bZz790ci.js +0 -404
- package/dist/assets/DataTable.stories-9eBclyx2.js +0 -438
- package/dist/assets/DataView _labs_-AutzTAhE.js +0 -332
- package/dist/assets/DataView _labs_.stories-CO0XGhOV.js +0 -438
- package/dist/assets/DataView-CHGdxu-Z.js +0 -91
- package/dist/assets/DataView.stories-6cnSmpm3.js +0 -954
- package/dist/assets/DatePicker-BGoHW8Is.js +0 -1
- package/dist/assets/DatePicker-C6TIvuN7.js +0 -11
- package/dist/assets/DatePicker.stories-DldeVOlB.js +0 -133
- package/dist/assets/DateTimePicker-DKGE8593.js +0 -1
- package/dist/assets/DateTimePicker.stories-TBpe3AjQ.js +0 -158
- package/dist/assets/Design Tokens-BnlBB5OL.js +0 -4
- package/dist/assets/Dialog-BkOLgyLu.js +0 -1
- package/dist/assets/Dialog.stories-BQZpS-f5.js +0 -201
- package/dist/assets/DialogContent-B-pM1DP1.js +0 -1
- package/dist/assets/DialogTitle-DA2nrmUc.js +0 -1
- package/dist/assets/Divider-CAwVs6Y1.js +0 -1
- package/dist/assets/DocsRenderer-CFRXHY34-kO-n-5EB.js +0 -2
- package/dist/assets/Documentation-CBbHUjXC.js +0 -1
- package/dist/assets/Download-VHpUH0as.js +0 -1
- package/dist/assets/Drawer-C9M8pytV.js +0 -33
- package/dist/assets/Drawer.stories-DpNTQVxG.js +0 -95
- package/dist/assets/EmptyState-FpIKkMpd.js +0 -11
- package/dist/assets/EmptyState.stories-CkUF2dIR.js +0 -11
- package/dist/assets/ExampleButton.stories-CbAFs20l.js +0 -320
- package/dist/assets/Extending Translations-mp_vyXoH.js +0 -145
- package/dist/assets/ExternalLink-lox07hAR.js +0 -1
- package/dist/assets/Fade-CHnXmzFb.js +0 -1
- package/dist/assets/Field-BxkyNVQW.js +0 -11
- package/dist/assets/FieldHint-D5VttvwL.js +0 -1
- package/dist/assets/Fieldset-Dp9uCwiB.js +0 -11
- package/dist/assets/Fieldset.stories-Wa9hG8Z0.js +0 -15
- package/dist/assets/FileUploader.stories-CxYwF2DZ.js +0 -58
- package/dist/assets/Filter-BiREetkX.js +0 -1
- package/dist/assets/Folder-8esChg_E.js +0 -1
- package/dist/assets/Form Field Accessibility-BCFouYXt.js +0 -18
- package/dist/assets/Form-CJrxMkwr.js +0 -11
- package/dist/assets/Form.stories-Bc84FwlQ.js +0 -69
- package/dist/assets/FormControlLabel-CoGABX1G.js +0 -1
- package/dist/assets/FormGroup-D2d8E3Cw.js +0 -1
- package/dist/assets/FormHelperText-Ca69g4Je.js +0 -1
- package/dist/assets/FormLabel-EOlXQpGp.js +0 -1
- package/dist/assets/FullScreenOverlay-Bujsxbxh.js +0 -11
- package/dist/assets/Generating Icons-pN6RBs4J.js +0 -16
- package/dist/assets/Globe-BHk1B5d7.js +0 -1
- package/dist/assets/Grid-B7XSvQ_X.js +0 -1
- package/dist/assets/Group-DWmiPyzE.js +0 -1
- package/dist/assets/GroupPicker _labs_.stories-D0PDtKKA.js +0 -33
- package/dist/assets/Grow-6R6cTzr4.js +0 -1
- package/dist/assets/Hide-Bvhl5PVN.js +0 -1
- package/dist/assets/Hint-DTEjQAxl.js +0 -11
- package/dist/assets/Home-CUQc6tB8.js +0 -1
- package/dist/assets/Icon _icons_.stories-S2muaIBP.js +0 -16
- package/dist/assets/IconButton-Wwvz84xG.js +0 -1
- package/dist/assets/IconWithTooltip _icons_.stories-BiiIBhOv.js +0 -19
- package/dist/assets/InformationCircle-DYQV39lt.js +0 -1
- package/dist/assets/InputAdornment-Dj-8HF_1.js +0 -1
- package/dist/assets/InputBase-6reb9B7r.js +0 -2
- package/dist/assets/Installing odyssey-react-mui-DuIfuEaw.js +0 -216
- package/dist/assets/Introduction-BTH-MnwV.js +0 -36
- package/dist/assets/Layout-BndkhA1_.js +0 -11
- package/dist/assets/Layout.stories-BwMtW-cW.js +0 -285
- package/dist/assets/Legacy Migrations-BfDwGUg3.js +0 -86
- package/dist/assets/Link-BQo2zH0c.js +0 -1
- package/dist/assets/Link-C5sM1_ZF.js +0 -11
- package/dist/assets/Link-DcsndbPK.js +0 -1
- package/dist/assets/Link.stories-DiVQZsn1.js +0 -43
- package/dist/assets/List-CNCQEpRl.js +0 -1
- package/dist/assets/List-_p0jkXPM.js +0 -1
- package/dist/assets/ListItem-BLYwuKOG.js +0 -1
- package/dist/assets/ListSubheader-DO359rMr.js +0 -1
- package/dist/assets/Menu-CU_mHT7L.js +0 -1
- package/dist/assets/MenuButton-CGRa_Y2p.js +0 -9
- package/dist/assets/MenuButton-DvVmjwMC.js +0 -11
- package/dist/assets/MenuButton.stories-rLpv4nq1.js +0 -246
- package/dist/assets/MenuContext-DKMyPMNY.js +0 -11
- package/dist/assets/MenuItem-DoUaLmgU.js +0 -1
- package/dist/assets/MenuItem-oi_JaUho.js +0 -1
- package/dist/assets/MenuItem.stories-Ba6BR5kj.js +0 -29
- package/dist/assets/MenuList-0OHGr5AC.js +0 -1
- package/dist/assets/Modal-B12sS2Yh.js +0 -1
- package/dist/assets/More-BgQrTkKM.js +0 -1
- package/dist/assets/MuiPropsContext-DhRylJZk.js +0 -11
- package/dist/assets/NativeSelect.stories-CYtg4GGs.js +0 -173
- package/dist/assets/OdysseyProvider-BPLFYiwr.js +0 -66
- package/dist/assets/OdysseyStorybookThemeDecorator-CGH8visK.js +0 -1
- package/dist/assets/OdysseyThemeProvider-BykOaJq8.js +0 -189
- package/dist/assets/PageHeader.stories-Cg0XA0p_.js +0 -57
- package/dist/assets/PageHeader.stories-DHDJTskZ.js +0 -329
- package/dist/assets/PageTemplate _labs_-Bi3xwFV2.js +0 -8
- package/dist/assets/PageTemplate _labs_.stories-DdUcW43S.js +0 -306
- package/dist/assets/PageTemplate-mjLVQesI.js +0 -21
- package/dist/assets/PageTemplate.stories-BD8Hafdu.js +0 -197
- package/dist/assets/PaginatedTable _labs_.stories-Lt6yWTDo.js +0 -65
- package/dist/assets/Pagination-BTycGMV-.js +0 -11
- package/dist/assets/Pagination.stories-rN3x32X9.js +0 -17
- package/dist/assets/Paper-DwBg74qy.js +0 -1
- package/dist/assets/PasswordField.stories-BdnDY-tl.js +0 -129
- package/dist/assets/Picker _labs_.stories-D3FvB-m5.js +0 -18
- package/dist/assets/PickerWithOptionAdornment _labs_.stories-BxW5XACd.js +0 -70
- package/dist/assets/PlaceholderLogo-JfVvgA23.js +0 -11
- package/dist/assets/Popper-CSwIGEpk.js +0 -1
- package/dist/assets/Portal-CsPQSHsR.js +0 -1
- package/dist/assets/Radio-7iHx2pBU.js +0 -1
- package/dist/assets/Radio-AD-L5UNl.js +0 -1
- package/dist/assets/Radio.stories-eZmvoamt.js +0 -63
- package/dist/assets/RadioGroup-C_zn6OtS.js +0 -1
- package/dist/assets/RadioGroup-Mx_cTqVX.js +0 -1
- package/dist/assets/RadioGroup-yPcOJn0w.js +0 -10
- package/dist/assets/RadioGroup.stories-CackbN0d.js +0 -138
- package/dist/assets/Refresh-CgZVXlSy.js +0 -1
- package/dist/assets/ResourceAccessPolicyComponentsStorybookThemeDecorator-Xen2vDro.js +0 -212
- package/dist/assets/Right-to-Left (RTL)-CALRs8aM.js +0 -62
- package/dist/assets/ScreenReaderText-D9dVDvYs.js +0 -15
- package/dist/assets/ScreenReaderText-DbrZU7M5.js +0 -1
- package/dist/assets/ScreenReaderText.stories-CuVJmeWD.js +0 -8
- package/dist/assets/Search-BSlcf4bB.js +0 -1
- package/dist/assets/SearchDropdown _labs_.stories-CQype98o.js +0 -53
- package/dist/assets/SearchField-glDE5e-X.js +0 -1
- package/dist/assets/SearchField.stories-B_myC5_S.js +0 -37
- package/dist/assets/Select-BWJ6-p1Z.js +0 -15
- package/dist/assets/Select-VvpDulqk.js +0 -1
- package/dist/assets/Select.stories-BXXrgt5o.js +0 -293
- package/dist/assets/Server-DS5iERo2.js +0 -1
- package/dist/assets/Settings-SRsJGOHl.js +0 -1
- package/dist/assets/Setup-Ri7IU42o.js +0 -7
- package/dist/assets/Shadow DOM-DK_1Epv_.js +0 -64
- package/dist/assets/Show-DXIrBgNq.js +0 -1
- package/dist/assets/SideNav-CUpwLG1e.js +0 -85
- package/dist/assets/SideNav-QMiST_j6.js +0 -131
- package/dist/assets/SideNav.stories-l5XPKDfB.js +0 -207
- package/dist/assets/Skeleton-DAUyPclv.js +0 -51
- package/dist/assets/Snackbar-DWLMI8Az.js +0 -1
- package/dist/assets/Stack-t9yXrJ7r.js +0 -1
- package/dist/assets/Stack.stories-zmhDXY_k.js +0 -1
- package/dist/assets/StaticTable _labs_.stories-DJCAtW2q.js +0 -34
- package/dist/assets/Status-CdgTiE4c.js +0 -1
- package/dist/assets/Status.stories-D5tSpO2F.js +0 -66
- package/dist/assets/Surface-BCTO1YR-.js +0 -1
- package/dist/assets/Switch.stories-r3bYAZpt.js +0 -61
- package/dist/assets/SwitchBase-CWdXZnig.js +0 -1
- package/dist/assets/Sync-CCP_JZB8.js +0 -1
- package/dist/assets/Tabs-DCV9oDtT.js +0 -23
- package/dist/assets/Tabs-Dxt5P3aJ.js +0 -1
- package/dist/assets/Tabs.stories-CmjPJB02.js +0 -100
- package/dist/assets/Tag-C_iW2sj3.js +0 -11
- package/dist/assets/Tag.stories-uilRDgPB.js +0 -96
- package/dist/assets/TagList-cWni94xt.js +0 -1
- package/dist/assets/TextField-BIepBlYn.js +0 -1
- package/dist/assets/TextField.stories-DkCMFN0S.js +0 -149
- package/dist/assets/Toast.stories-BgAm1BNQ.js +0 -134
- package/dist/assets/ToastManager.stories-DToM8bFE.js +0 -196
- package/dist/assets/Tooltip-DQDBPKMu.js +0 -11
- package/dist/assets/Tooltip-D_pBGtcj.js +0 -1
- package/dist/assets/Tooltip.stories-CgIybZDx.js +0 -68
- package/dist/assets/TopNav-Dwo-KfAw.js +0 -11
- package/dist/assets/TopNav.stories-z9mNMFB3.js +0 -13
- package/dist/assets/TransitionGroupContext-DAL84N7p.js +0 -1
- package/dist/assets/Typography-B7ktrxCD.js +0 -1
- package/dist/assets/Typography-CQfngSjD.js +0 -1
- package/dist/assets/Typography-CSpPZFTF.js +0 -1
- package/dist/assets/Typography-DBt3ajUl.js +0 -9
- package/dist/assets/Typography.stories-CitS-iTX.js +0 -73
- package/dist/assets/Typography.stories-dzT0O_H3.js +0 -139
- package/dist/assets/UiShell.stories-BV5mK0Oz.js +0 -558
- package/dist/assets/UiShellProvider-Bm9plvoZ.js +0 -31
- package/dist/assets/Upload-DH1T10x5.js +0 -1
- package/dist/assets/User-CvYTA860.js +0 -1
- package/dist/assets/UserProfile-DrnAMPM1.js +0 -11
- package/dist/assets/UserProfile.stories-C4EJFTV8.js +0 -14
- package/dist/assets/UserProfileMenuButton.stories-Dhe9t4Oh.js +0 -30
- package/dist/assets/Video-D8qbHdF4.js +0 -1
- package/dist/assets/WorkflowsComponentsStorybookThemeDecorator-DJR9iMBt.js +0 -197
- package/dist/assets/_commonjsHelpers-gnU0ypJ3.js +0 -1
- package/dist/assets/assertThisInitialized-B9jnkVVz.js +0 -1
- package/dist/assets/axe-4JP0vCEZ.js +0 -30
- package/dist/assets/axeRun-B-LchFqf.js +0 -11
- package/dist/assets/chunk-XP5HYGXS-BpfKkqn7.js +0 -1
- package/dist/assets/client-ByW5HbEz.js +0 -1
- package/dist/assets/colorManipulator-C6C6_xuT.js +0 -1
- package/dist/assets/constants-CGUp4oSR.js +0 -11
- package/dist/assets/constants-CyailK6t.js +0 -11
- package/dist/assets/createChainedFunction-BO_9K8Jh.js +0 -1
- package/dist/assets/createStyled-B0CJenTX.js +0 -1
- package/dist/assets/createSvgIcon-Bv_3NNsK.js +0 -1
- package/dist/assets/createUniqueId-ByTaVY63.js +0 -1
- package/dist/assets/debounce-Be36O1Ab.js +0 -1
- package/dist/assets/dialogActionsClasses-d6kliu8x.js +0 -1
- package/dist/assets/emotion-react-jsx-runtime.browser.esm-Cn-06VTs.js +0 -1
- package/dist/assets/entry-preview-Bi6MTClg.js +0 -2
- package/dist/assets/entry-preview-docs-BKXv92OK.js +0 -46
- package/dist/assets/fieldComponentPropsMetaData-BqbNLw6V.js +0 -11
- package/dist/assets/getReactElementRef-Bs64nbeG.js +0 -1
- package/dist/assets/getScrollbarSize-Bqq2hMjQ.js +0 -1
- package/dist/assets/i18next-7SyOfhCu.js +0 -1
- package/dist/assets/iconUtils-C1HBA-0w.js +0 -11
- package/dist/assets/iframe-C7GWUW76.js +0 -211
- package/dist/assets/index-6QUE-j0v.js +0 -1
- package/dist/assets/index-B-lxVbXh.js +0 -1
- package/dist/assets/index-B5xazMy1.js +0 -1
- package/dist/assets/index-BJMTVygn.js +0 -240
- package/dist/assets/index-BJTM6NaI.js +0 -192
- package/dist/assets/index-BeeV6X6A.js +0 -1
- package/dist/assets/index-CXQShRbs.js +0 -8
- package/dist/assets/index-DfE121Jj.js +0 -384
- package/dist/assets/index-DieBXP3Z.js +0 -24
- package/dist/assets/index-DkrUiDVY.js +0 -1
- package/dist/assets/index-DoKqiSdS.js +0 -1
- package/dist/assets/index-DrFu-skq.js +0 -6
- package/dist/assets/index-NdkWRN8K.js +0 -9
- package/dist/assets/index.esm-BliC9-aw.js +0 -1
- package/dist/assets/index.esm-XFhSJO0s.js +0 -138
- package/dist/assets/index.modern-CkASn_bb.js +0 -14
- package/dist/assets/inheritsLoose-DTTkq0Su.js +0 -1
- package/dist/assets/inputUtils-Dbi8XkA6.js +0 -11
- package/dist/assets/isHostComponent-DVu5iVWx.js +0 -1
- package/dist/assets/jsx-runtime-CnH95YSl.js +0 -9
- package/dist/assets/matchers-7Z3WT2CE-T3xScrR7.js +0 -14
- package/dist/assets/ownerDocument-DW-IO8s5.js +0 -1
- package/dist/assets/ownerWindow-HkKU3E4x.js +0 -1
- package/dist/assets/personData-BOnk54P3.js +0 -11
- package/dist/assets/personData-L8dJyb3X.js +0 -1
- package/dist/assets/pickerComponentPropsMetadata-CozVRRyR.js +0 -21
- package/dist/assets/popper-aiaZgC6t.js +0 -1
- package/dist/assets/preview-B8lJiyuQ.js +0 -34
- package/dist/assets/preview-BAx1BwgB.js +0 -1
- package/dist/assets/preview-BBWR9nbA.js +0 -1
- package/dist/assets/preview-BWzBA1C2.js +0 -396
- package/dist/assets/preview-BaoH-L4j.js +0 -1
- package/dist/assets/preview-CYp4EYYZ.js +0 -1
- package/dist/assets/preview-CvbIS5ZJ.js +0 -1
- package/dist/assets/preview-DGUiP6tS.js +0 -7
- package/dist/assets/preview-DHQbi4pV.js +0 -1
- package/dist/assets/preview-DXRUsonv.js +0 -2
- package/dist/assets/preview-MBifGIx_.js +0 -1
- package/dist/assets/preview-NdtsJkHc.js +0 -2
- package/dist/assets/pxToRem-BrMhKUxS.js +0 -11
- package/dist/assets/queryOdysseySelector-CwauhQve.js +0 -187
- package/dist/assets/react-18-u8niHpKc.js +0 -1
- package/dist/assets/renderUiShell.stories-Pp6_Iqzc.js +0 -866
- package/dist/assets/resolveComponentProps-TTQVZ4OZ.js +0 -1
- package/dist/assets/tableSortLabelClasses-C7INAE6Y.js +0 -1
- package/dist/assets/test-utils-H9lH7T5D.js +0 -9
- package/dist/assets/uiShellSharedConstants-DD9UP82e.js +0 -11
- package/dist/assets/useAutocomplete-CD_GwhMI.js +0 -11
- package/dist/assets/useControlled-NQulfz4l.js +0 -1
- package/dist/assets/useFormControl-BMISTZuX.js +0 -1
- package/dist/assets/useIsFocusVisible-DH0qxT5e.js +0 -1
- package/dist/assets/useMobilePicker-CRiGjvfW.js +0 -6
- package/dist/assets/useMountLifecycleEffect-CjsUCFhB.js +0 -11
- package/dist/assets/useOdysseyDateFields-D1TYF4ew.js +0 -61
- package/dist/assets/useScrollIndication-Dq_i6CX-.js +0 -31
- package/dist/assets/useSlot-VN2O4BOA.js +0 -1
- package/dist/assets/useThemeProps-BgDANuN6.js +0 -1
- package/dist/assets/useThemeProps-DJ3F4KkW.js +0 -1
- package/dist/assets/useUniqueId-Bsgqe1tm.js +0 -11
- package/dist/assets/utilities.esm-DpQ0TZP_.js +0 -5
- package/dist/assets/utils-BdcLUgCD.js +0 -1
- package/dist/assets/utils-iop7lDec.js +0 -1
- package/dist/assets/v4-CtRu48qb.js +0 -1
- package/dist/assets/visuallyHidden-Dan1xhjv.js +0 -1
- package/dist/favicon.svg +0 -1
- package/dist/iframe.html +0 -748
- package/dist/index.cjs +0 -231
- package/dist/index.d.ts +0 -22
- package/dist/index.d.ts.map +0 -1
- package/dist/index.html +0 -203
- package/dist/index.js +0 -25
- package/dist/index.json +0 -1
- package/dist/index.mjs +0 -229
- package/dist/index.scss +0 -549
- package/dist/nunito-sans-bold-italic.woff2 +0 -0
- package/dist/nunito-sans-bold.woff2 +0 -0
- package/dist/nunito-sans-italic.woff2 +0 -0
- package/dist/nunito-sans-regular.woff2 +0 -0
- package/dist/project.json +0 -1
- package/dist/sb-addons/a11y-3/manager-bundle.js +0 -220
- package/dist/sb-addons/docs-1/manager-bundle.js +0 -242
- package/dist/sb-addons/essentials-actions-5/manager-bundle.js +0 -3
- package/dist/sb-addons/essentials-backgrounds-6/manager-bundle.js +0 -12
- package/dist/sb-addons/essentials-controls-4/manager-bundle.js +0 -402
- package/dist/sb-addons/essentials-measure-9/manager-bundle.js +0 -3
- package/dist/sb-addons/essentials-outline-10/manager-bundle.js +0 -3
- package/dist/sb-addons/essentials-toolbars-8/manager-bundle.js +0 -3
- package/dist/sb-addons/essentials-viewport-7/manager-bundle.js +0 -3
- package/dist/sb-addons/interactions-11/manager-bundle.js +0 -222
- package/dist/sb-addons/links-2/manager-bundle.js +0 -3
- package/dist/sb-addons/rtl-12/manager-bundle.js +0 -3
- package/dist/sb-addons/storybook-13/manager-bundle.js +0 -3
- package/dist/sb-addons/storybook-core-core-server-presets-0/common-manager-bundle.js +0 -3
- package/dist/sb-common-assets/favicon.svg +0 -1
- package/dist/sb-common-assets/nunito-sans-bold-italic.woff2 +0 -0
- package/dist/sb-common-assets/nunito-sans-bold.woff2 +0 -0
- package/dist/sb-common-assets/nunito-sans-italic.woff2 +0 -0
- package/dist/sb-common-assets/nunito-sans-regular.woff2 +0 -0
- package/dist/sb-manager/globals-module-info.js +0 -1052
- package/dist/sb-manager/globals-runtime.js +0 -42127
- package/dist/sb-manager/globals.js +0 -48
- package/dist/sb-manager/runtime.js +0 -12048
- package/dist/tsconfig.tsbuildinfo +0 -1
|
@@ -1,246 +0,0 @@
|
|
|
1
|
-
import{j as n}from"./jsx-runtime-CnH95YSl.js";import{w as f,e as L,u as hn,a as gn}from"./index-BJMTVygn.js";import{a as Mn}from"./axeRun-B-LchFqf.js";import{i as k}from"./iconUtils-C1HBA-0w.js";import{O as bn}from"./OdysseyStorybookThemeDecorator-CGH8visK.js";import{f as yn}from"./fieldComponentPropsMetaData-BqbNLw6V.js";import{m as j}from"./BaseMenuButton-DCwowxQ6.js";import{b as v}from"./BaseButton-Cd1oZPsh.js";import{M as un}from"./MenuButton-DvVmjwMC.js";import{M as e}from"./MenuItem-DoUaLmgU.js";import{L as w}from"./ListSubheader-DO359rMr.js";import{D as ln}from"./Divider-CAwVs6Y1.js";import{M as I}from"./Box-B-R2QRDU.js";import{f as xn,c as s,a as E}from"./Typography-B7ktrxCD.js";import{M as c}from"./Link-BQo2zH0c.js";import{a as Bn}from"./index-DkrUiDVY.js";import{u as In}from"./OdysseyThemeProvider-BykOaJq8.js";import{M as mn}from"./Group-DWmiPyzE.js";import{M as fn}from"./Globe-BHk1B5d7.js";import{M as Ln}from"./Calendar-DnwsjheN.js";const i=({children:o})=>{const t=In();return n.jsx(I,{sx:{marginBottom:t.Spacing4},children:o})},kn={component:un,decorators:[bn],tags:["autodocs"],argTypes:{ariaDescribedBy:{control:"text",description:"The ID of the element that describes the MenuButton, if one exists.",table:{type:{summary:"string"}}},ariaLabel:{control:"text",description:"aria-label to describe the MenuButton when the button label is empty",table:{type:{summary:"string"}}},ariaLabelledBy:{control:"text",description:"The ID of the element that labels the MenuButton. Only needed if the button has no text and `ariaLabel` is empty.",table:{type:{summary:"string"}}},buttonLabel:{control:"text",description:"The label on the triggering Button",table:{type:{summary:"string"}}},buttonVariant:{options:v,control:{type:"radio"},description:"The variant of the triggering Button",table:{type:{summary:v.join(" | ")},defaultValue:{summary:"secondary"}}},children:{control:"object",description:"The <MenuItem> components within the Menu",table:{type:{summary:"[MenuItem | Divider | ListSubheader | NullElement]"}},type:{required:!1,name:"other",value:"[MenuItem | Divider | ListSubheader]"}},popoverContent:{control:"object",description:"The contents to display in the popover (instead of children)",table:{type:{summary:"[ReactNode | NullElement]"}},type:{required:!1,name:"other",value:"ReactNode"}},endIcon:{control:{type:"select"},options:Object.keys(k),mapping:k,description:"The end Icon on the triggering Button",table:{type:{summary:"<Icon />"}}},id:{control:"text",description:"The id of the Button",table:{type:{summary:"string"}}},isDisabled:yn.isDisabled,isOverflow:{control:"boolean",description:"If the MenuButton is an overflow menu or standard menu.",table:{type:{summary:"boolean"}}},menuAlignment:{options:j,control:{type:"radio"},description:"The horizontal alignment of the menu.",table:{type:{summary:j.join(" | ")},defaultValue:{summary:"left"}}},tooltipText:{control:"text",description:"If defined, the button will include a tooltip that contains the string.",table:{type:{summary:"string"}}}},args:{buttonLabel:"More actions",buttonVariant:"secondary",menuAlignment:"left"}},B=({canvasElement:o,step:t})=>async(a,r)=>{const dn=f(o);await t("open menu button",async()=>{const pn=dn.getByRole("button",{name:a.buttonLabel});hn.click(pn),await gn(async()=>Mn(r))})},u={args:{buttonLabel:"More actions",children:[n.jsx(e,{children:"View details"},"1"),n.jsx(e,{children:"Edit configuration"},"2"),n.jsx(e,{children:"Launch"},"3")]},play:async({args:o,canvasElement:t,step:a})=>{await B({canvasElement:t,step:a})(o,"Menu Button Simple")}},l={args:{children:[n.jsxs(e,{isDisabled:!0,children:[n.jsx(mn,{}),"Assign crew"]},"1"),n.jsxs(e,{children:[n.jsx(fn,{}),"View destination"]},"2"),n.jsxs(e,{children:[n.jsx(Ln,{}),"Schedule launch"]},"3")]},play:async({args:o,canvasElement:t,step:a})=>{await B({canvasElement:t,step:a})(o,"Menu Button Action Icons")}},m={args:{buttonLabel:"More actions",buttonVariant:"floating",children:[n.jsx(e,{children:"View details"},"1"),n.jsx(e,{children:"Edit configuration"},"2"),n.jsx(e,{children:"Launch"},"3")],id:"floating"},play:async({canvasElement:o,step:t})=>{await t("Filter and Select from listbox",async()=>{const r=f(o).getByRole("button",{name:"More actions"});await L(r).toHaveAttribute("id","floating-button")})}},d={args:{buttonLabel:"More actions",children:[n.jsx(w,{children:"Crew"},"sh1"),n.jsx(e,{children:"Assign captain"},"1"),n.jsx(e,{children:"View roster"},"2"),n.jsx(w,{children:"Ship"},"sh2"),n.jsx(e,{children:"Configure thrusters"},"3"),n.jsx(e,{children:"View cargo"},"4"),n.jsx(ln,{},"div2"),n.jsx(e,{children:"Log out"},"5")]},play:async({args:o,canvasElement:t,step:a})=>{await B({canvasElement:t,step:a})(o,"Menu Button Groupings")}},p={args:{buttonLabel:"Cargo options",children:[n.jsx(e,{children:"View details"},"1"),n.jsx(e,{children:"Edit inventory"},"2"),n.jsx(e,{variant:"destructive",children:"Jettison cargo"},"3")]},play:async({args:o,canvasElement:t,step:a})=>{await B({canvasElement:t,step:a})(o,"Menu Button Destructive")}},h={args:{ariaLabel:"More actions",buttonLabel:"",children:[n.jsx(e,{children:"View details"},"1"),n.jsx(e,{children:"Edit configuration"},"2"),n.jsx(e,{children:"Launch"},"3")],tooltipText:"More actions"},play:async({canvasElement:o,step:t})=>{await t("MenuButton Aria-Label",async()=>{const r=f(o).queryByRole("button",{name:"More actions"});await L(r).not.toBeNull()})}},g={args:{ariaLabel:"More actions",endIcon:n.jsx(mn,{}),children:[n.jsx(e,{children:"View details"},"1"),n.jsx(e,{children:"Edit configuration"},"2"),n.jsx(e,{children:"Launch"},"3")],tooltipText:"Learn more"}},M={args:{buttonLabel:"Cargo options",children:[n.jsx(e,{children:"View details"},"1"),n.jsx(e,{children:"Edit configuration"},"2"),n.jsx(e,{children:"Launch"},"3")],isOverflow:!0}},b={args:{buttonLabel:"Cargo options",isDisabled:!0,children:[n.jsx(e,{children:"View details"},"1"),n.jsx(e,{children:"Edit configuration"},"2"),n.jsx(e,{children:"Launch"},"3")],tooltipText:"More actions"}},y={args:{buttonVariant:"secondary",children:[n.jsx(e,{children:"View details"},"1"),n.jsx(e,{children:"Edit configuration"},"2"),n.jsx(e,{children:"Launch"},"3")],menuAlignment:"right"},render:function(t){return n.jsx(I,{sx:{ml:"50px"},children:n.jsx(un,{buttonLabel:"More actions",buttonVariant:t.buttonVariant,menuAlignment:t.menuAlignment,children:t.children})})},play:async({args:o,canvasElement:t,step:a})=>{await B({canvasElement:t,step:a})(o,"Menu Button Alignment")}},x={args:{buttonLabel:"",endIcon:n.jsx(Bn,{}),buttonVariant:"secondary",popoverContent:[n.jsxs(I,{sx:{minWidth:"392px"},children:[n.jsxs(i,{children:[n.jsx(xn,{children:"Title"}),n.jsx(s,{children:"Caption"}),n.jsx(E,{children:"Body"})]}),n.jsxs(i,{children:[n.jsx(c,{href:"#",target:"_blank",children:"Link"}),n.jsx(s,{children:"Caption"})]}),n.jsxs(i,{children:[n.jsx(c,{href:"#",target:"_blank",children:"Link"}),n.jsx(s,{children:"Caption"})]}),n.jsxs(i,{children:[n.jsx(c,{href:"#",target:"_blank",children:"Link"}),n.jsx(s,{children:"Caption"})]}),n.jsxs(i,{children:[n.jsx(c,{href:"#",target:"_blank",children:"Link"}),n.jsx(s,{children:"Caption"})]}),n.jsxs(i,{children:[n.jsx(c,{href:"#",target:"_blank",children:"Link"}),n.jsx(s,{children:"Caption"})]}),n.jsx(i,{children:n.jsx(ln,{})}),n.jsx(I,{sx:{fontWeight:"bold"},children:n.jsxs(E,{children:["Body"," ",n.jsx(c,{href:"#",target:"_blank",children:"Link"})]})})]},"help-popover-content")],id:"floating",tooltipText:"More actions"},play:async({canvasElement:o,step:t})=>{await t("MenuButton Aria-Label",()=>{const r=f(o).queryByRole("button",{name:"More actions"});L(r).not.toBeNull()})}};var S,V,P;u.parameters={...u.parameters,docs:{...(S=u.parameters)==null?void 0:S.docs,source:{originalSource:`{
|
|
2
|
-
args: {
|
|
3
|
-
buttonLabel: "More actions",
|
|
4
|
-
children: [<MenuItem key="1">View details</MenuItem>, <MenuItem key="2">Edit configuration</MenuItem>, <MenuItem key="3">Launch</MenuItem>]
|
|
5
|
-
},
|
|
6
|
-
play: async ({
|
|
7
|
-
args,
|
|
8
|
-
canvasElement,
|
|
9
|
-
step
|
|
10
|
-
}: {
|
|
11
|
-
args: MenuButtonProps;
|
|
12
|
-
canvasElement: HTMLElement;
|
|
13
|
-
step: PlaywrightProps<MenuButtonProps>["step"];
|
|
14
|
-
}) => {
|
|
15
|
-
await clickMenuButton({
|
|
16
|
-
canvasElement,
|
|
17
|
-
step
|
|
18
|
-
})(args, "Menu Button Simple");
|
|
19
|
-
}
|
|
20
|
-
}`,...(P=(V=u.parameters)==null?void 0:V.docs)==null?void 0:P.source}}};var C,T,A;l.parameters={...l.parameters,docs:{...(C=l.parameters)==null?void 0:C.docs,source:{originalSource:`{
|
|
21
|
-
args: {
|
|
22
|
-
children: [<MenuItem isDisabled key="1">
|
|
23
|
-
<GroupIcon />
|
|
24
|
-
Assign crew
|
|
25
|
-
</MenuItem>, <MenuItem key="2">
|
|
26
|
-
<GlobeIcon />
|
|
27
|
-
View destination
|
|
28
|
-
</MenuItem>, <MenuItem key="3">
|
|
29
|
-
<CalendarIcon />
|
|
30
|
-
Schedule launch
|
|
31
|
-
</MenuItem>]
|
|
32
|
-
},
|
|
33
|
-
play: async ({
|
|
34
|
-
args,
|
|
35
|
-
canvasElement,
|
|
36
|
-
step
|
|
37
|
-
}: {
|
|
38
|
-
args: MenuButtonProps;
|
|
39
|
-
canvasElement: HTMLElement;
|
|
40
|
-
step: PlaywrightProps<MenuButtonProps>["step"];
|
|
41
|
-
}) => {
|
|
42
|
-
await clickMenuButton({
|
|
43
|
-
canvasElement,
|
|
44
|
-
step
|
|
45
|
-
})(args, "Menu Button Action Icons");
|
|
46
|
-
}
|
|
47
|
-
}`,...(A=(T=l.parameters)==null?void 0:T.docs)==null?void 0:A.source}}};var D,W,_;m.parameters={...m.parameters,docs:{...(D=m.parameters)==null?void 0:D.docs,source:{originalSource:`{
|
|
48
|
-
args: {
|
|
49
|
-
buttonLabel: "More actions",
|
|
50
|
-
buttonVariant: "floating",
|
|
51
|
-
children: [<MenuItem key="1">View details</MenuItem>, <MenuItem key="2">Edit configuration</MenuItem>, <MenuItem key="3">Launch</MenuItem>],
|
|
52
|
-
id: "floating"
|
|
53
|
-
},
|
|
54
|
-
play: async ({
|
|
55
|
-
canvasElement,
|
|
56
|
-
step
|
|
57
|
-
}: PlaywrightProps<MenuButtonProps>) => {
|
|
58
|
-
await step("Filter and Select from listbox", async () => {
|
|
59
|
-
const canvas = within(canvasElement);
|
|
60
|
-
const button = canvas.getByRole("button", {
|
|
61
|
-
name: "More actions"
|
|
62
|
-
});
|
|
63
|
-
await expect(button).toHaveAttribute("id", "floating-button");
|
|
64
|
-
});
|
|
65
|
-
}
|
|
66
|
-
}`,...(_=(W=m.parameters)==null?void 0:W.docs)==null?void 0:_.source}}};var z,O,H;d.parameters={...d.parameters,docs:{...(z=d.parameters)==null?void 0:z.docs,source:{originalSource:`{
|
|
67
|
-
args: {
|
|
68
|
-
buttonLabel: "More actions",
|
|
69
|
-
children: [<ListSubheader key="sh1">Crew</ListSubheader>, <MenuItem key="1">Assign captain</MenuItem>, <MenuItem key="2">View roster</MenuItem>, <ListSubheader key="sh2">Ship</ListSubheader>, <MenuItem key="3">Configure thrusters</MenuItem>, <MenuItem key="4">View cargo</MenuItem>, <Divider key="div2" />, <MenuItem key="5">Log out</MenuItem>]
|
|
70
|
-
},
|
|
71
|
-
play: async ({
|
|
72
|
-
args,
|
|
73
|
-
canvasElement,
|
|
74
|
-
step
|
|
75
|
-
}: {
|
|
76
|
-
args: MenuButtonProps;
|
|
77
|
-
canvasElement: HTMLElement;
|
|
78
|
-
step: PlaywrightProps<MenuButtonProps>["step"];
|
|
79
|
-
}) => {
|
|
80
|
-
await clickMenuButton({
|
|
81
|
-
canvasElement,
|
|
82
|
-
step
|
|
83
|
-
})(args, "Menu Button Groupings");
|
|
84
|
-
}
|
|
85
|
-
}`,...(H=(O=d.parameters)==null?void 0:O.docs)==null?void 0:H.source}}};var R,G,N;p.parameters={...p.parameters,docs:{...(R=p.parameters)==null?void 0:R.docs,source:{originalSource:`{
|
|
86
|
-
args: {
|
|
87
|
-
buttonLabel: "Cargo options",
|
|
88
|
-
children: [<MenuItem key="1">View details</MenuItem>, <MenuItem key="2">Edit inventory</MenuItem>, <MenuItem key="3" variant="destructive">
|
|
89
|
-
Jettison cargo
|
|
90
|
-
</MenuItem>]
|
|
91
|
-
},
|
|
92
|
-
play: async ({
|
|
93
|
-
args,
|
|
94
|
-
canvasElement,
|
|
95
|
-
step
|
|
96
|
-
}: {
|
|
97
|
-
args: MenuButtonProps;
|
|
98
|
-
canvasElement: HTMLElement;
|
|
99
|
-
step: PlaywrightProps<MenuButtonProps>["step"];
|
|
100
|
-
}) => {
|
|
101
|
-
await clickMenuButton({
|
|
102
|
-
canvasElement,
|
|
103
|
-
step
|
|
104
|
-
})(args, "Menu Button Destructive");
|
|
105
|
-
}
|
|
106
|
-
}`,...(N=(G=p.parameters)==null?void 0:G.docs)==null?void 0:N.source}}};var q,F,J;h.parameters={...h.parameters,docs:{...(q=h.parameters)==null?void 0:q.docs,source:{originalSource:`{
|
|
107
|
-
args: {
|
|
108
|
-
ariaLabel: "More actions",
|
|
109
|
-
buttonLabel: "",
|
|
110
|
-
children: [<MenuItem key="1">View details</MenuItem>, <MenuItem key="2">Edit configuration</MenuItem>, <MenuItem key="3">Launch</MenuItem>],
|
|
111
|
-
tooltipText: "More actions"
|
|
112
|
-
},
|
|
113
|
-
play: async ({
|
|
114
|
-
canvasElement,
|
|
115
|
-
step
|
|
116
|
-
}: PlaywrightProps<MenuButtonProps>) => {
|
|
117
|
-
await step("MenuButton Aria-Label", async () => {
|
|
118
|
-
const canvas = within(canvasElement);
|
|
119
|
-
const menuButton = canvas.queryByRole("button", {
|
|
120
|
-
name: "More actions"
|
|
121
|
-
});
|
|
122
|
-
await expect(menuButton).not.toBeNull();
|
|
123
|
-
});
|
|
124
|
-
}
|
|
125
|
-
}`,...(J=(F=h.parameters)==null?void 0:F.docs)==null?void 0:J.source}}};var Q,K,U;g.parameters={...g.parameters,docs:{...(Q=g.parameters)==null?void 0:Q.docs,source:{originalSource:`{
|
|
126
|
-
args: {
|
|
127
|
-
ariaLabel: "More actions",
|
|
128
|
-
endIcon: <GroupIcon />,
|
|
129
|
-
children: [<MenuItem key="1">View details</MenuItem>, <MenuItem key="2">Edit configuration</MenuItem>, <MenuItem key="3">Launch</MenuItem>],
|
|
130
|
-
tooltipText: "Learn more"
|
|
131
|
-
}
|
|
132
|
-
}`,...(U=(K=g.parameters)==null?void 0:K.docs)==null?void 0:U.source}}};var X,Y,Z;M.parameters={...M.parameters,docs:{...(X=M.parameters)==null?void 0:X.docs,source:{originalSource:`{
|
|
133
|
-
args: {
|
|
134
|
-
buttonLabel: "Cargo options",
|
|
135
|
-
children: [<MenuItem key="1">View details</MenuItem>, <MenuItem key="2">Edit configuration</MenuItem>, <MenuItem key="3">Launch</MenuItem>],
|
|
136
|
-
isOverflow: true
|
|
137
|
-
}
|
|
138
|
-
}`,...(Z=(Y=M.parameters)==null?void 0:Y.docs)==null?void 0:Z.source}}};var $,nn,en;b.parameters={...b.parameters,docs:{...($=b.parameters)==null?void 0:$.docs,source:{originalSource:`{
|
|
139
|
-
args: {
|
|
140
|
-
buttonLabel: "Cargo options",
|
|
141
|
-
isDisabled: true,
|
|
142
|
-
children: [<MenuItem key="1">View details</MenuItem>, <MenuItem key="2">Edit configuration</MenuItem>, <MenuItem key="3">Launch</MenuItem>],
|
|
143
|
-
tooltipText: "More actions"
|
|
144
|
-
}
|
|
145
|
-
}`,...(en=(nn=b.parameters)==null?void 0:nn.docs)==null?void 0:en.source}}};var tn,on,an;y.parameters={...y.parameters,docs:{...(tn=y.parameters)==null?void 0:tn.docs,source:{originalSource:`{
|
|
146
|
-
args: {
|
|
147
|
-
buttonVariant: "secondary",
|
|
148
|
-
children: [<MenuItem key="1">View details</MenuItem>, <MenuItem key="2">Edit configuration</MenuItem>, <MenuItem key="3">Launch</MenuItem>],
|
|
149
|
-
menuAlignment: "right"
|
|
150
|
-
},
|
|
151
|
-
render: function C(props: MenuButtonProps) {
|
|
152
|
-
return <Box sx={{
|
|
153
|
-
ml: "50px"
|
|
154
|
-
}}>
|
|
155
|
-
<MenuButton buttonLabel="More actions" buttonVariant={props.buttonVariant} menuAlignment={props.menuAlignment}>
|
|
156
|
-
{props.children}
|
|
157
|
-
</MenuButton>
|
|
158
|
-
</Box>;
|
|
159
|
-
},
|
|
160
|
-
play: async ({
|
|
161
|
-
args,
|
|
162
|
-
canvasElement,
|
|
163
|
-
step
|
|
164
|
-
}: {
|
|
165
|
-
args: MenuButtonProps;
|
|
166
|
-
canvasElement: HTMLElement;
|
|
167
|
-
step: PlaywrightProps<MenuButtonProps>["step"];
|
|
168
|
-
}) => {
|
|
169
|
-
await clickMenuButton({
|
|
170
|
-
canvasElement,
|
|
171
|
-
step
|
|
172
|
-
})(args, "Menu Button Alignment");
|
|
173
|
-
}
|
|
174
|
-
}`,...(an=(on=y.parameters)==null?void 0:on.docs)==null?void 0:an.source}}};var rn,sn,cn;x.parameters={...x.parameters,docs:{...(rn=x.parameters)==null?void 0:rn.docs,source:{originalSource:`{
|
|
175
|
-
args: {
|
|
176
|
-
buttonLabel: "",
|
|
177
|
-
endIcon: <QuestionCircleIcon />,
|
|
178
|
-
buttonVariant: "secondary",
|
|
179
|
-
popoverContent: [<Box key="help-popover-content" sx={{
|
|
180
|
-
minWidth: "392px"
|
|
181
|
-
}}>
|
|
182
|
-
<BoxWithBottomMargin>
|
|
183
|
-
<Heading5>Title</Heading5>
|
|
184
|
-
<Subordinate>Caption</Subordinate>
|
|
185
|
-
<Paragraph>Body</Paragraph>
|
|
186
|
-
</BoxWithBottomMargin>
|
|
187
|
-
<BoxWithBottomMargin>
|
|
188
|
-
<Link href="#" target="_blank">
|
|
189
|
-
Link
|
|
190
|
-
</Link>
|
|
191
|
-
<Subordinate>Caption</Subordinate>
|
|
192
|
-
</BoxWithBottomMargin>
|
|
193
|
-
<BoxWithBottomMargin>
|
|
194
|
-
<Link href="#" target="_blank">
|
|
195
|
-
Link
|
|
196
|
-
</Link>
|
|
197
|
-
<Subordinate>Caption</Subordinate>
|
|
198
|
-
</BoxWithBottomMargin>
|
|
199
|
-
<BoxWithBottomMargin>
|
|
200
|
-
<Link href="#" target="_blank">
|
|
201
|
-
Link
|
|
202
|
-
</Link>
|
|
203
|
-
<Subordinate>Caption</Subordinate>
|
|
204
|
-
</BoxWithBottomMargin>
|
|
205
|
-
<BoxWithBottomMargin>
|
|
206
|
-
<Link href="#" target="_blank">
|
|
207
|
-
Link
|
|
208
|
-
</Link>
|
|
209
|
-
<Subordinate>Caption</Subordinate>
|
|
210
|
-
</BoxWithBottomMargin>
|
|
211
|
-
<BoxWithBottomMargin>
|
|
212
|
-
<Link href="#" target="_blank">
|
|
213
|
-
Link
|
|
214
|
-
</Link>
|
|
215
|
-
<Subordinate>Caption</Subordinate>
|
|
216
|
-
</BoxWithBottomMargin>
|
|
217
|
-
<BoxWithBottomMargin>
|
|
218
|
-
<Divider />
|
|
219
|
-
</BoxWithBottomMargin>
|
|
220
|
-
<Box sx={{
|
|
221
|
-
fontWeight: "bold"
|
|
222
|
-
}}>
|
|
223
|
-
<Paragraph>
|
|
224
|
-
Body{" "}
|
|
225
|
-
<Link href="#" target="_blank">
|
|
226
|
-
Link
|
|
227
|
-
</Link>
|
|
228
|
-
</Paragraph>
|
|
229
|
-
</Box>
|
|
230
|
-
</Box>],
|
|
231
|
-
id: "floating",
|
|
232
|
-
tooltipText: "More actions"
|
|
233
|
-
},
|
|
234
|
-
play: async ({
|
|
235
|
-
canvasElement,
|
|
236
|
-
step
|
|
237
|
-
}: PlaywrightProps<MenuButtonProps>) => {
|
|
238
|
-
await step("MenuButton Aria-Label", () => {
|
|
239
|
-
const canvas = within(canvasElement);
|
|
240
|
-
const menuButton = canvas.queryByRole("button", {
|
|
241
|
-
name: "More actions"
|
|
242
|
-
});
|
|
243
|
-
expect(menuButton).not.toBeNull();
|
|
244
|
-
});
|
|
245
|
-
}
|
|
246
|
-
}`,...(cn=(sn=x.parameters)==null?void 0:sn.docs)==null?void 0:cn.source}}};const jn=["Simple","ActionIcons","ButtonVariant","Groupings","WithDestructive","IconButton","EndIcon","Overflow","Disabled","Alignment","HelpPopover"],Jn=Object.freeze(Object.defineProperty({__proto__:null,ActionIcons:l,Alignment:y,ButtonVariant:m,Disabled:b,EndIcon:g,Groupings:d,HelpPopover:x,IconButton:h,Overflow:M,Simple:u,WithDestructive:p,__namedExportsOrder:jn,default:kn},Symbol.toStringTag,{value:"Module"}));export{Jn as M};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import{r as e}from"./index-NdkWRN8K.js";/*!
|
|
2
|
-
* Copyright (c) 2023-present, Okta, Inc. and/or its affiliates. All rights reserved.
|
|
3
|
-
* The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the "License.")
|
|
4
|
-
*
|
|
5
|
-
* You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
7
|
-
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
8
|
-
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9
|
-
*
|
|
10
|
-
* See the License for the specific language governing permissions and limitations under the License.
|
|
11
|
-
*/const o=e.createContext({closeMenu:()=>{},openMenu:()=>{},shouldCloseOnSelect:!0});export{o as M};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t}from"./index-NdkWRN8K.js";import{M}from"./MenuContext-DKMyPMNY.js";import{j as f}from"./jsx-runtime-CnH95YSl.js";import{M as x}from"./MenuItem-oi_JaUho.js";import{m as I}from"./OdysseyThemeProvider-BykOaJq8.js";const p=({children:o,hasInitialFocus:u,isSelected:s,isDisabled:n,onClick:e,testId:r,value:d,variant:c="default"})=>{const{closeMenu:a,shouldCloseOnSelect:m}=t.useContext(M),i=t.useCallback(l=>{e==null||e(l),m&&a()},[e,a,m]);return f.jsx(x,{"aria-current":s,autoFocus:u,className:c==="destructive"?`${I.root}-destructive`:void 0,"data-se":r,disabled:n,onClick:i,selected:s,tabIndex:0,value:d,children:o})},b=t.memo(p);b.displayName="MenuItem";export{b as M};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{c as V,_ as E,a as F,b as n,s as G,d as x,f as L,l as T,r as w,n as c,o as C,p as $,q as I,m as i}from"./OdysseyThemeProvider-BykOaJq8.js";import{r as d}from"./index-NdkWRN8K.js";import{a as O}from"./List-_p0jkXPM.js";import{j as M}from"./jsx-runtime-CnH95YSl.js";import{u as _}from"./useIsFocusVisible-DH0qxT5e.js";import{B as D}from"./ButtonBase-CrcIXP69.js";const H=["autoFocus","component","dense","divider","disableGutters","focusVisibleClassName","role","tabIndex","className"],S=(a,e)=>{const{ownerState:s}=a;return[e.root,s.dense&&e.dense,s.divider&&e.divider,!s.disableGutters&&e.gutters]},z=a=>{const{disabled:e,dense:s,divider:t,disableGutters:l,selected:p,classes:o}=a,r=L({root:["root",s&&"dense",e&&"disabled",!l&&"gutters",t&&"divider",p&&"selected"]},T,o);return n({},o,r)},U=G(D,{shouldForwardProp:a=>w(a)||a==="classes",name:"MuiMenuItem",slot:"Root",overridesResolver:S})(({theme:a,ownerState:e})=>n({},a.typography.body1,{display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",textDecoration:"none",minHeight:48,paddingTop:6,paddingBottom:6,boxSizing:"border-box",whiteSpace:"nowrap"},!e.disableGutters&&{paddingLeft:16,paddingRight:16},e.divider&&{borderBottom:`1px solid ${(a.vars||a).palette.divider}`,backgroundClip:"padding-box"},{"&:hover":{textDecoration:"none",backgroundColor:(a.vars||a).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${i.selected}`]:{backgroundColor:a.vars?`rgba(${a.vars.palette.primary.mainChannel} / ${a.vars.palette.action.selectedOpacity})`:c.alpha(a.palette.primary.main,a.palette.action.selectedOpacity),[`&.${i.focusVisible}`]:{backgroundColor:a.vars?`rgba(${a.vars.palette.primary.mainChannel} / calc(${a.vars.palette.action.selectedOpacity} + ${a.vars.palette.action.focusOpacity}))`:c.alpha(a.palette.primary.main,a.palette.action.selectedOpacity+a.palette.action.focusOpacity)}},[`&.${i.selected}:hover`]:{backgroundColor:a.vars?`rgba(${a.vars.palette.primary.mainChannel} / calc(${a.vars.palette.action.selectedOpacity} + ${a.vars.palette.action.hoverOpacity}))`:c.alpha(a.palette.primary.main,a.palette.action.selectedOpacity+a.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:a.vars?`rgba(${a.vars.palette.primary.mainChannel} / ${a.vars.palette.action.selectedOpacity})`:c.alpha(a.palette.primary.main,a.palette.action.selectedOpacity)}},[`&.${i.focusVisible}`]:{backgroundColor:(a.vars||a).palette.action.focus},[`&.${i.disabled}`]:{opacity:(a.vars||a).palette.action.disabledOpacity},[`& + .${I.root}`]:{marginTop:a.spacing(1),marginBottom:a.spacing(1)},[`& + .${I.inset}`]:{marginLeft:52},[`& .${$.root}`]:{marginTop:0,marginBottom:0},[`& .${$.inset}`]:{paddingLeft:36},[`& .${C.root}`]:{minWidth:36}},!e.dense&&{[a.breakpoints.up("sm")]:{minHeight:"auto"}},e.dense&&n({minHeight:32,paddingTop:4,paddingBottom:4},a.typography.body2,{[`& .${C.root} svg`]:{fontSize:"1.25rem"}}))),X=d.forwardRef(function(e,s){const t=V({props:e,name:"MuiMenuItem"}),{autoFocus:l=!1,component:p="li",dense:o=!1,divider:b=!1,disableGutters:r=!1,focusVisibleClassName:k,role:R="menuitem",tabIndex:v,className:B}=t,j=E(t,H),m=d.useContext(O),g=d.useMemo(()=>({dense:o||m.dense||!1,disableGutters:r}),[m.dense,o,r]),u=d.useRef(null);F(()=>{l&&u.current&&u.current.focus()},[l]);const N=n({},t,{dense:g.dense,divider:b,disableGutters:r}),f=z(t),P=_(u,s);let y;return t.disabled||(y=v!==void 0?v:-1),M.jsx(O.Provider,{value:g,children:M.jsx(U,n({ref:P,role:R,tabIndex:y,component:p,focusVisibleClassName:x(f.focusVisible,k),className:x(f.root,B)},j,{ownerState:N,classes:f}))})});export{X as M};
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import{j as r}from"./jsx-runtime-CnH95YSl.js";import{r as I}from"./index-NdkWRN8K.js";import{O as v}from"./OdysseyStorybookThemeDecorator-CGH8visK.js";import{f as D}from"./fieldComponentPropsMetaData-BqbNLw6V.js";import{M as g}from"./MenuItem-DoUaLmgU.js";import{M as x}from"./Menu-CU_mHT7L.js";import"./_commonjsHelpers-gnU0ypJ3.js";import"./OdysseyThemeProvider-BykOaJq8.js";import"./index-BJTM6NaI.js";import"./OdysseyProvider-BPLFYiwr.js";import"./MenuContext-DKMyPMNY.js";import"./MenuItem-oi_JaUho.js";import"./List-_p0jkXPM.js";import"./useIsFocusVisible-DH0qxT5e.js";import"./ButtonBase-CrcIXP69.js";import"./assertThisInitialized-B9jnkVVz.js";import"./inheritsLoose-DTTkq0Su.js";import"./TransitionGroupContext-DAL84N7p.js";import"./getReactElementRef-Bs64nbeG.js";import"./resolveComponentProps-TTQVZ4OZ.js";import"./isHostComponent-DVu5iVWx.js";import"./Grow-6R6cTzr4.js";import"./utils-BdcLUgCD.js";import"./index-B5xazMy1.js";import"./index-DieBXP3Z.js";import"./ownerDocument-DW-IO8s5.js";import"./ownerWindow-HkKU3E4x.js";import"./debounce-Be36O1Ab.js";import"./Modal-B12sS2Yh.js";import"./getScrollbarSize-Bqq2hMjQ.js";import"./createChainedFunction-BO_9K8Jh.js";import"./Portal-CsPQSHsR.js";import"./Fade-CHnXmzFb.js";import"./Paper-DwBg74qy.js";import"./MenuList-0OHGr5AC.js";const ie={component:g,decorators:[v],tags:["autodocs"],argTypes:{children:{control:"object",description:"The content for the `MenuItem` components within the Menu",table:{type:{summary:"ReactNode"}},type:{required:!0,name:"other",value:"ReactNode"}},hasInitialFocus:{control:"boolean",description:"If `true`, focuses the item when the parent menu opens",table:{type:{summary:"boolean"}}},isDisabled:D.isDisabled,isSelected:{control:"boolean",description:"If `true`, the menu item will be visually marked as selected.",table:{type:{summary:"boolean"}}},variant:{options:["default","destructive"],control:{type:"radio"},description:"The variant of the triggering Button",table:{type:{summary:["default","destructive"].join(" | ")},defaultValue:{summary:"default"}}}},args:{children:"MenuItem content"}},a=t=>{const e=I.useRef(null);return r.jsx("div",{ref:e,children:r.jsx(x,{anchorEl:e.current,open:!0,children:r.jsx(g,{...t,children:t.children})})})},o={render:function(e){return r.jsx(a,{...e})}},n={args:{variant:"destructive",children:"Destructive MenuItem"},render:function(e){return r.jsx(a,{...e})}},s={args:{isDisabled:!0,children:"Disabled MenuItem"},render:function(e){return r.jsx(a,{...e})}},i={args:{isSelected:!0,children:"Selected MenuItem"},render:function(e){return r.jsx(a,{...e})}};var m,p,c;o.parameters={...o.parameters,docs:{...(m=o.parameters)==null?void 0:m.docs,source:{originalSource:`{
|
|
2
|
-
render: function C(props: MenuItemProps) {
|
|
3
|
-
return <BaseStory {...props} />;
|
|
4
|
-
}
|
|
5
|
-
}`,...(c=(p=o.parameters)==null?void 0:p.docs)==null?void 0:c.source}}};var u,d,l;n.parameters={...n.parameters,docs:{...(u=n.parameters)==null?void 0:u.docs,source:{originalSource:`{
|
|
6
|
-
args: {
|
|
7
|
-
variant: "destructive",
|
|
8
|
-
children: "Destructive MenuItem"
|
|
9
|
-
},
|
|
10
|
-
render: function C(props: MenuItemProps) {
|
|
11
|
-
return <BaseStory {...props} />;
|
|
12
|
-
}
|
|
13
|
-
}`,...(l=(d=n.parameters)==null?void 0:d.docs)==null?void 0:l.source}}};var f,h,y;s.parameters={...s.parameters,docs:{...(f=s.parameters)==null?void 0:f.docs,source:{originalSource:`{
|
|
14
|
-
args: {
|
|
15
|
-
isDisabled: true,
|
|
16
|
-
children: "Disabled MenuItem"
|
|
17
|
-
},
|
|
18
|
-
render: function C(props: MenuItemProps) {
|
|
19
|
-
return <BaseStory {...props} />;
|
|
20
|
-
}
|
|
21
|
-
}`,...(y=(h=s.parameters)==null?void 0:h.docs)==null?void 0:y.source}}};var b,M,S;i.parameters={...i.parameters,docs:{...(b=i.parameters)==null?void 0:b.docs,source:{originalSource:`{
|
|
22
|
-
args: {
|
|
23
|
-
isSelected: true,
|
|
24
|
-
children: "Selected MenuItem"
|
|
25
|
-
},
|
|
26
|
-
render: function C(props: MenuItemProps) {
|
|
27
|
-
return <BaseStory {...props} />;
|
|
28
|
-
}
|
|
29
|
-
}`,...(S=(M=i.parameters)==null?void 0:M.docs)==null?void 0:S.source}}};const ae=["Simple","Destructive","Disabled","Selected"];export{n as Destructive,s as Disabled,i as Selected,o as Simple,ae as __namedExportsOrder,ie as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as j,a as H,b as T}from"./OdysseyThemeProvider-BykOaJq8.js";import{r as c}from"./index-NdkWRN8K.js";import{j as A}from"./jsx-runtime-CnH95YSl.js";import{g as _}from"./getScrollbarSize-Bqq2hMjQ.js";import{o as C}from"./ownerDocument-DW-IO8s5.js";import{u as O}from"./useIsFocusVisible-DH0qxT5e.js";import{L as z}from"./List-_p0jkXPM.js";const N=["actions","autoFocus","autoFocusItem","children","className","disabledItemsFocusable","disableListWrap","onKeyDown","variant"];function w(n,t,r){return n===t?n.firstChild:t&&t.nextElementSibling?t.nextElementSibling:r?null:n.firstChild}function D(n,t,r){return n===t?r?n.firstChild:n.lastChild:t&&t.previousElementSibling?t.previousElementSibling:r?null:n.lastChild}function I(n,t){if(t===void 0)return!0;let r=n.innerText;return r===void 0&&(r=n.textContent),r=r.trim().toLowerCase(),r.length===0?!1:t.repeating?r[0]===t.keys[0]:r.indexOf(t.keys.join(""))===0}function h(n,t,r,b,m,y){let p=!1,u=m(n,t,t?r:!1);for(;u;){if(u===n.firstChild){if(p)return!1;p=!0}const d=b?!1:u.disabled||u.getAttribute("aria-disabled")==="true";if(!u.hasAttribute("tabindex")||!I(u,y)||d)u=m(n,u,r);else return u.focus(),!0}return!1}const G=c.forwardRef(function(t,r){const{actions:b,autoFocus:m=!1,autoFocusItem:y=!1,children:p,className:u,disabledItemsFocusable:d=!1,disableListWrap:g=!1,onKeyDown:x,variant:v="selectedMenu"}=t,F=j(t,N),a=c.useRef(null),M=c.useRef({keys:[],repeating:!0,previousKeyMatched:!0,lastTime:null});H(()=>{m&&a.current.focus()},[m]),c.useImperativeHandle(b,()=>({adjustStyleForScrollbar:(e,{direction:s})=>{const l=!a.current.style.width;if(e.clientHeight<a.current.clientHeight&&l){const f=`${_(C(e))}px`;a.current.style[s==="rtl"?"paddingLeft":"paddingRight"]=f,a.current.style.width=`calc(100% + ${f})`}return a.current}}),[]);const S=e=>{const s=a.current,l=e.key,f=C(s).activeElement;if(l==="ArrowDown")e.preventDefault(),h(s,f,g,d,w);else if(l==="ArrowUp")e.preventDefault(),h(s,f,g,d,D);else if(l==="Home")e.preventDefault(),h(s,null,g,d,w);else if(l==="End")e.preventDefault(),h(s,null,g,d,D);else if(l.length===1){const i=M.current,k=l.toLowerCase(),E=performance.now();i.keys.length>0&&(E-i.lastTime>500?(i.keys=[],i.repeating=!0,i.previousKeyMatched=!0):i.repeating&&k!==i.keys[0]&&(i.repeating=!1)),i.lastTime=E,i.keys.push(k);const R=f&&!i.repeating&&I(f,i);i.previousKeyMatched&&(R||h(s,f,!1,d,w,i))?e.preventDefault():i.previousKeyMatched=!1}x&&x(e)},L=O(a,r);let o=-1;c.Children.forEach(p,(e,s)=>{if(!c.isValidElement(e)){o===s&&(o+=1,o>=p.length&&(o=-1));return}e.props.disabled||(v==="selectedMenu"&&e.props.selected||o===-1)&&(o=s),o===s&&(e.props.disabled||e.props.muiSkipListHighlight||e.type.muiSkipListHighlight)&&(o+=1,o>=p.length&&(o=-1))});const K=c.Children.map(p,(e,s)=>{if(s===o){const l={};return y&&(l.autoFocus=!0),e.props.tabIndex===void 0&&v==="selectedMenu"&&(l.tabIndex=0),c.cloneElement(e,l)}return e});return A.jsx(z,T({role:"menu",ref:L,className:u,onKeyDown:S,tabIndex:m?0:-1},F,{children:K}))});export{G as M};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{U as ie,V as ae,c as le,_ as ce,b as x,s as G,d as q,f as de}from"./OdysseyThemeProvider-BykOaJq8.js";import{r as d}from"./index-NdkWRN8K.js";import{g as ge}from"./getScrollbarSize-Bqq2hMjQ.js";import{o as O}from"./ownerDocument-DW-IO8s5.js";import{o as V}from"./ownerWindow-HkKU3E4x.js";import{u as ue}from"./useIsFocusVisible-DH0qxT5e.js";import{u as te}from"./inheritsLoose-DTTkq0Su.js";import{c as oe}from"./createChainedFunction-BO_9K8Jh.js";import{e as xe}from"./resolveComponentProps-TTQVZ4OZ.js";import{j as N}from"./jsx-runtime-CnH95YSl.js";import{g as ve,u as ne}from"./getReactElementRef-Bs64nbeG.js";import{P as Ee}from"./Portal-CsPQSHsR.js";import{F as Re}from"./Fade-CHnXmzFb.js";function ke(e){return ie("MuiBackdrop",e)}ae("MuiBackdrop",["root","invisible"]);const Pe=["children","className","component","components","componentsProps","invisible","open","slotProps","slots","TransitionComponent","transitionDuration"],ye=e=>{const{classes:t,invisible:n}=e;return de({root:["root",n&&"invisible"]},ke,t)},Te=G("div",{name:"MuiBackdrop",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.invisible&&t.invisible]}})(({ownerState:e})=>x({position:"fixed",display:"flex",alignItems:"center",justifyContent:"center",right:0,bottom:0,top:0,left:0,backgroundColor:"rgba(0, 0, 0, 0.5)",WebkitTapHighlightColor:"transparent"},e.invisible&&{backgroundColor:"transparent"})),Se=d.forwardRef(function(t,n){var o,s,r;const i=le({props:t,name:"MuiBackdrop"}),{children:c,className:u,component:g="div",components:m={},componentsProps:b={},invisible:k=!1,open:v,slotProps:l={},slots:M={},TransitionComponent:C=Re,transitionDuration:I}=i,P=ce(i,Pe),a=x({},i,{component:g,invisible:k}),E=ye(a),h=(o=l.root)!=null?o:b.root;return N.jsx(C,x({in:v,timeout:I},P,{children:N.jsx(Te,x({"aria-hidden":!0},h,{as:(s=(r=M.root)!=null?r:m.Root)!=null?s:g,className:q(E.root,u,h==null?void 0:h.className),ownerState:x({},a,h==null?void 0:h.ownerState),classes:E,ref:n,children:c}))}))});function Ce(e){const t=O(e);return t.body===e?V(e).innerWidth>t.documentElement.clientWidth:e.scrollHeight>e.clientHeight}function _(e,t){t?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden")}function re(e){return parseInt(V(e).getComputedStyle(e).paddingRight,10)||0}function Ie(e){const n=["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].indexOf(e.tagName)!==-1,o=e.tagName==="INPUT"&&e.getAttribute("type")==="hidden";return n||o}function se(e,t,n,o,s){const r=[t,n,...o];[].forEach.call(e.children,i=>{const c=r.indexOf(i)===-1,u=!Ie(i);c&&u&&_(i,s)})}function Y(e,t){let n=-1;return e.some((o,s)=>t(o)?(n=s,!0):!1),n}function Ne(e,t){const n=[],o=e.container;if(!t.disableScrollLock){if(Ce(o)){const i=ge(O(o));n.push({value:o.style.paddingRight,property:"padding-right",el:o}),o.style.paddingRight=`${re(o)+i}px`;const c=O(o).querySelectorAll(".mui-fixed");[].forEach.call(c,u=>{n.push({value:u.style.paddingRight,property:"padding-right",el:u}),u.style.paddingRight=`${re(u)+i}px`})}let r;if(o.parentNode instanceof DocumentFragment)r=O(o).body;else{const i=o.parentElement,c=V(o);r=(i==null?void 0:i.nodeName)==="HTML"&&c.getComputedStyle(i).overflowY==="scroll"?i:o}n.push({value:r.style.overflow,property:"overflow",el:r},{value:r.style.overflowX,property:"overflow-x",el:r},{value:r.style.overflowY,property:"overflow-y",el:r}),r.style.overflow="hidden"}return()=>{n.forEach(({value:r,el:i,property:c})=>{r?i.style.setProperty(c,r):i.style.removeProperty(c)})}}function Me(e){const t=[];return[].forEach.call(e.children,n=>{n.getAttribute("aria-hidden")==="true"&&t.push(n)}),t}class we{constructor(){this.containers=void 0,this.modals=void 0,this.modals=[],this.containers=[]}add(t,n){let o=this.modals.indexOf(t);if(o!==-1)return o;o=this.modals.length,this.modals.push(t),t.modalRef&&_(t.modalRef,!1);const s=Me(n);se(n,t.mount,t.modalRef,s,!0);const r=Y(this.containers,i=>i.container===n);return r!==-1?(this.containers[r].modals.push(t),o):(this.containers.push({modals:[t],container:n,restore:null,hiddenSiblings:s}),o)}mount(t,n){const o=Y(this.containers,r=>r.modals.indexOf(t)!==-1),s=this.containers[o];s.restore||(s.restore=Ne(s,n))}remove(t,n=!0){const o=this.modals.indexOf(t);if(o===-1)return o;const s=Y(this.containers,i=>i.modals.indexOf(t)!==-1),r=this.containers[s];if(r.modals.splice(r.modals.indexOf(t),1),this.modals.splice(o,1),r.modals.length===0)r.restore&&r.restore(),t.modalRef&&_(t.modalRef,n),se(r.container,t.mount,t.modalRef,r.hiddenSiblings,!1),this.containers.splice(s,1);else{const i=r.modals[r.modals.length-1];i.modalRef&&_(i.modalRef,!1)}return o}isTopModal(t){return this.modals.length>0&&this.modals[this.modals.length-1]===t}}const Fe=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function Ae(e){const t=parseInt(e.getAttribute("tabindex")||"",10);return Number.isNaN(t)?e.contentEditable==="true"||(e.nodeName==="AUDIO"||e.nodeName==="VIDEO"||e.nodeName==="DETAILS")&&e.getAttribute("tabindex")===null?0:e.tabIndex:t}function Be(e){if(e.tagName!=="INPUT"||e.type!=="radio"||!e.name)return!1;const t=o=>e.ownerDocument.querySelector(`input[type="radio"]${o}`);let n=t(`[name="${e.name}"]:checked`);return n||(n=t(`[name="${e.name}"]`)),n!==e}function Oe(e){return!(e.disabled||e.tagName==="INPUT"&&e.type==="hidden"||Be(e))}function De(e){const t=[],n=[];return Array.from(e.querySelectorAll(Fe)).forEach((o,s)=>{const r=Ae(o);r===-1||!Oe(o)||(r===0?t.push(o):n.push({documentOrder:s,tabIndex:r,node:o}))}),n.sort((o,s)=>o.tabIndex===s.tabIndex?o.documentOrder-s.documentOrder:o.tabIndex-s.tabIndex).map(o=>o.node).concat(t)}function Le(){return!0}function He(e){const{children:t,disableAutoFocus:n=!1,disableEnforceFocus:o=!1,disableRestoreFocus:s=!1,getTabbable:r=De,isEnabled:i=Le,open:c}=e,u=d.useRef(!1),g=d.useRef(null),m=d.useRef(null),b=d.useRef(null),k=d.useRef(null),v=d.useRef(!1),l=d.useRef(null),M=ue(ve(t),l),C=d.useRef(null);d.useEffect(()=>{!c||!l.current||(v.current=!n)},[n,c]),d.useEffect(()=>{if(!c||!l.current)return;const a=O(l.current);return l.current.contains(a.activeElement)||(l.current.hasAttribute("tabIndex")||l.current.setAttribute("tabIndex","-1"),v.current&&l.current.focus()),()=>{s||(b.current&&b.current.focus&&(u.current=!0,b.current.focus()),b.current=null)}},[c]),d.useEffect(()=>{if(!c||!l.current)return;const a=O(l.current),E=R=>{C.current=R,!(o||!i()||R.key!=="Tab")&&a.activeElement===l.current&&R.shiftKey&&(u.current=!0,m.current&&m.current.focus())},h=()=>{const R=l.current;if(R===null)return;if(!a.hasFocus()||!i()||u.current){u.current=!1;return}if(R.contains(a.activeElement)||o&&a.activeElement!==g.current&&a.activeElement!==m.current)return;if(a.activeElement!==k.current)k.current=null;else if(k.current!==null)return;if(!v.current)return;let y=[];if((a.activeElement===g.current||a.activeElement===m.current)&&(y=r(l.current)),y.length>0){var A,T;const D=!!((A=C.current)!=null&&A.shiftKey&&((T=C.current)==null?void 0:T.key)==="Tab"),B=y[0],w=y[y.length-1];typeof B!="string"&&typeof w!="string"&&(D?w.focus():B.focus())}else R.focus()};a.addEventListener("focusin",h),a.addEventListener("keydown",E,!0);const F=setInterval(()=>{a.activeElement&&a.activeElement.tagName==="BODY"&&h()},50);return()=>{clearInterval(F),a.removeEventListener("focusin",h),a.removeEventListener("keydown",E,!0)}},[n,o,s,i,c,r]);const I=a=>{b.current===null&&(b.current=a.relatedTarget),v.current=!0,k.current=a.target;const E=t.props.onFocus;E&&E(a)},P=a=>{b.current===null&&(b.current=a.relatedTarget),v.current=!0};return N.jsxs(d.Fragment,{children:[N.jsx("div",{tabIndex:c?0:-1,onFocus:P,ref:g,"data-testid":"sentinelStart"}),d.cloneElement(t,{ref:M,onFocus:I}),N.jsx("div",{tabIndex:c?0:-1,onFocus:P,ref:m,"data-testid":"sentinelEnd"})]})}function je(e){return typeof e=="function"?e():e}function Ue(e){return e?e.props.hasOwnProperty("in"):!1}const _e=new we;function $e(e){const{container:t,disableEscapeKeyDown:n=!1,disableScrollLock:o=!1,manager:s=_e,closeAfterTransition:r=!1,onTransitionEnter:i,onTransitionExited:c,children:u,onClose:g,open:m,rootRef:b}=e,k=d.useRef({}),v=d.useRef(null),l=d.useRef(null),M=ue(l,b),[C,I]=d.useState(!m),P=Ue(u);let a=!0;(e["aria-hidden"]==="false"||e["aria-hidden"]===!1)&&(a=!1);const E=()=>O(v.current),h=()=>(k.current.modalRef=l.current,k.current.mount=v.current,k.current),F=()=>{s.mount(h(),{disableScrollLock:o}),l.current&&(l.current.scrollTop=0)},R=te(()=>{const p=je(t)||E().body;s.add(h(),p),l.current&&F()}),y=d.useCallback(()=>s.isTopModal(h()),[s]),A=te(p=>{v.current=p,p&&(m&&y()?F():l.current&&_(l.current,a))}),T=d.useCallback(()=>{s.remove(h(),a)},[a,s]);d.useEffect(()=>()=>{T()},[T]),d.useEffect(()=>{m?R():(!P||!r)&&T()},[m,T,P,r,R]);const D=p=>f=>{var S;(S=p.onKeyDown)==null||S.call(p,f),!(f.key!=="Escape"||f.which===229||!y())&&(n||(f.stopPropagation(),g&&g(f,"escapeKeyDown")))},B=p=>f=>{var S;(S=p.onClick)==null||S.call(p,f),f.target===f.currentTarget&&g&&g(f,"backdropClick")};return{getRootProps:(p={})=>{const f=xe(e);delete f.onTransitionEnter,delete f.onTransitionExited;const S=x({},f,p);return x({role:"presentation"},S,{onKeyDown:D(S),ref:M})},getBackdropProps:(p={})=>{const f=p;return x({"aria-hidden":!0},f,{onClick:B(f),open:m})},getTransitionProps:()=>{const p=()=>{I(!1),i&&i()},f=()=>{I(!0),c&&c(),r&&T()};return{onEnter:oe(p,u==null?void 0:u.props.onEnter),onExited:oe(f,u==null?void 0:u.props.onExited)}},rootRef:M,portalRef:A,isTopModal:y,exited:C,hasTransition:P}}function Ke(e){return ie("MuiModal",e)}ae("MuiModal",["root","hidden","backdrop"]);const We=["BackdropComponent","BackdropProps","classes","className","closeAfterTransition","children","container","component","components","componentsProps","disableAutoFocus","disableEnforceFocus","disableEscapeKeyDown","disablePortal","disableRestoreFocus","disableScrollLock","hideBackdrop","keepMounted","onBackdropClick","onClose","onTransitionEnter","onTransitionExited","open","slotProps","slots","theme"],ze=e=>{const{open:t,exited:n,classes:o}=e;return de({root:["root",!t&&n&&"hidden"],backdrop:["backdrop"]},Ke,o)},Ye=G("div",{name:"MuiModal",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.open&&n.exited&&t.hidden]}})(({theme:e,ownerState:t})=>x({position:"fixed",zIndex:(e.vars||e).zIndex.modal,right:0,bottom:0,top:0,left:0},!t.open&&t.exited&&{visibility:"hidden"})),qe=G(Se,{name:"MuiModal",slot:"Backdrop",overridesResolver:(e,t)=>t.backdrop})({zIndex:-1}),at=d.forwardRef(function(t,n){var o,s,r,i,c,u;const g=le({name:"MuiModal",props:t}),{BackdropComponent:m=qe,BackdropProps:b,className:k,closeAfterTransition:v=!1,children:l,container:M,component:C,components:I={},componentsProps:P={},disableAutoFocus:a=!1,disableEnforceFocus:E=!1,disableEscapeKeyDown:h=!1,disablePortal:F=!1,disableRestoreFocus:R=!1,disableScrollLock:y=!1,hideBackdrop:A=!1,keepMounted:T=!1,onBackdropClick:D,open:B,slotProps:w,slots:j}=g,X=ce(g,We),p=x({},g,{closeAfterTransition:v,disableAutoFocus:a,disableEnforceFocus:E,disableEscapeKeyDown:h,disablePortal:F,disableRestoreFocus:R,disableScrollLock:y,hideBackdrop:A,keepMounted:T}),{getRootProps:f,getBackdropProps:S,getTransitionProps:fe,portalRef:pe,isTopModal:me,exited:J,hasTransition:Q}=$e(x({},p,{rootRef:n})),U=x({},p,{exited:J}),L=ze(U),$={};if(l.props.tabIndex===void 0&&($.tabIndex="-1"),Q){const{onEnter:H,onExited:K}=fe();$.onEnter=H,$.onExited=K}const Z=(o=(s=j==null?void 0:j.root)!=null?s:I.Root)!=null?o:Ye,ee=(r=(i=j==null?void 0:j.backdrop)!=null?i:I.Backdrop)!=null?r:m,W=(c=w==null?void 0:w.root)!=null?c:P.root,z=(u=w==null?void 0:w.backdrop)!=null?u:P.backdrop,be=ne({elementType:Z,externalSlotProps:W,externalForwardedProps:X,getSlotProps:f,additionalProps:{ref:n,as:C},ownerState:U,className:q(k,W==null?void 0:W.className,L==null?void 0:L.root,!U.open&&U.exited&&(L==null?void 0:L.hidden))}),he=ne({elementType:ee,externalSlotProps:z,additionalProps:b,getSlotProps:H=>S(x({},H,{onClick:K=>{D&&D(K),H!=null&&H.onClick&&H.onClick(K)}})),className:q(z==null?void 0:z.className,b==null?void 0:b.className,L==null?void 0:L.backdrop),ownerState:U});return!T&&!B&&(!Q||J)?null:N.jsx(Ee,{ref:pe,container:M,disablePortal:F,children:N.jsxs(Z,x({},be,{children:[!A&&m?N.jsx(ee,x({},he)):null,N.jsx(He,{disableEnforceFocus:E,disableAutoFocus:a,disableRestoreFocus:R,isEnabled:me,open:B,children:d.cloneElement(l,$)})]}))})});export{Se as B,He as F,at as M};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r}from"./index-NdkWRN8K.js";import{j as o}from"./jsx-runtime-CnH95YSl.js";import{S as t}from"./OdysseyThemeProvider-BykOaJq8.js";const s=r.forwardRef((e,n)=>o.jsx(t,{fill:"none",ref:n,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",...e,children:o.jsx(o.Fragment,{children:o.jsx("path",{clipRule:"evenodd",d:"M13.5 4.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Zm0 7.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0ZM12 21a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3Z",fill:"currentColor",fillRule:"evenodd"})})})),l=r.memo(s);l.displayName="MoreIcon";export{l as M};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import{r as t}from"./index-NdkWRN8K.js";/*!
|
|
2
|
-
* Copyright (c) 2023-present, Okta, Inc. and/or its affiliates. All rights reserved.
|
|
3
|
-
* The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the "License.")
|
|
4
|
-
*
|
|
5
|
-
* You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.
|
|
6
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
7
|
-
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
8
|
-
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9
|
-
*
|
|
10
|
-
* See the License for the specific language governing permissions and limitations under the License.
|
|
11
|
-
*/const o=t.createContext({}),e=()=>t.useContext(o);export{o as M,e as u};
|
|
@@ -1,173 +0,0 @@
|
|
|
1
|
-
import{j as e}from"./jsx-runtime-CnH95YSl.js";import{r as n}from"./index-NdkWRN8K.js";import{O as Oe}from"./OdysseyStorybookThemeDecorator-CGH8visK.js";import{f as i}from"./fieldComponentPropsMetaData-BqbNLw6V.js";import{M as De}from"./Field-BxkyNVQW.js";import{g as Fe,u as He}from"./inputUtils-Dbi8XkA6.js";import{S as Ne}from"./Select-VvpDulqk.js";import{M as Ae}from"./Link-BQo2zH0c.js";import"./_commonjsHelpers-gnU0ypJ3.js";import"./OdysseyThemeProvider-BykOaJq8.js";import"./index-BJTM6NaI.js";import"./OdysseyProvider-BPLFYiwr.js";import"./Box-B-R2QRDU.js";import"./Box-B6KmU4_J.js";import"./List-_p0jkXPM.js";import"./ListItem-BLYwuKOG.js";import"./utils-iop7lDec.js";import"./useFormControl-BMISTZuX.js";import"./FormLabel-EOlXQpGp.js";import"./useIsFocusVisible-DH0qxT5e.js";import"./isHostComponent-DVu5iVWx.js";import"./ButtonBase-CrcIXP69.js";import"./assertThisInitialized-B9jnkVVz.js";import"./inheritsLoose-DTTkq0Su.js";import"./TransitionGroupContext-DAL84N7p.js";import"./ScreenReaderText-DbrZU7M5.js";import"./visuallyHidden-Dan1xhjv.js";import"./FormHelperText-Ca69g4Je.js";import"./FieldHint-D5VttvwL.js";import"./Typography-B7ktrxCD.js";import"./Typography-CSpPZFTF.js";import"./useUniqueId-Bsgqe1tm.js";import"./createUniqueId-ByTaVY63.js";import"./Menu-CU_mHT7L.js";import"./getReactElementRef-Bs64nbeG.js";import"./resolveComponentProps-TTQVZ4OZ.js";import"./Grow-6R6cTzr4.js";import"./utils-BdcLUgCD.js";import"./index-B5xazMy1.js";import"./index-DieBXP3Z.js";import"./ownerDocument-DW-IO8s5.js";import"./ownerWindow-HkKU3E4x.js";import"./debounce-Be36O1Ab.js";import"./Modal-B12sS2Yh.js";import"./getScrollbarSize-Bqq2hMjQ.js";import"./createChainedFunction-BO_9K8Jh.js";import"./Portal-CsPQSHsR.js";import"./Fade-CHnXmzFb.js";import"./Paper-DwBg74qy.js";import"./MenuList-0OHGr5AC.js";import"./useControlled-NQulfz4l.js";import"./ArrowDropDown-Dnrg-0Q8.js";import"./createSvgIcon-Bv_3NNsK.js";import"./InputBase-6reb9B7r.js";import"./Link-DcsndbPK.js";import"./ExternalLink-lox07hAR.js";const Ge=n.forwardRef(({ariaDescribedBy:c,autoCompleteType:o,defaultValue:r,errorMessage:l,errorMessageList:s,hasMultipleChoices:a,hint:h,HintLinkComponent:t,id:m,inputRef:Se,isDisabled:Me=!1,isFullWidth:Le=!1,isMultiSelect:w,isOptional:Ee=!1,label:Te,onBlur:k,onChange:v,onFocus:O,testId:D,translate:F,value:H,children:N},A)=>{const Ve=n.useRef(Fe({controlledValue:H,uncontrolledValue:r})),G=n.useRef(null);n.useImperativeHandle(Se,()=>({focus:()=>{var d;(d=G.current)==null||d.focus()}}),[]);const P=He({defaultValue:r,value:H,controlState:Ve.current}),R=n.useCallback((d,V)=>{v==null||v(d,V)},[v]),W=n.useMemo(()=>a===void 0?w:a,[a,w]),we=n.useCallback(({ariaDescribedBy:d,errorMessageElementId:V,labelElementId:ke})=>e.jsx(Ne,{...P,"aria-describedby":d,autoComplete:o,children:N,id:m,inputProps:{"aria-errormessage":V,"aria-labelledby":ke,"data-se":D},inputRef:G,multiple:W,name:m,native:!0,onBlur:k,onChange:R,onFocus:O,ref:A,translate:F}),[o,N,m,P,W,k,R,O,A,D,F]);return e.jsx(De,{ariaDescribedBy:c,errorMessage:l,errorMessageList:s,fieldType:"single",hasVisibleLabel:!0,hint:h,HintLinkComponent:t,id:m,isDisabled:Me,isFullWidth:Le,isOptional:Ee,label:Te,renderFieldComponent:we})}),p=n.memo(Ge);p.displayName="NativeSelect";const zo={component:p,decorators:[Oe],tags:["autodocs"],argTypes:{children:{description:"The options or optgroup elements within the native select component",table:{type:{summary:"ReactElement<'option'> | ReactElement<'optgroup'> | undefined"}}},defaultValue:{control:"text",description:"The default value of the native select component. Only applicable if `value` is not provided",table:{type:{summary:"string | string[] | undefined"}}},errorMessage:i.errorMessage,errorMessageList:i.errorMessageList,hint:i.hint,HintLinkComponent:i.HintLinkComponent,id:i.id,isDisabled:i.isDisabled,isFullWidth:i.isFullWidth,hasMultipleChoices:{control:"boolean",description:"If `true`, the native select component allows multiple selections",table:{type:{summary:"boolean"},defaultValue:{summary:"false"}}},isOptional:i.isOptional,label:{control:"text",description:"The label text for the native select component",table:{type:{summary:"string"}},type:{required:!0,name:"string"}},onBlur:{description:"Callback fired when the native select component loses focus",table:{type:{summary:"func"}}},onChange:{description:"Callback fired when the value of the native select component changes",table:{type:{summary:"func"}}},onFocus:{description:"Callback fired when the native select component gains focus",table:{type:{summary:"func"}}},value:{control:"text",description:"The value or values selected in the native select component",table:{type:{summary:"string | string[]"}}}},args:{isDisabled:!1,hint:"Select your destination in the Sol system.",isOptional:!1,label:"Destination",id:"SolarDestination",defaultValue:""}},u={render:function(o){return e.jsx(p,{...o,children:e.jsxs(e.Fragment,{children:[e.jsx("option",{value:"earth",children:"Earth"}),e.jsx("option",{value:"mars",children:"Mars"}),e.jsx("option",{value:"ceres",children:"Ceres"}),e.jsx("option",{value:"eros",children:"Eros"}),e.jsx("option",{value:"tycho-station",children:"Tycho Station"}),e.jsx("option",{value:"phoebe",children:"Phoebe"}),e.jsx("option",{value:"ganymede",children:"Ganymede"})]}),defaultValue:o.defaultValue,errorMessage:o.errorMessage,errorMessageList:o.errorMessageList,hint:o.hint,id:o.id,isDisabled:o.isDisabled,isMultiSelect:o.isMultiSelect,isOptional:o.isOptional,label:o.label})}},Pe={render:function(o){return e.jsx(p,{...o,children:e.jsxs(e.Fragment,{children:[e.jsxs("optgroup",{label:"Sol System",children:[e.jsx("option",{value:"earth",children:"Earth"}),e.jsx("option",{value:"mars",children:"Mars"}),e.jsx("option",{value:"ceres",children:"Ceres"}),e.jsx("option",{value:"eros",children:"Eros"}),e.jsx("option",{value:"tycho-station",children:"Tycho Station"}),e.jsx("option",{value:"phoebe",children:"Phoebe"}),e.jsx("option",{value:"ganymede",children:"Ganymede"})]}),e.jsxs("optgroup",{label:"Extrasolar",children:[e.jsx("option",{value:"auberon",children:"Auberon"}),e.jsx("option",{value:"al-halub",children:"Al-Halub"}),e.jsx("option",{value:"freehold",children:"Freehold"}),e.jsx("option",{value:"laconia",children:"Laconia"}),e.jsx("option",{value:"new-terra",children:"New Terra"})]})]})})}},g={...u},b={...u,args:{isDisabled:!0}},f={...u,args:{errorMessage:"Select your destination."}},x={...u,args:{errorMessage:"Select your destination.",errorMessageList:["Select 1 planet","Select 1 moon"]}},y={...Pe},j={...u,args:{hasMultipleChoices:!0,defaultValue:[]}},C={...u,args:{isOptional:!0}},S={...u,args:{HintLinkComponent:e.jsx(Ae,{href:"/learn-more",children:"Learn more"})}},M={parameters:{docs:{description:{story:"When the component is controlled, the parent component is responsible for passing `value` to the component and listening for changes with `onChange`"}}},args:{},render:function(o){const[r,l]=n.useState(""),s=n.useCallback(a=>l(a.target.value),[]);return e.jsx(p,{...o,children:e.jsxs(e.Fragment,{children:[e.jsxs("optgroup",{label:"Sol System",children:[e.jsx("option",{value:"earth",children:"Earth"}),e.jsx("option",{value:"mars",children:"Mars"}),e.jsx("option",{value:"ceres",children:"Ceres"}),e.jsx("option",{value:"eros",children:"Eros"}),e.jsx("option",{value:"tycho-station",children:"Tycho Station"}),e.jsx("option",{value:"phoebe",children:"Phoebe"}),e.jsx("option",{value:"ganymede",children:"Ganymede"})]}),e.jsxs("optgroup",{label:"Extrasolar",children:[e.jsx("option",{value:"auberon",children:"Auberon"}),e.jsx("option",{value:"al-halub",children:"Al-Halub"}),e.jsx("option",{value:"freehold",children:"Freehold"}),e.jsx("option",{value:"laconia",children:"Laconia"}),e.jsx("option",{value:"new-terra",children:"New Terra"})]})]}),onChange:s,value:r})}},L={parameters:{docs:{description:{story:"When the component is controlled, the parent component is responsible for passing `value` to the component and listening for changes with `onChange`"}}},render:function(o){const[r,l]=n.useState([""]),s=n.useCallback(a=>{const h=[a.target].filter(t=>t instanceof HTMLOptionElement).filter(t=>t.selected).map(t=>t.value);l(h)},[]);return e.jsx(p,{...o,defaultValue:void 0,hasMultipleChoices:!0,onChange:s,value:r,children:e.jsxs(e.Fragment,{children:[e.jsxs("optgroup",{label:"Sol System",children:[e.jsx("option",{value:"earth",children:"Earth"}),e.jsx("option",{value:"mars",children:"Mars"}),e.jsx("option",{value:"ceres",children:"Ceres"}),e.jsx("option",{value:"eros",children:"Eros"}),e.jsx("option",{value:"tycho-station",children:"Tycho Station"}),e.jsx("option",{value:"phoebe",children:"Phoebe"}),e.jsx("option",{value:"ganymede",children:"Ganymede"})]}),e.jsxs("optgroup",{label:"Extrasolar",children:[e.jsx("option",{value:"auberon",children:"Auberon"}),e.jsx("option",{value:"al-halub",children:"Al-Halub"}),e.jsx("option",{value:"freehold",children:"Freehold"}),e.jsx("option",{value:"laconia",children:"Laconia"}),e.jsx("option",{value:"new-terra",children:"New Terra"})]})]})})}},E={parameters:{docs:{description:{story:"When the component is controlled, the parent component is responsible for passing `value` to the component and listening for changes with `onChange`"}}},args:{},render:function(o){const[r,l]=n.useState("Laconia"),s=n.useCallback(a=>l(a.target.value),[]);return e.jsx(p,{...o,children:e.jsxs(e.Fragment,{children:[e.jsxs("optgroup",{label:"Sol System",children:[e.jsx("option",{value:"earth",children:"Earth"}),e.jsx("option",{value:"mars",children:"Mars"}),e.jsx("option",{value:"ceres",children:"Ceres"}),e.jsx("option",{value:"eros",children:"Eros"}),e.jsx("option",{value:"tycho-station",children:"Tycho Station"}),e.jsx("option",{value:"phoebe",children:"Phoebe"}),e.jsx("option",{value:"ganymede",children:"Ganymede"})]}),e.jsxs("optgroup",{label:"Extrasolar",children:[e.jsx("option",{value:"auberon",children:"Auberon"}),e.jsx("option",{value:"al-halub",children:"Al-Halub"}),e.jsx("option",{value:"freehold",children:"Freehold"}),e.jsx("option",{value:"laconia",children:"Laconia"}),e.jsx("option",{value:"new-terra",children:"New Terra"})]})]}),onChange:s,value:r})}},T={parameters:{docs:{description:{story:"When the component is controlled, the parent component is responsible for passing `value` to the component and listening for changes with `onChange`.\n\nPreselected values are referenced by the value of the `value` attritube on `option` elements."}}},render:function(o){const[r,l]=n.useState(["laconia","new-terra"]),s=n.useCallback(a=>{const h=[a.target].filter(t=>t instanceof HTMLOptionElement).filter(t=>t.selected).map(t=>t.value);l(h)},[]);return e.jsx(p,{...o,defaultValue:void 0,hasMultipleChoices:!0,onChange:s,value:r,children:e.jsxs(e.Fragment,{children:[e.jsxs("optgroup",{label:"Sol System",children:[e.jsx("option",{value:"earth",children:"Earth"}),e.jsx("option",{value:"mars",children:"Mars"}),e.jsx("option",{value:"ceres",children:"Ceres"}),e.jsx("option",{value:"eros",children:"Eros"}),e.jsx("option",{value:"tycho-station",children:"Tycho Station"}),e.jsx("option",{value:"phoebe",children:"Phoebe"}),e.jsx("option",{value:"ganymede",children:"Ganymede"})]}),e.jsxs("optgroup",{label:"Extrasolar",children:[e.jsx("option",{value:"auberon",children:"Auberon"}),e.jsx("option",{value:"al-halub",children:"Al-Halub"}),e.jsx("option",{value:"freehold",children:"Freehold"}),e.jsx("option",{value:"laconia",children:"Laconia"}),e.jsx("option",{value:"new-terra",children:"New Terra"})]})]})})}};var q,z,I;g.parameters={...g.parameters,docs:{...(q=g.parameters)==null?void 0:q.docs,source:{originalSource:`{
|
|
2
|
-
...Template
|
|
3
|
-
}`,...(I=(z=g.parameters)==null?void 0:z.docs)==null?void 0:I.source}}};var B,_,J;b.parameters={...b.parameters,docs:{...(B=b.parameters)==null?void 0:B.docs,source:{originalSource:`{
|
|
4
|
-
...Template,
|
|
5
|
-
args: {
|
|
6
|
-
isDisabled: true
|
|
7
|
-
}
|
|
8
|
-
}`,...(J=(_=b.parameters)==null?void 0:_.docs)==null?void 0:J.source}}};var K,Q,U;f.parameters={...f.parameters,docs:{...(K=f.parameters)==null?void 0:K.docs,source:{originalSource:`{
|
|
9
|
-
...Template,
|
|
10
|
-
args: {
|
|
11
|
-
errorMessage: "Select your destination."
|
|
12
|
-
}
|
|
13
|
-
}`,...(U=(Q=f.parameters)==null?void 0:Q.docs)==null?void 0:U.source}}};var X,Y,Z;x.parameters={...x.parameters,docs:{...(X=x.parameters)==null?void 0:X.docs,source:{originalSource:`{
|
|
14
|
-
...Template,
|
|
15
|
-
args: {
|
|
16
|
-
errorMessage: "Select your destination.",
|
|
17
|
-
errorMessageList: ["Select 1 planet", "Select 1 moon"]
|
|
18
|
-
}
|
|
19
|
-
}`,...(Z=(Y=x.parameters)==null?void 0:Y.docs)==null?void 0:Z.source}}};var $,ee,oe;y.parameters={...y.parameters,docs:{...($=y.parameters)==null?void 0:$.docs,source:{originalSource:`{
|
|
20
|
-
...GroupTemplate
|
|
21
|
-
}`,...(oe=(ee=y.parameters)==null?void 0:ee.docs)==null?void 0:oe.source}}};var ne,te,ae;j.parameters={...j.parameters,docs:{...(ne=j.parameters)==null?void 0:ne.docs,source:{originalSource:`{
|
|
22
|
-
...Template,
|
|
23
|
-
args: {
|
|
24
|
-
hasMultipleChoices: true,
|
|
25
|
-
defaultValue: []
|
|
26
|
-
}
|
|
27
|
-
}`,...(ae=(te=j.parameters)==null?void 0:te.docs)==null?void 0:ae.source}}};var re,le,se;C.parameters={...C.parameters,docs:{...(re=C.parameters)==null?void 0:re.docs,source:{originalSource:`{
|
|
28
|
-
...Template,
|
|
29
|
-
args: {
|
|
30
|
-
isOptional: true
|
|
31
|
-
}
|
|
32
|
-
}`,...(se=(le=C.parameters)==null?void 0:le.docs)==null?void 0:se.source}}};var ie,pe,ce;S.parameters={...S.parameters,docs:{...(ie=S.parameters)==null?void 0:ie.docs,source:{originalSource:`{
|
|
33
|
-
...Template,
|
|
34
|
-
args: {
|
|
35
|
-
HintLinkComponent: <Link href="/learn-more">Learn more</Link>
|
|
36
|
-
}
|
|
37
|
-
}`,...(ce=(pe=S.parameters)==null?void 0:pe.docs)==null?void 0:ce.source}}};var ue,de,he;M.parameters={...M.parameters,docs:{...(ue=M.parameters)==null?void 0:ue.docs,source:{originalSource:`{
|
|
38
|
-
parameters: {
|
|
39
|
-
docs: {
|
|
40
|
-
description: {
|
|
41
|
-
story: "When the component is controlled, the parent component is responsible for passing \`value\` to the component and listening for changes with \`onChange\`"
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
},
|
|
45
|
-
args: {},
|
|
46
|
-
render: function C(args) {
|
|
47
|
-
const [localValue, setLocalValue] = useState("");
|
|
48
|
-
const onChange = useCallback((event: SelectChangeEvent<string | string[]>) => setLocalValue(event.target.value as string), []);
|
|
49
|
-
return <NativeSelect {...args} children={<>
|
|
50
|
-
<optgroup label="Sol System">
|
|
51
|
-
<option value="earth">Earth</option>
|
|
52
|
-
<option value="mars">Mars</option>
|
|
53
|
-
<option value="ceres">Ceres</option>
|
|
54
|
-
<option value="eros">Eros</option>
|
|
55
|
-
<option value="tycho-station">Tycho Station</option>
|
|
56
|
-
<option value="phoebe">Phoebe</option>
|
|
57
|
-
<option value="ganymede">Ganymede</option>
|
|
58
|
-
</optgroup>
|
|
59
|
-
<optgroup label="Extrasolar">
|
|
60
|
-
<option value="auberon">Auberon</option>
|
|
61
|
-
<option value="al-halub">Al-Halub</option>
|
|
62
|
-
<option value="freehold">Freehold</option>
|
|
63
|
-
<option value="laconia">Laconia</option>
|
|
64
|
-
<option value="new-terra">New Terra</option>
|
|
65
|
-
</optgroup>
|
|
66
|
-
</>} onChange={onChange} value={localValue} />;
|
|
67
|
-
}
|
|
68
|
-
}`,...(he=(de=M.parameters)==null?void 0:de.docs)==null?void 0:he.source}}};var me,ve,ge;L.parameters={...L.parameters,docs:{...(me=L.parameters)==null?void 0:me.docs,source:{originalSource:`{
|
|
69
|
-
parameters: {
|
|
70
|
-
docs: {
|
|
71
|
-
description: {
|
|
72
|
-
story: "When the component is controlled, the parent component is responsible for passing \`value\` to the component and listening for changes with \`onChange\`"
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
},
|
|
76
|
-
render: function C(args) {
|
|
77
|
-
const [localValue, setLocalValue] = useState([""]);
|
|
78
|
-
const onChange = useCallback<Required<NativeSelectProps<typeof localValue, true>>["onChange"]>(event => {
|
|
79
|
-
const selectedOptions = [event.target].filter(option => option instanceof HTMLOptionElement).filter(option => option.selected).map(selectedOption => selectedOption.value);
|
|
80
|
-
setLocalValue(selectedOptions);
|
|
81
|
-
}, []);
|
|
82
|
-
return <NativeSelect {...args} defaultValue={undefined} hasMultipleChoices={true}
|
|
83
|
-
// @ts-expect-error This is going to break because generics aren't passed through.
|
|
84
|
-
onChange={onChange} value={localValue}>
|
|
85
|
-
<>
|
|
86
|
-
<optgroup label="Sol System">
|
|
87
|
-
<option value="earth">Earth</option>
|
|
88
|
-
<option value="mars">Mars</option>
|
|
89
|
-
<option value="ceres">Ceres</option>
|
|
90
|
-
<option value="eros">Eros</option>
|
|
91
|
-
<option value="tycho-station">Tycho Station</option>
|
|
92
|
-
<option value="phoebe">Phoebe</option>
|
|
93
|
-
<option value="ganymede">Ganymede</option>
|
|
94
|
-
</optgroup>
|
|
95
|
-
<optgroup label="Extrasolar">
|
|
96
|
-
<option value="auberon">Auberon</option>
|
|
97
|
-
<option value="al-halub">Al-Halub</option>
|
|
98
|
-
<option value="freehold">Freehold</option>
|
|
99
|
-
<option value="laconia">Laconia</option>
|
|
100
|
-
<option value="new-terra">New Terra</option>
|
|
101
|
-
</optgroup>
|
|
102
|
-
</>
|
|
103
|
-
</NativeSelect>;
|
|
104
|
-
}
|
|
105
|
-
}`,...(ge=(ve=L.parameters)==null?void 0:ve.docs)==null?void 0:ge.source}}};var be,fe,xe;E.parameters={...E.parameters,docs:{...(be=E.parameters)==null?void 0:be.docs,source:{originalSource:`{
|
|
106
|
-
parameters: {
|
|
107
|
-
docs: {
|
|
108
|
-
description: {
|
|
109
|
-
story: "When the component is controlled, the parent component is responsible for passing \`value\` to the component and listening for changes with \`onChange\`"
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
},
|
|
113
|
-
args: {},
|
|
114
|
-
render: function C(args) {
|
|
115
|
-
const [localValue, setLocalValue] = useState("Laconia");
|
|
116
|
-
const onChange = useCallback((event: SelectChangeEvent<string | string[]>) => setLocalValue(event.target.value as string), []);
|
|
117
|
-
return <NativeSelect {...args} children={<>
|
|
118
|
-
<optgroup label="Sol System">
|
|
119
|
-
<option value="earth">Earth</option>
|
|
120
|
-
<option value="mars">Mars</option>
|
|
121
|
-
<option value="ceres">Ceres</option>
|
|
122
|
-
<option value="eros">Eros</option>
|
|
123
|
-
<option value="tycho-station">Tycho Station</option>
|
|
124
|
-
<option value="phoebe">Phoebe</option>
|
|
125
|
-
<option value="ganymede">Ganymede</option>
|
|
126
|
-
</optgroup>
|
|
127
|
-
<optgroup label="Extrasolar">
|
|
128
|
-
<option value="auberon">Auberon</option>
|
|
129
|
-
<option value="al-halub">Al-Halub</option>
|
|
130
|
-
<option value="freehold">Freehold</option>
|
|
131
|
-
<option value="laconia">Laconia</option>
|
|
132
|
-
<option value="new-terra">New Terra</option>
|
|
133
|
-
</optgroup>
|
|
134
|
-
</>} onChange={onChange} value={localValue} />;
|
|
135
|
-
}
|
|
136
|
-
}`,...(xe=(fe=E.parameters)==null?void 0:fe.docs)==null?void 0:xe.source}}};var ye,je,Ce;T.parameters={...T.parameters,docs:{...(ye=T.parameters)==null?void 0:ye.docs,source:{originalSource:`{
|
|
137
|
-
parameters: {
|
|
138
|
-
docs: {
|
|
139
|
-
description: {
|
|
140
|
-
story: "When the component is controlled, the parent component is responsible for passing \`value\` to the component and listening for changes with \`onChange\`.\\n\\nPreselected values are referenced by the value of the \`value\` attritube on \`option\` elements."
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
},
|
|
144
|
-
render: function C(args) {
|
|
145
|
-
const [localValue, setLocalValue] = useState(["laconia", "new-terra"]);
|
|
146
|
-
const onChange = useCallback<Required<NativeSelectProps<typeof localValue, true>>["onChange"]>(event => {
|
|
147
|
-
const selectedOptions = [event.target].filter(option => option instanceof HTMLOptionElement).filter(option => option.selected).map(selectedOption => selectedOption.value);
|
|
148
|
-
setLocalValue(selectedOptions);
|
|
149
|
-
}, []);
|
|
150
|
-
return <NativeSelect {...args} defaultValue={undefined} hasMultipleChoices
|
|
151
|
-
// @ts-expect-error This is going to break because generics aren't passed through.
|
|
152
|
-
onChange={onChange} value={localValue}>
|
|
153
|
-
<>
|
|
154
|
-
<optgroup label="Sol System">
|
|
155
|
-
<option value="earth">Earth</option>
|
|
156
|
-
<option value="mars">Mars</option>
|
|
157
|
-
<option value="ceres">Ceres</option>
|
|
158
|
-
<option value="eros">Eros</option>
|
|
159
|
-
<option value="tycho-station">Tycho Station</option>
|
|
160
|
-
<option value="phoebe">Phoebe</option>
|
|
161
|
-
<option value="ganymede">Ganymede</option>
|
|
162
|
-
</optgroup>
|
|
163
|
-
<optgroup label="Extrasolar">
|
|
164
|
-
<option value="auberon">Auberon</option>
|
|
165
|
-
<option value="al-halub">Al-Halub</option>
|
|
166
|
-
<option value="freehold">Freehold</option>
|
|
167
|
-
<option value="laconia">Laconia</option>
|
|
168
|
-
<option value="new-terra">New Terra</option>
|
|
169
|
-
</optgroup>
|
|
170
|
-
</>
|
|
171
|
-
</NativeSelect>;
|
|
172
|
-
}
|
|
173
|
-
}`,...(Ce=(je=T.parameters)==null?void 0:je.docs)==null?void 0:Ce.source}}};const Io=["Default","DefaultDisabled","DefaultError","ErrorsList","DefaultGrouped","Multi","Optional","HintLink","Controlled","ControlledMultiselect","ControlledPreselected","ControlledPreselectedMultiselect"];export{M as Controlled,L as ControlledMultiselect,E as ControlledPreselected,T as ControlledPreselectedMultiselect,g as Default,b as DefaultDisabled,f as DefaultError,y as DefaultGrouped,x as ErrorsList,S as HintLink,j as Multi,C as Optional,Io as __namedExportsOrder,zo as default};
|