Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export const GalleryChapterPanel: React.FC<IGalleryChapterPanelProps> = ({
return () => {
Mousetrap.unbind("n");
};
});
}, [isVisible]);

function onOpenEditor(chapter?: GQL.GalleryChapterDataFragment) {
setIsEditorOpen(true);
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/Galleries/GalleryList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ export const FilteredGalleryList = PatchComponent(
Mousetrap.unbind("e");
Mousetrap.unbind("d d");
};
});
}, []);

const onCloseEditDelete = useCloseEditDelete({
closeModal,
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/Groups/GroupDetails/Group.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ const GroupPage: React.FC<IProps> = ({ group, tabKey }) => {
Mousetrap.unbind("e");
Mousetrap.unbind("d d");
};
});
}, []);

useRatingKeybinds(
true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ export const GroupEditPanel: React.FC<IGroupEditPanel> = ({
// Mousetrap.unbind("u");
Mousetrap.unbind("s s");
};
});
}, []);

function updateGroupEditStateFromScraper(
state: Partial<GQL.ScrapedGroupDataFragment>
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/Groups/GroupList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,7 @@ export const FilteredGroupList = PatchComponent(
Mousetrap.unbind("e");
Mousetrap.unbind("d d");
};
});
}, []);

const onCloseEditDelete = useCloseEditDelete({
closeModal,
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/Images/ImageDetails/Image.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ const ImagePage: React.FC<IProps> = ({ image }) => {
Mousetrap.unbind("f");
Mousetrap.unbind("o");
};
});
}, []);

const file = useMemo(
() => (image.visual_files.length > 0 ? image.visual_files[0] : undefined),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ export const ImageEditPanel: React.FC<IProps> = ({
Mousetrap.unbind("d d");
};
}
});
}, [isVisible]);

const fragmentScrapers = useMemo(() => {
return (scrapers?.data?.listScrapers ?? []).filter((s) =>
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/List/EditFilterDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ export const EditFilterDialog: React.FC<IEditFilterProps> = ({
return () => {
Mousetrap.unbind("/");
};
});
}, []);

async function updatePinnedFilters(filters: string[]) {
const configKey = filterModeToConfigKey(currentFilter.mode);
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/List/ListFilter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ export const SearchTermInput: React.FC<{
return () => {
Mousetrap.unbind("/");
};
});
}, []);

function onSetQuery(value: string) {
setLocalInput(value);
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/List/ListViewOptions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ export const ListViewOptions: React.FC<IListViewOptionsProps> = ({
Mousetrap.unbind("v w");
Mousetrap.unbind("v t");
};
});
}, []);

function onChangeZoom(v: number) {
if (onSetZoom) {
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/List/ZoomSlider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export function useZoomKeybinds(props: {
Mousetrap.unbind("+");
Mousetrap.unbind("-");
};
});
}, []);
}

export interface IZoomSelectProps {
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/MainNavbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ export const MainNavbar: React.FC = () => {
Mousetrap.unbind("n");
}
};
});
}, []);

function maybeRenderLogout() {
if (SessionUtils.isLoggedIn()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ const PerformerTabs: React.FC<{
Mousetrap.unbind("g");
Mousetrap.unbind("m");
};
});
}, []);

return (
<Tabs
Expand Down Expand Up @@ -331,7 +331,7 @@ const PerformerPage: React.FC<IProps> = PatchComponent(
Mousetrap.unbind("f");
Mousetrap.unbind(",");
};
});
}, []);

async function onSave(input: GQL.PerformerCreateInput) {
await updatePerformer({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,7 @@ export const PerformerEditPanel: React.FC<IPerformerDetails> = ({
}
};
}
});
}, [isVisible]);

useEffect(() => {
const newQueryableScrapers = (Scrapers?.data?.listScrapers ?? []).filter(
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/Performers/PerformerList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -447,7 +447,7 @@ export const FilteredPerformerList = PatchComponent(
Mousetrap.unbind("e");
Mousetrap.unbind("d d");
};
});
}, []);

const onCloseEditDelete = useCloseEditDelete({
closeModal,
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/Scenes/SceneDetails/Scene.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ const ScenePage: React.FC<IProps> = PatchComponent("ScenePage", (props) => {
Mousetrap.unbind("c c");
Mousetrap.unbind("c d");
};
});
}, []);

async function onSave(input: GQL.SceneCreateInput) {
await updateScene({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ export const SceneEditPanel: React.FC<IProps> = ({
Mousetrap.unbind("d d");
};
}
});
}, [isVisible]);

useEffect(() => {
const toFilter = Scrapers?.data?.listScrapers ?? [];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export const SceneMarkersPanel: React.FC<ISceneMarkersPanelProps> = ({
return () => {
Mousetrap.unbind("n");
};
});
}, [isVisible]);

if (loading) return null;

Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/Studios/StudioDetails/Studio.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@ const StudioPage: React.FC<IProps> = ({ studio, tabKey }) => {
Mousetrap.unbind(",");
Mousetrap.unbind("f");
};
});
}, []);

useRatingKeybinds(
true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ export const StudioEditPanel: React.FC<IStudioEditPanel> = ({
return () => {
Mousetrap.unbind("s s");
};
});
}, []);

async function onSave(input: InputValues, andNew?: boolean) {
setIsLoading(true);
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/Studios/StudioList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ export const FilteredStudioList = PatchComponent(
Mousetrap.unbind("e");
Mousetrap.unbind("d d");
};
});
}, []);

const onCloseEditDelete = useCloseEditDelete({
closeModal,
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/Tags/TagDetails/Tag.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ const TagPage: React.FC<IProps> = ({ tag, tabKey }) => {
Mousetrap.unbind(",");
Mousetrap.unbind("f");
};
});
}, []);

async function onSave(input: GQL.TagCreateInput) {
const oldRelations = {
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/components/Tags/TagList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@ export const FilteredTagList = PatchComponent(
Mousetrap.unbind("e");
Mousetrap.unbind("d d");
};
});
}, []);

const onCloseEditDelete = useCloseEditDelete({
closeModal,
Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/hooks/LocalForage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ export function useLocalForage<T extends {}>(
};
localForage.setItem(key, Cache[key]);
}
});
}, []);

const isLoading = loading || loading === undefined;

Expand Down
2 changes: 1 addition & 1 deletion ui/v2.5/src/hooks/keybinds.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,5 +81,5 @@ export function useRatingKeybinds(
return () => {
Mousetrap.unbind("r");
};
});
}, [isVisible]);
}
2 changes: 1 addition & 1 deletion ui/v2.5/src/utils/form.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export function useStopWheelScroll(ref: React.RefObject<HTMLElement>) {
current.removeEventListener("wheel", stopWheelScroll);
}
};
});
}, []);
}

// NumberField is a wrapper around Form.Control that prevents wheel events from scrolling the window.
Expand Down