style: notes

This commit is contained in:
cv
2021-06-13 14:29:41 +02:00
parent 17ddfb535f
commit 68b723d4ec
5 changed files with 10 additions and 5 deletions
+2 -2
View File
@@ -3,7 +3,7 @@ import { useEffect, useState } from 'react';
import style from './EditableText.module.css';
export default function EditableText(props) {
const { label, defaultValue, placeholder, submitHandler } = props;
const { label, defaultValue, placeholder, submitHandler, ...rest } = props;
const [text, setText] = useState(defaultValue || '');
useEffect(() => {
@@ -22,7 +22,7 @@ export default function EditableText(props) {
};
return (
<div className={style.block}>
<div className={style.block} {...rest}>
<span className={style.title}>{label}</span>
<Editable
onChange={(v) => handleChange(v)}