@razorpay/blade 12.18.0 → 12.19.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.
Files changed (29) hide show
  1. package/build/lib/native/components/ActionList/ActionListItem.js +4 -4
  2. package/build/lib/native/components/ActionList/ActionListItem.js.map +1 -1
  3. package/build/lib/native/components/ActionList/componentIds.js +1 -1
  4. package/build/lib/native/components/ActionList/componentIds.js.map +1 -1
  5. package/build/lib/native/components/BaseMenu/BaseMenuItem/tokens.js.map +1 -1
  6. package/build/lib/native/components/index.js +1 -1
  7. package/build/lib/web/development/components/ActionList/ActionListBox.web.js +170 -36
  8. package/build/lib/web/development/components/ActionList/ActionListBox.web.js.map +1 -1
  9. package/build/lib/web/development/components/ActionList/ActionListItem.js +48 -29
  10. package/build/lib/web/development/components/ActionList/ActionListItem.js.map +1 -1
  11. package/build/lib/web/development/components/ActionList/componentIds.js +2 -1
  12. package/build/lib/web/development/components/ActionList/componentIds.js.map +1 -1
  13. package/build/lib/web/development/components/ActionList/index.js +1 -1
  14. package/build/lib/web/development/components/BaseMenu/BaseMenuItem/tokens.js +8 -2
  15. package/build/lib/web/development/components/BaseMenu/BaseMenuItem/tokens.js.map +1 -1
  16. package/build/lib/web/development/components/index.js +1 -1
  17. package/build/lib/web/production/components/ActionList/ActionListBox.web.js +170 -36
  18. package/build/lib/web/production/components/ActionList/ActionListBox.web.js.map +1 -1
  19. package/build/lib/web/production/components/ActionList/ActionListItem.js +48 -29
  20. package/build/lib/web/production/components/ActionList/ActionListItem.js.map +1 -1
  21. package/build/lib/web/production/components/ActionList/componentIds.js +2 -1
  22. package/build/lib/web/production/components/ActionList/componentIds.js.map +1 -1
  23. package/build/lib/web/production/components/ActionList/index.js +1 -1
  24. package/build/lib/web/production/components/BaseMenu/BaseMenuItem/tokens.js +8 -2
  25. package/build/lib/web/production/components/BaseMenu/BaseMenuItem/tokens.js.map +1 -1
  26. package/build/lib/web/production/components/index.js +1 -1
  27. package/build/types/components/index.d.ts +19 -3
  28. package/build/types/components/index.native.d.ts +19 -3
  29. package/package.json +1 -1
@@ -1,5 +1,5 @@
1
- import _defineProperty from '@babel/runtime/helpers/defineProperty';
2
1
  import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProperties';
2
+ import _defineProperty from '@babel/runtime/helpers/defineProperty';
3
3
  import React__default from 'react';
4
4
  import styled from 'styled-components';
5
5
  import { componentIds } from './componentIds.js';
@@ -22,17 +22,17 @@ import '../BaseMenu/index.js';
22
22
  import '../Checkbox/index.js';
23
23
  import '../Avatar/index.js';
24
24
  import '../../utils/makeAnalyticsAttribute/index.js';
25
- import { jsxs, jsx } from 'react/jsx-runtime';
25
+ import { jsx, jsxs } from 'react/jsx-runtime';
26
26
  import { BaseBox } from '../Box/BaseBox/BaseBox.web.js';
27
27
  import { makeSize } from '../../utils/makeSize/makeSize.js';
28
- import { isReactNative } from '../../utils/platform/isReactNative.js';
29
28
  import { makeAccessible } from '../../utils/makeAccessible/makeAccessible.web.js';
29
+ import { Text } from '../Typography/Text/Text.js';
30
+ import { assignWithoutSideEffects } from '../../utils/assignWithoutSideEffects/assignWithoutSideEffects.js';
31
+ import { isReactNative } from '../../utils/platform/isReactNative.js';
30
32
  import { metaAttribute } from '../../utils/metaAttribute/metaAttribute.web.js';
31
33
  import { MetaConstants } from '../../utils/metaAttribute/metaConstants.js';
32
34
  import { makeAnalyticsAttribute } from '../../utils/makeAnalyticsAttribute/makeAnalyticsAttribute.js';
33
- import { Text } from '../Typography/Text/Text.js';
34
35
  import { Divider } from '../Divider/Divider.js';
35
- import { assignWithoutSideEffects } from '../../utils/assignWithoutSideEffects/assignWithoutSideEffects.js';
36
36
  import { useBaseMenuItem } from '../BaseMenu/BaseMenuContext.js';
37
37
  import { Box } from '../Box/Box.js';
38
38
  import { Avatar } from '../Avatar/Avatar.web.js';
@@ -54,13 +54,32 @@ var StyledActionListSectionTitle = /*#__PURE__*/styled(BaseBox).withConfig({
54
54
  padding: makeSize(props.theme.spacing[3])
55
55
  };
56
56
  });
57
- var _ActionListSection = function _ActionListSection(_ref) {
57
+ var _ActionListSectionTitle = function _ActionListSectionTitle(_ref) {
58
58
  var title = _ref.title,
59
- children = _ref.children,
60
- testID = _ref.testID,
61
- _hideDivider = _ref._hideDivider,
62
- _sectionChildValues = _ref._sectionChildValues,
63
- rest = _objectWithoutProperties(_ref, _excluded);
59
+ _ref$isInsideVirtuali = _ref.isInsideVirtualizedList,
60
+ isInsideVirtualizedList = _ref$isInsideVirtuali === void 0 ? false : _ref$isInsideVirtuali;
61
+ return /*#__PURE__*/jsx(StyledActionListSectionTitle, _objectSpread(_objectSpread({}, makeAccessible({
62
+ hidden: !isInsideVirtualizedList,
63
+ role: isInsideVirtualizedList ? 'heading' : undefined
64
+ })), {}, {
65
+ children: /*#__PURE__*/jsx(Text, {
66
+ color: "surface.text.gray.muted",
67
+ size: "small",
68
+ weight: "semibold",
69
+ children: title
70
+ })
71
+ }));
72
+ };
73
+ var ActionListSectionTitle = /*#__PURE__*/assignWithoutSideEffects(_ActionListSectionTitle, {
74
+ componentId: componentIds.ActionListSectionTitle
75
+ });
76
+ var _ActionListSection = function _ActionListSection(_ref2) {
77
+ var title = _ref2.title,
78
+ children = _ref2.children,
79
+ testID = _ref2.testID,
80
+ _hideDivider = _ref2._hideDivider,
81
+ _sectionChildValues = _ref2._sectionChildValues,
82
+ rest = _objectWithoutProperties(_ref2, _excluded);
64
83
  var _useDropdown = useDropdown(),
65
84
  hasAutoCompleteInBottomSheetHeader = _useDropdown.hasAutoCompleteInBottomSheetHeader,
66
85
  dropdownTriggerer = _useDropdown.dropdownTriggerer,
@@ -84,16 +103,9 @@ var _ActionListSection = function _ActionListSection(_ref) {
84
103
  name: MetaConstants.ActionListSection,
85
104
  testID: testID
86
105
  })), makeAnalyticsAttribute(rest)), {}, {
87
- children: [isSectionVisible ? /*#__PURE__*/jsx(StyledActionListSectionTitle, _objectSpread(_objectSpread({}, makeAccessible({
88
- hidden: true
89
- })), {}, {
90
- children: /*#__PURE__*/jsx(Text, {
91
- color: "surface.text.gray.muted",
92
- size: "small",
93
- weight: "semibold",
94
- children: title
95
- })
96
- })) : null, /*#__PURE__*/jsx(BaseBox, _objectSpread(_objectSpread({}, makeAccessible({
106
+ children: [isSectionVisible ? /*#__PURE__*/jsx(ActionListSectionTitle, {
107
+ title: title
108
+ }) : null, /*#__PURE__*/jsx(BaseBox, _objectSpread(_objectSpread({}, makeAccessible({
97
109
  // On web, we just wrap it in another listbox to announce item count properly for particular group.
98
110
  // On React Native, we ignore it since `menu` + `group` role will take care of accessibility
99
111
  role: isReactNative() ? undefined : 'listbox'
@@ -105,11 +117,11 @@ var _ActionListSection = function _ActionListSection(_ref) {
105
117
  }) : null]
106
118
  }));
107
119
  };
108
- var ActionListSection = /*#__PURE__*/assignWithoutSideEffects(_ActionListSection, {
120
+ var ActionListSection = /*#__PURE__*/assignWithoutSideEffects( /*#__PURE__*/React__default.memo(_ActionListSection), {
109
121
  componentId: componentIds.ActionListSection
110
122
  });
111
- var _ActionListItemIcon = function _ActionListItemIcon(_ref2) {
112
- var icon = _ref2.icon;
123
+ var _ActionListItemIcon = function _ActionListItemIcon(_ref3) {
124
+ var icon = _ref3.icon;
113
125
  var Icon = icon;
114
126
  var _useBaseMenuItem = useBaseMenuItem(),
115
127
  color = _useBaseMenuItem.color,
@@ -123,8 +135,8 @@ var _ActionListItemIcon = function _ActionListItemIcon(_ref2) {
123
135
  var ActionListItemIcon = /*#__PURE__*/assignWithoutSideEffects(_ActionListItemIcon, {
124
136
  componentId: componentIds.ActionListItemIcon
125
137
  });
126
- var _ActionListItemBadgeGroup = function _ActionListItemBadgeGroup(_ref3) {
127
- var children = _ref3.children;
138
+ var _ActionListItemBadgeGroup = function _ActionListItemBadgeGroup(_ref4) {
139
+ var children = _ref4.children;
128
140
  return /*#__PURE__*/jsx(Box, {
129
141
  display: "flex",
130
142
  alignItems: "center",
@@ -152,8 +164,8 @@ var _ActionListItemBadge = function _ActionListItemBadge(props) {
152
164
  var ActionListItemBadge = /*#__PURE__*/assignWithoutSideEffects(_ActionListItemBadge, {
153
165
  componentId: componentIds.ActionListItemBadge
154
166
  });
155
- var _ActionListItemText = function _ActionListItemText(_ref4) {
156
- var children = _ref4.children;
167
+ var _ActionListItemText = function _ActionListItemText(_ref5) {
168
+ var children = _ref5.children;
157
169
  var _useBaseMenuItem2 = useBaseMenuItem(),
158
170
  isDisabled = _useBaseMenuItem2.isDisabled;
159
171
  return /*#__PURE__*/jsx(Text, {
@@ -210,6 +222,13 @@ var _ActionListItem = function _ActionListItem(props) {
210
222
  isKeydownPressed = _useDropdown2.isKeydownPressed,
211
223
  filteredValues = _useDropdown2.filteredValues,
212
224
  hasAutoCompleteInBottomSheetHeader = _useDropdown2.hasAutoCompleteInBottomSheetHeader;
225
+ React__default.useEffect(function () {
226
+ if (activeIndex === props._index && props._virtualizedIndex !== undefined) {
227
+ var _props$_onVirtualized;
228
+ (_props$_onVirtualized = props._onVirtualizedFocus) === null || _props$_onVirtualized === void 0 ? void 0 : _props$_onVirtualized.call(props, props._virtualizedIndex);
229
+ }
230
+ // eslint-disable-next-line react-hooks/exhaustive-deps
231
+ }, [activeIndex]);
213
232
  var hasAutoComplete = hasAutoCompleteInBottomSheetHeader || dropdownTriggerer === dropdownComponentIds.triggers.AutoComplete;
214
233
  var renderOnWebAs = props.href ? 'a' : 'button';
215
234
 
@@ -310,5 +329,5 @@ var ActionListItem = /*#__PURE__*/assignWithoutSideEffects( /*#__PURE__*/React__
310
329
  displayName: componentIds.ActionListItem
311
330
  });
312
331
 
313
- export { ActionListItem, ActionListItemAvatar, ActionListItemBadge, ActionListItemBadgeGroup, ActionListItemIcon, ActionListItemText, ActionListSection };
332
+ export { ActionListItem, ActionListItemAvatar, ActionListItemBadge, ActionListItemBadgeGroup, ActionListItemIcon, ActionListItemText, ActionListSection, ActionListSectionTitle };
314
333
  //# sourceMappingURL=ActionListItem.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ActionListItem.js","sources":["../../../../../../src/components/ActionList/ActionListItem.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/ban-ts-comment */\nimport React from 'react';\nimport styled from 'styled-components';\nimport type { TouchableOpacity } from 'react-native';\nimport { componentIds } from './componentIds';\nimport { validateActionListItemProps, getNormalTextColor } from './actionListUtils';\nimport { getActionListItemRole, getActionListSectionRole } from './getA11yRoles';\nimport { Divider } from '~components/Divider';\nimport BaseBox from '~components/Box/BaseBox';\nimport type { IconComponent } from '~components/Icons';\nimport { useDropdown } from '~components/Dropdown/useDropdown';\nimport type { FeedbackColors } from '~tokens/theme/theme';\nimport { Text } from '~components/Typography';\nimport type { Platform } from '~utils';\nimport { castWebType, isReactNative } from '~utils';\nimport { metaAttribute, MetaConstants } from '~utils/metaAttribute';\nimport type { DataAnalyticsAttribute, StringChildrenType, TestID } from '~utils/types';\nimport { assignWithoutSideEffects } from '~utils/assignWithoutSideEffects';\nimport { makeSize } from '~utils/makeSize';\nimport { makeAccessible } from '~utils/makeAccessible';\nimport { throwBladeError } from '~utils/logger';\nimport type { BadgeProps } from '~components/Badge';\nimport { Badge } from '~components/Badge';\nimport { Box } from '~components/Box';\nimport { dropdownComponentIds } from '~components/Dropdown/dropdownComponentIds';\nimport { BaseMenuItem, useBaseMenuItem } from '~components/BaseMenu';\nimport { Checkbox } from '~components/Checkbox';\nimport type { AvatarProps } from '~components/Avatar/types';\nimport { Avatar } from '~components/Avatar';\nimport { makeAnalyticsAttribute } from '~utils/makeAnalyticsAttribute';\n\ntype ActionListItemProps = {\n title: string;\n description?: string;\n onClick?: (clickProps: {\n name: string;\n value?: boolean;\n event: Platform.Select<{\n web: React.MouseEvent;\n native: React.TouchEvent<TouchableOpacity>;\n }>;\n }) => void;\n /**\n * value that you get from `onChange` event on SelectInput or in form submissions.\n */\n value: string;\n /**\n * Link to open when item is clicked.\n */\n href?: string;\n /**\n * HTML target of the link\n */\n target?: string;\n /**\n * Item that goes on left-side of item.\n *\n * Valid elements - `<ActionListItemIcon />`, `<ActionListItemAsset />`\n *\n * Will be overriden in multiselect\n */\n leading?: React.ReactNode;\n /**\n * Item that goes on right-side of item.\n *\n * Valid elements - `<ActionListItemText />`, `<ActionListItemIcon />`\n */\n trailing?: React.ReactNode;\n /**\n * Item that goes immediately next to the title.\n *\n * Valid elements - `<ActionListItemBadge />`, `<ActionListItemBadgeGroup />`\n *\n */\n titleSuffix?: React.ReactElement;\n isDisabled?: boolean;\n intent?: Extract<FeedbackColors, 'negative'>;\n /**\n * Can be used in combination of `onClick` to highlight item as selected in Button Triggers.\n *\n * When trigger is SelectInput, Use `value` prop on SelectInput instead to make dropdown controlled.\n */\n isSelected?: boolean;\n /**\n * Internally passed from ActionList. No need to pass it explicitly\n *\n * @private\n */\n _index?: number;\n} & TestID &\n DataAnalyticsAttribute;\n\nconst StyledActionListSectionTitle = styled(BaseBox)((props) => ({\n // @TODO: replace this styled-component with new layout box when we have padding shorthand\n padding: makeSize(props.theme.spacing[3]),\n}));\n\ntype ActionListSectionProps = {\n title: string;\n children: React.ReactNode[] | React.ReactNode;\n /**\n * Internally used to hide the divider on final item in React Native.\n *\n * Should not be used by consumers (also won't work on web)\n *\n * @private\n */\n _hideDivider?: boolean;\n /**\n * Internally used to hide / show section in AutoComplete\n *\n * @private\n */\n _sectionChildValues?: string[];\n} & TestID &\n DataAnalyticsAttribute;\nconst _ActionListSection = ({\n title,\n children,\n testID,\n _hideDivider,\n _sectionChildValues,\n ...rest\n}: ActionListSectionProps): React.ReactElement => {\n const { hasAutoCompleteInBottomSheetHeader, dropdownTriggerer, filteredValues } = useDropdown();\n const hasAutoComplete =\n hasAutoCompleteInBottomSheetHeader ||\n dropdownTriggerer === dropdownComponentIds.triggers.AutoComplete;\n\n const isSectionVisible = React.useMemo(() => {\n if (hasAutoComplete) {\n const visibleActionListItemInSection = _sectionChildValues?.find((actionItemValue) =>\n filteredValues.includes(actionItemValue),\n );\n\n return Boolean(visibleActionListItemInSection);\n }\n\n return true;\n }, [_sectionChildValues, hasAutoComplete, filteredValues]);\n\n const showDividerInRN = !(_hideDivider && isReactNative());\n const showDividerInAutoComplete = hasAutoComplete\n ? isSectionVisible && filteredValues.length > 1\n : true;\n\n return (\n <BaseBox\n {...makeAccessible({\n role: getActionListSectionRole(),\n label: title,\n })}\n {...metaAttribute({ name: MetaConstants.ActionListSection, testID })}\n {...makeAnalyticsAttribute(rest as Record<string, unknown>)}\n >\n {/* We're announcing title as group label so we can hide this */}\n {isSectionVisible ? (\n <StyledActionListSectionTitle {...makeAccessible({ hidden: true })}>\n <Text color=\"surface.text.gray.muted\" size=\"small\" weight=\"semibold\">\n {title}\n </Text>\n </StyledActionListSectionTitle>\n ) : null}\n <BaseBox\n {...makeAccessible({\n // On web, we just wrap it in another listbox to announce item count properly for particular group.\n // On React Native, we ignore it since `menu` + `group` role will take care of accessibility\n role: isReactNative() ? undefined : 'listbox',\n })}\n >\n {children}\n </BaseBox>\n {showDividerInAutoComplete && showDividerInRN ? (\n <Divider marginX=\"spacing.3\" marginY=\"spacing.1\" />\n ) : null}\n </BaseBox>\n );\n};\n\nconst ActionListSection = assignWithoutSideEffects(_ActionListSection, {\n componentId: componentIds.ActionListSection,\n});\n\nconst _ActionListItemIcon = ({ icon }: { icon: IconComponent }): React.ReactElement => {\n const Icon = icon;\n const { color, isDisabled } = useBaseMenuItem();\n const iconState = isDisabled ? 'disabled' : 'muted';\n return (\n <Icon\n color={\n color === 'negative'\n ? 'feedback.icon.negative.intense'\n : `interactive.icon.gray.${iconState}`\n }\n size=\"medium\"\n />\n );\n};\n\nconst ActionListItemIcon = assignWithoutSideEffects(_ActionListItemIcon, {\n componentId: componentIds.ActionListItemIcon,\n});\n\nconst _ActionListItemBadgeGroup = ({\n children,\n}: {\n children: React.ReactElement[] | React.ReactElement;\n}): React.ReactElement => {\n return (\n <Box display=\"flex\" alignItems=\"center\" flexDirection=\"row\">\n {children}\n </Box>\n );\n};\n\nconst ActionListItemBadgeGroup = assignWithoutSideEffects(_ActionListItemBadgeGroup, {\n componentId: componentIds.ActionListItemBadgeGroup,\n});\n\nconst _ActionListItemAvatar = (avatarProps: Omit<AvatarProps, 'size' | ''>): React.ReactElement => {\n return <Avatar size=\"xsmall\" {...avatarProps} />;\n};\n\nconst ActionListItemAvatar = assignWithoutSideEffects(_ActionListItemAvatar, {\n componentId: componentIds.ActionListItemAvatar,\n});\n\nconst _ActionListItemBadge = (props: BadgeProps): React.ReactElement => {\n return <Badge size=\"medium\" marginLeft=\"spacing.3\" {...props} />;\n};\n\nconst ActionListItemBadge = assignWithoutSideEffects(_ActionListItemBadge, {\n componentId: componentIds.ActionListItemBadge,\n});\n\nconst _ActionListItemText = ({\n children,\n}: {\n children: StringChildrenType;\n}): React.ReactElement => {\n const { isDisabled } = useBaseMenuItem();\n\n return (\n <Text variant=\"caption\" color={getNormalTextColor(isDisabled, { isMuted: true })}>\n {children}\n </Text>\n );\n};\n\nconst ActionListItemText = assignWithoutSideEffects(_ActionListItemText, {\n componentId: componentIds.ActionListItemText,\n});\n\ntype ClickHandlerType = (e: React.MouseEvent<HTMLButtonElement>) => void;\n\nconst makeActionListItemClickable = (\n clickHandler: ClickHandlerType,\n): { onPress?: (e: React.TouchEvent<TouchableOpacity>) => void; onClick?: ClickHandlerType } => {\n if (isReactNative()) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment, @typescript-eslint/prefer-ts-expect-error\n // @ts-ignore: ignoring ReactNative press type for the peace of mind\n return { onPress: clickHandler };\n }\n\n return {\n onClick: clickHandler,\n };\n};\n\n/**\n * ### ActionListItem\n *\n * Creates option inside `ActionList`.\n *\n * #### Usage\n *\n * ```jsx\n * <ActionList>\n * <ActionListItem\n * title=\"Home\"\n * value=\"home\"\n * leading={<ActionListItemIcon icon={HomeIcon} />}\n * trailing={<ActionListItemText>⌘ + S</ActionListItemText>}\n * />\n * </ActionList>\n * ```\n */\nconst _ActionListItem = (props: ActionListItemProps): React.ReactElement => {\n const {\n activeIndex,\n dropdownBaseId,\n onOptionClick,\n selectedIndices,\n setShouldIgnoreBlurAnimation,\n selectionType,\n dropdownTriggerer,\n isKeydownPressed,\n filteredValues,\n hasAutoCompleteInBottomSheetHeader,\n } = useDropdown();\n\n const hasAutoComplete =\n hasAutoCompleteInBottomSheetHeader ||\n dropdownTriggerer === dropdownComponentIds.triggers.AutoComplete;\n\n const renderOnWebAs = props.href ? 'a' : 'button';\n\n /**\n * In SelectInput, returns the isSelected according to selected indexes in the state\n *\n * In Other Triggers (Menu Usecase), returns `props.isSelected` since passing the\n * isSelected prop explicitly is the only way to select item in menu\n */\n const getIsSelected = (): boolean | undefined => {\n if (dropdownTriggerer === dropdownComponentIds.triggers.SelectInput || hasAutoComplete) {\n if (typeof props._index === 'number') {\n return selectedIndices.includes(props._index);\n }\n\n return undefined;\n }\n\n return props.isSelected;\n };\n\n const isSelected = getIsSelected();\n\n React.useEffect(() => {\n validateActionListItemProps({\n leading: props.leading,\n trailing: props.trailing,\n titleSuffix: props.titleSuffix,\n });\n }, [props.leading, props.trailing, props.titleSuffix]);\n\n React.useEffect(() => {\n if (__DEV__) {\n if (\n dropdownTriggerer === dropdownComponentIds.triggers.SelectInput &&\n props.intent === 'negative'\n ) {\n throwBladeError({\n message:\n 'negative intent ActionListItem cannot be used inside Dropdown with SelectInput trigger',\n moduleName: 'ActionListItem',\n });\n }\n }\n }, [props.intent, dropdownTriggerer]);\n\n const isVisible = hasAutoComplete && filteredValues ? filteredValues.includes(props.value) : true;\n\n return (\n <BaseMenuItem\n isVisible={isVisible}\n as={!isReactNative() ? renderOnWebAs : undefined}\n id={`${dropdownBaseId}-${props._index}`}\n tabIndex={-1}\n title={props.title}\n description={props.description}\n leading={\n selectionType === 'multiple' ? (\n <BaseBox\n pointerEvents=\"none\"\n // Adding aria-hidden because the listbox item in multiselect in itself explains the behaviour so announcing checkbox is unneccesary and just a nice UI tweak for us\n {...makeAccessible({\n hidden: true,\n })}\n >\n <Checkbox isChecked={isSelected} tabIndex={-1} isDisabled={props.isDisabled}>\n {/* \n Checkbox requires children. Didn't want to make it optional because its helpful for consumers\n But for this case in particular, we just want to use Text separately so that we can control spacing and color and keep it consistent with non-multiselect dropdowns\n */}\n {null}\n </Checkbox>\n </BaseBox>\n ) : (\n props.leading\n )\n }\n trailing={props.trailing}\n titleSuffix={props.titleSuffix}\n href={props.href}\n target={props.target}\n className={activeIndex === props._index ? 'active-focus' : ''}\n isSelected={isSelected}\n isDisabled={props.isDisabled}\n role={getActionListItemRole(dropdownTriggerer, props.href)}\n {...makeActionListItemClickable((e: React.MouseEvent<HTMLButtonElement>): void => {\n if (typeof props._index === 'number') {\n onOptionClick(e, props._index);\n props.onClick?.({ name: props.value, value: isSelected, event: castWebType(e) });\n }\n })}\n {...makeAnalyticsAttribute({ ...props })}\n {...metaAttribute({ name: MetaConstants.ActionListItem, testID: props.testID })}\n onMouseDown={() => {\n // We want to keep focus on Dropdown's trigger while option is being clicked\n // So We set this flag that ignores the blur animation to avoid the flicker between focus out + focus in\n setShouldIgnoreBlurAnimation(true);\n }}\n onMouseUp={() => {\n // (Contd from above comment...) We set this flag back to false since blur of SelectInput is done calling by this time\n setShouldIgnoreBlurAnimation(false);\n }}\n data-value={props.value}\n data-index={props._index}\n selectionType={selectionType}\n color={props.intent}\n isKeydownPressed={isKeydownPressed}\n />\n );\n};\n\nconst ActionListItem = assignWithoutSideEffects(React.memo(_ActionListItem), {\n componentId: componentIds.ActionListItem,\n displayName: componentIds.ActionListItem,\n});\n\nexport type { ActionListItemProps, ActionListSectionProps };\nexport {\n ActionListItem,\n ActionListItemIcon,\n ActionListItemText,\n ActionListItemAvatar,\n ActionListItemBadge,\n ActionListItemBadgeGroup,\n ActionListSection,\n};\n"],"names":["StyledActionListSectionTitle","styled","BaseBox","withConfig","displayName","componentId","props","padding","makeSize","theme","spacing","_ActionListSection","_ref","title","children","testID","_hideDivider","_sectionChildValues","rest","_objectWithoutProperties","_excluded","_useDropdown","useDropdown","hasAutoCompleteInBottomSheetHeader","dropdownTriggerer","filteredValues","hasAutoComplete","dropdownComponentIds","triggers","AutoComplete","isSectionVisible","React","useMemo","visibleActionListItemInSection","find","actionItemValue","includes","Boolean","showDividerInRN","isReactNative","showDividerInAutoComplete","length","_jsxs","_objectSpread","makeAccessible","role","getActionListSectionRole","label","metaAttribute","name","MetaConstants","ActionListSection","makeAnalyticsAttribute","_jsx","hidden","Text","color","size","weight","undefined","Divider","marginX","marginY","assignWithoutSideEffects","componentIds","_ActionListItemIcon","_ref2","icon","Icon","_useBaseMenuItem","useBaseMenuItem","isDisabled","iconState","concat","ActionListItemIcon","_ActionListItemBadgeGroup","_ref3","Box","display","alignItems","flexDirection","ActionListItemBadgeGroup","_ActionListItemAvatar","avatarProps","Avatar","ActionListItemAvatar","_ActionListItemBadge","Badge","marginLeft","ActionListItemBadge","_ActionListItemText","_ref4","_useBaseMenuItem2","variant","getNormalTextColor","isMuted","ActionListItemText","makeActionListItemClickable","clickHandler","onPress","onClick","_ActionListItem","_useDropdown2","activeIndex","dropdownBaseId","onOptionClick","selectedIndices","setShouldIgnoreBlurAnimation","selectionType","isKeydownPressed","renderOnWebAs","href","getIsSelected","SelectInput","_index","isSelected","useEffect","validateActionListItemProps","leading","trailing","titleSuffix","intent","throwBladeError","message","moduleName","isVisible","value","BaseMenuItem","as","id","tabIndex","description","pointerEvents","Checkbox","isChecked","target","className","getActionListItemRole","e","_props$onClick","call","event","castWebType","ActionListItem","onMouseDown","onMouseUp","memo"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA4FA,IAAMA,4BAA4B,gBAAGC,MAAM,CAACC,OAAO,CAAC,CAAAC,UAAA,CAAA;EAAAC,WAAA,EAAA,8CAAA;EAAAC,WAAA,EAAA,UAAA;AAAA,CAAA,CAAA,CAAC,UAACC,KAAK,EAAA;EAAA,OAAM;AAC/D;IACAC,OAAO,EAAEC,QAAQ,CAACF,KAAK,CAACG,KAAK,CAACC,OAAO,CAAC,CAAC,CAAC,CAAA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WAAAA,GAAM;AACjB;AACA;MACArC,4BAA4B,CAAC,IAAI,CAAC,CAAA;KAClC;IACFsC,SAAS,EAAE,SAAAA,SAAAA,GAAM;AACf;MACAtC,4BAA4B,CAAC,KAAK,CAAC,CAAA;KACnC;IACF,YAAYrG,EAAAA,KAAK,CAACwH,KAAM;IACxB,YAAYxH,EAAAA,KAAK,CAAC4G,MAAO;AACzBN,IAAAA,aAAa,EAAEA,aAAc;IAC7BpD,KAAK,EAAElD,KAAK,CAACmH,MAAO;AACpBZ,IAAAA,gBAAgB,EAAEA,gBAAAA;AAAiB,GAAA,CACpC,CAAC,CAAA;AAEN,CAAC,CAAA;AAEKkC,IAAAA,cAAc,gBAAGhF,wBAAwB,eAAChC,cAAK,CAACmH,IAAI,CAAC7C,eAAe,CAAC,EAAE;EAC3EhG,WAAW,EAAE2D,YAAY,CAAC+E,cAAc;EACxC3I,WAAW,EAAE4D,YAAY,CAAC+E,cAAAA;AAC5B,CAAC;;;;"}
1
+ {"version":3,"file":"ActionListItem.js","sources":["../../../../../../src/components/ActionList/ActionListItem.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/ban-ts-comment */\nimport React from 'react';\nimport styled from 'styled-components';\nimport type { TouchableOpacity } from 'react-native';\nimport { componentIds } from './componentIds';\nimport { validateActionListItemProps, getNormalTextColor } from './actionListUtils';\nimport { getActionListItemRole, getActionListSectionRole } from './getA11yRoles';\nimport { Divider } from '~components/Divider';\nimport BaseBox from '~components/Box/BaseBox';\nimport type { IconComponent } from '~components/Icons';\nimport { useDropdown } from '~components/Dropdown/useDropdown';\nimport type { FeedbackColors } from '~tokens/theme/theme';\nimport { Text } from '~components/Typography';\nimport type { Platform } from '~utils';\nimport { castWebType, isReactNative } from '~utils';\nimport { metaAttribute, MetaConstants } from '~utils/metaAttribute';\nimport type { DataAnalyticsAttribute, StringChildrenType, TestID } from '~utils/types';\nimport { assignWithoutSideEffects } from '~utils/assignWithoutSideEffects';\nimport { makeSize } from '~utils/makeSize';\nimport { makeAccessible } from '~utils/makeAccessible';\nimport { throwBladeError } from '~utils/logger';\nimport type { BadgeProps } from '~components/Badge';\nimport { Badge } from '~components/Badge';\nimport { Box } from '~components/Box';\nimport { dropdownComponentIds } from '~components/Dropdown/dropdownComponentIds';\nimport { BaseMenuItem, useBaseMenuItem } from '~components/BaseMenu';\nimport { Checkbox } from '~components/Checkbox';\nimport type { AvatarProps } from '~components/Avatar/types';\nimport { Avatar } from '~components/Avatar';\nimport { makeAnalyticsAttribute } from '~utils/makeAnalyticsAttribute';\n\ntype ActionListItemProps = {\n title: string;\n description?: string;\n onClick?: (clickProps: {\n name: string;\n value?: boolean;\n event: Platform.Select<{\n web: React.MouseEvent;\n native: React.TouchEvent<TouchableOpacity>;\n }>;\n }) => void;\n /**\n * value that you get from `onChange` event on SelectInput or in form submissions.\n */\n value: string;\n /**\n * Link to open when item is clicked.\n */\n href?: string;\n /**\n * HTML target of the link\n */\n target?: string;\n /**\n * Item that goes on left-side of item.\n *\n * Valid elements - `<ActionListItemIcon />`, `<ActionListItemAsset />`\n *\n * Will be overriden in multiselect\n */\n leading?: React.ReactNode;\n /**\n * Item that goes on right-side of item.\n *\n * Valid elements - `<ActionListItemText />`, `<ActionListItemIcon />`\n */\n trailing?: React.ReactNode;\n /**\n * Item that goes immediately next to the title.\n *\n * Valid elements - `<ActionListItemBadge />`, `<ActionListItemBadgeGroup />`\n *\n */\n titleSuffix?: React.ReactElement;\n isDisabled?: boolean;\n intent?: Extract<FeedbackColors, 'negative'>;\n /**\n * Can be used in combination of `onClick` to highlight item as selected in Button Triggers.\n *\n * When trigger is SelectInput, Use `value` prop on SelectInput instead to make dropdown controlled.\n */\n isSelected?: boolean;\n /**\n * Internally passed from ActionList. No need to pass it explicitly\n *\n * @private\n */\n _index?: number;\n /**\n * Internally used to pass index for virtualized lists\n *\n * @private\n */\n _virtualizedIndex?: number;\n /**\n * Internally used to focus on virtualized list\n *\n * @private\n */\n _onVirtualizedFocus?: (_virtuazedIndex: number) => void;\n} & TestID &\n DataAnalyticsAttribute;\n\nconst StyledActionListSectionTitle = styled(BaseBox)((props) => ({\n // @TODO: replace this styled-component with new layout box when we have padding shorthand\n padding: makeSize(props.theme.spacing[3]),\n}));\n\ntype ActionListSectionProps = {\n title: string;\n children: React.ReactNode[] | React.ReactNode;\n /**\n * Internally used to hide the divider on final item in React Native\n *\n * Should not be used by consumers (also won't work on web)\n *\n * @private\n */\n _hideDivider?: boolean;\n /**\n * Internally used to hide / show section in AutoComplete\n *\n * @private\n */\n _sectionChildValues?: string[];\n} & TestID &\n DataAnalyticsAttribute;\n\nconst _ActionListSectionTitle = ({\n title,\n isInsideVirtualizedList = false,\n}: {\n title: string;\n isInsideVirtualizedList?: boolean;\n}): React.ReactElement => {\n return (\n <StyledActionListSectionTitle\n {...makeAccessible({\n hidden: !isInsideVirtualizedList,\n role: isInsideVirtualizedList ? 'heading' : undefined,\n })}\n >\n <Text color=\"surface.text.gray.muted\" size=\"small\" weight=\"semibold\">\n {title}\n </Text>\n </StyledActionListSectionTitle>\n );\n};\n\nconst ActionListSectionTitle = assignWithoutSideEffects(_ActionListSectionTitle, {\n componentId: componentIds.ActionListSectionTitle,\n});\nconst _ActionListSection = ({\n title,\n children,\n testID,\n _hideDivider,\n _sectionChildValues,\n ...rest\n}: ActionListSectionProps): React.ReactElement => {\n const { hasAutoCompleteInBottomSheetHeader, dropdownTriggerer, filteredValues } = useDropdown();\n const hasAutoComplete =\n hasAutoCompleteInBottomSheetHeader ||\n dropdownTriggerer === dropdownComponentIds.triggers.AutoComplete;\n\n const isSectionVisible = React.useMemo(() => {\n if (hasAutoComplete) {\n const visibleActionListItemInSection = _sectionChildValues?.find((actionItemValue) =>\n filteredValues.includes(actionItemValue),\n );\n\n return Boolean(visibleActionListItemInSection);\n }\n\n return true;\n }, [_sectionChildValues, hasAutoComplete, filteredValues]);\n\n const showDividerInRN = !(_hideDivider && isReactNative());\n const showDividerInAutoComplete = hasAutoComplete\n ? isSectionVisible && filteredValues.length > 1\n : true;\n\n return (\n <BaseBox\n {...makeAccessible({\n role: getActionListSectionRole(),\n label: title,\n })}\n {...metaAttribute({ name: MetaConstants.ActionListSection, testID })}\n {...makeAnalyticsAttribute(rest as Record<string, unknown>)}\n >\n {/* We're announcing title as group label so we can hide this */}\n {isSectionVisible ? <ActionListSectionTitle title={title} /> : null}\n\n <BaseBox\n {...makeAccessible({\n // On web, we just wrap it in another listbox to announce item count properly for particular group.\n // On React Native, we ignore it since `menu` + `group` role will take care of accessibility\n role: isReactNative() ? undefined : 'listbox',\n })}\n >\n {children}\n </BaseBox>\n {showDividerInAutoComplete && showDividerInRN ? (\n <Divider marginX=\"spacing.3\" marginY=\"spacing.1\" />\n ) : null}\n </BaseBox>\n );\n};\n\nconst ActionListSection = assignWithoutSideEffects(React.memo(_ActionListSection), {\n componentId: componentIds.ActionListSection,\n});\n\nconst _ActionListItemIcon = ({ icon }: { icon: IconComponent }): React.ReactElement => {\n const Icon = icon;\n const { color, isDisabled } = useBaseMenuItem();\n const iconState = isDisabled ? 'disabled' : 'muted';\n return (\n <Icon\n color={\n color === 'negative'\n ? 'feedback.icon.negative.intense'\n : `interactive.icon.gray.${iconState}`\n }\n size=\"medium\"\n />\n );\n};\n\nconst ActionListItemIcon = assignWithoutSideEffects(_ActionListItemIcon, {\n componentId: componentIds.ActionListItemIcon,\n});\n\nconst _ActionListItemBadgeGroup = ({\n children,\n}: {\n children: React.ReactElement[] | React.ReactElement;\n}): React.ReactElement => {\n return (\n <Box display=\"flex\" alignItems=\"center\" flexDirection=\"row\">\n {children}\n </Box>\n );\n};\n\nconst ActionListItemBadgeGroup = assignWithoutSideEffects(_ActionListItemBadgeGroup, {\n componentId: componentIds.ActionListItemBadgeGroup,\n});\n\nconst _ActionListItemAvatar = (avatarProps: Omit<AvatarProps, 'size' | ''>): React.ReactElement => {\n return <Avatar size=\"xsmall\" {...avatarProps} />;\n};\n\nconst ActionListItemAvatar = assignWithoutSideEffects(_ActionListItemAvatar, {\n componentId: componentIds.ActionListItemAvatar,\n});\n\nconst _ActionListItemBadge = (props: BadgeProps): React.ReactElement => {\n return <Badge size=\"medium\" marginLeft=\"spacing.3\" {...props} />;\n};\n\nconst ActionListItemBadge = assignWithoutSideEffects(_ActionListItemBadge, {\n componentId: componentIds.ActionListItemBadge,\n});\n\nconst _ActionListItemText = ({\n children,\n}: {\n children: StringChildrenType;\n}): React.ReactElement => {\n const { isDisabled } = useBaseMenuItem();\n\n return (\n <Text variant=\"caption\" color={getNormalTextColor(isDisabled, { isMuted: true })}>\n {children}\n </Text>\n );\n};\n\nconst ActionListItemText = assignWithoutSideEffects(_ActionListItemText, {\n componentId: componentIds.ActionListItemText,\n});\n\ntype ClickHandlerType = (e: React.MouseEvent<HTMLButtonElement>) => void;\n\nconst makeActionListItemClickable = (\n clickHandler: ClickHandlerType,\n): { onPress?: (e: React.TouchEvent<TouchableOpacity>) => void; onClick?: ClickHandlerType } => {\n if (isReactNative()) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment, @typescript-eslint/prefer-ts-expect-error\n // @ts-ignore: ignoring ReactNative press type for the peace of mind\n return { onPress: clickHandler };\n }\n\n return {\n onClick: clickHandler,\n };\n};\n\n/**\n * ### ActionListItem\n *\n * Creates option inside `ActionList`.\n *\n * #### Usage\n *\n * ```jsx\n * <ActionList>\n * <ActionListItem\n * title=\"Home\"\n * value=\"home\"\n * leading={<ActionListItemIcon icon={HomeIcon} />}\n * trailing={<ActionListItemText>⌘ + S</ActionListItemText>}\n * />\n * </ActionList>\n * ```\n */\nconst _ActionListItem = (props: ActionListItemProps): React.ReactElement => {\n const {\n activeIndex,\n dropdownBaseId,\n onOptionClick,\n selectedIndices,\n setShouldIgnoreBlurAnimation,\n selectionType,\n dropdownTriggerer,\n isKeydownPressed,\n filteredValues,\n hasAutoCompleteInBottomSheetHeader,\n } = useDropdown();\n\n React.useEffect(() => {\n if (activeIndex === props._index && props._virtualizedIndex !== undefined) {\n props._onVirtualizedFocus?.(props._virtualizedIndex as number);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [activeIndex]);\n\n const hasAutoComplete =\n hasAutoCompleteInBottomSheetHeader ||\n dropdownTriggerer === dropdownComponentIds.triggers.AutoComplete;\n\n const renderOnWebAs = props.href ? 'a' : 'button';\n\n /**\n * In SelectInput, returns the isSelected according to selected indexes in the state\n *\n * In Other Triggers (Menu Usecase), returns `props.isSelected` since passing the\n * isSelected prop explicitly is the only way to select item in menu\n */\n const getIsSelected = (): boolean | undefined => {\n if (dropdownTriggerer === dropdownComponentIds.triggers.SelectInput || hasAutoComplete) {\n if (typeof props._index === 'number') {\n return selectedIndices.includes(props._index);\n }\n\n return undefined;\n }\n\n return props.isSelected;\n };\n\n const isSelected = getIsSelected();\n\n React.useEffect(() => {\n validateActionListItemProps({\n leading: props.leading,\n trailing: props.trailing,\n titleSuffix: props.titleSuffix,\n });\n }, [props.leading, props.trailing, props.titleSuffix]);\n\n React.useEffect(() => {\n if (__DEV__) {\n if (\n dropdownTriggerer === dropdownComponentIds.triggers.SelectInput &&\n props.intent === 'negative'\n ) {\n throwBladeError({\n message:\n 'negative intent ActionListItem cannot be used inside Dropdown with SelectInput trigger',\n moduleName: 'ActionListItem',\n });\n }\n }\n }, [props.intent, dropdownTriggerer]);\n\n const isVisible = hasAutoComplete && filteredValues ? filteredValues.includes(props.value) : true;\n\n return (\n <BaseMenuItem\n isVisible={isVisible}\n as={!isReactNative() ? renderOnWebAs : undefined}\n id={`${dropdownBaseId}-${props._index}`}\n tabIndex={-1}\n title={props.title}\n description={props.description}\n leading={\n selectionType === 'multiple' ? (\n <BaseBox\n pointerEvents=\"none\"\n // Adding aria-hidden because the listbox item in multiselect in itself explains the behaviour so announcing checkbox is unneccesary and just a nice UI tweak for us\n {...makeAccessible({\n hidden: true,\n })}\n >\n <Checkbox isChecked={isSelected} tabIndex={-1} isDisabled={props.isDisabled}>\n {/* \n Checkbox requires children. Didn't want to make it optional because its helpful for consumers\n But for this case in particular, we just want to use Text separately so that we can control spacing and color and keep it consistent with non-multiselect dropdowns\n */}\n {null}\n </Checkbox>\n </BaseBox>\n ) : (\n props.leading\n )\n }\n trailing={props.trailing}\n titleSuffix={props.titleSuffix}\n href={props.href}\n target={props.target}\n className={activeIndex === props._index ? 'active-focus' : ''}\n isSelected={isSelected}\n isDisabled={props.isDisabled}\n role={getActionListItemRole(dropdownTriggerer, props.href)}\n {...makeActionListItemClickable((e: React.MouseEvent<HTMLButtonElement>): void => {\n if (typeof props._index === 'number') {\n onOptionClick(e, props._index);\n props.onClick?.({ name: props.value, value: isSelected, event: castWebType(e) });\n }\n })}\n {...makeAnalyticsAttribute({ ...props })}\n {...metaAttribute({ name: MetaConstants.ActionListItem, testID: props.testID })}\n onMouseDown={() => {\n // We want to keep focus on Dropdown's trigger while option is being clicked\n // So We set this flag that ignores the blur animation to avoid the flicker between focus out + focus in\n setShouldIgnoreBlurAnimation(true);\n }}\n onMouseUp={() => {\n // (Contd from above comment...) We set this flag back to false since blur of SelectInput is done calling by this time\n setShouldIgnoreBlurAnimation(false);\n }}\n data-value={props.value}\n data-index={props._index}\n selectionType={selectionType}\n color={props.intent}\n isKeydownPressed={isKeydownPressed}\n />\n );\n};\n\nconst ActionListItem = assignWithoutSideEffects(React.memo(_ActionListItem), {\n componentId: componentIds.ActionListItem,\n displayName: componentIds.ActionListItem,\n});\n\nexport type { ActionListItemProps, ActionListSectionProps };\nexport {\n ActionListItem,\n ActionListItemIcon,\n ActionListItemText,\n ActionListItemAvatar,\n ActionListItemBadge,\n ActionListItemBadgeGroup,\n ActionListSection,\n ActionListSectionTitle,\n};\n"],"names":["StyledActionListSectionTitle","styled","BaseBox","withConfig","displayName","componentId","props","padding","makeSize","theme","spacing","_ActionListSectionTitle","_ref","title","_ref$isInsideVirtuali","isInsideVirtualizedList","_jsx","_objectSpread","makeAccessible","hidden","role","undefined","children","Text","color","size","weight","ActionListSectionTitle","assignWithoutSideEffects","componentIds","_ActionListSection","_ref2","testID","_hideDivider","_sectionChildValues","rest","_objectWithoutProperties","_excluded","_useDropdown","useDropdown","hasAutoCompleteInBottomSheetHeader","dropdownTriggerer","filteredValues","hasAutoComplete","dropdownComponentIds","triggers","AutoComplete","isSectionVisible","React","useMemo","visibleActionListItemInSection","find","actionItemValue","includes","Boolean","showDividerInRN","isReactNative","showDividerInAutoComplete","length","_jsxs","getActionListSectionRole","label","metaAttribute","name","MetaConstants","ActionListSection","makeAnalyticsAttribute","Divider","marginX","marginY","memo","_ActionListItemIcon","_ref3","icon","Icon","_useBaseMenuItem","useBaseMenuItem","isDisabled","iconState","concat","ActionListItemIcon","_ActionListItemBadgeGroup","_ref4","Box","display","alignItems","flexDirection","ActionListItemBadgeGroup","_ActionListItemAvatar","avatarProps","Avatar","ActionListItemAvatar","_ActionListItemBadge","Badge","marginLeft","ActionListItemBadge","_ActionListItemText","_ref5","_useBaseMenuItem2","variant","getNormalTextColor","isMuted","ActionListItemText","makeActionListItemClickable","clickHandler","onPress","onClick","_ActionListItem","_useDropdown2","activeIndex","dropdownBaseId","onOptionClick","selectedIndices","setShouldIgnoreBlurAnimation","selectionType","isKeydownPressed","useEffect","_index","_virtualizedIndex","_props$_onVirtualized","_onVirtualizedFocus","call","renderOnWebAs","href","getIsSelected","SelectInput","isSelected","validateActionListItemProps","leading","trailing","titleSuffix","intent","throwBladeError","message","moduleName","isVisible","value","BaseMenuItem","as","id","tabIndex","description","pointerEvents","Checkbox","isChecked","target","className","getActionListItemRole","e","_props$onClick","event","castWebType","ActionListItem","onMouseDown","onMouseUp"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwGA,IAAMA,4BAA4B,gBAAGC,MAAM,CAACC,OAAO,CAAC,CAAAC,UAAA,CAAA;EAAAC,WAAA,EAAA,8CAAA;EAAAC,WAAA,EAAA,UAAA;AAAA,CAAA,CAAA,CAAC,UAACC,KAAK,EAAA;EAAA,OAAM;AAC/D;IACAC,OAAO,EAAEC,QAAQ,CAACF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BAA4B,CAAC,KAAK,CAAC,CAAA;KACnC;IACF,YAAY3G,EAAAA,KAAK,CAACkI,KAAM;IACxB,YAAYlI,EAAAA,KAAK,CAAC+G,MAAO;AACzBH,IAAAA,aAAa,EAAEA,aAAc;IAC7B1F,KAAK,EAAElB,KAAK,CAAC6H,MAAO;AACpBhB,IAAAA,gBAAgB,EAAEA,gBAAAA;AAAiB,GAAA,CACpC,CAAC,CAAA;AAEN,CAAC,CAAA;AAEKqC,IAAAA,cAAc,gBAAG5H,wBAAwB,eAACoB,cAAK,CAACsB,IAAI,CAACqC,eAAe,CAAC,EAAE;EAC3EtG,WAAW,EAAEwB,YAAY,CAAC2H,cAAc;EACxCpJ,WAAW,EAAEyB,YAAY,CAAC2H,cAAAA;AAC5B,CAAC;;;;"}
@@ -7,7 +7,8 @@ var componentIds = {
7
7
  ActionListItemIcon: 'ActionListItemIcon',
8
8
  ActionListItemAvatar: 'ActionListItemAvatar',
9
9
  ActionListItemText: 'ActionListItemText',
10
- ActionListSection: 'ActionListSection'
10
+ ActionListSection: 'ActionListSection',
11
+ ActionListSectionTitle: 'ActionListSectionTitle'
11
12
  };
12
13
 
13
14
  export { componentIds };
@@ -1 +1 @@
1
- {"version":3,"file":"componentIds.js","sources":["../../../../../../src/components/ActionList/componentIds.ts"],"sourcesContent":["export const componentIds = {\n ActionList: 'ActionList',\n ActionListItem: 'ActionListItem',\n ActionListItemBadge: 'ActionListItemBadge',\n ActionListItemBadgeGroup: 'ActionListItemBadgeGroup',\n ActionListItemAsset: 'ActionListItemAsset',\n ActionListItemIcon: 'ActionListItemIcon',\n ActionListItemAvatar: 'ActionListItemAvatar',\n ActionListItemText: 'ActionListItemText',\n ActionListSection: 'ActionListSection',\n};\n"],"names":["componentIds","ActionList","ActionListItem","ActionListItemBadge","ActionListItemBadgeGroup","ActionListItemAsset","ActionListItemIcon","ActionListItemAvatar","ActionListItemText","ActionListSection"],"mappings":"AAAO,IAAMA,YAAY,GAAG;AAC1BC,EAAAA,UAAU,EAAE,YAAY;AACxBC,EAAAA,cAAc,EAAE,gBAAgB;AAChCC,EAAAA,mBAAmB,EAAE,qBAAqB;AAC1CC,EAAAA,wBAAwB,EAAE,0BAA0B;AACpDC,EAAAA,mBAAmB,EAAE,qBAAqB;AAC1CC,EAAAA,kBAAkB,EAAE,oBAAoB;AACxCC,EAAAA,oBAAoB,EAAE,sBAAsB;AAC5CC,EAAAA,kBAAkB,EAAE,oBAAoB;AACxCC,EAAAA,iBAAiB,EAAE,mBAAA;AACrB;;;;"}
1
+ {"version":3,"file":"componentIds.js","sources":["../../../../../../src/components/ActionList/componentIds.ts"],"sourcesContent":["export const componentIds = {\n ActionList: 'ActionList',\n ActionListItem: 'ActionListItem',\n ActionListItemBadge: 'ActionListItemBadge',\n ActionListItemBadgeGroup: 'ActionListItemBadgeGroup',\n ActionListItemAsset: 'ActionListItemAsset',\n ActionListItemIcon: 'ActionListItemIcon',\n ActionListItemAvatar: 'ActionListItemAvatar',\n ActionListItemText: 'ActionListItemText',\n ActionListSection: 'ActionListSection',\n ActionListSectionTitle: 'ActionListSectionTitle',\n};\n"],"names":["componentIds","ActionList","ActionListItem","ActionListItemBadge","ActionListItemBadgeGroup","ActionListItemAsset","ActionListItemIcon","ActionListItemAvatar","ActionListItemText","ActionListSection","ActionListSectionTitle"],"mappings":"AAAO,IAAMA,YAAY,GAAG;AAC1BC,EAAAA,UAAU,EAAE,YAAY;AACxBC,EAAAA,cAAc,EAAE,gBAAgB;AAChCC,EAAAA,mBAAmB,EAAE,qBAAqB;AAC1CC,EAAAA,wBAAwB,EAAE,0BAA0B;AACpDC,EAAAA,mBAAmB,EAAE,qBAAqB;AAC1CC,EAAAA,kBAAkB,EAAE,oBAAoB;AACxCC,EAAAA,oBAAoB,EAAE,sBAAsB;AAC5CC,EAAAA,kBAAkB,EAAE,oBAAoB;AACxCC,EAAAA,iBAAiB,EAAE,mBAAmB;AACtCC,EAAAA,sBAAsB,EAAE,wBAAA;AAC1B;;;;"}
@@ -1,4 +1,4 @@
1
1
  export { ActionList } from './ActionList.js';
2
- export { ActionListItem, ActionListItemAvatar, ActionListItemBadge, ActionListItemBadgeGroup, ActionListItemIcon, ActionListItemText, ActionListSection } from './ActionListItem.js';
2
+ export { ActionListItem, ActionListItemAvatar, ActionListItemBadge, ActionListItemBadgeGroup, ActionListItemIcon, ActionListItemText, ActionListSection, ActionListSectionTitle } from './ActionListItem.js';
3
3
  export { ActionListItemAsset } from './ActionListItemAsset.web.js';
4
4
  //# sourceMappingURL=index.js.map
@@ -1,7 +1,13 @@
1
1
  import '../../../tokens/global/index.js';
2
2
  import { size } from '../../../tokens/global/size.js';
3
3
 
4
+ /* eslint-disable @typescript-eslint/restrict-plus-operands */
5
+
4
6
  var itemFirstRowHeight = size[20];
7
+ var actionListItemPadding = 8;
8
+ var dividerYMargin = 1;
9
+ var actionListSectionTitleHeight = size[18] + actionListItemPadding * 2;
10
+ var actionListDividerHeight = size[1] + dividerYMargin * 2;
5
11
  var getItemPadding = function getItemPadding(theme) {
6
12
  return {
7
13
  itemPaddingMobile: theme.spacing[2],
@@ -11,7 +17,7 @@ var getItemPadding = function getItemPadding(theme) {
11
17
  var getItemMargin = function getItemMargin(theme) {
12
18
  return theme.spacing[1];
13
19
  };
14
- var getItemHeight = function getItemHeight(theme) {
20
+ var getActionListItemHeight = function getActionListItemHeight(theme) {
15
21
  return {
16
22
  itemHeightMobile:
17
23
  // eslint-disable-next-line @typescript-eslint/restrict-plus-operands
@@ -22,5 +28,5 @@ var getItemHeight = function getItemHeight(theme) {
22
28
  };
23
29
  };
24
30
 
25
- export { getItemHeight, getItemMargin, getItemPadding, itemFirstRowHeight };
31
+ export { actionListDividerHeight, actionListSectionTitleHeight, getActionListItemHeight, getItemMargin, getItemPadding, itemFirstRowHeight };
26
32
  //# sourceMappingURL=tokens.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"tokens.js","sources":["../../../../../../../src/components/BaseMenu/BaseMenuItem/tokens.ts"],"sourcesContent":["import type { Theme } from '~components/BladeProvider';\nimport { size } from '~tokens/global';\n\nconst itemFirstRowHeight = size[20];\n\nconst getItemPadding = (\n theme: Theme,\n): {\n itemPaddingMobile: 4;\n itemPaddingDesktop: 8;\n} => {\n return {\n itemPaddingMobile: theme.spacing[2],\n itemPaddingDesktop: theme.spacing[3],\n };\n};\n\nconst getItemMargin = (theme: Theme): number => {\n return theme.spacing[1];\n};\n\nconst getItemHeight = (\n theme: Theme,\n): {\n itemHeightMobile: number;\n itemHeightDesktop: number;\n} => {\n return {\n itemHeightMobile:\n // eslint-disable-next-line @typescript-eslint/restrict-plus-operands\n itemFirstRowHeight + getItemPadding(theme).itemPaddingMobile * 2 + getItemMargin(theme) * 2,\n itemHeightDesktop:\n // eslint-disable-next-line @typescript-eslint/restrict-plus-operands\n itemFirstRowHeight + getItemPadding(theme).itemPaddingDesktop * 2 + getItemMargin(theme) * 2,\n };\n};\n\nexport { itemFirstRowHeight, getItemPadding, getItemMargin, getItemHeight };\n"],"names":["itemFirstRowHeight","size","getItemPadding","theme","itemPaddingMobile","spacing","itemPaddingDesktop","getItemMargin","getItemHeight","itemHeightMobile","itemHeightDesktop"],"mappings":";;;AAGA,IAAMA,kBAAkB,GAAGC,IAAI,CAAC,EAAE,EAAC;AAEnC,IAAMC,cAAc,GAAG,SAAjBA,cAAcA,CAClBC,KAAY,EAIT;EACH,OAAO;AACLC,IAAAA,iBAAiB,EAAED,KAAK,CAACE,OAAO,CAAC,CAAC,CAAC;AACnCC,IAAAA,kBAAkB,EAAEH,KAAK,CAACE,OAAO,CAAC,CAAC,CAAA;GACpC,CAAA;AACH,EAAC;AAED,IAAME,aAAa,GAAG,SAAhBA,aAAaA,CAAIJ,KAAY,EAAa;AAC9C,EAAA,OAAOA,KAAK,CAACE,OAAO,CAAC,CAAC,CAAC,CAAA;AACzB,EAAC;AAED,IAAMG,aAAa,GAAG,SAAhBA,aAAaA,CACjBL,KAAY,EAIT;EACH,OAAO;IACLM,gBAAgB;AACd;AACAT,IAAAA,kBAAkB,GAAGE,cAAc,CAACC,KAAK,CAAC,CAACC,iBAAiB,GAAG,CAAC,GAAGG,aAAa,CAACJ,KAAK,CAAC,GAAG,CAAC;IAC7FO,iBAAiB;AACf;AACAV,IAAAA,kBAAkB,GAAGE,cAAc,CAACC,KAAK,CAAC,CAACG,kBAAkB,GAAG,CAAC,GAAGC,aAAa,CAACJ,KAAK,CAAC,GAAG,CAAA;GAC9F,CAAA;AACH;;;;"}
1
+ {"version":3,"file":"tokens.js","sources":["../../../../../../../src/components/BaseMenu/BaseMenuItem/tokens.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/restrict-plus-operands */\nimport type { Theme } from '~components/BladeProvider';\nimport { size } from '~tokens/global';\n\nconst itemFirstRowHeight = size[20];\nconst actionListItemPadding = 8;\nconst dividerYMargin = 1;\nconst actionListSectionTitleHeight = size[18] + actionListItemPadding * 2;\nconst actionListDividerHeight = size[1] + dividerYMargin * 2;\n\nconst getItemPadding = (\n theme: Theme,\n): {\n itemPaddingMobile: 4;\n itemPaddingDesktop: 8;\n} => {\n return {\n itemPaddingMobile: theme.spacing[2],\n itemPaddingDesktop: theme.spacing[3],\n };\n};\n\nconst getItemMargin = (theme: Theme): number => {\n return theme.spacing[1];\n};\n\nconst getActionListItemHeight = (\n theme: Theme,\n): {\n itemHeightMobile: number;\n itemHeightDesktop: number;\n} => {\n return {\n itemHeightMobile:\n // eslint-disable-next-line @typescript-eslint/restrict-plus-operands\n itemFirstRowHeight + getItemPadding(theme).itemPaddingMobile * 2 + getItemMargin(theme) * 2,\n itemHeightDesktop:\n // eslint-disable-next-line @typescript-eslint/restrict-plus-operands\n itemFirstRowHeight + getItemPadding(theme).itemPaddingDesktop * 2 + getItemMargin(theme) * 2,\n };\n};\n\nexport {\n actionListSectionTitleHeight,\n actionListDividerHeight,\n itemFirstRowHeight,\n getItemPadding,\n getItemMargin,\n getActionListItemHeight,\n};\n"],"names":["itemFirstRowHeight","size","actionListItemPadding","dividerYMargin","actionListSectionTitleHeight","actionListDividerHeight","getItemPadding","theme","itemPaddingMobile","spacing","itemPaddingDesktop","getItemMargin","getActionListItemHeight","itemHeightMobile","itemHeightDesktop"],"mappings":";;;AAAA;;AAIA,IAAMA,kBAAkB,GAAGC,IAAI,CAAC,EAAE,EAAC;AACnC,IAAMC,qBAAqB,GAAG,CAAC,CAAA;AAC/B,IAAMC,cAAc,GAAG,CAAC,CAAA;AAClBC,IAAAA,4BAA4B,GAAGH,IAAI,CAAC,EAAE,CAAC,GAAGC,qBAAqB,GAAG,EAAC;AACnEG,IAAAA,uBAAuB,GAAGJ,IAAI,CAAC,CAAC,CAAC,GAAGE,cAAc,GAAG,EAAC;AAE5D,IAAMG,cAAc,GAAG,SAAjBA,cAAcA,CAClBC,KAAY,EAIT;EACH,OAAO;AACLC,IAAAA,iBAAiB,EAAED,KAAK,CAACE,OAAO,CAAC,CAAC,CAAC;AACnCC,IAAAA,kBAAkB,EAAEH,KAAK,CAACE,OAAO,CAAC,CAAC,CAAA;GACpC,CAAA;AACH,EAAC;AAED,IAAME,aAAa,GAAG,SAAhBA,aAAaA,CAAIJ,KAAY,EAAa;AAC9C,EAAA,OAAOA,KAAK,CAACE,OAAO,CAAC,CAAC,CAAC,CAAA;AACzB,EAAC;AAED,IAAMG,uBAAuB,GAAG,SAA1BA,uBAAuBA,CAC3BL,KAAY,EAIT;EACH,OAAO;IACLM,gBAAgB;AACd;AACAb,IAAAA,kBAAkB,GAAGM,cAAc,CAACC,KAAK,CAAC,CAACC,iBAAiB,GAAG,CAAC,GAAGG,aAAa,CAACJ,KAAK,CAAC,GAAG,CAAC;IAC7FO,iBAAiB;AACf;AACAd,IAAAA,kBAAkB,GAAGM,cAAc,CAACC,KAAK,CAAC,CAACG,kBAAkB,GAAG,CAAC,GAAGC,aAAa,CAACJ,KAAK,CAAC,GAAG,CAAA;GAC9F,CAAA;AACH;;;;"}
@@ -71,7 +71,7 @@ export { AccordionItemHeader } from './Accordion/AccordionItemHeader.js';
71
71
  export { AccordionItemBody } from './Accordion/AccordionItemBody.js';
72
72
  export { AccordionItem } from './Accordion/AccordionItem.js';
73
73
  export { ActionList } from './ActionList/ActionList.js';
74
- export { ActionListItem, ActionListItemAvatar, ActionListItemBadge, ActionListItemBadgeGroup, ActionListItemIcon, ActionListItemText, ActionListSection } from './ActionList/ActionListItem.js';
74
+ export { ActionListItem, ActionListItemAvatar, ActionListItemBadge, ActionListItemBadgeGroup, ActionListItemIcon, ActionListItemText, ActionListSection, ActionListSectionTitle } from './ActionList/ActionListItem.js';
75
75
  export { ActionListItemAsset } from './ActionList/ActionListItemAsset.web.js';
76
76
  export { Alert } from './Alert/Alert.js';
77
77
  export { Amount } from './Amount/Amount.js';