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

Custom checkbox column throws warning #6067

Closed
2 tasks done
calteran opened this issue Sep 7, 2022 · 1 comment
Closed
2 tasks done

Custom checkbox column throws warning #6067

calteran opened this issue Sep 7, 2022 · 1 comment
Labels
duplicate This issue or pull request already exists

Comments

@calteran
Copy link

calteran commented Sep 7, 2022

Duplicates

  • I have searched the existing issues

Latest version

  • I have tested the latest version

Current behavior 😯

When using a custom checkbox column like

{
      ...GRID_CHECKBOX_SELECTION_COL_DEF,
      headerName: 'Checkbox',
},

the browser throws a warning:

image

Expected behavior 🤔

There should not be a warning.

Steps to reproduce 🕹

Link to live example (issue seen in actual example from the MUI-X docs): https://codesandbox.io/s/tu72cu?file=/demo.js

Steps:

  1. Follow the documentation on custom checkbox columns
  2. Load in browser
  3. See warning

Context 🔦

In my particular case, I'm configuring the checkboxSelection column to have a custom header name because the header appears in the enable/disable Columns menu in the toolbar and I want it to have a more user-friendly name.

But since the warning shows up the the vanilla example, any use-case or context will likely experience this issue.

Your environment 🌎

npx @mui/envinfo
  System:
    OS: macOS 12.5.1
  Binaries:
    Node: 17.8.0 - ~/.nvm/versions/node/v17.8.0/bin/node
    Yarn: 1.22.15 - ~/.nvm/versions/node/v17.8.0/bin/yarn
    npm: 8.12.2 - ~/.nvm/versions/node/v17.8.0/bin/npm
  Browsers:
    Chrome: 104.0.5112.101
    Edge: Not Found
    Firefox: 104.0.1 <- tested here
    Safari: 15.6.1
  npmPackages:
    @emotion/react: ^11.10.4 => 11.10.4 
    @emotion/styled: ^11.10.4 => 11.10.4 
    @mui/base:  5.0.0-alpha.95 
    @mui/core-downloads-tracker:  5.10.3 
    @mui/icons-material: ^5.10.3 => 5.10.3 
    @mui/lab: ^5.0.0-alpha.97 => 5.0.0-alpha.97 
    @mui/material: ^5.10.3 => 5.10.3 
    @mui/private-theming:  5.10.3 
    @mui/styled-engine:  5.10.3 
    @mui/system:  5.10.3 
    @mui/types:  7.2.0 
    @mui/utils:  5.10.3 
    @mui/x-data-grid:  5.17.1 
    @mui/x-data-grid-pro: ^5.17.0 => 5.17.1 
    @mui/x-license-pro:  5.17.0 
    @types/react:  18.0.14 
    react: ^18.1.0 => 18.2.0 
    react-dom: ^18.0.0 => 18.2.0 
    typescript:  4.7.4

Order ID 💳 (optional)

No response

@calteran calteran added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Sep 7, 2022
@m4theushw
Copy link
Member

Duplicate of #4769

As a workaround you can try #4769 (comment)

@m4theushw m4theushw closed this as not planned Won't fix, can't repro, duplicate, stale Sep 9, 2022
@m4theushw m4theushw removed the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Sep 9, 2022
@github-actions github-actions bot added the duplicate This issue or pull request already exists label Sep 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

2 participants