victory-core 36.9.2-next.3 → 36.9.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 +22 -10
- package/README.md +1 -1
- package/dist/victory-core.js +124 -493
- package/dist/victory-core.min.js +1 -1
- package/es/index.d.ts +17 -17
- package/es/types/callbacks.d.ts +36 -36
- package/es/types/prop-types.d.ts +129 -129
- package/es/victory-accessible-group/victory-accessible-group.d.ts +10 -10
- package/es/victory-animation/util.d.ts +66 -66
- package/es/victory-animation/victory-animation.d.ts +34 -34
- package/es/victory-clip-container/victory-clip-container.d.ts +46 -46
- package/es/victory-container/victory-container.d.ts +68 -68
- package/es/victory-label/victory-label.d.ts +58 -58
- package/es/victory-portal/portal-context.d.ts +11 -11
- package/es/victory-portal/portal.d.ts +20 -20
- package/es/victory-portal/victory-portal.d.ts +26 -26
- package/es/victory-primitives/arc.d.ts +14 -14
- package/es/victory-primitives/background.d.ts +13 -13
- package/es/victory-primitives/border.d.ts +10 -10
- package/es/victory-primitives/circle.d.ts +3 -3
- package/es/victory-primitives/clip-path.d.ts +7 -7
- package/es/victory-primitives/index.d.ts +14 -14
- package/es/victory-primitives/line-segment.d.ts +11 -11
- package/es/victory-primitives/line.d.ts +3 -3
- package/es/victory-primitives/path.d.ts +3 -3
- package/es/victory-primitives/point.d.ts +13 -13
- package/es/victory-primitives/rect.d.ts +3 -3
- package/es/victory-primitives/text.d.ts +8 -8
- package/es/victory-primitives/tspan.d.ts +3 -3
- package/es/victory-primitives/types.d.ts +7 -7
- package/es/victory-primitives/whisker.d.ts +15 -15
- package/es/victory-theme/grayscale.d.ts +2 -2
- package/es/victory-theme/material.d.ts +2 -2
- package/es/victory-theme/types.d.ts +238 -238
- package/es/victory-theme/victory-theme.d.ts +5 -5
- package/es/victory-transition/victory-transition.d.ts +53 -53
- package/es/victory-util/add-events.d.ts +126 -126
- package/es/victory-util/add-events.js +4 -8
- package/es/victory-util/axis.d.ts +50 -50
- package/es/victory-util/axis.js +13 -6
- package/es/victory-util/collection.d.ts +15 -8
- package/es/victory-util/collection.js +16 -0
- package/es/victory-util/common-props.d.ts +79 -79
- package/es/victory-util/data.d.ts +74 -74
- package/es/victory-util/default-transitions.d.ts +4 -4
- package/es/victory-util/domain.d.ts +90 -90
- package/es/victory-util/events.d.ts +64 -64
- package/es/victory-util/helpers.d.ts +96 -91
- package/es/victory-util/helpers.js +12 -1
- package/es/victory-util/hooks/index.d.ts +2 -2
- package/es/victory-util/hooks/use-animation-state.d.ts +21 -21
- package/es/victory-util/hooks/use-previous-props.d.ts +1 -1
- package/es/victory-util/immutable.d.ts +11 -11
- package/es/victory-util/index.d.ts +26 -26
- package/es/victory-util/label-helpers.d.ts +26 -26
- package/es/victory-util/line-helpers.d.ts +4 -4
- package/es/victory-util/log.d.ts +1 -1
- package/es/victory-util/point-path-helpers.d.ts +9 -9
- package/es/victory-util/scale.d.ts +9 -9
- package/es/victory-util/selection.d.ts +28 -28
- package/es/victory-util/style.d.ts +18 -18
- package/es/victory-util/textsize.d.ts +35 -35
- package/es/victory-util/timer-context.d.ts +11 -11
- package/es/victory-util/timer.d.ts +16 -16
- package/es/victory-util/transitions.d.ts +48 -48
- package/es/victory-util/type-helpers.d.ts +9 -9
- package/es/victory-util/user-props.d.ts +26 -26
- package/es/victory-util/wrapper.d.ts +33 -37
- package/es/victory-util/wrapper.js +2 -2
- package/lib/index.d.ts +17 -17
- package/lib/types/callbacks.d.ts +36 -36
- package/lib/types/prop-types.d.ts +129 -129
- package/lib/victory-accessible-group/victory-accessible-group.d.ts +10 -10
- package/lib/victory-animation/util.d.ts +66 -66
- package/lib/victory-animation/victory-animation.d.ts +34 -34
- package/lib/victory-clip-container/victory-clip-container.d.ts +46 -46
- package/lib/victory-container/victory-container.d.ts +68 -68
- package/lib/victory-label/victory-label.d.ts +58 -58
- package/lib/victory-portal/portal-context.d.ts +11 -11
- package/lib/victory-portal/portal.d.ts +20 -20
- package/lib/victory-portal/victory-portal.d.ts +26 -26
- package/lib/victory-primitives/arc.d.ts +14 -14
- package/lib/victory-primitives/background.d.ts +13 -13
- package/lib/victory-primitives/border.d.ts +10 -10
- package/lib/victory-primitives/circle.d.ts +3 -3
- package/lib/victory-primitives/clip-path.d.ts +7 -7
- package/lib/victory-primitives/index.d.ts +14 -14
- package/lib/victory-primitives/line-segment.d.ts +11 -11
- package/lib/victory-primitives/line.d.ts +3 -3
- package/lib/victory-primitives/path.d.ts +3 -3
- package/lib/victory-primitives/point.d.ts +13 -13
- package/lib/victory-primitives/rect.d.ts +3 -3
- package/lib/victory-primitives/text.d.ts +8 -8
- package/lib/victory-primitives/tspan.d.ts +3 -3
- package/lib/victory-primitives/types.d.ts +7 -7
- package/lib/victory-primitives/whisker.d.ts +15 -15
- package/lib/victory-theme/grayscale.d.ts +2 -2
- package/lib/victory-theme/material.d.ts +2 -2
- package/lib/victory-theme/types.d.ts +238 -238
- package/lib/victory-theme/victory-theme.d.ts +5 -5
- package/lib/victory-transition/victory-transition.d.ts +53 -53
- package/lib/victory-util/add-events.d.ts +126 -126
- package/lib/victory-util/add-events.js +6 -6
- package/lib/victory-util/axis.d.ts +50 -50
- package/lib/victory-util/axis.js +13 -7
- package/lib/victory-util/collection.d.ts +15 -8
- package/lib/victory-util/collection.js +18 -0
- package/lib/victory-util/common-props.d.ts +79 -79
- package/lib/victory-util/data.d.ts +74 -74
- package/lib/victory-util/default-transitions.d.ts +4 -4
- package/lib/victory-util/domain.d.ts +90 -90
- package/lib/victory-util/events.d.ts +64 -64
- package/lib/victory-util/helpers.d.ts +96 -91
- package/lib/victory-util/helpers.js +13 -0
- package/lib/victory-util/hooks/index.d.ts +2 -2
- package/lib/victory-util/hooks/use-animation-state.d.ts +21 -21
- package/lib/victory-util/hooks/use-previous-props.d.ts +1 -1
- package/lib/victory-util/immutable.d.ts +11 -11
- package/lib/victory-util/index.d.ts +26 -26
- package/lib/victory-util/label-helpers.d.ts +26 -26
- package/lib/victory-util/line-helpers.d.ts +4 -4
- package/lib/victory-util/log.d.ts +1 -1
- package/lib/victory-util/point-path-helpers.d.ts +9 -9
- package/lib/victory-util/scale.d.ts +9 -9
- package/lib/victory-util/selection.d.ts +28 -28
- package/lib/victory-util/style.d.ts +18 -18
- package/lib/victory-util/textsize.d.ts +35 -35
- package/lib/victory-util/timer-context.d.ts +11 -11
- package/lib/victory-util/timer.d.ts +16 -16
- package/lib/victory-util/transitions.d.ts +48 -48
- package/lib/victory-util/type-helpers.d.ts +9 -9
- package/lib/victory-util/user-props.d.ts +26 -26
- package/lib/victory-util/wrapper.d.ts +33 -37
- package/lib/victory-util/wrapper.js +2 -2
- package/package.json +6 -3
- package/src/types/prop-types.ts +0 -7
- package/src/victory-container/victory-container.tsx +195 -171
- package/src/victory-portal/portal-context.ts +4 -5
- package/src/victory-portal/portal.tsx +42 -5
- package/src/victory-portal/victory-portal.tsx +71 -34
- package/src/victory-util/add-events.tsx +6 -4
- package/src/victory-util/axis.tsx +12 -3
- package/src/victory-util/collection.tsx +13 -0
- package/src/victory-util/helpers.ts +11 -0
- package/src/victory-util/index.ts +0 -1
- package/src/victory-util/wrapper.tsx +1 -0
- package/src/victory-util/merge-refs.ts +0 -13
|
@@ -1,92 +1,97 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { CallbackArgs } from "../types/callbacks";
|
|
3
|
-
import { ValueOrAccessor } from "../types/prop-types";
|
|
4
|
-
/**
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
export declare function
|
|
31
|
-
export declare function
|
|
32
|
-
export declare function
|
|
33
|
-
export declare function
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
export declare function
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
export declare function
|
|
43
|
-
/**
|
|
44
|
-
* Checks if `value` is
|
|
45
|
-
*
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
*
|
|
62
|
-
*
|
|
63
|
-
*/
|
|
64
|
-
export declare function
|
|
65
|
-
/**
|
|
66
|
-
* Creates an
|
|
67
|
-
*
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
*
|
|
72
|
-
*
|
|
73
|
-
*
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
* @param
|
|
78
|
-
* @
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
*
|
|
83
|
-
* @
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
*
|
|
88
|
-
* @returns {
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { CallbackArgs } from "../types/callbacks";
|
|
3
|
+
import { ValueOrAccessor } from "../types/prop-types";
|
|
4
|
+
/**
|
|
5
|
+
* Creates an object composed of the inverted keys and values of object.
|
|
6
|
+
* If object contains duplicate values, subsequent values overwrite property assignments of previous values.
|
|
7
|
+
*/
|
|
8
|
+
export declare function invert(original: Record<string, string | number>): {};
|
|
9
|
+
/**
|
|
10
|
+
* creates an object with some keys excluded
|
|
11
|
+
* replacement for lodash.omit for performance. does not mimic the entire lodash.omit api
|
|
12
|
+
* @param {Object} originalObject: created object will be based on this object
|
|
13
|
+
* @param {Array<String>} ks: an array of keys to omit from the new object
|
|
14
|
+
* @returns {Object} new object with same properties as originalObject
|
|
15
|
+
*/
|
|
16
|
+
export declare function omit<T, Keys extends keyof T>(originalObject: T, ks?: Array<Keys>): Omit<T, Keys>;
|
|
17
|
+
export declare function getPoint(datum: any): any;
|
|
18
|
+
export declare function scalePoint(props: any, datum: any): {
|
|
19
|
+
x: any;
|
|
20
|
+
x0: any;
|
|
21
|
+
y: any;
|
|
22
|
+
y0: any;
|
|
23
|
+
};
|
|
24
|
+
export declare function getPadding(props: any, name?: string): {
|
|
25
|
+
top: any;
|
|
26
|
+
bottom: any;
|
|
27
|
+
left: any;
|
|
28
|
+
right: any;
|
|
29
|
+
};
|
|
30
|
+
export declare function isTooltip(component: any): boolean;
|
|
31
|
+
export declare function getDefaultStyles(props: any, role: any): any;
|
|
32
|
+
export declare function getStyles(style: any, defaultStyles: any): any;
|
|
33
|
+
export declare function evaluateProp<TValue>(prop: ValueOrAccessor<TValue, CallbackArgs>, props: CallbackArgs): TValue;
|
|
34
|
+
export declare function evaluateStyle(style: any, props: any): any;
|
|
35
|
+
export declare function degreesToRadians(degrees: any): any;
|
|
36
|
+
export declare function radiansToDegrees(radians: any): any;
|
|
37
|
+
export declare function getRadius(props: any): number;
|
|
38
|
+
export declare function getPolarOrigin(props: any): {
|
|
39
|
+
x: number;
|
|
40
|
+
y: number;
|
|
41
|
+
};
|
|
42
|
+
export declare function getRange(props: any, axis: any): any;
|
|
43
|
+
/**
|
|
44
|
+
* Checks if `value` is `null` or `undefined`.
|
|
45
|
+
* @returns {boolean} Returns `true` if `value` is nullish, else `false`.
|
|
46
|
+
*/
|
|
47
|
+
export declare function isNil(value: any): boolean;
|
|
48
|
+
/**
|
|
49
|
+
* Checks if `value` is classified as a `Function` object.
|
|
50
|
+
*
|
|
51
|
+
* @since 0.1.0
|
|
52
|
+
* @param {*} value The value to check.
|
|
53
|
+
* @returns {boolean} Returns `true` if `value` is a function, else `false`.
|
|
54
|
+
*/
|
|
55
|
+
export declare function isFunction(value: any): value is (...args: any[]) => any;
|
|
56
|
+
export declare function createAccessor(key: any): (...args: any[]) => any;
|
|
57
|
+
export declare function modifyProps(props: any, fallbackProps?: any, role?: any): any;
|
|
58
|
+
/**
|
|
59
|
+
* Returns the given axis or the opposite axis when horizontal
|
|
60
|
+
* @param {string} axis: the given axis, either "x" pr "y"
|
|
61
|
+
* @param {Boolean} horizontal: true when the chart is flipped to the horizontal orientation
|
|
62
|
+
* @returns {String} the dimension appropriate for the axis given its props "x" or "y"
|
|
63
|
+
*/
|
|
64
|
+
export declare function getCurrentAxis(axis: any, horizontal: any): any;
|
|
65
|
+
/**
|
|
66
|
+
* Creates an object with the same keys as object and values generated by running
|
|
67
|
+
* each own enumerable string keyed property of object through the function fn
|
|
68
|
+
*/
|
|
69
|
+
export declare function mapValues<T>(values: T, fn: (value?: any) => any): T | undefined;
|
|
70
|
+
/**
|
|
71
|
+
* Creates an array of numbers (positive and/or negative) progressing
|
|
72
|
+
* from start up to, but not including, end.
|
|
73
|
+
* A step of -1 is used if a negative start is specified without an end or step.
|
|
74
|
+
* If end is not specified, it's set to start with start then set to 0.
|
|
75
|
+
*
|
|
76
|
+
* @param start The length of the array to create, or the start value
|
|
77
|
+
* @param end [The end value] If this is defined, start is the start value
|
|
78
|
+
* @returns An array of the given length
|
|
79
|
+
*/
|
|
80
|
+
export declare function range(start: number, end?: number, increment?: number): number[];
|
|
81
|
+
/**
|
|
82
|
+
* @param {Array} children: an array of child components
|
|
83
|
+
* @param {Function} iteratee: a function with arguments "child", "childName", and "parent"
|
|
84
|
+
* @param {Object} parentProps: props from the parent that are applied to children
|
|
85
|
+
* @param {any} initialMemo: The object in which the iteration results are combined.
|
|
86
|
+
* @param {Function} combine: Combines the result of the iteratee with the current memo
|
|
87
|
+
* to the memo for the next iteration step
|
|
88
|
+
* @returns {Array} returns an array of results from calling the iteratee on all nested children
|
|
89
|
+
*/
|
|
90
|
+
export declare function reduceChildren<TChildren extends React.ReactNode, TItem, TResult = TItem[]>(children: TChildren[], iteratee: (child: TChildren, childName: string, parent?: TChildren) => TItem | null, parentProps?: {}, initialMemo?: TResult, combine?: (memo: TResult, item: TItem) => TResult): TResult;
|
|
91
|
+
/**
|
|
92
|
+
* @param {Object} props: the props object
|
|
93
|
+
* @returns {Boolean} returns true if the props object contains `horizontal: true` of if any
|
|
94
|
+
* children or nested children are horizontal
|
|
95
|
+
*/
|
|
96
|
+
export declare function isHorizontal(props: any): any;
|
|
92
97
|
//# sourceMappingURL=helpers.d.ts.map
|
|
@@ -28,6 +28,18 @@ function getPolarRange(props, axis) {
|
|
|
28
28
|
return [props.innerRadius || 0, getRadius(props)];
|
|
29
29
|
} // Exported Functions
|
|
30
30
|
|
|
31
|
+
/**
|
|
32
|
+
* Creates an object composed of the inverted keys and values of object.
|
|
33
|
+
* If object contains duplicate values, subsequent values overwrite property assignments of previous values.
|
|
34
|
+
*/
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
export function invert(original) {
|
|
38
|
+
return Object.entries(original).reduce(function (acc, current) {
|
|
39
|
+
acc[current[1]] = current[0];
|
|
40
|
+
return acc;
|
|
41
|
+
}, {});
|
|
42
|
+
}
|
|
31
43
|
/**
|
|
32
44
|
* creates an object with some keys excluded
|
|
33
45
|
* replacement for lodash.omit for performance. does not mimic the entire lodash.omit api
|
|
@@ -36,7 +48,6 @@ function getPolarRange(props, axis) {
|
|
|
36
48
|
* @returns {Object} new object with same properties as originalObject
|
|
37
49
|
*/
|
|
38
50
|
|
|
39
|
-
|
|
40
51
|
export function omit(originalObject) {
|
|
41
52
|
var ks = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
42
53
|
// code based on babel's _objectWithoutProperties
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { usePreviousProps } from "./use-previous-props";
|
|
2
|
-
export { useAnimationState } from "./use-animation-state";
|
|
1
|
+
export { usePreviousProps } from "./use-previous-props";
|
|
2
|
+
export { useAnimationState } from "./use-animation-state";
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
declare type AnyObject = Record<string, any>;
|
|
2
|
-
export declare type AnimationState = {
|
|
3
|
-
nodesShouldLoad?: boolean;
|
|
4
|
-
nodesDoneLoad?: boolean;
|
|
5
|
-
animating?: boolean;
|
|
6
|
-
childrenTransitions?: any[];
|
|
7
|
-
nodesWillExit?: boolean;
|
|
8
|
-
nodesWillEnter?: boolean;
|
|
9
|
-
nodesShouldEnter?: boolean;
|
|
10
|
-
oldProps?: AnyObject;
|
|
11
|
-
nextProps?: AnyObject;
|
|
12
|
-
continuous?: boolean;
|
|
13
|
-
};
|
|
14
|
-
export declare const useAnimationState: (initialState?: AnimationState) => {
|
|
15
|
-
state: AnimationState;
|
|
16
|
-
setState: (newState: AnimationState) => void;
|
|
17
|
-
getAnimationProps: (props: AnyObject | undefined, child: any, index: any) => any;
|
|
18
|
-
setAnimationState: (props: AnyObject | undefined, nextProps: any) => void;
|
|
19
|
-
getProps: (initialProps: AnyObject) => AnyObject;
|
|
20
|
-
};
|
|
21
|
-
export {};
|
|
1
|
+
declare type AnyObject = Record<string, any>;
|
|
2
|
+
export declare type AnimationState = {
|
|
3
|
+
nodesShouldLoad?: boolean;
|
|
4
|
+
nodesDoneLoad?: boolean;
|
|
5
|
+
animating?: boolean;
|
|
6
|
+
childrenTransitions?: any[];
|
|
7
|
+
nodesWillExit?: boolean;
|
|
8
|
+
nodesWillEnter?: boolean;
|
|
9
|
+
nodesShouldEnter?: boolean;
|
|
10
|
+
oldProps?: AnyObject;
|
|
11
|
+
nextProps?: AnyObject;
|
|
12
|
+
continuous?: boolean;
|
|
13
|
+
};
|
|
14
|
+
export declare const useAnimationState: (initialState?: AnimationState) => {
|
|
15
|
+
state: AnimationState;
|
|
16
|
+
setState: (newState: AnimationState) => void;
|
|
17
|
+
getAnimationProps: (props: AnyObject | undefined, child: any, index: any) => any;
|
|
18
|
+
setAnimationState: (props: AnyObject | undefined, nextProps: any) => void;
|
|
19
|
+
getProps: (initialProps: AnyObject) => AnyObject;
|
|
20
|
+
};
|
|
21
|
+
export {};
|
|
22
22
|
//# sourceMappingURL=use-animation-state.d.ts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare function usePreviousProps<T>(props: T): T | undefined;
|
|
1
|
+
export declare function usePreviousProps<T>(props: T): T | undefined;
|
|
2
2
|
//# sourceMappingURL=use-previous-props.d.ts.map
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import type { Iterable, List, Map } from "./immutable-types";
|
|
2
|
-
export declare const IMMUTABLE_ITERABLE = "@@__IMMUTABLE_ITERABLE__@@";
|
|
3
|
-
export declare const IMMUTABLE_RECORD = "@@__IMMUTABLE_RECORD__@@";
|
|
4
|
-
export declare const IMMUTABLE_LIST = "@@__IMMUTABLE_LIST__@@";
|
|
5
|
-
export declare const IMMUTABLE_MAP = "@@__IMMUTABLE_MAP__@@";
|
|
6
|
-
export declare function isIterable(x: any): x is Iterable<unknown, unknown>;
|
|
7
|
-
export declare function isRecord(x: any): x is Record<string, unknown>;
|
|
8
|
-
export declare function isImmutable(x: any): x is Iterable<unknown, unknown> | Record<string, unknown>;
|
|
9
|
-
export declare function isList(x: any): x is List<unknown>;
|
|
10
|
-
export declare function isMap(x: any): x is Map<unknown, unknown>;
|
|
11
|
-
export declare function shallowToJS(x: any, whitelist?: Record<string, boolean | unknown>): any;
|
|
1
|
+
import type { Iterable, List, Map } from "./immutable-types";
|
|
2
|
+
export declare const IMMUTABLE_ITERABLE = "@@__IMMUTABLE_ITERABLE__@@";
|
|
3
|
+
export declare const IMMUTABLE_RECORD = "@@__IMMUTABLE_RECORD__@@";
|
|
4
|
+
export declare const IMMUTABLE_LIST = "@@__IMMUTABLE_LIST__@@";
|
|
5
|
+
export declare const IMMUTABLE_MAP = "@@__IMMUTABLE_MAP__@@";
|
|
6
|
+
export declare function isIterable(x: any): x is Iterable<unknown, unknown>;
|
|
7
|
+
export declare function isRecord(x: any): x is Record<string, unknown>;
|
|
8
|
+
export declare function isImmutable(x: any): x is Iterable<unknown, unknown> | Record<string, unknown>;
|
|
9
|
+
export declare function isList(x: any): x is List<unknown>;
|
|
10
|
+
export declare function isMap(x: any): x is Map<unknown, unknown>;
|
|
11
|
+
export declare function shallowToJS(x: any, whitelist?: Record<string, boolean | unknown>): any;
|
|
12
12
|
//# sourceMappingURL=immutable.d.ts.map
|
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
export * from "./add-events";
|
|
2
|
-
export * as Axis from "./axis";
|
|
3
|
-
export * as Collection from "./collection";
|
|
4
|
-
export * from "./common-props";
|
|
5
|
-
export * as Data from "./data";
|
|
6
|
-
export * as DefaultTransitions from "./default-transitions";
|
|
7
|
-
export * as Domain from "./domain";
|
|
8
|
-
export * as Events from "./events";
|
|
9
|
-
export * as Helpers from "./helpers";
|
|
10
|
-
export * as Hooks from "./hooks";
|
|
11
|
-
export * as Immutable from "./immutable";
|
|
12
|
-
export * as LabelHelpers from "./label-helpers";
|
|
13
|
-
export * as LineHelpers from "./line-helpers";
|
|
14
|
-
export * as Log from "./log";
|
|
15
|
-
export * as PointPathHelpers from "./point-path-helpers";
|
|
16
|
-
export * as Scale from "./scale";
|
|
17
|
-
export * as Selection from "./selection";
|
|
18
|
-
export type { SVGCoordinateType, SVGCoordinateBounds } from "./selection";
|
|
19
|
-
export * as Style from "./style";
|
|
20
|
-
export * as TextSize from "./textsize";
|
|
21
|
-
export type { TextSizeStyleInterface } from "./textsize";
|
|
22
|
-
export { default as Timer } from "./timer";
|
|
23
|
-
export { default as TimerContext } from "./timer-context";
|
|
24
|
-
export * as Transitions from "./transitions";
|
|
25
|
-
export * as UserProps from "./user-props";
|
|
26
|
-
export * as Wrapper from "./wrapper";
|
|
1
|
+
export * from "./add-events";
|
|
2
|
+
export * as Axis from "./axis";
|
|
3
|
+
export * as Collection from "./collection";
|
|
4
|
+
export * from "./common-props";
|
|
5
|
+
export * as Data from "./data";
|
|
6
|
+
export * as DefaultTransitions from "./default-transitions";
|
|
7
|
+
export * as Domain from "./domain";
|
|
8
|
+
export * as Events from "./events";
|
|
9
|
+
export * as Helpers from "./helpers";
|
|
10
|
+
export * as Hooks from "./hooks";
|
|
11
|
+
export * as Immutable from "./immutable";
|
|
12
|
+
export * as LabelHelpers from "./label-helpers";
|
|
13
|
+
export * as LineHelpers from "./line-helpers";
|
|
14
|
+
export * as Log from "./log";
|
|
15
|
+
export * as PointPathHelpers from "./point-path-helpers";
|
|
16
|
+
export * as Scale from "./scale";
|
|
17
|
+
export * as Selection from "./selection";
|
|
18
|
+
export type { SVGCoordinateType, SVGCoordinateBounds } from "./selection";
|
|
19
|
+
export * as Style from "./style";
|
|
20
|
+
export * as TextSize from "./textsize";
|
|
21
|
+
export type { TextSizeStyleInterface } from "./textsize";
|
|
22
|
+
export { default as Timer } from "./timer";
|
|
23
|
+
export { default as TimerContext } from "./timer-context";
|
|
24
|
+
export * as Transitions from "./transitions";
|
|
25
|
+
export * as UserProps from "./user-props";
|
|
26
|
+
export * as Wrapper from "./wrapper";
|
|
27
27
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
export declare function getText(props: any, datum: Record<string, any> | undefined, index: any): any;
|
|
2
|
-
export declare function getPolarTextAnchor(props: any, degrees: any): "end" | "start" | "middle";
|
|
3
|
-
export declare function getPolarVerticalAnchor(props: any, degrees: any): "end" | "start" | "middle";
|
|
4
|
-
export declare function getPolarAngle(props: any, baseAngle?: any): number;
|
|
5
|
-
export declare function getDegrees(props: any, datum: any): number;
|
|
6
|
-
export declare function getProps(props: any, index: any): {
|
|
7
|
-
angle: any;
|
|
8
|
-
data: any;
|
|
9
|
-
datum: any;
|
|
10
|
-
disableInlineStyles: any;
|
|
11
|
-
horizontal: any;
|
|
12
|
-
index: any;
|
|
13
|
-
polar: any;
|
|
14
|
-
scale: any;
|
|
15
|
-
labelPlacement: any;
|
|
16
|
-
text: any;
|
|
17
|
-
textAnchor: any;
|
|
18
|
-
verticalAnchor: any;
|
|
19
|
-
x: any;
|
|
20
|
-
y: any;
|
|
21
|
-
dx: number | undefined;
|
|
22
|
-
dy: number | undefined;
|
|
23
|
-
width: any;
|
|
24
|
-
height: any;
|
|
25
|
-
style: any;
|
|
26
|
-
};
|
|
1
|
+
export declare function getText(props: any, datum: Record<string, any> | undefined, index: any): any;
|
|
2
|
+
export declare function getPolarTextAnchor(props: any, degrees: any): "end" | "start" | "middle";
|
|
3
|
+
export declare function getPolarVerticalAnchor(props: any, degrees: any): "end" | "start" | "middle";
|
|
4
|
+
export declare function getPolarAngle(props: any, baseAngle?: any): number;
|
|
5
|
+
export declare function getDegrees(props: any, datum: any): number;
|
|
6
|
+
export declare function getProps(props: any, index: any): {
|
|
7
|
+
angle: any;
|
|
8
|
+
data: any;
|
|
9
|
+
datum: any;
|
|
10
|
+
disableInlineStyles: any;
|
|
11
|
+
horizontal: any;
|
|
12
|
+
index: any;
|
|
13
|
+
polar: any;
|
|
14
|
+
scale: any;
|
|
15
|
+
labelPlacement: any;
|
|
16
|
+
text: any;
|
|
17
|
+
textAnchor: any;
|
|
18
|
+
verticalAnchor: any;
|
|
19
|
+
x: any;
|
|
20
|
+
y: any;
|
|
21
|
+
dx: number | undefined;
|
|
22
|
+
dy: number | undefined;
|
|
23
|
+
width: any;
|
|
24
|
+
height: any;
|
|
25
|
+
style: any;
|
|
26
|
+
};
|
|
27
27
|
//# sourceMappingURL=label-helpers.d.ts.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as d3Shape from "victory-vendor/d3-shape";
|
|
2
|
-
export declare type CurveName = "basis" | "cardinal" | "bumpX" | "bumpY" | "bundle" | "catmullRom" | "linear" | "monotoneX" | "monotoneY" | "step" | "stepAfter" | "stepBefore" | "natural";
|
|
3
|
-
export declare const getInterpolationFunction: (props: any) => any;
|
|
4
|
-
export declare const getLineFunction: (props: any) => d3Shape.LineRadial<[number, number]> | d3Shape.Line<[number, number]>;
|
|
1
|
+
import * as d3Shape from "victory-vendor/d3-shape";
|
|
2
|
+
export declare type CurveName = "basis" | "cardinal" | "bumpX" | "bumpY" | "bundle" | "catmullRom" | "linear" | "monotoneX" | "monotoneY" | "step" | "stepAfter" | "stepBefore" | "natural";
|
|
3
|
+
export declare const getInterpolationFunction: (props: any) => any;
|
|
4
|
+
export declare const getLineFunction: (props: any) => d3Shape.LineRadial<[number, number]> | d3Shape.Line<[number, number]>;
|
|
5
5
|
//# sourceMappingURL=line-helpers.d.ts.map
|
package/es/victory-util/log.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare function warn(message: string): void;
|
|
1
|
+
export declare function warn(message: string): void;
|
|
2
2
|
//# sourceMappingURL=log.d.ts.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
export declare function circle(x: number, y: number, size: number): string;
|
|
2
|
-
export declare function square(x: number, y: number, size: number): string;
|
|
3
|
-
export declare function diamond(x: number, y: number, size: number): string;
|
|
4
|
-
export declare function triangleDown(x: number, y: number, size: number): string;
|
|
5
|
-
export declare function triangleUp(x: number, y: number, size: number): string;
|
|
6
|
-
export declare function plus(x: number, y: number, size: number): string;
|
|
7
|
-
export declare function cross(x: number, y: number, size: number): string;
|
|
8
|
-
export declare function minus(x: number, y: number, size: number): string;
|
|
9
|
-
export declare function star(x: number, y: number, size: number): string;
|
|
1
|
+
export declare function circle(x: number, y: number, size: number): string;
|
|
2
|
+
export declare function square(x: number, y: number, size: number): string;
|
|
3
|
+
export declare function diamond(x: number, y: number, size: number): string;
|
|
4
|
+
export declare function triangleDown(x: number, y: number, size: number): string;
|
|
5
|
+
export declare function triangleUp(x: number, y: number, size: number): string;
|
|
6
|
+
export declare function plus(x: number, y: number, size: number): string;
|
|
7
|
+
export declare function cross(x: number, y: number, size: number): string;
|
|
8
|
+
export declare function minus(x: number, y: number, size: number): string;
|
|
9
|
+
export declare function star(x: number, y: number, size: number): string;
|
|
10
10
|
//# sourceMappingURL=point-path-helpers.d.ts.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import * as d3Scale from "victory-vendor/d3-scale";
|
|
2
|
-
import { D3Scale, ScaleName } from "../types/prop-types";
|
|
3
|
-
export declare function validScale(scale: string | D3Scale): scale is ScaleName | D3Scale;
|
|
4
|
-
export declare function getScaleFromName(name: ScaleName | string): D3Scale;
|
|
5
|
-
export declare function getBaseScale(props: any, axis: "x" | "y"): D3Scale<any>;
|
|
6
|
-
export declare function getDefaultScale(): d3Scale.ScaleLinear<number, number, never>;
|
|
7
|
-
export declare function getScaleFromProps(props: any, axis: any): D3Scale | undefined;
|
|
8
|
-
export declare function getScaleType(props: any, axis: any): string;
|
|
9
|
-
export declare function getType(scale: any): string | undefined;
|
|
1
|
+
import * as d3Scale from "victory-vendor/d3-scale";
|
|
2
|
+
import { D3Scale, ScaleName } from "../types/prop-types";
|
|
3
|
+
export declare function validScale(scale: string | D3Scale): scale is ScaleName | D3Scale;
|
|
4
|
+
export declare function getScaleFromName(name: ScaleName | string): D3Scale;
|
|
5
|
+
export declare function getBaseScale(props: any, axis: "x" | "y"): D3Scale<any>;
|
|
6
|
+
export declare function getDefaultScale(): d3Scale.ScaleLinear<number, number, never>;
|
|
7
|
+
export declare function getScaleFromProps(props: any, axis: any): D3Scale | undefined;
|
|
8
|
+
export declare function getScaleType(props: any, axis: any): string;
|
|
9
|
+
export declare function getType(scale: any): string | undefined;
|
|
10
10
|
//# sourceMappingURL=scale.d.ts.map
|
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import { VictoryCommonProps } from "./common-props";
|
|
3
|
-
import type { DomainPropType, ScaleXYPropType } from "../types/prop-types";
|
|
4
|
-
export declare function getParentSVG(evt: Pick<React.SyntheticEvent, "target"> & Partial<Pick<React.SyntheticEvent, "nativeEvent">>): SVGElement;
|
|
5
|
-
export declare function getSVGEventCoordinates(evt: React.SyntheticEvent, svg?: SVGElement): SVGCoordinateType;
|
|
6
|
-
export declare function getDomainCoordinates(props: Pick<VictoryCommonProps, "scale" | "horizontal">, domain?: DomainPropType): {
|
|
7
|
-
x: number[];
|
|
8
|
-
y: number[];
|
|
9
|
-
};
|
|
10
|
-
export declare function getDataCoordinates(props: any, scale: ScaleXYPropType, x: number, y: number): SVGCoordinateType;
|
|
11
|
-
export declare function getBounds(props: ComputedCommonProps): SVGCoordinateBounds;
|
|
12
|
-
export declare type SVGCoordinateType = {
|
|
13
|
-
x: number;
|
|
14
|
-
y: number;
|
|
15
|
-
};
|
|
16
|
-
export declare type SVGCoordinateBounds = {
|
|
17
|
-
x: readonly [number, number];
|
|
18
|
-
y: readonly [number, number];
|
|
19
|
-
};
|
|
20
|
-
declare type ComputedCommonProps = {
|
|
21
|
-
scale: ScaleXYPropType;
|
|
22
|
-
x1: number;
|
|
23
|
-
x2: number;
|
|
24
|
-
y1: number;
|
|
25
|
-
y2: number;
|
|
26
|
-
horizontal?: boolean;
|
|
27
|
-
};
|
|
28
|
-
export {};
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { VictoryCommonProps } from "./common-props";
|
|
3
|
+
import type { DomainPropType, ScaleXYPropType } from "../types/prop-types";
|
|
4
|
+
export declare function getParentSVG(evt: Pick<React.SyntheticEvent, "target"> & Partial<Pick<React.SyntheticEvent, "nativeEvent">>): SVGElement;
|
|
5
|
+
export declare function getSVGEventCoordinates(evt: React.SyntheticEvent, svg?: SVGElement): SVGCoordinateType;
|
|
6
|
+
export declare function getDomainCoordinates(props: Pick<VictoryCommonProps, "scale" | "horizontal">, domain?: DomainPropType): {
|
|
7
|
+
x: number[];
|
|
8
|
+
y: number[];
|
|
9
|
+
};
|
|
10
|
+
export declare function getDataCoordinates(props: any, scale: ScaleXYPropType, x: number, y: number): SVGCoordinateType;
|
|
11
|
+
export declare function getBounds(props: ComputedCommonProps): SVGCoordinateBounds;
|
|
12
|
+
export declare type SVGCoordinateType = {
|
|
13
|
+
x: number;
|
|
14
|
+
y: number;
|
|
15
|
+
};
|
|
16
|
+
export declare type SVGCoordinateBounds = {
|
|
17
|
+
x: readonly [number, number];
|
|
18
|
+
y: readonly [number, number];
|
|
19
|
+
};
|
|
20
|
+
declare type ComputedCommonProps = {
|
|
21
|
+
scale: ScaleXYPropType;
|
|
22
|
+
x1: number;
|
|
23
|
+
x2: number;
|
|
24
|
+
y1: number;
|
|
25
|
+
y2: number;
|
|
26
|
+
horizontal?: boolean;
|
|
27
|
+
};
|
|
28
|
+
export {};
|
|
29
29
|
//# sourceMappingURL=selection.d.ts.map
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Given an object with CSS/SVG transform definitions, return the string value
|
|
3
|
-
* for use with the `transform` CSS property or SVG attribute. Note that we
|
|
4
|
-
* can't always guarantee the order will match the author's intended order, so
|
|
5
|
-
* authors should only use the object notation if they know that their transform
|
|
6
|
-
* is commutative or that there is only one.
|
|
7
|
-
* @param {Object} obj An object of transform definitions.
|
|
8
|
-
* @returns {String} The generated transform string.
|
|
9
|
-
*/
|
|
10
|
-
export declare const toTransformString: (obj: any, ...more: any[]) => any;
|
|
11
|
-
/**
|
|
12
|
-
* Given the name of a color scale, getColorScale will return an array
|
|
13
|
-
* of 5 hex string values in that color scale. If no 'name' parameter
|
|
14
|
-
* is given, it will return the Victory default grayscale.
|
|
15
|
-
* @param {String} name The name of the color scale to return (optional).
|
|
16
|
-
* @returns {Array} An array of 5 hex string values composing a color scale.
|
|
17
|
-
*/
|
|
18
|
-
export declare function getColorScale(name: any): any;
|
|
1
|
+
/**
|
|
2
|
+
* Given an object with CSS/SVG transform definitions, return the string value
|
|
3
|
+
* for use with the `transform` CSS property or SVG attribute. Note that we
|
|
4
|
+
* can't always guarantee the order will match the author's intended order, so
|
|
5
|
+
* authors should only use the object notation if they know that their transform
|
|
6
|
+
* is commutative or that there is only one.
|
|
7
|
+
* @param {Object} obj An object of transform definitions.
|
|
8
|
+
* @returns {String} The generated transform string.
|
|
9
|
+
*/
|
|
10
|
+
export declare const toTransformString: (obj: any, ...more: any[]) => any;
|
|
11
|
+
/**
|
|
12
|
+
* Given the name of a color scale, getColorScale will return an array
|
|
13
|
+
* of 5 hex string values in that color scale. If no 'name' parameter
|
|
14
|
+
* is given, it will return the Victory default grayscale.
|
|
15
|
+
* @param {String} name The name of the color scale to return (optional).
|
|
16
|
+
* @returns {Array} An array of 5 hex string values composing a color scale.
|
|
17
|
+
*/
|
|
18
|
+
export declare function getColorScale(name: any): any;
|
|
19
19
|
//# sourceMappingURL=style.d.ts.map
|