@nebula.js/sn-waterfall 0.36.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
@@ -22,8 +22,6 @@ You can use the Measure operation option (`Add/Subtract/Subtotals`) of each meas
22
22
 
23
23
  - Subtotals. The measure value is considered a subtotal. Setting `valueType` to `SUBTOTAL`.
24
24
 
25
- <!--![image info](./assets/sn-waterfall-chart.png)-->
26
-
27
25
  ```js
28
26
  import { embed } from '@nebula.js/stardust';
29
27
  import waterfall from '@nebula.js/sn-waterfall';
@@ -87,8 +85,6 @@ embeddable.render({
87
85
 
88
86
  You can set the presentation color for the different measure operations: Positive value color, Negative value color or Subtotal color
89
87
 
90
- <!--![image info](./assets/sn-waterfall-chart-colors.png)-->
91
-
92
88
  ```js
93
89
  embeddable.render({
94
90
  element,
@@ -145,7 +141,7 @@ embeddable.render({
145
141
  subtotal: {
146
142
  paletteColor: {
147
143
  index: -1,
148
- color: '#7b7a78',
144
+ color: '#7b7a77',
149
145
  },
150
146
  },
151
147
  },
@@ -328,102 +328,3 @@ Visualization footnote.
328
328
  **Default**: <code>&quot;&quot;</code>
329
329
 
330
330
  # Definitions
331
- <a name="subtotalProperties"></a>
332
-
333
- ## subtotalProperties : <code>object</code>
334
- Settings for subtotal
335
-
336
- **Kind**: global typedef
337
- **Properties**
338
-
339
- | Name | Type | Default | Description |
340
- | --- | --- | --- | --- |
341
- | enable | <code>boolean</code> | <code>false</code> | Option to add a subtotal after a measure. |
342
- | label | <code>string</code> | <code>&quot;&#x27;Subtotal&#x27;&quot;</code> | Label of the subtotal added after a measure. |
343
-
344
- <a name="InlineMeasureDef"></a>
345
-
346
- ## InlineMeasureDef : <code>object</code>
347
- Extends `NxInlineMeasureDef`, see Engine API: `NxInlineMeasureDef`.
348
-
349
- **Kind**: global typedef
350
- **Extends**: <code>NxInlineMeasureDef</code>
351
- **Properties**
352
-
353
- | Name | Type | Default | Description |
354
- | --- | --- | --- | --- |
355
- | subtotal | [<code>subtotalProperties</code>](#subtotalProperties) | | subtotal settings. |
356
- | valueType | <code>&#x27;NORMAL&#x27;</code> \| <code>&#x27;INVERSE&#x27;</code> \| <code>&#x27;SUBTOTAL&#x27;</code> | <code>&#x27;NORMAL&#x27;</code> | Measure operation. |
357
-
358
- <a name="MeasureProperties"></a>
359
-
360
- ## MeasureProperties : <code>object</code>
361
- Extends `NxMeasure`, see Engine API: `NxMeasure`.
362
-
363
- **Kind**: global typedef
364
- **Extends**: <code>NxMeasure</code>
365
- **Properties**
366
-
367
- | Name | Type |
368
- | --- | --- |
369
- | qDef | [<code>InlineMeasureDef</code>](#InlineMeasureDef) |
370
-
371
- <a name="FieldAttributes"></a>
372
-
373
- ## FieldAttributes : <code>object</code>
374
- Field attributes structure.
375
-
376
- **Kind**: global typedef
377
- **Properties**
378
-
379
- | Name | Type | Description |
380
- | --- | --- | --- |
381
- | dec | <code>string</code> | Defines the decimal separator. |
382
- | Fmt | <code>string</code> | Defines the format pattern that applies to qText. |
383
- | nDec | <code>number</code> | Number of decimals. |
384
- | Thou | <code>string</code> | Defines the thousand separator (if any). |
385
- | Type | <code>string</code> | Type of the field. |
386
- | UseThou | <code>number</code> | Defines whether or not a thousands separator must be used. |
387
-
388
- <a name="paletteColor"></a>
389
-
390
- ## paletteColor : <code>object</code>
391
- Color information structure. Holds the actual color and index in palette.
392
-
393
- **Kind**: global typedef
394
- **Properties**
395
-
396
- | Name | Type | Description |
397
- | --- | --- | --- |
398
- | color | <code>string</code> | Color as hex string (mandatory if index: -1) |
399
- | index | <code>number</code> | Index in palette |
400
-
401
- <a name="refLineStyle"></a>
402
-
403
- ## refLineStyle : <code>object</code>
404
- Styling settings for reference line
405
-
406
- **Kind**: global typedef
407
- **Properties**
408
-
409
- | Name | Type | Default | Description |
410
- | --- | --- | --- | --- |
411
- | [lineThickness] | <code>number</code> | <code>2</code> | Set the thickness for this reference line. |
412
- | [lineType] | <code>string</code> | <code>&quot;&#x27;&#x27;&quot;</code> | Set the dash type for this reference line. |
413
-
414
- <a name="refLine"></a>
415
-
416
- ## refLine : <code>object</code>
417
- **Kind**: global typedef
418
- **Properties**
419
-
420
- | Name | Type | Default | Description |
421
- | --- | --- | --- | --- |
422
- | show | <code>boolean</code> \| <code>ValueExpression</code> | <code>true</code> | Set to true to display this reference line. |
423
- | label | <code>string</code> | | Reference line label. |
424
- | [showLabel] | <code>boolean</code> | <code>true</code> | Set to true to show the label of this reference line. |
425
- | [showValue] | <code>boolean</code> | <code>true</code> | Set to true to show the value of this reference line. |
426
- | paletteColor | [<code>paletteColor</code>](#paletteColor) | | |
427
- | [style] | [<code>refLineStyle</code>](#refLineStyle) | | Styling settings for reference line |
428
- | [coloredBackground] | <code>boolean</code> | <code>false</code> | Set to true to fill the label and/or value of this reference line with this color |
429
-
@@ -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-waterfall:properties",
5
5
  "description": "Waterfall chart generic object definition",
6
- "version": "0.36.7",
6
+ "version": "0.36.8",
7
7
  "license": "MIT",
8
8
  "stability": "experimental",
9
9
  "x-qlik-visibility": "private"
@@ -14,7 +14,6 @@
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
  "auto": {
20
19
  "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.",
@@ -23,53 +22,53 @@
23
22
  },
24
23
  "negativeValue": {
25
24
  "description": "Negative value color.",
26
- "kind": "object",
27
25
  "entries": {
28
26
  "paletteColor": {
29
27
  "description": "paletteColor",
30
28
  "defaultValue": "{ index: -1, color: '#cc6677' }",
31
29
  "type": "#/definitions/paletteColor"
32
30
  }
33
- }
31
+ },
32
+ "kind": "object"
34
33
  },
35
34
  "positiveValue": {
36
35
  "description": "Positive value color.",
37
- "kind": "object",
38
36
  "entries": {
39
37
  "paletteColor": {
40
38
  "description": "paletteColor",
41
39
  "defaultValue": "{ index: 6, color: null }",
42
40
  "type": "#/definitions/paletteColor"
43
41
  }
44
- }
42
+ },
43
+ "kind": "object"
45
44
  },
46
45
  "subtotal": {
47
46
  "description": "Subtotal value color.",
48
- "kind": "object",
49
47
  "entries": {
50
48
  "paletteColor": {
51
49
  "description": "paletteColor",
52
50
  "defaultValue": "{ index: -1, color: '#c3c3c3' }",
53
51
  "type": "#/definitions/paletteColor"
54
52
  }
55
- }
53
+ },
54
+ "kind": "object"
56
55
  }
57
- }
56
+ },
57
+ "kind": "object"
58
58
  },
59
59
  "dataPoint": {
60
60
  "description": "Data point.",
61
- "kind": "object",
62
61
  "entries": {
63
62
  "showLabels": {
64
63
  "description": "Show labels.",
65
64
  "defaultValue": true,
66
65
  "type": "boolean"
67
66
  }
68
- }
67
+ },
68
+ "kind": "object"
69
69
  },
70
70
  "dimensionAxis": {
71
71
  "description": "Dimension axis settings.",
72
- "kind": "object",
73
72
  "entries": {
74
73
  "dock": {
75
74
  "description": "Axis docking position",
@@ -84,8 +83,7 @@
84
83
  "kind": "literal",
85
84
  "value": "'far'"
86
85
  }
87
- ],
88
- "type": "string"
86
+ ]
89
87
  },
90
88
  "label": {
91
89
  "description": "Label orientation",
@@ -104,8 +102,7 @@
104
102
  "kind": "literal",
105
103
  "value": "'tilted'"
106
104
  }
107
- ],
108
- "type": "string"
105
+ ]
109
106
  },
110
107
  "show": {
111
108
  "description": "Labels and title",
@@ -120,10 +117,10 @@
120
117
  "kind": "literal",
121
118
  "value": "'none'"
122
119
  }
123
- ],
124
- "type": "string"
120
+ ]
125
121
  }
126
- }
122
+ },
123
+ "kind": "object"
127
124
  },
128
125
  "footnote": {
129
126
  "description": "Visualization footnote.",
@@ -137,12 +134,10 @@
137
134
  {
138
135
  "type": "StringExpression"
139
136
  }
140
- ],
141
- "type": "any"
137
+ ]
142
138
  },
143
139
  "gridlines": {
144
140
  "description": "Grid lines settings.",
145
- "kind": "object",
146
141
  "entries": {
147
142
  "auto": {
148
143
  "description": "Automatic grid line spacing.",
@@ -166,14 +161,13 @@
166
161
  "kind": "literal",
167
162
  "value": 3
168
163
  }
169
- ],
170
- "type": "number"
164
+ ]
171
165
  }
172
- }
166
+ },
167
+ "kind": "object"
173
168
  },
174
169
  "legend": {
175
170
  "description": "Legend settings.",
176
- "kind": "object",
177
171
  "entries": {
178
172
  "dock": {
179
173
  "description": "Sets the legend position.",
@@ -200,19 +194,18 @@
200
194
  "kind": "literal",
201
195
  "value": "'top'"
202
196
  }
203
- ],
204
- "type": "string"
197
+ ]
205
198
  },
206
199
  "show": {
207
200
  "description": "Set to show the legend.",
208
201
  "defaultValue": true,
209
202
  "type": "boolean"
210
203
  }
211
- }
204
+ },
205
+ "kind": "object"
212
206
  },
213
207
  "measureAxis": {
214
208
  "description": "Measure axis settings.",
215
- "kind": "object",
216
209
  "entries": {
217
210
  "autoMinMax": {
218
211
  "description": "Automatic max/min",
@@ -232,8 +225,7 @@
232
225
  "kind": "literal",
233
226
  "value": "'far'"
234
227
  }
235
- ],
236
- "type": "string"
228
+ ]
237
229
  },
238
230
  "max": {
239
231
  "description": "Axis max value. `\"autoMinMax\"` must be set to false and `\"minMax\"`\nmust be set to `\"max\"` or `\"minMax\"` to use this property",
@@ -246,8 +238,7 @@
246
238
  {
247
239
  "type": "ValueExpression"
248
240
  }
249
- ],
250
- "type": "any"
241
+ ]
251
242
  },
252
243
  "min": {
253
244
  "description": "Axis min value. `\"autoMinMax\"` must be set to false and `\"minMax\"`\nmust be set to `\"min\"` or `\"minMax\"` to use this property",
@@ -260,8 +251,7 @@
260
251
  {
261
252
  "type": "ValueExpression"
262
253
  }
263
- ],
264
- "type": "any"
254
+ ]
265
255
  },
266
256
  "minMax": {
267
257
  "description": "Set custom max/min",
@@ -280,8 +270,7 @@
280
270
  "kind": "literal",
281
271
  "value": "'minMax'"
282
272
  }
283
- ],
284
- "type": "string"
273
+ ]
285
274
  },
286
275
  "show": {
287
276
  "description": "Labels and title",
@@ -296,15 +285,15 @@
296
285
  "kind": "literal",
297
286
  "value": "'none'"
298
287
  }
299
- ],
300
- "type": "string"
288
+ ]
301
289
  },
302
290
  "spacing": {
303
291
  "description": "Axis scale",
304
292
  "defaultValue": 1,
305
293
  "type": "number"
306
294
  }
307
- }
295
+ },
296
+ "kind": "object"
308
297
  },
309
298
  "qHyperCubeDef": {
310
299
  "description": "Extends `HyperCubeDef`, see Engine API: `HyperCubeDef`.",
@@ -325,7 +314,6 @@
325
314
  },
326
315
  "refLine": {
327
316
  "description": "Reference lines settings",
328
- "kind": "object",
329
317
  "entries": {
330
318
  "refLines": {
331
319
  "description": "Array of measure based reference line definitions",
@@ -334,7 +322,8 @@
334
322
  "type": "#/definitions/refLine"
335
323
  }
336
324
  }
337
- }
325
+ },
326
+ "kind": "object"
338
327
  },
339
328
  "showTitles": {
340
329
  "description": "Show title for the visualization.",
@@ -354,8 +343,7 @@
354
343
  {
355
344
  "type": "StringExpression"
356
345
  }
357
- ],
358
- "type": "any"
346
+ ]
359
347
  },
360
348
  "title": {
361
349
  "description": "Visualization title.",
@@ -369,8 +357,7 @@
369
357
  {
370
358
  "type": "StringExpression"
371
359
  }
372
- ],
373
- "type": "any"
360
+ ]
374
361
  },
375
362
  "version": {
376
363
  "description": "Current version of this generic object definition.",
@@ -440,8 +427,7 @@
440
427
  "kind": "literal",
441
428
  "value": "'SUBTOTAL'"
442
429
  }
443
- ],
444
- "type": "string"
430
+ ]
445
431
  }
446
432
  }
447
433
  },
@@ -491,6 +477,13 @@
491
477
  "refLine": {
492
478
  "kind": "object",
493
479
  "entries": {
480
+ "label": {
481
+ "description": "Reference line label.",
482
+ "type": "string"
483
+ },
484
+ "paletteColor": {
485
+ "type": "#/definitions/paletteColor"
486
+ },
494
487
  "show": {
495
488
  "description": "Set to true to display this reference line.",
496
489
  "defaultValue": true,
@@ -502,12 +495,13 @@
502
495
  {
503
496
  "type": "ValueExpression"
504
497
  }
505
- ],
506
- "type": "any"
498
+ ]
507
499
  },
508
- "label": {
509
- "description": "Reference line label.",
510
- "type": "string"
500
+ "coloredBackground": {
501
+ "description": "Set to true to fill the label and/or value of this reference line with this color",
502
+ "optional": true,
503
+ "defaultValue": false,
504
+ "type": "boolean"
511
505
  },
512
506
  "showLabel": {
513
507
  "description": "Set to true to show the label of this reference line.",
@@ -521,19 +515,10 @@
521
515
  "defaultValue": true,
522
516
  "type": "boolean"
523
517
  },
524
- "paletteColor": {
525
- "type": "#/definitions/paletteColor"
526
- },
527
518
  "style": {
528
519
  "description": "Styling settings for reference line",
529
520
  "optional": true,
530
521
  "type": "#/definitions/refLineStyle"
531
- },
532
- "coloredBackground": {
533
- "description": "Set to true to fill the label and/or value of this reference line with this color",
534
- "optional": true,
535
- "defaultValue": false,
536
- "type": "boolean"
537
522
  }
538
523
  }
539
524
  },