Changed from Record<string, unknown> to Record<string, (...args: any[]) => any>
so TypeScript understands the action properties are callable functions.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
The previous BoundActions<CombinedExploreActions> type failed because
action modules export both action creators AND action type constants
(e.g., UPDATE_FORM_DATA_BY_DATASOURCE = 'UPDATE_FORM_DATA_BY_DATASOURCE').
Simplified to Record<string, unknown> which properly represents the
mixed nature of these exports while maintaining type safety elsewhere.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Create CombinedExploreActions type for combined action creators
- Add BoundActions<T> utility type for bound action creators
- Update ControlPanelsContainer to use Pick<ExploreActions, 'setControlValue'>
- Change datasource_type from string to DatasourceType enum
- Change exploreState to use ExplorePageState['explore']
- Replace control.label() as any with as unknown as ControlPanelState
- Add eslint-disable comments for remaining necessary casts
- Remove unnecessary as any casts from connect() and SaveModal
Reduces 'as any' casts from ~12 to 5, with remaining casts
documented with eslint-disable comments explaining why they're needed.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- ChartRenderer.test.tsx: Remove viz_type from formData to allow vizType
prop to take precedence for suppressContextMenu test, use as unknown
for test data type assertions
- ExploreChartHeader.test.tsx: Fix placeholder text assertion - use
findByDisplayValue instead of findByText since chart has a title
- ExploreViewContainer: Pass exploreState prop to ExploreChartPanel
to match original behavior of spread props
- ExploreChartPanel: Add exploreState to props interface
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Fix ExploreViewContainer type assertions for props passing
- Fix ExploreChartHeader.test.tsx with proper type imports
- Fix logger.test.ts with correct middleware typing
- Fix exploreReducer.ts with proper control state and function parameter types
- Fix test files (getChartDataUri, getChartKey, getExploreUrl, getSimpleSQLExpression)
- Fix HeaderReportDropdown and ReportModal type issues
- Fix useExploreAdditionalActionsMenu menu item literal types
- Update ExploreState interface to match expected types
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Fix ExploreChartHeader.test.tsx: add missing ChartState properties to test props
- Fix ResultSet/index.tsx: use 'base' for mountExploreUrl, map columns to names
- Fix CopyToClipboardButton.test.tsx: pass data as array instead of object
- Fix ExploreChartPanel/index.tsx: use undefined instead of null, add form_data check,
wrap setControlValue to adapt signature
- Fix ExploreViewContainer/index.tsx: remove unused KeyboardEvent import, fix history
state types, cast form_data for isMatrixifyEnabled
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>