mirror of
https://github.com/meowarex/TidaLuna-Plugins.git
synced 2026-10-15 07:53:13 +11:00
feat: add fps setting
This commit is contained in:
1 parent
8ef69f57a2
commit
47813e0559
4 files changed
+74
-77
No files matched your search
@@ -9,6 +9,7 @@ declare global {
|
||||
updateRadiantLyricsPlayerBarTint?: () => void;
|
||||
updateRadiantLyricsBackdrop?: () => void;
|
||||
updateAnimatedArtwork?: (target?: unknown) => void;
|
||||
updateAnimatedArtworkRate?: () => void;
|
||||
updateQualityProgressColor?: () => void;
|
||||
updateIntegratedSeekBar?: () => void;
|
||||
updateLyricsStyle?: () => void;
|
||||
@@ -50,6 +51,7 @@ export const settings = await ReactiveStore.getPluginStorage("RadiantLyrics", {
|
||||
// Master switch
|
||||
backdropEnabled: true,
|
||||
animatedArtwork: true,
|
||||
animatedArtworkFps: 25,
|
||||
backdropStyle: 0,
|
||||
backdropPlaybackReactive: true,
|
||||
CoverEverywhere: true,
|
||||
@@ -87,6 +89,9 @@ export const Settings = () => {
|
||||
const [animatedArtwork, setAnimatedArtwork] = React.useState(
|
||||
settings.animatedArtwork,
|
||||
);
|
||||
const [animatedArtworkFps, setAnimatedArtworkFps] = React.useState(
|
||||
settings.animatedArtworkFps,
|
||||
);
|
||||
const [backdropStyle, setBackdropStyle] = React.useState(
|
||||
settings.backdropStyle,
|
||||
);
|
||||
@@ -930,6 +935,21 @@ export const Settings = () => {
|
||||
window.updateAnimatedArtwork?.();
|
||||
}}
|
||||
/>
|
||||
{animatedArtwork && (
|
||||
<LunaNumberSetting
|
||||
title="Animated Artwork Frame Rate"
|
||||
desc="Frames per second for the animated artwork. Lower is cheaper but choppier; 25 is native speed."
|
||||
min={1}
|
||||
max={25}
|
||||
step={1}
|
||||
value={animatedArtworkFps}
|
||||
onNumber={(value: number) => {
|
||||
settings.animatedArtworkFps = value;
|
||||
setAnimatedArtworkFps(value);
|
||||
window.updateAnimatedArtworkRate?.();
|
||||
}}
|
||||
/>
|
||||
)}
|
||||
{backdropEnabled && (
|
||||
<>
|
||||
<LunaNumberSetting
|
||||
|
||||
Reference in new issue
Block a user