fix(deps): Update dependencies to latest versions
This commit is contained in:
@@ -3,11 +3,11 @@ import * as domtools from '@design.estate/dees-domtools';
|
||||
|
||||
const appstate = new plugins.deesDomtools.plugins.smartstate.Smartstate();
|
||||
export interface ILoginState {
|
||||
jwt: string;
|
||||
identity: plugins.interfaces.data.IIdentity;
|
||||
}
|
||||
export const loginStatePart: plugins.smartstate.StatePart<unknown, ILoginState> = await appstate.getStatePart<ILoginState>(
|
||||
'login',
|
||||
{ jwt: null },
|
||||
{ identity: null },
|
||||
'persistent'
|
||||
);
|
||||
|
||||
@@ -25,7 +25,7 @@ export const loginAction = loginStatePart.createAction<{ username: string; passw
|
||||
});
|
||||
return {
|
||||
...currentState,
|
||||
...(response.jwt ? { jwt: response.jwt } : {}),
|
||||
...(response.identity ? { identity: response.identity } : {}),
|
||||
};
|
||||
}
|
||||
);
|
||||
@@ -34,7 +34,7 @@ export const logoutAction = loginStatePart.createAction(async (statePartArg) =>
|
||||
const currentState = statePartArg.getState();
|
||||
return {
|
||||
...currentState,
|
||||
jwt: null,
|
||||
identity: null,
|
||||
};
|
||||
});
|
||||
|
||||
@@ -81,7 +81,7 @@ export const getAllDataAction = dataState.createAction(async (statePartArg, part
|
||||
'adminGetConfigBundlesAndSecretGroups'
|
||||
);
|
||||
const response = await trGetSecrets.fire({
|
||||
jwt: loginStatePart.getState().jwt,
|
||||
identity: loginStatePart.getState().identity,
|
||||
});
|
||||
currentState = {
|
||||
...currentState,
|
||||
@@ -95,7 +95,7 @@ export const getAllDataAction = dataState.createAction(async (statePartArg, part
|
||||
'getAllImages'
|
||||
);
|
||||
const responseImages = await trGetImages.fire({
|
||||
jwt: loginStatePart.getState().jwt,
|
||||
identity: loginStatePart.getState().identity,
|
||||
});
|
||||
currentState = {
|
||||
...currentState,
|
||||
@@ -109,7 +109,7 @@ export const getAllDataAction = dataState.createAction(async (statePartArg, part
|
||||
'getAllClusters'
|
||||
);
|
||||
const responseClusters = await trGetClusters.fire({
|
||||
jwt: loginStatePart.getState().jwt,
|
||||
identity: loginStatePart.getState().identity,
|
||||
});
|
||||
|
||||
currentState = {
|
||||
@@ -130,7 +130,7 @@ export const createSecretGroupAction = dataState.createAction(
|
||||
'adminCreateConfigBundlesAndSecretGroups'
|
||||
);
|
||||
const response = await trCreateSecretGroup.fire({
|
||||
jwt: loginStatePart.getState().jwt,
|
||||
identity: loginStatePart.getState().identity,
|
||||
secretBundles: [],
|
||||
secretGroups: [payloadArg],
|
||||
});
|
||||
@@ -149,7 +149,7 @@ export const deleteSecretGroupAction = dataState.createAction(
|
||||
'adminDeleteConfigBundlesAndSecretGroups'
|
||||
);
|
||||
const response = await trDeleteSecretGroup.fire({
|
||||
jwt: loginStatePart.getState().jwt,
|
||||
identity: loginStatePart.getState().identity,
|
||||
secretBundleIds: [],
|
||||
secretGroupIds: [payloadArg.secretGroupId],
|
||||
});
|
||||
@@ -168,7 +168,7 @@ export const deleteSecretBundleAction = dataState.createAction(
|
||||
'adminDeleteConfigBundlesAndSecretGroups'
|
||||
);
|
||||
const response = await trDeleteConfigBundle.fire({
|
||||
jwt: loginStatePart.getState().jwt,
|
||||
identity: loginStatePart.getState().identity,
|
||||
secretBundleIds: [payloadArg.configBundleId],
|
||||
secretGroupIds: [],
|
||||
});
|
||||
@@ -187,7 +187,7 @@ export const createImageAction = dataState.createAction(
|
||||
'createImage'
|
||||
);
|
||||
const response = await trCreateImage.fire({
|
||||
jwt: loginStatePart.getState().jwt,
|
||||
identity: loginStatePart.getState().identity,
|
||||
name: payloadArg.imageName,
|
||||
description: payloadArg.description,
|
||||
});
|
||||
@@ -210,7 +210,7 @@ export const deleteImageAction = dataState.createAction(
|
||||
'deleteImage'
|
||||
);
|
||||
const response = await trDeleteImage.fire({
|
||||
jwt: loginStatePart.getState().jwt,
|
||||
identity: loginStatePart.getState().identity,
|
||||
imageId: payloadArg.imageId,
|
||||
});
|
||||
currentState = {
|
||||
@@ -238,7 +238,7 @@ export const addClusterAction = dataState.createAction(
|
||||
'createCluster'
|
||||
);
|
||||
const response = await trAddCluster.fire({
|
||||
jwt: loginStatePart.getState().jwt,
|
||||
identity: loginStatePart.getState().identity,
|
||||
...payloadArg,
|
||||
});
|
||||
currentState = {
|
||||
|
||||
Reference in New Issue
Block a user