@coorpacademy/components 11.35.2 → 11.35.3-forcedeploy3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/atom/button-link/index.js +1 -1
- package/es/atom/button-link/index.js.map +1 -1
- package/es/atom/button-link/style.css +2 -2
- package/es/atom/icon/index.d.ts +35 -17
- package/es/atom/icon/index.d.ts.map +1 -1
- package/es/atom/icon/index.js +32 -15
- package/es/atom/icon/index.js.map +1 -1
- package/es/atom/radio-with-title/index.d.ts +13 -3
- package/es/atom/radio-with-title/index.d.ts.map +1 -1
- package/es/atom/radio-with-title/types.d.ts +13 -2
- package/es/atom/radio-with-title/types.d.ts.map +1 -1
- package/es/atom/status-item/index.native.js +1 -1
- package/es/atom/status-item/index.native.js.map +1 -1
- package/es/atom/tag/index.d.ts +12 -1
- package/es/atom/tag/style.css +1 -0
- package/es/atom/title/index.d.ts +13 -2
- package/es/molecule/banner/style.css +1 -0
- package/es/molecule/base-modal/style.css +0 -1
- package/es/molecule/bulk-progress-bar/index.js +2 -2
- package/es/molecule/bulk-progress-bar/index.js.map +1 -1
- package/es/molecule/certification-card/index.js +1 -1
- package/es/molecule/certification-card/index.js.map +1 -1
- package/es/molecule/cm-popin/types.d.ts +28 -7
- package/es/molecule/cm-popin/types.d.ts.map +1 -1
- package/es/molecule/cm-popin/types.js +1 -1
- package/es/molecule/cm-popin/types.js.map +1 -1
- package/es/molecule/dashboard/cards-list/index.d.ts.map +1 -1
- package/es/molecule/dashboard/cards-list/index.js +2 -0
- package/es/molecule/dashboard/cards-list/index.js.map +1 -1
- package/es/molecule/icon-preview/index.d.ts.map +1 -1
- package/es/molecule/icon-preview/index.js +2 -1
- package/es/molecule/icon-preview/index.js.map +1 -1
- package/es/molecule/icon-preview/style.css +4 -0
- package/es/molecule/learner-skill-card/index.js +10 -8
- package/es/molecule/learner-skill-card/index.js.map +1 -1
- package/es/molecule/learner-skill-card/style.css +1 -0
- package/es/molecule/learning-priority-modal/style.css +3 -2
- package/es/molecule/progress-wrapper/index.js +1 -1
- package/es/molecule/progress-wrapper/index.js.map +1 -1
- package/es/molecule/skills-chart-side-information-item/index.d.ts +1 -1
- package/es/molecule/skills-chart-side-information-panel/index.d.ts +1 -1
- package/es/molecule/title-and-checkbox-wrapper/index.d.ts +13 -2
- package/es/molecule/title-radio-wrapper/index.d.ts +13 -3
- package/es/molecule/title-radio-wrapper/index.d.ts.map +1 -1
- package/es/molecule/title-radio-wrapper/types.d.ts +13 -2
- package/es/molecule/title-radio-wrapper/types.d.ts.map +1 -1
- package/es/organism/cards-grid/index.d.ts +48 -10
- package/es/organism/cards-grid/index.d.ts.map +1 -1
- package/es/organism/cards-grid/index.js +3 -2
- package/es/organism/cards-grid/index.js.map +1 -1
- package/es/organism/content-skill-modal/index.d.ts +13 -3
- package/es/organism/content-skill-modal/index.d.ts.map +1 -1
- package/es/organism/content-skill-modal/types.d.ts +12 -2
- package/es/organism/content-skill-modal/types.d.ts.map +1 -1
- package/es/organism/list-item/index.js +5 -5
- package/es/organism/list-item/index.js.map +1 -1
- package/es/organism/list-item/style.css +23 -17
- package/es/organism/list-items/index.d.ts +13 -2
- package/es/organism/rewards-form/index.d.ts +13 -2
- package/es/organism/select-opponents/index.d.ts +13 -3
- package/es/organism/select-opponents/index.d.ts.map +1 -1
- package/es/organism/select-opponents/types.d.ts +13 -2
- package/es/organism/select-opponents/types.d.ts.map +1 -1
- package/es/organism/sidebar/index.d.ts +2 -2
- package/es/organism/title-and-input/index.d.ts +25 -5
- package/es/organism/title-and-input/index.d.ts.map +1 -1
- package/es/organism/title-and-input/types.d.ts +24 -4
- package/es/organism/title-and-input/types.d.ts.map +1 -1
- package/es/organism/wizard-contents/index.d.ts +13 -2
- package/es/template/app-player/loading/index.d.ts +27 -6
- package/es/template/app-player/player/index.d.ts +53 -12
- package/es/template/app-player/player/slides/index.d.ts +27 -6
- package/es/template/app-player/player/slides/index.d.ts.map +1 -1
- package/es/template/app-player/popin-correction/index.d.ts +26 -6
- package/es/template/app-player/popin-correction/index.d.ts.map +1 -1
- package/es/template/app-player/popin-end/index.d.ts +27 -6
- package/es/template/app-review/index.d.ts +27 -7
- package/es/template/app-review/index.d.ts.map +1 -1
- package/es/template/app-review/player/prop-types.d.ts +27 -6
- package/es/template/app-review/player/prop-types.d.ts.map +1 -1
- package/es/template/app-review/prop-types.d.ts +27 -6
- package/es/template/app-review/prop-types.d.ts.map +1 -1
- package/es/template/back-office/brand-update/index.d.ts +63 -12
- package/es/template/back-office/brand-update/utils.d.ts +1 -1
- package/es/template/common/dashboard/index.d.ts +53 -12
- package/es/template/common/search-page/index.d.ts +27 -6
- package/es/template/external-course/index.d.ts +27 -6
- package/es/template/skill-detail/all-courses.css +3 -2
- package/es/template/skill-detail/all-courses.d.ts +52 -17
- package/es/template/skill-detail/all-courses.d.ts.map +1 -1
- package/es/template/skill-detail/all-courses.js +12 -11
- package/es/template/skill-detail/all-courses.js.map +1 -1
- package/es/template/skill-detail/continue-learning.css +7 -2
- package/es/template/skill-detail/continue-learning.d.ts +25 -12
- package/es/template/skill-detail/continue-learning.d.ts.map +1 -1
- package/es/template/skill-detail/continue-learning.js.map +1 -1
- package/es/template/skill-detail/index.d.ts +89 -71
- package/es/template/skill-detail/index.d.ts.map +1 -1
- package/es/template/skill-detail/index.js +95 -55
- package/es/template/skill-detail/index.js.map +1 -1
- package/es/template/skill-detail/style.css +97 -39
- package/es/variables/colors.css +2 -0
- package/es/variables/colors.d.ts +3 -2
- package/es/variables/colors.d.ts.map +1 -1
- package/es/variables/colors.js +4 -3
- package/es/variables/colors.js.map +1 -1
- package/es/variables/theme.native.js +1 -1
- package/es/variables/theme.native.js.map +1 -1
- package/lib/atom/button-link/index.js +1 -1
- package/lib/atom/button-link/index.js.map +1 -1
- package/lib/atom/button-link/style.css +2 -2
- package/lib/atom/icon/index.d.ts +35 -17
- package/lib/atom/icon/index.d.ts.map +1 -1
- package/lib/atom/icon/index.js +34 -18
- package/lib/atom/icon/index.js.map +1 -1
- package/lib/atom/radio-with-title/index.d.ts +13 -3
- package/lib/atom/radio-with-title/index.d.ts.map +1 -1
- package/lib/atom/radio-with-title/types.d.ts +13 -2
- package/lib/atom/radio-with-title/types.d.ts.map +1 -1
- package/lib/atom/status-item/index.native.js +1 -1
- package/lib/atom/status-item/index.native.js.map +1 -1
- package/lib/atom/tag/index.d.ts +12 -1
- package/lib/atom/tag/style.css +1 -0
- package/lib/atom/title/index.d.ts +13 -2
- package/lib/molecule/banner/style.css +1 -0
- package/lib/molecule/base-modal/style.css +0 -1
- package/lib/molecule/bulk-progress-bar/index.js +2 -2
- package/lib/molecule/bulk-progress-bar/index.js.map +1 -1
- package/lib/molecule/certification-card/index.js +1 -1
- package/lib/molecule/certification-card/index.js.map +1 -1
- package/lib/molecule/cm-popin/types.d.ts +28 -7
- package/lib/molecule/cm-popin/types.d.ts.map +1 -1
- package/lib/molecule/cm-popin/types.js +1 -1
- package/lib/molecule/cm-popin/types.js.map +1 -1
- package/lib/molecule/dashboard/cards-list/index.d.ts.map +1 -1
- package/lib/molecule/dashboard/cards-list/index.js +2 -0
- package/lib/molecule/dashboard/cards-list/index.js.map +1 -1
- package/lib/molecule/icon-preview/index.d.ts.map +1 -1
- package/lib/molecule/icon-preview/index.js +2 -1
- package/lib/molecule/icon-preview/index.js.map +1 -1
- package/lib/molecule/icon-preview/style.css +4 -0
- package/lib/molecule/learner-skill-card/index.js +10 -8
- package/lib/molecule/learner-skill-card/index.js.map +1 -1
- package/lib/molecule/learner-skill-card/style.css +1 -0
- package/lib/molecule/learning-priority-modal/style.css +3 -2
- package/lib/molecule/progress-wrapper/index.js +1 -1
- package/lib/molecule/progress-wrapper/index.js.map +1 -1
- package/lib/molecule/skills-chart-side-information-item/index.d.ts +1 -1
- package/lib/molecule/skills-chart-side-information-panel/index.d.ts +1 -1
- package/lib/molecule/title-and-checkbox-wrapper/index.d.ts +13 -2
- package/lib/molecule/title-radio-wrapper/index.d.ts +13 -3
- package/lib/molecule/title-radio-wrapper/index.d.ts.map +1 -1
- package/lib/molecule/title-radio-wrapper/types.d.ts +13 -2
- package/lib/molecule/title-radio-wrapper/types.d.ts.map +1 -1
- package/lib/organism/cards-grid/index.d.ts +48 -10
- package/lib/organism/cards-grid/index.d.ts.map +1 -1
- package/lib/organism/cards-grid/index.js +3 -2
- package/lib/organism/cards-grid/index.js.map +1 -1
- package/lib/organism/content-skill-modal/index.d.ts +13 -3
- package/lib/organism/content-skill-modal/index.d.ts.map +1 -1
- package/lib/organism/content-skill-modal/types.d.ts +12 -2
- package/lib/organism/content-skill-modal/types.d.ts.map +1 -1
- package/lib/organism/list-item/index.js +5 -5
- package/lib/organism/list-item/index.js.map +1 -1
- package/lib/organism/list-item/style.css +23 -17
- package/lib/organism/list-items/index.d.ts +13 -2
- package/lib/organism/rewards-form/index.d.ts +13 -2
- package/lib/organism/select-opponents/index.d.ts +13 -3
- package/lib/organism/select-opponents/index.d.ts.map +1 -1
- package/lib/organism/select-opponents/types.d.ts +13 -2
- package/lib/organism/select-opponents/types.d.ts.map +1 -1
- package/lib/organism/sidebar/index.d.ts +2 -2
- package/lib/organism/title-and-input/index.d.ts +25 -5
- package/lib/organism/title-and-input/index.d.ts.map +1 -1
- package/lib/organism/title-and-input/types.d.ts +24 -4
- package/lib/organism/title-and-input/types.d.ts.map +1 -1
- package/lib/organism/wizard-contents/index.d.ts +13 -2
- package/lib/template/app-player/loading/index.d.ts +27 -6
- package/lib/template/app-player/player/index.d.ts +53 -12
- package/lib/template/app-player/player/slides/index.d.ts +27 -6
- package/lib/template/app-player/player/slides/index.d.ts.map +1 -1
- package/lib/template/app-player/popin-correction/index.d.ts +26 -6
- package/lib/template/app-player/popin-correction/index.d.ts.map +1 -1
- package/lib/template/app-player/popin-end/index.d.ts +27 -6
- package/lib/template/app-review/index.d.ts +27 -7
- package/lib/template/app-review/index.d.ts.map +1 -1
- package/lib/template/app-review/player/prop-types.d.ts +27 -6
- package/lib/template/app-review/player/prop-types.d.ts.map +1 -1
- package/lib/template/app-review/prop-types.d.ts +27 -6
- package/lib/template/app-review/prop-types.d.ts.map +1 -1
- package/lib/template/back-office/brand-update/index.d.ts +63 -12
- package/lib/template/back-office/brand-update/utils.d.ts +1 -1
- package/lib/template/common/dashboard/index.d.ts +53 -12
- package/lib/template/common/search-page/index.d.ts +27 -6
- package/lib/template/external-course/index.d.ts +27 -6
- package/lib/template/skill-detail/all-courses.css +3 -2
- package/lib/template/skill-detail/all-courses.d.ts +52 -17
- package/lib/template/skill-detail/all-courses.d.ts.map +1 -1
- package/lib/template/skill-detail/all-courses.js +11 -11
- package/lib/template/skill-detail/all-courses.js.map +1 -1
- package/lib/template/skill-detail/continue-learning.css +7 -2
- package/lib/template/skill-detail/continue-learning.d.ts +25 -12
- package/lib/template/skill-detail/continue-learning.d.ts.map +1 -1
- package/lib/template/skill-detail/continue-learning.js.map +1 -1
- package/lib/template/skill-detail/index.d.ts +89 -71
- package/lib/template/skill-detail/index.d.ts.map +1 -1
- package/lib/template/skill-detail/index.js +95 -55
- package/lib/template/skill-detail/index.js.map +1 -1
- package/lib/template/skill-detail/style.css +97 -39
- package/lib/variables/colors.css +2 -0
- package/lib/variables/colors.d.ts +3 -2
- package/lib/variables/colors.d.ts.map +1 -1
- package/lib/variables/colors.js +4 -3
- package/lib/variables/colors.js.map +1 -1
- package/lib/variables/theme.native.js +1 -1
- package/lib/variables/theme.native.js.map +1 -1
- package/package.json +2 -2
|
@@ -1,8 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import PropTypes from 'prop-types';
|
|
3
|
+
import { CardsGridProps } from '../../organism/cards-grid';
|
|
4
|
+
interface ProviderContext {
|
|
5
|
+
skin: {
|
|
6
|
+
common: {
|
|
7
|
+
primary: string;
|
|
8
|
+
secondary: string;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
translate: (key: string, options?: any) => string;
|
|
12
|
+
}
|
|
13
|
+
declare const ContinueLearning: {
|
|
14
|
+
(props: {
|
|
15
|
+
ongoingCourses: CardsGridProps;
|
|
16
|
+
}, context: ProviderContext): JSX.Element | null;
|
|
17
|
+
contextTypes: {
|
|
18
|
+
skin: PropTypes.Requireable<PropTypes.InferProps<{
|
|
6
19
|
common: PropTypes.Requireable<{
|
|
7
20
|
[x: string]: any;
|
|
8
21
|
}>;
|
|
@@ -23,17 +36,17 @@ declare namespace ContinueLearning {
|
|
|
23
36
|
[x: string]: any;
|
|
24
37
|
}>;
|
|
25
38
|
}>>;
|
|
26
|
-
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
|
|
39
|
+
translate: PropTypes.Requireable<(...args: any[]) => any>;
|
|
40
|
+
};
|
|
41
|
+
propTypes: {
|
|
42
|
+
ongoingCourses: PropTypes.Requireable<PropTypes.InferProps<{
|
|
30
43
|
list: PropTypes.Requireable<(PropTypes.InferProps<any> | null | undefined)[]>;
|
|
31
44
|
customStyle: PropTypes.Requireable<{
|
|
32
45
|
[x: string]: string | null | undefined;
|
|
33
46
|
}>;
|
|
34
47
|
loading: PropTypes.Requireable<boolean>;
|
|
35
48
|
}>>;
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
|
|
49
|
+
};
|
|
50
|
+
};
|
|
51
|
+
export default ContinueLearning;
|
|
39
52
|
//# sourceMappingURL=continue-learning.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"continue-learning.d.ts","sourceRoot":"","sources":["../../../src/template/skill-detail/continue-learning.
|
|
1
|
+
{"version":3,"file":"continue-learning.d.ts","sourceRoot":"","sources":["../../../src/template/skill-detail/continue-learning.tsx"],"names":[],"mappings":";AACA,OAAO,SAAS,MAAM,YAAY,CAAC;AAGnC,OAAkB,EAAC,cAAc,EAAC,MAAM,2BAA2B,CAAC;AAIpE,UAAU,eAAe;IACvB,IAAI,EAAE;QACJ,MAAM,EAAE;YACN,OAAO,EAAE,MAAM,CAAC;YAChB,SAAS,EAAE,MAAM,CAAC;SACnB,CAAC;KACH,CAAC;IACF,SAAS,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,GAAG,KAAK,MAAM,CAAC;CACnD;AAED,QAAA,MAAM,gBAAgB;YAAW;QAAC,cAAc,EAAE,cAAc,CAAA;KAAC,WAAW,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0B1F,CAAC;AAWF,eAAe,gBAAgB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"continue-learning.js","names":["React","useCallback","PropTypes","Provider","CardsGrid","CardsList","style","ContinueLearning","props","context","ongoingCourses","translate","Title","createElement","Fragment","className","continueLearningTitle","continueLearningNumber","list","length","cards","_sortBy","course","_getOr","title","customStyle","padding","contextTypes","skin","childContextTypes","propTypes","process","env","NODE_ENV","shape"],"sources":["../../../src/template/skill-detail/continue-learning.
|
|
1
|
+
{"version":3,"file":"continue-learning.js","names":["React","useCallback","PropTypes","Provider","CardsGrid","CardsList","style","ContinueLearning","props","context","ongoingCourses","translate","Title","createElement","Fragment","className","continueLearningTitle","continueLearningNumber","list","length","cards","_sortBy","course","_getOr","title","customStyle","padding","contextTypes","skin","childContextTypes","propTypes","process","env","NODE_ENV","shape"],"sources":["../../../src/template/skill-detail/continue-learning.tsx"],"sourcesContent":["import React, {useCallback} from 'react';\nimport PropTypes from 'prop-types';\nimport {getOr, sortBy} from 'lodash/fp';\nimport Provider from '../../atom/provider';\nimport CardsGrid, {CardsGridProps} from '../../organism/cards-grid';\nimport CardsList from '../../molecule/dashboard/cards-list';\nimport style from './continue-learning.css';\n\ninterface ProviderContext {\n skin: {\n common: {\n primary: string;\n secondary: string;\n };\n };\n translate: (key: string, options?: any) => string;\n}\n\nconst ContinueLearning = (props: {ongoingCourses: CardsGridProps}, context: ProviderContext) => {\n const {ongoingCourses} = props;\n const {translate} = context;\n\n const Title = useCallback(\n () => (\n <>\n <span className={style.continueLearningTitle}>{translate('continue_learning')}</span>\n <span className={style.continueLearningNumber}>{ongoingCourses.list.length}</span>\n </>\n ),\n [ongoingCourses, translate]\n );\n\n if (ongoingCourses.list.length === 0) {\n return null;\n }\n\n return (\n <CardsList\n cards={sortBy(course => -getOr(0, ['progress'], course), ongoingCourses.list)}\n title={<Title />}\n // to override CardList wrapper padding\n customStyle={{padding: '0px'}}\n />\n );\n};\n\nContinueLearning.contextTypes = {\n skin: Provider.childContextTypes.skin,\n translate: Provider.childContextTypes.translate\n};\n\nContinueLearning.propTypes = {\n ongoingCourses: PropTypes.shape(CardsGrid.propTypes)\n};\n\nexport default ContinueLearning;\n"],"mappings":";;AAAA,OAAOA,KAAK,IAAGC,WAAW,QAAO,OAAO;AACxC,OAAOC,SAAS,MAAM,YAAY;AAElC,OAAOC,QAAQ,MAAM,qBAAqB;AAC1C,OAAOC,SAAS,MAAwB,2BAA2B;AACnE,OAAOC,SAAS,MAAM,qCAAqC;AAC3D,OAAOC,KAAK,MAAM,yBAAyB;AAY3C,MAAMC,gBAAgB,GAAGA,CAACC,KAAuC,EAAEC,OAAwB,KAAK;EAC9F,MAAM;IAACC;EAAc,CAAC,GAAGF,KAAK;EAC9B,MAAM;IAACG;EAAS,CAAC,GAAGF,OAAO;EAE3B,MAAMG,KAAK,GAAGX,WAAW,CACvB,mBACED,KAAA,CAAAa,aAAA,CAAAb,KAAA,CAAAc,QAAA,qBACEd,KAAA,CAAAa,aAAA;IAAME,SAAS,EAAET,KAAK,CAACU;EAAsB,GAAEL,SAAS,CAAC,mBAAmB,CAAQ,CAAC,eACrFX,KAAA,CAAAa,aAAA;IAAME,SAAS,EAAET,KAAK,CAACW;EAAuB,GAAEP,cAAc,CAACQ,IAAI,CAACC,MAAa,CACjF,CACH,EACD,CAACT,cAAc,EAAEC,SAAS,CAC5B,CAAC;EAED,IAAID,cAAc,CAACQ,IAAI,CAACC,MAAM,KAAK,CAAC,EAAE;IACpC,OAAO,IAAI;EACb;EAEA,oBACEnB,KAAA,CAAAa,aAAA,CAACR,SAAS;IACRe,KAAK,EAAEC,OAAA,CAAOC,MAAM,IAAI,CAACC,MAAA,CAAM,CAAC,EAAE,CAAC,UAAU,CAAC,EAAED,MAAM,CAAC,EAAEZ,cAAc,CAACQ,IAAI,CAAE;IAC9EM,KAAK,eAAExB,KAAA,CAAAa,aAAA,CAACD,KAAK,MAAE;IACf;IAAA;IACAa,WAAW,EAAE;MAACC,OAAO,EAAE;IAAK;EAAE,CAC/B,CAAC;AAEN,CAAC;AAEDnB,gBAAgB,CAACoB,YAAY,GAAG;EAC9BC,IAAI,EAAEzB,QAAQ,CAAC0B,iBAAiB,CAACD,IAAI;EACrCjB,SAAS,EAAER,QAAQ,CAAC0B,iBAAiB,CAAClB;AACxC,CAAC;AAEDJ,gBAAgB,CAACuB,SAAS,GAAAC,OAAA,CAAAC,GAAA,CAAAC,QAAA,oBAAG;EAC3BvB,cAAc,EAAER,SAAS,CAACgC,KAAK,CAAC9B,SAAS,CAAC0B,SAAS;AACrD,CAAC;AAED,eAAevB,gBAAgB","ignoreList":[]}
|
|
@@ -1,7 +1,23 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import PropTypes from 'prop-types';
|
|
3
|
+
import { CardsGridProps } from '../../organism/cards-grid';
|
|
4
|
+
interface ContinueLearningButtonProps {
|
|
5
|
+
ongoingCoursesAvailable?: boolean;
|
|
6
|
+
onClick?: () => void;
|
|
7
|
+
}
|
|
8
|
+
interface ProviderContext {
|
|
9
|
+
skin: {
|
|
10
|
+
common: {
|
|
11
|
+
primary: string;
|
|
12
|
+
secondary: string;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
translate: (key: string) => string;
|
|
16
|
+
}
|
|
17
|
+
export declare const ContinueLearningButton: {
|
|
18
|
+
(props: ContinueLearningButtonProps, context: ProviderContext): JSX.Element;
|
|
19
|
+
contextTypes: {
|
|
20
|
+
skin: PropTypes.Requireable<PropTypes.InferProps<{
|
|
5
21
|
common: PropTypes.Requireable<{
|
|
6
22
|
[x: string]: any;
|
|
7
23
|
}>;
|
|
@@ -22,19 +38,53 @@ export namespace ContinueLearningButton {
|
|
|
22
38
|
[x: string]: any;
|
|
23
39
|
}>;
|
|
24
40
|
}>>;
|
|
25
|
-
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
}
|
|
41
|
+
translate: PropTypes.Requireable<(...args: any[]) => any>;
|
|
42
|
+
};
|
|
43
|
+
propTypes: {
|
|
44
|
+
ongoingCoursesAvailable: PropTypes.Requireable<boolean>;
|
|
45
|
+
onClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
interface Metrics {
|
|
49
|
+
score?: number;
|
|
50
|
+
questionsToReview?: number;
|
|
51
|
+
totalContents?: number;
|
|
31
52
|
}
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
53
|
+
declare type BannerMicrolearning = Record<string, never> | {
|
|
54
|
+
action: () => void;
|
|
55
|
+
oldSwitchValue: boolean;
|
|
56
|
+
};
|
|
57
|
+
interface SkillDetailProps {
|
|
58
|
+
title: string;
|
|
59
|
+
icon: {
|
|
60
|
+
name: string;
|
|
61
|
+
color: string;
|
|
62
|
+
};
|
|
63
|
+
skillRef: string;
|
|
64
|
+
description?: string;
|
|
65
|
+
metrics?: Metrics;
|
|
66
|
+
focused?: boolean;
|
|
67
|
+
availableForReview?: boolean;
|
|
68
|
+
ongoingCoursesAvailable?: boolean;
|
|
69
|
+
skillIncludedCourses: CardsGridProps;
|
|
70
|
+
filters: {
|
|
71
|
+
onChange?: () => void;
|
|
72
|
+
options?: unknown[];
|
|
73
|
+
};
|
|
74
|
+
onBackClick?: () => void;
|
|
75
|
+
onReviewClick?: () => void;
|
|
76
|
+
onContinueLearningClick?: () => void;
|
|
77
|
+
search: {
|
|
78
|
+
oldValue: string;
|
|
79
|
+
onChange: () => void;
|
|
80
|
+
};
|
|
81
|
+
bannerMicrolearning?: BannerMicrolearning;
|
|
82
|
+
}
|
|
83
|
+
declare const SkillDetail: {
|
|
84
|
+
(props: SkillDetailProps, context: ProviderContext): JSX.Element;
|
|
85
|
+
contextTypes: {
|
|
86
|
+
translate: PropTypes.Requireable<(...args: any[]) => any>;
|
|
87
|
+
skin: PropTypes.Requireable<PropTypes.InferProps<{
|
|
38
88
|
common: PropTypes.Requireable<{
|
|
39
89
|
[x: string]: any;
|
|
40
90
|
}>;
|
|
@@ -55,32 +105,31 @@ declare namespace SkillDetail {
|
|
|
55
105
|
[x: string]: any;
|
|
56
106
|
}>;
|
|
57
107
|
}>>;
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
108
|
+
};
|
|
109
|
+
propTypes: {
|
|
110
|
+
title: PropTypes.Validator<string>;
|
|
111
|
+
icon: PropTypes.Validator<NonNullable<PropTypes.InferProps<{
|
|
112
|
+
name: PropTypes.Requireable<string>;
|
|
113
|
+
color: PropTypes.Requireable<string>;
|
|
114
|
+
}>>>;
|
|
115
|
+
skillRef: PropTypes.Validator<string>;
|
|
116
|
+
description: PropTypes.Requireable<string>;
|
|
117
|
+
metrics: PropTypes.Requireable<PropTypes.InferProps<{
|
|
68
118
|
score: PropTypes.Requireable<number>;
|
|
69
119
|
questionsToReview: PropTypes.Requireable<number>;
|
|
70
120
|
totalContents: PropTypes.Requireable<number>;
|
|
71
121
|
}>>;
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
export const skillIncludedCourses: PropTypes.Requireable<PropTypes.InferProps<{
|
|
122
|
+
focused: PropTypes.Requireable<boolean>;
|
|
123
|
+
availableForReview: PropTypes.Requireable<boolean>;
|
|
124
|
+
ongoingCoursesAvailable: PropTypes.Requireable<boolean>;
|
|
125
|
+
skillIncludedCourses: PropTypes.Requireable<PropTypes.InferProps<{
|
|
77
126
|
list: PropTypes.Requireable<(PropTypes.InferProps<any> | null | undefined)[]>;
|
|
78
127
|
customStyle: PropTypes.Requireable<{
|
|
79
128
|
[x: string]: string | null | undefined;
|
|
80
129
|
}>;
|
|
81
130
|
loading: PropTypes.Requireable<boolean>;
|
|
82
131
|
}>>;
|
|
83
|
-
|
|
132
|
+
filters: PropTypes.Requireable<PropTypes.InferProps<{
|
|
84
133
|
onChange: PropTypes.Requireable<(...args: any[]) => any>;
|
|
85
134
|
options: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
86
135
|
name: PropTypes.Validator<string>;
|
|
@@ -89,49 +138,18 @@ declare namespace SkillDetail {
|
|
|
89
138
|
validOption: PropTypes.Requireable<boolean>;
|
|
90
139
|
}> | null | undefined)[]>;
|
|
91
140
|
}>>;
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
borderClassName: PropTypes.Requireable<string>;
|
|
97
|
-
disabled: PropTypes.Requireable<boolean>;
|
|
98
|
-
multiple: PropTypes.Requireable<boolean>;
|
|
99
|
-
description: PropTypes.Requireable<string>;
|
|
100
|
-
required: PropTypes.Requireable<boolean>;
|
|
101
|
-
onChange: PropTypes.Requireable<(...args: any[]) => any>;
|
|
102
|
-
theme: PropTypes.Requireable<string>;
|
|
103
|
-
options: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
104
|
-
name: PropTypes.Validator<string>;
|
|
105
|
-
value: PropTypes.Requireable<NonNullable<string | number | null | undefined>>;
|
|
106
|
-
selected: PropTypes.Requireable<boolean>;
|
|
107
|
-
validOption: PropTypes.Requireable<boolean>;
|
|
108
|
-
}> | null | undefined)[]>;
|
|
109
|
-
optgroups: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
110
|
-
label: PropTypes.Validator<string>;
|
|
111
|
-
options: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
112
|
-
name: PropTypes.Validator<string>;
|
|
113
|
-
value: PropTypes.Requireable<NonNullable<string | number | null | undefined>>;
|
|
114
|
-
selected: PropTypes.Requireable<boolean>;
|
|
115
|
-
validOption: PropTypes.Requireable<boolean>;
|
|
116
|
-
}> | null | undefined)[]>;
|
|
117
|
-
}> | null | undefined)[]>;
|
|
118
|
-
modified: PropTypes.Requireable<boolean>;
|
|
119
|
-
error: PropTypes.Requireable<boolean>;
|
|
120
|
-
'aria-label': PropTypes.Requireable<string>;
|
|
121
|
-
'aria-labelledby': PropTypes.Requireable<string>;
|
|
122
|
-
}>>;
|
|
123
|
-
export const onBackClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
124
|
-
export const onReviewClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
125
|
-
export const onContinueLearningClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
126
|
-
export const search: PropTypes.Requireable<PropTypes.InferProps<{
|
|
141
|
+
onBackClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
142
|
+
onReviewClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
143
|
+
onContinueLearningClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
144
|
+
search: PropTypes.Requireable<PropTypes.InferProps<{
|
|
127
145
|
oldValue: PropTypes.Requireable<string>;
|
|
128
146
|
onChange: PropTypes.Requireable<(...args: any[]) => any>;
|
|
129
147
|
}>>;
|
|
130
|
-
|
|
148
|
+
bannerMicrolearning: PropTypes.Requireable<PropTypes.InferProps<{
|
|
131
149
|
action: PropTypes.Requireable<(...args: any[]) => any>;
|
|
132
150
|
oldSwitchValue: PropTypes.Requireable<boolean>;
|
|
133
151
|
}>>;
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
|
|
152
|
+
};
|
|
153
|
+
};
|
|
154
|
+
export default SkillDetail;
|
|
137
155
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/template/skill-detail/index.
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/template/skill-detail/index.tsx"],"names":[],"mappings":";AACA,OAAO,SAAS,MAAM,YAAY,CAAC;AAUnC,OAAkB,EAAC,cAAc,EAAC,MAAM,2BAA2B,CAAC;AAMpE,UAAU,2BAA2B;IACnC,uBAAuB,CAAC,EAAE,OAAO,CAAC;IAClC,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB;AACD,UAAU,eAAe;IACvB,IAAI,EAAE;QACJ,MAAM,EAAE;YACN,OAAO,EAAE,MAAM,CAAC;YAChB,SAAS,EAAE,MAAM,CAAC;SACnB,CAAC;KACH,CAAC;IACF,SAAS,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CACpC;AAED,eAAO,MAAM,sBAAsB;YAC1B,2BAA2B,WACzB,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA4BzB,CAAC;AAYF,UAAU,OAAO;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,aAAK,mBAAmB,GACpB,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,GACrB;IACE,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,cAAc,EAAE,OAAO,CAAC;CACzB,CAAC;AACN,UAAU,gBAAgB;IACxB,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAC,CAAC;IACpC,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,uBAAuB,CAAC,EAAE,OAAO,CAAC;IAClC,oBAAoB,EAAE,cAAc,CAAC;IACrC,OAAO,EAAE;QACP,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;QACtB,OAAO,CAAC,EAAE,OAAO,EAAE,CAAC;KACrB,CAAC;IACF,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;IACzB,aAAa,CAAC,EAAE,MAAM,IAAI,CAAC;IAC3B,uBAAuB,CAAC,EAAE,MAAM,IAAI,CAAC;IACrC,MAAM,EAAE;QACN,QAAQ,EAAE,MAAM,CAAC;QACjB,QAAQ,EAAE,MAAM,IAAI,CAAC;KACtB,CAAC;IACF,mBAAmB,CAAC,EAAE,mBAAmB,CAAC;CAC3C;AACD,QAAA,MAAM,WAAW;YAAW,gBAAgB,WAAW,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0MrE,CAAC;AAyCF,eAAe,WAAW,CAAC"}
|
|
@@ -2,18 +2,19 @@ import _isNil from "lodash/fp/isNil";
|
|
|
2
2
|
import _get from "lodash/fp/get";
|
|
3
3
|
import React, { useCallback, useState, useRef, useEffect } from 'react';
|
|
4
4
|
import PropTypes from 'prop-types';
|
|
5
|
-
import { convert } from 'css-color-function';
|
|
6
5
|
import classnames from 'classnames';
|
|
7
6
|
import Markdown from 'markdown-to-jsx';
|
|
7
|
+
import { convert } from 'css-color-function';
|
|
8
8
|
import Provider from '../../atom/provider';
|
|
9
|
-
import Select, { SelectOptionPropTypes } from '../../atom/select';
|
|
10
|
-
import ButtonLink from '../../atom/button-link';
|
|
11
9
|
import ButtonLinkIcon from '../../atom/button-link-icon';
|
|
12
10
|
import Icon from '../../atom/icon';
|
|
11
|
+
import IconPreview from '../../molecule/icon-preview';
|
|
12
|
+
import ButtonLink from '../../atom/button-link';
|
|
13
13
|
import CardsGrid from '../../organism/cards-grid';
|
|
14
14
|
import { COLORS } from '../../variables/colors';
|
|
15
|
-
import
|
|
15
|
+
import { SelectOptionPropTypes } from '../../atom/select';
|
|
16
16
|
import AllCourses from './all-courses';
|
|
17
|
+
import style from './style.css';
|
|
17
18
|
export const ContinueLearningButton = (props, context) => {
|
|
18
19
|
const {
|
|
19
20
|
ongoingCoursesAvailable,
|
|
@@ -24,7 +25,7 @@ export const ContinueLearningButton = (props, context) => {
|
|
|
24
25
|
translate
|
|
25
26
|
} = context;
|
|
26
27
|
const primarySkinColor = _get('common.primary', skin);
|
|
27
|
-
return /*#__PURE__*/React.createElement(
|
|
28
|
+
return /*#__PURE__*/React.createElement(ButtonLink, {
|
|
28
29
|
label: ongoingCoursesAvailable ? translate('continue_learning') : translate('start_learning'),
|
|
29
30
|
type: "primary",
|
|
30
31
|
customStyle: {
|
|
@@ -39,11 +40,11 @@ export const ContinueLearningButton = (props, context) => {
|
|
|
39
40
|
faIcon: {
|
|
40
41
|
name: 'play',
|
|
41
42
|
color: COLORS.white,
|
|
42
|
-
size:
|
|
43
|
+
size: 14
|
|
43
44
|
}
|
|
44
45
|
},
|
|
45
46
|
onClick: onClick
|
|
46
|
-
})
|
|
47
|
+
});
|
|
47
48
|
};
|
|
48
49
|
ContinueLearningButton.contextTypes = {
|
|
49
50
|
skin: Provider.childContextTypes.skin,
|
|
@@ -56,6 +57,10 @@ ContinueLearningButton.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
56
57
|
const SkillDetail = (props, context) => {
|
|
57
58
|
const {
|
|
58
59
|
title,
|
|
60
|
+
icon: {
|
|
61
|
+
color: iconColor,
|
|
62
|
+
name: iconName
|
|
63
|
+
},
|
|
59
64
|
skillRef,
|
|
60
65
|
description,
|
|
61
66
|
metrics = {},
|
|
@@ -64,29 +69,27 @@ const SkillDetail = (props, context) => {
|
|
|
64
69
|
ongoingCoursesAvailable,
|
|
65
70
|
skillIncludedCourses,
|
|
66
71
|
filters,
|
|
67
|
-
sorting,
|
|
68
72
|
onBackClick,
|
|
69
73
|
onReviewClick,
|
|
70
74
|
onContinueLearningClick,
|
|
71
75
|
search,
|
|
72
|
-
bannerMicrolearning
|
|
76
|
+
bannerMicrolearning
|
|
73
77
|
} = props;
|
|
74
|
-
const descriptionRef = useRef(null);
|
|
75
78
|
const {
|
|
76
79
|
score = 0,
|
|
77
|
-
questionsToReview,
|
|
78
|
-
totalContents
|
|
80
|
+
questionsToReview = 0,
|
|
81
|
+
totalContents = 0
|
|
79
82
|
} = metrics;
|
|
80
83
|
const {
|
|
81
84
|
translate
|
|
82
85
|
} = context;
|
|
83
|
-
const
|
|
84
|
-
|
|
85
|
-
oldSwitchValue
|
|
86
|
-
} = bannerMicrolearning;
|
|
86
|
+
const bannerMicrolearningAction = bannerMicrolearning?.action;
|
|
87
|
+
const descriptionRef = useRef(null);
|
|
87
88
|
const [isDescriptionTruncated, setIsDescriptionTruncated] = useState(false);
|
|
88
89
|
const [showMore, setShowMore] = useState(false);
|
|
89
|
-
const handleShowMore = useCallback(() =>
|
|
90
|
+
const handleShowMore = useCallback(() => {
|
|
91
|
+
setShowMore(!showMore);
|
|
92
|
+
}, [showMore]);
|
|
90
93
|
useEffect(() => {
|
|
91
94
|
if (descriptionRef.current) {
|
|
92
95
|
const {
|
|
@@ -100,29 +103,39 @@ const SkillDetail = (props, context) => {
|
|
|
100
103
|
return /*#__PURE__*/React.createElement("div", {
|
|
101
104
|
ref: descriptionRef,
|
|
102
105
|
className: classnames(style.description, !showMore && style.truncate)
|
|
103
|
-
}, /*#__PURE__*/React.createElement(Markdown, null, description));
|
|
106
|
+
}, description ? /*#__PURE__*/React.createElement(Markdown, null, description) : null);
|
|
104
107
|
}, [showMore, description]);
|
|
105
108
|
const ProgressBar = useCallback(() => {
|
|
106
|
-
if (score
|
|
107
|
-
const progressBarColor =
|
|
108
|
-
const
|
|
109
|
+
if (typeof score !== 'number') return null;
|
|
110
|
+
const progressBarColor = COLORS.cm_positive_500;
|
|
111
|
+
const inlineProgressStyle = {
|
|
109
112
|
backgroundColor: progressBarColor,
|
|
110
113
|
width: `${score}%`
|
|
111
114
|
};
|
|
112
115
|
return /*#__PURE__*/React.createElement("div", {
|
|
116
|
+
className: style.progressBarRow
|
|
117
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
113
118
|
className: style.progressBarWrapper
|
|
114
119
|
}, /*#__PURE__*/React.createElement("div", {
|
|
115
120
|
"data-name": "progress",
|
|
116
121
|
className: style.progress,
|
|
117
|
-
style:
|
|
118
|
-
role: "progressbar"
|
|
119
|
-
|
|
122
|
+
style: inlineProgressStyle,
|
|
123
|
+
role: "progressbar",
|
|
124
|
+
"aria-valuenow": score,
|
|
125
|
+
"aria-valuemin": 0,
|
|
126
|
+
"aria-valuemax": 100
|
|
127
|
+
})), /*#__PURE__*/React.createElement("span", {
|
|
128
|
+
className: style.progressInformationNumber
|
|
129
|
+
}, score.toFixed(1), "%"));
|
|
120
130
|
}, [score]);
|
|
131
|
+
const hasDescription = Boolean(description && description.trim().length > 0);
|
|
121
132
|
return /*#__PURE__*/React.createElement("div", {
|
|
122
133
|
className: style.backgroundContainer
|
|
123
134
|
}, /*#__PURE__*/React.createElement("div", {
|
|
124
135
|
className: style.container,
|
|
125
136
|
"data-name": skillRef
|
|
137
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
138
|
+
className: style.topSection
|
|
126
139
|
}, !_isNil(onBackClick) ? /*#__PURE__*/React.createElement(ButtonLinkIcon, {
|
|
127
140
|
faIcon: "arrow-left",
|
|
128
141
|
"data-name": "back-button",
|
|
@@ -130,9 +143,19 @@ const SkillDetail = (props, context) => {
|
|
|
130
143
|
onClick: onBackClick,
|
|
131
144
|
className: style.backButton,
|
|
132
145
|
tooltipPlacement: "right"
|
|
133
|
-
}) : null, /*#__PURE__*/React.createElement("div", {
|
|
134
|
-
className: style.
|
|
135
|
-
}, /*#__PURE__*/React.createElement("div",
|
|
146
|
+
}) : null), /*#__PURE__*/React.createElement("div", {
|
|
147
|
+
className: style.mainSection
|
|
148
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
149
|
+
className: style.leftSide
|
|
150
|
+
}, /*#__PURE__*/React.createElement(IconPreview, {
|
|
151
|
+
icon: {
|
|
152
|
+
name: iconName,
|
|
153
|
+
color: iconColor
|
|
154
|
+
},
|
|
155
|
+
title: title
|
|
156
|
+
})), /*#__PURE__*/React.createElement("div", {
|
|
157
|
+
className: style.rightSide
|
|
158
|
+
}, focused ? /*#__PURE__*/React.createElement("div", {
|
|
136
159
|
className: style.skillFocusBadge
|
|
137
160
|
}, /*#__PURE__*/React.createElement(Icon, {
|
|
138
161
|
iconName: "bullseye-arrow",
|
|
@@ -141,59 +164,77 @@ const SkillDetail = (props, context) => {
|
|
|
141
164
|
faSize: 10,
|
|
142
165
|
wrapperSize: 16
|
|
143
166
|
}
|
|
144
|
-
}), translate('skill_focus')) :
|
|
167
|
+
}), translate('skill_focus')) : /*#__PURE__*/React.createElement("div", {
|
|
168
|
+
className: style.skillBadge
|
|
169
|
+
}, /*#__PURE__*/React.createElement(Icon, {
|
|
170
|
+
iconName: "shapes",
|
|
171
|
+
backgroundColor: COLORS.gray,
|
|
172
|
+
size: {
|
|
173
|
+
faSize: 10,
|
|
174
|
+
wrapperSize: 16
|
|
175
|
+
}
|
|
176
|
+
}), translate('skill')), /*#__PURE__*/React.createElement("h2", {
|
|
145
177
|
className: style.title
|
|
146
|
-
}, title), description
|
|
178
|
+
}, title), description && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Description, null), isDescriptionTruncated ? /*#__PURE__*/React.createElement("div", {
|
|
147
179
|
className: style.showMoreWrapper,
|
|
148
180
|
onClick: handleShowMore
|
|
149
181
|
}, showMore ? translate('Show less') : translate('Show more'), /*#__PURE__*/React.createElement(Icon, {
|
|
150
182
|
iconName: showMore ? 'chevron-up' : 'chevron-down',
|
|
151
183
|
size: {
|
|
152
184
|
faSize: 14,
|
|
153
|
-
wrapperSize:
|
|
185
|
+
wrapperSize: 14
|
|
186
|
+
},
|
|
187
|
+
customStyle: {
|
|
188
|
+
padding: '8px'
|
|
154
189
|
}
|
|
155
|
-
})) : null)
|
|
190
|
+
})) : null), questionsToReview > 0 ? /*#__PURE__*/React.createElement("div", {
|
|
191
|
+
className: style.skillInformation
|
|
192
|
+
}, /*#__PURE__*/React.createElement("span", null, questionsToReview), "\xA0", translate('skill_chart_side_panel_questions_to_review')) : null, /*#__PURE__*/React.createElement("div", {
|
|
193
|
+
className: classnames(style.progressContainer, !hasDescription && style.noDescriptionSpacing)
|
|
194
|
+
}, /*#__PURE__*/React.createElement(ProgressBar, null)), /*#__PURE__*/React.createElement("div", {
|
|
156
195
|
className: style.ctaWrapper
|
|
157
|
-
}, /*#__PURE__*/React.createElement(
|
|
196
|
+
}, /*#__PURE__*/React.createElement(ContinueLearningButton, {
|
|
197
|
+
ongoingCoursesAvailable: ongoingCoursesAvailable,
|
|
198
|
+
onClick: onContinueLearningClick
|
|
199
|
+
}), /*#__PURE__*/React.createElement(ButtonLink, {
|
|
158
200
|
type: "secondary",
|
|
159
|
-
onClick: onReviewClick,
|
|
160
201
|
label: translate('review_this_skill'),
|
|
161
202
|
disabled: !availableForReview,
|
|
203
|
+
onClick: onReviewClick,
|
|
204
|
+
icon: {
|
|
205
|
+
position: 'left',
|
|
206
|
+
faIcon: {
|
|
207
|
+
name: 'rotate-right',
|
|
208
|
+
color: COLORS.cm_grey_700,
|
|
209
|
+
size: 14
|
|
210
|
+
}
|
|
211
|
+
},
|
|
162
212
|
customStyle: {
|
|
163
|
-
|
|
164
|
-
|
|
213
|
+
borderRadius: '12px',
|
|
214
|
+
width: 'fit-content'
|
|
165
215
|
}
|
|
166
|
-
}), /*#__PURE__*/React.createElement(
|
|
167
|
-
ongoingCoursesAvailable: ongoingCoursesAvailable,
|
|
168
|
-
onClick: onContinueLearningClick
|
|
169
|
-
}))), questionsToReview > 0 ? /*#__PURE__*/React.createElement("div", {
|
|
170
|
-
className: style.skillInformation,
|
|
171
|
-
"data-name": "skill-questions"
|
|
172
|
-
}, /*#__PURE__*/React.createElement("span", {
|
|
173
|
-
className: style.skillInformationNumber
|
|
174
|
-
}, questionsToReview), "\xA0", translate('skill_chart_side_panel_questions_to_review')) : null, /*#__PURE__*/React.createElement("div", {
|
|
175
|
-
className: style.progressContainer
|
|
176
|
-
}, /*#__PURE__*/React.createElement(ProgressBar, null), /*#__PURE__*/React.createElement("span", {
|
|
177
|
-
className: style.progressInformationNumber
|
|
178
|
-
}, score.toFixed(1), "%")), /*#__PURE__*/React.createElement(AllCourses, {
|
|
216
|
+
})))), /*#__PURE__*/React.createElement(AllCourses, {
|
|
179
217
|
content: skillIncludedCourses,
|
|
180
218
|
filters: filters,
|
|
181
|
-
sorting: sorting,
|
|
182
219
|
totalContents: totalContents,
|
|
183
|
-
bannerMicrolearning: bannerMicrolearningAction ? {
|
|
220
|
+
bannerMicrolearning: bannerMicrolearning && bannerMicrolearningAction ? {
|
|
184
221
|
type: 'skill',
|
|
185
222
|
action: bannerMicrolearningAction,
|
|
186
|
-
oldSwitchValue
|
|
187
|
-
} :
|
|
223
|
+
oldSwitchValue: bannerMicrolearning.oldSwitchValue
|
|
224
|
+
} : undefined,
|
|
188
225
|
search: search
|
|
189
226
|
})));
|
|
190
227
|
};
|
|
191
228
|
SkillDetail.contextTypes = {
|
|
192
|
-
|
|
193
|
-
|
|
229
|
+
translate: Provider.childContextTypes.translate,
|
|
230
|
+
skin: Provider.childContextTypes.skin
|
|
194
231
|
};
|
|
195
232
|
SkillDetail.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
196
233
|
title: PropTypes.string.isRequired,
|
|
234
|
+
icon: PropTypes.shape({
|
|
235
|
+
name: PropTypes.string,
|
|
236
|
+
color: PropTypes.string
|
|
237
|
+
}).isRequired,
|
|
197
238
|
skillRef: PropTypes.string.isRequired,
|
|
198
239
|
description: PropTypes.string,
|
|
199
240
|
metrics: PropTypes.shape({
|
|
@@ -209,7 +250,6 @@ SkillDetail.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
209
250
|
onChange: PropTypes.func,
|
|
210
251
|
options: PropTypes.arrayOf(PropTypes.shape(SelectOptionPropTypes))
|
|
211
252
|
}),
|
|
212
|
-
sorting: PropTypes.shape(Select.propTypes),
|
|
213
253
|
onBackClick: PropTypes.func,
|
|
214
254
|
onReviewClick: PropTypes.func,
|
|
215
255
|
onContinueLearningClick: PropTypes.func,
|