@cubejs-client/react 0.28.45 → 0.28.52
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/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,14 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [0.28.52](https://github.com/cube-js/cube.js/compare/v0.28.51...v0.28.52) (2021-11-03)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @cubejs-client/react
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
6
14
|
## [0.28.45](https://github.com/cube-js/cube.js/compare/v0.28.44...v0.28.45) (2021-10-19)
|
|
7
15
|
|
|
8
16
|
**Note:** Version bump only for package @cubejs-client/react
|
|
@@ -10680,10 +10680,15 @@
|
|
|
10680
10680
|
return target;
|
|
10681
10681
|
}
|
|
10682
10682
|
|
|
10683
|
-
dayjs_min.
|
|
10684
|
-
|
|
10685
|
-
|
|
10686
|
-
|
|
10683
|
+
dayjs_min.extend(quarterOfYear); // When granularity is week, weekStart Value must be 1. However, since the client can change it globally (https://day.js.org/docs/en/i18n/changing-locale)
|
|
10684
|
+
// So the function below has been added.
|
|
10685
|
+
|
|
10686
|
+
var internalDayjs = function internalDayjs() {
|
|
10687
|
+
return dayjs_min.apply(void 0, arguments).locale(_objectSpread$2$1(_objectSpread$2$1({}, en), {}, {
|
|
10688
|
+
weekStart: 1
|
|
10689
|
+
}));
|
|
10690
|
+
};
|
|
10691
|
+
|
|
10687
10692
|
var TIME_SERIES = {
|
|
10688
10693
|
day: function day(range) {
|
|
10689
10694
|
return range.by('d').map(function (d) {
|
|
@@ -10759,8 +10764,8 @@
|
|
|
10759
10764
|
return {
|
|
10760
10765
|
by: function by(value) {
|
|
10761
10766
|
var results = [];
|
|
10762
|
-
var start =
|
|
10763
|
-
var end =
|
|
10767
|
+
var start = internalDayjs(from);
|
|
10768
|
+
var end = internalDayjs(to);
|
|
10764
10769
|
|
|
10765
10770
|
while (start.isBefore(end) || start.isSame(end)) {
|
|
10766
10771
|
results.push(start);
|
|
@@ -10770,10 +10775,10 @@
|
|
|
10770
10775
|
return results;
|
|
10771
10776
|
},
|
|
10772
10777
|
snapTo: function snapTo(value) {
|
|
10773
|
-
return dayRange(
|
|
10778
|
+
return dayRange(internalDayjs(from).startOf(value), internalDayjs(to).endOf(value));
|
|
10774
10779
|
},
|
|
10775
|
-
start:
|
|
10776
|
-
end:
|
|
10780
|
+
start: internalDayjs(from),
|
|
10781
|
+
end: internalDayjs(to)
|
|
10777
10782
|
};
|
|
10778
10783
|
};
|
|
10779
10784
|
|
|
@@ -11000,7 +11005,7 @@
|
|
|
11000
11005
|
if (!dateRange) {
|
|
11001
11006
|
var member = ResultSet.timeDimensionMember(timeDimension);
|
|
11002
11007
|
var dates = pipe(map(function (row) {
|
|
11003
|
-
return row[member] &&
|
|
11008
|
+
return row[member] && internalDayjs(row[member]);
|
|
11004
11009
|
}), filter(Boolean))(this.timeDimensionBackwardCompatibleData(resultIndex));
|
|
11005
11010
|
dateRange = dates.length && [reduce(minBy(function (d) {
|
|
11006
11011
|
return d.toDate();
|