feat: single publisher
This commit is contained in:
parent
7ca6a3bc6e
commit
224bf5c85c
2
src/d.ts
2
src/d.ts
@ -47,3 +47,5 @@ declare module "light-bolt11-decoder" {
|
||||
value: string | Uint8Array | number | undefined;
|
||||
}
|
||||
}
|
||||
|
||||
declare const __SINGLE_PUBLISHER: string;
|
||||
|
@ -26,7 +26,7 @@ export function LiveVideoPlayer(props: VideoPlayerProps) {
|
||||
const hls = new Hls({
|
||||
enableWorker: true,
|
||||
lowLatencyMode: true,
|
||||
backBufferLength: 90
|
||||
backBufferLength: 90,
|
||||
});
|
||||
hls.loadSource(streamCached);
|
||||
hls.attachMedia(video.current);
|
||||
|
@ -17,9 +17,16 @@ export function useStreamsFeed(tag?: string) {
|
||||
leaveOpen: true,
|
||||
});
|
||||
if (tag) {
|
||||
rb.withFilter().kinds([LIVE_STREAM]).tag("t", [tag]).since(since);
|
||||
rb.withFilter()
|
||||
.kinds([LIVE_STREAM])
|
||||
.tag("t", [tag])
|
||||
.since(since)
|
||||
.authors(__SINGLE_PUBLISHER ? [__SINGLE_PUBLISHER] : undefined);
|
||||
} else {
|
||||
rb.withFilter().kinds([LIVE_STREAM]).since(since);
|
||||
rb.withFilter()
|
||||
.kinds([LIVE_STREAM])
|
||||
.since(since)
|
||||
.authors(__SINGLE_PUBLISHER ? [__SINGLE_PUBLISHER] : undefined);
|
||||
}
|
||||
return rb;
|
||||
}, [tag, since]);
|
||||
|
@ -55,7 +55,9 @@ export function LayoutPage() {
|
||||
|
||||
return (
|
||||
<>
|
||||
<NewStreamDialog btnClassName="btn btn-primary" />
|
||||
{(!__SINGLE_PUBLISHER || __SINGLE_PUBLISHER === login.pubkey) && (
|
||||
<NewStreamDialog btnClassName="btn btn-primary" />
|
||||
)}
|
||||
<Menu
|
||||
menuClassName="ctx-menu"
|
||||
menuButton={
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Zap Alert"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Зап Тревога"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "জ্যাপ অ্যালার্ট"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Zap Alert"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Zap Alert"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Alerta de Zap"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "هشدار زپ"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Zap-hälytys"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Alerte Zap"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Zap Riadó"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Zap Alert"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "ザップアラート"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Zap Alert"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Alerta Zap"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Оповещение о запе"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Zap Alert"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Tahadhari ya Zap"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "Zap Alert"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "打闪提示"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -418,4 +418,3 @@
|
||||
"defaultMessage": "打閃提示"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -61,6 +61,7 @@ const config = {
|
||||
new webpack.DefinePlugin({
|
||||
__XXX: process.env["__XXX"] || JSON.stringify(false),
|
||||
__XXX_HOST: JSON.stringify("https://xxzap.com"),
|
||||
__SINGLE_PUBLISHER: JSON.stringify(process.env.__SINGLE_PUBLISHER),
|
||||
}),
|
||||
isProduction
|
||||
? new WorkboxPlugin.InjectManifest({
|
||||
|
Loading…
x
Reference in New Issue
Block a user