@d3plus/docs 3.0.0-alpha.3

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.
Files changed (225) hide show
  1. package/.storybook/main.js +51 -0
  2. package/.storybook/manager-head.html +46 -0
  3. package/.storybook/manager.js +10 -0
  4. package/.storybook/preview-head.html +69 -0
  5. package/.storybook/preview.jsx +134 -0
  6. package/.storybook/theme.js +16 -0
  7. package/README.md +1 -0
  8. package/args/color/colorAdd.args.jsx +71 -0
  9. package/args/color/colorAssign.args.jsx +40 -0
  10. package/args/color/colorContrast.args.jsx +40 -0
  11. package/args/color/colorDefaults.args.jsx +8 -0
  12. package/args/color/colorLegible.args.jsx +24 -0
  13. package/args/color/colorLighter.args.jsx +40 -0
  14. package/args/color/colorSubtract.args.jsx +71 -0
  15. package/args/core/charts/AreaPlot.args.jsx +72 -0
  16. package/args/core/charts/BarChart.args.jsx +88 -0
  17. package/args/core/charts/BoxWhisker.args.jsx +73 -0
  18. package/args/core/charts/BumpChart.args.jsx +133 -0
  19. package/args/core/charts/Donut.args.jsx +58 -0
  20. package/args/core/charts/Geomap.args.jsx +363 -0
  21. package/args/core/charts/LinePlot.args.jsx +57 -0
  22. package/args/core/charts/Matrix.args.jsx +194 -0
  23. package/args/core/charts/Network.args.jsx +310 -0
  24. package/args/core/charts/Pack.args.jsx +171 -0
  25. package/args/core/charts/Pie.args.jsx +148 -0
  26. package/args/core/charts/Plot.args.jsx +685 -0
  27. package/args/core/charts/Priestley.args.jsx +118 -0
  28. package/args/core/charts/Radar.args.jsx +120 -0
  29. package/args/core/charts/RadialMatrix.args.jsx +197 -0
  30. package/args/core/charts/Rings.args.jsx +228 -0
  31. package/args/core/charts/Sankey.args.jsx +248 -0
  32. package/args/core/charts/StackedArea.args.jsx +26 -0
  33. package/args/core/charts/Tree.args.jsx +88 -0
  34. package/args/core/charts/Treemap.args.jsx +181 -0
  35. package/args/core/charts/Viz.args.jsx +1383 -0
  36. package/args/core/components/Axis.args.jsx +600 -0
  37. package/args/core/components/AxisBottom.args.jsx +42 -0
  38. package/args/core/components/AxisLeft.args.jsx +42 -0
  39. package/args/core/components/AxisRight.args.jsx +42 -0
  40. package/args/core/components/AxisTop.args.jsx +42 -0
  41. package/args/core/components/ColorScale.args.jsx +456 -0
  42. package/args/core/components/Legend.args.jsx +289 -0
  43. package/args/core/components/TextBox.args.jsx +554 -0
  44. package/args/core/components/Timeline.args.jsx +401 -0
  45. package/args/core/components/Tooltip.args.jsx +453 -0
  46. package/args/core/shapes/Area.args.jsx +190 -0
  47. package/args/core/shapes/Bar.args.jsx +176 -0
  48. package/args/core/shapes/Box.args.jsx +248 -0
  49. package/args/core/shapes/Circle.args.jsx +84 -0
  50. package/args/core/shapes/Image.args.jsx +177 -0
  51. package/args/core/shapes/Line.args.jsx +127 -0
  52. package/args/core/shapes/Path.args.jsx +84 -0
  53. package/args/core/shapes/Rect.args.jsx +85 -0
  54. package/args/core/shapes/Shape.args.jsx +633 -0
  55. package/args/core/shapes/Whisker.args.jsx +204 -0
  56. package/args/core/utils/BaseClass.args.jsx +65 -0
  57. package/args/core/utils/RESET.args.jsx +8 -0
  58. package/args/core/utils/accessor.args.jsx +39 -0
  59. package/args/core/utils/configPrep.args.jsx +56 -0
  60. package/args/core/utils/constant.args.jsx +24 -0
  61. package/args/core/utils/uuid.args.jsx +8 -0
  62. package/args/data/dataConcat.args.jsx +40 -0
  63. package/args/data/dataFold.args.jsx +56 -0
  64. package/args/data/dataLoad.args.jsx +65 -0
  65. package/args/data/isData.args.jsx +24 -0
  66. package/args/data/merge.args.jsx +39 -0
  67. package/args/data/unique.args.jsx +37 -0
  68. package/args/dom/assign.args.jsx +23 -0
  69. package/args/dom/attrize.args.jsx +39 -0
  70. package/args/dom/date.args.jsx +23 -0
  71. package/args/dom/elem.args.jsx +135 -0
  72. package/args/dom/fontExists.args.jsx +24 -0
  73. package/args/dom/htmlDecode.args.jsx +23 -0
  74. package/args/dom/isObject.args.jsx +23 -0
  75. package/args/dom/parseSides.args.jsx +24 -0
  76. package/args/dom/prefix.args.jsx +8 -0
  77. package/args/dom/rtl.args.jsx +8 -0
  78. package/args/dom/stylize.args.jsx +39 -0
  79. package/args/dom/textWidth.args.jsx +39 -0
  80. package/args/export/saveElement.args.jsx +99 -0
  81. package/args/format/format.args.jsx +24 -0
  82. package/args/format/formatAbbreviate.args.jsx +39 -0
  83. package/args/format/formatDate.args.jsx +53 -0
  84. package/args/format/formatDefaultLocale.args.jsx +24 -0
  85. package/args/locales/dictionaries/formatLocale.args.jsx +8 -0
  86. package/args/math/closest.args.jsx +39 -0
  87. package/args/math/largestRect.args.jsx +56 -0
  88. package/args/math/lineIntersection.args.jsx +69 -0
  89. package/args/math/path2polygon.args.jsx +40 -0
  90. package/args/math/pointDistance.args.jsx +39 -0
  91. package/args/math/pointDistanceSquared.args.jsx +39 -0
  92. package/args/math/pointRotate.args.jsx +55 -0
  93. package/args/math/polygonInside.args.jsx +39 -0
  94. package/args/math/polygonRayCast.args.jsx +55 -0
  95. package/args/math/polygonRotate.args.jsx +55 -0
  96. package/args/math/segmentBoxContains.args.jsx +54 -0
  97. package/args/math/segmentsIntersect.args.jsx +69 -0
  98. package/args/math/shapeEdgePoint.args.jsx +39 -0
  99. package/args/react/D3plusContext.args.jsx +8 -0
  100. package/args/react/Renderer.args.jsx +53 -0
  101. package/args/text/fontFamily.args.jsx +8 -0
  102. package/args/text/fontFamilyStringify.args.jsx +23 -0
  103. package/args/text/stringify.args.jsx +23 -0
  104. package/args/text/strip.args.jsx +38 -0
  105. package/args/text/textSplit.args.jsx +23 -0
  106. package/args/text/textWrap.args.jsx +8 -0
  107. package/args/text/titleCase.args.jsx +24 -0
  108. package/args/text/trim.args.jsx +23 -0
  109. package/args/text/trimLeft.args.jsx +23 -0
  110. package/args/text/trimRight.args.jsx +23 -0
  111. package/docs/Accessibility.mdx +70 -0
  112. package/docs/HomeChart.jsx +38 -0
  113. package/docs/Introduction.mdx +130 -0
  114. package/docs/Logo-Frames.js +352 -0
  115. package/docs/Logo.jsx +30 -0
  116. package/helpers/configify.js +18 -0
  117. package/helpers/funcify.js +14 -0
  118. package/helpers/stringify.js +30 -0
  119. package/package.json +44 -0
  120. package/packages/color/colorAdd.stories.jsx +23 -0
  121. package/packages/color/colorAssign.stories.jsx +23 -0
  122. package/packages/color/colorContrast.stories.jsx +23 -0
  123. package/packages/color/colorDefaults.stories.jsx +23 -0
  124. package/packages/color/colorLegible.stories.jsx +23 -0
  125. package/packages/color/colorLighter.stories.jsx +23 -0
  126. package/packages/color/colorSubtract.stories.jsx +23 -0
  127. package/packages/core/charts/AreaPlot.stories.jsx +74 -0
  128. package/packages/core/charts/BarChart.stories.jsx +307 -0
  129. package/packages/core/charts/BoxWhisker.stories.jsx +204 -0
  130. package/packages/core/charts/BumpChart.stories.jsx +52 -0
  131. package/packages/core/charts/Donut.stories.jsx +41 -0
  132. package/packages/core/charts/Geomap.stories.jsx +186 -0
  133. package/packages/core/charts/LinePlot.stories.jsx +564 -0
  134. package/packages/core/charts/Matrix.stories.jsx +36 -0
  135. package/packages/core/charts/Network.stories.jsx +99 -0
  136. package/packages/core/charts/Pack.stories.jsx +40 -0
  137. package/packages/core/charts/Pie.stories.jsx +40 -0
  138. package/packages/core/charts/Plot.stories.jsx +180 -0
  139. package/packages/core/charts/Priestley.stories.jsx +60 -0
  140. package/packages/core/charts/Radar.stories.jsx +60 -0
  141. package/packages/core/charts/RadialMatrix.stories.jsx +36 -0
  142. package/packages/core/charts/Rings.stories.jsx +41 -0
  143. package/packages/core/charts/Sankey.stories.jsx +41 -0
  144. package/packages/core/charts/StackedArea.stories.jsx +107 -0
  145. package/packages/core/charts/Tree.stories.jsx +27 -0
  146. package/packages/core/charts/Treemap.stories.jsx +81 -0
  147. package/packages/core/charts/Viz.stories.jsx +27 -0
  148. package/packages/core/components/Axis.stories.jsx +27 -0
  149. package/packages/core/components/AxisBottom.stories.jsx +27 -0
  150. package/packages/core/components/AxisLeft.stories.jsx +27 -0
  151. package/packages/core/components/AxisRight.stories.jsx +27 -0
  152. package/packages/core/components/AxisTop.stories.jsx +27 -0
  153. package/packages/core/components/ColorScale.stories.jsx +44 -0
  154. package/packages/core/components/Legend.stories.jsx +49 -0
  155. package/packages/core/components/TextBox.stories.jsx +222 -0
  156. package/packages/core/components/Timeline.stories.jsx +37 -0
  157. package/packages/core/components/Tooltip.stories.jsx +40 -0
  158. package/packages/core/shapes/Area.stories.jsx +27 -0
  159. package/packages/core/shapes/Bar.stories.jsx +27 -0
  160. package/packages/core/shapes/Box.stories.jsx +27 -0
  161. package/packages/core/shapes/Circle.stories.jsx +27 -0
  162. package/packages/core/shapes/Image.stories.jsx +27 -0
  163. package/packages/core/shapes/Line.stories.jsx +27 -0
  164. package/packages/core/shapes/Path.stories.jsx +27 -0
  165. package/packages/core/shapes/Rect.stories.jsx +27 -0
  166. package/packages/core/shapes/Shape.stories.jsx +27 -0
  167. package/packages/core/shapes/Whisker.stories.jsx +27 -0
  168. package/packages/core/utils/BaseClass.stories.jsx +27 -0
  169. package/packages/core/utils/RESET.stories.jsx +23 -0
  170. package/packages/core/utils/accessor.stories.jsx +23 -0
  171. package/packages/core/utils/configPrep.stories.jsx +23 -0
  172. package/packages/core/utils/constant.stories.jsx +23 -0
  173. package/packages/core/utils/uuid.stories.jsx +23 -0
  174. package/packages/data/dataConcat.stories.jsx +23 -0
  175. package/packages/data/dataFold.stories.jsx +23 -0
  176. package/packages/data/dataLoad.stories.jsx +23 -0
  177. package/packages/data/isData.stories.jsx +23 -0
  178. package/packages/data/merge.stories.jsx +23 -0
  179. package/packages/data/unique.stories.jsx +23 -0
  180. package/packages/dom/assign.stories.jsx +23 -0
  181. package/packages/dom/attrize.stories.jsx +23 -0
  182. package/packages/dom/date.stories.jsx +23 -0
  183. package/packages/dom/elem.stories.jsx +23 -0
  184. package/packages/dom/fontExists.stories.jsx +23 -0
  185. package/packages/dom/htmlDecode.stories.jsx +23 -0
  186. package/packages/dom/isObject.stories.jsx +23 -0
  187. package/packages/dom/parseSides.stories.jsx +23 -0
  188. package/packages/dom/prefix.stories.jsx +23 -0
  189. package/packages/dom/rtl.stories.jsx +23 -0
  190. package/packages/dom/stylize.stories.jsx +23 -0
  191. package/packages/dom/textWidth.stories.jsx +23 -0
  192. package/packages/export/saveElement.stories.jsx +23 -0
  193. package/packages/format/format.stories.jsx +23 -0
  194. package/packages/format/formatAbbreviate.stories.jsx +23 -0
  195. package/packages/format/formatDate.stories.jsx +23 -0
  196. package/packages/format/formatDefaultLocale.stories.jsx +23 -0
  197. package/packages/locales/dictionaries/formatLocale.stories.jsx +23 -0
  198. package/packages/math/closest.stories.jsx +23 -0
  199. package/packages/math/largestRect.stories.jsx +23 -0
  200. package/packages/math/lineIntersection.stories.jsx +23 -0
  201. package/packages/math/path2polygon.stories.jsx +23 -0
  202. package/packages/math/pointDistance.stories.jsx +23 -0
  203. package/packages/math/pointDistanceSquared.stories.jsx +23 -0
  204. package/packages/math/pointRotate.stories.jsx +23 -0
  205. package/packages/math/polygonInside.stories.jsx +23 -0
  206. package/packages/math/polygonRayCast.stories.jsx +23 -0
  207. package/packages/math/polygonRotate.stories.jsx +23 -0
  208. package/packages/math/segmentBoxContains.stories.jsx +23 -0
  209. package/packages/math/segmentsIntersect.stories.jsx +23 -0
  210. package/packages/math/shapeEdgePoint.stories.jsx +23 -0
  211. package/packages/react/D3plusContext.stories.jsx +23 -0
  212. package/packages/react/Renderer.stories.jsx +23 -0
  213. package/packages/text/fontFamily.stories.jsx +23 -0
  214. package/packages/text/fontFamilyStringify.stories.jsx +23 -0
  215. package/packages/text/stringify.stories.jsx +23 -0
  216. package/packages/text/strip.stories.jsx +23 -0
  217. package/packages/text/textSplit.stories.jsx +23 -0
  218. package/packages/text/textWrap.stories.jsx +23 -0
  219. package/packages/text/titleCase.stories.jsx +23 -0
  220. package/packages/text/trim.stories.jsx +23 -0
  221. package/packages/text/trimLeft.stories.jsx +23 -0
  222. package/packages/text/trimRight.stories.jsx +23 -0
  223. package/static/data/city_coords.json +224 -0
  224. package/static/images/favicon.ico +0 -0
  225. package/static/images/touchicon.png +0 -0
@@ -0,0 +1,600 @@
1
+ // WARNING: do not edit this file directly, it is generated dynamically from
2
+ // the source JSDOC comments using the npm run docs script.
3
+
4
+ import React from "react";
5
+ import {argTypes as baseClassArgTypes} from "../utils/BaseClass.args.jsx";
6
+ import {assign} from "@d3plus/dom";
7
+
8
+ import {Axis as D3plusAxis} from "@d3plus/react";
9
+ export const Axis = ({ config }) => <D3plusAxis config={config} />;
10
+
11
+ export const argTypes = assign(
12
+
13
+ /**
14
+ * Filters out unused argTypes from the BaseClass primitive and
15
+ * overrides any defaults that have been changed in Axis
16
+ */
17
+ Object.keys(baseClassArgTypes)
18
+ .reduce((obj, k) => (obj[k] = baseClassArgTypes[k], obj), {}),
19
+
20
+ /**
21
+ * Axis-specific methods
22
+ */
23
+
24
+ {
25
+ align: {
26
+ control: {
27
+ type: "text"
28
+ },
29
+ defaultValue: "middle",
30
+ description: "Supports `\"left\"` and `\"center\"` and `\"right\"`.",
31
+ table: {
32
+ defaultValue: {
33
+ summary: "middle"
34
+ }
35
+ },
36
+ type: {
37
+ required: false,
38
+ summary: "string"
39
+ }
40
+ },
41
+ barConfig: {
42
+ control: {
43
+ type: "object"
44
+ },
45
+ defaultValue: "{stroke: openColor.colors.gray.600, stroke-width: 1}",
46
+ table: {
47
+ defaultValue: {
48
+ summary: "{stroke: openColor.colors.gray.600, stroke-width: 1}"
49
+ }
50
+ },
51
+ type: {
52
+ required: false,
53
+ summary: "object"
54
+ }
55
+ },
56
+ data: {
57
+ control: {
58
+ type: "array"
59
+ },
60
+ defaultValue: "[\n\n]",
61
+ table: {
62
+ defaultValue: {
63
+ summary: "[\n\n]"
64
+ }
65
+ },
66
+ type: {
67
+ required: false,
68
+ summary: "array"
69
+ }
70
+ },
71
+ domain: {
72
+ control: {
73
+ type: "array"
74
+ },
75
+ defaultValue: "[\n0,\n10\n]",
76
+ table: {
77
+ defaultValue: {
78
+ summary: "[\n0,\n10\n]"
79
+ }
80
+ },
81
+ type: {
82
+ required: false,
83
+ summary: "array"
84
+ }
85
+ },
86
+ duration: {
87
+ control: {
88
+ type: "number"
89
+ },
90
+ defaultValue: 600,
91
+ table: {
92
+ defaultValue: {
93
+ summary: 600
94
+ }
95
+ },
96
+ type: {
97
+ required: false,
98
+ summary: "number"
99
+ }
100
+ },
101
+ grid: {
102
+ control: {
103
+ type: "array"
104
+ },
105
+ table: {
106
+ defaultValue: {
107
+ summary: "undefined"
108
+ }
109
+ },
110
+ type: {
111
+ required: false,
112
+ summary: "array"
113
+ }
114
+ },
115
+ gridConfig: {
116
+ control: {
117
+ type: "object"
118
+ },
119
+ defaultValue: "{stroke: colorDefaults.light, stroke-width: 1}",
120
+ table: {
121
+ defaultValue: {
122
+ summary: "{stroke: colorDefaults.light, stroke-width: 1}"
123
+ }
124
+ },
125
+ type: {
126
+ required: false,
127
+ summary: "object"
128
+ }
129
+ },
130
+ gridLog: {
131
+ control: {
132
+ type: "boolean"
133
+ },
134
+ defaultValue: false,
135
+ table: {
136
+ defaultValue: {
137
+ summary: false
138
+ }
139
+ },
140
+ type: {
141
+ required: false,
142
+ summary: "boolean"
143
+ }
144
+ },
145
+ gridSize: {
146
+ control: {
147
+ type: "number"
148
+ },
149
+ table: {
150
+ defaultValue: {
151
+ summary: "undefined"
152
+ }
153
+ },
154
+ type: {
155
+ required: false,
156
+ summary: "number"
157
+ }
158
+ },
159
+ height: {
160
+ control: {
161
+ type: "number"
162
+ },
163
+ defaultValue: 400,
164
+ table: {
165
+ defaultValue: {
166
+ summary: 400
167
+ }
168
+ },
169
+ type: {
170
+ required: false,
171
+ summary: "number"
172
+ }
173
+ },
174
+ labelOffset: {
175
+ control: {
176
+ type: "boolean"
177
+ },
178
+ defaultValue: false,
179
+ table: {
180
+ defaultValue: {
181
+ summary: false
182
+ }
183
+ },
184
+ type: {
185
+ required: false,
186
+ summary: "boolean"
187
+ }
188
+ },
189
+ labelRotation: {
190
+ control: {
191
+ type: "boolean"
192
+ },
193
+ defaultValue: false,
194
+ table: {
195
+ defaultValue: {
196
+ summary: false
197
+ }
198
+ },
199
+ type: {
200
+ required: false,
201
+ summary: "boolean"
202
+ }
203
+ },
204
+ labels: {
205
+ control: {
206
+ type: "array"
207
+ },
208
+ table: {
209
+ defaultValue: {
210
+ summary: "undefined"
211
+ }
212
+ },
213
+ type: {
214
+ required: false,
215
+ summary: "array"
216
+ }
217
+ },
218
+ maxSize: {
219
+ control: {
220
+ type: "number"
221
+ },
222
+ table: {
223
+ defaultValue: {
224
+ summary: "undefined"
225
+ }
226
+ },
227
+ type: {
228
+ required: true,
229
+ summary: "number"
230
+ }
231
+ },
232
+ minSize: {
233
+ control: {
234
+ type: "number"
235
+ },
236
+ table: {
237
+ defaultValue: {
238
+ summary: "undefined"
239
+ }
240
+ },
241
+ type: {
242
+ required: true,
243
+ summary: "number"
244
+ }
245
+ },
246
+ orient: {
247
+ control: {
248
+ type: "text"
249
+ },
250
+ defaultValue: "bottom",
251
+ description: "Supports `\"top\"`, `\"right\"`, `\"bottom\"`, and `\"left\"` orientations.",
252
+ table: {
253
+ defaultValue: {
254
+ summary: "bottom"
255
+ }
256
+ },
257
+ type: {
258
+ required: false,
259
+ summary: "string"
260
+ }
261
+ },
262
+ padding: {
263
+ control: {
264
+ type: "number"
265
+ },
266
+ defaultValue: 5,
267
+ table: {
268
+ defaultValue: {
269
+ summary: 5
270
+ }
271
+ },
272
+ type: {
273
+ required: false,
274
+ summary: "number"
275
+ }
276
+ },
277
+ paddingInner: {
278
+ control: {
279
+ type: "number"
280
+ },
281
+ defaultValue: 0.1,
282
+ table: {
283
+ defaultValue: {
284
+ summary: 0.1
285
+ }
286
+ },
287
+ type: {
288
+ required: false,
289
+ summary: "number"
290
+ }
291
+ },
292
+ paddingOuter: {
293
+ control: {
294
+ type: "number"
295
+ },
296
+ defaultValue: 0.1,
297
+ table: {
298
+ defaultValue: {
299
+ summary: 0.1
300
+ }
301
+ },
302
+ type: {
303
+ required: false,
304
+ summary: "number"
305
+ }
306
+ },
307
+ range: {
308
+ control: {
309
+ type: "array"
310
+ },
311
+ table: {
312
+ defaultValue: {
313
+ summary: "undefined"
314
+ }
315
+ },
316
+ type: {
317
+ required: false,
318
+ summary: "array"
319
+ }
320
+ },
321
+ render: {
322
+ control: {},
323
+ table: {
324
+ defaultValue: {
325
+ summary: "undefined"
326
+ }
327
+ },
328
+ type: {
329
+ required: false,
330
+ summary: "function"
331
+ }
332
+ },
333
+ rounding: {
334
+ control: {
335
+ type: "text"
336
+ },
337
+ defaultValue: "none",
338
+ table: {
339
+ defaultValue: {
340
+ summary: "none"
341
+ }
342
+ },
343
+ type: {
344
+ required: false,
345
+ summary: "string"
346
+ }
347
+ },
348
+ roundingInsideMaxPrefix: {
349
+ control: {
350
+ type: "text"
351
+ },
352
+ defaultValue: "",
353
+ table: {
354
+ defaultValue: {
355
+ summary: ""
356
+ }
357
+ },
358
+ type: {
359
+ required: false,
360
+ summary: "string"
361
+ }
362
+ },
363
+ roundingInsideMaxSuffix: {
364
+ control: {
365
+ type: "text"
366
+ },
367
+ defaultValue: "+",
368
+ table: {
369
+ defaultValue: {
370
+ summary: "+"
371
+ }
372
+ },
373
+ type: {
374
+ required: false,
375
+ summary: "string"
376
+ }
377
+ },
378
+ roundingInsideMinPrefix: {
379
+ control: {
380
+ type: "text"
381
+ },
382
+ defaultValue: "< ",
383
+ table: {
384
+ defaultValue: {
385
+ summary: "< "
386
+ }
387
+ },
388
+ type: {
389
+ required: false,
390
+ summary: "string"
391
+ }
392
+ },
393
+ roundingInsideMinSuffix: {
394
+ control: {
395
+ type: "text"
396
+ },
397
+ defaultValue: "",
398
+ table: {
399
+ defaultValue: {
400
+ summary: ""
401
+ }
402
+ },
403
+ type: {
404
+ required: false,
405
+ summary: "string"
406
+ }
407
+ },
408
+ scale: {
409
+ control: {
410
+ type: "text"
411
+ },
412
+ defaultValue: "linear",
413
+ table: {
414
+ defaultValue: {
415
+ summary: "linear"
416
+ }
417
+ },
418
+ type: {
419
+ required: false,
420
+ summary: "string"
421
+ }
422
+ },
423
+ scalePadding: {
424
+ control: {
425
+ type: "number"
426
+ },
427
+ defaultValue: 0.5,
428
+ table: {
429
+ defaultValue: {
430
+ summary: 0.5
431
+ }
432
+ },
433
+ type: {
434
+ required: false,
435
+ summary: "number"
436
+ }
437
+ },
438
+ select: {
439
+ control: {
440
+ type: "text"
441
+ },
442
+ defaultValue: "d3.select(\"body\").append(\"svg\")",
443
+ table: {
444
+ defaultValue: {
445
+ summary: "d3.select(\"body\").append(\"svg\")"
446
+ }
447
+ },
448
+ type: {
449
+ required: false,
450
+ summary: "string | htmlelement"
451
+ }
452
+ },
453
+ shape: {
454
+ control: {
455
+ type: "text"
456
+ },
457
+ defaultValue: "Line",
458
+ table: {
459
+ defaultValue: {
460
+ summary: "Line"
461
+ }
462
+ },
463
+ type: {
464
+ required: false,
465
+ summary: "string"
466
+ }
467
+ },
468
+ shapeConfig: {
469
+ control: {
470
+ type: "object"
471
+ },
472
+ defaultValue: "{fill: openColor.colors.gray.600, height: (d) => d.tick ? 8 : 0, label: (d) => d.text, labelBounds: (d) => d.labelBounds, labelConfig: {fontColor: openColor.colors.gray.600, fontResize: false, fontSize: 12, padding: 5, textAnchor: () => {\n const rtl = detectRTL(this._select.node());\n return this._orient === \"left\" ? rtl ? \"start\" : \"end\" : this._orient === \"right\" ? rtl ? \"end\" : \"start\" : this._labelRotation ? this._orient === \"bottom\" ? \"end\" : \"start\" : \"middle\";\n}, verticalAlign: () => this._orient === bottom ? top : this._orient === top ? bottom : middle}, r: (d) => d.tick ? 4 : 0, stroke: openColor.colors.gray.600, strokeWidth: 1, width: (d) => d.tick ? 8 : 0}",
473
+ table: {
474
+ defaultValue: {
475
+ detail: "{fill: openColor.colors.gray.600, height: (d) => d.tick ? 8 : 0, label: (d) => d.text, labelBounds: (d) => d.labelBounds, labelConfig: {fontColor: openColor.colors.gray.600, fontResize: false, fontSize: 12, padding: 5, textAnchor: () => {\n const rtl = detectRTL(this._select.node());\n return this._orient === \"left\" ? rtl ? \"start\" : \"end\" : this._orient === \"right\" ? rtl ? \"end\" : \"start\" : this._labelRotation ? this._orient === \"bottom\" ? \"end\" : \"start\" : \"middle\";\n}, verticalAlign: () => this._orient === bottom ? top : this._orient === top ? bottom : middle}, r: (d) => d.tick ? 4 : 0, stroke: openColor.colors.gray.600, strokeWidth: 1, width: (d) => d.tick ? 8 : 0}",
476
+ summary: "function"
477
+ }
478
+ },
479
+ type: {
480
+ required: false,
481
+ summary: "object"
482
+ }
483
+ },
484
+ tickFormat: {
485
+ control: {},
486
+ table: {
487
+ defaultValue: {
488
+ summary: "undefined"
489
+ }
490
+ },
491
+ type: {
492
+ required: false,
493
+ summary: "function"
494
+ }
495
+ },
496
+ tickSize: {
497
+ control: {
498
+ type: "number"
499
+ },
500
+ defaultValue: 8,
501
+ table: {
502
+ defaultValue: {
503
+ summary: 8
504
+ }
505
+ },
506
+ type: {
507
+ required: false,
508
+ summary: "number"
509
+ }
510
+ },
511
+ tickSuffix: {
512
+ control: {
513
+ type: "text"
514
+ },
515
+ defaultValue: "normal",
516
+ table: {
517
+ defaultValue: {
518
+ summary: "normal"
519
+ }
520
+ },
521
+ type: {
522
+ required: false,
523
+ summary: "string"
524
+ }
525
+ },
526
+ ticks: {
527
+ control: {
528
+ type: "array"
529
+ },
530
+ table: {
531
+ defaultValue: {
532
+ summary: "undefined"
533
+ }
534
+ },
535
+ type: {
536
+ required: false,
537
+ summary: "array"
538
+ }
539
+ },
540
+ timeLocale: {
541
+ control: {
542
+ type: "object"
543
+ },
544
+ defaultValue: "undefined",
545
+ table: {
546
+ defaultValue: {
547
+ summary: "undefined"
548
+ }
549
+ },
550
+ type: {
551
+ required: false,
552
+ summary: "object"
553
+ }
554
+ },
555
+ title: {
556
+ control: {
557
+ type: "text"
558
+ },
559
+ table: {
560
+ defaultValue: {
561
+ summary: "undefined"
562
+ }
563
+ },
564
+ type: {
565
+ required: false,
566
+ summary: "string"
567
+ }
568
+ },
569
+ titleConfig: {
570
+ control: {
571
+ type: "object"
572
+ },
573
+ defaultValue: "{fontColor: colorDefaults.dark, fontSize: 12, textAnchor: middle}",
574
+ table: {
575
+ defaultValue: {
576
+ summary: "{fontColor: colorDefaults.dark, fontSize: 12, textAnchor: middle}"
577
+ }
578
+ },
579
+ type: {
580
+ required: false,
581
+ summary: "object"
582
+ }
583
+ },
584
+ width: {
585
+ control: {
586
+ type: "number"
587
+ },
588
+ defaultValue: 400,
589
+ table: {
590
+ defaultValue: {
591
+ summary: 400
592
+ }
593
+ },
594
+ type: {
595
+ required: false,
596
+ summary: "number"
597
+ }
598
+ }
599
+ }
600
+ );
@@ -0,0 +1,42 @@
1
+ // WARNING: do not edit this file directly, it is generated dynamically from
2
+ // the source JSDOC comments using the npm run docs script.
3
+
4
+ import React from "react";
5
+ import {argTypes as axisArgTypes} from "./Axis.args.jsx";
6
+ import {assign} from "@d3plus/dom";
7
+
8
+ import {AxisBottom as D3plusAxisBottom} from "@d3plus/react";
9
+ export const AxisBottom = ({ config }) => <D3plusAxisBottom config={config} />;
10
+
11
+ export const argTypes = assign(
12
+
13
+ /**
14
+ * Filters out unused argTypes from the Axis primitive and
15
+ * overrides any defaults that have been changed in AxisBottom
16
+ */
17
+ Object.keys(axisArgTypes)
18
+ .reduce((obj, k) => (obj[k] = axisArgTypes[k], obj), {}),
19
+
20
+ /**
21
+ * AxisBottom-specific methods
22
+ */
23
+
24
+ {
25
+ orient: {
26
+ control: {
27
+ type: "text"
28
+ },
29
+ defaultValue: "bottom",
30
+ description: "Supports `\"top\"`, `\"right\"`, `\"bottom\"`, and `\"left\"` orientations.",
31
+ table: {
32
+ defaultValue: {
33
+ summary: "bottom"
34
+ }
35
+ },
36
+ type: {
37
+ required: false,
38
+ summary: "string"
39
+ }
40
+ }
41
+ }
42
+ );
@@ -0,0 +1,42 @@
1
+ // WARNING: do not edit this file directly, it is generated dynamically from
2
+ // the source JSDOC comments using the npm run docs script.
3
+
4
+ import React from "react";
5
+ import {argTypes as axisArgTypes} from "./Axis.args.jsx";
6
+ import {assign} from "@d3plus/dom";
7
+
8
+ import {AxisLeft as D3plusAxisLeft} from "@d3plus/react";
9
+ export const AxisLeft = ({ config }) => <D3plusAxisLeft config={config} />;
10
+
11
+ export const argTypes = assign(
12
+
13
+ /**
14
+ * Filters out unused argTypes from the Axis primitive and
15
+ * overrides any defaults that have been changed in AxisLeft
16
+ */
17
+ Object.keys(axisArgTypes)
18
+ .reduce((obj, k) => (obj[k] = axisArgTypes[k], obj), {}),
19
+
20
+ /**
21
+ * AxisLeft-specific methods
22
+ */
23
+
24
+ {
25
+ orient: {
26
+ control: {
27
+ type: "text"
28
+ },
29
+ defaultValue: "left",
30
+ description: "Supports `\"top\"`, `\"right\"`, `\"bottom\"`, and `\"left\"` orientations.",
31
+ table: {
32
+ defaultValue: {
33
+ summary: "left"
34
+ }
35
+ },
36
+ type: {
37
+ required: false,
38
+ summary: "string"
39
+ }
40
+ }
41
+ }
42
+ );
@@ -0,0 +1,42 @@
1
+ // WARNING: do not edit this file directly, it is generated dynamically from
2
+ // the source JSDOC comments using the npm run docs script.
3
+
4
+ import React from "react";
5
+ import {argTypes as axisArgTypes} from "./Axis.args.jsx";
6
+ import {assign} from "@d3plus/dom";
7
+
8
+ import {AxisRight as D3plusAxisRight} from "@d3plus/react";
9
+ export const AxisRight = ({ config }) => <D3plusAxisRight config={config} />;
10
+
11
+ export const argTypes = assign(
12
+
13
+ /**
14
+ * Filters out unused argTypes from the Axis primitive and
15
+ * overrides any defaults that have been changed in AxisRight
16
+ */
17
+ Object.keys(axisArgTypes)
18
+ .reduce((obj, k) => (obj[k] = axisArgTypes[k], obj), {}),
19
+
20
+ /**
21
+ * AxisRight-specific methods
22
+ */
23
+
24
+ {
25
+ orient: {
26
+ control: {
27
+ type: "text"
28
+ },
29
+ defaultValue: "right",
30
+ description: "Supports `\"top\"`, `\"right\"`, `\"bottom\"`, and `\"left\"` orientations.",
31
+ table: {
32
+ defaultValue: {
33
+ summary: "right"
34
+ }
35
+ },
36
+ type: {
37
+ required: false,
38
+ summary: "string"
39
+ }
40
+ }
41
+ }
42
+ );