fix: Lint errors

This commit is contained in:
blessedcoolant 2023-07-29 02:37:59 +12:00
parent 5ff4dd26bb
commit 8f2a646286
2 changed files with 6 additions and 18 deletions

View File

@ -21,14 +21,12 @@ import SDXLConcatLink from './SDXLConcatLink';
const promptInputSelector = createSelector( const promptInputSelector = createSelector(
[stateSelector, activeTabNameSelector], [stateSelector, activeTabNameSelector],
({ sdxl, ui }, activeTabName) => { ({ sdxl }, activeTabName) => {
const { negativeStylePrompt, shouldConcatSDXLStylePrompt } = sdxl; const { negativeStylePrompt, shouldConcatSDXLStylePrompt } = sdxl;
const { shouldPinParametersPanel } = ui;
return { return {
prompt: negativeStylePrompt, prompt: negativeStylePrompt,
shouldConcatSDXLStylePrompt, shouldConcatSDXLStylePrompt,
shouldPinParametersPanel,
activeTabName, activeTabName,
}; };
}, },
@ -48,12 +46,8 @@ const ParamSDXLNegativeStyleConditioning = () => {
const promptRef = useRef<HTMLTextAreaElement>(null); const promptRef = useRef<HTMLTextAreaElement>(null);
const { isOpen, onClose, onOpen } = useDisclosure(); const { isOpen, onClose, onOpen } = useDisclosure();
const { const { prompt, activeTabName, shouldConcatSDXLStylePrompt } =
prompt, useAppSelector(promptInputSelector);
activeTabName,
shouldPinParametersPanel,
shouldConcatSDXLStylePrompt,
} = useAppSelector(promptInputSelector);
const handleChangePrompt = useCallback( const handleChangePrompt = useCallback(
(e: ChangeEvent<HTMLTextAreaElement>) => { (e: ChangeEvent<HTMLTextAreaElement>) => {

View File

@ -21,13 +21,11 @@ import SDXLConcatLink from './SDXLConcatLink';
const promptInputSelector = createSelector( const promptInputSelector = createSelector(
[stateSelector, activeTabNameSelector], [stateSelector, activeTabNameSelector],
({ sdxl, ui }, activeTabName) => { ({ sdxl }, activeTabName) => {
const { positiveStylePrompt, shouldConcatSDXLStylePrompt } = sdxl; const { positiveStylePrompt, shouldConcatSDXLStylePrompt } = sdxl;
const { shouldPinParametersPanel } = ui;
return { return {
prompt: positiveStylePrompt, prompt: positiveStylePrompt,
shouldPinParametersPanel,
shouldConcatSDXLStylePrompt, shouldConcatSDXLStylePrompt,
activeTabName, activeTabName,
}; };
@ -48,12 +46,8 @@ const ParamSDXLPositiveStyleConditioning = () => {
const promptRef = useRef<HTMLTextAreaElement>(null); const promptRef = useRef<HTMLTextAreaElement>(null);
const { isOpen, onClose, onOpen } = useDisclosure(); const { isOpen, onClose, onOpen } = useDisclosure();
const { const { prompt, activeTabName, shouldConcatSDXLStylePrompt } =
prompt, useAppSelector(promptInputSelector);
activeTabName,
shouldPinParametersPanel,
shouldConcatSDXLStylePrompt,
} = useAppSelector(promptInputSelector);
const handleChangePrompt = useCallback( const handleChangePrompt = useCallback(
(e: ChangeEvent<HTMLTextAreaElement>) => { (e: ChangeEvent<HTMLTextAreaElement>) => {