@agimon-ai/po-native 0.0.1-alpha.43 → 0.0.1-alpha.44
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/package.json +12 -12
- package/src/screens/usePluginMarketplace.ts +14 -8
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agimon-ai/po-native",
|
|
3
|
-
"version": "0.0.1-alpha.
|
|
3
|
+
"version": "0.0.1-alpha.44",
|
|
4
4
|
"description": "Po for iOS and Android",
|
|
5
5
|
"homepage": "https://agimon.ai",
|
|
6
6
|
"bugs": {
|
|
@@ -29,17 +29,17 @@
|
|
|
29
29
|
"access": "public"
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@agimon-ai/po-core": "0.0.0-alpha.
|
|
33
|
-
"@agimon-ai/po-expo-signing": "0.0.1-alpha.
|
|
34
|
-
"@agimon-ai/po-identity": "0.0.2-alpha.
|
|
35
|
-
"@agimon-ai/po-native-components": "0.0.0-alpha.
|
|
36
|
-
"@agimon-ai/po-native-dashboard": "0.0.0-alpha.
|
|
37
|
-
"@agimon-ai/po-template-advanced": "0.0.0-alpha.
|
|
38
|
-
"@agimon-ai/po-template-elegant": "0.0.0-alpha.
|
|
39
|
-
"@agimon-ai/po-voice": "0.0.0-alpha.
|
|
40
|
-
"@agimon-ai/po-web-components": "0.0.0-alpha.
|
|
41
|
-
"@agimon-ai/po-web-dashboard": "0.0.0-alpha.
|
|
42
|
-
"@agimon-ai/po-web-security": "0.0.0-alpha.
|
|
32
|
+
"@agimon-ai/po-core": "0.0.0-alpha.164",
|
|
33
|
+
"@agimon-ai/po-expo-signing": "0.0.1-alpha.44",
|
|
34
|
+
"@agimon-ai/po-identity": "0.0.2-alpha.111",
|
|
35
|
+
"@agimon-ai/po-native-components": "0.0.0-alpha.164",
|
|
36
|
+
"@agimon-ai/po-native-dashboard": "0.0.0-alpha.36",
|
|
37
|
+
"@agimon-ai/po-template-advanced": "0.0.0-alpha.164",
|
|
38
|
+
"@agimon-ai/po-template-elegant": "0.0.0-alpha.164",
|
|
39
|
+
"@agimon-ai/po-voice": "0.0.0-alpha.164",
|
|
40
|
+
"@agimon-ai/po-web-components": "0.0.0-alpha.164",
|
|
41
|
+
"@agimon-ai/po-web-dashboard": "0.0.0-alpha.164",
|
|
42
|
+
"@agimon-ai/po-web-security": "0.0.0-alpha.164",
|
|
43
43
|
"@better-auth/expo": "1.7.12",
|
|
44
44
|
"@config-plugins/react-native-webrtc": "15.0.2",
|
|
45
45
|
"@earendil-works/chord": "1.5.1",
|
|
@@ -62,6 +62,17 @@ export function usePluginMarketplace(hostId?: string, hostLabel = 'your computer
|
|
|
62
62
|
void load();
|
|
63
63
|
}, [load]);
|
|
64
64
|
|
|
65
|
+
const receiveInstall = useCallback(
|
|
66
|
+
(operation: InstallOperation) => {
|
|
67
|
+
setInstalls((current) => ({ ...current, [operation.layer]: operation }));
|
|
68
|
+
if (!SETTLED.has(operation.state)) return;
|
|
69
|
+
if (operation.conflict) setConflict(true);
|
|
70
|
+
if (operation.state === 'succeeded') setJustTurnedOn(operation.layer);
|
|
71
|
+
void load();
|
|
72
|
+
},
|
|
73
|
+
[load],
|
|
74
|
+
);
|
|
75
|
+
|
|
65
76
|
// A running install is read until it settles; then the catalog and presets are read again.
|
|
66
77
|
const runningKey = Object.values(installs)
|
|
67
78
|
.filter((operation) => !SETTLED.has(operation.state))
|
|
@@ -83,17 +94,12 @@ export function usePluginMarketplace(hostId?: string, hostLabel = 'your computer
|
|
|
83
94
|
return;
|
|
84
95
|
}
|
|
85
96
|
missedReads.current.delete(id);
|
|
86
|
-
|
|
87
|
-
setInstalls((current) => ({ ...current, [operation.layer]: operation }));
|
|
88
|
-
if (!SETTLED.has(operation.state)) return;
|
|
89
|
-
if (operation.conflict) setConflict(true);
|
|
90
|
-
if (operation.state === 'succeeded') setJustTurnedOn(operation.layer);
|
|
91
|
-
void load();
|
|
97
|
+
receiveInstall(read.operation);
|
|
92
98
|
});
|
|
93
99
|
}
|
|
94
100
|
}, INSTALL_POLL_MS);
|
|
95
101
|
return () => clearInterval(timer);
|
|
96
|
-
}, [runningKey, hostId, load]);
|
|
102
|
+
}, [runningKey, hostId, load, receiveInstall]);
|
|
97
103
|
|
|
98
104
|
const entries = useMemo(
|
|
99
105
|
() => catalogEntries({ catalog: layers ?? [], presets, external, setups: {}, installs }),
|
|
@@ -113,7 +119,7 @@ export function usePluginMarketplace(hostId?: string, hostLabel = 'your computer
|
|
|
113
119
|
},
|
|
114
120
|
hostId,
|
|
115
121
|
);
|
|
116
|
-
if ('operation' in started)
|
|
122
|
+
if ('operation' in started) receiveInstall(started.operation);
|
|
117
123
|
else setStartErrors((current) => ({ ...current, [entry.id]: started.error }));
|
|
118
124
|
};
|
|
119
125
|
|