mirror of
https://github.com/antebudimir/feishin.git
synced 2026-01-01 18:33:33 +00:00
fix all imports for new structure
This commit is contained in:
parent
249eaf89f8
commit
930165d006
291 changed files with 2056 additions and 1894 deletions
|
|
@ -5,7 +5,7 @@ import { RiAlbumFill, RiPlayListFill, RiUserVoiceFill } from 'react-icons/ri';
|
|||
|
||||
import styles from './item-image-placeholder.module.css';
|
||||
|
||||
import { LibraryItem } from '/@/renderer/api/types';
|
||||
import { LibraryItem } from '/@/shared/types/domain-types';
|
||||
|
||||
interface ItemImagePlaceholderProps {
|
||||
itemType?: LibraryItem;
|
||||
|
|
|
|||
|
|
@ -8,10 +8,10 @@ import { Link } from 'react-router-dom';
|
|||
|
||||
import styles from './library-header.module.css';
|
||||
|
||||
import { LibraryItem } from '/@/renderer/api/types';
|
||||
import { Text } from '/@/renderer/components';
|
||||
import { ItemImagePlaceholder } from '/@/renderer/features/shared/components/item-image-placeholder';
|
||||
import { useGeneralSettings } from '/@/renderer/store';
|
||||
import { LibraryItem } from '/@/shared/types/domain-types';
|
||||
|
||||
interface LibraryHeaderProps {
|
||||
background: string;
|
||||
|
|
@ -25,15 +25,7 @@ interface LibraryHeaderProps {
|
|||
|
||||
export const LibraryHeader = forwardRef(
|
||||
(
|
||||
{
|
||||
background,
|
||||
blur,
|
||||
children,
|
||||
imagePlaceholderUrl,
|
||||
imageUrl,
|
||||
item,
|
||||
title,
|
||||
}: LibraryHeaderProps,
|
||||
{ background, blur, children, imageUrl, item, title }: LibraryHeaderProps,
|
||||
ref: Ref<HTMLDivElement>,
|
||||
) => {
|
||||
const { t } = useTranslation();
|
||||
|
|
@ -119,7 +111,7 @@ export const LibraryHeader = forwardRef(
|
|||
alt="cover"
|
||||
className={styles.image}
|
||||
onError={onImageError}
|
||||
placeholder={imagePlaceholderUrl || 'var(--placeholder-bg)'}
|
||||
// placeholder={imagePlaceholderUrl || 'var(--placeholder-bg)'}
|
||||
src={imageUrl}
|
||||
style={{ height: '' }}
|
||||
/>
|
||||
|
|
|
|||
|
|
@ -2,8 +2,8 @@ import { ButtonProps } from '@mantine/core';
|
|||
import { useTranslation } from 'react-i18next';
|
||||
import { RiSortAsc, RiSortDesc } from 'react-icons/ri';
|
||||
|
||||
import { SortOrder } from '/@/renderer/api/types';
|
||||
import { Button, Tooltip } from '/@/renderer/components';
|
||||
import { SortOrder } from '/@/shared/types/domain-types';
|
||||
|
||||
interface OrderToggleButtonProps {
|
||||
buttonProps?: Partial<ButtonProps>;
|
||||
|
|
|
|||
|
|
@ -1,10 +1,10 @@
|
|||
import { MutableRefObject, useCallback } from 'react';
|
||||
|
||||
import { LibraryItem } from '/@/renderer/api/types';
|
||||
import { VirtualInfiniteGridRef } from '/@/renderer/components/virtual-grid';
|
||||
import { useCreateFavorite } from '/@/renderer/features/shared/mutations/create-favorite-mutation';
|
||||
import { useDeleteFavorite } from '/@/renderer/features/shared/mutations/delete-favorite-mutation';
|
||||
import { ServerListItem } from '/@/renderer/types';
|
||||
import { LibraryItem } from '/@/shared/types/domain-types';
|
||||
import { ServerListItem } from '/@/shared/types/types';
|
||||
|
||||
interface HandleFavoriteProps {
|
||||
gridRef: MutableRefObject<null | VirtualInfiniteGridRef>;
|
||||
|
|
|
|||
|
|
@ -4,16 +4,16 @@ import isElectron from 'is-electron';
|
|||
|
||||
import { api } from '/@/renderer/api';
|
||||
import { queryKeys } from '/@/renderer/api/query-keys';
|
||||
import { MutationHookArgs } from '/@/renderer/lib/react-query';
|
||||
import { getServerById, useSetAlbumListItemDataById, useSetQueueFavorite } from '/@/renderer/store';
|
||||
import { useFavoriteEvent } from '/@/renderer/store/event.store';
|
||||
import {
|
||||
AlbumArtistDetailResponse,
|
||||
AlbumDetailResponse,
|
||||
FavoriteArgs,
|
||||
FavoriteResponse,
|
||||
LibraryItem,
|
||||
} from '/@/renderer/api/types';
|
||||
import { MutationHookArgs } from '/@/renderer/lib/react-query';
|
||||
import { getServerById, useSetAlbumListItemDataById, useSetQueueFavorite } from '/@/renderer/store';
|
||||
import { useFavoriteEvent } from '/@/renderer/store/event.store';
|
||||
} from '/@/shared/types/domain-types';
|
||||
|
||||
const remote = isElectron() ? window.api.remote : null;
|
||||
|
||||
|
|
|
|||
|
|
@ -4,16 +4,16 @@ import isElectron from 'is-electron';
|
|||
|
||||
import { api } from '/@/renderer/api';
|
||||
import { queryKeys } from '/@/renderer/api/query-keys';
|
||||
import { MutationHookArgs } from '/@/renderer/lib/react-query';
|
||||
import { getServerById, useSetAlbumListItemDataById, useSetQueueFavorite } from '/@/renderer/store';
|
||||
import { useFavoriteEvent } from '/@/renderer/store/event.store';
|
||||
import {
|
||||
AlbumArtistDetailResponse,
|
||||
AlbumDetailResponse,
|
||||
FavoriteArgs,
|
||||
FavoriteResponse,
|
||||
LibraryItem,
|
||||
} from '/@/renderer/api/types';
|
||||
import { MutationHookArgs } from '/@/renderer/lib/react-query';
|
||||
import { getServerById, useSetAlbumListItemDataById, useSetQueueFavorite } from '/@/renderer/store';
|
||||
import { useFavoriteEvent } from '/@/renderer/store/event.store';
|
||||
} from '/@/shared/types/domain-types';
|
||||
|
||||
const remote = isElectron() ? window.api.remote : null;
|
||||
|
||||
|
|
|
|||
|
|
@ -4,6 +4,9 @@ import isElectron from 'is-electron';
|
|||
|
||||
import { api } from '/@/renderer/api';
|
||||
import { queryKeys } from '/@/renderer/api/query-keys';
|
||||
import { MutationHookArgs } from '/@/renderer/lib/react-query';
|
||||
import { getServerById, useSetAlbumListItemDataById, useSetQueueRating } from '/@/renderer/store';
|
||||
import { useRatingEvent } from '/@/renderer/store/event.store';
|
||||
import {
|
||||
Album,
|
||||
AlbumArtist,
|
||||
|
|
@ -13,10 +16,7 @@ import {
|
|||
LibraryItem,
|
||||
RatingResponse,
|
||||
SetRatingArgs,
|
||||
} from '/@/renderer/api/types';
|
||||
import { MutationHookArgs } from '/@/renderer/lib/react-query';
|
||||
import { getServerById, useSetAlbumListItemDataById, useSetQueueRating } from '/@/renderer/store';
|
||||
import { useRatingEvent } from '/@/renderer/store/event.store';
|
||||
} from '/@/shared/types/domain-types';
|
||||
|
||||
const remote = isElectron() ? window.api.remote : null;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,11 +1,10 @@
|
|||
import { useQuery } from '@tanstack/react-query';
|
||||
|
||||
import { MusicFolderListQuery } from '../../../api/types';
|
||||
import { QueryHookArgs } from '../../../lib/react-query';
|
||||
|
||||
import { api } from '/@/renderer/api';
|
||||
import { queryKeys } from '/@/renderer/api/query-keys';
|
||||
import { QueryHookArgs } from '/@/renderer/lib/react-query';
|
||||
import { getServerById } from '/@/renderer/store';
|
||||
import { MusicFolderListQuery } from '/@/shared/types/domain-types';
|
||||
|
||||
export const useMusicFolders = (args: QueryHookArgs<MusicFolderListQuery>) => {
|
||||
const { options, serverId } = args || {};
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import i18n from '/@/i18n/i18n';
|
||||
import { Play } from '/@/renderer/types';
|
||||
import { Play } from '/@/shared/types/types';
|
||||
|
||||
export const PLAY_TYPES = [
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue