kopia lustrzana https://gitlab.com/soapbox-pub/soapbox
Change modal name
rodzic
ed096a83bd
commit
8c65924c43
|
@ -239,9 +239,9 @@ const PureStatusActionBar: React.FC<IPureStatusActionBar> = ({
|
|||
|
||||
const handleZapClick: React.EventHandler<React.MouseEvent> = (e) => {
|
||||
if (me) {
|
||||
dispatch(openModal('ZAP_PAY_REQUEST', { status, account: status.account }));
|
||||
dispatch(openModal('PAY_REQUEST', { status, account: status.account }));
|
||||
} else {
|
||||
onOpenUnauthorizedModal('ZAP_PAY_REQUEST');
|
||||
onOpenUnauthorizedModal('PAY_REQUEST');
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
@ -227,9 +227,9 @@ const StatusActionBar: React.FC<IStatusActionBar> = ({
|
|||
|
||||
const handleZapClick: React.EventHandler<React.MouseEvent> = (e) => {
|
||||
if (me) {
|
||||
dispatch(openModal('ZAP_PAY_REQUEST', { status, account: status.account }));
|
||||
dispatch(openModal('PAY_REQUEST', { status, account: status.account }));
|
||||
} else {
|
||||
onOpenUnauthorizedModal('ZAP_PAY_REQUEST');
|
||||
onOpenUnauthorizedModal('PAY_REQUEST');
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
@ -310,7 +310,7 @@ const Header: React.FC<IHeader> = ({ account }) => {
|
|||
};
|
||||
|
||||
const handleZapAccount: React.EventHandler<React.MouseEvent> = (e) => {
|
||||
dispatch(openModal('ZAP_PAY_REQUEST', { account }));
|
||||
dispatch(openModal('PAY_REQUEST', { account }));
|
||||
};
|
||||
|
||||
const makeMenu = () => {
|
||||
|
|
|
@ -43,7 +43,7 @@ import {
|
|||
UnauthorizedModal,
|
||||
VideoModal,
|
||||
EditRuleModal,
|
||||
ZapPayRequestModal,
|
||||
PayRequestModal,
|
||||
ZapSplitModal,
|
||||
ZapInvoiceModal,
|
||||
ZapsModal,
|
||||
|
@ -89,6 +89,7 @@ const MODAL_COMPONENTS: Record<string, React.ExoticComponent<any>> = {
|
|||
'NOSTR_LOGIN': NostrLoginModal,
|
||||
'NOSTR_SIGNUP': NostrSignupModal,
|
||||
'ONBOARDING': OnboardingModal,
|
||||
'PAY_REQUEST': PayRequestModal,
|
||||
'REACTIONS': ReactionsModal,
|
||||
'REBLOGS': ReblogsModal,
|
||||
'REPLY_MENTIONS': ReplyMentionsModal,
|
||||
|
@ -98,7 +99,6 @@ const MODAL_COMPONENTS: Record<string, React.ExoticComponent<any>> = {
|
|||
'VIDEO': VideoModal,
|
||||
'ZAPS': ZapsModal,
|
||||
'ZAP_INVOICE': ZapInvoiceModal,
|
||||
'ZAP_PAY_REQUEST': ZapPayRequestModal,
|
||||
'ZAP_SPLIT': ZapSplitModal,
|
||||
};
|
||||
|
||||
|
|
|
@ -45,7 +45,7 @@ const ZapInvoiceModal: React.FC<IZapInvoice> = ({ account, invoice, splitData, o
|
|||
const { hasZapSplit, zapSplitAccounts, splitValues } = splitData;
|
||||
const onClickClose = () => {
|
||||
onClose('ZAP_INVOICE');
|
||||
dispatch(closeModal('ZAP_PAY_REQUEST'));
|
||||
dispatch(closeModal('PAY_REQUEST'));
|
||||
};
|
||||
|
||||
const renderTitle = () => {
|
||||
|
|
|
@ -1,27 +0,0 @@
|
|||
import React from 'react';
|
||||
|
||||
import Modal from 'soapbox/components/ui/modal.tsx';
|
||||
import ZapPayRequestForm from 'soapbox/features/zap/components/zap-pay-request-form.tsx';
|
||||
|
||||
import type { Status as StatusEntity, Account as AccountEntity } from 'soapbox/types/entities.ts';
|
||||
|
||||
interface IZapPayRequestModal {
|
||||
account: AccountEntity;
|
||||
status?: StatusEntity;
|
||||
onClose:(type?: string) => void;
|
||||
}
|
||||
|
||||
const ZapPayRequestModal: React.FC<IZapPayRequestModal> = ({ account, status, onClose }) => {
|
||||
const onClickClose = () => {
|
||||
onClose('ZAP_PAY_REQUEST');
|
||||
};
|
||||
|
||||
|
||||
return (
|
||||
<Modal width='lg'>
|
||||
<ZapPayRequestForm account={account} status={status} onClose={onClickClose} />
|
||||
</Modal>
|
||||
);
|
||||
};
|
||||
|
||||
export default ZapPayRequestModal;
|
|
@ -174,7 +174,7 @@ export const Relays = lazy(() => import('soapbox/features/admin/relays.tsx'));
|
|||
export const Rules = lazy(() => import('soapbox/features/admin/rules.tsx'));
|
||||
export const EditRuleModal = lazy(() => import('soapbox/features/ui/components/modals/edit-rule-modal.tsx'));
|
||||
export const AdminNostrRelays = lazy(() => import('soapbox/features/admin/nostr-relays.tsx'));
|
||||
export const ZapPayRequestModal = lazy(() => import('soapbox/features/ui/components/modals/zap-pay-request-modal.tsx'));
|
||||
export const PayRequestModal = lazy(() => import('soapbox/features/ui/components/modals/pay-request-modal.tsx'));
|
||||
export const ZapInvoiceModal = lazy(() => import('soapbox/features/ui/components/modals/zap-invoice.tsx'));
|
||||
export const ZapsModal = lazy(() => import('soapbox/features/ui/components/modals/zaps-modal.tsx'));
|
||||
export const ZapSplitModal = lazy(() => import('soapbox/features/ui/components/modals/zap-split/zap-split-modal.tsx'));
|
||||
|
|
|
@ -70,7 +70,7 @@ const ZapPayRequestForm = ({ account, status, onClose }: IZapPayRequestForm) =>
|
|||
// In this case, we simply close the modal
|
||||
|
||||
if (!invoice) {
|
||||
dispatch(closeModal('ZAP_PAY_REQUEST'));
|
||||
dispatch(closeModal('PAY_REQUEST'));
|
||||
// Dispatch the adm account
|
||||
if (zapSplitAccounts.length > 0) {
|
||||
dispatch(openModal('ZAP_SPLIT', { zapSplitAccounts, splitValues }));
|
||||
|
@ -78,7 +78,7 @@ const ZapPayRequestForm = ({ account, status, onClose }: IZapPayRequestForm) =>
|
|||
return;
|
||||
}
|
||||
// open QR code modal
|
||||
dispatch(closeModal('ZAP_PAY_REQUEST'));
|
||||
dispatch(closeModal('PAY_REQUEST'));
|
||||
dispatch(openModal('ZAP_INVOICE', { account, invoice, splitData }));
|
||||
};
|
||||
|
||||
|
@ -115,8 +115,8 @@ const ZapPayRequestForm = ({ account, status, onClose }: IZapPayRequestForm) =>
|
|||
|
||||
<Text weight='semibold'>
|
||||
<FormattedMessage
|
||||
id='nutzap.send_to'
|
||||
defaultMessage='Send cashus to {target}'
|
||||
id='zap.send_to'
|
||||
defaultMessage='Send zaps to {target}'
|
||||
values={{ target: emojifyText(account.display_name, account.emojis) }}
|
||||
/>
|
||||
</Text>
|
||||
|
|
|
@ -1522,5 +1522,6 @@
|
|||
"who_to_follow.title": "حسابات مقترحة",
|
||||
"zap.comment_input.placeholder": "تعليق إختياري",
|
||||
"zap.open_wallet": "فتح المحفظة",
|
||||
"nutzap.send_to": "أرسل cashus إلى {target}"
|
||||
"nutzap.send_to": "أرسل cashus إلى {target}",
|
||||
"zap.send_to": "أرسل zaps إلى {target}"
|
||||
}
|
||||
|
|
|
@ -1125,6 +1125,7 @@
|
|||
"my_wallet.management": "Wallet Management",
|
||||
"my_wallet.mints": "Mints",
|
||||
"my_wallet.relays": "Wallet Relays",
|
||||
"my_wallet.payment": "Payment Method",
|
||||
"my_wallet.transactions": "Transactions",
|
||||
"navbar.login.action": "Log in",
|
||||
"navbar.login.email.placeholder": "E-mail address",
|
||||
|
@ -1247,6 +1248,7 @@
|
|||
"notifications.group": "{count, plural, one {# notification} other {# notifications}}",
|
||||
"notifications.queue_label": "Click to see {count} new {count, plural, one {notification} other {notifications}}",
|
||||
"nutzap.send_to": "Send cashus to {target}",
|
||||
"zap.send_to": "Send zaps to {target}",
|
||||
"oauth_consumer.tooltip": "Sign in with {provider}",
|
||||
"oauth_consumers.title": "Other ways to sign in",
|
||||
"onboarding.avatar.subtitle": "Just have fun with it.",
|
||||
|
|
|
@ -1629,5 +1629,6 @@
|
|||
"zap.button.text.raw": "Zap {amount} sats",
|
||||
"zap.comment_input.placeholder": "Comentario opcional",
|
||||
"zap.open_wallet": "Abrir Wallet",
|
||||
"nutzap.send_to": "Enviar cachus a {target}"
|
||||
"nutzap.send_to": "Enviar cachus a {target}",
|
||||
"zap.send_to": "Enviar zaps a {target}"
|
||||
}
|
||||
|
|
|
@ -1686,6 +1686,7 @@
|
|||
"zap.next": "Ar Aghaidh",
|
||||
"zap.open_wallet": "Oscail Sparán",
|
||||
"nutzap.send_to": "Seol cashus chuig {target}",
|
||||
"zap.send_to": "Seol zaps chuig {target}",
|
||||
"zap.split_message.deducted": "Asbhainfear {amountDeducted} sats*",
|
||||
"zap.split_message.receiver": "Gheobhaidh {receiver} {amountReceiver} sats*",
|
||||
"zap_split.question": "Cén fáth a bhfuil mé ag íoc seo?",
|
||||
|
|
|
@ -1639,6 +1639,7 @@
|
|||
"zap.comment_input.placeholder": "Comentário opcional",
|
||||
"zap.open_wallet": "Abrir Carteira",
|
||||
"nutzap.send_to": "Enviar cashus para {target}",
|
||||
"zap.send_to": "Enviar zaps para {target}",
|
||||
"zap.split_message.deducted": "{amountDeducted} sats serão deduzidos*",
|
||||
"zap.split_message.receiver": "{receiver} receberá {amountReceiver} sats*",
|
||||
"zap_split.question": "Por que estou pagando isso?",
|
||||
|
|
|
@ -1618,5 +1618,6 @@
|
|||
"who_to_follow.title": "Quem Seguir",
|
||||
"zap.comment_input.placeholder": "Comentário opcional",
|
||||
"zap.open_wallet": "Abrir Carteira",
|
||||
"nutzap.send_to": "Enviar cashus para {target}"
|
||||
"nutzap.send_to": "Enviar cashus para {target}",
|
||||
"zap.send_to": "Enviar zaps para {target}"
|
||||
}
|
||||
|
|
|
@ -1623,5 +1623,5 @@
|
|||
"zap.button.text.raw": "打闪 {amount} 聪",
|
||||
"zap.comment_input.placeholder": "可选评论",
|
||||
"zap.open_wallet": "打开钱包",
|
||||
"nutzap.send_to": "发送打闪给 {target}"
|
||||
"zap.send_to": "发送打闪给 {target}"
|
||||
}
|
||||
|
|
Ładowanie…
Reference in New Issue