@acrodata/gui 0.3.1 → 0.4.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/esm2022/button-toggle/icon.mjs +4 -4
- package/esm2022/gui-form.mjs +31 -28
- package/esm2022/gui-icons.mjs +6 -1
- package/esm2022/interface.mjs +1 -1
- package/esm2022/select/select.mjs +2 -2
- package/esm2022/slider/slider.mjs +2 -2
- package/fesm2022/acrodata-gui.mjs +42 -34
- package/fesm2022/acrodata-gui.mjs.map +1 -1
- package/fill/fill.scss +1 -1
- package/gui-form.d.ts +13 -18
- package/gui-form.scss +23 -5
- package/input-number/input-number.scss +1 -1
- package/interface.d.ts +1 -0
- package/package.json +1 -1
- package/select/select.scss +6 -1
- package/slider/slider.scss +5 -0
package/fill/fill.scss
CHANGED
package/gui-form.d.ts
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { EventEmitter, OnChanges, OnDestroy, OnInit, SimpleChanges } from '@angular/core';
|
|
2
2
|
import { FormArray, FormGroup } from '@angular/forms';
|
|
3
3
|
import { Subscription } from 'rxjs';
|
|
4
4
|
import { GuiControl, GuiFieldType, GuiFields, GuiTabsMode } from './interface';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
6
|
export declare class GuiForm implements OnChanges, OnInit, OnDestroy {
|
|
7
|
-
private cdr;
|
|
8
7
|
/**
|
|
9
8
|
* The form instance which allow to track model value and validation status.
|
|
10
9
|
*/
|
|
@@ -24,7 +23,6 @@ export declare class GuiForm implements OnChanges, OnInit, OnDestroy {
|
|
|
24
23
|
formFields: GuiControl[];
|
|
25
24
|
formSubscription: Subscription;
|
|
26
25
|
controlSubscriptions: Subscription[];
|
|
27
|
-
constructor(cdr: ChangeDetectorRef);
|
|
28
26
|
ngOnChanges(changes: SimpleChanges): void;
|
|
29
27
|
ngOnInit(): void;
|
|
30
28
|
ngOnDestroy(): void;
|
|
@@ -36,31 +34,28 @@ export declare class GuiForm implements OnChanges, OnInit, OnDestroy {
|
|
|
36
34
|
* @param model The value of the form control
|
|
37
35
|
* @param defaultValue The default value of the form field
|
|
38
36
|
* @param parentType The type of the form field parent
|
|
39
|
-
* @param options The reactive form options
|
|
40
37
|
* @returns
|
|
41
38
|
*/
|
|
42
|
-
getFormFieldArray(form: FormGroup | FormArray, config?: GuiFields | GuiControl[], model?: Record<string, any>, defaultValue?: any, parentType?: GuiFieldType
|
|
43
|
-
onlySelf?: boolean;
|
|
44
|
-
emitEvent?: boolean;
|
|
45
|
-
}): GuiControl[];
|
|
39
|
+
getFormFieldArray(form: FormGroup | FormArray, config?: GuiFields | GuiControl[], model?: Record<string, any>, defaultValue?: any, parentType?: GuiFieldType): GuiControl[];
|
|
46
40
|
/**
|
|
47
41
|
* Add a tab item.
|
|
48
42
|
*
|
|
49
|
-
* @param e
|
|
50
|
-
* @param
|
|
51
|
-
* @param tabs
|
|
52
|
-
* @param
|
|
43
|
+
* @param e The mouse event
|
|
44
|
+
* @param formArray The reactive form instance
|
|
45
|
+
* @param tabs The config of the tabs field
|
|
46
|
+
* @param copy Whether to copy the current tab
|
|
47
|
+
* @param index The index of the tabs array
|
|
53
48
|
*/
|
|
54
|
-
addTab(e: MouseEvent,
|
|
49
|
+
addTab(e: MouseEvent, formArray: FormArray, tabs: GuiControl, copy?: boolean, index?: number): void;
|
|
55
50
|
/**
|
|
56
51
|
* Remove a tab item.
|
|
57
52
|
*
|
|
58
|
-
* @param e
|
|
59
|
-
* @param
|
|
60
|
-
* @param tabs
|
|
61
|
-
* @param index
|
|
53
|
+
* @param e The mouse event
|
|
54
|
+
* @param formArray The reactive form instance
|
|
55
|
+
* @param tabs The config of the tabs field
|
|
56
|
+
* @param index The index of the tabs array
|
|
62
57
|
*/
|
|
63
|
-
removeTab(e: MouseEvent,
|
|
58
|
+
removeTab(e: MouseEvent, formArray: FormArray, tabs: GuiControl, index?: number): void;
|
|
64
59
|
/**
|
|
65
60
|
* Change the display mode of tabs.
|
|
66
61
|
*
|
package/gui-form.scss
CHANGED
|
@@ -26,8 +26,16 @@
|
|
|
26
26
|
align-items: center;
|
|
27
27
|
padding-right: 8px;
|
|
28
28
|
|
|
29
|
+
[dir='rtl'] & {
|
|
30
|
+
padding-right: 0;
|
|
31
|
+
padding-left: 8px;
|
|
32
|
+
}
|
|
33
|
+
|
|
29
34
|
gui-field-label {
|
|
30
35
|
flex: 1;
|
|
36
|
+
overflow: hidden;
|
|
37
|
+
white-space: nowrap;
|
|
38
|
+
text-overflow: ellipsis;
|
|
31
39
|
}
|
|
32
40
|
}
|
|
33
41
|
}
|
|
@@ -80,7 +88,7 @@
|
|
|
80
88
|
padding: 0 8px;
|
|
81
89
|
border-radius: var(--mdc-filled-text-field-container-shape);
|
|
82
90
|
|
|
83
|
-
[dir=
|
|
91
|
+
[dir='rtl'] & {
|
|
84
92
|
padding: 0 8px;
|
|
85
93
|
}
|
|
86
94
|
}
|
|
@@ -104,10 +112,6 @@
|
|
|
104
112
|
padding: 0 12px;
|
|
105
113
|
line-height: 24px;
|
|
106
114
|
|
|
107
|
-
.gui-list-item-title {
|
|
108
|
-
flex: 1;
|
|
109
|
-
}
|
|
110
|
-
|
|
111
115
|
&::before {
|
|
112
116
|
position: absolute;
|
|
113
117
|
left: 0;
|
|
@@ -115,6 +119,20 @@
|
|
|
115
119
|
height: 16px;
|
|
116
120
|
background-color: var(--mat-expansion-header-text-color);
|
|
117
121
|
content: '';
|
|
122
|
+
|
|
123
|
+
[dir='rtl'] & {
|
|
124
|
+
left: auto;
|
|
125
|
+
right: 0;
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.gui-list-item-title {
|
|
131
|
+
flex: 1;
|
|
132
|
+
cursor: pointer;
|
|
133
|
+
|
|
134
|
+
.gui-list-item-active & {
|
|
135
|
+
font-weight: bold;
|
|
118
136
|
}
|
|
119
137
|
}
|
|
120
138
|
|
package/interface.d.ts
CHANGED
package/package.json
CHANGED
package/select/select.scss
CHANGED
|
@@ -4,10 +4,15 @@
|
|
|
4
4
|
|
|
5
5
|
.mat-mdc-option {
|
|
6
6
|
min-height: var(--mat-option-label-text-line-height);
|
|
7
|
-
padding: 0 8px;
|
|
7
|
+
padding: 0 8px !important;
|
|
8
8
|
|
|
9
9
|
.mat-pseudo-checkbox-full {
|
|
10
10
|
margin-right: 8px;
|
|
11
|
+
|
|
12
|
+
[dir='rtl'] & {
|
|
13
|
+
margin-right: 0;
|
|
14
|
+
margin-left: 8px;
|
|
15
|
+
}
|
|
11
16
|
}
|
|
12
17
|
}
|
|
13
18
|
|