@sis-cc/dotstatsuite-visions 7.22.5 → 7.22.6
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.
|
@@ -13,8 +13,8 @@ import { useTheme } from '@material-ui/core';
|
|
|
13
13
|
import { getIsRtl } from '../utils';
|
|
14
14
|
|
|
15
15
|
var getCounter = function getCounter(items, displayAccessor, tagAccessor) {
|
|
16
|
-
var count = R.pipe(R.filter(R.prop('isSelected')), R.length)(items);
|
|
17
|
-
var total = R.pipe(R.when(R.always(R.is(Function, displayAccessor)), R.filter(displayAccessor)), R.map(R.
|
|
16
|
+
var count = R.pipe(R.filter(R.prop('isSelected')), R.map(R.prop('id')), R.uniq, R.length)(items);
|
|
17
|
+
var total = R.pipe(R.when(R.always(R.is(Function, displayAccessor)), R.filter(displayAccessor)), R.map(R.prop('id')), R.uniq, R.length)(items);
|
|
18
18
|
if (R.is(Function, tagAccessor)) {
|
|
19
19
|
return tagAccessor(count, total);
|
|
20
20
|
}
|
|
@@ -41,8 +41,8 @@ function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj;
|
|
|
41
41
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
42
42
|
|
|
43
43
|
var getCounter = function getCounter(items, displayAccessor, tagAccessor) {
|
|
44
|
-
var count = R.pipe(R.filter(R.prop('isSelected')), R.length)(items);
|
|
45
|
-
var total = R.pipe(R.when(R.always(R.is(Function, displayAccessor)), R.filter(displayAccessor)), R.map(R.
|
|
44
|
+
var count = R.pipe(R.filter(R.prop('isSelected')), R.map(R.prop('id')), R.uniq, R.length)(items);
|
|
45
|
+
var total = R.pipe(R.when(R.always(R.is(Function, displayAccessor)), R.filter(displayAccessor)), R.map(R.prop('id')), R.uniq, R.length)(items);
|
|
46
46
|
if (R.is(Function, tagAccessor)) {
|
|
47
47
|
return tagAccessor(count, total);
|
|
48
48
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sis-cc/dotstatsuite-visions",
|
|
3
|
-
"version": "7.22.
|
|
3
|
+
"version": "7.22.6",
|
|
4
4
|
"description": "Library of visual components",
|
|
5
5
|
"author": "OECD",
|
|
6
6
|
"homepage": "https://visions-qa.siscc.org/#o",
|
|
@@ -56,11 +56,11 @@
|
|
|
56
56
|
"react": "16.x"
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|
|
59
|
+
"@babel/eslint-parser": "^7.5.4",
|
|
59
60
|
"@babel/plugin-syntax-dynamic-import": "^7.2.0",
|
|
60
61
|
"@sis-cc/dotstatsuite-sdmxjs": "*",
|
|
61
62
|
"@testing-library/jest-dom": "^5.1.1",
|
|
62
63
|
"@testing-library/react": "^9.4.1",
|
|
63
|
-
"babel-eslint": "^10.0.3",
|
|
64
64
|
"babel-jest": "^24.8.0",
|
|
65
65
|
"babel-preset-react-app": "^9.0.0",
|
|
66
66
|
"dox": "^0.9.0",
|
|
@@ -151,8 +151,14 @@
|
|
|
151
151
|
"plugin:react/recommended",
|
|
152
152
|
"plugin:jsx-a11y/recommended"
|
|
153
153
|
],
|
|
154
|
-
"parser": "babel-
|
|
154
|
+
"parser": "@babel/eslint-parser",
|
|
155
155
|
"parserOptions": {
|
|
156
|
+
"babelOptions": {
|
|
157
|
+
"presets": [
|
|
158
|
+
["babel-preset-react-app", false],
|
|
159
|
+
"babel-preset-react-app/test"
|
|
160
|
+
]
|
|
161
|
+
},
|
|
156
162
|
"ecmaFeatures": {
|
|
157
163
|
"experimentalObjectRestSpread": true,
|
|
158
164
|
"jsx": true
|
|
@@ -207,7 +213,7 @@
|
|
|
207
213
|
"trailingComma": "all",
|
|
208
214
|
"jsxBracketSameLine": false,
|
|
209
215
|
"bracketSpacing": true,
|
|
210
|
-
"parser": "
|
|
216
|
+
"parser": "babel",
|
|
211
217
|
"semi": true
|
|
212
218
|
}
|
|
213
219
|
}
|