@elliemae/ds-form-layout-blocks 3.16.0-next.2 → 3.16.0-next.4
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/cjs/form-layout-block-item/config/useFormLayoutBlockItem.js +5 -5
- package/dist/cjs/form-layout-block-item/config/useFormLayoutBlockItem.js.map +2 -2
- package/dist/cjs/form-layout-block-item/propTypes.js +19 -19
- package/dist/cjs/form-layout-block-item/propTypes.js.map +2 -2
- package/dist/cjs/form-layout-checkbox-group/DSFormLayoutCheckboxGroup.js +2 -2
- package/dist/cjs/form-layout-checkbox-group/DSFormLayoutCheckboxGroup.js.map +2 -2
- package/dist/cjs/form-layout-checkbox-group/config/useFormLayoutCheckboxGroup.js +5 -5
- package/dist/cjs/form-layout-checkbox-group/config/useFormLayoutCheckboxGroup.js.map +2 -2
- package/dist/cjs/form-layout-checkbox-group/propTypes.js +4 -4
- package/dist/cjs/form-layout-checkbox-group/propTypes.js.map +2 -2
- package/dist/cjs/package.json +7 -0
- package/dist/esm/form-layout-block-item/DSFormLayoutBlockItem.js +1 -1
- package/dist/esm/form-layout-block-item/DSFormLayoutBlockItem.js.map +1 -1
- package/dist/esm/form-layout-block-item/config/useFormLayoutBlockItem.js +1 -1
- package/dist/esm/form-layout-block-item/config/useFormLayoutBlockItem.js.map +2 -2
- package/dist/esm/form-layout-block-item/propTypes.js +1 -1
- package/dist/esm/form-layout-block-item/propTypes.js.map +1 -1
- package/dist/esm/form-layout-checkbox-group/DSFormLayoutCheckboxGroup.js +1 -1
- package/dist/esm/form-layout-checkbox-group/DSFormLayoutCheckboxGroup.js.map +1 -1
- package/dist/esm/form-layout-checkbox-group/config/useFormLayoutCheckboxGroup.js +1 -1
- package/dist/esm/form-layout-checkbox-group/config/useFormLayoutCheckboxGroup.js.map +2 -2
- package/dist/esm/form-layout-checkbox-group/propTypes.js +1 -1
- package/dist/esm/form-layout-checkbox-group/propTypes.js.map +1 -1
- package/dist/esm/package.json +7 -0
- package/dist/types/form-layout-block-item/DSFormLayoutBlockItem.d.ts +457 -457
- package/dist/types/form-layout-block-item/config/useFormLayoutBlockItem.d.ts +1 -1
- package/dist/types/form-layout-block-item/propTypes.d.ts +456 -456
- package/dist/types/form-layout-checkbox-group/DSFormLayoutCheckboxGroup.d.ts +445 -445
- package/dist/types/form-layout-checkbox-group/config/useFormLayoutCheckboxGroup.d.ts +1 -1
- package/dist/types/form-layout-checkbox-group/propTypes.d.ts +444 -444
- package/package.json +7 -6
|
@@ -32,7 +32,7 @@ var React = __toESM(require("react"));
|
|
|
32
32
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
33
33
|
var import_react = require("react");
|
|
34
34
|
var import_ds_grid = require("@elliemae/ds-grid");
|
|
35
|
-
var
|
|
35
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
36
36
|
var import_uid = require("uid");
|
|
37
37
|
var import_ds_icons = require("@elliemae/ds-icons");
|
|
38
38
|
var import_DSFormLayoutBlockItemDataTestId = require("../exported-related/DSFormLayoutBlockItemDataTestId");
|
|
@@ -136,6 +136,6 @@ const DSFormLayoutBlockItem = (props) => {
|
|
|
136
136
|
};
|
|
137
137
|
DSFormLayoutBlockItem.propTypes = import_propTypes.propTypes;
|
|
138
138
|
DSFormLayoutBlockItem.displayName = "DSFormLayoutBlockItem";
|
|
139
|
-
const DSFormLayoutBlockItemWithSchema = (0,
|
|
139
|
+
const DSFormLayoutBlockItemWithSchema = (0, import_ds_props_helpers.describe)(DSFormLayoutBlockItem);
|
|
140
140
|
DSFormLayoutBlockItemWithSchema.propTypes = import_propTypes.propTypes;
|
|
141
141
|
//# sourceMappingURL=DSFormLayoutBlockItem.js.map
|
|
@@ -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 } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { describe } from '@elliemae/ds-
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADmDf;AAlDR,mBAA+B;AAC/B,qBAAqB;AACrB,
|
|
4
|
+
"sourcesContent": ["/* eslint-disable complexity */\nimport React, { useMemo } 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 { DSFormLayoutBlockItemDataTestId } from '../exported-related/DSFormLayoutBlockItemDataTestId';\nimport type { DSFormLayoutBlockItemT } from './propTypes';\nimport { propTypes } from './propTypes';\nimport { StyledMessage, StyledLabel, StyledContainer, StyledMark, ScreenReaderOnly, StyledCharCount } from './styles';\nimport { useFormLayoutBlockItem } from './config/useFormLayoutBlockItem';\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(() => `form_layout_block_item_${uid(6)}`, []);\n\n const cols = useMemo(() => (maxCharCounter !== undefined ? ['1fr', 'auto'] : ['1fr']), [maxCharCounter]);\n\n return (\n <StyledContainer\n data-testid={DSFormLayoutBlockItemDataTestId.CONTAINER}\n leftLabel={leftLabel}\n fitContent={fitContent}\n hideLabel={hideLabel}\n withHighlight={withHighlight}\n as={isGroup ? 'fieldset' : 'div'}\n isGroup={isGroup}\n aria-describedby={!isGroup ? `${inputID || instanceUID}_feedback_message` : undefined}\n className={className}\n {...xstyledProps}\n >\n <Grid cols={cols} gutter=\"xxs\">\n <StyledLabel\n id={`${inputID}_block_label`}\n data-testid={DSFormLayoutBlockItemDataTestId.LABEL}\n htmlFor={inputID}\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n aria-hidden={isGroup}\n {...othersGlobalAttributes}\n >\n {label}\n {(required || optional) && <StyledMark required={required} />}\n </StyledLabel>\n {maxCharCounter !== undefined && currentChar !== undefined ? (\n <StyledCharCount\n data-testid={DSFormLayoutBlockItemDataTestId.COUNTER}\n hasError={currentChar > maxCharCounter}\n >{`${currentChar}/${maxCharCounter}`}</StyledCharCount>\n ) : null}\n </Grid>\n {isGroup && <ScreenReaderOnly as=\"legend\">{`${label}. ${feedbackMessage || ''}`}</ScreenReaderOnly>}\n {children}\n {feedbackMessage && !hasError && (\n <StyledMessage\n data-testid={DSFormLayoutBlockItemDataTestId.MESSAGE}\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n aria-hidden={isGroup}\n id={`${inputID || instanceUID}_feedback_message`}\n >\n {feedbackMessage}\n </StyledMessage>\n )}\n {validationMessage && hasError && (\n <StyledMessage\n data-testid={DSFormLayoutBlockItemDataTestId.ERROR_MESSAGE}\n hasError={hasError}\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n role=\"alert\"\n id={`${inputID || instanceUID}_error_message`}\n >\n <AlertsSmallFill width={8} height={8} color={['danger', '900']} style={{ marginBottom: '2px' }} />\n \n {`${validationMessage} ${label}`}\n </StyledMessage>\n )}\n </StyledContainer>\n );\n};\n\nDSFormLayoutBlockItem.propTypes = propTypes;\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,YAAuB;ADmDf;AAlDR,mBAA+B;AAC/B,qBAAqB;AACrB,8BAAyB;AACzB,iBAAoB;AACpB,sBAAgC;AAChC,6CAAgD;AAEhD,uBAA0B;AAC1B,oBAA2G;AAC3G,oCAAuC;AAEvC,MAAM,wBAAwB,CAAC,UAAwC;AACrE,QAAM,EAAE,kBAAkB,cAAc,iBAAiB,QAAI,sDAAuB,KAAK;AACzF,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,IAAI;AAEJ,QAAM,EAAE,WAAW,OAAO,gBAAgB,uBAAuB,IAAI;AACrE,QAAM,kBAAc,sBAAQ,MAAM,8BAA0B,gBAAI,CAAC,KAAK,CAAC,CAAC;AAExE,QAAM,WAAO,sBAAQ,MAAO,mBAAmB,SAAY,CAAC,OAAO,MAAM,IAAI,CAAC,KAAK,GAAI,CAAC,cAAc,CAAC;AAEvG,SACE;AAAA,IAAC;AAAA;AAAA,MACC,eAAa,uEAAgC;AAAA,MAC7C;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,IAAI,UAAU,aAAa;AAAA,MAC3B;AAAA,MACA,oBAAkB,CAAC,UAAU,GAAG,WAAW,iCAAiC;AAAA,MAC5E;AAAA,MACC,GAAG;AAAA,MAEJ;AAAA,qDAAC,uBAAK,MAAY,QAAO,OACvB;AAAA;AAAA,YAAC;AAAA;AAAA,cACC,IAAI,GAAG;AAAA,cACP,eAAa,uEAAgC;AAAA,cAC7C,SAAS;AAAA,cACT;AAAA,cACA;AAAA,cACA,eAAa;AAAA,cACZ,GAAG;AAAA,cAEH;AAAA;AAAA,iBACC,YAAY,aAAa,4CAAC,4BAAW,UAAoB;AAAA;AAAA;AAAA,UAC7D;AAAA,UACC,mBAAmB,UAAa,gBAAgB,SAC/C;AAAA,YAAC;AAAA;AAAA,cACC,eAAa,uEAAgC;AAAA,cAC7C,UAAU,cAAc;AAAA,cACxB,aAAG,eAAe;AAAA;AAAA,UAAiB,IACnC;AAAA,WACN;AAAA,QACC,WAAW,4CAAC,kCAAiB,IAAG,UAAU,aAAG,UAAU,mBAAmB,MAAK;AAAA,QAC/E;AAAA,QACA,mBAAmB,CAAC,YACnB;AAAA,UAAC;AAAA;AAAA,YACC,eAAa,uEAAgC;AAAA,YAC7C;AAAA,YACA;AAAA,YACA,eAAa;AAAA,YACb,IAAI,GAAG,WAAW;AAAA,YAEjB;AAAA;AAAA,QACH;AAAA,QAED,qBAAqB,YACpB;AAAA,UAAC;AAAA;AAAA,YACC,eAAa,uEAAgC;AAAA,YAC7C;AAAA,YACA;AAAA,YACA;AAAA,YACA,MAAK;AAAA,YACL,IAAI,GAAG,WAAW;AAAA,YAElB;AAAA,0DAAC,mCAAgB,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAC,UAAU,KAAK,GAAG,OAAO,EAAE,cAAc,MAAM,GAAG;AAAA,cAAE;AAAA,cAEjG,GAAG,qBAAqB;AAAA;AAAA;AAAA,QAC3B;AAAA;AAAA;AAAA,EAEJ;AAEJ;AAEA,sBAAsB,YAAY;AAClC,sBAAsB,cAAc;AACpC,MAAM,sCAAkC,kCAAS,qBAAqB;AACtE,gCAAgC,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -29,14 +29,14 @@ __export(useFormLayoutBlockItem_exports, {
|
|
|
29
29
|
module.exports = __toCommonJS(useFormLayoutBlockItem_exports);
|
|
30
30
|
var React = __toESM(require("react"));
|
|
31
31
|
var import_react = __toESM(require("react"));
|
|
32
|
-
var
|
|
32
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
33
33
|
var import_propTypes = require("../propTypes");
|
|
34
34
|
var import_DSFormLayoutBlockItemDefinitions = require("../DSFormLayoutBlockItemDefinitions");
|
|
35
35
|
const useFormLayoutBlockItem = (props) => {
|
|
36
|
-
(0,
|
|
37
|
-
const propsWithDefault = (0,
|
|
38
|
-
const globalAttributes = (0,
|
|
39
|
-
const xstyledProps = (0,
|
|
36
|
+
(0, import_ds_props_helpers.useValidateTypescriptPropTypes)(props, import_propTypes.propTypes, import_DSFormLayoutBlockItemDefinitions.DSFormLayoutBlockItemName);
|
|
37
|
+
const propsWithDefault = (0, import_ds_props_helpers.useMemoMergePropsWithDefault)(props, import_propTypes.defaultProps);
|
|
38
|
+
const globalAttributes = (0, import_ds_props_helpers.useGetGlobalAttributes)(propsWithDefault);
|
|
39
|
+
const xstyledProps = (0, import_ds_props_helpers.useGetXstyledProps)(propsWithDefault);
|
|
40
40
|
return import_react.default.useMemo(
|
|
41
41
|
() => ({ globalAttributes, xstyledProps, propsWithDefault }),
|
|
42
42
|
[globalAttributes, xstyledProps, propsWithDefault]
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/form-layout-block-item/config/useFormLayoutBlockItem.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import React from 'react';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAAkB;
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport type {} from '@elliemae/ds-utilities';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-props-helpers';\nimport {\n useGetGlobalAttributes,\n useGetXstyledProps,\n useMemoMergePropsWithDefault,\n useValidateTypescriptPropTypes,\n} from '@elliemae/ds-props-helpers';\nimport { propTypes, defaultProps, type DSFormLayoutBlockItemT } from '../propTypes';\nimport { DSFormLayoutBlockItemName } from '../DSFormLayoutBlockItemDefinitions';\n\ninterface UseFormLayoutBlockItemT {\n propsWithDefault: DSFormLayoutBlockItemT.InternalProps;\n globalAttributes: GlobalAttributesT;\n xstyledProps: XstyledProps;\n}\n\nexport const useFormLayoutBlockItem = (props: DSFormLayoutBlockItemT.Props): UseFormLayoutBlockItemT => {\n useValidateTypescriptPropTypes(props, propTypes, DSFormLayoutBlockItemName);\n const propsWithDefault = useMemoMergePropsWithDefault<DSFormLayoutBlockItemT.InternalProps>(props, defaultProps);\n const globalAttributes = useGetGlobalAttributes(propsWithDefault);\n\n const xstyledProps = useGetXstyledProps(propsWithDefault);\n return React.useMemo(\n () => ({ globalAttributes, xstyledProps, propsWithDefault }),\n [globalAttributes, xstyledProps, propsWithDefault],\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAAkB;AAGlB,8BAKO;AACP,uBAAqE;AACrE,8CAA0C;AAQnC,MAAM,yBAAyB,CAAC,UAAiE;AACtG,8DAA+B,OAAO,4BAAW,iEAAyB;AAC1E,QAAM,uBAAmB,sDAAmE,OAAO,6BAAY;AAC/G,QAAM,uBAAmB,gDAAuB,gBAAgB;AAEhE,QAAM,mBAAe,4CAAmB,gBAAgB;AACxD,SAAO,aAAAA,QAAM;AAAA,IACX,OAAO,EAAE,kBAAkB,cAAc,iBAAiB;AAAA,IAC1D,CAAC,kBAAkB,cAAc,gBAAgB;AAAA,EACnD;AACF;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -29,40 +29,40 @@ __export(propTypes_exports, {
|
|
|
29
29
|
});
|
|
30
30
|
module.exports = __toCommonJS(propTypes_exports);
|
|
31
31
|
var React = __toESM(require("react"));
|
|
32
|
-
var
|
|
32
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
33
33
|
const defaultProps = {
|
|
34
34
|
isGroup: false
|
|
35
35
|
};
|
|
36
36
|
const propTypes = {
|
|
37
|
-
...
|
|
38
|
-
...
|
|
39
|
-
children:
|
|
40
|
-
label:
|
|
37
|
+
...import_ds_props_helpers.globalAttributesPropTypes,
|
|
38
|
+
...import_ds_props_helpers.xstyledPropTypes,
|
|
39
|
+
children: import_ds_props_helpers.PropTypes.node.isRequired.description("Input component. "),
|
|
40
|
+
label: import_ds_props_helpers.PropTypes.string.description(
|
|
41
41
|
"Label property for the input component. This property is required for accesibility purposes."
|
|
42
42
|
),
|
|
43
|
-
inputID:
|
|
43
|
+
inputID: import_ds_props_helpers.PropTypes.string.description(
|
|
44
44
|
"String that matches the input component's id. This property is required for accesibility purposes."
|
|
45
45
|
),
|
|
46
|
-
maxCharCounter:
|
|
47
|
-
currentChar:
|
|
48
|
-
feedbackMessage:
|
|
49
|
-
validationMessage:
|
|
46
|
+
maxCharCounter: import_ds_props_helpers.PropTypes.number.description("Max of characters allowed."),
|
|
47
|
+
currentChar: import_ds_props_helpers.PropTypes.number.description("Current counter of input text area"),
|
|
48
|
+
feedbackMessage: import_ds_props_helpers.PropTypes.string.description("Feedback message to show below the input component."),
|
|
49
|
+
validationMessage: import_ds_props_helpers.PropTypes.string.description(
|
|
50
50
|
"Validation message to show below the input component. It requires hasError property set to true to be visible."
|
|
51
51
|
),
|
|
52
|
-
hasError:
|
|
53
|
-
required:
|
|
54
|
-
optional:
|
|
55
|
-
fitContent:
|
|
56
|
-
leftLabel:
|
|
57
|
-
hideLabel:
|
|
52
|
+
hasError: import_ds_props_helpers.PropTypes.bool.description("Helper boolean property for the validation message."),
|
|
53
|
+
required: import_ds_props_helpers.PropTypes.bool.description("Adds required extra styling."),
|
|
54
|
+
optional: import_ds_props_helpers.PropTypes.bool.description("Adds optional extra styling."),
|
|
55
|
+
fitContent: import_ds_props_helpers.PropTypes.bool.description("Set the width of the layout to the input component."),
|
|
56
|
+
leftLabel: import_ds_props_helpers.PropTypes.bool.description("Adds the label at the left of the input component."),
|
|
57
|
+
hideLabel: import_ds_props_helpers.PropTypes.bool.description(
|
|
58
58
|
"Hides the input label. It still requires label and labelFor property for accesibility purposes"
|
|
59
59
|
),
|
|
60
|
-
withHighlight:
|
|
60
|
+
withHighlight: import_ds_props_helpers.PropTypes.bool.description(
|
|
61
61
|
"Adds highlight extra styling. It requires extra spacing, please check withHighlight explanation tab."
|
|
62
62
|
),
|
|
63
|
-
isGroup:
|
|
63
|
+
isGroup: import_ds_props_helpers.PropTypes.bool.description(
|
|
64
64
|
"Sets the HTML elements as fieldset and legend. This should be used when you want to group more than one input."
|
|
65
65
|
),
|
|
66
|
-
iconError:
|
|
66
|
+
iconError: import_ds_props_helpers.PropTypes.bool.description("Adds icon error extra styling.")
|
|
67
67
|
};
|
|
68
68
|
//# sourceMappingURL=propTypes.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/form-layout-block-item/propTypes.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from '@elliemae/ds-
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,
|
|
4
|
+
"sourcesContent": ["import { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from '@elliemae/ds-props-helpers';\n\nexport const defaultProps = {\n isGroup: false,\n};\n\nexport declare namespace DSFormLayoutBlockItemT {\n export interface PropsOptional {\n maxCharCounter?: number;\n currentChar?: number;\n inputID: string;\n iconError: boolean;\n validationMessage?: string;\n feedbackMessage?: string;\n hasError?: boolean;\n leftLabel?: boolean;\n required?: boolean;\n fitContent?: boolean;\n optional?: boolean;\n hideLabel?: boolean;\n withHighlight?: boolean;\n }\n\n export interface DefaultProps {\n isGroup?: boolean;\n }\n\n export interface PropsRequired {\n children: JSX.Element;\n label: string;\n }\n\n export interface Props extends PropsOptional, PropsRequired, DefaultProps {}\n export interface InternalProps extends PropsOptional, PropsRequired, Required<DefaultProps> {}\n}\n\nexport const propTypes = {\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n children: PropTypes.node.isRequired.description('Input component. '),\n label: PropTypes.string.description(\n 'Label property for the input component. This property is required for accesibility purposes.',\n ),\n inputID: PropTypes.string.description(\n \"String that matches the input component's id. This property is required for accesibility purposes.\",\n ),\n maxCharCounter: PropTypes.number.description('Max of characters allowed.'),\n currentChar: PropTypes.number.description('Current counter of input text area'),\n feedbackMessage: PropTypes.string.description('Feedback message to show below the input component.'),\n validationMessage: PropTypes.string.description(\n 'Validation message to show below the input component. It requires hasError property set to true to be visible.',\n ),\n hasError: PropTypes.bool.description('Helper boolean property for the validation message.'),\n required: PropTypes.bool.description('Adds required extra styling.'),\n optional: PropTypes.bool.description('Adds optional extra styling.'),\n fitContent: PropTypes.bool.description('Set the width of the layout to the input component.'),\n leftLabel: PropTypes.bool.description('Adds the label at the left of the input component.'),\n hideLabel: PropTypes.bool.description(\n 'Hides the input label. It still requires label and labelFor property for accesibility purposes',\n ),\n withHighlight: PropTypes.bool.description(\n 'Adds highlight extra styling. It requires extra spacing, please check withHighlight explanation tab.',\n ),\n isGroup: PropTypes.bool.description(\n 'Sets the HTML elements as fieldset and legend. This should be used when you want to group more than one input.',\n ),\n iconError: PropTypes.bool.description('Adds icon error extra styling.'),\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,8BAAuE;AAEhE,MAAM,eAAe;AAAA,EAC1B,SAAS;AACX;AAgCO,MAAM,YAAY;AAAA,EACvB,GAAG;AAAA,EACH,GAAG;AAAA,EACH,UAAU,kCAAU,KAAK,WAAW,YAAY,mBAAmB;AAAA,EACnE,OAAO,kCAAU,OAAO;AAAA,IACtB;AAAA,EACF;AAAA,EACA,SAAS,kCAAU,OAAO;AAAA,IACxB;AAAA,EACF;AAAA,EACA,gBAAgB,kCAAU,OAAO,YAAY,4BAA4B;AAAA,EACzE,aAAa,kCAAU,OAAO,YAAY,oCAAoC;AAAA,EAC9E,iBAAiB,kCAAU,OAAO,YAAY,qDAAqD;AAAA,EACnG,mBAAmB,kCAAU,OAAO;AAAA,IAClC;AAAA,EACF;AAAA,EACA,UAAU,kCAAU,KAAK,YAAY,qDAAqD;AAAA,EAC1F,UAAU,kCAAU,KAAK,YAAY,8BAA8B;AAAA,EACnE,UAAU,kCAAU,KAAK,YAAY,8BAA8B;AAAA,EACnE,YAAY,kCAAU,KAAK,YAAY,qDAAqD;AAAA,EAC5F,WAAW,kCAAU,KAAK,YAAY,oDAAoD;AAAA,EAC1F,WAAW,kCAAU,KAAK;AAAA,IACxB;AAAA,EACF;AAAA,EACA,eAAe,kCAAU,KAAK;AAAA,IAC5B;AAAA,EACF;AAAA,EACA,SAAS,kCAAU,KAAK;AAAA,IACtB;AAAA,EACF;AAAA,EACA,WAAW,kCAAU,KAAK,YAAY,gCAAgC;AACxE;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -30,7 +30,7 @@ __export(DSFormLayoutCheckboxGroup_exports, {
|
|
|
30
30
|
module.exports = __toCommonJS(DSFormLayoutCheckboxGroup_exports);
|
|
31
31
|
var React = __toESM(require("react"));
|
|
32
32
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
33
|
-
var
|
|
33
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
34
34
|
var import_styles = require("./styles");
|
|
35
35
|
var import_propTypes = require("./propTypes");
|
|
36
36
|
var import_useFormLayoutCheckboxGroup = require("./config/useFormLayoutCheckboxGroup");
|
|
@@ -44,6 +44,6 @@ const DSFormLayoutCheckboxGroup = (props) => {
|
|
|
44
44
|
};
|
|
45
45
|
DSFormLayoutCheckboxGroup.propTypes = import_propTypes.propTypes;
|
|
46
46
|
DSFormLayoutCheckboxGroup.displayName = "DSFormLayoutCheckboxGroup";
|
|
47
|
-
const DSFormLayoutCheckboxGroupWithSchema = (0,
|
|
47
|
+
const DSFormLayoutCheckboxGroupWithSchema = (0, import_ds_props_helpers.describe)(DSFormLayoutCheckboxGroup);
|
|
48
48
|
DSFormLayoutCheckboxGroupWithSchema.propTypes = import_propTypes.propTypes;
|
|
49
49
|
//# sourceMappingURL=DSFormLayoutCheckboxGroup.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/form-layout-checkbox-group/DSFormLayoutCheckboxGroup.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import React from 'react';\nimport { describe } from '@elliemae/ds-
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADcnB;AAbJ,
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { StyledContainer } from './styles';\nimport type { DSFormLayoutCheckboxGroupT } from './propTypes';\nimport { propTypes } from './propTypes';\nimport { useFormLayoutCheckboxGroup } from './config/useFormLayoutCheckboxGroup';\n\nconst DSFormLayoutCheckboxGroup = (props: DSFormLayoutCheckboxGroupT.Props): JSX.Element => {\n const {\n globalAttributes: { ...othersGlobalAttributes },\n xstyledProps,\n propsWithDefault,\n } = useFormLayoutCheckboxGroup(props);\n return (\n <StyledContainer role=\"group\" direction={propsWithDefault.direction} {...othersGlobalAttributes} {...xstyledProps}>\n {propsWithDefault.children}\n </StyledContainer>\n );\n};\n\nDSFormLayoutCheckboxGroup.propTypes = propTypes;\nDSFormLayoutCheckboxGroup.displayName = 'DSFormLayoutCheckboxGroup';\nconst DSFormLayoutCheckboxGroupWithSchema = describe(DSFormLayoutCheckboxGroup);\nDSFormLayoutCheckboxGroupWithSchema.propTypes = propTypes;\n\nexport { DSFormLayoutCheckboxGroup, DSFormLayoutCheckboxGroupWithSchema };\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADcnB;AAbJ,8BAAyB;AACzB,oBAAgC;AAEhC,uBAA0B;AAC1B,wCAA2C;AAE3C,MAAM,4BAA4B,CAAC,UAAyD;AAC1F,QAAM;AAAA,IACJ,kBAAkB,KAAK,uBAAuB;AAAA,IAC9C;AAAA,IACA;AAAA,EACF,QAAI,8DAA2B,KAAK;AACpC,SACE,4CAAC,iCAAgB,MAAK,SAAQ,WAAW,iBAAiB,WAAY,GAAG,wBAAyB,GAAG,cAClG,2BAAiB,UACpB;AAEJ;AAEA,0BAA0B,YAAY;AACtC,0BAA0B,cAAc;AACxC,MAAM,0CAAsC,kCAAS,yBAAyB;AAC9E,oCAAoC,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -29,14 +29,14 @@ __export(useFormLayoutCheckboxGroup_exports, {
|
|
|
29
29
|
module.exports = __toCommonJS(useFormLayoutCheckboxGroup_exports);
|
|
30
30
|
var React = __toESM(require("react"));
|
|
31
31
|
var import_react = __toESM(require("react"));
|
|
32
|
-
var
|
|
32
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
33
33
|
var import_propTypes = require("../propTypes");
|
|
34
34
|
var import_DSFormLayoutCheckboxGroupDefinitions = require("../DSFormLayoutCheckboxGroupDefinitions");
|
|
35
35
|
const useFormLayoutCheckboxGroup = (props) => {
|
|
36
|
-
(0,
|
|
37
|
-
const propsWithDefault = (0,
|
|
38
|
-
const globalAttributes = (0,
|
|
39
|
-
const xstyledProps = (0,
|
|
36
|
+
(0, import_ds_props_helpers.useValidateTypescriptPropTypes)(props, import_propTypes.propTypes, import_DSFormLayoutCheckboxGroupDefinitions.DSFormLayoutCheckboxGroupName);
|
|
37
|
+
const propsWithDefault = (0, import_ds_props_helpers.useMemoMergePropsWithDefault)(props, import_propTypes.defaultProps);
|
|
38
|
+
const globalAttributes = (0, import_ds_props_helpers.useGetGlobalAttributes)(propsWithDefault);
|
|
39
|
+
const xstyledProps = (0, import_ds_props_helpers.useGetXstyledProps)(propsWithDefault);
|
|
40
40
|
return import_react.default.useMemo(
|
|
41
41
|
() => ({ globalAttributes, xstyledProps, propsWithDefault }),
|
|
42
42
|
[globalAttributes, xstyledProps, propsWithDefault]
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../src/form-layout-checkbox-group/config/useFormLayoutCheckboxGroup.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import React from 'react';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAAkB;
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport type {} from '@elliemae/ds-utilities';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-props-helpers';\nimport {\n useGetGlobalAttributes,\n useGetXstyledProps,\n useMemoMergePropsWithDefault,\n useValidateTypescriptPropTypes,\n} from '@elliemae/ds-props-helpers';\nimport { propTypes, defaultProps, type DSFormLayoutCheckboxGroupT } from '../propTypes';\nimport { DSFormLayoutCheckboxGroupName } from '../DSFormLayoutCheckboxGroupDefinitions';\n\ninterface UseFormLayoutCheckboxGroupT {\n propsWithDefault: DSFormLayoutCheckboxGroupT.InternalProps;\n globalAttributes: GlobalAttributesT;\n xstyledProps: XstyledProps;\n}\n\nexport const useFormLayoutCheckboxGroup = (props: DSFormLayoutCheckboxGroupT.Props): UseFormLayoutCheckboxGroupT => {\n useValidateTypescriptPropTypes(props, propTypes, DSFormLayoutCheckboxGroupName);\n const propsWithDefault = useMemoMergePropsWithDefault<DSFormLayoutCheckboxGroupT.InternalProps>(props, defaultProps);\n const globalAttributes = useGetGlobalAttributes(propsWithDefault);\n\n const xstyledProps = useGetXstyledProps(propsWithDefault);\n return React.useMemo(\n () => ({ globalAttributes, xstyledProps, propsWithDefault }),\n [globalAttributes, xstyledProps, propsWithDefault],\n );\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,mBAAkB;AAGlB,8BAKO;AACP,uBAAyE;AACzE,kDAA8C;AAQvC,MAAM,6BAA6B,CAAC,UAAyE;AAClH,8DAA+B,OAAO,4BAAW,yEAA6B;AAC9E,QAAM,uBAAmB,sDAAuE,OAAO,6BAAY;AACnH,QAAM,uBAAmB,gDAAuB,gBAAgB;AAEhE,QAAM,mBAAe,4CAAmB,gBAAgB;AACxD,SAAO,aAAAA,QAAM;AAAA,IACX,OAAO,EAAE,kBAAkB,cAAc,iBAAiB;AAAA,IAC1D,CAAC,kBAAkB,cAAc,gBAAgB;AAAA,EACnD;AACF;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -29,13 +29,13 @@ __export(propTypes_exports, {
|
|
|
29
29
|
});
|
|
30
30
|
module.exports = __toCommonJS(propTypes_exports);
|
|
31
31
|
var React = __toESM(require("react"));
|
|
32
|
-
var
|
|
32
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
33
33
|
const defaultProps = {
|
|
34
34
|
direction: "horizontal"
|
|
35
35
|
};
|
|
36
36
|
const propTypes = {
|
|
37
|
-
...
|
|
38
|
-
...
|
|
39
|
-
direction:
|
|
37
|
+
...import_ds_props_helpers.globalAttributesPropTypes,
|
|
38
|
+
...import_ds_props_helpers.xstyledPropTypes,
|
|
39
|
+
direction: import_ds_props_helpers.PropTypes.oneOf(["horizontal", "vertical"]).description("Set direction for the checkbox group.")
|
|
40
40
|
};
|
|
41
41
|
//# sourceMappingURL=propTypes.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/form-layout-checkbox-group/propTypes.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["import { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from '@elliemae/ds-
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,
|
|
4
|
+
"sourcesContent": ["import { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from '@elliemae/ds-props-helpers';\n\nexport const defaultProps = {\n direction: 'horizontal',\n};\n\ntype DirectionsT = 'horizontal' | 'vertical';\n\nexport declare namespace DSFormLayoutCheckboxGroupT {\n export interface PropsRequired {\n direction: DirectionsT;\n children: JSX.Element;\n }\n\n export interface DefaultProps {\n direction?: string;\n }\n\n export interface Props extends PropsRequired, DefaultProps {}\n export interface InternalProps extends PropsRequired, Required<DefaultProps> {}\n}\n\nexport const propTypes = {\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n direction: PropTypes.oneOf(['horizontal', 'vertical']).description('Set direction for the checkbox group.'),\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,8BAAuE;AAEhE,MAAM,eAAe;AAAA,EAC1B,WAAW;AACb;AAkBO,MAAM,YAAY;AAAA,EACvB,GAAG;AAAA,EACH,GAAG;AAAA,EACH,WAAW,kCAAU,MAAM,CAAC,cAAc,UAAU,CAAC,EAAE,YAAY,uCAAuC;AAC5G;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,7 +2,7 @@ import * as React from "react";
|
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { useMemo } from "react";
|
|
4
4
|
import { Grid } from "@elliemae/ds-grid";
|
|
5
|
-
import { describe } from "@elliemae/ds-
|
|
5
|
+
import { describe } from "@elliemae/ds-props-helpers";
|
|
6
6
|
import { uid } from "uid";
|
|
7
7
|
import { AlertsSmallFill } from "@elliemae/ds-icons";
|
|
8
8
|
import { DSFormLayoutBlockItemDataTestId } from "../exported-related/DSFormLayoutBlockItemDataTestId";
|
|
@@ -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 } from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { describe } from '@elliemae/ds-
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable complexity */\nimport React, { useMemo } 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 { DSFormLayoutBlockItemDataTestId } from '../exported-related/DSFormLayoutBlockItemDataTestId';\nimport type { DSFormLayoutBlockItemT } from './propTypes';\nimport { propTypes } from './propTypes';\nimport { StyledMessage, StyledLabel, StyledContainer, StyledMark, ScreenReaderOnly, StyledCharCount } from './styles';\nimport { useFormLayoutBlockItem } from './config/useFormLayoutBlockItem';\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(() => `form_layout_block_item_${uid(6)}`, []);\n\n const cols = useMemo(() => (maxCharCounter !== undefined ? ['1fr', 'auto'] : ['1fr']), [maxCharCounter]);\n\n return (\n <StyledContainer\n data-testid={DSFormLayoutBlockItemDataTestId.CONTAINER}\n leftLabel={leftLabel}\n fitContent={fitContent}\n hideLabel={hideLabel}\n withHighlight={withHighlight}\n as={isGroup ? 'fieldset' : 'div'}\n isGroup={isGroup}\n aria-describedby={!isGroup ? `${inputID || instanceUID}_feedback_message` : undefined}\n className={className}\n {...xstyledProps}\n >\n <Grid cols={cols} gutter=\"xxs\">\n <StyledLabel\n id={`${inputID}_block_label`}\n data-testid={DSFormLayoutBlockItemDataTestId.LABEL}\n htmlFor={inputID}\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n aria-hidden={isGroup}\n {...othersGlobalAttributes}\n >\n {label}\n {(required || optional) && <StyledMark required={required} />}\n </StyledLabel>\n {maxCharCounter !== undefined && currentChar !== undefined ? (\n <StyledCharCount\n data-testid={DSFormLayoutBlockItemDataTestId.COUNTER}\n hasError={currentChar > maxCharCounter}\n >{`${currentChar}/${maxCharCounter}`}</StyledCharCount>\n ) : null}\n </Grid>\n {isGroup && <ScreenReaderOnly as=\"legend\">{`${label}. ${feedbackMessage || ''}`}</ScreenReaderOnly>}\n {children}\n {feedbackMessage && !hasError && (\n <StyledMessage\n data-testid={DSFormLayoutBlockItemDataTestId.MESSAGE}\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n aria-hidden={isGroup}\n id={`${inputID || instanceUID}_feedback_message`}\n >\n {feedbackMessage}\n </StyledMessage>\n )}\n {validationMessage && hasError && (\n <StyledMessage\n data-testid={DSFormLayoutBlockItemDataTestId.ERROR_MESSAGE}\n hasError={hasError}\n leftLabel={leftLabel}\n hideLabel={hideLabel}\n role=\"alert\"\n id={`${inputID || instanceUID}_error_message`}\n >\n <AlertsSmallFill width={8} height={8} color={['danger', '900']} style={{ marginBottom: '2px' }} />\n \n {`${validationMessage} ${label}`}\n </StyledMessage>\n )}\n </StyledContainer>\n );\n};\n\nDSFormLayoutBlockItem.propTypes = propTypes;\nDSFormLayoutBlockItem.displayName = 'DSFormLayoutBlockItem';\nconst DSFormLayoutBlockItemWithSchema = describe(DSFormLayoutBlockItem);\nDSFormLayoutBlockItemWithSchema.propTypes = propTypes;\n\nexport { DSFormLayoutBlockItem, DSFormLayoutBlockItemWithSchema };\n"],
|
|
5
5
|
"mappings": "AAAA,YAAY,WAAW;ACmDf,SAU6B,KAV7B;AAlDR,SAAgB,eAAe;AAC/B,SAAS,YAAY;AACrB,SAAS,gBAAgB;AACzB,SAAS,WAAW;AACpB,SAAS,uBAAuB;AAChC,SAAS,uCAAuC;AAEhD,SAAS,iBAAiB;AAC1B,SAAS,eAAe,aAAa,iBAAiB,YAAY,kBAAkB,uBAAuB;AAC3G,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;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF,IAAI;AAEJ,QAAM,EAAE,WAAW,OAAO,gBAAgB,uBAAuB,IAAI;AACrE,QAAM,cAAc,QAAQ,MAAM,0BAA0B,IAAI,CAAC,KAAK,CAAC,CAAC;AAExE,QAAM,OAAO,QAAQ,MAAO,mBAAmB,SAAY,CAAC,OAAO,MAAM,IAAI,CAAC,KAAK,GAAI,CAAC,cAAc,CAAC;AAEvG,SACE;AAAA,IAAC;AAAA;AAAA,MACC,eAAa,gCAAgC;AAAA,MAC7C;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,IAAI,UAAU,aAAa;AAAA,MAC3B;AAAA,MACA,oBAAkB,CAAC,UAAU,GAAG,WAAW,iCAAiC;AAAA,MAC5E;AAAA,MACC,GAAG;AAAA,MAEJ;AAAA,6BAAC,QAAK,MAAY,QAAO,OACvB;AAAA;AAAA,YAAC;AAAA;AAAA,cACC,IAAI,GAAG;AAAA,cACP,eAAa,gCAAgC;AAAA,cAC7C,SAAS;AAAA,cACT;AAAA,cACA;AAAA,cACA,eAAa;AAAA,cACZ,GAAG;AAAA,cAEH;AAAA;AAAA,iBACC,YAAY,aAAa,oBAAC,cAAW,UAAoB;AAAA;AAAA;AAAA,UAC7D;AAAA,UACC,mBAAmB,UAAa,gBAAgB,SAC/C;AAAA,YAAC;AAAA;AAAA,cACC,eAAa,gCAAgC;AAAA,cAC7C,UAAU,cAAc;AAAA,cACxB,aAAG,eAAe;AAAA;AAAA,UAAiB,IACnC;AAAA,WACN;AAAA,QACC,WAAW,oBAAC,oBAAiB,IAAG,UAAU,aAAG,UAAU,mBAAmB,MAAK;AAAA,QAC/E;AAAA,QACA,mBAAmB,CAAC,YACnB;AAAA,UAAC;AAAA;AAAA,YACC,eAAa,gCAAgC;AAAA,YAC7C;AAAA,YACA;AAAA,YACA,eAAa;AAAA,YACb,IAAI,GAAG,WAAW;AAAA,YAEjB;AAAA;AAAA,QACH;AAAA,QAED,qBAAqB,YACpB;AAAA,UAAC;AAAA;AAAA,YACC,eAAa,gCAAgC;AAAA,YAC7C;AAAA,YACA;AAAA,YACA;AAAA,YACA,MAAK;AAAA,YACL,IAAI,GAAG,WAAW;AAAA,YAElB;AAAA,kCAAC,mBAAgB,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAC,UAAU,KAAK,GAAG,OAAO,EAAE,cAAc,MAAM,GAAG;AAAA,cAAE;AAAA,cAEjG,GAAG,qBAAqB;AAAA;AAAA;AAAA,QAC3B;AAAA;AAAA;AAAA,EAEJ;AAEJ;AAEA,sBAAsB,YAAY;AAClC,sBAAsB,cAAc;AACpC,MAAM,kCAAkC,SAAS,qBAAqB;AACtE,gCAAgC,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
useGetXstyledProps,
|
|
6
6
|
useMemoMergePropsWithDefault,
|
|
7
7
|
useValidateTypescriptPropTypes
|
|
8
|
-
} from "@elliemae/ds-
|
|
8
|
+
} from "@elliemae/ds-props-helpers";
|
|
9
9
|
import { propTypes, defaultProps } from "../propTypes";
|
|
10
10
|
import { DSFormLayoutBlockItemName } from "../DSFormLayoutBlockItemDefinitions";
|
|
11
11
|
const useFormLayoutBlockItem = (props) => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/form-layout-block-item/config/useFormLayoutBlockItem.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACAvB,OAAOA,YAAW;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport type {} from '@elliemae/ds-utilities';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-props-helpers';\nimport {\n useGetGlobalAttributes,\n useGetXstyledProps,\n useMemoMergePropsWithDefault,\n useValidateTypescriptPropTypes,\n} from '@elliemae/ds-props-helpers';\nimport { propTypes, defaultProps, type DSFormLayoutBlockItemT } from '../propTypes';\nimport { DSFormLayoutBlockItemName } from '../DSFormLayoutBlockItemDefinitions';\n\ninterface UseFormLayoutBlockItemT {\n propsWithDefault: DSFormLayoutBlockItemT.InternalProps;\n globalAttributes: GlobalAttributesT;\n xstyledProps: XstyledProps;\n}\n\nexport const useFormLayoutBlockItem = (props: DSFormLayoutBlockItemT.Props): UseFormLayoutBlockItemT => {\n useValidateTypescriptPropTypes(props, propTypes, DSFormLayoutBlockItemName);\n const propsWithDefault = useMemoMergePropsWithDefault<DSFormLayoutBlockItemT.InternalProps>(props, defaultProps);\n const globalAttributes = useGetGlobalAttributes(propsWithDefault);\n\n const xstyledProps = useGetXstyledProps(propsWithDefault);\n return React.useMemo(\n () => ({ globalAttributes, xstyledProps, propsWithDefault }),\n [globalAttributes, xstyledProps, propsWithDefault],\n );\n};\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACAvB,OAAOA,YAAW;AAGlB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AACP,SAAS,WAAW,oBAAiD;AACrE,SAAS,iCAAiC;AAQnC,MAAM,yBAAyB,CAAC,UAAiE;AACtG,iCAA+B,OAAO,WAAW,yBAAyB;AAC1E,QAAM,mBAAmB,6BAAmE,OAAO,YAAY;AAC/G,QAAM,mBAAmB,uBAAuB,gBAAgB;AAEhE,QAAM,eAAe,mBAAmB,gBAAgB;AACxD,SAAOA,OAAM;AAAA,IACX,OAAO,EAAE,kBAAkB,cAAc,iBAAiB;AAAA,IAC1D,CAAC,kBAAkB,cAAc,gBAAgB;AAAA,EACnD;AACF;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
-
import { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from "@elliemae/ds-
|
|
2
|
+
import { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from "@elliemae/ds-props-helpers";
|
|
3
3
|
const defaultProps = {
|
|
4
4
|
isGroup: false
|
|
5
5
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/form-layout-block-item/propTypes.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from '@elliemae/ds-
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from '@elliemae/ds-props-helpers';\n\nexport const defaultProps = {\n isGroup: false,\n};\n\nexport declare namespace DSFormLayoutBlockItemT {\n export interface PropsOptional {\n maxCharCounter?: number;\n currentChar?: number;\n inputID: string;\n iconError: boolean;\n validationMessage?: string;\n feedbackMessage?: string;\n hasError?: boolean;\n leftLabel?: boolean;\n required?: boolean;\n fitContent?: boolean;\n optional?: boolean;\n hideLabel?: boolean;\n withHighlight?: boolean;\n }\n\n export interface DefaultProps {\n isGroup?: boolean;\n }\n\n export interface PropsRequired {\n children: JSX.Element;\n label: string;\n }\n\n export interface Props extends PropsOptional, PropsRequired, DefaultProps {}\n export interface InternalProps extends PropsOptional, PropsRequired, Required<DefaultProps> {}\n}\n\nexport const propTypes = {\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n children: PropTypes.node.isRequired.description('Input component. '),\n label: PropTypes.string.description(\n 'Label property for the input component. This property is required for accesibility purposes.',\n ),\n inputID: PropTypes.string.description(\n \"String that matches the input component's id. This property is required for accesibility purposes.\",\n ),\n maxCharCounter: PropTypes.number.description('Max of characters allowed.'),\n currentChar: PropTypes.number.description('Current counter of input text area'),\n feedbackMessage: PropTypes.string.description('Feedback message to show below the input component.'),\n validationMessage: PropTypes.string.description(\n 'Validation message to show below the input component. It requires hasError property set to true to be visible.',\n ),\n hasError: PropTypes.bool.description('Helper boolean property for the validation message.'),\n required: PropTypes.bool.description('Adds required extra styling.'),\n optional: PropTypes.bool.description('Adds optional extra styling.'),\n fitContent: PropTypes.bool.description('Set the width of the layout to the input component.'),\n leftLabel: PropTypes.bool.description('Adds the label at the left of the input component.'),\n hideLabel: PropTypes.bool.description(\n 'Hides the input label. It still requires label and labelFor property for accesibility purposes',\n ),\n withHighlight: PropTypes.bool.description(\n 'Adds highlight extra styling. It requires extra spacing, please check withHighlight explanation tab.',\n ),\n isGroup: PropTypes.bool.description(\n 'Sets the HTML elements as fieldset and legend. This should be used when you want to group more than one input.',\n ),\n iconError: PropTypes.bool.description('Adds icon error extra styling.'),\n};\n"],
|
|
5
5
|
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,WAAW,2BAA2B,wBAAwB;AAEhE,MAAM,eAAe;AAAA,EAC1B,SAAS;AACX;AAgCO,MAAM,YAAY;AAAA,EACvB,GAAG;AAAA,EACH,GAAG;AAAA,EACH,UAAU,UAAU,KAAK,WAAW,YAAY,mBAAmB;AAAA,EACnE,OAAO,UAAU,OAAO;AAAA,IACtB;AAAA,EACF;AAAA,EACA,SAAS,UAAU,OAAO;AAAA,IACxB;AAAA,EACF;AAAA,EACA,gBAAgB,UAAU,OAAO,YAAY,4BAA4B;AAAA,EACzE,aAAa,UAAU,OAAO,YAAY,oCAAoC;AAAA,EAC9E,iBAAiB,UAAU,OAAO,YAAY,qDAAqD;AAAA,EACnG,mBAAmB,UAAU,OAAO;AAAA,IAClC;AAAA,EACF;AAAA,EACA,UAAU,UAAU,KAAK,YAAY,qDAAqD;AAAA,EAC1F,UAAU,UAAU,KAAK,YAAY,8BAA8B;AAAA,EACnE,UAAU,UAAU,KAAK,YAAY,8BAA8B;AAAA,EACnE,YAAY,UAAU,KAAK,YAAY,qDAAqD;AAAA,EAC5F,WAAW,UAAU,KAAK,YAAY,oDAAoD;AAAA,EAC1F,WAAW,UAAU,KAAK;AAAA,IACxB;AAAA,EACF;AAAA,EACA,eAAe,UAAU,KAAK;AAAA,IAC5B;AAAA,EACF;AAAA,EACA,SAAS,UAAU,KAAK;AAAA,IACtB;AAAA,EACF;AAAA,EACA,WAAW,UAAU,KAAK,YAAY,gCAAgC;AACxE;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
|
-
import { describe } from "@elliemae/ds-
|
|
3
|
+
import { describe } from "@elliemae/ds-props-helpers";
|
|
4
4
|
import { StyledContainer } from "./styles";
|
|
5
5
|
import { propTypes } from "./propTypes";
|
|
6
6
|
import { useFormLayoutCheckboxGroup } from "./config/useFormLayoutCheckboxGroup";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/form-layout-checkbox-group/DSFormLayoutCheckboxGroup.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { describe } from '@elliemae/ds-
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { StyledContainer } from './styles';\nimport type { DSFormLayoutCheckboxGroupT } from './propTypes';\nimport { propTypes } from './propTypes';\nimport { useFormLayoutCheckboxGroup } from './config/useFormLayoutCheckboxGroup';\n\nconst DSFormLayoutCheckboxGroup = (props: DSFormLayoutCheckboxGroupT.Props): JSX.Element => {\n const {\n globalAttributes: { ...othersGlobalAttributes },\n xstyledProps,\n propsWithDefault,\n } = useFormLayoutCheckboxGroup(props);\n return (\n <StyledContainer role=\"group\" direction={propsWithDefault.direction} {...othersGlobalAttributes} {...xstyledProps}>\n {propsWithDefault.children}\n </StyledContainer>\n );\n};\n\nDSFormLayoutCheckboxGroup.propTypes = propTypes;\nDSFormLayoutCheckboxGroup.displayName = 'DSFormLayoutCheckboxGroup';\nconst DSFormLayoutCheckboxGroupWithSchema = describe(DSFormLayoutCheckboxGroup);\nDSFormLayoutCheckboxGroupWithSchema.propTypes = propTypes;\n\nexport { DSFormLayoutCheckboxGroup, DSFormLayoutCheckboxGroupWithSchema };\n"],
|
|
5
5
|
"mappings": "AAAA,YAAY,WAAW;ACcnB;AAbJ,SAAS,gBAAgB;AACzB,SAAS,uBAAuB;AAEhC,SAAS,iBAAiB;AAC1B,SAAS,kCAAkC;AAE3C,MAAM,4BAA4B,CAAC,UAAyD;AAC1F,QAAM;AAAA,IACJ,kBAAkB,KAAK,uBAAuB;AAAA,IAC9C;AAAA,IACA;AAAA,EACF,IAAI,2BAA2B,KAAK;AACpC,SACE,oBAAC,mBAAgB,MAAK,SAAQ,WAAW,iBAAiB,WAAY,GAAG,wBAAyB,GAAG,cAClG,2BAAiB,UACpB;AAEJ;AAEA,0BAA0B,YAAY;AACtC,0BAA0B,cAAc;AACxC,MAAM,sCAAsC,SAAS,yBAAyB;AAC9E,oCAAoC,YAAY;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
useGetXstyledProps,
|
|
6
6
|
useMemoMergePropsWithDefault,
|
|
7
7
|
useValidateTypescriptPropTypes
|
|
8
|
-
} from "@elliemae/ds-
|
|
8
|
+
} from "@elliemae/ds-props-helpers";
|
|
9
9
|
import { propTypes, defaultProps } from "../propTypes";
|
|
10
10
|
import { DSFormLayoutCheckboxGroupName } from "../DSFormLayoutCheckboxGroupDefinitions";
|
|
11
11
|
const useFormLayoutCheckboxGroup = (props) => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/form-layout-checkbox-group/config/useFormLayoutCheckboxGroup.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-
|
|
5
|
-
"mappings": "AAAA,YAAY,WAAW;ACAvB,OAAOA,YAAW;
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport type {} from '@elliemae/ds-utilities';\nimport type { GlobalAttributesT, XstyledProps } from '@elliemae/ds-props-helpers';\nimport {\n useGetGlobalAttributes,\n useGetXstyledProps,\n useMemoMergePropsWithDefault,\n useValidateTypescriptPropTypes,\n} from '@elliemae/ds-props-helpers';\nimport { propTypes, defaultProps, type DSFormLayoutCheckboxGroupT } from '../propTypes';\nimport { DSFormLayoutCheckboxGroupName } from '../DSFormLayoutCheckboxGroupDefinitions';\n\ninterface UseFormLayoutCheckboxGroupT {\n propsWithDefault: DSFormLayoutCheckboxGroupT.InternalProps;\n globalAttributes: GlobalAttributesT;\n xstyledProps: XstyledProps;\n}\n\nexport const useFormLayoutCheckboxGroup = (props: DSFormLayoutCheckboxGroupT.Props): UseFormLayoutCheckboxGroupT => {\n useValidateTypescriptPropTypes(props, propTypes, DSFormLayoutCheckboxGroupName);\n const propsWithDefault = useMemoMergePropsWithDefault<DSFormLayoutCheckboxGroupT.InternalProps>(props, defaultProps);\n const globalAttributes = useGetGlobalAttributes(propsWithDefault);\n\n const xstyledProps = useGetXstyledProps(propsWithDefault);\n return React.useMemo(\n () => ({ globalAttributes, xstyledProps, propsWithDefault }),\n [globalAttributes, xstyledProps, propsWithDefault],\n );\n};\n"],
|
|
5
|
+
"mappings": "AAAA,YAAY,WAAW;ACAvB,OAAOA,YAAW;AAGlB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AACP,SAAS,WAAW,oBAAqD;AACzE,SAAS,qCAAqC;AAQvC,MAAM,6BAA6B,CAAC,UAAyE;AAClH,iCAA+B,OAAO,WAAW,6BAA6B;AAC9E,QAAM,mBAAmB,6BAAuE,OAAO,YAAY;AACnH,QAAM,mBAAmB,uBAAuB,gBAAgB;AAEhE,QAAM,eAAe,mBAAmB,gBAAgB;AACxD,SAAOA,OAAM;AAAA,IACX,OAAO,EAAE,kBAAkB,cAAc,iBAAiB;AAAA,IAC1D,CAAC,kBAAkB,cAAc,gBAAgB;AAAA,EACnD;AACF;",
|
|
6
6
|
"names": ["React"]
|
|
7
7
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from "react";
|
|
2
|
-
import { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from "@elliemae/ds-
|
|
2
|
+
import { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from "@elliemae/ds-props-helpers";
|
|
3
3
|
const defaultProps = {
|
|
4
4
|
direction: "horizontal"
|
|
5
5
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/form-layout-checkbox-group/propTypes.tsx"],
|
|
4
|
-
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from '@elliemae/ds-
|
|
4
|
+
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { PropTypes, globalAttributesPropTypes, xstyledPropTypes } from '@elliemae/ds-props-helpers';\n\nexport const defaultProps = {\n direction: 'horizontal',\n};\n\ntype DirectionsT = 'horizontal' | 'vertical';\n\nexport declare namespace DSFormLayoutCheckboxGroupT {\n export interface PropsRequired {\n direction: DirectionsT;\n children: JSX.Element;\n }\n\n export interface DefaultProps {\n direction?: string;\n }\n\n export interface Props extends PropsRequired, DefaultProps {}\n export interface InternalProps extends PropsRequired, Required<DefaultProps> {}\n}\n\nexport const propTypes = {\n ...globalAttributesPropTypes,\n ...xstyledPropTypes,\n direction: PropTypes.oneOf(['horizontal', 'vertical']).description('Set direction for the checkbox group.'),\n};\n"],
|
|
5
5
|
"mappings": "AAAA,YAAY,WAAW;ACAvB,SAAS,WAAW,2BAA2B,wBAAwB;AAEhE,MAAM,eAAe;AAAA,EAC1B,WAAW;AACb;AAkBO,MAAM,YAAY;AAAA,EACvB,GAAG;AAAA,EACH,GAAG;AAAA,EACH,WAAW,UAAU,MAAM,CAAC,cAAc,UAAU,CAAC,EAAE,YAAY,uCAAuC;AAC5G;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|