Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

content: sheet modal docs should explain how to keep interactive content from dragging the sheet

Aperta Adatta ai principianti
#4,765 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
88/100
Tipo di issue
Documentazione
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
markdown
Ambito
documentation

Direzione di ricerca

Inizia con la sezione Sheet Modal in docs/api/modal.mdx e con la sezione corrispondente in versioned_docs/version-v8/api/modal.mdx. Aggiungi la sottosezione proposta Interactive content, inclusi i listener touchstart e mousedown e le note su pointerdown e sugli approcci CSS. Il lavoro è completato quando entrambe le versioni della documentazione spiegano come impedire al contenuto interattivo di trascinare lo sheet.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

content
URL

https://ionicframework.com/docs/api/modal#sheet-modal

Issue Description

Any drag on a sheet modal's content also moves the sheet between breakpoints. This breaks content that needs its own drag, such as image resizers, drawing or signature pads, and other vertical-swipe widgets. It came up in ionic-team/ionic-framework#30064 and earlier in ionic-team/ionic-framework#24715.

The current API already supports this, but the docs don't mention it. The sheet gesture starts from touchstart and mousedown, so stopping those two events from bubbling out of an element keeps the sheet still while that element is dragged:

const stopSheetDrag = (ev) => ev.stopPropagation();
el.addEventListener('touchstart', stopSheetDrag);
el.addEventListener('mousedown', stopSheetDrag);

Stopping pointerdown does not work, and neither do CSS approaches such as touch-action: none. Both are the first things people try. Applying the same listeners to ion-content makes the sheet draggable only from the handle and header.

Suggested addition: a short "Interactive content" subsection under Sheet Modal with the snippet above and those two notes, in docs/api/modal.mdx and versioned_docs/version-v8/api/modal.mdx.

Lingua principale
MDX
Stelle
621
Fork
3.2k
Merge medio
1g 6h
PR unite (30g)
65

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di ionic-team/ionic-docs

Tutte le issue di ionic-team/ionic-docs

Issue simili

Altre issue su Documentation

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.