ionic-team / ionic-team/ionic-framework

bug: ion-checkbox is toggled by ion-item click

Ouverte
#20,521 3 commentaires 3 réactions 0 personnes assignées Voir sur GitHub
package: core type: bug
Langage dominant
TypeScript
Étoiles
52.7k
Forks
13.3k
Merge moyen
1 j 15 h
PR mergées (30 j)
51

Description

# Bug Report

**Ionic version:**

[x] **4.x**

**Current behavior:**

If you have the following markup, any click or tap on the ion-item will toggle the ion-checkbox:

```


Testing!


```

**Expected behavior:**

The ion-checkbox should only toggle when it is clicked, or the click event from the ion-item should be cancellable.

**Steps to reproduce:**

**Related code:**

[Codepen](https://codepen.io/bsbechtel/pen/YzXWKOW?editors=1100)

**Other information:**

This issue has been brought up multiple times and not fixed: [19590](https://github.com/ionic-team/ionic/issues/19590) [15850](https://github.com/ionic-team/ionic/issues/15850) [17832](https://github.com/ionic-team/ionic/issues/17832)

**Ionic info:**

```
insert the output from ionic info here
```

Guide de contribution

Ouvrir le guide de contribution

Piste de recherche

Start with the CodePen reproduction and inspect the interaction between ion-item and ion-checkbox using the markup in the report. Trace how clicks propagate between these components and check existing related issues 19590, 15850, and 17832. Done means clicking the item no longer toggles the checkbox, or the item click can be cancelled.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
typescript
Domaine
frontend, web-dev
Type d'issue
Bug
Difficulté
3/5
Temps estimé
1-2 jours
Activité
À l'abandon
Clarté
Plutôt claire
Accessibilité débutants
35/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.