Skip to content

Commit

Permalink
Fix types
Browse files Browse the repository at this point in the history
  • Loading branch information
nukeop committed Dec 29, 2021
1 parent cf35c92 commit 24a412a
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 9 deletions.
4 changes: 2 additions & 2 deletions packages/app/app/components/FavoriteTracksView/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import trackRowStyles from '../TrackRow/styles.scss';
import styles from './styles.scss';
import { Track } from '@nuclear/core';
import { getTrackArtist } from '@nuclear/ui/lib';
import { addToQueue } from '../../actions/queue';

export const EmptyState = () => {
const { t } = useTranslation('favorites');
Expand All @@ -33,7 +34,7 @@ type FavoriteTracksViewProps = {
clearQueue: () => void;
selectSong: (x:number) =>void;
startPlayback: () => void;
addToQueue: React.MouseEventHandler;
addToQueue: typeof addToQueue;
}

const FavoriteTracksView: React.FC<FavoriteTracksViewProps> = ({
Expand Down Expand Up @@ -106,7 +107,6 @@ const FavoriteTracksView: React.FC<FavoriteTracksViewProps> = ({
<TrackRow
data-testid={`fav-track-${track.uuid}`}
key={'favorite-track-' + index}
index={index}
track={track}
displayCover
displayArtist
Expand Down
3 changes: 1 addition & 2 deletions packages/app/app/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,7 @@ const render = async Component => {
type: 'languageDetector',
detect: () => getOption('language') || remote.app.getLocale(),
cacheUserLanguage: Function.prototype
},
react: true
}
});

ReactDOM.render(
Expand Down
6 changes: 1 addition & 5 deletions packages/i18n/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,9 @@ import zh_tw from './locales/zh_tw.json';
interface I18nOptions {
languageDetector: LanguageDetectorModule;
debug?: boolean;
react?: boolean;
}

export const setupI18n = ({ languageDetector, debug, react }: I18nOptions) => {
export const setupI18n = ({ languageDetector, debug }: I18nOptions) => {
return i18n.use(languageDetector).init({
fallbackLng: 'en',
debug,
Expand Down Expand Up @@ -85,9 +84,6 @@ export const setupI18n = ({ languageDetector, debug, react }: I18nOptions) => {
},
interpolation: {
escapeValue: false
},
react: {
wait: react
}
});
};
Expand Down

0 comments on commit 24a412a

Please sign in to comment.