@viasat/beam-react 2.8.0 → 2.10.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/assets/ActionList.css +1 -1
- package/assets/{Search.Results.css → Search.css} +1 -1
- package/assets/panel.css +1 -1
- package/chunks/{ActionList.Group.C2R56u2A.js → ActionList.Group.Bw5vZpeb.js} +1 -1
- package/chunks/{ActionList.Group.B4PX5SKS.js → ActionList.Group.CUHMD8Oo.js} +3 -3
- package/chunks/ActionList.Item.CxvNhTRB.js +188 -0
- package/chunks/ActionList.Item.YxZyttjT.js +1 -0
- package/chunks/{Avatar.C9tpC3sT.js → Avatar.C-4xc2_q.js} +3 -3
- package/chunks/{BreadcrumbsItem.CPJ-ECZa.js → BreadcrumbsItem.fDLMzx4K.js} +3 -3
- package/chunks/{CSSLookup.Cjf6o2Gz.js → CSSLookup.DOOy1rxJ.js} +1 -1
- package/chunks/Search.Results.DBQWuhZu.js +1 -0
- package/chunks/Search.Results.DR20Rl2x.js +66 -0
- package/chunks/{SpinnerWrap.DI2J26ka.js → SpinnerWrap.DWZk-Vfo.js} +4 -4
- package/chunks/{ToastContext.DzKCvrgk.js → ToastContext.CYGy7l7R.js} +1 -1
- package/chunks/{classNames.DNsS4J__.js → classNames.BTJmrO_L.js} +2 -2
- package/chunks/{constants.BBi77pmH.js → constants.CKKGf1-i.js} +5 -5
- package/chunks/{form.context.CfsTSQpm.js → form.context.BhylRiG2.js} +2 -2
- package/chunks/{helpers.Wv7n4ip7.js → helpers.CPNYYxrE.js} +1 -1
- package/chunks/{panel.module.RGiUyC84.js → panel.module.BVm3KvDs.js} +14 -4
- package/chunks/panel.module.BX1x4FlX.js +1 -0
- package/index.es.js +3 -3
- package/lib/Accordion/Accordion.es.js +1 -1
- package/lib/Accordion/AccordionGroup.es.js +1 -1
- package/lib/ActionList/ActionList.Group.cjs.js +1 -1
- package/lib/ActionList/ActionList.Group.es.js +4 -4
- package/lib/ActionList/ActionList.IconButton.cjs.js +1 -1
- package/lib/ActionList/ActionList.IconButton.es.js +3 -3
- package/lib/ActionList/ActionList.Item.cjs.js +1 -1
- package/lib/ActionList/ActionList.Item.d.ts +18 -7
- package/lib/ActionList/ActionList.Item.es.js +4 -4
- package/lib/ActionList/ActionList.cjs.js +1 -1
- package/lib/ActionList/ActionList.d.ts +1 -1
- package/lib/ActionList/ActionList.es.js +5 -5
- package/lib/ActionList/useActionListChildren.cjs.js +1 -1
- package/lib/ActionList/useActionListChildren.es.js +2 -2
- package/lib/Alert/Alert.es.js +4 -4
- package/lib/Autocomplete/Autocomplete.cjs.js +1 -1
- package/lib/Autocomplete/Autocomplete.es.js +6 -6
- package/lib/Autocomplete/AutocompleteDropdown.es.js +3 -3
- package/lib/Autocomplete/AutocompleteField.es.js +2 -2
- package/lib/Autocomplete/useAutocompleteA11y.es.js +1 -1
- package/lib/Autocomplete/useAutocompleteDropdown.es.js +1 -1
- package/lib/Avatar/Avatar.es.js +1 -1
- package/lib/Avatar/AvatarGroup.es.js +3 -3
- package/lib/Avatar/index.es.js +1 -1
- package/lib/Badge/Badge.es.js +2 -2
- package/lib/BadgeDot/BadgeDot.es.js +2 -2
- package/lib/Box/Box.es.js +4 -4
- package/lib/Breadcrumbs/Breadcrumbs.es.js +3 -3
- package/lib/Breadcrumbs/BreadcrumbsItem.es.js +2 -2
- package/lib/Breadcrumbs/index.es.js +1 -1
- package/lib/Button/Button.es.js +3 -3
- package/lib/Card/AspectRatio.es.js +2 -2
- package/lib/Card/Card.Body.es.js +2 -2
- package/lib/Card/Card.Content.es.js +2 -2
- package/lib/Card/Card.Footer.es.js +2 -2
- package/lib/Card/Card.Header.es.js +2 -2
- package/lib/Card/Card.Media.es.js +2 -2
- package/lib/Card/Card.es.js +3 -3
- package/lib/Card/CardGroup.es.js +3 -3
- package/lib/Checkbox/Checkbox.es.js +3 -3
- package/lib/Chips/Chip.es.js +2 -2
- package/lib/Chips/ChipGroup.es.js +2 -2
- package/lib/CloseButton/CloseButton.es.js +2 -2
- package/lib/Dialog/Dialog.Body.es.js +2 -2
- package/lib/Dialog/Dialog.Content.es.js +2 -2
- package/lib/Dialog/Dialog.Footer.es.js +1 -1
- package/lib/Dialog/Dialog.Header.es.js +2 -2
- package/lib/Divider/Divider.es.js +2 -2
- package/lib/EmptyState/EmptyState.es.js +3 -3
- package/lib/FileUpload/FileUpload.Button.es.js +2 -2
- package/lib/FileUpload/FileUpload.Dropzone.es.js +2 -2
- package/lib/FileUpload/FileUpload.List.Item.es.js +3 -3
- package/lib/FileUpload/FileUpload.List.es.js +2 -2
- package/lib/FileUpload/FileUpload.es.js +3 -3
- package/lib/FileUpload/useFileManagement.es.js +1 -1
- package/lib/Flag/Flag.es.js +2 -2
- package/lib/FloatingUI/FloatingUI.arrow.es.js +2 -2
- package/lib/FloatingUI/FloatingUI.content.es.js +2 -2
- package/lib/FloatingUI/index.cjs.js +1 -1
- package/lib/FloatingUI/index.es.js +6 -6
- package/lib/Form/Form.es.js +2 -2
- package/lib/Form/contexts/form.context.es.js +2 -2
- package/lib/Form/contexts/index.es.js +1 -1
- package/lib/Form/hooks/index.es.js +1 -1
- package/lib/Form/hooks/useAccessibleId.hook.es.js +1 -1
- package/lib/Form/hooks/useFieldValidator.hook.es.js +1 -1
- package/lib/Header/Header.es.js +2 -2
- package/lib/Header/HeaderActionGroup.es.js +2 -2
- package/lib/Header/HeaderMasthead.es.js +2 -2
- package/lib/Header/HeaderSideNavTrigger.es.js +2 -2
- package/lib/HelperText/HelperText.es.js +3 -3
- package/lib/HelperText/index.es.js +1 -1
- package/lib/Icon/Icon.es.js +2 -2
- package/lib/InputChoiceGroup/InputChoiceGroup.es.js +3 -3
- package/lib/Label/Label.es.js +3 -3
- package/lib/Link/Link.es.js +2 -2
- package/lib/List/List.Item.es.js +2 -2
- package/lib/List/List.es.js +2 -2
- package/lib/Logo/Logo.es.js +2 -2
- package/lib/Menu/Menu.PopoverContent.es.js +2 -2
- package/lib/NativeSelect/NativeSelect.es.js +4 -4
- package/lib/PageHeader/PageHeader.es.js +2 -2
- package/lib/PageLayout/PageLayout.es.js +2 -2
- package/lib/PageLayout/PageLayoutAside.es.js +2 -2
- package/lib/PageLayout/PageLayoutHeader.es.js +2 -2
- package/lib/PageLayout/PageLayoutMain.es.js +2 -2
- package/lib/Pagination/PageButton.es.js +2 -2
- package/lib/Pagination/Pagination.es.js +2 -2
- package/lib/Pagination/PaginationControls.es.js +1 -1
- package/lib/Pagination/Truncation.es.js +2 -2
- package/lib/Popover/Popover.content.es.js +2 -2
- package/lib/Popover/Popover.es.js +3 -3
- package/lib/Popover/Popover.utils.es.js +2 -2
- package/lib/ProgressBar/ProgressBar.es.js +3 -3
- package/lib/RadioButton/RadioButton.es.js +3 -3
- package/lib/SegmentedControl/SegmentedControl.Item.es.js +2 -2
- package/lib/SegmentedControl/SegmentedControl.List.es.js +2 -2
- package/lib/SegmentedControl/SegmentedControl.Panel.es.js +2 -2
- package/lib/SegmentedControl/SegmentedControl.es.js +2 -2
- package/lib/Select/Select.cjs.js +1 -1
- package/lib/Select/Select.es.js +5 -5
- package/lib/Select/SelectDropdown.es.js +3 -3
- package/lib/Select/SelectField.es.js +2 -2
- package/lib/Select/useSelectA11y.es.js +1 -1
- package/lib/SideNav/SideNav.es.js +2 -2
- package/lib/SideNav/SideNavActionListGroup.cjs.js +1 -1
- package/lib/SideNav/SideNavActionListGroup.es.js +3 -3
- package/lib/SideNav/SideNavActionListGroupHeading.es.js +2 -2
- package/lib/SideNav/SideNavActionListItem.cjs.js +1 -1
- package/lib/SideNav/SideNavActionListItem.es.js +3 -3
- package/lib/SideNav/SideNavActionListItemExpandable.cjs.js +1 -1
- package/lib/SideNav/SideNavActionListItemExpandable.es.js +3 -3
- package/lib/SideNav/SideNavActionListItemFlyout.cjs.js +1 -1
- package/lib/SideNav/SideNavActionListItemFlyout.es.js +1 -1
- package/lib/SideNav/SideNavBody.es.js +3 -3
- package/lib/SideNav/SideNavContext.es.js +2 -2
- package/lib/SideNav/SideNavFooter.es.js +2 -2
- package/lib/SideNav/SideNavHeader.es.js +2 -2
- package/lib/Slider/DualSlider.es.js +3 -3
- package/lib/Slider/SingleSlider.es.js +6 -6
- package/lib/Slider/Slider.Error.es.js +3 -3
- package/lib/Slider/Slider.TextField.es.js +2 -2
- package/lib/Slider/Slider.Thumb.es.js +4 -4
- package/lib/Slider/Slider.TickMarks.es.js +2 -2
- package/lib/Slider/Slider.ValueAxisLabels.es.js +2 -2
- package/lib/Slider/hooks/useSliderBase.es.js +2 -2
- package/lib/Spinner/Spinner.es.js +7 -7
- package/lib/Spinner/SpinnerWrap.es.js +1 -1
- package/lib/StateLayer/StateLayer.es.js +2 -2
- package/lib/Stepper/Stepper.Body.es.js +2 -2
- package/lib/Stepper/Stepper.Heading.es.js +2 -2
- package/lib/Stepper/Stepper.Marker.es.js +2 -2
- package/lib/Stepper/Stepper.Step.es.js +2 -2
- package/lib/Stepper/Stepper.es.js +2 -2
- package/lib/Switch/Switch.es.js +3 -3
- package/lib/Tabs/Tabs.Group.es.js +3 -3
- package/lib/Tabs/Tabs.Item.es.js +2 -2
- package/lib/Tabs/Tabs.Panel.es.js +2 -2
- package/lib/Tabs/Tabs.es.js +2 -2
- package/lib/Text/Text.es.js +2 -2
- package/lib/TextArea/TextArea.es.js +3 -3
- package/lib/TextField/TextField.es.js +3 -3
- package/lib/Toasts/Toast.es.js +4 -4
- package/lib/Toasts/ToastContainer.es.js +4 -4
- package/lib/Toasts/ToastContext.es.js +1 -1
- package/lib/Toasts/index.es.js +1 -1
- package/lib/Tooltip/Tooltip.es.js +3 -3
- package/lib/_Navigation/classes.es.js +2 -2
- package/lib/_Options/OptionChips.es.js +2 -2
- package/lib/_Options/useSelectValue.es.js +2 -2
- package/lib/index.es.js +3 -3
- package/lib/wip/Panel/Panel.Body.cjs.js +1 -1
- package/lib/wip/Panel/Panel.Body.es.js +3 -3
- package/lib/wip/Panel/Panel.Footer.Actions.cjs.js +1 -1
- package/lib/wip/Panel/Panel.Footer.Actions.es.js +3 -3
- package/lib/wip/Panel/Panel.Footer.cjs.js +1 -1
- package/lib/wip/Panel/Panel.Footer.d.ts +2 -2
- package/lib/wip/Panel/Panel.Footer.es.js +13 -13
- package/lib/wip/Panel/Panel.Header.ContentAfter.cjs.js +1 -1
- package/lib/wip/Panel/Panel.Header.ContentAfter.es.js +3 -3
- package/lib/wip/Panel/Panel.Header.ContentBefore.cjs.js +1 -1
- package/lib/wip/Panel/Panel.Header.ContentBefore.es.js +3 -3
- package/lib/wip/Panel/Panel.Header.Description.cjs.js +1 -1
- package/lib/wip/Panel/Panel.Header.Description.es.js +3 -3
- package/lib/wip/Panel/Panel.Header.Heading.cjs.js +1 -1
- package/lib/wip/Panel/Panel.Header.Heading.es.js +3 -3
- package/lib/wip/Panel/Panel.Header.Row.cjs.js +1 -1
- package/lib/wip/Panel/Panel.Header.Row.es.js +3 -3
- package/lib/wip/Panel/Panel.Header.Subheader.cjs.js +1 -1
- package/lib/wip/Panel/Panel.Header.Subheader.es.js +3 -3
- package/lib/wip/Panel/Panel.Header.cjs.js +1 -1
- package/lib/wip/Panel/Panel.Header.d.ts +2 -2
- package/lib/wip/Panel/Panel.Header.es.js +21 -21
- package/lib/wip/Panel/Panel.cjs.js +1 -1
- package/lib/wip/Panel/Panel.context.d.ts +5 -0
- package/lib/wip/Panel/Panel.d.ts +3 -3
- package/lib/wip/Panel/Panel.es.js +113 -39
- package/lib/wip/Panel/Panel.helpers.cjs.js +1 -0
- package/lib/wip/Panel/Panel.helpers.d.ts +13 -0
- package/lib/wip/Panel/Panel.helpers.es.js +40 -0
- package/lib/wip/Panel/Panel.types.d.ts +16 -11
- package/lib/wip/Search/Search.Results.Item.cjs.js +1 -1
- package/lib/wip/Search/Search.Results.Item.d.ts +8 -5
- package/lib/wip/Search/Search.Results.Item.es.js +8 -10
- package/lib/wip/Search/Search.Results.ViewAll.cjs.js +1 -0
- package/lib/wip/Search/Search.Results.ViewAll.d.ts +22 -0
- package/lib/wip/Search/Search.Results.ViewAll.es.js +11 -0
- package/lib/wip/Search/Search.Results.cjs.js +1 -1
- package/lib/wip/Search/Search.Results.d.ts +5 -2
- package/lib/wip/Search/Search.Results.es.js +12 -17
- package/lib/wip/Search/Search.cjs.js +1 -1
- package/lib/wip/Search/Search.es.js +114 -110
- package/lib/wip/Search/SearchDropdown.cjs.js +1 -1
- package/lib/wip/Search/SearchDropdown.d.ts +2 -3
- package/lib/wip/Search/SearchDropdown.es.js +45 -59
- package/lib/wip/Search/useSearchDropdown.cjs.js +1 -1
- package/lib/wip/Search/useSearchDropdown.d.ts +0 -18
- package/lib/wip/Search/useSearchDropdown.es.js +25 -25
- package/package.json +6 -6
- package/utils/hooks/index.es.js +3 -3
- package/utils/hooks/useElementResize.es.js +2 -2
- package/utils/hooks/useId.es.js +1 -1
- package/utils/hooks/useLocalStorage.es.js +2 -2
- package/utils/spacing.es.js +1 -1
- package/utils/theming/useBeamTheme.es.js +5 -5
- package/chunks/ActionList.Item.5Y-SwzjK.js +0 -1
- package/chunks/ActionList.Item.BFcT86lS.js +0 -187
- package/chunks/Search.Results.Item.CLmMBPz1.js +0 -41
- package/chunks/Search.Results.Item.Dkh2yo4p.js +0 -1
- package/chunks/panel.module.DbEoAg1J.js +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { b as c } from "../../chunks/constants.
|
|
2
|
-
import { d as w } from "../../chunks/helpers.
|
|
1
|
+
import { b as c } from "../../chunks/constants.CKKGf1-i.js";
|
|
2
|
+
import { d as w } from "../../chunks/helpers.CPNYYxrE.js";
|
|
3
3
|
import s from "react";
|
|
4
4
|
function d(t, e) {
|
|
5
5
|
typeof window > "u" || !window.localStorage || window.dispatchEvent(new StorageEvent("storage", { key: t, newValue: e }));
|
package/utils/spacing.es.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as O } from "react/jsx-runtime";
|
|
2
2
|
import * as c from "react";
|
|
3
3
|
import { createContext as G, useContext as q, useMemo as I, useCallback as w, useState as X, useEffect as M, useRef as Z } from "react";
|
|
4
|
-
import { e as U, A as B, P as K, t as Y, f as F, d as H, D as P,
|
|
4
|
+
import { e as U, A as B, P as K, t as Y, f as F, d as H, D as P, g as Q, h as ee, p as te, i as ne, j as se, k as re, l as N } from "../../chunks/constants.CKKGf1-i.js";
|
|
5
5
|
var oe = (e, s, n, r, t, o, d, l) => {
|
|
6
6
|
let u = document.documentElement, E = ["light", "dark"];
|
|
7
7
|
function y(m) {
|
|
@@ -90,10 +90,10 @@ const k = (e) => [
|
|
|
90
90
|
].join(" "), ye = (e) => {
|
|
91
91
|
var o, d;
|
|
92
92
|
if (!e) return P;
|
|
93
|
-
e = e.replaceAll(
|
|
94
|
-
const s = e.split(" "), n = U.find((l) => s.includes(l)) ??
|
|
93
|
+
e = e.replaceAll(te, "");
|
|
94
|
+
const s = e.split(" "), n = U.find((l) => s.includes(l)) ?? ne, r = ((o = Object.entries(B).find(([, l]) => s.includes(l))) == null ? void 0 : o[1]) ?? se, t = ((d = Object.entries(K).find(
|
|
95
95
|
([, l]) => s.includes(l)
|
|
96
|
-
)) == null ? void 0 : d[1]) ??
|
|
96
|
+
)) == null ? void 0 : d[1]) ?? re;
|
|
97
97
|
return { mode: n, accent: r, productType: t };
|
|
98
98
|
}, Te = Object.values(U).flatMap(
|
|
99
99
|
(e) => Object.values(B).flatMap(
|
|
@@ -126,7 +126,7 @@ const z = G(null), Ee = ie, Se = ({
|
|
|
126
126
|
return /* @__PURE__ */ O(
|
|
127
127
|
Ee,
|
|
128
128
|
{
|
|
129
|
-
attribute:
|
|
129
|
+
attribute: ee,
|
|
130
130
|
storageKey: Q,
|
|
131
131
|
defaultTheme: k(o),
|
|
132
132
|
themes: Te,
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var At=require("../assets/ActionList.css");const e=require("react/jsx-runtime"),tt=require("../lib/ActionList/ActionListIndentationContext.cjs.js"),et=require("clsx"),it=require("./classNames.DAeKwerT.js");require("./constants.hwjHOsvT.js");const w=require("../lib/Icon/Icon.cjs.js"),N=require("./tokens.Bc11gmpN.js"),st=require("./Check.CR4kqxW9.js"),ot=require("./ChevronRightCurved.CoT-Bqyo.js"),nt=require("../lib/StateLayer/StateLayer.cjs.js"),ct=require("../lib/ActionList/ActionListSelectionContext.cjs.js"),rt=require("../lib/Tooltip/Tooltip.cjs.js"),x=require("../utils/functions.cjs.js"),lt=require("../lib/Tooltip/useTooltipClipping.cjs.js"),o=require("react"),at=require("../lib/Checkbox/Checkbox.cjs.js"),_t=require("../lib/RadioButton/RadioButton.cjs.js"),mt=require("@floating-ui/react"),ut=require("../lib/ActionList/ActionList.Item.context.cjs.js"),bt=require("../lib/ActionList/ActionList.context.cjs.js"),dt=require("../lib/Form/hooks/useAccessibleId.hook.cjs.js");require("./form.context.B26th8Od.js");const ht=require("../lib/Switch/Switch.cjs.js"),i={"bm-light":"bm-light","bm-dark":"bm-dark","bm-inverse":"bm-inverse","bm-action-list":"bm-action-list","bm-action-list__no-results":"bm-action-list__no-results","bm-action-list__loading":"bm-action-list__loading","bm-action-list__item":"bm-action-list__item","bm-action-list__item__supporting-text":"bm-action-list__item__supporting-text","bm-action-list__item--kind-destructive":"bm-action-list__item--kind-destructive","bm-action-list__item--disabled":"bm-action-list__item--disabled","bm-state-layer":"bm-state-layer","bm-action-list__item--active":"bm-action-list__item--active","bm-action-list__item__choice":"bm-action-list__item__choice","bm-action-list__item__switch":"bm-action-list__item__switch","bm-action-list__item__content-before":"bm-action-list__item__content-before","bm-action-list__item__content":"bm-action-list__item__content","bm-action-list__item__text":"bm-action-list__item__text","bm-action-list__item--header":"bm-action-list__item--header","bm-action-list__item__content-after":"bm-action-list__item__content-after","bm-button":"bm-button","bm-action-list__item__flyout":"bm-action-list__item__flyout","bm-action-list__group":"bm-action-list__group","bm-action-list__group__heading":"bm-action-list__group__heading","bm-action-list__group__no-results":"bm-action-list__group__no-results","bm-action-list__group__divider":"bm-action-list__group__divider","bm-action-list__item__icon-button__placeholder":"bm-action-list__item__icon-button__placeholder"},xt="singleCheckMark",ft="multiCheckMark",kt="checkbox",Ct="radio",pt="switch",vt=[xt,ft,kt,Ct,pt],k=r=>vt.includes(r),{baseClassNamePrefix:gt,classModifierPrefix:f,subElementClassPrefix:n}=it.getBEMClassNames("action-list__item"),C=o.createContext({current:null}),qt=()=>o.useContext(C),yt=o.forwardRef(({children:r,supportingText:p,contentAfter:v,contentBefore:g,onClick:a,onSelectionChange:$,defaultSelected:M=!1,kind:T="action",indent:F,disabled:l=!1,className:D,role:_,tooltipPlacement:E,hidden:K,...P},O)=>{const{kind:t}=ut.useActionListItemContext(T),{onItemClick:m,itemsFocusable:z,getItemProps:u,insideMenu:q,activeIndex:B}=bt.useActionListContext(),{selected:b,setSelected:G}=ct.useActionListItemSelection(t,M,$),[c,H]=o.useState(b);o.useEffect(()=>{requestAnimationFrame(()=>H(b))},[b]);const y=k(t),J=t==="flyout",d=tt.useActionListIndentation({isChoiceItem:y,indentProp:F}),{index:A,ref:Q}=mt.useListItem({label:l?null:x.extractTextFromReactNode(r)}),I=s=>{l||(k(t)?G(!c):a==null||a(s),m==null||m(A,t,s.nativeEvent))},U=s=>{(s.key==="Enter"||s.key===" ")&&(s.preventDefault(),I(s))},h=o.useCallback(s=>{s.preventDefault()},[]),L=o.useRef(null),R=o.useRef(null),V=lt.useTooltipClipping({clippingRef:R}),W=x.mergeRefs(Q,O),X=o.useMemo(()=>_||(q?t==="singleCheckMark"||t==="radio"?"menuitemradio":t==="multiCheckMark"||t==="checkbox"||t==="switch"?"menuitemcheckbox":"menuitem":"option"),[_,q,t]),j={...P,onClick:I,tabIndex:z?0:-1},{id:Y}=dt.useAccessibleId(),S=B===A,Z=et(i[gt],i[`${f}kind-${t}`],l&&i[`${f}disabled`],S&&i[`${f}active`],D);return e.jsxs(C.Provider,{value:L,children:[e.jsx(rt.Tooltip,{showDelay:500,portalled:!0,text:x.extractTextFromReactNode(r),...V,placement:E,children:e.jsxs("div",{className:Z,role:X,"aria-checked":c||void 0,"aria-selected":S||void 0,"aria-disabled":l,onKeyDown:U,id:Y,...(u==null?void 0:u(j))??j,ref:W,hidden:K,children:[d&&e.jsx("div",{style:{width:d===!0?N.bmCompActionlistSizeIcon:`${d}rem`}}),y&&t!=="switch"&&e.jsxs("div",{className:i[`${n}choice`],inert:"",children:[(t==="singleCheckMark"||t==="multiCheckMark")&&c&&e.jsx(w.Icon,{customIconSize:N.bmCompActionlistSizeChoice,icon:st.SvgCheck}),t==="checkbox"&&e.jsx(at.Checkbox,{checked:c,onChange:h}),t==="radio"&&e.jsx(_t.RadioButton,{checked:c,onChange:h})]}),g&&e.jsx("div",{className:i[`${n}content-before`],children:g}),e.jsxs("div",{className:i[`${n}content`],children:[e.jsx("div",{className:i[`${n}text`],ref:R,children:r}),p&&e.jsx("div",{className:i[`${n}supporting-text`],children:p})]}),v&&e.jsx("div",{className:i[`${n}content-after`],children:v}),t==="switch"&&e.jsx("div",{className:i[`${n}switch`],inert:"",children:e.jsx(ht.Switch,{checked:c,onChange:h})}),J&&e.jsx(w.Icon,{className:i[`${n}flyout`],icon:ot.SvgChevronRightCurved}),e.jsx(nt.StateLayer,{})]})}),e.jsx("div",{ref:L})]})});exports.ActionListItem=yt;exports.ActionListItemOverlayRefContext=C;exports.isChoiceKind=k;exports.styles=i;exports.useActionListItemOverlayRef=qt;
|
|
@@ -1,187 +0,0 @@
|
|
|
1
|
-
import "../assets/ActionList.css";
|
|
2
|
-
import { jsxs as a, jsx as i } from "react/jsx-runtime";
|
|
3
|
-
import { useActionListIndentation as tt } from "../lib/ActionList/ActionListIndentationContext.es.js";
|
|
4
|
-
import it from "clsx";
|
|
5
|
-
import { g as et } from "./classNames.DNsS4J__.js";
|
|
6
|
-
import "./constants.BBi77pmH.js";
|
|
7
|
-
import { Icon as $ } from "../lib/Icon/Icon.es.js";
|
|
8
|
-
import { n as ot, o as st } from "./tokens.BD_71qmL.js";
|
|
9
|
-
import { S as nt } from "./Check.DrrmNVhJ.js";
|
|
10
|
-
import { S as ct } from "./ChevronRightCurved.9hi9Zc8J.js";
|
|
11
|
-
import { StateLayer as mt } from "../lib/StateLayer/StateLayer.es.js";
|
|
12
|
-
import { useActionListItemSelection as at } from "../lib/ActionList/ActionListSelectionContext.es.js";
|
|
13
|
-
import { Tooltip as rt } from "../lib/Tooltip/Tooltip.es.js";
|
|
14
|
-
import { extractTextFromReactNode as A, mergeRefs as lt } from "../utils/functions.es.js";
|
|
15
|
-
import { useTooltipClipping as _t } from "../lib/Tooltip/useTooltipClipping.es.js";
|
|
16
|
-
import { createContext as dt, forwardRef as bt, useState as ut, useEffect as ht, useCallback as ft, useRef as M, useMemo as pt, useContext as kt } from "react";
|
|
17
|
-
import { Checkbox as gt } from "../lib/Checkbox/Checkbox.es.js";
|
|
18
|
-
import { RadioButton as vt } from "../lib/RadioButton/RadioButton.es.js";
|
|
19
|
-
import { useListItem as Ct } from "@floating-ui/react";
|
|
20
|
-
import { useActionListItemContext as xt } from "../lib/ActionList/ActionList.Item.context.es.js";
|
|
21
|
-
import { useActionListContext as yt } from "../lib/ActionList/ActionList.context.es.js";
|
|
22
|
-
import { useAccessibleId as wt } from "../lib/Form/hooks/useAccessibleId.hook.es.js";
|
|
23
|
-
import "./form.context.CfsTSQpm.js";
|
|
24
|
-
import { Switch as It } from "../lib/Switch/Switch.es.js";
|
|
25
|
-
const e = {
|
|
26
|
-
"bm-light": "bm-light",
|
|
27
|
-
"bm-dark": "bm-dark",
|
|
28
|
-
"bm-inverse": "bm-inverse",
|
|
29
|
-
"bm-action-list": "bm-action-list",
|
|
30
|
-
"bm-action-list__no-results": "bm-action-list__no-results",
|
|
31
|
-
"bm-action-list__loading": "bm-action-list__loading",
|
|
32
|
-
"bm-action-list__item": "bm-action-list__item",
|
|
33
|
-
"bm-action-list__item__supporting-text": "bm-action-list__item__supporting-text",
|
|
34
|
-
"bm-action-list__item--kind-destructive": "bm-action-list__item--kind-destructive",
|
|
35
|
-
"bm-action-list__item--disabled": "bm-action-list__item--disabled",
|
|
36
|
-
"bm-state-layer": "bm-state-layer",
|
|
37
|
-
"bm-action-list__item--active": "bm-action-list__item--active",
|
|
38
|
-
"bm-action-list__item__choice": "bm-action-list__item__choice",
|
|
39
|
-
"bm-action-list__item__switch": "bm-action-list__item__switch",
|
|
40
|
-
"bm-action-list__item__content-before": "bm-action-list__item__content-before",
|
|
41
|
-
"bm-action-list__item__content": "bm-action-list__item__content",
|
|
42
|
-
"bm-action-list__item__text": "bm-action-list__item__text",
|
|
43
|
-
"bm-action-list__item--header": "bm-action-list__item--header",
|
|
44
|
-
"bm-action-list__item__content-after": "bm-action-list__item__content-after",
|
|
45
|
-
"bm-button": "bm-button",
|
|
46
|
-
"bm-action-list__item__flyout": "bm-action-list__item__flyout",
|
|
47
|
-
"bm-action-list__group": "bm-action-list__group",
|
|
48
|
-
"bm-action-list__group__heading": "bm-action-list__group__heading",
|
|
49
|
-
"bm-action-list__group__no-results": "bm-action-list__group__no-results",
|
|
50
|
-
"bm-action-list__group__divider": "bm-action-list__group__divider",
|
|
51
|
-
"bm-action-list__item__icon-button__placeholder": "bm-action-list__item__icon-button__placeholder"
|
|
52
|
-
}, St = "singleCheckMark", Nt = "multiCheckMark", $t = "checkbox", At = "radio", Mt = "switch", Rt = [St, Nt, $t, At, Mt], R = (c) => Rt.includes(c), { baseClassNamePrefix: Lt, classModifierPrefix: f, subElementClassPrefix: s } = et("action-list__item"), L = dt({ current: null }), oi = () => kt(L), si = bt(
|
|
53
|
-
({
|
|
54
|
-
children: c,
|
|
55
|
-
supportingText: p,
|
|
56
|
-
contentAfter: k,
|
|
57
|
-
contentBefore: g,
|
|
58
|
-
onClick: r,
|
|
59
|
-
onSelectionChange: D,
|
|
60
|
-
defaultSelected: E = !1,
|
|
61
|
-
kind: P = "action",
|
|
62
|
-
indent: F,
|
|
63
|
-
disabled: m = !1,
|
|
64
|
-
className: K,
|
|
65
|
-
role: l,
|
|
66
|
-
tooltipPlacement: z,
|
|
67
|
-
hidden: j,
|
|
68
|
-
...O
|
|
69
|
-
}, T) => {
|
|
70
|
-
const { kind: t } = xt(P), { onItemClick: _, itemsFocusable: q, getItemProps: d, insideMenu: v, activeIndex: B } = yt(), { selected: b, setSelected: G } = at(
|
|
71
|
-
t,
|
|
72
|
-
E,
|
|
73
|
-
D
|
|
74
|
-
), [n, H] = ut(b);
|
|
75
|
-
ht(() => {
|
|
76
|
-
requestAnimationFrame(() => H(b));
|
|
77
|
-
}, [b]);
|
|
78
|
-
const C = R(t), J = t === "flyout", u = tt({
|
|
79
|
-
isChoiceItem: C,
|
|
80
|
-
indentProp: F
|
|
81
|
-
}), { index: x, ref: Q } = Ct({
|
|
82
|
-
label: m ? null : A(c)
|
|
83
|
-
}), y = (o) => {
|
|
84
|
-
m || (R(t) ? G(!n) : r == null || r(o), _ == null || _(x, t, o.nativeEvent));
|
|
85
|
-
}, U = (o) => {
|
|
86
|
-
(o.key === "Enter" || o.key === " ") && (o.preventDefault(), y(o));
|
|
87
|
-
}, h = ft((o) => {
|
|
88
|
-
o.preventDefault();
|
|
89
|
-
}, []), w = M(null), I = M(null), V = _t({ clippingRef: I }), W = lt(Q, T), X = pt(() => l || (v ? t === "singleCheckMark" || t === "radio" ? "menuitemradio" : t === "multiCheckMark" || t === "checkbox" || t === "switch" ? "menuitemcheckbox" : "menuitem" : "option"), [l, v, t]), S = {
|
|
90
|
-
...O,
|
|
91
|
-
onClick: y,
|
|
92
|
-
tabIndex: q ? 0 : -1
|
|
93
|
-
}, { id: Y } = wt(), N = B === x, Z = it(
|
|
94
|
-
e[Lt],
|
|
95
|
-
e[`${f}kind-${t}`],
|
|
96
|
-
m && e[`${f}disabled`],
|
|
97
|
-
N && e[`${f}active`],
|
|
98
|
-
K
|
|
99
|
-
);
|
|
100
|
-
return /* @__PURE__ */ a(L.Provider, { value: w, children: [
|
|
101
|
-
/* @__PURE__ */ i(
|
|
102
|
-
rt,
|
|
103
|
-
{
|
|
104
|
-
showDelay: 500,
|
|
105
|
-
portalled: !0,
|
|
106
|
-
text: A(c),
|
|
107
|
-
...V,
|
|
108
|
-
placement: z,
|
|
109
|
-
children: /* @__PURE__ */ a(
|
|
110
|
-
"div",
|
|
111
|
-
{
|
|
112
|
-
className: Z,
|
|
113
|
-
role: X,
|
|
114
|
-
"aria-checked": n || void 0,
|
|
115
|
-
"aria-selected": N || void 0,
|
|
116
|
-
"aria-disabled": m,
|
|
117
|
-
onKeyDown: U,
|
|
118
|
-
id: Y,
|
|
119
|
-
...(d == null ? void 0 : d(S)) ?? S,
|
|
120
|
-
ref: W,
|
|
121
|
-
hidden: j,
|
|
122
|
-
children: [
|
|
123
|
-
u && /* @__PURE__ */ i(
|
|
124
|
-
"div",
|
|
125
|
-
{
|
|
126
|
-
style: {
|
|
127
|
-
width: u === !0 ? ot : `${u}rem`
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
),
|
|
131
|
-
C && t !== "switch" && /* @__PURE__ */ a(
|
|
132
|
-
"div",
|
|
133
|
-
{
|
|
134
|
-
className: e[`${s}choice`],
|
|
135
|
-
inert: "",
|
|
136
|
-
children: [
|
|
137
|
-
(t === "singleCheckMark" || t === "multiCheckMark") && n && /* @__PURE__ */ i($, { customIconSize: st, icon: nt }),
|
|
138
|
-
t === "checkbox" && /* @__PURE__ */ i(gt, { checked: n, onChange: h }),
|
|
139
|
-
t === "radio" && /* @__PURE__ */ i(vt, { checked: n, onChange: h })
|
|
140
|
-
]
|
|
141
|
-
}
|
|
142
|
-
),
|
|
143
|
-
g && /* @__PURE__ */ i("div", { className: e[`${s}content-before`], children: g }),
|
|
144
|
-
/* @__PURE__ */ a("div", { className: e[`${s}content`], children: [
|
|
145
|
-
/* @__PURE__ */ i(
|
|
146
|
-
"div",
|
|
147
|
-
{
|
|
148
|
-
className: e[`${s}text`],
|
|
149
|
-
ref: I,
|
|
150
|
-
children: c
|
|
151
|
-
}
|
|
152
|
-
),
|
|
153
|
-
p && /* @__PURE__ */ i("div", { className: e[`${s}supporting-text`], children: p })
|
|
154
|
-
] }),
|
|
155
|
-
k && /* @__PURE__ */ i("div", { className: e[`${s}content-after`], children: k }),
|
|
156
|
-
t === "switch" && /* @__PURE__ */ i(
|
|
157
|
-
"div",
|
|
158
|
-
{
|
|
159
|
-
className: e[`${s}switch`],
|
|
160
|
-
inert: "",
|
|
161
|
-
children: /* @__PURE__ */ i(It, { checked: n, onChange: h })
|
|
162
|
-
}
|
|
163
|
-
),
|
|
164
|
-
J && /* @__PURE__ */ i(
|
|
165
|
-
$,
|
|
166
|
-
{
|
|
167
|
-
className: e[`${s}flyout`],
|
|
168
|
-
icon: ct
|
|
169
|
-
}
|
|
170
|
-
),
|
|
171
|
-
/* @__PURE__ */ i(mt, {})
|
|
172
|
-
]
|
|
173
|
-
}
|
|
174
|
-
)
|
|
175
|
-
}
|
|
176
|
-
),
|
|
177
|
-
/* @__PURE__ */ i("div", { ref: w })
|
|
178
|
-
] });
|
|
179
|
-
}
|
|
180
|
-
);
|
|
181
|
-
export {
|
|
182
|
-
si as A,
|
|
183
|
-
L as a,
|
|
184
|
-
R as i,
|
|
185
|
-
e as s,
|
|
186
|
-
oi as u
|
|
187
|
-
};
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import "../assets/Search.Results.css";
|
|
2
|
-
import { jsx as a } from "react/jsx-runtime";
|
|
3
|
-
import t from "react";
|
|
4
|
-
import { g as c } from "./classNames.DNsS4J__.js";
|
|
5
|
-
import "./constants.BBi77pmH.js";
|
|
6
|
-
import { clsx as o } from "clsx";
|
|
7
|
-
import { ActionList as i } from "../lib/ActionList/ActionList.es.js";
|
|
8
|
-
const b = {
|
|
9
|
-
"bm-light": "bm-light",
|
|
10
|
-
"bm-dark": "bm-dark",
|
|
11
|
-
"bm-inverse": "bm-inverse",
|
|
12
|
-
"bm-search": "bm-search",
|
|
13
|
-
"bm-search--disabled": "bm-search--disabled",
|
|
14
|
-
"bm-search--fluid": "bm-search--fluid",
|
|
15
|
-
"bm-search__field": "bm-search__field",
|
|
16
|
-
"bm-search__field__input": "bm-search__field__input",
|
|
17
|
-
"bm-search--error": "bm-search--error",
|
|
18
|
-
"bm-search--read-only": "bm-search--read-only",
|
|
19
|
-
"bm-search__content": "bm-search__content"
|
|
20
|
-
}, { baseClassNamePrefix: l } = c("search"), h = t.forwardRef(
|
|
21
|
-
({ children: e, ...s }, r) => {
|
|
22
|
-
const m = o(
|
|
23
|
-
b[`${l}__results__item`]
|
|
24
|
-
);
|
|
25
|
-
return /* @__PURE__ */ a(
|
|
26
|
-
i.Item,
|
|
27
|
-
{
|
|
28
|
-
ref: r,
|
|
29
|
-
className: m,
|
|
30
|
-
...s,
|
|
31
|
-
children: e
|
|
32
|
-
}
|
|
33
|
-
);
|
|
34
|
-
}
|
|
35
|
-
), _ = h;
|
|
36
|
-
_.displayName = "Search.Results.Item";
|
|
37
|
-
export {
|
|
38
|
-
_ as S,
|
|
39
|
-
h as a,
|
|
40
|
-
b as s
|
|
41
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var _=require("../assets/Search.Results.css");const i=require("react/jsx-runtime"),n=require("react"),l=require("./classNames.DAeKwerT.js");require("./constants.hwjHOsvT.js");const b=require("clsx"),o=require("../lib/ActionList/ActionList.cjs.js"),e={"bm-light":"bm-light","bm-dark":"bm-dark","bm-inverse":"bm-inverse","bm-search":"bm-search","bm-search--disabled":"bm-search--disabled","bm-search--fluid":"bm-search--fluid","bm-search__field":"bm-search__field","bm-search__field__input":"bm-search__field__input","bm-search--error":"bm-search--error","bm-search--read-only":"bm-search--read-only","bm-search__content":"bm-search__content"},{baseClassNamePrefix:h}=l.getBEMClassNames("search"),s=n.forwardRef(({children:t,...c},a)=>{const m=b.clsx(e[`${h}__results__item`]);return i.jsx(o.ActionList.Item,{ref:a,className:m,...c,children:t})}),r=s;r.displayName="Search.Results.Item";exports.SearchResultsItem=r;exports.SearchResultsItemComponent=s;exports.styles=e;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var _=require("../assets/panel.css");const e={"bm-light":"bm-light","bm-dark":"bm-dark","bm-inverse":"bm-inverse","bm-panel":"bm-panel","bm-panel--inline":"bm-panel--inline","bm-panel--overlay":"bm-panel--overlay","bm-panel--size-full":"bm-panel--size-full","bm-panel--position-bottom":"bm-panel--position-bottom","bm-panel--padding-sm":"bm-panel--padding-sm","bm-panel__header":"bm-panel__header","bm-panel__body":"bm-panel__body","bm-panel__footer":"bm-panel__footer","bm-panel--padding-md":"bm-panel--padding-md","bm-panel__header__row":"bm-panel__header__row","bm-panel__header__content-before":"bm-panel__header__content-before","bm-panel__header__content-after":"bm-panel__header__content-after","bm-panel__header__heading":"bm-panel__header__heading","bm-panel__header__description":"bm-panel__header__description","bm-panel__header__close-button":"bm-panel__header__close-button","bm-panel__footer__actions":"bm-panel__footer__actions","bm-panel__footer__actions--start":"bm-panel__footer__actions--start","bm-panel__footer__actions--end":"bm-panel__footer__actions--end","bm-panel__footer__actions--spaceBetween":"bm-panel__footer__actions--spaceBetween","bm-panel__footer__actions--stacked":"bm-panel__footer__actions--stacked"};exports.styles=e;
|