@elliemae/ds-form 3.3.1-rc.0 → 3.3.1-rc.1
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/esm/Checkbox/index.js +0 -1
- package/dist/esm/Checkbox/index.js.map +1 -1
- package/dist/esm/CheckboxGroup/DSCheckboxGroup.js +0 -1
- package/dist/esm/CheckboxGroup/DSCheckboxGroup.js.map +1 -1
- package/dist/esm/CheckboxGroup/defaultProps.js +0 -1
- package/dist/esm/CheckboxGroup/defaultProps.js.map +1 -1
- package/dist/esm/CheckboxGroup/index.js +0 -1
- package/dist/esm/CheckboxGroup/index.js.map +1 -1
- package/dist/esm/CheckboxGroup/props.js +0 -1
- package/dist/esm/CheckboxGroup/props.js.map +1 -1
- package/dist/esm/ComboBox/index.js +0 -1
- package/dist/esm/ComboBox/index.js.map +1 -1
- package/dist/esm/ComboBoxFreeSolo/ComboBoxFreeSolo.js +0 -1
- package/dist/esm/ComboBoxFreeSolo/ComboBoxFreeSolo.js.map +1 -1
- package/dist/esm/ComboBoxFreeSolo/components/MultiValueLabel.js +0 -1
- package/dist/esm/ComboBoxFreeSolo/components/MultiValueLabel.js.map +1 -1
- package/dist/esm/ComboBoxFreeSolo/components/MultiValueRemove.js +0 -1
- package/dist/esm/ComboBoxFreeSolo/components/MultiValueRemove.js.map +1 -1
- package/dist/esm/ComboBoxFreeSolo/components/SingleValue.js +0 -1
- package/dist/esm/ComboBoxFreeSolo/components/SingleValue.js.map +1 -1
- package/dist/esm/ComboBoxFreeSolo/components/SingleValueRemove.js +0 -1
- package/dist/esm/ComboBoxFreeSolo/components/SingleValueRemove.js.map +1 -1
- package/dist/esm/ComboBoxFreeSolo/index.js +0 -1
- package/dist/esm/ComboBoxFreeSolo/index.js.map +1 -1
- package/dist/esm/DateInput/DSDateInput.js +0 -1
- package/dist/esm/DateInput/DSDateInput.js.map +1 -1
- package/dist/esm/DateInput/components/DateInputImpl.js +0 -1
- package/dist/esm/DateInput/components/DateInputImpl.js.map +1 -1
- package/dist/esm/DateInput/components/DateInputs.js +0 -1
- package/dist/esm/DateInput/components/DateInputs.js.map +1 -1
- package/dist/esm/DateInput/components/utils.js +0 -1
- package/dist/esm/DateInput/components/utils.js.map +1 -1
- package/dist/esm/DateInput/defaultProps.js +0 -1
- package/dist/esm/DateInput/defaultProps.js.map +1 -1
- package/dist/esm/DateInput/index.js +0 -1
- package/dist/esm/DateInput/index.js.map +1 -1
- package/dist/esm/DateInput/props.js +0 -1
- package/dist/esm/DateInput/props.js.map +1 -1
- package/dist/esm/DateInputV2/components/DSDateInput.js +0 -1
- package/dist/esm/DateInputV2/components/DSDateInput.js.map +1 -1
- package/dist/esm/DateInputV2/components/DateInputs.js +0 -1
- package/dist/esm/DateInputV2/components/DateInputs.js.map +1 -1
- package/dist/esm/DateInputV2/components/helpers.js +0 -1
- package/dist/esm/DateInputV2/components/helpers.js.map +1 -1
- package/dist/esm/DateInputV2/components/props.js +0 -1
- package/dist/esm/DateInputV2/components/props.js.map +1 -1
- package/dist/esm/DateInputV2/components/propsTypes.js +0 -1
- package/dist/esm/DateInputV2/components/propsTypes.js.map +1 -1
- package/dist/esm/DateInputV2/components/styled.js +0 -1
- package/dist/esm/DateInputV2/components/styled.js.map +1 -1
- package/dist/esm/DateInputV2/components/utils.js +0 -1
- package/dist/esm/DateInputV2/components/utils.js.map +1 -1
- package/dist/esm/DateInputV2/index.js +0 -1
- package/dist/esm/DateInputV2/index.js.map +1 -1
- package/dist/esm/ExpandableInput/DSExpandableInput.js +0 -1
- package/dist/esm/ExpandableInput/DSExpandableInput.js.map +1 -1
- package/dist/esm/ExpandableInput/ExpandableInputImpl.js +0 -1
- package/dist/esm/ExpandableInput/ExpandableInputImpl.js.map +1 -1
- package/dist/esm/ExpandableInput/index.js +0 -1
- package/dist/esm/ExpandableInput/index.js.map +1 -1
- package/dist/esm/FloatingLabelInput/DSFloatingLabelInput.js +0 -1
- package/dist/esm/FloatingLabelInput/DSFloatingLabelInput.js.map +1 -1
- package/dist/esm/FloatingLabelInput/FloatingLabelInputImpl.js +0 -1
- package/dist/esm/FloatingLabelInput/FloatingLabelInputImpl.js.map +1 -1
- package/dist/esm/FloatingLabelInput/getSvgPath.js +0 -1
- package/dist/esm/FloatingLabelInput/getSvgPath.js.map +1 -1
- package/dist/esm/FloatingLabelInput/index.js +0 -1
- package/dist/esm/FloatingLabelInput/index.js.map +1 -1
- package/dist/esm/FormItem/DSFormItemLayout.js +0 -1
- package/dist/esm/FormItem/DSFormItemLayout.js.map +1 -1
- package/dist/esm/FormItem/Error/DSError.js +0 -1
- package/dist/esm/FormItem/Error/DSError.js.map +1 -1
- package/dist/esm/FormItem/Feedback.js +0 -1
- package/dist/esm/FormItem/Feedback.js.map +1 -1
- package/dist/esm/FormItem/Label/DSLabel.js +0 -1
- package/dist/esm/FormItem/Label/DSLabel.js.map +1 -1
- package/dist/esm/FormItem/Suffix/Suffix.js +0 -1
- package/dist/esm/FormItem/Suffix/Suffix.js.map +1 -1
- package/dist/esm/FormItem/ValidationFieldWrapper.js +0 -1
- package/dist/esm/FormItem/ValidationFieldWrapper.js.map +1 -1
- package/dist/esm/FormItem/defaultProps.js +0 -1
- package/dist/esm/FormItem/defaultProps.js.map +1 -1
- package/dist/esm/FormItem/index.js +0 -1
- package/dist/esm/FormItem/index.js.map +1 -1
- package/dist/esm/FormItem/props.js +0 -1
- package/dist/esm/FormItem/props.js.map +1 -1
- package/dist/esm/FormItem/variants.js +0 -1
- package/dist/esm/FormItem/variants.js.map +1 -1
- package/dist/esm/Input/DSInput.js +0 -1
- package/dist/esm/Input/DSInput.js.map +1 -1
- package/dist/esm/Input/InputAddonWrapper.js +0 -1
- package/dist/esm/Input/InputAddonWrapper.js.map +1 -1
- package/dist/esm/Input/InputImpl.js +0 -1
- package/dist/esm/Input/InputImpl.js.map +1 -1
- package/dist/esm/Input/index.js +0 -1
- package/dist/esm/Input/index.js.map +1 -1
- package/dist/esm/InputGroup/AddonWrapper.js +0 -1
- package/dist/esm/InputGroup/AddonWrapper.js.map +1 -1
- package/dist/esm/InputGroup/DSInputGroup.js +0 -1
- package/dist/esm/InputGroup/DSInputGroup.js.map +1 -1
- package/dist/esm/InputGroup/defaultProps.js +0 -1
- package/dist/esm/InputGroup/defaultProps.js.map +1 -1
- package/dist/esm/InputGroup/index.js +0 -1
- package/dist/esm/InputGroup/index.js.map +1 -1
- package/dist/esm/InputGroup/props.js +0 -1
- package/dist/esm/InputGroup/props.js.map +1 -1
- package/dist/esm/InputMask/DSInputMask.js +0 -1
- package/dist/esm/InputMask/DSInputMask.js.map +1 -1
- package/dist/esm/InputMask/DSInputMaskDeprecated.js +0 -1
- package/dist/esm/InputMask/DSInputMaskDeprecated.js.map +1 -1
- package/dist/esm/InputMask/InputMaskContext.js +0 -1
- package/dist/esm/InputMask/InputMaskContext.js.map +1 -1
- package/dist/esm/InputMask/MaskPipes.js +0 -1
- package/dist/esm/InputMask/MaskPipes.js.map +1 -1
- package/dist/esm/InputMask/MaskTypes.js +0 -1
- package/dist/esm/InputMask/MaskTypes.js.map +1 -1
- package/dist/esm/InputMask/addons/AutoCorrectedDatePipe.js +0 -1
- package/dist/esm/InputMask/addons/AutoCorrectedDatePipe.js.map +1 -1
- package/dist/esm/InputMask/defaultProps.js +0 -1
- package/dist/esm/InputMask/defaultProps.js.map +1 -1
- package/dist/esm/InputMask/index.js +0 -1
- package/dist/esm/InputMask/index.js.map +1 -1
- package/dist/esm/InputMask/mask_types/DateInputMask.js +0 -1
- package/dist/esm/InputMask/mask_types/DateInputMask.js.map +1 -1
- package/dist/esm/InputMask/mask_types/DateTimeInputMask.js +0 -1
- package/dist/esm/InputMask/mask_types/DateTimeInputMask.js.map +1 -1
- package/dist/esm/InputMask/mask_types/DictionaryInputMask.js +0 -1
- package/dist/esm/InputMask/mask_types/DictionaryInputMask.js.map +1 -1
- package/dist/esm/InputMask/mask_types/NumberInputMask.js +0 -1
- package/dist/esm/InputMask/mask_types/NumberInputMask.js.map +1 -1
- package/dist/esm/InputMask/mask_types/PhoneInputMask.js +0 -1
- package/dist/esm/InputMask/mask_types/PhoneInputMask.js.map +1 -1
- package/dist/esm/InputMask/mask_types/PhoneInternationalInputMask.js +0 -1
- package/dist/esm/InputMask/mask_types/PhoneInternationalInputMask.js.map +1 -1
- package/dist/esm/InputMask/mask_types/SsnInputMask.js +0 -1
- package/dist/esm/InputMask/mask_types/SsnInputMask.js.map +1 -1
- package/dist/esm/InputMask/mask_types/UsZipCodeInputMask.js +0 -1
- package/dist/esm/InputMask/mask_types/UsZipCodeInputMask.js.map +1 -1
- package/dist/esm/InputMask/mask_types/ZipCodeSearchInputMask.js +0 -1
- package/dist/esm/InputMask/mask_types/ZipCodeSearchInputMask.js.map +1 -1
- package/dist/esm/InputMask/mask_types/index.js +0 -1
- package/dist/esm/InputMask/mask_types/index.js.map +1 -1
- package/dist/esm/InputMask/props.js +0 -1
- package/dist/esm/InputMask/props.js.map +1 -1
- package/dist/esm/InputMask/types/index.js +0 -1
- package/dist/esm/InputMask/types/index.js.map +1 -1
- package/dist/esm/InputMask/utils/setCaretPosition.js +0 -1
- package/dist/esm/InputMask/utils/setCaretPosition.js.map +1 -1
- package/dist/esm/InputProtected/DSInputProtected.js +0 -1
- package/dist/esm/InputProtected/DSInputProtected.js.map +1 -1
- package/dist/esm/InputProtected/defaultProps.js +0 -1
- package/dist/esm/InputProtected/defaultProps.js.map +1 -1
- package/dist/esm/InputProtected/index.js +0 -1
- package/dist/esm/InputProtected/index.js.map +1 -1
- package/dist/esm/InputProtected/options.js +0 -1
- package/dist/esm/InputProtected/options.js.map +1 -1
- package/dist/esm/InputProtected/props.js +0 -1
- package/dist/esm/InputProtected/props.js.map +1 -1
- package/dist/esm/LargeInputText/DSLargeInputText.js +0 -1
- package/dist/esm/LargeInputText/DSLargeInputText.js.map +1 -1
- package/dist/esm/LargeInputText/defaultProps.js +0 -1
- package/dist/esm/LargeInputText/defaultProps.js.map +1 -1
- package/dist/esm/LargeInputText/index.js +0 -1
- package/dist/esm/LargeInputText/index.js.map +1 -1
- package/dist/esm/LargeInputText/props.js +0 -1
- package/dist/esm/LargeInputText/props.js.map +1 -1
- package/dist/esm/MenuItem/components/MenuItem/index.js +0 -1
- package/dist/esm/MenuItem/components/MenuItem/index.js.map +1 -1
- package/dist/esm/MenuItem/components/MenuItem/styled.js +0 -1
- package/dist/esm/MenuItem/components/MenuItem/styled.js.map +1 -1
- package/dist/esm/MenuItem/components/MultiMenuItem/MultiMenuItem.js +0 -1
- package/dist/esm/MenuItem/components/MultiMenuItem/MultiMenuItem.js.map +1 -1
- package/dist/esm/MenuItem/components/MultiMenuItem/styled.js +0 -1
- package/dist/esm/MenuItem/components/MultiMenuItem/styled.js.map +1 -1
- package/dist/esm/MenuItem/components/Section/index.js +0 -1
- package/dist/esm/MenuItem/components/Section/index.js.map +1 -1
- package/dist/esm/MenuItem/components/Section/props.js +0 -1
- package/dist/esm/MenuItem/components/Section/props.js.map +1 -1
- package/dist/esm/MenuItem/components/Section/styled.js +0 -1
- package/dist/esm/MenuItem/components/Section/styled.js.map +1 -1
- package/dist/esm/MenuItem/components/Separator/index.js +0 -1
- package/dist/esm/MenuItem/components/Separator/index.js.map +1 -1
- package/dist/esm/MenuItem/components/Separator/styled.js +0 -1
- package/dist/esm/MenuItem/components/Separator/styled.js.map +1 -1
- package/dist/esm/MenuItem/components/SingleMenuItem/SingleMenuItem.js +0 -1
- package/dist/esm/MenuItem/components/SingleMenuItem/SingleMenuItem.js.map +1 -1
- package/dist/esm/MenuItem/components/SubmenuItem/index.js +0 -1
- package/dist/esm/MenuItem/components/SubmenuItem/index.js.map +1 -1
- package/dist/esm/MenuItem/components/SubmenuItem/styled.js +0 -1
- package/dist/esm/MenuItem/components/SubmenuItem/styled.js.map +1 -1
- package/dist/esm/MenuItem/components/index.js +0 -1
- package/dist/esm/MenuItem/components/index.js.map +1 -1
- package/dist/esm/MenuItem/components/styled.js +0 -1
- package/dist/esm/MenuItem/components/styled.js.map +1 -1
- package/dist/esm/MenuItem/index.js +0 -1
- package/dist/esm/MenuItem/index.js.map +1 -1
- package/dist/esm/MenuItem/props.js +0 -1
- package/dist/esm/MenuItem/props.js.map +1 -1
- package/dist/esm/Radio/Circle.js +0 -1
- package/dist/esm/Radio/Circle.js.map +1 -1
- package/dist/esm/Radio/DSRadio.js +0 -1
- package/dist/esm/Radio/DSRadio.js.map +1 -1
- package/dist/esm/Radio/index.js +0 -1
- package/dist/esm/Radio/index.js.map +1 -1
- package/dist/esm/RadioGroup/DSRadioGroup.js +0 -1
- package/dist/esm/RadioGroup/DSRadioGroup.js.map +1 -1
- package/dist/esm/RadioGroup/defaultProps.js +0 -1
- package/dist/esm/RadioGroup/defaultProps.js.map +1 -1
- package/dist/esm/RadioGroup/index.js +0 -1
- package/dist/esm/RadioGroup/index.js.map +1 -1
- package/dist/esm/RadioGroup/props.js +0 -1
- package/dist/esm/RadioGroup/props.js.map +1 -1
- package/dist/esm/RequiredMark/RequiredMark.js +0 -1
- package/dist/esm/RequiredMark/RequiredMark.js.map +1 -1
- package/dist/esm/RequiredMark/index.js +0 -1
- package/dist/esm/RequiredMark/index.js.map +1 -1
- package/dist/esm/SearchBox/index.js +0 -1
- package/dist/esm/SearchBox/index.js.map +1 -1
- package/dist/esm/TextBox/index.js +0 -1
- package/dist/esm/TextBox/index.js.map +1 -1
- package/dist/esm/TimeInput/DSTimeInput.js +0 -1
- package/dist/esm/TimeInput/DSTimeInput.js.map +1 -1
- package/dist/esm/TimeInput/TimeInputImpl.js +0 -1
- package/dist/esm/TimeInput/TimeInputImpl.js.map +1 -1
- package/dist/esm/TimeInput/TimeInputs.js +0 -1
- package/dist/esm/TimeInput/TimeInputs.js.map +1 -1
- package/dist/esm/TimeInput/index.js +0 -1
- package/dist/esm/TimeInput/index.js.map +1 -1
- package/dist/esm/TimeInput/utils.js +0 -1
- package/dist/esm/TimeInput/utils.js.map +1 -1
- package/dist/esm/Toggle/DSToggle.js +0 -1
- package/dist/esm/Toggle/DSToggle.js.map +1 -1
- package/dist/esm/Toggle/DSToggleImpl.js +0 -1
- package/dist/esm/Toggle/DSToggleImpl.js.map +1 -1
- package/dist/esm/Toggle/DSToggleRender.js +0 -1
- package/dist/esm/Toggle/DSToggleRender.js.map +1 -1
- package/dist/esm/Toggle/index.js +0 -1
- package/dist/esm/Toggle/index.js.map +1 -1
- package/dist/esm/Toggle/props.js +0 -1
- package/dist/esm/Toggle/props.js.map +1 -1
- package/dist/esm/Toggle/toggleHelper.js +0 -1
- package/dist/esm/Toggle/toggleHelper.js.map +1 -1
- package/dist/esm/index.js +0 -1
- package/dist/esm/index.js.map +1 -1
- package/package.json +12 -12
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/DateInputV2/components/propsTypes.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import PropTypes from 'prop-types';\n\nexport const DateInputsPropTypes = {\n innerRef: PropTypes.oneOfType([\n PropTypes.func,\n PropTypes.shape({ current: PropTypes.any }),\n ]),\n onBlur: PropTypes.func,\n onChange: PropTypes.func,\n onDateChange: PropTypes.func,\n onCustomKeyDown: PropTypes.func,\n onError: PropTypes.func,\n format: PropTypes.string,\n showMonth: PropTypes.bool,\n showDay: PropTypes.bool,\n showYear: PropTypes.bool,\n step: PropTypes.number,\n yearMaxRange: PropTypes.number,\n disabled: PropTypes.bool,\n yearMinRange: PropTypes.number,\n time: PropTypes.string,\n tabIndex: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),\n};\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AAEO,MAAM,sBAAsB;AAAA,EACjC,UAAU,UAAU,UAAU;AAAA,IAC5B,UAAU;AAAA,IACV,UAAU,MAAM,EAAE,SAAS,UAAU,IAAI,CAAC;AAAA,EAC5C,CAAC;AAAA,EACD,QAAQ,UAAU;AAAA,EAClB,UAAU,UAAU;AAAA,EACpB,cAAc,UAAU;AAAA,EACxB,iBAAiB,UAAU;AAAA,EAC3B,SAAS,UAAU;AAAA,EACnB,QAAQ,UAAU;AAAA,EAClB,WAAW,UAAU;AAAA,EACrB,SAAS,UAAU;AAAA,EACnB,UAAU,UAAU;AAAA,EACpB,MAAM,UAAU;AAAA,EAChB,cAAc,UAAU;AAAA,EACxB,UAAU,UAAU;AAAA,EACpB,cAAc,UAAU;AAAA,EACxB,MAAM,UAAU;AAAA,EAChB,UAAU,UAAU,UAAU,CAAC,UAAU,QAAQ,UAAU,MAAM,CAAC;AACpE;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/DateInputV2/components/styled.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { styled } from '@elliemae/ds-system';\nimport { Grid } from '@elliemae/ds-grid';\n\n\nexport const DateInputFluidContainer = styled(Grid)`\n width: 100%;\n height: 100%;\n align-items: center;\n`;\n\nexport const DateInputWrapper = styled(Grid)`\n align-items: center;\n align-content: center;\n ${({ disabled, theme }) =>\n disabled\n ? `\n background: ${theme.colors.neutral[100]};\n color: ${theme.colors.neutral[500]};\n `\n : ''}\n width: 102px;\n\n &:focus {\n outline-style: none;\n box-shadow: none;\n border-color: transparent;\n }\n`;\n\nexport const DateInputInput = styled.input`\n outline: none;\n border: none;\n border-radius: 0;\n width: ${(props) => (props.size === 'l' ? '38px' : '25px')};\n height: ${(props) => props.theme.space.xs};\n ${({ disabled, theme }) =>\n disabled\n ? `\n background: ${theme.colors.neutral[100]};\n color: ${theme.colors.neutral[500]};\n `\n : ''}\n padding-left: 4px;\n padding-right: 0px;\n &::placeholder {\n font-size: 95%;\n font-style: italic;\n }\n :-moz-placeholder {\n font-size: 95%;\n font-style: italic;\n }\n\n ::-moz-placeholder {\n font-size: 95%;\n font-style: italic;\n }\n &:focus {\n background: ${({ theme }) => theme.colors.brand['300']};\n background-clip: content-box;\n }\n ::-moz-selection {\n background: transparent;\n }\n ::selection {\n background: transparent;\n }\n`;\n\nexport const DateInputDivider = styled.div`\n padding: 1px;\n text-align: center;\n`;\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AACA;AAGO,MAAM,0BAA0B,OAAO,IAAI;AAAA;AAAA;AAAA;AAAA;AAM3C,MAAM,mBAAmB,OAAO,IAAI;AAAA;AAAA;AAAA,IAGvC,CAAC,EAAE,UAAU,YACb,WACI;AAAA,kBACU,MAAM,OAAO,QAAQ;AAAA,aAC1B,MAAM,OAAO,QAAQ;AAAA,QAE1B;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUD,MAAM,iBAAiB,OAAO;AAAA;AAAA;AAAA;AAAA,WAI1B,CAAC,UAAW,MAAM,SAAS,MAAM,SAAS;AAAA,YACzC,CAAC,UAAU,MAAM,MAAM,MAAM;AAAA,IACrC,CAAC,EAAE,UAAU,YACb,WACI;AAAA,gBACQ,MAAM,OAAO,QAAQ;AAAA,WAC1B,MAAM,OAAO,QAAQ;AAAA,MAExB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAiBU,CAAC,EAAE,YAAY,MAAM,OAAO,MAAM;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAW7C,MAAM,mBAAmB,OAAO;AAAA;AAAA;AAAA;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/DateInputV2/components/utils.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable max-params */\n/* eslint-disable complexity */\n/* eslint-disable max-lines */\nimport { addLeadingZeros } from '@elliemae/ds-utilities';\nimport { parseInt, isNaN } from '@elliemae/ds-utilities';\nimport moment from 'moment';\n\nconst currentYear = new Date().getFullYear();\n\nconst getNextSibling = (elem, selector) => {\n // Get the next sibling element\n let sibling = elem.nextElementSibling;\n // If there's no selector, return the first sibling\n if (!selector) return sibling;\n\n // If the sibling matches our selector, use it\n // If not, jump to the next sibling and continue the loop\n while (sibling) {\n if (sibling.matches(selector)) return sibling;\n sibling = sibling.nextElementSibling;\n }\n return sibling;\n};\n\nconst getPreviousSibling = (elem, selector) => {\n let sibling = elem.previousElementSibling;\n if (!selector) return sibling;\n while (sibling) {\n if (sibling.matches(selector)) return sibling;\n sibling = sibling.previousElementSibling;\n }\n return sibling;\n};\n\nexport const isArrowIncrementDecrement = (key) =>\n key === 'ArrowDown' || key === 'ArrowUp';\n\n// TODO remove and keep `true` behavior ( PUI-4141 )\nexport const setNativeValue = (element, value) => {\n if (!Object.getOwnPropertyDescriptor(element, 'value')) return;\n const valueSetter = Object.getOwnPropertyDescriptor(element, 'value').set;\n const prototype = Object.getPrototypeOf(element);\n const prototypeValueSetter = Object.getOwnPropertyDescriptor(\n prototype,\n 'value',\n ).set;\n\n if (valueSetter && valueSetter !== prototypeValueSetter) {\n prototypeValueSetter.call(element, value);\n } else {\n valueSetter.call(element, value);\n }\n element.dispatchEvent(new Event('input', { bubbles: true }));\n};\n\nconst formatTimeNumber = (value, shouldAddLeadingZeros, leadingZeros) => {\n if (value === null || value === undefined) return '';\n return shouldAddLeadingZeros\n ? addLeadingZeros(leadingZeros)(value)\n : String(value);\n};\n\nexport const getFormattedDay = (value) => {\n const v = value.length > 2 ? value.slice(-2) : value;\n const parsedValue = parseInt(v, 10);\n\n if (parsedValue > 31) return '31';\n return formatTimeNumber(parseTimeNumberFromText(v), true, 2);\n};\n\nexport const getShouldShortcircuitDay = (value) => {\n const v = value.length > 2 ? value.slice(-2) : value;\n const parsedValue = parseInt(v, 10);\n if (parsedValue > 31) return true;\n // if the first input is in range 4-9 then there is no other option\n // so we auto advance\n if (parsedValue > 3 && parsedValue < 10) return true;\n return false;\n};\n\nexport const getFormattedYear = (value) => {\n const v = value.length > 4 ? value.slice(-4) : value;\n if (parseInt(v) > 9999) return '9999';\n return formatTimeNumber(parseTimeNumberFromText(v), true, 4);\n};\n\nexport const getFormattedMonth = (value) => {\n const v = value.length > 2 ? value.slice(-2) : value;\n const parsedValue = parseInt(v, 10);\n if (parsedValue > 12) return '12';\n return formatTimeNumber(parseTimeNumberFromText(v), true, 2);\n};\n\nexport const getShouldShortcircuitMonth = (value) => {\n const v = value.length > 2 ? value.slice(-2) : value;\n const parsedValue = parseInt(v, 10);\n if (parsedValue > 12) return true;\n // if the first input is in range 2-9 then there is no other option\n // so we auto advance\n if (parsedValue > 1 && parsedValue < 10) return true;\n return false;\n};\n\nexport const parseTimeNumberFromText = (stringValue) => {\n const parsedInt = parseInt(stringValue);\n\n if (isNaN(parsedInt)) return null;\n\n return parsedInt;\n};\n\n// trigger onBlur for entire DateInput control if focus is not in day, month, year\nexport const triggerOnBlur = (blurEvent, onBlur = () => {}) => {\n const { target: currentEl = {}, relatedTarget } = blurEvent || {};\n const nextElement = currentEl.nextElementSibling;\n const { nextElementSibling } = nextElement || {};\n // relatedTarget points to the element that is currently having focus\n if (!nextElementSibling || nextElementSibling !== relatedTarget) {\n onBlur(blurEvent);\n }\n};\n\nexport const focusNextInput = (currentEl) => {\n getNextSibling(currentEl, 'input')?.focus();\n};\n\nexport const focusPreviousInput = (currentEl) => {\n getPreviousSibling(currentEl, 'input')?.focus();\n};\n\nexport const getValidTimeNumber = (\n { min, max },\n number,\n valueString = '',\n onError = () => null,\n) => {\n if (valueString === '0' || number === 0) return null;\n if (number === undefined || number === null) return null;\n if (number > max) {\n onError();\n return max;\n }\n if (number < min) {\n onError();\n return min;\n }\n return number;\n};\n\nexport const shouldFocusNextInput = (max, number = 0, stringValue) => {\n if (stringValue.length > 1) return true;\n return number * 10 > max;\n};\n\nexport const getDateValuesFromTime = (time, format) => {\n if (!time || !time.format) return {};\n const month = time.format('MM');\n const day = time.format('DD');\n const year = time.format('YYYY');\n return {\n month: getFormattedMonth(format, month),\n day: getFormattedDay(format, day),\n year: getFormattedYear(format, year),\n };\n};\n\nexport const resetTimeValues = () => ({\n month: '',\n day: '',\n year: '',\n});\n\nexport const onInputFocus = (e) => {\n e.preventDefault();\n e.stopPropagation();\n // we select the whole value to be able to override the value on first key\n // we don't use selection color to be consistent with the highlight of the input\n e.target.select();\n};\n\nexport const getNextTimeValue = (\n value,\n target,\n yearMinRange,\n yearMaxRange,\n step = 1,\n incrementing = true,\n) => {\n const parsedValue = parseTimeNumberFromText(value);\n let result = incrementing ? parsedValue + step : parsedValue - step;\n if (target === 'year') {\n if (result < yearMinRange) result = currentYear;\n if (result > yearMaxRange) result = currentYear;\n }\n return result;\n};\n\nexport const focusNextInputIfNeeded = (\n currentEl,\n max,\n number,\n stringValue,\n currentKey,\n) => {\n if (\n shouldFocusNextInput(max, number, stringValue) &&\n !isArrowIncrementDecrement(currentKey)\n ) {\n focusNextInput(currentEl);\n }\n};\n\nexport const commonInputProps = (digits = 2, onKeyDown, placeholder) => {\n const props = {\n pattern: '[0-9]*',\n placeholder,\n type: 'text',\n onKeyDown,\n onFocus: onInputFocus,\n };\n if (digits === 4) props.placeholder = 'YYYY';\n return props;\n};\n\nexport const handleCompletedDate = (\n time,\n date,\n show,\n INTERNAL_V2_NO_MUTATION,\n) => {\n // clone time to avoid mutation when INTERNAL_V2_NO_MUTATION is true\n const newDate = INTERNAL_V2_NO_MUTATION\n ? (time && moment(time)) || moment()\n : time || moment();\n\n const { year, month, day } = date;\n const { showYear, showMonth, showDay } = show;\n\n if (time && !year && !month && !day) return '';\n\n newDate.value = `${year}-${month}-${day}`;\n\n if (showMonth && month) newDate.month(parseInt(month - 1, 10));\n if (showDay && day) newDate.date(parseInt(day, 10));\n if (showYear && year) newDate.year(parseInt(year, 10));\n\n return newDate;\n};\n\nexport const isTimeCompletelySet = (date, show, range) => {\n let neededValues = [];\n const { year, month, day } = date;\n const { showYear, showMonth, showDay } = show;\n const { yearMinRange, yearMaxRange } = range;\n\n if (showMonth) neededValues = [...neededValues, month || null];\n if (showDay) neededValues = [...neededValues, day || null];\n if (showYear) neededValues = [...neededValues, year || null];\n\n const isValidYear = year < yearMaxRange && year > yearMinRange;\n\n return !neededValues.some((value) => !value) && isValidYear;\n};\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACGA;AACA;AACA;AAEA,MAAM,cAAc,IAAI,KAAK,EAAE,YAAY;AAE3C,MAAM,iBAAiB,CAAC,MAAM,aAAa;AAEzC,MAAI,UAAU,KAAK;AAEnB,MAAI,CAAC;AAAU,WAAO;AAItB,SAAO,SAAS;AACd,QAAI,QAAQ,QAAQ,QAAQ;AAAG,aAAO;AACtC,cAAU,QAAQ;AAAA,EACpB;AACA,SAAO;AACT;AAEA,MAAM,qBAAqB,CAAC,MAAM,aAAa;AAC7C,MAAI,UAAU,KAAK;AACnB,MAAI,CAAC;AAAU,WAAO;AACtB,SAAO,SAAS;AACd,QAAI,QAAQ,QAAQ,QAAQ;AAAG,aAAO;AACtC,cAAU,QAAQ;AAAA,EACpB;AACA,SAAO;AACT;AAEO,MAAM,4BAA4B,CAAC,QACxC,QAAQ,eAAe,QAAQ;AAG1B,MAAM,iBAAiB,CAAC,SAAS,UAAU;AAChD,MAAI,CAAC,OAAO,yBAAyB,SAAS,OAAO;AAAG;AACxD,QAAM,cAAc,OAAO,yBAAyB,SAAS,OAAO,EAAE;AACtE,QAAM,YAAY,OAAO,eAAe,OAAO;AAC/C,QAAM,uBAAuB,OAAO,yBAClC,WACA,OACF,EAAE;AAEF,MAAI,eAAe,gBAAgB,sBAAsB;AACvD,yBAAqB,KAAK,SAAS,KAAK;AAAA,EAC1C,OAAO;AACL,gBAAY,KAAK,SAAS,KAAK;AAAA,EACjC;AACA,UAAQ,cAA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,GAAG,QAAQ,SAAS;AAEpC,MAAI,aAAa;AAAO,YAAQ,MAAM,SAAS,QAAQ,GAAG,EAAE,CAAC;AAC7D,MAAI,WAAW;AAAK,YAAQ,KAAK,SAAS,KAAK,EAAE,CAAC;AAClD,MAAI,YAAY;AAAM,YAAQ,KAAK,SAAS,MAAM,EAAE,CAAC;AAErD,SAAO;AACT;AAEO,MAAM,sBAAsB,CAAC,MAAM,MAAM,UAAU;AACxD,MAAI,eAAe,CAAC;AACpB,QAAM,EAAE,MAAM,OAAO,QAAQ;AAC7B,QAAM,EAAE,UAAU,WAAW,YAAY;AACzC,QAAM,EAAE,cAAc,iBAAiB;AAEvC,MAAI;AAAW,mBAAe,CAAC,GAAG,cAAc,SAAS,IAAI;AAC7D,MAAI;AAAS,mBAAe,CAAC,GAAG,cAAc,OAAO,IAAI;AACzD,MAAI;AAAU,mBAAe,CAAC,GAAG,cAAc,QAAQ,IAAI;AAE3D,QAAM,cAAc,OAAO,gBAAgB,OAAO;AAElD,SAAO,CAAC,aAAa,KAAK,CAAC,UAAU,CAAC,KAAK,KAAK;AAClD;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/DateInputV2/index.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export { DateInputs as DateInputsV2Impl } from './components/DateInputs';\nexport * from './components/DSDateInput';\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AACA;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/ExpandableInput/DSExpandableInput.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { ExpandableInputImpl } from './ExpandableInputImpl';\n\nconst DSExpandableInput = ({\n containerProps = {},\n innerRef,\n className = '',\n style = {},\n triggerComponent = undefined,\n children,\n isOpen = false,\n onOpen = () => null,\n onClose = () => null,\n onBlur = () => null,\n width = undefined,\n}) => (\n <ExpandableInputImpl\n className={className}\n containerProps={containerProps}\n innerRef={innerRef}\n isOpen={isOpen}\n onBlur={onBlur}\n onClose={onClose}\n onOpen={onOpen}\n style={style}\n triggerComponent={triggerComponent}\n width={width}\n >\n {children}\n </ExpandableInputImpl>\n);\n\nexport { DSExpandableInput };\nexport default DSExpandableInput;\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AACA;AAEA,MAAM,oBAAoB,CAAC;AAAA,EACzB,iBAAiB,CAAC;AAAA,EAClB;AAAA,EACA,YAAY;AAAA,EACZ,QAAQ,CAAC;AAAA,EACT,mBAAmB;AAAA,EACnB;AAAA,EACA,SAAS;AAAA,EACT,SAAS,MAAM;AAAA,EACf,UAAU,MAAM;AAAA,EAChB,SAAS,MAAM;AAAA,EACf,QAAQ;AAAA,MAER,qCAAC;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,GAEC,QACH;AAIF,IAAO,4BAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/ExpandableInput/ExpandableInputImpl.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React, { Component, cloneElement } from 'react';\nimport { aggregatedClasses } from '@elliemae/ds-classnames';\nimport { isFunction } from '@elliemae/ds-shared';\nimport { InputAddonWrapper } from '../Input';\n\nconst blockName = 'expandable-input';\n\nconst ExpandableInput = aggregatedClasses('div')(blockName, null, ({ isOpen }) => ({ opened: isOpen }));\nconst InputWrapper = aggregatedClasses(InputAddonWrapper)(blockName, 'wrapper', ({ isOpen }) => ({ opened: isOpen }));\n\nclass ExpandableInputImpl extends Component {\n componentDidUpdate(prevProps) {\n const { isOpen } = this.props;\n if (isOpen && isOpen !== prevProps.isOpen) this.input.focus();\n }\n\n render() {\n const { innerRef, triggerComponent, children, width, isOpen, onOpen, onClose, onBlur, containerProps } = this.props;\n const InputComponent = React.Children.only(children);\n const handleTriggerClick = (e) => {\n if (isFunction(triggerComponent.onClick)) triggerComponent.onClick(e);\n if (isOpen) {\n onClose();\n } else {\n onOpen();\n }\n };\n\n return (\n <ExpandableInput\n {...containerProps}\n classProps={{ isOpen }}\n innerRef={innerRef}\n style={{ width: isOpen && width }}\n >\n <InputWrapper\n rightComponents={[\n cloneElement(triggerComponent, {\n key: 'handler',\n onClick: handleTriggerClick,\n }),\n ]}\n >\n {cloneElement(InputComponent, {\n className: 'expandable-input__input',\n innerRef: (node) => (this.input = node),\n onBlur,\n })}\n </InputWrapper>\n </ExpandableInput>\n );\n }\n}\n\nexport { ExpandableInputImpl };\nexport default ExpandableInputImpl;\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AACA;AACA;AACA;AAEA,MAAM,YAAY;AAElB,MAAM,kBAAkB,kBAAkB,KAAK,EAAE,WAAW,MAAM,CAAC,EAAE,aAAc,GAAE,QAAQ,OAAO,EAAE;AACtG,MAAM,eAAe,kBAAkB,iBAAiB,EAAE,WAAW,WAAW,CAAC,EAAE,aAAc,GAAE,QAAQ,OAAO,EAAE;AAEpH,MAAM,4BAA4B,UAAU;AAAA,EAC1C,mBAAmB,WAAW;AAC5B,UAAM,EAAE,WAAW,KAAK;AACxB,QAAI,UAAU,WAAW,UAAU;AAAQ,WAAK,MAAM,MAAM;AAAA,EAC9D;AAAA,EAEA,SAAS;AACP,UAAM,EAAE,UAAU,kBAAkB,UAAU,OAAO,QAAQ,QAAQ,SAAS,QAAQ,mBAAmB,KAAK;AAC9G,UAAM,iBAAiB,OAAM,SAAS,KAAK,QAAQ;AACnD,UAAM,qBAAqB,CAAC,MAAM;AAChC,UAAI,WAAW,iBAAiB,OAAO;AAAG,yBAAiB,QAAQ,CAAC;AACpE,UAAI,QAAQ;AACV,gBAAQ;AAAA,MACV,OAAO;AACL,eAAO;AAAA,MACT;AAAA,IACF;AAEA,WACE,qCAAC;AAAA,MACE,GAAG;AAAA,MACJ,YAAY,EAAE,OAAO;AAAA,MACrB;AAAA,MACA,OAAO,EAAE,OAAO,UAAU,MAAM;AAAA,OAEhC,qCAAC;AAAA,MACC,iBAAiB;AAAA,QACf,aAAa,kBAAkB;AAAA,UAC7B,KAAK;AAAA,UACL,SAAS;AAAA,QACX,CAAC;AAAA,MACH;AAAA,OAEC,aAAa,gBAAgB;AAAA,MAC5B,WAAW;AAAA,MACX,UAAU,CAAC,SAAU,KAAK,QAAQ;AAAA,MAClC;AAAA,IACF,CAAC,CACH,CACF;AAAA,EAEJ;AACF;AAGA,IAAO,8BAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/ExpandableInput/index.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export * from './DSExpandableInput';\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/FloatingLabelInput/DSFloatingLabelInput.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { FloatingLabelInputImpl } from './FloatingLabelInputImpl';\nimport { DSLabel } from '../FormItem/Label/DSLabel';\nimport { DSTextBox } from '../TextBox';\n\nconst noop = () => {};\nconst DSFloatingLabelInput = ({\n containerProps = {},\n arialLabel = '',\n /**\n * Gets the reference for the input controller\n *\n * @param {HTMLElement} node\n */\n innerRef = noop,\n /**\n * Custom className for floatingLabelInput\n */\n className = '',\n /**\n * Props injected to the input component\n *\n * @type Object\n */\n extraInputProps = {},\n /**\n * Input controller\n *\n * @type {element}\n */\n inputComponent = DSTextBox,\n /**\n * Input value\n *\n * @type {string}\n */\n value = '',\n /**\n * Label component\n *\n * @type {element}\n */\n labelComponent = DSLabel,\n /**\n * Label text\n *\n * @type {string | element}\n */\n labelText = null,\n /**\n * Callback when input controller has changed\n *\n * @param event\n */\n onChange = noop,\n onBlur = noop,\n onFocus = noop,\n /**\n * Whether the label is floating or not\n *\n * @type {boolean}\n */\n isOpen = false,\n /**\n * Whether ...\n *\n * @type {boolean}\n */\n hasError = false,\n /**\n * Whether ...\n *\n * @type {boolean}\n */\n readOnly = false,\n /**\n * Whether ...\n *\n * @type {boolean}\n */\n disabled = false,\n /**\n * Whether ...\n *\n * @type {boolean}\n */\n required = false,\n optional = false,\n mask = null,\n useSubfix = '',\n}) => (\n <FloatingLabelInputImpl\n arialLabel={arialLabel}\n className={className}\n disabled={disabled}\n extraInputProps={extraInputProps}\n hasError={hasError}\n innerRef={innerRef}\n inputComponent={inputComponent}\n isOpen={isOpen}\n labelComponent={labelComponent}\n labelText={labelText}\n mask={mask}\n onBlur={onBlur}\n onChange={onChange}\n onFocus={onFocus}\n optional={optional}\n readOnly={readOnly}\n required={required}\n useSubfix={useSubfix}\n value={value}\n />\n);\n\nexport { DSFloatingLabelInput };\nexport default DSFloatingLabelInput;\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AACA;AACA;AACA;AAEA,MAAM,OAAO,MAAM;AAAC;AACpB,MAAM,uBAAuB,CAAC;AAAA,EAC5B,iBAAiB,CAAC;AAAA,EAClB,aAAa;AAAA,EAMb,WAAW;AAAA,EAIX,YAAY;AAAA,EAMZ,kBAAkB,CAAC;AAAA,EAMnB,iBAAiB;AAAA,EAMjB,QAAQ;AAAA,EAMR,iBAAiB;AAAA,EAMjB,YAAY;AAAA,EAMZ,WAAW;AAAA,EACX,SAAS;AAAA,EACT,UAAU;AAAA,EAMV,SAAS;AAAA,EAMT,WAAW;AAAA,EAMX,WAAW;AAAA,EAMX,WAAW;AAAA,EAMX,WAAW;AAAA,EACX,WAAW;AAAA,EACX,OAAO;AAAA,EACP,YAAY;AAAA,MAEZ,qCAAC;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,CACF;AAIF,IAAO,+BAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/FloatingLabelInput/FloatingLabelInputImpl.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable react/no-unused-state */\nimport React, { Component } from 'react';\nimport { aggregatedClasses } from '@elliemae/ds-classnames';\nimport { getComponentFromProps } from '@elliemae/ds-utilities';\nimport { DSTextWrapper } from '@elliemae/ds-text-wrapper';\nimport { ResizeObserver } from 'resize-observer';\nimport { getSvgPath } from './getSvgPath';\nimport { RequiredMark } from '../RequiredMark/RequiredMark';\n\nconst blockName = 'labeled-outline';\n\nconst Wrapper = aggregatedClasses('div')(blockName, null, ({ isOpen }) => ({\n 'has-value': isOpen,\n}));\nconst FloatingLabel = aggregatedClasses('label')(blockName, 'label');\nconst OutlineIdle = aggregatedClasses('div')(blockName, 'idle');\nconst Outline = aggregatedClasses('div')(blockName, 'outline');\nconst OutlinePath = aggregatedClasses('path')(blockName, 'outline__path');\n\nconst shouldUpdateSvgPath = ({ width, height, labelWidth }, prevSizes) => {\n if (width !== prevSizes.width) return true;\n if (height !== prevSizes.height) return true;\n return labelWidth !== prevSizes.labelWidth;\n};\n\nclass FloatingLabelInputImpl extends Component {\n resizeObserver = new ResizeObserver(() => this.updatePath());\n\n prevSizes = {};\n\n static defaultProps = { onChange: () => null };\n\n constructor(props) {\n super(props);\n this.wrapperRef = React.createRef();\n this.outlinePathRef = React.createRef();\n this.outlineIdleRef = React.createRef();\n this.labelRef = React.createRef();\n\n this.sizes = this.sizes.bind(this);\n this.isOpened = this.isOpened.bind(this);\n this.getValue = this.getValue.bind(this);\n this.updatePath = this.updatePath.bind(this);\n }\n\n componentDidMount() {\n this.resizeObserver.observe(this.wrapperRef.current);\n }\n\n componentDidUpdate() {\n if (!shouldUpdateSvgPath(this.sizes, this.prevSizes)) return;\n this.updatePath();\n }\n\n componentWillUnmount() {\n this.resizeObserver.unobserve(this.wrapperRef.current);\n }\n\n get sizes() {\n const { current: labelEl } = this.labelRef;\n const { current: wrapperEl } = this.wrapperRef;\n const { current: outlineIdleEl } = this.outlineIdleRef;\n const elStyles = window.getComputedStyle(outlineIdleEl);\n const leftRadius = elStyles.getPropertyValue('border-top-left-radius');\n const rightRadius = elStyles.getPropertyValue('border-top-right-radius');\n const hasLeftRadius = parseFloat(leftRadius) !== 0;\n const hasRightRadius = parseFloat(rightRadius) !== 0;\n return {\n labelWidth: labelEl.offsetWidth * 0.9,\n width: wrapperEl.offsetWidth,\n height: wrapperEl.offsetHeight,\n radiusStyle: leftRadius,\n hasLeftRadius,\n hasRightRadius,\n };\n }\n\n get isOpened() {\n const { focused, isOpen, value } = this.props;\n return focused || (Array.isArray(value) ? !!value.length : !!value) || isOpen;\n }\n\n getValue(value) {\n const { valueAccessor } = this.props;\n if (valueAccessor) return valueAccessor(value);\n // is an event\n if (value && value.target) return value.target.value;\n\n return value;\n }\n\n updatePath() {\n const path = getSvgPath(this.sizes);\n this.prevSizes = this.sizes;\n this.outlinePathRef.current.setAttribute('d', path);\n }\n\n render() {\n const {\n ariaLabel,\n hasError,\n readOnly,\n disabled,\n inputComponent,\n labelText,\n onBlur,\n onFocus,\n innerRef,\n extraInputProps,\n required,\n value,\n onChange,\n mask,\n useSubfix,\n optional,\n } = this.props;\n\n const inputProps = {\n ariaLabel,\n className: 'floating-label-input-controller',\n disabled,\n hasError,\n onBlur,\n onChange,\n onFocus,\n readOnly,\n value,\n innerRef,\n mask,\n useSubfix,\n ...extraInputProps,\n };\n const InputComponent = getComponentFromProps(inputComponent, inputProps);\n const isOpen = this.isOpened;\n\n return (\n <Wrapper\n classProps={{\n hasError,\n isOpen,\n readOnly,\n disabled,\n }}\n innerRef={this.wrapperRef}\n onBlur={() => null}\n onFocus={() => null}\n onMouseOut={this.handleMouseOut}\n onMouseOver={this.handleMouseOver}\n >\n {InputComponent}\n <FloatingLabel classProps={{ isOpen }} innerRef={this.labelRef}>\n <DSTextWrapper maxWidth=\"100%\" text={labelText} />\n <RequiredMark optional={optional} required={required} />\n </FloatingLabel>\n <Outline>\n <svg>\n <OutlinePath innerRef={this.outlinePathRef} />\n </svg>\n </Outline>\n <OutlineIdle innerRef={this.outlineIdleRef} />\n </Wrapper>\n );\n }\n}\n\nexport { FloatingLabelInputImpl };\nexport default FloatingLabelInputImpl;\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACCA;AACA;AACA;AACA;AACA;AACA;AACA;AAEA,MAAM,YAAY;AAElB,MAAM,UAAU,kBAAkB,KAAK,EAAE,WAAW,MAAM,CAAC,EAAE,aAAc;AAAA,EACzE,aAAa;AACf,EAAE;AACF,MAAM,gBAAgB,kBAAkB,OAAO,EAAE,WAAW,OAAO;AACnE,MAAM,cAAc,kBAAkB,KAAK,EAAE,WAAW,MAAM;AAC9D,MAAM,UAAU,kBAAkB,KAAK,EAAE,WAAW,SAAS;AAC7D,MAAM,cAAc,kBAAkB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MAAM;AAAA,MACf,YAAY,KAAK;AAAA,MACjB,aAAa,KAAK;AAAA,OAEjB,gBACD,qCAAC;AAAA,MAAc,YAAY,EAAE,OAAO;AAAA,MAAG,UAAU,KAAK;AAAA,OACpD,qCAAC;AAAA,MAAc,UAAS;AAAA,MAAO,MAAM;AAAA,KAAW,GAChD,qCAAC;AAAA,MAAa;AAAA,MAAoB;AAAA,KAAoB,CACxD,GACA,qCAAC,eACC,qCAAC,aACC,qCAAC;AAAA,MAAY,UAAU,KAAK;AAAA,KAAgB,CAC9C,CACF,GACA,qCAAC;AAAA,MAAY,UAAU,KAAK;AAAA,KAAgB,CAC9C;AAAA,EAEJ;AACF;AArIE,AALI,uBAKG,eAAe,EAAE,UAAU,MAAM,KAAK;AAwI/C,IAAO,iCAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/FloatingLabelInput/getSvgPath.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable prefer-template,max-statements,no-nested-ternary */\nfunction getSvgPath({\n labelWidth = 50,\n width = 200,\n height = 35,\n radiusStyle,\n hasRightRadius = true,\n hasLeftRadius = true,\n}) {\n const notchWidth = labelWidth;\n const isRtl = false;\n\n const radius = parseFloat(radiusStyle);\n const cornerWidth = radius + 1.3;\n const leadingStrokeLength = 4;\n const paddedNotchWidth = notchWidth + 8;\n\n let extraSizeForH = 0;\n let extraSizeForLeftV = 0;\n let extraSizeForRightV = 0;\n let extraSizeForTopH = radius;\n\n if (!hasRightRadius) {\n extraSizeForH += radius;\n extraSizeForRightV = radius * 2;\n }\n if (!hasLeftRadius) {\n extraSizeForH += radius;\n extraSizeForLeftV = radius * 2;\n }\n\n if ((!hasLeftRadius && hasRightRadius) || (hasRightRadius && hasLeftRadius)) {\n extraSizeForTopH = 0;\n }\n\n const pathMiddle =\n '' +\n (hasRightRadius\n ? 'a' + radius + ',' + radius + ' 0 0 1 ' + radius + ',' + radius\n : '') +\n 'v' +\n (height - (2 * cornerWidth - (extraSizeForRightV + 1.5))) + // right vertical line\n (hasRightRadius\n ? 'a' + radius + ',' + radius + ' 0 0 1 ' + -radius + ',' + radius\n : '') +\n 'h' +\n (-width + 2 * cornerWidth - extraSizeForH) +\n (hasLeftRadius\n ? 'a' + radius + ',' + radius + ' 0 0 1 ' + -radius + ',' + -radius\n : '') +\n 'v' +\n (-height + (2 * cornerWidth - (extraSizeForLeftV + 1.5))) + // left vertical line\n (hasLeftRadius\n ? 'a' + radius + ',' + radius + ' 0 0 1 ' + radius + ',' + -radius\n : '');\n\n let path;\n if (!isRtl) {\n path =\n '' +\n 'M' +\n (cornerWidth + leadingStrokeLength + paddedNotchWidth) +\n ',' +\n 0.5 +\n 'h' +\n (width -\n 2 * cornerWidth -\n paddedNotchWidth -\n leadingStrokeLength +\n extraSizeForTopH) +\n pathMiddle +\n 'h' +\n leadingStrokeLength;\n } else {\n path =\n '' +\n 'M' +\n (width - cornerWidth - leadingStrokeLength) +\n ',' +\n 0.5 +\n 'h' +\n leadingStrokeLength +\n pathMiddle +\n 'h' +\n (width - 2 * cornerWidth - paddedNotchWidth - leadingStrokeLength);\n }\n return path;\n}\n\nexport { getSvgPath };\nexport default getSvgPath;\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACCA,oBAAoB;AAAA,EAClB,aAAa;AAAA,EACb,QAAQ;AAAA,EACR,SAAS;AAAA,EACT;AAAA,EACA,iBAAiB;AAAA,EACjB,gBAAgB;AAAA,GACf;AACD,QAAM,aAAa;AACnB,QAAM,QAAQ;AAEd,QAAM,SAAS,WAAW,WAAW;AACrC,QAAM,cAAc,SAAS;AAC7B,QAAM,sBAAsB;AAC5B,QAAM,mBAAmB,aAAa;AAEtC,MAAI,gBAAgB;AACpB,MAAI,oBAAoB;AACxB,MAAI,qBAAqB;AACzB,MAAI,mBAAmB;AAEvB,MAAI,CAAC,gBAAgB;AACnB,qBAAiB;AACjB,yBAAqB,SAAS;AAAA,EAChC;AACA,MAAI,CAAC,eAAe;AAClB,qBAAiB;AACjB,wBAAoB,SAAS;AAAA,EAC/B;AAEA,MAAK,CAAC,iBAAiB,kBAAoB,kBAAkB,eAAgB;AAC3E,uBAAmB;AAAA,EACrB;AAEA,QAAM,aACJ,AACC,kBACG,MAAM,SAAS,MAAM,SAAS,YAAY,SAAS,MAAM,SACzD,MACJ,MACC,UAAU,KAAI,cAAe,sBAAqB,SAClD,kBACG,MAAM,SAAS,MAAM,SAAS,YAAY,CAAC,SAAS,MAAM,SAC1D,MACJ,MACC,EAAC,QAAQ,IAAI,cAAc,iBAC3B,iBACG,MAAM,SAAS,MAAM,SAAS,YAAY,CAAC,SAAS,MAAM,CAAC,SAC3D,MACJ,MACC,EAAC,SAAU,KAAI,cAAe,qBAAoB,SAClD,iBACG,MAAM,SAAS,MAAM,SAAS,YAAY,SAAS,MAAM,CAAC,SAC1D;AAEN,MAAI;AACJ,MAAI,CAAC,OAAO;AACV,WACE,MAEC,eAAc,sBAAsB,oBACrC,MACA,MACA,MACC,SACC,IAAI,cACJ,mBACA,sBACA,oBACF,aACA,MACA;AAAA,EACJ,OAAO;AACL,WACE,MAEC,SAAQ,cAAc,uBACvB,MACA,MACA,MACA,sBACA,aACA,MACC,SAAQ,IAAI,cAAc,mBAAmB;AAAA,EAClD;AACA,SAAO;AACT;AAGA,IAAO,qBAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/FloatingLabelInput/index.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export * from './DSFloatingLabelInput';\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/FormItem/DSFormItemLayout.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable complexity */\n/* eslint-disable max-lines */\nimport React from 'react';\nimport { aggregatedClasses } from '@elliemae/ds-classnames';\nimport { describe, getComponentFromProps } from '@elliemae/ds-utilities';\nimport { Group } from '@elliemae/ds-shared';\nimport { DSInputGroup } from '../InputGroup';\nimport { DSFloatingLabelInput } from '../FloatingLabelInput';\nimport { DSError } from './Error/DSError';\nimport { props } from './props';\nimport { defaultProps } from './defaultProps';\nimport { FORMITEM_LAYOUT_VARIANTS } from './variants';\nimport { Suffix, SuffixInputWrapper, SuffixWrapper } from './Suffix/Suffix';\n// import { maskTypes } from '../InputMask/MaskTypes';\n\nexport { DSError, FORMITEM_LAYOUT_VARIANTS };\n\nconst blockName = 'form-item';\n\nconst Wrapper = aggregatedClasses('div')(blockName, null, ({ leftLabel, variant, fitContent, withHighlight }) => ({\n 'with-left-label': leftLabel,\n 'fit-content': fitContent,\n [variant]: variant,\n 'with-highlight': withHighlight,\n}));\n\nconst WrapperContent = aggregatedClasses('div')(`${blockName}-content`);\nconst WrapperContentGroup = aggregatedClasses('fieldset')(`${blockName}-content`);\n\nconst DSFormItemLayout = ({\n leftLabel,\n floatingLabel,\n name,\n id,\n value,\n inputComponent: InputComponent,\n labelComponent: LabelComponent,\n feedbackComponent: FeedbackComponent,\n labelText,\n truncateText,\n hasError,\n // orientation = 'vertical', // one of [ vertical, horizontal ]\n validationState, // one of [ success, error, warning ]\n validationMessage,\n feedbackMessage,\n readOnly,\n focused,\n type,\n autoFocus,\n disabled,\n onChange,\n onBlur,\n onFocus,\n onPaste,\n onKeyUp,\n extraInputProps,\n extraContent,\n leftAddon,\n rightAddon,\n required,\n optional,\n mask,\n useSubfix,\n suffix,\n variant,\n fitContent,\n withHighlight,\n containerProps,\n ...rest\n}) => {\n const isGroup = InputComponent.type === (<Group />).type;\n const floatingLabelOverride = floatingLabel === 'UNSAFE';\n const WrapperContentComp = !isGroup ? WrapperContent : WrapperContentGroup;\n\n // group the input props to not duplicate it inside the specific inputComponent (floating or not)\n const inputProps = {\n ...extraInputProps,\n disabled,\n hasError: hasError || validationState === 'error',\n id,\n name,\n type,\n autoFocus,\n onBlur,\n onChange,\n onFocus,\n onPaste,\n onKeyUp,\n readOnly,\n value,\n mask,\n useSubfix,\n variant,\n required,\n ...rest,\n };\n\n const renderInput = (Input) =>\n leftAddon || rightAddon ? (\n <DSInputGroup leftAddon={leftAddon} rightAddon={rightAddon} variant={variant}>\n {Input}\n </DSInputGroup>\n ) : (\n Input\n );\n\n const renderFloating = (\n <DSFloatingLabelInput\n {...inputProps}\n extraInputProps={extraInputProps}\n focused={focused}\n inputComponent={InputComponent}\n labelComponent={LabelComponent}\n labelText={labelText}\n optional={optional}\n required={required}\n variant={variant}\n />\n );\n\n const InputWithLabel = floatingLabelOverride ? (\n renderInput(renderFloating)\n ) : (\n <>\n <LabelComponent\n htmlFor={id || name}\n label={labelText}\n optional={optional}\n required={required}\n isGroup={isGroup}\n truncateText={truncateText}\n />\n {renderInput(getComponentFromProps(InputComponent, inputProps))}\n </>\n );\n\n if (suffix) {\n return (\n <Wrapper\n classProps={{\n disabled,\n readOnly,\n hasError,\n leftLabel,\n variant,\n fitContent,\n withHighlight,\n }}\n {...containerProps}\n >\n <SuffixWrapper className=\"suffix-wrapper\">\n <SuffixInputWrapper className=\"suffix-input-wrapper\">\n <WrapperContentComp>\n {InputWithLabel}\n {extraContent}\n </WrapperContentComp>\n <FeedbackComponent\n hasError={hasError}\n text={validationState || hasError ? validationMessage : feedbackMessage}\n />\n </SuffixInputWrapper>\n <Suffix\n className=\"suffix-label\"\n label={!!labelText}\n withFeedback={Boolean(validationMessage || feedbackMessage)}\n >\n {suffix}\n </Suffix>\n </SuffixWrapper>\n </Wrapper>\n );\n }\n\n return (\n <Wrapper\n classProps={{\n disabled,\n readOnly,\n hasError,\n leftLabel,\n variant,\n fitContent,\n withHighlight,\n }}\n {...containerProps}\n >\n <WrapperContentComp>\n {InputWithLabel}\n {extraContent}\n </WrapperContentComp>\n <FeedbackComponent hasError={hasError} text={validationState || hasError ? validationMessage : feedbackMessage} />\n </Wrapper>\n );\n};\n\nDSFormItemLayout.propTypes = props;\nDSFormItemLayout.defaultProps = defaultProps;\nDSFormItemLayout.displayName = 'DSFormItemLayout';\nconst DSFormItemLayoutWithSchema = describe(DSFormItemLayout);\nDSFormItemLayoutWithSchema.propTypes = props;\n\nexport default DSFormItemLayout;\nexport { DSFormItemLayoutWithSchema, DSFormItemLayout };\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAKA,MAAM,YAAY;AAElB,MAAM,UAAU,kBAAkB,KAAK,EAAE,WAAW,MAAM,CAAC,EAAE,WAAW,SAAS,YAAY,oBAAqB;AAAA,EAChH,mBAAmB;AAAA,EACnB,eAAe;AAAA,EACf,CAAC,UAAU;AAAA,EACX,kBAAkB;AACpB,EAAE;AAEF,MAAM,iBAAiB,kBAAkB,KAAK,EAAE,GAAG,mBAAmB;AACtE,MAAM,sBAAsB,kBAAkB,UAAU,EAAE,GAAG,mBAAmB;AAEhF,MAAM,mBAAmB,CAAC;AAAA,EACxB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,mBAAmB;AAAA,EACnB;AAAA,EACA;AAAA,EACA;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA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,OAC5B,qCAAC,0BACE,gBACA,YACH,GACA,qCAAC;AAAA,MACC;AAAA,MACA,MAAM,mBAAmB,WAAW,oBAAoB;AAAA,KAC1D,CACF,GACA,qCAAC;AAAA,MACC,WAAU;AAAA,MACV,OAAO,CAAC,CAAC;AAAA,MACT,cAAc,QAAQ,qBAAqB,eAAe;AAAA,OAEzD,MACH,CACF,CACF;AAAA,EAEJ;AAEA,SACE,qCAAC;AAAA,IACC,YAAY;AAAA,MACV;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IACF;AAAA,IACC,GAAG;AAAA,KAEJ,qCAAC,0BACE,gBACA,YACH,GACA,qCAAC;AAAA,IAAkB;AAAA,IAAoB,MAAM,mBAAmB,WAAW,oBAAoB;AAAA,GAAiB,CAClH;AAEJ;AAEA,iBAAiB,YAAY;AAC7B,iBAAiB,eAAe;AAChC,iBAAiB,cAAc;AAC/B,MAAM,6BAA6B,SAAS,gBAAgB;AAC5D,2BAA2B,YAAY;AAEvC,IAAO,2BAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/FormItem/Error/DSError.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { PropTypes, describe } from '@elliemae/ds-utilities';\n\nconst DSError = ({ hasError = false, errorText = 'Error' }) => {\n if (!hasError) return null;\n return <div className=\"em-ds-error\">{errorText}</div>;\n};\n\nconst props = {\n /** error state */\n hasError: PropTypes.bool.description('error state'),\n /** error label text */\n errorText: PropTypes.string.description('error label text'),\n};\n\nDSError.propTypes = props;\nDSError.displayName = 'DSError';\nconst DSErrorWithSchema = describe(DSError);\n\nDSErrorWithSchema.propTypes = props;\n\nexport default DSError;\nexport { DSErrorWithSchema, DSError };\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AACA;AAEA,MAAM,UAAU,CAAC,EAAE,WAAW,OAAO,YAAY,cAAc;AAC7D,MAAI,CAAC;AAAU,WAAO;AACtB,SAAO,qCAAC;AAAA,IAAI,WAAU;AAAA,KAAe,SAAU;AACjD;AAEA,MAAM,QAAQ;AAAA,EAEZ,UAAU,UAAU,KAAK,YAAY,aAAa;AAAA,EAElD,WAAW,UAAU,OAAO,YAAY,kBAAkB;AAC5D;AAEA,QAAQ,YAAY;AACpB,QAAQ,cAAc;AACtB,MAAM,oBAAoB,SAAS,OAAO;AAE1C,kBAAkB,YAAY;AAE9B,IAAO,kBAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/FormItem/Feedback.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { aggregatedClasses } from '@elliemae/ds-classnames';\n\nconst blockName = 'form-item';\n\nconst FeedbackSpan = aggregatedClasses('span')(blockName, 'feedback');\n\nconst Feedback = ({ text, hasError }) => {\n if (!text) return null;\n return <FeedbackSpan classProps={hasError}>{text}</FeedbackSpan>;\n};\n\nexport { Feedback };\nexport default Feedback;\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AACA;AAEA,MAAM,YAAY;AAElB,MAAM,eAAe,kBAAkB,MAAM,EAAE,WAAW,UAAU;AAEpE,MAAM,WAAW,CAAC,EAAE,MAAM,eAAe;AACvC,MAAI,CAAC;AAAM,WAAO;AAClB,SAAO,qCAAC;AAAA,IAAa,YAAY;AAAA,KAAW,IAAK;AACnD;AAGA,IAAO,mBAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/FormItem/Label/DSLabel.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable jsx-a11y/label-has-associated-control */\n/* eslint-disable react/no-unknown-property, jsx-a11y/label-has-for */\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport { aggregatedClasses } from '@elliemae/ds-classnames';\nimport { DSTruncatedTooltipText } from '@elliemae/ds-truncated-tooltip-text';\nimport { RequiredMark } from '../../RequiredMark';\n\nconst blockName = 'em-ds-label';\n\nconst Text = aggregatedClasses('span')(blockName, 'text');\n\nconst DSLabel = ({\n children,\n label,\n htmlFor,\n required,\n optional,\n truncateText = true,\n isGroup = false,\n}) => {\n const Tag = isGroup ? 'legend' : 'label';\n\n return (\n <Tag\n className={`${blockName}${isGroup ? ` ${blockName}--group` : ''}`}\n htmlFor={htmlFor}\n >\n {truncateText ? (\n <DSTruncatedTooltipText value={children || label} />\n ) : (\n <Text>{label}</Text>\n )}\n <RequiredMark optional={optional} required={required} />\n </Tag>\n );\n};\n\nDSLabel.propTypes = {\n children: PropTypes.string,\n label: PropTypes.string,\n htmlFor: PropTypes.string,\n required: PropTypes.bool,\n optional: PropTypes.bool,\n truncateText: PropTypes.bool,\n isGroup: PropTypes.bool,\n};\n\nexport { DSLabel };\nexport default DSLabel;\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACEA;AACA;AACA;AACA;AACA;AAEA,MAAM,YAAY;AAElB,MAAM,OAAO,kBAAkB,MAAM,EAAE,WAAW,MAAM;AAExD,MAAM,UAAU,CAAC;AAAA,EACf;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,eAAe;AAAA,EACf,UAAU;AAAA,MACN;AACJ,QAAM,MAAM,UAAU,WAAW;AAEjC,SACE,qCAAC;AAAA,IACC,WAAW,GAAG,YAAY,UAAU,IAAI,qBAAqB;AAAA,IAC7D;AAAA,KAEC,eACC,qCAAC;AAAA,IAAuB,OAAO,YAAY;AAAA,GAAO,IAElD,qCAAC,YAAM,KAAM,GAEf,qCAAC;AAAA,IAAa;AAAA,IAAoB;AAAA,GAAoB,CACxD;AAEJ;AAEA,QAAQ,YAAY;AAAA,EAClB,UAAU,UAAU;AAAA,EACpB,OAAO,UAAU;AAAA,EACjB,SAAS,UAAU;AAAA,EACnB,UAAU,UAAU;AAAA,EACpB,UAAU,UAAU;AAAA,EACpB,cAAc,UAAU;AAAA,EACxB,SAAS,UAAU;AACrB;AAGA,IAAO,kBAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../../scripts/build/transpile/react-shim.js", "../../../../src/FormItem/Suffix/Suffix.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "/* eslint-disable consistent-return */\nimport { styled } from '@elliemae/ds-system';\n\nexport const Suffix = styled.div`\n height: 2.16rem;\n align-items: center;\n display: flex;\n ${props => {\n if (props.label && !props.withFeedback) {\n return `\n padding-top: 1.2rem;\n `;\n }\n if (!props.label && !props.withFeedback) {\n return `\n padding-top: 1rem;\n `;\n }\n }}\n`;\n\nexport const SuffixInputWrapper = styled.div`\n padding-right: 0.32rem;\n flex: 1;\n`;\nexport const SuffixWrapper = styled.div`\n display: flex;\n align-items: center;\n`;\n\nexport default Suffix;\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACCA;AAEO,MAAM,SAAS,OAAO;AAAA;AAAA;AAAA;AAAA,IAIzB,WAAS;AACT,MAAI,MAAM,SAAS,CAAC,MAAM,cAAc;AACtC,WAAO;AAAA;AAAA;AAAA,EAGT;AACA,MAAI,CAAC,MAAM,SAAS,CAAC,MAAM,cAAc;AACvC,WAAO;AAAA;AAAA;AAAA,EAGT;AACF;AAAA;AAGK,MAAM,qBAAqB,OAAO;AAAA;AAAA;AAAA;AAIlC,MAAM,gBAAgB,OAAO;AAAA;AAAA;AAAA;AAKpC,IAAO,iBAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/FormItem/ValidationFieldWrapper.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { Component } from 'react';\n\nexport default class ValidationFieldWrapper extends Component {\n static defaultProps = {\n validateOnBlur: false,\n validateOnChange: false,\n name: '', // name in context of the form\n value: '',\n validate: () => null,\n onChange: () => null,\n onBlur: () => null,\n };\n\n constructor(props) {\n super(props);\n this.state = {\n value: props.value,\n };\n }\n\n componentDidMount() {\n const { value } = this.state;\n this.executeValidations(value);\n }\n\n static getDerivedStateFromProps(nextProps, prevState) {\n const { value } = nextProps;\n if (value === prevState.value) return null;\n return {\n ...prevState,\n value,\n };\n }\n\n handleChange = (e) => {\n const { onChange } = this.props;\n this.setState({ value: e.target.value });\n if (onChange) onChange(e);\n }\n\n handleBlur = (e) => {\n const { onBlur, validateOnBlur } = this.props;\n const { value } = this.state;\n if (validateOnBlur) this.executeValidations(value);\n onBlur(e);\n }\n\n executeValidations = (value) => {\n const { validations } = this.props;\n if (validations && Array.isArray(validations)) {\n if (\n !validations.some(validation => {\n const { error, payload } = validation({ value });\n if (error)\n this.setState({ validationMessage: payload, state: error });\n return error;\n })\n ) {\n this.setState({ hasError: false });\n }\n }\n }\n\n render() {\n const { children } = this.props;\n const { value, validationMessage, validationState, hasError } = this.state;\n return children({\n value,\n validationMessage,\n validationState,\n hasError,\n onChange: this.handleChange,\n onBlur: this.handleBlur,\n });\n }\n}\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AAEA,MAAO,+BAA6C,UAAU;AAAA,EAW5D,YAAY,OAAO;AACjB,UAAM,KAAK;AAoBb,wBAAe,CAAC,MAAM;AACpB,YAAM,E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BACZ,eAAe;AAAA,EACpB,gBAAgB;AAAA,EAChB,kBAAkB;AAAA,EAClB,MAAM;AAAA,EACN,OAAO;AAAA,EACP,UAAU,MAAM;AAAA,EAChB,UAAU,MAAM;AAAA,EAChB,QAAQ,MAAM;AAChB;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/FormItem/defaultProps.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { DSTextBox } from '../TextBox';\nimport { DSLabel } from './Label/DSLabel';\nimport { Feedback } from './Feedback';\nimport { FORMITEM_LAYOUT_VARIANTS } from './variants';\n\nexport const defaultProps = {\n leftLabel: false,\n floatingLabel: false,\n inputComponent: DSTextBox,\n labelComponent: DSLabel,\n feedbackComponent: Feedback,\n hasError: false,\n validationMessage: '',\n feedbackMessage: '',\n focused: false,\n autoFocus: false,\n disabled: false,\n onChange: () => {},\n onBlur: () => {},\n onFocus: () => {},\n onPaste: () => {},\n onKeyUp: () => {},\n extraInputProps: {},\n leftAddon: null,\n rightAddon: null,\n required: false,\n optional: false,\n useSubfix: '',\n suffix: '',\n variant: FORMITEM_LAYOUT_VARIANTS.DEFAULT,\n containerProps: {},\n fitContent: false,\n withHighlight: false,\n};\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AACA;AACA;AACA;AAEO,MAAM,eAAe;AAAA,EAC1B,WAAW;AAAA,EACX,eAAe;AAAA,EACf,gBAAgB;AAAA,EAChB,gBAAgB;AAAA,EAChB,mBAAmB;AAAA,EACnB,UAAU;AAAA,EACV,mBAAmB;AAAA,EACnB,iBAAiB;AAAA,EACjB,SAAS;AAAA,EACT,WAAW;AAAA,EACX,UAAU;AAAA,EACV,UAAU,MAAM;AAAA,EAAC;AAAA,EACjB,QAAQ,MAAM;AAAA,EAAC;AAAA,EACf,SAAS,MAAM;AAAA,EAAC;AAAA,EAChB,SAAS,MAAM;AAAA,EAAC;AAAA,EAChB,SAAS,MAAM;AAAA,EAAC;AAAA,EAChB,iBAAiB,CAAC;AAAA,EAClB,WAAW;AAAA,EACX,YAAY;AAAA,EACZ,UAAU;AAAA,EACV,UAAU;AAAA,EACV,WAAW;AAAA,EACX,QAAQ;AAAA,EACR,SAAS,yBAAyB;AAAA,EAClC,gBAAgB,CAAC;AAAA,EACjB,YAAY;AAAA,EACZ,eAAe;AACjB;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/FormItem/index.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export {\n default,\n DSFormItemLayout,\n FORMITEM_LAYOUT_VARIANTS,\n DSError,\n DSFormItemLayoutWithSchema,\n} from './DSFormItemLayout';\nexport { DSErrorWithSchema } from './Error/DSError';\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOA;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/FormItem/props.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import { PropTypes } from '@elliemae/ds-utilities';\nimport { FORMITEM_LAYOUT_VARIANTS } from './variants';\n\nexport const props = {\n /** props to inject to form item layout wrapper */\n containerProps: PropTypes.object.description('props to inject to form item layout wrapper'),\n /** disableTooltip */\n disableTooltip: PropTypes.bool\n .description('Whether to show a tooltip or not when text does not fit')\n .defaultValue(true),\n /** position label on the left */\n leftLabel: PropTypes.bool.description('position label on the left'),\n /** turn on floating label */\n floatingLabel: PropTypes.bool.description('turn on floating label'),\n /** id for form item layout */\n id: PropTypes.string.description('id for form item layout'),\n /** html name prop for form tags */\n name: PropTypes.string.description('html name prop for form tags'),\n /** form item layout element value */\n value: PropTypes.oneOfType([PropTypes.string, PropTypes.number, PropTypes.object]).description(\n 'form item layout element value',\n ),\n /** Any input component */\n inputComponent: PropTypes.oneOfType([PropTypes.func, PropTypes.element]).description('Any input component'),\n /** isShowElipsisActive */\n /** isShowElipsisActive */\n isShowElipsisActive: PropTypes.bool\n .description('Wheter to enable the ellipsis and tooltip functionality or not')\n .defaultValue(true),\n /** Label component */\n labelComponent: PropTypes.func.description('Label component'),\n /** feedback component to embed on form item */\n feedbackComponent: PropTypes.func.description('feedback component to embed on form item'),\n /** label text */\n labelText: PropTypes.oneOfType([PropTypes.string, PropTypes.element]).description('label text'),\n /** error state */\n hasError: PropTypes.bool.description('error state'),\n /** add fit content to form container */\n fitContent: PropTypes.bool.description(\n 'Adds fit content css property to the main container, making the layout width adapt to the input component',\n ),\n /** validation state */\n validationState: PropTypes.oneOf(['success', 'error', 'warning']).description('validation state'),\n /** validation message */\n validationMessage: PropTypes.string.description('validation message'),\n /** feedback message */\n feedbackMessage: PropTypes.string.description('feedback message'),\n /** read only form item */\n readOnly: PropTypes.bool.description('read only form item'),\n /** focused state */\n focused: PropTypes.bool.description('focused state'),\n /** input type */\n type: PropTypes.string.description('input type'),\n /** auto focus input */\n autoFocus: PropTypes.bool.description('auto focus input'),\n /** disabled state */\n disabled: PropTypes.bool.description('disabled state'),\n /** on change handler */\n onChange: PropTypes.func.description('on change handler'),\n /** on blur handler */\n onBlur: PropTypes.func.description('on blur handler'),\n /** extra input props to inject */\n extraInputProps: PropTypes.object.description('extra input props to inject'),\n /** extra content */\n extraContent: PropTypes.element.description('extra content'),\n /** left addon for form item */\n leftAddon: PropTypes.element.description('left addon for form item'),\n /** right addon for form item */\n rightAddon: PropTypes.element.description('right addon for form item'),\n /** add required mark */\n required: PropTypes.bool.description('add required mark'),\n /** add optional mark */\n optional: PropTypes.bool.description('add optional mark'),\n /** on focus handler */\n onFocus: PropTypes.func.description('on focus handler'),\n /** on paste handler */\n onPaste: PropTypes.func.description('on paste handler'),\n /** add truncation and ellipsis */\n truncateText: PropTypes.bool.description('add truncation and ellipsis'),\n /** on key up event handler */\n onKeyUp: PropTypes.func.description('on key up event handler'),\n /** mask for input mask component */\n mask: PropTypes.oneOfType([\n // PropTypes.oneOf(maskTypes),\n PropTypes.string,\n PropTypes.func,\n PropTypes.object,\n PropTypes.array,\n ]).description('mask for input mask component'),\n /** add suffix to input */\n useSubfix: PropTypes.string.description('add suffix to input'),\n /** suffix for input */\n suffix: PropTypes.string.description('suffix for input'),\n /** form item layout type */\n variant: PropTypes.oneOf([\n FORMITEM_LAYOUT_VARIANTS.DEFAULT,\n FORMITEM_LAYOUT_VARIANTS.FOCUS,\n FORMITEM_LAYOUT_VARIANTS.ACTIVE,\n FORMITEM_LAYOUT_VARIANTS.DISABLED,\n FORMITEM_LAYOUT_VARIANTS.READ_ONLY,\n FORMITEM_LAYOUT_VARIANTS.OPTIONAL,\n ]).description('form item layout type'),\n withHighlight: PropTypes.bool.description('adds highlight style to the input component'),\n};\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AACA;AAEO,MAAM,QAAQ;AAAA,EAEnB,gBAAgB,UAAU,OAAO,YAAY,6CAA6C;AAAA,EAE1F,gBAAgB,UAAU,KACvB,YAAY,yDAAyD,EACrE,aAAa,IAAI;AAAA,EAEpB,WAAW,UAAU,KAAK,YAAY,4BAA4B;AAAA,EAElE,eAAe,UAAU,KAAK,YAAY,wBAAwB;AAAA,EAElE,IAAI,UAAU,OAAO,YAAY,yBAAyB;AAAA,EAE1D,MAAM,UAAU,OAAO,YAAY,8BAA8B;AAAA,EAEjE,OAAO,UAAU,UAAU,CAAC,UAAU,QAAQ,UAAU,QAAQ,UAAU,MAAM,CAAC,EAAE,YACjF,gCACF;AAAA,EAEA,gBAAgB,UAAU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AAU,KAAK,YAAY,kBAAkB;AAAA,EAEtD,cAAc,UAAU,KAAK,YAAY,6BAA6B;AAAA,EAEtE,SAAS,UAAU,KAAK,YAAY,yBAAyB;AAAA,EAE7D,MAAM,UAAU,UAAU;AAAA,IAExB,UAAU;AAAA,IACV,UAAU;AAAA,IACV,UAAU;AAAA,IACV,UAAU;AAAA,EACZ,CAAC,EAAE,YAAY,+BAA+B;AAAA,EAE9C,WAAW,UAAU,OAAO,YAAY,qBAAqB;AAAA,EAE7D,QAAQ,UAAU,OAAO,YAAY,kBAAkB;AAAA,EAEvD,SAAS,UAAU,MAAM;AAAA,IACvB,yBAAyB;AAAA,IACzB,yBAAyB;AAAA,IACzB,yBAAyB;AAAA,IACzB,yBAAyB;AAAA,IACzB,yBAAyB;AAAA,IACzB,yBAAyB;AAAA,EAC3B,CAAC,EAAE,YAAY,uBAAuB;AAAA,EACtC,eAAe,UAAU,KAAK,YAAY,6CAA6C;AACzF;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/FormItem/variants.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export const FORMITEM_LAYOUT_VARIANTS = {\n DEFAULT: 'variant-default',\n FOCUS: 'variant-focus',\n ACTIVE: 'variant-active',\n DISABLED: 'variant-disabled',\n READ_ONLY: 'variant-read-only',\n OPTIONAL: 'variant-optional',\n};\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAO,MAAM,2BAA2B;AAAA,EACtC,SAAS;AAAA,EACT,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,UAAU;AAAA,EACV,WAAW;AAAA,EACX,UAAU;AACZ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/esm/Input/index.js
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/Input/index.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "export { DSInput, InputAddonWrapper, DSInput as default } from '@elliemae/ds-common/Input';"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/InputGroup/AddonWrapper.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React, { Component } from 'react';\nimport { aggregatedClasses } from '@elliemae/ds-classnames';\n\nconst blockName = 'input-addon-group';\n\nconst Container = aggregatedClasses('div')(blockName);\nconst InputAddon = aggregatedClasses('span')(blockName, 'addon');\n\nclass AddonWrapper extends Component {\n static defaultProps = {};\n\n state = {};\n\n render() {\n const {\n leftAddon,\n rightAddon,\n children: inputComponent,\n className,\n containerProps,\n } = this.props;\n const childType =\n inputComponent && inputComponent.type && inputComponent.type.name\n ? inputComponent.type.name.toLowerCase()\n : 'default';\n return (\n <Container\n className={`${className} ${blockName}--${childType}`}\n {...containerProps}\n >\n {leftAddon && <InputAddon>{leftAddon}</InputAddon>}\n {inputComponent}\n {rightAddon && <InputAddon>{rightAddon}</InputAddon>}\n </Container>\n );\n }\n}\n\nexport { AddonWrapper };\nexport default AddonWrapper;\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AACA;AAEA,MAAM,YAAY;AAElB,MAAM,YAAY,kBAAkB,KAAK,EAAE,SAAS;AACpD,MAAM,aAAa,kBAAkB,MAAM,EAAE,WAAW,OAAO;AAE/D,MAAM,qBAAqB,UAAU;AAAA,EAArC;AAAA;AAGE,iBAAQ,CAAC;AAAA;AAAA,EAET,SAAS;AACP,UAAM;AAAA,MACJ;AAAA,MACA;AAAA,MACA,UAAU;AAAA,MACV;AAAA,MACA;AAAA,QACE,KAAK;AACT,UAAM,YACJ,kBAAkB,eAAe,QAAQ,eAAe,KAAK,OACzD,eAAe,KAAK,KAAK,YAAY,IACrC;AACN,WACE,qCAAC;AAAA,MACC,WAAW,GAAG,aAAa,cAAc;AAAA,MACxC,GAAG;AAAA,OAEH,aAAa,qCAAC,kBAAY,SAAU,GACpC,gBACA,cAAc,qCAAC,kBAAY,UAAW,CACzC;AAAA,EAEJ;AACF;AA3BE,AADI,aACG,eAAe,CAAC;AA8BzB,IAAO,uBAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../../../scripts/build/transpile/react-shim.js", "../../../src/InputGroup/DSInputGroup.tsx"],
|
|
4
4
|
"sourcesContent": ["import * as React from 'react';\nexport { React };\n", "import React from 'react';\nimport { describe } from '@elliemae/ds-utilities';\nimport { AddonWrapper } from './AddonWrapper';\nimport { props } from './props';\nimport { defaultProps } from './defaultProps';\n\nconst DSInputGroup = ({\n containerProps,\n innerRef,\n className,\n style,\n leftAddon,\n rightAddon,\n children: InputComponents, // as InputComponents,\n}) => (\n <AddonWrapper\n ref={innerRef}\n className={className}\n containerProps={containerProps}\n leftAddon={leftAddon}\n rightAddon={rightAddon}\n style={style}\n >\n {InputComponents}\n </AddonWrapper>\n);\n\nDSInputGroup.propTypes = props;\nDSInputGroup.defaultProps = defaultProps;\nDSInputGroup.displayName = 'DSInputGroup';\nconst DSInputGroupWithSchema = describe(DSInputGroup);\n\nDSInputGroupWithSchema.propTypes = props;\n\nexport default DSInputGroup;\nexport { DSInputGroupWithSchema, DSInputGroup };\n"],
|
|
5
|
-
"mappings": "
|
|
5
|
+
"mappings": "AAAA;ACAA;AACA;AACA;AACA;AACA;AAEA,MAAM,eAAe,CAAC;AAAA,EACpB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,UAAU;AAAA,MAEV,qCAAC;AAAA,EACC,KAAK;AAAA,EACL;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,GAEC,eACH;AAGF,aAAa,YAAY;AACzB,aAAa,eAAe;AAC5B,aAAa,cAAc;AAC3B,MAAM,yBAAyB,SAAS,YAAY;AAEpD,uBAAuB,YAAY;AAEnC,IAAO,uBAAQ;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|