11import { marginStyles , modal } from "@common" ;
22import { t as discordT , intl } from "@common/i18n" ;
33import { ToastType , toast } from "@common/toast" ;
4- import { Button , Notice } from "@components" ;
4+ import { Notice } from "@components" ;
55import { Logger } from "@replugged" ;
66import { generalSettings } from "src/renderer/managers/settings" ;
77import { setUpdaterState } from "src/renderer/managers/updater" ;
88import { t } from "src/renderer/modules/i18n" ;
9- import { openExternal } from "src/renderer/util" ;
109import type { AnyAddonManifest , CheckResultSuccess } from "src/types" ;
1110import * as pluginManager from "../../managers/plugins" ;
1211import * as themeManager from "../../managers/themes" ;
13- import { getAddonType , getSourceLink , label } from "../settings/pages" ;
12+ import { getAddonType , label } from "../settings/pages" ;
1413
1514const logger = Logger . coremod ( "Installer" ) ;
1615
@@ -226,7 +225,7 @@ export function authorList(authors: string[]): string {
226225async function showInstallPrompt (
227226 manifest : AnyAddonManifest ,
228227 source : InstallerSource | undefined ,
229- linkToStore = true ,
228+ _linkToStore = true ,
230229) : Promise < boolean | null > {
231230 let type : string ;
232231 switch ( manifest . type ) {
@@ -245,7 +244,9 @@ async function showInstallPrompt(
245244 authors,
246245 } ) ;
247246
248- const storeUrl = linkToStore ? getSourceLink ( manifest ) : undefined ;
247+ // TODO: Fix this! Mana ConfirmModals do not support secondary confirm buttons
248+
249+ // const storeUrl = linkToStore ? getSourceLink(manifest) : undefined;
249250
250251 const res = await modal . confirm ( {
251252 title,
@@ -263,8 +264,8 @@ async function showInstallPrompt(
263264 ) ,
264265 confirmText : intl . string ( discordT . CONFIRM ) ,
265266 cancelText : intl . string ( discordT . CANCEL ) ,
266- secondaryConfirmText : storeUrl ? intl . string ( t . REPLUGGED_INSTALLER_OPEN_STORE ) : undefined ,
267- onConfirmSecondary : ( ) => ( storeUrl ? openExternal ( storeUrl ) : undefined ) ,
267+ // secondaryConfirmText: storeUrl ? intl.string(t.REPLUGGED_INSTALLER_OPEN_STORE) : undefined,
268+ // onConfirmSecondary: () => (storeUrl ? openExternal(storeUrl) : undefined),
268269 } ) ;
269270
270271 return res ;
@@ -357,7 +358,6 @@ export async function installFlow(
357358 } ) ,
358359 confirmText : intl . string ( discordT . ERRORS_RELOAD ) ,
359360 cancelText : intl . string ( discordT . CANCEL ) ,
360- confirmColor : Button . Colors . RED ,
361361 } )
362362 . then ( ( answer ) => {
363363 if ( answer ) {
0 commit comments