victory-cursor-container 36.5.1 → 36.6.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "victory-cursor-container",
3
- "version": "36.5.1",
3
+ "version": "36.6.0",
4
4
  "description": "Interactive Cursor Component for Victory",
5
5
  "keywords": [
6
6
  "data visualization",
@@ -13,6 +13,7 @@
13
13
  "url": "https://github.com/formidablelabs/victory.git"
14
14
  },
15
15
  "homepage": "https://formidable.com/open-source/victory",
16
+ "sideEffects": false,
16
17
  "main": "lib/index.js",
17
18
  "module": "es/index.js",
18
19
  "jsnext:main": "es/index.js",
@@ -21,14 +22,241 @@
21
22
  "dependencies": {
22
23
  "lodash": "^4.17.19",
23
24
  "prop-types": "^15.8.1",
24
- "victory-core": "^36.5.1"
25
+ "victory-core": "^36.6.0"
25
26
  },
26
27
  "peerDependencies": {
27
28
  "react": ">=16.6.0"
28
29
  },
29
- "scripts": {
30
- "version": "yarn run nps build-libs && nps build-dists"
30
+ "wireit": {
31
+ "### THESE WIREIT CONFIGS ARE GENERATED ####": {},
32
+ "### DO NOT MODIFY THESE MANUALLY ####": {},
33
+ "build": {
34
+ "dependencies": [
35
+ "build:lib",
36
+ "build:dist",
37
+ "types:create"
38
+ ]
39
+ },
40
+ "build:lib": {
41
+ "dependencies": [
42
+ "build:lib:esm",
43
+ "build:lib:cjs"
44
+ ]
45
+ },
46
+ "build:lib:esm": {
47
+ "command": "nps build:lib:esm",
48
+ "files": [
49
+ "src/**",
50
+ "!src/**/*.test.*",
51
+ "../../.babelrc.build.js"
52
+ ],
53
+ "output": [
54
+ "es/**/*.js",
55
+ "es/**/*.js.map"
56
+ ],
57
+ "dependencies": [
58
+ "../victory-core:build:lib:esm"
59
+ ],
60
+ "packageLocks": [
61
+ "pnpm-lock.yaml"
62
+ ]
63
+ },
64
+ "build:lib:cjs": {
65
+ "command": "nps build:lib:cjs",
66
+ "files": [
67
+ "src/**",
68
+ "!src/**/*.test.*",
69
+ "../../.babelrc.build.js"
70
+ ],
71
+ "output": [
72
+ "lib/**/*.js",
73
+ "lib/**/*.js.map"
74
+ ],
75
+ "dependencies": [
76
+ "../victory-core:build:lib:cjs"
77
+ ],
78
+ "packageLocks": [
79
+ "pnpm-lock.yaml"
80
+ ]
81
+ },
82
+ "build:dist": {
83
+ "dependencies": [
84
+ "build:dist:dev",
85
+ "build:dist:min"
86
+ ]
87
+ },
88
+ "build:dist:dev": {
89
+ "command": "nps build:dist:dev",
90
+ "files": [
91
+ "src/**",
92
+ "!src/**/*.test.*",
93
+ "../../.babelrc.build.js",
94
+ "../../config/webpack.config.js",
95
+ "../../config/webpack.config.dev.js"
96
+ ],
97
+ "output": [
98
+ "dist/victory*.js",
99
+ "!dist/victory*.min.js*"
100
+ ],
101
+ "dependencies": [
102
+ "../victory-core:build:lib:esm"
103
+ ],
104
+ "packageLocks": [
105
+ "pnpm-lock.yaml"
106
+ ]
107
+ },
108
+ "build:dist:min": {
109
+ "command": "nps build:dist:min",
110
+ "files": [
111
+ "src/**",
112
+ "!src/**/*.test.*",
113
+ "../../.babelrc.build.js",
114
+ "../../config/webpack.config.js"
115
+ ],
116
+ "output": [
117
+ "dist/victory*.min.js*"
118
+ ],
119
+ "dependencies": [
120
+ "../victory-core:build:lib:esm"
121
+ ],
122
+ "packageLocks": [
123
+ "pnpm-lock.yaml"
124
+ ]
125
+ },
126
+ "types:check": {
127
+ "command": "nps types:pkg:check",
128
+ "files": [
129
+ "src/**/*.{ts,tsx}",
130
+ "../../tsconfig.base.json",
131
+ "tsconfig.json"
132
+ ],
133
+ "dependencies": [
134
+ "types:create",
135
+ "../victory-core:types:create",
136
+ "../victory-vendor:types:create",
137
+ "../victory-voronoi:types:create"
138
+ ],
139
+ "output": [],
140
+ "packageLocks": [
141
+ "pnpm-lock.yaml"
142
+ ]
143
+ },
144
+ "types:create": {
145
+ "command": "nps types:pkg:create",
146
+ "files": [
147
+ "src/**",
148
+ "!src/**/*.test.*",
149
+ "../../tsconfig.base.json",
150
+ "tsconfig.build.json"
151
+ ],
152
+ "output": [
153
+ "es/**/*.d.ts",
154
+ "es/**/*.d.ts.map",
155
+ "lib/**/*.d.ts",
156
+ "lib/**/*.d.ts.map"
157
+ ],
158
+ "dependencies": [
159
+ "../victory-core:types:create"
160
+ ],
161
+ "packageLocks": [
162
+ "pnpm-lock.yaml"
163
+ ]
164
+ },
165
+ "format": {
166
+ "command": "nps format:pkg",
167
+ "files": [
168
+ "src/**",
169
+ "*.json",
170
+ "../../.prettierignore",
171
+ "../../.prettierrc.json"
172
+ ],
173
+ "output": [],
174
+ "packageLocks": [
175
+ "pnpm-lock.yaml"
176
+ ]
177
+ },
178
+ "lint": {
179
+ "command": "nps lint:pkg",
180
+ "files": [
181
+ "src/**",
182
+ "../../.eslintignore",
183
+ "../../.eslintrc.js"
184
+ ],
185
+ "output": [],
186
+ "dependencies": [
187
+ "../victory-core:types:create",
188
+ "../victory-vendor:types:create",
189
+ "../victory-voronoi:types:create"
190
+ ],
191
+ "packageLocks": [
192
+ "pnpm-lock.yaml"
193
+ ]
194
+ },
195
+ "format:fix": {
196
+ "command": "pnpm run format || nps format:pkg:fix",
197
+ "files": [
198
+ "src/**",
199
+ "*.json",
200
+ "../../.prettierignore",
201
+ "../../.prettierrc.json"
202
+ ],
203
+ "output": [],
204
+ "packageLocks": [
205
+ "pnpm-lock.yaml"
206
+ ]
207
+ },
208
+ "lint:fix": {
209
+ "command": "pnpm run lint || nps lint:pkg:fix",
210
+ "files": [
211
+ "src/**",
212
+ "../../.eslintignore",
213
+ "../../.eslintrc.js"
214
+ ],
215
+ "output": [],
216
+ "dependencies": [
217
+ "../victory-core:types:create",
218
+ "../victory-vendor:types:create",
219
+ "../victory-voronoi:types:create"
220
+ ],
221
+ "packageLocks": [
222
+ "pnpm-lock.yaml"
223
+ ]
224
+ },
225
+ "jest": {
226
+ "command": "nps jest:pkg",
227
+ "files": [
228
+ "src/**/*.test.*",
229
+ "../../.babelrc.js",
230
+ "../../test/jest-config.js",
231
+ "../../test/jest-setup.ts"
232
+ ],
233
+ "output": [],
234
+ "dependencies": [
235
+ "build:lib:cjs",
236
+ "../victory-vendor:build:lib:cjs",
237
+ "../victory-voronoi:build:lib:cjs"
238
+ ],
239
+ "packageLocks": [
240
+ "pnpm-lock.yaml"
241
+ ]
242
+ }
31
243
  },
32
- "sideEffects": false,
33
- "gitHead": "fbe60407533cd7a6da4f8155d2ef8e189583c5a2"
34
- }
244
+ "scripts": {
245
+ "### THESE SCRIPTS ARE GENERATED ###": "true",
246
+ "### DO NOT MODIFY THESE MANUALLY ###": "true",
247
+ "build": "wireit",
248
+ "build:lib": "wireit",
249
+ "build:lib:esm": "wireit",
250
+ "build:lib:cjs": "wireit",
251
+ "build:dist": "wireit",
252
+ "build:dist:dev": "wireit",
253
+ "build:dist:min": "wireit",
254
+ "types:check": "wireit",
255
+ "types:create": "wireit",
256
+ "format": "wireit",
257
+ "format:fix": "wireit",
258
+ "lint": "wireit",
259
+ "lint:fix": "wireit",
260
+ "jest": "wireit"
261
+ }
262
+ }
package/src/index.d.ts CHANGED
@@ -25,3 +25,13 @@ export class VictoryCursorContainer extends React.Component<
25
25
  VictoryCursorContainerProps,
26
26
  any
27
27
  > {}
28
+
29
+ export const CursorHelpers: {
30
+ getDimension(props): any;
31
+ withinBounds(point, bounds): any;
32
+ onMouseMove(evt, targetProps): any;
33
+ onMouseLeave(evt, targetProps): any;
34
+ onTouchEnd(evt, targetProps): any;
35
+ };
36
+
37
+ export const cursorContainerMixin: (base: Function) => Function;
@@ -109,9 +109,8 @@ export const cursorContainerMixin = (base) =>
109
109
  return isObject(c.props) && c.props.padding !== undefined;
110
110
  });
111
111
  return Helpers.getPadding(child.props);
112
- } else {
113
- return Helpers.getPadding(props);
114
112
  }
113
+ return Helpers.getPadding(props);
115
114
  }
116
115
 
117
116
  getCursorElements(props) {