@elliemae/ds-form-layout-blocks 3.80.0-next.62 → 3.80.0-next.65
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/form-layout-block-item/DSFormLayoutBlockItem.js +2 -2
- package/dist/cjs/form-layout-block-item/DSFormLayoutBlockItem.js.map +2 -2
- package/dist/esm/form-layout-block-item/DSFormLayoutBlockItem.js +2 -2
- package/dist/esm/form-layout-block-item/DSFormLayoutBlockItem.js.map +2 -2
- package/package.json +12 -12
|
@@ -75,6 +75,7 @@ const DSFormLayoutBlockItem = (props) => {
|
|
|
75
75
|
withHighlight,
|
|
76
76
|
as: isGroup ? "fieldset" : "div",
|
|
77
77
|
isGroup,
|
|
78
|
+
"aria-describedby": isGroup ? `${instanceUID}_feedback_message ${instanceUID}_error_message` : void 0,
|
|
78
79
|
className,
|
|
79
80
|
...xstyledProps,
|
|
80
81
|
...othersGlobalAttributes,
|
|
@@ -111,7 +112,7 @@ const DSFormLayoutBlockItem = (props) => {
|
|
|
111
112
|
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styles.ScreenReaderOnly, { children: currentChar < maxCharCounter ? `${maxCharCounter - currentChar} characters remaining` : "" })
|
|
112
113
|
] }) : null
|
|
113
114
|
] }),
|
|
114
|
-
isGroup && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styles.ScreenReaderOnly, { as: "legend", id: `${instanceUID}_legend`, children:
|
|
115
|
+
isGroup && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styles.ScreenReaderOnly, { as: "legend", id: `${instanceUID}_legend`, children: label }),
|
|
115
116
|
children,
|
|
116
117
|
feedbackMessage && !hasError ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
117
118
|
import_styles.StyledMessage,
|
|
@@ -119,7 +120,6 @@ const DSFormLayoutBlockItem = (props) => {
|
|
|
119
120
|
"aria-live": "polite",
|
|
120
121
|
leftLabel,
|
|
121
122
|
hideLabel,
|
|
122
|
-
"aria-hidden": isGroup,
|
|
123
123
|
id: `${instanceUID}_feedback_message`,
|
|
124
124
|
getOwnerProps,
|
|
125
125
|
getOwnerPropsArguments,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/form-layout-block-item/DSFormLayoutBlockItem.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["/* eslint-disable complexity */\nimport React, { useMemo, useCallback } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { uid } from 'uid';\nimport { AlertsSmallFill } from '@elliemae/ds-icons';\nimport type { DSFormLayoutBlockItemT } from './react-desc-prop-types.js';\nimport { propTypes } from './react-desc-prop-types.js';\nimport {\n StyledMessage,\n StyledLabel,\n StyledContainer,\n StyledMark,\n ScreenReaderOnly,\n StyledCharCount,\n StyledErrorMessage,\n} from './styles.js';\nimport { useFormLayoutBlockItem } from './config/useFormLayoutBlockItem.js';\n\nconst DSFormLayoutBlockItem = (props: DSFormLayoutBlockItemT.Props) => {\n const { globalAttributes, xstyledProps, propsWithDefault } = useFormLayoutBlockItem(props);\n const {\n label,\n feedbackMessage,\n maxCharCounter,\n currentChar,\n validationMessage,\n inputID,\n children,\n hasError,\n leftLabel,\n required,\n optional,\n hideLabel,\n fitContent,\n withHighlight,\n isGroup,\n } = propsWithDefault;\n\n const { className, label: globalLabel, ...othersGlobalAttributes } = globalAttributes;\n const instanceUID = useMemo(() => inputID ?? `form_layout_block_item_${uid(6)}`, [inputID]);\n\n const cols = useMemo(() => (maxCharCounter !== undefined ? ['1fr', 'auto'] : ['1fr']), [maxCharCounter]);\n\n const getOwnerProps = useCallback(() => propsWithDefault, [propsWithDefault]);\n const getOwnerPropsArguments = useCallback(() => ({}), []);\n return (\n <StyledContainer\n leftLabel={leftLabel}\n fitContent={fitContent}\n hideLabel={hideLabel}\n withHighlight={withHighlight}\n as={isGroup ? 'fieldset' : 'div'}\n isGroup={isGroup}\n className={className}\n {...xstyledProps}\n {...othersGlobalAttributes}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Grid cols={cols} gutter=\"xxs\" aria-live=\"polite\" id={`${instanceUID}_remaining_characters`}>\n {label ? (\n <StyledLabel\n id={`${instanceUID}_block_label`}\n htmlFor={instanceUID}\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n aria-hidden={isGroup}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {label}\n {(required || optional) && (\n <StyledMark required={required} aria-hidden={required}>\n {optional ? <ScreenReaderOnly>Optional</ScreenReaderOnly> : null}\n </StyledMark>\n )}\n </StyledLabel>\n ) : null}\n\n {maxCharCounter !== undefined && currentChar !== undefined ? (\n <>\n <StyledCharCount\n hasError={currentChar > maxCharCounter}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {`${currentChar}/${maxCharCounter}`}\n </StyledCharCount>\n <ScreenReaderOnly>\n {currentChar < maxCharCounter ? `${maxCharCounter - currentChar} characters remaining` : ''}\n </ScreenReaderOnly>\n </>\n ) : null}\n </Grid>\n {isGroup && (\n <ScreenReaderOnly as=\"legend\" id={`${instanceUID}_legend`}
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;
|
|
4
|
+
"sourcesContent": ["/* eslint-disable complexity */\nimport React, { useMemo, useCallback } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { uid } from 'uid';\nimport { AlertsSmallFill } from '@elliemae/ds-icons';\nimport type { DSFormLayoutBlockItemT } from './react-desc-prop-types.js';\nimport { propTypes } from './react-desc-prop-types.js';\nimport {\n StyledMessage,\n StyledLabel,\n StyledContainer,\n StyledMark,\n ScreenReaderOnly,\n StyledCharCount,\n StyledErrorMessage,\n} from './styles.js';\nimport { useFormLayoutBlockItem } from './config/useFormLayoutBlockItem.js';\n\nconst DSFormLayoutBlockItem = (props: DSFormLayoutBlockItemT.Props) => {\n const { globalAttributes, xstyledProps, propsWithDefault } = useFormLayoutBlockItem(props);\n const {\n label,\n feedbackMessage,\n maxCharCounter,\n currentChar,\n validationMessage,\n inputID,\n children,\n hasError,\n leftLabel,\n required,\n optional,\n hideLabel,\n fitContent,\n withHighlight,\n isGroup,\n } = propsWithDefault;\n\n const { className, label: globalLabel, ...othersGlobalAttributes } = globalAttributes;\n const instanceUID = useMemo(() => inputID ?? `form_layout_block_item_${uid(6)}`, [inputID]);\n\n const cols = useMemo(() => (maxCharCounter !== undefined ? ['1fr', 'auto'] : ['1fr']), [maxCharCounter]);\n\n const getOwnerProps = useCallback(() => propsWithDefault, [propsWithDefault]);\n const getOwnerPropsArguments = useCallback(() => ({}), []);\n return (\n <StyledContainer\n leftLabel={leftLabel}\n fitContent={fitContent}\n hideLabel={hideLabel}\n withHighlight={withHighlight}\n as={isGroup ? 'fieldset' : 'div'}\n isGroup={isGroup}\n aria-describedby={isGroup ? `${instanceUID}_feedback_message ${instanceUID}_error_message` : undefined}\n className={className}\n {...xstyledProps}\n {...othersGlobalAttributes}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Grid cols={cols} gutter=\"xxs\" aria-live=\"polite\" id={`${instanceUID}_remaining_characters`}>\n {label ? (\n <StyledLabel\n id={`${instanceUID}_block_label`}\n htmlFor={instanceUID}\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n aria-hidden={isGroup}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {label}\n {(required || optional) && (\n <StyledMark required={required} aria-hidden={required}>\n {optional ? <ScreenReaderOnly>Optional</ScreenReaderOnly> : null}\n </StyledMark>\n )}\n </StyledLabel>\n ) : null}\n\n {maxCharCounter !== undefined && currentChar !== undefined ? (\n <>\n <StyledCharCount\n hasError={currentChar > maxCharCounter}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {`${currentChar}/${maxCharCounter}`}\n </StyledCharCount>\n <ScreenReaderOnly>\n {currentChar < maxCharCounter ? `${maxCharCounter - currentChar} characters remaining` : ''}\n </ScreenReaderOnly>\n </>\n ) : null}\n </Grid>\n {isGroup && (\n <ScreenReaderOnly as=\"legend\" id={`${instanceUID}_legend`}>\n {label}\n </ScreenReaderOnly>\n )}\n {children}\n {feedbackMessage && !hasError ? (\n <StyledMessage\n aria-live=\"polite\"\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n id={`${instanceUID}_feedback_message`}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {feedbackMessage}\n </StyledMessage>\n ) : (\n <ScreenReaderOnly id={`${instanceUID}_feedback_message`} />\n )}\n {validationMessage && hasError ? (\n <StyledErrorMessage\n hasError={hasError}\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n role=\"alert\"\n id={`${instanceUID}_error_message`}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <AlertsSmallFill width={8} height={8} color={['danger', '900']} style={{ marginBottom: '2px' }} />\n \n {`${validationMessage}`}\n </StyledErrorMessage>\n ) : (\n <ScreenReaderOnly id={`${instanceUID}_error_message`} />\n )}\n </StyledContainer>\n );\n};\n\nDSFormLayoutBlockItem.displayName = 'DSFormLayoutBlockItem';\nconst DSFormLayoutBlockItemWithSchema = describe(DSFormLayoutBlockItem);\nDSFormLayoutBlockItemWithSchema.propTypes = propTypes;\n\nexport { DSFormLayoutBlockItem, DSFormLayoutBlockItemWithSchema };\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,Y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AAqB;AACtE,gCAAgC,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -49,6 +49,7 @@ const DSFormLayoutBlockItem = (props) => {
|
|
|
49
49
|
withHighlight,
|
|
50
50
|
as: isGroup ? "fieldset" : "div",
|
|
51
51
|
isGroup,
|
|
52
|
+
"aria-describedby": isGroup ? `${instanceUID}_feedback_message ${instanceUID}_error_message` : void 0,
|
|
52
53
|
className,
|
|
53
54
|
...xstyledProps,
|
|
54
55
|
...othersGlobalAttributes,
|
|
@@ -85,7 +86,7 @@ const DSFormLayoutBlockItem = (props) => {
|
|
|
85
86
|
/* @__PURE__ */ jsx(ScreenReaderOnly, { children: currentChar < maxCharCounter ? `${maxCharCounter - currentChar} characters remaining` : "" })
|
|
86
87
|
] }) : null
|
|
87
88
|
] }),
|
|
88
|
-
isGroup && /* @__PURE__ */ jsx(ScreenReaderOnly, { as: "legend", id: `${instanceUID}_legend`, children:
|
|
89
|
+
isGroup && /* @__PURE__ */ jsx(ScreenReaderOnly, { as: "legend", id: `${instanceUID}_legend`, children: label }),
|
|
89
90
|
children,
|
|
90
91
|
feedbackMessage && !hasError ? /* @__PURE__ */ jsx(
|
|
91
92
|
StyledMessage,
|
|
@@ -93,7 +94,6 @@ const DSFormLayoutBlockItem = (props) => {
|
|
|
93
94
|
"aria-live": "polite",
|
|
94
95
|
leftLabel,
|
|
95
96
|
hideLabel,
|
|
96
|
-
"aria-hidden": isGroup,
|
|
97
97
|
id: `${instanceUID}_feedback_message`,
|
|
98
98
|
getOwnerProps,
|
|
99
99
|
getOwnerPropsArguments,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../src/form-layout-block-item/DSFormLayoutBlockItem.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable complexity */\nimport React, { useMemo, useCallback } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { uid } from 'uid';\nimport { AlertsSmallFill } from '@elliemae/ds-icons';\nimport type { DSFormLayoutBlockItemT } from './react-desc-prop-types.js';\nimport { propTypes } from './react-desc-prop-types.js';\nimport {\n StyledMessage,\n StyledLabel,\n StyledContainer,\n StyledMark,\n ScreenReaderOnly,\n StyledCharCount,\n StyledErrorMessage,\n} from './styles.js';\nimport { useFormLayoutBlockItem } from './config/useFormLayoutBlockItem.js';\n\nconst DSFormLayoutBlockItem = (props: DSFormLayoutBlockItemT.Props) => {\n const { globalAttributes, xstyledProps, propsWithDefault } = useFormLayoutBlockItem(props);\n const {\n label,\n feedbackMessage,\n maxCharCounter,\n currentChar,\n validationMessage,\n inputID,\n children,\n hasError,\n leftLabel,\n required,\n optional,\n hideLabel,\n fitContent,\n withHighlight,\n isGroup,\n } = propsWithDefault;\n\n const { className, label: globalLabel, ...othersGlobalAttributes } = globalAttributes;\n const instanceUID = useMemo(() => inputID ?? `form_layout_block_item_${uid(6)}`, [inputID]);\n\n const cols = useMemo(() => (maxCharCounter !== undefined ? ['1fr', 'auto'] : ['1fr']), [maxCharCounter]);\n\n const getOwnerProps = useCallback(() => propsWithDefault, [propsWithDefault]);\n const getOwnerPropsArguments = useCallback(() => ({}), []);\n return (\n <StyledContainer\n leftLabel={leftLabel}\n fitContent={fitContent}\n hideLabel={hideLabel}\n withHighlight={withHighlight}\n as={isGroup ? 'fieldset' : 'div'}\n isGroup={isGroup}\n className={className}\n {...xstyledProps}\n {...othersGlobalAttributes}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Grid cols={cols} gutter=\"xxs\" aria-live=\"polite\" id={`${instanceUID}_remaining_characters`}>\n {label ? (\n <StyledLabel\n id={`${instanceUID}_block_label`}\n htmlFor={instanceUID}\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n aria-hidden={isGroup}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {label}\n {(required || optional) && (\n <StyledMark required={required} aria-hidden={required}>\n {optional ? <ScreenReaderOnly>Optional</ScreenReaderOnly> : null}\n </StyledMark>\n )}\n </StyledLabel>\n ) : null}\n\n {maxCharCounter !== undefined && currentChar !== undefined ? (\n <>\n <StyledCharCount\n hasError={currentChar > maxCharCounter}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {`${currentChar}/${maxCharCounter}`}\n </StyledCharCount>\n <ScreenReaderOnly>\n {currentChar < maxCharCounter ? `${maxCharCounter - currentChar} characters remaining` : ''}\n </ScreenReaderOnly>\n </>\n ) : null}\n </Grid>\n {isGroup && (\n <ScreenReaderOnly as=\"legend\" id={`${instanceUID}_legend`}
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable complexity */\nimport React, { useMemo, useCallback } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { uid } from 'uid';\nimport { AlertsSmallFill } from '@elliemae/ds-icons';\nimport type { DSFormLayoutBlockItemT } from './react-desc-prop-types.js';\nimport { propTypes } from './react-desc-prop-types.js';\nimport {\n StyledMessage,\n StyledLabel,\n StyledContainer,\n StyledMark,\n ScreenReaderOnly,\n StyledCharCount,\n StyledErrorMessage,\n} from './styles.js';\nimport { useFormLayoutBlockItem } from './config/useFormLayoutBlockItem.js';\n\nconst DSFormLayoutBlockItem = (props: DSFormLayoutBlockItemT.Props) => {\n const { globalAttributes, xstyledProps, propsWithDefault } = useFormLayoutBlockItem(props);\n const {\n label,\n feedbackMessage,\n maxCharCounter,\n currentChar,\n validationMessage,\n inputID,\n children,\n hasError,\n leftLabel,\n required,\n optional,\n hideLabel,\n fitContent,\n withHighlight,\n isGroup,\n } = propsWithDefault;\n\n const { className, label: globalLabel, ...othersGlobalAttributes } = globalAttributes;\n const instanceUID = useMemo(() => inputID ?? `form_layout_block_item_${uid(6)}`, [inputID]);\n\n const cols = useMemo(() => (maxCharCounter !== undefined ? ['1fr', 'auto'] : ['1fr']), [maxCharCounter]);\n\n const getOwnerProps = useCallback(() => propsWithDefault, [propsWithDefault]);\n const getOwnerPropsArguments = useCallback(() => ({}), []);\n return (\n <StyledContainer\n leftLabel={leftLabel}\n fitContent={fitContent}\n hideLabel={hideLabel}\n withHighlight={withHighlight}\n as={isGroup ? 'fieldset' : 'div'}\n isGroup={isGroup}\n aria-describedby={isGroup ? `${instanceUID}_feedback_message ${instanceUID}_error_message` : undefined}\n className={className}\n {...xstyledProps}\n {...othersGlobalAttributes}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <Grid cols={cols} gutter=\"xxs\" aria-live=\"polite\" id={`${instanceUID}_remaining_characters`}>\n {label ? (\n <StyledLabel\n id={`${instanceUID}_block_label`}\n htmlFor={instanceUID}\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n aria-hidden={isGroup}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {label}\n {(required || optional) && (\n <StyledMark required={required} aria-hidden={required}>\n {optional ? <ScreenReaderOnly>Optional</ScreenReaderOnly> : null}\n </StyledMark>\n )}\n </StyledLabel>\n ) : null}\n\n {maxCharCounter !== undefined && currentChar !== undefined ? (\n <>\n <StyledCharCount\n hasError={currentChar > maxCharCounter}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {`${currentChar}/${maxCharCounter}`}\n </StyledCharCount>\n <ScreenReaderOnly>\n {currentChar < maxCharCounter ? `${maxCharCounter - currentChar} characters remaining` : ''}\n </ScreenReaderOnly>\n </>\n ) : null}\n </Grid>\n {isGroup && (\n <ScreenReaderOnly as=\"legend\" id={`${instanceUID}_legend`}>\n {label}\n </ScreenReaderOnly>\n )}\n {children}\n {feedbackMessage && !hasError ? (\n <StyledMessage\n aria-live=\"polite\"\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n id={`${instanceUID}_feedback_message`}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n {feedbackMessage}\n </StyledMessage>\n ) : (\n <ScreenReaderOnly id={`${instanceUID}_feedback_message`} />\n )}\n {validationMessage && hasError ? (\n <StyledErrorMessage\n hasError={hasError}\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n role=\"alert\"\n id={`${instanceUID}_error_message`}\n getOwnerProps={getOwnerProps}\n getOwnerPropsArguments={getOwnerPropsArguments}\n >\n <AlertsSmallFill width={8} height={8} color={['danger', '900']} style={{ marginBottom: '2px' }} />\n \n {`${validationMessage}`}\n </StyledErrorMessage>\n ) : (\n <ScreenReaderOnly id={`${instanceUID}_error_message`} />\n )}\n </StyledContainer>\n );\n};\n\nDSFormLayoutBlockItem.displayName = 'DSFormLayoutBlockItem';\nconst DSFormLayoutBlockItemWithSchema = describe(DSFormLayoutBlockItem);\nDSFormLayoutBlockItemWithSchema.propTypes = propTypes;\n\nexport { DSFormLayoutBlockItem, DSFormLayoutBlockItemWithSchema };\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;AC+Db,SAmBA,UAPkB,KAZlB;AA9DV,SAAgB,SAAS,mBAAmB;AAC5C,SAAS,YAAY;AACrB,SAAS,gBAAgB;AACzB,SAAS,WAAW;AACpB,SAAS,uBAAuB;AAEhC,SAAS,iBAAiB;AAC1B;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AACP,SAAS,8BAA8B;AAEvC,MAAM,wBAAwB,CAAC,UAAwC;AACrE,QAAM,EAAE,kBAAkB,cAAc,iBAAiB,IAAI,uBAAuB,KAAK;AACzF,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;A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AAI,cAAc;AAAA;AAAA,YACnC;AAAA,YACA,oBAAC,oBACE,wBAAc,iBAAiB,GAAG,iBAAiB,WAAW,0BAA0B,IAC3F;AAAA,aACF,IACE;AAAA,WACN;AAAA,QACC,WACC,oBAAC,oBAAiB,IAAG,UAAS,IAAI,GAAG,WAAW,WAC7C,iBACH;AAAA,QAED;AAAA,QACA,mBAAmB,CAAC,WACnB;AAAA,UAAC;AAAA;AAAA,YACC,aAAU;AAAA,YACV;AAAA,YACA;AAAA,YACA,IAAI,GAAG,WAAW;AAAA,YAClB;AAAA,YACA;AAAA,YAEC;AAAA;AAAA,QACH,IAEA,oBAAC,oBAAiB,IAAI,GAAG,WAAW,qBAAqB;AAAA,QAE1D,qBAAqB,WACpB;AAAA,UAAC;AAAA;AAAA,YACC;AAAA,YACA;AAAA,YACA;AAAA,YACA,MAAK;AAAA,YACL,IAAI,GAAG,WAAW;AAAA,YAClB;AAAA,YACA;AAAA,YAEA;AAAA,kCAAC,mBAAgB,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAC,UAAU,KAAK,GAAG,OAAO,EAAE,cAAc,MAAM,GAAG;AAAA,cAAE;AAAA,cAEjG,GAAG,iBAAiB;AAAA;AAAA;AAAA,QACvB,IAEA,oBAAC,oBAAiB,IAAI,GAAG,WAAW,kBAAkB;AAAA;AAAA;AAAA,EAE1D;AAEJ;AAEA,sBAAsB,cAAc;AACpC,MAAM,kCAAkC,SAAS,qBAAqB;AACtE,gCAAgC,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-form-layout-blocks",
|
|
3
|
-
"version": "3.80.0-next.
|
|
3
|
+
"version": "3.80.0-next.65",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Form Layout",
|
|
6
6
|
"files": [
|
|
@@ -36,20 +36,20 @@
|
|
|
36
36
|
"indent": 4
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@elliemae/ds-grid": "3.80.0-next.
|
|
40
|
-
"@elliemae/ds-icons": "3.80.0-next.
|
|
41
|
-
"@elliemae/ds-props-helpers": "3.80.0-next.
|
|
42
|
-
"@elliemae/ds-system": "3.80.0-next.
|
|
43
|
-
"@elliemae/ds-typescript-helpers": "3.80.0-next.
|
|
39
|
+
"@elliemae/ds-grid": "3.80.0-next.65",
|
|
40
|
+
"@elliemae/ds-icons": "3.80.0-next.65",
|
|
41
|
+
"@elliemae/ds-props-helpers": "3.80.0-next.65",
|
|
42
|
+
"@elliemae/ds-system": "3.80.0-next.65",
|
|
43
|
+
"@elliemae/ds-typescript-helpers": "3.80.0-next.65",
|
|
44
44
|
"uid": "^2.0.2"
|
|
45
45
|
},
|
|
46
46
|
"devDependencies": {
|
|
47
|
-
"@elliemae/ds-form-checkbox": "3.80.0-next.
|
|
48
|
-
"@elliemae/ds-form-input-text": "3.80.0-next.
|
|
49
|
-
"@elliemae/ds-form-input-textarea": "3.80.0-next.
|
|
50
|
-
"@elliemae/ds-form-radio": "3.80.0-next.
|
|
51
|
-
"@elliemae/ds-monorepo-devops": "3.80.0-next.
|
|
52
|
-
"@elliemae/ds-test-utils": "3.80.0-next.
|
|
47
|
+
"@elliemae/ds-form-checkbox": "3.80.0-next.65",
|
|
48
|
+
"@elliemae/ds-form-input-text": "3.80.0-next.65",
|
|
49
|
+
"@elliemae/ds-form-input-textarea": "3.80.0-next.65",
|
|
50
|
+
"@elliemae/ds-form-radio": "3.80.0-next.65",
|
|
51
|
+
"@elliemae/ds-monorepo-devops": "3.80.0-next.65",
|
|
52
|
+
"@elliemae/ds-test-utils": "3.80.0-next.65",
|
|
53
53
|
"jest": "^30.0.0",
|
|
54
54
|
"styled-components": "~5.3.11"
|
|
55
55
|
},
|