mirror of
https://github.com/aljazceru/mutiny-web.git
synced 2025-12-18 14:54:26 +01:00
remove beta disclaimers
This commit is contained in:
@@ -1,73 +0,0 @@
|
||||
import { Dialog } from "@kobalte/core";
|
||||
import { ParentComponent } from "solid-js";
|
||||
|
||||
import {
|
||||
DIALOG_CONTENT,
|
||||
DIALOG_POSITIONER,
|
||||
ExternalLink,
|
||||
ModalCloseButton,
|
||||
OVERLAY,
|
||||
SmallHeader
|
||||
} from "~/components";
|
||||
import { useI18n } from "~/i18n/context";
|
||||
import { useMegaStore } from "~/state/megaStore";
|
||||
|
||||
export function BetaWarningModal() {
|
||||
const i18n = useI18n();
|
||||
return (
|
||||
<WarningModal
|
||||
title={i18n.t("modals.beta_warning.title")}
|
||||
linkText={i18n.t("common.why")}
|
||||
>
|
||||
<p>{i18n.t("modals.beta_warning.be_careful")}</p>
|
||||
<p>
|
||||
<ExternalLink href="https://github.com/MutinyWallet/mutiny-web/wiki/Mutiny-Beta-Readme">
|
||||
{i18n.t("modals.beta_warning.beta_link")}
|
||||
</ExternalLink>
|
||||
</p>
|
||||
<p class="small text-neutral-400">
|
||||
{i18n.t("modals.beta_warning.pretend_money")}{" "}
|
||||
<ExternalLink href="https://blog.mutinywallet.com/mutiny-wallet-signet-release/">
|
||||
{i18n.t("modals.beta_warning.signet_link")}
|
||||
</ExternalLink>
|
||||
</p>
|
||||
</WarningModal>
|
||||
);
|
||||
}
|
||||
|
||||
const WarningModal: ParentComponent<{
|
||||
linkText: string;
|
||||
title: string;
|
||||
}> = (props) => {
|
||||
const [state, actions] = useMegaStore();
|
||||
|
||||
function close() {
|
||||
actions.setBetaWarned();
|
||||
}
|
||||
|
||||
return (
|
||||
<Dialog.Root
|
||||
open={!state.betaWarned && state.settings?.network === "bitcoin"}
|
||||
onOpenChange={close}
|
||||
>
|
||||
<Dialog.Portal>
|
||||
<Dialog.Overlay class={OVERLAY} />
|
||||
<div class={DIALOG_POSITIONER}>
|
||||
<Dialog.Content class={DIALOG_CONTENT}>
|
||||
<div class="p-4">
|
||||
<Dialog.Title class="mb-2 flex items-center justify-between">
|
||||
<SmallHeader>{props.title}</SmallHeader>
|
||||
<Dialog.CloseButton>
|
||||
<ModalCloseButton />
|
||||
</Dialog.CloseButton>
|
||||
</Dialog.Title>
|
||||
<Dialog.Description class="flex flex-col gap-4">
|
||||
<div>{props.children}</div>
|
||||
</Dialog.Description>
|
||||
</div>
|
||||
</Dialog.Content>
|
||||
</div>
|
||||
</Dialog.Portal>
|
||||
</Dialog.Root>
|
||||
);
|
||||
};
|
||||
@@ -50,7 +50,7 @@ export function ReceiveWarnings(props: {
|
||||
return undefined;
|
||||
};
|
||||
|
||||
const betaWarning = () => {
|
||||
const sillyAmountWarning = () => {
|
||||
const parsed = Number(props.amountSats);
|
||||
if (isNaN(parsed)) {
|
||||
return undefined;
|
||||
@@ -59,16 +59,13 @@ export function ReceiveWarnings(props: {
|
||||
if (parsed >= 2099999997690000) {
|
||||
// If over 21 million bitcoin, warn that too much
|
||||
return i18n.t("receive.amount_editable.more_than_21m");
|
||||
} else if (parsed >= 4000000) {
|
||||
// If over 4 million sats, warn that it's a beta bro
|
||||
return i18n.t("receive.amount_editable.too_big_for_beta");
|
||||
}
|
||||
};
|
||||
|
||||
return (
|
||||
<Switch>
|
||||
<Match when={betaWarning()}>
|
||||
<InfoBox accent="red">{betaWarning()}</InfoBox>
|
||||
<Match when={sillyAmountWarning()}>
|
||||
<InfoBox accent="red">{sillyAmountWarning()}</InfoBox>
|
||||
</Match>
|
||||
<Match when={warningText()}>
|
||||
<InfoBox accent="blue">
|
||||
|
||||
@@ -7,7 +7,6 @@ export * from "./ActivityItem";
|
||||
export * from "./Amount";
|
||||
export * from "./AmountEditable";
|
||||
export * from "./BalanceBox";
|
||||
export * from "./BetaWarningModal";
|
||||
export * from "./ChooseCurrency";
|
||||
export * from "./ChooseLanguage";
|
||||
export * from "./ContactEditor";
|
||||
|
||||
@@ -93,8 +93,6 @@ export default {
|
||||
"A lightning setup fee might be deducted from the requested amount.",
|
||||
setup_fee_lightning:
|
||||
"A lightning setup fee will be charged if paid over lightning.",
|
||||
too_big_for_beta:
|
||||
"That's a lot of sats. You do know Mutiny Wallet is still in beta, yeah?",
|
||||
more_than_21m: "There are only 21 million bitcoin.",
|
||||
set_amount: "Set amount",
|
||||
max: "MAX",
|
||||
@@ -244,7 +242,7 @@ export default {
|
||||
settings: {
|
||||
header: "Settings",
|
||||
support: "Learn how to support Mutiny",
|
||||
beta_features: "BETA FEATURES",
|
||||
experimental_features: "Experiments",
|
||||
debug_tools: "DEBUG TOOLS",
|
||||
danger_zone: "Danger zone",
|
||||
general: "General",
|
||||
@@ -487,7 +485,7 @@ export default {
|
||||
satisfaction: "Smug satisfaction",
|
||||
gifting: "Gifting",
|
||||
multi_device: "Multi-device access",
|
||||
ios_beta_access: "iOS beta access",
|
||||
ios_testflight: "iOS TestFlight access",
|
||||
more: "... and more to come",
|
||||
cta_description:
|
||||
"Enjoy early access to new features and premium functionality.",
|
||||
@@ -738,17 +736,6 @@ export default {
|
||||
not_available: "We don't do that yet",
|
||||
secure_your_funds: "Secure your funds"
|
||||
},
|
||||
beta_warning: {
|
||||
title: "Warning: beta software",
|
||||
beta_warning:
|
||||
"We're so glad you're here. But we do want to warn you: Mutiny Wallet is in beta, and there are still bugs and rough edges.",
|
||||
be_careful:
|
||||
"Please be careful and don't put more money into Mutiny than you're willing to lose.",
|
||||
beta_link: "Learn more about the beta",
|
||||
pretend_money:
|
||||
"If you want to use pretend money to test out Mutiny without risk,",
|
||||
signet_link: "check out our Signet version."
|
||||
},
|
||||
more_info: {
|
||||
whats_with_the_fees: "What's with the fees?",
|
||||
self_custodial:
|
||||
|
||||
@@ -71,8 +71,6 @@ export default {
|
||||
"첫 라이트닝 받기는 {{amount}} SATS 이상이어야 합니다. 요청한 금액에서 설정 비용이 차감됩니다.",
|
||||
setup_fee_lightning:
|
||||
"라이트닝으로 지불하는 경우 라이트닝 설치 비용이 부과됩니다.",
|
||||
too_big_for_beta:
|
||||
"많은 SATS입니다. Mutiny Wallet이 여전히 베타 버전임을 알고 계시겠죠?",
|
||||
more_than_21m: "비트코인은 총 2,100만 개밖에 없습니다.",
|
||||
set_amount: "금액 설정",
|
||||
max: "최대",
|
||||
@@ -183,7 +181,7 @@ export default {
|
||||
header: "설정",
|
||||
support: "Mutiny 지원 방법 알아보기",
|
||||
general: "일반",
|
||||
beta_features: "베타 기능",
|
||||
experimental_features: "실험",
|
||||
debug_tools: "디버그 도구",
|
||||
danger_zone: "위험 지역",
|
||||
admin: {
|
||||
@@ -495,17 +493,6 @@ export default {
|
||||
not_available: "아직 이 기능은 지원하지 않습니다",
|
||||
secure_your_funds: "자금을 안전하게 보호하세요"
|
||||
},
|
||||
beta_warning: {
|
||||
title: "경고: 베타 버전 소프트웨어",
|
||||
beta_warning:
|
||||
"저희가 여러분을 여기서 맞이할 수 있게 되어 기쁩니다. 그러나 경고하고 싶습니다: Mutiny Wallet은 베타 버전이며 여전히 버그와 미흡한 점이 있을 수 있습니다.",
|
||||
be_careful:
|
||||
"Mutiny에 지금보다 더 많은 자금을 투자하지 않도록 주의하세요.",
|
||||
beta_Link: "베타 버전에 대해 자세히 알아보기",
|
||||
pretend_money:
|
||||
"위험 없이 Mutiny를 테스트하려면 가상 자금을 사용하려면",
|
||||
signet_link: "Signet 버전을 확인하세요."
|
||||
},
|
||||
more_info: {
|
||||
whats_with_the_fees: "수수료는 어떻게 되나요?",
|
||||
self_custodial:
|
||||
|
||||
@@ -5,7 +5,6 @@ import scan from "~/assets/icons/scan.svg";
|
||||
import settings from "~/assets/icons/settings.svg";
|
||||
import {
|
||||
BalanceBox,
|
||||
BetaWarningModal,
|
||||
Card,
|
||||
CombinedActivity,
|
||||
DecryptDialog,
|
||||
@@ -106,7 +105,6 @@ export function Main() {
|
||||
</div>
|
||||
</DefaultMain>
|
||||
<DecryptDialog />
|
||||
<BetaWarningModal />
|
||||
<HomePrompt />
|
||||
<NavBar activeTab="home" />
|
||||
</SafeArea>
|
||||
|
||||
@@ -41,10 +41,10 @@ function Perks(props: { alreadySubbed?: boolean }) {
|
||||
<li>
|
||||
<Show
|
||||
when={props.alreadySubbed}
|
||||
fallback={i18n.t("settings.plus.ios_beta_access")}
|
||||
fallback={i18n.t("settings.plus.ios_testflight")}
|
||||
>
|
||||
<ExternalLink href="https://testflight.apple.com/join/9g23f0Mc">
|
||||
{i18n.t("settings.plus.ios_beta_access")}
|
||||
{i18n.t("settings.plus.ios_testflight")}
|
||||
</ExternalLink>
|
||||
</Show>
|
||||
</li>
|
||||
|
||||
@@ -131,7 +131,7 @@ export function Settings() {
|
||||
]}
|
||||
/>
|
||||
<SettingsLinkList
|
||||
header={i18n.t("settings.beta_features")}
|
||||
header={i18n.t("settings.experimental_features")}
|
||||
links={[
|
||||
{
|
||||
href: "/settings/connections",
|
||||
|
||||
@@ -69,7 +69,6 @@ type MegaStore = [
|
||||
safe_mode?: boolean;
|
||||
npub?: string;
|
||||
preferredInvoiceType: "unified" | "lightning" | "onchain";
|
||||
betaWarned: boolean;
|
||||
testflightPromptDismissed: boolean;
|
||||
should_zap_hodl: boolean;
|
||||
federations?: MutinyFederationIdentity[];
|
||||
@@ -94,7 +93,6 @@ type MegaStore = [
|
||||
onError: (e: Error) => void,
|
||||
onSuccess: (value: ParsedParams) => void
|
||||
): void;
|
||||
setBetaWarned(): void;
|
||||
setTestFlightPromptDismissed(): void;
|
||||
toggleHodl(): void;
|
||||
dropMutinyWallet(): void;
|
||||
@@ -137,7 +135,6 @@ export const Provider: ParentComponent = (props) => {
|
||||
lang: localStorage.getItem("i18nexLng") || undefined,
|
||||
npub: localStorage.getItem("npub") || undefined,
|
||||
preferredInvoiceType: "unified" as "unified" | "lightning" | "onchain",
|
||||
betaWarned: localStorage.getItem("betaWarned") === "true",
|
||||
should_zap_hodl: localStorage.getItem("should_zap_hodl") === "true",
|
||||
testflightPromptDismissed:
|
||||
localStorage.getItem("testflightPromptDismissed") === "true",
|
||||
@@ -410,10 +407,6 @@ export const Provider: ParentComponent = (props) => {
|
||||
}
|
||||
}
|
||||
},
|
||||
setBetaWarned() {
|
||||
localStorage.setItem("betaWarned", "true");
|
||||
setState({ betaWarned: true });
|
||||
},
|
||||
setTestFlightPromptDismissed() {
|
||||
localStorage.setItem("testflightPromptDismissed", "true");
|
||||
setState({ testflightPromptDismissed: true });
|
||||
|
||||
Reference in New Issue
Block a user