victory-area
Advanced tools
Comparing version
# victory-area | ||
## 37.3.3 | ||
### Patch Changes | ||
- Upgrade typescript to 5.7.2 ([#2997](https://github.com/FormidableLabs/victory/pull/2997)) | ||
* Remove deprecated babel-plugin-lodash plugin ([#2965](https://github.com/FormidableLabs/victory/pull/2965)) | ||
## 37.3.2 | ||
@@ -4,0 +12,0 @@ |
@@ -1,4 +0,4 @@ | ||
import _defaults from "lodash/defaults"; | ||
/* eslint no-magic-numbers: ["error", { "ignore": [-1, 0, 1, 2] }]*/ | ||
import React from "react"; | ||
import defaults from "lodash/defaults"; | ||
import * as d3Shape from "victory-vendor/d3-shape"; | ||
@@ -76,3 +76,3 @@ import { Helpers, Path, UserProps, LineHelpers } from "victory-core"; | ||
export const Area = initialProps => { | ||
const props = evaluateProps(_defaults({}, initialProps, defaultProps)); | ||
const props = evaluateProps(defaults({}, initialProps, defaultProps)); | ||
const { | ||
@@ -79,0 +79,0 @@ ariaLabel, |
@@ -13,5 +13,5 @@ import { Helpers, LabelHelpers, Data, Domain, Scale, Collection } from "victory-core"; | ||
let defaultMin = defaultZero; | ||
if (minY < 0 && maxY <= 0) { | ||
if (minY.valueOf() < 0 && maxY.valueOf() <= 0) { | ||
defaultMin = maxY; | ||
} else if (minY >= 0 && maxY > 0) { | ||
} else if (minY.valueOf() >= 0 && maxY.valueOf() > 0) { | ||
defaultMin = minY; | ||
@@ -18,0 +18,0 @@ } |
import React from "react"; | ||
import { Data, Domain, EventPropTypeInterface, InterpolationPropType, StringOrNumberOrCallback, VictoryCommonProps, VictoryDatableProps, VictoryMultiLabelableProps, VictoryStyleInterface, EventsMixinClass } from "victory-core"; | ||
export declare type VictoryAreaTTargetType = "data" | "labels" | "parent"; | ||
export type VictoryAreaTTargetType = "data" | "labels" | "parent"; | ||
export interface VictoryAreaProps extends VictoryCommonProps, VictoryDatableProps, VictoryMultiLabelableProps { | ||
@@ -57,5 +57,5 @@ eventKey?: string[] | number[] | StringOrNumberOrCallback; | ||
renderContainer(component: any, children: any): React.DetailedReactHTMLElement<any, HTMLElement>; | ||
animateComponent(props: import("victory-core").EventMixinCommonProps, defaultAnimationWhitelist: string[]): React.ReactElement<any, string | React.JSXElementConstructor<any>>; | ||
animateComponent(props: import("victory-core").EventMixinCommonProps, defaultAnimationWhitelist: string[]): React.ReactElement; | ||
renderContinuousData(props: import("victory-core").EventMixinCommonProps): React.DetailedReactHTMLElement<any, HTMLElement>; | ||
renderData(props: any, shouldRenderDatum?: ((datum: any) => boolean) | undefined): React.DetailedReactHTMLElement<any, HTMLElement>; | ||
renderData(props: any, shouldRenderDatum?: (datum: any) => boolean): React.DetailedReactHTMLElement<any, HTMLElement>; | ||
context: unknown; | ||
@@ -77,3 +77,3 @@ setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<import("victory-core").EventMixinCommonProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void; | ||
UNSAFE_componentWillUpdate?(nextProps: Readonly<import("victory-core").EventMixinCommonProps>, nextState: Readonly<{}>, nextContext: any): void; | ||
componentEvents: import("@/victory-core/lib/victory-util/events").ComponentEvent[]; | ||
componentEvents: Array<import("@/victory-core/lib/victory-util/events").ComponentEvent>; | ||
getSharedEventState: (key: string, value: string) => unknown; | ||
@@ -85,6 +85,6 @@ baseProps: Record<string, object>; | ||
}; | ||
getBaseProps?(props: import("victory-core").EventMixinCommonProps): Record<string, object>; | ||
role?: string | undefined; | ||
getBaseProps?(props: import("victory-core").EventMixinCommonProps): import("victory-core").EventMixinCalculatedValues["baseProps"]; | ||
role?: import("victory-core").VictoryComponentRole; | ||
expectedComponents?: string[] | undefined; | ||
getChildren?: ((props: import("victory-core").EventMixinCommonProps, childComponents?: React.ReactNode[] | undefined, calculatedProps?: import("victory-core").EventMixinCommonProps | undefined) => void) | undefined; | ||
getChildren?: ((props: import("victory-core").EventMixinCommonProps, childComponents?: Array<React.ReactNode>, calculatedProps?: import("victory-core").EventMixinCommonProps | undefined) => void) | undefined; | ||
animationWhitelist?: string[] | undefined; | ||
@@ -91,0 +91,0 @@ } & typeof VictoryAreaBase; |
@@ -7,4 +7,4 @@ "use strict"; | ||
exports.Area = void 0; | ||
var _defaults2 = _interopRequireDefault(require("lodash/defaults")); | ||
var _react = _interopRequireDefault(require("react")); | ||
var _defaults = _interopRequireDefault(require("lodash/defaults")); | ||
var d3Shape = _interopRequireWildcard(require("victory-vendor/d3-shape")); | ||
@@ -87,3 +87,3 @@ var _victoryCore = require("victory-core"); | ||
const Area = initialProps => { | ||
const props = evaluateProps((0, _defaults2.default)({}, initialProps, defaultProps)); | ||
const props = evaluateProps((0, _defaults.default)({}, initialProps, defaultProps)); | ||
const { | ||
@@ -90,0 +90,0 @@ ariaLabel, |
@@ -19,5 +19,5 @@ "use strict"; | ||
let defaultMin = defaultZero; | ||
if (minY < 0 && maxY <= 0) { | ||
if (minY.valueOf() < 0 && maxY.valueOf() <= 0) { | ||
defaultMin = maxY; | ||
} else if (minY >= 0 && maxY > 0) { | ||
} else if (minY.valueOf() >= 0 && maxY.valueOf() > 0) { | ||
defaultMin = minY; | ||
@@ -24,0 +24,0 @@ } |
import React from "react"; | ||
import { Data, Domain, EventPropTypeInterface, InterpolationPropType, StringOrNumberOrCallback, VictoryCommonProps, VictoryDatableProps, VictoryMultiLabelableProps, VictoryStyleInterface, EventsMixinClass } from "victory-core"; | ||
export declare type VictoryAreaTTargetType = "data" | "labels" | "parent"; | ||
export type VictoryAreaTTargetType = "data" | "labels" | "parent"; | ||
export interface VictoryAreaProps extends VictoryCommonProps, VictoryDatableProps, VictoryMultiLabelableProps { | ||
@@ -57,5 +57,5 @@ eventKey?: string[] | number[] | StringOrNumberOrCallback; | ||
renderContainer(component: any, children: any): React.DetailedReactHTMLElement<any, HTMLElement>; | ||
animateComponent(props: import("victory-core").EventMixinCommonProps, defaultAnimationWhitelist: string[]): React.ReactElement<any, string | React.JSXElementConstructor<any>>; | ||
animateComponent(props: import("victory-core").EventMixinCommonProps, defaultAnimationWhitelist: string[]): React.ReactElement; | ||
renderContinuousData(props: import("victory-core").EventMixinCommonProps): React.DetailedReactHTMLElement<any, HTMLElement>; | ||
renderData(props: any, shouldRenderDatum?: ((datum: any) => boolean) | undefined): React.DetailedReactHTMLElement<any, HTMLElement>; | ||
renderData(props: any, shouldRenderDatum?: (datum: any) => boolean): React.DetailedReactHTMLElement<any, HTMLElement>; | ||
context: unknown; | ||
@@ -77,3 +77,3 @@ setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<import("victory-core").EventMixinCommonProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void; | ||
UNSAFE_componentWillUpdate?(nextProps: Readonly<import("victory-core").EventMixinCommonProps>, nextState: Readonly<{}>, nextContext: any): void; | ||
componentEvents: import("@/victory-core/lib/victory-util/events").ComponentEvent[]; | ||
componentEvents: Array<import("@/victory-core/lib/victory-util/events").ComponentEvent>; | ||
getSharedEventState: (key: string, value: string) => unknown; | ||
@@ -85,6 +85,6 @@ baseProps: Record<string, object>; | ||
}; | ||
getBaseProps?(props: import("victory-core").EventMixinCommonProps): Record<string, object>; | ||
role?: string | undefined; | ||
getBaseProps?(props: import("victory-core").EventMixinCommonProps): import("victory-core").EventMixinCalculatedValues["baseProps"]; | ||
role?: import("victory-core").VictoryComponentRole; | ||
expectedComponents?: string[] | undefined; | ||
getChildren?: ((props: import("victory-core").EventMixinCommonProps, childComponents?: React.ReactNode[] | undefined, calculatedProps?: import("victory-core").EventMixinCommonProps | undefined) => void) | undefined; | ||
getChildren?: ((props: import("victory-core").EventMixinCommonProps, childComponents?: Array<React.ReactNode>, calculatedProps?: import("victory-core").EventMixinCommonProps | undefined) => void) | undefined; | ||
animationWhitelist?: string[] | undefined; | ||
@@ -91,0 +91,0 @@ } & typeof VictoryAreaBase; |
{ | ||
"name": "victory-area", | ||
"version": "37.3.2", | ||
"version": "37.3.3", | ||
"description": "Area Component for Victory", | ||
@@ -24,4 +24,4 @@ "keywords": [ | ||
"lodash": "^4.17.19", | ||
"victory-core": "37.3.2", | ||
"victory-vendor": "37.3.2" | ||
"victory-core": "37.3.3", | ||
"victory-vendor": "37.3.3" | ||
}, | ||
@@ -194,28 +194,2 @@ "peerDependencies": { | ||
}, | ||
"format": { | ||
"command": "nps format:pkg", | ||
"files": [ | ||
"src/**", | ||
"*.json", | ||
"../../.prettierignore", | ||
"../../.prettierrc.json" | ||
], | ||
"output": [], | ||
"packageLocks": [ | ||
"pnpm-lock.yaml" | ||
] | ||
}, | ||
"format:fix": { | ||
"command": "pnpm run format || nps format:pkg:fix", | ||
"files": [ | ||
"src/**", | ||
"*.json", | ||
"../../.prettierignore", | ||
"../../.prettierrc.json" | ||
], | ||
"output": [], | ||
"packageLocks": [ | ||
"pnpm-lock.yaml" | ||
] | ||
}, | ||
"lint": { | ||
@@ -288,4 +262,2 @@ "command": "eslint src", | ||
"types:create": "wireit", | ||
"format": "wireit", | ||
"format:fix": "wireit", | ||
"lint": "wireit", | ||
@@ -292,0 +264,0 @@ "lint:fix": "wireit", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
1203626
0.07%21147
0.2%+ Added
+ Added
- Removed
- Removed
Updated
Updated