@elliemae/ds-left-navigation 1.59.7 → 1.61.2

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 (63) hide show
  1. package/cjs/LeftNavigation.js +2 -2
  2. package/cjs/configs/useLeftNavConfig.js +1 -1
  3. package/cjs/configs/useLeftNavConfig.js.map +1 -1
  4. package/cjs/exported-related/ItemRenderer/index.js +4 -2
  5. package/cjs/exported-related/ItemRenderer/index.js.map +1 -1
  6. package/cjs/exported-related/ItemRenderer/usePropsWithDefaults.js +6 -3
  7. package/cjs/exported-related/ItemRenderer/usePropsWithDefaults.js.map +1 -1
  8. package/cjs/exported-related/Notifications/index.js +8 -4
  9. package/cjs/exported-related/Notifications/index.js.map +1 -1
  10. package/cjs/hooks/useSelectFirstBodyItem.js +3 -3
  11. package/cjs/hooks/useSelectFirstBodyItem.js.map +1 -1
  12. package/cjs/index.js +2 -2
  13. package/cjs/outOfTheBox/ItemControlledDrilldown/index.js +5 -2
  14. package/cjs/outOfTheBox/ItemControlledDrilldown/index.js.map +1 -1
  15. package/cjs/outOfTheBox/ItemHeader/index.js +6 -3
  16. package/cjs/outOfTheBox/ItemHeader/index.js.map +1 -1
  17. package/cjs/outOfTheBox/ItemLink/index.js +6 -3
  18. package/cjs/outOfTheBox/ItemLink/index.js.map +1 -1
  19. package/cjs/outOfTheBox/ItemSubmenu/index.js +6 -3
  20. package/cjs/outOfTheBox/ItemSubmenu/index.js.map +1 -1
  21. package/cjs/outOfTheBox/ItemTextLabel/index.js +2 -1
  22. package/cjs/outOfTheBox/ItemTextLabel/index.js.map +1 -1
  23. package/cjs/outOfTheBox/ItemUncontrolledDrilldown/index.js +2 -1
  24. package/cjs/outOfTheBox/ItemUncontrolledDrilldown/index.js.map +1 -1
  25. package/cjs/outOfTheBox/ItemWithDate/index.js +2 -1
  26. package/cjs/outOfTheBox/ItemWithDate/index.js.map +1 -1
  27. package/cjs/parts/LeftNavContent/index.js +4 -3
  28. package/cjs/parts/LeftNavContent/index.js.map +1 -1
  29. package/cjs/parts/OutOfTheBoxMapItem.js +2 -2
  30. package/cjs/prop-types.js +4 -3
  31. package/cjs/prop-types.js.map +1 -1
  32. package/esm/LeftNavigation.js +2 -2
  33. package/esm/configs/useLeftNavConfig.js +1 -1
  34. package/esm/configs/useLeftNavConfig.js.map +1 -1
  35. package/esm/exported-related/ItemRenderer/index.js +4 -2
  36. package/esm/exported-related/ItemRenderer/index.js.map +1 -1
  37. package/esm/exported-related/ItemRenderer/usePropsWithDefaults.js +6 -3
  38. package/esm/exported-related/ItemRenderer/usePropsWithDefaults.js.map +1 -1
  39. package/esm/exported-related/Notifications/index.js +8 -4
  40. package/esm/exported-related/Notifications/index.js.map +1 -1
  41. package/esm/hooks/useSelectFirstBodyItem.js +3 -3
  42. package/esm/hooks/useSelectFirstBodyItem.js.map +1 -1
  43. package/esm/index.js +2 -2
  44. package/esm/outOfTheBox/ItemControlledDrilldown/index.js +5 -2
  45. package/esm/outOfTheBox/ItemControlledDrilldown/index.js.map +1 -1
  46. package/esm/outOfTheBox/ItemHeader/index.js +6 -3
  47. package/esm/outOfTheBox/ItemHeader/index.js.map +1 -1
  48. package/esm/outOfTheBox/ItemLink/index.js +6 -3
  49. package/esm/outOfTheBox/ItemLink/index.js.map +1 -1
  50. package/esm/outOfTheBox/ItemSubmenu/index.js +6 -3
  51. package/esm/outOfTheBox/ItemSubmenu/index.js.map +1 -1
  52. package/esm/outOfTheBox/ItemTextLabel/index.js +2 -1
  53. package/esm/outOfTheBox/ItemTextLabel/index.js.map +1 -1
  54. package/esm/outOfTheBox/ItemUncontrolledDrilldown/index.js +2 -1
  55. package/esm/outOfTheBox/ItemUncontrolledDrilldown/index.js.map +1 -1
  56. package/esm/outOfTheBox/ItemWithDate/index.js +2 -1
  57. package/esm/outOfTheBox/ItemWithDate/index.js.map +1 -1
  58. package/esm/parts/LeftNavContent/index.js +4 -3
  59. package/esm/parts/LeftNavContent/index.js.map +1 -1
  60. package/esm/parts/OutOfTheBoxMapItem.js +2 -2
  61. package/esm/prop-types.js +4 -3
  62. package/esm/prop-types.js.map +1 -1
  63. package/package.json +6 -6
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../../src/outOfTheBox/ItemSubmenu/index.tsx"],"sourcesContent":["/* eslint-disable max-lines */\n/* eslint-disable complexity */\n/* eslint-disable indent */\nimport React, { useCallback } from 'react';\nimport Grid from '@elliemae/ds-grid';\nimport { SimpleTruncatedTooltipText } from '@elliemae/ds-truncated-tooltip-text';\nimport { ItemRenderer } from '../../exported-related/index';\nimport type { ComponentProps } from '../../index.d';\nimport { StyledLabel, StyledChevronLeft } from './styled';\nimport { CHEVRON_BACK_DS_ID } from '../../exported-related/constants';\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nconst notOpenedShadowStyle = (isSelected: boolean) => (theme: any) =>\n `\n box-shadow: inset 4px 0 0 0 ${isSelected ? theme.colors.brand[400] : 'transparent'};\n\n :hover {\n box-shadow: inset 4px 0 0 0 ${isSelected ? theme.colors.brand[400] : theme.colors.brand[300]};\n }\n\n :active {\n box-shadow: inset 4px 0 0 0 ${theme.colors.brand[400]};\n }\n`;\n\nexport const ItemSubmenu = (props: ComponentProps): JSX.Element => {\n const {\n item,\n item: {\n dsId,\n itemOpts: { label, RightComponent, BottomComponent },\n CollapsedComponent = () => null,\n },\n ctx,\n ctx: {\n leftNavProps: { openedItem, labelOverflow, onItemClick },\n expandedForAnimation,\n selectedItem,\n selectedParent,\n setFocusedItem,\n },\n } = props;\n\n const opened = openedItem === dsId;\n\n const isSelected = selectedItem === dsId;\n\n const shadowStyle = useCallback(\n (theme) =>\n !openedItem ? notOpenedShadowStyle(isSelected || selectedParent === dsId)(theme) : `box-shadow: inherit`,\n [dsId, isSelected, openedItem, selectedParent],\n );\n\n const ariaLabel = item.itemOpts.ariaLabel ?? (typeof label === 'string' ? label : 'menuitem');\n\n return (\n <ItemRenderer\n item={{\n ...item,\n itemOpts: {\n ...item.itemOpts,\n ariaLabel,\n ariaExpanded: opened,\n openable: expandedForAnimation && !opened,\n closable: expandedForAnimation && opened,\n selectable: !opened,\n },\n }}\n shadowStyle={shadowStyle}\n hasBorderBottom={opened}\n borderBottomMr=\"12px\"\n >\n <Grid\n cols={opened ? ['auto', 'auto'] : ['38px']}\n gutter=\"1px\"\n pl={opened ? 'xxs' : 0}\n justifyItems=\"center\"\n data-testid=\"leftnav-leftcomponent\"\n >\n {opened && (\n <StyledChevronLeft\n size=\"m\"\n color={['brand-primary', 800]}\n onClick={(e) => {\n onItemClick(item, e);\n }}\n data-testid=\"leftnav-leftcomponent-chevron\"\n tabIndex={0}\n onFocus={(e) => {\n e.stopPropagation();\n setFocusedItem(CHEVRON_BACK_DS_ID);\n }}\n role=\"button\"\n aria-label={`Close ${ariaLabel}`}\n />\n )}\n <CollapsedComponent item={item} ctx={ctx} />\n </Grid>\n <StyledLabel\n ml={opened ? 'xxs' : '1px'}\n mt=\"xxxs\"\n mb=\"15px\"\n data-testid=\"leftnav-itemlabel\"\n labelOverflow={labelOverflow}\n >\n {labelOverflow === 'truncate' ? <SimpleTruncatedTooltipText value={label} placement=\"bottom-start\" /> : label}\n </StyledLabel>\n <Grid\n pl=\"xs\"\n pr={opened ? 'xxs2' : 'xxs'}\n onFocus={(e) => {\n e.stopPropagation();\n setFocusedItem(null);\n }}\n onKeyDown={(e) => e.stopPropagation()}\n onClick={(e) => openedItem && e.stopPropagation()}\n data-testid=\"leftnav-right-component\"\n >\n {RightComponent && <RightComponent ctx={ctx} item={item} />}\n </Grid>\n {BottomComponent && (\n <Grid\n style={{ gridColumn: 'span 3' }}\n pb=\"xxxs\"\n pl=\"xxs\"\n pr=\"xxs\"\n onFocus={(e) => {\n e.stopPropagation();\n setFocusedItem(null);\n }}\n onKeyDown={(e) => e.stopPropagation()}\n onClick={(e) => openedItem && e.stopPropagation()}\n >\n <BottomComponent ctx={ctx} item={item} />\n </Grid>\n )}\n </ItemRenderer>\n );\n};\n"],"names":["notOpenedShadowStyle","isSelected","theme","colors","brand","ItemSubmenu","props","item","dsId","itemOpts","label","RightComponent","BottomComponent","CollapsedComponent","ctx","leftNavProps","openedItem","labelOverflow","onItemClick","expandedForAnimation","selectedItem","selectedParent","setFocusedItem","opened","shadowStyle","useCallback","ariaLabel","React","ItemRenderer","ariaExpanded","openable","closable","selectable","Grid","StyledChevronLeft","e","stopPropagation","CHEVRON_BACK_DS_ID","StyledLabel","SimpleTruncatedTooltipText","gridColumn"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAYA,IAAMA,oBAAoB,GAAG,SAAvBA,oBAAuB,CAACC,UAAD;AAAA,SAAyB,UAACC,KAAD;AAAA,qDAEtBD,UAAU,GAAGC,KAAK,CAACC,MAAN,CAAaC,KAAb,CAAmB,GAAnB,CAAH,GAA6B,aAFjB,8DAKpBH,UAAU,GAAGC,KAAK,CAACC,MAAN,CAAaC,KAAb,CAAmB,GAAnB,CAAH,GAA6BF,KAAK,CAACC,MAAN,CAAaC,KAAb,CAAmB,GAAnB,CALnB,oEASpBF,KAAK,CAACC,MAAN,CAAaC,KAAb,CAAmB,GAAnB,CAToB;AAAA,GAAzB;AAAA,CAA7B;;IAaaC,WAAW,GAAG,SAAdA,WAAc,CAACC,KAAD,EAAwC;AAAA;;AACjE,MACEC,IADF,GAeID,KAfJ,CACEC,IADF;AAAA,oBAeID,KAfJ,CAEEC,IAFF;AAAA,MAGIC,IAHJ,eAGIA,IAHJ;AAAA,yCAIIC,QAJJ;AAAA,MAIgBC,KAJhB,wBAIgBA,KAJhB;AAAA,MAIuBC,cAJvB,wBAIuBA,cAJvB;AAAA,MAIuCC,eAJvC,wBAIuCA,eAJvC;AAAA,0CAKIC,kBALJ;AAAA,MAKIA,kBALJ,sCAKyB;AAAA,WAAM,IAAN;AAAA,GALzB;AAAA,MAOEC,GAPF,GAeIR,KAfJ,CAOEQ,GAPF;AAAA,mBAeIR,KAfJ,CAQEQ,GARF;AAAA,yCASIC,YATJ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dA,MAAAA,CAAC,CAACC,eAAF;AACAd,MAAAA,cAAc,CAAC,IAAD,CAAd;AACD,KANH;AAOE,IAAA,SAAS,EAAE,mBAACa,CAAD;AAAA,aAAOA,CAAC,CAACC,eAAF,EAAP;AAAA,KAPb;AAQE,IAAA,OAAO,EAAE,iBAACD,CAAD;AAAA,aAAOnB,UAAU,IAAImB,CAAC,CAACC,eAAF,EAArB;AAAA,KARX;AASE,mBAAY;AATd,KAWGzB,cAAc,iBAAIgB,wCAAC,cAAD;AAAgB,IAAA,GAAG,EAAEb,GAArB;AAA0B,IAAA,IAAI,EAAEP;AAAhC,IAXrB,CAnDF,EAgEGK,eAAe,iBACde,wCAACM,wBAAD;AACE,IAAA,KAAK,EAAE;AAAEO,MAAAA,UAAU,EAAE;AAAd,KADT;AAEE,IAAA,EAAE,EAAC,MAFL;AAGE,IAAA,EAAE,EAAC,KAHL;AAIE,IAAA,EAAE,EAAC,KAJL;AAKE,IAAA,OAAO,EAAE,iBAACL,CAAD,EAAO;AACdA,MAAAA,CAAC,CAACC,eAAF;AACAd,MAAAA,cAAc,CAAC,IAAD,CAAd;AACD,KARH;AASE,IAAA,SAAS,EAAE,mBAACa,CAAD;AAAA,aAAOA,CAAC,CAACC,eAAF,EAAP;AAAA,KATb;AAUE,IAAA,OAAO,EAAE,iBAACD,CAAD;AAAA,aAAOnB,UAAU,IAAImB,CAAC,CAACC,eAAF,EAArB;AAAA;AAVX,kBAYET,wCAAC,eAAD;AAAiB,IAAA,GAAG,EAAEb,GAAtB;AAA2B,IAAA,IAAI,EAAEP;AAAjC,IAZF,CAjEJ,CADF;AAmFD;;;;"}
1
+ {"version":3,"file":"index.js","sources":["../../../../src/outOfTheBox/ItemSubmenu/index.tsx"],"sourcesContent":["/* eslint-disable max-lines */\n/* eslint-disable complexity */\n/* eslint-disable indent */\nimport React, { useCallback } from 'react';\nimport Grid from '@elliemae/ds-grid';\nimport { SimpleTruncatedTooltipText } from '@elliemae/ds-truncated-tooltip-text';\nimport { ItemRenderer } from '../../exported-related/index';\nimport type { ComponentProps } from '../../index.d';\nimport { StyledLabel, StyledChevronLeft } from './styled';\nimport { CHEVRON_BACK_DS_ID } from '../../exported-related/constants';\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nconst notOpenedShadowStyle = (isSelected: boolean) => (theme: any) =>\n `\n box-shadow: inset 4px 0 0 0 ${isSelected ? theme.colors.brand[400] : 'transparent'};\n\n :hover {\n box-shadow: inset 4px 0 0 0 ${isSelected ? theme.colors.brand[400] : theme.colors.brand[300]};\n }\n\n :active {\n box-shadow: inset 4px 0 0 0 ${theme.colors.brand[400]};\n }\n`;\n\nexport const ItemSubmenu = (props: ComponentProps): JSX.Element => {\n const {\n item,\n item: {\n dsId,\n itemOpts: { label, RightComponent, BottomComponent, labelDataTestId },\n CollapsedComponent = () => null,\n },\n ctx,\n ctx: {\n leftNavProps: { openedItem, labelOverflow, onItemClick },\n expandedForAnimation,\n selectedItem,\n selectedParent,\n setFocusedItem,\n },\n } = props;\n\n const opened = openedItem === dsId;\n\n const isSelected = selectedItem === dsId;\n\n const shadowStyle = useCallback(\n (opened) => (theme: any) =>\n !opened ? notOpenedShadowStyle(isSelected || selectedParent === dsId)(theme) : `box-shadow: inset 4px 0 0 0 #52A6EC`,\n [dsId, isSelected, openedItem, selectedParent],\n );\n\n const ariaLabel = item.itemOpts.ariaLabel ?? (typeof label === 'string' ? label : 'menuitem');\n\n return (\n <ItemRenderer\n item={{\n ...item,\n itemOpts: {\n ...item.itemOpts,\n ariaLabel,\n ariaExpanded: opened,\n openable: expandedForAnimation && !opened,\n closable: expandedForAnimation && opened,\n selectable: !opened,\n },\n }}\n shadowStyle={shadowStyle}\n hasBorderBottom={opened}\n borderBottomMr=\"12px\"\n >\n <Grid\n cols={opened ? ['auto', 'auto'] : ['38px']}\n gutter=\"1px\"\n pl={opened ? 'xxs' : 0}\n justifyItems=\"center\"\n data-testid=\"leftnav-leftcomponent\"\n >\n {opened && (\n <StyledChevronLeft\n size=\"m\"\n color={['brand-primary', 800]}\n onClick={(e) => {\n onItemClick(item, e);\n }}\n data-testid=\"leftnav-leftcomponent-chevron\"\n tabIndex={0}\n onFocus={(e) => {\n e.stopPropagation();\n setFocusedItem(CHEVRON_BACK_DS_ID);\n }}\n role=\"button\"\n aria-label={`Close ${ariaLabel}`}\n />\n )}\n <CollapsedComponent item={item} ctx={ctx} />\n </Grid>\n <StyledLabel\n ml={opened ? 'xxs' : '1px'}\n mt=\"xxxs\"\n mb=\"15px\"\n data-testid={labelDataTestId || 'leftnav-itemlabel'}\n labelOverflow={labelOverflow}\n >\n {labelOverflow === 'truncate' ? <SimpleTruncatedTooltipText value={label} placement=\"bottom-start\" /> : label}\n </StyledLabel>\n <Grid\n pl=\"xs\"\n pr={opened ? 'xxs2' : 'xxs'}\n onFocus={(e) => {\n e.stopPropagation();\n setFocusedItem(null);\n }}\n onKeyDown={(e) => e.stopPropagation()}\n onClick={(e) => openedItem && e.stopPropagation()}\n data-testid=\"leftnav-right-component\"\n >\n {RightComponent && <RightComponent ctx={ctx} item={item} />}\n </Grid>\n {BottomComponent && (\n <Grid\n style={{ gridColumn: 'span 3' }}\n pb=\"xxxs\"\n pl=\"xxs\"\n pr=\"xxs\"\n onFocus={(e) => {\n e.stopPropagation();\n setFocusedItem(null);\n }}\n onKeyDown={(e) => e.stopPropagation()}\n onClick={(e) => openedItem && e.stopPropagation()}\n >\n <BottomComponent ctx={ctx} item={item} />\n </Grid>\n )}\n </ItemRenderer>\n );\n};\n"],"names":["notOpenedShadowStyle","isSelected","theme","colors","brand","ItemSubmenu","props","item","dsId","itemOpts","label","RightComponent","BottomComponent","labelDataTestId","CollapsedComponent","ctx","leftNavProps","openedItem","labelOverflow","onItemClick","expandedForAnimation","selectedItem","selectedParent","setFocusedItem","opened","shadowStyle","useCallback","ariaLabel","React","ItemRenderer","ariaExpanded","openable","closable","selectable","Grid","StyledChevronLeft","e","stopPropagation","CHEVRON_BACK_DS_ID","StyledLabel","SimpleTru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AD;AAAA,aAAOnB,UAAU,IAAImB,CAAC,CAACC,eAAF,EAArB;AAAA,KARX;AASE,mBAAY;AATd,KAWG1B,cAAc,iBAAIiB,wCAAC,cAAD;AAAgB,IAAA,GAAG,EAAEb,GAArB;AAA0B,IAAA,IAAI,EAAER;AAAhC,IAXrB,CAnDF,EAgEGK,eAAe,iBACdgB,wCAACM,wBAAD;AACE,IAAA,KAAK,EAAE;AAAEO,MAAAA,UAAU,EAAE;AAAd,KADT;AAEE,IAAA,EAAE,EAAC,MAFL;AAGE,IAAA,EAAE,EAAC,KAHL;AAIE,IAAA,EAAE,EAAC,KAJL;AAKE,IAAA,OAAO,EAAE,iBAACL,CAAD,EAAO;AACdA,MAAAA,CAAC,CAACC,eAAF;AACAd,MAAAA,cAAc,CAAC,IAAD,CAAd;AACD,KARH;AASE,IAAA,SAAS,EAAE,mBAACa,CAAD;AAAA,aAAOA,CAAC,CAACC,eAAF,EAAP;AAAA,KATb;AAUE,IAAA,OAAO,EAAE,iBAACD,CAAD;AAAA,aAAOnB,UAAU,IAAImB,CAAC,CAACC,eAAF,EAArB;AAAA;AAVX,kBAYET,wCAAC,eAAD;AAAiB,IAAA,GAAG,EAAEb,GAAtB;AAA2B,IAAA,IAAI,EAAER;AAAjC,IAZF,CAjEJ,CADF;AAmFD;;;;"}
@@ -32,6 +32,7 @@ var ItemTextLabel = function ItemTextLabel(props) {
32
32
  itemLabelOverflow = _props$item$itemOpts.labelOverflow,
33
33
  labelBold = _props$item$itemOpts.labelBold,
34
34
  labelColor = _props$item$itemOpts.labelColor,
35
+ labelDataTestId = _props$item$itemOpts.labelDataTestId,
35
36
  leftNavLabelOverflow = props.ctx.leftNavProps.labelOverflow;
36
37
  var labelOverflow = itemLabelOverflow || leftNavLabelOverflow;
37
38
  return /*#__PURE__*/React__default['default'].createElement(exportedRelated_ItemRenderer_index.ItemRenderer, {
@@ -41,7 +42,7 @@ var ItemTextLabel = function ItemTextLabel(props) {
41
42
  minHeight: "32px",
42
43
  paddingTop: "8px"
43
44
  }, " ", /*#__PURE__*/React__default['default'].createElement("div", null), /*#__PURE__*/React__default['default'].createElement(outOfTheBox_ItemTextLabel_styled.StyledLabel, {
44
- "data-testid": "leftnav-list-item-label",
45
+ "data-testid": labelDataTestId || 'leftnav-list-item-label',
45
46
  pl: "24px",
46
47
  labelOverflow: labelOverflow,
47
48
  labelBold: labelBold,
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../../src/outOfTheBox/ItemTextLabel/index.tsx"],"sourcesContent":["import React from 'react';\nimport { SimpleTruncatedTooltipText } from '@elliemae/ds-truncated-tooltip-text';\nimport { ItemRenderer } from '../../exported-related/index';\nimport type { ComponentProps } from '../../index.d';\nimport { StyledLabel } from './styled';\n\nexport const ItemTextLabel = (props: ComponentProps): JSX.Element => {\n const {\n item,\n item: {\n itemOpts: { label, labelOverflow: itemLabelOverflow, labelBold, labelColor },\n },\n ctx: {\n leftNavProps: { labelOverflow: leftNavLabelOverflow },\n },\n } = props;\n\n const labelOverflow = itemLabelOverflow || leftNavLabelOverflow;\n\n return (\n <ItemRenderer\n item={{\n ...item,\n CollapsedComponent: null,\n }}\n minHeight=\"32px\"\n paddingTop=\"8px\"\n >\n {/* Empty LeftComponent */} <div />\n <StyledLabel\n data-testid=\"leftnav-list-item-label\"\n pl=\"24px\"\n labelOverflow={labelOverflow}\n labelBold={labelBold}\n labelColor={labelColor}\n mr=\"xxs2\"\n pb=\"xxxs\"\n >\n {labelOverflow === 'truncate' ? <SimpleTruncatedTooltipText value={label} placement=\"bottom-start\" /> : label}\n </StyledLabel>\n </ItemRenderer>\n );\n};\n"],"names":["ItemTextLabel","props","item","itemOpts","label","itemLabelOverflow","labelOverflow","labelBold","labelColor","leftNavLabelOverflow","ctx","leftNavProps","React","ItemRenderer","CollapsedComponent","StyledLabel","SimpleTruncatedTooltipText"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;IAMaA,aAAa,GAAG,SAAhBA,aAAgB,CAACC,KAAD,EAAwC;AACnE,MACEC,IADF,GAQID,KARJ,CACEC,IADF;AAAA,6BAQID,KARJ,CAEEC,IAFF,CAGIC,QAHJ;AAAA,MAGgBC,KAHhB,wBAGgBA,KAHhB;AAAA,MAGsCC,iBAHtC,wBAGuBC,aAHvB;AAAA,MAGyDC,SAHzD,wBAGyDA,SAHzD;AAAA,MAGoEC,UAHpE,wBAGoEA,UAHpE;AAAA,MAMmCC,oBANnC,GAQIR,KARJ,CAKES,GALF,CAMIC,YANJ,CAMoBL,aANpB;AAUA,MAAMA,aAAa,GAAGD,iBAAiB,IAAII,oBAA3C;AAEA,sBACEG,wCAACC,+CAAD;AACE,IAAA,IAAI,kCACCX,IADD;AAEFY,MAAAA,kBAAkB,EAAE;AAFlB,MADN;AAKE,IAAA,SAAS,EAAC,MALZ;AAME,IAAA,UAAU,EAAC;AANb,uBAQ8BF,oDAR9B,eASEA,wCAACG,4CAAD;AACE,mBAAY,yBADd;AAEE,IAAA,EAAE,EAAC,MAFL;AAGE,IAAA,aAAa,EAAET,aAHjB;AAIE,IAAA,SAAS,EAAEC,SAJb;AAKE,IAAA,UAAU,EAAEC,UALd;AAME,IAAA,EAAE,EAAC,MANL;AAOE,IAAA,EAAE,EAAC;AAPL,KASGF,aAAa,KAAK,UAAlB,gBAA+BM,wCAACI,iDAAD;AAA4B,IAAA,KAAK,EAAEZ,KAAnC;AAA0C,IAAA,SAAS,EAAC;AAApD,IAA/B,GAAuGA,KAT1G,CATF,CADF;AAuBD;;;;"}
1
+ {"version":3,"file":"index.js","sources":["../../../../src/outOfTheBox/ItemTextLabel/index.tsx"],"sourcesContent":["import React from 'react';\nimport { SimpleTruncatedTooltipText } from '@elliemae/ds-truncated-tooltip-text';\nimport { ItemRenderer } from '../../exported-related/index';\nimport type { ComponentProps } from '../../index.d';\nimport { StyledLabel } from './styled';\n\nexport const ItemTextLabel = (props: ComponentProps): JSX.Element => {\n const {\n item,\n item: {\n itemOpts: { label, labelOverflow: itemLabelOverflow, labelBold, labelColor, labelDataTestId },\n },\n ctx: {\n leftNavProps: { labelOverflow: leftNavLabelOverflow },\n },\n } = props;\n\n const labelOverflow = itemLabelOverflow || leftNavLabelOverflow;\n\n return (\n <ItemRenderer\n item={{\n ...item,\n CollapsedComponent: null,\n }}\n minHeight=\"32px\"\n paddingTop=\"8px\"\n >\n {/* Empty LeftComponent */} <div />\n <StyledLabel\n data-testid={labelDataTestId || 'leftnav-list-item-label'}\n pl=\"24px\"\n labelOverflow={labelOverflow}\n labelBold={labelBold}\n labelColor={labelColor}\n mr=\"xxs2\"\n pb=\"xxxs\"\n >\n {labelOverflow === 'truncate' ? <SimpleTruncatedTooltipText value={label} placement=\"bottom-start\" /> : label}\n </StyledLabel>\n </ItemRenderer>\n );\n};\n"],"names":["ItemTextLabel","props","item","itemOpts","label","itemLabelOverflow","labelOverflow","labelBold","labelColor","labelDataTestId","leftNavLabelOverflow","ctx","leftNavProps","React","ItemRenderer","CollapsedComponent","StyledLabel","SimpleTruncatedTooltipText"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;IAMaA,aAAa,GAAG,SAAhBA,aAAgB,CAACC,KAAD,EAAwC;AACnE,MACEC,IADF,GAQID,KARJ,CACEC,IADF;AAAA,6BAQID,KARJ,CAEEC,IAFF,CAGIC,QAHJ;AAAA,MAGgBC,KAHhB,wBAGgBA,KAHhB;AAAA,MAGsCC,iBAHtC,wBAGuBC,aAHvB;AAAA,MAGyDC,SAHzD,wBAGyDA,SAHzD;AAAA,MAGoEC,UAHpE,wBAGoEA,UAHpE;AAAA,MAGgFC,eAHhF,wBAGgFA,eAHhF;AAAA,MAMmCC,oBANnC,GAQIT,KARJ,CAKEU,GALF,CAMIC,YANJ,CAMoBN,aANpB;AAUA,MAAMA,aAAa,GAAGD,iBAAiB,IAAIK,oBAA3C;AAEA,sBACEG,wCAACC,+CAAD;AACE,IAAA,IAAI,kCACCZ,IADD;AAEFa,MAAAA,kBAAkB,EAAE;AAFlB,MADN;AAKE,IAAA,SAAS,EAAC,MALZ;AAME,IAAA,UAAU,EAAC;AANb,uBAQ8BF,oDAR9B,eASEA,wCAACG,4CAAD;AACE,mBAAaP,eAAe,IAAI,yBADlC;AAEE,IAAA,EAAE,EAAC,MAFL;AAGE,IAAA,aAAa,EAAEH,aAHjB;AAIE,IAAA,SAAS,EAAEC,SAJb;AAKE,IAAA,UAAU,EAAEC,UALd;AAME,IAAA,EAAE,EAAC,MANL;AAOE,IAAA,EAAE,EAAC;AAPL,KASGF,aAAa,KAAK,UAAlB,gBAA+BO,wCAACI,iDAAD;AAA4B,IAAA,KAAK,EAAEb,KAAnC;AAA0C,IAAA,SAAS,EAAC;AAApD,IAA/B,GAAuGA,KAT1G,CATF,CADF;AAuBD;;;;"}
@@ -83,6 +83,7 @@ var ItemUncontrolledDrilldown = function ItemUncontrolledDrilldown(props) {
83
83
  labelColor = _props$item2$itemOpts.labelColor,
84
84
  startOpened = _props$item2$itemOpts.startOpened,
85
85
  items = _props$item2$itemOpts.items,
86
+ labelDataTestId = _props$item2$itemOpts.labelDataTestId,
86
87
  ctx = props.ctx,
87
88
  _props$ctx = props.ctx,
88
89
  leftNavLabelOverflow = _props$ctx.leftNavProps.labelOverflow,
@@ -138,7 +139,7 @@ var ItemUncontrolledDrilldown = function ItemUncontrolledDrilldown(props) {
138
139
  mt: "-2px"
139
140
  }, arrowIcon), /*#__PURE__*/React__default['default'].createElement(outOfTheBox_ItemUncontrolledDrilldown_styled.StyledLabel, {
140
141
  pb: "xxxs",
141
- "data-testid": "leftnav-list-item-label",
142
+ "data-testid": labelDataTestId || 'leftnav-list-item-label',
142
143
  labelOverflow: labelOverflow,
143
144
  labelBold: labelBold,
144
145
  labelColor: labelColor
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../../src/outOfTheBox/ItemUncontrolledDrilldown/index.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nimport React, { useMemo, useCallback, useEffect } from 'react';\nimport Grid from '@elliemae/ds-grid';\nimport { SimpleTruncatedTooltipText } from '@elliemae/ds-truncated-tooltip-text';\nimport { ArrowheadDown, ArrowheadRight } from '@elliemae/ds-icons';\nimport { ItemRenderer, ITEM_TYPES } from '../../exported-related/index';\nimport { StyledLabel, StyledDate } from './styled';\nimport { ItemSeparator } from '../ItemSeparator';\nimport { ItemWithDate } from '../ItemWithDate';\nimport { ItemTextLabel } from '../ItemTextLabel';\nimport type { ComponentProps } from '../../index.d';\n\n// Subitem mapping\nconst outOfTheBoxSubitemsComponents: Record<string, React.ComponentType<ComponentProps>> = {\n [ITEM_TYPES.LEFT_NAV_ITEM_SEPARATOR]: ItemSeparator,\n [ITEM_TYPES.LEFT_NAV_ITEM_WITH_DATE]: ItemWithDate,\n [ITEM_TYPES.LEFT_NAV_ITEM_TEXT_LABEL]: ItemTextLabel,\n};\n\nconst OutOfTheBoxMapSubitem = (props: ComponentProps): JSX.Element => {\n const {\n item,\n item: { type, Component },\n ctx,\n } = props;\n\n if (typeof type === 'string' && !!outOfTheBoxSubitemsComponents[type]) {\n const OutOfTheBoxComponent = outOfTheBoxSubitemsComponents[type];\n const currentIndent = item.itemOpts?.indent ?? 0;\n const newItem = {\n ...item,\n itemOpts: { ...item.itemOpts, indent: currentIndent + 44 },\n };\n return <OutOfTheBoxComponent item={newItem} ctx={ctx} />;\n }\n // we expect an error to be threw if Component is not defined and type is not a valid out-of-the-box...\n return <Component item={item} ctx={ctx} />;\n};\n\nexport const ItemUncontrolledDrilldown = (props: ComponentProps): JSX.Element => {\n const {\n item,\n item: {\n dsId,\n itemOpts: {\n label,\n RightComponent,\n labelRightSection,\n labelOverflow: itemLabelOverflow,\n labelBold,\n labelColor,\n startOpened,\n items,\n },\n },\n ctx,\n ctx: {\n leftNavProps: { labelOverflow: leftNavLabelOverflow },\n openedDrilldowns,\n setOpenedDrilldowns,\n },\n } = props;\n\n // Start opened functionality\n useEffect(() => {\n if (startOpened) setOpenedDrilldowns([...openedDrilldowns, dsId]);\n }, []);\n\n const opened = openedDrilldowns.includes(dsId);\n\n const labelOverflow = itemLabelOverflow || leftNavLabelOverflow;\n\n const arrowIcon = useMemo(() => {\n const Component = opened ? ArrowheadDown : ArrowheadRight;\n return <Component width=\"24px\" height=\"18px\" color={['brand-primary', '800']} />;\n }, [opened]);\n\n // Array of subitems\n const subitems = useMemo(() => {\n if (!opened || !items) return [];\n return items.map((subitem) => <OutOfTheBoxMapSubitem item={subitem} ctx={ctx} key={subitem.dsId} />);\n }, [items, opened]);\n\n const handleOnClick = useCallback(() => {\n if (opened) setOpenedDrilldowns(openedDrilldowns.filter((openedDrilldown) => openedDrilldown !== dsId));\n else setOpenedDrilldowns([...openedDrilldowns, dsId]);\n }, [opened, setOpenedDrilldowns, openedDrilldowns]);\n\n return (\n <ItemRenderer\n item={{\n ...item,\n itemOpts: {\n ariaExpanded: opened,\n ariaRole: 'menuitem',\n ...item.itemOpts,\n openable: !opened,\n closable: opened,\n },\n CollapsedComponent: null,\n }}\n subitems={subitems}\n minHeight=\"32px\"\n paddingTop=\"8px\"\n onClick={handleOnClick}\n >\n <Grid pl=\"xxs\" mt=\"-2px\">\n {arrowIcon}\n </Grid>\n <StyledLabel\n pb=\"xxxs\"\n data-testid=\"leftnav-list-item-label\"\n labelOverflow={labelOverflow}\n labelBold={labelBold}\n labelColor={labelColor}\n >\n {labelOverflow === 'truncate' ? <SimpleTruncatedTooltipText value={label} placement=\"bottom-start\" /> : label}\n </StyledLabel>\n <Grid pr=\"xxs2\" cols={['auto', 'auto']} alignItems=\"center\">\n <StyledDate ml=\"xxs\" data-testid=\"leftnav-list-item-date\">\n {labelRightSection}\n </StyledDate>\n <Grid pl={RightComponent ? 'xxs' : '0px'}>{RightComponent && <RightComponent ctx={ctx} item={item} />}</Grid>\n </Grid>\n </ItemRenderer>\n );\n};\n"],"names":["outOfTheBoxSubitemsComponents","ITEM_TYPES","LEFT_NAV_ITEM_SEPARATOR","ItemSeparator","LEFT_NAV_ITEM_WITH_DATE","ItemWithDate","LEFT_NAV_ITEM_TEXT_LABEL","ItemTextLabel","OutOfTheBoxMapSubitem","props","item","type","Component","ctx","OutOfTheBoxComponent","currentIndent","itemOpts","indent","newItem","React","ItemUncontrolledDrilldown","dsId","label","RightComponent","labelRightSection","itemLabelOverflow","labelOverflow","labelBold","labelColor","startOpened","items","leftNavLabelOverflow","leftNavProps","openedDrilldowns","setOpenedDrilldowns","useEffect","opened","includes","arrowIcon","useMemo","ArrowheadDown","ArrowheadRight","subitems","map","subitem","handleOnClick","useCallback","filter","openedDrilldown","ItemRenderer","ariaExpanded","ariaRole","openable","closable","CollapsedComponent","Grid","StyledLabel","SimpleTruncatedTooltipText","StyledDate"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAYA;AACA,IAAMA,6BAAkF,2FACrFC,oCAAU,CAACC,uBAD0E,EAChDC,6CADgD,8DAErFF,oCAAU,CAACG,uBAF0E,EAEhDC,2CAFgD,8DAGrFJ,oCAAU,CAACK,wBAH0E,EAG/CC,6CAH+C,yBAAxF;;AAMA,IAAMC,qBAAqB,GAAG,SAAxBA,qBAAwB,CAACC,KAAD,EAAwC;AACpE,MACEC,IADF,GAIID,KAJJ,CACEC,IADF;AAAA,oBAIID,KAJJ,CAEEC,IAFF;AAAA,MAEUC,IAFV,eAEUA,IAFV;AAAA,MAEgBC,SAFhB,eAEgBA,SAFhB;AAAA,MAGEC,GAHF,GAIIJ,KAJJ,CAGEI,GAHF;;AAMA,MAAI,OAAOF,IAAP,KAAgB,QAAhB,IAA4B,CAAC,CAACX,6BAA6B,CAACW,IAAD,CAA/D,EAAuE;AAAA;;AACrE,QAAMG,oBAAoB,GAAGd,6BAA6B,CAACW,IAAD,CAA1D;AACA,QAAMI,aAAa,8CAAGL,IAAI,CAACM,QAAR,mDAAG,eAAeC,MAAlB,yEAA4B,CAA/C;;AACA,QAAMC,OAAO,mCACRR,IADQ;AAEXM,MAAAA,QAAQ,kCAAON,IAAI,CAACM,QAAZ;AAAsBC,QAAAA,MAAM,EAAEF,a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Q,EAAE,CAAChB,MAJL;AAKNiB,QAAAA,QAAQ,EAAEjB;AALJ,QAFN;AASFkB,MAAAA,kBAAkB,EAAE;AATlB,MADN;AAYE,IAAA,QAAQ,EAAEZ,QAZZ;AAaE,IAAA,SAAS,EAAC,MAbZ;AAcE,IAAA,UAAU,EAAC,KAdb;AAeE,IAAA,OAAO,EAAEG;AAfX,kBAiBE1B,wCAACoC,wBAAD;AAAM,IAAA,EAAE,EAAC,KAAT;AAAe,IAAA,EAAE,EAAC;AAAlB,KACGjB,SADH,CAjBF,eAoBEnB,wCAACqC,wDAAD;AACE,IAAA,EAAE,EAAC,MADL;AAEE,mBAAY,yBAFd;AAGE,IAAA,aAAa,EAAE9B,aAHjB;AAIE,IAAA,SAAS,EAAEC,SAJb;AAKE,IAAA,UAAU,EAAEC;AALd,KAOGF,aAAa,KAAK,UAAlB,gBAA+BP,wCAACsC,iDAAD;AAA4B,IAAA,KAAK,EAAEnC,KAAnC;AAA0C,IAAA,SAAS,EAAC;AAApD,IAA/B,GAAuGA,KAP1G,CApBF,eA6BEH,wCAACoC,wBAAD;AAAM,IAAA,EAAE,EAAC,MAAT;AAAgB,IAAA,IAAI,EAAE,CAAC,MAAD,EAAS,MAAT,CAAtB;AAAwC,IAAA,UAAU,EAAC;AAAnD,kBACEpC,wCAACuC,uDAAD;AAAY,IAAA,EAAE,EAAC,KAAf;AAAqB,mBAAY;AAAjC,KACGlC,iBADH,CADF,eAIEL,wCAACoC,wBAAD;AAAM,IAAA,EAAE,EAAEhC,cAAc,GAAG,KAAH,GAAW;AAAnC,KAA2CA,cAAc,iBAAIJ,wCAAC,cAAD;AAAgB,IAAA,GAAG,EAAEN,GAArB;AAA0B,IAAA,IAAI,EAAEH;AAAhC,IAA7D,CAJF,CA7BF,CADF;AAsCD;;;;"}
1
+ {"version":3,"file":"index.js","sources":["../../../../src/outOfTheBox/ItemUncontrolledDrilldown/index.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nimport React, { useMemo, useCallback, useEffect } from 'react';\nimport Grid from '@elliemae/ds-grid';\nimport { SimpleTruncatedTooltipText } from '@elliemae/ds-truncated-tooltip-text';\nimport { ArrowheadDown, ArrowheadRight } from '@elliemae/ds-icons';\nimport { ItemRenderer, ITEM_TYPES } from '../../exported-related/index';\nimport { StyledLabel, StyledDate } from './styled';\nimport { ItemSeparator } from '../ItemSeparator';\nimport { ItemWithDate } from '../ItemWithDate';\nimport { ItemTextLabel } from '../ItemTextLabel';\nimport type { ComponentProps } from '../../index.d';\n\n// Subitem mapping\nconst outOfTheBoxSubitemsComponents: Record<string, React.ComponentType<ComponentProps>> = {\n [ITEM_TYPES.LEFT_NAV_ITEM_SEPARATOR]: ItemSeparator,\n [ITEM_TYPES.LEFT_NAV_ITEM_WITH_DATE]: ItemWithDate,\n [ITEM_TYPES.LEFT_NAV_ITEM_TEXT_LABEL]: ItemTextLabel,\n};\n\nconst OutOfTheBoxMapSubitem = (props: ComponentProps): JSX.Element => {\n const {\n item,\n item: { type, Component },\n ctx,\n } = props;\n\n if (typeof type === 'string' && !!outOfTheBoxSubitemsComponents[type]) {\n const OutOfTheBoxComponent = outOfTheBoxSubitemsComponents[type];\n const currentIndent = item.itemOpts?.indent ?? 0;\n const newItem = {\n ...item,\n itemOpts: { ...item.itemOpts, indent: currentIndent + 44 },\n };\n return <OutOfTheBoxComponent item={newItem} ctx={ctx} />;\n }\n // we expect an error to be threw if Component is not defined and type is not a valid out-of-the-box...\n return <Component item={item} ctx={ctx} />;\n};\n\nexport const ItemUncontrolledDrilldown = (props: ComponentProps): JSX.Element => {\n const {\n item,\n item: {\n dsId,\n itemOpts: {\n label,\n RightComponent,\n labelRightSection,\n labelOverflow: itemLabelOverflow,\n labelBold,\n labelColor,\n startOpened,\n items,\n labelDataTestId,\n },\n },\n ctx,\n ctx: {\n leftNavProps: { labelOverflow: leftNavLabelOverflow },\n openedDrilldowns,\n setOpenedDrilldowns,\n },\n } = props;\n\n // Start opened functionality\n useEffect(() => {\n if (startOpened) setOpenedDrilldowns([...openedDrilldowns, dsId]);\n }, []);\n\n const opened = openedDrilldowns.includes(dsId);\n\n const labelOverflow = itemLabelOverflow || leftNavLabelOverflow;\n\n const arrowIcon = useMemo(() => {\n const Component = opened ? ArrowheadDown : ArrowheadRight;\n return <Component width=\"24px\" height=\"18px\" color={['brand-primary', '800']} />;\n }, [opened]);\n\n // Array of subitems\n const subitems = useMemo(() => {\n if (!opened || !items) return [];\n return items.map((subitem) => <OutOfTheBoxMapSubitem item={subitem} ctx={ctx} key={subitem.dsId} />);\n }, [items, opened]);\n\n const handleOnClick = useCallback(() => {\n if (opened) setOpenedDrilldowns(openedDrilldowns.filter((openedDrilldown) => openedDrilldown !== dsId));\n else setOpenedDrilldowns([...openedDrilldowns, dsId]);\n }, [opened, setOpenedDrilldowns, openedDrilldowns]);\n\n return (\n <ItemRenderer\n item={{\n ...item,\n itemOpts: {\n ariaExpanded: opened,\n ariaRole: 'menuitem',\n ...item.itemOpts,\n openable: !opened,\n closable: opened,\n },\n CollapsedComponent: null,\n }}\n subitems={subitems}\n minHeight=\"32px\"\n paddingTop=\"8px\"\n onClick={handleOnClick}\n >\n <Grid pl=\"xxs\" mt=\"-2px\">\n {arrowIcon}\n </Grid>\n <StyledLabel\n pb=\"xxxs\"\n data-testid={labelDataTestId || 'leftnav-list-item-label'}\n labelOverflow={labelOverflow}\n labelBold={labelBold}\n labelColor={labelColor}\n >\n {labelOverflow === 'truncate' ? <SimpleTruncatedTooltipText value={label} placement=\"bottom-start\" /> : label}\n </StyledLabel>\n <Grid pr=\"xxs2\" cols={['auto', 'auto']} alignItems=\"center\">\n <StyledDate ml=\"xxs\" data-testid=\"leftnav-list-item-date\">\n {labelRightSection}\n </StyledDate>\n <Grid pl={RightComponent ? 'xxs' : '0px'}>{RightComponent && <RightComponent ctx={ctx} item={item} />}</Grid>\n </Grid>\n </ItemRenderer>\n );\n};\n"],"names":["outOfTheBoxSubitemsComponents","ITEM_TYPES","LEFT_NAV_ITEM_SEPARATOR","ItemSeparator","LEFT_NAV_ITEM_WITH_DATE","ItemWithDate","LEFT_NAV_ITEM_TEXT_LABEL","ItemTextLabel","OutOfTheBoxMapSubitem","props","item","type","Component","ctx","OutOfTheBoxComponent","currentIndent","itemOpts","indent","newItem","React","ItemUncontrolledDrilldown","dsId","label","RightComponent","labelRightSection","itemLabelOverflow","labelOverflow","labelBold","labelColor","startOpened","items","labelDataTestId","leftNavLabelOverflow","leftNavProps","openedDrilldowns","setOpenedDrilldowns","useEffect","opened","includes","arrowIcon","useMemo","ArrowheadDown","ArrowheadRight","subitems","map","subitem","handleOnClick","useCallback","filter","openedDrilldown","ItemRenderer","ariaExpanded","ariaRole","openable","closable","CollapsedComponent","Grid","StyledLabel","SimpleTruncatedTooltipText","StyledDate"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAYA;AACA,IAAMA,6BAAkF,2FACrFC,oCAAU,CAACC,uBAD0E,EAChDC,6CADgD,8DAErFF,oCAAU,CAACG,uBAF0E,EAEhDC,2CAFgD,8DAGrFJ,oCAAU,CAACK,wBAH0E,EAG/CC,6CAH+C,yBAAxF;;AAMA,IAAMC,qBAAqB,GAAG,SAAxBA,qBAAwB,CAACC,KAAD,EAAwC;AACpE,MACEC,IADF,GAIID,KAJJ,CACEC,IADF;AAAA,oBAIID,KAJJ,CAEEC,IAFF;AAAA,MAEUC,IAFV,eAEUA,IAFV;AAAA,MAEgBC,SAFhB,eAEgBA,SAFhB;AAAA,MAGEC,GAHF,GAIIJ,KAJJ,CAGEI,GAHF;;AAMA,MAAI,OAAOF,IAAP,KAAgB,QAAhB,IAA4B,CAAC,CAACX,6BAA6B,CAACW,IAAD,CAA/D,EAAuE;AAAA;;AACrE,QAAMG,oBAAoB,GAAGd,6BAA6B,CAACW,IAAD,CAA1D;AACA,QAAMI,aAAa,8CAAGL,IAAI,CAACM,QAAR,mDAAG,eAAeC,MAAlB,yEAA4B,CAA/C;;AACA,QAAMC,OAAO,mCACRR,IAD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F,CADF;AAsCD;;;;"}
@@ -35,6 +35,7 @@ var ItemWithDate = function ItemWithDate(props) {
35
35
  itemLabelOverflow = _props$item$itemOpts.labelOverflow,
36
36
  labelBold = _props$item$itemOpts.labelBold,
37
37
  labelColor = _props$item$itemOpts.labelColor,
38
+ labelDataTestId = _props$item$itemOpts.labelDataTestId,
38
39
  ctx = props.ctx,
39
40
  leftNavLabelOverflow = props.ctx.leftNavProps.labelOverflow;
40
41
  var labelOverflow = itemLabelOverflow || leftNavLabelOverflow;
@@ -47,7 +48,7 @@ var ItemWithDate = function ItemWithDate(props) {
47
48
  }, " ", /*#__PURE__*/React__default['default'].createElement("div", null), /*#__PURE__*/React__default['default'].createElement(outOfTheBox_ItemWithDate_styled.StyledLabel, {
48
49
  pl: "xxs",
49
50
  pb: "xxxs",
50
- "data-testid": "leftnav-list-item-label",
51
+ "data-testid": labelDataTestId || 'leftnav-list-item-label',
51
52
  labelOverflow: labelOverflow,
52
53
  labelBold: labelBold,
53
54
  labelColor: labelColor
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../../src/outOfTheBox/ItemWithDate/index.tsx"],"sourcesContent":["import React from 'react';\nimport Grid from '@elliemae/ds-grid';\nimport { SimpleTruncatedTooltipText } from '@elliemae/ds-truncated-tooltip-text';\nimport { ItemRenderer } from '../../exported-related/index';\nimport type { ComponentProps } from '../../index.d';\nimport { StyledLabel, StyledDate } from './styled';\n\nexport const ItemWithDate = (props: ComponentProps): JSX.Element => {\n const {\n item,\n item: {\n itemOpts: {\n label,\n RightComponent,\n labelRightSection,\n labelOverflow: itemLabelOverflow,\n labelBold,\n labelColor,\n },\n },\n ctx,\n ctx: {\n leftNavProps: { labelOverflow: leftNavLabelOverflow },\n },\n } = props;\n\n const labelOverflow = itemLabelOverflow || leftNavLabelOverflow;\n\n return (\n <ItemRenderer\n item={{\n ...item,\n CollapsedComponent: null,\n }}\n minHeight=\"32px\"\n paddingTop=\"8px\"\n >\n {/* Empty LeftComponent */} <div />\n <StyledLabel\n pl=\"xxs\"\n pb=\"xxxs\"\n data-testid=\"leftnav-list-item-label\"\n labelOverflow={labelOverflow}\n labelBold={labelBold}\n labelColor={labelColor}\n >\n {labelOverflow === 'truncate' ? (\n <SimpleTruncatedTooltipText value={label} placement=\"bottom-start\" />\n ) : (\n label\n )}\n </StyledLabel>\n <Grid pr=\"xxs2\" cols={['auto', 'auto']} alignItems=\"center\">\n <StyledDate ml=\"xxs\" data-testid=\"leftnav-list-item-date\">\n {labelRightSection}\n </StyledDate>\n <Grid\n pl={RightComponent ? 'xxs' : '0px'}\n data-testid=\"leftnav-right-component\"\n >\n {RightComponent && <RightComponent ctx={ctx} item={item} />}\n </Grid>\n </Grid>\n </ItemRenderer>\n );\n};\n"],"names":["ItemWithDate","props","item","itemOpts","label","RightComponent","labelRightSection","itemLabelOverflow","labelOverflow","labelBold","labelColor","ctx","leftNavLabelOverflow","leftNavProps","React","ItemRenderer","CollapsedComponent","StyledLabel","SimpleTruncatedTooltipText","Grid","StyledDate"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;IAOaA,YAAY,GAAG,SAAfA,YAAe,CAACC,KAAD,EAAwC;AAClE,MACEC,IADF,GAgBID,KAhBJ,CACEC,IADF;AAAA,6BAgBID,KAhBJ,CAEEC,IAFF,CAGIC,QAHJ;AAAA,MAIMC,KAJN,wBAIMA,KAJN;AAAA,MAKMC,cALN,wBAKMA,cALN;AAAA,MAMMC,iBANN,wBAMMA,iBANN;AAAA,MAOqBC,iBAPrB,wBAOMC,aAPN;AAAA,MAQMC,SARN,wBAQMA,SARN;AAAA,MASMC,UATN,wBASMA,UATN;AAAA,MAYEC,GAZF,GAgBIV,KAhBJ,CAYEU,GAZF;AAAA,MAcmCC,oBAdnC,GAgBIX,KAhBJ,CAaEU,GAbF,CAcIE,YAdJ,CAcoBL,aAdpB;AAkBA,MAAMA,aAAa,GAAGD,iBAAiB,IAAIK,oBAA3C;AAEA,sBACEE,wCAACC,+CAAD;AACE,IAAA,IAAI,kCACCb,IADD;AAEFc,MAAAA,kBAAkB,EAAE;AAFlB,MADN;AAKE,IAAA,SAAS,EAAC,MALZ;AAME,IAAA,UAAU,EAAC;AANb,uBAQ8BF,oDAR9B,eASEA,wCAACG,2CAAD;AACE,IAAA,EAAE,EAAC,KADL;AAEE,IAAA,EAAE,EAAC,MAFL;AAGE,mBAAY,yBAHd;AAIE,IAAA,aAAa,EAAET,aAJjB;AAKE,IAAA,SAAS,EAAEC,SALb;AAME,IAAA,UAAU,EAAEC;AANd,KAQGF,aAAa,KAAK,UAAlB,gBACCM,wCAACI,iDAAD;AAA4B,IAAA,KAAK,EAAEd,KAAnC;AAA0C,IAAA,SAAS,EAAC;AAApD,IADD,GAGCA,KAXJ,CATF,eAuBEU,wCAACK,wBAAD;AAAM,IAAA,EAAE,EAAC,MAAT;AAAgB,IAAA,IAAI,EAAE,CAAC,MAAD,EAAS,MAAT,CAAtB;AAAwC,IAAA,UAAU,EAAC;AAAnD,kBACEL,wCAACM,0CAAD;AAAY,IAAA,EAAE,EAAC,KAAf;AAAqB,mBAAY;AAAjC,KACGd,iBADH,CADF,eAIEQ,wCAACK,wBAAD;AACE,IAAA,EAAE,EAAEd,cAAc,GAAG,KAAH,GAAW,KAD/B;AAEE,mBAAY;AAFd,KAIGA,cAAc,iBAAIS,wCAAC,cAAD;AAAgB,IAAA,GAAG,EAAEH,GAArB;AAA0B,IAAA,IAAI,EAAET;AAAhC,IAJrB,CAJF,CAvBF,CADF;AAqCD;;;;"}
1
+ {"version":3,"file":"index.js","sources":["../../../../src/outOfTheBox/ItemWithDate/index.tsx"],"sourcesContent":["import React from 'react';\nimport Grid from '@elliemae/ds-grid';\nimport { SimpleTruncatedTooltipText } from '@elliemae/ds-truncated-tooltip-text';\nimport { ItemRenderer } from '../../exported-related/index';\nimport type { ComponentProps } from '../../index.d';\nimport { StyledLabel, StyledDate } from './styled';\n\nexport const ItemWithDate = (props: ComponentProps): JSX.Element => {\n const {\n item,\n item: {\n itemOpts: {\n label,\n RightComponent,\n labelRightSection,\n labelOverflow: itemLabelOverflow,\n labelBold,\n labelColor,\n labelDataTestId,\n },\n },\n ctx,\n ctx: {\n leftNavProps: { labelOverflow: leftNavLabelOverflow },\n },\n } = props;\n\n const labelOverflow = itemLabelOverflow || leftNavLabelOverflow;\n\n return (\n <ItemRenderer\n item={{\n ...item,\n CollapsedComponent: null,\n }}\n minHeight=\"32px\"\n paddingTop=\"8px\"\n >\n {/* Empty LeftComponent */} <div />\n <StyledLabel\n pl=\"xxs\"\n pb=\"xxxs\"\n data-testid={labelDataTestId || 'leftnav-list-item-label'}\n labelOverflow={labelOverflow}\n labelBold={labelBold}\n labelColor={labelColor}\n >\n {labelOverflow === 'truncate' ? <SimpleTruncatedTooltipText value={label} placement=\"bottom-start\" /> : label}\n </StyledLabel>\n <Grid pr=\"xxs2\" cols={['auto', 'auto']} alignItems=\"center\">\n <StyledDate ml=\"xxs\" data-testid=\"leftnav-list-item-date\">\n {labelRightSection}\n </StyledDate>\n <Grid pl={RightComponent ? 'xxs' : '0px'} data-testid=\"leftnav-right-component\">\n {RightComponent && <RightComponent ctx={ctx} item={item} />}\n </Grid>\n </Grid>\n </ItemRenderer>\n );\n};\n"],"names":["ItemWithDate","props","item","itemOpts","label","RightComponent","labelRightSection","itemLabelOverflow","labelOverflow","labelBold","labelColor","labelDataTestId","ctx","leftNavLabelOverflow","leftNavProps","React","ItemRenderer","CollapsedComponent","StyledLabel","SimpleTruncatedTooltipText","Grid","StyledDate"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;IAOaA,YAAY,GAAG,SAAfA,YAAe,CAACC,KAAD,EAAwC;AAClE,MACEC,IADF,GAiBID,KAjBJ,CACEC,IADF;AAAA,6BAiBID,KAjBJ,CAEEC,IAFF,CAGIC,QAHJ;AAAA,MAIMC,KAJN,wBAIMA,KAJN;AAAA,MAKMC,cALN,wBAKMA,cALN;AAAA,MAMMC,iBANN,wBAMMA,iBANN;AAAA,MAOqBC,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,IAAI,EAAEV;AAAhC,IADrB,CAJF,CAnBF,CADF;AA8BD;;;;"}
@@ -31,11 +31,11 @@ require('../../outOfTheBox/ItemControlledDrilldown/styled.js');
31
31
  require('../../outOfTheBox/ItemSeparator/index.js');
32
32
  require('../../outOfTheBox/ItemWithDate/index.js');
33
33
  require('../../outOfTheBox/ItemWithDate/styled.js');
34
+ require('../../outOfTheBox/ItemTextLabel/index.js');
35
+ require('../../outOfTheBox/ItemTextLabel/styled.js');
34
36
  require('../../outOfTheBox/ItemUncontrolledDrilldown/index.js');
35
37
  require('@babel/runtime/helpers/toConsumableArray');
36
38
  require('../../outOfTheBox/ItemUncontrolledDrilldown/styled.js');
37
- require('../../outOfTheBox/ItemTextLabel/index.js');
38
- require('../../outOfTheBox/ItemTextLabel/styled.js');
39
39
  require('../../outOfTheBox/ItemHeader/index.js');
40
40
  require('../../outOfTheBox/ItemHeader/styled.js');
41
41
  require('../../outOfTheBox/ItemLink/index.js');
@@ -59,6 +59,7 @@ var LeftNavInnerContent = function LeftNavInnerContent() {
59
59
  BodyHeaderComponent = _React$useContext$lef.BodyHeaderComponent,
60
60
  openedItem = _React$useContext$lef.openedItem,
61
61
  items = _React$useContext$lef.items,
62
+ withoutBodyShadow = _React$useContext$lef.withoutBodyShadow,
62
63
  selectedItem = _React$useContext.selectedItem;
63
64
 
64
65
  return /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, /*#__PURE__*/React__default['default'].createElement(parts_LeftNavContent_styled.StyledLeftNavHeaderArea, {
@@ -72,7 +73,7 @@ var LeftNavInnerContent = function LeftNavInnerContent() {
72
73
  }, BodyHeaderComponent ? /*#__PURE__*/React__default['default'].createElement(parts_OutOfTheBoxMapItem.OutOfTheBoxMapItem, {
73
74
  item: BodyHeaderComponent
74
75
  }) : null), /*#__PURE__*/React__default['default'].createElement(parts_LeftNavContent_styled.StyledLeftNavBodyItemsArea, {
75
- selected: openedItem !== null,
76
+ selected: !withoutBodyShadow && openedItem !== null,
76
77
  "data-testid": "leftnav-body-items-area",
77
78
  tabIndex: -1
78
79
  }, /*#__PURE__*/React__default['default'].createElement(parts_LeftNavContentWithScrollbar_index.LeftNavContentWithScrollbar, null, items.map(function (item) {
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../../src/parts/LeftNavContent/index.tsx"],"sourcesContent":["import React from 'react';\nimport { LeftNavContext } from '../../LeftNavigationContext';\nimport { LeftNavFooterItem } from '../LeftNavFooterItem';\nimport { LeftNavContentWithScrollbar } from '../LeftNavContentWithScrollbar';\nimport { OutOfTheBoxMapItem } from '../OutOfTheBoxMapItem';\nimport {\n StyledLeftNavExpandAnimationWrapper,\n StyledLeftNavAreasContainer,\n StyledLeftNavHeaderArea,\n StyledLeftNavBodyAreasContainer,\n StyledLeftNavBodyHeaderArea,\n StyledLeftNavBodyItemsArea,\n StyledLeftNavFooterArea,\n} from './styled';\nimport { LeftNavLoading } from '../LeftNavLoading';\n\nconst leftNavScreenReaderInstructions =\n 'Left Navigation. You can navigate through the items using the Up/Down arrows. ' +\n 'To expand or select an item, use the Enter/Return or Space keys. ' +\n 'Expandable items can also be opened/closed with the Right/Left arrows. ' +\n 'The Home and End keys will take you to the first and last item respectively.';\n\nconst LeftNavInnerContent = () => {\n const {\n leftNavProps: { HeaderComponent, BodyHeaderComponent, openedItem, items },\n selectedItem,\n } = React.useContext(LeftNavContext);\n return (\n <>\n <StyledLeftNavHeaderArea\n data-testid=\"leftnav-header-area\"\n selected={HeaderComponent && [selectedItem, openedItem].includes(HeaderComponent.dsId)}\n >\n {HeaderComponent ? <OutOfTheBoxMapItem item={HeaderComponent} /> : null}\n </StyledLeftNavHeaderArea>\n <StyledLeftNavBodyAreasContainer>\n <StyledLeftNavBodyHeaderArea\n data-testid=\"leftnav-body-header-area\"\n selected={BodyHeaderComponent && [selectedItem, openedItem].includes(BodyHeaderComponent.dsId)}\n >\n {BodyHeaderComponent ? <OutOfTheBoxMapItem item={BodyHeaderComponent} /> : null}\n </StyledLeftNavBodyHeaderArea>\n <StyledLeftNavBodyItemsArea selected={openedItem !== null} data-testid=\"leftnav-body-items-area\" tabIndex={-1}>\n <LeftNavContentWithScrollbar>\n {items.map((item) => (\n <OutOfTheBoxMapItem item={item} key={item.dsId} />\n ))}\n </LeftNavContentWithScrollbar>\n </StyledLeftNavBodyItemsArea>\n </StyledLeftNavBodyAreasContainer>\n </>\n );\n};\n\nconst LeftNavContent: React.ComponentType = () => {\n const {\n expandedForAnimation,\n leftNavProps: { expanded, expandedWidth, footerLabel, onFooterExpand, onFooterClose, loading },\n } = React.useContext(LeftNavContext);\n\n return (\n <StyledLeftNavExpandAnimationWrapper\n expandedWidth={expandedWidth}\n expanded={expanded}\n data-testid=\"leftnav-component\"\n aria-label={leftNavScreenReaderInstructions}\n >\n <StyledLeftNavAreasContainer expandedWidth={expandedWidth} expanded={expandedForAnimation}>\n {loading && <LeftNavLoading expanded={expandedForAnimation} />}\n {!loading && <LeftNavInnerContent />}\n <StyledLeftNavFooterArea>\n <LeftNavFooterItem footerLabel={footerLabel} onFooterExpand={onFooterExpand} onFooterClose={onFooterClose} />\n </StyledLeftNavFooterArea>\n </StyledLeftNavAreasContainer>\n </StyledLeftNavExpandAnimationWrapper>\n );\n};\n\nexport default LeftNavContent;\n"],"names":["leftNavScreenReaderInstructions","LeftNavInnerContent","React","useContext","LeftNavContext","leftNavProps","HeaderComponent","BodyHeaderComponent","openedItem","items","selectedItem","StyledLeftNavHeaderArea","includes","dsId","OutOfTheBoxMapItem","StyledLeftNavBodyAreasContainer","StyledLeftNavBodyHeaderArea","StyledLeftNavBodyItemsArea","LeftNavContentWithScrollbar","map","item","LeftNavContent","expandedForAnimation","expanded","expandedWidth","footerLabel","onFooterExpand","onFooterClose","loading","StyledLeftNavExpandAnimationWrapper","StyledLeftNavAreasContainer","LeftNavLoading","StyledLeftNavFooterArea","LeftNavFooterItem"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;A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,CAPF,CAPF,CADF;AAyBD,CA9BD;;IAgCMQ,cAAmC,GAAG,SAAtCA,cAAsC,GAAM;AAChD,2BAGInB,yBAAK,CAACC,UAAN,CAAiBC,oCAAjB,CAHJ;AAAA,MACEkB,oBADF,sBACEA,oBADF;AAAA,iDAEEjB,YAFF;AAAA,MAEkBkB,QAFlB,yBAEkBA,QAFlB;AAAA,MAE4BC,aAF5B,yBAE4BA,aAF5B;AAAA,MAE2CC,WAF3C,yBAE2CA,WAF3C;AAAA,MAEwDC,cAFxD,yBAEwDA,cAFxD;AAAA,MAEwEC,aAFxE,yBAEwEA,aAFxE;AAAA,MAEuFC,OAFvF,yBAEuFA,OAFvF;;AAKA,sBACE1B,wCAAC2B,+DAAD;AACE,IAAA,aAAa,EAAEL,aADjB;AAEE,IAAA,QAAQ,EAAED,QAFZ;AAGE,mBAAY,mBAHd;AAIE,kBAAYvB;AAJd,kBAMEE,wCAAC4B,uDAAD;AAA6B,IAAA,aAAa,EAAEN,aAA5C;AAA2D,IAAA,QAAQ,EAAEF;AAArE,KACGM,OAAO,iBAAI1B,wCAAC6B,yCAAD;AAAgB,IAAA,QAAQ,EAAET;AAA1B,IADd,EAEG,CAACM,OAAD,iBAAY1B,wCAAC,mBAAD,OAFf,eAGEA,wCAAC8B,mDAAD,qBACE9B,wCAAC+B,+CAAD;AAAmB,IAAA,WAAW,EAAER,WAAhC;AAA6C,IAAA,cAAc,EAAEC,cAA7D;AAA6E,IAAA,aAAa,EAAEC;AAA5F,IADF,CAHF,CANF,CADF;AAgBD;;;;"}
1
+ {"version":3,"file":"index.js","sources":["../../../../src/parts/LeftNavContent/index.tsx"],"sourcesContent":["import React from 'react';\nimport { LeftNavContext } from '../../LeftNavigationContext';\nimport { LeftNavFooterItem } from '../LeftNavFooterItem';\nimport { LeftNavContentWithScrollbar } from '../LeftNavContentWithScrollbar';\nimport { OutOfTheBoxMapItem } from '../OutOfTheBoxMapItem';\nimport {\n StyledLeftNavExpandAnimationWrapper,\n StyledLeftNavAreasContainer,\n StyledLeftNavHeaderArea,\n StyledLeftNavBodyAreasContainer,\n StyledLeftNavBodyHeaderArea,\n StyledLeftNavBodyItemsArea,\n StyledLeftNavFooterArea,\n} from './styled';\nimport { LeftNavLoading } from '../LeftNavLoading';\n\nconst leftNavScreenReaderInstructions =\n 'Left Navigation. You can navigate through the items using the Up/Down arrows. ' +\n 'To expand or select an item, use the Enter/Return or Space keys. ' +\n 'Expandable items can also be opened/closed with the Right/Left arrows. ' +\n 'The Home and End keys will take you to the first and last item respectively.';\n\nconst LeftNavInnerContent = () => {\n const {\n leftNavProps: { HeaderComponent, BodyHeaderComponent, openedItem, items, withoutBodyShadow },\n selectedItem,\n } = React.useContext(LeftNavContext);\n return (\n <>\n <StyledLeftNavHeaderArea\n data-testid=\"leftnav-header-area\"\n selected={HeaderComponent && [selectedItem, openedItem].includes(HeaderComponent.dsId)}\n >\n {HeaderComponent ? <OutOfTheBoxMapItem item={HeaderComponent} /> : null}\n </StyledLeftNavHeaderArea>\n <StyledLeftNavBodyAreasContainer>\n <StyledLeftNavBodyHeaderArea\n data-testid=\"leftnav-body-header-area\"\n selected={BodyHeaderComponent && [selectedItem, openedItem].includes(BodyHeaderComponent.dsId)}\n >\n {BodyHeaderComponent ? <OutOfTheBoxMapItem item={BodyHeaderComponent} /> : null}\n </StyledLeftNavBodyHeaderArea>\n <StyledLeftNavBodyItemsArea\n selected={!withoutBodyShadow && openedItem !== null}\n data-testid=\"leftnav-body-items-area\"\n tabIndex={-1}\n >\n <LeftNavContentWithScrollbar>\n {items.map((item) => (\n <OutOfTheBoxMapItem item={item} key={item.dsId} />\n ))}\n </LeftNavContentWithScrollbar>\n </StyledLeftNavBodyItemsArea>\n </StyledLeftNavBodyAreasContainer>\n </>\n );\n};\n\nconst LeftNavContent: React.ComponentType = () => {\n const {\n expandedForAnimation,\n leftNavProps: { expanded, expandedWidth, footerLabel, onFooterExpand, onFooterClose, loading },\n } = React.useContext(LeftNavContext);\n\n return (\n <StyledLeftNavExpandAnimationWrapper\n expandedWidth={expandedWidth}\n expanded={expanded}\n data-testid=\"leftnav-component\"\n aria-label={leftNavScreenReaderInstructions}\n >\n <StyledLeftNavAreasContainer expandedWidth={expandedWidth} expanded={expandedForAnimation}>\n {loading && <LeftNavLoading expanded={expandedForAnimation} />}\n {!loading && <LeftNavInnerContent />}\n <StyledLeftNavFooterArea>\n <LeftNavFooterItem footerLabel={footerLabel} onFooterExpand={onFooterExpand} onFooterClose={onFooterClose} />\n </StyledLeftNavFooterArea>\n </StyledLeftNavAreasContainer>\n </StyledLeftNavExpandAnimationWrapper>\n );\n};\n\nexport default LeftNavContent;\n"],"names":["leftNavScreenReaderInstructions","LeftNavInnerContent","React","useContext","LeftNavContext","leftNavProps","HeaderComponent","BodyHeaderComponent","openedItem","items","withoutBodyShadow","selectedItem","StyledLeftNavHeaderArea","includes","dsId","OutOfTheBoxMapItem","StyledLeftNavBodyAreasContainer","StyledLeftNavBodyHeaderArea","StyledLeftNavBodyItemsArea","LeftNavContentWithScrollbar","map","item","LeftNavContent","expandedForAnimation","expanded","expandedWidth","footerLabel","onFooterExpand","onFooterClose","loading","StyledLeftNavExpandAnimationWrapper","StyledLeftNavAreasContainer","LeftNavLoading","StyledLeftNavFooterArea","LeftNavFooterItem"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgBA,IAAMA,+BAA+B,GACnC,mFACA,mEADA,GAEA,yEAFA,GAGA,8EAJF;;AAMA,IAAMC,mBAAmB,GAAG,SAAtBA,mBAAsB,GAAM;AAChC,0BAGIC,yBAAK,CAACC,UAAN,CAAiBC,oCAAjB,CAHJ;AAAA,gDACEC,YADF;AAAA,MACkBC,eADlB,yBACkBA,eADlB;AAAA,MACmCC,mBADnC,yBACmCA,mBADnC;AAAA,MACwDC,UADxD,yBACwDA,UADxD;AAAA,MACoEC,KADpE,yBACoEA,KADpE;AAAA,MAC2EC,iBAD3E,yBAC2EA,iBAD3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A,MAEwDC,cAFxD,yBAEwDA,cAFxD;AAAA,MAEwEC,aAFxE,yBAEwEA,aAFxE;AAAA,MAEuFC,OAFvF,yBAEuFA,OAFvF;;AAKA,sBACE3B,wCAAC4B,+DAAD;AACE,IAAA,aAAa,EAAEL,aADjB;AAEE,IAAA,QAAQ,EAAED,QAFZ;AAGE,mBAAY,mBAHd;AAIE,kBAAYxB;AAJd,kBAMEE,wCAAC6B,uDAAD;AAA6B,IAAA,aAAa,EAAEN,aAA5C;AAA2D,IAAA,QAAQ,EAAEF;AAArE,KACGM,OAAO,iBAAI3B,wCAAC8B,yCAAD;AAAgB,IAAA,QAAQ,EAAET;AAA1B,IADd,EAEG,CAACM,OAAD,iBAAY3B,wCAAC,mBAAD,OAFf,eAGEA,wCAAC+B,mDAAD,qBACE/B,wCAACgC,+CAAD;AAAmB,IAAA,WAAW,EAAER,WAAhC;AAA6C,IAAA,cAAc,EAAEC,cAA7D;AAA6E,IAAA,aAAa,EAAEC;AAA5F,IADF,CAHF,CANF,CADF;AAgBD;;;;"}
@@ -21,11 +21,11 @@ require('../outOfTheBox/ItemControlledDrilldown/styled.js');
21
21
  require('../outOfTheBox/ItemSeparator/index.js');
22
22
  require('../outOfTheBox/ItemWithDate/index.js');
23
23
  require('../outOfTheBox/ItemWithDate/styled.js');
24
+ require('../outOfTheBox/ItemTextLabel/index.js');
25
+ require('../outOfTheBox/ItemTextLabel/styled.js');
24
26
  require('../outOfTheBox/ItemUncontrolledDrilldown/index.js');
25
27
  require('@babel/runtime/helpers/toConsumableArray');
26
28
  require('../outOfTheBox/ItemUncontrolledDrilldown/styled.js');
27
- require('../outOfTheBox/ItemTextLabel/index.js');
28
- require('../outOfTheBox/ItemTextLabel/styled.js');
29
29
  require('../outOfTheBox/ItemHeader/index.js');
30
30
  require('../outOfTheBox/ItemHeader/styled.js');
31
31
  require('../outOfTheBox/ItemLink/index.js');
package/cjs/prop-types.js CHANGED
@@ -22,11 +22,11 @@ require('./outOfTheBox/ItemControlledDrilldown/styled.js');
22
22
  require('./outOfTheBox/ItemSeparator/index.js');
23
23
  require('./outOfTheBox/ItemWithDate/index.js');
24
24
  require('./outOfTheBox/ItemWithDate/styled.js');
25
+ require('./outOfTheBox/ItemTextLabel/index.js');
26
+ require('./outOfTheBox/ItemTextLabel/styled.js');
25
27
  require('./outOfTheBox/ItemUncontrolledDrilldown/index.js');
26
28
  require('@babel/runtime/helpers/toConsumableArray');
27
29
  require('./outOfTheBox/ItemUncontrolledDrilldown/styled.js');
28
- require('./outOfTheBox/ItemTextLabel/index.js');
29
- require('./outOfTheBox/ItemTextLabel/styled.js');
30
30
  require('./outOfTheBox/ItemHeader/index.js');
31
31
  require('./outOfTheBox/ItemHeader/styled.js');
32
32
  require('./outOfTheBox/ItemLink/index.js');
@@ -62,7 +62,8 @@ var leftNavigationProps = {
62
62
  onFocusChange: reactDesc.PropTypes.func.description('A callback which triggers when the focused item changes').defaultValue(function () {
63
63
  return null;
64
64
  }),
65
- items: reactDesc.PropTypes.arrayOf(reactDesc.PropTypes.object).description('The array of items you want to render inside the left nav').defaultValue([])
65
+ items: reactDesc.PropTypes.arrayOf(reactDesc.PropTypes.object).description('The array of items you want to render inside the left nav').defaultValue([]),
66
+ disableDefaultSelection: reactDesc.PropTypes.bool.description('Whether you do not want to automatically select the first body item').defaultValue(false)
66
67
  };
67
68
 
68
69
  var LeftNavItemProps = function LeftNavItemProps() {
@@ -1 +1 @@
1
- {"version":3,"file":"prop-types.js","sources":["../../src/prop-types.tsx"],"sourcesContent":["import { PropTypes, describe } from 'react-desc';\nimport { outOfTheBoxTypes } from './outOfTheBox';\n\nexport const leftNavItemProps = {\n type: PropTypes.oneOf(outOfTheBoxTypes).description('out of the box types'),\n dsId: PropTypes.string.description('unique identifier for the left nav item'),\n Component: PropTypes.func.description(\n \"A custom component, receives the item as prop. This is used only when type is not defined or doesn't matches any out-of-the-box\",\n ),\n CollapsedComponent: PropTypes.func.description(\n 'A component which is renderer when the left-nav is collapsed',\n ),\n itemOpts: PropTypes.object.description('Item options'),\n};\n\nexport const leftNavigationProps = {\n containerProps: PropTypes.shape({ expandedWidth: PropTypes.string })\n .description('Set of Properties attached to the main container')\n .defaultValue({ expandedWidth: '240px' }),\n expanded: PropTypes.bool\n .description('Whether to show the left navigation expanded or collapsed')\n .defaultValue(false),\n loading: PropTypes.bool\n .description('Whether the left-nav is loading')\n .defaultValue(false),\n tabIndex: PropTypes.number.description('Tab index').defaultValue(0),\n openedItem: PropTypes.string\n .description('The id of the left navigation item you want to be opened')\n .defaultValue(null),\n footerLabel: PropTypes.string.description(\n 'The label to show in the footer item',\n ),\n onFooterExpand: PropTypes.func.description(\n 'The function to call when the left-nav is opened via the footer',\n ),\n onFooterClose: PropTypes.func.description(\n 'The function to call when the left-nav is closed via the footer',\n ),\n onSelectedChange: PropTypes.func\n .description('A callback which triggers when the selected item changes')\n .defaultValue(() => null),\n onFocusChange: PropTypes.func\n .description('A callback which triggers when the focused item changes')\n .defaultValue(() => null),\n items: PropTypes.arrayOf(PropTypes.object)\n .description('The array of items you want to render inside the left nav')\n .defaultValue([]),\n};\n\nconst LeftNavItemProps = () => null;\nexport const LeftNavItemPropsSchema = describe(LeftNavItemProps);\nLeftNavItemPropsSchema.propTypes = leftNavItemProps;\n\nconst LeftNavItemOptions = () => null;\nexport const LeftNavItemOptionsSchema = describe(LeftNavItemOptions);\nLeftNavItemOptionsSchema.propTypes = leftNavItemProps;\n"],"names":["leftNavItemProps","type","PropTypes","oneOf","outOfTheBoxTypes","description","dsId","string","Component","func","CollapsedComponent","itemOpts","object","leftNavigationProps","containerProps","shape","expandedWidth","defaultValue","expanded","bool","loading","tabIndex","number","openedItem","footerLabel","onFooterExpand","onFooterClose","onSelectedChange","onFocusChange","items","arrayOf","LeftNavItemProps","LeftNavItemPropsSchema","describe","propTypes","LeftNavItemOptions","LeftNavItemOptionsSchema"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAGaA,gBAAgB,GAAG;A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Af,CACd,iEADc,CAjBiB;AAoBjCqB,EAAAA,aAAa,EAAExB,mBAAS,CAACO,IAAV,CAAeJ,WAAf,CACb,iEADa,CApBkB;AAuBjCsB,EAAAA,gBAAgB,EAAEzB,mBAAS,CAACO,IAAV,CACfJ,WADe,CACH,0DADG,EAEfY,YAFe,CAEF;AAAA,WAAM,IAAN;AAAA,GAFE,CAvBe;AA0BjCW,EAAAA,aAAa,EAAE1B,mBAAS,CAACO,IAAV,CACZJ,WADY,CACA,yDADA,EAEZY,YAFY,CAEC;AAAA,WAAM,IAAN;AAAA,GAFD,CA1BkB;AA6BjCY,EAAAA,KAAK,EAAE3B,mBAAS,CAAC4B,OAAV,CAAkB5B,mBAAS,CAACU,MAA5B,EACJP,WADI,CACQ,2DADR,EAEJY,YAFI,CAES,EAFT;AA7B0B;;AAkCnC,IAAMc,gBAAgB,GAAG,SAAnBA,gBAAmB;AAAA,SAAM,IAAN;AAAA,CAAzB;;IACaC,sBAAsB,GAAGC,kBAAQ,CAACF,gBAAD;AAC9CC,sBAAsB,CAACE,SAAvB,GAAmClC,gBAAnC;;AAEA,IAAMmC,kBAAkB,GAAG,SAArBA,kBAAqB;AAAA,SAAM,IAAN;AAAA,CAA3B;;IACaC,wBAAwB,GAAGH,kBAAQ,CAACE,kBAAD;AAChDC,wBAAwB,CAACF,SAAzB,GAAqClC,gBAArC;;;;;;;"}
1
+ {"version":3,"file":"prop-types.js","sources":["../../src/prop-types.tsx"],"sourcesContent":["import { PropTypes, describe } from 'react-desc';\nimport { outOfTheBoxTypes } from './outOfTheBox';\n\nexport const leftNavItemProps = {\n type: PropTypes.oneOf(outOfTheBoxTypes).description('out of the box types'),\n dsId: PropTypes.string.description('unique identifier for the left nav item'),\n Component: PropTypes.func.description(\n \"A custom component, receives the item as prop. This is used only when type is not defined or doesn't matches any out-of-the-box\",\n ),\n CollapsedComponent: PropTypes.func.description('A component which is renderer when the left-nav is collapsed'),\n itemOpts: PropTypes.object.description('Item options'),\n};\n\nexport const leftNavigationProps = {\n containerProps: PropTypes.shape({ expandedWidth: PropTypes.string })\n .description('Set of Properties attached to the main container')\n .defaultValue({ expandedWidth: '240px' }),\n expanded: PropTypes.bool.description('Whether to show the left navigation expanded or collapsed').defaultValue(false),\n loading: PropTypes.bool.description('Whether the left-nav is loading').defaultValue(false),\n tabIndex: PropTypes.number.description('Tab index').defaultValue(0),\n openedItem: PropTypes.string\n .description('The id of the left navigation item you want to be opened')\n .defaultValue(null),\n footerLabel: PropTypes.string.description('The label to show in the footer item'),\n onFooterExpand: PropTypes.func.description('The function to call when the left-nav is opened via the footer'),\n onFooterClose: PropTypes.func.description('The function to call when the left-nav is closed via the footer'),\n onSelectedChange: PropTypes.func\n .description('A callback which triggers when the selected item changes')\n .defaultValue(() => null),\n onFocusChange: PropTypes.func\n .description('A callback which triggers when the focused item changes')\n .defaultValue(() => null),\n items: PropTypes.arrayOf(PropTypes.object)\n .description('The array of items you want to render inside the left nav')\n .defaultValue([]),\n disableDefaultSelection: PropTypes.bool\n .description('Whether you do not want to automatically select the first body item')\n .defaultValue(false),\n};\n\nconst LeftNavItemProps = () => null;\nexport const LeftNavItemPropsSchema = describe(LeftNavItemProps);\nLeftNavItemPropsSchema.propTypes = leftNavItemProps;\n\nconst LeftNavItemOptions = () => null;\nexport const LeftNavItemOptionsSchema = describe(LeftNavItemOptions);\nLeftNavItemOptionsSchema.propTypes = leftNavItemProps;\n"],"names":["leftNavItemProps","type","PropTypes","oneOf","outOfTheBoxTypes","description","dsId","string","Component","func","CollapsedComponent","itemOpts","object","leftNavigationProps","containerProps","shape","expandedWidth","defaultValue","expanded","bool","loading","tabIndex","number","openedItem","footerLabel","onFooterExpand","onFooterClose","onSelectedChange","onFocusChange","items","arrayOf","disableDefaultSelection","LeftNavItemProps","LeftNavItemPropsSchema","describe","propTypes","LeftNavItemOptions","LeftNavItemOptionsSchema"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAGaA,gBAAgB,GAAG;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AAS,CAACO,IAAV,CAAeJ,WAAf,CAA2B,iEAA3B,CAXiB;AAYjCqB,EAAAA,aAAa,EAAExB,mBAAS,CAACO,IAAV,CAAeJ,WAAf,CAA2B,iEAA3B,CAZkB;AAajCsB,EAAAA,gBAAgB,EAAEzB,mBAAS,CAACO,IAAV,CACfJ,WADe,CACH,0DADG,EAEfY,YAFe,CAEF;AAAA,WAAM,IAAN;AAAA,GAFE,CAbe;AAgBjCW,EAAAA,aAAa,EAAE1B,mBAAS,CAACO,IAAV,CACZJ,WADY,CACA,yDADA,EAEZY,YAFY,CAEC;AAAA,WAAM,IAAN;AAAA,GAFD,CAhBkB;AAmBjCY,EAAAA,KAAK,EAAE3B,mBAAS,CAAC4B,OAAV,CAAkB5B,mBAAS,CAACU,MAA5B,EACJP,WADI,CACQ,2DADR,EAEJY,YAFI,CAES,EAFT,CAnB0B;AAsBjCc,EAAAA,uBAAuB,EAAE7B,mBAAS,CAACiB,IAAV,CACtBd,WADsB,CACV,qEADU,EAEtBY,YAFsB,CAET,KAFS;AAtBQ;;AA2BnC,IAAMe,gBAAgB,GAAG,SAAnBA,gBAAmB;AAAA,SAAM,IAAN;AAAA,CAAzB;;IACaC,sBAAsB,GAAGC,kBAAQ,CAACF,gBAAD;AAC9CC,sBAAsB,CAACE,SAAvB,GAAmCnC,gBAAnC;;AAEA,IAAMoC,kBAAkB,GAAG,SAArBA,kBAAqB;AAAA,SAAM,IAAN;AAAA,CAA3B;;IACaC,wBAAwB,GAAGH,kBAAQ,CAACE,kBAAD;AAChDC,wBAAwB,CAACF,SAAzB,GAAqCnC,gBAArC;;;;;;;"}
@@ -21,11 +21,11 @@ import './outOfTheBox/ItemControlledDrilldown/styled.js';
21
21
  import './outOfTheBox/ItemSeparator/index.js';
22
22
  import './outOfTheBox/ItemWithDate/index.js';
23
23
  import './outOfTheBox/ItemWithDate/styled.js';
24
+ import './outOfTheBox/ItemTextLabel/index.js';
25
+ import './outOfTheBox/ItemTextLabel/styled.js';
24
26
  import './outOfTheBox/ItemUncontrolledDrilldown/index.js';
25
27
  import '@babel/runtime/helpers/esm/toConsumableArray';
26
28
  import './outOfTheBox/ItemUncontrolledDrilldown/styled.js';
27
- import './outOfTheBox/ItemTextLabel/index.js';
28
- import './outOfTheBox/ItemTextLabel/styled.js';
29
29
  import './outOfTheBox/ItemHeader/index.js';
30
30
  import './outOfTheBox/ItemHeader/styled.js';
31
31
  import './outOfTheBox/ItemLink/index.js';
@@ -80,7 +80,7 @@ var useLeftNavConfig = function useLeftNavConfig(props) {
80
80
  React.useEffect(function () {
81
81
  onFocusChange(focusedItem);
82
82
  }, [focusedItem, onFocusChange]);
83
- useSelectFirstBodyItem(items, openedItem, props.selectedItem !== undefined ? props.selectedItem : selectedItem, setSelectedItem); // -----------------------------------------------------------------------------
83
+ useSelectFirstBodyItem(items, openedItem, props.selectedItem !== undefined ? props.selectedItem : selectedItem, setSelectedItem, props.disableDefaultSelection); // -----------------------------------------------------------------------------
84
84
  // ************************** ------------ **************************
85
85
  // * ITEMS MANAGEMENT *
86
86
  // ************************** ------------ **************************
@@ -1 +1 @@
1
- {"version":3,"file":"useLeftNavConfig.js","sources":["../../../src/configs/useLeftNavConfig.tsx"],"sourcesContent":["import React from 'react';\nimport type { LeftNavProps } from '../index.d';\nimport { ContextProps } from '../LeftNavigationContext';\nimport useLeftNavItems from './useLeftNavItems';\nimport { useLeftNavSmoothExpand } from './useLeftNavSmoothExpand';\nimport { useSelectFirstBodyItem } from '../hooks/useSelectFirstBodyItem';\n\nexport const useLeftNavConfig = (props: LeftNavProps): ContextProps => {\n const { expanded, openedItem, onSelectedChange, onFocusChange, items } = props;\n\n // -----------------------------------------------------------------------------\n // ************************** ------------ **************************\n // * INTERNAL STATE *\n // ************************** ------------ **************************\n // Selection related\n const [selectedItem, setSelectedItem] = React.useState(null);\n const [selectedSubitem, setSelectedSubitem] = React.useState(null);\n const [selectedParent, setSelectedParent] = React.useState(null);\n // Focus related\n const [focusedItem, setFocusedItem] = React.useState(null);\n // Opened uncontrolled drilldowns\n const [openedDrilldowns, setOpenedDrilldowns] = React.useState<string[]>([]);\n\n // -----------------------------------------------------------------------------\n // ************************** ------------ **************************\n // * EXPAND ANIMATION *\n // ************************** ------------ **************************\n const [expandedForAnimation, setExpandedForAnimation] = React.useState(expanded);\n const timeoutRef = React.useRef<ReturnType<typeof setTimeout>>(null);\n const smoothExpandOpts = React.useMemo(\n () => ({\n expandedForAnimation,\n timeoutRef,\n setExpandedForAnimation,\n }),\n [expandedForAnimation, timeoutRef, setExpandedForAnimation],\n );\n useLeftNavSmoothExpand(props, smoothExpandOpts);\n\n // -----------------------------------------------------------------------------\n // ************************** ------------ **************************\n // * SIDE EFFECTS *\n // ************************** ------------ **************************\n React.useEffect(() => {\n onSelectedChange(selectedItem);\n }, [selectedItem, onSelectedChange]);\n\n React.useEffect(() => {\n if (openedItem !== null) setSelectedParent(openedItem);\n }, [openedItem]);\n\n React.useEffect(() => {\n onFocusChange(focusedItem);\n }, [focusedItem, onFocusChange]);\n\n useSelectFirstBodyItem(\n items,\n openedItem,\n props.selectedItem !== undefined ? props.selectedItem : selectedItem,\n setSelectedItem,\n );\n\n // -----------------------------------------------------------------------------\n // ************************** ------------ **************************\n // * ITEMS MANAGEMENT *\n // ************************** ------------ **************************\n\n const leftNavItemsProps = React.useMemo(\n () => ({\n headerItem: props.HeaderComponent,\n bodyHeaderItem: props.BodyHeaderComponent,\n items: props.items,\n openedDrilldowns,\n }),\n [props.HeaderComponent, props.BodyHeaderComponent, props.items, openedDrilldowns],\n );\n // We need to know the current visible items since we have drilldowns\n const { visibleItems, visibleItemsRefs } = useLeftNavItems(leftNavItemsProps);\n\n // -----------------------------------------------------------------------------\n // ************************** ------------ **************************\n // * LEFTNAV CONFIG *\n // ************************** ------------ **************************\n const finalConfig = React.useMemo(\n () => ({\n leftNavProps: props,\n expandedForAnimation,\n selectedItem: props.selectedItem !== undefined ? props.selectedItem : selectedItem,\n setSelectedItem,\n selectedParent: props.selectedParent !== undefined ? props.selectedParent : selectedParent,\n setSelectedParent,\n focusedItem,\n setFocusedItem,\n openedDrilldowns,\n setOpenedDrilldowns,\n visibleItems,\n visibleItemsRefs,\n }),\n [\n props,\n expandedForAnimation,\n selectedItem,\n setSelectedItem,\n setSelectedParent,\n selectedParent,\n focusedItem,\n setFocusedItem,\n openedDrilldowns,\n setOpenedDrilldowns,\n visibleItems,\n visibleItemsRefs,\n ],\n );\n\n return finalConfig;\n};\n\nexport default useLeftNavConfig;\n"],"names":["useLeftNavConfig","props","expanded","openedItem","onSelectedChange","onFocusChange","items","React","useState","selectedItem","setSelectedItem","selectedParent","setSelectedParent","focusedItem","setFocusedItem","openedDrilldowns","setOpenedDrilldowns","expandedForAnimation","setExpandedForAnimation","timeoutRef","useRef","smoothExpandOpts","useMemo","useLeftNavSmoothExpand","useEffect","useSelectFirstBodyItem","undefined","leftNavItemsProps","headerItem","HeaderComponent","bodyHeaderItem","BodyHeaderComponent","useLeftNavItems","visibleItems","visibleItemsRefs","finalConfig","leftNavProps"],"mappings":";;;;;;;;;;;;;IAOaA,gBAAgB,GAAG,SAAnBA,gBAAmB,CAACC,KAAD,EAAuC;AACrE,MAAQC,QAAR,GAAyED,KAAzE,CAAQC,QAAR;AAAA,MAAkBC,UAAlB,GAAyEF,KAAzE,CAAkBE,UAAlB;AAAA,MAA8BC,gBAA9B,GAAyEH,KAAzE,CAA8BG,gBAA9B;AAAA,MAAgDC,aAAhD,GAAyEJ,KAAzE,CAAgDI,aAAhD;AAAA,MAA+DC,KAA/D,GAAyEL,KAAzE,CAA+DK,KAA/D,CADqE;AAIrE;AACA;AACA;AACA;;AACA,wBAAwCC,KAAK,CAACC,QAAN,CAAe,IAAf,CAAxC;AAAA;AAAA,MAAOC,YAAP;AAAA,MAAqBC,eAArB;;AACA,yBAA8CH,KAAK,CAACC,QAAN,CAAe,IAAf,CAA9C;AAAA;AAAA;AAAA;;AACA,yBAA4CD,KAAK,CAACC,QAAN,CAAe,IAAf,CAA5C;AA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ASLC,MAAAA,gBAAgB,EAAhBA,gBATK;AAULC,MAAAA,mBAAmB,EAAnBA,mBAVK;AAWLiB,MAAAA,YAAY,EAAZA,YAXK;AAYLC,MAAAA,gBAAgB,EAAhBA;AAZK,KAAP;AAAA,GADkB,EAelB,CACEjC,KADF,EAEEgB,oBAFF,EAGER,YAHF,EAIEC,eAJF,EAKEE,iBALF,EAMED,cANF,EAOEE,WAPF,EAQEC,cARF,EASEC,gBATF,EAUEC,mBAVF,EAWEiB,YAXF,EAYEC,gBAZF,CAfkB,CAApB;AA+BA,SAAOC,WAAP;AACD;;;;"}
1
+ {"version":3,"file":"useLeftNavConfig.js","sources":["../../../src/configs/useLeftNavConfig.tsx"],"sourcesContent":["import React from 'react';\nimport type { LeftNavProps } from '../index.d';\nimport { ContextProps } from '../LeftNavigationContext';\nimport useLeftNavItems from './useLeftNavItems';\nimport { useLeftNavSmoothExpand } from './useLeftNavSmoothExpand';\nimport { useSelectFirstBodyItem } from '../hooks/useSelectFirstBodyItem';\n\nexport const useLeftNavConfig = (props: LeftNavProps): ContextProps => {\n const { expanded, openedItem, onSelectedChange, onFocusChange, items } = props;\n\n // -----------------------------------------------------------------------------\n // ************************** ------------ **************************\n // * INTERNAL STATE *\n // ************************** ------------ **************************\n // Selection related\n const [selectedItem, setSelectedItem] = React.useState(null);\n const [selectedSubitem, setSelectedSubitem] = React.useState(null);\n const [selectedParent, setSelectedParent] = React.useState(null);\n // Focus related\n const [focusedItem, setFocusedItem] = React.useState(null);\n // Opened uncontrolled drilldowns\n const [openedDrilldowns, setOpenedDrilldowns] = React.useState<string[]>([]);\n\n // -----------------------------------------------------------------------------\n // ************************** ------------ **************************\n // * EXPAND ANIMATION *\n // ************************** ------------ **************************\n const [expandedForAnimation, setExpandedForAnimation] = React.useState(expanded);\n const timeoutRef = React.useRef<ReturnType<typeof setTimeout>>(null);\n const smoothExpandOpts = React.useMemo(\n () => ({\n expandedForAnimation,\n timeoutRef,\n setExpandedForAnimation,\n }),\n [expandedForAnimation, timeoutRef, setExpandedForAnimation],\n );\n useLeftNavSmoothExpand(props, smoothExpandOpts);\n\n // -----------------------------------------------------------------------------\n // ************************** ------------ **************************\n // * SIDE EFFECTS *\n // ************************** ------------ **************************\n React.useEffect(() => {\n onSelectedChange(selectedItem);\n }, [selectedItem, onSelectedChange]);\n\n React.useEffect(() => {\n if (openedItem !== null) setSelectedParent(openedItem);\n }, [openedItem]);\n\n React.useEffect(() => {\n onFocusChange(focusedItem);\n }, [focusedItem, onFocusChange]);\n\n useSelectFirstBodyItem(\n items,\n openedItem,\n props.selectedItem !== undefined ? props.selectedItem : selectedItem,\n setSelectedItem,\n props.disableDefaultSelection,\n );\n\n // -----------------------------------------------------------------------------\n // ************************** ------------ **************************\n // * ITEMS MANAGEMENT *\n // ************************** ------------ **************************\n\n const leftNavItemsProps = React.useMemo(\n () => ({\n headerItem: props.HeaderComponent,\n bodyHeaderItem: props.BodyHeaderComponent,\n items: props.items,\n openedDrilldowns,\n }),\n [props.HeaderComponent, props.BodyHeaderComponent, props.items, openedDrilldowns],\n );\n\n // We need to know the current visible items since we have drilldowns\n const { visibleItems, visibleItemsRefs } = useLeftNavItems(leftNavItemsProps);\n\n // -----------------------------------------------------------------------------\n // ************************** ------------ **************************\n // * LEFTNAV CONFIG *\n // ************************** ------------ **************************\n const finalConfig = React.useMemo(\n () => ({\n leftNavProps: props,\n expandedForAnimation,\n selectedItem: props.selectedItem !== undefined ? props.selectedItem : selectedItem,\n setSelectedItem,\n selectedParent: props.selectedParent !== undefined ? props.selectedParent : selectedParent,\n setSelectedParent,\n focusedItem,\n setFocusedItem,\n openedDrilldowns,\n setOpenedDrilldowns,\n visibleItems,\n visibleItemsRefs,\n }),\n [\n props,\n expandedForAnimation,\n selectedItem,\n setSelectedItem,\n setSelectedParent,\n selectedParent,\n focusedItem,\n setFocusedItem,\n openedDrilldowns,\n setOpenedDrilldowns,\n visibleItems,\n visibleItemsRefs,\n ],\n );\n\n return finalConfig;\n};\n\nexport default useLeftNavConfig;\n"],"names":["useLeftNavConfig","props","expanded","openedItem","onSelectedChange","onFocusChange","items","React","useState","selectedItem","setSelectedItem","selectedParent","setSelectedParent","focusedItem","setFocusedItem","openedDrilldowns","setOpenedDrilldowns","expandedForAnimation","setExpandedForAnimation","timeoutRef","useRef","smoothExpandOpts","useMemo","useLeftNavSmoothExpand","useEffect","useSelectFirstBodyItem","undefined","disableDefaultSelection","leftNavItemsProps","headerItem","HeaderComponent","bodyHeaderItem","BodyHeaderComponent","useLeftNavItems","visibleItems","visibleItemsRefs","finalConfig","leftNavProps"],"mappings":";;;;;;;;;;;;;IAOaA,gBAAgB,GAAG,SAAnBA,gBAAmB,CAACC,KAAD,EAAuC;AACrE,MAAQC,QAAR,GAAyED,KAAzE,CAAQC,QAAR;AAAA,MAAkBC,UAAlB,GAAyEF,KAAzE,CAAkBE,UAAlB;AAAA,MAA8BC,gBAA9B,GAAyEH,KAAzE,CAA8BG,gBAA9B;AAAA,MAAgDC,aAAhD,GAAyEJ,KAAzE,CAAgDI,aAAhD;AAAA,MAA+DC,KAA/D,GAAyEL,KAAzE,CAA+DK,KAA/D,CADqE;AAIrE;AACA;AACA;AACA;;AACA,wBAAwCC,KAAK,CAACC,QAAN,CAAe,IAAf,CAAxC;AAAA;AAAA,MAAOC,YAAP;AAAA,MAAqBC,eAArB;;AACA,yBAA8CH,KAAK,CAACC,QAAN,CAAe,IAAf,CAA9C;AAAA;AAAA;AAAA;;AACA,yBAA4CD,KAAK,CAACC,QAAN,CAAe,IAAf,CAA5C;AAAA;AAAA,MAAOG,cAAP;AAAA,MAAuBC,iBAAvB,uBAVqE;;;AAYrE,yBAAsCL,KAAK,CAACC,QAAN,CAAe,IAAf,CAAtC;AAAA;AAAA,MAAOK,WAAP;AAAA,MAAoBC,cAApB,uBAZqE;;;AAcrE,yBAAgDP,KAAK,CAACC,QAAN,CAAyB,EAAzB,CAAhD;AAAA;AAAA,MAAOO,gBAAP;AAAA,MAAyBC,mBAAzB,wBAd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E,WAPF,EAQEC,cARF,EASEC,gBATF,EAUEC,mBAVF,EAWEkB,YAXF,EAYEC,gBAZF,CAfkB,CAApB;AA+BA,SAAOC,WAAP;AACD;;;;"}
@@ -68,14 +68,14 @@ var ItemRenderer = function ItemRenderer(props) {
68
68
  }
69
69
 
70
70
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(StyledItemWrapper, {
71
- shadowStyle: shadowStyle,
71
+ shadowStyle: shadowStyle(opened, item.type),
72
72
  "data-testid": "leftnav-item-wrapper"
73
73
  }, /*#__PURE__*/React.createElement(StyledItem, {
74
74
  ref: visibleItemsRefs.current[dsId],
75
75
  pt: paddingTop,
76
76
  pl: indent === undefined ? 'xxxs' : "".concat(indent, "px"),
77
77
  minHeight: minHeight,
78
- shadowStyle: shadowStyle,
78
+ shadowStyle: shadowStyle(opened, item.type),
79
79
  alignItems: "flex-start",
80
80
  cols: cols,
81
81
  onClick: !opened ? handleOnClick : function () {
@@ -92,6 +92,8 @@ var ItemRenderer = function ItemRenderer(props) {
92
92
  "aria-describedby": ariaDescribedBy,
93
93
  "aria-expanded": ariaExpanded,
94
94
  role: ariaRole,
95
+ "data-selected": isSelected,
96
+ "data-selectedparent": selectedParent === dsId,
95
97
  "aria-label": ariaLabel,
96
98
  "aria-hidden": !focuseable,
97
99
  "aria-live": ariaLive
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../../src/exported-related/ItemRenderer/index.tsx"],"sourcesContent":["/* eslint-disable complexity */\n/* eslint-disable max-lines */\nimport React, { useContext, useMemo, useCallback } from 'react';\nimport Grid from '@elliemae/ds-grid';\nimport { StyledItemWrapper, StyledItem } from './styled';\n\nimport { ItemRendererT } from '../../index.d';\nimport { LeftNavContext } from '../../LeftNavigationContext';\nimport { usePropsWithDefaults } from './usePropsWithDefaults';\nimport { useKeyboardNavigation } from '../../hooks';\n\nexport const ItemRenderer = (props: ItemRendererT): JSX.Element => {\n const propsWithDefault = usePropsWithDefaults(props);\n const {\n item,\n item: {\n dsId,\n itemOpts: { selectable, focuseable, indent, ariaLabel, ariaRole, ariaLive, ariaExpanded, ariaDescribedBy },\n CollapsedComponent,\n },\n subitems,\n minHeight,\n paddingTop,\n onClick,\n shadowStyle,\n hasBorderBottom,\n borderBottomMr,\n children,\n } = propsWithDefault;\n\n const ctx = useContext(LeftNavContext);\n const {\n leftNavProps: { onItemClick, openedItem },\n expandedForAnimation,\n selectedParent,\n selectedItem,\n setSelectedItem,\n setFocusedItem,\n visibleItemsRefs,\n } = ctx;\n\n const opened = dsId === openedItem;\n\n const handleOnClick = useCallback(\n (e) => {\n if (onClick) onClick(); // used by uncontrolled drilldowns\n onItemClick(item, e);\n if (selectable) setSelectedItem(item.dsId);\n },\n [onItemClick, item, setSelectedItem, selectable, onClick],\n );\n\n const handleFocus = useCallback(() => {\n if (focuseable) setFocusedItem(dsId);\n }, [dsId, setFocusedItem, focuseable]);\n\n const onKeyDown = useKeyboardNavigation({\n item,\n onClick: handleOnClick,\n });\n\n const cols = useMemo(() => (expandedForAnimation ? ['auto', '1fr', 'auto'] : ['38px']), [expandedForAnimation]);\n const isSelected = useMemo(() => selectedItem === dsId, [selectedItem, dsId]);\n\n if (!expandedForAnimation && !CollapsedComponent) {\n return null;\n }\n\n return (\n <>\n <StyledItemWrapper shadowStyle={shadowStyle} data-testid=\"leftnav-item-wrapper\">\n <StyledItem\n ref={visibleItemsRefs.current[dsId]}\n pt={paddingTop}\n pl={indent === undefined ? 'xxxs' : `${indent}px`}\n minHeight={minHeight}\n shadowStyle={shadowStyle}\n alignItems=\"flex-start\"\n cols={cols}\n onClick={!opened ? handleOnClick : () => null}\n onKeyDown={onKeyDown}\n selectable={selectable}\n selected={isSelected}\n selectedParent={selectedParent === dsId}\n opened={opened}\n onFocus={handleFocus}\n data-testid=\"leftnav-item-container\"\n tabIndex={focuseable ? 0 : -1}\n aria-describedby={ariaDescribedBy}\n aria-expanded={ariaExpanded}\n role={ariaRole}\n aria-label={ariaLabel}\n aria-hidden={!focuseable}\n aria-live={ariaLive}\n >\n {!expandedForAnimation ? (\n <Grid data-testid=\"leftnav-leftcomponent\" justifyContent=\"center\">\n <CollapsedComponent item={item} ctx={ctx} />\n </Grid>\n ) : (\n children\n )}\n </StyledItem>\n {hasBorderBottom && (\n <div\n style={{\n marginLeft: opened ? '16px' : '0px',\n marginRight: borderBottomMr,\n height: '1px',\n width: `calc(100% - ${borderBottomMr} - ${opened ? '16px' : '0px'})`,\n backgroundColor: '#E0E3E8',\n }}\n />\n )}\n </StyledItemWrapper>\n {subitems}\n </>\n );\n};\n"],"names":["ItemRenderer","props","propsWithDefault","usePropsWithDefaults","item","dsId","itemOpts","selectable","focuseable","indent","ariaLabel","ariaRole","ariaLive","ariaExpanded","ariaDescribedBy","CollapsedComponent","subitems","minHeight","paddingTop","onClick","shadowStyle","hasBorderBottom","borderBottomMr","children","ctx","useContext","LeftNavContext","leftNavProps","onItemClick","openedItem","expandedForAnimation","selectedParent","selectedItem","setSelectedItem","setFocusedItem","visibleItemsRefs","opened","handleOnClick","useCallback","e","handleFocus","onKeyDown","useKeyboardNavigation","cols","useMemo","isSelected","current","undefined","marginLeft","marginRight","height","width","backgroundColor"],"mappings":";;;;;;;;;;AAAA;IAWaA,YAAY,GAAG,SAAfA,YAAe,CAACC,KAAD,EAAuC;AACjE,MAAMC,gBAAgB,GAAGC,oBAAoB,CAACF,KAAD,CAA7C;AACA,MACEG,IADF,GAeIF,gBAfJ,CACEE,IADF;AAAA,8BAeIF,gBAfJ,CAEEE,IAFF;AAAA,MAGIC,IAHJ,yBAGIA,IAHJ;AAAA,qDAIIC,QAJJ;AAAA,MAIgBC,UAJhB,0BAIgBA,UAJhB;AAAA,MAI4BC,UAJ5B,0BAI4BA,UAJ5B;AAAA,MAIwCC,MAJxC,0BAIwCA,MAJxC;AAAA,MAIgDC,SAJhD,0BAIgDA,SAJhD;AAAA,MAI2DC,QAJ3D,0BAI2DA,QAJ3D;AAAA,MAIqEC,QAJrE,0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,EAAE,CAACP,MAAD,GAAUC,aAAV,GAA0B;AAAA,aAAM,IAAN;AAAA,KARrC;AASE,IAAA,SAAS,EAAEI,SATb;AAUE,IAAA,UAAU,EAAElC,UAVd;AAWE,IAAA,QAAQ,EAAEsC,UAXZ;AAYE,IAAA,cAAc,EAAEd,cAAc,KAAK1B,IAZrC;AAaE,IAAA,MAAM,EAAE+B,MAbV;AAcE,IAAA,OAAO,EAAEI,WAdX;AAeE,mBAAY,wBAfd;AAgBE,IAAA,QAAQ,EAAEhC,UAAU,GAAG,CAAH,GAAO,CAAC,CAhB9B;AAiBE,wBAAkBM,eAjBpB;AAkBE,qBAAeD,YAlBjB;AAmBE,IAAA,IAAI,EAAEF,QAnBR;AAoBE,kBAAYD,SApBd;AAqBE,mBAAa,CAACF,UArBhB;AAsBE,iBAAWI;AAtBb,KAwBG,CAACkB,oBAAD,gBACC,oBAAC,IAAD;AAAM,mBAAY,uBAAlB;AAA0C,IAAA,cAAc,EAAC;AAAzD,kBACE,oBAAC,kBAAD;AAAoB,IAAA,IAAI,EAAE1B,IAA1B;AAAgC,IAAA,GAAG,EAAEoB;AAArC,IADF,CADD,GAKCD,QA7BJ,CADF,EAiCGF,eAAe,iBACd;AACE,IAAA,KAAK,EAAE;AACL2B,MAAAA,UAAU,EAAEZ,MAAM,GAAG,MAAH,GAAY,KADzB;AAELa,MAAAA,WAAW,EAAE3B,cAFR;AAGL4B,MAAAA,MAAM,EAAE,KAHH;AAILC,MAAAA,KAAK,wBAAiB7B,cAAjB,gBAAqCc,MAAM,GAAG,MAAH,GAAY,KAAvD,MAJA;AAKLgB,MAAAA,eAAe,EAAE;AALZ;AADT,IAlCJ,CADF,EA8CGpC,QA9CH,CADF;AAkDD;;;;"}
1
+ {"version":3,"file":"index.js","sources":["../../../../src/exported-related/ItemRenderer/index.tsx"],"sourcesContent":["/* eslint-disable complexity */\n/* eslint-disable max-lines */\nimport React, { useContext, useMemo, useCallback } from 'react';\nimport Grid from '@elliemae/ds-grid';\nimport { StyledItemWrapper, StyledItem } from './styled';\n\nimport { ItemRendererT } from '../../index.d';\nimport { LeftNavContext } from '../../LeftNavigationContext';\nimport { usePropsWithDefaults } from './usePropsWithDefaults';\nimport { useKeyboardNavigation } from '../../hooks';\n\nexport const ItemRenderer = (props: ItemRendererT): JSX.Element => {\n const propsWithDefault = usePropsWithDefaults(props);\n const {\n item,\n item: {\n dsId,\n itemOpts: { selectable, focuseable, indent, ariaLabel, ariaRole, ariaLive, ariaExpanded, ariaDescribedBy },\n CollapsedComponent,\n },\n subitems,\n minHeight,\n paddingTop,\n onClick,\n shadowStyle,\n hasBorderBottom,\n borderBottomMr,\n children,\n } = propsWithDefault;\n\n const ctx = useContext(LeftNavContext);\n const {\n leftNavProps: { onItemClick, openedItem },\n expandedForAnimation,\n selectedParent,\n selectedItem,\n setSelectedItem,\n setFocusedItem,\n visibleItemsRefs,\n } = ctx;\n\n const opened = dsId === openedItem;\n\n const handleOnClick = useCallback(\n (e) => {\n if (onClick) onClick(); // used by uncontrolled drilldowns\n onItemClick(item, e);\n if (selectable) setSelectedItem(item.dsId);\n },\n [onItemClick, item, setSelectedItem, selectable, onClick],\n );\n\n const handleFocus = useCallback(() => {\n if (focuseable) setFocusedItem(dsId);\n }, [dsId, setFocusedItem, focuseable]);\n\n const onKeyDown = useKeyboardNavigation({\n item,\n onClick: handleOnClick,\n });\n\n const cols = useMemo(() => (expandedForAnimation ? ['auto', '1fr', 'auto'] : ['38px']), [expandedForAnimation]);\n const isSelected = useMemo(() => selectedItem === dsId, [selectedItem, dsId]);\n\n if (!expandedForAnimation && !CollapsedComponent) {\n return null;\n }\n\n return (\n <>\n <StyledItemWrapper shadowStyle={shadowStyle(opened, item.type)} data-testid=\"leftnav-item-wrapper\">\n <StyledItem\n ref={visibleItemsRefs.current[dsId]}\n pt={paddingTop}\n pl={indent === undefined ? 'xxxs' : `${indent}px`}\n minHeight={minHeight}\n shadowStyle={shadowStyle(opened, item.type)}\n alignItems=\"flex-start\"\n cols={cols}\n onClick={!opened ? handleOnClick : () => null}\n onKeyDown={onKeyDown}\n selectable={selectable}\n selected={isSelected}\n selectedParent={selectedParent === dsId}\n opened={opened}\n onFocus={handleFocus}\n data-testid=\"leftnav-item-container\"\n tabIndex={focuseable ? 0 : -1}\n aria-describedby={ariaDescribedBy}\n aria-expanded={ariaExpanded}\n role={ariaRole}\n data-selected={isSelected}\n data-selectedparent={selectedParent===dsId}\n aria-label={ariaLabel}\n aria-hidden={!focuseable}\n aria-live={ariaLive}\n >\n {!expandedForAnimation ? (\n <Grid data-testid=\"leftnav-leftcomponent\" justifyContent=\"center\">\n <CollapsedComponent item={item} ctx={ctx} />\n </Grid>\n ) : (\n children\n )}\n </StyledItem>\n {hasBorderBottom && (\n <div\n style={{\n marginLeft: opened ? '16px' : '0px',\n marginRight: borderBottomMr,\n height: '1px',\n width: `calc(100% - ${borderBottomMr} - ${opened ? '16px' : '0px'})`,\n backgroundColor: '#E0E3E8',\n }}\n />\n )}\n </StyledItemWrapper>\n {subitems}\n </>\n );\n};\n"],"names":["ItemRenderer","props","propsWithDefault","usePropsWithDefaults","item","dsId","itemOpts","selectable","focuseable","indent","ariaLabel","ariaRole","ariaLive","ariaExpanded","ariaDescribedBy","CollapsedComponent","subitems","minHeight","paddingTop","onClick","shadowStyle","hasBorderBottom","borderBottomMr","children","ctx","useContext","LeftNavContext","leftNavProps","onItemClick","openedItem","expandedForAnimation","selectedParent","selectedItem","setSelectedItem","setFocusedItem","visibleItemsRefs","opened","handleOnClick","useCallback","e","handleFocus","onKeyDown","useKeyboardNavigation","cols","useMemo","isSelected","type","current","undefined","marginLeft","marginRight","height","width","backgroundColor"],"mappings":";;;;;;;;;;AAAA;IAWaA,YAAY,GAAG,SAAfA,YAAe,CAACC,KAAD,EAAuC;AACjE,MAAMC,gBAAgB,GAAGC,oBAAoB,CAACF,KAAD,CAA7C;AACA,MACEG,IADF,GAeIF,gBAfJ,CACEE,IADF;AAAA,8BAeIF,gBAfJ,CAEEE,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,UAAU,EAAEb,MAAM,GAAG,MAAH,GAAY,KADzB;AAELc,MAAAA,WAAW,EAAE5B,cAFR;AAGL6B,MAAAA,MAAM,EAAE,KAHH;AAILC,MAAAA,KAAK,wBAAiB9B,cAAjB,gBAAqCc,MAAM,GAAG,MAAH,GAAY,KAAvD,MAJA;AAKLiB,MAAAA,eAAe,EAAE;AALZ;AADT,IApCJ,CADF,EAgDGrC,QAhDH,CADF;AAoDD;;;;"}
@@ -16,7 +16,8 @@ var itemDefaultProps = {
16
16
  ariaLive: 'off',
17
17
  ariaExpanded: undefined,
18
18
  ariaDescribedBy: undefined
19
- }; // Make use Item props with defaults
19
+ };
20
+ var itemWithoutShadows = ['ds-left-nav-item-header', 'ds-left-nav-item-link', 'ds-left-nav-item-submenu']; // Make use Item props with defaults
20
21
 
21
22
  var usePropsWithDefaults = function usePropsWithDefaults(props) {
22
23
  var propsWithDefault = useMemo(function () {
@@ -32,8 +33,10 @@ var usePropsWithDefaults = function usePropsWithDefaults(props) {
32
33
  minHeight: '48px',
33
34
  paddingTop: '12px',
34
35
  subitems: [],
35
- shadowStyle: function shadowStyle() {
36
- return 'box-shadow: inherit';
36
+ shadowStyle: function shadowStyle(opened, type) {
37
+ return function (theme) {
38
+ return "box-shadow: ".concat(opened || !itemWithoutShadows.includes(type) ? 'inset 4px 0 0 0 #52A6EC' : 'inset 4px 0 0 0 white');
39
+ };
37
40
  },
38
41
  hasBorderBottom: false,
39
42
  borderBottomMr: '0px'
@@ -1 +1 @@
1
- {"version":3,"file":"usePropsWithDefaults.js","sources":["../../../../src/exported-related/ItemRenderer/usePropsWithDefaults.tsx"],"sourcesContent":["import { useMemo } from 'react';\nimport { itemOptsT, ItemRendererT } from '../../index.d';\n\nconst itemDefaultProps: itemOptsT = {\n label: '',\n labelOverflow: 'truncate',\n selectable: true,\n focuseable: true,\n openable: false,\n closable: false,\n ariaLabel: '',\n ariaRole: 'menuitem',\n ariaLive: 'off',\n ariaExpanded: undefined,\n ariaDescribedBy: undefined,\n};\n\n// Make use Item props with defaults\n\nexport const usePropsWithDefaults = (props: ItemRendererT): ItemRendererT => {\n const propsWithDefault = useMemo(() => {\n const itemWithDefaults = {\n CollapsedComponent: () => null,\n ...props.item,\n itemOpts: { ...itemDefaultProps, ...props.item.itemOpts },\n };\n return {\n minHeight: '48px',\n paddingTop: '12px',\n subitems: [],\n shadowStyle: () => 'box-shadow: inherit',\n hasBorderBottom: false,\n borderBottomMr: '0px',\n ...props,\n item: itemWithDefaults,\n };\n }, [props]);\n\n return propsWithDefault;\n};\n"],"names":["itemDefaultProps","label","labelOverflow","selectable","focuseable","openable","closable","ariaLabel","ariaRole","ariaLive","ariaExpanded","undefined","ariaDescribedBy","usePropsWithDefaults","props","propsWithDefault","useMemo","itemWithDefaults","CollapsedComponent","item","itemOpts","minHeight","paddingTop","subitems","shadowStyle","hasBorderBottom","borderBottomMr"],"mappings":";;;;;;AAGA,IAAMA,gBAA2B,GAAG;AAClCC,EAAAA,KAAK,EAAE,EAD2B;AAElCC,EAAAA,aAAa,EAAE,UAFmB;AAGlCC,EAAAA,UAAU,EAAE,IAHsB;AAIlCC,EAAAA,UAAU,EAAE,IAJsB;AAKlCC,EAAAA,QAAQ,EAAE,KALwB;AAMlCC,EAAAA,QAAQ,EAAE,KANwB;AAOlCC,EAAAA,SAAS,EAAE,EAPuB;AAQlCC,EAAAA,QAAQ,EAAE,UARwB;AASlCC,EAAAA,QAAQ,EAAE,KATwB;AAUlCC,EAAAA,YAAY,EAAEC,SAVoB;AAWlCC,EAAAA,eAAe,EAAED;AAXiB,CAApC;;IAgBaE,oBAAoB,GAAG,SAAvBA,oBAAuB,CAACC,KAAD,EAAyC;AAC3E,MAAMC,gBAAgB,GAAGC,OAAO,CAAC,YAAM;AACrC,QAAMC,gBAAgB;AACpBC,MAAAA,kBAAkB,EAAE;AAAA,eAAM,IAAN;AAAA;AADA,OAEjBJ,KAAK,CAACK,IAFW;AAGpBC,MAAAA,QAAQ,kCAAOpB,gBAAP,GAA4Bc,KAAK,CAACK,IAAN,CAAWC,QAAvC;AAHY,MAAtB;;AAKA;AACEC,MAAAA,SAAS,EAAE,MADb;AAEEC,MAAAA,UAAU,EAAE,MAFd;AAGEC,MAAAA,QAAQ,EAAE,EAHZ;AAIEC,MAAAA,WAAW,EAAE;AAAA,eAAM,qBAAN;AAAA,OAJf;AAKEC,MAAAA,eAAe,EAAE,KALnB;AAMEC,MAAAA,cAAc,EAAE;AANlB,OAOKZ,KAPL;AAQEK,MAAAA,IAAI,EAAEF;AARR;AAUD,GAhB+B,EAgB7B,CAACH,KAAD,CAhB6B,CAAhC;AAkBA,SAAOC,gBAAP;AACD;;;;"}
1
+ {"version":3,"file":"usePropsWithDefaults.js","sources":["../../../../src/exported-related/ItemRenderer/usePropsWithDefaults.tsx"],"sourcesContent":["import { useMemo } from 'react';\nimport { itemOptsT, ItemRendererT } from '../../index.d';\n\nconst itemDefaultProps: itemOptsT = {\n label: '',\n labelOverflow: 'truncate',\n selectable: true,\n focuseable: true,\n openable: false,\n closable: false,\n ariaLabel: '',\n ariaRole: 'menuitem',\n ariaLive: 'off',\n ariaExpanded: undefined,\n ariaDescribedBy: undefined,\n};\n\nconst itemWithoutShadows = ['ds-left-nav-item-header', 'ds-left-nav-item-link', 'ds-left-nav-item-submenu'];\n\n// Make use Item props with defaults\nexport const usePropsWithDefaults = (props: ItemRendererT): ItemRendererT => {\n const propsWithDefault = useMemo(() => {\n const itemWithDefaults = {\n CollapsedComponent: () => null,\n ...props.item,\n itemOpts: { ...itemDefaultProps, ...props.item.itemOpts },\n };\n return {\n minHeight: '48px',\n paddingTop: '12px',\n subitems: [],\n shadowStyle: (opened: boolean, type: string) => (theme: any) =>\n `box-shadow: ${\n opened || !itemWithoutShadows.includes(type) ? 'inset 4px 0 0 0 #52A6EC' : 'inset 4px 0 0 0 white'\n }`,\n hasBorderBottom: false,\n borderBottomMr: '0px',\n ...props,\n item: itemWithDefaults,\n };\n }, [props]);\n\n return propsWithDefault;\n};\n"],"names":["itemDefaultProps","label","labelOverflow","selectable","focuseable","openable","closable","ariaLabel","ariaRole","ariaLive","ariaExpanded","undefined","ariaDescribedBy","itemWithoutShadows","usePropsWithDefaults","props","propsWithDefault","useMemo","itemWithDefaults","CollapsedComponent","item","itemOpts","minHeight","paddingTop","subitems","shadowStyle","opened","type","theme","includes","hasBorderBottom","borderBottomMr"],"mappings":";;;;;;AAGA,IAAMA,gBAA2B,GAAG;AAClCC,EAAAA,KAAK,EAAE,EAD2B;AAElCC,EAAAA,aAAa,EAAE,UAFmB;AAGlCC,EAAAA,UAAU,EAAE,IAHsB;AAIlCC,EAAAA,UAAU,EAAE,IAJsB;AAKlCC,EAAAA,QAAQ,EAAE,KALwB;AAMlCC,EAAAA,QAAQ,EAAE,KANwB;AAOlCC,EAAAA,SAAS,EAAE,EAPuB;AAQlCC,EAAAA,QAAQ,EAAE,UARwB;AASlCC,EAAAA,QAAQ,EAAE,KATwB;AAUlCC,EAAAA,YAAY,EAAEC,SAVoB;AAWlCC,EAAAA,eAAe,EAAED;AAXiB,CAApC;AAcA,IAAME,kBAAkB,GAAG,CAAC,yBAAD,EAA4B,uBAA5B,EAAqD,0BAArD,CAA3B;;IAGaC,oBAAoB,GAAG,SAAvBA,oBAAuB,CAACC,KAAD,EAAyC;AAC3E,MAAMC,gBAAgB,GAAGC,OAAO,CAAC,YAAM;AACrC,QAAMC,gBAAgB;AACpBC,MAAAA,kBAAkB,EAAE;AAAA,eAAM,IAAN;AAAA;AADA,OAEjBJ,KAAK,CAACK,IAFW;AAGpBC,MAAAA,QAAQ,kCAAOrB,gBAAP,GAA4Be,KAAK,CAACK,IAAN,CAAWC,QAAvC;AAHY,MAAtB;;AAKA;AACEC,MAAAA,SAAS,EAAE,MADb;AAEEC,MAAAA,UAAU,EAAE,MAFd;AAGEC,MAAAA,QAAQ,EAAE,EAHZ;AAIEC,MAAAA,WAAW,EAAE,qBAACC,MAAD,EAAkBC,IAAlB;AAAA,eAAmC,UAACC,KAAD;AAAA,uCAE5CF,MAAM,IAAI,CAACb,kBAAkB,CAACgB,QAAnB,CAA4BF,IAA5B,CAAX,GAA+C,yBAA/C,GAA2E,uBAF/B;AAAA,SAAnC;AAAA,OAJf;AAQEG,MAAAA,eAAe,EAAE,KARnB;AASEC,MAAAA,cAAc,EAAE;AATlB,OAUKhB,KAVL;AAWEK,MAAAA,IAAI,EAAEF;AAXR;AAaD,GAnB+B,EAmB7B,CAACH,KAAD,CAnB6B,CAAhC;AAqBA,SAAOC,gBAAP;AACD;;;;"}
@@ -15,28 +15,32 @@ var Notifications = function Notifications(_ref) {
15
15
  messages = _ref$messages === void 0 ? false : _ref$messages;
16
16
  return /*#__PURE__*/React.createElement(StyledIcon, null, /*#__PURE__*/React.createElement(Notifications$1, {
17
17
  size: "m",
18
- color: ['brand-primary', 800]
18
+ color: ['brand-primary', 800],
19
+ "data-testid": "left-nav-notifications-icon"
19
20
  }), (exceptions || alerts || messages) && /*#__PURE__*/React.createElement(Grid, {
20
21
  cols: ['1fr', '1fr', '1fr'],
21
22
  gutter: "xxxs",
22
23
  mt: "2px"
23
24
  }, /*#__PURE__*/React.createElement(Grid, {
24
25
  width: "6px",
25
- height: "6px"
26
+ height: "6px",
27
+ "data-testid": "left-nav-exceptions-icon"
26
28
  }, exceptions && /*#__PURE__*/React.createElement(ExceptionsSmallFill, {
27
29
  width: "6px",
28
30
  height: "6px",
29
31
  color: ['warning', 900]
30
32
  })), /*#__PURE__*/React.createElement(Grid, {
31
33
  width: "6px",
32
- height: "6px"
34
+ height: "6px",
35
+ "data-testid": "left-nav-alerts-icon"
33
36
  }, alerts && /*#__PURE__*/React.createElement(AlertsSmallFill, {
34
37
  width: "6px",
35
38
  height: "6px",
36
39
  color: ['danger', 900]
37
40
  })), /*#__PURE__*/React.createElement(Grid, {
38
41
  width: "6px",
39
- height: "6px"
42
+ height: "6px",
43
+ "data-testid": "left-nav-messages-icon"
40
44
  }, messages && /*#__PURE__*/React.createElement(MessagesSmallFill, {
41
45
  width: "6px",
42
46
  height: "6px",
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../../src/exported-related/Notifications/index.tsx"],"sourcesContent":["import React from 'react';\nimport {\n AlertsSmallFill,\n Notifications as InternalNotifications,\n ExceptionsSmallFill,\n MessagesSmallFill,\n} from '@elliemae/ds-icons';\nimport styled from 'styled-components';\nimport Grid from '@elliemae/ds-grid';\n\nconst StyledIcon = styled.div`\n display: flex;\n flex-direction: column;\n align-items: center;\n`;\n\ntype NotificationsProps = {\n exceptions?: boolean;\n alerts?: boolean;\n messages?: boolean;\n};\n\nexport const Notifications = ({\n exceptions = false,\n alerts = false,\n messages = false,\n}: NotificationsProps): JSX.Element => (\n <StyledIcon>\n <InternalNotifications size=\"m\" color={['brand-primary', 800]} />\n {(exceptions || alerts || messages) && (\n <Grid cols={['1fr', '1fr', '1fr']} gutter=\"xxxs\" mt=\"2px\">\n <Grid width=\"6px\" height=\"6px\">\n {exceptions && <ExceptionsSmallFill width=\"6px\" height=\"6px\" color={['warning', 900]} />}\n </Grid>\n <Grid width=\"6px\" height=\"6px\">\n {alerts && <AlertsSmallFill width=\"6px\" height=\"6px\" color={['danger', 900]} />}\n </Grid>\n <Grid width=\"6px\" height=\"6px\">\n {messages && <MessagesSmallFill width=\"6px\" height=\"6px\" color={['success', 900]} />}\n </Grid>\n </Grid>\n )}\n </StyledIcon>\n);\n\nexport default Notifications;\n"],"names":["StyledIcon","styled","div","Notifications","exceptions","alerts","messages","InternalNotifications"],"mappings":";;;;;AAUA,IAAMA,UAAU,gBAAGC,MAAM,CAACC,GAAV;AAAA;AAAA,8DAAhB;IAYaC,aAAa,GAAG,SAAhBA,aAAgB;AAAA,6BAC3BC,UAD2B;AAAA,MAC3BA,UAD2B,gCACd,KADc;AAAA,yBAE3BC,MAF2B;AAAA,MAE3BA,MAF2B,4BAElB,KAFkB;AAAA,2BAG3BC,QAH2B;AAAA,MAG3BA,QAH2B,8BAGhB,KAHgB;AAAA,sBAK3B,oBAAC,UAAD,qBACE,oBAACC,eAAD;AAAuB,IAAA,IAAI,EAAC,GAA5B;AAAgC,IAAA,KAAK,EAAE,CAAC,eAAD,EAAkB,GAAlB;AAAvC,IADF,EAEG,CAACH,UAAU,IAAIC,MAAd,IAAwBC,QAAzB,kBACC,oBAAC,IAAD;AAAM,IAAA,IAAI,EAAE,CAAC,KAAD,EAAQ,KAAR,EAAe,KAAf,CAAZ;AAAmC,IAAA,MAAM,EAAC,MAA1C;AAAiD,IAAA,EAAE,EAAC;AAApD,kBACE,oBAAC,IAAD;AAAM,IAAA,KAAK,EAAC,KAAZ;AAAkB,IAAA,MAAM,EAAC;AAAzB,KACGF,UAAU,iBAAI,oBAAC,mBAAD;AAAqB,IAAA,KAAK,EAAC,KAA3B;AAAiC,IAAA,MAAM,EAAC,KAAxC;AAA8C,IAAA,KAAK,EAAE,CAAC,SAAD,EAAY,GAAZ;AAArD,IADjB,CADF,eAIE,oBAAC,IAAD;AAAM,IAAA,KAAK,EAAC,KAAZ;AAAkB,IAAA,MAAM,EAAC;AAAzB,KACGC,MAAM,iBAAI,oBAAC,eAAD;AAAiB,IAAA,KAAK,EAAC,KAAvB;AAA6B,IAAA,MAAM,EAAC,KAApC;AAA0C,IAAA,KAAK,EAAE,CAAC,QAAD,EAAW,GAAX;AAAjD,IADb,CAJF,eAOE,oBAAC,IAAD;AAAM,IAAA,KAAK,EAAC,KAAZ;AAAkB,IAAA,MAAM,EAAC;AAAzB,KACGC,QAAQ,iBAAI,oBAAC,iBAAD;AAAmB,IAAA,KAAK,EAAC,KAAzB;AAA+B,IAAA,MAAM,EAAC,KAAtC;AAA4C,IAAA,KAAK,EAAE,CAAC,SAAD,EAAY,GAAZ;AAAnD,IADf,CAPF,CAHJ,CAL2B;AAAA;;;;"}
1
+ {"version":3,"file":"index.js","sources":["../../../../src/exported-related/Notifications/index.tsx"],"sourcesContent":["import React from 'react';\nimport {\n AlertsSmallFill,\n Notifications as InternalNotifications,\n ExceptionsSmallFill,\n MessagesSmallFill,\n} from '@elliemae/ds-icons';\nimport styled from 'styled-components';\nimport Grid from '@elliemae/ds-grid';\n\nconst StyledIcon = styled.div`\n display: flex;\n flex-direction: column;\n align-items: center;\n`;\n\ntype NotificationsProps = {\n exceptions?: boolean;\n alerts?: boolean;\n messages?: boolean;\n};\n\nexport const Notifications = ({\n exceptions = false,\n alerts = false,\n messages = false,\n}: NotificationsProps): JSX.Element => (\n <StyledIcon>\n <InternalNotifications size=\"m\" color={['brand-primary', 800]} data-testid=\"left-nav-notifications-icon\" />\n {(exceptions || alerts || messages) && (\n <Grid cols={['1fr', '1fr', '1fr']} gutter=\"xxxs\" mt=\"2px\">\n <Grid width=\"6px\" height=\"6px\" data-testid=\"left-nav-exceptions-icon\">\n {exceptions && <ExceptionsSmallFill width=\"6px\" height=\"6px\" color={['warning', 900]} />}\n </Grid>\n <Grid width=\"6px\" height=\"6px\" data-testid=\"left-nav-alerts-icon\">\n {alerts && <AlertsSmallFill width=\"6px\" height=\"6px\" color={['danger', 900]} />}\n </Grid>\n <Grid width=\"6px\" height=\"6px\" data-testid=\"left-nav-messages-icon\">\n {messages && <MessagesSmallFill width=\"6px\" height=\"6px\" color={['success', 900]} />}\n </Grid>\n </Grid>\n )}\n </StyledIcon>\n);\n\nexport default Notifications;\n"],"names":["StyledIcon","styled","div","Notifications","exceptions","alerts","messages","InternalNotifications"],"mappings":";;;;;AAUA,IAAMA,UAAU,gBAAGC,MAAM,CAACC,GAAV;AAAA;AAAA,8DAAhB;IAYaC,aAAa,GAAG,SAAhBA,aAAgB;AAAA,6BAC3BC,UAD2B;AAAA,MAC3BA,UAD2B,gCACd,KADc;AAAA,yBAE3BC,MAF2B;AAAA,MAE3BA,MAF2B,4BAElB,KAFkB;AAAA,2BAG3BC,QAH2B;AAAA,MAG3BA,QAH2B,8BAGhB,KAHgB;AAAA,sBAK3B,oBAAC,UAAD,qBACE,oBAACC,eAAD;AAAuB,IAAA,IAAI,EAAC,GAA5B;AAAgC,IAAA,KAAK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