@cccteam/ccc-lib 0.0.14 → 0.0.16

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.
Files changed (58) hide show
  1. package/README.md +38 -13
  2. package/fesm2022/cccteam-ccc-lib-src-auth-authentication-guard.mjs.map +1 -1
  3. package/fesm2022/cccteam-ccc-lib-src-auth-authorization-guard.mjs.map +1 -1
  4. package/fesm2022/cccteam-ccc-lib-src-auth-forms.mjs +15 -49
  5. package/fesm2022/cccteam-ccc-lib-src-auth-forms.mjs.map +1 -1
  6. package/fesm2022/cccteam-ccc-lib-src-auth-has-permission.mjs +4 -4
  7. package/fesm2022/cccteam-ccc-lib-src-auth-has-permission.mjs.map +1 -1
  8. package/fesm2022/cccteam-ccc-lib-src-auth-service.mjs +16 -22
  9. package/fesm2022/cccteam-ccc-lib-src-auth-service.mjs.map +1 -1
  10. package/fesm2022/cccteam-ccc-lib-src-ccc-camel-case-to-title.mjs +33 -0
  11. package/fesm2022/cccteam-ccc-lib-src-ccc-camel-case-to-title.mjs.map +1 -0
  12. package/fesm2022/cccteam-ccc-lib-src-ccc-grid.mjs +256 -0
  13. package/fesm2022/cccteam-ccc-lib-src-ccc-grid.mjs.map +1 -0
  14. package/fesm2022/cccteam-ccc-lib-src-ccc-resource.mjs +3129 -0
  15. package/fesm2022/cccteam-ccc-lib-src-ccc-resource.mjs.map +1 -0
  16. package/fesm2022/cccteam-ccc-lib-src-forms.mjs +79 -0
  17. package/fesm2022/cccteam-ccc-lib-src-forms.mjs.map +1 -0
  18. package/fesm2022/cccteam-ccc-lib-src-internal-types.mjs +6 -0
  19. package/fesm2022/cccteam-ccc-lib-src-internal-types.mjs.map +1 -0
  20. package/fesm2022/cccteam-ccc-lib-src-types.mjs +406 -112
  21. package/fesm2022/cccteam-ccc-lib-src-types.mjs.map +1 -1
  22. package/fesm2022/cccteam-ccc-lib-src-ui-alert.mjs +3 -3
  23. package/fesm2022/cccteam-ccc-lib-src-ui-alert.mjs.map +1 -1
  24. package/fesm2022/cccteam-ccc-lib-src-ui-core-service.mjs +7 -7
  25. package/fesm2022/cccteam-ccc-lib-src-ui-core-service.mjs.map +1 -1
  26. package/fesm2022/cccteam-ccc-lib-src-ui-idle-service.mjs +157 -0
  27. package/fesm2022/cccteam-ccc-lib-src-ui-idle-service.mjs.map +1 -0
  28. package/fesm2022/cccteam-ccc-lib-src-ui-interceptor.mjs +4 -4
  29. package/fesm2022/cccteam-ccc-lib-src-ui-interceptor.mjs.map +1 -1
  30. package/fesm2022/cccteam-ccc-lib-src-ui-notification-service.mjs +5 -5
  31. package/fesm2022/cccteam-ccc-lib-src-ui-notification-service.mjs.map +1 -1
  32. package/fesm2022/cccteam-ccc-lib-src-ui-sidenav.mjs +4 -4
  33. package/fesm2022/cccteam-ccc-lib-src-ui-sidenav.mjs.map +1 -1
  34. package/fesm2022/cccteam-ccc-lib-src-util-request-options.mjs.map +1 -1
  35. package/fesm2022/cccteam-ccc-lib.mjs +4434 -12
  36. package/fesm2022/cccteam-ccc-lib.mjs.map +1 -1
  37. package/package.json +44 -18
  38. package/{src/auth-forms/index.d.ts → types/cccteam-ccc-lib-src-auth-forms.d.ts} +1 -18
  39. package/{src/auth-service/index.d.ts → types/cccteam-ccc-lib-src-auth-service.d.ts} +3 -1
  40. package/types/cccteam-ccc-lib-src-ccc-camel-case-to-title.d.ts +10 -0
  41. package/types/cccteam-ccc-lib-src-ccc-grid.d.ts +35 -0
  42. package/types/cccteam-ccc-lib-src-ccc-resource.d.ts +674 -0
  43. package/types/cccteam-ccc-lib-src-forms.d.ts +27 -0
  44. package/types/cccteam-ccc-lib-src-internal-types.d.ts +1 -0
  45. package/types/cccteam-ccc-lib-src-types.d.ts +934 -0
  46. package/types/cccteam-ccc-lib-src-ui-idle-service.d.ts +49 -0
  47. package/types/cccteam-ccc-lib.d.ts +1877 -0
  48. package/index.d.ts +0 -12
  49. package/src/types/index.d.ts +0 -133
  50. /package/{src/auth-authentication-guard/index.d.ts → types/cccteam-ccc-lib-src-auth-authentication-guard.d.ts} +0 -0
  51. /package/{src/auth-authorization-guard/index.d.ts → types/cccteam-ccc-lib-src-auth-authorization-guard.d.ts} +0 -0
  52. /package/{src/auth-has-permission/index.d.ts → types/cccteam-ccc-lib-src-auth-has-permission.d.ts} +0 -0
  53. /package/{src/ui-alert/index.d.ts → types/cccteam-ccc-lib-src-ui-alert.d.ts} +0 -0
  54. /package/{src/ui-core-service/index.d.ts → types/cccteam-ccc-lib-src-ui-core-service.d.ts} +0 -0
  55. /package/{src/ui-interceptor/index.d.ts → types/cccteam-ccc-lib-src-ui-interceptor.d.ts} +0 -0
  56. /package/{src/ui-notification-service/index.d.ts → types/cccteam-ccc-lib-src-ui-notification-service.d.ts} +0 -0
  57. /package/{src/ui-sidenav/index.d.ts → types/cccteam-ccc-lib-src-ui-sidenav.d.ts} +0 -0
  58. /package/{src/util-request-options/index.d.ts → types/cccteam-ccc-lib-src-util-request-options.d.ts} +0 -0
package/index.d.ts DELETED
@@ -1,12 +0,0 @@
1
- export * from '@cccteam/ccc-lib/src/auth-service';
2
- export * from '@cccteam/ccc-lib/src/ui-core-service';
3
- export * from '@cccteam/ccc-lib/src/auth-has-permission';
4
- export * from '@cccteam/ccc-lib/src/auth-forms';
5
- export * from '@cccteam/ccc-lib/src/auth-authentication-guard';
6
- export * from '@cccteam/ccc-lib/src/auth-authorization-guard';
7
- export * from '@cccteam/ccc-lib/src/util-request-options';
8
- export * from '@cccteam/ccc-lib/src/types';
9
- export * from '@cccteam/ccc-lib/src/ui-alert';
10
- export * from '@cccteam/ccc-lib/src/ui-sidenav';
11
- export * from '@cccteam/ccc-lib/src/ui-interceptor';
12
- export * from '@cccteam/ccc-lib/src/ui-notification-service';
@@ -1,133 +0,0 @@
1
- import { InjectionToken } from '@angular/core';
2
-
3
- declare enum AlertLevel {
4
- ERROR = "warn",
5
- INFO = "accent",
6
- SUCCESS = "success"
7
- }
8
- interface CreateNotificationMessage {
9
- duration?: number;
10
- message: string;
11
- link: string;
12
- level: AlertLevel;
13
- }
14
- interface NotificationMessage {
15
- id: number;
16
- duration?: number;
17
- message: string;
18
- link: string;
19
- level: AlertLevel;
20
- }
21
-
22
- declare namespace AuthenticationGuardAction {
23
- class SetRedirectUrl {
24
- redirectUrl: string;
25
- static readonly type = "[AuthenticationGuard] Set Redirect Url And Navigate To Login Page";
26
- constructor(redirectUrl: string);
27
- }
28
- class CheckUserSession {
29
- static readonly type = "[AuthenticationGuard] Check User Session";
30
- }
31
- }
32
- declare namespace LoginAction {
33
- class Logout {
34
- static readonly type = "[Login] Auto Logout";
35
- }
36
- class SetRedirectUrl {
37
- redirectUrl: string;
38
- static readonly type = "[Login] Set Redirect Url";
39
- constructor(redirectUrl: string);
40
- }
41
- class PublishError {
42
- message: CreateNotificationMessage;
43
- static readonly type = "[Login] Publish Error";
44
- constructor(message: CreateNotificationMessage);
45
- }
46
- }
47
- declare namespace AppAction {
48
- class CheckUserSession {
49
- static readonly type = "[App] Check User Session";
50
- }
51
- class SetRedirectUrl {
52
- redirectUrl: string;
53
- static readonly type = "[App] Set Redirect Url";
54
- constructor(redirectUrl: string);
55
- }
56
- class SetNavIdentifier {
57
- identifier: string;
58
- static readonly type = "[App] Set Nav Identifier";
59
- constructor(identifier: string);
60
- }
61
- }
62
-
63
- declare namespace ApiInterceptorAction {
64
- class BeginActivity {
65
- process: string;
66
- static readonly type = "[ApiInterceptor] Add Loading Activity";
67
- constructor(process: string);
68
- }
69
- class EndActivity {
70
- process: string;
71
- static readonly type = "[ApiInterceptor] Remove Loading Activity";
72
- constructor(process: string);
73
- }
74
- class PublishError {
75
- message: CreateNotificationMessage;
76
- static readonly type = "[ApiInterceptor] Publish Error";
77
- constructor(message: CreateNotificationMessage);
78
- }
79
- class SetRedirectUrl {
80
- redirectUrl: string;
81
- static readonly type = "[ApiInterceptor] Set Redirect Url";
82
- constructor(redirectUrl: string);
83
- }
84
- }
85
- declare namespace HeaderAction {
86
- class ToggleSidenav {
87
- static readonly type = "[Header] Toggle Sidenav";
88
- }
89
- class Logout {
90
- static readonly type = "[Header] User Logout";
91
- }
92
- }
93
-
94
- type Brand<K, T> = K & {
95
- __brand: T;
96
- };
97
- type Permission = Brand<string, 'Permission'>;
98
- type Resource = Brand<string, 'Resource'>;
99
- type Domain = Brand<string, 'Domain'>;
100
- type FieldName = Brand<string, 'FieldName'>;
101
- type Method = Brand<string, 'Method'>;
102
- type DomainPermissions = Record<Domain, Record<Resource, Record<Permission, Permissions>>>;
103
- interface PermissionScope {
104
- resource: Resource;
105
- permission: Permission;
106
- domain: Domain;
107
- }
108
- declare const ReadPermission: Permission;
109
- declare const UpdatePermission: Permission;
110
-
111
- /**
112
- * Session Information for a logged in user
113
- */
114
- interface SessionInfo {
115
- authenticated: boolean;
116
- username: string;
117
- permissions: DomainPermissions;
118
- }
119
-
120
- declare const BASE_URL: InjectionToken<string>;
121
- declare const API_URL: InjectionToken<string>;
122
- declare const PERMISSION_REQUIRED: InjectionToken<(resource: Resource, permission: Permission) => boolean>;
123
- declare const AVAILABLE_PERMISSIONS: InjectionToken<{
124
- Create: Permission;
125
- Delete: Permission;
126
- List: Permission;
127
- Read: Permission;
128
- Update: Permission;
129
- }>;
130
- declare const AVAILABLE_DOMAINS: InjectionToken<Record<string, Domain>[]>;
131
-
132
- export { API_URL, AVAILABLE_DOMAINS, AVAILABLE_PERMISSIONS, AlertLevel, ApiInterceptorAction, AppAction, AuthenticationGuardAction, BASE_URL, HeaderAction, LoginAction, PERMISSION_REQUIRED, ReadPermission, UpdatePermission };
133
- export type { CreateNotificationMessage, Domain, DomainPermissions, FieldName, Method, NotificationMessage, Permission, PermissionScope, Resource, SessionInfo };