@elliemae/ds-grid 3.22.0-next.26 → 3.22.0-next.28

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 (33) hide show
  1. package/dist/cjs/DSGridDefinitions.js.map +1 -1
  2. package/dist/cjs/Grid.js.map +1 -1
  3. package/dist/cjs/GridItem.js.map +1 -1
  4. package/dist/cjs/config/useGrid.js.map +1 -1
  5. package/dist/cjs/config/useRenderChildren.js.map +1 -1
  6. package/dist/cjs/config/useValidateProps.js.map +1 -1
  7. package/dist/cjs/index.js.map +1 -1
  8. package/dist/cjs/react-desc-prop-types.js.map +1 -1
  9. package/dist/cjs/utils/constants.js.map +1 -1
  10. package/dist/cjs/utils/manageCols.js +9 -15
  11. package/dist/cjs/utils/manageCols.js.map +3 -3
  12. package/dist/cjs/utils/manageRows.js +9 -15
  13. package/dist/cjs/utils/manageRows.js.map +3 -3
  14. package/dist/cjs/utils/manageSpanParent.js +9 -15
  15. package/dist/cjs/utils/manageSpanParent.js.map +3 -3
  16. package/dist/cjs/utils/styles.js.map +1 -1
  17. package/dist/esm/DSGridDefinitions.js.map +1 -1
  18. package/dist/esm/Grid.js.map +1 -1
  19. package/dist/esm/GridItem.js.map +1 -1
  20. package/dist/esm/config/useGrid.js.map +1 -1
  21. package/dist/esm/config/useRenderChildren.js.map +1 -1
  22. package/dist/esm/config/useValidateProps.js.map +1 -1
  23. package/dist/esm/index.js.map +1 -1
  24. package/dist/esm/react-desc-prop-types.js.map +1 -1
  25. package/dist/esm/utils/constants.js.map +1 -1
  26. package/dist/esm/utils/manageCols.js +9 -15
  27. package/dist/esm/utils/manageCols.js.map +3 -3
  28. package/dist/esm/utils/manageRows.js +9 -15
  29. package/dist/esm/utils/manageRows.js.map +3 -3
  30. package/dist/esm/utils/manageSpanParent.js +9 -15
  31. package/dist/esm/utils/manageSpanParent.js.map +3 -3
  32. package/dist/esm/utils/styles.js.map +1 -1
  33. package/package.json +10 -10
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../src/DSGridDefinitions.tsx", "../../../../scripts/build/transpile/react-shim.js"],
3
+ "sources": ["../../src/DSGridDefinitions.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["export const DSGridName = 'DSGrid';\n", "import * as React from 'react';\nexport { React };\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAhB,MAAM,aAAa;",
6
6
  "names": []
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../src/Grid.tsx", "../../../../scripts/build/transpile/react-shim.js"],
3
+ "sources": ["../../src/Grid.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["import React from 'react';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport type { DSGridT } from './react-desc-prop-types.js';\nimport { DSGridPropTypes } from './react-desc-prop-types.js';\nimport { GridItem } from './GridItem.js';\nimport { useGrid } from './config/useGrid.js';\nimport { DSGridName } from './DSGridDefinitions.js';\n\nconst Grid = React.forwardRef<HTMLDivElement, DSGridT.Props>((props, ref) => {\n const {\n propsWithDefaults: {\n withMaxWidthBreakpoints,\n alignItems,\n cols,\n children,\n rows,\n gutter,\n justify,\n wrap,\n width,\n height,\n ...rest\n },\n globalProps,\n xstyledProps,\n isSpanParent,\n renderChildren,\n } = useGrid(props);\n\n return (\n <GridItem\n alignItems={alignItems}\n cols={cols}\n gutter={gutter}\n isSpanParent={isSpanParent}\n justify={justify}\n rows={rows}\n wrap={wrap}\n childNumber={React.Children.count(children)}\n ref={ref}\n {...rest}\n {...globalProps}\n {...xstyledProps}\n w={width}\n h={height}\n withMaxWidthBreakpoints={withMaxWidthBreakpoints}\n >\n {renderChildren}\n </GridItem>\n );\n});\n\n// Since this component is using ForwardRef, we must provide a displayName to avoid 'undefined' name in propsTable.\nGrid.displayName = DSGridName;\n\nGrid.propTypes = DSGridPropTypes;\nconst DSGridWithSchema = describe(Grid);\nDSGridWithSchema.propTypes = DSGridPropTypes;\n\nexport default Grid;\nexport { DSGridWithSchema, Grid };\n", "import * as React from 'react';\nexport { React };\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;AD8BnB;AA9BJ,mBAAkB;AAClB,8BAAyB;AAEzB,mCAAgC;AAChC,sBAAyB;AACzB,qBAAwB;AACxB,+BAA2B;AAE3B,MAAM,OAAO,aAAAA,QAAM,WAA0C,CAAC,OAAO,QAAQ;AAC3E,QAAM;AAAA,IACJ,mBAAmB;AAAA,MACjB;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,GAAG;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,QAAI,wBAAQ,KAAK;AAEjB,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,aAAa,aAAAA,QAAM,SAAS,MAAM,QAAQ;AAAA,MAC1C;AAAA,MACC,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAG;AAAA,MACJ,GAAG;AAAA,MACH,GAAG;AAAA,MACH;AAAA,MAEC;AAAA;AAAA,EACH;AAEJ,CAAC;AAGD,KAAK,cAAc;AAEnB,KAAK,YAAY;AACjB,MAAM,uBAAmB,kCAAS,IAAI;AACtC,iBAAiB,YAAY;AAE7B,IAAO,eAAQ;",
6
6
  "names": ["React"]
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../src/GridItem.tsx", "../../../../scripts/build/transpile/react-shim.js"],
3
+ "sources": ["../../src/GridItem.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["/* eslint-disable max-lines */\n/* eslint-disable complexity */\nimport {\n styled,\n css,\n mapGap,\n background,\n borders,\n sizing,\n space,\n boxShadows,\n flexboxes,\n grids,\n layout,\n type LayoutProps,\n type SpaceProps,\n type SizingProps,\n} from '@elliemae/ds-system';\nimport { manageSpanParent } from './utils/manageSpanParent.js';\nimport { manageColsV2 } from './utils/manageCols.js';\nimport { manageRowsV2 } from './utils/manageRows.js';\nimport { type DSGridT } from './react-desc-prop-types.js';\nimport { manageCols, manageRows, manageSpan } from './utils/styles.js';\n\nconst gridV2 = css<DSGridT.ItemProps & LayoutProps & SpaceProps & SizingProps>`\n ${manageColsV2}\n ${manageRowsV2}\n ${manageSpanParent}\n`;\n\nconst gridV1 = css`\n ${manageCols}\n ${manageRows}\n ${manageSpan}\n`;\nexport const GridItem = styled.div<DSGridT.ItemProps & LayoutProps & SpaceProps & SizingProps>`\n display: grid;\n display: -ms-grid;\n column-gap: ${({ gutter }) => mapGap(gutter)};\n row-gap: ${({ gutter }) => mapGap(gutter)};\n ${grids}\n ${flexboxes}\n ${sizing}\n ${space}\n ${({ withMaxWidthBreakpoints }) => (withMaxWidthBreakpoints ? gridV2 : gridV1)}\n ${boxShadows}\n ${borders}\n ${background}\n ${layout}\n`;\n", "import * as React from 'react';\nexport { React };\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,uBAeO;AACP,8BAAiC;AACjC,wBAA6B;AAC7B,wBAA6B;AAE7B,oBAAmD;AAEnD,MAAM,SAAS;AAAA,IACX;AAAA,IACA;AAAA,IACA;AAAA;AAGJ,MAAM,SAAS;AAAA,IACX;AAAA,IACA;AAAA,IACA;AAAA;AAEG,MAAM,WAAW,wBAAO;AAAA;AAAA;AAAA,gBAGf,CAAC,EAAE,OAAO,UAAM,yBAAO,MAAM;AAAA,aAChC,CAAC,EAAE,OAAO,UAAM,yBAAO,MAAM;AAAA,IACtC;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA,CAAC,EAAE,wBAAwB,MAAO,0BAA0B,SAAS;AAAA,IACrE;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA;",
6
6
  "names": []
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../src/config/useGrid.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
3
+ "sources": ["../../../src/config/useGrid.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["import { useGetGlobalAttributes, useGetXstyledProps, useMemoMergePropsWithDefault } from '@elliemae/ds-props-helpers';\nimport type { DSGridT } from '../react-desc-prop-types.js';\n// eslint-disable-next-line no-unused-vars\nimport { DSGridPropTypes, defaultProps } from '../react-desc-prop-types.js';\nimport { useRenderChildren } from './useRenderChildren.js';\n// eslint-disable-next-line no-unused-vars\nimport { useValidateProps } from './useValidateProps.js';\n\nexport const useGrid = (props: DSGridT.Props) => {\n const { children, ...propsWithoutChildren } = props;\n\n // =========================================================================\n // MERGE WITH DEFAULT AND VALIDATE PROPS\n // =========================================================================\n const propsWithDefaults = useMemoMergePropsWithDefault<DSGridT.InternalProps>(propsWithoutChildren, defaultProps);\n // children prop create the Maximum call stack size exceeded inside useMemoMergePropsWithDefault\n propsWithDefaults.children = children;\n // useValidateProps(propsWithDefaults, DSGridPropTypes); // TODO @carusox: Uncomment this line when we have the safety\n // ===========================================================================\n // GLOBAL ATTRIBUTES & XSTYLED PROPS\n // ===========================================================================\n const globalProps = useGetGlobalAttributes<DSGridT.InternalProps>(propsWithDefaults);\n const xstyledProps = useGetXstyledProps(propsWithDefaults);\n\n const { isSpanParent, renderChildren } = useRenderChildren(propsWithDefaults);\n\n return { propsWithDefaults, globalProps, xstyledProps, isSpanParent, renderChildren };\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,8BAAyF;AAGzF,mCAA8C;AAC9C,+BAAkC;AAI3B,MAAM,UAAU,CAAC,UAAyB;AAC/C,QAAM,EAAE,UAAU,GAAG,qBAAqB,IAAI;AAK9C,QAAM,wBAAoB,sDAAoD,sBAAsB,yCAAY;AAEhH,oBAAkB,WAAW;AAK7B,QAAM,kBAAc,gDAA8C,iBAAiB;AACnF,QAAM,mBAAe,4CAAmB,iBAAiB;AAEzD,QAAM,EAAE,cAAc,eAAe,QAAI,4CAAkB,iBAAiB;AAE5E,SAAO,EAAE,mBAAmB,aAAa,cAAc,cAAc,eAAe;AACtF;",
6
6
  "names": []
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../src/config/useRenderChildren.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
3
+ "sources": ["../../../src/config/useRenderChildren.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["import React from 'react';\nimport { get } from 'lodash';\nimport { fixSpaceGutter } from '@elliemae/ds-system';\nimport type { DSGridT } from '../react-desc-prop-types.js';\n\nexport const useRenderChildren = (props: DSGridT.InternalProps) => {\n const { children } = props;\n let isSpanParent = true;\n\n const renderChildren = React.Children.map(children, (child: React.ReactNode) => {\n if (\n get(child, 'child.type.name') === 'Grid' ||\n get(child, 'type.displayName') === 'Grid' ||\n parseInt(get(child, 'props.span', '0') as string, 10) > 0\n ) {\n const { width: wc, height: hc, span } = (child as React.ReactElement).props as Required<DSGridT.Props>;\n if (!span) isSpanParent = false;\n // eslint-disable-next-line @typescript-eslint/no-unsafe-argument\n return React.cloneElement(child as React.ReactElement, {\n ...(child as React.ReactElement).props,\n width: fixSpaceGutter(wc),\n height: fixSpaceGutter(hc),\n });\n }\n return child;\n });\n\n return { isSpanParent, renderChildren };\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAAkB;AAClB,oBAAoB;AACpB,uBAA+B;AAGxB,MAAM,oBAAoB,CAAC,UAAiC;AACjE,QAAM,EAAE,SAAS,IAAI;AACrB,MAAI,eAAe;AAEnB,QAAM,iBAAiB,aAAAA,QAAM,SAAS,IAAI,UAAU,CAAC,UAA2B;AAC9E,YACE,mBAAI,OAAO,iBAAiB,MAAM,cAClC,mBAAI,OAAO,kBAAkB,MAAM,UACnC,aAAS,mBAAI,OAAO,cAAc,GAAG,GAAa,EAAE,IAAI,GACxD;AACA,YAAM,EAAE,OAAO,IAAI,QAAQ,IAAI,KAAK,IAAK,MAA6B;AACtE,UAAI,CAAC;AAAM,uBAAe;AAE1B,aAAO,aAAAA,QAAM,aAAa,OAA6B;AAAA,QACrD,GAAI,MAA6B;AAAA,QACjC,WAAO,iCAAe,EAAE;AAAA,QACxB,YAAQ,iCAAe,EAAE;AAAA,MAC3B,CAAC;AAAA,IACH;AACA,WAAO;AAAA,EACT,CAAC;AAED,SAAO,EAAE,cAAc,eAAe;AACxC;",
6
6
  "names": ["React"]
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../src/config/useValidateProps.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
3
+ "sources": ["../../../src/config/useValidateProps.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["import type { WeakValidationMap } from 'react';\nimport { useValidateTypescriptPropTypes } from '@elliemae/ds-props-helpers';\nimport type { DSGridT } from '../react-desc-prop-types.js';\nimport { DSGridName } from '../DSGridDefinitions.js';\n\nexport const useValidateProps = (props: DSGridT.InternalProps, propTypes: WeakValidationMap<unknown>) => {\n useValidateTypescriptPropTypes(props, propTypes, DSGridName);\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADCvB,8BAA+C;AAE/C,+BAA2B;AAEpB,MAAM,mBAAmB,CAAC,OAA8B,cAA0C;AACvG,8DAA+B,OAAO,WAAW,mCAAU;AAC7D;",
6
6
  "names": []
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../src/index.tsx", "../../../../scripts/build/transpile/react-shim.js"],
3
+ "sources": ["../../src/index.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["import type {} from '@xstyled/system';\nimport Grid, { DSGridWithSchema } from './Grid.js';\n\nexport default Grid;\nexport { Grid, Grid as GridContainer, Grid as GridItem, DSGridWithSchema };\n", "import * as React from 'react';\nexport { React };\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA,0BAAAA;AAAA,EAAA,iCAAAA;AAAA,EAAA,4BAAAA;AAAA,EAAA;AAAA;AAAA;ACAA,YAAuB;ADCvB,kBAAuC;AAEvC,IAAO,cAAQ,YAAAC;",
6
6
  "names": ["Grid", "Grid"]
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../src/react-desc-prop-types.tsx", "../../../../scripts/build/transpile/react-shim.js"],
3
+ "sources": ["../../src/react-desc-prop-types.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["import type { WeakValidationMap } from 'react';\nimport type React from 'react';\nimport type {} from '@elliemae/ds-utilities';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-props-helpers';\nimport { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from '@elliemae/ds-props-helpers';\nimport { alignItemsPlacement, justifyPlacement, wrap, boxShadow } from './utils/constants.js';\n\nexport declare namespace DSGridT {\n interface RowColBreakpoints {\n small?: string | number | (string | number)[];\n medium?: string | number | (string | number)[];\n large?: string | number | (string | number)[];\n }\n\n interface SpanBreakpoints {\n small?: number;\n medium?: number;\n large?: number;\n }\n\n type JustifyPlacement = 'flex-start' | 'center' | 'flex-end' | 'space-between' | 'space-around' | 'space-evenly';\n type AlignItemsPlacement = 'flex-start' | 'center' | 'flex-end' | 'stretch' | 'baseline';\n type Wrap = 'wrap' | 'nowrap' | 'wrap-reverse';\n type BoxShadow = 'xs' | 's' | 'm' | 'l' | 'xl';\n\n export interface DefaultProps {\n rows: string[] | string | number[] | RowColBreakpoints;\n cols: string[] | string | number[] | RowColBreakpoints;\n className: string;\n justify: JustifyPlacement;\n gutter: string | number;\n wrap: Wrap;\n span: number;\n justifyItems: string;\n }\n\n export interface OptionalProps {\n height?: string | number;\n width?: string | number;\n justifyContent?: JustifyPlacement;\n alignItems?: AlignItemsPlacement;\n children?: React.ReactNode;\n withMaxWidthBreakpoints?: boolean;\n rowGap?: string | number;\n }\n\n export interface Props\n extends Partial<DefaultProps>,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLDivElement>, keyof DefaultProps | keyof OptionalProps | keyof XstyledProps>,\n XstyledProps {}\n\n export interface InternalProps\n extends DefaultProps,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLDivElement>, keyof DefaultProps | keyof OptionalProps | keyof XstyledProps>,\n XstyledProps {}\n\n export interface ItemProps {\n rows: string[] | string | number[] | RowColBreakpoints;\n cols: string[] | string | number[] | RowColBreakpoints;\n alignItems: AlignItemsPlacement;\n children: React.ReactNode;\n className: string;\n justify: JustifyPlacement;\n gutter: string | number;\n wrap: Wrap;\n childNumber: number;\n isSpanParent: boolean;\n span?: number | SpanBreakpoints;\n ref: React.ForwardedRef<HTMLDivElement>;\n boxShadow?: BoxShadow;\n backgroundColor?: string;\n bg?: string;\n withMaxWidthBreakpoints?: boolean;\n }\n}\n\nexport const defaultProps: DSGridT.DefaultProps = {\n rows: [],\n cols: [],\n className: '',\n justify: 'flex-start',\n gutter: 0,\n wrap: 'wrap',\n span: 1,\n justifyItems: 'normal',\n};\n\n// =============================================================================\n// PropTypes\n// =============================================================================\nconst rowColBreakpoints = PropTypes.shape({\n small: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])),\n medium: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])),\n large: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])),\n});\n\nconst spanBreakpoints = PropTypes.shape({\n small: PropTypes.number,\n medium: PropTypes.number,\n large: PropTypes.number,\n});\n\nexport const DSGridPropTypes = {\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n rows: PropTypes.oneOfType([\n PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])),\n PropTypes.number,\n rowColBreakpoints,\n ])\n .description('Row layout cells')\n .defaultValue([]),\n cols: PropTypes.oneOfType([\n PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])),\n PropTypes.number,\n rowColBreakpoints,\n ])\n .description('Column layout cells')\n .defaultValue([]),\n span: PropTypes.oneOfType([PropTypes.number, spanBreakpoints]).description(\n 'Expands the grid element within columns.',\n ),\n alignItems: PropTypes.oneOf(alignItemsPlacement).description('flex-like align items prop'),\n children: PropTypes.node.description('Children node inside grid cell'),\n className: PropTypes.string.description('CSS class').defaultValue(''),\n justifyContent: PropTypes.oneOf(justifyPlacement)\n .description('flex-like justify prop')\n .defaultValue(justifyPlacement[0]),\n gutter: PropTypes.oneOfType([PropTypes.number, PropTypes.string])\n .description('Space between cells prop')\n .defaultValue(0),\n wrap: PropTypes.oneOf(wrap).description('Wrap type').defaultValue(wrap[0]),\n withMaxWidthBreakpoints: PropTypes.bool.description('weather use max width').defaultValue(undefined),\n height: PropTypes.oneOfType([PropTypes.number, PropTypes.string]).description('Grid height.'),\n width: PropTypes.oneOfType([PropTypes.number, PropTypes.string]).description('Grid width.'),\n backgroundColor: PropTypes.string.description('Sets background color.'),\n bg: PropTypes.string.description('Sets background color.'),\n boxShadow: PropTypes.oneOf(boxShadow).description('Sets background color.'),\n border: PropTypes.string.description('Sets border.'),\n borderRadius: PropTypes.string.description('Sets border radius.'),\n borderWidth: PropTypes.string.description('Sets border width.'),\n borderStyle: PropTypes.string.description('Sets border style.'),\n borderColor: PropTypes.string.description('Sets border color.'),\n borderTop: PropTypes.string.description('Sets top border.'),\n borderBottom: PropTypes.string.description('Sets bottom border.'),\n borderLeft: PropTypes.string.description('Sets left border.'),\n borderRight: PropTypes.string.description('Sets right border.'),\n borderTopWidth: PropTypes.string.description('Sets border top width.'),\n borderTopStyle: PropTypes.string.description('Sets border top style.'),\n borderTopColor: PropTypes.string.description('Sets border top color.'),\n borderBottomWidth: PropTypes.string.description('Sets border bottom width.'),\n borderBottomStyle: PropTypes.string.description('Sets border bottom style.'),\n borderBottomColor: PropTypes.string.description('Sets border bottom color.'),\n borderRightWidth: PropTypes.string.description('Sets border right width.'),\n borderRightStyle: PropTypes.string.description('Sets border right style.'),\n borderRightColor: PropTypes.string.description('Sets border right color.'),\n borderLeftWidth: PropTypes.string.description('Sets border left width.'),\n borderLeftStyle: PropTypes.string.description('Sets border left style.'),\n borderLeftColor: PropTypes.string.description('Sets border left color.'),\n} as WeakValidationMap<unknown>;\n", "import * as React from 'react';\nexport { React };\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADIvB,8BAAuE;AACvE,uBAAuE;AAyEhE,MAAM,eAAqC;AAAA,EAChD,MAAM,CAAC;AAAA,EACP,MAAM,CAAC;AAAA,EACP,WAAW;AAAA,EACX,SAAS;AAAA,EACT,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,MAAM;AAAA,EACN,cAAc;AAChB;AAKA,MAAM,oBAAoB,kCAAU,MAAM;AAAA,EACxC,OAAO,kCAAU,QAAQ,kCAAU,UAAU,CAAC,kCAAU,QAAQ,kCAAU,MAAM,CAAC,CAAC;AAAA,EAClF,QAAQ,kCAAU,QAAQ,kCAAU,UAAU,CAAC,kCAAU,QAAQ,kCAAU,M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YAAY,0BAA0B;AAAA,EACzE,kBAAkB,kCAAU,OAAO,YAAY,0BAA0B;AAAA,EACzE,iBAAiB,kCAAU,OAAO,YAAY,yBAAyB;AAAA,EACvE,iBAAiB,kCAAU,OAAO,YAAY,yBAAyB;AAAA,EACvE,iBAAiB,kCAAU,OAAO,YAAY,yBAAyB;AACzE;",
6
6
  "names": []
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../src/utils/constants.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
3
+ "sources": ["../../../src/utils/constants.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["export const justifyPlacement = ['flex-start', 'center', 'flex-end', 'space-between', 'space-around', 'space-evenly'];\n\nexport const alignItemsPlacement = ['flex-start', 'center', 'flex-end', 'stretch', 'baseline'];\n\nexport const wrap = ['wrap', 'nowrap', 'wrap-reverse'];\n\nexport const boxShadow = ['xs', 's', 'm', 'l', 'xl'];\n", "import * as React from 'react';\nexport { React };\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAhB,MAAM,mBAAmB,CAAC,cAAc,UAAU,YAAY,iBAAiB,gBAAgB,cAAc;AAE7G,MAAM,sBAAsB,CAAC,cAAc,UAAU,YAAY,WAAW,UAAU;AAEtF,MAAM,OAAO,CAAC,QAAQ,UAAU,cAAc;AAE9C,MAAM,YAAY,CAAC,MAAM,KAAK,KAAK,KAAK,IAAI;",
6
6
  "names": []
@@ -59,11 +59,9 @@ const generateColsWithMediaQueries = (cols, theme, isSpanParent) => {
59
59
  }
60
60
  finalMediaDeclaration.push(theme.media.large`${cssString}`);
61
61
  if (finalMediaDeclaration.length === 0)
62
- finalMediaDeclaration.push(
63
- import_ds_system.css`
64
- ${cssString}
65
- `
66
- );
62
+ finalMediaDeclaration.push(import_ds_system.css`
63
+ ${cssString}
64
+ `);
67
65
  }
68
66
  if (cols.medium) {
69
67
  let cssString = "";
@@ -74,11 +72,9 @@ const generateColsWithMediaQueries = (cols, theme, isSpanParent) => {
74
72
  }
75
73
  finalMediaDeclaration.push(theme.media.medium`${cssString}`);
76
74
  if (finalMediaDeclaration.length === 0)
77
- finalMediaDeclaration.push(
78
- import_ds_system.css`
79
- ${cssString}
80
- `
81
- );
75
+ finalMediaDeclaration.push(import_ds_system.css`
76
+ ${cssString}
77
+ `);
82
78
  }
83
79
  if (cols.small) {
84
80
  let cssString = "";
@@ -89,11 +85,9 @@ const generateColsWithMediaQueries = (cols, theme, isSpanParent) => {
89
85
  }
90
86
  finalMediaDeclaration.push(theme.media.small`${cssString}`);
91
87
  if (finalMediaDeclaration.length === 0)
92
- finalMediaDeclaration.push(
93
- import_ds_system.css`
94
- ${cssString}
95
- `
96
- );
88
+ finalMediaDeclaration.push(import_ds_system.css`
89
+ ${cssString}
90
+ `);
97
91
  }
98
92
  return finalMediaDeclaration;
99
93
  };
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../src/utils/manageCols.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["/* eslint-disable max-statements */\n/* eslint-disable complexity */\nimport { css, mapTemplateGrid } from '@elliemae/ds-system';\nimport type { DSGridT } from '../react-desc-prop-types.js';\nimport type { Theme } from '@elliemae/pui-theme';\n\ntype BreakPointObject = {\n large?: string | number | (string | number)[];\n medium?: string | number | (string | number)[];\n small?: string | number | (string | number)[];\n};\n// this typeguard is not extremely accurate but it has historically been like this and we need to avoid breaking changes\nconst colsIsBreakpointDefinition = (cols: unknown): cols is BreakPointObject =>\n typeof cols === 'object' && !Array.isArray(cols);\ntype InterpolatedFunctionProps = {\n theme: Theme;\n} & DSGridT.ItemProps;\n\nconst generateColsCssStringForArray = (colsVal: (string | number)[]): string => {\n // mtg and mtgs are used to support mapping different ways of defining the cols\n // when mtg produces valid css, mtgs will produce invalid css and vice-versa\n // only one of them will be effectively applied by the browser\n const mtg = (mapTemplateGrid(colsVal) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(colsVal) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n return `\n -ms-grid-columns: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtg || 'auto'};\n -ms-grid-columns: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtgs || 'auto'};\n `;\n};\nconst generateColsCssStringForBootstrapLikeishScenario = (colsVal: string | number): string => `\n -ms-grid-columns: repeat(${colsVal}, 1fr);\n grid-template-columns: repeat(${colsVal}, 1fr);\n `;\nconst generateColsWithMediaQueries = (\n cols: BreakPointObject,\n theme: Theme,\n isSpanParent: boolean,\n): ReturnType<typeof css>[] => {\n const finalMediaDeclaration: ReturnType<typeof css>[] = [];\n // we conditionally push into the array the media queries because grid cols definitions supports partial definitions\n // meaning that you can define cols only for small and medium and not for large\n // in such case we want to avoid generating media queries for large\n // we also need to make sure that the largest definition is used as the default one\n if (cols.large) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(cols.large)) {\n cssString = generateColsCssStringForArray(cols.large);\n } else if (isSpanParent) {\n cssString = generateColsCssStringForBootstrapLikeishScenario(cols.large);\n }\n finalMediaDeclaration.push(theme.media.large`${cssString}`);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n }\n if (cols.medium) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(cols.medium)) {\n cssString = generateColsCssStringForArray(cols.medium);\n } else if (isSpanParent) {\n cssString = generateColsCssStringForBootstrapLikeishScenario(cols.medium);\n }\n finalMediaDeclaration.push(theme.media.medium`${cssString}`);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n }\n if (cols.small) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(cols.small)) {\n cssString = generateColsCssStringForArray(cols.small);\n } else if (isSpanParent) {\n cssString = generateColsCssStringForBootstrapLikeishScenario(cols.small);\n }\n finalMediaDeclaration.push(theme.media.small`${cssString}`);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n }\n return finalMediaDeclaration;\n};\n\nexport const manageColsV2 = ({ cols, theme, isSpanParent }: InterpolatedFunctionProps): ReturnType<typeof css>[] => {\n // we want to be extremely explicit with how we handle the different use-cases\n // the component is quite old and has been tailored to fit the needs of the different use-cases\n // even ones that should have not been supported in the first place (isSpanParent to simulate bootstrap, different kind of cols definitions, etc)\n // support for\n // cols:{small: 1, medium: 2, large: 3}\n // AND\n // cols: {small: ['1fr'], medium: ['160px'], large: ['400px'] }\n if (colsIsBreakpointDefinition(cols)) {\n // there is no way to guarantee dynamic co-relation between pui-theme and the grid component\n // any change in the theme will break the co-relation and we would need to update the component\n // for such reason we are optimizing for maintainability and not scalability\n return generateColsWithMediaQueries(cols, theme, isSpanParent);\n }\n\n // support for cols: ['1fr', '1fr', '1fr'] && cols: [1, 1, 1]\n if (Array.isArray(cols)) {\n const cssString = generateColsCssStringForArray(cols);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // support for parent is span and is like cols: 3\n if (isSpanParent) {\n const cssString = generateColsCssStringForBootstrapLikeishScenario(cols);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // fallback is not doing anything\n return [css``];\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;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,KAAK,KAAK,GAAG;AAC7B,kBAAY,8BAA8B,KAAK,KAAK;AAAA,IACtD,WAAW,cAAc;AACvB,kBAAY,iDAAiD,KAAK,KAAK;AAAA,IACzE;AACA,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAC1D,QAAI,sBAAsB,WAAW;AACnC,4BAAsB;AAAA,QACpB;AAAA,YACI;AAAA;AAAA,MAEN;AAAA,EACJ;AACA,SAAO;AACT;AAEO,MAAM,eAAe,CAAC,EAAE,MAAM,OAAO,aAAa,MAA2D;AAQlH,MAAI,2BAA2B,IAAI,GAAG;AAIpC,WAAO,6BAA6B,MAAM,OAAO,YAAY;AAAA,EAC/D;AAGA,MAAI,MAAM,QAAQ,IAAI,GAAG;AACvB,UAAM,YAAY,8BAA8B,IAAI;AACpD,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,MAAI,cAAc;AAChB,UAAM,YAAY,iDAAiD,IAAI;AACvE,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,SAAO,CAAC,sBAAK;AACf;",
3
+ "sources": ["../../../src/utils/manageCols.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
+ "sourcesContent": ["/* eslint-disable max-statements */\n/* eslint-disable complexity */\nimport { css, mapTemplateGrid } from '@elliemae/ds-system';\nimport type { DSGridT } from '../react-desc-prop-types.js';\nimport type { Theme } from '@elliemae/pui-theme';\n\ntype BreakPointObject = {\n large?: string | number | (string | number)[];\n medium?: string | number | (string | number)[];\n small?: string | number | (string | number)[];\n};\n// this typeguard is not extremely accurate but it has historically been like this and we need to avoid breaking changes\nconst colsIsBreakpointDefinition = (cols: unknown): cols is BreakPointObject =>\n typeof cols === 'object' && !Array.isArray(cols);\ntype InterpolatedFunctionProps = {\n theme: Theme;\n} & DSGridT.ItemProps;\n\nconst generateColsCssStringForArray = (colsVal: (string | number)[]): string => {\n // mtg and mtgs are used to support mapping different ways of defining the cols\n // when mtg produces valid css, mtgs will produce invalid css and vice-versa\n // only one of them will be effectively applied by the browser\n const mtg = (mapTemplateGrid(colsVal) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(colsVal) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n return `\n -ms-grid-columns: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtg || 'auto'};\n -ms-grid-columns: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtgs || 'auto'};\n `;\n};\nconst generateColsCssStringForBootstrapLikeishScenario = (colsVal: string | number): string => `\n -ms-grid-columns: repeat(${colsVal}, 1fr);\n grid-template-columns: repeat(${colsVal}, 1fr);\n `;\nconst generateColsWithMediaQueries = (\n cols: BreakPointObject,\n theme: Theme,\n isSpanParent: boolean,\n): ReturnType<typeof css>[] => {\n const finalMediaDeclaration: ReturnType<typeof css>[] = [];\n // we conditionally push into the array the media queries because grid cols definitions supports partial definitions\n // meaning that you can define cols only for small and medium and not for large\n // in such case we want to avoid generating media queries for large\n // we also need to make sure that the largest definition is used as the default one\n if (cols.large) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(cols.large)) {\n cssString = generateColsCssStringForArray(cols.large);\n } else if (isSpanParent) {\n cssString = generateColsCssStringForBootstrapLikeishScenario(cols.large);\n }\n finalMediaDeclaration.push(theme.media.large`${cssString}`);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n }\n if (cols.medium) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(cols.medium)) {\n cssString = generateColsCssStringForArray(cols.medium);\n } else if (isSpanParent) {\n cssString = generateColsCssStringForBootstrapLikeishScenario(cols.medium);\n }\n finalMediaDeclaration.push(theme.media.medium`${cssString}`);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n }\n if (cols.small) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(cols.small)) {\n cssString = generateColsCssStringForArray(cols.small);\n } else if (isSpanParent) {\n cssString = generateColsCssStringForBootstrapLikeishScenario(cols.small);\n }\n finalMediaDeclaration.push(theme.media.small`${cssString}`);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n }\n return finalMediaDeclaration;\n};\n\nexport const manageColsV2 = ({ cols, theme, isSpanParent }: InterpolatedFunctionProps): ReturnType<typeof css>[] => {\n // we want to be extremely explicit with how we handle the different use-cases\n // the component is quite old and has been tailored to fit the needs of the different use-cases\n // even ones that should have not been supported in the first place (isSpanParent to simulate bootstrap, different kind of cols definitions, etc)\n // support for\n // cols:{small: 1, medium: 2, large: 3}\n // AND\n // cols: {small: ['1fr'], medium: ['160px'], large: ['400px'] }\n if (colsIsBreakpointDefinition(cols)) {\n // there is no way to guarantee dynamic co-relation between pui-theme and the grid component\n // any change in the theme will break the co-relation and we would need to update the component\n // for such reason we are optimizing for maintainability and not scalability\n return generateColsWithMediaQueries(cols, theme, isSpanParent);\n }\n\n // support for cols: ['1fr', '1fr', '1fr'] && cols: [1, 1, 1]\n if (Array.isArray(cols)) {\n const cssString = generateColsCssStringForArray(cols);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // support for parent is span and is like cols: 3\n if (isSpanParent) {\n const cssString = generateColsCssStringForBootstrapLikeishScenario(cols);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // fallback is not doing anything\n return [css``];\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AA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AAK,KAAK,GAAG;AAC7B,kBAAY,8BAA8B,KAAK,KAAK;AAAA,IACtD,WAAW,cAAc;AACvB,kBAAY,iDAAiD,KAAK,KAAK;AAAA,IACzE;AACA,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAC1D,QAAI,sBAAsB,WAAW;AACnC,4BAAsB,KAAK;AAAA,UACvB;AAAA,OACH;AAAA,EACL;AACA,SAAO;AACT;AAEO,MAAM,eAAe,CAAC,EAAE,MAAM,OAAO,aAAa,MAA2D;AAQlH,MAAI,2BAA2B,IAAI,GAAG;AAIpC,WAAO,6BAA6B,MAAM,OAAO,YAAY;AAAA,EAC/D;AAGA,MAAI,MAAM,QAAQ,IAAI,GAAG;AACvB,UAAM,YAAY,8BAA8B,IAAI;AACpD,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,MAAI,cAAc;AAChB,UAAM,YAAY,iDAAiD,IAAI;AACvE,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,SAAO,CAAC,sBAAK;AACf;",
6
6
  "names": []
7
7
  }
@@ -58,11 +58,9 @@ const generateRowsWithMediaQueries = (rows, theme, isSpanParent) => {
58
58
  cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.large);
59
59
  }
60
60
  if (finalMediaDeclaration.length === 0)
61
- finalMediaDeclaration.push(
62
- import_ds_system.css`
63
- ${cssString}
64
- `
65
- );
61
+ finalMediaDeclaration.push(import_ds_system.css`
62
+ ${cssString}
63
+ `);
66
64
  finalMediaDeclaration.push(theme.media.large`${cssString}`);
67
65
  }
68
66
  if (rows.medium) {
@@ -73,11 +71,9 @@ const generateRowsWithMediaQueries = (rows, theme, isSpanParent) => {
73
71
  cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.medium);
74
72
  }
75
73
  if (finalMediaDeclaration.length === 0)
76
- finalMediaDeclaration.push(
77
- import_ds_system.css`
78
- ${cssString}
79
- `
80
- );
74
+ finalMediaDeclaration.push(import_ds_system.css`
75
+ ${cssString}
76
+ `);
81
77
  finalMediaDeclaration.push(theme.media.medium`${cssString}`);
82
78
  }
83
79
  if (rows.small) {
@@ -88,11 +84,9 @@ const generateRowsWithMediaQueries = (rows, theme, isSpanParent) => {
88
84
  cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.small);
89
85
  }
90
86
  if (finalMediaDeclaration.length === 0)
91
- finalMediaDeclaration.push(
92
- import_ds_system.css`
93
- ${cssString}
94
- `
95
- );
87
+ finalMediaDeclaration.push(import_ds_system.css`
88
+ ${cssString}
89
+ `);
96
90
  finalMediaDeclaration.push(theme.media.small`${cssString}`);
97
91
  }
98
92
  return finalMediaDeclaration;
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../src/utils/manageRows.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["/* eslint-disable max-statements */\n/* eslint-disable complexity */\nimport { css, mapTemplateGrid } from '@elliemae/ds-system';\nimport type { DSGridT } from '../react-desc-prop-types.js';\nimport type { Theme } from '@elliemae/pui-theme';\n\ntype BreakPointObject = {\n large?: string | number | (string | number)[];\n medium?: string | number | (string | number)[];\n small?: string | number | (string | number)[];\n};\n// this typeguard is not extremely accurate but it has historically been like this and we need to avoid breaking changes\nconst rowsIsBreakpointDefinition = (rows: unknown): rows is BreakPointObject =>\n typeof rows === 'object' && !Array.isArray(rows);\ntype InterpolatedFunctionProps = {\n theme: Theme;\n} & DSGridT.ItemProps;\n\nconst generateRowsCssStringForArray = (rowsVal: (string | number)[]): string => {\n // mtg and mtgs are used to support mapping different ways of defining the rows\n // when mtg produces valid css, mtgs will produce invalid css and vice-versa\n // only one of them will be effectively applied by the browser\n const mtg = (mapTemplateGrid(rowsVal) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(rowsVal) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n return `\n -ms-grid-rows: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtg || 'auto'};\n -ms-grid-rows: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtgs || 'auto'};\n `;\n};\nconst generateRowsCssStringForBootstrapLikeishScenario = (rowsVal: string | number): string => `\n -ms-grid-rows: repeat(${rowsVal}, 1fr);\n grid-template-rows: repeat(${rowsVal}, 1fr);\n `;\nconst generateRowsWithMediaQueries = (\n rows: BreakPointObject,\n theme: Theme,\n isSpanParent: boolean,\n): ReturnType<typeof css>[] => {\n const finalMediaDeclaration: ReturnType<typeof css>[] = [];\n // we conditionally push into the array the media queries because grid rows definitions supports partial definitions\n // meaning that you can define rows only for small and medium and not for large\n // in such case we want to avoid generating media queries for large\n // we also need to make sure that the largest definition is used as the default one\n if (rows.large) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(rows.large)) {\n cssString = generateRowsCssStringForArray(rows.large);\n } else if (isSpanParent) {\n cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.large);\n }\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n finalMediaDeclaration.push(theme.media.large`${cssString}`);\n }\n if (rows.medium) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(rows.medium)) {\n cssString = generateRowsCssStringForArray(rows.medium);\n } else if (isSpanParent) {\n cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.medium);\n }\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n finalMediaDeclaration.push(theme.media.medium`${cssString}`);\n }\n if (rows.small) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(rows.small)) {\n cssString = generateRowsCssStringForArray(rows.small);\n } else if (isSpanParent) {\n cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.small);\n }\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n finalMediaDeclaration.push(theme.media.small`${cssString}`);\n }\n return finalMediaDeclaration;\n};\n\nexport const manageRowsV2 = ({ rows, theme, isSpanParent }: InterpolatedFunctionProps): ReturnType<typeof css>[] => {\n // we want to be extremely explicit with how we handle the different use-cases\n // the component is quite old and has been tailored to fit the needs of the different use-cases\n // even ones that should have not been supported in the first place (isSpanParent to simulate bootstrap, different kind of rows definitions, etc)\n // support for\n // rows:{small: 1, medium: 2, large: 3}\n // AND\n // rows: {small: ['1fr'], medium: ['160px'], large: ['400px'] }\n if (rowsIsBreakpointDefinition(rows)) {\n // there is no way to guarantee dynamic co-relation between pui-theme and the grid component\n // any change in the theme will break the co-relation and we would need to update the component\n // for such reason we are optimizing for maintainability and not scalability\n return generateRowsWithMediaQueries(rows, theme, isSpanParent);\n }\n\n // support for rows: ['1fr', '1fr', '1fr'] && rows: [1, 1, 1]\n if (Array.isArray(rows)) {\n const cssString = generateRowsCssStringForArray(rows);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // support for parent is span and is like rows: 3\n if (isSpanParent) {\n const cssString = generateRowsCssStringForBootstrapLikeishScenario(rows);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // fallback is not doing anything\n return [css``];\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,uBAAqC;AAUrC,MAAM,6BAA6B,CAAC,SAClC,OAAO,SAAS,YAAY,CAAC,MAAM,QAAQ,IAAI;AAKjD,MAAM,gCAAgC,CAAC,YAAyC;AAI9E,QAAM,UAAO,kCAAgB,O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sB;AAAA,QACpB;AAAA,YACI;AAAA;AAAA,MAEN;AACF,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAAA,EAC5D;AACA,SAAO;AACT;AAEO,MAAM,eAAe,CAAC,EAAE,MAAM,OAAO,aAAa,MAA2D;AAQlH,MAAI,2BAA2B,IAAI,GAAG;AAIpC,WAAO,6BAA6B,MAAM,OAAO,YAAY;AAAA,EAC/D;AAGA,MAAI,MAAM,QAAQ,IAAI,GAAG;AACvB,UAAM,YAAY,8BAA8B,IAAI;AACpD,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,MAAI,cAAc;AAChB,UAAM,YAAY,iDAAiD,IAAI;AACvE,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,SAAO,CAAC,sBAAK;AACf;",
3
+ "sources": ["../../../src/utils/manageRows.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
+ "sourcesContent": ["/* eslint-disable max-statements */\n/* eslint-disable complexity */\nimport { css, mapTemplateGrid } from '@elliemae/ds-system';\nimport type { DSGridT } from '../react-desc-prop-types.js';\nimport type { Theme } from '@elliemae/pui-theme';\n\ntype BreakPointObject = {\n large?: string | number | (string | number)[];\n medium?: string | number | (string | number)[];\n small?: string | number | (string | number)[];\n};\n// this typeguard is not extremely accurate but it has historically been like this and we need to avoid breaking changes\nconst rowsIsBreakpointDefinition = (rows: unknown): rows is BreakPointObject =>\n typeof rows === 'object' && !Array.isArray(rows);\ntype InterpolatedFunctionProps = {\n theme: Theme;\n} & DSGridT.ItemProps;\n\nconst generateRowsCssStringForArray = (rowsVal: (string | number)[]): string => {\n // mtg and mtgs are used to support mapping different ways of defining the rows\n // when mtg produces valid css, mtgs will produce invalid css and vice-versa\n // only one of them will be effectively applied by the browser\n const mtg = (mapTemplateGrid(rowsVal) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(rowsVal) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n return `\n -ms-grid-rows: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtg || 'auto'};\n -ms-grid-rows: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtgs || 'auto'};\n `;\n};\nconst generateRowsCssStringForBootstrapLikeishScenario = (rowsVal: string | number): string => `\n -ms-grid-rows: repeat(${rowsVal}, 1fr);\n grid-template-rows: repeat(${rowsVal}, 1fr);\n `;\nconst generateRowsWithMediaQueries = (\n rows: BreakPointObject,\n theme: Theme,\n isSpanParent: boolean,\n): ReturnType<typeof css>[] => {\n const finalMediaDeclaration: ReturnType<typeof css>[] = [];\n // we conditionally push into the array the media queries because grid rows definitions supports partial definitions\n // meaning that you can define rows only for small and medium and not for large\n // in such case we want to avoid generating media queries for large\n // we also need to make sure that the largest definition is used as the default one\n if (rows.large) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(rows.large)) {\n cssString = generateRowsCssStringForArray(rows.large);\n } else if (isSpanParent) {\n cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.large);\n }\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n finalMediaDeclaration.push(theme.media.large`${cssString}`);\n }\n if (rows.medium) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(rows.medium)) {\n cssString = generateRowsCssStringForArray(rows.medium);\n } else if (isSpanParent) {\n cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.medium);\n }\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n finalMediaDeclaration.push(theme.media.medium`${cssString}`);\n }\n if (rows.small) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(rows.small)) {\n cssString = generateRowsCssStringForArray(rows.small);\n } else if (isSpanParent) {\n cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.small);\n }\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n finalMediaDeclaration.push(theme.media.small`${cssString}`);\n }\n return finalMediaDeclaration;\n};\n\nexport const manageRowsV2 = ({ rows, theme, isSpanParent }: InterpolatedFunctionProps): ReturnType<typeof css>[] => {\n // we want to be extremely explicit with how we handle the different use-cases\n // the component is quite old and has been tailored to fit the needs of the different use-cases\n // even ones that should have not been supported in the first place (isSpanParent to simulate bootstrap, different kind of rows definitions, etc)\n // support for\n // rows:{small: 1, medium: 2, large: 3}\n // AND\n // rows: {small: ['1fr'], medium: ['160px'], large: ['400px'] }\n if (rowsIsBreakpointDefinition(rows)) {\n // there is no way to guarantee dynamic co-relation between pui-theme and the grid component\n // any change in the theme will break the co-relation and we would need to update the component\n // for such reason we are optimizing for maintainability and not scalability\n return generateRowsWithMediaQueries(rows, theme, isSpanParent);\n }\n\n // support for rows: ['1fr', '1fr', '1fr'] && rows: [1, 1, 1]\n if (Array.isArray(rows)) {\n const cssString = generateRowsCssStringForArray(rows);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // support for parent is span and is like rows: 3\n if (isSpanParent) {\n const cssString = generateRowsCssStringForBootstrapLikeishScenario(rows);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // fallback is not doing anything\n return [css``];\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,uBAAqC;AAUrC,MAAM,6BAA6B,CAAC,SAClC,OAAO,SAAS,YAAY,CAAC,MAAM,QAAQ,IAAI;AAKjD,MAAM,gCAAgC,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,WAAW;AACnC,4BAAsB,KAAK;AAAA,UACvB;AAAA,OACH;AACH,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAAA,EAC5D;AACA,SAAO;AACT;AAEO,MAAM,eAAe,CAAC,EAAE,MAAM,OAAO,aAAa,MAA2D;AAQlH,MAAI,2BAA2B,IAAI,GAAG;AAIpC,WAAO,6BAA6B,MAAM,OAAO,YAAY;AAAA,EAC/D;AAGA,MAAI,MAAM,QAAQ,IAAI,GAAG;AACvB,UAAM,YAAY,8BAA8B,IAAI;AACpD,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,MAAI,cAAc;AAChB,UAAM,YAAY,iDAAiD,IAAI;AACvE,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,SAAO,CAAC,sBAAK;AACf;",
6
6
  "names": []
7
7
  }
@@ -58,31 +58,25 @@ const manageSpanParent = ({
58
58
  if (span.large) {
59
59
  const cssString = generateCssStringForSpan(span.large);
60
60
  if (finalMediaDeclaration.length === 0)
61
- finalMediaDeclaration.push(
62
- import_ds_system.css`
63
- ${cssString}
64
- `
65
- );
61
+ finalMediaDeclaration.push(import_ds_system.css`
62
+ ${cssString}
63
+ `);
66
64
  finalMediaDeclaration.push(theme.media.large`${cssString}`);
67
65
  }
68
66
  if (span.medium) {
69
67
  const cssString = generateCssStringForSpan(span.medium);
70
68
  if (finalMediaDeclaration.length === 0)
71
- finalMediaDeclaration.push(
72
- import_ds_system.css`
73
- ${cssString}
74
- `
75
- );
69
+ finalMediaDeclaration.push(import_ds_system.css`
70
+ ${cssString}
71
+ `);
76
72
  finalMediaDeclaration.push(theme.media.medium`${cssString}`);
77
73
  }
78
74
  if (span.small) {
79
75
  const cssString = generateCssStringForSpan(span.small);
80
76
  if (finalMediaDeclaration.length === 0)
81
- finalMediaDeclaration.push(
82
- import_ds_system.css`
83
- ${cssString}
84
- `
85
- );
77
+ finalMediaDeclaration.push(import_ds_system.css`
78
+ ${cssString}
79
+ `);
86
80
  finalMediaDeclaration.push(theme.media.small`${cssString}`);
87
81
  }
88
82
  return finalMediaDeclaration;
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../src/utils/manageSpanParent.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
4
- "sourcesContent": ["/* eslint-disable max-statements */\n/* eslint-disable max-lines */\n/* eslint-disable complexity */\nimport { css } from '@elliemae/ds-system';\nimport type { Theme } from '@elliemae/pui-theme';\nimport type { DSGridT } from '../react-desc-prop-types.js';\n\ntype InterpolatedFunctionProps = {\n theme: Theme;\n} & DSGridT.ItemProps;\n\nconst generateCssStringForSpan = (span: number): string => `\n -ms-grid-column: auto / span ${span};\n grid-column: auto / span ${span};\n`;\n// This is used to support bootrap like-ish way of using the grid component\nexport const manageSpanParent = ({\n isSpanParent,\n span,\n theme,\n}: InterpolatedFunctionProps): ReturnType<typeof css>[] => {\n // If it's not a span parent, we don't need to do anything\n if (!isSpanParent) return [css``];\n\n // if span is a number we don't add media queries\n if (typeof span === 'number') {\n return [\n css`\n -ms-grid-column: auto / span ${span};\n grid-column: auto / span ${span};\n `,\n ];\n }\n // the only remaining valid definition for our supported types is an object, if it's not an object we fallback to doing nothing\n if (typeof span !== 'object') return [css``];\n\n // Span object\n\n const finalMediaDeclaration: ReturnType<typeof css>[] = [];\n // we conditionally push into the array the media queries because span definitions supports partial definitions\n // meaning that you can define spans only for small and medium and not for large\n // in such case we want to avoid generating media queries for large\n // we also need to make sure that the largest definition is used as the default one\n if (span.large) {\n const cssString = generateCssStringForSpan(span.large);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n finalMediaDeclaration.push(theme.media.large`${cssString}`);\n }\n if (span.medium) {\n const cssString = generateCssStringForSpan(span.medium);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n finalMediaDeclaration.push(theme.media.medium`${cssString}`);\n }\n if (span.small) {\n const cssString = generateCssStringForSpan(span.small);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n finalMediaDeclaration.push(theme.media.small`${cssString}`);\n }\n return finalMediaDeclaration;\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADGvB,uBAAoB;AAQpB,MAAM,2BAA2B,CAAC,SAAyB;AAAA,iCAC1B;AAAA,6BACJ;AAAA;AAGtB,MAAM,mBAAmB,CAAC;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AACF,MAA2D;AAEzD,MAAI,CAAC;AAAc,WAAO,CAAC,sBAAK;AAGhC,MAAI,OAAO,SAAS,UAAU;AAC5B,WAAO;AAAA,MACL;AAAA,uCACiC;AAAA,mCACJ;AAAA;AAAA,IAE/B;AAAA,EACF;AAEA,MAAI,OAAO,SAAS;AAAU,WAAO,CAAC,sBAAK;AAI3C,QAAM,wBAAkD,CAAC;AAKzD,MAAI,KAAK,OAAO;AACd,UAAM,YAAY,yBAAyB,KAAK,KAAK;AACrD,QAAI,sBAAsB,WAAW;AACnC,4BAAsB;AAAA,QACpB;AAAA,YACI;AAAA;AAAA,MAEN;AACF,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAAA,EAC5D;AACA,MAAI,KAAK,QAAQ;AACf,UAAM,YAAY,yBAAyB,KAAK,MAAM;AACtD,QAAI,sBAAsB,WAAW;AACnC,4BAAsB;AAAA,QACpB;AAAA,YACI;AAAA;AAAA,MAEN;AACF,0BAAsB,KAAK,MAAM,MAAM,SAAS,WAAW;AAAA,EAC7D;AACA,MAAI,KAAK,OAAO;AACd,UAAM,YAAY,yBAAyB,KAAK,KAAK;AACrD,QAAI,sBAAsB,WAAW;AACnC,4BAAsB;AAAA,QACpB;AAAA,YACI;AAAA;AAAA,MAEN;AACF,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAAA,EAC5D;AACA,SAAO;AACT;",
3
+ "sources": ["../../../src/utils/manageSpanParent.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
+ "sourcesContent": ["/* eslint-disable max-statements */\n/* eslint-disable max-lines */\n/* eslint-disable complexity */\nimport { css } from '@elliemae/ds-system';\nimport type { Theme } from '@elliemae/pui-theme';\nimport type { DSGridT } from '../react-desc-prop-types.js';\n\ntype InterpolatedFunctionProps = {\n theme: Theme;\n} & DSGridT.ItemProps;\n\nconst generateCssStringForSpan = (span: number): string => `\n -ms-grid-column: auto / span ${span};\n grid-column: auto / span ${span};\n`;\n// This is used to support bootrap like-ish way of using the grid component\nexport const manageSpanParent = ({\n isSpanParent,\n span,\n theme,\n}: InterpolatedFunctionProps): ReturnType<typeof css>[] => {\n // If it's not a span parent, we don't need to do anything\n if (!isSpanParent) return [css``];\n\n // if span is a number we don't add media queries\n if (typeof span === 'number') {\n return [\n css`\n -ms-grid-column: auto / span ${span};\n grid-column: auto / span ${span};\n `,\n ];\n }\n // the only remaining valid definition for our supported types is an object, if it's not an object we fallback to doing nothing\n if (typeof span !== 'object') return [css``];\n\n // Span object\n\n const finalMediaDeclaration: ReturnType<typeof css>[] = [];\n // we conditionally push into the array the media queries because span definitions supports partial definitions\n // meaning that you can define spans only for small and medium and not for large\n // in such case we want to avoid generating media queries for large\n // we also need to make sure that the largest definition is used as the default one\n if (span.large) {\n const cssString = generateCssStringForSpan(span.large);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n finalMediaDeclaration.push(theme.media.large`${cssString}`);\n }\n if (span.medium) {\n const cssString = generateCssStringForSpan(span.medium);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n finalMediaDeclaration.push(theme.media.medium`${cssString}`);\n }\n if (span.small) {\n const cssString = generateCssStringForSpan(span.small);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n finalMediaDeclaration.push(theme.media.small`${cssString}`);\n }\n return finalMediaDeclaration;\n};\n", "import * as React from 'react';\nexport { React };\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADGvB,uBAAoB;AAQpB,MAAM,2BAA2B,CAAC,SAAyB;AAAA,iCAC1B;AAAA,6BACJ;AAAA;AAGtB,MAAM,mBAAmB,CAAC;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AACF,MAA2D;AAEzD,MAAI,CAAC;AAAc,WAAO,CAAC,sBAAK;AAGhC,MAAI,OAAO,SAAS,UAAU;AAC5B,WAAO;AAAA,MACL;AAAA,uCACiC;AAAA,mCACJ;AAAA;AAAA,IAE/B;AAAA,EACF;AAEA,MAAI,OAAO,SAAS;AAAU,WAAO,CAAC,sBAAK;AAI3C,QAAM,wBAAkD,CAAC;AAKzD,MAAI,KAAK,OAAO;AACd,UAAM,YAAY,yBAAyB,KAAK,KAAK;AACrD,QAAI,sBAAsB,WAAW;AACnC,4BAAsB,KAAK;AAAA,UACvB;AAAA,OACH;AACH,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAAA,EAC5D;AACA,MAAI,KAAK,QAAQ;AACf,UAAM,YAAY,yBAAyB,KAAK,MAAM;AACtD,QAAI,sBAAsB,WAAW;AACnC,4BAAsB,KAAK;AAAA,UACvB;AAAA,OACH;AACH,0BAAsB,KAAK,MAAM,MAAM,SAAS,WAAW;AAAA,EAC7D;AACA,MAAI,KAAK,OAAO;AACd,UAAM,YAAY,yBAAyB,KAAK,KAAK;AACrD,QAAI,sBAAsB,WAAW;AACnC,4BAAsB,KAAK;AAAA,UACvB;AAAA,OACH;AACH,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAAA,EAC5D;AACA,SAAO;AACT;",
6
6
  "names": []
7
7
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../src/utils/styles.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
3
+ "sources": ["../../../src/utils/styles.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
4
4
  "sourcesContent": ["/* eslint-disable max-lines */\n/* eslint-disable complexity */\nimport { css, mapTemplateGrid } from '@elliemae/ds-system';\nimport type { DSGridT } from '../react-desc-prop-types.js';\n\nexport const manageSpan = css<DSGridT.ItemProps>`\n ${({ isSpanParent, span, theme }) => {\n if (!isSpanParent) return '';\n\n if (typeof span === 'number') {\n return `\n -ms-grid-column: auto / span ${span};\n grid-column: auto / span ${span};`;\n }\n\n if (typeof span !== 'object') return ``;\n\n // Span object\n\n let data = '';\n Object.keys(theme.media).forEach((key) => {\n // Type castings\n const theKey = key as keyof typeof span & keyof typeof theme.breakpoints;\n const spanValue = span[theKey];\n\n if (!!spanValue && theme.breakpoints[theKey]) {\n if (theKey === 'small') {\n data += `\n -ms-grid-column: auto / span ${spanValue};\n grid-column: auto / span ${spanValue};\n `;\n } else {\n data += `@media (min-width: ${theme.breakpoints[theKey]}) {\n -ms-grid-column: auto / span ${spanValue};\n grid-column: auto / span ${spanValue};\n }`;\n }\n }\n });\n return data;\n }}\n`;\n\nexport const manageCols = css<DSGridT.ItemProps>`\n ${({ cols, theme, isSpanParent }) => {\n if (typeof cols === 'object' && !Array.isArray(cols)) {\n let data = '';\n Object.keys(theme.media).forEach((key) => {\n const theKey = key as keyof typeof cols;\n const colValue = cols[theKey];\n if (!!colValue && Array.isArray(colValue)) {\n const mtg = (mapTemplateGrid(colValue) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(colValue) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n if (theKey === 'small') {\n data += `-ms-grid-columns: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtg || 'auto'};\n -ms-grid-columns: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtgs || 'auto'};`;\n } else {\n data += `@media (min-width: ${theme.breakpoints[theKey]}) {\n -ms-grid-columns: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtg || 'auto'};\n -ms-grid-columns: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtgs || 'auto'};\n }`;\n }\n } else if (!!colValue && isSpanParent) {\n if (theKey === 'small') {\n data += `-ms-grid-columns: repeat(${colValue}, 1fr);\n grid-template-columns: repeat(${colValue}, 1fr);`;\n } else {\n data += `@media (min-width: ${theme.breakpoints[theKey]}) {\n -ms-grid-columns: repeat(${colValue}, 1fr);\n grid-template-columns: repeat(${colValue}, 1fr);\n }`;\n }\n }\n });\n return data;\n }\n if (Array.isArray(cols)) {\n const mtg = (mapTemplateGrid(cols) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(cols) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n return `\n -ms-grid-columns: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtg || 'auto'};\n -ms-grid-columns: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtgs || 'auto'};`;\n }\n if (isSpanParent) {\n return `\n -ms-grid-columns: repeat(${cols}, 1fr);\n grid-template-columns: repeat(${cols}, 1fr);`;\n }\n return '';\n }}\n`;\n\nexport const manageRows = css<DSGridT.ItemProps>`\n ${({ rows, theme, isSpanParent }) => {\n if (typeof rows === 'object' && !Array.isArray(rows)) {\n let data = '';\n Object.keys(theme.media).forEach((key) => {\n const theKey = key as keyof typeof rows & keyof typeof theme.breakpoints;\n const rowValue = rows[theKey];\n if (rowValue && Array.isArray(rowValue)) {\n const mtg = (mapTemplateGrid(rowValue) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(rowValue) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n if (key === 'small') {\n data += `-ms-grid-rows: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtg || 'auto'};\n -ms-grid-rows: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtgs || 'auto'};`;\n } else {\n data += `@media (min-width: ${theme.breakpoints[theKey]}) {\n -ms-grid-rows: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtg || 'auto'};\n -ms-grid-rows: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtgs || 'auto'};\n }`;\n }\n } else if (!!rowValue && isSpanParent) {\n if (theKey === 'small') {\n data += `-ms-grid-rows: repeat(${rowValue}, 1fr);\n grid-template-rows: repeat(${rowValue}, 1fr);`;\n } else {\n data += `@media (min-width: ${theme.breakpoints[theKey]}) {\n -ms-grid-rows: repeat(${rowValue}, 1fr);\n grid-template-rows: repeat(${rowValue}, 1fr);\n }`;\n }\n }\n });\n return data;\n }\n if (Array.isArray(rows)) {\n const mtg = (mapTemplateGrid(rows) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(rows) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n return `\n -ms-grid-rows: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtg || 'auto'};\n -ms-grid-rows: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtgs || 'auto'};\n `;\n }\n if (isSpanParent) {\n return `\n -ms-grid-rows: repeat(${rows}, 1fr);\n grid-template-rows: repeat(${rows}, 1fr);`;\n }\n return '';\n }}\n`;\n", "import * as React from 'react';\nexport { React };\n"],
5
5
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADEvB,uBAAqC;AAG9B,MAAM,aAAa;AAAA,IACtB,CAAC,EAAE,cAAc,MAAM,MAAM,MAAM;AACnC,MAAI,CAAC;AAAc,WAAO;AAE1B,MAAI,OAAO,SAAS,UAAU;AAC5B,WAAO;AAAA,uCAC0B;AAAA,mCACJ;AAAA,EAC/B;AAEA,MAAI,OAAO,SAAS;AAAU,WAAO;AAIrC,MAAI,OAAO;AACX,SAA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AW,SAAS;AACtB,kBAAQ,yBAAyB;AAAA,kDACK;AAAA,QACxC,OAAO;AACL,kBAAQ,sBAAsB,MAAM,YAAY,MAAM;AAAA,8CACpB;AAAA,mDACK;AAAA;AAAA,QAEzC;AAAA,MACF;AAAA,IACF,CAAC;AACD,WAAO;AAAA,EACT;AACA,MAAI,MAAM,QAAQ,IAAI,GAAG;AACvB,UAAM,UAAO,kCAAgB,IAAI,EAAe,KAAK,GAAG;AACxD,UAAM,WAAQ,kCAAgB,IAAI,EAAe,IAAI,CAAC,MAAM,aAAa,IAAI,EAAE,KAAK,GAAG;AACvF,WAAO;AAAA,yBACY,OAAO;AAAA,8BACF,OAAO;AAAA,yBACZ,QAAQ;AAAA,8BACH,QAAQ;AAAA;AAAA,EAElC;AACA,MAAI,cAAc;AAChB,WAAO;AAAA,gCACmB;AAAA,qCACK;AAAA,EACjC;AACA,SAAO;AACT;AAAA;",
6
6
  "names": []
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../scripts/build/transpile/react-shim.js", "../../src/DSGridDefinitions.tsx"],
3
+ "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/DSGridDefinitions.tsx"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export const DSGridName = 'DSGrid';\n"],
5
5
  "mappings": "AAAA,YAAY,WAAW;ACAhB,MAAM,aAAa;",
6
6
  "names": []
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../scripts/build/transpile/react-shim.js", "../../src/Grid.tsx"],
3
+ "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/Grid.tsx"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport type { DSGridT } from './react-desc-prop-types.js';\nimport { DSGridPropTypes } from './react-desc-prop-types.js';\nimport { GridItem } from './GridItem.js';\nimport { useGrid } from './config/useGrid.js';\nimport { DSGridName } from './DSGridDefinitions.js';\n\nconst Grid = React.forwardRef<HTMLDivElement, DSGridT.Props>((props, ref) => {\n const {\n propsWithDefaults: {\n withMaxWidthBreakpoints,\n alignItems,\n cols,\n children,\n rows,\n gutter,\n justify,\n wrap,\n width,\n height,\n ...rest\n },\n globalProps,\n xstyledProps,\n isSpanParent,\n renderChildren,\n } = useGrid(props);\n\n return (\n <GridItem\n alignItems={alignItems}\n cols={cols}\n gutter={gutter}\n isSpanParent={isSpanParent}\n justify={justify}\n rows={rows}\n wrap={wrap}\n childNumber={React.Children.count(children)}\n ref={ref}\n {...rest}\n {...globalProps}\n {...xstyledProps}\n w={width}\n h={height}\n withMaxWidthBreakpoints={withMaxWidthBreakpoints}\n >\n {renderChildren}\n </GridItem>\n );\n});\n\n// Since this component is using ForwardRef, we must provide a displayName to avoid 'undefined' name in propsTable.\nGrid.displayName = DSGridName;\n\nGrid.propTypes = DSGridPropTypes;\nconst DSGridWithSchema = describe(Grid);\nDSGridWithSchema.propTypes = DSGridPropTypes;\n\nexport default Grid;\nexport { DSGridWithSchema, Grid };\n"],
5
5
  "mappings": "AAAA,YAAY,WAAW;AC8BnB;AA9BJ,OAAOA,YAAW;AAClB,SAAS,gBAAgB;AAEzB,SAAS,uBAAuB;AAChC,SAAS,gBAAgB;AACzB,SAAS,eAAe;AACxB,SAAS,kBAAkB;AAE3B,MAAM,OAAOA,OAAM,WAA0C,CAAC,OAAO,QAAQ;AAC3E,QAAM;AAAA,IACJ,mBAAmB;AAAA,MACjB;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,GAAG;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,IAAI,QAAQ,KAAK;AAEjB,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,aAAaA,OAAM,SAAS,MAAM,QAAQ;AAAA,MAC1C;AAAA,MACC,GAAG;AAAA,MACH,GAAG;AAAA,MACH,GAAG;AAAA,MACJ,GAAG;AAAA,MACH,GAAG;AAAA,MACH;AAAA,MAEC;AAAA;AAAA,EACH;AAEJ,CAAC;AAGD,KAAK,cAAc;AAEnB,KAAK,YAAY;AACjB,MAAM,mBAAmB,SAAS,IAAI;AACtC,iBAAiB,YAAY;AAE7B,IAAO,eAAQ;",
6
6
  "names": ["React"]
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../scripts/build/transpile/react-shim.js", "../../src/GridItem.tsx"],
3
+ "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/GridItem.tsx"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-lines */\n/* eslint-disable complexity */\nimport {\n styled,\n css,\n mapGap,\n background,\n borders,\n sizing,\n space,\n boxShadows,\n flexboxes,\n grids,\n layout,\n type LayoutProps,\n type SpaceProps,\n type SizingProps,\n} from '@elliemae/ds-system';\nimport { manageSpanParent } from './utils/manageSpanParent.js';\nimport { manageColsV2 } from './utils/manageCols.js';\nimport { manageRowsV2 } from './utils/manageRows.js';\nimport { type DSGridT } from './react-desc-prop-types.js';\nimport { manageCols, manageRows, manageSpan } from './utils/styles.js';\n\nconst gridV2 = css<DSGridT.ItemProps & LayoutProps & SpaceProps & SizingProps>`\n ${manageColsV2}\n ${manageRowsV2}\n ${manageSpanParent}\n`;\n\nconst gridV1 = css`\n ${manageCols}\n ${manageRows}\n ${manageSpan}\n`;\nexport const GridItem = styled.div<DSGridT.ItemProps & LayoutProps & SpaceProps & SizingProps>`\n display: grid;\n display: -ms-grid;\n column-gap: ${({ gutter }) => mapGap(gutter)};\n row-gap: ${({ gutter }) => mapGap(gutter)};\n ${grids}\n ${flexboxes}\n ${sizing}\n ${space}\n ${({ withMaxWidthBreakpoints }) => (withMaxWidthBreakpoints ? gridV2 : gridV1)}\n ${boxShadows}\n ${borders}\n ${background}\n ${layout}\n`;\n"],
5
5
  "mappings": "AAAA,YAAY,WAAW;ACEvB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OAIK;AACP,SAAS,wBAAwB;AACjC,SAAS,oBAAoB;AAC7B,SAAS,oBAAoB;AAE7B,SAAS,YAAY,YAAY,kBAAkB;AAEnD,MAAM,SAAS;AAAA,IACX;AAAA,IACA;AAAA,IACA;AAAA;AAGJ,MAAM,SAAS;AAAA,IACX;AAAA,IACA;AAAA,IACA;AAAA;AAEG,MAAM,WAAW,OAAO;AAAA;AAAA;AAAA,gBAGf,CAAC,EAAE,OAAO,MAAM,OAAO,MAAM;AAAA,aAChC,CAAC,EAAE,OAAO,MAAM,OAAO,MAAM;AAAA,IACtC;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA,CAAC,EAAE,wBAAwB,MAAO,0BAA0B,SAAS;AAAA,IACrE;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA;",
6
6
  "names": []
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/config/useGrid.tsx"],
3
+ "sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/config/useGrid.tsx"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { useGetGlobalAttributes, useGetXstyledProps, useMemoMergePropsWithDefault } from '@elliemae/ds-props-helpers';\nimport type { DSGridT } from '../react-desc-prop-types.js';\n// eslint-disable-next-line no-unused-vars\nimport { DSGridPropTypes, defaultProps } from '../react-desc-prop-types.js';\nimport { useRenderChildren } from './useRenderChildren.js';\n// eslint-disable-next-line no-unused-vars\nimport { useValidateProps } from './useValidateProps.js';\n\nexport const useGrid = (props: DSGridT.Props) => {\n const { children, ...propsWithoutChildren } = props;\n\n // =========================================================================\n // MERGE WITH DEFAULT AND VALIDATE PROPS\n // =========================================================================\n const propsWithDefaults = useMemoMergePropsWithDefault<DSGridT.InternalProps>(propsWithoutChildren, defaultProps);\n // children prop create the Maximum call stack size exceeded inside useMemoMergePropsWithDefault\n propsWithDefaults.children = children;\n // useValidateProps(propsWithDefaults, DSGridPropTypes); // TODO @carusox: Uncomment this line when we have the safety\n // ===========================================================================\n // GLOBAL ATTRIBUTES & XSTYLED PROPS\n // ===========================================================================\n const globalProps = useGetGlobalAttributes<DSGridT.InternalProps>(propsWithDefaults);\n const xstyledProps = useGetXstyledProps(propsWithDefaults);\n\n const { isSpanParent, renderChildren } = useRenderChildren(propsWithDefaults);\n\n return { propsWithDefaults, globalProps, xstyledProps, isSpanParent, renderChildren };\n};\n"],
5
5
  "mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,wBAAwB,oBAAoB,oCAAoC;AAGzF,SAA0B,oBAAoB;AAC9C,SAAS,yBAAyB;AAI3B,MAAM,UAAU,CAAC,UAAyB;AAC/C,QAAM,EAAE,UAAU,GAAG,qBAAqB,IAAI;AAK9C,QAAM,oBAAoB,6BAAoD,sBAAsB,YAAY;AAEhH,oBAAkB,WAAW;AAK7B,QAAM,cAAc,uBAA8C,iBAAiB;AACnF,QAAM,eAAe,mBAAmB,iBAAiB;AAEzD,QAAM,EAAE,cAAc,eAAe,IAAI,kBAAkB,iBAAiB;AAE5E,SAAO,EAAE,mBAAmB,aAAa,cAAc,cAAc,eAAe;AACtF;",
6
6
  "names": []
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/config/useRenderChildren.tsx"],
3
+ "sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/config/useRenderChildren.tsx"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { get } from 'lodash';\nimport { fixSpaceGutter } from '@elliemae/ds-system';\nimport type { DSGridT } from '../react-desc-prop-types.js';\n\nexport const useRenderChildren = (props: DSGridT.InternalProps) => {\n const { children } = props;\n let isSpanParent = true;\n\n const renderChildren = React.Children.map(children, (child: React.ReactNode) => {\n if (\n get(child, 'child.type.name') === 'Grid' ||\n get(child, 'type.displayName') === 'Grid' ||\n parseInt(get(child, 'props.span', '0') as string, 10) > 0\n ) {\n const { width: wc, height: hc, span } = (child as React.ReactElement).props as Required<DSGridT.Props>;\n if (!span) isSpanParent = false;\n // eslint-disable-next-line @typescript-eslint/no-unsafe-argument\n return React.cloneElement(child as React.ReactElement, {\n ...(child as React.ReactElement).props,\n width: fixSpaceGutter(wc),\n height: fixSpaceGutter(hc),\n });\n }\n return child;\n });\n\n return { isSpanParent, renderChildren };\n};\n"],
5
5
  "mappings": "AAAA,YAAY,WAAW;ACAvB,OAAOA,YAAW;AAClB,SAAS,WAAW;AACpB,SAAS,sBAAsB;AAGxB,MAAM,oBAAoB,CAAC,UAAiC;AACjE,QAAM,EAAE,SAAS,IAAI;AACrB,MAAI,eAAe;AAEnB,QAAM,iBAAiBA,OAAM,SAAS,IAAI,UAAU,CAAC,UAA2B;AAC9E,QACE,IAAI,OAAO,iBAAiB,MAAM,UAClC,IAAI,OAAO,kBAAkB,MAAM,UACnC,SAAS,IAAI,OAAO,cAAc,GAAG,GAAa,EAAE,IAAI,GACxD;AACA,YAAM,EAAE,OAAO,IAAI,QAAQ,IAAI,KAAK,IAAK,MAA6B;AACtE,UAAI,CAAC;AAAM,uBAAe;AAE1B,aAAOA,OAAM,aAAa,OAA6B;AAAA,QACrD,GAAI,MAA6B;AAAA,QACjC,OAAO,eAAe,EAAE;AAAA,QACxB,QAAQ,eAAe,EAAE;AAAA,MAC3B,CAAC;AAAA,IACH;AACA,WAAO;AAAA,EACT,CAAC;AAED,SAAO,EAAE,cAAc,eAAe;AACxC;",
6
6
  "names": ["React"]
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/config/useValidateProps.tsx"],
3
+ "sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/config/useValidateProps.tsx"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import type { WeakValidationMap } from 'react';\nimport { useValidateTypescriptPropTypes } from '@elliemae/ds-props-helpers';\nimport type { DSGridT } from '../react-desc-prop-types.js';\nimport { DSGridName } from '../DSGridDefinitions.js';\n\nexport const useValidateProps = (props: DSGridT.InternalProps, propTypes: WeakValidationMap<unknown>) => {\n useValidateTypescriptPropTypes(props, propTypes, DSGridName);\n};\n"],
5
5
  "mappings": "AAAA,YAAY,WAAW;ACCvB,SAAS,sCAAsC;AAE/C,SAAS,kBAAkB;AAEpB,MAAM,mBAAmB,CAAC,OAA8B,cAA0C;AACvG,iCAA+B,OAAO,WAAW,UAAU;AAC7D;",
6
6
  "names": []
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../scripts/build/transpile/react-shim.js", "../../src/index.tsx"],
3
+ "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/index.tsx"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import type {} from '@xstyled/system';\nimport Grid, { DSGridWithSchema } from './Grid.js';\n\nexport default Grid;\nexport { Grid, Grid as GridContainer, Grid as GridItem, DSGridWithSchema };\n"],
5
5
  "mappings": "AAAA,YAAY,WAAW;ACCvB,OAAO,QAAQ,wBAAwB;AAEvC,IAAO,cAAQ;",
6
6
  "names": []
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../scripts/build/transpile/react-shim.js", "../../src/react-desc-prop-types.tsx"],
3
+ "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../src/react-desc-prop-types.tsx"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import type { WeakValidationMap } from 'react';\nimport type React from 'react';\nimport type {} from '@elliemae/ds-utilities';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-props-helpers';\nimport { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from '@elliemae/ds-props-helpers';\nimport { alignItemsPlacement, justifyPlacement, wrap, boxShadow } from './utils/constants.js';\n\nexport declare namespace DSGridT {\n interface RowColBreakpoints {\n small?: string | number | (string | number)[];\n medium?: string | number | (string | number)[];\n large?: string | number | (string | number)[];\n }\n\n interface SpanBreakpoints {\n small?: number;\n medium?: number;\n large?: number;\n }\n\n type JustifyPlacement = 'flex-start' | 'center' | 'flex-end' | 'space-between' | 'space-around' | 'space-evenly';\n type AlignItemsPlacement = 'flex-start' | 'center' | 'flex-end' | 'stretch' | 'baseline';\n type Wrap = 'wrap' | 'nowrap' | 'wrap-reverse';\n type BoxShadow = 'xs' | 's' | 'm' | 'l' | 'xl';\n\n export interface DefaultProps {\n rows: string[] | string | number[] | RowColBreakpoints;\n cols: string[] | string | number[] | RowColBreakpoints;\n className: string;\n justify: JustifyPlacement;\n gutter: string | number;\n wrap: Wrap;\n span: number;\n justifyItems: string;\n }\n\n export interface OptionalProps {\n height?: string | number;\n width?: string | number;\n justifyContent?: JustifyPlacement;\n alignItems?: AlignItemsPlacement;\n children?: React.ReactNode;\n withMaxWidthBreakpoints?: boolean;\n rowGap?: string | number;\n }\n\n export interface Props\n extends Partial<DefaultProps>,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLDivElement>, keyof DefaultProps | keyof OptionalProps | keyof XstyledProps>,\n XstyledProps {}\n\n export interface InternalProps\n extends DefaultProps,\n OptionalProps,\n Omit<GlobalAttributesT<HTMLDivElement>, keyof DefaultProps | keyof OptionalProps | keyof XstyledProps>,\n XstyledProps {}\n\n export interface ItemProps {\n rows: string[] | string | number[] | RowColBreakpoints;\n cols: string[] | string | number[] | RowColBreakpoints;\n alignItems: AlignItemsPlacement;\n children: React.ReactNode;\n className: string;\n justify: JustifyPlacement;\n gutter: string | number;\n wrap: Wrap;\n childNumber: number;\n isSpanParent: boolean;\n span?: number | SpanBreakpoints;\n ref: React.ForwardedRef<HTMLDivElement>;\n boxShadow?: BoxShadow;\n backgroundColor?: string;\n bg?: string;\n withMaxWidthBreakpoints?: boolean;\n }\n}\n\nexport const defaultProps: DSGridT.DefaultProps = {\n rows: [],\n cols: [],\n className: '',\n justify: 'flex-start',\n gutter: 0,\n wrap: 'wrap',\n span: 1,\n justifyItems: 'normal',\n};\n\n// =============================================================================\n// PropTypes\n// =============================================================================\nconst rowColBreakpoints = PropTypes.shape({\n small: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])),\n medium: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])),\n large: PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])),\n});\n\nconst spanBreakpoints = PropTypes.shape({\n small: PropTypes.number,\n medium: PropTypes.number,\n large: PropTypes.number,\n});\n\nexport const DSGridPropTypes = {\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n rows: PropTypes.oneOfType([\n PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])),\n PropTypes.number,\n rowColBreakpoints,\n ])\n .description('Row layout cells')\n .defaultValue([]),\n cols: PropTypes.oneOfType([\n PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.number, PropTypes.string])),\n PropTypes.number,\n rowColBreakpoints,\n ])\n .description('Column layout cells')\n .defaultValue([]),\n span: PropTypes.oneOfType([PropTypes.number, spanBreakpoints]).description(\n 'Expands the grid element within columns.',\n ),\n alignItems: PropTypes.oneOf(alignItemsPlacement).description('flex-like align items prop'),\n children: PropTypes.node.description('Children node inside grid cell'),\n className: PropTypes.string.description('CSS class').defaultValue(''),\n justifyContent: PropTypes.oneOf(justifyPlacement)\n .description('flex-like justify prop')\n .defaultValue(justifyPlacement[0]),\n gutter: PropTypes.oneOfType([PropTypes.number, PropTypes.string])\n .description('Space between cells prop')\n .defaultValue(0),\n wrap: PropTypes.oneOf(wrap).description('Wrap type').defaultValue(wrap[0]),\n withMaxWidthBreakpoints: PropTypes.bool.description('weather use max width').defaultValue(undefined),\n height: PropTypes.oneOfType([PropTypes.number, PropTypes.string]).description('Grid height.'),\n width: PropTypes.oneOfType([PropTypes.number, PropTypes.string]).description('Grid width.'),\n backgroundColor: PropTypes.string.description('Sets background color.'),\n bg: PropTypes.string.description('Sets background color.'),\n boxShadow: PropTypes.oneOf(boxShadow).description('Sets background color.'),\n border: PropTypes.string.description('Sets border.'),\n borderRadius: PropTypes.string.description('Sets border radius.'),\n borderWidth: PropTypes.string.description('Sets border width.'),\n borderStyle: PropTypes.string.description('Sets border style.'),\n borderColor: PropTypes.string.description('Sets border color.'),\n borderTop: PropTypes.string.description('Sets top border.'),\n borderBottom: PropTypes.string.description('Sets bottom border.'),\n borderLeft: PropTypes.string.description('Sets left border.'),\n borderRight: PropTypes.string.description('Sets right border.'),\n borderTopWidth: PropTypes.string.description('Sets border top width.'),\n borderTopStyle: PropTypes.string.description('Sets border top style.'),\n borderTopColor: PropTypes.string.description('Sets border top color.'),\n borderBottomWidth: PropTypes.string.description('Sets border bottom width.'),\n borderBottomStyle: PropTypes.string.description('Sets border bottom style.'),\n borderBottomColor: PropTypes.string.description('Sets border bottom color.'),\n borderRightWidth: PropTypes.string.description('Sets border right width.'),\n borderRightStyle: PropTypes.string.description('Sets border right style.'),\n borderRightColor: PropTypes.string.description('Sets border right color.'),\n borderLeftWidth: PropTypes.string.description('Sets border left width.'),\n borderLeftStyle: PropTypes.string.description('Sets border left style.'),\n borderLeftColor: PropTypes.string.description('Sets border left color.'),\n} as WeakValidationMap<unknown>;\n"],
5
5
  "mappings": "AAAA,YAAY,WAAW;ACIvB,SAAS,WAAW,2BAA2B,wBAAwB;AACvE,SAAS,qBAAqB,kBAAkB,MAAM,iBAAiB;AAyEhE,MAAM,eAAqC;AAAA,EAChD,MAAM,CAAC;AAAA,EACP,MAAM,CAAC;AAAA,EACP,WAAW;AAAA,E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AAU,OAAO,YAAY,2BAA2B;AAAA,EAC3E,mBAAmB,UAAU,OAAO,YAAY,2BAA2B;AAAA,EAC3E,mBAAmB,UAAU,OAAO,YAAY,2BAA2B;AAAA,EAC3E,kBAAkB,UAAU,OAAO,YAAY,0BAA0B;AAAA,EACzE,kBAAkB,UAAU,OAAO,YAAY,0BAA0B;AAAA,EACzE,kBAAkB,UAAU,OAAO,YAAY,0BAA0B;AAAA,EACzE,iBAAiB,UAAU,OAAO,YAAY,yBAAyB;AAAA,EACvE,iBAAiB,UAAU,OAAO,YAAY,yBAAyB;AAAA,EACvE,iBAAiB,UAAU,OAAO,YAAY,yBAAyB;AACzE;",
6
6
  "names": []
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/utils/constants.tsx"],
3
+ "sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/utils/constants.tsx"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export const justifyPlacement = ['flex-start', 'center', 'flex-end', 'space-between', 'space-around', 'space-evenly'];\n\nexport const alignItemsPlacement = ['flex-start', 'center', 'flex-end', 'stretch', 'baseline'];\n\nexport const wrap = ['wrap', 'nowrap', 'wrap-reverse'];\n\nexport const boxShadow = ['xs', 's', 'm', 'l', 'xl'];\n"],
5
5
  "mappings": "AAAA,YAAY,WAAW;ACAhB,MAAM,mBAAmB,CAAC,cAAc,UAAU,YAAY,iBAAiB,gBAAgB,cAAc;AAE7G,MAAM,sBAAsB,CAAC,cAAc,UAAU,YAAY,WAAW,UAAU;AAEtF,MAAM,OAAO,CAAC,QAAQ,UAAU,cAAc;AAE9C,MAAM,YAAY,CAAC,MAAM,KAAK,KAAK,KAAK,IAAI;",
6
6
  "names": []
@@ -26,11 +26,9 @@ const generateColsWithMediaQueries = (cols, theme, isSpanParent) => {
26
26
  }
27
27
  finalMediaDeclaration.push(theme.media.large`${cssString}`);
28
28
  if (finalMediaDeclaration.length === 0)
29
- finalMediaDeclaration.push(
30
- css`
31
- ${cssString}
32
- `
33
- );
29
+ finalMediaDeclaration.push(css`
30
+ ${cssString}
31
+ `);
34
32
  }
35
33
  if (cols.medium) {
36
34
  let cssString = "";
@@ -41,11 +39,9 @@ const generateColsWithMediaQueries = (cols, theme, isSpanParent) => {
41
39
  }
42
40
  finalMediaDeclaration.push(theme.media.medium`${cssString}`);
43
41
  if (finalMediaDeclaration.length === 0)
44
- finalMediaDeclaration.push(
45
- css`
46
- ${cssString}
47
- `
48
- );
42
+ finalMediaDeclaration.push(css`
43
+ ${cssString}
44
+ `);
49
45
  }
50
46
  if (cols.small) {
51
47
  let cssString = "";
@@ -56,11 +52,9 @@ const generateColsWithMediaQueries = (cols, theme, isSpanParent) => {
56
52
  }
57
53
  finalMediaDeclaration.push(theme.media.small`${cssString}`);
58
54
  if (finalMediaDeclaration.length === 0)
59
- finalMediaDeclaration.push(
60
- css`
61
- ${cssString}
62
- `
63
- );
55
+ finalMediaDeclaration.push(css`
56
+ ${cssString}
57
+ `);
64
58
  }
65
59
  return finalMediaDeclaration;
66
60
  };
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/utils/manageCols.tsx"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-statements */\n/* eslint-disable complexity */\nimport { css, mapTemplateGrid } from '@elliemae/ds-system';\nimport type { DSGridT } from '../react-desc-prop-types.js';\nimport type { Theme } from '@elliemae/pui-theme';\n\ntype BreakPointObject = {\n large?: string | number | (string | number)[];\n medium?: string | number | (string | number)[];\n small?: string | number | (string | number)[];\n};\n// this typeguard is not extremely accurate but it has historically been like this and we need to avoid breaking changes\nconst colsIsBreakpointDefinition = (cols: unknown): cols is BreakPointObject =>\n typeof cols === 'object' && !Array.isArray(cols);\ntype InterpolatedFunctionProps = {\n theme: Theme;\n} & DSGridT.ItemProps;\n\nconst generateColsCssStringForArray = (colsVal: (string | number)[]): string => {\n // mtg and mtgs are used to support mapping different ways of defining the cols\n // when mtg produces valid css, mtgs will produce invalid css and vice-versa\n // only one of them will be effectively applied by the browser\n const mtg = (mapTemplateGrid(colsVal) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(colsVal) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n return `\n -ms-grid-columns: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtg || 'auto'};\n -ms-grid-columns: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtgs || 'auto'};\n `;\n};\nconst generateColsCssStringForBootstrapLikeishScenario = (colsVal: string | number): string => `\n -ms-grid-columns: repeat(${colsVal}, 1fr);\n grid-template-columns: repeat(${colsVal}, 1fr);\n `;\nconst generateColsWithMediaQueries = (\n cols: BreakPointObject,\n theme: Theme,\n isSpanParent: boolean,\n): ReturnType<typeof css>[] => {\n const finalMediaDeclaration: ReturnType<typeof css>[] = [];\n // we conditionally push into the array the media queries because grid cols definitions supports partial definitions\n // meaning that you can define cols only for small and medium and not for large\n // in such case we want to avoid generating media queries for large\n // we also need to make sure that the largest definition is used as the default one\n if (cols.large) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(cols.large)) {\n cssString = generateColsCssStringForArray(cols.large);\n } else if (isSpanParent) {\n cssString = generateColsCssStringForBootstrapLikeishScenario(cols.large);\n }\n finalMediaDeclaration.push(theme.media.large`${cssString}`);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n }\n if (cols.medium) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(cols.medium)) {\n cssString = generateColsCssStringForArray(cols.medium);\n } else if (isSpanParent) {\n cssString = generateColsCssStringForBootstrapLikeishScenario(cols.medium);\n }\n finalMediaDeclaration.push(theme.media.medium`${cssString}`);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n }\n if (cols.small) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(cols.small)) {\n cssString = generateColsCssStringForArray(cols.small);\n } else if (isSpanParent) {\n cssString = generateColsCssStringForBootstrapLikeishScenario(cols.small);\n }\n finalMediaDeclaration.push(theme.media.small`${cssString}`);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n }\n return finalMediaDeclaration;\n};\n\nexport const manageColsV2 = ({ cols, theme, isSpanParent }: InterpolatedFunctionProps): ReturnType<typeof css>[] => {\n // we want to be extremely explicit with how we handle the different use-cases\n // the component is quite old and has been tailored to fit the needs of the different use-cases\n // even ones that should have not been supported in the first place (isSpanParent to simulate bootstrap, different kind of cols definitions, etc)\n // support for\n // cols:{small: 1, medium: 2, large: 3}\n // AND\n // cols: {small: ['1fr'], medium: ['160px'], large: ['400px'] }\n if (colsIsBreakpointDefinition(cols)) {\n // there is no way to guarantee dynamic co-relation between pui-theme and the grid component\n // any change in the theme will break the co-relation and we would need to update the component\n // for such reason we are optimizing for maintainability and not scalability\n return generateColsWithMediaQueries(cols, theme, isSpanParent);\n }\n\n // support for cols: ['1fr', '1fr', '1fr'] && cols: [1, 1, 1]\n if (Array.isArray(cols)) {\n const cssString = generateColsCssStringForArray(cols);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // support for parent is span and is like cols: 3\n if (isSpanParent) {\n const cssString = generateColsCssStringForBootstrapLikeishScenario(cols);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // fallback is not doing anything\n return [css``];\n};\n"],
5
- "mappings": "AAAA,Y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AAChB,QAAI,MAAM,QAAQ,KAAK,KAAK,GAAG;AAC7B,kBAAY,8BAA8B,KAAK,KAAK;AAAA,IACtD,WAAW,cAAc;AACvB,kBAAY,iDAAiD,KAAK,KAAK;AAAA,IACzE;AACA,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAC1D,QAAI,sBAAsB,WAAW;AACnC,4BAAsB;AAAA,QACpB;AAAA,YACI;AAAA;AAAA,MAEN;AAAA,EACJ;AACA,SAAO;AACT;AAEO,MAAM,eAAe,CAAC,EAAE,MAAM,OAAO,aAAa,MAA2D;AAQlH,MAAI,2BAA2B,IAAI,GAAG;AAIpC,WAAO,6BAA6B,MAAM,OAAO,YAAY;AAAA,EAC/D;AAGA,MAAI,MAAM,QAAQ,IAAI,GAAG;AACvB,UAAM,YAAY,8BAA8B,IAAI;AACpD,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,MAAI,cAAc;AAChB,UAAM,YAAY,iDAAiD,IAAI;AACvE,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,SAAO,CAAC,KAAK;AACf;",
3
+ "sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/utils/manageCols.tsx"],
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-statements */\n/* eslint-disable complexity */\nimport { css, mapTemplateGrid } from '@elliemae/ds-system';\nimport type { DSGridT } from '../react-desc-prop-types.js';\nimport type { Theme } from '@elliemae/pui-theme';\n\ntype BreakPointObject = {\n large?: string | number | (string | number)[];\n medium?: string | number | (string | number)[];\n small?: string | number | (string | number)[];\n};\n// this typeguard is not extremely accurate but it has historically been like this and we need to avoid breaking changes\nconst colsIsBreakpointDefinition = (cols: unknown): cols is BreakPointObject =>\n typeof cols === 'object' && !Array.isArray(cols);\ntype InterpolatedFunctionProps = {\n theme: Theme;\n} & DSGridT.ItemProps;\n\nconst generateColsCssStringForArray = (colsVal: (string | number)[]): string => {\n // mtg and mtgs are used to support mapping different ways of defining the cols\n // when mtg produces valid css, mtgs will produce invalid css and vice-versa\n // only one of them will be effectively applied by the browser\n const mtg = (mapTemplateGrid(colsVal) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(colsVal) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n return `\n -ms-grid-columns: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtg || 'auto'};\n -ms-grid-columns: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtgs || 'auto'};\n `;\n};\nconst generateColsCssStringForBootstrapLikeishScenario = (colsVal: string | number): string => `\n -ms-grid-columns: repeat(${colsVal}, 1fr);\n grid-template-columns: repeat(${colsVal}, 1fr);\n `;\nconst generateColsWithMediaQueries = (\n cols: BreakPointObject,\n theme: Theme,\n isSpanParent: boolean,\n): ReturnType<typeof css>[] => {\n const finalMediaDeclaration: ReturnType<typeof css>[] = [];\n // we conditionally push into the array the media queries because grid cols definitions supports partial definitions\n // meaning that you can define cols only for small and medium and not for large\n // in such case we want to avoid generating media queries for large\n // we also need to make sure that the largest definition is used as the default one\n if (cols.large) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(cols.large)) {\n cssString = generateColsCssStringForArray(cols.large);\n } else if (isSpanParent) {\n cssString = generateColsCssStringForBootstrapLikeishScenario(cols.large);\n }\n finalMediaDeclaration.push(theme.media.large`${cssString}`);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n }\n if (cols.medium) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(cols.medium)) {\n cssString = generateColsCssStringForArray(cols.medium);\n } else if (isSpanParent) {\n cssString = generateColsCssStringForBootstrapLikeishScenario(cols.medium);\n }\n finalMediaDeclaration.push(theme.media.medium`${cssString}`);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n }\n if (cols.small) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(cols.small)) {\n cssString = generateColsCssStringForArray(cols.small);\n } else if (isSpanParent) {\n cssString = generateColsCssStringForBootstrapLikeishScenario(cols.small);\n }\n finalMediaDeclaration.push(theme.media.small`${cssString}`);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n }\n return finalMediaDeclaration;\n};\n\nexport const manageColsV2 = ({ cols, theme, isSpanParent }: InterpolatedFunctionProps): ReturnType<typeof css>[] => {\n // we want to be extremely explicit with how we handle the different use-cases\n // the component is quite old and has been tailored to fit the needs of the different use-cases\n // even ones that should have not been supported in the first place (isSpanParent to simulate bootstrap, different kind of cols definitions, etc)\n // support for\n // cols:{small: 1, medium: 2, large: 3}\n // AND\n // cols: {small: ['1fr'], medium: ['160px'], large: ['400px'] }\n if (colsIsBreakpointDefinition(cols)) {\n // there is no way to guarantee dynamic co-relation between pui-theme and the grid component\n // any change in the theme will break the co-relation and we would need to update the component\n // for such reason we are optimizing for maintainability and not scalability\n return generateColsWithMediaQueries(cols, theme, isSpanParent);\n }\n\n // support for cols: ['1fr', '1fr', '1fr'] && cols: [1, 1, 1]\n if (Array.isArray(cols)) {\n const cssString = generateColsCssStringForArray(cols);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // support for parent is span and is like cols: 3\n if (isSpanParent) {\n const cssString = generateColsCssStringForBootstrapLikeishScenario(cols);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // fallback is not doing anything\n return [css``];\n};\n"],
5
+ "mappings": "AAAA,YAAY,WAAW;ACEvB,SAAS,K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BAAY,8BAA8B,KAAK,KAAK;AAAA,IACtD,WAAW,cAAc;AACvB,kBAAY,iDAAiD,KAAK,KAAK;AAAA,IACzE;AACA,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAC1D,QAAI,sBAAsB,WAAW;AACnC,4BAAsB,KAAK;AAAA,UACvB;AAAA,OACH;AAAA,EACL;AACA,SAAO;AACT;AAEO,MAAM,eAAe,CAAC,EAAE,MAAM,OAAO,aAAa,MAA2D;AAQlH,MAAI,2BAA2B,IAAI,GAAG;AAIpC,WAAO,6BAA6B,MAAM,OAAO,YAAY;AAAA,EAC/D;AAGA,MAAI,MAAM,QAAQ,IAAI,GAAG;AACvB,UAAM,YAAY,8BAA8B,IAAI;AACpD,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,MAAI,cAAc;AAChB,UAAM,YAAY,iDAAiD,IAAI;AACvE,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,SAAO,CAAC,KAAK;AACf;",
6
6
  "names": []
7
7
  }
@@ -25,11 +25,9 @@ const generateRowsWithMediaQueries = (rows, theme, isSpanParent) => {
25
25
  cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.large);
26
26
  }
27
27
  if (finalMediaDeclaration.length === 0)
28
- finalMediaDeclaration.push(
29
- css`
30
- ${cssString}
31
- `
32
- );
28
+ finalMediaDeclaration.push(css`
29
+ ${cssString}
30
+ `);
33
31
  finalMediaDeclaration.push(theme.media.large`${cssString}`);
34
32
  }
35
33
  if (rows.medium) {
@@ -40,11 +38,9 @@ const generateRowsWithMediaQueries = (rows, theme, isSpanParent) => {
40
38
  cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.medium);
41
39
  }
42
40
  if (finalMediaDeclaration.length === 0)
43
- finalMediaDeclaration.push(
44
- css`
45
- ${cssString}
46
- `
47
- );
41
+ finalMediaDeclaration.push(css`
42
+ ${cssString}
43
+ `);
48
44
  finalMediaDeclaration.push(theme.media.medium`${cssString}`);
49
45
  }
50
46
  if (rows.small) {
@@ -55,11 +51,9 @@ const generateRowsWithMediaQueries = (rows, theme, isSpanParent) => {
55
51
  cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.small);
56
52
  }
57
53
  if (finalMediaDeclaration.length === 0)
58
- finalMediaDeclaration.push(
59
- css`
60
- ${cssString}
61
- `
62
- );
54
+ finalMediaDeclaration.push(css`
55
+ ${cssString}
56
+ `);
63
57
  finalMediaDeclaration.push(theme.media.small`${cssString}`);
64
58
  }
65
59
  return finalMediaDeclaration;
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/utils/manageRows.tsx"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-statements */\n/* eslint-disable complexity */\nimport { css, mapTemplateGrid } from '@elliemae/ds-system';\nimport type { DSGridT } from '../react-desc-prop-types.js';\nimport type { Theme } from '@elliemae/pui-theme';\n\ntype BreakPointObject = {\n large?: string | number | (string | number)[];\n medium?: string | number | (string | number)[];\n small?: string | number | (string | number)[];\n};\n// this typeguard is not extremely accurate but it has historically been like this and we need to avoid breaking changes\nconst rowsIsBreakpointDefinition = (rows: unknown): rows is BreakPointObject =>\n typeof rows === 'object' && !Array.isArray(rows);\ntype InterpolatedFunctionProps = {\n theme: Theme;\n} & DSGridT.ItemProps;\n\nconst generateRowsCssStringForArray = (rowsVal: (string | number)[]): string => {\n // mtg and mtgs are used to support mapping different ways of defining the rows\n // when mtg produces valid css, mtgs will produce invalid css and vice-versa\n // only one of them will be effectively applied by the browser\n const mtg = (mapTemplateGrid(rowsVal) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(rowsVal) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n return `\n -ms-grid-rows: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtg || 'auto'};\n -ms-grid-rows: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtgs || 'auto'};\n `;\n};\nconst generateRowsCssStringForBootstrapLikeishScenario = (rowsVal: string | number): string => `\n -ms-grid-rows: repeat(${rowsVal}, 1fr);\n grid-template-rows: repeat(${rowsVal}, 1fr);\n `;\nconst generateRowsWithMediaQueries = (\n rows: BreakPointObject,\n theme: Theme,\n isSpanParent: boolean,\n): ReturnType<typeof css>[] => {\n const finalMediaDeclaration: ReturnType<typeof css>[] = [];\n // we conditionally push into the array the media queries because grid rows definitions supports partial definitions\n // meaning that you can define rows only for small and medium and not for large\n // in such case we want to avoid generating media queries for large\n // we also need to make sure that the largest definition is used as the default one\n if (rows.large) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(rows.large)) {\n cssString = generateRowsCssStringForArray(rows.large);\n } else if (isSpanParent) {\n cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.large);\n }\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n finalMediaDeclaration.push(theme.media.large`${cssString}`);\n }\n if (rows.medium) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(rows.medium)) {\n cssString = generateRowsCssStringForArray(rows.medium);\n } else if (isSpanParent) {\n cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.medium);\n }\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n finalMediaDeclaration.push(theme.media.medium`${cssString}`);\n }\n if (rows.small) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(rows.small)) {\n cssString = generateRowsCssStringForArray(rows.small);\n } else if (isSpanParent) {\n cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.small);\n }\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n finalMediaDeclaration.push(theme.media.small`${cssString}`);\n }\n return finalMediaDeclaration;\n};\n\nexport const manageRowsV2 = ({ rows, theme, isSpanParent }: InterpolatedFunctionProps): ReturnType<typeof css>[] => {\n // we want to be extremely explicit with how we handle the different use-cases\n // the component is quite old and has been tailored to fit the needs of the different use-cases\n // even ones that should have not been supported in the first place (isSpanParent to simulate bootstrap, different kind of rows definitions, etc)\n // support for\n // rows:{small: 1, medium: 2, large: 3}\n // AND\n // rows: {small: ['1fr'], medium: ['160px'], large: ['400px'] }\n if (rowsIsBreakpointDefinition(rows)) {\n // there is no way to guarantee dynamic co-relation between pui-theme and the grid component\n // any change in the theme will break the co-relation and we would need to update the component\n // for such reason we are optimizing for maintainability and not scalability\n return generateRowsWithMediaQueries(rows, theme, isSpanParent);\n }\n\n // support for rows: ['1fr', '1fr', '1fr'] && rows: [1, 1, 1]\n if (Array.isArray(rows)) {\n const cssString = generateRowsCssStringForArray(rows);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // support for parent is span and is like rows: 3\n if (isSpanParent) {\n const cssString = generateRowsCssStringForBootstrapLikeishScenario(rows);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // fallback is not doing anything\n return [css``];\n};\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACEvB,SAAS,KAAK,uBAAuB;AAUrC,MAAM,6BAA6B,CAAC,SAClC,OAAO,SAAS,YAAY,CAAC,MAAM,QAAQ,IAAI;AAKjD,MAAM,gCAAgC,CAAC,YAAyC;AAI9E,QAAM,MAAO,gBAAgB,OAAO,EAAe,KAAK,GAAG;AAC3D,QAAM,OAAQ,gBAAgB,OAAO,EAAe,IAAI,CAAC,MAAM,aAAa,IAAI,EAAE,KAAK,GAAG;AAC1F,SAAO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MAAM,eAAe,CAAC,EAAE,MAAM,OAAO,aAAa,MAA2D;AAQlH,MAAI,2BAA2B,IAAI,GAAG;AAIpC,WAAO,6BAA6B,MAAM,OAAO,YAAY;AAAA,EAC/D;AAGA,MAAI,MAAM,QAAQ,IAAI,GAAG;AACvB,UAAM,YAAY,8BAA8B,IAAI;AACpD,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,MAAI,cAAc;AAChB,UAAM,YAAY,iDAAiD,IAAI;AACvE,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,SAAO,CAAC,KAAK;AACf;",
3
+ "sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/utils/manageRows.tsx"],
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-statements */\n/* eslint-disable complexity */\nimport { css, mapTemplateGrid } from '@elliemae/ds-system';\nimport type { DSGridT } from '../react-desc-prop-types.js';\nimport type { Theme } from '@elliemae/pui-theme';\n\ntype BreakPointObject = {\n large?: string | number | (string | number)[];\n medium?: string | number | (string | number)[];\n small?: string | number | (string | number)[];\n};\n// this typeguard is not extremely accurate but it has historically been like this and we need to avoid breaking changes\nconst rowsIsBreakpointDefinition = (rows: unknown): rows is BreakPointObject =>\n typeof rows === 'object' && !Array.isArray(rows);\ntype InterpolatedFunctionProps = {\n theme: Theme;\n} & DSGridT.ItemProps;\n\nconst generateRowsCssStringForArray = (rowsVal: (string | number)[]): string => {\n // mtg and mtgs are used to support mapping different ways of defining the rows\n // when mtg produces valid css, mtgs will produce invalid css and vice-versa\n // only one of them will be effectively applied by the browser\n const mtg = (mapTemplateGrid(rowsVal) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(rowsVal) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n return `\n -ms-grid-rows: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtg || 'auto'};\n -ms-grid-rows: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtgs || 'auto'};\n `;\n};\nconst generateRowsCssStringForBootstrapLikeishScenario = (rowsVal: string | number): string => `\n -ms-grid-rows: repeat(${rowsVal}, 1fr);\n grid-template-rows: repeat(${rowsVal}, 1fr);\n `;\nconst generateRowsWithMediaQueries = (\n rows: BreakPointObject,\n theme: Theme,\n isSpanParent: boolean,\n): ReturnType<typeof css>[] => {\n const finalMediaDeclaration: ReturnType<typeof css>[] = [];\n // we conditionally push into the array the media queries because grid rows definitions supports partial definitions\n // meaning that you can define rows only for small and medium and not for large\n // in such case we want to avoid generating media queries for large\n // we also need to make sure that the largest definition is used as the default one\n if (rows.large) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(rows.large)) {\n cssString = generateRowsCssStringForArray(rows.large);\n } else if (isSpanParent) {\n cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.large);\n }\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n finalMediaDeclaration.push(theme.media.large`${cssString}`);\n }\n if (rows.medium) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(rows.medium)) {\n cssString = generateRowsCssStringForArray(rows.medium);\n } else if (isSpanParent) {\n cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.medium);\n }\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n finalMediaDeclaration.push(theme.media.medium`${cssString}`);\n }\n if (rows.small) {\n // we apply different styles for defintions that are arrays and definitions that are not\n // specifically when the definition are NOT arrays we check if the parent is a span tag\n // if it is we try to copy bootstrap's behavior and use repeat css grid function\n let cssString = '';\n if (Array.isArray(rows.small)) {\n cssString = generateRowsCssStringForArray(rows.small);\n } else if (isSpanParent) {\n cssString = generateRowsCssStringForBootstrapLikeishScenario(rows.small);\n }\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n finalMediaDeclaration.push(theme.media.small`${cssString}`);\n }\n return finalMediaDeclaration;\n};\n\nexport const manageRowsV2 = ({ rows, theme, isSpanParent }: InterpolatedFunctionProps): ReturnType<typeof css>[] => {\n // we want to be extremely explicit with how we handle the different use-cases\n // the component is quite old and has been tailored to fit the needs of the different use-cases\n // even ones that should have not been supported in the first place (isSpanParent to simulate bootstrap, different kind of rows definitions, etc)\n // support for\n // rows:{small: 1, medium: 2, large: 3}\n // AND\n // rows: {small: ['1fr'], medium: ['160px'], large: ['400px'] }\n if (rowsIsBreakpointDefinition(rows)) {\n // there is no way to guarantee dynamic co-relation between pui-theme and the grid component\n // any change in the theme will break the co-relation and we would need to update the component\n // for such reason we are optimizing for maintainability and not scalability\n return generateRowsWithMediaQueries(rows, theme, isSpanParent);\n }\n\n // support for rows: ['1fr', '1fr', '1fr'] && rows: [1, 1, 1]\n if (Array.isArray(rows)) {\n const cssString = generateRowsCssStringForArray(rows);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // support for parent is span and is like rows: 3\n if (isSpanParent) {\n const cssString = generateRowsCssStringForBootstrapLikeishScenario(rows);\n return [\n css`\n ${cssString}\n `,\n ];\n }\n // fallback is not doing anything\n return [css``];\n};\n"],
5
+ "mappings": "AAAA,YAAY,WAAW;ACEvB,SAAS,KAAK,uBAAuB;AAUrC,MAAM,6BAA6B,CAAC,SAClC,OAAO,SAAS,YAAY,CAAC,MAAM,QAAQ,IAAI;AAKjD,MAAM,gCAAgC,CAAC,YAAyC;AAI9E,QAAM,MAAO,gBAAgB,OAAO,EAAe,KAAK,GAAG;AAC3D,QAAM,OAAQ,gBAAgB,OAAO,EAAe,IAAI,CAAC,MAAM,aAAa,IAAI,EAAE,KAAK,GAAG;AAC1F,SAAO;AAAA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MAA2D;AAQlH,MAAI,2BAA2B,IAAI,GAAG;AAIpC,WAAO,6BAA6B,MAAM,OAAO,YAAY;AAAA,EAC/D;AAGA,MAAI,MAAM,QAAQ,IAAI,GAAG;AACvB,UAAM,YAAY,8BAA8B,IAAI;AACpD,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,MAAI,cAAc;AAChB,UAAM,YAAY,iDAAiD,IAAI;AACvE,WAAO;AAAA,MACL;AAAA,UACI;AAAA;AAAA,IAEN;AAAA,EACF;AAEA,SAAO,CAAC,KAAK;AACf;",
6
6
  "names": []
7
7
  }
@@ -25,31 +25,25 @@ const manageSpanParent = ({
25
25
  if (span.large) {
26
26
  const cssString = generateCssStringForSpan(span.large);
27
27
  if (finalMediaDeclaration.length === 0)
28
- finalMediaDeclaration.push(
29
- css`
30
- ${cssString}
31
- `
32
- );
28
+ finalMediaDeclaration.push(css`
29
+ ${cssString}
30
+ `);
33
31
  finalMediaDeclaration.push(theme.media.large`${cssString}`);
34
32
  }
35
33
  if (span.medium) {
36
34
  const cssString = generateCssStringForSpan(span.medium);
37
35
  if (finalMediaDeclaration.length === 0)
38
- finalMediaDeclaration.push(
39
- css`
40
- ${cssString}
41
- `
42
- );
36
+ finalMediaDeclaration.push(css`
37
+ ${cssString}
38
+ `);
43
39
  finalMediaDeclaration.push(theme.media.medium`${cssString}`);
44
40
  }
45
41
  if (span.small) {
46
42
  const cssString = generateCssStringForSpan(span.small);
47
43
  if (finalMediaDeclaration.length === 0)
48
- finalMediaDeclaration.push(
49
- css`
50
- ${cssString}
51
- `
52
- );
44
+ finalMediaDeclaration.push(css`
45
+ ${cssString}
46
+ `);
53
47
  finalMediaDeclaration.push(theme.media.small`${cssString}`);
54
48
  }
55
49
  return finalMediaDeclaration;
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/utils/manageSpanParent.tsx"],
4
- "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-statements */\n/* eslint-disable max-lines */\n/* eslint-disable complexity */\nimport { css } from '@elliemae/ds-system';\nimport type { Theme } from '@elliemae/pui-theme';\nimport type { DSGridT } from '../react-desc-prop-types.js';\n\ntype InterpolatedFunctionProps = {\n theme: Theme;\n} & DSGridT.ItemProps;\n\nconst generateCssStringForSpan = (span: number): string => `\n -ms-grid-column: auto / span ${span};\n grid-column: auto / span ${span};\n`;\n// This is used to support bootrap like-ish way of using the grid component\nexport const manageSpanParent = ({\n isSpanParent,\n span,\n theme,\n}: InterpolatedFunctionProps): ReturnType<typeof css>[] => {\n // If it's not a span parent, we don't need to do anything\n if (!isSpanParent) return [css``];\n\n // if span is a number we don't add media queries\n if (typeof span === 'number') {\n return [\n css`\n -ms-grid-column: auto / span ${span};\n grid-column: auto / span ${span};\n `,\n ];\n }\n // the only remaining valid definition for our supported types is an object, if it's not an object we fallback to doing nothing\n if (typeof span !== 'object') return [css``];\n\n // Span object\n\n const finalMediaDeclaration: ReturnType<typeof css>[] = [];\n // we conditionally push into the array the media queries because span definitions supports partial definitions\n // meaning that you can define spans only for small and medium and not for large\n // in such case we want to avoid generating media queries for large\n // we also need to make sure that the largest definition is used as the default one\n if (span.large) {\n const cssString = generateCssStringForSpan(span.large);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n finalMediaDeclaration.push(theme.media.large`${cssString}`);\n }\n if (span.medium) {\n const cssString = generateCssStringForSpan(span.medium);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n finalMediaDeclaration.push(theme.media.medium`${cssString}`);\n }\n if (span.small) {\n const cssString = generateCssStringForSpan(span.small);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(\n css`\n ${cssString}\n `,\n );\n finalMediaDeclaration.push(theme.media.small`${cssString}`);\n }\n return finalMediaDeclaration;\n};\n"],
5
- "mappings": "AAAA,YAAY,WAAW;ACGvB,SAAS,WAAW;AAQpB,MAAM,2BAA2B,CAAC,SAAyB;AAAA,iCAC1B;AAAA,6BACJ;AAAA;AAGtB,MAAM,mBAAmB,CAAC;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AACF,MAA2D;AAEzD,MAAI,CAAC;AAAc,WAAO,CAAC,KAAK;AAGhC,MAAI,OAAO,SAAS,UAAU;AAC5B,WAAO;AAAA,MACL;AAAA,uCACiC;AAAA,mCACJ;AAAA;AAAA,IAE/B;AAAA,EACF;AAEA,MAAI,OAAO,SAAS;AAAU,WAAO,CAAC,KAAK;AAI3C,QAAM,wBAAkD,CAAC;AAKzD,MAAI,KAAK,OAAO;AACd,UAAM,YAAY,yBAAyB,KAAK,KAAK;AACrD,QAAI,sBAAsB,WAAW;AACnC,4BAAsB;AAAA,QACpB;AAAA,YACI;AAAA;AAAA,MAEN;AACF,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAAA,EAC5D;AACA,MAAI,KAAK,QAAQ;AACf,UAAM,YAAY,yBAAyB,KAAK,MAAM;AACtD,QAAI,sBAAsB,WAAW;AACnC,4BAAsB;AAAA,QACpB;AAAA,YACI;AAAA;AAAA,MAEN;AACF,0BAAsB,KAAK,MAAM,MAAM,SAAS,WAAW;AAAA,EAC7D;AACA,MAAI,KAAK,OAAO;AACd,UAAM,YAAY,yBAAyB,KAAK,KAAK;AACrD,QAAI,sBAAsB,WAAW;AACnC,4BAAsB;AAAA,QACpB;AAAA,YACI;AAAA;AAAA,MAEN;AACF,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAAA,EAC5D;AACA,SAAO;AACT;",
3
+ "sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/utils/manageSpanParent.tsx"],
4
+ "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-statements */\n/* eslint-disable max-lines */\n/* eslint-disable complexity */\nimport { css } from '@elliemae/ds-system';\nimport type { Theme } from '@elliemae/pui-theme';\nimport type { DSGridT } from '../react-desc-prop-types.js';\n\ntype InterpolatedFunctionProps = {\n theme: Theme;\n} & DSGridT.ItemProps;\n\nconst generateCssStringForSpan = (span: number): string => `\n -ms-grid-column: auto / span ${span};\n grid-column: auto / span ${span};\n`;\n// This is used to support bootrap like-ish way of using the grid component\nexport const manageSpanParent = ({\n isSpanParent,\n span,\n theme,\n}: InterpolatedFunctionProps): ReturnType<typeof css>[] => {\n // If it's not a span parent, we don't need to do anything\n if (!isSpanParent) return [css``];\n\n // if span is a number we don't add media queries\n if (typeof span === 'number') {\n return [\n css`\n -ms-grid-column: auto / span ${span};\n grid-column: auto / span ${span};\n `,\n ];\n }\n // the only remaining valid definition for our supported types is an object, if it's not an object we fallback to doing nothing\n if (typeof span !== 'object') return [css``];\n\n // Span object\n\n const finalMediaDeclaration: ReturnType<typeof css>[] = [];\n // we conditionally push into the array the media queries because span definitions supports partial definitions\n // meaning that you can define spans only for small and medium and not for large\n // in such case we want to avoid generating media queries for large\n // we also need to make sure that the largest definition is used as the default one\n if (span.large) {\n const cssString = generateCssStringForSpan(span.large);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n finalMediaDeclaration.push(theme.media.large`${cssString}`);\n }\n if (span.medium) {\n const cssString = generateCssStringForSpan(span.medium);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n finalMediaDeclaration.push(theme.media.medium`${cssString}`);\n }\n if (span.small) {\n const cssString = generateCssStringForSpan(span.small);\n if (finalMediaDeclaration.length === 0)\n finalMediaDeclaration.push(css`\n ${cssString}\n `);\n finalMediaDeclaration.push(theme.media.small`${cssString}`);\n }\n return finalMediaDeclaration;\n};\n"],
5
+ "mappings": "AAAA,YAAY,WAAW;ACGvB,SAAS,WAAW;AAQpB,MAAM,2BAA2B,CAAC,SAAyB;AAAA,iCAC1B;AAAA,6BACJ;AAAA;AAGtB,MAAM,mBAAmB,CAAC;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AACF,MAA2D;AAEzD,MAAI,CAAC;AAAc,WAAO,CAAC,KAAK;AAGhC,MAAI,OAAO,SAAS,UAAU;AAC5B,WAAO;AAAA,MACL;AAAA,uCACiC;AAAA,mCACJ;AAAA;AAAA,IAE/B;AAAA,EACF;AAEA,MAAI,OAAO,SAAS;AAAU,WAAO,CAAC,KAAK;AAI3C,QAAM,wBAAkD,CAAC;AAKzD,MAAI,KAAK,OAAO;AACd,UAAM,YAAY,yBAAyB,KAAK,KAAK;AACrD,QAAI,sBAAsB,WAAW;AACnC,4BAAsB,KAAK;AAAA,UACvB;AAAA,OACH;AACH,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAAA,EAC5D;AACA,MAAI,KAAK,QAAQ;AACf,UAAM,YAAY,yBAAyB,KAAK,MAAM;AACtD,QAAI,sBAAsB,WAAW;AACnC,4BAAsB,KAAK;AAAA,UACvB;AAAA,OACH;AACH,0BAAsB,KAAK,MAAM,MAAM,SAAS,WAAW;AAAA,EAC7D;AACA,MAAI,KAAK,OAAO;AACd,UAAM,YAAY,yBAAyB,KAAK,KAAK;AACrD,QAAI,sBAAsB,WAAW;AACnC,4BAAsB,KAAK;AAAA,UACvB;AAAA,OACH;AACH,0BAAsB,KAAK,MAAM,MAAM,QAAQ,WAAW;AAAA,EAC5D;AACA,SAAO;AACT;",
6
6
  "names": []
7
7
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/utils/styles.tsx"],
3
+ "sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/utils/styles.tsx"],
4
4
  "sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-lines */\n/* eslint-disable complexity */\nimport { css, mapTemplateGrid } from '@elliemae/ds-system';\nimport type { DSGridT } from '../react-desc-prop-types.js';\n\nexport const manageSpan = css<DSGridT.ItemProps>`\n ${({ isSpanParent, span, theme }) => {\n if (!isSpanParent) return '';\n\n if (typeof span === 'number') {\n return `\n -ms-grid-column: auto / span ${span};\n grid-column: auto / span ${span};`;\n }\n\n if (typeof span !== 'object') return ``;\n\n // Span object\n\n let data = '';\n Object.keys(theme.media).forEach((key) => {\n // Type castings\n const theKey = key as keyof typeof span & keyof typeof theme.breakpoints;\n const spanValue = span[theKey];\n\n if (!!spanValue && theme.breakpoints[theKey]) {\n if (theKey === 'small') {\n data += `\n -ms-grid-column: auto / span ${spanValue};\n grid-column: auto / span ${spanValue};\n `;\n } else {\n data += `@media (min-width: ${theme.breakpoints[theKey]}) {\n -ms-grid-column: auto / span ${spanValue};\n grid-column: auto / span ${spanValue};\n }`;\n }\n }\n });\n return data;\n }}\n`;\n\nexport const manageCols = css<DSGridT.ItemProps>`\n ${({ cols, theme, isSpanParent }) => {\n if (typeof cols === 'object' && !Array.isArray(cols)) {\n let data = '';\n Object.keys(theme.media).forEach((key) => {\n const theKey = key as keyof typeof cols;\n const colValue = cols[theKey];\n if (!!colValue && Array.isArray(colValue)) {\n const mtg = (mapTemplateGrid(colValue) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(colValue) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n if (theKey === 'small') {\n data += `-ms-grid-columns: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtg || 'auto'};\n -ms-grid-columns: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtgs || 'auto'};`;\n } else {\n data += `@media (min-width: ${theme.breakpoints[theKey]}) {\n -ms-grid-columns: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtg || 'auto'};\n -ms-grid-columns: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtgs || 'auto'};\n }`;\n }\n } else if (!!colValue && isSpanParent) {\n if (theKey === 'small') {\n data += `-ms-grid-columns: repeat(${colValue}, 1fr);\n grid-template-columns: repeat(${colValue}, 1fr);`;\n } else {\n data += `@media (min-width: ${theme.breakpoints[theKey]}) {\n -ms-grid-columns: repeat(${colValue}, 1fr);\n grid-template-columns: repeat(${colValue}, 1fr);\n }`;\n }\n }\n });\n return data;\n }\n if (Array.isArray(cols)) {\n const mtg = (mapTemplateGrid(cols) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(cols) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n return `\n -ms-grid-columns: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtg || 'auto'};\n -ms-grid-columns: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-columns: ${mtgs || 'auto'};`;\n }\n if (isSpanParent) {\n return `\n -ms-grid-columns: repeat(${cols}, 1fr);\n grid-template-columns: repeat(${cols}, 1fr);`;\n }\n return '';\n }}\n`;\n\nexport const manageRows = css<DSGridT.ItemProps>`\n ${({ rows, theme, isSpanParent }) => {\n if (typeof rows === 'object' && !Array.isArray(rows)) {\n let data = '';\n Object.keys(theme.media).forEach((key) => {\n const theKey = key as keyof typeof rows & keyof typeof theme.breakpoints;\n const rowValue = rows[theKey];\n if (rowValue && Array.isArray(rowValue)) {\n const mtg = (mapTemplateGrid(rowValue) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(rowValue) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n if (key === 'small') {\n data += `-ms-grid-rows: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtg || 'auto'};\n -ms-grid-rows: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtgs || 'auto'};`;\n } else {\n data += `@media (min-width: ${theme.breakpoints[theKey]}) {\n -ms-grid-rows: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtg || 'auto'};\n -ms-grid-rows: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtgs || 'auto'};\n }`;\n }\n } else if (!!rowValue && isSpanParent) {\n if (theKey === 'small') {\n data += `-ms-grid-rows: repeat(${rowValue}, 1fr);\n grid-template-rows: repeat(${rowValue}, 1fr);`;\n } else {\n data += `@media (min-width: ${theme.breakpoints[theKey]}) {\n -ms-grid-rows: repeat(${rowValue}, 1fr);\n grid-template-rows: repeat(${rowValue}, 1fr);\n }`;\n }\n }\n });\n return data;\n }\n if (Array.isArray(rows)) {\n const mtg = (mapTemplateGrid(rows) as string[]).join(' ');\n const mtgs = (mapTemplateGrid(rows) as string[]).map((c) => `minmax(0, ${c})`).join(' ');\n return `\n -ms-grid-rows: ${mtg || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtg || 'auto'};\n -ms-grid-rows: ${mtgs || 'minmax(0px, 1fr)'};\n grid-template-rows: ${mtgs || 'auto'};\n `;\n }\n if (isSpanParent) {\n return `\n -ms-grid-rows: repeat(${rows}, 1fr);\n grid-template-rows: repeat(${rows}, 1fr);`;\n }\n return '';\n }}\n`;\n"],
5
5
  "mappings": "AAAA,YAAY,WAAW;ACEvB,SAAS,KAAK,uBAAuB;AAG9B,MAAM,aAAa;AAAA,IACtB,CAAC,EAAE,cAAc,MAAM,MAAM,MAAM;AACnC,MAAI,CAAC;AAAc,WAAO;AAE1B,MAAI,OAAO,SAAS,UAAU;AAC5B,WAAO;AAAA,uCAC0B;AAAA,mCACJ;AAAA,EAC/B;AAEA,MAAI,OAAO,SAAS;AAAU,WAAO;AAIrC,MAAI,OAAO;AACX,SAAO,KAAK,MAAM,KAAK,EAAE,QAAQ,CAAC,QAAQ;AAExC,UAAM,SAAS;AACf,UAAM,YAAY,KAAK,MAAM;AAE7B,QAAI,CAAC,CAAC,aAAa,MAAM,YAAY,MAAM,GAAG;AAC5C,UAAI,WAAW,SAAS;AACtB,gBAAQ;AAAA,2CACyB;AAAA,uCACJ;AAAA;AAAA,MAE/B,OAAO;AACL,gBAAQ,sBAAsB,MAAM,YAAY,MAAM;AAAA,mDACb;AAAA,+CACJ;AAAA;AAAA,MAEvC;AAAA,IACF;AAAA,EACF,CAAC;AACD,SAAO;AACT;AAAA;AAGK,MAAM,aAAa;AAAA,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O;AAAA,8BACF,OAAO;AAAA,yBACZ,QAAQ;AAAA,8BACH,QAAQ;AAAA;AAAA,EAElC;AACA,MAAI,cAAc;AAChB,WAAO;AAAA,gCACmB;AAAA,qCACK;AAAA,EACjC;AACA,SAAO;AACT;AAAA;",
6
6
  "names": []
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elliemae/ds-grid",
3
- "version": "3.22.0-next.26",
3
+ "version": "3.22.0-next.28",
4
4
  "license": "MIT",
5
5
  "description": "ICE MT - Dimsum - Grid",
6
6
  "files": [
@@ -64,9 +64,9 @@
64
64
  },
65
65
  "dependencies": {
66
66
  "@xstyled/system": "~3.7.3",
67
- "@elliemae/ds-props-helpers": "3.22.0-next.26",
68
- "@elliemae/ds-utilities": "3.22.0-next.26",
69
- "@elliemae/ds-system": "3.22.0-next.26"
67
+ "@elliemae/ds-props-helpers": "3.22.0-next.28",
68
+ "@elliemae/ds-system": "3.22.0-next.28",
69
+ "@elliemae/ds-utilities": "3.22.0-next.28"
70
70
  },
71
71
  "devDependencies": {
72
72
  "@elliemae/pui-cli": "~9.0.0-next.22",
@@ -76,7 +76,7 @@
76
76
  "@testing-library/user-event": "~13.5.0",
77
77
  "react-test-renderer": "~17.0.2",
78
78
  "styled-components": "~5.3.9",
79
- "@elliemae/ds-monorepo-devops": "3.22.0-next.26"
79
+ "@elliemae/ds-monorepo-devops": "3.22.0-next.28"
80
80
  },
81
81
  "peerDependencies": {
82
82
  "@elliemae/pui-theme": "^2.6.0",
@@ -91,12 +91,12 @@
91
91
  "typeSafety": false
92
92
  },
93
93
  "scripts": {
94
- "dev": "cross-env NODE_ENV=development node ../../scripts/build/build.mjs --watch",
94
+ "dev": "cross-env NODE_ENV=development node ../../../scripts/build/build.mjs --watch",
95
95
  "test": "pui-cli test --passWithNoTests",
96
- "lint": "node ../../scripts/lint.mjs",
97
- "eslint:fix": "eslint --ext='.js,.jsx,.test.js,.ts,.tsx' --fix --config='../../.eslintrc.js' src/",
98
- "dts": "node ../../scripts/dts.mjs",
99
- "build": "cross-env NODE_ENV=production node ../../scripts/build/build.mjs",
96
+ "lint": "node ../../../scripts/lint.mjs",
97
+ "eslint:fix": "eslint --ext='.js,.jsx,.test.js,.ts,.tsx' --fix --config='../../../.eslintrc.js' src/",
98
+ "dts": "node ../../../scripts/dts.mjs",
99
+ "build": "cross-env NODE_ENV=production node ../../../scripts/build/build.mjs",
100
100
  "dev:build": "pnpm --filter {.}... build",
101
101
  "dev:install": "pnpm --filter {.}... i --no-lockfile && pnpm run dev:build",
102
102
  "checkDeps": "npm exec ../ds-codemods -- check-missing-packages --projectFolderPath=\"./\" --ignorePackagesGlobPattern=\"\" --ignoreFilesGlobPattern=\"**/test-ables/*,**/tests/*\""