mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
Lint Code
This commit is contained in:
parent
de73e4f5b9
commit
2d0f932737
@ -1,3 +1,4 @@
|
||||
import { memo, ChangeEvent } from 'react';
|
||||
import { Textarea, Input } from '@chakra-ui/react';
|
||||
import { useAppDispatch } from 'app/store/storeHooks';
|
||||
import { fieldValueChanged } from 'features/nodes/store/nodesSlice';
|
||||
@ -5,9 +6,10 @@ import {
|
||||
StringInputFieldTemplate,
|
||||
StringInputFieldValue,
|
||||
} from 'features/nodes/types/types';
|
||||
import { ChangeEvent, memo } from 'react';
|
||||
import { FieldComponentProps } from './types';
|
||||
|
||||
const FIELD_PADDING = 20;
|
||||
|
||||
const StringInputFieldComponent = (
|
||||
props: FieldComponentProps<
|
||||
StringInputFieldValue,
|
||||
@ -31,12 +33,13 @@ const StringInputFieldComponent = (
|
||||
);
|
||||
};
|
||||
|
||||
const textareaWidth = nodeWidth - 20;
|
||||
const textareaWidth = nodeWidth - FIELD_PADDING;
|
||||
|
||||
const textareaFieldNames = ['prompt', 'text'];
|
||||
|
||||
return (
|
||||
<>
|
||||
{field.name.toLowerCase() === 'prompt' ||
|
||||
field.name.toLowerCase() === 'text' ? (
|
||||
{textareaFieldNames.includes(field.name.toLowerCase()) ? (
|
||||
<Textarea
|
||||
style={{
|
||||
height: '150px',
|
||||
|
Loading…
Reference in New Issue
Block a user