@coorpacademy/components 10.3.5 → 10.3.9
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/input-textarea/index.js +2 -2
- package/es/atom/input-textarea/index.js.map +1 -1
- package/es/atom/input-textarea/test/on-change.js +2 -2
- package/es/atom/input-textarea/test/on-change.js.map +1 -1
- package/es/atom/provider/index.js +4 -0
- package/es/atom/provider/index.js.map +1 -1
- package/es/atom/radio-group/index.js +11 -2
- package/es/atom/radio-group/index.js.map +1 -1
- package/es/atom/radio-group/item.css +48 -1
- package/es/atom/radio-group/item.js +12 -3
- package/es/atom/radio-group/item.js.map +1 -1
- package/es/atom/radio-group/style.css +9 -1
- package/es/molecule/banner/index.js +4 -1
- package/es/molecule/banner/index.js.map +1 -1
- package/es/molecule/banner/test/fixtures/error-temporary-banner.js +1 -0
- package/es/molecule/banner/test/fixtures/error-temporary-banner.js.map +1 -1
- package/es/molecule/banner/test/fixtures/success-temporary-banner.js +1 -0
- package/es/molecule/banner/test/fixtures/success-temporary-banner.js.map +1 -1
- package/es/molecule/banner/test/fixtures/warning-temporary-banner.js +1 -0
- package/es/molecule/banner/test/fixtures/warning-temporary-banner.js.map +1 -1
- package/es/molecule/bullet-point-menu-button/style.css +0 -1
- package/es/organism/content-translation/index.js +2 -2
- package/es/organism/content-translation/index.js.map +1 -1
- package/es/organism/content-translation/test/fixtures/delete.js +1 -1
- package/es/organism/content-translation/test/fixtures/delete.js.map +1 -1
- package/es/organism/playlist-translation/test/fixtures.js +15 -0
- package/es/organism/playlist-translation/test/fixtures.js.map +1 -0
- package/es/template/back-office/brand-list/index.js +7 -2
- package/es/template/back-office/brand-list/index.js.map +1 -1
- package/es/template/back-office/brand-list/style.css +13 -0
- package/es/template/back-office/brand-list/test/fixtures/default.js +15 -0
- package/es/template/back-office/brand-list/test/fixtures/default.js.map +1 -1
- package/es/template/back-office/brand-update/test/fixtures.js +0 -4
- package/es/template/back-office/brand-update/test/fixtures.js.map +1 -1
- package/lib/atom/input-textarea/index.js +2 -2
- package/lib/atom/input-textarea/index.js.map +1 -1
- package/lib/atom/input-textarea/test/on-change.js +2 -2
- package/lib/atom/input-textarea/test/on-change.js.map +1 -1
- package/lib/atom/provider/index.js +4 -0
- package/lib/atom/provider/index.js.map +1 -1
- package/lib/atom/radio-group/index.js +11 -2
- package/lib/atom/radio-group/index.js.map +1 -1
- package/lib/atom/radio-group/item.css +48 -1
- package/lib/atom/radio-group/item.js +13 -3
- package/lib/atom/radio-group/item.js.map +1 -1
- package/lib/atom/radio-group/style.css +9 -1
- package/lib/molecule/banner/index.js +4 -1
- package/lib/molecule/banner/index.js.map +1 -1
- package/lib/molecule/banner/test/fixtures/error-temporary-banner.js +1 -0
- package/lib/molecule/banner/test/fixtures/error-temporary-banner.js.map +1 -1
- package/lib/molecule/banner/test/fixtures/success-temporary-banner.js +1 -0
- package/lib/molecule/banner/test/fixtures/success-temporary-banner.js.map +1 -1
- package/lib/molecule/banner/test/fixtures/warning-temporary-banner.js +1 -0
- package/lib/molecule/banner/test/fixtures/warning-temporary-banner.js.map +1 -1
- package/lib/molecule/bullet-point-menu-button/style.css +0 -1
- package/lib/organism/content-translation/index.js +2 -2
- package/lib/organism/content-translation/index.js.map +1 -1
- package/lib/organism/content-translation/test/fixtures/delete.js +1 -1
- package/lib/organism/content-translation/test/fixtures/delete.js.map +1 -1
- package/lib/organism/playlist-translation/test/fixtures.js +25 -0
- package/lib/organism/playlist-translation/test/fixtures.js.map +1 -0
- package/lib/template/back-office/brand-list/index.js +8 -2
- package/lib/template/back-office/brand-list/index.js.map +1 -1
- package/lib/template/back-office/brand-list/style.css +13 -0
- package/lib/template/back-office/brand-list/test/fixtures/default.js +15 -0
- package/lib/template/back-office/brand-list/test/fixtures/default.js.map +1 -1
- package/lib/template/back-office/brand-update/test/fixtures.js +0 -6
- package/lib/template/back-office/brand-update/test/fixtures.js.map +1 -1
- package/locales/hr/global.json +2 -2
- package/package.json +2 -2
- package/es/molecule/cockpit-popin/test/fixtures.js +0 -17
- package/es/molecule/cockpit-popin/test/fixtures.js.map +0 -1
- package/es/molecule/search/test/fixtures.js +0 -15
- package/es/molecule/search/test/fixtures.js.map +0 -1
- package/lib/molecule/cockpit-popin/test/fixtures.js +0 -28
- package/lib/molecule/cockpit-popin/test/fixtures.js.map +0 -1
- package/lib/molecule/search/test/fixtures.js +0 -25
- package/lib/molecule/search/test/fixtures.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/template/back-office/brand-list/index.js"],"names":["React","PropTypes","GridList","BrandCard","BrandCardCreate","Search","Layout","style","BrandList","props","brands","create","search","brandCards","map","brand","index","title","push","container","searchBar","wrapper","propTypes","arrayOf","shape"],"mappings":";;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,SAAP,MAAsB,YAAtB;AACA,OAAOC,QAAP,MAAqB,6BAArB;AACA,OAAOC,SAAP,MAAsB,8BAAtB;AACA,OAAOC,eAAP,MAA4B,qCAA5B;AACA,OAAOC,MAAP,MAAmB,4BAAnB;AACA,OAAOC,MAAP,MAAmB,WAAnB;AACA,OAAOC,KAAP,MAAkB,aAAlB;AAEA,MAAMC,SAAS,GAAGF,MAAM,CAACG,KAAK,IAAI;AAChC,QAAM;AAACC,IAAAA,MAAM,GAAG,EAAV;AAAcC,IAAAA,MAAd;AAAsBC,IAAAA;
|
|
1
|
+
{"version":3,"sources":["../../../../src/template/back-office/brand-list/index.js"],"names":["React","PropTypes","GridList","BrandCard","BrandCardCreate","Search","RadioGroup","Layout","style","BrandList","props","brands","create","search","filter","brandCards","map","brand","index","title","push","container","filterBar","searchBar","wrapper","propTypes","arrayOf","shape"],"mappings":";;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,SAAP,MAAsB,YAAtB;AACA,OAAOC,QAAP,MAAqB,6BAArB;AACA,OAAOC,SAAP,MAAsB,8BAAtB;AACA,OAAOC,eAAP,MAA4B,qC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EV,SAAS,CAACyB,OAAV,CAAkBzB,SAAS,CAAC0B,KAAV,CAAgBxB,SAAS,CAACsB,SAA1B,CAAlB,CADY;AAEpBX,EAAAA,MAAM,EAAEb,SAAS,CAAC0B,KAAV,CAAgBrB,UAAU,CAACmB,SAA3B,CAFY;AAGpBZ,EAAAA,MAAM,EAAEZ,SAAS,CAAC0B,KAAV,CAAgBtB,MAAM,CAACoB,SAAvB,CAHY;AAIpBb,EAAAA,MAAM,EAAEX,SAAS,CAAC0B,KAAV,CAAgBvB,eAAe,CAACqB,SAAhC;AAJY,CAAtB;AAOA,eAAehB,SAAf","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport GridList from '../../../organism/grid-list';\nimport BrandCard from '../../../molecule/brand-card';\nimport BrandCardCreate from '../../../molecule/brand-card-create';\nimport Search from '../../../atom/input-search';\nimport RadioGroup from '../../../atom/radio-group';\nimport Layout from '../layout';\nimport style from './style.css';\n\nconst BrandList = Layout(props => {\n const {brands = [], create, search, filter} = props;\n\n const brandCards = brands.map((brand, index) => {\n return (\n <div key={brand.title} className={style.brand}>\n <BrandCard {...brand} />\n </div>\n );\n });\n\n if (create) {\n brandCards.push(\n <div key=\"new\" className={style.brand}>\n <BrandCardCreate {...create} />\n </div>\n );\n }\n\n return (\n <div className={style.container}>\n {filter ? (\n <div className={style.filterBar}>\n <RadioGroup {...filter} />\n </div>\n ) : null}\n <div className={style.searchBar}>\n <Search {...search} theme=\"coorpmanager\" />\n </div>\n <div className={style.wrapper}>\n <GridList>{brandCards}</GridList>\n </div>\n </div>\n );\n});\n\nBrandList.propTypes = {\n brands: PropTypes.arrayOf(PropTypes.shape(BrandCard.propTypes)),\n filter: PropTypes.shape(RadioGroup.propTypes),\n search: PropTypes.shape(Search.propTypes),\n create: PropTypes.shape(BrandCardCreate.propTypes)\n};\n\nexport default BrandList;\n"],"file":"index.js"}
|
|
@@ -30,6 +30,13 @@
|
|
|
30
30
|
border-radius: 2px;
|
|
31
31
|
}
|
|
32
32
|
|
|
33
|
+
.filterBar {
|
|
34
|
+
width: 400px;
|
|
35
|
+
margin: auto;
|
|
36
|
+
padding-bottom: 20px;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
|
|
33
40
|
@media desktop {
|
|
34
41
|
.wrapper {
|
|
35
42
|
width: 960px;
|
|
@@ -50,6 +57,12 @@
|
|
|
50
57
|
margin: 0 30px;
|
|
51
58
|
box-sizing: content-box;
|
|
52
59
|
}
|
|
60
|
+
|
|
61
|
+
.filterBar {
|
|
62
|
+
width: auto;
|
|
63
|
+
margin: 0 30px;
|
|
64
|
+
box-sizing: content-box;
|
|
65
|
+
}
|
|
53
66
|
}
|
|
54
67
|
|
|
55
68
|
@media mobile {
|
|
@@ -16,6 +16,21 @@ export default {
|
|
|
16
16
|
placeholder: 'Search brand',
|
|
17
17
|
onChange: () => {}
|
|
18
18
|
},
|
|
19
|
+
filter: {
|
|
20
|
+
list: [{
|
|
21
|
+
name: 'customer',
|
|
22
|
+
value: 'customer',
|
|
23
|
+
checked: false,
|
|
24
|
+
label: 'Customer platforms'
|
|
25
|
+
}, {
|
|
26
|
+
name: 'team',
|
|
27
|
+
value: 'team',
|
|
28
|
+
checked: true,
|
|
29
|
+
label: 'Team platforms'
|
|
30
|
+
}],
|
|
31
|
+
theme: 'coorpmanager',
|
|
32
|
+
onChange: value => console.log(value)
|
|
33
|
+
},
|
|
19
34
|
create: {
|
|
20
35
|
edit: 'Create a new platform',
|
|
21
36
|
editHref: '#'
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../src/template/back-office/brand-list/test/fixtures/default.js"],"names":["BrandCard","Header","props","header","isHome","brands","search","value","placeholder","onChange","create","edit","editHref"],"mappings":";;AAAA,OAAOA,SAAP,MAAsB,0DAAtB;AACA,OAAOC,MAAP,MAAmB,4DAAnB;AAEA,MAAM;AAACC,EAAAA;AAAD,IAAUF,SAAhB;AAEA,eAAe;AACbE,EAAAA,KAAK,EAAE;AACLC,IAAAA,MAAM,wBAAMF,MAAM,CAACC,KAAb;AAAoBE,MAAAA,MAAM,EAAE;AAA5B,MADD;AAELC,IAAAA,MAAM,EAAE,CAACH,KAAD,EAAQA,KAAR,EAAeA,KAAf,EAAsBA,KAAtB,EAA6BA,KAA7B,CAFH;AAGLI,IAAAA,MAAM,EAAE;AACNC,MAAAA,KAAK,EAAE,EADD;AAENC,MAAAA,WAAW,EAAE,cAFP;AAGNC,MAAAA,QAAQ,EAAE,MAAM,CAAE;AAHZ,KAHH;AAQLC,IAAAA,MAAM,EAAE;AACNC,MAAAA,IAAI,EAAE,uBADA;AAENC,MAAAA,QAAQ,EAAE;AAFJ;
|
|
1
|
+
{"version":3,"sources":["../../../../../../src/template/back-office/brand-list/test/fixtures/default.js"],"names":["BrandCard","Header","props","header","isHome","brands","search","value","placeholder","onChange","filter","list","name","checked","label","theme","console","log","create","edit","editHref"],"mappings":";;AAAA,OAAOA,SAAP,MAAsB,0DAAtB;AACA,OAAOC,MAAP,MAAmB,4DAAnB;AAEA,MAAM;AAACC,EAAAA;AAAD,IAAUF,SAAhB;AAEA,eAAe;AACbE,EAAAA,KAAK,EAAE;AACLC,IAAAA,MAAM,wBAAMF,MAAM,CAACC,KAAb;AAAoBE,MAAAA,MAAM,EAAE;AAA5B,MADD;AAELC,IAAAA,MAAM,EAAE,CAACH,KAAD,EAAQA,KAAR,EAAeA,KAAf,EAAsBA,KAAtB,EAA6BA,KAA7B,CAFH;AAGLI,IAAAA,MAAM,EAAE;AACNC,MAAAA,KAAK,EAAE,EADD;AAENC,MAAAA,WAAW,EAAE,cAFP;AAGNC,MAAAA,QAAQ,EAAE,MAAM,CAAE;AAHZ,KAHH;AAQLC,IAAAA,MAAM,EAAE;AACNC,MAAAA,IAAI,EAAE,CACJ;AACEC,QAAAA,IAAI,EAAE,UADR;AAEEL,QAAAA,KAAK,EAAE,UAFT;AAGEM,QAAAA,OAAO,EAAE,KAHX;AAIEC,QAAAA,KAAK,EAAE;AAJT,OADI,EAOJ;AACEF,QAAAA,IAAI,EAAE,MADR;AAEEL,QAAAA,KAAK,EAAE,MAFT;AAGEM,QAAAA,OAAO,EAAE,IAHX;AAIEC,QAAAA,KAAK,EAAE;AAJT,OAPI,CADA;AAeNC,MAAAA,KAAK,EAAE,cAfD;AAgBNN,MAAAA,QAAQ,EAAEF,KAAK,IAAIS,OAAO,CAACC,GAAR,CAAYV,KAAZ;AAhBb,KARH;AA0BLW,IAAAA,MAAM,EAAE;AACNC,MAAAA,IAAI,EAAE,uBADA;AAENC,MAAAA,QAAQ,EAAE;AAFJ;AA1BH;AADM,CAAf","sourcesContent":["import BrandCard from '../../../../../molecule/brand-card/test/fixtures/default';\nimport Header from '../../../../../organism/setup-header/test/fixtures/default';\n\nconst {props} = BrandCard;\n\nexport default {\n props: {\n header: {...Header.props, isHome: true},\n brands: [props, props, props, props, props],\n search: {\n value: '',\n placeholder: 'Search brand',\n onChange: () => {}\n },\n filter: {\n list: [\n {\n name: 'customer',\n value: 'customer',\n checked: false,\n label: 'Customer platforms'\n },\n {\n name: 'team',\n value: 'team',\n checked: true,\n label: 'Team platforms'\n }\n ],\n theme: 'coorpmanager',\n onChange: value => console.log(value)\n },\n create: {\n edit: 'Create a new platform',\n editHref: '#'\n }\n }\n};\n"],"file":"default.js"}
|
|
@@ -13,7 +13,6 @@ import fixtureGeneralSettingsSuccess from './fixtures/general-settings-success';
|
|
|
13
13
|
import fixtureGeneralSettings from './fixtures/general-settings';
|
|
14
14
|
import fixtureListItemsArchived from './fixtures/list-items-archived';
|
|
15
15
|
import fixtureListItemsDraft from './fixtures/list-items-draft';
|
|
16
|
-
import fixtureListItemsPublishedWithPopin from './fixtures/list-items-published-with-popin';
|
|
17
16
|
import fixtureListItemsPublished from './fixtures/list-items-published';
|
|
18
17
|
import fixtureLmsError from './fixtures/lms-error';
|
|
19
18
|
import fixtureLmsModified from './fixtures/lms-modified';
|
|
@@ -36,7 +35,6 @@ import fixtureUploadusers from './fixtures/uploadusers';
|
|
|
36
35
|
import fixtureWizardAddCoursesPlaylist from './fixtures/wizard-add-courses-playlist';
|
|
37
36
|
import fixtureWizardFormCreatePlaylist from './fixtures/wizard-form-create-playlist';
|
|
38
37
|
import fixtureWizardFormEditPlaylist from './fixtures/wizard-form-edit-playlist';
|
|
39
|
-
import fixtureWizardPopulationsPlaylistWithPopin from './fixtures/wizard-populations-playlist-with-popin';
|
|
40
38
|
import fixtureWizardPopulationsPlaylist from './fixtures/wizard-populations-playlist';
|
|
41
39
|
import fixtureWizardTranslatePlaylist from './fixtures/wizard-translate-playlist';
|
|
42
40
|
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate > should have valid propTypes', t => {
|
|
@@ -56,7 +54,6 @@ test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › GeneralSettingsSu
|
|
|
56
54
|
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › GeneralSettings › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureGeneralSettings);
|
|
57
55
|
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ListItemsArchived › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureListItemsArchived);
|
|
58
56
|
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ListItemsDraft › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureListItemsDraft);
|
|
59
|
-
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ListItemsPublishedWithPopin › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureListItemsPublishedWithPopin);
|
|
60
57
|
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ListItemsPublished › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureListItemsPublished);
|
|
61
58
|
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LmsError › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLmsError);
|
|
62
59
|
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LmsModified › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLmsModified);
|
|
@@ -79,7 +76,6 @@ test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Uploadusers › s
|
|
|
79
76
|
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardAddCoursesPlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardAddCoursesPlaylist);
|
|
80
77
|
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardFormCreatePlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardFormCreatePlaylist);
|
|
81
78
|
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardFormEditPlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardFormEditPlaylist);
|
|
82
|
-
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardPopulationsPlaylistWithPopin › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardPopulationsPlaylistWithPopin);
|
|
83
79
|
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardPopulationsPlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardPopulationsPlaylist);
|
|
84
80
|
test('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardTranslatePlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardTranslatePlaylist);
|
|
85
81
|
//# sourceMappingURL=fixtures.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../src/template/back-office/brand-update/test/fixtures.js"],"names":["test","forEach","renderComponentMacro","TemplateBackOfficeBrandUpdate","fixtureAnalytics","fixtureAnimations","fixtureCohortError","fixtureCohort","fixtureDashboard","fixtureDashboardsAnalytics","fixtureDefault","fixtureGeneralSettingsSuccess","fixtureGeneralSettings","fixtureListItemsArchived","fixtureListItemsDraft","fixtureListItemsPublishedWithPopin","fixtureListItemsPublished","fixtureLmsError","fixtureLmsModified","fixtureLmsSuccess","fixtureLms","fixtureLoader","fixtureLookandfeelError","fixtureLookandfeelModified","fixtureLookandfeelPending","fixtureLookandfeelSuccess","fixtureLookandfeel","fixtureManageusersEdit","fixtureManageusersList","fixtureQuickAccess","fixtureSsoActivate","fixtureSso","fixtureUploadusersLoading","fixtureUploadusersSuccessful","fixtureUploadusers","fixtureWizardAddCoursesPlaylist","fixtureWizardFormCreatePlaylist","fixtureWizardFormEditPlaylist","fixtureWizardPopulationsPlaylistWithPopin","fixtureWizardPopulationsPlaylist","fixtureWizardTranslatePlaylist","t","pass","propTypes","value","key","not","undefined"],"mappings":"AAAA,OAAOA,IAAP,MAAiB,KAAjB;AACA,OAAOC,OAAP,MAAoB,gBAApB;AACA,OAAOC,oBAAP,MAAiC,2CAAjC;AACA,OAAOC,6BAAP,MAA0C,IAA1C;AACA,OAAOC,gBAAP,MAA6B,sBAA7B;AACA,OAAOC,iBAAP,MAA8B,uBAA9B;AACA,OAAOC,kBAAP,MAA+B,yBAA/B;AACA,OAAOC,aAAP,MAA0B,mBAA1B;AACA,OAAOC,gBAAP,MAA6B,sBAA7B;AACA,OAAOC,0BAAP,MAAuC,iCAAvC;AACA,OAAOC,cAAP,MAA2B,oBAA3B;AACA,OAAOC,6BAAP,MAA0C,qCAA1C;AACA,OAAOC,sBAAP,MAAmC,6BAAnC;AACA,OAAOC,wBAAP,MAAqC,gCAArC;AACA,OAAOC,qBAAP,MAAkC,6BAAlC;AACA,OAAOC,kCAAP,MAA+C,4CAA/C;AACA,OAAOC,yBAAP,MAAsC,iCAAtC;AACA,OAAOC,eAAP,MAA4B,sBAA5B;AACA,OAAOC,kBAAP,MAA+B,yBAA/B;AACA,OAAOC,iBAAP,MAA8B,wBAA9B;AACA,OAAOC,UAAP,MAAuB,gBAAvB;AACA,OAAOC,aAAP,MAA0B,mBAA1B;AACA,OAAOC,uBAAP,MAAoC,8BAApC;AACA,OAAOC,0BAA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;AACApC,IAAI,CAAC,kGAAD,EAAqGE,oBAArG,EAA2HC,6BAA3H,EAA0JkC,6BAA1J,CAAJ;AACArC,IAAI,CAAC,8GAAD,EAAiHE,oBAAjH,EAAuIC,6BAAvI,EAAsKmC,yCAAtK,CAAJ;AACAtC,IAAI,CAAC,qGAAD,EAAwGE,oBAAxG,EAA8HC,6BAA9H,EAA6JoC,gCAA7J,CAAJ;AACAvC,IAAI,CAAC,mGAAD,EAAsGE,oBAAtG,EAA4HC,6BAA5H,EAA2JqC,8BAA3J,CAAJ","sourcesContent":["import test from 'ava';\nimport forEach from 'lodash/forEach';\nimport renderComponentMacro from '../../../../test/helpers/render-component';\nimport TemplateBackOfficeBrandUpdate from '..';\nimport fixtureAnalytics from './fixtures/analytics';\nimport fixtureAnimations from './fixtures/animations';\nimport fixtureCohortError from './fixtures/cohort-error';\nimport fixtureCohort from './fixtures/cohort';\nimport fixtureDashboard from './fixtures/dashboard';\nimport fixtureDashboardsAnalytics from './fixtures/dashboards-analytics';\nimport fixtureDefault from './fixtures/default';\nimport fixtureGeneralSettingsSuccess from './fixtures/general-settings-success';\nimport fixtureGeneralSettings from './fixtures/general-settings';\nimport fixtureListItemsArchived from './fixtures/list-items-archived';\nimport fixtureListItemsDraft from './fixtures/list-items-draft';\nimport fixtureListItemsPublishedWithPopin from './fixtures/list-items-published-with-popin';\nimport fixtureListItemsPublished from './fixtures/list-items-published';\nimport fixtureLmsError from './fixtures/lms-error';\nimport fixtureLmsModified from './fixtures/lms-modified';\nimport fixtureLmsSuccess from './fixtures/lms-success';\nimport fixtureLms from './fixtures/lms';\nimport fixtureLoader from './fixtures/loader';\nimport fixtureLookandfeelError from './fixtures/lookandfeel-error';\nimport fixtureLookandfeelModified from './fixtures/lookandfeel-modified';\nimport fixtureLookandfeelPending from './fixtures/lookandfeel-pending';\nimport fixtureLookandfeelSuccess from './fixtures/lookandfeel-success';\nimport fixtureLookandfeel from './fixtures/lookandfeel';\nimport fixtureManageusersEdit from './fixtures/manageusers-edit';\nimport fixtureManageusersList from './fixtures/manageusers-list';\nimport fixtureQuickAccess from './fixtures/quick-access';\nimport fixtureSsoActivate from './fixtures/sso-activate';\nimport fixtureSso from './fixtures/sso';\nimport fixtureUploadusersLoading from './fixtures/uploadusers-loading';\nimport fixtureUploadusersSuccessful from './fixtures/uploadusers-successful';\nimport fixtureUploadusers from './fixtures/uploadusers';\nimport fixtureWizardAddCoursesPlaylist from './fixtures/wizard-add-courses-playlist';\nimport fixtureWizardFormCreatePlaylist from './fixtures/wizard-form-create-playlist';\nimport fixtureWizardFormEditPlaylist from './fixtures/wizard-form-edit-playlist';\nimport fixtureWizardPopulationsPlaylistWithPopin from './fixtures/wizard-populations-playlist-with-popin';\nimport fixtureWizardPopulationsPlaylist from './fixtures/wizard-populations-playlist';\nimport fixtureWizardTranslatePlaylist from './fixtures/wizard-translate-playlist';\n\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate > should have valid propTypes', t => {\n t.pass();\n forEach(TemplateBackOfficeBrandUpdate.propTypes, (value, key) => {\n t.not(value, undefined, `PropType for \"TemplateBackOffice.TemplateBackOfficeBrandUpdate.propTypes.${key}\" may not be undefined. Did you mistype the propTypes definition?`);\n });\n});\n\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Analytics › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureAnalytics);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Animations › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureAnimations);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › CohortError › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureCohortError);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Cohort › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureCohort);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Dashboard › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureDashboard);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › DashboardsAnalytics › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureDashboardsAnalytics);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Default › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureDefault);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › GeneralSettingsSuccess › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureGeneralSettingsSuccess);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › GeneralSettings › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureGeneralSettings);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ListItemsArchived › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureListItemsArchived);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ListItemsDraft › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureListItemsDraft);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ListItemsPublishedWithPopin › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureListItemsPublishedWithPopin);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ListItemsPublished › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureListItemsPublished);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LmsError › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLmsError);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LmsModified › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLmsModified);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LmsSuccess › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLmsSuccess);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Lms › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLms);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Loader › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLoader);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LookandfeelError › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLookandfeelError);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LookandfeelModified › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLookandfeelModified);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LookandfeelPending › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLookandfeelPending);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LookandfeelSuccess › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLookandfeelSuccess);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Lookandfeel › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLookandfeel);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ManageusersEdit › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureManageusersEdit);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ManageusersList › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureManageusersList);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › QuickAccess › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureQuickAccess);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › SsoActivate › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureSsoActivate);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Sso › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureSso);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › UploadusersLoading › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureUploadusersLoading);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › UploadusersSuccessful › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureUploadusersSuccessful);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Uploadusers › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureUploadusers);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardAddCoursesPlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardAddCoursesPlaylist);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardFormCreatePlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardFormCreatePlaylist);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardFormEditPlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardFormEditPlaylist);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardPopulationsPlaylistWithPopin › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardPopulationsPlaylistWithPopin);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardPopulationsPlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardPopulationsPlaylist);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardTranslatePlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardTranslatePlaylist);\n"],"file":"fixtures.js"}
|
|
1
|
+
{"version":3,"sources":["../../../../../src/template/back-office/brand-update/test/fixtures.js"],"names":["test","forEach","renderComponentMacro","TemplateBackOfficeBrandUpdate","fixtureAnalytics","fixtureAnimations","fixtureCohortError","fixtureCohort","fixtureDashboard","fixtureDashboardsAnalytics","fixtureDefault","fixtureGeneralSettingsSuccess","fixtureGeneralSettings","fixtureListItemsArchived","fixtureListItemsDraft","fixtureListItemsPublished","fixtureLmsError","fixtureLmsModified","fixtureLmsSuccess","fixtureLms","fixtureLoader","fixtureLookandfeelError","fixtureLookandfeelModified","fixtureLookandfeelPending","fixtureLookandfeelSuccess","fixtureLookandfeel","fixtureManageusersEdit","fixtureManageusersList","fixtureQuickAccess","fixtureSsoActivate","fixtureSso","fixtureUploadusersLoading","fixtureUploadusersSuccessful","fixtureUploadusers","fixtureWizardAddCoursesPlaylist","fixtureWizardFormCreatePlaylist","fixtureWizardFormEditPlaylist","fixtureWizardPopulationsPlaylist","fixtureWizardTranslatePlaylist","t","pass","propTypes","value","key","not","undefined"],"mappings":"AAAA,OAAOA,IAAP,MAAiB,KAAjB;AACA,OAAOC,OAAP,MAAoB,gBAApB;AACA,OAAOC,oBAAP,MAAiC,2CAAjC;AACA,OAAOC,6BAAP,MAA0C,IAA1C;AACA,OAAOC,gBAAP,MAA6B,sBAA7B;AACA,OAAOC,iBAAP,MAA8B,uBAA9B;AACA,OAAOC,kBAAP,MAA+B,yBAA/B;AACA,OAAOC,aAAP,MAA0B,mBAA1B;AACA,OAAOC,gBAAP,MAA6B,sBAA7B;AACA,OAAOC,0BAAP,MAAuC,iCAAvC;AACA,OAAOC,cAAP,MAA2B,oBAA3B;AACA,OAAOC,6BAAP,MAA0C,qCAA1C;AACA,OAAOC,sBAAP,MAAmC,6BAAnC;AACA,OAAOC,wBAAP,MAAqC,gCAArC;AACA,OAAOC,qBAAP,MAAkC,6BAAlC;AACA,OAAOC,yBAAP,MAAsC,iCAAtC;AACA,OAAOC,eAAP,MAA4B,sBAA5B;AACA,OAAOC,kBAAP,MAA+B,yBAA/B;AACA,OAAOC,iBAAP,MAA8B,wBAA9B;AACA,OAAOC,UAAP,MAAuB,gBAAvB;AACA,OAAOC,aAAP,MAA0B,mBAA1B;AACA,OAAOC,uBAAP,MAAoC,8BAApC;AACA,OAAOC,0BAAP,MAAuC,iCAAvC;AACA,OAAOC,yBAAP,MAAsC,gCAAtC;AACA,OAAOC,yBAAP,MAAsC,gCAAtC;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AAtG,EAA4HC,6BAA5H,EAA2JmC,8BAA3J,CAAJ","sourcesContent":["import test from 'ava';\nimport forEach from 'lodash/forEach';\nimport renderComponentMacro from '../../../../test/helpers/render-component';\nimport TemplateBackOfficeBrandUpdate from '..';\nimport fixtureAnalytics from './fixtures/analytics';\nimport fixtureAnimations from './fixtures/animations';\nimport fixtureCohortError from './fixtures/cohort-error';\nimport fixtureCohort from './fixtures/cohort';\nimport fixtureDashboard from './fixtures/dashboard';\nimport fixtureDashboardsAnalytics from './fixtures/dashboards-analytics';\nimport fixtureDefault from './fixtures/default';\nimport fixtureGeneralSettingsSuccess from './fixtures/general-settings-success';\nimport fixtureGeneralSettings from './fixtures/general-settings';\nimport fixtureListItemsArchived from './fixtures/list-items-archived';\nimport fixtureListItemsDraft from './fixtures/list-items-draft';\nimport fixtureListItemsPublished from './fixtures/list-items-published';\nimport fixtureLmsError from './fixtures/lms-error';\nimport fixtureLmsModified from './fixtures/lms-modified';\nimport fixtureLmsSuccess from './fixtures/lms-success';\nimport fixtureLms from './fixtures/lms';\nimport fixtureLoader from './fixtures/loader';\nimport fixtureLookandfeelError from './fixtures/lookandfeel-error';\nimport fixtureLookandfeelModified from './fixtures/lookandfeel-modified';\nimport fixtureLookandfeelPending from './fixtures/lookandfeel-pending';\nimport fixtureLookandfeelSuccess from './fixtures/lookandfeel-success';\nimport fixtureLookandfeel from './fixtures/lookandfeel';\nimport fixtureManageusersEdit from './fixtures/manageusers-edit';\nimport fixtureManageusersList from './fixtures/manageusers-list';\nimport fixtureQuickAccess from './fixtures/quick-access';\nimport fixtureSsoActivate from './fixtures/sso-activate';\nimport fixtureSso from './fixtures/sso';\nimport fixtureUploadusersLoading from './fixtures/uploadusers-loading';\nimport fixtureUploadusersSuccessful from './fixtures/uploadusers-successful';\nimport fixtureUploadusers from './fixtures/uploadusers';\nimport fixtureWizardAddCoursesPlaylist from './fixtures/wizard-add-courses-playlist';\nimport fixtureWizardFormCreatePlaylist from './fixtures/wizard-form-create-playlist';\nimport fixtureWizardFormEditPlaylist from './fixtures/wizard-form-edit-playlist';\nimport fixtureWizardPopulationsPlaylist from './fixtures/wizard-populations-playlist';\nimport fixtureWizardTranslatePlaylist from './fixtures/wizard-translate-playlist';\n\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate > should have valid propTypes', t => {\n t.pass();\n forEach(TemplateBackOfficeBrandUpdate.propTypes, (value, key) => {\n t.not(value, undefined, `PropType for \"TemplateBackOffice.TemplateBackOfficeBrandUpdate.propTypes.${key}\" may not be undefined. Did you mistype the propTypes definition?`);\n });\n});\n\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Analytics › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureAnalytics);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Animations › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureAnimations);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › CohortError › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureCohortError);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Cohort › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureCohort);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Dashboard › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureDashboard);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › DashboardsAnalytics › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureDashboardsAnalytics);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Default › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureDefault);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › GeneralSettingsSuccess › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureGeneralSettingsSuccess);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › GeneralSettings › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureGeneralSettings);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ListItemsArchived › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureListItemsArchived);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ListItemsDraft › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureListItemsDraft);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ListItemsPublished › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureListItemsPublished);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LmsError › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLmsError);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LmsModified › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLmsModified);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LmsSuccess › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLmsSuccess);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Lms › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLms);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Loader › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLoader);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LookandfeelError › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLookandfeelError);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LookandfeelModified › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLookandfeelModified);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LookandfeelPending › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLookandfeelPending);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › LookandfeelSuccess › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLookandfeelSuccess);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Lookandfeel › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureLookandfeel);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ManageusersEdit › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureManageusersEdit);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › ManageusersList › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureManageusersList);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › QuickAccess › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureQuickAccess);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › SsoActivate › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureSsoActivate);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Sso › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureSso);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › UploadusersLoading › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureUploadusersLoading);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › UploadusersSuccessful › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureUploadusersSuccessful);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › Uploadusers › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureUploadusers);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardAddCoursesPlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardAddCoursesPlaylist);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardFormCreatePlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardFormCreatePlaylist);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardFormEditPlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardFormEditPlaylist);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardPopulationsPlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardPopulationsPlaylist);\ntest('TemplateBackOffice › TemplateBackOfficeBrandUpdate › WizardTranslatePlaylist › should be rendered', renderComponentMacro, TemplateBackOfficeBrandUpdate, fixtureWizardTranslatePlaylist);\n"],"file":"fixtures.js"}
|
|
@@ -83,9 +83,9 @@ const InputTextarea = props => {
|
|
|
83
83
|
className: (0, _classnames.default)(_style.default.title, (0, _isEmpty2.default)(value) && _style.default.noValue)
|
|
84
84
|
}, title, toolTipView), /*#__PURE__*/_react.default.createElement("textarea", {
|
|
85
85
|
name: name,
|
|
86
|
-
|
|
86
|
+
value: value,
|
|
87
87
|
placeholder: placeholder,
|
|
88
|
-
|
|
88
|
+
onChange: handleChange,
|
|
89
89
|
disabled: disabled
|
|
90
90
|
}), errorIconView, validIconView, hintView), descriptionView);
|
|
91
91
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/atom/input-textarea/index.js"],"names":["themeStyle","setup","style","coorpmanager","cockpit","default","InputTextarea","props","title","propsTitle","name","placeholder","value","hint","theme","onChange","error","valid","required","description","disabled","modified","mainClass","className","handleChange","e","target","descriptionView","toolTipView","infoIconWrapper","infoIcon","descriptionLabel","hintView","__html","errorIconView","leftIcon","validIconView","noValue","propTypes","PropTypes","string","bool","oneOf","func"],"mappings":";;;;;;;;;;;AAAA;;AACA;;AAEA;;AACA;;AAKA;;AACA;;;;;;;;AAEA,MAAMA,UAAU,GAAG;AACjBC,EAAAA,KAAK,EAAEC,eAAMD,KADI;AAEjBE,EAAAA,YAAY,EAAED,eAAMC,YAFH;AAGjBC,EAAAA,OAAO,EAAEF,eAAME,OAHE;AAIjBC,EAAAA,OAAO,EAAEH,eAAMG;AAJE,CAAnB;;AAMA,MAAMC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EAAEZ,eAAMW,IADnB,CAEE;AAFF;AAGE,IAAA,uBAAuB,EAAE;AAACoB,MAAAA,MAAM,EAAEjB,KAAK,IAAIH;AAAlB;AAH3B,IADF,GAMI,IAPN;AAQA,QAAMqB,aAAa,GAAGlB,KAAK,gBAAG,6BAAC,+BAAD;AAAW,IAAA,SAAS,EAAEd,eAAMiC;AAA5B,IAAH,GAA8C,IAAzE;AACA,QAAMC,aAAa,GAAGnB,KAAK,gBAAG,6BAAC,sCAAD;AAAW,IAAA,SAAS,EAAEf,eAAMiC;AAA5B,IAAH,GAA8C,IAAzE;AAEA,sBACE;AAAK,IAAA,SAAS,EAAE,yBAAWb,SAAX,EAAsBC,SAAtB,EAAiCH,QAAQ,IAAIlB,eAAMkB,QAAnD;AAAhB,kBACE,yDACE;AAAM,IAAA,SAAS,EAAE,yBAAWlB,eAAMM,KAAjB,EAAwB,uBAAQI,KAAR,KAAkBV,eAAMmC,OAAhD;AAAjB,KACG7B,KADH,EAEGoB,WAFH,CADF,eAKE;AACE,IAAA,IAAI,EAAElB,IADR;AAEE,IAAA,
|
|
1
|
+
{"version":3,"sources":["../../../src/atom/input-textarea/index.js"],"names":["themeStyle","setup","style","coorpmanager","cockpit","default","InputTextarea","props","title","propsTitle","name","placeholder","value","hint","theme","onChange","error","valid","required","description","disabled","modified","mainClass","className","handleChange","e","target","descriptionView","toolTipView","infoIconWrapper","infoIcon","descriptionLabel","hintView","__html","errorIconView","leftIcon","validIconView","noValue","propTypes","PropTypes","string","bool","oneOf","func"],"mappings":";;;;;;;;;;;AAAA;;AACA;;AAEA;;AACA;;AAKA;;AACA;;;;;;;;AAEA,MAAMA,UAAU,GAAG;AACjBC,EAAAA,KAAK,EAAEC,eAAMD,KADI;AAEjBE,EAAAA,YAAY,EAAED,eAAMC,YAFH;AAGjBC,EAAAA,OAAO,EAAEF,eAAME,OAHE;AAIjBC,EAAAA,OAAO,EAAEH,eAAMG;AAJE,CAAnB;;AAMA,MAAMC,aAAa,GAAGC,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2B,mBAAUC,MAPO;AAQxB3B,EAAAA,IAAI,EAAE0B,mBAAUC,MARQ;AASxBxB,EAAAA,KAAK,EAAEuB,mBAAUC,MATO;AAUxBzB,EAAAA,QAAQ,EAAEwB,mBAAUI,IAVI;AAWxBxB,EAAAA,WAAW,EAAEoB,mBAAUC,MAXC;AAYxBnB,EAAAA,QAAQ,EAAEkB,mBAAUE,IAZI;AAaxBxB,EAAAA,KAAK,EAAEsB,mBAAUE;AAbO,CAA1B;eAeenC,a","sourcesContent":["import React, {useMemo} from 'react';\nimport PropTypes from 'prop-types';\nimport {noop, keys, isEmpty} from 'lodash/fp';\nimport classnames from 'classnames';\nimport {\n NovaSolidStatusCheckCircle2 as CheckIcon,\n NovaSolidStatusClose as ErrorIcon,\n NovaCompositionCoorpacademyInformationIcon as InfoIcon\n} from '@coorpacademy/nova-icons';\nimport getClassState from '../../util/get-class-state';\nimport style from './style.css';\n\nconst themeStyle = {\n setup: style.setup,\n coorpmanager: style.coorpmanager,\n cockpit: style.cockpit,\n default: style.default\n};\nconst InputTextarea = props => {\n const {\n title: propsTitle,\n name,\n placeholder,\n value,\n hint,\n theme = 'default',\n onChange = noop,\n error,\n valid,\n required,\n description,\n disabled,\n modified = false\n } = props;\n\n const title = `${propsTitle}${required ? '* ' : ' '}`;\n const mainClass = themeStyle[theme];\n const className = getClassState(style.default, style.modified, style.error, modified, error);\n const handleChange = useMemo(() => e => onChange(e.target.value), [onChange]);\n\n const descriptionView =\n description && theme !== 'coorpmanager' ? (\n <div className={style.description}>{description}</div>\n ) : null;\n const toolTipView =\n description && theme === 'coorpmanager' ? (\n <div className={style.infoIconWrapper}>\n <InfoIcon className={style.infoIcon} />\n <div className={style.descriptionLabel}>{description}</div>\n </div>\n ) : null;\n const hintView =\n theme === 'coorpmanager' ? (\n <div\n className={style.hint}\n // eslint-disable-next-line react/no-danger\n dangerouslySetInnerHTML={{__html: error || hint}}\n />\n ) : null;\n const errorIconView = error ? <ErrorIcon className={style.leftIcon} /> : null;\n const validIconView = valid ? <CheckIcon className={style.leftIcon} /> : null;\n\n return (\n <div className={classnames(mainClass, className, disabled && style.disabled)}>\n <label>\n <span className={classnames(style.title, isEmpty(value) && style.noValue)}>\n {title}\n {toolTipView}\n </span>\n <textarea\n name={name}\n value={value}\n placeholder={placeholder}\n onChange={handleChange}\n disabled={disabled}\n />\n {errorIconView}\n {validIconView}\n {hintView}\n </label>\n {descriptionView}\n </div>\n );\n};\n\nInputTextarea.propTypes = {\n placeholder: PropTypes.string,\n title: PropTypes.string,\n required: PropTypes.bool,\n name: PropTypes.string,\n theme: PropTypes.oneOf(keys(themeStyle)),\n disabled: PropTypes.bool,\n value: PropTypes.string,\n hint: PropTypes.string,\n error: PropTypes.string,\n onChange: PropTypes.func,\n description: PropTypes.string,\n modified: PropTypes.bool,\n valid: PropTypes.bool\n};\nexport default InputTextarea;\n"],"file":"index.js"}
|
|
@@ -34,7 +34,7 @@ function _extends() { _extends = Object.assign || function (target) { for (var i
|
|
|
34
34
|
const wrapper = (0, _enzyme.shallow)( /*#__PURE__*/_react.default.createElement(_.default, _extends({}, _default.default.props, {
|
|
35
35
|
onChange: onChange
|
|
36
36
|
})));
|
|
37
|
-
wrapper.find('textarea').simulate('
|
|
37
|
+
wrapper.find('textarea').simulate('change', {
|
|
38
38
|
target: {
|
|
39
39
|
value: 'foo'
|
|
40
40
|
}
|
|
@@ -42,7 +42,7 @@ function _extends() { _extends = Object.assign || function (target) { for (var i
|
|
|
42
42
|
});
|
|
43
43
|
(0, _ava.default)('should not crash if the onChange function has not been specified', t => {
|
|
44
44
|
const wrapper = (0, _enzyme.shallow)( /*#__PURE__*/_react.default.createElement(_.default, (0, _omit2.default)('onChange', _default.default.props)));
|
|
45
|
-
wrapper.find('textarea').simulate('
|
|
45
|
+
wrapper.find('textarea').simulate('change', {
|
|
46
46
|
target: {
|
|
47
47
|
value: 'foo'
|
|
48
48
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/atom/input-textarea/test/on-change.js"],"names":["adapter","Adapter","t","plan","onChange","value","is","wrapper","defaultFixture","props","find","simulate","target","pass"],"mappings":";;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AAEA;;AACA;;;;;;AAEA;AACA,uBAAU;AAACA,EAAAA,OAAO,EAAE,IAAIC,2BAAJ;AAAV,CAAV;AAEA,kBAAK,gEAAL,EAAuEC,CAAC,IAAI;AAC1EA,EAAAA,CAAC,CAACC,IAAF,CAAO,CAAP;;AACA,QAAMC,QAAQ,GAAGC,KAAK,IAAI;AACxBH,IAAAA,CAAC,CAACI,EAAF,CAAKD,KAAL,EAAY,KAAZ;AACD,GAFD;;AAGA,QAAME,OAAO,GAAG,mCAAQ,6BAAC,SAAD,eAAmBC,iBAAeC,KAAlC;AAAyC,IAAA,QAAQ,EAAEL;AAAnD,KAAR,CAAhB;AAEAG,EAAAA,OAAO,CAACG,IAAR,CAAa,UAAb,EAAyBC,QAAzB,CAAkC,
|
|
1
|
+
{"version":3,"sources":["../../../../src/atom/input-textarea/test/on-change.js"],"names":["adapter","Adapter","t","plan","onChange","value","is","wrapper","defaultFixture","props","find","simulate","target","pass"],"mappings":";;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AAEA;;AACA;;;;;;AAEA;AACA,uBAAU;AAACA,EAAAA,OAAO,EAAE,IAAIC,2BAAJ;AAAV,CAAV;AAEA,kBAAK,gEAAL,EAAuEC,CAAC,IAAI;AAC1EA,EAAAA,CAAC,CAACC,IAAF,CAAO,CAAP;;AACA,QAAMC,QAAQ,GAAGC,KAAK,IAAI;AACxBH,IAAAA,CAAC,CAACI,EAAF,CAAKD,KAAL,EAAY,KAAZ;AACD,GAFD;;AAGA,QAAME,OAAO,GAAG,mCAAQ,6BAAC,SAAD,eAAmBC,iBAAeC,KAAlC;AAAyC,IAAA,QAAQ,EAAEL;AAAnD,KAAR,CAAhB;AAEAG,EAAAA,OAAO,CAACG,IAAR,CAAa,UAAb,EAAyBC,QAAzB,CAAkC,QAAlC,EAA4C;AAACC,IAAAA,MAAM,EAAE;AAACP,MAAAA,KAAK,EAAE;AAAR;AAAT,GAA5C;AACD,CARD;AAUA,kBAAK,kEAAL,EAAyEH,CAAC,IAAI;AAC5E,QAAMK,OAAO,GAAG,mCAAQ,6BAAC,SAAD,EAAmB,oBAAK,UAAL,EAAiBC,iBAAeC,KAAhC,CAAnB,CAAR,CAAhB;AAEAF,EAAAA,OAAO,CAACG,IAAR,CAAa,UAAb,EAAyBC,QAAzB,CAAkC,QAAlC,EAA4C;AAACC,IAAAA,MAAM,EAAE;AAACP,MAAAA,KAAK,EAAE;AAAR;AAAT,GAA5C;AACAH,EAAAA,CAAC,CAACW,IAAF;AACD,CALD","sourcesContent":["import browserEnv from 'browser-env';\nimport test from 'ava';\nimport React from 'react';\nimport {shallow, configure} from 'enzyme';\nimport Adapter from 'enzyme-adapter-react-16';\nimport {omit} from 'lodash/fp';\nimport InputTextarea from '..';\nimport defaultFixture from './fixtures/default';\n\nbrowserEnv();\nconfigure({adapter: new Adapter()});\n\ntest('should call the onChange function with the value of the target', t => {\n t.plan(1);\n const onChange = value => {\n t.is(value, 'foo');\n };\n const wrapper = shallow(<InputTextarea {...defaultFixture.props} onChange={onChange} />);\n\n wrapper.find('textarea').simulate('change', {target: {value: 'foo'}});\n});\n\ntest('should not crash if the onChange function has not been specified', t => {\n const wrapper = shallow(<InputTextarea {...omit('onChange', defaultFixture.props)} />);\n\n wrapper.find('textarea').simulate('change', {target: {value: 'foo'}});\n t.pass();\n});\n"],"file":"on-change.js"}
|
|
@@ -17,6 +17,10 @@ function _defineProperty(obj, key, value) { if (key in obj) { Object.definePrope
|
|
|
17
17
|
|
|
18
18
|
const DEFAULT_SKIN = {
|
|
19
19
|
common: {
|
|
20
|
+
good: '#24b694',
|
|
21
|
+
bad: '#ed1c24',
|
|
22
|
+
primary: '#00B0FF',
|
|
23
|
+
life: '#ed1c24',
|
|
20
24
|
brand: '#00B0FF',
|
|
21
25
|
primaryAdd1: '#B3E5FC',
|
|
22
26
|
primaryAdd2: '#0091EA',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/atom/provider/index.js"],"names":["DEFAULT_SKIN","common","brand","primaryAdd1","primaryAdd2","primaryAdd3","primaryAdd4","xtraLightGrey","light","medium","dark","grey","orangeAdd","orange","positive","lightGreen","negative","battle","white","black","mergeSkin","skin","historyShape","PropTypes","shape","createHref","func","push","skinShape","objectOf","ColorPropType","images","SrcPropType","logo","login","icons","HexPropType","mod","courses","arrayOf","texts","translateShape","Provider","React","Component","getDerivedStateFromProps","props","history","translate","constructor","context","Vimeo","state","getChildContext","render","children","Children","only","isRequired","object","propTypes","node"],"mappings":";;;;;;;AAAA;;AACA;;AAEA;;;;;;AAEA,MAAMA,YAAY,GAAG;AACnBC,EAAAA,MAAM,EAAE;AACNC,IAAAA,
|
|
1
|
+
{"version":3,"sources":["../../../src/atom/provider/index.js"],"names":["DEFAULT_SKIN","common","good","bad","primary","life","brand","primaryAdd1","primaryAdd2","primaryAdd3","primaryAdd4","xtraLightGrey","light","medium","dark","grey","orangeAdd","orange","positive","lightGreen","negative","battle","white","black","mergeSkin","skin","historyShape","PropTypes","shape","createHref","func","push","skinShape","objectOf","ColorPropType","images","SrcPropType","logo","login","icons","HexPropType","mod","courses","arrayOf","texts","translateShape","Provider","React","Component","getDerivedStateFromProps","props","history","translate","constructor","context","Vimeo","state","getChildContext","render","children","Children","only","isRequired","object","propTypes","node"],"mappings":";;;;;;;AAAA;;AACA;;AAEA;;;;;;AAEA,MAAMA,YAAY,GAAG;AACnBC,EAAAA,MAAM,EAAE;AACNC,IAAAA,IAAI,EAAE,SADA;AAENC,IAAAA,GAAG,EAAE,SAFC;AAGNC,IAAAA,OAAO,EAAE,SAHH;AAINC,IAAAA,IAAI,EAAE,SAJA;AAKNC,IAAAA,KAAK,EAAE,SALD;AAMNC,IAAAA,WAAW,EAAE,SANP;AAONC,IAAAA,WAAW,EAAE,SAPP;AAQNC,IAA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jB,Q,CACGkB,S,2CAAY;AACjBb,EAAAA,OAAO,EAAEzB,YADQ;AAEjBD,EAAAA,IAAI,EAAEO,SAFW;AAGjBoB,EAAAA,SAAS,EAAEP,cAHM;AAIjBc,EAAAA,QAAQ,EAAEhC,mBAAUsC,IAAV,CAAeH,UAJR;AAKjBP,EAAAA,KAAK,EAAE5B,mBAAUC,KAAV,CAAgB;AACrB3B,IAAAA,MAAM,EAAE0B,mBAAUG;AADG,GAAhB;AALU,C;eA4CNgB,Q","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {defaultsDeep} from 'lodash/fp';\nimport {SrcPropType, ColorPropType, HexPropType} from '../../util/proptypes';\n\nconst DEFAULT_SKIN = {\n common: {\n good: '#24b694',\n bad: '#ed1c24',\n primary: '#00B0FF',\n life: '#ed1c24',\n brand: '#00B0FF',\n primaryAdd1: '#B3E5FC',\n primaryAdd2: '#0091EA',\n primaryAdd3: '#0277BD',\n primaryAdd4: '#015798',\n xtraLightGrey: '#FAFAFA',\n light: '#ECEFF1',\n medium: '#90A4AE',\n dark: '#546E7A',\n grey: '#607D8B',\n orangeAdd: '#FF7043',\n orange: '#FFA000',\n positive: '#3EC483',\n lightGreen: '#66BB6A',\n negative: '#F73F52',\n battle: '#FFE100',\n white: '#FFFFFF',\n black: '#14171A'\n }\n};\n\nconst mergeSkin = (skin = {}) => defaultsDeep(skin, DEFAULT_SKIN);\n\nconst historyShape = PropTypes.shape({\n createHref: PropTypes.func,\n push: PropTypes.func\n});\n\nconst skinShape = PropTypes.shape({\n common: PropTypes.objectOf(ColorPropType),\n images: PropTypes.shape({\n 'logo-mobile': SrcPropType,\n logo: SrcPropType,\n 'logo-email': SrcPropType,\n login: SrcPropType\n }),\n icons: PropTypes.objectOf(HexPropType),\n mod: PropTypes.objectOf(ColorPropType),\n courses: PropTypes.arrayOf(ColorPropType),\n texts: PropTypes.objectOf(ColorPropType)\n});\n\nconst translateShape = PropTypes.func;\n\nclass Provider extends React.Component {\n static propTypes = {\n history: historyShape,\n skin: skinShape,\n translate: translateShape,\n children: PropTypes.node.isRequired,\n Vimeo: PropTypes.shape({\n common: PropTypes.func\n })\n };\n\n static childContextTypes = {\n history: historyShape,\n skin: skinShape,\n translate: translateShape.isRequired,\n Vimeo: PropTypes.object\n };\n\n static getDerivedStateFromProps(props) {\n const {history, skin, translate} = props;\n\n return {\n history,\n skin: mergeSkin(skin),\n translate\n };\n }\n\n constructor(props, context) {\n super(props, context);\n const {history, skin, translate, Vimeo} = props;\n // eslint-disable-next-line react/no-unused-state\n this.state = {history, skin: mergeSkin(skin), translate, Vimeo};\n }\n\n getChildContext() {\n return this.state;\n }\n\n render() {\n const {children} = this.props;\n return React.Children.only(children);\n }\n}\n\nexport default Provider;\n"],"file":"index.js"}
|
|
@@ -23,26 +23,34 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
23
23
|
|
|
24
24
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
25
25
|
|
|
26
|
+
const themeStyle = {
|
|
27
|
+
setup: _style.default.setup,
|
|
28
|
+
coorpmanager: _style.default.coorpmanager
|
|
29
|
+
};
|
|
30
|
+
|
|
26
31
|
const RadioGroup = (props, context) => {
|
|
27
32
|
const {
|
|
28
33
|
list = [],
|
|
29
34
|
onChange,
|
|
30
35
|
color,
|
|
31
|
-
className
|
|
36
|
+
className,
|
|
37
|
+
theme = 'setup'
|
|
32
38
|
} = props;
|
|
33
39
|
const {
|
|
34
40
|
skin
|
|
35
41
|
} = context;
|
|
36
42
|
const borderColor = color || (0, _get2.default)('common.primary', skin);
|
|
43
|
+
const mainClass = themeStyle[theme];
|
|
37
44
|
const items = (0, _map2.default)(itemProps => {
|
|
38
45
|
return /*#__PURE__*/_react.default.createElement(_item.default, _extends({}, itemProps, {
|
|
39
46
|
color: color,
|
|
47
|
+
theme: theme,
|
|
40
48
|
onChange: onChange,
|
|
41
49
|
key: itemProps.value
|
|
42
50
|
}));
|
|
43
51
|
}, list);
|
|
44
52
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
45
|
-
className: (0, _classnames.default)([_style.default.container, className]),
|
|
53
|
+
className: (0, _classnames.default)([mainClass, _style.default.container, className]),
|
|
46
54
|
style: {
|
|
47
55
|
borderColor
|
|
48
56
|
}
|
|
@@ -54,6 +62,7 @@ RadioGroup.contextTypes = {
|
|
|
54
62
|
};
|
|
55
63
|
RadioGroup.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
56
64
|
color: _propTypes.default.string,
|
|
65
|
+
theme: _propTypes.default.string,
|
|
57
66
|
className: _propTypes.default.string,
|
|
58
67
|
list: _propTypes.default.arrayOf(_propTypes.default.shape(_item.default.propTypes)),
|
|
59
68
|
onChange: _propTypes.default.func
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/atom/radio-group/index.js"],"names":["RadioGroup","props","context","list","onChange","color","className","skin","borderColor","items","itemProps","value","
|
|
1
|
+
{"version":3,"sources":["../../../src/atom/radio-group/index.js"],"names":["themeStyle","setup","style","coorpmanager","RadioGroup","props","context","list","onChange","color","className","theme","skin","borderColor","mainClass","items","itemProps","value","container","contextTypes","Provider","childContextTypes","propTypes","PropTypes","string","arrayOf","shape","Item","func"],"mappings":";;;;;;;;;AAAA;;AACA;;AAEA;;AACA;;AACA;;AAEA;;;;;;AAEA,MAAMA,UAAU,GAAG;AACjBC,EAAAA,KAAK,EAAEC,eAAMD,KADI;AAEjBE,EAAAA,YAAY,EAAED,eAAMC;AAFH,CAAnB;;AAKA,MAAMC,UAAU,GAAG,CAACC,KAAD,EAAQC,OAAR,KAAoB;AACrC,QAAM;AAACC,IAAAA,IAAI,GAAG,EAAR;AAAYC,IAAAA,QAAZ;AAAsBC,IAAAA,KAAtB;AAA6BC,IAAAA,SAA7B;AAAwCC,IAAAA,KAAK,GAAG;AAAhD,MAA2DN,KAAjE;AACA,QAAM;AAACO,IAAAA;AAAD,MAASN,OAAf;AACA,QAAMO,WAAW,GAAGJ,KAAK,IAAI,mBAAI,gBAAJ,EAAsBG,IAAtB,CAA7B;AACA,QAAME,SAAS,GAAGd,UAAU,CAACW,KAAD,CAA5B;AACA,QAAMI,KAAK,GAAG,mBAAIC,SAAS,IAAI;AAC7B,wBACE,6BAAC,aAAD,eAAUA,SAAV;AAAqB,MAAA,KAAK,EAAEP,KAA5B;AAAmC,MAAA,KAAK,EAAEE,KAA1C;AAAiD,MAAA,QAAQ,EAAEH,QAA3D;AAAqE,MAAA,GAAG,EAAEQ,SAAS,CAACC;AAApF,OADF;AAGD,GAJa,EAIXV,IAJW,CAAd;AAMA,sBACE;AAAK,IAAA,SAAS,EAAE,yBAAW,CAACO,SAAD,EAAYZ,eAAMgB,SAAlB,EAA6BR,SAA7B,CAAX,CAAhB;AAAqE,IAAA,KAAK,EAAE;AAACG,MAAAA;AAAD;AAA5E,KACGE,KADH,CADF;AAKD,CAhBD;;AAkBAX,UAAU,CAACe,YAAX,GAA0B;AACxBP,EAAAA,IAAI,EAAEQ,kBAASC,iBAAT,CAA2BT;AADT,CAA1B;AAIAR,UAAU,CAACkB,SAAX,2CAAuB;AACrBb,EAAAA,KAAK,EAAEc,mBAAUC,MADI;AAErBb,EAAAA,KAAK,EAAEY,mBAAUC,MAFI;AAGrBd,EAAAA,SAAS,EAAEa,mBAAUC,MAHA;AAIrBjB,EAAAA,IAAI,EAAEgB,mBAAUE,OAAV,CAAkBF,mBAAUG,KAAV,CAAgBC,cAAKL,SAArB,CAAlB,CAJe;AAKrBd,EAAAA,QAAQ,EAAEe,mBAAUK;AALC,CAAvB;eAQexB,U","sourcesContent":["import classnames from 'classnames';\nimport React from 'react';\nimport {get, map} from 'lodash/fp';\nimport PropTypes from 'prop-types';\nimport Provider from '../provider';\nimport style from './style.css';\n\nimport Item from './item';\n\nconst themeStyle = {\n setup: style.setup,\n coorpmanager: style.coorpmanager\n};\n\nconst RadioGroup = (props, context) => {\n const {list = [], onChange, color, className, theme = 'setup'} = props;\n const {skin} = context;\n const borderColor = color || get('common.primary', skin);\n const mainClass = themeStyle[theme];\n const items = map(itemProps => {\n return (\n <Item {...itemProps} color={color} theme={theme} onChange={onChange} key={itemProps.value} />\n );\n }, list);\n\n return (\n <div className={classnames([mainClass, style.container, className])} style={{borderColor}}>\n {items}\n </div>\n );\n};\n\nRadioGroup.contextTypes = {\n skin: Provider.childContextTypes.skin\n};\n\nRadioGroup.propTypes = {\n color: PropTypes.string,\n theme: PropTypes.string,\n className: PropTypes.string,\n list: PropTypes.arrayOf(PropTypes.shape(Item.propTypes)),\n onChange: PropTypes.func\n};\n\nexport default RadioGroup;\n"],"file":"index.js"}
|
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
@value colors: "../../variables/colors.css";
|
|
2
|
+
@value cm_primary_blue from colors;
|
|
3
|
+
@value cm_blue_50 from colors;
|
|
4
|
+
@value cm_grey_400 from colors;
|
|
5
|
+
|
|
6
|
+
|
|
1
7
|
.radio {
|
|
2
8
|
visibility: hidden;
|
|
3
9
|
display: none;
|
|
@@ -6,7 +12,6 @@
|
|
|
6
12
|
.normal {
|
|
7
13
|
flex: 1 1 0;
|
|
8
14
|
line-height: 30px;
|
|
9
|
-
border-right: solid 1px;
|
|
10
15
|
color: white;
|
|
11
16
|
cursor: pointer;
|
|
12
17
|
min-width: 33%;
|
|
@@ -29,8 +34,50 @@
|
|
|
29
34
|
white-space: nowrap;
|
|
30
35
|
text-align: center;
|
|
31
36
|
box-sizing: border-box;
|
|
37
|
+
user-select: none;
|
|
32
38
|
}
|
|
33
39
|
|
|
34
40
|
.normal:last-child {
|
|
35
41
|
border-right-width: 0;
|
|
36
42
|
}
|
|
43
|
+
|
|
44
|
+
.setup.normal{
|
|
45
|
+
border-right: solid 1px;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.coorpmanager label {
|
|
49
|
+
flex-grow: 0;
|
|
50
|
+
box-sizing: border-box;;
|
|
51
|
+
font-family: Gilroy;
|
|
52
|
+
font-size: 14px;
|
|
53
|
+
font-weight: bold;
|
|
54
|
+
font-stretch: normal;
|
|
55
|
+
font-style: normal;
|
|
56
|
+
line-height: 1.43;
|
|
57
|
+
letter-spacing: normal;
|
|
58
|
+
text-align: left;
|
|
59
|
+
height: 36px;
|
|
60
|
+
display: flex;
|
|
61
|
+
flex-direction: column;
|
|
62
|
+
justify-content: center;
|
|
63
|
+
align-items: center;
|
|
64
|
+
gap: 8px;
|
|
65
|
+
|
|
66
|
+
border-radius: 5px;
|
|
67
|
+
}
|
|
68
|
+
.coorpmanager.normal{
|
|
69
|
+
border: 0px;
|
|
70
|
+
border-radius: 5px;
|
|
71
|
+
overflow: hidden;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.coorpmanager .label.selected .labelSpan{
|
|
75
|
+
color: cm_primary_blue;
|
|
76
|
+
background-color: cm_blue_50;
|
|
77
|
+
}
|
|
78
|
+
.coorpmanager .labelSpan {
|
|
79
|
+
color: cm_grey_400;
|
|
80
|
+
background-color: transparent;
|
|
81
|
+
padding: 8px 16px;
|
|
82
|
+
transition: color 0.5s linear;
|
|
83
|
+
}
|
|
@@ -15,6 +15,8 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
17
17
|
|
|
18
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
19
|
+
|
|
18
20
|
var _provider = _interopRequireDefault(require("../provider"));
|
|
19
21
|
|
|
20
22
|
var _item = _interopRequireDefault(require("./item.css"));
|
|
@@ -23,6 +25,11 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
23
25
|
|
|
24
26
|
const getTargetValueAndCall = fun => (0, _pipe2.default)((0, _get2.default)('target.value'), fun);
|
|
25
27
|
|
|
28
|
+
const themeStyle = {
|
|
29
|
+
setup: _item.default.setup,
|
|
30
|
+
coorpmanager: _item.default.coorpmanager
|
|
31
|
+
};
|
|
32
|
+
|
|
26
33
|
const Item = (props, context) => {
|
|
27
34
|
const idRadioButton = (0, _uniqueId2.default)('inputRadioButton');
|
|
28
35
|
const {
|
|
@@ -34,11 +41,13 @@ const Item = (props, context) => {
|
|
|
34
41
|
value,
|
|
35
42
|
checked,
|
|
36
43
|
label,
|
|
37
|
-
onChange = _identity2.default
|
|
44
|
+
onChange = _identity2.default,
|
|
45
|
+
theme
|
|
38
46
|
} = props;
|
|
39
47
|
const defaultColor = color || (0, _get2.default)('common.primary', skin);
|
|
48
|
+
const mainClass = themeStyle[theme];
|
|
40
49
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
41
|
-
className: _item.default.normal,
|
|
50
|
+
className: (0, _classnames.default)(_item.default.normal, mainClass),
|
|
42
51
|
style: {
|
|
43
52
|
backgroundColor: checked && defaultColor,
|
|
44
53
|
borderRightColor: defaultColor,
|
|
@@ -53,7 +62,7 @@ const Item = (props, context) => {
|
|
|
53
62
|
checked: checked,
|
|
54
63
|
onChange: getTargetValueAndCall(onChange)
|
|
55
64
|
}), /*#__PURE__*/_react.default.createElement("label", {
|
|
56
|
-
className: _item.default.label,
|
|
65
|
+
className: (0, _classnames.default)(_item.default.label, checked && _item.default.selected),
|
|
57
66
|
style: {
|
|
58
67
|
color: !checked && defaultColor
|
|
59
68
|
},
|
|
@@ -72,6 +81,7 @@ Item.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
72
81
|
color: _propTypes.default.string,
|
|
73
82
|
value: _propTypes.default.string.isRequired,
|
|
74
83
|
name: _propTypes.default.string,
|
|
84
|
+
theme: _propTypes.default.string,
|
|
75
85
|
checked: _propTypes.default.bool,
|
|
76
86
|
label: _propTypes.default.string,
|
|
77
87
|
onChange: _propTypes.default.func
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/atom/radio-group/item.js"],"names":["getTargetValueAndCall","fun","Item","props","context","idRadioButton","skin","color","name","value","checked","label","onChange","defaultColor","
|
|
1
|
+
{"version":3,"sources":["../../../src/atom/radio-group/item.js"],"names":["getTargetValueAndCall","fun","themeStyle","setup","style","coorpmanager","Item","props","context","idRadioButton","skin","color","name","value","checked","label","onChange","theme","defaultColor","mainClass","normal","backgroundColor","borderRightColor","radio","selected","labelSpan","contextTypes","Provider","childContextTypes","propTypes","PropTypes","string","isRequired","bool","func"],"mappings":";;;;;;;;;;;;;AAAA;;AAEA;;AACA;;AACA;;AACA;;;;AAEA,MAAMA,qBAAqB,GAAGC,GAAG,IAAI,oBAAK,mBAAI,cAAJ,CAAL,EAA0BA,GAA1B,CAArC;;AAEA,MAAMC,UAAU,GAAG;AACjBC,EAAAA,KAAK,EAAEC,cAAMD,KADI;AAEjBE,EAAAA,YAAY,EAAED,cAAMC;AAFH,CAAnB;;AAKA,MAAMC,IAAI,GAAG,CAACC,KAAD,EAAQC,OAAR,KAAoB;AAC/B,QAAMC,aAAa,GAAG,wBAAS,kBAAT,CAAtB;AACA,QAAM;AAACC,IAAAA;AAAD,MAASF,OAAf;AACA,QAAM;AAACG,IAAAA,KAAD;AAAQC,IAAAA,IAAR;AAAcC,IAAAA,KAAd;AAAqBC,IAAAA,OAArB;AAA8BC,IAAAA,KAA9B;AAAqCC,IAAAA,QAAQ,qBAA7C;AAA0DC,IAAAA;AAA1D,MAAmEV,KAAzE;AACA,QAAMW,YAAY,GAAGP,KAAK,IAAI,mBAAI,gBAAJ,EAAsBD,IAAtB,CAA9B;AACA,QAAMS,SAAS,GAAGjB,UAAU,CAACe,KAAD,CAA5B;AACA,sBACE;AACE,IAAA,SAAS,EAAE,yBAAWb,cAAMgB,MAAjB,EAAyBD,SAAzB,CADb;AAEE,IAAA,KAAK,EAAE;AACLE,MAAAA,eAAe,EAAEP,OAAO,IAAII,YADvB;AAELI,MAAAA,gBAAgB,EAAEJ,YAFb;AAGLP,MAAAA,KAAK,EAAE,CAACG,OAAD,IAAYI;AAHd;AAFT,kBAQE;AACE,IAAA,IAAI,EAAC,OADP;AAEE,IAAA,EAAE,EAAET,aAFN;AAGE,IAAA,SAAS,EAAEL,cAAMmB,KAHnB;AAIE,IAAA,IAAI,EAAEX,IAJR;AAKE,IAAA,KAAK,EAAEC,KALT;AAME,IAAA,OAAO,EAAEC,OANX;AAOE,IAAA,QAAQ,EAAEd,qBAAqB,CAACgB,QAAD;AAPjC,IARF,eAiBE;AACE,IAAA,SAAS,EAAE,yBAAWZ,cAAMW,KAAjB,EAAwBD,OAAO,IAAIV,cAAMoB,QAAzC,CADb;AAEE,IAAA,KAAK,EAAE;AACLb,MAAAA,KAAK,EAAE,CAACG,OAAD,IAAYI;AADd,KAFT;AAKE,IAAA,OAAO,EAAET;AALX,kBAOE;AAAM,IAAA,SAAS,EAAEL,cAAMqB,SAAvB;AAAkC,iBAAY,SAAQZ,KAAM,EAA5D;AAA+D,IAAA,KAAK,EAAEE;AAAtE,KACGA,KADH,CAPF,CAjBF,CADF;AA+BD,CArCD;;AAuCAT,IAAI,CAACoB,YAAL,GAAoB;AAClBhB,EAAAA,IAAI,EAAEiB,kBAASC,iBAAT,CAA2BlB;AADf,CAApB;AAGAJ,IAAI,CAACuB,SAAL,2CAAiB;AACflB,EAAAA,KAAK,EAAEmB,mBAAUC,MADF;AAEflB,EAAAA,KAAK,EAAEiB,mBAAUC,MAAV,CAAiBC,UAFT;AAGfpB,EAAAA,IAAI,EAAEkB,mBAAUC,MAHD;AAIfd,EAAAA,KAAK,EAAEa,mBAAUC,MAJF;AAKfjB,EAAAA,OAAO,EAAEgB,mBAAUG,IALJ;AAMflB,EAAAA,KAAK,EAAEe,mBAAUC,MANF;AAOff,EAAAA,QAAQ,EAAEc,mBAAUI;AAPL,CAAjB;eAUe5B,I","sourcesContent":["import React from 'react';\nimport {get, pipe, identity, uniqueId} from 'lodash/fp';\nimport PropTypes from 'prop-types';\nimport classNames from 'classnames';\nimport Provider from '../provider';\nimport style from './item.css';\n\nconst getTargetValueAndCall = fun => pipe(get('target.value'), fun);\n\nconst themeStyle = {\n setup: style.setup,\n coorpmanager: style.coorpmanager\n};\n\nconst Item = (props, context) => {\n const idRadioButton = uniqueId('inputRadioButton');\n const {skin} = context;\n const {color, name, value, checked, label, onChange = identity, theme} = props;\n const defaultColor = color || get('common.primary', skin);\n const mainClass = themeStyle[theme];\n return (\n <div\n className={classNames(style.normal, mainClass)}\n style={{\n backgroundColor: checked && defaultColor,\n borderRightColor: defaultColor,\n color: !checked && defaultColor\n }}\n >\n <input\n type=\"radio\"\n id={idRadioButton}\n className={style.radio}\n name={name}\n value={value}\n checked={checked}\n onChange={getTargetValueAndCall(onChange)}\n />\n <label\n className={classNames(style.label, checked && style.selected)}\n style={{\n color: !checked && defaultColor\n }}\n htmlFor={idRadioButton}\n >\n <span className={style.labelSpan} data-name={`radio-${value}`} title={label}>\n {label}\n </span>\n </label>\n </div>\n );\n};\n\nItem.contextTypes = {\n skin: Provider.childContextTypes.skin\n};\nItem.propTypes = {\n color: PropTypes.string,\n value: PropTypes.string.isRequired,\n name: PropTypes.string,\n theme: PropTypes.string,\n checked: PropTypes.bool,\n label: PropTypes.string,\n onChange: PropTypes.func\n};\n\nexport default Item;\n"],"file":"item.js"}
|
|
@@ -33,10 +33,12 @@ const Banner = props => {
|
|
|
33
33
|
firstCTALabel,
|
|
34
34
|
secondCTALabel,
|
|
35
35
|
secondCTA,
|
|
36
|
-
temporary
|
|
36
|
+
temporary,
|
|
37
|
+
bannerKey
|
|
37
38
|
} = props;
|
|
38
39
|
const Icon = ICONS[type];
|
|
39
40
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
41
|
+
key: bannerKey,
|
|
40
42
|
className: (0, _classnames.default)(_style.default.banner, type === 'error' && _style.default.errorBanner, type === 'success' && _style.default.successBanner, temporary && _style.default.temporaryBanner),
|
|
41
43
|
title: message
|
|
42
44
|
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
@@ -66,6 +68,7 @@ const Banner = props => {
|
|
|
66
68
|
};
|
|
67
69
|
|
|
68
70
|
Banner.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
71
|
+
bannerKey: _propTypes.default.string,
|
|
69
72
|
type: _propTypes.default.oneOf((0, _keys2.default)(ICONS)),
|
|
70
73
|
message: _propTypes.default.string.isRequired,
|
|
71
74
|
firstCTA: _propTypes.default.func,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/molecule/banner/index.js"],"names":["ICONS","success","ValidateIcon","error","QuestionIcon","warning","Banner","props","type","message","firstCTA","firstCTALabel","secondCTALabel","secondCTA","temporary","Icon","style","banner","errorBanner","successBanner","temporaryBanner","icon","temporaryIcon","button","buttonsBar","propTypes","PropTypes","
|
|
1
|
+
{"version":3,"sources":["../../../src/molecule/banner/index.js"],"names":["ICONS","success","ValidateIcon","error","QuestionIcon","warning","Banner","props","type","message","firstCTA","firstCTALabel","secondCTALabel","secondCTA","temporary","bannerKey","Icon","style","banner","errorBanner","successBanner","temporaryBanner","icon","temporaryIcon","button","buttonsBar","propTypes","PropTypes","string","oneOf","isRequired","func","bool"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AAEA;;AAIA;;AACA;;;;AAEA,MAAMA,KAAK,GAAG;AACZC,EAAAA,OAAO,EAAEC,8CADG;AAEZC,EAAAA,KAAK,EAAEC,0DAFK;AAGZC,EAAAA,OAAO,EAAED;AAHG,CAAd;;AAMA,MAAME,MAAM,GAAGC,KAAK,IAAI;AACtB,QAAM;AACJC,IAAAA,IADI;AAEJC,IAAAA,OAFI;AAGJC,IAAAA,QAHI;AAIJC,IAAAA,aAJI;AAKJC,IAAAA,cALI;AAMJC,IAAAA,SANI;AAOJC,IAAAA,SAPI;AAQJC,IAAAA;AARI,MASFR,KATJ;AAUA,QAAMS,IAAI,GAAGhB,KAAK,CAACQ,IAAD,CAAlB;AACA,sBACE;AACE,IAAA,GAAG,EAAEO,SADP;AAEE,IAAA,SAAS,EAAE,yBACTE,eAAMC,MADG,EAETV,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B,EAAAA,aAAa,EAAEgB,mBAAUC,MALR;AAMjBhB,EAAAA,cAAc,EAAEe,mBAAUC,MANT;AAOjBf,EAAAA,SAAS,EAAEc,mBAAUI,IAPJ;AAQjBjB,EAAAA,SAAS,EAAEa,mBAAUK;AARJ,CAAnB;eAWe1B,M","sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport classnames from 'classnames';\nimport {keys} from 'lodash/fp';\nimport {\n NovaSolidInterfaceFeedbackInterfaceAlertDiamond as QuestionIcon,\n NovaCompositionCoorpacademyValidate as ValidateIcon\n} from '@coorpacademy/nova-icons';\nimport Link from '../../atom/button-link';\nimport style from './style.css';\n\nconst ICONS = {\n success: ValidateIcon,\n error: QuestionIcon,\n warning: QuestionIcon\n};\n\nconst Banner = props => {\n const {\n type,\n message,\n firstCTA,\n firstCTALabel,\n secondCTALabel,\n secondCTA,\n temporary,\n bannerKey\n } = props;\n const Icon = ICONS[type];\n return (\n <div\n key={bannerKey}\n className={classnames(\n style.banner,\n type === 'error' && style.errorBanner,\n type === 'success' && style.successBanner,\n temporary && style.temporaryBanner\n )}\n title={message}\n >\n <div data-name={`${type}-banner-message`} className={style.message}>\n <Icon className={classnames(style.icon, temporary && style.temporaryIcon)} />\n {message}\n </div>\n {firstCTALabel ? (\n <div className={style.button}>\n <Link\n data-name=\"first-banner-cta\"\n aria-label={firstCTALabel}\n label={firstCTALabel}\n onClick={firstCTA}\n type=\"text\"\n />\n </div>\n ) : null}\n {firstCTALabel && secondCTALabel ? <div className={style.buttonsBar} /> : null}\n {secondCTALabel ? (\n <div className={style.button}>\n <Link\n data-name=\"second-banner-cta\"\n onClick={secondCTA}\n aria-label={secondCTALabel}\n label={secondCTALabel}\n type=\"text\"\n />\n </div>\n ) : null}\n </div>\n );\n};\n\nBanner.propTypes = {\n bannerKey: PropTypes.string,\n type: PropTypes.oneOf(keys(ICONS)),\n message: PropTypes.string.isRequired,\n firstCTA: PropTypes.func,\n firstCTALabel: PropTypes.string,\n secondCTALabel: PropTypes.string,\n secondCTA: PropTypes.func,\n temporary: PropTypes.bool\n};\n\nexport default Banner;\n"],"file":"index.js"}
|