@coorpacademy/components 11.11.4 → 11.11.5
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/battle-opponent/index.d.ts +20 -0
- package/es/atom/battle-opponent/index.d.ts.map +1 -0
- package/es/atom/battle-opponent/index.js +104 -0
- package/es/atom/battle-opponent/index.js.map +1 -0
- package/es/atom/battle-opponent/prop-types.d.ts +21 -0
- package/es/atom/battle-opponent/prop-types.d.ts.map +1 -0
- package/es/atom/battle-opponent/prop-types.js +12 -0
- package/es/atom/battle-opponent/prop-types.js.map +1 -0
- package/es/atom/battle-opponent/style.css +133 -0
- package/es/atom/button-link-icon-only/index.d.ts.map +1 -1
- package/es/atom/button-link-icon-only/index.js +3 -2
- package/es/atom/button-link-icon-only/index.js.map +1 -1
- package/es/atom/button-link-icon-only/style.css +23 -0
- package/es/atom/{review-header-step-item → status-item}/index.d.ts +4 -4
- package/es/atom/status-item/index.d.ts.map +1 -0
- package/es/atom/status-item/index.js +104 -0
- package/es/atom/status-item/index.js.map +1 -0
- package/es/atom/status-item/index.native.d.ts +5 -0
- package/es/atom/status-item/index.native.d.ts.map +1 -0
- package/es/atom/{review-header-step-item → status-item}/index.native.js +2 -2
- package/es/atom/status-item/index.native.js.map +1 -0
- package/es/atom/{review-header-step-item → status-item}/style.css +47 -0
- package/es/atom/{review-header-step-item → status-item}/types.d.ts +5 -5
- package/es/atom/status-item/types.d.ts.map +1 -0
- package/es/atom/{review-header-step-item → status-item}/types.js +1 -1
- package/es/atom/status-item/types.js.map +1 -0
- package/es/atom/tooltip/index.d.ts +3 -1
- package/es/atom/tooltip/index.d.ts.map +1 -1
- package/es/atom/tooltip/index.js +18 -7
- package/es/atom/tooltip/index.js.map +1 -1
- package/es/atom/tooltip/style.css +11 -2
- package/es/globals.d.js.map +1 -1
- package/es/molecule/battle-opponent-list/index.d.ts +18 -0
- package/es/molecule/battle-opponent-list/index.d.ts.map +1 -0
- package/es/molecule/battle-opponent-list/index.js +25 -0
- package/es/molecule/battle-opponent-list/index.js.map +1 -0
- package/es/molecule/battle-opponent-list/prop-types.d.ts +26 -0
- package/es/molecule/battle-opponent-list/prop-types.d.ts.map +1 -0
- package/es/molecule/battle-opponent-list/prop-types.js +14 -0
- package/es/molecule/battle-opponent-list/prop-types.js.map +1 -0
- package/es/molecule/battle-opponent-list/style.css +5 -0
- package/es/molecule/review-header-steps/index.js +2 -2
- package/es/molecule/review-header-steps/index.js.map +1 -1
- package/es/molecule/review-header-steps/prop-types.d.ts +2 -2
- package/es/molecule/review-header-steps/prop-types.d.ts.map +1 -1
- package/es/molecule/review-header-steps/prop-types.js +1 -1
- package/es/molecule/review-header-steps/prop-types.js.map +1 -1
- package/es/organism/review-header/index.native.js +1 -1
- package/es/organism/review-header/index.native.js.map +1 -1
- package/es/organism/review-header/types.d.ts +2 -2
- package/es/organism/review-header/types.d.ts.map +1 -1
- package/es/organism/review-header/types.js.map +1 -1
- package/es/organism/user-preferences/index.d.ts.map +1 -1
- package/es/organism/user-preferences/index.js +6 -3
- package/es/organism/user-preferences/index.js.map +1 -1
- package/es/util/button-icons.d.ts +1 -0
- package/es/util/button-icons.d.ts.map +1 -1
- package/es/util/button-icons.js +3 -2
- package/es/util/button-icons.js.map +1 -1
- package/es/variables/colors.css +2 -0
- package/lib/atom/battle-opponent/index.d.ts +20 -0
- package/lib/atom/battle-opponent/index.d.ts.map +1 -0
- package/lib/atom/battle-opponent/index.js +124 -0
- package/lib/atom/battle-opponent/index.js.map +1 -0
- package/lib/atom/battle-opponent/prop-types.d.ts +21 -0
- package/lib/atom/battle-opponent/prop-types.d.ts.map +1 -0
- package/lib/atom/battle-opponent/prop-types.js +21 -0
- package/lib/atom/battle-opponent/prop-types.js.map +1 -0
- package/lib/atom/battle-opponent/style.css +133 -0
- package/lib/atom/button-link-icon-only/index.d.ts.map +1 -1
- package/lib/atom/button-link-icon-only/index.js +1 -1
- package/lib/atom/button-link-icon-only/index.js.map +1 -1
- package/lib/atom/button-link-icon-only/style.css +23 -0
- package/lib/atom/{review-header-step-item → status-item}/index.d.ts +4 -4
- package/lib/atom/status-item/index.d.ts.map +1 -0
- package/lib/atom/{review-header-step-item → status-item}/index.js +50 -23
- package/lib/atom/status-item/index.js.map +1 -0
- package/lib/atom/status-item/index.native.d.ts +5 -0
- package/lib/atom/status-item/index.native.d.ts.map +1 -0
- package/lib/atom/{review-header-step-item → status-item}/index.native.js +2 -2
- package/lib/atom/status-item/index.native.js.map +1 -0
- package/lib/atom/{review-header-step-item → status-item}/style.css +47 -0
- package/lib/atom/{review-header-step-item → status-item}/types.d.ts +5 -5
- package/lib/atom/status-item/types.d.ts.map +1 -0
- package/lib/atom/{review-header-step-item → status-item}/types.js +1 -1
- package/lib/atom/status-item/types.js.map +1 -0
- package/lib/atom/tooltip/index.d.ts +3 -1
- package/lib/atom/tooltip/index.d.ts.map +1 -1
- package/lib/atom/tooltip/index.js +19 -7
- package/lib/atom/tooltip/index.js.map +1 -1
- package/lib/atom/tooltip/style.css +11 -2
- package/lib/globals.d.js.map +1 -1
- package/lib/molecule/battle-opponent-list/index.d.ts +18 -0
- package/lib/molecule/battle-opponent-list/index.d.ts.map +1 -0
- package/lib/molecule/battle-opponent-list/index.js +43 -0
- package/lib/molecule/battle-opponent-list/index.js.map +1 -0
- package/lib/molecule/battle-opponent-list/prop-types.d.ts +26 -0
- package/lib/molecule/battle-opponent-list/prop-types.d.ts.map +1 -0
- package/lib/molecule/battle-opponent-list/prop-types.js +23 -0
- package/lib/molecule/battle-opponent-list/prop-types.js.map +1 -0
- package/lib/molecule/battle-opponent-list/style.css +5 -0
- package/lib/molecule/review-header-steps/index.js +2 -2
- package/lib/molecule/review-header-steps/index.js.map +1 -1
- package/lib/molecule/review-header-steps/prop-types.d.ts +2 -2
- package/lib/molecule/review-header-steps/prop-types.d.ts.map +1 -1
- package/lib/molecule/review-header-steps/prop-types.js +1 -1
- package/lib/molecule/review-header-steps/prop-types.js.map +1 -1
- package/lib/organism/review-header/index.native.js +1 -1
- package/lib/organism/review-header/index.native.js.map +1 -1
- package/lib/organism/review-header/types.d.ts +2 -2
- package/lib/organism/review-header/types.d.ts.map +1 -1
- package/lib/organism/review-header/types.js.map +1 -1
- package/lib/organism/user-preferences/index.d.ts.map +1 -1
- package/lib/organism/user-preferences/index.js +10 -3
- package/lib/organism/user-preferences/index.js.map +1 -1
- package/lib/util/button-icons.d.ts +1 -0
- package/lib/util/button-icons.d.ts.map +1 -1
- package/lib/util/button-icons.js +2 -1
- package/lib/util/button-icons.js.map +1 -1
- package/lib/variables/colors.css +2 -0
- package/locales/bs/global.json +0 -2
- package/locales/cs/global.json +0 -2
- package/locales/de/global.json +0 -2
- package/locales/en/global.json +8 -5
- package/locales/es/global.json +0 -2
- package/locales/et/global.json +0 -2
- package/locales/fr/global.json +0 -2
- package/locales/hr/global.json +0 -2
- package/locales/hu/global.json +0 -2
- package/locales/hy/global.json +0 -2
- package/locales/it/global.json +0 -2
- package/locales/ja/global.json +0 -2
- package/locales/ko/global.json +0 -2
- package/locales/nl/global.json +0 -2
- package/locales/pl/global.json +0 -2
- package/locales/pt/global.json +0 -2
- package/locales/ro/global.json +0 -2
- package/locales/ru/global.json +0 -2
- package/locales/sk/global.json +0 -2
- package/locales/th/global.json +0 -2
- package/locales/tl/global.json +0 -2
- package/locales/tr/global.json +0 -2
- package/locales/uk/global.json +0 -2
- package/locales/vi/global.json +0 -2
- package/locales/zh/global.json +0 -2
- package/locales/zh_TW/global.json +0 -2
- package/package.json +3 -2
- package/es/atom/review-header-step-item/index.d.ts.map +0 -1
- package/es/atom/review-header-step-item/index.js +0 -77
- package/es/atom/review-header-step-item/index.js.map +0 -1
- package/es/atom/review-header-step-item/index.native.d.ts +0 -5
- package/es/atom/review-header-step-item/index.native.d.ts.map +0 -1
- package/es/atom/review-header-step-item/index.native.js.map +0 -1
- package/es/atom/review-header-step-item/types.d.ts.map +0 -1
- package/es/atom/review-header-step-item/types.js.map +0 -1
- package/lib/atom/review-header-step-item/index.d.ts.map +0 -1
- package/lib/atom/review-header-step-item/index.js.map +0 -1
- package/lib/atom/review-header-step-item/index.native.d.ts +0 -5
- package/lib/atom/review-header-step-item/index.native.d.ts.map +0 -1
- package/lib/atom/review-header-step-item/index.native.js.map +0 -1
- package/lib/atom/review-header-step-item/types.d.ts.map +0 -1
- package/lib/atom/review-header-step-item/types.js.map +0 -1
|
@@ -11,7 +11,7 @@ var _isEmpty = _interopRequireDefault(require("lodash/fp/isEmpty"));
|
|
|
11
11
|
|
|
12
12
|
var _map = _interopRequireDefault(require("lodash/fp/map"));
|
|
13
13
|
|
|
14
|
-
var _provider = require("../../atom/provider");
|
|
14
|
+
var _provider = _interopRequireWildcard(require("../../atom/provider"));
|
|
15
15
|
|
|
16
16
|
var _tooltip = _interopRequireDefault(require("../../atom/tooltip"));
|
|
17
17
|
|
|
@@ -21,14 +21,18 @@ var _style = _interopRequireDefault(require("./style.css"));
|
|
|
21
21
|
|
|
22
22
|
const _excluded = ["label", "description", "moreInfoAriaLabel"];
|
|
23
23
|
|
|
24
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
25
|
+
|
|
26
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
27
|
+
|
|
24
28
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
25
29
|
|
|
26
30
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : 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); }
|
|
27
31
|
|
|
28
32
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
29
33
|
|
|
30
|
-
const Settings = props => {
|
|
31
|
-
const translate = (0, _provider.GetTranslateFromContext)();
|
|
34
|
+
const Settings = (props, legacyContext) => {
|
|
35
|
+
const translate = (0, _provider.GetTranslateFromContext)(legacyContext);
|
|
32
36
|
|
|
33
37
|
const {
|
|
34
38
|
label,
|
|
@@ -56,6 +60,9 @@ Settings.propTypes = process.env.NODE_ENV !== "production" ? _extends({}, _input
|
|
|
56
60
|
label: _propTypes.default.string.isRequired,
|
|
57
61
|
description: _propTypes.default.string
|
|
58
62
|
}) : {};
|
|
63
|
+
Settings.contextTypes = {
|
|
64
|
+
translate: _provider.default.childContextTypes.translate
|
|
65
|
+
};
|
|
59
66
|
|
|
60
67
|
const UserPreferences = props => {
|
|
61
68
|
const {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["Settings","props","translate","GetTranslateFromContext","label","description","moreInfoAriaLabel","settings","style","isEmpty","infoIconTooltip","propTypes","InputSwitch","PropTypes","string","isRequired","UserPreferences","preferences","groupAriaLabel","map","arrayOf","shape"],"sources":["../../../src/organism/user-preferences/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport isEmpty from 'lodash/fp/isEmpty';\nimport map from 'lodash/fp/map';\nimport {GetTranslateFromContext} from '../../atom/provider';\nimport ToolTip from '../../atom/tooltip';\nimport InputSwitch from '../../atom/input-switch';\nimport style from './style.css';\n\nconst Settings = props => {\n const translate = GetTranslateFromContext();\n const {label, description, moreInfoAriaLabel, ...settings} = props;\n return (\n <div className={style.settings}>\n <InputSwitch {...settings} />\n <span className={style.label} tabIndex={0}>\n {label}\n </span>\n {isEmpty(description) ? null : (\n <ToolTip\n TooltipContent={description}\n closeToolTipInformationTextAriaLabel={translate(\n 'Press the escape key to close the information text'\n )}\n data-testid=\"user-preferences-tooltip\"\n aria-label={moreInfoAriaLabel}\n iconContainerClassName={style.infoIconTooltip}\n fontSize={12}\n />\n )}\n </div>\n );\n};\n\nSettings.propTypes = {\n ...InputSwitch.propTypes,\n label: PropTypes.string.isRequired,\n description: PropTypes.string\n};\n\nconst UserPreferences = props => {\n const {preferences, moreInfoAriaLabel, groupAriaLabel} = props;\n\n return (\n <form>\n <div className={style.preferences} role=\"group\" aria-label={groupAriaLabel} tabIndex={0}>\n {map(\n settings => (\n <Settings {...settings} key={settings.label} moreInfoAriaLabel={moreInfoAriaLabel} />\n ),\n preferences\n )}\n </div>\n </form>\n );\n};\n\nUserPreferences.propTypes = {\n preferences: PropTypes.arrayOf(PropTypes.shape(Settings.propTypes)),\n moreInfoAriaLabel: PropTypes.string,\n groupAriaLabel: PropTypes.string\n};\n\nexport default UserPreferences;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA
|
|
1
|
+
{"version":3,"file":"index.js","names":["Settings","props","legacyContext","translate","GetTranslateFromContext","label","description","moreInfoAriaLabel","settings","style","isEmpty","infoIconTooltip","propTypes","InputSwitch","PropTypes","string","isRequired","contextTypes","Provider","childContextTypes","UserPreferences","preferences","groupAriaLabel","map","arrayOf","shape"],"sources":["../../../src/organism/user-preferences/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport isEmpty from 'lodash/fp/isEmpty';\nimport map from 'lodash/fp/map';\nimport Provider, {GetTranslateFromContext} from '../../atom/provider';\nimport ToolTip from '../../atom/tooltip';\nimport InputSwitch from '../../atom/input-switch';\nimport style from './style.css';\n\nconst Settings = (props, legacyContext) => {\n const translate = GetTranslateFromContext(legacyContext);\n const {label, description, moreInfoAriaLabel, ...settings} = props;\n return (\n <div className={style.settings}>\n <InputSwitch {...settings} />\n <span className={style.label} tabIndex={0}>\n {label}\n </span>\n {isEmpty(description) ? null : (\n <ToolTip\n TooltipContent={description}\n closeToolTipInformationTextAriaLabel={translate(\n 'Press the escape key to close the information text'\n )}\n data-testid=\"user-preferences-tooltip\"\n aria-label={moreInfoAriaLabel}\n iconContainerClassName={style.infoIconTooltip}\n fontSize={12}\n />\n )}\n </div>\n );\n};\n\nSettings.propTypes = {\n ...InputSwitch.propTypes,\n label: PropTypes.string.isRequired,\n description: PropTypes.string\n};\n\nSettings.contextTypes = {\n translate: Provider.childContextTypes.translate\n};\n\nconst UserPreferences = props => {\n const {preferences, moreInfoAriaLabel, groupAriaLabel} = props;\n\n return (\n <form>\n <div className={style.preferences} role=\"group\" aria-label={groupAriaLabel} tabIndex={0}>\n {map(\n settings => (\n <Settings {...settings} key={settings.label} moreInfoAriaLabel={moreInfoAriaLabel} />\n ),\n preferences\n )}\n </div>\n </form>\n );\n};\n\nUserPreferences.propTypes = {\n preferences: PropTypes.arrayOf(PropTypes.shape(Settings.propTypes)),\n moreInfoAriaLabel: PropTypes.string,\n groupAriaLabel: PropTypes.string\n};\n\nexport default UserPreferences;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;;;;;AAEA,MAAMA,QAAQ,GAAG,CAACC,KAAD,EAAQC,aAAR,KAA0B;EACzC,MAAMC,SAAS,GAAG,IAAAC,iCAAA,EAAwBF,aAAxB,CAAlB;;EACA,MAAM;IAACG,KAAD;IAAQC,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AACR,SAAhB,2CAA4B;EAC1BS,WAAW,EAAEP,kBAAA,CAAUU,OAAV,CAAkBV,kBAAA,CAAUW,KAAV,CAAgBzB,QAAQ,CAACY,SAAzB,CAAlB,CADa;EAE1BL,iBAAiB,EAAEO,kBAAA,CAAUC,MAFH;EAG1BO,cAAc,EAAER,kBAAA,CAAUC;AAHA,CAA5B;eAMeK,e"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button-icons.d.ts","sourceRoot":"","sources":["../../src/util/button-icons.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"button-icons.d.ts","sourceRoot":"","sources":["../../src/util/button-icons.js"],"names":[],"mappings":"AAoBA;;;;;;;;;;;;;;;;;;EAkBE"}
|
package/lib/util/button-icons.js
CHANGED
|
@@ -21,7 +21,8 @@ const ICONS = {
|
|
|
21
21
|
save: _novaIcons.NovaSolidComputersSdCard,
|
|
22
22
|
see: _novaIcons.NovaCompositionCoorpacademyEye,
|
|
23
23
|
folders: _novaIcons.NovaSolidFilesFoldersFolders,
|
|
24
|
-
upload: _novaIcons.NovaSolidFilesBasicFileUpload2
|
|
24
|
+
upload: _novaIcons.NovaSolidFilesBasicFileUpload2,
|
|
25
|
+
down: _novaIcons.NovaCompositionNavigationArrowDown
|
|
25
26
|
};
|
|
26
27
|
exports.ICONS = ICONS;
|
|
27
28
|
//# sourceMappingURL=button-icons.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button-icons.js","names":["ICONS","add","AddIcon","analytics","AnalyticsIcon","bin","BinIcon","BulletPointIcon","ChevronLeftIcon","ChevronRightIcon","close","CloseIcon","edit","EditIcon","key","KlfIcon","list","ListIcon","logout","LogoutIcon","publish","PublishIcon","save","SaveIcon","see","EyeIcon","folders","FoldersIcon","upload","UploadIcon"],"sources":["../../src/util/button-icons.js"],"sourcesContent":["import {\n NovaSolidRemoveAddAddCircle1 as AddIcon,\n NovaCompositionCoorpacademyAnalytics as AnalyticsIcon,\n NovaSolidContentEditionBin as BinIcon,\n NovaCompositionCoorpacademyBulletPoint as BulletPointIcon,\n NovaCompositionNavigationArrowLeft as ChevronLeftIcon,\n NovaCompositionNavigationArrowRight as ChevronRightIcon,\n NovaSolidStatusClose as CloseIcon,\n NovaSolidContentEditionPencilWrite as EditIcon,\n NovaCompositionCoorpacademyEye as EyeIcon,\n NovaSolidContentContentViewModule1 as ListIcon,\n NovaSolidLoginLogout1 as LogoutIcon,\n NovaSolidApplicationsWindowUpload3 as PublishIcon,\n NovaSolidComputersSdCard as SaveIcon,\n NovaLineLoginKey1 as KlfIcon,\n NovaSolidFilesFoldersFolders as FoldersIcon,\n NovaSolidFilesBasicFileUpload2 as UploadIcon\n} from '@coorpacademy/nova-icons';\n\nexport const ICONS = {\n add: AddIcon,\n analytics: AnalyticsIcon,\n bin: BinIcon,\n 'bullet-point': BulletPointIcon,\n 'chevron-left': ChevronLeftIcon,\n 'chevron-right': ChevronRightIcon,\n close: CloseIcon,\n edit: EditIcon,\n key: KlfIcon,\n list: ListIcon,\n logout: LogoutIcon,\n publish: PublishIcon,\n save: SaveIcon,\n see: EyeIcon,\n folders: FoldersIcon,\n upload: UploadIcon\n};\n"],"mappings":";;;;;AAAA;;
|
|
1
|
+
{"version":3,"file":"button-icons.js","names":["ICONS","add","AddIcon","analytics","AnalyticsIcon","bin","BinIcon","BulletPointIcon","ChevronLeftIcon","ChevronRightIcon","close","CloseIcon","edit","EditIcon","key","KlfIcon","list","ListIcon","logout","LogoutIcon","publish","PublishIcon","save","SaveIcon","see","EyeIcon","folders","FoldersIcon","upload","UploadIcon","down","ArrowDown"],"sources":["../../src/util/button-icons.js"],"sourcesContent":["import {\n NovaSolidRemoveAddAddCircle1 as AddIcon,\n NovaCompositionCoorpacademyAnalytics as AnalyticsIcon,\n NovaSolidContentEditionBin as BinIcon,\n NovaCompositionCoorpacademyBulletPoint as BulletPointIcon,\n NovaCompositionNavigationArrowLeft as ChevronLeftIcon,\n NovaCompositionNavigationArrowRight as ChevronRightIcon,\n NovaSolidStatusClose as CloseIcon,\n NovaSolidContentEditionPencilWrite as EditIcon,\n NovaCompositionCoorpacademyEye as EyeIcon,\n NovaSolidContentContentViewModule1 as ListIcon,\n NovaSolidLoginLogout1 as LogoutIcon,\n NovaSolidApplicationsWindowUpload3 as PublishIcon,\n NovaSolidComputersSdCard as SaveIcon,\n NovaLineLoginKey1 as KlfIcon,\n NovaSolidFilesFoldersFolders as FoldersIcon,\n NovaSolidFilesBasicFileUpload2 as UploadIcon,\n NovaCompositionNavigationArrowDown as ArrowDown\n} from '@coorpacademy/nova-icons';\n\nexport const ICONS = {\n add: AddIcon,\n analytics: AnalyticsIcon,\n bin: BinIcon,\n 'bullet-point': BulletPointIcon,\n 'chevron-left': ChevronLeftIcon,\n 'chevron-right': ChevronRightIcon,\n close: CloseIcon,\n edit: EditIcon,\n key: KlfIcon,\n list: ListIcon,\n logout: LogoutIcon,\n publish: PublishIcon,\n save: SaveIcon,\n see: EyeIcon,\n folders: FoldersIcon,\n upload: UploadIcon,\n down: ArrowDown\n};\n"],"mappings":";;;;;AAAA;;AAoBO,MAAMA,KAAK,GAAG;EACnBC,GAAG,EAAEC,uCADc;EAEnBC,SAAS,EAAEC,+CAFQ;EAGnBC,GAAG,EAAEC,qCAHc;EAInB,gBAAgBC,iDAJG;EAKnB,gBAAgBC,6CALG;EAMnB,iBAAiBC,8CANE;EAOnBC,KAAK,EAAEC,+BAPY;EAQnBC,IAAI,EAAEC,6CARa;EASnBC,GAAG,EAAEC,4BATc;EAUnBC,IAAI,EAAEC,6CAVa;EAWnBC,MAAM,EAAEC,gCAXW;EAYnBC,OAAO,EAAEC,6CAZU;EAanBC,IAAI,EAAEC,mCAba;EAcnBC,GAAG,EAAEC,yCAdc;EAenBC,OAAO,EAAEC,uCAfU;EAgBnBC,MAAM,EAAEC,yCAhBW;EAiBnBC,IAAI,EAAEC;AAjBa,CAAd"}
|
package/lib/variables/colors.css
CHANGED
|
@@ -51,6 +51,8 @@
|
|
|
51
51
|
@value cm_negative_50: #ffe5e6;
|
|
52
52
|
@value cm_green_50: #e8fcf8;
|
|
53
53
|
@value cm_green_200: #16ac8c;
|
|
54
|
+
@value cm_green_secondary_100: #D6F5E1;
|
|
55
|
+
@value cm_green_secondary_200: #38CC6C;
|
|
54
56
|
@value cm_orange_200: #FF7043;
|
|
55
57
|
@value cm_orange_700: #FF4105;
|
|
56
58
|
@value cm_pink_50: #ffefeb;
|
package/locales/bs/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "* Obavezna polja",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Pitanje {{headerStepValue}}",
|
|
85
|
-
"current_question": "Pitanje {{headerStepValue}} je trenutno pitanje",
|
|
86
84
|
"correct_question": "Pitanje {{headerStepValue}} je tačno",
|
|
87
85
|
"incorrect_question": "Pitanje {{headerStepValue}} je netačno",
|
|
88
86
|
"not_answered_question": "Pitanje {{headerStepValue}} još nije odgovoreno"
|
package/locales/cs/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Otázka {{headerStepValue}}",
|
|
85
|
-
"current_question": "Otázka {{headerStepValue}} je aktuální otázka",
|
|
86
84
|
"correct_question": "Otázka {{headerStepValue}} je správná",
|
|
87
85
|
"incorrect_question": "Otázka {{headerStepValue}} je nesprávná",
|
|
88
86
|
"not_answered_question": "Otázka {{headerStepValue}} zatím není zodpovězena"
|
package/locales/de/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Frage {{headerStepValue}}",
|
|
85
|
-
"current_question": "Frage {{headerStepValue}} ist die aktuelle Frage",
|
|
86
84
|
"correct_question": "Frage {{headerStepValue}} ist richtig",
|
|
87
85
|
"incorrect_question": "Frage {{headerStepValue}} ist falsch",
|
|
88
86
|
"not_answered_question": "Frage {{headerStepValue}} ist noch nicht beantwortet"
|
package/locales/en/global.json
CHANGED
|
@@ -81,10 +81,13 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"
|
|
85
|
-
"
|
|
86
|
-
"
|
|
87
|
-
|
|
88
|
-
|
|
84
|
+
"correct_question": "{{current}}question {{headerStepValue}} is correct",
|
|
85
|
+
"incorrect_question": "{{current}}question {{headerStepValue}} is incorrect",
|
|
86
|
+
"not_answered_question": "{{current}}question {{headerStepValue}} is not answered yet"
|
|
87
|
+
},
|
|
88
|
+
"bulk_import": {
|
|
89
|
+
"errors_number": "bulk import errors number is {{bulkImportErrorsNumber}}",
|
|
90
|
+
"valid_scorm": "scorm file is valid",
|
|
91
|
+
"invalid_scorm": "scorm file is not valid"
|
|
89
92
|
}
|
|
90
93
|
}
|
package/locales/es/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Pregunta {{headerStepValue}}",
|
|
85
|
-
"current_question": "Pregunta {{headerStepValue}} es la pregunta actual",
|
|
86
84
|
"correct_question": "La pregunta {{headerStepValue}} es correcta",
|
|
87
85
|
"incorrect_question": "La pregunta {{headerStepValue}} es incorrecta",
|
|
88
86
|
"not_answered_question": "La pregunta {{headerStepValue}} aún no ha sido respondida"
|
package/locales/et/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Kohustuslikud väljad",
|
|
82
82
|
"something_went_wrong": "Oih! Midagi läks viltu.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Küsimus {{headerStepValue}}",
|
|
85
|
-
"current_question": "Küsimus {{headerStepValue}} on praegune küsimus",
|
|
86
84
|
"correct_question": "Küsimus {{headerStepValue}} on õige",
|
|
87
85
|
"incorrect_question": "Küsimus {{headerStepValue}} on vale",
|
|
88
86
|
"not_answered_question": "Küsimusele {{headerStepValue}} pole veel vastust"
|
package/locales/fr/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "* Champs obligatoires",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Quelque chose a mal tourné.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Question {{headerStepValue}}",
|
|
85
|
-
"current_question": "La question {{headerStepValue}} est la question actuelle",
|
|
86
84
|
"correct_question": "La question {{headerStepValue}} est correcte",
|
|
87
85
|
"incorrect_question": "La question {{headerStepValue}} est incorrecte",
|
|
88
86
|
"not_answered_question": "La question {{headerStepValue}} n'a pas encore de réponse"
|
package/locales/hr/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Obavezna polja",
|
|
82
82
|
"something_went_wrong": "Ajoj! Nešto je otišlo ukrivo.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Pitanje {{headerStepValue}}",
|
|
85
|
-
"current_question": "Pitanje {{headerStepValue}} je trenutno pitanje",
|
|
86
84
|
"correct_question": "Pitanje {{headerStepValue}} je točno",
|
|
87
85
|
"incorrect_question": "Pitanje {{headerStepValue}} je netočno",
|
|
88
86
|
"not_answered_question": "Na pitanje {{headerStepValue}} još nije odgovoreno"
|
package/locales/hu/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Kérdés {{headerStepValue}}",
|
|
85
|
-
"current_question": "Az {{headerStepValue}} kérdés az aktuális kérdés",
|
|
86
84
|
"correct_question": "Az {{headerStepValue}} kérdés helyes",
|
|
87
85
|
"incorrect_question": "Az {{headerStepValue}} kérdés helytelen",
|
|
88
86
|
"not_answered_question": "Az {{headerStepValue}} kérdésre még nincs válasz"
|
package/locales/hy/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Պարտադիր դաշտեր",
|
|
82
82
|
"something_went_wrong": "Վա՜յ: Ինչ որ բան այնպես չգնաց.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Հարց {{headerStepValue}}",
|
|
85
|
-
"current_question": "{{headerStepValue}} հարցը ընթացիկ հարցն է",
|
|
86
84
|
"correct_question": "{{headerStepValue}} հարցը ճիշտ է",
|
|
87
85
|
"incorrect_question": "Հարցը {{headerStepValue}} սխալ է",
|
|
88
86
|
"not_answered_question": "Հարցին {{headerStepValue}} դեռ պատասխանված չէ"
|
package/locales/it/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Domanda {{headerStepValue}}",
|
|
85
|
-
"current_question": "La domanda {{headerStepValue}} è la domanda attuale",
|
|
86
84
|
"correct_question": "La domanda {{headerStepValue}} è corretta",
|
|
87
85
|
"incorrect_question": "La domanda {{headerStepValue}} non è corretta",
|
|
88
86
|
"not_answered_question": "La domanda {{headerStepValue}} non ha ancora ricevuto risposta"
|
package/locales/ja/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "質問 {{headerStepValue}}",
|
|
85
|
-
"current_question": "質問 {{headerStepValue}} が現在の質問です",
|
|
86
84
|
"correct_question": "問題 {{headerStepValue}} は正解です",
|
|
87
85
|
"incorrect_question": "質問 {{headerStepValue}} は不正解です",
|
|
88
86
|
"not_answered_question": "質問 {{headerStepValue}} はまだ回答されていません"
|
package/locales/ko/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "질문 {{headerStepValue}}",
|
|
85
|
-
"current_question": "질문 {{headerStepValue}}이 현재 질문입니다.",
|
|
86
84
|
"correct_question": "질문 {{headerStepValue}}이 맞습니다.",
|
|
87
85
|
"incorrect_question": "질문 {{headerStepValue}}이 올바르지 않습니다.",
|
|
88
86
|
"not_answered_question": "질문 {{headerStepValue}}은 아직 답변되지 않았습니다."
|
package/locales/nl/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Vraag {{headerStepValue}}",
|
|
85
|
-
"current_question": "Vraag {{headerStepValue}} is de huidige vraag",
|
|
86
84
|
"correct_question": "Vraag {{headerStepValue}} is juist",
|
|
87
85
|
"incorrect_question": "Vraag {{headerStepValue}} is onjuist",
|
|
88
86
|
"not_answered_question": "Vraag {{headerStepValue}} is nog niet beantwoord"
|
package/locales/pl/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Pytanie {{headerStepValue}}",
|
|
85
|
-
"current_question": "Pytanie {{headerStepValue}} jest aktualnym pytaniem",
|
|
86
84
|
"correct_question": "Pytanie {{headerStepValue}} jest poprawne",
|
|
87
85
|
"incorrect_question": "Pytanie {{headerStepValue}} jest nieprawidłowe",
|
|
88
86
|
"not_answered_question": "Na pytanie {{headerStepValue}} nie ma jeszcze odpowiedzi"
|
package/locales/pt/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Pergunta {{headerStepValue}}",
|
|
85
|
-
"current_question": "A pergunta {{headerStepValue}} é a pergunta atual",
|
|
86
84
|
"correct_question": "A questão {{headerStepValue}} está correta",
|
|
87
85
|
"incorrect_question": "A pergunta {{headerStepValue}} está incorreta",
|
|
88
86
|
"not_answered_question": "A pergunta {{headerStepValue}} ainda não foi respondida"
|
package/locales/ro/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Întrebare {{headerStepValue}}",
|
|
85
|
-
"current_question": "Întrebarea {{headerStepValue}} este întrebarea curentă",
|
|
86
84
|
"correct_question": "Întrebarea {{headerStepValue}} este corectă",
|
|
87
85
|
"incorrect_question": "Întrebarea {{headerStepValue}} este incorectă",
|
|
88
86
|
"not_answered_question": "Întrebarea {{headerStepValue}} nu a primit încă răspuns"
|
package/locales/ru/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Обязательные поля",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Вопрос {{headerStepValue}}",
|
|
85
|
-
"current_question": "Вопрос {{headerStepValue}} — текущий вопрос",
|
|
86
84
|
"correct_question": "Вопрос {{headerStepValue}} правильный",
|
|
87
85
|
"incorrect_question": "Вопрос {{headerStepValue}} неверен",
|
|
88
86
|
"not_answered_question": "На вопрос {{headerStepValue}} пока нет ответа"
|
package/locales/sk/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Povinné polia",
|
|
82
82
|
"something_went_wrong": "Och! Niečo sa pokazilo.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Otázka {{headerStepValue}}",
|
|
85
|
-
"current_question": "Otázka {{headerStepValue}} je aktuálna otázka",
|
|
86
84
|
"correct_question": "Otázka {{headerStepValue}} je správna",
|
|
87
85
|
"incorrect_question": "Otázka {{headerStepValue}} je nesprávna",
|
|
88
86
|
"not_answered_question": "Otázka {{headerStepValue}} zatiaľ nie je zodpovedaná"
|
package/locales/th/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*ข้อมูลที่จำเป็นต้องกรอก",
|
|
82
82
|
"something_went_wrong": "อ้าว! มีสิ่งผิดปกติ",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "คำถามข้อที่ {{headerStepValue}}",
|
|
85
|
-
"current_question": "คำถามข้อที่ {{headerStepValue}} คือคำถามปัจจุบัน",
|
|
86
84
|
"correct_question": "คำถามข้อที่ {{headerStepValue}} ถูกต้อง",
|
|
87
85
|
"incorrect_question": "คำถามข้อที่ {{headerStepValue}} ไม่ถูกต้อง",
|
|
88
86
|
"not_answered_question": "คำถามข้อที่ {{headerStepValue}} ยังไม่ได้ตอบ"
|
package/locales/tl/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "* Mga patlang na ipinag-uutos",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Tanong {{headerStepValue}}",
|
|
85
|
-
"current_question": "Tanong {{headerStepValue}} ang kasalukuyang tanong",
|
|
86
84
|
"correct_question": "Tama ang tanong na {{headerStepValue}}",
|
|
87
85
|
"incorrect_question": "Ang tanong na {{headerStepValue}} ay hindi tama",
|
|
88
86
|
"not_answered_question": "Ang tanong na {{headerStepValue}} ay hindi pa nasasagot"
|
package/locales/tr/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Soru {{headerStepValue}}",
|
|
85
|
-
"current_question": "Soru {{headerStepValue}} şu anki soru",
|
|
86
84
|
"correct_question": "{{headerStepValue}} sorusu doğru",
|
|
87
85
|
"incorrect_question": "{{headerStepValue}} sorusu yanlış",
|
|
88
86
|
"not_answered_question": "{{headerStepValue}} sorusu henüz cevaplanmadı"
|
package/locales/uk/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Питання {{headerStepValue}}",
|
|
85
|
-
"current_question": "Питання {{headerStepValue}} є поточним питанням",
|
|
86
84
|
"correct_question": "Питання {{headerStepValue}} правильне",
|
|
87
85
|
"incorrect_question": "Питання {{headerStepValue}} некоректне",
|
|
88
86
|
"not_answered_question": "На запитання {{headerStepValue}} ще немає відповіді"
|
package/locales/vi/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "Câu hỏi {{headerStepValue}}",
|
|
85
|
-
"current_question": "Câu hỏi {{headerStepValue}} là câu hỏi hiện tại",
|
|
86
84
|
"correct_question": "Câu {{headerStepValue}} đúng không",
|
|
87
85
|
"incorrect_question": "Câu {{headerStepValue}} sai",
|
|
88
86
|
"not_answered_question": "Câu hỏi {{headerStepValue}} chưa có câu trả lời"
|
package/locales/zh/global.json
CHANGED
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "问题{{headerStepValue}}",
|
|
85
|
-
"current_question": "问题 {{headerStepValue}} 是当前问题",
|
|
86
84
|
"correct_question": "问题{{headerStepValue}}是正确的",
|
|
87
85
|
"incorrect_question": "问题 {{headerStepValue}} 不正确",
|
|
88
86
|
"not_answered_question": "问题 {{headerStepValue}} 尚未回答"
|
|
@@ -81,8 +81,6 @@
|
|
|
81
81
|
"mandatory_fields": "*Mandatory fields",
|
|
82
82
|
"something_went_wrong": "Oh Snap! Something went wrong.",
|
|
83
83
|
"review_header_step_item": {
|
|
84
|
-
"aria_label": "問題{{headerStepValue}}",
|
|
85
|
-
"current_question": "問題 {{headerStepValue}} 是當前問題",
|
|
86
84
|
"correct_question": "問題{{headerStepValue}}是正確的",
|
|
87
85
|
"incorrect_question": "問題 {{headerStepValue}} 不正確",
|
|
88
86
|
"not_answered_question": "問題 {{headerStepValue}} 尚未回答"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@coorpacademy/components",
|
|
3
|
-
"version": "11.11.
|
|
3
|
+
"version": "11.11.5",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "es/index.js",
|
|
@@ -120,6 +120,7 @@
|
|
|
120
120
|
"@testing-library/react": "12.1.5",
|
|
121
121
|
"@testing-library/react-native": "^10.1.1",
|
|
122
122
|
"@types/react-native": "~0.68.7",
|
|
123
|
+
"@types/uuid": "^9.0.0",
|
|
123
124
|
"@typescript-eslint/eslint-plugin": "^5.39.0",
|
|
124
125
|
"@typescript-eslint/parser": "^5.39.0",
|
|
125
126
|
"@wojtekmaj/enzyme-adapter-react-17": "^0.6.7",
|
|
@@ -164,5 +165,5 @@
|
|
|
164
165
|
"last 2 versions",
|
|
165
166
|
"IE 11"
|
|
166
167
|
],
|
|
167
|
-
"gitHead": "
|
|
168
|
+
"gitHead": "456d4e9e9257073fb0969dfdc2fffce1cc24fd3b"
|
|
168
169
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/atom/review-header-step-item/index.tsx"],"names":[],"mappings":";AASA,OAAkB,EAAC,mBAAmB,EAAC,MAAM,SAAS,CAAC;AAsDvD,QAAA,MAAM,oBAAoB;YAAW,mBAAmB;;;;;;CAevD,CAAC;AAWF,eAAe,oBAAoB,CAAC"}
|
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import classnames from 'classnames';
|
|
3
|
-
import { NovaCompositionCoorpacademyCheck as RightIcon, NovaSolidStatusClose as WrongIcon } from '@coorpacademy/nova-icons';
|
|
4
|
-
import Provider, { GetTranslateFromContext } from '../provider';
|
|
5
|
-
import style from './style.css';
|
|
6
|
-
import propTypes from './types';
|
|
7
|
-
|
|
8
|
-
const Content = (props, legacyContext) => {
|
|
9
|
-
const {
|
|
10
|
-
icon,
|
|
11
|
-
current,
|
|
12
|
-
value
|
|
13
|
-
} = props;
|
|
14
|
-
const translate = GetTranslateFromContext(legacyContext);
|
|
15
|
-
let child;
|
|
16
|
-
let ariaDescription;
|
|
17
|
-
|
|
18
|
-
switch (icon) {
|
|
19
|
-
case 'no-answer':
|
|
20
|
-
child = value;
|
|
21
|
-
ariaDescription = current ? translate('review_header_step_item.current_question', {
|
|
22
|
-
headerStepValue: value
|
|
23
|
-
}) : translate('review_header_step_item.not_answered_question', {
|
|
24
|
-
headerStepValue: value
|
|
25
|
-
});
|
|
26
|
-
break;
|
|
27
|
-
|
|
28
|
-
case 'right':
|
|
29
|
-
child = /*#__PURE__*/React.createElement(RightIcon, {
|
|
30
|
-
className: classnames(style.rightIcon, current && style.currentRightIcon)
|
|
31
|
-
});
|
|
32
|
-
ariaDescription = translate('review_header_step_item.correct_question', {
|
|
33
|
-
headerStepValue: value
|
|
34
|
-
});
|
|
35
|
-
break;
|
|
36
|
-
|
|
37
|
-
case 'wrong':
|
|
38
|
-
child = /*#__PURE__*/React.createElement(WrongIcon, {
|
|
39
|
-
className: classnames(style.wrongIcon, current && style.currentWrongIcon)
|
|
40
|
-
});
|
|
41
|
-
ariaDescription = translate('review_header_step_item.incorrect_question', {
|
|
42
|
-
headerStepValue: value
|
|
43
|
-
});
|
|
44
|
-
break;
|
|
45
|
-
|
|
46
|
-
default:
|
|
47
|
-
return null;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
return /*#__PURE__*/React.createElement("span", {
|
|
51
|
-
className: style.value,
|
|
52
|
-
"aria-label": translate('review_header_step_item.aria_label', {
|
|
53
|
-
headerStepValue: value
|
|
54
|
-
}),
|
|
55
|
-
"aria-describedby": ariaDescription
|
|
56
|
-
}, child);
|
|
57
|
-
};
|
|
58
|
-
|
|
59
|
-
const ReviewHeaderStepItem = props => {
|
|
60
|
-
const {
|
|
61
|
-
icon,
|
|
62
|
-
current
|
|
63
|
-
} = props;
|
|
64
|
-
return /*#__PURE__*/React.createElement("div", {
|
|
65
|
-
className: classnames(style.default, icon === 'right' && style.right, icon === 'wrong' && style.wrong, current && style.current),
|
|
66
|
-
"data-name": "header-step-item"
|
|
67
|
-
}, /*#__PURE__*/React.createElement(Content, props));
|
|
68
|
-
};
|
|
69
|
-
|
|
70
|
-
Content.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {};
|
|
71
|
-
Content.contextTypes = {
|
|
72
|
-
skin: Provider.childContextTypes.skin,
|
|
73
|
-
translate: Provider.childContextTypes.translate
|
|
74
|
-
};
|
|
75
|
-
ReviewHeaderStepItem.propTypes = process.env.NODE_ENV !== "production" ? propTypes : {};
|
|
76
|
-
export default ReviewHeaderStepItem;
|
|
77
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["React","classnames","NovaCompositionCoorpacademyCheck","RightIcon","NovaSolidStatusClose","WrongIcon","Provider","GetTranslateFromContext","style","propTypes","Content","props","legacyContext","icon","current","value","translate","child","ariaDescription","headerStepValue","rightIcon","currentRightIcon","wrongIcon","currentWrongIcon","ReviewHeaderStepItem","default","right","wrong","contextTypes","skin","childContextTypes"],"sources":["../../../src/atom/review-header-step-item/index.tsx"],"sourcesContent":["import React from 'react';\nimport classnames from 'classnames';\nimport {\n NovaCompositionCoorpacademyCheck as RightIcon,\n NovaSolidStatusClose as WrongIcon\n} from '@coorpacademy/nova-icons';\nimport Provider, {GetTranslateFromContext} from '../provider';\nimport {WebContextValues} from '../provider/web-context';\nimport style from './style.css';\nimport propTypes, {HeaderStepItemProps} from './types';\n\nconst Content = (props: HeaderStepItemProps, legacyContext: WebContextValues) => {\n const {icon, current, value} = props;\n const translate = GetTranslateFromContext(legacyContext);\n let child;\n let ariaDescription;\n switch (icon) {\n case 'no-answer':\n child = value;\n ariaDescription = current\n ? translate('review_header_step_item.current_question', {\n headerStepValue: value\n })\n : translate('review_header_step_item.not_answered_question', {\n headerStepValue: value\n });\n break;\n\n case 'right':\n child = (\n <RightIcon className={classnames(style.rightIcon, current && style.currentRightIcon)} />\n );\n ariaDescription = translate('review_header_step_item.correct_question', {\n headerStepValue: value\n });\n break;\n\n case 'wrong':\n child = (\n <WrongIcon className={classnames(style.wrongIcon, current && style.currentWrongIcon)} />\n );\n ariaDescription = translate('review_header_step_item.incorrect_question', {\n headerStepValue: value\n });\n break;\n\n default:\n return null;\n }\n\n return (\n <span\n className={style.value}\n aria-label={translate('review_header_step_item.aria_label', {\n headerStepValue: value\n })}\n aria-describedby={ariaDescription}\n >\n {child}\n </span>\n );\n};\n\nconst ReviewHeaderStepItem = (props: HeaderStepItemProps) => {\n const {icon, current} = props;\n return (\n <div\n className={classnames(\n style.default,\n icon === 'right' && style.right,\n icon === 'wrong' && style.wrong,\n current && style.current\n )}\n data-name=\"header-step-item\"\n >\n <Content {...props} />\n </div>\n );\n};\n\nContent.propTypes = propTypes;\n\nContent.contextTypes = {\n skin: Provider.childContextTypes.skin,\n translate: Provider.childContextTypes.translate\n};\n\nReviewHeaderStepItem.propTypes = propTypes;\n\nexport default ReviewHeaderStepItem;\n"],"mappings":"AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,UAAP,MAAuB,YAAvB;AACA,SACEC,gCAAgC,IAAIC,SADtC,EAEEC,oBAAoB,IAAIC,SAF1B,QAGO,0BAHP;AAIA,OAAOC,QAAP,IAAkBC,uBAAlB,QAAgD,aAAhD;AAEA,OAAOC,KAAP,MAAkB,aAAlB;AACA,OAAOC,SAAP,MAA6C,SAA7C;;AAEA,MAAMC,OAAO,GAAG,CAACC,KAAD,EAA6BC,aAA7B,KAAiE;EAC/E,MAAM;IAACC,IAAD;IAAOC,OAAP;IAAgBC;EAAhB,IAAyBJ,KAA/B;EACA,MAAMK,SAAS,GAAGT,uBAAuB,CAACK,aAAD,CAAzC;EACA,IAAIK,KAAJ;EACA,IAAIC,eAAJ;;EACA,QAAQL,IAAR;IACE,KAAK,WAAL;MACEI,KAAK,GAAGF,KAAR;MACAG,eAAe,GAAGJ,OAAO,GACrBE,SAAS,CAAC,0CAAD,EAA6C;QACpDG,eAAe,EAAEJ;MADmC,CAA7C,CADY,GAIrBC,SAAS,CAAC,+CAAD,EAAkD;QACzDG,eAAe,EAAEJ;MADwC,CAAlD,CAJb;MAOA;;IAEF,KAAK,OAAL;MACEE,KAAK,gBACH,oBAAC,SAAD;QAAW,SAAS,EAAEhB,UAAU,CAACO,KAAK,CAACY,SAAP,EAAkBN,OAAO,IAAIN,KAAK,CAACa,gBAAnC;MAAhC,EADF;MAGAH,eAAe,GAAGF,SAAS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version":3,"file":"index.native.d.ts","sourceRoot":"","sources":["../../../src/atom/review-header-step-item/index.native.tsx"],"names":[],"mappings":";AAOA,OAAO,EAAC,mBAAmB,EAAC,MAAM,SAAS,CAAC;AA6C5C,QAAA,MAAM,IAAI,6BAA4B,mBAAmB,uBA2BxD,CAAC;AAEF,eAAe,IAAI,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.js","names":["React","useEffect","useState","StyleSheet","Text","View","NovaCompositionCoorpacademyCheck","RightIcon","NovaSolidStatusClose","WrongIcon","COLORS","createStyle","current","icon","backgroundColor","positive","negative","gray","create","step","width","height","opacity","marginHorizontal","alignItems","justifyContent","borderRadius","stepText","fontWeight","fontSize","Step","value","style","setStyle","_style","child"],"sources":["../../../src/atom/review-header-step-item/index.native.tsx"],"sourcesContent":["import React, {useEffect, useState} from 'react';\nimport {StyleSheet, Text, TextStyle, View, ViewStyle} from 'react-native';\nimport {\n NovaCompositionCoorpacademyCheck as RightIcon,\n NovaSolidStatusClose as WrongIcon\n} from '@coorpacademy/nova-icons';\nimport {COLORS} from '../../variables/colors';\nimport {HeaderStepItemProps} from './types';\n\ntype StyleSheetType = {\n step: ViewStyle;\n stepText: TextStyle;\n icon: ViewStyle;\n};\n\nconst createStyle = (current: boolean, icon: HeaderStepItemProps['icon']): StyleSheetType => {\n let backgroundColor;\n\n switch (icon) {\n case 'right':\n backgroundColor = COLORS.positive;\n break;\n case 'wrong':\n backgroundColor = COLORS.negative;\n break;\n case 'no-answer':\n default:\n backgroundColor = COLORS.gray;\n }\n\n return StyleSheet.create({\n step: {\n width: current ? 40 : 32,\n height: current ? 40 : 32,\n opacity: current ? 1 : 0.5,\n marginHorizontal: 8,\n backgroundColor,\n alignItems: 'center',\n justifyContent: 'center',\n borderRadius: 50\n },\n stepText: {\n fontWeight: '600',\n fontSize: current ? 16 : 12\n },\n icon: {\n width: current ? 14 : 12,\n height: current ? 14 : 12\n }\n });\n};\n\nconst Step = ({value, icon, current}: HeaderStepItemProps) => {\n const [style, setStyle] = useState<StyleSheetType | null>(null);\n\n useEffect(() => {\n const _style = createStyle(current, icon);\n setStyle(_style);\n }, [current, icon]);\n\n if (!style) {\n return null;\n }\n\n let child;\n\n switch (icon) {\n case 'right':\n child = <RightIcon style={style.icon} color=\"#fff\" />;\n break;\n case 'wrong':\n child = <WrongIcon style={style.icon} color=\"#fff\" />;\n break;\n case 'no-answer':\n default:\n child = <Text style={style.stepText}>{value}</Text>;\n }\n\n return <View style={style.step}>{child}</View>;\n};\n\nexport default Step;\n"],"mappings":"AAAA,OAAOA,KAAP,IAAeC,SAAf,EAA0BC,QAA1B,QAAyC,OAAzC;AACA,SAAQC,UAAR,EAAoBC,IAApB,EAAqCC,IAArC,QAA2D,cAA3D;AACA,SACEC,gCAAgC,IAAIC,SADtC,EAEEC,oBAAoB,IAAIC,SAF1B,QAGO,0BAHP;AAIA,SAAQC,MAAR,QAAqB,wBAArB;;AASA,MAAMC,WAAW,GAAG,CAACC,OAAD,EAAmBC,IAAnB,KAAyE;EAC3F,IAAIC,eAAJ;;EAEA,QAAQD,IAAR;IACE,KAAK,OAAL;MACEC,eAAe,GAAGJ,MAAM,CAACK,QAAzB;MACA;;IACF,KAAK,OAAL;MACED,eAAe,GAAGJ,MAAM,CAACM,QAAzB;MACA;;IACF,KAAK,WAAL;IACA;MACEF,eAAe,GAAGJ,MAAM,CAACO,IAAzB;EATJ;;EAYA,OAAOd,UAAU,CAACe,MAAX,CAAkB;IACvBC,IAAI,EAAE;MACJC,KAAK,EAAER,OAAO,GAAG,EAAH,GAAQ,EADlB;MAEJS,MAAM,EAAET,OAAO,GAAG,EAAH,GAAQ,EAFnB;MAGJU,OAAO,EAAEV,OAAO,GAAG,CAAH,GAAO,GAHnB;MAIJW,gBAAgB,EAAE,CAJd;MAKJT,eALI;MAMJU,UAAU,EAAE,QANR;MAOJC,cAAc,EAAE,QAPZ;MAQJC,YAAY,EAAE;IARV,CADiB;IAWvBC,QAAQ,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3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/atom/review-header-step-item/types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AAEnC,QAAA,MAAM,SAAS;;;;CAId,CAAC;AAEF,eAAe,SAAS,CAAC;AAEzB,oBAAY,mBAAmB,GAAG;IAChC,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,EAAE,WAAW,GAAG,OAAO,GAAG,OAAO,CAAC;IACtC,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,oBAAY,OAAO,GAAG;IACpB,KAAK,EAAE,mBAAmB,CAAC;CAC5B,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","names":["PropTypes","propTypes","current","bool","icon","oneOf","value","string"],"sources":["../../../src/atom/review-header-step-item/types.ts"],"sourcesContent":["import PropTypes from 'prop-types';\n\nconst propTypes = {\n current: PropTypes.bool,\n icon: PropTypes.oneOf(['no-answer', 'right', 'wrong']),\n value: PropTypes.string\n};\n\nexport default propTypes;\n\nexport type HeaderStepItemProps = {\n current: boolean;\n icon: 'no-answer' | 'right' | 'wrong';\n value: string;\n};\n\nexport type Fixture = {\n props: HeaderStepItemProps;\n};\n"],"mappings":"AAAA,OAAOA,SAAP,MAAsB,YAAtB;AAEA,MAAMC,SAAS,GAAG;EAChBC,OAAO,EAAEF,SAAS,CAACG,IADH;EAEhBC,IAAI,EAAEJ,SAAS,CAACK,KAAV,CAAgB,CAAC,WAAD,EAAc,OAAd,EAAuB,OAAvB,CAAhB,CAFU;EAGhBC,KAAK,EAAEN,SAAS,CAACO;AAHD,CAAlB;AAMA,eAAeN,SAAf"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/atom/review-header-step-item/index.tsx"],"names":[],"mappings":";AASA,OAAkB,EAAC,mBAAmB,EAAC,MAAM,SAAS,CAAC;AAsDvD,QAAA,MAAM,oBAAoB;YAAW,mBAAmB;;;;;;CAevD,CAAC;AAWF,eAAe,oBAAoB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["Content","props","legacyContext","icon","current","value","translate","GetTranslateFromContext","child","ariaDescription","headerStepValue","classnames","style","rightIcon","currentRightIcon","wrongIcon","currentWrongIcon","ReviewHeaderStepItem","default","right","wrong","propTypes","contextTypes","skin","Provider","childContextTypes"],"sources":["../../../src/atom/review-header-step-item/index.tsx"],"sourcesContent":["import React from 'react';\nimport classnames from 'classnames';\nimport {\n NovaCompositionCoorpacademyCheck as RightIcon,\n NovaSolidStatusClose as WrongIcon\n} from '@coorpacademy/nova-icons';\nimport Provider, {GetTranslateFromContext} from '../provider';\nimport {WebContextValues} from '../provider/web-context';\nimport style from './style.css';\nimport propTypes, {HeaderStepItemProps} from './types';\n\nconst Content = (props: HeaderStepItemProps, legacyContext: WebContextValues) => {\n const {icon, current, value} = props;\n const translate = GetTranslateFromContext(legacyContext);\n let child;\n let ariaDescription;\n switch (icon) {\n case 'no-answer':\n child = value;\n ariaDescription = current\n ? translate('review_header_step_item.current_question', {\n headerStepValue: value\n })\n : translate('review_header_step_item.not_answered_question', {\n headerStepValue: value\n });\n break;\n\n case 'right':\n child = (\n <RightIcon className={classnames(style.rightIcon, current && style.currentRightIcon)} />\n );\n ariaDescription = translate('review_header_step_item.correct_question', {\n headerStepValue: value\n });\n break;\n\n case 'wrong':\n child = (\n <WrongIcon className={classnames(style.wrongIcon, current && style.currentWrongIcon)} />\n );\n ariaDescription = translate('review_header_step_item.incorrect_question', {\n headerStepValue: value\n });\n break;\n\n default:\n return null;\n }\n\n return (\n <span\n className={style.value}\n aria-label={translate('review_header_step_item.aria_label', {\n headerStepValue: value\n })}\n aria-describedby={ariaDescription}\n >\n {child}\n </span>\n );\n};\n\nconst ReviewHeaderStepItem = (props: HeaderStepItemProps) => {\n const {icon, current} = props;\n return (\n <div\n className={classnames(\n style.default,\n icon === 'right' && style.right,\n icon === 'wrong' && style.wrong,\n current && style.current\n )}\n data-name=\"header-step-item\"\n >\n <Content {...props} />\n </div>\n );\n};\n\nContent.propTypes = propTypes;\n\nContent.contextTypes = {\n skin: Provider.childContextTypes.skin,\n translate: Provider.childContextTypes.translate\n};\n\nReviewHeaderStepItem.propTypes = propTypes;\n\nexport default ReviewHeaderStepItem;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AAIA;;AAEA;;AACA;;;;;;;;AAEA,MAAMA,OAAO,GAAG,CAACC,KAAD,EAA6BC,aAA7B,KAAiE;EAC/E,MAAM;IAACC,IAAD;IAAOC,OAAP;IAAgBC;EAAhB,IAAyBJ,KAA/B;EACA,MAAMK,SAAS,GAAG,IAAAC,iCAAA,EAAwBL,aAAxB,CAAlB;EACA,IAAIM,KAAJ;EACA,IAAIC,eAAJ;;EACA,QAAQN,IAAR;IACE,KAAK,WAAL;MACEK,KAAK,GAAGH,KAAR;MACAI,eAAe,GAAGL,OAAO,GACrBE,SAAS,CAAC,0CAAD,EAA6C;QACpDI,eAAe,EAAEL;MADmC,CAA7C,CADY,GAIrBC,SAAS,CAAC,+CAAD,EAAkD;QACzDI,eAAe,EAAEL;MADwC,CAAlD,CAJb;MAOA;;IAEF,KAAK,OAAL;MACEG,KAAK,gBACH,6BAAC,2CAAD;QAAW,SAAS,EAAE,IAAAG,mBAAA,EAAWC,cAAA,CAAMC,SAAjB,EAA4BT,OAAO,IAAIQ,cAAA,CAAME,gBAA7C;MAAtB,EADF;MAGAL,eAAe,GAAGH,SAAS,CAAC,0CAAD,EAA6C;QACtEI,eAAe,EAAEL;MADqD,CAA7C,CAA3B;MAGA;;IAEF,KAAK,OAAL;MACEG,KAAK,gBACH,6BAAC,+BAAD;QAAW,SAAS,EAAE,IAAAG,mBAAA,EAAWC,cAAA,CAAMG,SAAjB,EAA4BX,OAAO,IAAIQ,cAAA,CAAMI,gBAA7C;MAAtB,EADF;MAGAP,eAAe,GAAGH,SAAS,CAAC,4CAAD,EAA+C;QACxEI,eAAe,EAAEL;MADuD,CAA/C,CAA3B;MAGA;;IAEF;MACE,OAAO,IAAP;EA/BJ;;EAkCA,oBACE;IACE,SAAS,EAAEO,cAAA,CAAMP,KADnB;IAEE,cAAYC,SAAS,CAAC,oCAAD,EAAuC;MAC1DI,eAAe,EAAEL;IADyC,CAAvC,CAFvB;IAKE,oBAAkBI;EALpB,GAOGD,KAPH,CADF;AAWD,CAlDD;;AAoDA,MAAMS,oBAAoB,GAAIhB,KAAD,IAAgC;EAC3D,MAAM;IAACE,IAAD;IAAOC;EAAP,IAAkBH,KAAxB;EACA,oBACE;IACE,SAAS,EAAE,IAAAU,mBAAA,EACTC,cAAA,CAAMM,OADG,EAETf,IAAI,KAAK,OAAT,IAAoBS,cAAA,CAAMO,KAFjB,EAGThB,IAAI,KAAK,OAAT,IAAoBS,cAAA,CAAMQ,KAHjB,EAIThB,OAAO,IAAIQ,cAAA,CAAMR,OAJR,CADb;IAOE,aAAU;EAPZ,gBASE,6BAAC,OAAD,EAAaH,KAAb,CATF,CADF;AAaD,CAfD;;AAiBAD,OAAO,CAACqB,SAAR,2CAAoBA,cAApB;AAEArB,OAAO,CAACsB,YAAR,GAAuB;EACrBC,IAAI,EAAEC,iBAAA,CAASC,iBAAT,CAA2BF,IADZ;EAErBjB,SAAS,EAAEkB,iBAAA,CAASC,iBAAT,CAA2BnB;AAFjB,CAAvB;AAKAW,oBAAoB,CAACI,SAArB,2CAAiCA,cAAjC;eAEeJ,oB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.d.ts","sourceRoot":"","sources":["../../../src/atom/review-header-step-item/index.native.tsx"],"names":[],"mappings":";AAOA,OAAO,EAAC,mBAAmB,EAAC,MAAM,SAAS,CAAC;AA6C5C,QAAA,MAAM,IAAI,6BAA4B,mBAAmB,uBA2BxD,CAAC;AAEF,eAAe,IAAI,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.js","names":["createStyle","current","icon","backgroundColor","COLORS","positive","negative","gray","StyleSheet","create","step","width","height","opacity","marginHorizontal","alignItems","justifyContent","borderRadius","stepText","fontWeight","fontSize","Step","value","style","setStyle","useState","useEffect","_style","child"],"sources":["../../../src/atom/review-header-step-item/index.native.tsx"],"sourcesContent":["import React, {useEffect, useState} from 'react';\nimport {StyleSheet, Text, TextStyle, View, ViewStyle} from 'react-native';\nimport {\n NovaCompositionCoorpacademyCheck as RightIcon,\n NovaSolidStatusClose as WrongIcon\n} from '@coorpacademy/nova-icons';\nimport {COLORS} from '../../variables/colors';\nimport {HeaderStepItemProps} from './types';\n\ntype StyleSheetType = {\n step: ViewStyle;\n stepText: TextStyle;\n icon: ViewStyle;\n};\n\nconst createStyle = (current: boolean, icon: HeaderStepItemProps['icon']): StyleSheetType => {\n let backgroundColor;\n\n switch (icon) {\n case 'right':\n backgroundColor = COLORS.positive;\n break;\n case 'wrong':\n backgroundColor = COLORS.negative;\n break;\n case 'no-answer':\n default:\n backgroundColor = COLORS.gray;\n }\n\n return StyleSheet.create({\n step: {\n width: current ? 40 : 32,\n height: current ? 40 : 32,\n opacity: current ? 1 : 0.5,\n marginHorizontal: 8,\n backgroundColor,\n alignItems: 'center',\n justifyContent: 'center',\n borderRadius: 50\n },\n stepText: {\n fontWeight: '600',\n fontSize: current ? 16 : 12\n },\n icon: {\n width: current ? 14 : 12,\n height: current ? 14 : 12\n }\n });\n};\n\nconst Step = ({value, icon, current}: HeaderStepItemProps) => {\n const [style, setStyle] = useState<StyleSheetType | null>(null);\n\n useEffect(() => {\n const _style = createStyle(current, icon);\n setStyle(_style);\n }, [current, icon]);\n\n if (!style) {\n return null;\n }\n\n let child;\n\n switch (icon) {\n case 'right':\n child = <RightIcon style={style.icon} color=\"#fff\" />;\n break;\n case 'wrong':\n child = <WrongIcon style={style.icon} color=\"#fff\" />;\n break;\n case 'no-answer':\n default:\n child = <Text style={style.stepText}>{value}</Text>;\n }\n\n return <View style={style.step}>{child}</View>;\n};\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AQ,CAACG,MAAD,CAAR;EACD,CAHD,EAGG,CAAC1B,OAAD,EAAUC,IAAV,CAHH;;EAKA,IAAI,CAACqB,KAAL,EAAY;IACV,OAAO,IAAP;EACD;;EAED,IAAIK,KAAJ;;EAEA,QAAQ1B,IAAR;IACE,KAAK,OAAL;MACE0B,KAAK,gBAAG,6BAAC,2CAAD;QAAW,KAAK,EAAEL,KAAK,CAACrB,IAAxB;QAA8B,KAAK,EAAC;MAApC,EAAR;MACA;;IACF,KAAK,OAAL;MACE0B,KAAK,gBAAG,6BAAC,+BAAD;QAAW,KAAK,EAAEL,KAAK,CAACrB,IAAxB;QAA8B,KAAK,EAAC;MAApC,EAAR;MACA;;IACF,KAAK,WAAL;IACA;MACE0B,KAAK,gBAAG,6BAAC,iBAAD;QAAM,KAAK,EAAEL,KAAK,CAACL;MAAnB,GAA8BI,KAA9B,CAAR;EATJ;;EAYA,oBAAO,6BAAC,iBAAD;IAAM,KAAK,EAAEC,KAAK,CAACb;EAAnB,GAA0BkB,KAA1B,CAAP;AACD,CA3BD;;eA6BeP,I"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/atom/review-header-step-item/types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AAEnC,QAAA,MAAM,SAAS;;;;CAId,CAAC;AAEF,eAAe,SAAS,CAAC;AAEzB,oBAAY,mBAAmB,GAAG;IAChC,OAAO,EAAE,OAAO,CAAC;IACjB,IAAI,EAAE,WAAW,GAAG,OAAO,GAAG,OAAO,CAAC;IACtC,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,oBAAY,OAAO,GAAG;IACpB,KAAK,EAAE,mBAAmB,CAAC;CAC5B,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","names":["propTypes","current","PropTypes","bool","icon","oneOf","value","string"],"sources":["../../../src/atom/review-header-step-item/types.ts"],"sourcesContent":["import PropTypes from 'prop-types';\n\nconst propTypes = {\n current: PropTypes.bool,\n icon: PropTypes.oneOf(['no-answer', 'right', 'wrong']),\n value: PropTypes.string\n};\n\nexport default propTypes;\n\nexport type HeaderStepItemProps = {\n current: boolean;\n icon: 'no-answer' | 'right' | 'wrong';\n value: string;\n};\n\nexport type Fixture = {\n props: HeaderStepItemProps;\n};\n"],"mappings":";;;;;AAAA;;;;AAEA,MAAMA,SAAS,GAAG;EAChBC,OAAO,EAAEC,kBAAA,CAAUC,IADH;EAEhBC,IAAI,EAAEF,kBAAA,CAAUG,KAAV,CAAgB,CAAC,WAAD,EAAc,OAAd,EAAuB,OAAvB,CAAhB,CAFU;EAGhBC,KAAK,EAAEJ,kBAAA,CAAUK;AAHD,CAAlB;eAMeP,S"}
|