@becollective/utils 1.5.3 → 1.5.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/bundle.js +2 -2
- package/package.json +2 -2
- package/src/opportunity.js +3 -4
package/bundle.js
CHANGED
|
@@ -158,8 +158,8 @@ var _TYPE_MAP;
|
|
|
158
158
|
var _require$1 = require('@becollective/constants'),
|
|
159
159
|
opportunities = _require$1.opportunities;
|
|
160
160
|
|
|
161
|
-
var opportunityTypes = opportunities.
|
|
162
|
-
var TYPE_MAP = (_TYPE_MAP = {}, _defineProperty(_TYPE_MAP, opportunityTypes.
|
|
161
|
+
var opportunityTypes = opportunities.typesMapV2;
|
|
162
|
+
var TYPE_MAP = (_TYPE_MAP = {}, _defineProperty(_TYPE_MAP, opportunityTypes.shift, 'Shifts'), _defineProperty(_TYPE_MAP, opportunityTypes.flexible, 'Flexible'), _TYPE_MAP);
|
|
163
163
|
var readableOpportunityType = function readableOpportunityType(type) {
|
|
164
164
|
return TYPE_MAP[type] || null;
|
|
165
165
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@becollective/utils",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.5",
|
|
4
4
|
"description": "Common utilities",
|
|
5
5
|
"main": "bundle.js",
|
|
6
6
|
"scripts": {
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"rollup-plugin-node-resolve": "^3.4.0"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@becollective/constants": "^3.
|
|
22
|
+
"@becollective/constants": "^3.11.0",
|
|
23
23
|
"lodash": "^4.17.15",
|
|
24
24
|
"moment": "^2.24.0",
|
|
25
25
|
"moment-timezone": "^0.5.26"
|
package/src/opportunity.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
const { opportunities } = require('@becollective/constants');
|
|
2
|
-
const {
|
|
2
|
+
const { typesMapV2: opportunityTypes } = opportunities;
|
|
3
3
|
|
|
4
4
|
const TYPE_MAP = {
|
|
5
|
-
[opportunityTypes.
|
|
6
|
-
[opportunityTypes.
|
|
7
|
-
[opportunityTypes.ongoing]: 'Ongoing',
|
|
5
|
+
[opportunityTypes.shift]: 'Shifts',
|
|
6
|
+
[opportunityTypes.flexible]: 'Flexible',
|
|
8
7
|
};
|
|
9
8
|
|
|
10
9
|
export const readableOpportunityType = type => TYPE_MAP[type] || null;
|