YuriyKrasilnikov commented on code in PR #37790:
URL: https://github.com/apache/superset/pull/37790#discussion_r2779220889
##########
superset-frontend/src/dashboard/components/PropertiesModal/sections/BasicInfoSection.tsx:
##########
@@ -58,8 +82,21 @@ const BasicInfoSection = ({
placeholder={t('The display name of your dashboard')}
data-test="dashboard-title-input"
type="text"
+ suffix={!isEditingTranslation ? localeSwitcher : undefined}
/>
</FormItem>
+ {isEditingTranslation && (
+ <Input
+ value={translationValue}
Review Comment:
Not an issue. The translation Input (line 88) only renders when
`isEditingTranslation === true`, which requires `activeLocale !==
DEFAULT_LOCALE_KEY`. In that code path, `translationValue` is computed as:
```tsx
translations.dashboard_title?.[titleActiveLocale] ?? ''
```
The `?? ''` fallback guarantees a string value — never `undefined`. The
Input never transitions from uncontrolled to controlled because it is not
rendered when `translationValue` would be `undefined`.
Same pattern is used consistently across all three integration points
(Dashboard PropertiesModal, Chart PropertiesModal, FiltersConfigForm).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]