-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Input blocks pt-BR translation #1114
Input blocks pt-BR translation #1114
Conversation
…er_feat/input-blocks-pt_BR-translation
@gabrielgpavao is attempting to deploy a commit to the Typebot Team on Vercel. A member of the Team first needs to authorize it. |
Important Auto Review SkippedReview was skipped due to path filters WalkthroughThe overall change involves integrating internationalization (i18n) across various components of a React application using the Changes
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChat with CodeRabbit Bot (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 1
Configuration used: CodeRabbit UI
Files ignored due to filter (2)
- apps/builder/public/locales/en.json
- apps/builder/public/locales/pt-BR.json
Files selected for processing (41)
- apps/builder/src/components/DropdownList.tsx (3 hunks)
- apps/builder/src/components/SetVariableLabel.tsx (3 hunks)
- apps/builder/src/components/inputs/VariableSearchInput.tsx (6 hunks)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsBlockNode.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsBlockSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsItemNode.tsx (6 hunks)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsItemSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/date/components/DateInputSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/date/components/DateNodeContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/emailInput/components/EmailInputNodeContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/emailInput/components/EmailInputSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/fileUpload/components/FileInputContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/fileUpload/components/FileInputSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/number/components/NumberInputSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/number/components/NumberNodeContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/payment/components/PaymentAddressSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/payment/components/PaymentInputContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/payment/components/PaymentSettings.tsx (4 hunks)
- apps/builder/src/features/blocks/inputs/payment/components/StripeConfigModal.tsx (6 hunks)
- apps/builder/src/features/blocks/inputs/phone/components/CountryCodeSelect.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/phone/components/PhoneInputSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/phone/components/PhoneNodeContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceItemSettings.tsx (4 hunks)
- apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceNode.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceSettings.tsx (6 hunks)
- apps/builder/src/features/blocks/inputs/rating/components/RatingInputContent.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/rating/components/RatingInputSettings.tsx (4 hunks)
- apps/builder/src/features/blocks/inputs/textInput/components/TextInputNodeContent.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/textInput/components/TextInputSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/url/components/UrlInputSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/url/components/UrlNodeContent.tsx (1 hunks)
- apps/builder/src/features/blocks/logic/condition/components/ComparisonItem.tsx (3 hunks)
- apps/builder/src/features/blocks/logic/condition/components/ConditionContent.tsx (4 hunks)
- apps/builder/src/features/blocks/logic/condition/components/ConditionForm.tsx (2 hunks)
- apps/builder/src/features/credentials/components/CredentialsDropdown.tsx (6 hunks)
- apps/builder/src/features/editor/providers/typebotActions/groups.ts (2 hunks)
- apps/builder/src/features/graph/components/nodes/block/BlockNodeContextMenu.tsx (2 hunks)
- apps/builder/src/features/graph/components/nodes/block/SettingsHoverBar.tsx (2 hunks)
- apps/builder/src/features/graph/components/nodes/group/GroupNodeContextMenu.tsx (2 hunks)
- apps/builder/src/features/graph/components/nodes/item/ItemNodesList.tsx (3 hunks)
- apps/builder/src/features/variables/components/VariablesButton.tsx (4 hunks)
Files skipped from review due to trivial changes (1)
- apps/builder/src/features/graph/components/nodes/block/BlockNodeContextMenu.tsx
Additional comments: 110
apps/builder/src/features/blocks/inputs/date/components/DateNodeContent.tsx (1)
- 4-17: The addition of the
useTranslate
hook and the use of thet
function to replace a hardcoded string with a translated label is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/url/components/UrlNodeContent.tsx (1)
- 5-22: The addition of the
useTranslate
hook and the use of thet
function to replace a hardcoded string with a translated label is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/payment/components/PaymentInputContent.tsx (1)
- 2-24: The addition of the
useTranslate
hook and the use of thet
function to replace static strings with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/number/components/NumberNodeContent.tsx (1)
- 5-23: The addition of the
useTranslate
hook and the use of thet
function to replace a hardcoded string with a translated label is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/emailInput/components/EmailInputNodeContent.tsx (1)
- 5-23: The addition of the
useTranslate
hook and the use of thet
function to replace a hardcoded string with a translated label is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/phone/components/PhoneNodeContent.tsx (1)
- 5-23: The addition of the
useTranslate
hook and the use of thet
function to replace a hardcoded string with a translated label is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/fileUpload/components/FileInputContent.tsx (1)
- 3-24: The addition of the
useTranslate
hook and the use of thet
function to replace static strings with translated labels based on theisMultipleAllowed
property is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/textInput/components/TextInputNodeContent.tsx (1)
- 2-16: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [5-26]
The addition of the
useTranslate
hook and the use of thet
function to replace a hardcoded string with a translated label is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/components/SetVariableLabel.tsx (1)
- 9-15: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [2-22]
The addition of the
useTranslate
hook and the use of thet
function to replace a hardcoded string with a translated label is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/graph/components/nodes/group/GroupNodeContextMenu.tsx (1)
- 1-14: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [4-27]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded strings with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/rating/components/RatingInputContent.tsx (1)
- 9-25: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [3-25]
The addition of the
useTranslate
hook and the use of thet
function to replace static strings with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/graph/components/nodes/block/SettingsHoverBar.tsx (1)
- 9-23: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [12-54]
The addition of the
useTranslate
hook and the use of thet
function to replace the static "Help" text with a translated version is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/buttons/components/ButtonsBlockNode.tsx (1)
- 4-19: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [7-29]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded strings with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceNode.tsx (1)
- 5-19: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [8-31]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded strings with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/logic/condition/components/ConditionForm.tsx (1)
- 29-46: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [10-47]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded strings with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/buttons/components/ButtonsItemSettings.tsx (1)
- 4-19: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [7-51]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded labels with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/variables/components/VariablesButton.tsx (1)
- 37-45: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [18-62]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded strings with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/url/components/UrlInputSettings.tsx (1)
- 24-54: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [4-54]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded labels with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/emailInput/components/EmailInputSettings.tsx (1)
- 24-54: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [4-54]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded labels with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/textInput/components/TextInputSettings.tsx (1)
- 26-53: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [5-69]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded labels with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/editor/providers/typebotActions/groups.ts (1)
- 43-49: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [12-49]
The addition of the
tolgee
import and the use oftolgee.t
to provide a translated default group name is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/phone/components/PhoneInputSettings.tsx (1)
- 27-66: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [7-66]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded labels with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/features/blocks/inputs/number/components/NumberInputSettings.tsx (1)
- 32-69: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [4-69]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded labels with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations.apps/builder/src/components/DropdownList.tsx (1)
- 82-100: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [19-100]
The addition of the
useTranslate
hook and the translation of dropdown items using thet
function is correctly implemented. This change aligns with the PR's objective to support pt-BR translations and enhances the internationalization of the dropdown component.apps/builder/src/features/blocks/inputs/payment/components/PaymentAddressSettings.tsx (1)
- 59-99: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [12-99]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded labels with translated labels is correctly implemented. This change aligns with the PR's objective to support pt-BR translations and enhances the internationalization of the payment address settings.apps/builder/src/features/blocks/logic/condition/components/ComparisonItem.tsx (1)
- 34-65: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [8-65]
The addition of the
useTranslate
hook and the use of thet
function to replace hardcoded placeholders and default values with translated strings is correctly implemented. This change aligns with the PR's objective to support pt-BR translations and enhances the internationalization of the comparison item component.apps/builder/src/features/blocks/logic/condition/components/ConditionContent.tsx (6)
2-2: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.19-19: The destructuring assignment for
t
fromuseTranslate
is correctly placed within the functional component to access the translation function.27-31: The conditional rendering based on the index to display the "if" label is correctly translated using the
t
function.33-39: The logical operator is being translated using the
t
function. Ensure that the translation keys likecomponents.dropdownList.item.${condition.logicalOperator?.replace(/\s/g, "")}
are correctly defined in the translation files.48-50: The
parseComparisonOperatorSymbol
function is correctly modified to return translation keys instead of hardcoded strings, which is then used with thet
function for internationalization.75-97: The
parseComparisonOperatorSymbol
function has been updated to return translation keys for different comparison operators. Ensure that these keys are correctly defined in the translation files and that the translations are provided for all supported languages.apps/builder/src/features/blocks/inputs/buttons/components/ButtonsBlockSettings.tsx (6)
9-9: The
useTranslate
hook is correctly imported from@tolgee/react
to support internationalization.17-17: The
t
function fromuseTranslate
is correctly destructured within the component to be used for translating strings.34-44: The labels for the
SwitchWithRelatedSettings
andTextInput
components are correctly replaced with translated strings using thet
function.50-60: The label for the searchable setting and its corresponding input placeholder are correctly internationalized using the
t
function.67-69: The translation function
t
is used correctly to internationalize the tooltip text for the dynamic data setting.79-79: The label for saving the answer in a variable is correctly internationalized using the
t
function.apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceItemSettings.tsx (5)
18-18: The
useTranslate
hook is correctly imported from@tolgee/react
to support internationalization.35-35: The
t
function fromuseTranslate
is correctly destructured within the component to be used for translating strings.67-77: The label for the image in the
PictureChoiceItemSettings
component is correctly internationalized using thet
function.101-106: The labels for title and description inputs are correctly replaced with translated strings using the
t
function.111-111: The label for the display condition switch is correctly internationalized using the
t
function.apps/builder/src/features/blocks/inputs/fileUpload/components/FileInputSettings.tsx (9)
9-9: The
useTranslate
hook is correctly imported from@tolgee/react
to support internationalization.17-17: The
t
function fromuseTranslate
is correctly destructured within the component to be used for translating strings.43-43: The label for the required setting switch is correctly internationalized using the
t
function.48-48: The label for the allow multiple files setting switch is correctly internationalized using the
t
function.56-62: The placeholder label for the code editor is correctly internationalized using the
t
function.69-71: The label for the button text input is correctly internationalized using the
t
function.77-79: The label for the clear button text input is correctly internationalized using the
t
function.85-87: The label for the skip button text input is correctly internationalized using the
t
function.94-98: The label for saving the upload in a variable is correctly internationalized using the
t
function, with consideration for whether multiple files are allowed.apps/builder/src/features/blocks/inputs/date/components/DateInputSettings.tsx (10)
9-9: The
useTranslate
hook is correctly imported from@tolgee/react
to support internationalization.17-17: The
t
function fromuseTranslate
is correctly destructured within the component to be used for translating strings.46-51: The label for the date range switch and the from input label are correctly internationalized using the
t
function.58-60: The to input label is correctly internationalized using the
t
function.66-66: The label for the with time switch is correctly internationalized using the
t
function.71-73: The label for the button text input is correctly internationalized using the
t
function.78-78: The label for the min date input is correctly internationalized using the
t
function.84-84: The label for the max date input is correctly internationalized using the
t
function.90-99: The label for the date format input and its tooltip are correctly internationalized using the
t
function.105-105: The label for saving the answer in a variable is correctly internationalized using the
t
function.apps/builder/src/features/credentials/components/CredentialsDropdown.tsx (6)
18-18: The
useTranslate
hook is correctly imported from@tolgee/react
to support internationalization.40-40: The
t
function fromuseTranslate
is correctly destructured within the component to be used for translating strings.67-67: The default credentials label is correctly internationalized using the
t
function.96-96: The button text for adding new credentials is correctly internationalized using the
t
function.145-145: The aria-label for the delete credentials button is correctly internationalized using the
t
function.161-161: The label for connecting new credentials is correctly internationalized using the
t
function.apps/builder/src/features/blocks/inputs/buttons/components/ButtonsItemNode.tsx (7)
24-24: The
useTranslate
hook is correctly imported from@tolgee/react
to support internationalization.33-33: The
t
function fromuseTranslate
is correctly destructured within the component to be used for translating strings.36-37: The default content for the button item node is correctly set to a translated string using the
t
function.54-55: The escape key behavior to delete the item if the value is the default translated string is correctly implemented.
90-91: The color of the
EditablePreview
is conditionally set based on whether the content is the default translated string, which is a good use of thet
function for internationalization.113-113: The aria-label for the settings button is correctly internationalized using the
t
function.133-133: The aria-label for the add item button is correctly internationalized using the
t
function.apps/builder/src/features/blocks/inputs/rating/components/RatingInputSettings.tsx (10)
9-9: The
useTranslate
hook is correctly imported from@tolgee/react
to support internationalization.17-17: The
t
function fromuseTranslate
is correctly destructured within the component to be used for translating strings.6-21: > Note: This review was outside the patches, and no patch overlapping with it was found. Original lines [46-46]
The label for the rating input range setting is correctly internationalized using the
t
function.
69-69: The label for the rating input type setting is correctly internationalized using the
t
function.89-89: The label for the custom icon switch is correctly internationalized using the
t
function.99-99: The label for the icon SVG input is correctly internationalized using the
t
function.106-111: The labels for the rate input placeholders are correctly internationalized using the
t
function with dynamic values.122-123: The label and more info content for the one-click submit switch are correctly internationalized using the
t
function.129-131: The label for the button text input is correctly internationalized using the
t
function.138-138: The label for saving the answer in a variable is correctly internationalized using the
t
function.apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceSettings.tsx (6)
9-9: The
useTranslate
hook is correctly imported from@tolgee/react
to support internationalization.17-17: The
t
function fromuseTranslate
is correctly destructured within the component to be used for translating strings.69-79: The label for the searchable setting and its corresponding input placeholder are correctly internationalized using the
t
function.85-95: The label for the multiple choice setting and the submit button text input are correctly internationalized using the
t
function.108-114: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [102-129]
The label for the dynamic items setting and the labels for the variables associated with dynamic items are correctly internationalized using the
t
function.
- 140-140: The label for saving the answer in a variable is correctly internationalized using the
t
function.apps/builder/src/features/blocks/inputs/payment/components/StripeConfigModal.tsx (7)
26-26: The
useTranslate
hook is correctly imported from@tolgee/react
to support internationalization.39-39: The
t
function fromuseTranslate
is correctly destructured within the component to be used for translating strings.127-127: The modal header is correctly internationalized using the
t
function.133-143: The labels for the account name input and the test keys section are correctly internationalized using the
t
function.162-162: The label for connecting new credentials is correctly internationalized using the
t
function.184-186: The text indicating where to find the Stripe keys is correctly internationalized using the
t
function.204-204: The button text for connecting the Stripe account is correctly internationalized using the
t
function.apps/builder/src/features/graph/components/nodes/item/ItemNodesList.tsx (3)
25-25: The
useTranslate
hook is correctly imported from@tolgee/react
to support internationalization.196-196: The
t
function fromuseTranslate
is correctly destructured within theDefaultItemNode
component to be used for translating strings.211-215: The static text within the
DefaultItemNode
component is correctly replaced with dynamic translations using thet
function.apps/builder/src/components/inputs/VariableSearchInput.tsx (6)
36-36: The import of
useTranslate
from@tolgee/react
is correctly added to enable translations within the component.82-82: The
useTranslate
hook is correctly used to obtain thet
function for translations. Ensure that the translation keys used witht
are defined in the localization files.142-142: The translation function
t
is correctly used to localize the prompt text in theprompt
function. However, ensure that the translation key"variables.rename"
exists and is properly translated in the localization files.226-226: The
placeholder
property of theInput
component is correctly localized using thet
function. Verify that the translation key"variables.select"
is present in the localization files.260-260: The button text for creating a new variable is correctly localized using the
t
function. Confirm that the translation key"create"
is available and accurately translated in the localization files.301-301: The
aria-label
for the edit icon button is correctly localized using thet
function. Ensure that the translation key"variables.rename"
is defined in the localization files.apps/builder/src/features/blocks/inputs/phone/components/CountryCodeSelect.tsx (3)
2-2: The import of
useTranslate
from@tolgee/react
is correctly added to enable translations within theCountryCodeSelect
component.11-11: The
useTranslate
hook is correctly used to obtain thet
function for translations within theCountryCodeSelect
component.17-19: The
placeholder
property of theSelect
component is correctly localized using thet
function. Verify that the translation key"editor.blocks.inputs.phone.settings.international.placeholder.label"
is present in the localization files and accurately translated.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 0
Configuration used: CodeRabbit UI
Files selected for processing (1)
- apps/builder/src/components/inputs/VariableSearchInput.tsx (6 hunks)
Files skipped from review as they are similar to previous changes (1)
- apps/builder/src/components/inputs/VariableSearchInput.tsx
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 0
Configuration used: CodeRabbit UI
Files ignored due to filter (2)
- apps/builder/public/locales/en.json
- apps/builder/public/locales/pt-BR.json
Files selected for processing (40)
- apps/builder/src/components/DropdownList.tsx (3 hunks)
- apps/builder/src/components/SetVariableLabel.tsx (3 hunks)
- apps/builder/src/components/inputs/VariableSearchInput.tsx (6 hunks)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsBlockNode.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsBlockSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsItemNode.tsx (6 hunks)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsItemSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/date/components/DateInputSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/date/components/DateNodeContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/emailInput/components/EmailInputNodeContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/emailInput/components/EmailInputSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/fileUpload/components/FileInputContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/fileUpload/components/FileInputSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/number/components/NumberInputSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/number/components/NumberNodeContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/payment/components/PaymentAddressSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/payment/components/PaymentInputContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/payment/components/PaymentSettings.tsx (4 hunks)
- apps/builder/src/features/blocks/inputs/payment/components/StripeConfigModal.tsx (6 hunks)
- apps/builder/src/features/blocks/inputs/phone/components/CountryCodeSelect.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/phone/components/PhoneInputSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/phone/components/PhoneNodeContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceItemSettings.tsx (4 hunks)
- apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceNode.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceSettings.tsx (6 hunks)
- apps/builder/src/features/blocks/inputs/rating/components/RatingInputContent.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/rating/components/RatingInputSettings.tsx (4 hunks)
- apps/builder/src/features/blocks/inputs/textInput/components/TextInputNodeContent.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/textInput/components/TextInputSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/url/components/UrlInputSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/url/components/UrlNodeContent.tsx (1 hunks)
- apps/builder/src/features/blocks/logic/condition/components/ComparisonItem.tsx (3 hunks)
- apps/builder/src/features/blocks/logic/condition/components/ConditionContent.tsx (4 hunks)
- apps/builder/src/features/blocks/logic/condition/components/ConditionForm.tsx (2 hunks)
- apps/builder/src/features/credentials/components/CredentialsDropdown.tsx (6 hunks)
- apps/builder/src/features/editor/providers/typebotActions/groups.ts (2 hunks)
- apps/builder/src/features/graph/components/nodes/block/BlockNodeContextMenu.tsx (2 hunks)
- apps/builder/src/features/graph/components/nodes/block/SettingsHoverBar.tsx (2 hunks)
- apps/builder/src/features/graph/components/nodes/group/GroupNodeContextMenu.tsx (2 hunks)
- apps/builder/src/features/graph/components/nodes/item/ItemNodesList.tsx (3 hunks)
Files skipped from review due to trivial changes (2)
- apps/builder/src/features/blocks/inputs/rating/components/RatingInputSettings.tsx
- apps/builder/src/features/graph/components/nodes/block/BlockNodeContextMenu.tsx
Additional comments: 133
apps/builder/src/features/blocks/inputs/date/components/DateNodeContent.tsx (2)
4-4: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.9-19: Ensure that the translation key
'editor.blocks.inputs.date.placeholder.label'
is properly defined in the translation files to avoid missing translation issues.apps/builder/src/features/blocks/inputs/url/components/UrlNodeContent.tsx (2)
5-5: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.11-22: Ensure that the translation key
'editor.blocks.inputs.url.placeholder.label'
is properly defined in the translation files to avoid missing translation issues.apps/builder/src/features/blocks/inputs/emailInput/components/EmailInputNodeContent.tsx (2)
5-5: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.11-23: Ensure that the translation key
'editor.blocks.inputs.email.placeholder.label'
is properly defined in the translation files to avoid missing translation issues.apps/builder/src/features/blocks/inputs/phone/components/PhoneNodeContent.tsx (2)
5-5: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.11-23: Ensure that the translation key
'editor.blocks.inputs.phone.placeholder.label'
is properly defined in the translation files to avoid missing translation issues.apps/builder/src/features/blocks/inputs/number/components/NumberNodeContent.tsx (2)
5-5: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.11-24: Ensure that the translation key
'editor.blocks.inputs.number.placeholder.label'
is properly defined in the translation files to avoid missing translation issues.apps/builder/src/features/blocks/inputs/fileUpload/components/FileInputContent.tsx (2)
3-3: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.10-22: Ensure that the translation keys
'editor.blocks.inputs.file.collectMultiple.label'
and'editor.blocks.inputs.file.collectSingle.label'
are properly defined in the translation files to avoid missing translation issues.apps/builder/src/features/blocks/inputs/payment/components/PaymentInputContent.tsx (2)
2-2: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.9-28: Ensure that the translation keys
'editor.blocks.inputs.payment.placeholder.label'
and'editor.blocks.inputs.payment.collect.label'
are properly defined in the translation files to avoid missing translation issues.apps/builder/src/features/blocks/inputs/textInput/components/TextInputNodeContent.tsx (2)
5-5: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.21-27: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [11-27]
Ensure that the translation key
'editor.blocks.inputs.text.placeholder.label'
is properly defined in the translation files to avoid missing translation issues.apps/builder/src/components/SetVariableLabel.tsx (2)
2-2: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.9-15: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [5-25]
Ensure that the translation key
'variables.set'
is properly defined in the translation files to avoid missing translation issues.apps/builder/src/features/graph/components/nodes/group/GroupNodeContextMenu.tsx (2)
4-4: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.18-27: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [6-27]
Ensure that the translation keys for context menu options like
'duplicate'
and'delete'
are properly defined in the translation files to avoid missing translation issues.apps/builder/src/features/blocks/inputs/rating/components/RatingInputContent.tsx (2)
3-3: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.12-25: Ensure that the translation keys
'editor.blocks.inputs.rating.from.label'
and'editor.blocks.inputs.rating.to.label'
are properly defined in the translation files to avoid missing translation issues.apps/builder/src/features/graph/components/nodes/block/SettingsHoverBar.tsx (2)
12-12: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.48-54: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [19-54]
Ensure that the translation key
'help'
is properly defined in the translation files to avoid missing translation issues.apps/builder/src/features/blocks/inputs/buttons/components/ButtonsBlockNode.tsx (2)
7-7: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.22-36: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [14-33]
Ensure that the translation keys related to button variables and labels are properly defined in the translation files to avoid missing translation issues.
apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceNode.tsx (2)
8-8: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.24-42: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [15-41]
Ensure that the translation keys related to picture choice settings are properly defined in the translation files to avoid missing translation issues.
apps/builder/src/features/blocks/inputs/buttons/components/ButtonsItemSettings.tsx (2)
7-7: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.35-44: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [14-44]
Ensure that the translation keys for button item settings are properly defined in the translation files to avoid missing translation issues.
apps/builder/src/features/blocks/logic/condition/components/ConditionForm.tsx (3)
7-8: The import of
useTranslate
and its initialization withconst { t } = useTranslate()
is correctly implemented to facilitate translations within the component.30-37: The translation function
t
is used to translate thecurrentItem
prop of theDropdownList
component. Ensure that the translation keys follow the project's naming conventions and that the translations exist for theLogicalOperator
values.44-46: The
addLabel
prop of theTableList
component is translated using thet
function. Verify that the translation key'editor.blocks.inputs.button.buttonSettings.addComparisonButton.label'
is correctly defined in the translation files.apps/builder/src/features/blocks/inputs/url/components/UrlInputSettings.tsx (4)
4-4: The import of
useTranslate
from@tolgee/react
is correctly added to enable translations within theUrlInputSettings
component.27-30: The
label
prop for theTextInput
component is translated using thet
function. Verify that the translation key'editor.blocks.inputs.settings.placeholder.label'
is correctly defined in the translation files.35-38: The
defaultValue
for the button label is translated using thet
function. Verify that the translation key'editor.blocks.inputs.settings.buttonText.label'
is correctly defined in the translation files.43-46: The
label
for the retry message is translated using thet
function. Verify that the translation key'editor.blocks.inputs.url.settings.retryMessageText.label'
is correctly defined in the translation files.apps/builder/src/features/blocks/inputs/emailInput/components/EmailInputSettings.tsx (4)
4-4: The import of
useTranslate
from@tolgee/react
is correctly added to enable translations within theEmailInputSettings
component.27-30: The
label
prop for theTextInput
component is translated using thet
function. Verify that the translation key'editor.blocks.inputs.email.placeholder.label'
is correctly defined in the translation files.35-38: The
defaultValue
for the button label is translated using thet
function. Verify that the translation key'editor.blocks.inputs.settings.buttonText.label'
is correctly defined in the translation files.43-46: The
label
for the retry message is translated using thet
function. Verify that the translation key'editor.blocks.inputs.email.settings.retryMessageText.label'
is correctly defined in the translation files.apps/builder/src/features/blocks/inputs/textInput/components/TextInputSettings.tsx (4)
5-5: The import of
useTranslate
from@tolgee/react
is correctly added to enable translations within theTextInputSettings
component.29-29: The
label
for the long text switch is translated using thet
function. Verify that the translation key'editor.blocks.inputs.text.settings.longText.label'
is correctly defined in the translation files.34-37: The
label
prop for theTextInput
component is translated using thet
function. Verify that the translation key'editor.blocks.inputs.text.placeholder.label'
is correctly defined in the translation files.42-45: The
defaultValue
for the button label is translated using thet
function. Verify that the translation key'editor.blocks.inputs.settings.buttonText.label'
is correctly defined in the translation files.apps/builder/src/features/editor/providers/typebotActions/groups.ts (2)
12-12: The import of
tolgee
from '@/lib/tolgee' is correctly added to enable translations within thecreateGroup
function.46-48: The
title
property of a new group is translated using thetolgee.t
function. Verify that the translation key'groups.defaultName'
is correctly defined in the translation files.apps/builder/src/features/blocks/inputs/phone/components/PhoneInputSettings.tsx (5)
7-7: The import of
useTranslate
from@tolgee/react
is correctly added to enable translations within thePhoneInputSettings
component.30-33: The
label
prop for theTextInput
component is translated using thet
function. Verify that the translation key'editor.blocks.inputs.phone.placeholder.label'
is correctly defined in the translation files.38-41: The
defaultValue
for the button label is translated using thet
function. Verify that the translation key'editor.blocks.inputs.settings.buttonText.label'
is correctly defined in the translation files.47-47: The label for the default country select is translated using the
t
function. Verify that the translation key'editor.blocks.inputs.phone.settings.defaultCountry.label'
is correctly defined in the translation files.55-58: The
label
for the retry message is translated using thet
function. Verify that the translation key'editor.blocks.inputs.phone.settings.retryMessageText.label'
is correctly defined in the translation files.apps/builder/src/features/blocks/inputs/number/components/NumberInputSettings.tsx (6)
4-4: The import of
useTranslate
from@tolgee/react
is correctly added to enable translations within theNumberInputSettings
component.35-38: The
label
prop for theTextInput
component is translated using thet
function. Verify that the translation key'editor.blocks.inputs.number.placeholder.label'
is correctly defined in the translation files.43-46: The
defaultValue
for the button label is translated using thet
function. Verify that the translation key'editor.blocks.inputs.settings.buttonText.label'
is correctly defined in the translation files.51-51: The
label
for the min value input is translated using thet
function. Verify that the translation key'editor.blocks.inputs.settings.min.label'
is correctly defined in the translation files.56-56: The
label
for the max value input is translated using thet
function. Verify that the translation key'editor.blocks.inputs.settings.max.label'
is correctly defined in the translation files.61-61: The
label
for the step value input is translated using thet
function. Verify that the translation key'editor.blocks.inputs.number.settings.step.label'
is correctly defined in the translation files.apps/builder/src/components/DropdownList.tsx (2)
19-19: The import of
useTranslate
from@tolgee/react
is correctly added to enable translations within theDropdownList
component.93-96: The items in the dropdown list are translated using the
t
function. Verify that the translation keys follow the project's naming conventions and that the translations exist for the dropdown items.apps/builder/src/features/blocks/inputs/payment/components/PaymentAddressSettings.tsx (8)
12-12: The import of
useTranslate
from@tolgee/react
is correctly added to enable translations within thePaymentAddressSettings
component.62-62: The accordion button label is translated using the
t
function. Verify that the translation key'editor.blocks.inputs.payment.settings.address.label'
is correctly defined in the translation files.67-69: The label for the country input field is translated using the
t
function. Verify that the translation key'editor.blocks.inputs.payment.settings.address.country.label'
is correctly defined in the translation files.74-79: The label for the address line 1 input field is translated using the
t
function with a variable. Verify that the translation key'editor.blocks.inputs.payment.settings.address.line.label'
is correctly defined in the translation files and supports variable substitution.84-89: The label for the address line 2 input field is translated using the
t
function with a variable. Verify that the translation key'editor.blocks.inputs.payment.settings.address.line.label'
is correctly defined in the translation files and supports variable substitution.94-96: The label for the city input field is translated using the
t
function. Verify that the translation key'editor.blocks.inputs.payment.settings.address.city.label'
is correctly defined in the translation files.101-103: The label for the state input field is translated using the
t
function. Verify that the translation key'editor.blocks.inputs.payment.settings.address.state.label'
is correctly defined in the translation files.108-110: The label for the postal code input field is translated using the
t
function. Verify that the translation key'editor.blocks.inputs.payment.settings.address.postalCode.label'
is correctly defined in the translation files.apps/builder/src/features/blocks/logic/condition/components/ComparisonItem.tsx (4)
8-8: Ensure that the
useTranslate
hook is used correctly and follows the library's best practices for internationalization.37-37: Verify that the translation key
'variables.search'
is correctly set up in the translation files and that it corresponds to the intended text in theVariableSearchInput
placeholder.40-50: Ensure that dynamic translation keys based on
comparisonOperator
values are correctly handled and that all possible values have corresponding translations.81-90: Confirm that the translation keys returned by the
parseValuePlaceholder
function are correctly set up in the translation files and that they correspond to the intended placeholder text for eachcomparisonOperator
.apps/builder/src/features/blocks/logic/condition/components/ConditionContent.tsx (3)
2-2: Ensure that the
useTranslate
hook is used correctly and follows the library's best practices for internationalization.29-30: Verify that the translation key
'editor.blocks.inputs.button.conditionContent.if.label'
is correctly set up in the translation files and that it corresponds to the intended text in theText
component.77-99: Confirm that the translation keys returned by the
parseComparisonOperatorSymbol
function are correctly set up in the translation files and that they correspond to the intended symbols for eachcomparisonOperator
.apps/builder/src/features/blocks/inputs/buttons/components/ButtonsBlockSettings.tsx (3)
9-9: Ensure that the
useTranslate
hook is used correctly and follows the library's best practices for internationalization.34-34: Verify that the translation key
'editor.blocks.inputs.settings.multipleChoice.label'
is correctly set up in the translation files and that it corresponds to the intended text for theSwitchWithRelatedSettings
label.68-71: Ensure that the tooltip and label translations within the
MoreInfoTooltip
andFormLabel
components are correctly set up and match the intended text.apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceItemSettings.tsx (2)
18-18: Ensure that the
useTranslate
hook is used correctly and follows the library's best practices for internationalization.68-68: Verify that the translation key
'editor.blocks.inputs.picture.itemSettings.image.label'
is correctly set up in the translation files and that it corresponds to the intended text for theText
component label.apps/builder/src/features/blocks/inputs/fileUpload/components/FileInputSettings.tsx (2)
9-9: Ensure that the
useTranslate
hook is used correctly and follows the library's best practices for internationalization.43-43: Verify that the translation key
'editor.blocks.inputs.file.settings.required.label'
is correctly set up in the translation files and that it corresponds to the intended text for theSwitchWithLabel
component.apps/builder/src/features/blocks/inputs/date/components/DateInputSettings.tsx (2)
9-9: Ensure that the
useTranslate
hook is used correctly and follows the library's best practices for internationalization.46-46: Verify that the translation key
'editor.blocks.inputs.date.settings.isRange.label'
is correctly set up in the translation files and that it corresponds to the intended text for theSwitchWithRelatedSettings
label.apps/builder/src/features/credentials/components/CredentialsDropdown.tsx (3)
18-18: Ensure that the
useTranslate
hook is used correctly and follows the library's best practices for internationalization.67-67: Verify that the default credentials label translation key is correctly set up in the translation files and that it corresponds to the intended default label text.
145-147: Ensure that the
aria-label
translation for the delete button is correctly set up and matches the intended accessibility text.apps/builder/src/features/blocks/inputs/buttons/components/ButtonsItemNode.tsx (6)
24-24: The addition of the
useTranslate
hook from@tolgee/react
is correctly implemented to support internationalization.36-38: The initialization of the
t
function fromuseTranslate
is correct, and its use to set the default state ofitemValue
is appropriate for internationalization.54-63: The logic for handling key presses has been updated to use the translated string. Ensure that the translated string is consistent and correctly represents the intended text in all languages supported by the application.
97-102: The conditional logic for setting the color of the
EditablePreview
component based on the content being equal to a translated label is correct. This ensures that the placeholder text is visually distinct.121-123: The
aria-label
for the "Open settings" button has been correctly updated to use a translated value, improving accessibility for international users.143-143: The
aria-label
for the "Add item" button has been correctly updated to use a translated value, which is important for screen readers and internationalization.apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceSettings.tsx (9)
9-9: The
useTranslate
hook from@tolgee/react
has been correctly imported to enable internationalization for thePictureChoiceSettings
component.17-17: The
t
function fromuseTranslate
is correctly initialized for use in translating labels and default values within the component.69-79: The labels and default values for the
SwitchWithRelatedSettings
andTextInput
components have been correctly replaced with calls to thet
function for internationalization.85-96: The use of the
t
function to translate the label and default button text for the multiple choice setting is correctly implemented.103-106: The label for dynamic items in the
PictureChoiceSettings
component is correctly internationalized using thet
function.112-114: The label for dynamic item images is correctly internationalized using the
t
function.123-125: The label for dynamic item titles is correctly internationalized using the
t
function.134-136: The label for dynamic item descriptions is correctly internationalized using the
t
function.147-147: The label for saving the answer is correctly internationalized using the
t
function.apps/builder/src/features/graph/components/nodes/item/ItemNodesList.tsx (2)
25-25: The
useTranslate
hook from@tolgee/react
has been correctly imported to enable internationalization within theItemNodesList
component.208-216: > Note: This review was outside the patches, so it was mapped to the patch with the greatest overlap. Original lines [196-213]
The
DefaultItemNode
component now correctly uses thet
function to internationalize the displayed text based on the block type, which is a good practice for supporting multiple languages.apps/builder/src/features/blocks/inputs/payment/components/StripeConfigModal.tsx (8)
26-26: The
useTranslate
hook from@tolgee/react
has been correctly imported to support internationalization in theStripeConfigModal
.39-39: The
t
function fromuseTranslate
is correctly initialized for use in translating text content and button labels within the modal.127-129: The modal header text has been correctly replaced with a translated version using the
t
function, which is essential for internationalization.135-137: The label for the account name input field has been correctly internationalized using the
t
function.145-151: The label and info text for test keys have been correctly internationalized using the
t
function.170-174: The label for live keys has been correctly internationalized using the
t
function.196-203: The text and link for finding Stripe keys have been correctly internationalized using the
t
function.221-221: The button text to connect has been correctly internationalized using the
t
function.apps/builder/src/features/blocks/inputs/payment/components/PaymentSettings.tsx (11)
26-26: The
useTranslate
hook from@tolgee/react
has been correctly imported to enable internationalization for thePaymentSettings
component.36-36: The
t
function fromuseTranslate
is correctly initialized for use in translating various text labels and placeholders within the component.109-114: The provider label in the
PaymentSettings
component is correctly internationalized using thet
function.117-130: The account label and credentials name in the
CredentialsDropdown
component are correctly internationalized using thet
function.136-144: The labels for price amount and currency in the
PaymentSettings
component are correctly internationalized using thet
function.159-163: The button label in the
PaymentSettings
component is correctly internationalized using thet
function.167-169: The success message label in the
PaymentSettings
component is correctly internationalized using thet
function.174-186: The accordion label and placeholder for additional information description in the
PaymentSettings
component are correctly internationalized using thet
function.189-191: The label for the name input field in the additional information section of the
PaymentSettings
component is correctly internationalized using thet
function.197-199: The label for the email input field in the additional information section of the
PaymentSettings
component is correctly internationalized using thet
function.205-207: The label for the phone number input field in the additional information section of the
PaymentSettings
component is correctly internationalized using thet
function.apps/builder/src/components/inputs/VariableSearchInput.tsx (7)
36-36: The import of
useTranslate
from@tolgee/react
is correctly added to enable translations within the component.82-82: The
t
function is correctly declared using theuseTranslate
hook for translating strings within the component.142-142: The translation key
'variables.rename'
is used for the prompt in thehandleRenameVariableClick
function. Ensure that this key is correctly defined in the translation files and follows the project's naming conventions.Verification successful
The translation key
'variables.rename'
is correctly defined in the translation files for both English and Portuguese-Brazilian (pt-BR
), as evidenced by the output from the locales directory. It follows the project's naming conventions and is present in the expected location.
* 226-226: The dynamic setting of the `placeholder` property using the translation key `'variables.select'` is a good practice for internationalization. Ensure that this key is correctly defined in the translation files.Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Verify that the translation key exists in the translation files. rg --type json '"variables.rename":' ./localesLength of output: 98
Script:
#!/bin/bash # Attempt to find directories that might contain translation files. fd 'locales' --type dLength of output: 50
Script:
#!/bin/bash # Verify that the translation key exists in the translation files within the correct directory. rg --type json '"variables.rename":' apps/builder/public/locales/Length of output: 228
Verification successful
The translation key
'variables.select'
has been successfully located in both the Portuguese-Brazilian (pt-BR.json
) and English (en.json
) translation files within theapps/builder/public/locales/
directory. This confirms that the key is correctly defined and available for use in theVariableSearchInput.tsx
component.
* 260-260: The translation key `'create'` is used for the create button text. Ensure that this key is correctly defined in the translation files and follows the project's naming conventions.Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Verify that the translation key exists in the translation files. rg --type json '"variables.select":' ./localesLength of output: 98
Script:
#!/bin/bash # Attempt to locate the directory where translation files might be stored. fd 'locales|i18n|translations' --type dLength of output: 70
Script:
#!/bin/bash # Verify that the translation key 'variables.select' exists within the located translation files directory. rg --type json '"variables.select":' apps/builder/public/locales/Length of output: 233
Verification successful
The translation key
'create'
has been found in the JSON translation files located inapps/builder/public/locales/
, with translations provided for at least two languages, including the English version"Create"
and another language which appears to be Portuguese with the translation"Criar"
. This confirms that the key is correctly defined in the translation files and is likely following the project's naming conventions.* 301-301: The `aria-label` for the edit icon is set using the translation key `'variables.rename'`. Ensure that this key is correctly defined in the translation files and is accessible for screen readers.Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Verify that the translation key exists in the translation files. rg --type json '"create":' ./localesLength of output: 88
Script:
#!/bin/bash # Attempt to locate the directory where translation files are stored fd 'locales' --type dLength of output: 50
Script:
#!/bin/bash # If the above command finds a directory, search for the "create" key within JSON files in that directory fd '.json' --type f --exec rg '"create":' {}Length of output: 89
Verification successful
The translation key
"variables.rename"
has been found in the JSON files, with translations provided for at least two languages, including English ("Rename variable") and Portuguese-Brazilian ("Renomeie a variável"). This confirms that the key is correctly defined in the translation files and should be accessible for screen readers.
* 307-307: The `aria-label` for the delete icon is set using the translation key `'variables.remove'`. Ensure that this key is correctly defined in the translation files and is accessible for screen readers.Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Verify that the translation key exists in the translation files. rg --type json '"variables.rename":' ./localesLength of output: 98
Script:
#!/bin/bash # Locate the directory that contains the translation files. fd '.*\.json' --type d --exec rg '"variables.rename":' {}Length of output: 61
Script:
#!/bin/bash # Search for JSON files and then look for the translation key within those files. fd '.*\.json' --type f --exec rg '"variables.rename":' {}Length of output: 147
Verification successful
The translation key
'variables.remove'
is correctly defined in the translation files for both Portuguese-Brazilian (pt-BR.json
) and English (en.json
). This confirms that the key is accessible for screen readers as long as the translation functionality is properly implemented in the application.
- The
aria-label
for the delete icon using the translation key'variables.remove'
is verified to exist in the translation files for both English and Portuguese-Brazilian locales.Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Verify that the translation key exists in the translation files. rg --type json '"variables.remove":' ./localesLength of output: 98
Script:
#!/bin/bash # Search for the translation key 'variables.remove' in all JSON files in the repository. rg --type json '"variables.remove":'Length of output: 197
apps/builder/src/features/blocks/inputs/phone/components/CountryCodeSelect.tsx (3)
2-2: The import of
useTranslate
from@tolgee/react
is correctly added to enable translations within theCountryCodeSelect
component.11-11: The
t
function is correctly declared using theuseTranslate
hook for translating the placeholder within theSelect
component.17-19: The translation key
'editor.blocks.inputs.phone.settings.international.placeholder.label'
is used for theSelect
component's placeholder. Ensure that this key is correctly defined in the translation files and follows the project's naming conventions.Verification successful
The translation key
'editor.blocks.inputs.phone.settings.international.placeholder.label'
is correctly defined in the translation files for both Portuguese-Brazilian (pt-BR.json
) and English (en.json
), which aligns with the PR's objective to implement pt-BR translations.Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Verify that the translation key exists in the translation files. rg --type json '"editor.blocks.inputs.phone.settings.international.placeholder.label":' ./localesLength of output: 149
Script:
#!/bin/bash # Attempt to find the locales directory or equivalent translation files in the repository. fd 'locales' --type dLength of output: 50
Script:
#!/bin/bash # Search for the translation key within the JSON files located in the locales directory. rg '"editor.blocks.inputs.phone.settings.international.placeholder.label":' ./apps/builder/public/locales/Length of output: 367
…feat/input-blocks-pt_BR-translation
I had to remove all the default values as it can't be internationalized for now. Also removed the Dropdown dynamic key parsing (for Condition for example) as it should be done differently. Keys shoud not be built dynamically. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 1
Configuration used: CodeRabbit UI
Files ignored due to filter (2)
- apps/builder/src/i18n/en.json
- apps/builder/src/i18n/pt-BR.json
Files selected for processing (30)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsBlockNode.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsBlockSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsItemNode.tsx (6 hunks)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsItemSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/date/components/DateInputSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/date/components/DateNodeContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/emailInput/components/EmailInputSettings.tsx (4 hunks)
- apps/builder/src/features/blocks/inputs/fileUpload/components/FileInputContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/fileUpload/components/FileInputSettings.tsx (4 hunks)
- apps/builder/src/features/blocks/inputs/number/components/NumberInputSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/payment/components/PaymentAddressSettings.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/payment/components/PaymentInputContent.tsx (1 hunks)
- apps/builder/src/features/blocks/inputs/payment/components/PaymentSettings.tsx (5 hunks)
- apps/builder/src/features/blocks/inputs/payment/components/StripeConfigModal.tsx (6 hunks)
- apps/builder/src/features/blocks/inputs/phone/components/CountryCodeSelect.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/phone/components/PhoneInputSettings.tsx (4 hunks)
- apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceItemSettings.tsx (4 hunks)
- apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceNode.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceSettings.tsx (8 hunks)
- apps/builder/src/features/blocks/inputs/rating/components/RatingInputContent.tsx (2 hunks)
- apps/builder/src/features/blocks/inputs/rating/components/RatingInputSettings.tsx (6 hunks)
- apps/builder/src/features/blocks/inputs/textInput/components/TextInputSettings.tsx (3 hunks)
- apps/builder/src/features/blocks/inputs/url/components/UrlInputSettings.tsx (4 hunks)
- apps/builder/src/features/blocks/inputs/url/components/UrlNodeContent.tsx (1 hunks)
- apps/builder/src/features/blocks/logic/condition/components/ComparisonItem.tsx (2 hunks)
- apps/builder/src/features/blocks/logic/condition/components/ConditionContent.tsx (2 hunks)
- apps/builder/src/features/blocks/logic/condition/components/ConditionForm.tsx (2 hunks)
- apps/builder/src/features/credentials/components/CredentialsDropdown.tsx (6 hunks)
- apps/builder/src/features/editor/providers/typebotActions/groups.ts (2 hunks)
- apps/builder/src/features/graph/components/nodes/item/ItemNodesList.tsx (3 hunks)
Files skipped from review as they are similar to previous changes (28)
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsBlockNode.tsx
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsBlockSettings.tsx
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsItemNode.tsx
- apps/builder/src/features/blocks/inputs/buttons/components/ButtonsItemSettings.tsx
- apps/builder/src/features/blocks/inputs/date/components/DateNodeContent.tsx
- apps/builder/src/features/blocks/inputs/emailInput/components/EmailInputSettings.tsx
- apps/builder/src/features/blocks/inputs/fileUpload/components/FileInputContent.tsx
- apps/builder/src/features/blocks/inputs/fileUpload/components/FileInputSettings.tsx
- apps/builder/src/features/blocks/inputs/number/components/NumberInputSettings.tsx
- apps/builder/src/features/blocks/inputs/payment/components/PaymentAddressSettings.tsx
- apps/builder/src/features/blocks/inputs/payment/components/PaymentInputContent.tsx
- apps/builder/src/features/blocks/inputs/payment/components/PaymentSettings.tsx
- apps/builder/src/features/blocks/inputs/payment/components/StripeConfigModal.tsx
- apps/builder/src/features/blocks/inputs/phone/components/CountryCodeSelect.tsx
- apps/builder/src/features/blocks/inputs/phone/components/PhoneInputSettings.tsx
- apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceItemSettings.tsx
- apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceNode.tsx
- apps/builder/src/features/blocks/inputs/pictureChoice/components/PictureChoiceSettings.tsx
- apps/builder/src/features/blocks/inputs/rating/components/RatingInputContent.tsx
- apps/builder/src/features/blocks/inputs/rating/components/RatingInputSettings.tsx
- apps/builder/src/features/blocks/inputs/textInput/components/TextInputSettings.tsx
- apps/builder/src/features/blocks/inputs/url/components/UrlInputSettings.tsx
- apps/builder/src/features/blocks/inputs/url/components/UrlNodeContent.tsx
- apps/builder/src/features/blocks/logic/condition/components/ComparisonItem.tsx
- apps/builder/src/features/blocks/logic/condition/components/ConditionContent.tsx
- apps/builder/src/features/blocks/logic/condition/components/ConditionForm.tsx
- apps/builder/src/features/credentials/components/CredentialsDropdown.tsx
- apps/builder/src/features/graph/components/nodes/item/ItemNodesList.tsx
Additional comments: 3
apps/builder/src/features/editor/providers/typebotActions/groups.ts (1)
- 31-41: Added an optional parameter
groupLabel
to thecreateGroup
function signature. Ensure that all calls to this function are reviewed to confirm whether the new parameter is being utilized correctly or if the default behavior is expected.apps/builder/src/features/blocks/inputs/date/components/DateInputSettings.tsx (2)
9-9: The
useTranslate
hook from@tolgee/react
is correctly imported and used to initialize thet
function for translations. This is a necessary change for supporting internationalization.46-108: All labels, placeholders, and tooltips within the
DateInputSettings
component have been updated to use thet
function for translations. This aligns with the PR's objective to implement pt-BR translations for input blocks. Ensure that the translation keys used here are correctly defined in the localization files.Verification successful
The script output confirms that all the translation keys used in the
DateInputSettings
component are present in both the English and Portuguese-Brazilian (pt-BR) localization files. This includes keys for labels, placeholders, tooltips, and other UI elements that were updated to support internationalization.Based on the provided script results, the following keys are verified to be correctly defined:
blocks.inputs.date.settings.toInputValue.label
blocks.inputs.date.settings.withTime.label
blocks.inputs.settings.button.label
blocks.inputs.settings.min.label
blocks.inputs.settings.max.label
blocks.inputs.date.settings.format.label
blocks.inputs.date.settings.format.example.label
blocks.inputs.settings.saveAnswer.label
Given this information, the changes in the
DateInputSettings
component align with the PR's objective to implement pt-BR translations for input blocks, and the translation keys are correctly defined in the localization files.Scripts Executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Verify that the translation keys are present in the localization files. rg 'blocks.inputs.date.settings.isRange.label' --type json rg 'blocks.inputs.date.settings.from.label' --type json rg 'blocks.inputs.date.settings.to.label' --type json # ... and so on for all the keys used in this component.Length of output: 709
Script:
#!/bin/bash # Continue verifying the presence of the remaining translation keys in the localization files. rg 'blocks.inputs.date.settings.toInputValue.label' --type json rg 'blocks.inputs.date.settings.withTime.label' --type json rg 'blocks.inputs.settings.button.label' --type json rg 'blocks.inputs.settings.min.label' --type json rg 'blocks.inputs.settings.max.label' --type json rg 'blocks.inputs.date.settings.format.label' --type json rg 'blocks.inputs.date.settings.format.example.label' --type json rg 'blocks.inputs.settings.saveAnswer.label' --type jsonLength of output: 1907
@@ -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}`, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The logic to default the title
to 'Group' if groupLabel
is not provided is sound. However, consider externalizing 'Group' to a constant or a localization file if it's user-facing text to support future internationalization.
- title: `${groupLabel ?? 'Group'} #${typebot.groups.length + 1}`,
+ const DEFAULT_GROUP_LABEL = 'Group'; // This should be externalized if it's user-facing
+ title: `${groupLabel ?? DEFAULT_GROUP_LABEL} #${typebot.groups.length + 1}`,
Committable suggestion
❗ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation.
title: `${groupLabel ?? 'Group'} #${typebot.groups.length + 1}`, | |
const DEFAULT_GROUP_LABEL = 'Group'; // This should be externalized if it's user-facing | |
title: `${groupLabel ?? DEFAULT_GROUP_LABEL} #${typebot.groups.length + 1}`, |
<!-- 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 <[email protected]>
Summary by CodeRabbit
New Features
useTranslate
hook for dynamic translations.Enhancements
User Interface