@carto/api-client 0.4.1 → 0.4.2
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
|
@@ -4,9 +4,13 @@
|
|
|
4
4
|
|
|
5
5
|
## 0.4
|
|
6
6
|
|
|
7
|
+
### 0.4.2
|
|
8
|
+
|
|
9
|
+
- fix: Fix incorrect column name lowercasing in Picking Model API
|
|
10
|
+
|
|
7
11
|
### 0.4.1
|
|
8
12
|
|
|
9
|
-
-
|
|
13
|
+
- feat: Add cache control mechanism for sources and query APIs
|
|
10
14
|
|
|
11
15
|
### 0.4.0
|
|
12
16
|
|
package/build/api-client.cjs
CHANGED
|
@@ -669,9 +669,15 @@ class WidgetBaseSource {
|
|
|
669
669
|
opts: {
|
|
670
670
|
abortController
|
|
671
671
|
}
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
672
|
+
// Avoid `normalizeObjectKeys()`, which changes column names.
|
|
673
|
+
}).then(_ref => {
|
|
674
|
+
let {
|
|
675
|
+
rows
|
|
676
|
+
} = _ref;
|
|
677
|
+
return {
|
|
678
|
+
rows
|
|
679
|
+
};
|
|
680
|
+
}));
|
|
675
681
|
} catch (e) {
|
|
676
682
|
return Promise.reject(e);
|
|
677
683
|
}
|
|
@@ -756,11 +762,11 @@ class WidgetBaseSource {
|
|
|
756
762
|
// Given N ticks the API returns up to N+1 bins, omitting any empty bins. Bins
|
|
757
763
|
// include 1 bin below the lowest tick, N-1 between ticks, and 1 bin above the highest tick.
|
|
758
764
|
const result = Array(ticks.length + 1).fill(0);
|
|
759
|
-
data.forEach(
|
|
765
|
+
data.forEach(_ref2 => {
|
|
760
766
|
let {
|
|
761
767
|
tick,
|
|
762
768
|
value
|
|
763
|
-
} =
|
|
769
|
+
} = _ref2;
|
|
764
770
|
return result[tick] = value;
|
|
765
771
|
});
|
|
766
772
|
return result;
|
|
@@ -848,11 +854,11 @@ class WidgetBaseSource {
|
|
|
848
854
|
opts: {
|
|
849
855
|
abortController
|
|
850
856
|
}
|
|
851
|
-
}).then(res => normalizeObjectKeys(res.rows)).then(res => res.map(
|
|
857
|
+
}).then(res => normalizeObjectKeys(res.rows)).then(res => res.map(_ref3 => {
|
|
852
858
|
let {
|
|
853
859
|
x,
|
|
854
860
|
y
|
|
855
|
-
} =
|
|
861
|
+
} = _ref3;
|
|
856
862
|
return [x, y];
|
|
857
863
|
})));
|
|
858
864
|
} catch (e) {
|