@automattic/charts 1.3.0 → 1.3.1
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 +5 -0
- package/dist/index.cjs +32 -36
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +32 -36
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [1.3.1] - 2026-05-11
|
|
9
|
+
### Changed
|
|
10
|
+
- Update dependencies. [#43811]
|
|
11
|
+
|
|
8
12
|
## [1.3.0] - 2026-05-04
|
|
9
13
|
### Added
|
|
10
14
|
- Charts: Add AreaChart component for stacked and overlapping area visualisations. [#48388]
|
|
@@ -816,6 +820,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
816
820
|
- Fixed lints following ESLint rule changes for TS [#40584]
|
|
817
821
|
- Fixing a bug in Chart storybook data. [#40640]
|
|
818
822
|
|
|
823
|
+
[1.3.1]: https://github.com/Automattic/charts/compare/v1.3.0...v1.3.1
|
|
819
824
|
[1.3.0]: https://github.com/Automattic/charts/compare/v1.2.1...v1.3.0
|
|
820
825
|
[1.2.1]: https://github.com/Automattic/charts/compare/v1.2.0...v1.2.1
|
|
821
826
|
[1.2.0]: https://github.com/Automattic/charts/compare/v1.1.1...v1.2.0
|
package/dist/index.cjs
CHANGED
|
@@ -1728,7 +1728,7 @@ function paramCase(input, options) {
|
|
|
1728
1728
|
return dotCase(input, _tslib.__assign.call(void 0, { delimiter: "-" }, options));
|
|
1729
1729
|
}
|
|
1730
1730
|
|
|
1731
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
1731
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.8_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/useRefWithInit.js
|
|
1732
1732
|
|
|
1733
1733
|
var UNINITIALIZED = {};
|
|
1734
1734
|
function useRefWithInit(init, initArg) {
|
|
@@ -1739,7 +1739,7 @@ function useRefWithInit(init, initArg) {
|
|
|
1739
1739
|
return ref;
|
|
1740
1740
|
}
|
|
1741
1741
|
|
|
1742
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
1742
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.8_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/warn.js
|
|
1743
1743
|
var set;
|
|
1744
1744
|
if (process.env.NODE_ENV !== "production") {
|
|
1745
1745
|
set = /* @__PURE__ */ new Set();
|
|
@@ -1754,7 +1754,7 @@ function warn(...messages) {
|
|
|
1754
1754
|
}
|
|
1755
1755
|
}
|
|
1756
1756
|
|
|
1757
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
1757
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.8_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/formatErrorMessage.js
|
|
1758
1758
|
function createFormatErrorMessage(baseUrl, prefix2) {
|
|
1759
1759
|
return function formatErrorMessage2(code, ...args) {
|
|
1760
1760
|
const url = new URL(baseUrl);
|
|
@@ -1766,10 +1766,10 @@ function createFormatErrorMessage(baseUrl, prefix2) {
|
|
|
1766
1766
|
var formatErrorMessage = createFormatErrorMessage("https://base-ui.com/production-error", "Base UI");
|
|
1767
1767
|
var formatErrorMessage_default = formatErrorMessage;
|
|
1768
1768
|
|
|
1769
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.4.
|
|
1769
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.4.1_@date-fns+tz@1.4.1_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/internals/useRenderElement.js
|
|
1770
1770
|
|
|
1771
1771
|
|
|
1772
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
1772
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.8_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/useMergedRefs.js
|
|
1773
1773
|
function useMergedRefs(a, b, c, d) {
|
|
1774
1774
|
const forkRef = useRefWithInit(createForkRef).current;
|
|
1775
1775
|
if (didChange(forkRef, a, b, c, d)) {
|
|
@@ -1858,17 +1858,17 @@ function update(forkRef, refs) {
|
|
|
1858
1858
|
};
|
|
1859
1859
|
}
|
|
1860
1860
|
|
|
1861
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
1861
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.8_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/getReactElementRef.js
|
|
1862
1862
|
|
|
1863
1863
|
|
|
1864
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
1864
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.8_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/reactVersion.js
|
|
1865
1865
|
|
|
1866
1866
|
var majorVersion = parseInt(React2.version, 10);
|
|
1867
1867
|
function isReactVersionAtLeast(reactVersionToCheck) {
|
|
1868
1868
|
return majorVersion >= reactVersionToCheck;
|
|
1869
1869
|
}
|
|
1870
1870
|
|
|
1871
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
1871
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.8_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/getReactElementRef.js
|
|
1872
1872
|
function getReactElementRef(element) {
|
|
1873
1873
|
if (!/* @__PURE__ */ React3.isValidElement(element)) {
|
|
1874
1874
|
return null;
|
|
@@ -1878,7 +1878,7 @@ function getReactElementRef(element) {
|
|
|
1878
1878
|
return _nullishCoalesce((isReactVersionAtLeast(19) ? _optionalChain([propsWithRef, 'optionalAccess', _60 => _60.ref]) : reactElement.ref), () => ( null));
|
|
1879
1879
|
}
|
|
1880
1880
|
|
|
1881
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
1881
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.8_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/mergeObjects.js
|
|
1882
1882
|
function mergeObjects(a, b) {
|
|
1883
1883
|
if (a && !b) {
|
|
1884
1884
|
return a;
|
|
@@ -1895,7 +1895,11 @@ function mergeObjects(a, b) {
|
|
|
1895
1895
|
return void 0;
|
|
1896
1896
|
}
|
|
1897
1897
|
|
|
1898
|
-
// ../../../node_modules/.pnpm/@base-ui+
|
|
1898
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.8_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/empty.js
|
|
1899
|
+
var EMPTY_ARRAY = Object.freeze([]);
|
|
1900
|
+
var EMPTY_OBJECT = Object.freeze({});
|
|
1901
|
+
|
|
1902
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.4.1_@date-fns+tz@1.4.1_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/internals/getStateAttributesProps.js
|
|
1899
1903
|
function getStateAttributesProps(state, customMapping) {
|
|
1900
1904
|
const props = {};
|
|
1901
1905
|
for (const key in state) {
|
|
@@ -1916,17 +1920,17 @@ function getStateAttributesProps(state, customMapping) {
|
|
|
1916
1920
|
return props;
|
|
1917
1921
|
}
|
|
1918
1922
|
|
|
1919
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.4.
|
|
1923
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.4.1_@date-fns+tz@1.4.1_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/utils/resolveClassName.js
|
|
1920
1924
|
function resolveClassName(className, state) {
|
|
1921
1925
|
return typeof className === "function" ? className(state) : className;
|
|
1922
1926
|
}
|
|
1923
1927
|
|
|
1924
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.4.
|
|
1928
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.4.1_@date-fns+tz@1.4.1_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/utils/resolveStyle.js
|
|
1925
1929
|
function resolveStyle(style, state) {
|
|
1926
1930
|
return typeof style === "function" ? style(state) : style;
|
|
1927
1931
|
}
|
|
1928
1932
|
|
|
1929
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.4.
|
|
1933
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.4.1_@date-fns+tz@1.4.1_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/merge-props/mergeProps.js
|
|
1930
1934
|
var EMPTY_PROPS = {};
|
|
1931
1935
|
function mergeProps(a, b, c, d, e) {
|
|
1932
1936
|
if (!c && !d && !e && !a) {
|
|
@@ -2034,18 +2038,19 @@ function mergeEventHandlers(ourHandler, theirHandler) {
|
|
|
2034
2038
|
if (!ourHandler) {
|
|
2035
2039
|
return wrapEventHandler(theirHandler);
|
|
2036
2040
|
}
|
|
2037
|
-
return (
|
|
2041
|
+
return (...args) => {
|
|
2042
|
+
const event = args[0];
|
|
2038
2043
|
if (isSyntheticEvent(event)) {
|
|
2039
2044
|
const baseUIEvent = event;
|
|
2040
2045
|
makeEventPreventable(baseUIEvent);
|
|
2041
|
-
const result2 = theirHandler(
|
|
2046
|
+
const result2 = theirHandler(...args);
|
|
2042
2047
|
if (!baseUIEvent.baseUIHandlerPrevented) {
|
|
2043
|
-
_optionalChain([ourHandler, 'optionalCall', _63 => _63(
|
|
2048
|
+
_optionalChain([ourHandler, 'optionalCall', _63 => _63(...args)]);
|
|
2044
2049
|
}
|
|
2045
2050
|
return result2;
|
|
2046
2051
|
}
|
|
2047
|
-
const result = theirHandler(
|
|
2048
|
-
_optionalChain([ourHandler, 'optionalCall', _64 => _64(
|
|
2052
|
+
const result = theirHandler(...args);
|
|
2053
|
+
_optionalChain([ourHandler, 'optionalCall', _64 => _64(...args)]);
|
|
2049
2054
|
return result;
|
|
2050
2055
|
};
|
|
2051
2056
|
}
|
|
@@ -2053,11 +2058,12 @@ function wrapEventHandler(handler) {
|
|
|
2053
2058
|
if (!handler) {
|
|
2054
2059
|
return handler;
|
|
2055
2060
|
}
|
|
2056
|
-
return (
|
|
2061
|
+
return (...args) => {
|
|
2062
|
+
const event = args[0];
|
|
2057
2063
|
if (isSyntheticEvent(event)) {
|
|
2058
2064
|
makeEventPreventable(event);
|
|
2059
2065
|
}
|
|
2060
|
-
return handler(
|
|
2066
|
+
return handler(...args);
|
|
2061
2067
|
};
|
|
2062
2068
|
}
|
|
2063
2069
|
function makeEventPreventable(event) {
|
|
@@ -2079,17 +2085,7 @@ function isSyntheticEvent(event) {
|
|
|
2079
2085
|
return event != null && typeof event === "object" && "nativeEvent" in event;
|
|
2080
2086
|
}
|
|
2081
2087
|
|
|
2082
|
-
// ../../../node_modules/.pnpm/@base-ui+
|
|
2083
|
-
var EMPTY_ARRAY = Object.freeze([]);
|
|
2084
|
-
var EMPTY_OBJECT = Object.freeze({});
|
|
2085
|
-
|
|
2086
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.4.0_@date-fns+tz@1.4.1_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/utils/constants.js
|
|
2087
|
-
var BASE_UI_SWIPE_IGNORE_ATTRIBUTE = "data-base-ui-swipe-ignore";
|
|
2088
|
-
var LEGACY_SWIPE_IGNORE_ATTRIBUTE = "data-swipe-ignore";
|
|
2089
|
-
var BASE_UI_SWIPE_IGNORE_SELECTOR = `[${BASE_UI_SWIPE_IGNORE_ATTRIBUTE}]`;
|
|
2090
|
-
var LEGACY_SWIPE_IGNORE_SELECTOR = `[${LEGACY_SWIPE_IGNORE_ATTRIBUTE}]`;
|
|
2091
|
-
|
|
2092
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.4.0_@date-fns+tz@1.4.1_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/utils/useRenderElement.js
|
|
2088
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.4.1_@date-fns+tz@1.4.1_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/internals/useRenderElement.js
|
|
2093
2089
|
|
|
2094
2090
|
function useRenderElement(element, componentProps, params = {}) {
|
|
2095
2091
|
const renderProp = componentProps.render;
|
|
@@ -2207,12 +2203,12 @@ function renderTag(Tag, props) {
|
|
|
2207
2203
|
return /* @__PURE__ */ React4.createElement(Tag, props);
|
|
2208
2204
|
}
|
|
2209
2205
|
|
|
2210
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.4.
|
|
2206
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.4.1_@date-fns+tz@1.4.1_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/use-render/useRender.js
|
|
2211
2207
|
function useRender(params) {
|
|
2212
2208
|
return useRenderElement(_nullishCoalesce(params.defaultTagName, () => ( "div")), params, params);
|
|
2213
2209
|
}
|
|
2214
2210
|
|
|
2215
|
-
// ../../../node_modules/.pnpm/@wordpress+ui@0.11.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.
|
|
2211
|
+
// ../../../node_modules/.pnpm/@wordpress+ui@0.11.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/ui/build-module/text/text.mjs
|
|
2216
2212
|
|
|
2217
2213
|
if (typeof document !== "undefined" && process.env.NODE_ENV !== "test" && !document.head.querySelector("style[data-wp-hash='4130d64bea']")) {
|
|
2218
2214
|
const style = document.createElement("style");
|
|
@@ -2246,7 +2242,7 @@ var Text = _react.forwardRef.call(void 0, function Text2({ variant = "body-md",
|
|
|
2246
2242
|
return element;
|
|
2247
2243
|
});
|
|
2248
2244
|
|
|
2249
|
-
// ../../../node_modules/.pnpm/@wordpress+ui@0.11.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.
|
|
2245
|
+
// ../../../node_modules/.pnpm/@wordpress+ui@0.11.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/ui/build-module/stack/stack.mjs
|
|
2250
2246
|
if (typeof document !== "undefined" && process.env.NODE_ENV !== "test" && !document.head.querySelector("style[data-wp-hash='b51ff41489']")) {
|
|
2251
2247
|
const style = document.createElement("style");
|
|
2252
2248
|
style.setAttribute("data-wp-hash", "b51ff41489");
|
|
@@ -7617,10 +7613,10 @@ var config_values_default = Object.assign({}, CONTROL_PROPS, {
|
|
|
7617
7613
|
var import_es6 = _chunkDZUJEN5Ncjs.__toESM.call(void 0, require_es6(), 1);
|
|
7618
7614
|
|
|
7619
7615
|
|
|
7620
|
-
// ../../../node_modules/.pnpm/@wordpress+warning@3.
|
|
7616
|
+
// ../../../node_modules/.pnpm/@wordpress+warning@3.45.0/node_modules/@wordpress/warning/build-module/utils.mjs
|
|
7621
7617
|
var logged = /* @__PURE__ */ new Set();
|
|
7622
7618
|
|
|
7623
|
-
// ../../../node_modules/.pnpm/@wordpress+warning@3.
|
|
7619
|
+
// ../../../node_modules/.pnpm/@wordpress+warning@3.45.0/node_modules/@wordpress/warning/build-module/index.mjs
|
|
7624
7620
|
function isDev() {
|
|
7625
7621
|
return globalThis.SCRIPT_DEBUG === true;
|
|
7626
7622
|
}
|