aminghadersohi commented on code in PR #45173:
URL: https://github.com/apache/superset/pull/45173#discussion_r4254514214
##########
superset-frontend/src/features/semanticLayers/jsonFormsHelpers.tsx:
##########
@@ -248,7 +313,7 @@ export function DynamicFieldControl(props: ControlProps) {
}
if (!refreshing) {
- return TextControl(props);
+ return <SchemaTextControl {...props} />;
Review Comment:
Typing into a dynamic text field that another dynamic field depends on sets
`refreshing` on the first keystroke; adding the spinner suffix remounts the
antd input, so focus drops to `<body>` and only the first character lands.
Keeping a suffix mounted avoids the remount:
```suggestion
// Keep a suffix mounted: toggling the spinner would remount the input
and drop focus.
const options = {
...props.uischema.options,
inputProps: { suffix: <span /> },
};
return (
<SchemaTextControl {...props} uischema={{ ...props.uischema, options
}} />
);
```
--
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]