mirror of
https://github.com/mosip/inji-wallet.git
synced 2026-01-09 13:38:01 -05:00
* [INJIMOB-2670]: Enable Auto Vc Activation (#1) * [INJIMOB-2670]: Enable Auto Vc Activation (#1759) * [INJIMOB-2670]: Hide Success Banner during Auto Activation. Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * [INJIMOB-2670]: Locales for Auto Activation Error message Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * [INJIMOB-2670]: Enable Auto Vc Activation and handle error scenarios Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * [INJIMOB-2670]: Remove activation sections from Help content Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * [INJIMOB-2670]: Update Event name to be generic Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * [INJIMOB-2670]: Remove communication details and add default OTP into constants Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> --------- Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * [INJIMOB-2670]: Removing Mosip specific condition for mosipInidividualId Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> --------- Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * add spanish language (#2) Signed-off-by: Sk Mijan Hossain <skmijanhossain@gmail.com> Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * [INJIMOB-2670]: Individual Id fix and add prefix to face image (#4) * [INJIMOB-2670]: Individual Id fix and appending image format for face image. Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * [INJIMOB-2670]: Add Utils to append Png Base64 Prefix to faceImage. Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> --------- Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * [INJIMOB-2670]: Update artifact Id and App name in fastlane scripts and build.gradle. (#3) Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * [INJIMOB-2670]: Add enable_auth and remove lilveness_detection in internal-build yml (#5) Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * [INJIMOB-2670]: Spanish locale updates. (#6) Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> * [INJIMOB-2670]: Liveness detection flag type changed to string Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> --------- Signed-off-by: BalachandarG <balachandar.g@thoughtworks.com> Signed-off-by: Sk Mijan Hossain <skmijanhossain@gmail.com> Co-authored-by: mijan32 <74153970+mijan32@users.noreply.github.com>
53 lines
2.0 KiB
TypeScript
53 lines
2.0 KiB
TypeScript
import {useSelector} from '@xstate/react';
|
|
import {
|
|
selectIsPasscodeUnlock,
|
|
selectIsBiometricUnlock,
|
|
SettingsEvents,
|
|
} from '../machines/settings';
|
|
import {useContext} from 'react';
|
|
import {GlobalContext} from '../shared/GlobalContext';
|
|
import {VcMetaEvents} from '../machines/VerifiableCredential/VCMetaMachine/VCMetaMachine';
|
|
import {
|
|
selectAutoWalletBindingSuccess,
|
|
selectIsDownloadingFailed,
|
|
selectIsDownloadingSuccess,
|
|
selectWalletBindingSuccess,
|
|
} from '../machines/VerifiableCredential/VCMetaMachine/VCMetaSelectors';
|
|
import {selectVerificationStatus} from '../machines/VerifiableCredential/VCItemMachine/VCItemSelectors';
|
|
|
|
export const UseBannerNotification = () => {
|
|
const {appService} = useContext(GlobalContext);
|
|
const settingsService = appService.children.get('settings')!!;
|
|
const vcMetaService = appService.children.get('vcMeta')!!;
|
|
|
|
return {
|
|
isBindingSuccess: useSelector(vcMetaService, selectWalletBindingSuccess),
|
|
isAutoWalletBindingSuccess: useSelector(
|
|
vcMetaService,
|
|
selectAutoWalletBindingSuccess,
|
|
),
|
|
verificationStatus: useSelector(vcMetaService, selectVerificationStatus),
|
|
isPasscodeUnlock: useSelector(settingsService, selectIsPasscodeUnlock),
|
|
|
|
isBiometricUnlock: useSelector(settingsService, selectIsBiometricUnlock),
|
|
isDownloadingSuccess: useSelector(
|
|
vcMetaService,
|
|
selectIsDownloadingSuccess,
|
|
),
|
|
isDownloadingFailed: useSelector(vcMetaService, selectIsDownloadingFailed),
|
|
DISMISS: () => {
|
|
settingsService.send(SettingsEvents.DISMISS());
|
|
},
|
|
RESET_WALLET_BINDING_SUCCESS: () =>
|
|
vcMetaService.send(VcMetaEvents.RESET_WALLET_BINDING_SUCCESS()),
|
|
RESET_VERIFICATION_STATUS: () =>
|
|
vcMetaService.send(VcMetaEvents.RESET_VERIFICATION_STATUS(null)),
|
|
RESET_DOWNLOADING_FAILED: () => {
|
|
vcMetaService.send(VcMetaEvents.RESET_DOWNLOADING_FAILED());
|
|
},
|
|
RESET_DOWNLOADING_SUCCESS: () => {
|
|
vcMetaService.send(VcMetaEvents.RESET_DOWNLOADING_SUCCESS());
|
|
},
|
|
};
|
|
};
|