@smartbit4all/ng-client 4.5.32 → 4.5.34
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/session/smart-error-catching.interceptor.mjs +3 -3
- package/esm2022/lib/session/smart-session.service.mjs +48 -23
- package/esm2022/lib/smart-form/api/model/models.mjs +1 -1
- package/esm2022/lib/view-context/api/api/view.service.mjs +46 -1
- package/esm2022/lib/view-context/api/model/models.mjs +2 -1
- package/esm2022/lib/view-context/api/model/publishedViewData.mjs +13 -0
- package/esm2022/lib/view-context/api/model/view.mjs +1 -1
- package/esm2022/lib/view-context/api/model/viewData.mjs +1 -1
- package/fesm2022/smartbit4all-ng-client.mjs +426 -345
- package/fesm2022/smartbit4all-ng-client.mjs.map +1 -1
- package/lib/session/smart-error-catching.interceptor.d.ts +2 -1
- package/lib/session/smart-session.service.d.ts +18 -1
- package/lib/view-context/api/api/view.service.d.ts +20 -0
- package/lib/view-context/api/model/models.d.ts +1 -0
- package/lib/view-context/api/model/publishedViewData.d.ts +14 -0
- package/lib/view-context/api/model/view.d.ts +1 -0
- package/lib/view-context/api/model/viewData.d.ts +1 -0
- package/package.json +1 -1
- package/smartbit4all-ng-client-4.5.34.tgz +0 -0
- package/smartbit4all-ng-client-4.5.32.tgz +0 -0
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';
|
|
2
2
|
import { Observable } from 'rxjs';
|
|
3
|
-
import { SessionError
|
|
3
|
+
import { SessionError } from './smart-session-handler.service';
|
|
4
|
+
import { SmartSessionService } from './smart-session.service';
|
|
4
5
|
import { SmartBackendBootstrapService } from './smart-backend-bootstrap.service';
|
|
5
6
|
import * as i0 from "@angular/core";
|
|
6
7
|
export declare class SmartErrorCatchingInterceptor implements HttpInterceptor {
|
|
@@ -58,8 +58,25 @@ export declare class SmartSessionService implements OnDestroy {
|
|
|
58
58
|
getSession(): Promise<SessionInfoData>;
|
|
59
59
|
refreshSession(): Promise<SessionInfoData>;
|
|
60
60
|
private doRefreshSession;
|
|
61
|
+
/**
|
|
62
|
+
* Runs the standard session-restart handling for a refresh that finished
|
|
63
|
+
* without an error HTTP response (no refresh token, or an empty refresh
|
|
64
|
+
* result), then throws a failure shaped like the backend's rejected refresh.
|
|
65
|
+
*
|
|
66
|
+
* Only the paths that do NOT produce an error HTTP response come here: a
|
|
67
|
+
* refresh call that fails with a session error is already handled by the
|
|
68
|
+
* SmartErrorCatchingInterceptor, so routing it through here too would invoke
|
|
69
|
+
* handleSessionError a second time.
|
|
70
|
+
*/
|
|
71
|
+
private failRefresh;
|
|
72
|
+
/**
|
|
73
|
+
* Builds a failure shaped exactly like the backend's rejected-refresh
|
|
74
|
+
* response (HTTP 400 + ApiError.code === 'session.refreshtoken.invalid'), so a
|
|
75
|
+
* failed/impossible refresh surfaces like any other invalid refresh token
|
|
76
|
+
* instead of producing a fresh session as a refresh side effect.
|
|
77
|
+
*/
|
|
78
|
+
private createRefreshFailedError;
|
|
61
79
|
private updateSessionInfo;
|
|
62
|
-
private isInvalidRefreshTokenError;
|
|
63
80
|
getAuthenticationProviders(): Promise<Array<AuthenticationProviderData>>;
|
|
64
81
|
getIsAuthenticated(): Promise<boolean>;
|
|
65
82
|
is2FANecessary(): Promise<boolean>;
|
|
@@ -3,6 +3,7 @@ import { Observable } from 'rxjs';
|
|
|
3
3
|
import { ComponentModel } from '../model/componentModel';
|
|
4
4
|
import { DataChange } from '../model/dataChange';
|
|
5
5
|
import { MessageResult } from '../model/messageResult';
|
|
6
|
+
import { PublishedViewData } from '../model/publishedViewData';
|
|
6
7
|
import { UiActionRequest } from '../model/uiActionRequest';
|
|
7
8
|
import { ViewConstraint } from '../model/viewConstraint';
|
|
8
9
|
import { ViewContextChange } from '../model/viewContextChange';
|
|
@@ -132,6 +133,25 @@ export declare class ViewService {
|
|
|
132
133
|
httpHeaderAccept?: 'application/json';
|
|
133
134
|
context?: HttpContext;
|
|
134
135
|
}): Observable<HttpEvent<ViewContextChange>>;
|
|
136
|
+
/**
|
|
137
|
+
* Get Published View Data
|
|
138
|
+
* @param channel Smartlink\'s channel.
|
|
139
|
+
* @param uuid Smartlink\'s unique identifier. Not a UUID anymore.
|
|
140
|
+
* @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
|
|
141
|
+
* @param reportProgress flag to report request and response progress.
|
|
142
|
+
*/
|
|
143
|
+
getPublishedViewData(channel: string, uuid: string, observe?: 'body', reportProgress?: boolean, options?: {
|
|
144
|
+
httpHeaderAccept?: 'application/json';
|
|
145
|
+
context?: HttpContext;
|
|
146
|
+
}): Observable<PublishedViewData>;
|
|
147
|
+
getPublishedViewData(channel: string, uuid: string, observe?: 'response', reportProgress?: boolean, options?: {
|
|
148
|
+
httpHeaderAccept?: 'application/json';
|
|
149
|
+
context?: HttpContext;
|
|
150
|
+
}): Observable<HttpResponse<PublishedViewData>>;
|
|
151
|
+
getPublishedViewData(channel: string, uuid: string, observe?: 'events', reportProgress?: boolean, options?: {
|
|
152
|
+
httpHeaderAccept?: 'application/json';
|
|
153
|
+
context?: HttpContext;
|
|
154
|
+
}): Observable<HttpEvent<PublishedViewData>>;
|
|
135
155
|
/**
|
|
136
156
|
* Returns the view constraint object belongs to the given view
|
|
137
157
|
* @param uuid View\'s unique identifier.
|
|
@@ -23,6 +23,7 @@ export * from './multiComboBoxElement';
|
|
|
23
23
|
export * from './multiComboBoxModel';
|
|
24
24
|
export * from './namedValidator';
|
|
25
25
|
export * from './openPendingData';
|
|
26
|
+
export * from './publishedViewData';
|
|
26
27
|
export * from './serverRequestExecutionStat';
|
|
27
28
|
export * from './serverRequestTrack';
|
|
28
29
|
export * from './serverRequestType';
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* View API
|
|
3
|
+
* View API
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
* Contact: info@it4all.hu
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
export interface PublishedViewData {
|
|
13
|
+
isPublic?: boolean;
|
|
14
|
+
}
|
package/package.json
CHANGED
|
Binary file
|
|
Binary file
|