mirror of
https://github.com/aljazceru/mutiny-web.git
synced 2025-12-18 23:04:25 +01:00
better cta when already a mutiny+ sub
This commit is contained in:
committed by
benthecarman
parent
7a962c5f92
commit
a1b94803df
@@ -1,8 +1,9 @@
|
||||
import { ParentComponent } from "solid-js";
|
||||
import { ParentComponent, Show } from "solid-js";
|
||||
import { A } from "solid-start";
|
||||
|
||||
import forward from "~/assets/icons/forward.svg";
|
||||
import { useI18n } from "~/i18n/context";
|
||||
import { useMegaStore } from "~/state/megaStore";
|
||||
|
||||
export const CtaCard: ParentComponent = (props) => {
|
||||
return (
|
||||
@@ -18,6 +19,7 @@ export const CtaCard: ParentComponent = (props) => {
|
||||
};
|
||||
|
||||
export function MutinyPlusCta() {
|
||||
const [state, _actions] = useMegaStore();
|
||||
const i18n = useI18n();
|
||||
return (
|
||||
<CtaCard>
|
||||
@@ -32,7 +34,12 @@ export function MutinyPlusCta() {
|
||||
<img src={forward} alt="go" />
|
||||
</div>
|
||||
<div class="text-sm text-m-grey-400">
|
||||
{i18n.t("settings.plus.cta_description")}
|
||||
<Show
|
||||
when={state.mutiny_plus}
|
||||
fallback={i18n.t("settings.plus.cta_description")}
|
||||
>
|
||||
{i18n.t("settings.plus.cta_but_already_plus")}
|
||||
</Show>
|
||||
</div>
|
||||
</A>
|
||||
</CtaCard>
|
||||
|
||||
Reference in New Issue
Block a user