@tsi-developpement/tsi-shared-ui 1.9.1 → 1.9.3
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/lib/tsi-components/create-or-edit-entity-informations/create-or-edit-entity-informations.component.mjs +1 -1
- package/esm2022/lib/tsi-components/create-or-edit-modele-import/create-or-edit-modele-import.component.mjs +3 -3
- package/esm2022/lib/tsi-components/input-components/editable-grid/editable-grid.component.mjs +5 -21
- package/esm2022/lib/tsi-components/input-components/tsi-rate-input/tsi-rate-input.component.mjs +41 -12
- package/esm2022/lib/tsi-components/output-components/tsi-rate-display/tsi-rate-display.component.mjs +15 -5
- package/esm2022/lib/tsi-components/tsi-action-erp-create-or-edit/tsi-action-erp-create-or-edit.component.mjs +1 -1
- package/fesm2022/tsi-developpement-tsi-shared-ui.mjs +62 -39
- package/fesm2022/tsi-developpement-tsi-shared-ui.mjs.map +1 -1
- package/lib/consts/app-providers.d.ts +1 -1
- package/lib/providers/shared-ui-tsi.provider.d.ts +1 -1
- package/lib/tsi-components/input-components/editable-grid/editable-grid.component.d.ts +1 -7
- package/lib/tsi-components/input-components/tsi-rate-input/tsi-rate-input.component.d.ts +24 -3
- package/lib/tsi-components/output-components/tsi-rate-display/tsi-rate-display.component.d.ts +7 -1
- package/package.json +1 -1
|
@@ -3,4 +3,4 @@ import { FormStateService } from "../services/form/form-state.service";
|
|
|
3
3
|
import { PresentationDesignerBaseService } from "../services/presentation-setting/presentation-designer-base.service";
|
|
4
4
|
import { GenericValidationStateService } from "../services/validation/generic-validation-state.service";
|
|
5
5
|
import { InputRegistryService } from "../services/validation/input-registry.service";
|
|
6
|
-
export declare const appProviders: (typeof PresentationDesignerBaseService | typeof
|
|
6
|
+
export declare const appProviders: (typeof PresentationDesignerBaseService | typeof GenericValidationStateService | typeof InputRegistryService | typeof DynamicFormService | typeof FormStateService)[];
|
|
@@ -2,7 +2,7 @@ import { DynamicDialogConfig, DynamicDialogRef } from "primeng/dynamicdialog";
|
|
|
2
2
|
import { TabView } from "primeng/tabview";
|
|
3
3
|
import { JwtHelperService } from "@auth0/angular-jwt";
|
|
4
4
|
import { ConfirmationService, MessageService } from "primeng/api";
|
|
5
|
-
export declare const SharedUiTsiProviders: (typeof TabView | typeof
|
|
5
|
+
export declare const SharedUiTsiProviders: (typeof TabView | typeof DynamicDialogRef | typeof DynamicDialogConfig | typeof JwtHelperService | typeof MessageService | typeof ConfirmationService | {
|
|
6
6
|
provide: import("@angular/core").InjectionToken<unknown>;
|
|
7
7
|
useValue: import("@angular/core").InjectionToken<unknown>;
|
|
8
8
|
})[];
|
|
@@ -80,7 +80,6 @@ export declare class EditableGridComponent extends TsiInputBase implements OnIni
|
|
|
80
80
|
get gridData(): Array<any>;
|
|
81
81
|
isTableLoading?: boolean;
|
|
82
82
|
parent: any;
|
|
83
|
-
events?: Observable<void>;
|
|
84
83
|
showSaveButton: boolean;
|
|
85
84
|
showActionColumn: boolean;
|
|
86
85
|
enableRowDisabling: boolean;
|
|
@@ -98,10 +97,6 @@ export declare class EditableGridComponent extends TsiInputBase implements OnIni
|
|
|
98
97
|
orderColumn: string;
|
|
99
98
|
deleteLineButtonDisabled: (item: any) => any;
|
|
100
99
|
showDuplicateButton: boolean;
|
|
101
|
-
itemsSave: EventEmitter<any[]>;
|
|
102
|
-
/**
|
|
103
|
-
*
|
|
104
|
-
*/
|
|
105
100
|
refreshEventEmitter: EventEmitter<any>;
|
|
106
101
|
saveDataEventEmitter: EventEmitter<any>;
|
|
107
102
|
rowChangedEventEmitter: EventEmitter<any>;
|
|
@@ -137,7 +132,6 @@ export declare class EditableGridComponent extends TsiInputBase implements OnIni
|
|
|
137
132
|
isDeleteButtonDisabled(item: any): any;
|
|
138
133
|
ngOnDestroy(): void;
|
|
139
134
|
private _onColumnsChanged;
|
|
140
|
-
inputChanged(col: GridColumn): void;
|
|
141
135
|
saveItems(): void;
|
|
142
136
|
addRow(): void;
|
|
143
137
|
duplicateRow(item: any, updateSelection?: boolean, skipEmit?: boolean): RowAddedResult | null;
|
|
@@ -174,5 +168,5 @@ export declare class EditableGridComponent extends TsiInputBase implements OnIni
|
|
|
174
168
|
private _cleanGridDataForEmit;
|
|
175
169
|
private _getShadowSearchColumnLabel;
|
|
176
170
|
static ɵfac: i0.ɵɵFactoryDeclaration<EditableGridComponent, never>;
|
|
177
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<EditableGridComponent, "Tsi-Generic-Editable-Grid", never, { "selectedItems": { "alias": "selectedItems"; "required": false; }; "configuration": { "alias": "configuration"; "required": false; }; "key": { "alias": "key"; "required": false; }; "items": { "alias": "items"; "required": false; }; "saveEvent": { "alias": "
|
|
171
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<EditableGridComponent, "Tsi-Generic-Editable-Grid", never, { "selectedItems": { "alias": "selectedItems"; "required": false; }; "configuration": { "alias": "configuration"; "required": false; }; "key": { "alias": "key"; "required": false; }; "items": { "alias": "items"; "required": false; }; "saveEvent": { "alias": "saveEvent"; "required": false; }; "showGlobalSearch": { "alias": "showGlobalSearch"; "required": false; }; "showAddButton": { "alias": "showAddButton"; "required": false; }; "showDeleteButton": { "alias": "showDeleteButton"; "required": false; }; "showEditButton": { "alias": "showEditButton"; "required": false; }; "showRowSummary": { "alias": "showRowSummary"; "required": false; }; "scrollHeight": { "alias": "scrollHeight"; "required": false; }; "rowPerPage": { "alias": "rowPerPage"; "required": false; }; "pageSize": { "alias": "pageSize"; "required": false; }; "entityPrimaryKeyName": { "alias": "entityPrimaryKeyName"; "required": false; }; "columns": { "alias": "columns"; "required": false; }; "gridData": { "alias": "gridData"; "required": false; }; "isTableLoading": { "alias": "isTableLoading"; "required": false; }; "parent": { "alias": "parent"; "required": false; }; "showSaveButton": { "alias": "showSaveButton"; "required": false; }; "showActionColumn": { "alias": "showActionColumn"; "required": false; }; "enableRowDisabling": { "alias": "enableRowDisabling"; "required": false; }; "rowSummaryConfig": { "alias": "rowSummaryConfig"; "required": false; }; "showHaveSumary": { "alias": "showHaveSumary"; "required": false; }; "showRowSumary": { "alias": "showRowSumary"; "required": false; }; "selectKeyOnly": { "alias": "selectKeyOnly"; "required": false; }; "selectionMode": { "alias": "selectionMode"; "required": false; }; "showConsultButton": { "alias": "showConsultButton"; "required": false; }; "editableGridBusinessClass": { "alias": "editableGridBusinessClass"; "required": false; }; "orderColumn": { "alias": "orderColumn"; "required": false; }; "deleteLineButtonDisabled": { "alias": "deleteLineButtonDisabled"; "required": false; }; "showDuplicateButton": { "alias": "showDuplicateButton"; "required": false; }; "id": { "alias": "id"; "required": false; }; }, { "refreshEventEmitter": "refreshEventEmitter"; "saveDataEventEmitter": "saveDataEventEmitter"; "rowChangedEventEmitter": "rowChangedEventEmitter"; "selectedRowEventEmitter": "selectedRowEventEmitter"; "addedRowEventEmitter": "addedRowEventEmitter"; "focusOutEventEmitter": "focusOutEventEmitter"; "cellChanged": "cellChanged"; "rowDeletedEventEmitter": "rowDeletedEventEmitter"; "selectedItemsChange": "selectedItemsChange"; "onRowSelect": "onRowSelect"; "focusOutRow": "focusOutRow"; "onConsultClicked": "onConsultClicked"; "rowDuplicatedEventEmitter": "rowDuplicatedEventEmitter"; }, never, never, false, never>;
|
|
178
172
|
}
|
|
@@ -1,16 +1,37 @@
|
|
|
1
|
-
import { EventEmitter
|
|
1
|
+
import { EventEmitter } from '@angular/core';
|
|
2
2
|
import { TsiInputBase } from '../../../tsi-base/tsi-input-base/tsi-input-base.component';
|
|
3
3
|
import * as i0 from "@angular/core";
|
|
4
|
-
export declare class TsiRateInputComponent extends TsiInputBase<number | undefined>
|
|
4
|
+
export declare class TsiRateInputComponent extends TsiInputBase<number | undefined> {
|
|
5
5
|
required?: boolean;
|
|
6
|
+
/**
|
|
7
|
+
* Governs how the percentage the user sees/edits relates to the value stored in the model.
|
|
8
|
+
* The user always reads and types a percentage; this flag only changes what is persisted.
|
|
9
|
+
*
|
|
10
|
+
* - false (default): "2 %" on screen is stored as the whole percent `2`.
|
|
11
|
+
* - true : "2 %" on screen is stored as the fraction `0.02`.
|
|
12
|
+
*
|
|
13
|
+
* Must match the `isFraction` given to the mirror `Tsi-Rate-Display` so the pair
|
|
14
|
+
* interprets a stored value identically.
|
|
15
|
+
*/
|
|
6
16
|
isFraction?: boolean;
|
|
7
17
|
numOfDecimal?: number;
|
|
8
18
|
newItemEvent: EventEmitter<number>;
|
|
9
19
|
inputFieldChange: EventEmitter<number>;
|
|
10
20
|
private isValueChanged;
|
|
11
|
-
|
|
21
|
+
/**
|
|
22
|
+
* The percentage shown in / typed into the p-inputNumber. It is a view-only
|
|
23
|
+
* projection of the stored model value (`inputField`), converted according to
|
|
24
|
+
* `isFraction`. The model remains the single source of truth.
|
|
25
|
+
*/
|
|
26
|
+
get displayValue(): number | undefined;
|
|
12
27
|
valueChanged(event: any): void;
|
|
13
28
|
onChangeofOptions(): void;
|
|
29
|
+
/** stored model value -> on-screen percentage */
|
|
30
|
+
private toDisplay;
|
|
31
|
+
/** on-screen percentage -> stored model value */
|
|
32
|
+
private toModel;
|
|
33
|
+
/** Rounds to a fixed number of decimals, guarding against binary-float drift introduced by the x100 conversion. */
|
|
34
|
+
private round;
|
|
14
35
|
static ɵfac: i0.ɵɵFactoryDeclaration<TsiRateInputComponent, never>;
|
|
15
36
|
static ɵcmp: i0.ɵɵComponentDeclaration<TsiRateInputComponent, "Tsi-Rate-Input", never, { "required": { "alias": "required"; "required": false; }; "isFraction": { "alias": "isFraction"; "required": false; }; "numOfDecimal": { "alias": "numOfDecimal"; "required": false; }; }, { "newItemEvent": "newItemEvent"; "inputFieldChange": "inputFieldChange"; }, never, never, false, never>;
|
|
16
37
|
}
|
package/lib/tsi-components/output-components/tsi-rate-display/tsi-rate-display.component.d.ts
CHANGED
|
@@ -3,11 +3,17 @@ import * as i0 from "@angular/core";
|
|
|
3
3
|
export declare class TsiRateDisplayComponent {
|
|
4
4
|
private _localizationService;
|
|
5
5
|
protected locale: LocaleCode;
|
|
6
|
+
/**
|
|
7
|
+
* How to interpret `inputData` as a percentage. Must match the `isFraction`
|
|
8
|
+
* of the mirror `Tsi-Rate-Input`.
|
|
9
|
+
* - false (default): `inputData` is a whole percent (`2` shows as "2 %").
|
|
10
|
+
* - true : `inputData` is a fraction (`0.02` shows as "2 %").
|
|
11
|
+
*/
|
|
6
12
|
isFraction: boolean;
|
|
7
13
|
inputData?: number;
|
|
8
14
|
numOfDecimal?: number;
|
|
9
15
|
constructor();
|
|
10
|
-
getToFraction(): number;
|
|
16
|
+
getToFraction(): number | null;
|
|
11
17
|
getFormat(): string;
|
|
12
18
|
static ɵfac: i0.ɵɵFactoryDeclaration<TsiRateDisplayComponent, never>;
|
|
13
19
|
static ɵcmp: i0.ɵɵComponentDeclaration<TsiRateDisplayComponent, "Tsi-Rate-Display", never, { "isFraction": { "alias": "isFraction"; "required": false; }; "inputData": { "alias": "inputData"; "required": false; }; "numOfDecimal": { "alias": "numOfDecimal"; "required": false; }; }, {}, never, never, false, never>;
|