[chip] Add "selected" prop

Open
#10,610 11 comments 4 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
javascript, react
Domain
frontend

Research direction

Start by locating the Material-UI Chip component and reviewing how its current click behavior produces a visually active state. Resolve whether the prop should be named "selected" or "active", then add the prop behavior and tests showing both active and inactive visual states.

Written by the indexing model from the issue text.

Description

design: material scope: chip type: new feature
  • I have searched the issues of this repository and believe that this is not a duplicate.

Expected Behavior

Chip should have an active prop to set the Chip to be visually active or not.

Current Behavior

Currently, the only way to make a Chip active is to click on it with onClick set.

Steps to Reproduce (for bugs)

Context

Your Environment

Tech Version
Material-UI beta.36
React 16.2.0
browser
etc
Dominant language
JavaScript
Stars
99.1k
Forks
32.5k
Avg merge
2d 17h
Merged PRs (30d)
106

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from mui/material-ui

All issues in mui/material-ui

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.