chore: formatting

This commit is contained in:
Kieran 2023-12-04 13:18:35 +00:00
parent 22297aecaa
commit 5780bc38c0
Signed by: Kieran
GPG Key ID: DE71CEB3925BE941
5 changed files with 30 additions and 12 deletions

View File

@ -54,15 +54,25 @@ function NewStream({ ev, onFinish }: Omit<StreamEditorProps, "onFinish"> & { onF
);
}
case StreamProviders.NostrType: {
return <>
<button className="btn btn-secondary" onClick={() => {
navigate("/settings");
onFinish?.();
}}>
<FormattedMessage defaultMessage="Get stream key" id="KdYELp" />
</button>
<NostrProviderDialog provider={currentProvider} onFinish={onFinish} ev={ev} showEndpoints={false} showEditor={true} />
</>;
return (
<>
<button
className="btn btn-secondary"
onClick={() => {
navigate("/settings");
onFinish?.();
}}>
<FormattedMessage defaultMessage="Get stream key" id="KdYELp" />
</button>
<NostrProviderDialog
provider={currentProvider}
onFinish={onFinish}
ev={ev}
showEndpoints={false}
showEditor={true}
/>
</>
);
}
case StreamProviders.Owncast: {
return;

View File

@ -14,7 +14,7 @@ export function NostrProviderDialog({
showEndpoints,
showEditor,
...others
}: { provider: StreamProvider; showEndpoints: boolean, showEditor: boolean } & StreamEditorProps) {
}: { provider: StreamProvider; showEndpoints: boolean; showEditor: boolean } & StreamEditorProps) {
const system = useContext(SnortContext);
const [topup, setTopup] = useState(false);
const [info, setInfo] = useState<StreamProviderInfo>();

View File

@ -179,6 +179,9 @@
"K7AkdL": {
"defaultMessage": "Show"
},
"KdYELp": {
"defaultMessage": "Get stream key"
},
"KkIL3s": {
"defaultMessage": "No, I am under 18"
},

View File

@ -11,7 +11,7 @@ import { useStreamProvider } from "@/hooks/stream-provider";
const enum Tab {
Account,
Notifications
Notifications,
}
export function SettingsPage() {
@ -57,7 +57,11 @@ export function SettingsPage() {
<h1>
<FormattedMessage defaultMessage="Stream Key" id="LknBsU" />
</h1>
<NostrProviderDialog provider={unwrap(providers.find(a => a.name === "zap.stream"))} showEndpoints={true} showEditor={false} />
<NostrProviderDialog
provider={unwrap(providers.find(a => a.name === "zap.stream"))}
showEndpoints={true}
showEditor={false}
/>
</>
);
}

View File

@ -59,6 +59,7 @@
"K3r6DQ": "Delete",
"K3uH1C": "offline",
"K7AkdL": "Show",
"KdYELp": "Get stream key",
"KkIL3s": "No, I am under 18",
"LknBsU": "Stream Key",
"My6HwN": "Ok, it's safe",