mirror of
https://github.com/aljazceru/mutiny-web.git
synced 2025-12-17 14:24:26 +01:00
Remove mutiny plus references
This commit is contained in:
committed by
Tony Giorgio
parent
625c0f6de7
commit
6e31400d23
@@ -19,7 +19,6 @@ const settingsRoutes = [
|
||||
"/connections",
|
||||
"/currency",
|
||||
"/emergencykit",
|
||||
"/plus",
|
||||
"/restore",
|
||||
"/servers",
|
||||
"/nostrkeys"
|
||||
@@ -62,10 +61,6 @@ test("visit each route", async ({ page }) => {
|
||||
|
||||
checklist.set("/settings", true);
|
||||
|
||||
// Mutiny+
|
||||
await checkRoute(page, "/settings/plus", "Mutiny+", checklist);
|
||||
await page.goBack();
|
||||
|
||||
// Lightning Channels
|
||||
await checkRoute(
|
||||
page,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { createAsync, useNavigate } from "@solidjs/router";
|
||||
import { AtSign, Edit, Import } from "lucide-solid";
|
||||
import { Edit, Import } from "lucide-solid";
|
||||
import { createMemo, Show, Suspense } from "solid-js";
|
||||
|
||||
import {
|
||||
@@ -47,21 +47,6 @@ export function Profile() {
|
||||
return profile()?.deleted === true || profile()?.deleted === "true";
|
||||
});
|
||||
|
||||
const hasMutinyAddress = createMemo(() => {
|
||||
if (profile()?.lud16) {
|
||||
const hermes = import.meta.env.VITE_HERMES;
|
||||
if (!hermes) {
|
||||
return false;
|
||||
}
|
||||
const hermesDomain = new URL(hermes).hostname;
|
||||
const afterAt = profile()?.lud16!.split("@")[1];
|
||||
if (afterAt && afterAt.includes(hermesDomain)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
});
|
||||
|
||||
return (
|
||||
<MutinyWalletGuard>
|
||||
<DefaultMain>
|
||||
@@ -89,26 +74,6 @@ export function Profile() {
|
||||
<NiceP>{i18n.t("profile.edit_profile")}</NiceP>
|
||||
</div>
|
||||
</ButtonCard>
|
||||
<Show
|
||||
when={
|
||||
!hasMutinyAddress() && import.meta.env.VITE_HERMES
|
||||
}
|
||||
>
|
||||
<ButtonCard
|
||||
onClick={() =>
|
||||
navigate("/settings/lightningaddress")
|
||||
}
|
||||
>
|
||||
<div class="flex items-center gap-2">
|
||||
<AtSign class="inline-block text-m-red" />
|
||||
<NiceP>
|
||||
{i18n.t(
|
||||
"settings.lightning_address.create"
|
||||
)}
|
||||
</NiceP>
|
||||
</div>
|
||||
</ButtonCard>
|
||||
</Show>
|
||||
</Show>
|
||||
<Show when={profile() && profile()?.deleted}>
|
||||
<ButtonCard
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
import { A, useNavigate } from "@solidjs/router";
|
||||
import { AtSign } from "lucide-solid";
|
||||
import { A } from "@solidjs/router";
|
||||
import {
|
||||
createResource,
|
||||
createSignal,
|
||||
@@ -13,7 +12,6 @@ import party from "~/assets/party.gif";
|
||||
import {
|
||||
BackLink,
|
||||
Button,
|
||||
ButtonCard,
|
||||
ConfirmDialog,
|
||||
DefaultMain,
|
||||
ExternalLink,
|
||||
@@ -170,8 +168,6 @@ export function Plus() {
|
||||
const i18n = useI18n();
|
||||
const [state, _actions] = useMegaStore();
|
||||
|
||||
const navigate = useNavigate();
|
||||
|
||||
return (
|
||||
<MutinyWalletGuard>
|
||||
<DefaultMain>
|
||||
@@ -198,22 +194,6 @@ export function Plus() {
|
||||
{i18n.t("settings.plus.wallet_connection")}
|
||||
</A>
|
||||
</NiceP>
|
||||
<Show when={import.meta.env.VITE_HERMES}>
|
||||
<ButtonCard
|
||||
onClick={() =>
|
||||
navigate("/settings/lightningaddress")
|
||||
}
|
||||
>
|
||||
<div class="flex items-center gap-2">
|
||||
<AtSign class="inline-block text-m-red" />
|
||||
<NiceP>
|
||||
{i18n.t(
|
||||
"settings.lightning_address.create"
|
||||
)}
|
||||
</NiceP>
|
||||
</div>
|
||||
</ButtonCard>
|
||||
</Show>
|
||||
</Match>
|
||||
<Match when={!state.mutiny_plus}>
|
||||
<NiceP>
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import { Capacitor } from "@capacitor/core";
|
||||
import { A } from "@solidjs/router";
|
||||
import { ChevronRight } from "lucide-solid";
|
||||
import { For, Show } from "solid-js";
|
||||
@@ -8,7 +7,6 @@ import {
|
||||
DefaultMain,
|
||||
ExternalLink,
|
||||
LargeHeader,
|
||||
MutinyPlusCta,
|
||||
NavBar,
|
||||
SettingsCard,
|
||||
TinyText,
|
||||
@@ -73,18 +71,11 @@ export function Settings() {
|
||||
// @ts-ignore
|
||||
const COMMIT_HASH = import.meta.env.__COMMIT_HASH__;
|
||||
|
||||
const selfHosted = state.settings?.selfhosted === "true";
|
||||
|
||||
const ios = Capacitor.getPlatform() === "ios";
|
||||
|
||||
return (
|
||||
<DefaultMain>
|
||||
<BackLink />
|
||||
<LargeHeader>{i18n.t("settings.header")}</LargeHeader>
|
||||
<VStack biggap>
|
||||
<Show when={state.mutiny_plus || (!selfHosted && !ios)}>
|
||||
<MutinyPlusCta />
|
||||
</Show>
|
||||
<SettingsLinkList
|
||||
header={i18n.t("settings.general")}
|
||||
links={[
|
||||
|
||||
Reference in New Issue
Block a user