fix: restore compatibility of plugins that have custom pages
This commit is contained in:
parent
094ff7c879
commit
f2916d4b79
3 changed files with 5 additions and 5 deletions
|
@ -114,7 +114,7 @@ export default function PluginCard({ item: plugin, index }: CardWrapper<Plugin>)
|
||||||
actions={[
|
actions={[
|
||||||
...(settings ? [{
|
...(settings ? [{
|
||||||
icon: "settings",
|
icon: "settings",
|
||||||
onPress: () => navigation.push("RevengeCustomPage", {
|
onPress: () => navigation.push("VendettaCustomPage", {
|
||||||
title: plugin.manifest.name,
|
title: plugin.manifest.name,
|
||||||
render: settings,
|
render: settings,
|
||||||
})
|
})
|
||||||
|
|
|
@ -85,7 +85,7 @@ export const getScreens = (youKeys = false): Screen[] => [
|
||||||
render: Developer,
|
render: Developer,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: formatKey("RevengeCustomPage", youKeys),
|
key: formatKey("VendettaCustomPage", youKeys),
|
||||||
title: "Revenge Page",
|
title: "Revenge Page",
|
||||||
shouldRender: () => false,
|
shouldRender: () => false,
|
||||||
render: ({ render: PageView, noErrorBoundary, ...options }: { render: React.ComponentType; noErrorBoundary: boolean } & Record<string, object>) => {
|
render: ({ render: PageView, noErrorBoundary, ...options }: { render: React.ComponentType; noErrorBoundary: boolean } & Record<string, object>) => {
|
||||||
|
|
|
@ -80,7 +80,7 @@ export default function Developer() {
|
||||||
label="Asset Browser"
|
label="Asset Browser"
|
||||||
leading={<FormRow.Icon source={getAssetIDByName("ic_image")} />}
|
leading={<FormRow.Icon source={getAssetIDByName("ic_image")} />}
|
||||||
trailing={FormRow.Arrow}
|
trailing={FormRow.Arrow}
|
||||||
onPress={() => navigation.push("RevengeCustomPage", {
|
onPress={() => navigation.push("VendettaCustomPage", {
|
||||||
title: "Asset Browser",
|
title: "Asset Browser",
|
||||||
render: AssetBrowser,
|
render: AssetBrowser,
|
||||||
})}
|
})}
|
||||||
|
@ -100,8 +100,8 @@ export default function Developer() {
|
||||||
options: [
|
options: [
|
||||||
// @ts-expect-error
|
// @ts-expect-error
|
||||||
// Of course, to trigger an error, we need to do something incorrectly. The below will do!
|
// Of course, to trigger an error, we need to do something incorrectly. The below will do!
|
||||||
{ label: "Revenge", onPress: () => navigation.push("RevengeCustomPage", { render: () => <undefined /> }) },
|
{ label: "Revenge", onPress: () => navigation.push("VendettaCustomPage", { render: () => <undefined /> }) },
|
||||||
{ label: "Discord", isDestructive: true, onPress: () => navigation.push("RevengeCustomPage", { noErrorBoundary: true }) },
|
{ label: "Discord", isDestructive: true, onPress: () => navigation.push("VendettaCustomPage", { noErrorBoundary: true }) },
|
||||||
],
|
],
|
||||||
})}
|
})}
|
||||||
/>
|
/>
|
||||||
|
|
Loading…
Reference in a new issue