🔄 refactor(keypairListComponent): replace Input component with Textarea component for key and value inputs

🐛 fix(keypairListComponent): fix incorrect prop name in Textarea component for value input
This commit is contained in:
Cristhian Zanforlin Lousa 2023-09-26 08:19:31 -03:00
commit 5c57e62f55

View file

@ -4,7 +4,7 @@ import { KeyPairListComponentType } from "../../types/components";
import _ from "lodash"; import _ from "lodash";
import { classNames } from "../../utils/utils"; import { classNames } from "../../utils/utils";
import IconComponent from "../genericIconComponent"; import IconComponent from "../genericIconComponent";
import { Input } from "../ui/input"; import { Textarea } from "../ui/textarea";
export default function KeypairListComponent({ export default function KeypairListComponent({
value, value,
@ -49,8 +49,7 @@ export default function KeypairListComponent({
return Object.keys(obj).map((key, idx) => { return Object.keys(obj).map((key, idx) => {
return ( return (
<div key={idx} className="flex w-full gap-3"> <div key={idx} className="flex w-full gap-3">
<Input <Textarea
type="text"
value={key.trim()} value={key.trim()}
className={classNames( className={classNames(
editNode ? "input-edit-node" : "", editNode ? "input-edit-node" : "",
@ -66,8 +65,7 @@ export default function KeypairListComponent({
}} }}
/> />
<Input <Textarea
type="text"
value={obj[key]} value={obj[key]}
className={editNode ? "input-edit-node" : ""} className={editNode ? "input-edit-node" : ""}
placeholder="Type a value..." placeholder="Type a value..."