* Refactor icons passed as props with the new way Co-authored-by: v1b3m <vibenjamin6@gmail.com> Co-authored-by: Matheus <matheus_benini@hotmail.com> * Update more files Co-authored-by: v1b3m <vibenjamin6@gmail.com> Co-authored-by: Matheus <matheus_benini@hotmail.com> * Fix according to review * Fix according to review * Fix according to review * Fix chromatic regressions --------- Co-authored-by: v1b3m <vibenjamin6@gmail.com> Co-authored-by: Matheus <matheus_benini@hotmail.com> Co-authored-by: Charles Bochet <charles@twenty.com>
22 lines
513 B
TypeScript
22 lines
513 B
TypeScript
import { FloatingIconButton } from '@/ui/button/components/FloatingIconButton';
|
|
import { IconPencil } from '@/ui/icon';
|
|
|
|
import { useEditableField } from '../hooks/useEditableField';
|
|
|
|
export function EditableFieldEditButton() {
|
|
const { openEditableField } = useEditableField();
|
|
|
|
function handleClick() {
|
|
openEditableField();
|
|
}
|
|
|
|
return (
|
|
<FloatingIconButton
|
|
size="small"
|
|
onClick={handleClick}
|
|
Icon={IconPencil}
|
|
data-testid="editable-field-edit-mode-container"
|
|
/>
|
|
);
|
|
}
|