fix: disable resizing in TextModal (#6718)
* Created resizable parameter in TextEditorArea * Changed resizable to false in TextModal
This commit is contained in:
parent
e0b1c63c1b
commit
e8d2635e1c
2 changed files with 6 additions and 1 deletions
|
|
@ -3,10 +3,12 @@ import { Textarea } from "../../../../components/ui/textarea";
|
||||||
const TextEditorArea = ({
|
const TextEditorArea = ({
|
||||||
left,
|
left,
|
||||||
value,
|
value,
|
||||||
|
resizable = true,
|
||||||
onChange,
|
onChange,
|
||||||
readonly,
|
readonly,
|
||||||
}: {
|
}: {
|
||||||
left: boolean | undefined;
|
left: boolean | undefined;
|
||||||
|
resizable?: boolean;
|
||||||
value: any;
|
value: any;
|
||||||
onChange?: (string) => void;
|
onChange?: (string) => void;
|
||||||
readonly: boolean;
|
readonly: boolean;
|
||||||
|
|
@ -17,7 +19,9 @@ const TextEditorArea = ({
|
||||||
return (
|
return (
|
||||||
<Textarea
|
<Textarea
|
||||||
readOnly={readonly}
|
readOnly={readonly}
|
||||||
className={`w-full custom-scroll ${left ? "min-h-32" : "h-full"}`}
|
className={`w-full custom-scroll ${left ? "min-h-32" : "h-full"} ${
|
||||||
|
resizable ? "resize-y" : "resize-none"
|
||||||
|
}`}
|
||||||
placeholder={"Empty"}
|
placeholder={"Empty"}
|
||||||
// update to real value on flowPool
|
// update to real value on flowPool
|
||||||
value={value}
|
value={value}
|
||||||
|
|
|
||||||
|
|
@ -54,6 +54,7 @@ export default function TextModal({
|
||||||
readonly={!editable}
|
readonly={!editable}
|
||||||
onChange={(text) => setInternalValue(text)}
|
onChange={(text) => setInternalValue(text)}
|
||||||
value={internalValue}
|
value={internalValue}
|
||||||
|
resizable={false}
|
||||||
left={false}
|
left={false}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue