Format file

This commit is contained in:
Nicola Benaglia 2025-04-12 18:19:21 +02:00
parent 9b675f470d
commit 52c733f48a

View File

@ -1,53 +1,57 @@
import { atom, selectorFamily } from 'recoil'; import { atom, selectorFamily } from 'recoil';
export const sortablePinnedAppsAtom = atom({ export const sortablePinnedAppsAtom = atom({
key: 'sortablePinnedAppsFromAtom', key: 'sortablePinnedAppsFromAtom',
default: [{ default: [
name: 'Q-Tube', {
service: 'APP' name: 'Q-Tube',
}, { service: 'APP',
name: 'Q-Mail', },
service: 'APP' {
}, { name: 'Q-Mail',
name: 'Q-Share', service: 'APP',
service: 'APP' },
}, { {
name: 'Q-Fund', name: 'Q-Share',
service: 'APP' service: 'APP',
}, { },
name: 'Q-Shop', {
service: 'APP' name: 'Q-Fund',
}, service: 'APP',
{ },
name: 'Q-Trade', {
service: 'APP' name: 'Q-Shop',
}, service: 'APP',
{ },
name: 'Q-Support', {
service: 'APP' name: 'Q-Trade',
}, service: 'APP',
{ },
name: 'Q-Manager', {
service: 'APP' name: 'Q-Support',
}, service: 'APP',
{ },
name: 'Q-Blog', {
service: 'APP' name: 'Q-Manager',
}, service: 'APP',
{ },
name: 'Q-Mintership', {
service: 'APP' name: 'Q-Blog',
}, service: 'APP',
{ },
name: 'Q-Wallets', {
service: 'APP' name: 'Q-Mintership',
}, service: 'APP',
{ },
name: 'Q-Search', {
service: 'APP' name: 'Q-Wallets',
}, service: 'APP',
], },
{
name: 'Q-Search',
service: 'APP',
},
],
}); });
export const canSaveSettingToQdnAtom = atom({ export const canSaveSettingToQdnAtom = atom({
@ -69,12 +73,12 @@ export const oldPinnedAppsAtom = atom({
key: 'oldPinnedAppsAtom', key: 'oldPinnedAppsAtom',
default: [], default: [],
}); });
export const isUsingImportExportSettingsAtom = atom({ export const isUsingImportExportSettingsAtom = atom({
key: 'isUsingImportExportSettingsAtom', key: 'isUsingImportExportSettingsAtom',
default: null, default: null,
}); });
export const fullScreenAtom = atom({ export const fullScreenAtom = atom({
key: 'fullScreenAtom', key: 'fullScreenAtom',
default: false, default: false,
@ -117,10 +121,12 @@ export const resourceDownloadControllerAtom = atom({
export const resourceKeySelector = selectorFamily({ export const resourceKeySelector = selectorFamily({
key: 'resourceKeySelector', key: 'resourceKeySelector',
get: (key) => ({ get }) => { get:
const resources = get(resourceDownloadControllerAtom); (key) =>
return resources[key] || null; // Return the value for the key or null if not found ({ get }) => {
}, const resources = get(resourceDownloadControllerAtom);
return resources[key] || null; // Return the value for the key or null if not found
},
}); });
export const blobControllerAtom = atom({ export const blobControllerAtom = atom({
@ -130,10 +136,12 @@ export const blobControllerAtom = atom({
export const blobKeySelector = selectorFamily({ export const blobKeySelector = selectorFamily({
key: 'blobKeySelector', key: 'blobKeySelector',
get: (key) => ({ get }) => { get:
const blobs = get(blobControllerAtom); (key) =>
return blobs[key] || null; // Return the value for the key or null if not found ({ get }) => {
}, const blobs = get(blobControllerAtom);
return blobs[key] || null; // Return the value for the key or null if not found
},
}); });
export const selectedGroupIdAtom = atom({ export const selectedGroupIdAtom = atom({
@ -148,10 +156,12 @@ export const addressInfoControllerAtom = atom({
export const addressInfoKeySelector = selectorFamily({ export const addressInfoKeySelector = selectorFamily({
key: 'addressInfoKeySelector', key: 'addressInfoKeySelector',
get: (key) => ({ get }) => { get:
const userInfo = get(addressInfoControllerAtom); (key) =>
return userInfo[key] || null; // Return the value for the key or null if not found ({ get }) => {
}, const userInfo = get(addressInfoControllerAtom);
return userInfo[key] || null; // Return the value for the key or null if not found
},
}); });
export const isDisabledEditorEnterAtom = atom({ export const isDisabledEditorEnterAtom = atom({