@coorpacademy/components 11.9.2-alpha.1 → 11.9.2-alpha.12
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/es/atom/drag-and-drop/style.css +14 -9
- package/es/atom/image-upload/index.d.ts +6 -1
- package/es/atom/image-upload/index.d.ts.map +1 -1
- package/es/atom/image-upload/index.js +24 -4
- package/es/atom/image-upload/index.js.map +1 -1
- package/es/atom/image-upload/style.css +7 -0
- package/es/atom/review-presentation/index.d.ts.map +1 -1
- package/es/atom/review-presentation/index.js +62 -12
- package/es/atom/review-presentation/index.js.map +1 -1
- package/es/atom/review-presentation/style.css +67 -7
- package/es/atom/title/index.d.ts +1 -0
- package/es/atom/title/index.d.ts.map +1 -1
- package/es/atom/title/index.js +14 -5
- package/es/atom/title/index.js.map +1 -1
- package/es/atom/title/style.css +6 -0
- package/es/molecule/brand-form-group/index.d.ts +5 -0
- package/es/molecule/brand-form-group/index.d.ts.map +1 -1
- package/es/molecule/brand-form-group/index.js +4 -1
- package/es/molecule/brand-form-group/index.js.map +1 -1
- package/es/molecule/brand-form-group/style.css +9 -10
- package/es/molecule/drag-and-drop-wrapper/index.d.ts +2 -0
- package/es/molecule/setup-slide/index.d.ts +2 -0
- package/es/molecule/setup-slider/index.d.ts +2 -0
- package/es/molecule/title-and-checkbox-wrapper/index.d.ts +3 -0
- package/es/organism/brand-form/index.d.ts +5 -0
- package/es/organism/rewards-form/index.d.ts +3 -0
- package/es/organism/wizard-contents/index.d.ts +10 -2
- package/es/organism/wizard-contents/index.d.ts.map +1 -1
- package/es/organism/wizard-contents/index.js +9 -4
- package/es/organism/wizard-contents/index.js.map +1 -1
- package/es/organism/wizard-contents/style.css +36 -4
- package/es/template/activity/engine-stars.css +33 -16
- package/es/template/activity/engine-stars.d.ts +17 -15
- package/es/template/activity/engine-stars.d.ts.map +1 -1
- package/es/template/activity/engine-stars.js +115 -128
- package/es/template/activity/engine-stars.js.map +1 -1
- package/es/template/activity/index.d.ts +0 -1
- package/es/template/activity/index.d.ts.map +1 -1
- package/es/template/activity/index.js +9 -18
- package/es/template/activity/index.js.map +1 -1
- package/es/template/activity/progression-item.js +1 -1
- package/es/template/activity/progression-item.js.map +1 -1
- package/es/template/activity/stars-summary.d.ts +0 -1
- package/es/template/activity/stars-summary.d.ts.map +1 -1
- package/es/template/activity/stars-summary.js +5 -10
- package/es/template/activity/stars-summary.js.map +1 -1
- package/es/template/back-office/brand-update/index.d.ts +15 -2
- package/es/template/back-office/brand-update/index.d.ts.map +1 -1
- package/es/template/back-office/brand-update/index.js.map +1 -1
- package/lib/atom/drag-and-drop/style.css +14 -9
- package/lib/atom/image-upload/index.d.ts +6 -1
- package/lib/atom/image-upload/index.d.ts.map +1 -1
- package/lib/atom/image-upload/index.js +25 -4
- package/lib/atom/image-upload/index.js.map +1 -1
- package/lib/atom/image-upload/style.css +7 -0
- package/lib/atom/review-presentation/index.d.ts.map +1 -1
- package/lib/atom/review-presentation/index.js +66 -13
- package/lib/atom/review-presentation/index.js.map +1 -1
- package/lib/atom/review-presentation/style.css +67 -7
- package/lib/atom/title/index.d.ts +1 -0
- package/lib/atom/title/index.d.ts.map +1 -1
- package/lib/atom/title/index.js +14 -5
- package/lib/atom/title/index.js.map +1 -1
- package/lib/atom/title/style.css +6 -0
- package/lib/molecule/brand-form-group/index.d.ts +5 -0
- package/lib/molecule/brand-form-group/index.d.ts.map +1 -1
- package/lib/molecule/brand-form-group/index.js +4 -1
- package/lib/molecule/brand-form-group/index.js.map +1 -1
- package/lib/molecule/brand-form-group/style.css +9 -10
- package/lib/molecule/drag-and-drop-wrapper/index.d.ts +2 -0
- package/lib/molecule/setup-slide/index.d.ts +2 -0
- package/lib/molecule/setup-slider/index.d.ts +2 -0
- package/lib/molecule/title-and-checkbox-wrapper/index.d.ts +3 -0
- package/lib/organism/brand-form/index.d.ts +5 -0
- package/lib/organism/rewards-form/index.d.ts +3 -0
- package/lib/organism/wizard-contents/index.d.ts +10 -2
- package/lib/organism/wizard-contents/index.d.ts.map +1 -1
- package/lib/organism/wizard-contents/index.js +9 -4
- package/lib/organism/wizard-contents/index.js.map +1 -1
- package/lib/organism/wizard-contents/style.css +36 -4
- package/lib/template/activity/engine-stars.css +33 -16
- package/lib/template/activity/engine-stars.d.ts +17 -15
- package/lib/template/activity/engine-stars.d.ts.map +1 -1
- package/lib/template/activity/engine-stars.js +116 -135
- package/lib/template/activity/engine-stars.js.map +1 -1
- package/lib/template/activity/index.d.ts +0 -1
- package/lib/template/activity/index.d.ts.map +1 -1
- package/lib/template/activity/index.js +9 -21
- package/lib/template/activity/index.js.map +1 -1
- package/lib/template/activity/progression-item.js +1 -1
- package/lib/template/activity/progression-item.js.map +1 -1
- package/lib/template/activity/stars-summary.d.ts +0 -1
- package/lib/template/activity/stars-summary.d.ts.map +1 -1
- package/lib/template/activity/stars-summary.js +5 -10
- package/lib/template/activity/stars-summary.js.map +1 -1
- package/lib/template/back-office/brand-update/index.d.ts +15 -2
- package/lib/template/back-office/brand-update/index.d.ts.map +1 -1
- package/lib/template/back-office/brand-update/index.js.map +1 -1
- package/locales/en/global.json +0 -1
- package/package.json +3 -4
- package/es/atom/tooltip/index.d.ts +0 -22
- package/es/atom/tooltip/index.d.ts.map +0 -1
- package/es/atom/tooltip/index.js +0 -117
- package/es/atom/tooltip/index.js.map +0 -1
- package/es/atom/tooltip/style.css +0 -96
- package/lib/atom/tooltip/index.d.ts +0 -22
- package/lib/atom/tooltip/index.d.ts.map +0 -1
- package/lib/atom/tooltip/index.js +0 -137
- package/lib/atom/tooltip/index.js.map +0 -1
- package/lib/atom/tooltip/style.css +0 -96
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["React","PropTypes","classNames","Autocomplete","Select","SelectMultiple","InputText","InputColor","InputCheckbox","InputReadonly","InputSwitch","BrandUploadBox","BrandDownloadBox","Button","InputTextarea","InputHTML","InputDoublestep","ImageUpload","SetupSlider","SetupSections","Title","Roles","TitleAndCheckBoxWrapper","ButtonLink","style","inputContainerStyle","default","defaultWidth","medium","mediumWidth","large","largeWidth","buildInput","field","type","imageUploadContainer","buttonType","buildField","index","input","theme","size","styleInput","BrandFormGroup","props","title","subtitle","fieldsLayout","groupLayout","fields","fieldsList","convert","cap","wrapper","groupGrid","titleWrapper","grid","propTypes","string","arrayOf","oneOfType","shape","oneOf"],"sources":["../../../src/molecule/brand-form-group/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {keys, map, snakeCase} from 'lodash/fp';\nimport classNames from 'classnames';\nimport Autocomplete from '../../atom/autocomplete';\nimport Select from '../../atom/select';\nimport SelectMultiple from '../select-multiple';\nimport InputText from '../../atom/input-text';\nimport InputColor from '../../atom/input-color';\nimport InputCheckbox from '../../atom/input-checkbox';\nimport InputReadonly from '../../atom/input-readonly';\nimport InputSwitch from '../../atom/input-switch';\nimport BrandUploadBox from '../brand-upload-box';\nimport BrandDownloadBox from '../brand-download-box';\nimport Button from '../../atom/button';\nimport InputTextarea from '../../atom/input-textarea';\nimport InputHTML from '../../atom/input-html';\nimport InputDoublestep from '../../atom/input-doublestep';\nimport ImageUpload from '../../atom/image-upload';\nimport SetupSlider from '../setup-slider';\nimport SetupSections from '../setup-sections';\nimport Title from '../../atom/title';\nimport Roles from '../coorp-manager-roles';\nimport TitleAndCheckBoxWrapper from '../title-and-checkbox-wrapper';\nimport ButtonLink from '../../atom/button-link';\nimport style from './style.css';\n\nconst inputContainerStyle = {\n default: style.defaultWidth,\n medium: style.mediumWidth,\n large: style.largeWidth\n};\n\nconst buildInput = field => {\n const {type} = field;\n\n switch (type) {\n case 'autoComplete':\n return <Autocomplete {...field} />;\n case 'color':\n return <InputColor {...field} />;\n case 'readonly':\n return <InputReadonly {...field} />;\n case 'switch':\n return <InputSwitch {...field} />;\n case 'textarea':\n return <InputTextarea {...field} />;\n case 'html':\n return <InputHTML {...field} />;\n case 'doublestep':\n return <InputDoublestep {...field} />;\n case 'select':\n return <Select {...field} theme={'coorpmanager'} />;\n case 'selectMultiple':\n return <SelectMultiple {...field} />;\n case 'checkbox':\n return <InputCheckbox {...field} />;\n case 'image':\n return (\n <div className={style.imageUploadContainer}>\n <ImageUpload {...field} />\n </div>\n );\n case 'slider':\n return <SetupSlider {...field} />;\n case 'sections':\n return <SetupSections {...field} />;\n case 'text':\n return <InputText {...field} />;\n case 'downloadbox':\n return <BrandDownloadBox {...field} />;\n case 'uploadbox':\n return <BrandUploadBox {...field} />;\n case 'button':\n case 'link':\n return <Button {...field} />;\n case 'buttonLink':\n return <ButtonLink {...field} type={field.buttonType} />;\n case 'roles':\n return <Roles {...field} />;\n case 'titleAndCheckBoxWrapper':\n return <TitleAndCheckBoxWrapper {...field} />;\n default:\n return <InputText {...field} />;\n }\n};\n\nconst buildField = (field, index) => {\n const input = buildInput(field);\n const {theme, size = 'default'} = field;\n const styleInput = theme === 'coorpmanager' ? inputContainerStyle[size] : style.field;\n\n return (\n <div className={styleInput} key={index}>\n {input}\n </div>\n );\n};\n\nconst BrandFormGroup = props => {\n const {title, subtitle = '', fieldsLayout = '', groupLayout = '', fields = []} = props;\n const fieldsList = map.convert({cap: false})(buildField, fields);\n\n return (\n <div\n data-name={`brand_form_group_${snakeCase(title)}`}\n className={classNames(style.wrapper, groupLayout === 'grid' && style.groupGrid)}\n >\n <div className={style.titleWrapper}>\n <Title title={title} subtitle={subtitle} type={'form-group'} />\n </div>\n <div className={fieldsLayout === 'grid' ? style.grid : null}>{fieldsList}</div>\n </div>\n );\n};\n\nBrandFormGroup.propTypes = {\n title: PropTypes.string,\n subtitle: PropTypes.string,\n fieldsLayout: PropTypes.string,\n groupLayout: PropTypes.string,\n fields: PropTypes.arrayOf(\n PropTypes.oneOfType([\n PropTypes.shape({\n ...Autocomplete.propTypes,\n type: PropTypes.oneOf(['autoComplete']),\n size: PropTypes.oneOf(keys(inputContainerStyle))\n }),\n PropTypes.shape({\n ...InputColor.propTypes,\n type: PropTypes.oneOf(['color'])\n }),\n PropTypes.shape({\n ...InputReadonly.propTypes,\n type: PropTypes.oneOf(['readonly'])\n }),\n PropTypes.shape({\n ...InputSwitch.propTypes,\n type: PropTypes.oneOf(['switch'])\n }),\n PropTypes.shape({\n ...InputTextarea.propTypes,\n type: PropTypes.oneOf(['textarea']),\n size: PropTypes.oneOf(keys(inputContainerStyle))\n }),\n PropTypes.shape({\n ...InputHTML.propTypes,\n type: PropTypes.oneOf(['html'])\n }),\n PropTypes.shape({\n ...InputDoublestep.propTypes,\n type: PropTypes.oneOf(['doublestep'])\n }),\n PropTypes.shape({\n ...Select.propTypes,\n type: PropTypes.oneOf(['select']),\n size: PropTypes.oneOf(keys(inputContainerStyle))\n }),\n PropTypes.shape({\n ...InputCheckbox.propTypes,\n type: PropTypes.oneOf(['checkbox'])\n }),\n PropTypes.shape({\n ...ImageUpload.propTypes,\n type: PropTypes.oneOf(['image'])\n }),\n PropTypes.shape({\n ...SetupSlider.propTypes,\n type: PropTypes.oneOf(['slider'])\n }),\n PropTypes.shape({\n ...SetupSections.propTypes,\n type: PropTypes.oneOf(['sections'])\n }),\n PropTypes.shape({\n ...InputText.propTypes,\n type: PropTypes.oneOf(['text']),\n size: PropTypes.oneOf(keys(inputContainerStyle))\n }),\n PropTypes.shape({\n ...BrandDownloadBox.propTypes,\n type: PropTypes.oneOf(['downloadbox'])\n }),\n PropTypes.shape({\n ...BrandUploadBox.propTypes,\n type: PropTypes.oneOf(['uploadbox'])\n }),\n PropTypes.shape({\n ...Button.propTypes,\n type: PropTypes.oneOf(['button'])\n }),\n PropTypes.shape({\n ...ButtonLink.propTypes,\n buttonType: ButtonLink.propTypes.type,\n type: PropTypes.oneOf(['buttonLink'])\n }),\n PropTypes.shape({\n ...SelectMultiple.propTypes,\n type: PropTypes.oneOf(['selectMultiple'])\n }),\n PropTypes.shape({\n ...Roles.propTypes,\n type: PropTypes.oneOf(['roles'])\n }),\n PropTypes.shape(InputText.propTypes)\n ])\n )\n};\nexport default BrandFormGroup;\n"],"mappings":";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GApDkB,EAyDlBxB,SAAS,CAAC4D,KAAV,cACKjD,gBAAgB,CAAC6C,SADtB;IAEEvB,IAAI,EAAEjC,SAAS,CAAC6D,KAAV,CAAgB,CAAC,aAAD,CAAhB;EAFR,GAzDkB,EA6DlB7D,SAAS,CAAC4D,KAAV,cACKlD,cAAc,CAAC8C,SADpB;IAEEvB,IAAI,EAAEjC,SAAS,CAAC6D,KAAV,CAAgB,CAAC,WAAD,CAAhB;EAFR,GA7DkB,EAiElB7D,SAAS,CAAC4D,KAAV,cACKhD,MAAM,CAAC4C,SADZ;IAEEvB,IAAI,EAAEjC,SAAS,CAAC6D,KAAV,CAAgB,CAAC,QAAD,CAAhB;EAFR,GAjEkB,EAqElB7D,SAAS,CAAC4D,KAAV,cACKtC,UAAU,CAACkC,SADhB;IAEErB,UAAU,EAAEb,UAAU,CAACkC,SAAX,CAAqBvB,IAFnC;IAGEA,IAAI,EAAEjC,SAAS,CAAC6D,KAAV,CAAgB,CAAC,YAAD,CAAhB;EAHR,GArEkB,EA0ElB7D,SAAS,CAAC4D,KAAV,cACKxD,cAAc,CAACoD,SADpB;IAEEvB,IAAI,EAAEjC,SAAS,CAAC6D,KAAV,CAAgB,CAAC,gBAAD,CAAhB;EAFR,GA1EkB,EA8ElB7D,SAAS,CAAC4D,KAAV,cACKxC,KAAK,CAACoC,SADX;IAEEvB,IAAI,EAAEjC,SAAS,CAAC6D,KAAV,CAAgB,CAAC,OAAD,CAAhB;EAFR,GA9EkB,EAkFlB7D,SAAS,CAAC4D,KAAV,CAAgBvD,SAAS,CAACmD,SAA1B,CAlFkB,CAApB,CADM;AALiB,CAA3B;AA4FA,eAAed,cAAf"}
|
|
1
|
+
{"version":3,"file":"index.js","names":["React","PropTypes","classNames","Autocomplete","Select","SelectMultiple","InputText","InputColor","InputCheckbox","InputReadonly","InputSwitch","BrandUploadBox","BrandDownloadBox","Button","InputTextarea","InputHTML","InputDoublestep","ImageUpload","SetupSlider","SetupSections","Title","Roles","TitleAndCheckBoxWrapper","ButtonLink","style","inputContainerStyle","default","defaultWidth","medium","mediumWidth","large","largeWidth","buildInput","field","type","imageUploadContainer","buttonType","buildField","index","input","theme","size","styleInput","BrandFormGroup","props","title","subtitle","fieldsLayout","groupLayout","fields","subtitleSize","fieldsList","convert","cap","wrapper","groupGrid","titleWrapper","grid","propTypes","string","arrayOf","oneOfType","shape","oneOf"],"sources":["../../../src/molecule/brand-form-group/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {keys, map, snakeCase} from 'lodash/fp';\nimport classNames from 'classnames';\nimport Autocomplete from '../../atom/autocomplete';\nimport Select from '../../atom/select';\nimport SelectMultiple from '../select-multiple';\nimport InputText from '../../atom/input-text';\nimport InputColor from '../../atom/input-color';\nimport InputCheckbox from '../../atom/input-checkbox';\nimport InputReadonly from '../../atom/input-readonly';\nimport InputSwitch from '../../atom/input-switch';\nimport BrandUploadBox from '../brand-upload-box';\nimport BrandDownloadBox from '../brand-download-box';\nimport Button from '../../atom/button';\nimport InputTextarea from '../../atom/input-textarea';\nimport InputHTML from '../../atom/input-html';\nimport InputDoublestep from '../../atom/input-doublestep';\nimport ImageUpload from '../../atom/image-upload';\nimport SetupSlider from '../setup-slider';\nimport SetupSections from '../setup-sections';\nimport Title from '../../atom/title';\nimport Roles from '../coorp-manager-roles';\nimport TitleAndCheckBoxWrapper from '../title-and-checkbox-wrapper';\nimport ButtonLink from '../../atom/button-link';\nimport style from './style.css';\n\nconst inputContainerStyle = {\n default: style.defaultWidth,\n medium: style.mediumWidth,\n large: style.largeWidth\n};\n\nconst buildInput = field => {\n const {type} = field;\n\n switch (type) {\n case 'autoComplete':\n return <Autocomplete {...field} />;\n case 'color':\n return <InputColor {...field} />;\n case 'readonly':\n return <InputReadonly {...field} />;\n case 'switch':\n return <InputSwitch {...field} />;\n case 'textarea':\n return <InputTextarea {...field} />;\n case 'html':\n return <InputHTML {...field} />;\n case 'doublestep':\n return <InputDoublestep {...field} />;\n case 'select':\n return <Select {...field} theme={'coorpmanager'} />;\n case 'selectMultiple':\n return <SelectMultiple {...field} />;\n case 'checkbox':\n return <InputCheckbox {...field} />;\n case 'image':\n return (\n <div className={style.imageUploadContainer}>\n <ImageUpload {...field} />\n </div>\n );\n case 'slider':\n return <SetupSlider {...field} />;\n case 'sections':\n return <SetupSections {...field} />;\n case 'text':\n return <InputText {...field} />;\n case 'downloadbox':\n return <BrandDownloadBox {...field} />;\n case 'uploadbox':\n return <BrandUploadBox {...field} />;\n case 'button':\n case 'link':\n return <Button {...field} />;\n case 'buttonLink':\n return <ButtonLink {...field} type={field.buttonType} />;\n case 'roles':\n return <Roles {...field} />;\n case 'titleAndCheckBoxWrapper':\n return <TitleAndCheckBoxWrapper {...field} />;\n default:\n return <InputText {...field} />;\n }\n};\n\nconst buildField = (field, index) => {\n const input = buildInput(field);\n const {theme, size = 'default'} = field;\n const styleInput = theme === 'coorpmanager' ? inputContainerStyle[size] : style.field;\n\n return (\n <div className={styleInput} key={index}>\n {input}\n </div>\n );\n};\n\nconst BrandFormGroup = props => {\n const {\n title,\n subtitle = '',\n fieldsLayout = '',\n groupLayout = '',\n fields = [],\n subtitleSize = 'standard'\n } = props;\n const fieldsList = map.convert({cap: false})(buildField, fields);\n\n return (\n <div\n data-name={`brand_form_group_${snakeCase(title)}`}\n className={classNames(style.wrapper, groupLayout === 'grid' && style.groupGrid)}\n >\n <div className={style.titleWrapper}>\n <Title title={title} subtitle={subtitle} subtitleSize={subtitleSize} type={'form-group'} />\n </div>\n <div className={fieldsLayout === 'grid' ? style.grid : null}>{fieldsList}</div>\n </div>\n );\n};\n\nBrandFormGroup.propTypes = {\n title: PropTypes.string,\n subtitle: PropTypes.string,\n subtitleSize: PropTypes.string,\n fieldsLayout: PropTypes.string,\n groupLayout: PropTypes.string,\n fields: PropTypes.arrayOf(\n PropTypes.oneOfType([\n PropTypes.shape({\n ...Autocomplete.propTypes,\n type: PropTypes.oneOf(['autoComplete']),\n size: PropTypes.oneOf(keys(inputContainerStyle))\n }),\n PropTypes.shape({\n ...InputColor.propTypes,\n type: PropTypes.oneOf(['color'])\n }),\n PropTypes.shape({\n ...InputReadonly.propTypes,\n type: PropTypes.oneOf(['readonly'])\n }),\n PropTypes.shape({\n ...InputSwitch.propTypes,\n type: PropTypes.oneOf(['switch'])\n }),\n PropTypes.shape({\n ...InputTextarea.propTypes,\n type: PropTypes.oneOf(['textarea']),\n size: PropTypes.oneOf(keys(inputContainerStyle))\n }),\n PropTypes.shape({\n ...InputHTML.propTypes,\n type: PropTypes.oneOf(['html'])\n }),\n PropTypes.shape({\n ...InputDoublestep.propTypes,\n type: PropTypes.oneOf(['doublestep'])\n }),\n PropTypes.shape({\n ...Select.propTypes,\n type: PropTypes.oneOf(['select']),\n size: PropTypes.oneOf(keys(inputContainerStyle))\n }),\n PropTypes.shape({\n ...InputCheckbox.propTypes,\n type: PropTypes.oneOf(['checkbox'])\n }),\n PropTypes.shape({\n ...ImageUpload.propTypes,\n type: PropTypes.oneOf(['image'])\n }),\n PropTypes.shape({\n ...SetupSlider.propTypes,\n type: PropTypes.oneOf(['slider'])\n }),\n PropTypes.shape({\n ...SetupSections.propTypes,\n type: PropTypes.oneOf(['sections'])\n }),\n PropTypes.shape({\n ...InputText.propTypes,\n type: PropTypes.oneOf(['text']),\n size: PropTypes.oneOf(keys(inputContainerStyle))\n }),\n PropTypes.shape({\n ...BrandDownloadBox.propTypes,\n type: PropTypes.oneOf(['downloadbox'])\n }),\n PropTypes.shape({\n ...BrandUploadBox.propTypes,\n type: PropTypes.oneOf(['uploadbox'])\n }),\n PropTypes.shape({\n ...Button.propTypes,\n type: PropTypes.oneOf(['button'])\n }),\n PropTypes.shape({\n ...ButtonLink.propTypes,\n buttonType: ButtonLink.propTypes.type,\n type: PropTypes.oneOf(['buttonLink'])\n }),\n PropTypes.shape({\n ...SelectMultiple.propTypes,\n type: PropTypes.oneOf(['selectMultiple'])\n }),\n PropTypes.shape({\n ...Roles.propTypes,\n type: PropTypes.oneOf(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
|
|
43
43
|
}
|
|
44
44
|
|
|
45
|
-
.grid .field {
|
|
46
|
-
margin-right: 20px;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
45
|
.field {
|
|
50
|
-
|
|
46
|
+
display: flex;
|
|
47
|
+
margin: 0 32px 64px 0;
|
|
48
|
+
flex: 1 0 0;
|
|
51
49
|
}
|
|
52
50
|
|
|
53
|
-
.field:last-child {
|
|
54
|
-
margin-bottom: 0;
|
|
55
|
-
}
|
|
56
51
|
|
|
57
52
|
.fieldCoorpmanager {
|
|
58
53
|
margin: 0 0 32px 0;
|
|
@@ -74,8 +69,10 @@
|
|
|
74
69
|
}
|
|
75
70
|
|
|
76
71
|
.imageUploadContainer {
|
|
77
|
-
|
|
78
|
-
|
|
72
|
+
display: flex;
|
|
73
|
+
flex-direction: column;
|
|
74
|
+
width: 100%;
|
|
75
|
+
min-width: 230px;
|
|
79
76
|
}
|
|
80
77
|
|
|
81
78
|
@media desktop {
|
|
@@ -84,6 +81,8 @@
|
|
|
84
81
|
}
|
|
85
82
|
|
|
86
83
|
.groupGrid .grid {
|
|
84
|
+
display: flex;
|
|
85
|
+
flex-direction: row;
|
|
87
86
|
justify-content: flex-start;
|
|
88
87
|
margin-top: 0;
|
|
89
88
|
}
|
|
@@ -10,6 +10,8 @@ declare namespace DragAndDropWrapper {
|
|
|
10
10
|
error: PropTypes.Requireable<string>;
|
|
11
11
|
buttonAriaLabel: PropTypes.Requireable<string>;
|
|
12
12
|
errorButtonLabel: PropTypes.Requireable<string>;
|
|
13
|
+
labelLink: PropTypes.Requireable<string>;
|
|
14
|
+
hrefLink: PropTypes.Requireable<string>;
|
|
13
15
|
title: PropTypes.Requireable<string>;
|
|
14
16
|
description: PropTypes.Requireable<string>;
|
|
15
17
|
uploadLabel: PropTypes.Requireable<string>;
|
|
@@ -87,6 +87,8 @@ declare namespace SetupSlide {
|
|
|
87
87
|
error: PropTypes.Requireable<string>;
|
|
88
88
|
buttonAriaLabel: PropTypes.Requireable<string>;
|
|
89
89
|
errorButtonLabel: PropTypes.Requireable<string>;
|
|
90
|
+
labelLink: PropTypes.Requireable<string>;
|
|
91
|
+
hrefLink: PropTypes.Requireable<string>;
|
|
90
92
|
title: PropTypes.Requireable<string>;
|
|
91
93
|
description: PropTypes.Requireable<string>;
|
|
92
94
|
uploadLabel: PropTypes.Requireable<string>;
|
|
@@ -100,6 +100,8 @@ declare namespace SetupSlider {
|
|
|
100
100
|
error: PropTypes.Requireable<string>;
|
|
101
101
|
buttonAriaLabel: PropTypes.Requireable<string>;
|
|
102
102
|
errorButtonLabel: PropTypes.Requireable<string>;
|
|
103
|
+
labelLink: PropTypes.Requireable<string>;
|
|
104
|
+
hrefLink: PropTypes.Requireable<string>;
|
|
103
105
|
title: PropTypes.Requireable<string>;
|
|
104
106
|
description: PropTypes.Requireable<string>;
|
|
105
107
|
uploadLabel: PropTypes.Requireable<string>;
|
|
@@ -15,6 +15,7 @@ declare namespace TitleAndCheckBoxWrapper {
|
|
|
15
15
|
subtitle: PropTypes.Requireable<string>;
|
|
16
16
|
type: PropTypes.Requireable<string>;
|
|
17
17
|
'data-name': PropTypes.Requireable<string>;
|
|
18
|
+
subtitleSize: PropTypes.Requireable<string>;
|
|
18
19
|
}>>;
|
|
19
20
|
const child: PropTypes.Requireable<NonNullable<PropTypes.InferProps<{
|
|
20
21
|
childType: PropTypes.Requireable<string>;
|
|
@@ -49,6 +50,8 @@ declare namespace TitleAndCheckBoxWrapper {
|
|
|
49
50
|
error: PropTypes.Requireable<string>;
|
|
50
51
|
buttonAriaLabel: PropTypes.Requireable<string>;
|
|
51
52
|
errorButtonLabel: PropTypes.Requireable<string>;
|
|
53
|
+
labelLink: PropTypes.Requireable<string>;
|
|
54
|
+
hrefLink: PropTypes.Requireable<string>;
|
|
52
55
|
title: PropTypes.Requireable<string>;
|
|
53
56
|
description: PropTypes.Requireable<string>;
|
|
54
57
|
uploadLabel: PropTypes.Requireable<string>;
|
|
@@ -34,6 +34,7 @@ declare namespace BrandForm {
|
|
|
34
34
|
export const groups: PropTypes.Validator<(PropTypes.InferProps<{
|
|
35
35
|
title: PropTypes.Requireable<string>;
|
|
36
36
|
subtitle: PropTypes.Requireable<string>;
|
|
37
|
+
subtitleSize: PropTypes.Requireable<string>;
|
|
37
38
|
fieldsLayout: PropTypes.Requireable<string>;
|
|
38
39
|
groupLayout: PropTypes.Requireable<string>;
|
|
39
40
|
fields: PropTypes.Requireable<(NonNullable<PropTypes.InferProps<{
|
|
@@ -159,6 +160,8 @@ declare namespace BrandForm {
|
|
|
159
160
|
error: PropTypes.Requireable<string>;
|
|
160
161
|
buttonAriaLabel: PropTypes.Requireable<string>;
|
|
161
162
|
errorButtonLabel: PropTypes.Requireable<string>;
|
|
163
|
+
labelLink: PropTypes.Requireable<string>;
|
|
164
|
+
hrefLink: PropTypes.Requireable<string>;
|
|
162
165
|
title: PropTypes.Requireable<string>;
|
|
163
166
|
description: PropTypes.Requireable<string>;
|
|
164
167
|
uploadLabel: PropTypes.Requireable<string>;
|
|
@@ -272,6 +275,8 @@ declare namespace BrandForm {
|
|
|
272
275
|
error: PropTypes.Requireable<string>;
|
|
273
276
|
buttonAriaLabel: PropTypes.Requireable<string>;
|
|
274
277
|
errorButtonLabel: PropTypes.Requireable<string>;
|
|
278
|
+
labelLink: PropTypes.Requireable<string>;
|
|
279
|
+
hrefLink: PropTypes.Requireable<string>;
|
|
275
280
|
title: PropTypes.Requireable<string>;
|
|
276
281
|
description: PropTypes.Requireable<string>;
|
|
277
282
|
uploadLabel: PropTypes.Requireable<string>;
|
|
@@ -18,6 +18,7 @@ declare namespace RewardsForm {
|
|
|
18
18
|
subtitle: PropTypes.Requireable<string>;
|
|
19
19
|
type: PropTypes.Requireable<string>;
|
|
20
20
|
'data-name': PropTypes.Requireable<string>;
|
|
21
|
+
subtitleSize: PropTypes.Requireable<string>;
|
|
21
22
|
}>>;
|
|
22
23
|
child: PropTypes.Requireable<NonNullable<PropTypes.InferProps<{
|
|
23
24
|
childType: PropTypes.Requireable<string>;
|
|
@@ -52,6 +53,8 @@ declare namespace RewardsForm {
|
|
|
52
53
|
error: PropTypes.Requireable<string>;
|
|
53
54
|
buttonAriaLabel: PropTypes.Requireable<string>;
|
|
54
55
|
errorButtonLabel: PropTypes.Requireable<string>;
|
|
56
|
+
labelLink: PropTypes.Requireable<string>;
|
|
57
|
+
hrefLink: PropTypes.Requireable<string>;
|
|
55
58
|
title: PropTypes.Requireable<string>;
|
|
56
59
|
description: PropTypes.Requireable<string>;
|
|
57
60
|
uploadLabel: PropTypes.Requireable<string>;
|
|
@@ -12,7 +12,7 @@ declare namespace WizardContents {
|
|
|
12
12
|
done: PropTypes.Requireable<boolean>;
|
|
13
13
|
current: PropTypes.Requireable<boolean>;
|
|
14
14
|
}> | null | undefined)[]>;
|
|
15
|
-
const summary: PropTypes.
|
|
15
|
+
const summary: PropTypes.Requireable<PropTypes.InferProps<{
|
|
16
16
|
title: PropTypes.Requireable<string>;
|
|
17
17
|
side: PropTypes.Requireable<string>;
|
|
18
18
|
sections: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
@@ -45,12 +45,13 @@ declare namespace WizardContents {
|
|
|
45
45
|
onClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
46
46
|
'aria-label': PropTypes.Requireable<string>;
|
|
47
47
|
}>>;
|
|
48
|
-
}
|
|
48
|
+
}>>;
|
|
49
49
|
const content: PropTypes.Requireable<NonNullable<PropTypes.InferProps<{
|
|
50
50
|
type: PropTypes.Requireable<string>;
|
|
51
51
|
groups: PropTypes.Validator<(PropTypes.InferProps<{
|
|
52
52
|
title: PropTypes.Requireable<string>;
|
|
53
53
|
subtitle: PropTypes.Requireable<string>;
|
|
54
|
+
subtitleSize: PropTypes.Requireable<string>;
|
|
54
55
|
fieldsLayout: PropTypes.Requireable<string>;
|
|
55
56
|
groupLayout: PropTypes.Requireable<string>;
|
|
56
57
|
fields: PropTypes.Requireable<(NonNullable<PropTypes.InferProps<{
|
|
@@ -176,6 +177,8 @@ declare namespace WizardContents {
|
|
|
176
177
|
error: PropTypes.Requireable<string>;
|
|
177
178
|
buttonAriaLabel: PropTypes.Requireable<string>;
|
|
178
179
|
errorButtonLabel: PropTypes.Requireable<string>;
|
|
180
|
+
labelLink: PropTypes.Requireable<string>;
|
|
181
|
+
hrefLink: PropTypes.Requireable<string>;
|
|
179
182
|
title: PropTypes.Requireable<string>;
|
|
180
183
|
description: PropTypes.Requireable<string>;
|
|
181
184
|
uploadLabel: PropTypes.Requireable<string>;
|
|
@@ -289,6 +292,8 @@ declare namespace WizardContents {
|
|
|
289
292
|
error: PropTypes.Requireable<string>;
|
|
290
293
|
buttonAriaLabel: PropTypes.Requireable<string>;
|
|
291
294
|
errorButtonLabel: PropTypes.Requireable<string>;
|
|
295
|
+
labelLink: PropTypes.Requireable<string>;
|
|
296
|
+
hrefLink: PropTypes.Requireable<string>;
|
|
292
297
|
title: PropTypes.Requireable<string>;
|
|
293
298
|
description: PropTypes.Requireable<string>;
|
|
294
299
|
uploadLabel: PropTypes.Requireable<string>;
|
|
@@ -640,6 +645,7 @@ declare namespace WizardContents {
|
|
|
640
645
|
subtitle: PropTypes.Requireable<string>;
|
|
641
646
|
type: PropTypes.Requireable<string>;
|
|
642
647
|
'data-name': PropTypes.Requireable<string>;
|
|
648
|
+
subtitleSize: PropTypes.Requireable<string>;
|
|
643
649
|
}>>;
|
|
644
650
|
child: PropTypes.Requireable<NonNullable<PropTypes.InferProps<{
|
|
645
651
|
childType: PropTypes.Requireable<string>;
|
|
@@ -674,6 +680,8 @@ declare namespace WizardContents {
|
|
|
674
680
|
error: PropTypes.Requireable<string>;
|
|
675
681
|
buttonAriaLabel: PropTypes.Requireable<string>;
|
|
676
682
|
errorButtonLabel: PropTypes.Requireable<string>;
|
|
683
|
+
labelLink: PropTypes.Requireable<string>;
|
|
684
|
+
hrefLink: PropTypes.Requireable<string>;
|
|
677
685
|
title: PropTypes.Requireable<string>;
|
|
678
686
|
description: PropTypes.Requireable<string>;
|
|
679
687
|
uploadLabel: PropTypes.Requireable<string>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/wizard-contents/index.js"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/organism/wizard-contents/index.js"],"names":[],"mappings":";AAmGA,yDAmCC"}
|
|
@@ -126,10 +126,10 @@ const WizardContents = props => {
|
|
|
126
126
|
className: style.container,
|
|
127
127
|
"data-name": "content-summary"
|
|
128
128
|
}, /*#__PURE__*/React.createElement("div", {
|
|
129
|
-
className: style.leftSection
|
|
129
|
+
className: summary ? style.leftSection : style.leftSectionWithoutSummary
|
|
130
130
|
}, headerView, /*#__PURE__*/React.createElement("div", {
|
|
131
131
|
className: style.form
|
|
132
|
-
}, formView)), /*#__PURE__*/React.createElement("div", {
|
|
132
|
+
}, formView)), summary ? /*#__PURE__*/React.createElement("div", {
|
|
133
133
|
className: style.rightSection,
|
|
134
134
|
"data-name": "summary-right-section"
|
|
135
135
|
}, /*#__PURE__*/React.createElement("div", {
|
|
@@ -139,7 +139,7 @@ const WizardContents = props => {
|
|
|
139
139
|
"data-name": "summary-zone"
|
|
140
140
|
}, /*#__PURE__*/React.createElement(WizardSummary, _extends({}, summary, {
|
|
141
141
|
side: 'right'
|
|
142
|
-
}))), rightActionView)), /*#__PURE__*/React.createElement("div", {
|
|
142
|
+
}))), rightActionView)) : null, summary ? /*#__PURE__*/React.createElement("div", {
|
|
143
143
|
className: style.footer,
|
|
144
144
|
"data-name": "summary-footer-section"
|
|
145
145
|
}, /*#__PURE__*/React.createElement("div", {
|
|
@@ -148,6 +148,11 @@ const WizardContents = props => {
|
|
|
148
148
|
side: 'footer'
|
|
149
149
|
}))), /*#__PURE__*/React.createElement("div", {
|
|
150
150
|
className: style.actionFooter
|
|
151
|
+
}, footerActionView)) : /*#__PURE__*/React.createElement("div", {
|
|
152
|
+
className: style.footerWithoutSummary,
|
|
153
|
+
"data-name": "footer-section"
|
|
154
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
155
|
+
className: style.actionFooterWithoutSummary
|
|
151
156
|
}, footerActionView)));
|
|
152
157
|
};
|
|
153
158
|
|
|
@@ -158,7 +163,7 @@ WizardContents.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
158
163
|
onClick: PropTypes.func
|
|
159
164
|
}).isRequired,
|
|
160
165
|
steps: WizardSteps.propTypes.steps,
|
|
161
|
-
summary: PropTypes.shape(_extends({}, WizardSummary.propTypes))
|
|
166
|
+
summary: PropTypes.shape(_extends({}, WizardSummary.propTypes)),
|
|
162
167
|
content: PropTypes.oneOfType([PropTypes.shape(_extends({}, BrandForm.propTypes, {
|
|
163
168
|
type: PropTypes.oneOf(['form'])
|
|
164
169
|
})), PropTypes.shape(_extends({}, ContentTranslate.propTypes, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["React","getOr","PropTypes","ButtonLink","ButtonLinkIconOnly","WizardSteps","WizardSummary","BrandForm","ContentTranslate","OrganismSearchAndChipsResults","CourseSelection","CourseSections","RewardsForm","style","buildHeader","wizardHeader","steps","title","onClick","buttonCloseIcon","size","icon","header","headerTitle","buildForm","content","type","buildButton","step","side","ICONS","previous","position","next","publish","label","buttonProps","buildActionZone","previousStep","nextStep","previousButton","nextStepType","nextButton","actionZone","button","WizardContents","props","isLoading","summary","headerView","formView","rightActionView","footerActionView","container","leftSection","form","rightSection","stickySection","summaryZone","footer","summaryFooter","actionFooter","propTypes","bool","shape","string","func","isRequired","oneOfType","oneOf"],"sources":["../../../src/organism/wizard-contents/index.js"],"sourcesContent":["import React from 'react';\nimport getOr from 'lodash/fp/getOr';\nimport PropTypes from 'prop-types';\nimport ButtonLink from '../../atom/button-link';\nimport ButtonLinkIconOnly from '../../atom/button-link-icon-only';\nimport WizardSteps from '../../atom/wizard-steps';\nimport WizardSummary from '../../molecule/wizard-summary';\nimport BrandForm from '../brand-form';\nimport ContentTranslate from '../content-translation';\nimport OrganismSearchAndChipsResults from '../search-and-chips-results';\nimport CourseSelection from '../course-selection';\nimport CourseSections from '../../molecule/course-sections';\nimport RewardsForm from '../rewards-form';\nimport style from './style.css';\n\nconst buildHeader = (wizardHeader, steps) => {\n const {title, onClick} = wizardHeader;\n\n const buttonCloseIcon = {\n size: 'small',\n 'data-name': 'close-button',\n 'aria-label': 'close button',\n icon: 'close',\n onClick\n };\n\n return (\n <div>\n <div className={style.header}>\n <ButtonLinkIconOnly {...buttonCloseIcon} />\n <div className={style.headerTitle} data-name={'content-title'}>\n {title}\n </div>\n </div>\n <WizardSteps steps={steps} />\n </div>\n );\n};\n\nconst buildForm = content => {\n const {type} = content;\n switch (type) {\n case 'form':\n return <BrandForm {...content} />;\n case 'translate':\n return <ContentTranslate {...content} />;\n case 'populations':\n return <OrganismSearchAndChipsResults {...content} />;\n case 'courses':\n return <CourseSelection {...content} />;\n case 'organize-courses':\n return <CourseSections {...content} />;\n case 'rewards':\n return <RewardsForm {...content} />;\n }\n};\n\nconst buildButton = (type, step, side) => {\n const ICONS = {\n previous: {\n position: 'left',\n type: 'chevron-left'\n },\n next: {\n position: 'right',\n type: 'chevron-right'\n },\n publish: {\n position: 'left',\n type: 'publish'\n }\n };\n\n const {label, onClick} = step;\n const buttonProps = {\n type: type === 'previous' ? 'secondary' : 'primary',\n 'aria-label': `${type} step button`,\n 'data-name': `${type}-step-button-${side}`,\n icon: ICONS[type],\n label,\n onClick\n };\n\n return <ButtonLink {...buttonProps} />;\n};\n\nconst buildActionZone = (previousStep, nextStep, side) => {\n const previousButton = previousStep ? buildButton('previous', previousStep, side) : null;\n const nextStepType = getOr('next', 'type', nextStep);\n const nextButton = nextStep ? buildButton(nextStepType, nextStep, side) : null;\n return (\n <div className={style.actionZone}>\n <div className={style.button}>{previousButton}</div>\n <div className={style.button}>{nextButton}</div>\n </div>\n );\n};\n\nconst WizardContents = props => {\n const {isLoading, wizardHeader, steps, summary, content, nextStep, previousStep} = props;\n const headerView = buildHeader(wizardHeader, steps);\n const formView = buildForm({...content, isLoading});\n const rightActionView = buildActionZone(previousStep, nextStep, 'right');\n const footerActionView = buildActionZone(previousStep, nextStep, 'footer');\n\n return (\n <div className={style.container} data-name=\"content-summary\">\n <div className={style.leftSection}>\n {headerView}\n <div className={style.form}>{formView}</div>\n </div>\n <div className={style.rightSection} data-name=\"summary-right-section\">\n <div className={style.stickySection}>\n <div className={style.summaryZone} data-name=\"summary-zone\">\n <WizardSummary {...summary} side={'right'} />\n </div>\n {rightActionView}\n </div>\n </div>\n <div className={style.footer} data-name=\"summary-footer-section\">\n <div className={style.summaryFooter}>\n <WizardSummary {...summary} side={'footer'} />\n </div>\n <div className={style.actionFooter}>{footerActionView}</div>\n </div>\n </div>\n );\n};\n\nWizardContents.propTypes = {\n isLoading: PropTypes.bool,\n wizardHeader: PropTypes.shape({\n title: PropTypes.string,\n onClick: PropTypes.func\n }).isRequired,\n steps: WizardSteps.propTypes.steps,\n summary: PropTypes.shape({\n ...WizardSummary.propTypes\n }).isRequired,\n content: PropTypes.oneOfType([\n PropTypes.shape({\n ...BrandForm.propTypes,\n type: PropTypes.oneOf(['form'])\n }),\n PropTypes.shape({\n ...ContentTranslate.propTypes,\n type: PropTypes.oneOf(['translate'])\n }),\n PropTypes.shape({\n ...OrganismSearchAndChipsResults.propTypes,\n type: PropTypes.oneOf(['populations'])\n }),\n PropTypes.shape({\n ...CourseSelection.propTypes,\n type: PropTypes.oneOf(['courses'])\n }),\n PropTypes.shape({\n ...CourseSections.propTypes,\n type: PropTypes.oneOf(['organize-courses'])\n }),\n PropTypes.shape({\n ...RewardsForm.propTypes,\n type: PropTypes.oneOf(['rewards'])\n })\n ]),\n previousStep: PropTypes.shape({\n label: PropTypes.string,\n onClick: PropTypes.func\n }),\n nextStep: PropTypes.shape({\n type: PropTypes.oneOf(['next', 'publish']),\n label: PropTypes.string,\n onClick: PropTypes.func\n })\n};\n\nexport default WizardContents;\n"],"mappings":";;AAAA,OAA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AC,SAAD,CAAhB;EAFR,GAb2B,EAiB3BnE,SAAS,CAAC8D,KAAV,cACKrD,cAAc,CAACmD,SADpB;IAEEpC,IAAI,EAAExB,SAAS,CAACmE,KAAV,CAAgB,CAAC,kBAAD,CAAhB;EAFR,GAjB2B,EAqB3BnE,SAAS,CAAC8D,KAAV,cACKpD,WAAW,CAACkD,SADjB;IAEEpC,IAAI,EAAExB,SAAS,CAACmE,KAAV,CAAgB,CAAC,SAAD,CAAhB;EAFR,GArB2B,CAApB,CAVgB;EAoCzB/B,YAAY,EAAEpC,SAAS,CAAC8D,KAAV,CAAgB;IAC5B7B,KAAK,EAAEjC,SAAS,CAAC+D,MADW;IAE5B/C,OAAO,EAAEhB,SAAS,CAACgE;EAFS,CAAhB,CApCW;EAwCzB3B,QAAQ,EAAErC,SAAS,CAAC8D,KAAV,CAAgB;IACxBtC,IAAI,EAAExB,SAAS,CAACmE,KAAV,CAAgB,CAAC,MAAD,EAAS,SAAT,CAAhB,CADkB;IAExBlC,KAAK,EAAEjC,SAAS,CAAC+D,MAFO;IAGxB/C,OAAO,EAAEhB,SAAS,CAACgE;EAHK,CAAhB;AAxCe,CAA3B;AA+CA,eAAerB,cAAf"}
|
|
1
|
+
{"version":3,"file":"index.js","names":["React","getOr","PropTypes","ButtonLink","ButtonLinkIconOnly","WizardSteps","WizardSummary","BrandForm","ContentTranslate","OrganismSearchAndChipsResults","CourseSelection","CourseSections","RewardsForm","style","buildHeader","wizardHeader","steps","title","onClick","buttonCloseIcon","size","icon","header","headerTitle","buildForm","content","type","buildButton","step","side","ICONS","previous","position","next","publish","label","buttonProps","buildActionZone","previousStep","nextStep","previousButton","nextStepType","nextButton","actionZone","button","WizardContents","props","isLoading","summary","headerView","formView","rightActionView","footerActionView","container","leftSection","leftSectionWithoutSummary","form","rightSection","stickySection","summaryZone","footer","summaryFooter","actionFooter","footerWithoutSummary","actionFooterWithoutSummary","propTypes","bool","shape","string","func","isRequired","oneOfType","oneOf"],"sources":["../../../src/organism/wizard-contents/index.js"],"sourcesContent":["import React from 'react';\nimport getOr from 'lodash/fp/getOr';\nimport PropTypes from 'prop-types';\nimport ButtonLink from '../../atom/button-link';\nimport ButtonLinkIconOnly from '../../atom/button-link-icon-only';\nimport WizardSteps from '../../atom/wizard-steps';\nimport WizardSummary from '../../molecule/wizard-summary';\nimport BrandForm from '../brand-form';\nimport ContentTranslate from '../content-translation';\nimport OrganismSearchAndChipsResults from '../search-and-chips-results';\nimport CourseSelection from '../course-selection';\nimport CourseSections from '../../molecule/course-sections';\nimport RewardsForm from '../rewards-form';\nimport style from './style.css';\nimport isEmpty from 'lodash/fp/isEmpty';\n\nconst buildHeader = (wizardHeader, steps) => {\n const {title, onClick} = wizardHeader;\n\n const buttonCloseIcon = {\n size: 'small',\n 'data-name': 'close-button',\n 'aria-label': 'close button',\n icon: 'close',\n onClick\n };\n\n return (\n <div>\n <div className={style.header}>\n <ButtonLinkIconOnly {...buttonCloseIcon} />\n <div className={style.headerTitle} data-name={'content-title'}>\n {title}\n </div>\n </div>\n <WizardSteps steps={steps} />\n </div>\n );\n};\n\nconst buildForm = content => {\n const {type} = content;\n switch (type) {\n case 'form':\n return <BrandForm {...content} />;\n case 'translate':\n return <ContentTranslate {...content} />;\n case 'populations':\n return <OrganismSearchAndChipsResults {...content} />;\n case 'courses':\n return <CourseSelection {...content} />;\n case 'organize-courses':\n return <CourseSections {...content} />;\n case 'rewards':\n return <RewardsForm {...content} />;\n }\n};\n\nconst buildButton = (type, step, side) => {\n const ICONS = {\n previous: {\n position: 'left',\n type: 'chevron-left'\n },\n next: {\n position: 'right',\n type: 'chevron-right'\n },\n publish: {\n position: 'left',\n type: 'publish'\n }\n };\n\n const {label, onClick} = step;\n const buttonProps = {\n type: type === 'previous' ? 'secondary' : 'primary',\n 'aria-label': `${type} step button`,\n 'data-name': `${type}-step-button-${side}`,\n icon: ICONS[type],\n label,\n onClick\n };\n\n return <ButtonLink {...buttonProps} />;\n};\n\nconst buildActionZone = (previousStep, nextStep, side) => {\n const previousButton = previousStep ? buildButton('previous', previousStep, side) : null;\n const nextStepType = getOr('next', 'type', nextStep);\n const nextButton = nextStep ? buildButton(nextStepType, nextStep, side) : null;\n return (\n <div className={style.actionZone}>\n <div className={style.button}>{previousButton}</div>\n <div className={style.button}>{nextButton}</div>\n </div>\n );\n};\n\nconst WizardContents = props => {\n const {isLoading, wizardHeader, steps, summary, content, nextStep, previousStep} = props;\n const headerView = buildHeader(wizardHeader, steps);\n const formView = buildForm({...content, isLoading});\n const rightActionView = buildActionZone(previousStep, nextStep, 'right');\n const footerActionView = buildActionZone(previousStep, nextStep, 'footer');\n\n\n return (\n <div className={style.container} data-name=\"content-summary\">\n <div className={summary ? style.leftSection: style.leftSectionWithoutSummary}>\n {headerView}\n <div className={style.form}>{formView}</div>\n </div>\n {summary ? (\n <div className={style.rightSection} data-name=\"summary-right-section\">\n <div className={style.stickySection}>\n <div className={style.summaryZone} data-name=\"summary-zone\">\n <WizardSummary {...summary} side={'right'} />\n </div>\n {rightActionView}\n </div>\n </div>\n ) : null}\n {summary ? ( <div className={style.footer} data-name=\"summary-footer-section\">\n <div className={style.summaryFooter}>\n <WizardSummary {...summary} side={'footer'} />\n </div>\n <div className={style.actionFooter}>{footerActionView}</div>\n </div>\n ) : ( <div className={style.footerWithoutSummary} data-name=\"footer-section\">\n <div className={style.actionFooterWithoutSummary}>{footerActionView}</div>\n </div>)}\n </div>\n );\n};\n\nWizardContents.propTypes = {\n isLoading: PropTypes.bool,\n wizardHeader: PropTypes.shape({\n title: PropTypes.string,\n onClick: PropTypes.func\n }).isRequired,\n steps: WizardSteps.propTypes.steps,\n summary: PropTypes.shape({\n ...WizardSummary.propTypes\n }),\n content: PropTypes.oneOfType([\n PropTypes.shape({\n ...BrandForm.propTypes,\n type: PropTypes.oneOf(['form'])\n }),\n PropTypes.shape({\n ...ContentTranslate.propTypes,\n type: PropTypes.oneOf(['translate'])\n }),\n PropTypes.shape({\n ...OrganismSearchAndChipsResults.propTypes,\n type: PropTypes.oneOf(['populations'])\n }),\n PropTypes.shape({\n ...CourseSelection.propTypes,\n type: PropTypes.oneOf(['courses'])\n }),\n PropTypes.shape({\n ...CourseSections.propTypes,\n type: PropTypes.oneOf(['organize-courses'])\n }),\n PropTypes.shape({\n ...RewardsForm.propTypes,\n type: PropTypes.oneOf(['rewards'])\n })\n ]),\n previousStep: PropTypes.shape({\n label: PropTypes.string,\n onClick: PropTypes.func\n }),\n nextStep: PropTypes.shape({\n type: PropTypes.oneOf(['next', 'publish']),\n label: PropTypes.string,\n onClick: PropTypes.func\n })\n};\n\nexport default WizardContents;\n"],"mappings":";;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,KAAP,MAAkB,iBAAlB;AACA,OAAOC,SAAP,MAAsB,YAAtB;AACA,OAAOC,UAAP,MAAuB,wBAAvB;AACA,OAAOC,kBAAP,MAA+B,kCAA/B;AACA,OAAOC,WAAP,MAAwB,yBAAxB;AACA,OAAOC,aAAP,MAA0B,+BAA1B;AACA,OAAOC,SAAP,MAAsB,eAAtB;AACA,OAAOC,gBAAP,MAA6B,wBAA7B;AACA,OAAOC,6BAAP,MAA0C,6BAA1C;AACA,OAAOC,eAAP,MAA4B,qBAA5B;AACA,OAAOC,cAAP,MAA2B,gCAA3B;AACA,OAAOC,WAAP,MAAwB,iBAAxB;AACA,OAAOC,KAAP,MAAkB,aAAlB;;AAGA,MAAMC,WAAW,GAAG,CAACC,YAAD,EAAeC,KAAf,KAAyB;EAC3C,MAAM;IAACC,KAAD;IAAQC;EAAR,IAAmBH,YAAzB;EAEA,MAAMI,eAAe,GAAG;IACtBC,IAAI,EAAE,OADgB;IAEtB,aAAa,cAFS;IAGtB,cAAc,cAHQ;IAItBC,IAAI,EAAE,OAJgB;IAKtBH;EALsB,CAAxB;EAQA,oBACE,8CACE;IAAK,SAAS,EAAEL,KAAK,CAACS;EAAtB,gBACE,oBAAC,kBAAD,EAAwBH,eAAxB,CADF,eAEE;IAAK,SAAS,EAA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KAAK,EAAEjC,SAAS,CAACkE,MAFO;IAGxBlD,OAAO,EAAEhB,SAAS,CAACmE;EAHK,CAAhB;AAxCe,CAA3B;AA+CA,eAAexB,cAAf"}
|
|
@@ -22,6 +22,15 @@
|
|
|
22
22
|
position: relative;
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
+
.leftSectionWithoutSummary {
|
|
26
|
+
display: block;
|
|
27
|
+
overflow: auto;
|
|
28
|
+
box-sizing: border-box;
|
|
29
|
+
width: 100%;
|
|
30
|
+
height: 100%;
|
|
31
|
+
position: relative;
|
|
32
|
+
}
|
|
33
|
+
|
|
25
34
|
.rightSection {
|
|
26
35
|
height: 100%;
|
|
27
36
|
padding-bottom: 58px;
|
|
@@ -69,12 +78,22 @@
|
|
|
69
78
|
.actionZone {
|
|
70
79
|
width: 100%;
|
|
71
80
|
display: flex;
|
|
72
|
-
justify-content:
|
|
81
|
+
justify-content: center;
|
|
73
82
|
margin: 16px 0;
|
|
83
|
+
flex-wrap: wrap;
|
|
74
84
|
}
|
|
75
85
|
|
|
76
86
|
.button {
|
|
77
|
-
width:
|
|
87
|
+
width: 100%;
|
|
88
|
+
max-width: 184px;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
.footerWithoutSummary {
|
|
92
|
+
width: 100%;
|
|
93
|
+
bottom: 0px;
|
|
94
|
+
position: inherit;
|
|
95
|
+
display: flex;
|
|
96
|
+
justify-content: flex-end;
|
|
78
97
|
}
|
|
79
98
|
|
|
80
99
|
.footer {
|
|
@@ -84,6 +103,16 @@
|
|
|
84
103
|
position: inherit;
|
|
85
104
|
}
|
|
86
105
|
|
|
106
|
+
.actionFooterWithoutSummary {
|
|
107
|
+
width: 100%;
|
|
108
|
+
display: flex;
|
|
109
|
+
right: 0;
|
|
110
|
+
max-width: 184px;
|
|
111
|
+
bottom: -10px;
|
|
112
|
+
position: sticky;
|
|
113
|
+
position: absolute;
|
|
114
|
+
}
|
|
115
|
+
|
|
87
116
|
@media desktop, tablet {
|
|
88
117
|
.leftSection {
|
|
89
118
|
width: 100%;
|
|
@@ -94,13 +123,14 @@
|
|
|
94
123
|
display: none;
|
|
95
124
|
}
|
|
96
125
|
|
|
97
|
-
.footer
|
|
126
|
+
.footer {
|
|
98
127
|
display: flex;
|
|
99
128
|
align-items: flex-end;
|
|
100
129
|
bottom: 10px;
|
|
101
130
|
position: sticky;
|
|
102
131
|
z-index: 1;
|
|
103
132
|
}
|
|
133
|
+
|
|
104
134
|
.footer::before {
|
|
105
135
|
content: '';
|
|
106
136
|
background: linear-gradient(to top,white 64px, #ffffff00 );
|
|
@@ -118,8 +148,10 @@
|
|
|
118
148
|
}
|
|
119
149
|
|
|
120
150
|
.actionFooter {
|
|
121
|
-
width:
|
|
151
|
+
max-width: 184px;
|
|
152
|
+
width: 100%;
|
|
122
153
|
}
|
|
154
|
+
|
|
123
155
|
.actionZone {
|
|
124
156
|
margin: 0;
|
|
125
157
|
}
|
|
@@ -21,10 +21,6 @@
|
|
|
21
21
|
|
|
22
22
|
user-select: none;
|
|
23
23
|
position: relative;
|
|
24
|
-
border-bottom: none;
|
|
25
|
-
border-right: 0px;
|
|
26
|
-
border-width: 1px 0 0 1px;
|
|
27
|
-
background: inherit;
|
|
28
24
|
}
|
|
29
25
|
|
|
30
26
|
.engineIcon {
|
|
@@ -160,22 +156,28 @@
|
|
|
160
156
|
opacity: 0.4;
|
|
161
157
|
}
|
|
162
158
|
|
|
163
|
-
.
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
159
|
+
.toolTip {
|
|
160
|
+
opacity: 1 !important;
|
|
161
|
+
padding: 0;
|
|
162
|
+
pointer-events: all;
|
|
163
|
+
background-color: transparent !important;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
.toolTip::after {
|
|
167
|
+
border-left-color: transparent !important;
|
|
167
168
|
}
|
|
168
169
|
|
|
169
170
|
.toolTipContent {
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
font-weight: 500;
|
|
173
|
-
font-size: 14px;
|
|
174
|
-
display: inline-block;
|
|
171
|
+
padding: 10px;
|
|
172
|
+
margin: 0;
|
|
175
173
|
border-radius: 3px;
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
174
|
+
font-family: 'Gilroy';
|
|
175
|
+
font-size: 12px;
|
|
176
|
+
width: 270px;
|
|
177
|
+
background-color: white;
|
|
178
|
+
border: 1px solid white;
|
|
179
|
+
color: dark;
|
|
180
|
+
box-shadow: 0 3px 6px rgba(0, 0, 0, 0.16), 8px 3px 10px rgba(0, 0, 0, 0.23);
|
|
179
181
|
}
|
|
180
182
|
|
|
181
183
|
.toolTipContent > a {
|
|
@@ -189,6 +191,21 @@
|
|
|
189
191
|
text-decoration: underline;
|
|
190
192
|
}
|
|
191
193
|
|
|
194
|
+
.toolTipContent::after {
|
|
195
|
+
content: '';
|
|
196
|
+
width: 0;
|
|
197
|
+
height: 0;
|
|
198
|
+
position: absolute;
|
|
199
|
+
border-left-color: inherit;
|
|
200
|
+
border-left-style: solid;
|
|
201
|
+
border-left-width: 6px;
|
|
202
|
+
border-top: 5px solid transparent;
|
|
203
|
+
border-bottom: 5px solid transparent;
|
|
204
|
+
right: -6px;
|
|
205
|
+
top: 50%;
|
|
206
|
+
margin-top: -4px;
|
|
207
|
+
}
|
|
208
|
+
|
|
192
209
|
/* ------------------------------------------------------ */
|
|
193
210
|
|
|
194
211
|
@media tablet, mobile {
|
|
@@ -1,23 +1,21 @@
|
|
|
1
1
|
export default EngineStars;
|
|
2
|
-
declare
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
const className: PropTypes.Requireable<string>;
|
|
12
|
-
const toolTip: PropTypes.Requireable<PropTypes.InferProps<{
|
|
2
|
+
declare class EngineStars extends React.Component<any, any, any> {
|
|
3
|
+
static propTypes: {
|
|
4
|
+
type: PropTypes.Validator<string>;
|
|
5
|
+
stars: PropTypes.Validator<number>;
|
|
6
|
+
title: PropTypes.Validator<string>;
|
|
7
|
+
active: PropTypes.Requireable<boolean>;
|
|
8
|
+
disabled: PropTypes.Requireable<boolean>;
|
|
9
|
+
onClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
10
|
+
toolTip: PropTypes.Requireable<PropTypes.InferProps<{
|
|
13
11
|
preMessage: PropTypes.Requireable<string>;
|
|
14
12
|
linkMessage: PropTypes.Requireable<string>;
|
|
15
13
|
endMessage: PropTypes.Requireable<string>;
|
|
16
14
|
onClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
17
15
|
}>>;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
|
|
16
|
+
};
|
|
17
|
+
static contextTypes: {
|
|
18
|
+
skin: PropTypes.Requireable<PropTypes.InferProps<{
|
|
21
19
|
common: PropTypes.Requireable<{
|
|
22
20
|
[x: string]: any;
|
|
23
21
|
}>;
|
|
@@ -38,7 +36,11 @@ declare namespace EngineStars {
|
|
|
38
36
|
[x: string]: any;
|
|
39
37
|
}>;
|
|
40
38
|
}>>;
|
|
41
|
-
}
|
|
39
|
+
};
|
|
40
|
+
constructor(props: any, context: any);
|
|
41
|
+
handleClick: (e: any) => void;
|
|
42
|
+
render(): JSX.Element;
|
|
42
43
|
}
|
|
44
|
+
import React from "react";
|
|
43
45
|
import PropTypes from "prop-types";
|
|
44
46
|
//# sourceMappingURL=engine-stars.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"engine-stars.d.ts","sourceRoot":"","sources":["../../../src/template/activity/engine-stars.js"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"engine-stars.d.ts","sourceRoot":"","sources":["../../../src/template/activity/engine-stars.js"],"names":[],"mappings":";AAqFA;IACE;;;;;;;;;;;;;MAaE;IAEF;;;;;;;;;;;;;;;;;;;;;;MAEE;IAEF,sCAGC;IAED,8BAKE;IAEF,sBAqDC;CACF"}
|