bito-code-review[bot] commented on code in PR #39535:
URL: https://github.com/apache/superset/pull/39535#discussion_r3223490547
##########
superset-frontend/packages/superset-ui-core/src/components/TimezoneSelector/index.tsx:
##########
@@ -26,6 +26,7 @@ import {
getOffsetKey,
DEFAULT_TIMEZONE,
} from './TimezoneOptionsCache';
+import type { LabeledValue } from 'antd/es/select';
Review Comment:
<div>
<div id="suggestion">
<div id="issue"><b>Direct antd import violation</b></div>
<div id="fix">
Direct import of LabeledValue from 'antd/es/select' violates repository
standards that prohibit direct Ant Design imports. Use the re-exported type
from @superset-ui/core/components to maintain consistency.
</div>
<details>
<summary>
<b>Code suggestion</b>
</summary>
<blockquote>Check the AI-generated fix before applying</blockquote>
<div id="code">
```
- import { Select } from '@superset-ui/core/components';
- import {
- timezoneOptionsCache,
- getOffsetKey,
- DEFAULT_TIMEZONE,
- } from './TimezoneOptionsCache';
- import type { LabeledValue } from 'antd/es/select';
- import type { TimezoneOption } from './types';
+ import { Select, type LabeledValue } from '@superset-ui/core/components';
+ import {
+ timezoneOptionsCache,
+ getOffsetKey,
+ DEFAULT_TIMEZONE,
+ } from './TimezoneOptionsCache';
+ import type { TimezoneOption } from './types';
```
</div>
</details>
</div>
<details>
<summary><b>Citations</b></summary>
<ul>
<li>
Rule Violated: <a
href="https://github.com/apache/superset/blob/c733d58/.cursor/rules/dev-standard.mdc#L19">dev-standard.mdc:19</a>
</li>
<li>
Rule Violated: <a
href="https://github.com/apache/superset/blob/c733d58/AGENTS.md#L33">AGENTS.md:33</a>
</li>
</ul>
</details>
<small><i>Code Review Run #e35dab</i></small>
</div>
---
Should Bito avoid suggestions like this for future reviews? (<a
href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
- [ ] Yes, avoid them
--
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]