@nebula.js/sn-distributionplot 0.40.7 → 1.0.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/README.md CHANGED
@@ -14,8 +14,6 @@ If you use pnpm: `pnpm install @nebula.js/sn-distributionplot`. You can also loa
14
14
 
15
15
  In a distribution plot you need to use one or two dimensions, and one measure. If you use a single dimension you will receive a single line visualization. If you use two dimensions, you will get one line for each value of the second, or outer, dimension.
16
16
 
17
- <!--![image info](./assets/sn-distributionplot-chart.png)-->
18
-
19
17
  ```js
20
18
  import { embed } from '@nebula.js/stardust';
21
19
  import distributionplot from '@nebula.js/sn-distributionplot';
@@ -44,8 +42,6 @@ embeddable.render({
44
42
 
45
43
  Setting `orientation` property value to `vertical`. Default value is `horizontal`.
46
44
 
47
- <!--![image info](./assets/sn-distributionplot-chart-vertical.png)-->
48
-
49
45
  ```js
50
46
  embeddable.render({
51
47
  element,
@@ -64,8 +60,6 @@ embeddable.render({
64
60
 
65
61
  Displays value points only.
66
62
 
67
- <!--![image info](./assets/sn-distributionplot-chart-only-points.png)-->
68
-
69
63
  ```js
70
64
  embeddable.render({
71
65
  element,
@@ -84,8 +78,6 @@ embeddable.render({
84
78
 
85
79
  Displays a bounding box showing the range of the values only.
86
80
 
87
- <!--![image info](./assets/sn-distributionplot-chart-only-bg.png)-->
88
-
89
81
  ```js
90
82
  embeddable.render({
91
83
  element,
@@ -106,8 +98,6 @@ You can adjust the size of the bubbles that illustrate the value points by setti
106
98
 
107
99
  You can set `displacement` to `jitter` to jitter several overlapping value points. This moves some of the points slightly to create a larger footprint that shows that there are more than one value behind the point.
108
100
 
109
- <!--![image info](./assets/sn-distributionplot-chart-size-jitter.png)-->
110
-
111
101
  ```js
112
102
  embeddable.render({
113
103
  element,
@@ -341,45 +341,3 @@ Visualization footnote.
341
341
  **Default**: <code>&quot;&quot;</code>
342
342
 
343
343
  # Definitions
344
- <a name="paletteColor"></a>
345
-
346
- ## paletteColor : <code>object</code>
347
- Color information structure. Holds the actual color and index in palette.
348
-
349
- **Kind**: global typedef
350
- **Properties**
351
-
352
- | Name | Type | Description |
353
- | --- | --- | --- |
354
- | color | <code>string</code> | Color as hex string (mandatory if index: -1) |
355
- | index | <code>number</code> | Index in palette |
356
-
357
- <a name="refLineStyle"></a>
358
-
359
- ## refLineStyle : <code>object</code>
360
- Styling settings for reference line
361
-
362
- **Kind**: global typedef
363
- **Properties**
364
-
365
- | Name | Type | Default | Description |
366
- | --- | --- | --- | --- |
367
- | [lineThickness] | <code>number</code> | <code>2</code> | Set the thickness for this reference line. |
368
- | [lineType] | <code>string</code> | <code>&quot;&#x27;&#x27;&quot;</code> | Set the dash type for this reference line. |
369
-
370
- <a name="refLine"></a>
371
-
372
- ## refLine : <code>object</code>
373
- **Kind**: global typedef
374
- **Properties**
375
-
376
- | Name | Type | Default | Description |
377
- | --- | --- | --- | --- |
378
- | show | <code>boolean</code> \| <code>ValueExpression</code> | <code>true</code> | Set to true to display this reference line. |
379
- | label | <code>string</code> | | Reference line label. |
380
- | [showLabel] | <code>boolean</code> | <code>true</code> | Set to true to show the label of this reference line. |
381
- | [showValue] | <code>boolean</code> | <code>true</code> | Set to true to show the value of this reference line. |
382
- | paletteColor | [<code>paletteColor</code>](#paletteColor) | | |
383
- | [style] | [<code>refLineStyle</code>](#refLineStyle) | | Styling settings for reference line |
384
- | [coloredBackground] | <code>boolean</code> | <code>false</code> | Set to true to fill the label and/or value of this reference line with this color |
385
-
@@ -1,9 +1,9 @@
1
1
  {
2
- "scriptappy": "1.0.0",
2
+ "scriptappy": "1.1.0",
3
3
  "info": {
4
4
  "name": "@nebula.js/sn-distributionplot:properties",
5
5
  "description": "Distributionplot generic object definition",
6
- "version": "0.40.7",
6
+ "version": "0.40.8",
7
7
  "license": "MIT",
8
8
  "stability": "experimental",
9
9
  "x-qlik-visibility": "private"
@@ -14,17 +14,16 @@
14
14
  "entries": {
15
15
  "color": {
16
16
  "description": "Color settings.\nMost color options for visualizations are set in the color object in the options. You activate custom coloring by setting `\"auto\": false` which turns off auto-coloring.\nIf `\"auto\": true`, no other properties need to be defined in the color object.\nNote: Some of the color properties are depending on which theme is currently being used.",
17
- "kind": "object",
18
17
  "entries": {
19
18
  "box": {
20
- "kind": "object",
21
19
  "entries": {
22
20
  "paletteColor": {
23
21
  "description": "The paletteColor object is used to define the box color when you color by single color `(\"mode\": \"primary\")`.",
24
22
  "defaultValue": "{ index: -1, color: '#e6e6e6' }",
25
23
  "type": "#/definitions/paletteColor"
26
24
  }
27
- }
25
+ },
26
+ "kind": "object"
28
27
  },
29
28
  "expressionLabel": {
30
29
  "description": "Label to be defined on tool tips when using a coloring expression.\nOnly used if `'expressionIsColor': false`.",
@@ -32,7 +31,6 @@
32
31
  "type": "string"
33
32
  },
34
33
  "point": {
35
- "kind": "object",
36
34
  "entries": {
37
35
  "auto": {
38
36
  "description": "Set to use automatic coloring.\nWhen `\"auto\": true`, color settings are based on the visualization used and the number of dimensions\nand measures, that is, the settings are not fixed, but are dependent on the data input.",
@@ -41,9 +39,8 @@
41
39
  },
42
40
  "expressionIsColor": {
43
41
  "description": "Should be true",
44
- "defaultValue": true,
45
- "kind": "literal",
46
- "value": "true"
42
+ "value": "true",
43
+ "kind": "literal"
47
44
  },
48
45
  "mode": {
49
46
  "description": "Sets the coloring mode for the visualization when auto-coloring has been switched off (`\"auto\": false`). Can be one of:\n* `primary`: a single color (by default blue) is used for all items in the chart. In visualizations that do not benefit from multiple colors (bar charts with one dimension and scatter plots), single color is the default setting.\n* `byExpression`: coloring is based on an expression, which in most cases is a color code. Details are set in the `\"expressionIsColor\"`, `\"expressionLabel`\" and `\"colorExpression\"` properties.\n* `byMultiple`: can be used when more than one measure is used. By default, 12 colors are used for the dimensions. The colors are reused when there are more than 12 dimension values.",
@@ -62,8 +59,7 @@
62
59
  "kind": "literal",
63
60
  "value": "'byMultiple'"
64
61
  }
65
- ],
66
- "type": "string"
62
+ ]
67
63
  },
68
64
  "useBaseColors": {
69
65
  "description": "Use colors encoded in master items.\nOnly applicable when `\"mode\": \"primary\"` has been defined.",
@@ -82,16 +78,16 @@
82
78
  "kind": "literal",
83
79
  "value": "'measure'"
84
80
  }
85
- ],
86
- "type": "string"
81
+ ]
87
82
  }
88
- }
83
+ },
84
+ "kind": "object"
89
85
  }
90
- }
86
+ },
87
+ "kind": "object"
91
88
  },
92
89
  "dimensionAxis": {
93
90
  "description": "Dimension axis settings.",
94
- "kind": "object",
95
91
  "entries": {
96
92
  "dock": {
97
93
  "description": "Axis docking position",
@@ -106,14 +102,12 @@
106
102
  "kind": "literal",
107
103
  "value": "'far'"
108
104
  }
109
- ],
110
- "type": "string"
105
+ ]
111
106
  },
112
107
  "label": {
113
108
  "description": "Label orientation",
114
- "defaultValue": "auto",
115
- "kind": "literal",
116
- "value": "'auto'"
109
+ "value": "'auto'",
110
+ "kind": "literal"
117
111
  },
118
112
  "show": {
119
113
  "description": "Labels and title",
@@ -136,10 +130,10 @@
136
130
  "kind": "literal",
137
131
  "value": "'none'"
138
132
  }
139
- ],
140
- "type": "string"
133
+ ]
141
134
  }
142
- }
135
+ },
136
+ "kind": "object"
143
137
  },
144
138
  "footnote": {
145
139
  "description": "Visualization footnote.",
@@ -153,12 +147,10 @@
153
147
  {
154
148
  "type": "StringExpression"
155
149
  }
156
- ],
157
- "type": "any"
150
+ ]
158
151
  },
159
152
  "gridlines": {
160
153
  "description": "Grid lines settings.",
161
- "kind": "object",
162
154
  "entries": {
163
155
  "auto": {
164
156
  "description": "Automatic grid line spacing.",
@@ -182,14 +174,13 @@
182
174
  "kind": "literal",
183
175
  "value": 3
184
176
  }
185
- ],
186
- "type": "number"
177
+ ]
187
178
  }
188
- }
179
+ },
180
+ "kind": "object"
189
181
  },
190
182
  "measureAxis": {
191
183
  "description": "Measure axis settings.",
192
- "kind": "object",
193
184
  "entries": {
194
185
  "autoMinMax": {
195
186
  "description": "Automatic max/min",
@@ -209,8 +200,7 @@
209
200
  "kind": "literal",
210
201
  "value": "'far'"
211
202
  }
212
- ],
213
- "type": "string"
203
+ ]
214
204
  },
215
205
  "max": {
216
206
  "description": "Axis max value. `\"autoMinMax\"` must be set to false and `\"minMax\"`\nmust be set to `\"max\"` or `\"minMax\"` to use this property",
@@ -223,8 +213,7 @@
223
213
  {
224
214
  "type": "ValueExpression"
225
215
  }
226
- ],
227
- "type": "any"
216
+ ]
228
217
  },
229
218
  "min": {
230
219
  "description": "Axis min value. `\"autoMinMax\"` must be set to false and `\"minMax\"`\nmust be set to `\"min\"` or `\"minMax\"` to use this property",
@@ -237,8 +226,7 @@
237
226
  {
238
227
  "type": "ValueExpression"
239
228
  }
240
- ],
241
- "type": "any"
229
+ ]
242
230
  },
243
231
  "minMax": {
244
232
  "description": "Set custom max/min",
@@ -257,8 +245,7 @@
257
245
  "kind": "literal",
258
246
  "value": "'minMax'"
259
247
  }
260
- ],
261
- "type": "string"
248
+ ]
262
249
  },
263
250
  "show": {
264
251
  "description": "Labels and title",
@@ -281,15 +268,15 @@
281
268
  "kind": "literal",
282
269
  "value": "'none'"
283
270
  }
284
- ],
285
- "type": "string"
271
+ ]
286
272
  },
287
273
  "spacing": {
288
274
  "description": "Axis scale",
289
275
  "defaultValue": 1,
290
276
  "type": "number"
291
277
  }
292
- }
278
+ },
279
+ "kind": "object"
293
280
  },
294
281
  "orientation": {
295
282
  "description": "Orientation setting.\nIf vertical, the dimension axis can only be docked on bottom or top and measure axis on left or right.",
@@ -304,12 +291,10 @@
304
291
  "kind": "literal",
305
292
  "value": "'horizontal'"
306
293
  }
307
- ],
308
- "type": "string"
294
+ ]
309
295
  },
310
296
  "presentation": {
311
297
  "description": "Presentation settings for the distributionplot",
312
- "kind": "object",
313
298
  "entries": {
314
299
  "visibleComponents": {
315
300
  "description": "Visible components of the distributionplot",
@@ -328,10 +313,10 @@
328
313
  "kind": "literal",
329
314
  "value": "'box'"
330
315
  }
331
- ],
332
- "type": "string"
316
+ ]
333
317
  }
334
- }
318
+ },
319
+ "kind": "object"
335
320
  },
336
321
  "qHyperCubeDef": {
337
322
  "description": "Extends `HyperCubeDef`, see Engine API: `HyperCubeDef`.",
@@ -340,12 +325,10 @@
340
325
  "type": "HyperCubeDef"
341
326
  }
342
327
  ],
343
- "kind": "object",
344
- "entries": {}
328
+ "kind": "object"
345
329
  },
346
330
  "refLine": {
347
331
  "description": "Reference lines settings",
348
- "kind": "object",
349
332
  "entries": {
350
333
  "refLines": {
351
334
  "description": "Array of measure based reference line definitions",
@@ -354,7 +337,8 @@
354
337
  "type": "#/definitions/refLine"
355
338
  }
356
339
  }
357
- }
340
+ },
341
+ "kind": "object"
358
342
  },
359
343
  "showTitles": {
360
344
  "description": "Show title for the visualization.",
@@ -384,8 +368,7 @@
384
368
  "kind": "literal",
385
369
  "value": "'distplot-exp-max'"
386
370
  }
387
- ],
388
- "type": "string"
371
+ ]
389
372
  },
390
373
  "expression": {
391
374
  "description": "Expression for the sorting. Requires sortByExpression to be -1 or 1.",
@@ -430,8 +413,7 @@
430
413
  {
431
414
  "type": "StringExpression"
432
415
  }
433
- ],
434
- "type": "any"
416
+ ]
435
417
  },
436
418
  "title": {
437
419
  "description": "Visualization title.",
@@ -445,8 +427,7 @@
445
427
  {
446
428
  "type": "StringExpression"
447
429
  }
448
- ],
449
- "type": "any"
430
+ ]
450
431
  },
451
432
  "version": {
452
433
  "description": "Current version of this generic object definition.",
@@ -488,12 +469,18 @@
488
469
  "kind": "literal",
489
470
  "value": "'jitter'"
490
471
  }
491
- ],
492
- "type": "string"
472
+ ]
493
473
  },
494
474
  "refLine": {
495
475
  "kind": "object",
496
476
  "entries": {
477
+ "label": {
478
+ "description": "Reference line label.",
479
+ "type": "string"
480
+ },
481
+ "paletteColor": {
482
+ "type": "#/definitions/paletteColor"
483
+ },
497
484
  "show": {
498
485
  "description": "Set to true to display this reference line.",
499
486
  "defaultValue": true,
@@ -505,12 +492,13 @@
505
492
  {
506
493
  "type": "ValueExpression"
507
494
  }
508
- ],
509
- "type": "any"
495
+ ]
510
496
  },
511
- "label": {
512
- "description": "Reference line label.",
513
- "type": "string"
497
+ "coloredBackground": {
498
+ "description": "Set to true to fill the label and/or value of this reference line with this color",
499
+ "optional": true,
500
+ "defaultValue": false,
501
+ "type": "boolean"
514
502
  },
515
503
  "showLabel": {
516
504
  "description": "Set to true to show the label of this reference line.",
@@ -524,19 +512,10 @@
524
512
  "defaultValue": true,
525
513
  "type": "boolean"
526
514
  },
527
- "paletteColor": {
528
- "type": "#/definitions/paletteColor"
529
- },
530
515
  "style": {
531
516
  "description": "Styling settings for reference line",
532
517
  "optional": true,
533
518
  "type": "#/definitions/refLineStyle"
534
- },
535
- "coloredBackground": {
536
- "description": "Set to true to fill the label and/or value of this reference line with this color",
537
- "optional": true,
538
- "defaultValue": false,
539
- "type": "boolean"
540
519
  }
541
520
  }
542
521
  },