@elliemae/ds-modal 1.57.0-rc.1 → 1.57.0-rc.10
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/cjs/{DSModal-57b59236.js → DSModal-3126a986.js} +6 -7
- package/cjs/DSModal-3126a986.js.map +1 -0
- package/cjs/DSModal.js +5 -11
- package/cjs/DSModal.js.map +1 -1
- package/cjs/index.js +5 -11
- package/cjs/index.js.map +1 -1
- package/cjs/v1/DSModal.js +4 -8
- package/cjs/v1/DSModal.js.map +1 -1
- package/cjs/v1/ModalFeedBack/ModalFeedBack.js +6 -13
- package/cjs/v1/ModalFeedBack/ModalFeedBack.js.map +1 -1
- package/cjs/v2/DSModal.js +3 -8
- package/cjs/v2/DSModal.js.map +1 -1
- package/cjs/v2/components/DecisionHeader.js +3 -4
- package/cjs/v2/components/DecisionHeader.js.map +1 -1
- package/cjs/v2/components/FeedbackIcon.js +6 -15
- package/cjs/v2/components/FeedbackIcon.js.map +1 -1
- package/cjs/v2/components/Footer.js +1 -1
- package/cjs/v2/components/Footer.js.map +1 -1
- package/cjs/v2/components/FormHeader.js +3 -4
- package/cjs/v2/components/FormHeader.js.map +1 -1
- package/cjs/v2/components/ModalContent.js +3 -8
- package/cjs/v2/components/ModalContent.js.map +1 -1
- package/cjs/v2/components/SelectionHeader.js +2 -3
- package/cjs/v2/components/SelectionHeader.js.map +1 -1
- package/esm/{DSModal-a60fa661.js → DSModal-a8b0fbf0.js} +5 -5
- package/esm/DSModal-a8b0fbf0.js.map +1 -0
- package/esm/DSModal.js +5 -11
- package/esm/DSModal.js.map +1 -1
- package/esm/index.js +5 -11
- package/esm/index.js.map +1 -1
- package/esm/v1/DSModal.js +4 -8
- package/esm/v1/DSModal.js.map +1 -1
- package/esm/v1/ModalFeedBack/ModalFeedBack.js +1 -4
- package/esm/v1/ModalFeedBack/ModalFeedBack.js.map +1 -1
- package/esm/v2/DSModal.js +3 -8
- package/esm/v2/DSModal.js.map +1 -1
- package/esm/v2/components/DecisionHeader.js +3 -3
- package/esm/v2/components/DecisionHeader.js.map +1 -1
- package/esm/v2/components/FeedbackIcon.js +1 -5
- package/esm/v2/components/FeedbackIcon.js.map +1 -1
- package/esm/v2/components/Footer.js +1 -1
- package/esm/v2/components/Footer.js.map +1 -1
- package/esm/v2/components/FormHeader.js +3 -3
- package/esm/v2/components/FormHeader.js.map +1 -1
- package/esm/v2/components/ModalContent.js +3 -8
- package/esm/v2/components/ModalContent.js.map +1 -1
- package/esm/v2/components/SelectionHeader.js +1 -1
- package/esm/v2/components/SelectionHeader.js.map +1 -1
- package/package.json +6 -6
- package/cjs/DSModal-57b59236.js.map +0 -1
- package/esm/DSModal-a60fa661.js.map +0 -1
|
@@ -6,9 +6,9 @@ var React = require('react');
|
|
|
6
6
|
var PropTypes = require('prop-types');
|
|
7
7
|
var ReactModal = require('react-modal');
|
|
8
8
|
var dsClassnames = require('@elliemae/ds-classnames');
|
|
9
|
-
var
|
|
10
|
-
var
|
|
11
|
-
var DSButton = require('@elliemae/ds-
|
|
9
|
+
var dsIcon = require('@elliemae/ds-icon');
|
|
10
|
+
var dsIcons = require('@elliemae/ds-icons');
|
|
11
|
+
var DSButton = require('@elliemae/ds-button');
|
|
12
12
|
var constants = require('./constants.js');
|
|
13
13
|
var v1_ModalFeedBack_ModalFeedBack = require('./v1/ModalFeedBack/ModalFeedBack.js');
|
|
14
14
|
|
|
@@ -19,7 +19,6 @@ var _defineProperty__default = /*#__PURE__*/_interopDefaultLegacy(_definePropert
|
|
|
19
19
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
20
20
|
var PropTypes__default = /*#__PURE__*/_interopDefaultLegacy(PropTypes);
|
|
21
21
|
var ReactModal__default = /*#__PURE__*/_interopDefaultLegacy(ReactModal);
|
|
22
|
-
var CloseIcon__default = /*#__PURE__*/_interopDefaultLegacy(CloseIcon);
|
|
23
22
|
var DSButton__default = /*#__PURE__*/_interopDefaultLegacy(DSButton);
|
|
24
23
|
|
|
25
24
|
/* eslint-disable max-lines */
|
|
@@ -44,7 +43,7 @@ var DSModal = function DSModal(_ref) {
|
|
|
44
43
|
_ref$style = _ref.style,
|
|
45
44
|
style = _ref$style === void 0 ? {} : _ref$style,
|
|
46
45
|
_ref$iconCloseSize = _ref.iconCloseSize,
|
|
47
|
-
iconCloseSize = _ref$iconCloseSize === void 0 ?
|
|
46
|
+
iconCloseSize = _ref$iconCloseSize === void 0 ? dsIcon.DSIconSizes.S : _ref$iconCloseSize,
|
|
48
47
|
_ref$modalType = _ref.modalType,
|
|
49
48
|
modalType = _ref$modalType === void 0 ? constants.MODAL_TYPE.DEFAULT : _ref$modalType,
|
|
50
49
|
_ref$showHeader = _ref.showHeader,
|
|
@@ -150,7 +149,7 @@ var DSModal = function DSModal(_ref) {
|
|
|
150
149
|
className: classNameElement('icon', 'modal-header')
|
|
151
150
|
}, /*#__PURE__*/React__default['default'].createElement(DSButton__default['default'], {
|
|
152
151
|
buttonType: "link",
|
|
153
|
-
icon: /*#__PURE__*/React__default['default'].createElement(
|
|
152
|
+
icon: /*#__PURE__*/React__default['default'].createElement(dsIcons.Close, null),
|
|
154
153
|
onClick: onClose,
|
|
155
154
|
size: iconCloseSize
|
|
156
155
|
}))), /*#__PURE__*/React__default['default'].createElement("div", {
|
|
@@ -314,4 +313,4 @@ DSModal.propTypes = {
|
|
|
314
313
|
exports.DSModal = DSModal;
|
|
315
314
|
exports.iconSizes = iconSizes;
|
|
316
315
|
exports.sizes = sizes;
|
|
317
|
-
//# sourceMappingURL=DSModal-
|
|
316
|
+
//# sourceMappingURL=DSModal-3126a986.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DSModal-3126a986.js","sources":["../../../../shared-configs/prop-types.js","../../src/v1/DSModal.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nexport const dsBasicSizes = ['s', 'm', 'l'];\n\nexport const sizes = ['xsmall', 'small', 'medium', 'large', 'xlarge'];\n\nexport const iconSizes = ['xxs', 'xs', 's', 'm', 'l', 'xl', 'xxl'];\n\nexport const iconColors = [\n ['neutral', '900'],\n ['neutral', '0'],\n ['danger', '900'],\n ['warning', '500'],\n ['success', '900'],\n ['brand-primary', '600'],\n];\n\nexport const CHECKBOX_VARIANT = {\n DEFAULT: 'variant-default',\n FOCUS: 'variant-focus',\n ACTIVE: 'variant-active',\n DISABLED: 'variant-disabled',\n ERROR: 'variant-error',\n};\nexport const checkboxVariants = [\n CHECKBOX_VARIANT.DEFAULT,\n CHECKBOX_VARIANT.FOCUS,\n CHECKBOX_VARIANT.ACTIVE,\n CHECKBOX_VARIANT.DISABLED,\n CHECKBOX_VARIANT.ERROR,\n];\n\nexport const COMBOBOX_VARIANT = {\n DEFAULT: 'variant-default',\n FOCUS: 'variant-focus-input',\n FOCUS_ICON: 'variant-focus-icon',\n ACTIVE: 'variant-active-input',\n ACTIVE_ICON: 'variant-active-icon',\n DISABLED: 'variant-disabled',\n ERROR: 'variant-error',\n};\n\nexport const comboBoxVariants = [\n COMBOBOX_VARIANT.DEFAULT,\n COMBOBOX_VARIANT.FOCUS,\n COMBOBOX_VARIANT.FOCUS_ICON,\n COMBOBOX_VARIANT.ACTIVE,\n COMBOBOX_VARIANT.ACTIVE_ICON,\n COMBOBOX_VARIANT.DISABLED,\n COMBOBOX_VARIANT.ERROR,\n];\n\nexport const sizeVariants = {\n S: 's',\n M: 'm',\n L: 'l',\n};\n\nexport const position = {\n LEFT: 'left',\n RIGHT: 'right',\n CENTER: 'center',\n};\n\nexport const fontColor = {\n NEUTRAL500: 'neutral500',\n NEUTRAL700: 'neutral700',\n};\n\nexport const orientation = ['horizontal', 'vertical'];\n\nexport const orientationVariants = {\n HORIZONTAL: 'horizontal',\n VERTICAL: 'vertical',\n};\n","/* eslint-disable max-lines */\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport ReactModal from 'react-modal';\nimport { convertPropToCssClassName } from '@elliemae/ds-classnames';\nimport { DSIconSizes } from '@elliemae/ds-icon';\nimport { Close } from '@elliemae/ds-icons';\nimport DSButton from '@elliemae/ds-button';\nimport MODAL_TYPE, { modalTypes } from '../constants';\nimport ModalFeedBack from './ModalFeedBack/ModalFeedBack';\nimport { sizes, iconSizes } from '../../../../shared-configs/prop-types';\n\nconst DSModal = ({\n containerProps = {},\n className = '',\n dataTestId = 'ds-modal',\n additionalFooterCssClass = '',\n style = {},\n iconCloseSize = DSIconSizes.S,\n modalType = MODAL_TYPE.DEFAULT,\n showHeader = true,\n showFooter = true,\n children,\n centered = true,\n confirmLabel = 'Accept',\n modalTitle = '',\n size = 'medium',\n isOpen = false,\n onClose = () => null,\n onAfterOpen = () => null,\n onConfirm = () => null,\n onReject = () => null,\n rejectLabel = 'Cancel',\n shouldCloseOnOverlayClick = false,\n hasError = false,\n hasWarning = false,\n hasSuccess = false,\n hasInfo = false,\n hasHelp = false,\n actionsRef = () => null,\n appElement = '#root',\n overridePropsConfirmButton = {},\n overridePropsRejectButton = {},\n zIndex = 10,\n}) => {\n // http://reactcommunity.org/react-modal/accessibility/ https://github.com/reactjs/react-modal#examples\n typeof document !== 'undefined' && document && ReactModal.setAppElement && ReactModal.setAppElement(appElement); // eslint-disable-line\n const { cssClassName, classNameElement, classNameBlock, classNameModifier, classNameBlockModifier } =\n convertPropToCssClassName('modal', className, {\n hasError,\n hasWarning,\n hasSuccess,\n modalType,\n size,\n });\n\n const { WARNING, ERROR, SUCCESS, HELP, INFO } = MODAL_TYPE;\n\n const isAFeedbackType = [WARNING, ERROR, SUCCESS, HELP, INFO].indexOf(modalType) > -1;\n const showFeedBack = isAFeedbackType || hasError || hasWarning || hasSuccess || hasInfo || hasHelp;\n\n return (\n <ReactModal\n testId={dataTestId}\n className={cssClassName}\n contentLabel={modalTitle}\n isOpen={isOpen}\n onAfterOpen={onAfterOpen}\n onRequestClose={onClose}\n overlayClassName={`${classNameBlock('overlay')} ${classNameModifier(centered && 'center')}`}\n shouldCloseOnOverlayClick={shouldCloseOnOverlayClick}\n style={{\n content: {\n ...style,\n },\n overlay: {\n zIndex,\n },\n }}\n >\n <div {...containerProps}>\n {showHeader && (\n <div className={classNameBlock('modal-header')}>\n <div className={classNameElement('title', 'modal-header')}>{modalTitle}</div>\n <div className={classNameElement('icon', 'modal-header')}>\n <DSButton buttonType=\"link\" icon={<Close />} onClick={onClose} size={iconCloseSize} />\n </div>\n </div>\n )}\n <div className={classNameElement('body')}>\n {showFeedBack && (\n <ModalFeedBack\n hasError={hasError}\n hasHelp={hasHelp}\n hasInfo={hasInfo}\n hasSuccess={hasSuccess}\n hasWarning={hasWarning}\n modalType={modalType}\n />\n )}\n {children}\n </div>\n {showFooter && !isAFeedbackType && (\n <div\n className={`${classNameBlock('modal-footer')} ${\n additionalFooterCssClass ? classNameBlockModifier(additionalFooterCssClass, 'modal-footer') : ''\n }`}\n >\n <div ref={actionsRef} className={classNameBlock('modal-footer-actions')}>\n {modalType === MODAL_TYPE.CONFIRM && (\n <DSButton\n buttonType=\"secondary\"\n className={`${classNameElement('button-action')} ${classNameModifier('reject', 'button-action')} `}\n labelText={rejectLabel}\n onClick={onReject}\n {...overridePropsRejectButton}\n />\n )}\n <DSButton\n buttonType=\"primary\"\n className={`${classNameElement('button-action')} ${classNameModifier('confirm', 'button-action')} `}\n labelText={confirmLabel}\n onClick={onConfirm}\n {...overridePropsConfirmButton}\n />\n </div>\n </div>\n )}\n </div>\n </ReactModal>\n );\n};\n\nDSModal.propTypes = {\n className: PropTypes.string,\n /**\n * Add an additional css class to the footer\n */\n additionalFooterCssClass: PropTypes.string,\n /**\n * Set style for the modal\n */\n style: PropTypes.shape({}),\n /**\n * Select size for the close icon\n */\n iconCloseSize: PropTypes.oneOf(iconSizes),\n /**\n * ['default', 'alert', 'confirm', 'notification', 'warning', 'error', 'success', 'help', 'info']\n */\n modalType: PropTypes.oneOf(modalTypes),\n /**\n * Show the header or not\n */\n showHeader: PropTypes.bool,\n /**\n * Show the footer or not\n */\n showFooter: PropTypes.bool,\n /**\n * Main content of the modal\n */\n children: PropTypes.oneOfType([PropTypes.element, PropTypes.string, PropTypes.any]).isRequired,\n /**\n * Content is centered or not\n */\n centered: PropTypes.bool,\n /**\n * Text to be added in the confirm button\n */\n confirmLabel: PropTypes.string,\n /**\n * Text to be added in the modal title\n */\n modalTitle: PropTypes.string,\n /**\n * Text to be added in the modal title\n */\n size: PropTypes.oneOf(sizes),\n /**\n * Modal is open or not\n */\n isOpen: PropTypes.bool,\n /**\n * Allows a function to be triggered once the modal is closed\n */\n onClose: PropTypes.func,\n /**\n * Allows a function to be triggered once the modal is opened\n */\n onAfterOpen: PropTypes.func,\n /**\n * Allows a function to be triggered once the modal open is confirmed\n */\n onConfirm: PropTypes.func,\n /**\n * Allows a function to be triggered once the modal open is rejected\n */\n onReject: PropTypes.func,\n /**\n * Text to be added in the reject button\n */\n rejectLabel: PropTypes.string,\n /**\n * If modal should close on overlay click\n */\n shouldCloseOnOverlayClick: PropTypes.bool,\n /**\n * Modal has error or not\n */\n hasError: PropTypes.bool,\n /**\n * Modal has warning or not\n */\n hasWarning: PropTypes.bool,\n /**\n * Modal has success or not\n */\n hasSuccess: PropTypes.bool,\n /**\n * Modal has info or not\n */\n hasInfo: PropTypes.bool,\n /**\n * Modal has help or not\n */\n hasHelp: PropTypes.bool,\n actionsRef: PropTypes.func,\n appElement: PropTypes.string,\n /**\n * Customized props for the confirm button\n */\n overridePropsConfirmButton: PropTypes.shape({}),\n /**\n * Customized props for the reject button\n */\n overridePropsRejectButton: PropTypes.shape({}),\n};\n\nexport default DSModal;\n"],"names":["DSModal","containerProps","className","dataTestId","additionalFooterCssClass","style","iconCloseSize","DSIconSizes","S","modalType","MODAL_TYPE","DEFAULT","showHeader","showFooter","children","centered","confirmLabel","modalTitle","size","isOpen","onClose","onAfterOpen","onConfirm","onReject","rejectLabel","shouldCloseOnOverlayClick","hasError","hasWarning","hasSuccess","hasInfo","hasHelp","actionsRef","appElement","overridePropsConfirmButton","overridePropsRejectButton","zIndex","document","ReactModal","setAppElement","convertPropToCssClassName","cssClassName","classNameElement","classNameBlock","classNameModifier","classNameBlockModifier","WARNING","ERROR","SUCCESS","HELP","INFO","isAFeedbackType","indexOf","showFeedBack","React","content","overlay","DSButton","Close","ModalFeedBack","CONFIRM","propTypes","PropTypes","string","shape","oneOf","iconSizes","modalTypes","bool","oneOfType","element","any","isRequired","sizes","func"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAAA;AAEA;AACY,MAAC,KAAK,GAAG,CAAC,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE;AACtE;AACY,MAAC,SAAS,GAAG,CAAC,KAAK,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,KAAK;;;;;;ICO3DA,OAAO,GAAG,SAAVA,OAAU,OAgCV;AAAA,iCA/BJC,cA+BI;AAAA,MA/BJA,cA+BI,oCA/Ba,EA+Bb;AAAA,4BA9BJC,SA8BI;AAAA,MA9BJA,SA8BI,+BA9BQ,EA8BR;AAAA,6BA7BJC,UA6BI;AAAA,MA7BJA,UA6BI,gCA7BS,UA6BT;AAAA,mCA5BJC,wBA4BI;AAAA,MA5BJA,wBA4BI,sCA5BuB,EA4BvB;AAAA,wBA3BJC,KA2BI;AAAA,MA3BJA,KA2BI,2BA3BI,EA2BJ;AAAA,gCA1BJC,aA0BI;AAAA,MA1BJA,aA0BI,mCA1BYC,kBAAW,CAACC,CA0BxB;AAAA,4BAzBJC,SAyBI;AAAA,MAzBJA,SAyBI,+BAzBQC,oBAAU,CAACC,OAyBnB;AAAA,6BAxBJC,UAwBI;AAAA,MAxBJA,UAwBI,gCAxBS,IAwBT;AAAA,6BAvBJC,UAuBI;AAAA,MAvBJA,UAuBI,gCAvBS,IAuBT;AAAA,MAtBJC,QAsBI,QAtBJA,QAsBI;AAAA,2BArBJC,QAqBI;AAAA,MArBJA,QAqBI,8BArBO,IAqBP;AAAA,+BApBJC,YAoBI;AAAA,MApBJA,YA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C,EAAAA,OAAO,EAAE+B,6BAAS,CAACM,IA7FD;AA8FlBpC,EAAAA,UAAU,EAAE8B,6BAAS,CAACY,IA9FJ;AA+FlBzC,EAAAA,UAAU,EAAE6B,6BAAS,CAACC,MA/FJ;;AAgGlB;AACF;AACA;AACE7B,EAAAA,0BAA0B,EAAE4B,6BAAS,CAACE,KAAV,CAAgB,EAAhB,CAnGV;;AAoGlB;AACF;AACA;AACE7B,EAAAA,yBAAyB,EAAE2B,6BAAS,CAACE,KAAV,CAAgB,EAAhB;AAvGT,CAApB;;;;;;"}
|
package/cjs/DSModal.js
CHANGED
|
@@ -6,31 +6,25 @@ var _objectWithoutProperties = require('@babel/runtime/helpers/objectWithoutProp
|
|
|
6
6
|
var React = require('react');
|
|
7
7
|
var PropTypes = require('prop-types');
|
|
8
8
|
var constants = require('./constants.js');
|
|
9
|
-
var v1_DSModal = require('./DSModal-
|
|
9
|
+
var v1_DSModal = require('./DSModal-3126a986.js');
|
|
10
10
|
var v2_DSModal = require('./v2/DSModal.js');
|
|
11
11
|
var v2_components_ModalContent = require('./v2/components/ModalContent.js');
|
|
12
12
|
require('@babel/runtime/helpers/extends');
|
|
13
13
|
require('@babel/runtime/helpers/defineProperty');
|
|
14
14
|
require('react-modal');
|
|
15
15
|
require('@elliemae/ds-classnames');
|
|
16
|
-
require('@elliemae/ds-
|
|
17
|
-
require('@elliemae/ds-
|
|
18
|
-
require('@elliemae/ds-
|
|
16
|
+
require('@elliemae/ds-icon');
|
|
17
|
+
require('@elliemae/ds-icons');
|
|
18
|
+
require('@elliemae/ds-button');
|
|
19
19
|
require('./v1/ModalFeedBack/ModalFeedBack.js');
|
|
20
|
-
require('@elliemae/ds-icons/WarningCircle');
|
|
21
|
-
require('@elliemae/ds-icons/CheckmarkCircle');
|
|
22
|
-
require('@elliemae/ds-icons/HelpCircle');
|
|
23
|
-
require('@elliemae/ds-icons/InfoCircle');
|
|
24
20
|
require('react-desc');
|
|
25
21
|
require('./v2/components/SelectionHeader.js');
|
|
26
|
-
require('@elliemae/ds-
|
|
22
|
+
require('@elliemae/ds-form');
|
|
27
23
|
require('./v2/blocks.js');
|
|
28
24
|
require('./v2/components/Title.js');
|
|
29
25
|
require('./v2/components/DecisionHeader.js');
|
|
30
26
|
require('./v2/components/FormHeader.js');
|
|
31
27
|
require('./v2/components/FeedbackIcon.js');
|
|
32
|
-
require('@elliemae/ds-icons/ErrorHexegon');
|
|
33
|
-
require('@elliemae/ds-icons/WarningTriangle');
|
|
34
28
|
require('./v2/components/Footer.js');
|
|
35
29
|
require('./v2/helpers.js');
|
|
36
30
|
|
package/cjs/DSModal.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DSModal.js","sources":["../../src/DSModal.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport { modalTypes } from './constants';\nimport DSModalV1 from './v1/DSModal';\nimport DSModalV2, { DSModalContent } from './v2/DSModal';\nimport { sizes, iconSizes } from '../../../shared-configs/prop-types';\n\nconst DSModal = ({ version = 1, ...rest }) => {\n if (version === 2) return <DSModalV2 {...rest} />;\n return <DSModalV1 {...rest} />;\n};\n\nDSModal.propTypes = {\n version: PropTypes.oneOf([1, 2]),\n};\n\nDSModalV1.propTypes = {\n version: PropTypes.oneOf([1, 2]),\n className: PropTypes.string,\n /**\n * Add an additional css class to the footer\n */\n additionalFooterCssClass: PropTypes.string,\n /**\n * Set style for the modal\n */\n style: PropTypes.objectOf(PropTypes.string),\n /**\n * Select size for the close icon\n */\n iconCloseSize: PropTypes.oneOf(iconSizes),\n /**\n * ['default', 'alert', 'confirm', 'notification', 'warning', 'error', 'success', 'help', 'info']\n */\n modalType: PropTypes.oneOf(modalTypes),\n /**\n * Show the header or not\n */\n showHeader: PropTypes.bool,\n /**\n * Show the footer or not\n */\n showFooter: PropTypes.bool,\n /**\n * Main content of the modal\n */\n children: PropTypes.element.isRequired,\n /**\n * Content is centered or not\n */\n centered: PropTypes.bool,\n /**\n * Text to be added in the confirm button\n */\n confirmLabel: PropTypes.string,\n /**\n * Text to be added in the modal title\n */\n modalTitle: PropTypes.string,\n /**\n * Text to be added in the modal title\n */\n size: PropTypes.oneOf(sizes),\n /**\n * Modal is open or not\n */\n isOpen: PropTypes.bool,\n /**\n * Allows a function to be triggered once the modal is closed\n */\n onClose: PropTypes.func,\n /**\n * Allows a function to be triggered once the modal is opened\n */\n onAfterOpen: PropTypes.func,\n /**\n * Allows a function to be triggered once the modal open is confirmed\n */\n onConfirm: PropTypes.func,\n /**\n * Allows a function to be triggered once the modal open is rejected\n */\n onReject: PropTypes.func,\n /**\n * Text to be added in the reject button\n */\n rejectLabel: PropTypes.string,\n /**\n * If modal should close on overlay click\n */\n shouldCloseOnOverlayClick: PropTypes.bool,\n /**\n * Modal has error or not\n */\n hasError: PropTypes.bool,\n /**\n * Modal has warning or not\n */\n hasWarning: PropTypes.bool,\n /**\n * Modal has success or not\n */\n hasSuccess: PropTypes.bool,\n /**\n * Modal has info or not\n */\n hasInfo: PropTypes.bool,\n /**\n * Modal has help or not\n */\n hasHelp: PropTypes.bool,\n actionsRef: PropTypes.func,\n appElement: PropTypes.string,\n /**\n * Customized props for the confirm button\n */\n overridePropsConfirmButton: PropTypes.objectOf(PropTypes.shape({})),\n /**\n * Customized props for the reject button\n */\n overridePropsRejectButton: PropTypes.objectOf(PropTypes.string),\n /**\n * Show confirm button\n */\n showConfirmButton: PropTypes.bool,\n /**\n * Show confirm button\n */\n customCloseComponent: PropTypes.element,\n};\nexport { DSModalContent };\nexport default DSModal;\n"],"names":["DSModal","version","rest","React","DSModalV2","DSModalV1","propTypes","PropTypes","oneOf","className","string","additionalFooterCssClass","style","objectOf","iconCloseSize","iconSizes","modalType","modalTypes","showHeader","bool","showFooter","children","element","isRequired","centered","confirmLabel","modalTitle","size","sizes","isOpen","onClose","func","onAfterOpen","onConfirm","onReject","rejectLabel","shouldCloseOnOverlayClick","hasError","hasWarning","hasSuccess","hasInfo","hasHelp","actionsRef","appElement","overridePropsConfirmButton","shape","overridePropsRejectButton","showConfirmButton","customCloseComponent"],"mappings":"
|
|
1
|
+
{"version":3,"file":"DSModal.js","sources":["../../src/DSModal.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nimport React from 'react';\nimport PropTypes from 'prop-types';\nimport { modalTypes } from './constants';\nimport DSModalV1 from './v1/DSModal';\nimport DSModalV2, { DSModalContent } from './v2/DSModal';\nimport { sizes, iconSizes } from '../../../shared-configs/prop-types';\n\nconst DSModal = ({ version = 1, ...rest }) => {\n if (version === 2) return <DSModalV2 {...rest} />;\n return <DSModalV1 {...rest} />;\n};\n\nDSModal.propTypes = {\n version: PropTypes.oneOf([1, 2]),\n};\n\nDSModalV1.propTypes = {\n version: PropTypes.oneOf([1, 2]),\n className: PropTypes.string,\n /**\n * Add an additional css class to the footer\n */\n additionalFooterCssClass: PropTypes.string,\n /**\n * Set style for the modal\n */\n style: PropTypes.objectOf(PropTypes.string),\n /**\n * Select size for the close icon\n */\n iconCloseSize: PropTypes.oneOf(iconSizes),\n /**\n * ['default', 'alert', 'confirm', 'notification', 'warning', 'error', 'success', 'help', 'info']\n */\n modalType: PropTypes.oneOf(modalTypes),\n /**\n * Show the header or not\n */\n showHeader: PropTypes.bool,\n /**\n * Show the footer or not\n */\n showFooter: PropTypes.bool,\n /**\n * Main content of the modal\n */\n children: PropTypes.element.isRequired,\n /**\n * Content is centered or not\n */\n centered: PropTypes.bool,\n /**\n * Text to be added in the confirm button\n */\n confirmLabel: PropTypes.string,\n /**\n * Text to be added in the modal title\n */\n modalTitle: PropTypes.string,\n /**\n * Text to be added in the modal title\n */\n size: PropTypes.oneOf(sizes),\n /**\n * Modal is open or not\n */\n isOpen: PropTypes.bool,\n /**\n * Allows a function to be triggered once the modal is closed\n */\n onClose: PropTypes.func,\n /**\n * Allows a function to be triggered once the modal is opened\n */\n onAfterOpen: PropTypes.func,\n /**\n * Allows a function to be triggered once the modal open is confirmed\n */\n onConfirm: PropTypes.func,\n /**\n * Allows a function to be triggered once the modal open is rejected\n */\n onReject: PropTypes.func,\n /**\n * Text to be added in the reject button\n */\n rejectLabel: PropTypes.string,\n /**\n * If modal should close on overlay click\n */\n shouldCloseOnOverlayClick: PropTypes.bool,\n /**\n * Modal has error or not\n */\n hasError: PropTypes.bool,\n /**\n * Modal has warning or not\n */\n hasWarning: PropTypes.bool,\n /**\n * Modal has success or not\n */\n hasSuccess: PropTypes.bool,\n /**\n * Modal has info or not\n */\n hasInfo: PropTypes.bool,\n /**\n * Modal has help or not\n */\n hasHelp: PropTypes.bool,\n actionsRef: PropTypes.func,\n appElement: PropTypes.string,\n /**\n * Customized props for the confirm button\n */\n overridePropsConfirmButton: PropTypes.objectOf(PropTypes.shape({})),\n /**\n * Customized props for the reject button\n */\n overridePropsRejectButton: PropTypes.objectOf(PropTypes.string),\n /**\n * Show confirm button\n */\n showConfirmButton: PropTypes.bool,\n /**\n * Show confirm button\n */\n customCloseComponent: PropTypes.element,\n};\nexport { DSModalContent };\nexport default DSModal;\n"],"names":["DSModal","version","rest","React","DSModalV2","DSModalV1","propTypes","PropTypes","oneOf","className","string","additionalFooterCssClass","style","objectOf","iconCloseSize","iconSizes","modalType","modalTypes","showHeader","bool","showFooter","children","element","isRequired","centered","confirmLabel","modalTitle","size","sizes","isOpen","onClose","func","onAfterOpen","onConfirm","onReject","rejectLabel","shouldCloseOnOverlayClick","hasError","hasWarning","hasSuccess","hasInfo","hasHelp","actionsRef","appElement","overridePropsConfirmButton","shape","overridePropsRejectButton","showConfirmButton","customCloseComponent"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAQMA,OAAO,GAAG,SAAVA,OAAU,OAA8B;AAAA,0BAA3BC,OAA2B;AAAA,MAA3BA,OAA2B,6BAAjB,CAAiB;AAAA,MAAXC,IAAW;;AAC5C,MAAID,OAAO,KAAK,CAAhB,EAAmB,oBAAOE,wCAACC,qBAAD,EAAeF,IAAf,CAAP;AACnB,sBA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BAAoB,EAAEzC,6BAAS,CAACe;AAhHZ,CAAtB;;;;;"}
|
package/cjs/index.js
CHANGED
|
@@ -9,29 +9,23 @@ var v2_components_ModalContent = require('./v2/components/ModalContent.js');
|
|
|
9
9
|
require('@babel/runtime/helpers/objectWithoutProperties');
|
|
10
10
|
require('react');
|
|
11
11
|
require('prop-types');
|
|
12
|
-
require('./DSModal-
|
|
12
|
+
require('./DSModal-3126a986.js');
|
|
13
13
|
require('@babel/runtime/helpers/extends');
|
|
14
14
|
require('@babel/runtime/helpers/defineProperty');
|
|
15
15
|
require('react-modal');
|
|
16
16
|
require('@elliemae/ds-classnames');
|
|
17
|
-
require('@elliemae/ds-
|
|
18
|
-
require('@elliemae/ds-
|
|
19
|
-
require('@elliemae/ds-
|
|
17
|
+
require('@elliemae/ds-icon');
|
|
18
|
+
require('@elliemae/ds-icons');
|
|
19
|
+
require('@elliemae/ds-button');
|
|
20
20
|
require('./v1/ModalFeedBack/ModalFeedBack.js');
|
|
21
|
-
require('@elliemae/ds-icons/WarningCircle');
|
|
22
|
-
require('@elliemae/ds-icons/CheckmarkCircle');
|
|
23
|
-
require('@elliemae/ds-icons/HelpCircle');
|
|
24
|
-
require('@elliemae/ds-icons/InfoCircle');
|
|
25
21
|
require('react-desc');
|
|
26
22
|
require('./v2/components/SelectionHeader.js');
|
|
27
|
-
require('@elliemae/ds-
|
|
23
|
+
require('@elliemae/ds-form');
|
|
28
24
|
require('./v2/blocks.js');
|
|
29
25
|
require('./v2/components/Title.js');
|
|
30
26
|
require('./v2/components/DecisionHeader.js');
|
|
31
27
|
require('./v2/components/FormHeader.js');
|
|
32
28
|
require('./v2/components/FeedbackIcon.js');
|
|
33
|
-
require('@elliemae/ds-icons/ErrorHexegon');
|
|
34
|
-
require('@elliemae/ds-icons/WarningTriangle');
|
|
35
29
|
require('./v2/components/Footer.js');
|
|
36
30
|
require('./v2/helpers.js');
|
|
37
31
|
|
package/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/cjs/v1/DSModal.js
CHANGED
|
@@ -6,16 +6,12 @@ require('react');
|
|
|
6
6
|
require('prop-types');
|
|
7
7
|
require('react-modal');
|
|
8
8
|
require('@elliemae/ds-classnames');
|
|
9
|
-
require('@elliemae/ds-
|
|
10
|
-
require('@elliemae/ds-
|
|
11
|
-
require('@elliemae/ds-
|
|
9
|
+
require('@elliemae/ds-icon');
|
|
10
|
+
require('@elliemae/ds-icons');
|
|
11
|
+
require('@elliemae/ds-button');
|
|
12
12
|
require('../constants.js');
|
|
13
13
|
require('./ModalFeedBack/ModalFeedBack.js');
|
|
14
|
-
var v1_DSModal = require('../DSModal-
|
|
15
|
-
require('@elliemae/ds-icons/WarningCircle');
|
|
16
|
-
require('@elliemae/ds-icons/CheckmarkCircle');
|
|
17
|
-
require('@elliemae/ds-icons/HelpCircle');
|
|
18
|
-
require('@elliemae/ds-icons/InfoCircle');
|
|
14
|
+
var v1_DSModal = require('../DSModal-3126a986.js');
|
|
19
15
|
|
|
20
16
|
|
|
21
17
|
|
package/cjs/v1/DSModal.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DSModal.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"DSModal.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;"}
|
|
@@ -1,20 +1,13 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var React = require('react');
|
|
4
|
-
var
|
|
5
|
-
var CheckmarkCircle = require('@elliemae/ds-icons/CheckmarkCircle');
|
|
6
|
-
var HelpCircle = require('@elliemae/ds-icons/HelpCircle');
|
|
7
|
-
var InfoCircle = require('@elliemae/ds-icons/InfoCircle');
|
|
4
|
+
var dsIcons = require('@elliemae/ds-icons');
|
|
8
5
|
var dsClassnames = require('@elliemae/ds-classnames');
|
|
9
6
|
var constants = require('../../constants.js');
|
|
10
7
|
|
|
11
8
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
12
9
|
|
|
13
10
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
14
|
-
var WarningCircle__default = /*#__PURE__*/_interopDefaultLegacy(WarningCircle);
|
|
15
|
-
var CheckmarkCircle__default = /*#__PURE__*/_interopDefaultLegacy(CheckmarkCircle);
|
|
16
|
-
var HelpCircle__default = /*#__PURE__*/_interopDefaultLegacy(HelpCircle);
|
|
17
|
-
var InfoCircle__default = /*#__PURE__*/_interopDefaultLegacy(InfoCircle);
|
|
18
11
|
|
|
19
12
|
var feedbackIconSize = 'xxl';
|
|
20
13
|
var WARNING = constants.MODAL_TYPE.WARNING,
|
|
@@ -42,27 +35,27 @@ var getIconType = function getIconType(modalType) {
|
|
|
42
35
|
switch (modalType) {
|
|
43
36
|
case WARNING:
|
|
44
37
|
case ERROR:
|
|
45
|
-
return /*#__PURE__*/React__default['default'].createElement(
|
|
38
|
+
return /*#__PURE__*/React__default['default'].createElement(dsIcons.WarningCircle, {
|
|
46
39
|
size: feedbackIconSize
|
|
47
40
|
});
|
|
48
41
|
|
|
49
42
|
case SUCCESS:
|
|
50
|
-
return /*#__PURE__*/React__default['default'].createElement(
|
|
43
|
+
return /*#__PURE__*/React__default['default'].createElement(dsIcons.CheckmarkCircle, {
|
|
51
44
|
size: feedbackIconSize
|
|
52
45
|
});
|
|
53
46
|
|
|
54
47
|
case HELP:
|
|
55
|
-
return /*#__PURE__*/React__default['default'].createElement(
|
|
48
|
+
return /*#__PURE__*/React__default['default'].createElement(dsIcons.HelpCircle, {
|
|
56
49
|
size: feedbackIconSize
|
|
57
50
|
});
|
|
58
51
|
|
|
59
52
|
case INFO:
|
|
60
|
-
return /*#__PURE__*/React__default['default'].createElement(
|
|
53
|
+
return /*#__PURE__*/React__default['default'].createElement(dsIcons.InfoCircle, {
|
|
61
54
|
size: feedbackIconSize
|
|
62
55
|
});
|
|
63
56
|
|
|
64
57
|
default:
|
|
65
|
-
return /*#__PURE__*/React__default['default'].createElement(
|
|
58
|
+
return /*#__PURE__*/React__default['default'].createElement(dsIcons.InfoCircle, {
|
|
66
59
|
size: feedbackIconSize
|
|
67
60
|
});
|
|
68
61
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ModalFeedBack.js","sources":["../../../../src/v1/ModalFeedBack/ModalFeedBack.tsx"],"sourcesContent":["import React from 'react';\nimport
|
|
1
|
+
{"version":3,"file":"ModalFeedBack.js","sources":["../../../../src/v1/ModalFeedBack/ModalFeedBack.tsx"],"sourcesContent":["import React from 'react';\nimport { WarningCircle, CheckmarkCircle, HelpCircle, InfoCircle } from '@elliemae/ds-icons';\nimport { convertPropToCssClassName } from '@elliemae/ds-classnames';\nimport { MODAL_TYPE } from '../../constants';\n\nconst feedbackIconSize = 'xxl';\n\nconst { WARNING, ERROR, SUCCESS, HELP, INFO } = MODAL_TYPE;\n\nconst getModalType = (modalType, { hasError, hasWarning, hasSuccess, hasInfo, hasHelp }) => {\n if ([WARNING, ERROR, SUCCESS, HELP, INFO].indexOf(modalType) > -1) return modalType;\n if (hasError) return ERROR;\n if (hasWarning) return WARNING;\n if (hasSuccess) return SUCCESS;\n if (hasHelp) return HELP;\n if (hasInfo) return INFO;\n return INFO;\n};\n\nconst getIconType = (modalType) => {\n switch (modalType) {\n case WARNING:\n case ERROR:\n return <WarningCircle size={feedbackIconSize} />;\n case SUCCESS:\n return <CheckmarkCircle size={feedbackIconSize} />;\n case HELP:\n return <HelpCircle size={feedbackIconSize} />;\n case INFO:\n return <InfoCircle size={feedbackIconSize} />;\n default:\n return <InfoCircle size={feedbackIconSize} />;\n }\n};\n\nconst ModalFeedBack = ({\n className = '',\n modalType = null,\n hasError = false,\n hasWarning = false,\n hasSuccess = false,\n hasInfo = false,\n hasHelp = false,\n}) => {\n const type = getModalType(modalType, {\n hasError,\n hasWarning,\n hasSuccess,\n hasInfo,\n hasHelp,\n });\n const { cssClassName } = convertPropToCssClassName('modal-feedback', className, { modalType: type });\n const feedbackIcon = getIconType(type);\n\n return <div className={cssClassName}>{feedbackIcon}</div>;\n};\n\nexport default ModalFeedBack;\n"],"names":["feedbackIconSize","WARNING","MODAL_TYPE","ERROR","SUCCESS","HELP","INFO","getModalType","modalType","hasError","hasWarning","hasSuccess","hasInfo","hasHelp","indexOf","getIconType","React","WarningCircle","CheckmarkCircle","HelpCircle","InfoCircle","ModalFeedBack","className","type","convertPropToCssClassName","cssClassName","feedbackIcon"],"mappings":";;;;;;;;;;;AAKA,IAAMA,gBAAgB,GAAG,KAAzB;AAEA,IAAQC,OAAR,GAAgDC,oBAAhD,CAAQD,OAAR;AAAA,IAAiBE,KAAjB,GAAgDD,oBAAhD,CAAiBC,KAAjB;AAAA,IAAwBC,OAAxB,GAAgDF,oBAAhD,CAAwBE,OAAxB;AAAA,IAAiCC,IAAjC,GAAgDH,oBAAhD,CAAiCG,IAAjC;AAAA,IAAuCC,IAAvC,GAAgDJ,oBAAhD,CAAuCI,IAAvC;;AAEA,IAAMC,YAAY,GAAG,SAAfA,YAAe,CAACC,SAAD,QAAuE;AAAA,MAAzDC,QAAyD,QAAzDA,QAAyD;AAAA,MAA/CC,UAA+C,QAA/CA,UAA+C;AAAA,MAAnCC,UAAmC,QAAnCA,UAAmC;AAAA,MAAvBC,OAAuB,QAAvBA,OAAuB;AAAA,MAAdC,OAAc,QAAdA,OAAc;AAC1F,MAAI,CAACZ,OAAD,EAAUE,KAAV,EAAiBC,OAAjB,EAA0BC,IAA1B,EAAgCC,IAAhC,EAAsCQ,OAAtC,CAA8CN,SAA9C,IAA2D,CAAC,CAAhE,EAAmE,OAAOA,SAAP;AACnE,MAAIC,QAAJ,EAAc,OAAON,KAAP;AACd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AFmC;AAGnCC,IAAAA,UAAU,EAAVA,UAHmC;AAInCC,IAAAA,OAAO,EAAPA,OAJmC;AAKnCC,IAAAA,OAAO,EAAPA;AALmC,GAAZ,CAAzB;;AAOA,8BAAyBW,sCAAyB,CAAC,gBAAD,EAAmBF,SAAnB,EAA8B;AAAEd,IAAAA,SAAS,EAAEe;AAAb,GAA9B,CAAlD;AAAA,MAAQE,YAAR,yBAAQA,YAAR;;AACA,MAAMC,YAAY,GAAGX,WAAW,CAACQ,IAAD,CAAhC;AAEA,sBAAOP;AAAK,IAAA,SAAS,EAAES;AAAhB,KAA+BC,YAA/B,CAAP;AACD;;;;"}
|
package/cjs/v2/DSModal.js
CHANGED
|
@@ -10,19 +10,14 @@ var dsClassnames = require('@elliemae/ds-classnames');
|
|
|
10
10
|
var constants = require('../constants.js');
|
|
11
11
|
var v2_components_ModalContent = require('./components/ModalContent.js');
|
|
12
12
|
require('./components/SelectionHeader.js');
|
|
13
|
-
require('@elliemae/ds-
|
|
13
|
+
require('@elliemae/ds-form');
|
|
14
14
|
require('./blocks.js');
|
|
15
15
|
require('./components/Title.js');
|
|
16
16
|
require('./components/DecisionHeader.js');
|
|
17
|
-
require('@elliemae/ds-icons
|
|
18
|
-
require('@elliemae/ds-
|
|
17
|
+
require('@elliemae/ds-icons');
|
|
18
|
+
require('@elliemae/ds-button');
|
|
19
19
|
require('./components/FormHeader.js');
|
|
20
20
|
require('./components/FeedbackIcon.js');
|
|
21
|
-
require('@elliemae/ds-icons/ErrorHexegon');
|
|
22
|
-
require('@elliemae/ds-icons/WarningTriangle');
|
|
23
|
-
require('@elliemae/ds-icons/CheckmarkCircle');
|
|
24
|
-
require('@elliemae/ds-icons/HelpCircle');
|
|
25
|
-
require('@elliemae/ds-icons/InfoCircle');
|
|
26
21
|
require('./components/Footer.js');
|
|
27
22
|
require('@babel/runtime/helpers/extends');
|
|
28
23
|
require('./helpers.js');
|
package/cjs/v2/DSModal.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DSModal.js","sources":["../../../src/v2/DSModal.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nimport React from 'react';\nimport { PropTypes, describe } from 'react-desc';\nimport ReactModal from 'react-modal';\nimport { convertPropToCssClassName } from '@elliemae/ds-classnames';\nimport { MODAL_TYPE_V2 } from '../constants';\nimport { DSModalContent } from './components/ModalContent';\n\nconst DSModal = ({\n containerProps = {},\n className = '',\n style = {},\n size = 'default',\n //\n modalType = MODAL_TYPE_V2.INFORMATION,\n modalSubType = null,\n modalTitle = '',\n dataTestId = 'ds-modal',\n centered = false,\n showRejectButton = false,\n showClose = true,\n searchProps = {},\n // override\n actionsRef = () => null,\n additionalFooterCssClass,\n overridePropsConfirmButton = {},\n overridePropsRejectButton = {},\n // react modal\n children,\n isOpen = true,\n onClose = () => null,\n onAfterOpen = () => null,\n onConfirm = () => null,\n onReject = () => null,\n rejectLabel = 'Discard',\n confirmLabel = 'Save',\n shouldCloseOnOverlayClick = false,\n appElement = '#root',\n zIndex = 10,\n removePadding = false,\n}) => {\n if (\n typeof document !== 'undefined' &&\n process.env.NODE_ENV !== 'test' &&\n document &&\n ReactModal.setAppElement\n ) {\n ReactModal.setAppElement(appElement);\n }\n\n const {\n cssClassName,\n classNameBlock,\n classNameModifier,\n } = convertPropToCssClassName('modal-v2', className, { size });\n\n return (\n <ReactModal\n testId={dataTestId}\n className={`${cssClassName} ${classNameBlock(`type-${modalType}`)}`}\n contentLabel={modalTitle}\n isOpen={isOpen}\n onAfterOpen={onAfterOpen}\n onRequestClose={onClose}\n overlayClassName={`${classNameBlock('overlay')} ${classNameModifier(\n centered ? 'center' : 'top',\n )}`}\n shouldCloseOnOverlayClick={shouldCloseOnOverlayClick}\n style={{\n content: {\n ...style,\n },\n overlay: {\n // position: 'absolute', https://jira.elliemae.io/browse/PUI-1471, the overlay should be positioned based on the browser window rather positioned absolute to its parent\n zIndex,\n },\n }}\n >\n <DSModalContent\n actionsRef={actionsRef}\n additionalFooterCssClass={additionalFooterCssClass}\n confirmLabel={confirmLabel}\n containerProps={containerProps}\n modalSubType={modalSubType}\n modalTitle={modalTitle}\n modalType={modalType}\n onClose={onClose}\n onConfirm={onConfirm}\n onReject={onReject}\n overridePropsConfirmButton={overridePropsConfirmButton}\n overridePropsRejectButton={overridePropsRejectButton}\n rejectLabel={rejectLabel}\n searchProps={searchProps}\n showClose={showClose}\n showRejectButton={showRejectButton}\n removePadding={removePadding}\n >\n {children}\n </DSModalContent>\n </ReactModal>\n );\n};\n\nconst props = {\n /** inject props to container wrapper */\n containerProps: PropTypes.object.description(\n 'inject props to container wrapper',\n ),\n /** css class */\n className: PropTypes.string.description('css class'),\n /** style object for container wrapper */\n style: PropTypes.object.description('style object for container wrapper'),\n /** modal container title */\n modalTitle: PropTypes.string.description('modal container title'),\n /** center container */\n centered: PropTypes.bool.description('center container'),\n /** show reject button */\n showRejectButton: PropTypes.bool.description('show reject button'),\n /** show close button */\n showClose: PropTypes.bool.description('show close button'),\n /*\n Props for search component\n */\n searchProps: PropTypes.object.description('Props for search component'),\n /** css class for footer */\n additionalFooterCssClass: PropTypes.string.description(\n 'css class for footer',\n ),\n /** override props confirm button */\n overridePropsConfirmButton: PropTypes.object.description(\n 'override props confirm button',\n ),\n /** override props reject button */\n overridePropsRejectButton: PropTypes.object.description(\n 'override props reject button',\n ),\n /** controlled isOpen flag */\n isOpen: PropTypes.bool.description('controlled isOpen flag'),\n /** close callback */\n onClose: PropTypes.func.description('close callback'),\n /** after open callback */\n onAfterOpen: PropTypes.func.description('after open callback'),\n /** confirm callback */\n onConfirm: PropTypes.func.description('confirm callback'),\n /** reject callback */\n onReject: PropTypes.func.description('reject callback'),\n /** reject label */\n rejectLabel: PropTypes.string.description('reject label'),\n /** confirm text string */\n confirmLabel: PropTypes.string.description('confirm text string'),\n /** modal container size */\n size: PropTypes.oneOf([\n 'default',\n 'xx-large',\n 'x-large',\n 'large',\n 'medium',\n 'small',\n ]).description('modal container size'),\n /** modal sub type */\n modalSubType: PropTypes.any.description('modal sub type'),\n /** modal type */\n modalType: PropTypes.any.description('modal type'),\n /** ref for modal footer actions */\n actionsRef: PropTypes.any.description('ref for modal footer actions'),\n /** modal container children */\n children: PropTypes.oneOfType([\n PropTypes.element,\n PropTypes.arrayOf([PropTypes.element]),\n ]).description('modal container children'),\n /** close on click outside container */\n shouldCloseOnOverlayClick: PropTypes.bool.description(\n 'close on click outside container',\n ),\n /*\n App element ID to inject the modal\n */\n appElement: PropTypes.string.description(\n 'App element ID to inject the modal',\n ),\n /** zindex for modal container */\n zIndex: PropTypes.number.description('zindex for modal container'),\n /** remove modal builtin padding */\n removePadding: PropTypes.bool.description('remove modal builtin padding'),\n};\n\nDSModal.propTypes = props;\n\nconst DSModalWithSchema = describe(DSModal);\nDSModalWithSchema.propTypes = props;\n\nexport { DSModalContent, DSModalWithSchema };\nexport default DSModal;\n"],"names":["DSModal","containerProps","className","style","size","modalType","MODAL_TYPE_V2","INFORMATION","modalSubType","modalTitle","dataTestId","centered","showRejectButton","showClose","searchProps","actionsRef","additionalFooterCssClass","overridePropsConfirmButton","overridePropsRejectButton","children","isOpen","onClose","onAfterOpen","onConfirm","onReject","rejectLabel","confirmLabel","shouldCloseOnOverlayClick","appElement","zIndex","removePadding","document","process","env","NODE_ENV","ReactModal","setAppElement","convertPropToCssClassName","cssClassName","classNameBlock","classNameModifier","React","content","overlay","DSModalContent","props","PropTypes","object","description","string","bool","func","oneOf","any","oneOfType","element","arrayOf","number","propTypes","DSModalWithSchema","describe"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAQMA,OAAO,GAAG,SAAVA,OAAU,OAgCV;AAAA,iCA/BJC,cA+BI;AAAA,MA/BJA,cA+BI,oCA/Ba,EA+Bb;AAAA,4BA9BJC,SA8BI;AAAA,MA9BJA,SA8BI,+BA9BQ,EA8BR;AAAA,wBA7BJC,KA6BI;AAAA,MA7BJA,KA6BI,2BA7BI,EA6BJ;AAAA,uBA5B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G,CAOS,sBAPT,CAhDM;;AAwDZ;AACAxC,EAAAA,YAAY,EAAEsC,mBAAS,CAACO,GAAV,CAAcL,WAAd,CAA0B,gBAA1B,CAzDF;;AA0DZ;AACA3C,EAAAA,SAAS,EAAEyC,mBAAS,CAACO,GAAV,CAAcL,WAAd,CAA0B,YAA1B,CA3DC;;AA4DZ;AACAjC,EAAAA,UAAU,EAAE+B,mBAAS,CAACO,GAAV,CAAcL,WAAd,CAA0B,8BAA1B,CA7DA;;AA8DZ;AACA7B,EAAAA,QAAQ,EAAE2B,mBAAS,CAACQ,SAAV,CAAoB,CAC5BR,mBAAS,CAACS,OADkB,EAE5BT,mBAAS,CAACU,OAAV,CAAkB,CAACV,mBAAS,CAACS,OAAX,CAAlB,CAF4B,CAApB,EAGPP,WAHO,CAGK,0BAHL,CA/DE;;AAmEZ;AACArB,EAAAA,yBAAyB,EAAEmB,mBAAS,CAACI,IAAV,CAAeF,WAAf,CACzB,kCADyB,CApEf;;AAuEZ;AACF;AACA;AACEpB,EAAAA,UAAU,EAAEkB,mBAAS,CAACG,MAAV,CAAiBD,WAAjB,CACV,oCADU,CA1EA;;AA6EZ;AACAnB,EAAAA,MAAM,EAAEiB,mBAAS,CAACW,MAAV,CAAiBT,WAAjB,CAA6B,4BAA7B,CA9EI;;AA+EZ;AACAlB,EAAAA,aAAa,EAAEgB,mBAAS,CAACI,IAAV,CAAeF,WAAf,CAA2B,8BAA3B;AAhFH,CAAd;AAmFAhD,OAAO,CAAC0D,SAAR,GAAoBb,KAApB;IAEMc,iBAAiB,GAAGC,kBAAQ,CAAC5D,OAAD;AAClC2D,iBAAiB,CAACD,SAAlB,GAA8Bb,KAA9B;;;;;;"}
|
|
1
|
+
{"version":3,"file":"DSModal.js","sources":["../../../src/v2/DSModal.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nimport React from 'react';\nimport { PropTypes, describe } from 'react-desc';\nimport ReactModal from 'react-modal';\nimport { convertPropToCssClassName } from '@elliemae/ds-classnames';\nimport { MODAL_TYPE_V2 } from '../constants';\nimport { DSModalContent } from './components/ModalContent';\n\nconst DSModal = ({\n containerProps = {},\n className = '',\n style = {},\n size = 'default',\n //\n modalType = MODAL_TYPE_V2.INFORMATION,\n modalSubType = null,\n modalTitle = '',\n dataTestId = 'ds-modal',\n centered = false,\n showRejectButton = false,\n showClose = true,\n searchProps = {},\n // override\n actionsRef = () => null,\n additionalFooterCssClass,\n overridePropsConfirmButton = {},\n overridePropsRejectButton = {},\n // react modal\n children,\n isOpen = true,\n onClose = () => null,\n onAfterOpen = () => null,\n onConfirm = () => null,\n onReject = () => null,\n rejectLabel = 'Discard',\n confirmLabel = 'Save',\n shouldCloseOnOverlayClick = false,\n appElement = '#root',\n zIndex = 10,\n removePadding = false,\n}) => {\n if (\n typeof document !== 'undefined' &&\n process.env.NODE_ENV !== 'test' &&\n document &&\n ReactModal.setAppElement\n ) {\n ReactModal.setAppElement(appElement);\n }\n\n const {\n cssClassName,\n classNameBlock,\n classNameModifier,\n } = convertPropToCssClassName('modal-v2', className, { size });\n\n return (\n <ReactModal\n testId={dataTestId}\n className={`${cssClassName} ${classNameBlock(`type-${modalType}`)}`}\n contentLabel={modalTitle}\n isOpen={isOpen}\n onAfterOpen={onAfterOpen}\n onRequestClose={onClose}\n overlayClassName={`${classNameBlock('overlay')} ${classNameModifier(\n centered ? 'center' : 'top',\n )}`}\n shouldCloseOnOverlayClick={shouldCloseOnOverlayClick}\n style={{\n content: {\n ...style,\n },\n overlay: {\n // position: 'absolute', https://jira.elliemae.io/browse/PUI-1471, the overlay should be positioned based on the browser window rather positioned absolute to its parent\n zIndex,\n },\n }}\n >\n <DSModalContent\n actionsRef={actionsRef}\n additionalFooterCssClass={additionalFooterCssClass}\n confirmLabel={confirmLabel}\n containerProps={containerProps}\n modalSubType={modalSubType}\n modalTitle={modalTitle}\n modalType={modalType}\n onClose={onClose}\n onConfirm={onConfirm}\n onReject={onReject}\n overridePropsConfirmButton={overridePropsConfirmButton}\n overridePropsRejectButton={overridePropsRejectButton}\n rejectLabel={rejectLabel}\n searchProps={searchProps}\n showClose={showClose}\n showRejectButton={showRejectButton}\n removePadding={removePadding}\n >\n {children}\n </DSModalContent>\n </ReactModal>\n );\n};\n\nconst props = {\n /** inject props to container wrapper */\n containerProps: PropTypes.object.description(\n 'inject props to container wrapper',\n ),\n /** css class */\n className: PropTypes.string.description('css class'),\n /** style object for container wrapper */\n style: PropTypes.object.description('style object for container wrapper'),\n /** modal container title */\n modalTitle: PropTypes.string.description('modal container title'),\n /** center container */\n centered: PropTypes.bool.description('center container'),\n /** show reject button */\n showRejectButton: PropTypes.bool.description('show reject button'),\n /** show close button */\n showClose: PropTypes.bool.description('show close button'),\n /*\n Props for search component\n */\n searchProps: PropTypes.object.description('Props for search component'),\n /** css class for footer */\n additionalFooterCssClass: PropTypes.string.description(\n 'css class for footer',\n ),\n /** override props confirm button */\n overridePropsConfirmButton: PropTypes.object.description(\n 'override props confirm button',\n ),\n /** override props reject button */\n overridePropsRejectButton: PropTypes.object.description(\n 'override props reject button',\n ),\n /** controlled isOpen flag */\n isOpen: PropTypes.bool.description('controlled isOpen flag'),\n /** close callback */\n onClose: PropTypes.func.description('close callback'),\n /** after open callback */\n onAfterOpen: PropTypes.func.description('after open callback'),\n /** confirm callback */\n onConfirm: PropTypes.func.description('confirm callback'),\n /** reject callback */\n onReject: PropTypes.func.description('reject callback'),\n /** reject label */\n rejectLabel: PropTypes.string.description('reject label'),\n /** confirm text string */\n confirmLabel: PropTypes.string.description('confirm text string'),\n /** modal container size */\n size: PropTypes.oneOf([\n 'default',\n 'xx-large',\n 'x-large',\n 'large',\n 'medium',\n 'small',\n ]).description('modal container size'),\n /** modal sub type */\n modalSubType: PropTypes.any.description('modal sub type'),\n /** modal type */\n modalType: PropTypes.any.description('modal type'),\n /** ref for modal footer actions */\n actionsRef: PropTypes.any.description('ref for modal footer actions'),\n /** modal container children */\n children: PropTypes.oneOfType([\n PropTypes.element,\n PropTypes.arrayOf([PropTypes.element]),\n ]).description('modal container children'),\n /** close on click outside container */\n shouldCloseOnOverlayClick: PropTypes.bool.description(\n 'close on click outside container',\n ),\n /*\n App element ID to inject the modal\n */\n appElement: PropTypes.string.description(\n 'App element ID to inject the modal',\n ),\n /** zindex for modal container */\n zIndex: PropTypes.number.description('zindex for modal container'),\n /** remove modal builtin padding */\n removePadding: PropTypes.bool.description('remove modal builtin padding'),\n};\n\nDSModal.propTypes = props;\n\nconst DSModalWithSchema = describe(DSModal);\nDSModalWithSchema.propTypes = props;\n\nexport { DSModalContent, DSModalWithSchema };\nexport default DSModal;\n"],"names":["DSModal","containerProps","className","style","size","modalType","MODAL_TYPE_V2","INFORMATION","modalSubType","modalTitle","dataTestId","centered","showRejectButton","showClose","searchProps","actionsRef","additionalFooterCssClass","overridePropsConfirmButton","overridePropsRejectButton","children","isOpen","onClose","onAfterOpen","onConfirm","onReject","rejectLabel","confirmLabel","shouldCloseOnOverlayClick","appElement","zIndex","removePadding","document","process","env","NODE_ENV","ReactModal","setAppElement","convertPropToCssClassName","cssClassName","classNameBlock","classNameModifier","React","content","overlay","DSModalContent","props","PropTypes","object","description","string","bool","func","oneOf","any","oneOfType","element","arrayOf","number","propTypes","DSModalWithSchema","describe"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAQMA,OAAO,GAAG,SAAVA,OAAU,OAgCV;AAAA,iCA/BJC,cA+BI;AAAA,MA/BJA,cA+BI,oCA/Ba,EA+Bb;AAAA,4BA9BJC,SA8BI;AAAA,MA9BJA,SA8BI,+BA9BQ,EA8BR;AAAA,wBA7BJC,KA6BI;AAAA,MA7BJA,KA6BI,2BA7BI,EA6BJ;AAAA,uBA5BJC,IA4BI;AAAA,MA5BJA,IA4BI,0BA5BG,SA4BH;AAAA,4BA1BJC,SA0BI;AAAA,MA1BJA,SA0BI,+BA1BQC,uBAAa,CAACC,WA0BtB;AAAA,+BAzBJC,YAyBI;AAAA,MAzBJA,YAyBI,kCAzBW,IAyBX;AAAA,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A0B,YAA1B,CA3DC;;AA4DZ;AACAjC,EAAAA,UAAU,EAAE+B,mBAAS,CAACO,GAAV,CAAcL,WAAd,CAA0B,8BAA1B,CA7DA;;AA8DZ;AACA7B,EAAAA,QAAQ,EAAE2B,mBAAS,CAACQ,SAAV,CAAoB,CAC5BR,mBAAS,CAACS,OADkB,EAE5BT,mBAAS,CAACU,OAAV,CAAkB,CAACV,mBAAS,CAACS,OAAX,CAAlB,CAF4B,CAApB,EAGPP,WAHO,CAGK,0BAHL,CA/DE;;AAmEZ;AACArB,EAAAA,yBAAyB,EAAEmB,mBAAS,CAACI,IAAV,CAAeF,WAAf,CACzB,kCADyB,CApEf;;AAuEZ;AACF;AACA;AACEpB,EAAAA,UAAU,EAAEkB,mBAAS,CAACG,MAAV,CAAiBD,WAAjB,CACV,oCADU,CA1EA;;AA6EZ;AACAnB,EAAAA,MAAM,EAAEiB,mBAAS,CAACW,MAAV,CAAiBT,WAAjB,CAA6B,4BAA7B,CA9EI;;AA+EZ;AACAlB,EAAAA,aAAa,EAAEgB,mBAAS,CAACI,IAAV,CAAeF,WAAf,CAA2B,8BAA3B;AAhFH,CAAd;AAmFAhD,OAAO,CAAC0D,SAAR,GAAoBb,KAApB;IAEMc,iBAAiB,GAAGC,kBAAQ,CAAC5D,OAAD;AAClC2D,iBAAiB,CAACD,SAAlB,GAA8Bb,KAA9B;;;;;;"}
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var React = require('react');
|
|
6
|
-
var
|
|
7
|
-
var DSButton = require('@elliemae/ds-
|
|
6
|
+
var dsIcons = require('@elliemae/ds-icons');
|
|
7
|
+
var DSButton = require('@elliemae/ds-button');
|
|
8
8
|
var v2_blocks = require('../blocks.js');
|
|
9
9
|
require('@babel/runtime/helpers/defineProperty');
|
|
10
10
|
require('@elliemae/ds-classnames');
|
|
@@ -12,7 +12,6 @@ require('@elliemae/ds-classnames');
|
|
|
12
12
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
13
13
|
|
|
14
14
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
15
|
-
var CloseIcon__default = /*#__PURE__*/_interopDefaultLegacy(CloseIcon);
|
|
16
15
|
var DSButton__default = /*#__PURE__*/_interopDefaultLegacy(DSButton);
|
|
17
16
|
|
|
18
17
|
/* eslint-disable max-lines */
|
|
@@ -29,7 +28,7 @@ var DecisionHeader = function DecisionHeader(_ref) {
|
|
|
29
28
|
containerProps: {
|
|
30
29
|
'data-testid': 'modal-button-close'
|
|
31
30
|
},
|
|
32
|
-
icon: /*#__PURE__*/React__default['default'].createElement(
|
|
31
|
+
icon: /*#__PURE__*/React__default['default'].createElement(dsIcons.Close, null),
|
|
33
32
|
onClick: onClose
|
|
34
33
|
}));
|
|
35
34
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DecisionHeader.js","sources":["../../../../src/v2/components/DecisionHeader.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nimport React from 'react';\nimport
|
|
1
|
+
{"version":3,"file":"DecisionHeader.js","sources":["../../../../src/v2/components/DecisionHeader.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nimport React from 'react';\nimport { Close } from '@elliemae/ds-icons';\nimport DSButton from '@elliemae/ds-button';\nimport { ModalHeader } from '../blocks';\n\nexport const DecisionHeader = ({ onClose, showClose }) => (\n <ModalHeader classProps={{ type: 'decision', showClose }}>\n {showClose && (\n <DSButton\n buttonType=\"link\"\n containerProps={{ 'data-testid': 'modal-button-close' }}\n icon={<Close />}\n onClick={onClose}\n />\n )}\n </ModalHeader>\n);\n\nexport default DecisionHeader;\n"],"names":["DecisionHeader","onClose","showClose","React","ModalHeader","type","DSButton","Close"],"mappings":";;;;;;;;;;;;;;;;AAAA;IAMaA,cAAc,GAAG,SAAjBA,cAAiB;AAAA,MAAGC,OAAH,QAAGA,OAAH;AAAA,MAAYC,SAAZ,QAAYA,SAAZ;AAAA,sBAC5BC,wCAACC,qBAAD;AAAa,IAAA,UAAU,EAAE;AAAEC,MAAAA,IAAI,EAAE,UAAR;AAAoBH,MAAAA,SAAS,EAATA;AAApB;AAAzB,KACGA,SAAS,iBACRC,wCAACG,4BAAD;AACE,IAAA,UAAU,EAAC,MADb;AAEE,IAAA,cAAc,EAAE;AAAE,qBAAe;AAAjB,KAFlB;AAGE,IAAA,IAAI,eAAEH,wCAACI,aAAD,OAHR;AAIE,IAAA,OAAO,EAAEN;AAJX,IAFJ,CAD4B;AAAA;;;;;"}
|
|
@@ -3,11 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var React = require('react');
|
|
6
|
-
var
|
|
7
|
-
var WarningTriangle = require('@elliemae/ds-icons/WarningTriangle');
|
|
8
|
-
var CheckmarkCircle = require('@elliemae/ds-icons/CheckmarkCircle');
|
|
9
|
-
var HelpCircle = require('@elliemae/ds-icons/HelpCircle');
|
|
10
|
-
var InfoCircle = require('@elliemae/ds-icons/InfoCircle');
|
|
6
|
+
var dsIcons = require('@elliemae/ds-icons');
|
|
11
7
|
var constants = require('../../constants.js');
|
|
12
8
|
var v2_blocks = require('../blocks.js');
|
|
13
9
|
require('@babel/runtime/helpers/defineProperty');
|
|
@@ -16,42 +12,37 @@ require('@elliemae/ds-classnames');
|
|
|
16
12
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
17
13
|
|
|
18
14
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
19
|
-
var ErrorHexegon__default = /*#__PURE__*/_interopDefaultLegacy(ErrorHexegon);
|
|
20
|
-
var WarningTriangle__default = /*#__PURE__*/_interopDefaultLegacy(WarningTriangle);
|
|
21
|
-
var CheckmarkCircle__default = /*#__PURE__*/_interopDefaultLegacy(CheckmarkCircle);
|
|
22
|
-
var HelpCircle__default = /*#__PURE__*/_interopDefaultLegacy(HelpCircle);
|
|
23
|
-
var InfoCircle__default = /*#__PURE__*/_interopDefaultLegacy(InfoCircle);
|
|
24
15
|
|
|
25
16
|
var feedbackIconSize = 'xxl';
|
|
26
17
|
|
|
27
18
|
var getIconType = function getIconType(subtype) {
|
|
28
19
|
switch (subtype) {
|
|
29
20
|
case constants.MODAL_SUB_TYPE_V2.WARNING:
|
|
30
|
-
return /*#__PURE__*/React__default['default'].createElement(
|
|
21
|
+
return /*#__PURE__*/React__default['default'].createElement(dsIcons.WarningTriangle, {
|
|
31
22
|
"data-testid": "icon-waring",
|
|
32
23
|
size: feedbackIconSize
|
|
33
24
|
});
|
|
34
25
|
|
|
35
26
|
case constants.MODAL_SUB_TYPE_V2.ERROR:
|
|
36
|
-
return /*#__PURE__*/React__default['default'].createElement(
|
|
27
|
+
return /*#__PURE__*/React__default['default'].createElement(dsIcons.ErrorHexegon, {
|
|
37
28
|
"data-testid": "icon-error",
|
|
38
29
|
size: feedbackIconSize
|
|
39
30
|
});
|
|
40
31
|
|
|
41
32
|
case constants.MODAL_SUB_TYPE_V2.SUCCESS:
|
|
42
|
-
return /*#__PURE__*/React__default['default'].createElement(
|
|
33
|
+
return /*#__PURE__*/React__default['default'].createElement(dsIcons.CheckmarkCircle, {
|
|
43
34
|
"data-testid": "icon-success",
|
|
44
35
|
size: feedbackIconSize
|
|
45
36
|
});
|
|
46
37
|
|
|
47
38
|
case constants.MODAL_SUB_TYPE_V2.INFORMATION:
|
|
48
|
-
return /*#__PURE__*/React__default['default'].createElement(
|
|
39
|
+
return /*#__PURE__*/React__default['default'].createElement(dsIcons.InfoCircle, {
|
|
49
40
|
"data-testid": "icon-information",
|
|
50
41
|
size: feedbackIconSize
|
|
51
42
|
});
|
|
52
43
|
|
|
53
44
|
default:
|
|
54
|
-
return /*#__PURE__*/React__default['default'].createElement(
|
|
45
|
+
return /*#__PURE__*/React__default['default'].createElement(dsIcons.HelpCircle, {
|
|
55
46
|
"data-testid": "icon-help",
|
|
56
47
|
size: feedbackIconSize
|
|
57
48
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FeedbackIcon.js","sources":["../../../../src/v2/components/FeedbackIcon.tsx"],"sourcesContent":["import React from 'react';\nimport
|
|
1
|
+
{"version":3,"file":"FeedbackIcon.js","sources":["../../../../src/v2/components/FeedbackIcon.tsx"],"sourcesContent":["import React from 'react';\nimport { ErrorHexegon, WarningTriangle, CheckmarkCircle, HelpCircle, InfoCircle } from '@elliemae/ds-icons';\n\nimport { MODAL_SUB_TYPE_V2 } from '../../constants';\nimport { ModalFeedback } from '../blocks';\n\nconst feedbackIconSize = 'xxl';\n\nconst getIconType = (subtype) => {\n switch (subtype) {\n case MODAL_SUB_TYPE_V2.WARNING:\n return <WarningTriangle data-testid=\"icon-waring\" size={feedbackIconSize} />;\n case MODAL_SUB_TYPE_V2.ERROR:\n return <ErrorHexegon data-testid=\"icon-error\" size={feedbackIconSize} />;\n case MODAL_SUB_TYPE_V2.SUCCESS:\n return <CheckmarkCircle data-testid=\"icon-success\" size={feedbackIconSize} />;\n case MODAL_SUB_TYPE_V2.INFORMATION:\n return <InfoCircle data-testid=\"icon-information\" size={feedbackIconSize} />;\n default:\n return <HelpCircle data-testid=\"icon-help\" size={feedbackIconSize} />;\n }\n};\n\nexport const FeedbackIcon = ({ modalSubType }) => (\n <ModalFeedback classProps={{ type: modalSubType }}>{getIconType(modalSubType)}</ModalFeedback>\n);\n\nexport default FeedbackIcon;\n"],"names":["feedbackIconSize","getIconType","subtype","MODAL_SUB_TYPE_V2","WARNING","React","WarningTriangle","ERROR","ErrorHexegon","SUCCESS","CheckmarkCircle","INFORMATION","InfoCircle","HelpCircle","FeedbackIcon","modalSubType","ModalFeedback","type"],"mappings":";;;;;;;;;;;;;;;AAMA,IAAMA,gBAAgB,GAAG,KAAzB;;AAEA,IAAMC,WAAW,GAAG,SAAdA,WAAc,CAACC,OAAD,EAAa;AAC/B,UAAQA,OAAR;AACE,SAAKC,2BAAiB,CAACC,OAAvB;AACE,0BAAOC,wCAACC,uBAAD;AAAiB,uBAAY,aAA7B;AAA2C,QAAA,IAAI,EAAEN;AAAjD,QAAP;;AACF,SAAKG,2BAAiB,CAACI,KAAvB;AACE,0BAAOF,wCAACG,oBAAD;AAAc,uBAAY,YAA1B;AAAuC,QAAA,IAAI,EAAER;AAA7C,QAAP;;AACF,SAAKG,2BAAiB,CAACM,OAAvB;AACE,0BAAOJ,wCAACK,uBAAD;AAAiB,uBAAY,cAA7B;AAA4C,QAAA,IAAI,EAAEV;AAAlD,QAAP;;AACF,SAAKG,2BAAiB,CAACQ,WAAvB;AACE,0BAAON,wCAACO,kBAAD;AAAY,uBAAY,kBAAxB;AAA2C,QAAA,IAAI,EAAEZ;AAAjD,QAAP;;AACF;AACE,0BAAOK,wCAACQ,kBAAD;AAAY,uBAAY,WAAxB;AAAoC,QAAA,IAAI,EAAEb;AAA1C,QAAP;AAVJ;AAYD,CAbD;;IAeac,YAAY,GAAG,SAAfA,YAAe;AAAA,MAAGC,YAAH,QAAGA,YAAH;AAAA,sBAC1BV,wCAACW,uBAAD;AAAe,IAAA,UAAU,EAAE;AAAEC,MAAAA,IAAI,EAAEF;AAAR;AAA3B,KAAoDd,WAAW,CAACc,YAAD,CAA/D,CAD0B;AAAA;;;;;"}
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
var _extends = require('@babel/runtime/helpers/extends');
|
|
6
6
|
var React = require('react');
|
|
7
|
-
var DSButton = require('@elliemae/ds-
|
|
7
|
+
var DSButton = require('@elliemae/ds-button');
|
|
8
8
|
var v2_blocks = require('../blocks.js');
|
|
9
9
|
require('@babel/runtime/helpers/defineProperty');
|
|
10
10
|
require('@elliemae/ds-classnames');
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Footer.js","sources":["../../../../src/v2/components/Footer.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nimport React from 'react';\nimport DSButton from '@elliemae/ds-
|
|
1
|
+
{"version":3,"file":"Footer.js","sources":["../../../../src/v2/components/Footer.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nimport React from 'react';\nimport DSButton from '@elliemae/ds-button';\nimport { ModalFooter, ModalFooterActions } from '../blocks';\n\nexport const Footer = ({\n additionalFooterCssClass,\n actionsRef,\n rejectLabel,\n onReject,\n overridePropsRejectButton,\n confirmLabel,\n onConfirm,\n overridePropsConfirmButton,\n showRejectButton,\n}) => (\n <ModalFooter classProps={{ additionalFooterCssClass }} data-testid=\"modal-footer-wrapper\">\n <ModalFooterActions ref={actionsRef}>\n {showRejectButton === true && (\n <DSButton\n buttonType=\"secondary\"\n className=\"action-reject\"\n containerProps={{ 'data-testid': 'modal-footer-reject-btn' }}\n labelText={rejectLabel}\n onClick={onReject}\n {...overridePropsRejectButton}\n />\n )}\n <DSButton\n buttonType=\"primary\"\n className=\"action-confirm\"\n containerProps={{ 'data-testid': 'modal-footer-confirm-btn' }}\n labelText={confirmLabel}\n onClick={onConfirm}\n {...overridePropsConfirmButton}\n />\n </ModalFooterActions>\n </ModalFooter>\n);\n\nexport default Footer;\n"],"names":["Footer","additionalFooterCssClass","actionsRef","rejectLabel","onReject","overridePropsRejectButton","confirmLabel","onConfirm","overridePropsConfirmButton","showRejectButton","React","ModalFooter","ModalFooterActions","DSButton"],"mappings":";;;;;;;;;;;;;;;;;IAKaA,MAAM,GAAG,SAATA,MAAS;AAAA,MACpBC,wBADoB,QACpBA,wBADoB;AAAA,MAEpBC,UAFoB,QAEpBA,UAFoB;AAAA,MAGpBC,WAHoB,QAGpBA,WAHoB;AAAA,MAIpBC,QAJoB,QAIpBA,QAJoB;AAAA,MAKpBC,yBALoB,QAKpBA,yBALoB;AAAA,MAMpBC,YANoB,QAMpBA,YANoB;AAAA,MAOpBC,SAPoB,QAOpBA,SAPoB;AAAA,MAQpBC,0BARoB,QAQpBA,0BARoB;AAAA,MASpBC,gBAToB,QASpBA,gBAToB;AAAA,sBAWpBC,wCAACC,qBAAD;AAAa,IAAA,UAAU,EAAE;AAAEV,MAAAA,wBAAwB,EAAxBA;AAAF,KAAzB;AAAuD,mBAAY;AAAnE,kBACES,wCAACE,4BAAD;AAAoB,IAAA,GAAG,EAAEV;AAAzB,KACGO,gBAAgB,KAAK,IAArB,iBACCC,wCAACG,4BAAD;AACE,IAAA,UAAU,EAAC,WADb;AAEE,IAAA,SAAS,EAAC,eAFZ;AAGE,IAAA,cAAc,EAAE;AAAE,qBAAe;AAAjB,KAHlB;AAIE,IAAA,SAAS,EAAEV,WAJb;AAKE,IAAA,OAAO,EAAEC;AALX,KAMMC,yBANN,EAFJ,eAWEK,wCAACG,4BAAD;AACE,IAAA,UAAU,EAAC,SADb;AAEE,IAAA,SAAS,EAAC,gBAFZ;AAGE,IAAA,cAAc,EAAE;AAAE,qBAAe;AAAjB,KAHlB;AAIE,IAAA,SAAS,EAAEP,YAJb;AAKE,IAAA,OAAO,EAAEC;AALX,KAMMC,0BANN,EAXF,CADF,CAXoB;AAAA;;;;;"}
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var React = require('react');
|
|
6
|
-
var
|
|
7
|
-
var DSButton = require('@elliemae/ds-
|
|
6
|
+
var dsIcons = require('@elliemae/ds-icons');
|
|
7
|
+
var DSButton = require('@elliemae/ds-button');
|
|
8
8
|
var v2_blocks = require('../blocks.js');
|
|
9
9
|
var v2_components_Title = require('./Title.js');
|
|
10
10
|
require('@babel/runtime/helpers/defineProperty');
|
|
@@ -13,7 +13,6 @@ require('@elliemae/ds-classnames');
|
|
|
13
13
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
14
14
|
|
|
15
15
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
16
|
-
var CloseIcon__default = /*#__PURE__*/_interopDefaultLegacy(CloseIcon);
|
|
17
16
|
var DSButton__default = /*#__PURE__*/_interopDefaultLegacy(DSButton);
|
|
18
17
|
|
|
19
18
|
/* eslint-disable max-lines */
|
|
@@ -38,7 +37,7 @@ var FormHeader = function FormHeader(_ref) {
|
|
|
38
37
|
containerProps: {
|
|
39
38
|
'data-testid': 'modal-close-btn'
|
|
40
39
|
},
|
|
41
|
-
icon: /*#__PURE__*/React__default['default'].createElement(
|
|
40
|
+
icon: /*#__PURE__*/React__default['default'].createElement(dsIcons.Close, null),
|
|
42
41
|
onClick: onClose
|
|
43
42
|
})));
|
|
44
43
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FormHeader.js","sources":["../../../../src/v2/components/FormHeader.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nimport React from 'react';\nimport
|
|
1
|
+
{"version":3,"file":"FormHeader.js","sources":["../../../../src/v2/components/FormHeader.tsx"],"sourcesContent":["/* eslint-disable max-lines */\nimport React from 'react';\nimport { Close } from '@elliemae/ds-icons';\nimport DSButton from '@elliemae/ds-button';\nimport { ModalHeader, ModalHeaderTopRight } from '../blocks';\nimport { Title } from './Title';\n\nexport const FormHeader = ({ showClose, modalTitle, modalType, onClose }) => (\n <ModalHeader classProps={{ type: 'selection' }}>\n <Title modalTitle={modalTitle} modalType={modalType} />\n <ModalHeaderTopRight classProps={{ type: 'form' }}>\n {showClose && (\n <DSButton\n buttonType=\"link\"\n containerProps={{ 'data-testid': 'modal-close-btn' }}\n icon={<Close />}\n onClick={onClose}\n />\n )}\n </ModalHeaderTopRight>\n </ModalHeader>\n);\n\nexport default FormHeader;\n"],"names":["FormHeader","showClose","modalTitle","modalType","onClose","React","ModalHeader","type","Title","ModalHeaderTopRight","DSButton","Close"],"mappings":";;;;;;;;;;;;;;;;;AAAA;IAOaA,UAAU,GAAG,SAAbA,UAAa;AAAA,MAAGC,SAAH,QAAGA,SAAH;AAAA,MAAcC,UAAd,QAAcA,UAAd;AAAA,MAA0BC,SAA1B,QAA0BA,SAA1B;AAAA,MAAqCC,OAArC,QAAqCA,OAArC;AAAA,sBACxBC,wCAACC,qBAAD;AAAa,IAAA,UAAU,EAAE;AAAEC,MAAAA,IAAI,EAAE;AAAR;AAAzB,kBACEF,wCAACG,yBAAD;AAAO,IAAA,UAAU,EAAEN,UAAnB;AAA+B,IAAA,SAAS,EAAEC;AAA1C,IADF,eAEEE,wCAACI,6BAAD;AAAqB,IAAA,UAAU,EAAE;AAAEF,MAAAA,IAAI,EAAE;AAAR;AAAjC,KACGN,SAAS,iBACRI,wCAACK,4BAAD;AACE,IAAA,UAAU,EAAC,MADb;AAEE,IAAA,cAAc,EAAE;AAAE,qBAAe;AAAjB,KAFlB;AAGE,IAAA,IAAI,eAAEL,wCAACM,aAAD,OAHR;AAIE,IAAA,OAAO,EAAEP;AAJX,IAFJ,CAFF,CADwB;AAAA;;;;;"}
|