x4js 2.2.47 → 2.2.49
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 +3 -2
- package/src/components/breadcrumb/breadcrumb.ts +7 -0
- package/src/components/button/button.ts +15 -5
- package/src/components/calendar/calendar.ts +19 -1
- package/src/components/checkbox/checkbox.ts +11 -0
- package/src/components/colorinput/colorinput.ts +6 -1
- package/src/components/combobox/combobox.ts +14 -0
- package/src/components/dialog/dialog.ts +5 -1
- package/src/components/filedrop/filedrop.ts +10 -0
- package/src/components/form/form.ts +4 -1
- package/src/components/gauge/gauge.ts +9 -0
- package/src/components/gridview/gridview.ts +28 -1
- package/src/components/header/header.ts +6 -6
- package/src/components/image/image.ts +5 -0
- package/src/components/input/input.ts +9 -0
- package/src/components/keyboard/keyboard.ts +8 -0
- package/src/components/label/label.ts +7 -1
- package/src/components/link/link.ts +4 -0
- package/src/components/listbox/listbox.ts +14 -1
- package/src/components/menu/menu.ts +10 -1
- package/src/components/messages/messages.ts +6 -0
- package/src/components/notification/notification.ts +8 -1
- package/src/components/panel/panel.ts +5 -1
- package/src/components/popup/popup.ts +5 -2
- package/src/components/progress/progress.ts +8 -0
- package/src/components/propgrid/propgrid.ts +7 -2
- package/src/components/rating/rating.ts +6 -0
- package/src/components/select/select.ts +1 -0
- package/src/components/slider/slider.ts +7 -0
- package/src/components/spreadsheet/spreadsheet.ts +28 -1
- package/src/components/switch/switch.ts +7 -0
- package/src/components/tabs/tabs.ts +6 -0
- package/src/components/tag/tag.ts +11 -0
- package/src/components/textarea/textarea.ts +6 -0
- package/src/components/textedit/textedit.ts +10 -0
- package/src/components/tickline/tickline.ts +9 -0
- package/src/components/tooltips/tooltips.ts +10 -0
- package/src/components/treeview/treeview.ts +12 -0
- package/src/components/viewport/viewport.ts +8 -0
- package/src/core/component.ts +7 -5
- package/src/core/core_application.ts +1 -4
- package/src/core/core_data.ts +1 -4
- package/src/core/core_element.ts +8 -8
- package/src/core/core_svg.ts +2 -2
- package/src/core/core_tools.ts +1 -5
- package/src/x4doc.ts +23 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "x4js",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.49",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "src/x4.ts",
|
|
6
6
|
"module": "src/x4.ts",
|
|
@@ -35,6 +35,7 @@
|
|
|
35
35
|
"devDependencies": {
|
|
36
36
|
"typescript": "^5.8.3",
|
|
37
37
|
"typedoc": "^0.28.19",
|
|
38
|
-
"typedoc-plugin-markdown": "
|
|
38
|
+
"typedoc-plugin-markdown": "latest",
|
|
39
|
+
"typedoc-plugin-missing-exports": "latest"
|
|
39
40
|
}
|
|
40
41
|
}
|
|
@@ -24,6 +24,7 @@ import { Icon } from "../icon/icon"
|
|
|
24
24
|
import "./button.module.scss";
|
|
25
25
|
|
|
26
26
|
|
|
27
|
+
|
|
27
28
|
/**
|
|
28
29
|
* Button events
|
|
29
30
|
*/
|
|
@@ -76,13 +77,22 @@ export interface ButtonProps extends ComponentProps {
|
|
|
76
77
|
/**
|
|
77
78
|
* Represents a clickable button component.
|
|
78
79
|
*
|
|
79
|
-
*
|
|
80
|
-
*
|
|
81
|
-
*
|
|
82
|
-
*
|
|
80
|
+
* @cssvar
|
|
81
|
+
* ```
|
|
82
|
+
* --button-background
|
|
83
|
+
* --button-color
|
|
84
|
+
* --button-background-hover
|
|
85
|
+
* --button-color-hover
|
|
86
|
+
* --button-background-active
|
|
87
|
+
* --button-color-active
|
|
88
|
+
* --button-background-focus
|
|
89
|
+
* --button-color-focus
|
|
90
|
+
* --button-background-disabled
|
|
91
|
+
* --button-color-disabled
|
|
92
|
+
* --button-icon-color
|
|
93
|
+
* ```
|
|
83
94
|
*/
|
|
84
95
|
|
|
85
|
-
|
|
86
96
|
@class_ns( "x4" )
|
|
87
97
|
export class Button extends Component<ButtonProps,ButtonEvents> {
|
|
88
98
|
|
|
@@ -48,7 +48,25 @@ interface CalendarProps extends ComponentProps {
|
|
|
48
48
|
* default calendar control
|
|
49
49
|
*
|
|
50
50
|
* fires:
|
|
51
|
-
*
|
|
51
|
+
* EventChange ( value = Date )
|
|
52
|
+
*
|
|
53
|
+
* @cssvar
|
|
54
|
+
* ```
|
|
55
|
+
* --calendar-btn-background
|
|
56
|
+
* --calendar-btn-color
|
|
57
|
+
* --calendar-btn-color
|
|
58
|
+
* --calendar-week-color
|
|
59
|
+
* --calendar-week-color-hover
|
|
60
|
+
* --calendard-day-background-hover
|
|
61
|
+
* --calendard-day-color-hover
|
|
62
|
+
* --calendar-sel-background
|
|
63
|
+
* --calendar-sel-color
|
|
64
|
+
* --calendar-today-background
|
|
65
|
+
* --calendar-today-color
|
|
66
|
+
* --calendar-today-border
|
|
67
|
+
* --calendar-header-color
|
|
68
|
+
* --calendar-out-color
|
|
69
|
+
* ```
|
|
52
70
|
*/
|
|
53
71
|
|
|
54
72
|
@class_ns( "x4" )
|
|
@@ -31,6 +31,17 @@ interface CheckboxProps extends ComponentProps {
|
|
|
31
31
|
|
|
32
32
|
/**
|
|
33
33
|
* Checkbox component that can be checked or unchecked.
|
|
34
|
+
*
|
|
35
|
+
* @cssvar
|
|
36
|
+
* ```
|
|
37
|
+
* --checkbox-background-check
|
|
38
|
+
* --checkbox-background-check-hover
|
|
39
|
+
* --checkbox-background-disabled
|
|
40
|
+
* --checkbox-background-disabled-check
|
|
41
|
+
* --checkbox-color-disabled
|
|
42
|
+
* --checkbox-check-border
|
|
43
|
+
* --checkbox-check-border-hover
|
|
44
|
+
* ```
|
|
34
45
|
*/
|
|
35
46
|
|
|
36
47
|
@class_ns( "x4" )
|
|
@@ -87,6 +87,20 @@ interface ComboboxProps extends Omit<ComponentProps,"content"> {
|
|
|
87
87
|
selectionChange?: EventCallback<EvSelectionChange>,
|
|
88
88
|
}
|
|
89
89
|
|
|
90
|
+
/**
|
|
91
|
+
* @cssvar
|
|
92
|
+
* ```
|
|
93
|
+
* --dropdown-border
|
|
94
|
+
* --dropdown-background
|
|
95
|
+
* --combobox-border
|
|
96
|
+
* --combobox-border-focus
|
|
97
|
+
* --combobox-btn-background
|
|
98
|
+
* --combobox-btn-color
|
|
99
|
+
* --combobox-btn-color-hover
|
|
100
|
+
* --combo-tree-indent
|
|
101
|
+
* ```
|
|
102
|
+
*/
|
|
103
|
+
|
|
90
104
|
@class_ns( "x4" )
|
|
91
105
|
export class Combobox extends Component<ComboboxProps,ComboboxEvents> {
|
|
92
106
|
|
|
@@ -36,6 +36,16 @@ interface FileDialogProps extends ComponentProps {
|
|
|
36
36
|
callback: LoadCallback;
|
|
37
37
|
}
|
|
38
38
|
|
|
39
|
+
/**
|
|
40
|
+
* @cssvar
|
|
41
|
+
* ```
|
|
42
|
+
* --filedrop-border
|
|
43
|
+
* --filedrop-icon-color
|
|
44
|
+
* --filedrop-border-drop-hover
|
|
45
|
+
* --filedrop-icon-color-hover
|
|
46
|
+
* ```
|
|
47
|
+
*/
|
|
48
|
+
|
|
39
49
|
export class FileDialog extends Component {
|
|
40
50
|
|
|
41
51
|
constructor( props: FileDialogProps ) {
|
|
@@ -40,6 +40,15 @@ export const simpleColorStop = [
|
|
|
40
40
|
'var(--gauge-base-color)'
|
|
41
41
|
]
|
|
42
42
|
|
|
43
|
+
/**
|
|
44
|
+
* @cssvar
|
|
45
|
+
* ```
|
|
46
|
+
* --gauge-base-color
|
|
47
|
+
* --gauge-needle-back
|
|
48
|
+
* --gauge-needle-dot
|
|
49
|
+
* ```
|
|
50
|
+
*/
|
|
51
|
+
|
|
43
52
|
@class_ns( "x4" )
|
|
44
53
|
export class Gauge extends Component<GaugeProps> {
|
|
45
54
|
|
|
@@ -95,7 +95,34 @@ export interface GridviewProps extends ComponentProps {
|
|
|
95
95
|
*/
|
|
96
96
|
|
|
97
97
|
/**
|
|
98
|
-
*
|
|
98
|
+
* @cssvar
|
|
99
|
+
* ```
|
|
100
|
+
* --gridview-background
|
|
101
|
+
* --gridview-border
|
|
102
|
+
* --gridview-header-cell-background
|
|
103
|
+
* --gridview-header-cell-color
|
|
104
|
+
* --gridview-header-cell-vline
|
|
105
|
+
* --gridview-header-cell-border
|
|
106
|
+
* --grid-check-background
|
|
107
|
+
* --grid-check-color
|
|
108
|
+
* --grid-check-background-hover
|
|
109
|
+
* --grid-check-color-hover
|
|
110
|
+
* --grid-perc-background
|
|
111
|
+
* --grid-perc-color
|
|
112
|
+
* --grid-perc-background-hover
|
|
113
|
+
* --grid-perc-color-hover
|
|
114
|
+
* --gridview-cell-color
|
|
115
|
+
* --gridview-cell-color-sel
|
|
116
|
+
* --gridview-cell-vline
|
|
117
|
+
* --gridview-row-background
|
|
118
|
+
* --gridview-row-odd-background
|
|
119
|
+
* --gridview-row-border
|
|
120
|
+
* --gridview-row-background-hover
|
|
121
|
+
* --gridview-row-background-hover-sel
|
|
122
|
+
* --gridview-row-background-sel
|
|
123
|
+
* --gridview-row-color-sel
|
|
124
|
+
* --gridview-fix-border
|
|
125
|
+
* ```
|
|
99
126
|
*/
|
|
100
127
|
|
|
101
128
|
@class_ns("x4")
|
|
@@ -20,13 +20,13 @@ interface HeaderProps extends Omit<ComponentProps,"content"> {
|
|
|
20
20
|
|
|
21
21
|
/**
|
|
22
22
|
* by default when a header item is resized, the 'target' style '--{name}-width' is updated
|
|
23
|
-
* if you listbox has a header and 3 cols named A, B, C then in your css, use
|
|
24
23
|
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
24
|
+
* @cssvar
|
|
25
|
+
* ```
|
|
26
|
+
* --header-background-hover
|
|
27
|
+
* --header-sizer-hover
|
|
28
|
+
* --header-color
|
|
29
|
+
* ```
|
|
30
30
|
*/
|
|
31
31
|
|
|
32
32
|
@class_ns( "x4" )
|
|
@@ -32,6 +32,7 @@ interface ImageEvents extends ComponentEvents {
|
|
|
32
32
|
change: EvDropChange;
|
|
33
33
|
clear: CoreEvent;
|
|
34
34
|
}
|
|
35
|
+
|
|
35
36
|
export interface ImageProps extends ComponentProps {
|
|
36
37
|
src: string;
|
|
37
38
|
fit?: "contain" | "cover" | "fill" | "scale-down";
|
|
@@ -49,6 +50,10 @@ export interface ImageProps extends ComponentProps {
|
|
|
49
50
|
|
|
50
51
|
/**
|
|
51
52
|
*
|
|
53
|
+
* @cssvar
|
|
54
|
+
* ```
|
|
55
|
+
* --image-border-drop-hover
|
|
56
|
+
* ```
|
|
52
57
|
*/
|
|
53
58
|
|
|
54
59
|
@class_ns( "x4" )
|
|
@@ -198,6 +198,15 @@ interface InputEvents extends ComponentEvent {
|
|
|
198
198
|
* change: (e) => console.log("Checked:", e.value)
|
|
199
199
|
* });
|
|
200
200
|
* ```
|
|
201
|
+
*
|
|
202
|
+
* @cssvar
|
|
203
|
+
* ```
|
|
204
|
+
* --input-sel-background
|
|
205
|
+
* --input-sel-color
|
|
206
|
+
* --input-placeholder
|
|
207
|
+
* --input-error
|
|
208
|
+
* --input-checkbox-color
|
|
209
|
+
* ```
|
|
201
210
|
*/
|
|
202
211
|
|
|
203
212
|
@class_ns( "x4" )
|
|
@@ -99,6 +99,14 @@ interface KeyboardProps extends BoxProps {
|
|
|
99
99
|
|
|
100
100
|
}
|
|
101
101
|
|
|
102
|
+
/**
|
|
103
|
+
* @cssvar
|
|
104
|
+
* ```
|
|
105
|
+
* --keyboard-key-background
|
|
106
|
+
* --keyboard-hilite-color
|
|
107
|
+
* --keyboard-zoom
|
|
108
|
+
* ```
|
|
109
|
+
*/
|
|
102
110
|
@class_ns( "x4" )
|
|
103
111
|
export class Keyboard extends HBox<KeyboardProps>
|
|
104
112
|
{
|
|
@@ -75,7 +75,20 @@ export interface ListboxProps extends Omit<ComponentProps,'content'> {
|
|
|
75
75
|
}
|
|
76
76
|
|
|
77
77
|
/**
|
|
78
|
-
*
|
|
78
|
+
* @cssvar
|
|
79
|
+
* ```
|
|
80
|
+
* --listbox-item-color
|
|
81
|
+
* --listbox-icon-color
|
|
82
|
+
* --listbox-item-color-disabled
|
|
83
|
+
* --listbox-item-color-sel
|
|
84
|
+
* --listbox-item-background-sel
|
|
85
|
+
* --listbox-item-color-sel-disabled
|
|
86
|
+
* --listbox-item-color-hover
|
|
87
|
+
* --listbox-item-background-hover
|
|
88
|
+
* --listbox-background
|
|
89
|
+
* --listbox-border
|
|
90
|
+
* --listbox-border-focus
|
|
91
|
+
* ```
|
|
79
92
|
*/
|
|
80
93
|
|
|
81
94
|
@class_ns( "x4" )
|
|
@@ -47,7 +47,16 @@ export interface MenuProps extends Omit<PopupProps,"content"> {
|
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
/**
|
|
50
|
-
*
|
|
50
|
+
* @cssvar
|
|
51
|
+
* ```
|
|
52
|
+
* --menu-background
|
|
53
|
+
* --menu-border
|
|
54
|
+
* --menuitem-color
|
|
55
|
+
* --menuitem-background-active
|
|
56
|
+
* --menuitem-color-active
|
|
57
|
+
* --menuitem-background-hover
|
|
58
|
+
* --menuitem-color-hover
|
|
59
|
+
* ```
|
|
51
60
|
*/
|
|
52
61
|
|
|
53
62
|
@class_ns( "x4" )
|
|
@@ -42,7 +42,14 @@ interface NotificationProps extends ComponentProps {
|
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
/**
|
|
45
|
-
*
|
|
45
|
+
* @cssvar
|
|
46
|
+
* ```
|
|
47
|
+
* --notification-border
|
|
48
|
+
* --notification-background
|
|
49
|
+
* --notification-icon-default
|
|
50
|
+
* --notification-icon-success
|
|
51
|
+
* --notification-icon-danger
|
|
52
|
+
* ```
|
|
46
53
|
*/
|
|
47
54
|
|
|
48
55
|
@class_ns( "x4" )
|
|
@@ -46,7 +46,10 @@ function getRoot( ) {
|
|
|
46
46
|
}
|
|
47
47
|
|
|
48
48
|
/**
|
|
49
|
-
*
|
|
49
|
+
* @cssvar
|
|
50
|
+
* ```
|
|
51
|
+
* --modal-mask-background
|
|
52
|
+
* ```
|
|
50
53
|
*/
|
|
51
54
|
|
|
52
55
|
@class_ns( "x4" )
|
|
@@ -395,7 +398,7 @@ export class Popup<P extends PopupProps = PopupProps, E extends PopupEvents = Po
|
|
|
395
398
|
|
|
396
399
|
|
|
397
400
|
/**
|
|
398
|
-
*
|
|
401
|
+
* @internal
|
|
399
402
|
*/
|
|
400
403
|
|
|
401
404
|
export
|
|
@@ -25,6 +25,14 @@ interface ProgressProps extends ComponentProps {
|
|
|
25
25
|
max: number;
|
|
26
26
|
}
|
|
27
27
|
|
|
28
|
+
/**
|
|
29
|
+
* @cssvar
|
|
30
|
+
* ```
|
|
31
|
+
* --progress-background
|
|
32
|
+
* --progress-color
|
|
33
|
+
* ```
|
|
34
|
+
*/
|
|
35
|
+
|
|
28
36
|
@class_ns( "x4" )
|
|
29
37
|
export class Progress extends Component<ProgressProps> {
|
|
30
38
|
|
|
@@ -59,6 +59,13 @@ export interface PropertyProps extends ComponentProps {
|
|
|
59
59
|
groups: PropertyGroup[];
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
+
/**
|
|
63
|
+
* @cssvar
|
|
64
|
+
* ```
|
|
65
|
+
* --propertygrid-background
|
|
66
|
+
* ```
|
|
67
|
+
*/
|
|
68
|
+
|
|
62
69
|
@class_ns( "x4" )
|
|
63
70
|
export class PropertyGrid extends VBox {
|
|
64
71
|
|
|
@@ -106,8 +113,6 @@ export class PropertyGrid extends VBox {
|
|
|
106
113
|
|
|
107
114
|
/**
|
|
108
115
|
* Gets the html of a group header row
|
|
109
|
-
* @param {string} displayName - The group display name
|
|
110
|
-
* @param {boolean} isCollapsible - Whether the group should support expand/collapse
|
|
111
116
|
*/
|
|
112
117
|
|
|
113
118
|
makeGroupHeader( g: PropertyGroup ) {
|
|
@@ -202,7 +202,34 @@ export interface SpreadsheetProps extends ComponentProps {
|
|
|
202
202
|
*/
|
|
203
203
|
|
|
204
204
|
/**
|
|
205
|
-
*
|
|
205
|
+
* @cssvar
|
|
206
|
+
* ```
|
|
207
|
+
* --spreadsheet-background
|
|
208
|
+
* --spreadsheet-border
|
|
209
|
+
* --spreadsheet-header-cell-background
|
|
210
|
+
* --spreadsheet-header-cell-color
|
|
211
|
+
* --spreadsheet-header-cell-vline
|
|
212
|
+
* --spreadsheet-header-cell-border
|
|
213
|
+
* --spreadsheet-check-background
|
|
214
|
+
* --spreadsheet-check-color
|
|
215
|
+
* --spreadsheet-check-background-hover
|
|
216
|
+
* --spreadsheet-check-color-hover
|
|
217
|
+
* --spreadsheet-perc-background
|
|
218
|
+
* --spreadsheet-perc-color
|
|
219
|
+
* --spreadsheet-perc-background-hover
|
|
220
|
+
* --spreadsheet-perc-color-hover
|
|
221
|
+
* --spreadsheet-cell-color
|
|
222
|
+
* --spreadsheet-cell-color-sel
|
|
223
|
+
* --spreadsheet-cell-vline
|
|
224
|
+
* --spreadsheet-row-background
|
|
225
|
+
* --spreadsheet-row-odd-background
|
|
226
|
+
* --spreadsheet-row-border
|
|
227
|
+
* --spreadsheet-row-background-hover
|
|
228
|
+
* --spreadsheet-row-background-hover-sel
|
|
229
|
+
* --spreadsheet-row-background-sel
|
|
230
|
+
* --spreadsheet-row-color-sel
|
|
231
|
+
* --spreadsheet-fix-border
|
|
232
|
+
* ```
|
|
206
233
|
*/
|
|
207
234
|
|
|
208
235
|
@class_ns("x4")
|
|
@@ -18,6 +18,17 @@ export interface TagProps extends ComponentProps {
|
|
|
18
18
|
icon?: string;
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
+
/**
|
|
22
|
+
*
|
|
23
|
+
* @cssvar
|
|
24
|
+
* ```
|
|
25
|
+
* --tag-border
|
|
26
|
+
* --tag-border-focus
|
|
27
|
+
* --tag-selection
|
|
28
|
+
* --tag-color
|
|
29
|
+
* --tag-icon-color
|
|
30
|
+
* ```
|
|
31
|
+
*/
|
|
21
32
|
|
|
22
33
|
@class_ns( "x4" )
|
|
23
34
|
export class Tag extends HBox<TagProps> {
|
|
@@ -69,6 +69,16 @@ interface TextEditProps extends InputProps {
|
|
|
69
69
|
|
|
70
70
|
/**
|
|
71
71
|
*
|
|
72
|
+
* @cssvar
|
|
73
|
+
* ```
|
|
74
|
+
* --textedit-border
|
|
75
|
+
* --textedit-border-focus
|
|
76
|
+
* --textedit-required
|
|
77
|
+
* --textedit-btn-background
|
|
78
|
+
* --textedit-btn-color
|
|
79
|
+
* --textedit-btn-color-hover
|
|
80
|
+
* --textedit-color-disabled
|
|
81
|
+
* ```
|
|
72
82
|
*/
|
|
73
83
|
|
|
74
84
|
@class_ns( "x4" )
|
|
@@ -13,6 +13,15 @@ interface TickLineProps extends ComponentProps {
|
|
|
13
13
|
type: "bars" | "line";
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @cssvar
|
|
19
|
+
* ```
|
|
20
|
+
* --tickline-axis-color
|
|
21
|
+
* --tickline-color
|
|
22
|
+
* --tickline-background
|
|
23
|
+
* ```
|
|
24
|
+
*/
|
|
16
25
|
|
|
17
26
|
export class TickLine extends Component<TickLineProps> {
|
|
18
27
|
|
|
@@ -95,6 +95,16 @@ function closeTT( ) {
|
|
|
95
95
|
|
|
96
96
|
/**
|
|
97
97
|
*
|
|
98
|
+
* @cssvar
|
|
99
|
+
* ```
|
|
100
|
+
* --tooltip-caption-background
|
|
101
|
+
* --tooltip-caption-color
|
|
102
|
+
* --tooltip-icon-background
|
|
103
|
+
* --tooltip-icon-color
|
|
104
|
+
* --tooltip-background
|
|
105
|
+
* --tooltip-color
|
|
106
|
+
* --tooltip-border
|
|
107
|
+
* ```
|
|
98
108
|
*/
|
|
99
109
|
|
|
100
110
|
@class_ns( "x4" )
|
|
@@ -69,6 +69,18 @@ interface TreeviewEvents extends ComponentEvents {
|
|
|
69
69
|
|
|
70
70
|
/**
|
|
71
71
|
*
|
|
72
|
+
* @cssvar
|
|
73
|
+
* ```
|
|
74
|
+
* --treeview-background
|
|
75
|
+
* --treeitem-backgound-hover
|
|
76
|
+
* --treeitem-color-hover
|
|
77
|
+
* --treeitem-background-sel
|
|
78
|
+
* --treeitem-color-sel
|
|
79
|
+
* --treeview-item-color-sel-disabled
|
|
80
|
+
* --treeview-item-color-disabled
|
|
81
|
+
* --treeitem-backgound-active
|
|
82
|
+
* --treeitem-color-active
|
|
83
|
+
* ```
|
|
72
84
|
*/
|
|
73
85
|
|
|
74
86
|
@class_ns( "x4" )
|
|
@@ -19,6 +19,10 @@ import { Component, ComponentProps } from "../../core/component"
|
|
|
19
19
|
|
|
20
20
|
import "./viewport.module.scss"
|
|
21
21
|
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
*/
|
|
25
|
+
|
|
22
26
|
@class_ns( "x4" )
|
|
23
27
|
export class Viewport extends Component {
|
|
24
28
|
constructor( props: ComponentProps ) {
|
|
@@ -26,6 +30,10 @@ export class Viewport extends Component {
|
|
|
26
30
|
}
|
|
27
31
|
}
|
|
28
32
|
|
|
33
|
+
/**
|
|
34
|
+
*
|
|
35
|
+
*/
|
|
36
|
+
|
|
29
37
|
@class_ns( "x4" )
|
|
30
38
|
export class ScrollView extends Component {
|
|
31
39
|
constructor( props: ComponentProps ) {
|
package/src/core/component.ts
CHANGED
|
@@ -416,8 +416,10 @@ export class Component<P extends ComponentProps = ComponentProps, E extends Comp
|
|
|
416
416
|
* @param name - The suffix of the `data-` attribute (e.g., for `data-foo`, use `"foo"`).
|
|
417
417
|
* @returns The string value of the `data-*` attribute, or `null` if not present.
|
|
418
418
|
*
|
|
419
|
-
* @
|
|
420
|
-
* @
|
|
419
|
+
* @see Component.setIntData
|
|
420
|
+
* @see Component.getIntData
|
|
421
|
+
* @see Component.setInternalData
|
|
422
|
+
* @see Component.getInternalData
|
|
421
423
|
*/
|
|
422
424
|
|
|
423
425
|
getData( name: string ) : string {
|
|
@@ -536,7 +538,7 @@ export class Component<P extends ComponentProps = ComponentProps, E extends Comp
|
|
|
536
538
|
* Appends content to the end of the component's DOM element.
|
|
537
539
|
* Content can be a single Component, an array of Components, a string, an array of strings,
|
|
538
540
|
* raw HTML, an array of raw HTML, a number, or a boolean.
|
|
539
|
-
* @
|
|
541
|
+
* @remarks
|
|
540
542
|
* for simplicity, null is also allowed:
|
|
541
543
|
* setContent( [
|
|
542
544
|
* optional ? myControl : null,
|
|
@@ -629,7 +631,7 @@ export class Component<P extends ComponentProps = ComponentProps, E extends Comp
|
|
|
629
631
|
/**
|
|
630
632
|
* Removes a specific child component from this component's DOM element.
|
|
631
633
|
* @param child - The child component instance to remove.
|
|
632
|
-
* @
|
|
634
|
+
* @see clearContent
|
|
633
635
|
*/
|
|
634
636
|
|
|
635
637
|
removeChild( child: Component ) {
|
|
@@ -793,7 +795,7 @@ export class Component<P extends ComponentProps = ComponentProps, E extends Comp
|
|
|
793
795
|
* Sets pointer capture on the component's DOM element for a specific pointer.
|
|
794
796
|
* @param pointerId - The unique ID of the pointer.
|
|
795
797
|
*
|
|
796
|
-
* @
|
|
798
|
+
* @example
|
|
797
799
|
* control.on("pointerdown", (ev) => {
|
|
798
800
|
* ev.preventDefault(); // Prevent default browser actions
|
|
799
801
|
* control.setCapture(ev.pointerId);
|
|
@@ -171,10 +171,7 @@ export class Application<E extends ApplicationEvents = ApplicationEvents> extend
|
|
|
171
171
|
}
|
|
172
172
|
|
|
173
173
|
/**
|
|
174
|
-
*
|
|
175
|
-
* @param name - The name of the environment variable.
|
|
176
|
-
* @param def_value - An optional default value to return if the variable is not found.
|
|
177
|
-
* @returns The value of the environment variable, or `def_value` if not found.
|
|
174
|
+
*
|
|
178
175
|
*/
|
|
179
176
|
|
|
180
177
|
static fireGlobal( msg: string, params?: any ) {
|
package/src/core/core_data.ts
CHANGED
|
@@ -602,7 +602,6 @@ export class DataStore<T = any> extends EventSource<DataStoreEventMap> {
|
|
|
602
602
|
|
|
603
603
|
/**
|
|
604
604
|
*
|
|
605
|
-
* @param records
|
|
606
605
|
*/
|
|
607
606
|
|
|
608
607
|
async load( url?: string ) {
|
|
@@ -666,7 +665,7 @@ export class DataStore<T = any> extends EventSource<DataStoreEventMap> {
|
|
|
666
665
|
|
|
667
666
|
/**
|
|
668
667
|
*
|
|
669
|
-
* @param
|
|
668
|
+
* @param rec
|
|
670
669
|
*/
|
|
671
670
|
|
|
672
671
|
public appendRaw( rec: T ) {
|
|
@@ -1206,8 +1205,6 @@ export class DataView extends CoreElement<DataViewEventMap>
|
|
|
1206
1205
|
|
|
1207
1206
|
/**
|
|
1208
1207
|
*
|
|
1209
|
-
* @param columns
|
|
1210
|
-
* @param ascending
|
|
1211
1208
|
*/
|
|
1212
1209
|
|
|
1213
1210
|
public sort( props: SortProp[] ) {
|
package/src/core/core_element.ts
CHANGED
|
@@ -118,7 +118,7 @@ export class CoreElement<E extends EventMap = EventMap> {
|
|
|
118
118
|
/**
|
|
119
119
|
* Clears a previously set timeout.
|
|
120
120
|
* @param name - The name of the timeout to clear.
|
|
121
|
-
* @
|
|
121
|
+
* @see setTimeout
|
|
122
122
|
*/
|
|
123
123
|
|
|
124
124
|
clearTimeout( name: string ) {
|
|
@@ -140,7 +140,7 @@ export class CoreElement<E extends EventMap = EventMap> {
|
|
|
140
140
|
/**
|
|
141
141
|
* Clears a previously set interval.
|
|
142
142
|
* @param name - The name of the interval to clear.
|
|
143
|
-
* @
|
|
143
|
+
* @see setInterval
|
|
144
144
|
*/
|
|
145
145
|
|
|
146
146
|
clearInterval( name: string ) {
|
|
@@ -150,7 +150,7 @@ export class CoreElement<E extends EventMap = EventMap> {
|
|
|
150
150
|
/**
|
|
151
151
|
* Clears all timeouts and intervals currently managed by this instance.
|
|
152
152
|
* This stops all scheduled callbacks and removes their references.
|
|
153
|
-
* @
|
|
153
|
+
* @see setTimeout
|
|
154
154
|
*/
|
|
155
155
|
clearTimeouts( ) {
|
|
156
156
|
for( const [id,val] of this.#timers ) {
|
|
@@ -169,7 +169,7 @@ export class CoreElement<E extends EventMap = EventMap> {
|
|
|
169
169
|
* @param name - The name of the event to listen for.
|
|
170
170
|
* @param listener - The callback function to execute when the event is fired.
|
|
171
171
|
* @returns An object containing an `off()` method to unsubscribe the listener.
|
|
172
|
-
* @
|
|
172
|
+
* @see fire
|
|
173
173
|
* attach to an event
|
|
174
174
|
*/
|
|
175
175
|
|
|
@@ -193,8 +193,8 @@ export class CoreElement<E extends EventMap = EventMap> {
|
|
|
193
193
|
* If the listener was not found or no events were registered, this method does nothing.
|
|
194
194
|
* @param name - The name of the event from which to remove the listener.
|
|
195
195
|
* @param listener - The specific listener function to remove.
|
|
196
|
-
* @
|
|
197
|
-
* @
|
|
196
|
+
* @see on
|
|
197
|
+
* @see fire
|
|
198
198
|
*/
|
|
199
199
|
|
|
200
200
|
off<K extends keyof E>( name: K, listener: ( ev: E[K] ) => void ) {
|
|
@@ -210,8 +210,8 @@ export class CoreElement<E extends EventMap = EventMap> {
|
|
|
210
210
|
* If no listeners are registered for the event name, or if no EventSource has been initialized, this method does nothing.
|
|
211
211
|
* @param name - The name of the event to fire.
|
|
212
212
|
* @param ev - The payload (event object) to pass to the listeners.
|
|
213
|
-
* @
|
|
214
|
-
* @
|
|
213
|
+
* @see on
|
|
214
|
+
* @see off
|
|
215
215
|
*/
|
|
216
216
|
|
|
217
217
|
fire<K extends keyof E>( name: K, ev: E[K] ) {
|
package/src/core/core_svg.ts
CHANGED
|
@@ -267,7 +267,7 @@ class SvgItem {
|
|
|
267
267
|
|
|
268
268
|
/**
|
|
269
269
|
* add a class
|
|
270
|
-
* @param
|
|
270
|
+
* @param cls class name to add
|
|
271
271
|
*/
|
|
272
272
|
|
|
273
273
|
addClass( cls: string ): this {
|
|
@@ -287,7 +287,7 @@ class SvgItem {
|
|
|
287
287
|
|
|
288
288
|
/**
|
|
289
289
|
* remove a class
|
|
290
|
-
* @param
|
|
290
|
+
* @param cls class name to remove
|
|
291
291
|
*/
|
|
292
292
|
|
|
293
293
|
removeClass( cls: string ): this {
|
package/src/core/core_tools.ts
CHANGED
|
@@ -424,8 +424,6 @@ export function oneshot(callback: () => void, ms = 0) {
|
|
|
424
424
|
|
|
425
425
|
/**
|
|
426
426
|
* prepend 0 to a value to a given length
|
|
427
|
-
* @param value
|
|
428
|
-
* @param length
|
|
429
427
|
*/
|
|
430
428
|
|
|
431
429
|
export function pad(what: any, size: number, ch: string = '0') {
|
|
@@ -466,7 +464,7 @@ export function sprintf(format: string, ...args: any[]) {
|
|
|
466
464
|
/**
|
|
467
465
|
* inverse of camel case
|
|
468
466
|
* theThingToCase -> the-thing-to-case
|
|
469
|
-
* @param
|
|
467
|
+
* @param string
|
|
470
468
|
*/
|
|
471
469
|
|
|
472
470
|
export function pascalCase(string: string): string {
|
|
@@ -524,8 +522,6 @@ export function date_format(date: Date, options?: any): string {
|
|
|
524
522
|
|
|
525
523
|
/**
|
|
526
524
|
* difference between 2 dates
|
|
527
|
-
* @param date
|
|
528
|
-
* @param options
|
|
529
525
|
* @return text
|
|
530
526
|
*/
|
|
531
527
|
|
package/src/x4doc.ts
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ___ ___ __
|
|
3
|
+
* \ \/ / / _
|
|
4
|
+
* \ / /_| |_
|
|
5
|
+
* / \____ _|
|
|
6
|
+
* /__/\__\ |_|
|
|
7
|
+
*
|
|
8
|
+
* @file x4-doc.ts
|
|
9
|
+
* @author Etienne Cochard
|
|
10
|
+
*
|
|
11
|
+
* @copyright (c) 2026 R-libre ingenierie
|
|
12
|
+
*
|
|
13
|
+
* Use of this source code is governed by an MIT-style license
|
|
14
|
+
* that can be found in the LICENSE file or at https://opensource.org/licenses/MIT.
|
|
15
|
+
**/
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* do not use, only to generate full x4documentation
|
|
20
|
+
*/
|
|
21
|
+
|
|
22
|
+
export * from "./x4.js"
|
|
23
|
+
export * from "./components/monaco/monaco.js"
|