🌐 Add translation keys for input blocks (#1114)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Integrated localization support across various components using the
`useTranslate` hook for dynamic translations.

- **Enhancements**
- Replaced hardcoded text with localized strings to support multiple
languages in the user interface.

- **User Interface**
- Updated labels, placeholders, tooltips, and button texts to utilize
translated content for a multilingual experience.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: Baptiste Arnaud <baptiste.arnaud95@gmail.com>
This commit is contained in:
Gabriel Pavão
2023-12-29 08:42:50 -03:00
committed by GitHub
parent 5fbbe9d86e
commit 53b702e8b1
37 changed files with 550 additions and 152 deletions

View File

@@ -31,9 +31,11 @@ const groupsActions = (setTypebot: SetTypebot): GroupsActions => ({
id,
block,
indices,
groupLabel,
...graphCoordinates
}: Coordinates & {
id: string
groupLabel?: string
block: BlockV6 | BlockV6['type']
indices: BlockIndices
}) =>
@@ -42,7 +44,7 @@ const groupsActions = (setTypebot: SetTypebot): GroupsActions => ({
const newGroup: GroupV6 = {
id,
graphCoordinates,
title: `Group #${typebot.groups.length + 1}`,
title: `${groupLabel ?? 'Group'} #${typebot.groups.length + 1}`,
blocks: [],
}
typebot.groups.push(newGroup)