@hpcc-js/layout 2.51.0 → 3.1.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/dist/index.js +581 -5128
- package/dist/index.js.map +7 -1
- package/package.json +34 -37
- package/src/AbsoluteSurface.ts +17 -8
- package/src/Accordion.ts +18 -8
- package/src/Border.ts +45 -26
- package/src/Cell.ts +18 -13
- package/src/ChartPanel.ts +10 -10
- package/src/Grid.ts +1 -1
- package/src/HorizontalList.ts +1 -1
- package/src/Layered.ts +7 -3
- package/src/Legend.ts +1 -1
- package/src/Popup.ts +23 -12
- package/src/Surface.ts +52 -5
- package/src/Tabbed.ts +19 -12
- package/src/Toolbar.ts +107 -82
- package/src/VerticalList.ts +1 -1
- package/src/__package__.ts +2 -2
- package/src/index.ts +19 -19
- package/types/AbsoluteSurface.d.ts +16 -29
- package/types/Accordion.d.ts +16 -29
- package/types/Border.d.ts +36 -69
- package/types/Border2.d.ts +0 -1
- package/types/Carousel.d.ts +0 -1
- package/types/Cell.d.ts +17 -39
- package/types/ChartPanel.d.ts +8 -9
- package/types/FlexGrid.d.ts +0 -1
- package/types/Grid.d.ts +1 -2
- package/types/HorizontalList.d.ts +1 -2
- package/types/Layered.d.ts +6 -9
- package/types/Legend.d.ts +1 -2
- package/types/Modal.d.ts +0 -1
- package/types/Popup.d.ts +21 -38
- package/types/Surface.d.ts +42 -75
- package/types/Tabbed.d.ts +15 -30
- package/types/Toolbar.d.ts +32 -5
- package/types/VerticalList.d.ts +1 -2
- package/types/__package__.d.ts +2 -3
- package/types/index.d.ts +19 -20
- package/dist/index.es6.js +0 -5104
- package/dist/index.es6.js.map +0 -1
- package/dist/index.min.js +0 -2
- package/dist/index.min.js.map +0 -1
- package/types/AbsoluteSurface.d.ts.map +0 -1
- package/types/Accordion.d.ts.map +0 -1
- package/types/Border.d.ts.map +0 -1
- package/types/Border2.d.ts.map +0 -1
- package/types/Carousel.d.ts.map +0 -1
- package/types/Cell.d.ts.map +0 -1
- package/types/ChartPanel.d.ts.map +0 -1
- package/types/FlexGrid.d.ts.map +0 -1
- package/types/Grid.d.ts.map +0 -1
- package/types/HorizontalList.d.ts.map +0 -1
- package/types/Layered.d.ts.map +0 -1
- package/types/Legend.d.ts.map +0 -1
- package/types/Modal.d.ts.map +0 -1
- package/types/Popup.d.ts.map +0 -1
- package/types/Surface.d.ts.map +0 -1
- package/types/Tabbed.d.ts.map +0 -1
- package/types/Toolbar.d.ts.map +0 -1
- package/types/VerticalList.d.ts.map +0 -1
- package/types/__package__.d.ts.map +0 -1
- package/types/index.d.ts.map +0 -1
- package/types-3.4/AbsoluteSurface.d.ts +0 -37
- package/types-3.4/Accordion.d.ts +0 -45
- package/types-3.4/Border.d.ts +0 -114
- package/types-3.4/Border2.d.ts +0 -102
- package/types-3.4/Carousel.d.ts +0 -21
- package/types-3.4/Cell.d.ts +0 -50
- package/types-3.4/ChartPanel.d.ts +0 -129
- package/types-3.4/FlexGrid.d.ts +0 -44
- package/types-3.4/Grid.d.ts +0 -93
- package/types-3.4/HorizontalList.d.ts +0 -9
- package/types-3.4/Layered.d.ts +0 -29
- package/types-3.4/Legend.d.ts +0 -78
- package/types-3.4/Modal.d.ts +0 -65
- package/types-3.4/Popup.d.ts +0 -49
- package/types-3.4/Surface.d.ts +0 -89
- package/types-3.4/Tabbed.d.ts +0 -46
- package/types-3.4/Toolbar.d.ts +0 -7
- package/types-3.4/VerticalList.d.ts +0 -9
- package/types-3.4/__package__.d.ts +0 -4
- package/types-3.4/index.d.ts +0 -20
package/package.json
CHANGED
|
@@ -1,58 +1,55 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hpcc-js/layout",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.1.1",
|
|
4
4
|
"description": "hpcc-js - Viz Layout",
|
|
5
|
-
"
|
|
6
|
-
"
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
"
|
|
12
|
-
"*": [
|
|
13
|
-
"types-3.4/index.d.ts"
|
|
14
|
-
]
|
|
15
|
-
}
|
|
5
|
+
"type": "module",
|
|
6
|
+
"exports": {
|
|
7
|
+
".": {
|
|
8
|
+
"types": "./types/index.d.ts",
|
|
9
|
+
"default": "./dist/index.js"
|
|
10
|
+
},
|
|
11
|
+
"./dist/*": "./dist/*"
|
|
16
12
|
},
|
|
13
|
+
"module": "./dist/index.js",
|
|
14
|
+
"browser": "./dist/index.js",
|
|
15
|
+
"types": "./types/index.d.ts",
|
|
17
16
|
"files": [
|
|
18
17
|
"dist/*",
|
|
19
|
-
"
|
|
20
|
-
"types
|
|
21
|
-
"src/*"
|
|
18
|
+
"src/*",
|
|
19
|
+
"types/*"
|
|
22
20
|
],
|
|
23
21
|
"scripts": {
|
|
24
|
-
"clean": "rimraf --glob lib* types dist *.tsbuildinfo",
|
|
25
|
-
"
|
|
26
|
-
"
|
|
27
|
-
"
|
|
28
|
-
"
|
|
29
|
-
"
|
|
30
|
-
"bundle-watch": "npm run bundle -- -w",
|
|
31
|
-
"minimize": "terser dist/index.js -c -m --source-map \"content='dist/index.js.map',url='index.min.js.map'\" -o dist/index.min.js",
|
|
32
|
-
"gen-legacy-types": "downlevel-dts ./types ./types-3.4",
|
|
33
|
-
"build": "npm run compile-es6 && npm run bundle",
|
|
34
|
-
"watch": "npm-run-all compile-es6 -p compile-es6-watch bundle-watch",
|
|
35
|
-
"stamp": "node ../../node_modules/@hpcc-js/bundle/src/stamp.js",
|
|
22
|
+
"clean": "rimraf --glob lib* types dist *.tsbuildinfo .turbo",
|
|
23
|
+
"bundle": "node esbuild.js",
|
|
24
|
+
"bundle-watch": "npm run bundle -- --development --watch",
|
|
25
|
+
"gen-types": "tsc --project tsconfig.json",
|
|
26
|
+
"gen-types-watch": "npm run gen-types -- --watch",
|
|
27
|
+
"build": "run-p gen-types bundle",
|
|
36
28
|
"lint": "eslint ./src",
|
|
29
|
+
"lint-fix": "eslint --fix src/**/*.ts",
|
|
37
30
|
"docs": "typedoc --options tdoptions.json .",
|
|
38
|
-
"
|
|
31
|
+
"test-browser": "vitest run --project browser",
|
|
32
|
+
"test": "vitest run",
|
|
33
|
+
"coverage": "vitest run --coverage",
|
|
34
|
+
"update": "npx --yes npm-check-updates -u -t minor",
|
|
35
|
+
"update-major": "npx --yes npm-check-updates -u"
|
|
39
36
|
},
|
|
40
37
|
"dependencies": {
|
|
41
|
-
"@hpcc-js/api": "^2.
|
|
42
|
-
"@hpcc-js/chart": "^2.
|
|
43
|
-
"@hpcc-js/common": "^2.
|
|
44
|
-
"@hpcc-js/dgrid2": "^
|
|
38
|
+
"@hpcc-js/api": "^3.2.0",
|
|
39
|
+
"@hpcc-js/chart": "^3.2.0",
|
|
40
|
+
"@hpcc-js/common": "^3.2.0",
|
|
41
|
+
"@hpcc-js/dgrid2": "^3.1.1",
|
|
42
|
+
"@hpcc-js/util": "^3.2.0"
|
|
45
43
|
},
|
|
46
44
|
"devDependencies": {
|
|
47
|
-
"@hpcc-js/
|
|
48
|
-
"@types/d3-transition": "1.3.
|
|
45
|
+
"@hpcc-js/esbuild-plugins": "^1.3.0",
|
|
46
|
+
"@types/d3-transition": "1.3.6",
|
|
49
47
|
"d3-drag": "^1",
|
|
50
48
|
"d3-selection": "^1",
|
|
51
49
|
"d3-shape": "^1",
|
|
52
50
|
"d3-svg-legend": "2.25.6",
|
|
53
51
|
"d3-transition": "^1",
|
|
54
|
-
"grid-list": "0.4.1"
|
|
55
|
-
"tslib": "2.7.0"
|
|
52
|
+
"grid-list": "0.4.1"
|
|
56
53
|
},
|
|
57
54
|
"repository": {
|
|
58
55
|
"type": "git",
|
|
@@ -65,5 +62,5 @@
|
|
|
65
62
|
"url": "https://github.com/hpcc-systems/Visualization/issues"
|
|
66
63
|
},
|
|
67
64
|
"homepage": "https://github.com/hpcc-systems/Visualization",
|
|
68
|
-
"gitHead": "
|
|
65
|
+
"gitHead": "b4f63e027feea45ebdfc578ef9c85d107bd97322"
|
|
69
66
|
}
|
package/src/AbsoluteSurface.ts
CHANGED
|
@@ -64,17 +64,26 @@ export class AbsoluteSurface extends HTMLWidget {
|
|
|
64
64
|
}
|
|
65
65
|
super.exit(domNode, element);
|
|
66
66
|
}
|
|
67
|
-
|
|
68
|
-
units: { (): string; (_: string): AbsoluteSurface; };
|
|
69
|
-
widgetX: { (): number; (_: number): AbsoluteSurface; };
|
|
70
|
-
widgetY: { (): number; (_: number): AbsoluteSurface; };
|
|
71
|
-
widgetWidth: { (): string; (_: string): AbsoluteSurface; };
|
|
72
|
-
widgetHeight: { (): string; (_: string): AbsoluteSurface; };
|
|
73
|
-
widget: { (): any; (_: any): AbsoluteSurface; };
|
|
74
|
-
opacity: { (): number; (_: number): AbsoluteSurface; };
|
|
75
67
|
}
|
|
76
68
|
AbsoluteSurface.prototype._class += " layout_AbsoluteSurface";
|
|
77
69
|
|
|
70
|
+
export interface AbsoluteSurface {
|
|
71
|
+
units(): string;
|
|
72
|
+
units(_: string): this;
|
|
73
|
+
widgetX(): number;
|
|
74
|
+
widgetX(_: number): this;
|
|
75
|
+
widgetY(): number;
|
|
76
|
+
widgetY(_: number): this;
|
|
77
|
+
widgetWidth(): string;
|
|
78
|
+
widgetWidth(_: string): this;
|
|
79
|
+
widgetHeight(): string;
|
|
80
|
+
widgetHeight(_: string): this;
|
|
81
|
+
widget(): any;
|
|
82
|
+
widget(_: any): this;
|
|
83
|
+
opacity(): number;
|
|
84
|
+
opacity(_: number): this;
|
|
85
|
+
}
|
|
86
|
+
|
|
78
87
|
AbsoluteSurface.prototype.publish("units", "percent", "set", "Units", ["pixels", "percent"]);
|
|
79
88
|
AbsoluteSurface.prototype.publish("widgetX", 0, "number", "Widget XPos");
|
|
80
89
|
AbsoluteSurface.prototype.publish("widgetY", 0, "number", "Widget YPos");
|
package/src/Accordion.ts
CHANGED
|
@@ -115,17 +115,27 @@ export class Accordion extends HTMLWidget {
|
|
|
115
115
|
exit(domNode, element) {
|
|
116
116
|
super.exit(domNode, element);
|
|
117
117
|
}
|
|
118
|
-
|
|
119
|
-
content: { (): any[]; (_: any[]): Accordion; };
|
|
120
|
-
title: { (): string; (_: string): Accordion; };
|
|
121
|
-
openIcon: { (): string; (_: string): Accordion; };
|
|
122
|
-
closedIcon: { (): string; (_: string): Accordion; };
|
|
123
|
-
titleFontColor: { (): string; (_: string): Accordion; };
|
|
124
|
-
titleBackgroundColor: { (): any; (_: any): Accordion; };
|
|
125
|
-
defaultCollapsed: { (): boolean; (_: boolean): Accordion; };
|
|
126
118
|
}
|
|
127
119
|
Accordion.prototype._class += " layout_Accordion";
|
|
128
120
|
|
|
121
|
+
export interface Accordion {
|
|
122
|
+
content(): any[];
|
|
123
|
+
content(_: any[]): this;
|
|
124
|
+
title(): string;
|
|
125
|
+
title(_: string): this;
|
|
126
|
+
openIcon(): string;
|
|
127
|
+
openIcon(_: string): this;
|
|
128
|
+
closedIcon(): string;
|
|
129
|
+
closedIcon(_: string): this;
|
|
130
|
+
titleFontColor(): string;
|
|
131
|
+
titleFontColor(_: string): this;
|
|
132
|
+
titleBackgroundColor(): string;
|
|
133
|
+
titleBackgroundColor(_: string): this;
|
|
134
|
+
|
|
135
|
+
defaultCollapsed(): boolean;
|
|
136
|
+
defaultCollapsed(_: boolean): this;
|
|
137
|
+
}
|
|
138
|
+
|
|
129
139
|
Accordion.prototype.publish("content", [], "widgetArray", "Array of widgets", null, { tags: ["Basic"] });
|
|
130
140
|
Accordion.prototype.publish("title", "", "string", "Title of collapsible section", null, { tags: ["Private"] });
|
|
131
141
|
Accordion.prototype.publish("openIcon", "\uf147", "string", "Icon to display when list is open", null, { tags: ["Private"] });
|
package/src/Border.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { d3Event, HTMLWidget, Platform, select as d3Select, selectAll as d3SelectAll, Utility } from "@hpcc-js/common";
|
|
2
2
|
import { drag as d3Drag } from "d3-drag";
|
|
3
|
-
import { Cell } from "./Cell";
|
|
3
|
+
import { Cell } from "./Cell.ts";
|
|
4
4
|
|
|
5
5
|
import "../src/Border.css";
|
|
6
6
|
|
|
@@ -563,34 +563,53 @@ export class Border extends HTMLWidget {
|
|
|
563
563
|
this.content().forEach(w => w.target(null));
|
|
564
564
|
super.exit(domNode, element);
|
|
565
565
|
}
|
|
566
|
-
|
|
567
|
-
designMode: { (): boolean; (_: boolean): Border; };
|
|
568
|
-
|
|
569
|
-
content: { (): any[]; (_: any[]): Border; };
|
|
570
|
-
|
|
571
|
-
gutter: { (): number; (_: number): Border; };
|
|
572
|
-
|
|
573
|
-
topShrinkWrap: { (): boolean; (_: boolean): Border; };
|
|
574
|
-
leftShrinkWrap: { (): boolean; (_: boolean): Border; };
|
|
575
|
-
rightShrinkWrap: { (): boolean; (_: boolean): Border; };
|
|
576
|
-
bottomShrinkWrap: { (): boolean; (_: boolean): Border; };
|
|
577
|
-
|
|
578
|
-
topSize: { (): number; (_: number): Border; };
|
|
579
|
-
leftSize: { (): number; (_: number): Border; };
|
|
580
|
-
rightSize: { (): number; (_: number): Border; };
|
|
581
|
-
bottomSize: { (): number; (_: number): Border; };
|
|
582
|
-
|
|
583
|
-
topPercentage: { (): number; (_: number): Border; };
|
|
584
|
-
leftPercentage: { (): number; (_: number): Border; };
|
|
585
|
-
rightPercentage: { (): number; (_: number): Border; };
|
|
586
|
-
bottomPercentage: { (): number; (_: number): Border; };
|
|
587
|
-
|
|
588
|
-
surfacePadding: { (): number; (_: number): Border; };
|
|
589
|
-
|
|
590
|
-
sectionTypes: { (): any[]; (_: any[]): Border; };
|
|
591
566
|
}
|
|
592
567
|
Border.prototype._class += " layout_Border";
|
|
593
568
|
|
|
569
|
+
export interface Border {
|
|
570
|
+
designMode(): boolean;
|
|
571
|
+
designMode(_: boolean): this;
|
|
572
|
+
|
|
573
|
+
content(): any[];
|
|
574
|
+
content(_: any[]): this;
|
|
575
|
+
|
|
576
|
+
gutter(): number;
|
|
577
|
+
gutter(_: number): this;
|
|
578
|
+
|
|
579
|
+
topShrinkWrap(): boolean;
|
|
580
|
+
topShrinkWrap(_: boolean): this;
|
|
581
|
+
leftShrinkWrap(): boolean;
|
|
582
|
+
leftShrinkWrap(_: boolean): this;
|
|
583
|
+
rightShrinkWrap(): boolean;
|
|
584
|
+
rightShrinkWrap(_: boolean): this;
|
|
585
|
+
bottomShrinkWrap(): boolean;
|
|
586
|
+
bottomShrinkWrap(_: boolean): this;
|
|
587
|
+
|
|
588
|
+
topSize(): number;
|
|
589
|
+
topSize(_: number): this;
|
|
590
|
+
leftSize(): number;
|
|
591
|
+
leftSize(_: number): this;
|
|
592
|
+
rightSize(): number;
|
|
593
|
+
rightSize(_: number): this;
|
|
594
|
+
bottomSize(): number;
|
|
595
|
+
bottomSize(_: number): this;
|
|
596
|
+
|
|
597
|
+
topPercentage(): number;
|
|
598
|
+
topPercentage(_: number): this;
|
|
599
|
+
leftPercentage(): number;
|
|
600
|
+
leftPercentage(_: number): this;
|
|
601
|
+
rightPercentage(): number;
|
|
602
|
+
rightPercentage(_: number): this;
|
|
603
|
+
bottomPercentage(): number;
|
|
604
|
+
bottomPercentage(_: number): this;
|
|
605
|
+
|
|
606
|
+
surfacePadding(): number;
|
|
607
|
+
surfacePadding(_: number): this;
|
|
608
|
+
|
|
609
|
+
sectionTypes(): any[];
|
|
610
|
+
sectionTypes(_: any[]): this;
|
|
611
|
+
}
|
|
612
|
+
|
|
594
613
|
Border.prototype.publish("designMode", false, "boolean", "Design Mode", null, { tags: ["Basic"] });
|
|
595
614
|
|
|
596
615
|
Border.prototype.publish("content", [], "widgetArray", "widgets", null, { tags: ["Intermediate"] });
|
package/src/Cell.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Widget } from "@hpcc-js/common";
|
|
2
2
|
import { select as d3Select, selectAll as d3SelectAll } from "d3-selection";
|
|
3
|
-
import { Surface } from "./Surface";
|
|
3
|
+
import { Surface } from "./Surface.ts";
|
|
4
4
|
|
|
5
5
|
import "../src/Cell.css";
|
|
6
6
|
|
|
@@ -63,21 +63,26 @@ export class Cell extends Surface {
|
|
|
63
63
|
d3SelectAll("#" + arr[i] + " > div.update-indicator").remove();
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
|
+
}
|
|
67
|
+
Cell.prototype._class += " layout_Cell";
|
|
66
68
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
gridCol
|
|
72
|
-
gridRowSpan
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
indicatorBorderColor: { (): string; (_: string): Cell; };
|
|
77
|
-
indicatorOpacity: { (): number; (_: number): Cell; };
|
|
69
|
+
export interface Cell {
|
|
70
|
+
gridRow(): number;
|
|
71
|
+
gridRow(_: number): this;
|
|
72
|
+
gridCol(): number;
|
|
73
|
+
gridCol(_: number): this;
|
|
74
|
+
gridRowSpan(): number;
|
|
75
|
+
gridRowSpan(_: number): this;
|
|
76
|
+
gridColSpan(): number;
|
|
77
|
+
gridColSpan(_: number): this;
|
|
78
78
|
|
|
79
|
+
indicatorGlowColor(): string;
|
|
80
|
+
indicatorGlowColor(_: string): this;
|
|
81
|
+
indicatorBorderColor(): string;
|
|
82
|
+
indicatorBorderColor(_: string): this;
|
|
83
|
+
indicatorOpacity(): number;
|
|
84
|
+
indicatorOpacity(_: number): this;
|
|
79
85
|
}
|
|
80
|
-
Cell.prototype._class += " layout_Cell";
|
|
81
86
|
|
|
82
87
|
Cell.prototype.publish("gridRow", 0, "number", "Grid Row Position", null, { tags: ["Private"] });
|
|
83
88
|
Cell.prototype.publish("gridCol", 0, "number", "Grid Column Position", null, { tags: ["Private"] });
|
package/src/ChartPanel.ts
CHANGED
|
@@ -3,14 +3,14 @@ import { Button, Database, IconBar, ProgressBar, Spacer, SVGWidget, Text, TitleB
|
|
|
3
3
|
import type { XYAxis } from "@hpcc-js/chart";
|
|
4
4
|
import { Table } from "@hpcc-js/dgrid2";
|
|
5
5
|
import { select as d3Select } from "d3-selection";
|
|
6
|
-
import { Border2 } from "./Border2";
|
|
7
|
-
import { Carousel } from "./Carousel";
|
|
8
|
-
import { Legend } from "./Legend";
|
|
9
|
-
import { Modal } from "./Modal";
|
|
6
|
+
import { Border2 } from "./Border2.ts";
|
|
7
|
+
import { Carousel } from "./Carousel.ts";
|
|
8
|
+
import { Legend } from "./Legend.ts";
|
|
9
|
+
import { Modal } from "./Modal.ts";
|
|
10
10
|
|
|
11
11
|
import "../src/ChartPanel.css";
|
|
12
12
|
|
|
13
|
-
export class ChartPanel extends Border2 implements IHighlight {
|
|
13
|
+
export class ChartPanel<T extends Widget = Widget> extends Border2 implements IHighlight {
|
|
14
14
|
|
|
15
15
|
protected _legend = new Legend(this).enableOverflow(true);
|
|
16
16
|
protected _progressBar = new ProgressBar();
|
|
@@ -98,7 +98,7 @@ export class ChartPanel extends Border2 implements IHighlight {
|
|
|
98
98
|
|
|
99
99
|
protected _carousel = new Carousel();
|
|
100
100
|
protected _table = new Table();
|
|
101
|
-
protected _widget:
|
|
101
|
+
protected _widget: T;
|
|
102
102
|
|
|
103
103
|
protected _hideLegendToggleList = ["dgrid_Table"];
|
|
104
104
|
|
|
@@ -287,7 +287,7 @@ export class ChartPanel extends Border2 implements IHighlight {
|
|
|
287
287
|
update(domNode, element) {
|
|
288
288
|
super.update(domNode, element);
|
|
289
289
|
if (this._table && this.widget_exists() && this.widget().class().indexOf("chart_XYAxis") >= 0) {
|
|
290
|
-
const chart = this.widget() as XYAxis;
|
|
290
|
+
const chart = this.widget() as unknown as XYAxis;
|
|
291
291
|
this._table.columns().forEach((column, idx) => {
|
|
292
292
|
switch (idx === 0 ? chart.xAxisType() : chart.yAxisType()) {
|
|
293
293
|
case "linear":
|
|
@@ -533,7 +533,7 @@ export class ChartPanel extends Border2 implements IHighlight {
|
|
|
533
533
|
}
|
|
534
534
|
ChartPanel.prototype._class += " layout_ChartPanel";
|
|
535
535
|
|
|
536
|
-
export interface ChartPanel {
|
|
536
|
+
export interface ChartPanel<T extends Widget = Widget> {
|
|
537
537
|
title(): string;
|
|
538
538
|
title(_: string): this;
|
|
539
539
|
titleVisible(): boolean;
|
|
@@ -568,8 +568,8 @@ export interface ChartPanel {
|
|
|
568
568
|
description(): string;
|
|
569
569
|
description(_: string): this;
|
|
570
570
|
description_exists(): boolean;
|
|
571
|
-
widget():
|
|
572
|
-
widget(_:
|
|
571
|
+
widget(): T;
|
|
572
|
+
widget(_: T): this;
|
|
573
573
|
widget_exists(): boolean;
|
|
574
574
|
enableAutoscaling(): boolean;
|
|
575
575
|
enableAutoscaling(_: boolean): this;
|
package/src/Grid.ts
CHANGED
package/src/HorizontalList.ts
CHANGED
package/src/Layered.ts
CHANGED
|
@@ -118,11 +118,15 @@ export class Layered extends HTMLWidget {
|
|
|
118
118
|
};
|
|
119
119
|
}
|
|
120
120
|
}
|
|
121
|
-
|
|
122
|
-
surfacePadding: { (): number; (_: string): Layered; };
|
|
123
|
-
widgets: { (): any[]; (_: any[]): Layered; };
|
|
124
121
|
}
|
|
125
122
|
Layered.prototype._class += " layout_Layered";
|
|
126
123
|
|
|
124
|
+
export interface Layered {
|
|
125
|
+
surfacePadding(): number;
|
|
126
|
+
surfacePadding(_: number): this;
|
|
127
|
+
widgets(): any;
|
|
128
|
+
widgets(_: any): this;
|
|
129
|
+
}
|
|
130
|
+
|
|
127
131
|
Layered.prototype.publish("surfacePadding", 0, "number", "Padding");
|
|
128
132
|
Layered.prototype.publish("widgets", [], "widgetArray", "widgets", null, { tags: ["Private"] });
|
package/src/Legend.ts
CHANGED
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
symbolWye as d3SymbolWye
|
|
14
14
|
} from "d3-shape";
|
|
15
15
|
import { legendColor as d3LegendColor } from "d3-svg-legend";
|
|
16
|
-
import { ChartPanel } from "./ChartPanel";
|
|
16
|
+
import { ChartPanel } from "./ChartPanel.ts";
|
|
17
17
|
|
|
18
18
|
export class Legend extends SVGWidget {
|
|
19
19
|
_owner: ChartPanel;
|
package/src/Popup.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { HTMLWidget } from "@hpcc-js/common";
|
|
1
|
+
import { HTMLWidget, Widget } from "@hpcc-js/common";
|
|
2
2
|
|
|
3
3
|
export class Popup extends HTMLWidget {
|
|
4
4
|
_surfaceButtons;
|
|
@@ -83,20 +83,31 @@ export class Popup extends HTMLWidget {
|
|
|
83
83
|
|
|
84
84
|
click(obj) {
|
|
85
85
|
}
|
|
86
|
-
|
|
87
|
-
popupState: { (): boolean; (_: boolean): Popup; };
|
|
88
|
-
shrinkWrap: { (): boolean; (_: boolean): Popup; };
|
|
89
|
-
centerPopup: { (): string; (_: string): Popup; };
|
|
90
|
-
top: { (): number; (_: number): Popup; };
|
|
91
|
-
bottom: { (): number; (_: number): Popup; };
|
|
92
|
-
left: { (): number; (_: number): Popup; };
|
|
93
|
-
right: { (): number; (_: number): Popup; };
|
|
94
|
-
position: { (): string; (_: string): Popup; };
|
|
95
|
-
|
|
96
|
-
widget: { (): any; (_: any): Popup; };
|
|
97
86
|
}
|
|
98
87
|
Popup.prototype._class += " layout_Popup";
|
|
99
88
|
|
|
89
|
+
export interface Popup {
|
|
90
|
+
popupState(): boolean;
|
|
91
|
+
popupState(_: boolean): this;
|
|
92
|
+
shrinkWrap(): boolean;
|
|
93
|
+
shrinkWrap(_: boolean): this;
|
|
94
|
+
centerPopup(): "none" | "container" | "window";
|
|
95
|
+
centerPopup(_: "none" | "container" | "window"): this;
|
|
96
|
+
top(): number;
|
|
97
|
+
top(_: number): this;
|
|
98
|
+
bottom(): number;
|
|
99
|
+
bottom(_: number): this;
|
|
100
|
+
left(): number;
|
|
101
|
+
left(_: number): this;
|
|
102
|
+
right(): number;
|
|
103
|
+
right(_: number): this;
|
|
104
|
+
position(): string;
|
|
105
|
+
position(_: string): this;
|
|
106
|
+
|
|
107
|
+
widget(): Widget;
|
|
108
|
+
widget(_: Widget): this;
|
|
109
|
+
}
|
|
110
|
+
|
|
100
111
|
Popup.prototype.publish("popupState", false, "boolean", "State of the popup, visible (true) or hidden (false)", null, {});
|
|
101
112
|
Popup.prototype.publish("shrinkWrap", false, "boolean", "The popup parent container either shrinks to the size of its contents (true) or expands to fit thge popup's parentDiv (false)", null, {});
|
|
102
113
|
Popup.prototype.publish("centerPopup", "none", "set", "Center the widget in its container element (target) or in the window", ["none", "container", "window"], {});
|
package/src/Surface.ts
CHANGED
|
@@ -121,6 +121,14 @@ export class Surface extends HTMLWidget {
|
|
|
121
121
|
super.exit(domNode, element);
|
|
122
122
|
}
|
|
123
123
|
|
|
124
|
+
// Events ---
|
|
125
|
+
click(obj) {
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
Surface.prototype._class += " layout_Surface";
|
|
129
|
+
|
|
130
|
+
export interface Surface {
|
|
131
|
+
/*
|
|
124
132
|
title: { (): string; (_: string): Surface; };
|
|
125
133
|
altText: { (): string; (_: string): Surface; };
|
|
126
134
|
altText_exists: () => boolean;
|
|
@@ -147,12 +155,51 @@ export class Surface extends HTMLWidget {
|
|
|
147
155
|
buttonAnnotations: { (): any[]; (_: any[]): Surface; };
|
|
148
156
|
|
|
149
157
|
widget: { (): Widget; (_: Widget): Surface; };
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
158
|
+
*/
|
|
159
|
+
title(): string;
|
|
160
|
+
title(_: string): this;
|
|
161
|
+
altText(): string;
|
|
162
|
+
altText(_: string): this;
|
|
163
|
+
altText_exists(): boolean;
|
|
164
|
+
surfaceTitlePadding(): number;
|
|
165
|
+
surfaceTitlePadding(_: number): this;
|
|
166
|
+
surfaceTitlePadding_exists(): boolean;
|
|
167
|
+
surfaceTitleFontSize(): number;
|
|
168
|
+
surfaceTitleFontSize(_: number): this;
|
|
169
|
+
surfaceTitleFontSize_exists(): boolean;
|
|
170
|
+
surfaceTitleFontColor(): string;
|
|
171
|
+
surfaceTitleFontColor(_: string): this;
|
|
172
|
+
surfaceTitleFontFamily(): string;
|
|
173
|
+
surfaceTitleFontFamily(_: string): this;
|
|
174
|
+
surfaceTitleFontBold(): boolean;
|
|
175
|
+
surfaceTitleFontBold(_: boolean): this;
|
|
176
|
+
surfaceTitleBackgroundColor(): string;
|
|
177
|
+
surfaceTitleBackgroundColor(_: string): this;
|
|
178
|
+
surfaceTitleAlignment(): string;
|
|
179
|
+
surfaceTitleAlignment(_: string): this;
|
|
180
|
+
|
|
181
|
+
surfaceShadow(): boolean;
|
|
182
|
+
surfaceShadow(_: boolean): this;
|
|
183
|
+
surfacePadding(): string;
|
|
184
|
+
surfacePadding(_: string): this;
|
|
185
|
+
surfacePadding_exists(): boolean;
|
|
186
|
+
surfaceBackgroundColor(): string;
|
|
187
|
+
surfaceBackgroundColor(_: string): this;
|
|
188
|
+
surfaceBorderWidth(): number;
|
|
189
|
+
surfaceBorderWidth(_: number): this;
|
|
190
|
+
surfaceBorderWidth_exists(): boolean;
|
|
191
|
+
surfaceBorderColor(): string;
|
|
192
|
+
surfaceBorderColor(_: string): this;
|
|
193
|
+
surfaceBorderRadius(): number;
|
|
194
|
+
surfaceBorderRadius(_: number): this;
|
|
195
|
+
surfaceBorderRadius_exists(): boolean;
|
|
196
|
+
|
|
197
|
+
buttonAnnotations(): any[];
|
|
198
|
+
buttonAnnotations(_: any[]): this;
|
|
199
|
+
|
|
200
|
+
widget(): Widget;
|
|
201
|
+
widget(_: Widget): this;
|
|
154
202
|
}
|
|
155
|
-
Surface.prototype._class += " layout_Surface";
|
|
156
203
|
|
|
157
204
|
Surface.prototype.publish("title", "", "string", "Title", null, { tags: ["Intermediate"] });
|
|
158
205
|
Surface.prototype.publish("altText", null, "string", "Alt text", null, { optional: true });
|
package/src/Tabbed.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { HTMLWidget, Text } from "@hpcc-js/common";
|
|
1
|
+
import { HTMLWidget, Text, Widget } from "@hpcc-js/common";
|
|
2
2
|
import { select as d3Select } from "d3-selection";
|
|
3
|
-
import { Surface } from "./Surface";
|
|
3
|
+
import { Surface } from "./Surface.ts";
|
|
4
4
|
|
|
5
5
|
import "../src/Tabbed.css";
|
|
6
6
|
|
|
@@ -136,19 +136,26 @@ export class Tabbed extends HTMLWidget {
|
|
|
136
136
|
|
|
137
137
|
click(widget, column, idx) {
|
|
138
138
|
}
|
|
139
|
-
|
|
140
|
-
showTabs: { (): boolean; (_: boolean): Tabbed; };
|
|
141
|
-
surfacePadding: { (): number; (_: number): Tabbed; };
|
|
142
|
-
surfacePadding_default: { (): number; (_: number): Tabbed; };
|
|
143
|
-
surfacePadding_exists: () => boolean;
|
|
144
|
-
activeTabIdx: { (): number; (_: number): Tabbed; };
|
|
145
|
-
|
|
146
|
-
labels: { (): string[]; (_: string[]): Tabbed; };
|
|
147
|
-
tabLocation: { (): string; (_: string): Tabbed; };
|
|
148
|
-
widgets: { (): any[]; (_: any[]): Tabbed; };
|
|
149
139
|
}
|
|
150
140
|
Tabbed.prototype._class += " layout_Tabbed";
|
|
151
141
|
|
|
142
|
+
export interface Tabbed {
|
|
143
|
+
showTabs(): boolean;
|
|
144
|
+
showTabs(_: boolean): this;
|
|
145
|
+
surfacePadding(): number;
|
|
146
|
+
surfacePadding(_: number): this;
|
|
147
|
+
surfacePadding_exists(): boolean;
|
|
148
|
+
activeTabIdx(): number;
|
|
149
|
+
activeTabIdx(_: number): this;
|
|
150
|
+
|
|
151
|
+
labels(): string[];
|
|
152
|
+
labels(_: string[]): this;
|
|
153
|
+
tabLocation(): "top" | "bottom";
|
|
154
|
+
tabLocation(_: "top" | "bottom"): this;
|
|
155
|
+
widgets(): any[];
|
|
156
|
+
widgets(_: any[]): this;
|
|
157
|
+
}
|
|
158
|
+
|
|
152
159
|
Tabbed.prototype.publish("showTabs", true, "boolean", "Show Tabs", null, {});
|
|
153
160
|
Tabbed.prototype.publish("surfacePadding", 4, "number", "Padding");
|
|
154
161
|
Tabbed.prototype.publish("activeTabIdx", 0, "number", "Index of active tab", null, {});
|