Skip to content

Commit

Permalink
feat(INJI-472): show loader on issuer select
Browse files Browse the repository at this point in the history
Co-authored-by: KiruthikaJeyashankar <[email protected]>
Signed-off-by: Harsh Vardhan <[email protected]>
  • Loading branch information
vharsh and KiruthikaJeyashankar committed Oct 18, 2023
1 parent c1c7e70 commit 8243187
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .talismanrc
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ fileignoreconfig:
- filename: machines/VCItemMachine/EsignetMosipVCItem/EsignetMosipVCItemMachine.ts
checksum: 3ac59db154914fec7770e14b0451f21f98a0fe8bb0b0243e800ae3aac8a2941d
- filename: machines/issuersMachine.ts
checksum: fa1db95fbe9f635979f481d57793cb99114f34a8a5e17fbc4e0c41ef6197d783
checksum: f86249731a374b108891be4661bfaffb42b6e7115ee82aa69e99e0fce6319534
- filename: machines/issuersMachine.typegen.ts
checksum: 31bb8e3b650b076815dd1186487918bd48f46195c8ec82c916d7f7a16c0b5df2
version: ""
8 changes: 4 additions & 4 deletions machines/issuersMachine.ts
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ export const IssuersMachine = model.createMachine(
},
{
description: 'not fetched issuers config yet',
actions: ['setLoadingReasonAsDisplayIssuers', 'resetError'],
actions: ['setLoadingReasonAsSettingUp', 'resetError'],
target: 'downloadIssuerConfig',
},
],
Expand All @@ -133,7 +133,7 @@ export const IssuersMachine = model.createMachine(
actions: sendParent('DOWNLOAD_ID'),
},
SELECTED_ISSUER: {
actions: 'setSelectedIssuerId',
actions: ['setSelectedIssuerId', 'setLoadingReasonAsSettingUp'],
target: 'downloadIssuerConfig',
},
},
Expand Down Expand Up @@ -211,7 +211,7 @@ export const IssuersMachine = model.createMachine(
},
checkKeyPair: {
description: 'checks whether key pair is generated',
entry: [send('CHECK_KEY_PAIR'), 'setLoadingReasonAsSettingUp'],
entry: ['setLoadingReasonAsSettingUp', send('CHECK_KEY_PAIR')],
on: {
CHECK_KEY_PAIR: [
{
Expand Down Expand Up @@ -520,7 +520,7 @@ export const IssuersMachine = model.createMachine(
);
return await authorize(context.selectedIssuer);
},
generateKeyPair: async context => {
generateKeyPair: async () => {
if (!isCustomKeystore) {
return await generateKeys();
}
Expand Down
5 changes: 4 additions & 1 deletion machines/issuersMachine.typegen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,10 @@ export interface Typegen0 {
setIssuers: 'done.invoke.issuersMachine.displayIssuers:invocation[0]';
setLoadingReasonAsDisplayIssuers: 'TRY_AGAIN';
setLoadingReasonAsDownloadingCredentials: 'done.invoke.issuersMachine.generateKeyPair:invocation[0]';
setLoadingReasonAsSettingUp: 'done.invoke.issuersMachine.performAuthorization:invocation[0]';
setLoadingReasonAsSettingUp:
| 'SELECTED_ISSUER'
| 'TRY_AGAIN'
| 'done.invoke.issuersMachine.performAuthorization:invocation[0]';
setNoInternet: 'done.invoke.checkInternet';
setOIDCConfigError: 'error.platform.issuersMachine.performAuthorization:invocation[0]';
setPrivateKey: 'done.invoke.issuersMachine.generateKeyPair:invocation[0]';
Expand Down

0 comments on commit 8243187

Please sign in to comment.