@coorpacademy/components 10.28.2 → 10.28.3-alpha.3
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/molecule/review-correction-popin/index.d.ts.map +1 -1
- package/es/molecule/review-correction-popin/index.js +13 -5
- package/es/molecule/review-correction-popin/index.js.map +1 -1
- package/es/molecule/skill-card/index.native.d.ts +5 -0
- package/es/molecule/skill-card/index.native.d.ts.map +1 -0
- package/es/molecule/skill-card/index.native.js +82 -0
- package/es/molecule/skill-card/index.native.js.map +1 -0
- package/es/molecule/skill-card/prop-types.d.ts +14 -3
- package/es/molecule/skill-card/prop-types.d.ts.map +1 -1
- package/es/molecule/skill-card/prop-types.js +2 -1
- package/es/molecule/skill-card/prop-types.js.map +1 -1
- package/es/organism/review-no-skills/index.d.ts +11 -0
- package/es/organism/review-no-skills/index.d.ts.map +1 -0
- package/es/organism/review-no-skills/index.js +25 -0
- package/es/organism/review-no-skills/index.js.map +1 -0
- package/es/organism/review-no-skills/index.native.d.ts +5 -0
- package/es/organism/review-no-skills/index.native.d.ts.map +1 -0
- package/es/organism/review-no-skills/index.native.js +59 -0
- package/es/organism/review-no-skills/index.native.js.map +1 -0
- package/es/organism/review-no-skills/prop-types.d.ts +13 -0
- package/es/organism/review-no-skills/prop-types.d.ts.map +1 -0
- package/es/organism/review-no-skills/prop-types.js +8 -0
- package/es/organism/review-no-skills/prop-types.js.map +1 -0
- package/es/organism/review-no-skills/style.css +73 -0
- package/es/organism/review-skills/index.d.ts +5 -3
- package/es/organism/review-skills/index.d.ts.map +1 -1
- package/es/organism/review-skills/index.js +3 -60
- package/es/organism/review-skills/index.js.map +1 -1
- package/es/organism/review-skills/index.native.d.ts +5 -0
- package/es/organism/review-skills/index.native.d.ts.map +1 -0
- package/es/organism/review-skills/index.native.js +46 -0
- package/es/organism/review-skills/index.native.js.map +1 -0
- package/es/organism/review-skills/prop-types.d.ts +7 -28
- package/es/organism/review-skills/prop-types.d.ts.map +1 -1
- package/es/organism/review-skills/prop-types.js +4 -16
- package/es/organism/review-skills/prop-types.js.map +1 -1
- package/es/organism/review-skills/style.css +3 -106
- package/es/template/app-review/index.d.ts +7 -7
- package/es/template/app-review/index.js +1 -5
- package/es/template/app-review/index.js.map +1 -1
- package/es/template/app-review/index.native.d.ts.map +1 -1
- package/es/template/app-review/index.native.js +3 -1
- package/es/template/app-review/index.native.js.map +1 -1
- package/es/template/app-review/prop-types.d.ts +9 -9
- package/es/template/app-review/prop-types.d.ts.map +1 -1
- package/es/template/app-review/prop-types.js.map +1 -1
- package/es/template/app-review/skills/index.d.ts +6 -2
- package/es/template/app-review/skills/index.d.ts.map +1 -1
- package/es/template/app-review/skills/index.js +46 -2
- package/es/template/app-review/skills/index.js.map +1 -1
- package/es/template/app-review/skills/index.native.d.ts +3 -3
- package/es/template/app-review/skills/index.native.d.ts.map +1 -1
- package/es/template/app-review/skills/index.native.js +26 -176
- package/es/template/app-review/skills/index.native.js.map +1 -1
- package/es/template/app-review/skills/prop-types.d.ts +14 -38
- package/es/template/app-review/skills/prop-types.d.ts.map +1 -1
- package/es/template/app-review/skills/prop-types.js +10 -13
- package/es/template/app-review/skills/prop-types.js.map +1 -1
- package/es/template/app-review/skills/style.css +49 -0
- package/es/template/review-dashboard-skills/index.d.ts +7 -7
- package/es/template/review-dashboard-skills/index.js +1 -1
- package/es/template/review-dashboard-skills/index.js.map +1 -1
- package/lib/molecule/review-correction-popin/index.d.ts.map +1 -1
- package/lib/molecule/review-correction-popin/index.js +13 -5
- package/lib/molecule/review-correction-popin/index.js.map +1 -1
- package/lib/molecule/skill-card/index.native.d.ts +5 -0
- package/lib/molecule/skill-card/index.native.d.ts.map +1 -0
- package/lib/molecule/skill-card/index.native.js +95 -0
- package/lib/molecule/skill-card/index.native.js.map +1 -0
- package/lib/molecule/skill-card/prop-types.d.ts +14 -3
- package/lib/molecule/skill-card/prop-types.d.ts.map +1 -1
- package/lib/molecule/skill-card/prop-types.js +2 -1
- package/lib/molecule/skill-card/prop-types.js.map +1 -1
- package/lib/organism/review-no-skills/index.d.ts +11 -0
- package/lib/organism/review-no-skills/index.d.ts.map +1 -0
- package/lib/organism/review-no-skills/index.js +36 -0
- package/lib/organism/review-no-skills/index.js.map +1 -0
- package/lib/organism/review-no-skills/index.native.d.ts +5 -0
- package/lib/organism/review-no-skills/index.native.d.ts.map +1 -0
- package/lib/organism/review-no-skills/index.native.js +72 -0
- package/lib/organism/review-no-skills/index.native.js.map +1 -0
- package/lib/organism/review-no-skills/prop-types.d.ts +13 -0
- package/lib/organism/review-no-skills/prop-types.d.ts.map +1 -0
- package/lib/organism/review-no-skills/prop-types.js +17 -0
- package/lib/organism/review-no-skills/prop-types.js.map +1 -0
- package/lib/organism/review-no-skills/style.css +73 -0
- package/lib/organism/review-skills/index.d.ts +5 -3
- package/lib/organism/review-skills/index.d.ts.map +1 -1
- package/lib/organism/review-skills/index.js +3 -67
- package/lib/organism/review-skills/index.js.map +1 -1
- package/lib/organism/review-skills/index.native.d.ts +5 -0
- package/lib/organism/review-skills/index.native.d.ts.map +1 -0
- package/lib/organism/review-skills/index.native.js +57 -0
- package/lib/organism/review-skills/index.native.js.map +1 -0
- package/lib/organism/review-skills/prop-types.d.ts +7 -28
- package/lib/organism/review-skills/prop-types.d.ts.map +1 -1
- package/lib/organism/review-skills/prop-types.js +3 -19
- package/lib/organism/review-skills/prop-types.js.map +1 -1
- package/lib/organism/review-skills/style.css +3 -106
- package/lib/template/app-review/index.d.ts +7 -7
- package/lib/template/app-review/index.js +1 -5
- package/lib/template/app-review/index.js.map +1 -1
- package/lib/template/app-review/index.native.d.ts.map +1 -1
- package/lib/template/app-review/index.native.js +4 -1
- package/lib/template/app-review/index.native.js.map +1 -1
- package/lib/template/app-review/prop-types.d.ts +9 -9
- package/lib/template/app-review/prop-types.d.ts.map +1 -1
- package/lib/template/app-review/prop-types.js.map +1 -1
- package/lib/template/app-review/skills/index.d.ts +6 -2
- package/lib/template/app-review/skills/index.d.ts.map +1 -1
- package/lib/template/app-review/skills/index.js +51 -1
- package/lib/template/app-review/skills/index.js.map +1 -1
- package/lib/template/app-review/skills/index.native.d.ts +3 -3
- package/lib/template/app-review/skills/index.native.d.ts.map +1 -1
- package/lib/template/app-review/skills/index.native.js +28 -175
- package/lib/template/app-review/skills/index.native.js.map +1 -1
- package/lib/template/app-review/skills/prop-types.d.ts +14 -38
- package/lib/template/app-review/skills/prop-types.d.ts.map +1 -1
- package/lib/template/app-review/skills/prop-types.js +12 -17
- package/lib/template/app-review/skills/prop-types.js.map +1 -1
- package/lib/template/app-review/skills/style.css +49 -0
- package/lib/template/review-dashboard-skills/index.d.ts +7 -7
- package/lib/template/review-dashboard-skills/index.js +3 -3
- package/lib/template/review-dashboard-skills/index.js.map +1 -1
- package/package.json +2 -2
- package/es/template/app-review/skills/stories.d.ts +0 -1
- package/es/template/app-review/skills/stories.d.ts.map +0 -1
- package/es/template/app-review/skills/stories.js +0 -15
- package/es/template/app-review/skills/stories.js.map +0 -1
- package/lib/template/app-review/skills/stories.d.ts +0 -1
- package/lib/template/app-review/skills/stories.d.ts.map +0 -1
- package/lib/template/app-review/skills/stories.js +0 -16
- package/lib/template/app-review/skills/stories.js.map +0 -1
|
@@ -7,11 +7,15 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
7
7
|
|
|
8
8
|
var _reactNative = require("react-native");
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _index = require("../../../organism/header-v2/index.native");
|
|
11
|
+
|
|
12
|
+
var _index2 = _interopRequireDefault(require("../../../organism/review-no-skills/index.native"));
|
|
13
|
+
|
|
14
|
+
var _index3 = _interopRequireDefault(require("../../../organism/review-skills/index.native"));
|
|
11
15
|
|
|
12
16
|
var _templateContext = require("../template-context");
|
|
13
17
|
|
|
14
|
-
|
|
18
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
15
19
|
|
|
16
20
|
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); }
|
|
17
21
|
|
|
@@ -31,176 +35,19 @@ const createStyleSheet = theme => _reactNative.StyleSheet.create({
|
|
|
31
35
|
color: theme.colors.text.primary,
|
|
32
36
|
marginBottom: theme.spacing.base,
|
|
33
37
|
marginTop: theme.spacing.small
|
|
34
|
-
},
|
|
35
|
-
subtitle: {
|
|
36
|
-
fontSize: theme.fontSize.xlarge,
|
|
37
|
-
color: theme.colors.text.primary,
|
|
38
|
-
marginBottom: theme.spacing.tiny
|
|
39
|
-
},
|
|
40
|
-
text: {
|
|
41
|
-
fontSize: 16,
|
|
42
|
-
lineHeight: 22,
|
|
43
|
-
color: theme.colors.text.primary,
|
|
44
|
-
opacity: 0.7,
|
|
45
|
-
marginBottom: theme.spacing.base
|
|
46
|
-
},
|
|
47
|
-
noSkillsImage: {
|
|
48
|
-
flex: 1,
|
|
49
|
-
alignSelf: 'center',
|
|
50
|
-
width: 320,
|
|
51
|
-
height: 300
|
|
52
|
-
},
|
|
53
|
-
skills: {
|
|
54
|
-
paddingBottom: 100
|
|
55
|
-
},
|
|
56
|
-
skill: {
|
|
57
|
-
display: 'flex',
|
|
58
|
-
flexDirection: 'row',
|
|
59
|
-
overflow: 'hidden',
|
|
60
|
-
alignItems: 'center',
|
|
61
|
-
height: 118,
|
|
62
|
-
borderRadius: 8,
|
|
63
|
-
backgroundColor: theme.colors.gray.lighter,
|
|
64
|
-
marginTop: theme.spacing.micro,
|
|
65
|
-
marginBottom: theme.spacing.micro,
|
|
66
|
-
padding: theme.spacing.base
|
|
67
|
-
},
|
|
68
|
-
skillTexts: {
|
|
69
|
-
flex: 1,
|
|
70
|
-
flexDirection: 'column'
|
|
71
|
-
},
|
|
72
|
-
skillTitle: {
|
|
73
|
-
fontSize: 18,
|
|
74
|
-
fontWeight: '600',
|
|
75
|
-
lineHeight: 22,
|
|
76
|
-
color: theme.colors.text.primary,
|
|
77
|
-
marginBottom: theme.spacing.tiny
|
|
78
|
-
},
|
|
79
|
-
skillInfo: {
|
|
80
|
-
fontSize: 12,
|
|
81
|
-
lineHeight: 16,
|
|
82
|
-
color: theme.colors.gray.medium
|
|
83
|
-
}
|
|
84
|
-
}); // -----------------------------------------------------------------------------
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
const onSelectSkill = title => () => {
|
|
88
|
-
// eslint-disable-next-line no-console
|
|
89
|
-
console.log('pressed on', {
|
|
90
|
-
title
|
|
91
|
-
});
|
|
92
|
-
};
|
|
93
|
-
|
|
94
|
-
const Skill = ({
|
|
95
|
-
title,
|
|
96
|
-
info
|
|
97
|
-
}) => {
|
|
98
|
-
const templateContext = (0, _templateContext.useTemplateContext)();
|
|
99
|
-
const [styleSheet, setStylesheet] = (0, _react.useState)(null);
|
|
100
|
-
const {
|
|
101
|
-
theme
|
|
102
|
-
} = templateContext;
|
|
103
|
-
(0, _react.useEffect)(() => {
|
|
104
|
-
const _stylesheet = createStyleSheet(theme);
|
|
105
|
-
|
|
106
|
-
setStylesheet(_stylesheet);
|
|
107
|
-
}, [theme]);
|
|
108
|
-
|
|
109
|
-
if (!styleSheet) {
|
|
110
|
-
return null;
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
return /*#__PURE__*/_react.default.createElement(_reactNative.Pressable, {
|
|
114
|
-
style: styleSheet.skill,
|
|
115
|
-
onPress: onSelectSkill(title)
|
|
116
|
-
}, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
117
|
-
style: styleSheet.skillTexts
|
|
118
|
-
}, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
119
|
-
style: styleSheet.skillTitle
|
|
120
|
-
}, title), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
121
|
-
style: styleSheet.skillInfo
|
|
122
|
-
}, info)), /*#__PURE__*/_react.default.createElement(_novaIcons.NovaCompositionNavigationArrowRight, {
|
|
123
|
-
color: "#ededed",
|
|
124
|
-
height: 20,
|
|
125
|
-
width: 20
|
|
126
|
-
}));
|
|
127
|
-
}; // -----------------------------------------------------------------------------
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
const Item = ({
|
|
131
|
-
item: {
|
|
132
|
-
title,
|
|
133
|
-
info
|
|
134
38
|
}
|
|
135
|
-
}) => /*#__PURE__*/_react.default.createElement(Skill, {
|
|
136
|
-
title: title,
|
|
137
|
-
info: info
|
|
138
39
|
});
|
|
139
40
|
|
|
140
|
-
const
|
|
141
|
-
const templateContext = (0, _templateContext.useTemplateContext)();
|
|
142
|
-
const [styleSheet, setStylesheet] = (0, _react.useState)(null);
|
|
143
|
-
const {
|
|
144
|
-
theme
|
|
145
|
-
} = templateContext;
|
|
146
|
-
const {
|
|
147
|
-
skills
|
|
148
|
-
} = props;
|
|
149
|
-
(0, _react.useEffect)(() => {
|
|
150
|
-
const _stylesheet = createStyleSheet(theme);
|
|
151
|
-
|
|
152
|
-
setStylesheet(_stylesheet);
|
|
153
|
-
}, [theme]);
|
|
154
|
-
|
|
155
|
-
if (!styleSheet) {
|
|
156
|
-
return null;
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
const formattedDataList = [];
|
|
160
|
-
skills.map(skill => formattedDataList.push({
|
|
161
|
-
title: skill.skillTitle,
|
|
162
|
-
info: skill.skillAriaLabel
|
|
163
|
-
}));
|
|
164
|
-
return /*#__PURE__*/_react.default.createElement(_reactNative.FlatList, {
|
|
165
|
-
contentContainerStyle: styleSheet.skills,
|
|
166
|
-
data: formattedDataList,
|
|
167
|
-
renderItem: Item
|
|
168
|
-
});
|
|
169
|
-
}; // -----------------------------------------------------------------------------
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
const NoSkills = () => {
|
|
173
|
-
const templateContext = (0, _templateContext.useTemplateContext)();
|
|
174
|
-
const [styleSheet, setStylesheet] = (0, _react.useState)(null);
|
|
175
|
-
const {
|
|
176
|
-
theme,
|
|
177
|
-
translations
|
|
178
|
-
} = templateContext;
|
|
179
|
-
(0, _react.useEffect)(() => {
|
|
180
|
-
const _stylesheet = createStyleSheet(theme);
|
|
181
|
-
|
|
182
|
-
setStylesheet(_stylesheet);
|
|
183
|
-
}, [theme]);
|
|
184
|
-
|
|
185
|
-
if (!styleSheet) {
|
|
186
|
-
return null;
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
190
|
-
style: styleSheet.subtitle
|
|
191
|
-
}, translations.appReview?.noSkills?.title), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
192
|
-
style: styleSheet.text
|
|
193
|
-
}, translations.appReview?.noSkills?.text), /*#__PURE__*/_react.default.createElement(_novaIcons.NovaCompositionCoorpacademyEmptyStateHomeRevision, {
|
|
194
|
-
style: styleSheet.noSkillsImage
|
|
195
|
-
}));
|
|
196
|
-
}; // -----------------------------------------------------------------------------
|
|
197
|
-
// title --> translations.revision.home.title
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
const Skills = props => {
|
|
41
|
+
const ReviewSkills = props => {
|
|
201
42
|
const {
|
|
43
|
+
'aria-label': ariaLabel,
|
|
202
44
|
title,
|
|
203
|
-
|
|
45
|
+
isLoading,
|
|
46
|
+
isLoadingAriaLabel,
|
|
47
|
+
listSkills,
|
|
48
|
+
titleNoSkills,
|
|
49
|
+
textNoSkills,
|
|
50
|
+
iconSkillAriaLabel
|
|
204
51
|
} = props;
|
|
205
52
|
const templateContext = (0, _templateContext.useTemplateContext)();
|
|
206
53
|
const [styleSheet, setStylesheet] = (0, _react.useState)(null);
|
|
@@ -211,22 +58,28 @@ const Skills = props => {
|
|
|
211
58
|
const _stylesheet = createStyleSheet(theme);
|
|
212
59
|
|
|
213
60
|
setStylesheet(_stylesheet);
|
|
214
|
-
}, [theme]);
|
|
61
|
+
}, [theme]);
|
|
215
62
|
|
|
216
63
|
if (!styleSheet) {
|
|
217
64
|
return null;
|
|
218
65
|
}
|
|
219
66
|
|
|
220
67
|
return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
221
|
-
style: styleSheet.container
|
|
68
|
+
style: styleSheet.container,
|
|
69
|
+
accessibilityLabel: ariaLabel
|
|
222
70
|
}, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
223
71
|
style: styleSheet.title
|
|
224
|
-
}, title),
|
|
225
|
-
|
|
226
|
-
})
|
|
227
|
-
|
|
228
|
-
|
|
72
|
+
}, title), isLoading ? /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
73
|
+
accessibilityLabel: isLoadingAriaLabel
|
|
74
|
+
}, "Loading") : /*#__PURE__*/_react.default.createElement(_reactNative.View, null, !listSkills || listSkills.length === 0 ? /*#__PURE__*/_react.default.createElement(_index2.default, {
|
|
75
|
+
titleNoSkills: titleNoSkills,
|
|
76
|
+
textNoSkills: textNoSkills,
|
|
77
|
+
iconSkillAriaLabel: iconSkillAriaLabel
|
|
78
|
+
}) : /*#__PURE__*/_react.default.createElement(_index3.default, {
|
|
79
|
+
listSkills: listSkills
|
|
80
|
+
})));
|
|
81
|
+
};
|
|
229
82
|
|
|
230
|
-
var _default =
|
|
83
|
+
var _default = ReviewSkills;
|
|
231
84
|
exports.default = _default;
|
|
232
85
|
//# sourceMappingURL=index.native.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.js","names":["createStyleSheet","theme","StyleSheet","create","container","flex","padding","paddingTop","HEADER_HEIGHT","backgroundColor","colors","white","title","fontSize","xlarge","fontWeight","bold","lineHeight","color","text","primary","marginBottom","spacing","base","marginTop","small","subtitle","tiny","opacity","noSkillsImage","alignSelf","width","height","skills","paddingBottom","skill","display","flexDirection","overflow","alignItems","borderRadius","gray","lighter","micro","skillTexts","skillTitle","skillInfo","medium","onSelectSkill","console","log","Skill","info","templateContext","useTemplateContext","styleSheet","setStylesheet","useState","useEffect","_stylesheet","Item","item","List","props","formattedDataList","map","push","skillAriaLabel","NoSkills","translations","appReview","noSkills","Skills","listSkills","length"],"sources":["../../../../src/template/app-review/skills/index.native.tsx"],"sourcesContent":["import React, {useState, useEffect} from 'react';\nimport {View, FlatList, Pressable, StyleSheet, Text, ViewStyle, TextStyle} from 'react-native';\nimport {\n NovaCompositionNavigationArrowRight as ArrowRight,\n NovaCompositionCoorpacademyEmptyStateHomeRevision as EmptyStateHomeRevision\n} from '@coorpacademy/nova-icons';\nimport {useTemplateContext} from '../template-context';\nimport {Theme} from '../../../variables/theme.native';\n\nimport {HEADER_HEIGHT} from '../../../organism/header-v2/index.native';\nimport {ItemProps, ListSkillsProps, SkillProps, SkillsProps} from './prop-types';\n\ntype StyleSheetType = {\n container: ViewStyle;\n title: TextStyle;\n subtitle: TextStyle;\n text: TextStyle;\n noSkillsImage: ViewStyle;\n skills: ViewStyle;\n skill: ViewStyle;\n skillTexts: TextStyle;\n skillTitle: TextStyle;\n skillInfo: TextStyle;\n};\n\nconst createStyleSheet = (theme: Theme): StyleSheetType =>\n StyleSheet.create({\n container: {\n flex: 1,\n padding: 20,\n paddingTop: HEADER_HEIGHT + 20,\n backgroundColor: theme.colors.white\n },\n title: {\n fontSize: theme.fontSize.xlarge,\n fontWeight: theme.fontWeight.bold,\n lineHeight: 28,\n color: theme.colors.text.primary,\n marginBottom: theme.spacing.base,\n marginTop: theme.spacing.small\n },\n subtitle: {\n fontSize: theme.fontSize.xlarge,\n color: theme.colors.text.primary,\n marginBottom: theme.spacing.tiny\n },\n text: {\n fontSize: 16,\n lineHeight: 22,\n color: theme.colors.text.primary,\n opacity: 0.7,\n marginBottom: theme.spacing.base\n },\n noSkillsImage: {\n flex: 1,\n alignSelf: 'center',\n width: 320,\n height: 300\n },\n skills: {paddingBottom: 100},\n skill: {\n display: 'flex',\n flexDirection: 'row',\n overflow: 'hidden',\n alignItems: 'center',\n height: 118,\n borderRadius: 8,\n backgroundColor: theme.colors.gray.lighter,\n marginTop: theme.spacing.micro,\n marginBottom: theme.spacing.micro,\n padding: theme.spacing.base\n },\n skillTexts: {\n flex: 1,\n flexDirection: 'column'\n },\n skillTitle: {\n fontSize: 18,\n fontWeight: '600',\n lineHeight: 22,\n color: theme.colors.text.primary,\n marginBottom: theme.spacing.tiny\n },\n skillInfo: {\n fontSize: 12,\n lineHeight: 16,\n color: theme.colors.gray.medium\n }\n });\n\n// -----------------------------------------------------------------------------\n\nconst onSelectSkill = (title: string) => () => {\n // eslint-disable-next-line no-console\n console.log('pressed on', {title});\n};\n\nconst Skill = ({title, info}: SkillProps) => {\n const templateContext = useTemplateContext();\n const [styleSheet, setStylesheet] = useState<StyleSheetType | null>(null);\n const {theme} = templateContext;\n\n useEffect(() => {\n const _stylesheet = createStyleSheet(theme);\n setStylesheet(_stylesheet);\n }, [theme]);\n\n if (!styleSheet) {\n return null;\n }\n\n return (\n <Pressable style={styleSheet.skill} onPress={onSelectSkill(title)}>\n <View style={styleSheet.skillTexts}>\n <Text style={styleSheet.skillTitle}>{title}</Text>\n <Text style={styleSheet.skillInfo}>{info}</Text>\n </View>\n <ArrowRight color=\"#ededed\" height={20} width={20} />\n </Pressable>\n );\n};\n\n// -----------------------------------------------------------------------------\n\nconst Item = ({item: {title, info}}: ItemProps) => <Skill title={title} info={info} />;\n\ntype ItemDataType = {\n title: string;\n info: string;\n};\n\nconst List = (props: {skills: Array<ListSkillsProps>}) => {\n const templateContext = useTemplateContext();\n const [styleSheet, setStylesheet] = useState<StyleSheetType | null>(null);\n const {theme} = templateContext;\n const {skills} = props;\n\n useEffect(() => {\n const _stylesheet = createStyleSheet(theme);\n setStylesheet(_stylesheet);\n }, [theme]);\n\n if (!styleSheet) {\n return null;\n }\n\n const formattedDataList: Array<ItemDataType> = [];\n skills.map(skill =>\n formattedDataList.push({\n title: skill.skillTitle,\n info: skill.skillAriaLabel\n })\n );\n\n return (\n <FlatList\n contentContainerStyle={styleSheet.skills}\n data={formattedDataList}\n renderItem={Item}\n />\n );\n};\n\n// -----------------------------------------------------------------------------\n\nconst NoSkills = () => {\n const templateContext = useTemplateContext();\n const [styleSheet, setStylesheet] = useState<StyleSheetType | null>(null);\n const {theme, translations} = templateContext;\n\n useEffect(() => {\n const _stylesheet = createStyleSheet(theme);\n setStylesheet(_stylesheet);\n }, [theme]);\n\n if (!styleSheet) {\n return null;\n }\n\n return (\n <>\n <Text style={styleSheet.subtitle}>{translations.appReview?.noSkills?.title}</Text>\n <Text style={styleSheet.text}>{translations.appReview?.noSkills?.text}</Text>\n <EmptyStateHomeRevision style={styleSheet.noSkillsImage} />\n </>\n );\n};\n\n// -----------------------------------------------------------------------------\n\n// title --> translations.revision.home.title\nconst Skills = (props: SkillsProps) => {\n const {title, listSkills} = props;\n const templateContext = useTemplateContext();\n const [styleSheet, setStylesheet] = useState<StyleSheetType | null>(null);\n const {theme} = templateContext;\n\n useEffect(() => {\n const _stylesheet = createStyleSheet(theme);\n setStylesheet(_stylesheet);\n }, [theme]);\n\n // ------------------------------------\n\n if (!styleSheet) {\n return null;\n }\n\n return (\n <View style={styleSheet.container}>\n <Text style={styleSheet.title}>{title}</Text>\n {!listSkills || listSkills.length === 0 ? <NoSkills /> : <List skills={listSkills} />}\n </View>\n );\n};\n\n// -----------------------------------------------------------------------------\n\nexport default Skills;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AAIA;;AAGA;;;;;;AAgBA,MAAMA,gBAAgB,GAAIC,KAAD,IACvBC,uBAAA,CAAWC,MAAX,CAAkB;EAChBC,SAAS,EAAE;IACTC,IAAI,EAAE,CADG;IAETC,OAAO,EAAE,EAFA;IAGTC,UAAU,EAAEC,oBAAA,GAAgB,EAHnB;IAITC,eAAe,EAAER,KAAK,CAACS,MAAN,CAAaC;EAJrB,CADK;EAOhBC,KAAK,EAAE;IACLC,QAAQ,EAAEZ,KAAK,CAACY,QAAN,CAAeC,MADpB;IAELC,UAAU,EAAEd,KAAK,CAACc,UAAN,CAAiBC,IAFxB;I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GG,CAAC1D,KAAD,CAHH,EANqC,CAWrC;;EAEA,IAAI,CAACsD,UAAL,EAAiB;IACf,OAAO,IAAP;EACD;;EAED,oBACE,6BAAC,iBAAD;IAAM,KAAK,EAAEA,UAAU,CAACnD;EAAxB,gBACE,6BAAC,iBAAD;IAAM,KAAK,EAAEmD,UAAU,CAAC3C;EAAxB,GAAgCA,KAAhC,CADF,EAEG,CAAC6D,UAAD,IAAeA,UAAU,CAACC,MAAX,KAAsB,CAArC,gBAAyC,6BAAC,QAAD,OAAzC,gBAAwD,6BAAC,IAAD;IAAM,MAAM,EAAED;EAAd,EAF3D,CADF;AAMD,CAvBD,C,CAyBA;;;eAEeD,M"}
|
|
1
|
+
{"version":3,"file":"index.native.js","names":["createStyleSheet","theme","StyleSheet","create","container","flex","padding","paddingTop","HEADER_HEIGHT","backgroundColor","colors","white","title","fontSize","xlarge","fontWeight","bold","lineHeight","color","text","primary","marginBottom","spacing","base","marginTop","small","ReviewSkills","props","ariaLabel","isLoading","isLoadingAriaLabel","listSkills","titleNoSkills","textNoSkills","iconSkillAriaLabel","templateContext","useTemplateContext","styleSheet","setStylesheet","useState","useEffect","_stylesheet","length"],"sources":["../../../../src/template/app-review/skills/index.native.tsx"],"sourcesContent":["import React, {useState, useEffect} from 'react';\nimport {Text, View, StyleSheet, ViewStyle, TextStyle} from 'react-native';\nimport {HEADER_HEIGHT} from '../../../organism/header-v2/index.native';\nimport ReviewNoSkills from '../../../organism/review-no-skills/index.native';\nimport ReviewListSkills from '../../../organism/review-skills/index.native';\nimport {Theme} from '../../../variables/theme.native';\nimport {useTemplateContext} from '../template-context';\nimport {ReviewSkillsProps} from './prop-types';\n\ntype StyleSheetType = {\n container: ViewStyle;\n title: TextStyle;\n};\n\nconst createStyleSheet = (theme: Theme): StyleSheetType =>\n StyleSheet.create({\n container: {\n flex: 1,\n padding: 20,\n paddingTop: HEADER_HEIGHT + 20,\n backgroundColor: theme.colors.white\n },\n title: {\n fontSize: theme.fontSize.xlarge,\n fontWeight: theme.fontWeight.bold,\n lineHeight: 28,\n color: theme.colors.text.primary,\n marginBottom: theme.spacing.base,\n marginTop: theme.spacing.small\n }\n });\n\nconst ReviewSkills = (props: ReviewSkillsProps) => {\n const {\n 'aria-label': ariaLabel,\n title,\n isLoading,\n isLoadingAriaLabel,\n listSkills,\n titleNoSkills,\n textNoSkills,\n iconSkillAriaLabel\n } = props;\n const templateContext = useTemplateContext();\n const [styleSheet, setStylesheet] = useState<StyleSheetType | null>(null);\n const {theme} = templateContext;\n\n useEffect(() => {\n const _stylesheet = createStyleSheet(theme);\n setStylesheet(_stylesheet);\n }, [theme]);\n\n if (!styleSheet) {\n return null;\n }\n\n return (\n <View style={styleSheet.container} accessibilityLabel={ariaLabel}>\n <Text style={styleSheet.title}>{title}</Text>\n {isLoading ? (\n <Text accessibilityLabel={isLoadingAriaLabel}>Loading</Text>\n ) : (\n <View>\n {!listSkills || listSkills.length === 0 ? (\n <ReviewNoSkills\n titleNoSkills={titleNoSkills}\n textNoSkills={textNoSkills}\n iconSkillAriaLabel={iconSkillAriaLabel}\n />\n ) : (\n <ReviewListSkills listSkills={listSkills} />\n )}\n </View>\n )}\n </View>\n );\n};\n\nexport default ReviewSkills;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AAEA;;;;;;;;AAQA,MAAMA,gBAAgB,GAAIC,KAAD,IACvBC,uBAAA,CAAWC,MAAX,CAAkB;EAChBC,SAAS,EAAE;IACTC,IAAI,EAAE,CADG;IAETC,OAAO,EAAE,EAFA;IAGTC,UAAU,EAAEC,oBAAA,GAAgB,EAHnB;IAITC,eAAe,EAAER,KAAK,CAACS,MAAN,CAAaC;EAJrB,CADK;EAOhBC,KAAK,EAAE;IACLC,QAAQ,EAAEZ,KAAK,CAACY,QAAN,CAAeC,MADpB;IAELC,UAAU,EAAEd,KAAK,CAACc,UAAN,CAAiBC,IAFxB;IAGLC,UAAU,EAAE,EAHP;IAILC,KAAK,EAAEjB,KAAK,CAACS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"}
|
|
@@ -1,17 +1,12 @@
|
|
|
1
1
|
import PropTypes from 'prop-types';
|
|
2
|
-
|
|
2
|
+
import { NoSkillsProps } from '../../../organism/review-no-skills/prop-types';
|
|
3
|
+
import { ReviewSkills } from '../../../organism/review-skills/prop-types';
|
|
4
|
+
declare const propTypes: {
|
|
5
|
+
'aria-label': PropTypes.Requireable<string>;
|
|
3
6
|
title: PropTypes.Requireable<string>;
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
item: PropTypes.Requireable<PropTypes.InferProps<{
|
|
8
|
-
title: PropTypes.Requireable<string>;
|
|
9
|
-
info: PropTypes.Requireable<string>;
|
|
10
|
-
isExtraSpace: PropTypes.Requireable<boolean>;
|
|
11
|
-
}>>;
|
|
12
|
-
};
|
|
13
|
-
export declare const ListPropTypes: {
|
|
14
|
-
skills: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
7
|
+
isLoading: PropTypes.Requireable<boolean>;
|
|
8
|
+
isLoadingAriaLabel: PropTypes.Requireable<string>;
|
|
9
|
+
listSkills: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
15
10
|
'aria-label': PropTypes.Requireable<string>;
|
|
16
11
|
skillTitle: PropTypes.Requireable<string>;
|
|
17
12
|
skillAriaLabel: PropTypes.Requireable<string>;
|
|
@@ -22,34 +17,15 @@ export declare const ListPropTypes: {
|
|
|
22
17
|
isCustom: PropTypes.Requireable<boolean>;
|
|
23
18
|
onClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
24
19
|
}> | null | undefined)[]>;
|
|
20
|
+
titleNoSkills: PropTypes.Requireable<string>;
|
|
21
|
+
textNoSkills: PropTypes.Requireable<string>;
|
|
22
|
+
iconSkillAriaLabel: PropTypes.Requireable<string>;
|
|
25
23
|
};
|
|
26
|
-
export
|
|
27
|
-
|
|
28
|
-
info: string;
|
|
29
|
-
};
|
|
30
|
-
export declare type ItemProps = {
|
|
31
|
-
item: {
|
|
32
|
-
title: string;
|
|
33
|
-
info: string;
|
|
34
|
-
};
|
|
35
|
-
};
|
|
36
|
-
export declare type NoSkillsProps = {
|
|
37
|
-
titleNoSkills: string;
|
|
38
|
-
textNoSkills: string;
|
|
39
|
-
};
|
|
40
|
-
export declare type ListSkillsProps = {
|
|
41
|
-
skillTitle: string;
|
|
42
|
-
isCustom: boolean;
|
|
24
|
+
export default propTypes;
|
|
25
|
+
export declare type ReviewSkillsProps = NoSkillsProps & ReviewSkills & {
|
|
43
26
|
'aria-label': string;
|
|
44
|
-
skillAriaLabel: string;
|
|
45
|
-
buttonLabel: string;
|
|
46
|
-
buttonAriaLabel: string;
|
|
47
|
-
reviseLabel: string;
|
|
48
|
-
reviseAriaLabel: string;
|
|
49
|
-
onClick: () => void;
|
|
50
|
-
};
|
|
51
|
-
export declare type SkillsProps = {
|
|
52
27
|
title: string;
|
|
53
|
-
|
|
28
|
+
isLoading: boolean;
|
|
29
|
+
isLoadingAriaLabel: string;
|
|
54
30
|
};
|
|
55
31
|
//# sourceMappingURL=prop-types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prop-types.d.ts","sourceRoot":"","sources":["../../../../src/template/app-review/skills/prop-types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"prop-types.d.ts","sourceRoot":"","sources":["../../../../src/template/app-review/skills/prop-types.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,YAAY,CAAC;AAEnC,OAAO,EAAC,aAAa,EAAC,MAAM,+CAA+C,CAAC;AAC5E,OAAO,EAAC,YAAY,EAAC,MAAM,4CAA4C,CAAC;AAExE,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;;;;;CASd,CAAC;AAEF,eAAe,SAAS,CAAC;AAEzB,oBAAY,iBAAiB,GAAG,aAAa,GAC3C,YAAY,GAAG;IACb,YAAY,EAAE,MAAM,CAAC;IACrB,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,OAAO,CAAC;IACnB,kBAAkB,EAAE,MAAM,CAAC;CAC5B,CAAC"}
|
|
@@ -1,29 +1,24 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
exports.__esModule = true;
|
|
4
|
-
exports.
|
|
4
|
+
exports.default = void 0;
|
|
5
5
|
|
|
6
6
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
7
7
|
|
|
8
|
-
var _propTypes2 = require("../../../
|
|
8
|
+
var _propTypes2 = _interopRequireDefault(require("../../../molecule/skill-card/prop-types"));
|
|
9
9
|
|
|
10
10
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
11
|
|
|
12
|
-
const
|
|
12
|
+
const propTypes = {
|
|
13
|
+
'aria-label': _propTypes.default.string,
|
|
13
14
|
title: _propTypes.default.string,
|
|
14
|
-
|
|
15
|
+
isLoading: _propTypes.default.bool,
|
|
16
|
+
isLoadingAriaLabel: _propTypes.default.string,
|
|
17
|
+
listSkills: _propTypes.default.arrayOf(_propTypes.default.shape(_propTypes2.default)),
|
|
18
|
+
titleNoSkills: _propTypes.default.string,
|
|
19
|
+
textNoSkills: _propTypes.default.string,
|
|
20
|
+
iconSkillAriaLabel: _propTypes.default.string
|
|
15
21
|
};
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
item: _propTypes.default.shape({
|
|
19
|
-
title: _propTypes.default.string,
|
|
20
|
-
info: _propTypes.default.string,
|
|
21
|
-
isExtraSpace: _propTypes.default.bool
|
|
22
|
-
})
|
|
23
|
-
};
|
|
24
|
-
exports.ItemPropsTypes = ItemPropsTypes;
|
|
25
|
-
const ListPropTypes = {
|
|
26
|
-
skills: _propTypes2.ListSkillsPropTypes.listSkills
|
|
27
|
-
};
|
|
28
|
-
exports.ListPropTypes = ListPropTypes;
|
|
22
|
+
var _default = propTypes;
|
|
23
|
+
exports.default = _default;
|
|
29
24
|
//# sourceMappingURL=prop-types.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prop-types.js","names":["
|
|
1
|
+
{"version":3,"file":"prop-types.js","names":["propTypes","PropTypes","string","title","isLoading","bool","isLoadingAriaLabel","listSkills","arrayOf","shape","SkillCardPropsType","titleNoSkills","textNoSkills","iconSkillAriaLabel"],"sources":["../../../../src/template/app-review/skills/prop-types.ts"],"sourcesContent":["import PropTypes from 'prop-types';\nimport SkillCardPropsType from '../../../molecule/skill-card/prop-types';\nimport {NoSkillsProps} from '../../../organism/review-no-skills/prop-types';\nimport {ReviewSkills} from '../../../organism/review-skills/prop-types';\n\nconst propTypes = {\n 'aria-label': PropTypes.string,\n title: PropTypes.string,\n isLoading: PropTypes.bool,\n isLoadingAriaLabel: PropTypes.string,\n listSkills: PropTypes.arrayOf(PropTypes.shape(SkillCardPropsType)),\n titleNoSkills: PropTypes.string,\n textNoSkills: PropTypes.string,\n iconSkillAriaLabel: PropTypes.string\n};\n\nexport default propTypes;\n\nexport type ReviewSkillsProps = NoSkillsProps &\n ReviewSkills & {\n 'aria-label': string;\n title: string;\n isLoading: boolean;\n isLoadingAriaLabel: string;\n };\n"],"mappings":";;;;;AAAA;;AACA;;;;AAIA,MAAMA,SAAS,GAAG;EAChB,cAAcC,kBAAA,CAAUC,MADR;EAEhBC,KAAK,EAAEF,kBAAA,CAAUC,MAFD;EAGhBE,SAAS,EAAEH,kBAAA,CAAUI,IAHL;EAIhBC,kBAAkB,EAAEL,kBAAA,CAAUC,MAJd;EAKhBK,UAAU,EAAEN,kBAAA,CAAUO,OAAV,CAAkBP,kBAAA,CAAUQ,KAAV,CAAgBC,mBAAhB,CAAlB,CALI;EAMhBC,aAAa,EAAEV,kBAAA,CAAUC,MANT;EAOhBU,YAAY,EAAEX,kBAAA,CAAUC,MAPR;EAQhBW,kBAAkB,EAAEZ,kBAAA,CAAUC;AARd,CAAlB;eAWeF,S"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
@value breakpoints: "../../../variables/breakpoints.css";
|
|
2
|
+
@value mobile from breakpoints;
|
|
3
|
+
@value colors: "../../../variables/colors.css";
|
|
4
|
+
@value cm_blue_900 from colors;
|
|
5
|
+
@value cm_grey_500 from colors;
|
|
6
|
+
|
|
7
|
+
.textBase {
|
|
8
|
+
color: cm_blue_900;
|
|
9
|
+
font-family: "Gilroy";
|
|
10
|
+
font-style: normal;
|
|
11
|
+
user-select: none;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.containerReviewSkill {
|
|
15
|
+
width: 100%;
|
|
16
|
+
position: relative;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.title {
|
|
20
|
+
composes: textBase;
|
|
21
|
+
font-size: 20px;
|
|
22
|
+
font-weight: 600;
|
|
23
|
+
line-height: 28px;
|
|
24
|
+
margin-left: 40px;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.informationIcon {
|
|
28
|
+
color: cm_grey_500;
|
|
29
|
+
padding-left: 8px;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.loaderContainer {
|
|
33
|
+
width: 100%;
|
|
34
|
+
height: 50vh;
|
|
35
|
+
display: flex;
|
|
36
|
+
align-items: center;
|
|
37
|
+
justify-content: center;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.loader {
|
|
41
|
+
height: 60px;
|
|
42
|
+
width: 60px;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
@media mobile {
|
|
46
|
+
.title {
|
|
47
|
+
margin-left: 0;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
@@ -27,9 +27,10 @@ declare namespace ReviewDashboardSkills {
|
|
|
27
27
|
}>>;
|
|
28
28
|
}>>;
|
|
29
29
|
reviewSkills: PropTypes.Requireable<PropTypes.InferProps<{
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
30
|
+
'aria-label': PropTypes.Requireable<string>;
|
|
31
|
+
title: PropTypes.Requireable<string>;
|
|
32
|
+
isLoading: PropTypes.Requireable<boolean>;
|
|
33
|
+
isLoadingAriaLabel: PropTypes.Requireable<string>;
|
|
33
34
|
listSkills: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
34
35
|
'aria-label': PropTypes.Requireable<string>;
|
|
35
36
|
skillTitle: PropTypes.Requireable<string>;
|
|
@@ -41,10 +42,9 @@ declare namespace ReviewDashboardSkills {
|
|
|
41
42
|
isCustom: PropTypes.Requireable<boolean>;
|
|
42
43
|
onClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
43
44
|
}> | null | undefined)[]>;
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
isLoadingAriaLabel: PropTypes.Requireable<string>;
|
|
45
|
+
titleNoSkills: PropTypes.Requireable<string>;
|
|
46
|
+
textNoSkills: PropTypes.Requireable<string>;
|
|
47
|
+
iconSkillAriaLabel: PropTypes.Requireable<string>;
|
|
48
48
|
}>>;
|
|
49
49
|
};
|
|
50
50
|
}
|
|
@@ -9,7 +9,7 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
|
9
9
|
|
|
10
10
|
var _reviewPresentation = _interopRequireDefault(require("../../atom/review-presentation"));
|
|
11
11
|
|
|
12
|
-
var
|
|
12
|
+
var _skills = _interopRequireDefault(require("../app-review/skills"));
|
|
13
13
|
|
|
14
14
|
var _style = _interopRequireDefault(require("./style.css"));
|
|
15
15
|
|
|
@@ -28,13 +28,13 @@ const ReviewDashboardSkills = props => {
|
|
|
28
28
|
className: _style.default.reviewPresentationContainer
|
|
29
29
|
}, /*#__PURE__*/_react.default.createElement(_reviewPresentation.default, reviewPresentation)), /*#__PURE__*/_react.default.createElement("div", {
|
|
30
30
|
className: _style.default.reviewSkillsContainer
|
|
31
|
-
}, /*#__PURE__*/_react.default.createElement(
|
|
31
|
+
}, /*#__PURE__*/_react.default.createElement(_skills.default, reviewSkills)));
|
|
32
32
|
};
|
|
33
33
|
|
|
34
34
|
ReviewDashboardSkills.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
35
35
|
'aria-label': _propTypes.default.string,
|
|
36
36
|
reviewPresentation: _propTypes.default.shape(_reviewPresentation.default.propTypes),
|
|
37
|
-
reviewSkills: _propTypes.default.shape(
|
|
37
|
+
reviewSkills: _propTypes.default.shape(_skills.default.propTypes)
|
|
38
38
|
} : {};
|
|
39
39
|
var _default = ReviewDashboardSkills;
|
|
40
40
|
exports.default = _default;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["ReviewDashboardSkills","props","ariaLabel","reviewPresentation","reviewSkills","style","reviewDashboardContainer","reviewPresentationContainer","reviewSkillsContainer","propTypes","PropTypes","string","shape","ReviewPresentation","ReviewSkills"],"sources":["../../../src/template/review-dashboard-skills/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport ReviewPresentation from '../../atom/review-presentation';\nimport ReviewSkills from '
|
|
1
|
+
{"version":3,"file":"index.js","names":["ReviewDashboardSkills","props","ariaLabel","reviewPresentation","reviewSkills","style","reviewDashboardContainer","reviewPresentationContainer","reviewSkillsContainer","propTypes","PropTypes","string","shape","ReviewPresentation","ReviewSkills"],"sources":["../../../src/template/review-dashboard-skills/index.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport ReviewPresentation from '../../atom/review-presentation';\nimport ReviewSkills from '../app-review/skills';\nimport style from './style.css';\n\nconst ReviewDashboardSkills = props => {\n const {'aria-label': ariaLabel, reviewPresentation, reviewSkills} = props;\n\n return (\n <div className={style.reviewDashboardContainer} aria-label={ariaLabel}>\n <div className={style.reviewPresentationContainer}>\n <ReviewPresentation {...reviewPresentation} />\n </div>\n <div className={style.reviewSkillsContainer}>\n <ReviewSkills {...reviewSkills} />\n </div>\n </div>\n );\n};\n\nReviewDashboardSkills.propTypes = {\n 'aria-label': PropTypes.string,\n reviewPresentation: PropTypes.shape(ReviewPresentation.propTypes),\n reviewSkills: PropTypes.shape(ReviewSkills.propTypes)\n};\nexport default ReviewDashboardSkills;\n"],"mappings":";;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;;;AAEA,MAAMA,qBAAqB,GAAGC,KAAK,IAAI;EACrC,MAAM;IAAC,cAAcC,SAAf;IAA0BC,kBAA1B;IAA8CC;EAA9C,IAA8DH,KAApE;EAEA,oBACE;IAAK,SAAS,EAAEI,cAAA,CAAMC,wBAAtB;IAAgD,cAAYJ;EAA5D,gBACE;IAAK,SAAS,EAAEG,cAAA,CAAME;EAAtB,gBACE,6BAAC,2BAAD,EAAwBJ,kBAAxB,CADF,CADF,eAIE;IAAK,SAAS,EAAEE,cAAA,CAAMG;EAAtB,gBACE,6BAAC,eAAD,EAAkBJ,YAAlB,CADF,CAJF,CADF;AAUD,CAbD;;AAeAJ,qBAAqB,CAACS,SAAtB,2CAAkC;EAChC,cAAcC,kBAAA,CAAUC,MADQ;EAEhCR,kBAAkB,EAAEO,kBAAA,CAAUE,KAAV,CAAgBC,2BAAA,CAAmBJ,SAAnC,CAFY;EAGhCL,YAAY,EAAEM,kBAAA,CAAUE,KAAV,CAAgBE,eAAA,CAAaL,SAA7B;AAHkB,CAAlC;eAKeT,qB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@coorpacademy/components",
|
|
3
|
-
"version": "10.28.
|
|
3
|
+
"version": "10.28.3-alpha.3+f2bb79b3c",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "es/index.js",
|
|
@@ -157,5 +157,5 @@
|
|
|
157
157
|
"last 2 versions",
|
|
158
158
|
"IE 11"
|
|
159
159
|
],
|
|
160
|
-
"gitHead": "
|
|
160
|
+
"gitHead": "f2bb79b3cbf9c8299df8a8dde9d05b0ca98cc199"
|
|
161
161
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=stories.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"stories.d.ts","sourceRoot":"","sources":["../../../../src/template/app-review/skills/stories.tsx"],"names":[],"mappings":""}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
// import * as React from 'react';
|
|
2
|
-
// import {storiesOf} from '@storybook/react-native';
|
|
3
|
-
// import RevisionHome from './revision-home';
|
|
4
|
-
// const emptySkills: [] = [];
|
|
5
|
-
// const skillsToRevise: {title: string; info: string}[] = [
|
|
6
|
-
// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},
|
|
7
|
-
// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},
|
|
8
|
-
// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},
|
|
9
|
-
// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},
|
|
10
|
-
// {title: 'Creativity and innovation', info: '75 questions to revise'}
|
|
11
|
-
// ];
|
|
12
|
-
// storiesOf('RevisionHome', module)
|
|
13
|
-
// .add('No skills', () => <RevisionHome skillsToRevise={emptySkills} />)
|
|
14
|
-
// .add('Few skills', () => <RevisionHome skillsToRevise={skillsToRevise} />);
|
|
15
|
-
//# sourceMappingURL=stories.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"stories.js","names":[],"sources":["../../../../src/template/app-review/skills/stories.tsx"],"sourcesContent":["// import * as React from 'react';\n// import {storiesOf} from '@storybook/react-native';\n// import RevisionHome from './revision-home';\n\n// const emptySkills: [] = [];\n// const skillsToRevise: {title: string; info: string}[] = [\n// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},\n// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},\n// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},\n// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},\n// {title: 'Creativity and innovation', info: '75 questions to revise'}\n// ];\n\n// storiesOf('RevisionHome', module)\n// .add('No skills', () => <RevisionHome skillsToRevise={emptySkills} />)\n// .add('Few skills', () => <RevisionHome skillsToRevise={skillsToRevise} />);\n"],"mappings":"AAAA;AACA;AACA;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAEA;AACA;AACA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=stories.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"stories.d.ts","sourceRoot":"","sources":["../../../../src/template/app-review/skills/stories.tsx"],"names":[],"mappings":""}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
// import * as React from 'react';
|
|
2
|
-
// import {storiesOf} from '@storybook/react-native';
|
|
3
|
-
// import RevisionHome from './revision-home';
|
|
4
|
-
// const emptySkills: [] = [];
|
|
5
|
-
// const skillsToRevise: {title: string; info: string}[] = [
|
|
6
|
-
// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},
|
|
7
|
-
// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},
|
|
8
|
-
// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},
|
|
9
|
-
// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},
|
|
10
|
-
// {title: 'Creativity and innovation', info: '75 questions to revise'}
|
|
11
|
-
// ];
|
|
12
|
-
// storiesOf('RevisionHome', module)
|
|
13
|
-
// .add('No skills', () => <RevisionHome skillsToRevise={emptySkills} />)
|
|
14
|
-
// .add('Few skills', () => <RevisionHome skillsToRevise={skillsToRevise} />);
|
|
15
|
-
"use strict";
|
|
16
|
-
//# sourceMappingURL=stories.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"stories.js","names":[],"sources":["../../../../src/template/app-review/skills/stories.tsx"],"sourcesContent":["// import * as React from 'react';\n// import {storiesOf} from '@storybook/react-native';\n// import RevisionHome from './revision-home';\n\n// const emptySkills: [] = [];\n// const skillsToRevise: {title: string; info: string}[] = [\n// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},\n// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},\n// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},\n// {title: 'Negotiation and powers of persuasion', info: '75 questions to revise'},\n// {title: 'Creativity and innovation', info: '75 questions to revise'}\n// ];\n\n// storiesOf('RevisionHome', module)\n// .add('No skills', () => <RevisionHome skillsToRevise={emptySkills} />)\n// .add('Few skills', () => <RevisionHome skillsToRevise={skillsToRevise} />);\n"],"mappings":"AAAA;AACA;AACA;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAEA;AACA;AACA"}
|