chore(frontend): comprehensive TypeScript quality improvements (#37625)

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Evan Rusackas
2026-02-06 16:16:57 -05:00
committed by GitHub
parent e9ae212c1c
commit fc5506e466
441 changed files with 14136 additions and 9956 deletions

View File

@@ -17,7 +17,6 @@
* under the License.
*/
import { Component } from 'react';
import PropTypes from 'prop-types';
import { t } from '@apache-superset/core';
import { Collapse, Label } from '@superset-ui/core/components';
import TextControl from 'src/explore/components/controls/TextControl';
@@ -65,17 +64,6 @@ interface FixedOrMetricControlState {
metricValue: MetricValue | null;
}
const propTypes = {
onChange: PropTypes.func,
value: PropTypes.object,
isFloat: PropTypes.bool,
datasource: PropTypes.object.isRequired,
default: PropTypes.shape({
type: PropTypes.oneOf(['fix', 'metric']),
value: PropTypes.oneOfType([PropTypes.string, PropTypes.number]),
}),
};
const defaultProps = {
onChange: () => {},
default: { type: controlTypes.fixed, value: 5 },
@@ -216,7 +204,5 @@ export default class FixedOrMetricControl extends Component<
}
}
// @ts-expect-error - propTypes are defined for runtime validation but TypeScript handles type checking
FixedOrMetricControl.propTypes = propTypes;
// @ts-expect-error - defaultProps for backward compatibility with PropTypes
// @ts-expect-error - defaultProps for backward compatibility
FixedOrMetricControl.defaultProps = defaultProps;