Add editor header translation keys (#1110)
<!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Implemented internationalization support across various components using the `useTranslate` function for dynamic content translation. - **Enhancements** - Updated UI elements such as buttons, tooltips, placeholders, and labels to display translated text, improving accessibility and user experience for non-English speakers. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Baptiste Arnaud <contact@baptiste-arnaud.fr> Co-authored-by: Baptiste Arnaud <baptiste.arnaud95@gmail.com>
This commit is contained in:
@@ -17,6 +17,7 @@ import { runtimes } from '../data'
|
||||
import { PreviewDrawerBody } from './PreviewDrawerBody'
|
||||
import { useDrag } from '@use-gesture/react'
|
||||
import { ResizeHandle } from './ResizeHandle'
|
||||
import { useTranslate } from '@tolgee/react'
|
||||
|
||||
const preferredRuntimeKey = 'preferredRuntime'
|
||||
|
||||
@@ -30,6 +31,7 @@ const getDefaultRuntime = (typebotId?: string) => {
|
||||
|
||||
export const PreviewDrawer = () => {
|
||||
const { typebot, save, isSavingLoading } = useTypebot()
|
||||
const { t } = useTranslate()
|
||||
const { setRightPanel } = useEditor()
|
||||
const { setPreviewingBlock } = useGraph()
|
||||
const [width, setWidth] = useState(500)
|
||||
@@ -103,7 +105,7 @@ export const PreviewDrawer = () => {
|
||||
isLoading={isSavingLoading}
|
||||
variant="ghost"
|
||||
>
|
||||
Restart
|
||||
{t('preview.restartButton.label')}
|
||||
</Button>
|
||||
) : null}
|
||||
</HStack>
|
||||
|
||||
Reference in New Issue
Block a user