mirror of
https://github.com/antebudimir/feishin.git
synced 2026-01-02 02:43:33 +00:00
Refactor settings store and components
This commit is contained in:
parent
373441e4c6
commit
eecbcddea3
30 changed files with 894 additions and 832 deletions
|
|
@ -3,7 +3,7 @@ import isElectron from 'is-electron';
|
|||
import { RiCheckboxBlankLine, RiCloseLine, RiSubtractLine } from 'react-icons/ri';
|
||||
import styled from 'styled-components';
|
||||
import { useCurrentStatus, useQueueStatus } from '/@/renderer/store';
|
||||
import { useGeneralSettings } from '/@/renderer/store/settings.store';
|
||||
import { useWindowSettings } from '/@/renderer/store/settings.store';
|
||||
import { Platform, PlayerStatus } from '/@/renderer/types';
|
||||
import appIcon from '../../../assets/icon.svg';
|
||||
import macCloseHover from './assets/close-mac-hover.png';
|
||||
|
|
@ -212,7 +212,7 @@ const MacOsControls = ({ controls, title }: WindowBarControlsProps) => {
|
|||
export const WindowBar = () => {
|
||||
const playerStatus = useCurrentStatus();
|
||||
const { currentSong, index, length } = useQueueStatus();
|
||||
const { windowBarStyle } = useGeneralSettings();
|
||||
const { windowBarStyle } = useWindowSettings();
|
||||
|
||||
const statusString = playerStatus === PlayerStatus.PAUSED ? '(Paused) ' : '';
|
||||
const queueString = length ? `(${index + 1} / ${length}) ` : '';
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue