@trudb/tru-common-lib 0.0.179 → 0.0.181
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/esm2020/lib/components/toolbar/tru-toolbar-module.mjs +21 -3
- package/esm2020/lib/services/tru-predicate-map.mjs +11 -0
- package/esm2020/lib/services/tru-text-manager.mjs +134 -0
- package/esm2020/lib/services/tru-user.mjs +54 -0
- package/esm2020/public-api.mjs +22 -2
- package/fesm2015/trudb-tru-common-lib.mjs +213 -3
- package/fesm2015/trudb-tru-common-lib.mjs.map +1 -1
- package/fesm2020/trudb-tru-common-lib.mjs +213 -3
- package/fesm2020/trudb-tru-common-lib.mjs.map +1 -1
- package/lib/components/toolbar/tru-toolbar-module.d.ts +1 -1
- package/lib/services/tru-predicate-map.d.ts +6 -0
- package/lib/services/tru-text-manager.d.ts +68 -0
- package/lib/services/tru-user.d.ts +21 -0
- package/package.json +1 -1
- package/public-api.d.ts +21 -1
|
@@ -10,6 +10,6 @@ import * as i8 from "./context-filter/tru-toolbar-context-filter-module";
|
|
|
10
10
|
import * as i9 from "./text/tru-toolbar-text-module";
|
|
11
11
|
export declare class TruToolbarModule {
|
|
12
12
|
static ɵfac: i0.ɵɵFactoryDeclaration<TruToolbarModule, never>;
|
|
13
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<TruToolbarModule, [typeof i1.TruToolbar], [typeof i2.CommonModule, typeof i3.FormsModule, typeof i4.TruToolbarMenuModule, typeof i5.TruToolbarButtonModule, typeof i6.TruToolbarDropdownModule, typeof i7.TruToolbarSeparatorModule, typeof i8.TruToolbarContextFilterModule, typeof i9.TruToolbarTextModule], [typeof i1.TruToolbar]>;
|
|
13
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<TruToolbarModule, [typeof i1.TruToolbar], [typeof i2.CommonModule, typeof i3.FormsModule, typeof i4.TruToolbarMenuModule, typeof i5.TruToolbarButtonModule, typeof i6.TruToolbarDropdownModule, typeof i7.TruToolbarSeparatorModule, typeof i8.TruToolbarContextFilterModule, typeof i9.TruToolbarTextModule], [typeof i1.TruToolbar, typeof i4.TruToolbarMenuModule, typeof i5.TruToolbarButtonModule, typeof i6.TruToolbarDropdownModule, typeof i7.TruToolbarSeparatorModule, typeof i8.TruToolbarContextFilterModule, typeof i9.TruToolbarTextModule]>;
|
|
14
14
|
static ɵinj: i0.ɵɵInjectorDeclaration<TruToolbarModule>;
|
|
15
15
|
}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class TruTextManager {
|
|
3
|
+
readonly msgModifierKeyLabel: string;
|
|
4
|
+
readonly msgConfirmExitWithChangesPending: string;
|
|
5
|
+
readonly msgDeleteSuccessful: string;
|
|
6
|
+
readonly msgSaveSuccessful: string;
|
|
7
|
+
readonly msgNoChangesToSave: string;
|
|
8
|
+
readonly msgSaveInProgress: string;
|
|
9
|
+
readonly msgInvalidData: string;
|
|
10
|
+
readonly msgDirtyPreventsReadOnly: string;
|
|
11
|
+
readonly msgDirtyPreventsNavigate: string;
|
|
12
|
+
readonly msgDirtyPreventsClose: string;
|
|
13
|
+
readonly msgDirtyPreventsDeleteExistingRecord: string;
|
|
14
|
+
readonly msgNoDeleteAccess: string;
|
|
15
|
+
readonly msgCannotDeleteNewAndExistingRecords: string;
|
|
16
|
+
readonly msgDeleteReferencingRecordsFirst: string;
|
|
17
|
+
constructor();
|
|
18
|
+
/**
|
|
19
|
+
* If text.length exceeds length, then returns a string that is the first length chars
|
|
20
|
+
* of text plus suffix. Otherwise, returns text.
|
|
21
|
+
* @param {string} text
|
|
22
|
+
* @param {number} length
|
|
23
|
+
* @param {string} suffix
|
|
24
|
+
* @return {string}
|
|
25
|
+
*/
|
|
26
|
+
private truncate;
|
|
27
|
+
isMac: () => boolean;
|
|
28
|
+
/**
|
|
29
|
+
* Formats the text to use for the window title.
|
|
30
|
+
* @param {string} text
|
|
31
|
+
* @return {string} - Window title.
|
|
32
|
+
*/
|
|
33
|
+
formatWindowTitle: (text: string) => string;
|
|
34
|
+
/**
|
|
35
|
+
* Returns a message indicating that an entity or entities were deleted in another view.
|
|
36
|
+
* @param {string} entityTypeLabel - Description of the entity type.
|
|
37
|
+
* @param [{string}] entityTypePluralLabel - Description of more than one of the entity type.
|
|
38
|
+
* @param [{number}] count - Number of entities.
|
|
39
|
+
*/
|
|
40
|
+
fmtEntityDeletedInOtherView: (entityTypeLabel: string, entityTypePluralLabel: string, count: number) => string;
|
|
41
|
+
/**
|
|
42
|
+
* Returns a message used to confirm deletion of an entity or entities.
|
|
43
|
+
* @param {string} entityTypeLabel - Description of the entity type.
|
|
44
|
+
* @param [{string}] entityTypePluralLabel - Description of more than one of the entity type.
|
|
45
|
+
* @param [{number}] count - Number of entities.
|
|
46
|
+
*/
|
|
47
|
+
fmtDeleteConfirmation: (entityTypeLabel: string, entityTypePluralLabel?: string | null, count?: number | null) => string;
|
|
48
|
+
/**
|
|
49
|
+
* Returns a message formatted from an error object.
|
|
50
|
+
* @param {error|string} error
|
|
51
|
+
* @returns {string}
|
|
52
|
+
*/
|
|
53
|
+
fmtErrorToShow: (error: any) => string;
|
|
54
|
+
/**
|
|
55
|
+
* Returns a message formatted from an exception object.
|
|
56
|
+
* @param {object} exception
|
|
57
|
+
* @returns {string}
|
|
58
|
+
*/
|
|
59
|
+
fmtExceptionToShow: (exception: any) => string;
|
|
60
|
+
/**
|
|
61
|
+
* Returns a message for a data error type.
|
|
62
|
+
* @param {string} typeName
|
|
63
|
+
* @returns {string}
|
|
64
|
+
*/
|
|
65
|
+
fmtDataError: (typeName: string) => string;
|
|
66
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<TruTextManager, never>;
|
|
67
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<TruTextManager>;
|
|
68
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
export declare class TruUser {
|
|
3
|
+
private _ref;
|
|
4
|
+
private _username;
|
|
5
|
+
private _firstName;
|
|
6
|
+
private _lastName;
|
|
7
|
+
private _roles;
|
|
8
|
+
constructor();
|
|
9
|
+
get activeUserRef(): number;
|
|
10
|
+
set activeUserRef(ref: number);
|
|
11
|
+
get username(): string | null;
|
|
12
|
+
set username(username: string | null);
|
|
13
|
+
get firstName(): string | null;
|
|
14
|
+
set firstName(firstName: string | null);
|
|
15
|
+
get lastName(): string | null;
|
|
16
|
+
set lastName(lastName: string | null);
|
|
17
|
+
set roles(roles: string[] | null);
|
|
18
|
+
hasRoles: (roles: string[]) => boolean;
|
|
19
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<TruUser, never>;
|
|
20
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<TruUser>;
|
|
21
|
+
}
|
package/package.json
CHANGED
package/public-api.d.ts
CHANGED
|
@@ -14,8 +14,28 @@ export * from "./lib/components/export-dialog/tru-export-dialog";
|
|
|
14
14
|
export * from "./lib/components/export-dialog/tru-export-dialog-module";
|
|
15
15
|
export * from "./lib/components/toolbar/tru-toolbar";
|
|
16
16
|
export * from "./lib/components/toolbar/tru-toolbar-module";
|
|
17
|
-
export * from
|
|
17
|
+
export * from "./lib/components/toolbar/menu/tru-toolbar-menu";
|
|
18
|
+
export * from "./lib/components/toolbar/menu/tru-toolbar-menu-module";
|
|
19
|
+
export * from "./lib/components/toolbar/button/tru-toolbar-button";
|
|
20
|
+
export * from "./lib/components/toolbar/button/tru-toolbar-button-module";
|
|
21
|
+
export * from "./lib/components/toolbar/dropdown/tru-toolbar-dropdown";
|
|
22
|
+
export * from "./lib/components/toolbar/dropdown/tru-toolbar-dropdown-module";
|
|
23
|
+
export * from "./lib/components/toolbar/separator/tru-toolbar-separator";
|
|
24
|
+
export * from "./lib/components/toolbar/separator/tru-toolbar-separator-module";
|
|
25
|
+
export * from "./lib/components/toolbar/context-filter/tru-toolbar-context-filter";
|
|
26
|
+
export * from "./lib/components/toolbar/context-filter/tru-toolbar-context-filter-module";
|
|
27
|
+
export * from "./lib/components/toolbar/text/tru-toolbar-text";
|
|
28
|
+
export * from "./lib/components/toolbar/text/tru-toolbar-text-module";
|
|
29
|
+
export * from './lib/services/tru-app-environment';
|
|
30
|
+
export * from './lib/services/tru-breeze-context-factory';
|
|
18
31
|
export * from './lib/services/tru-component-lookup';
|
|
32
|
+
export * from './lib/services/tru-data-context';
|
|
33
|
+
export * from './lib/services/tru-entity-accessor';
|
|
34
|
+
export * from './lib/services/tru-predicate-map';
|
|
35
|
+
export * from './lib/services/tru-text-manager';
|
|
36
|
+
export * from './lib/services/tru-ui-notification';
|
|
37
|
+
export * from './lib/services/tru-user';
|
|
38
|
+
export * from './lib/services/tru-search-group-event-handler';
|
|
19
39
|
export * from './lib/services/tru-window-action-event-handler';
|
|
20
40
|
export * from './lib/services/tru-window-event-handler';
|
|
21
41
|
export * from "./lib/assets/tru-search-icon-module";
|