Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[charts] undefined type zoom #15386

Closed
tanjiarui opened this issue Nov 12, 2024 · 4 comments
Closed

[charts] undefined type zoom #15386

tanjiarui opened this issue Nov 12, 2024 · 4 comments
Labels
bug 🐛 Something doesn't work component: charts This is the name of the generic UI component, not the React module! typescript

Comments

@tanjiarui
Copy link

tanjiarui commented Nov 12, 2024

Steps to reproduce

Link to live example: (required)
https://codesandbox.io/embed/86q369?module=/src/Demo.tsx&fontsize=12

Current behavior

in fact, the zoom feature is working well, but a type error is always there. is there a way to eliminate this error?
error

Expected behavior

No response

Context

No response

Your environment

npx @mui/envinfo
  System:
    OS: Linux 6.8 Ubuntu 22.04.5 LTS 22.04.5 LTS (Jammy Jellyfish)
  Binaries:
    Node: 20.11.1 - /usr/local/bin/node
    npm: 10.9.0 - /usr/local/bin/npm
    pnpm: Not Found
  Browsers:
    Chrome: edge
  npmPackages:
    @emotion/react: ^11.13.3 => 11.13.3 
    @emotion/styled: ^11.13.0 => 11.13.0 
    @mui/core-downloads-tracker:  6.1.6 
    @mui/icons-material: ^6.1.1 => 6.1.1 
    @mui/material: ^6.1.6 => 6.1.6 
    @mui/private-theming:  6.1.6 
    @mui/styled-engine:  6.1.6 
    @mui/system:  6.1.6 
    @mui/types:  7.2.19 
    @mui/utils:  6.1.6 
    @mui/x-charts:  7.22.2 
    @mui/x-charts-pro: ^7.0.0-beta.6 => 7.0.0-beta.7 
    @mui/x-charts-vendor:  7.20.0 
    @mui/x-data-grid:  7.18.0 
    @mui/x-data-grid-premium: ^7.18.0 => 7.18.0 
    @mui/x-data-grid-pro:  7.18.0 
    @mui/x-date-pickers:  7.22.1 
    @mui/x-date-pickers-pro: ^7.22.1 => 7.22.1 
    @mui/x-internals:  7.18.0 
    @mui/x-license:  7.18.0 
    @types/react: ^18.3.3 => 18.3.10 
    react: ^18.3.1 => 18.3.1 
    react-dom: ^18.3.1 => 18.3.1 
    typescript: ^5.5.3 => 5.6.2 
node ts config
{
  "compilerOptions": {
	"target": "ES2022",
	"lib": [
	  "ES2023"
	],
	"module": "ESNext",
	"skipLibCheck": true,
	/* Bundler mode */
	"moduleResolution": "bundler",
	"allowImportingTsExtensions": true,
	"isolatedModules": true,
	"moduleDetection": "force",
	"noEmit": true,
	/* Linting */
	"strict": true,
	"noUnusedLocals": true,
	"noUnusedParameters": true,
	"noFallthroughCasesInSwitch": true
  },
  "include": [
	"vite.config.ts"
  ]
}

app ts config

{
  "compilerOptions": {
	"target": "ES2020",
	"useDefineForClassFields": true,
	"lib": [
	  "ES2020",
	  "DOM",
	  "DOM.Iterable"
	],
	"module": "ESNext",
	"skipLibCheck": true,
	/* Bundler mode */
	"moduleResolution": "bundler",
	"allowImportingTsExtensions": true,
	"isolatedModules": true,
	"moduleDetection": "force",
	"noEmit": true,
	"jsx": "react-jsx",
	/* Linting */
	"strict": true,
	"noUnusedLocals": true,
	"noUnusedParameters": true,
	"noFallthroughCasesInSwitch": true
  },
  "include": [
	"src"
  ]
}

Search keywords: zoom

@tanjiarui tanjiarui added bug 🐛 Something doesn't work status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Nov 12, 2024
@github-actions github-actions bot added the component: charts This is the name of the generic UI component, not the React module! label Nov 12, 2024
@alexfauquette
Copy link
Member

Yes, that's because we forgot a type overload import. You can already fix it with

import {} from "@mui/x-charts-pro/typeOverloads";

@michelengelen michelengelen added typescript and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Nov 13, 2024
@michelengelen
Copy link
Member

@alexfauquette is there a PR that fixed this we can link here? I see that the error does not show with intellisense anymore

@alexfauquette
Copy link
Member

Fixed by #15400

Copy link

This issue has been closed. If you have a similar problem but not exactly the same, please open a new issue.
Now, if you have additional information related to this issue or things that could help future readers, feel free to leave a comment.

Note

@tanjiarui How did we do? Your experience with our support team matters to us. If you have a moment, please share your thoughts in this short Support Satisfaction survey.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something doesn't work component: charts This is the name of the generic UI component, not the React module! typescript
Projects
None yet
Development

No branches or pull requests

3 participants