Watch whether the 24px grab band around strokes gets in the way of placing annotations
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 35/100
- Tipo di issue
- Bug
- Chiarezza
- Da chiarire
- Stato di attività
- Attiva
- Stack tecnologico
- typescript
- Ambito
- frontend
Direzione di ricerca
Leggi MIN_HIT_AREA in lib/editor/render.ts:248 e DRAG_THRESHOLD in lib/editor/tools.ts:58, quindi esamina il relativo flusso di interazione. Esegui l’e2e in annotations.spec.ts, in particolare "a thin line can be selected without hitting it exactly", e verifica se il posizionamento di una didascalia o di uno sticker vicino a un tratto viene intercettato. Il lavoro è completato quando sia il comportamento di selezione previsto sia il posizionamento delle annotazioni create con un clic sono coperti dai test.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
MIN_HIT_AREA in lib/editor/render.ts:248 gives every stroked annotation an invisible 24px grab band, so a one pixel line can be selected without hitting that one pixel. It came from #50, where the complaint was the opposite one: selecting a thin line meant zooming in until it was wide enough to click.
Since #53 a click on an existing annotation selects it whatever tool is held, so that band now decides two things rather than one. Placing a caption or a sticker within 24 screen pixels of an existing stroke selects the stroke instead of placing anything. The gesture still draws, because a drag over an annotation draws (DRAG_THRESHOLD, lib/editor/tools.ts:58), but click-created annotations have no drag to fall back on.
Nobody has reported it. This is a note to watch for it, with the numbers written down while they are fresh:
- 24px is the grab band, in screen pixels at any zoom (
hitAreaWidth()divides by the view scale) - 4px is what separates a click from a drag
- the band applies to strokes only, so an unfilled rectangle is still selected by its outline rather than by the space it encloses
If it does bite, the first thing to try is a smaller band, 12 to 16px, which still beats the one or two pixels a hairline had before #50. The e2e in annotations.spec.ts ("a thin line can be selected without hitting it exactly") clicks 8px off the line, so it would have to move with the constant, and that is the test to watch when changing it.
- Lingua principale
- TypeScript
- Stelle
- 2
- Fork
- 0
- Merge medio
- 1h 15m
- PR unite (30g)
- 31
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di nextcloud-libraries/nextcloud-image-editor
-
Allow saving only as a copyApertatype: enhancement
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
nextcloud-libraries/nextcloud-image-editor#76 ·
I maintainer di solito rispondono entro 1 giorno
-
type: enhancement
Difficoltà 4/5 3-5 giorni Idoneità per principianti 42/100
nextcloud-libraries/nextcloud-image-editor#77 ·
I maintainer di solito rispondono entro 1 giorno
-
AI assisted type: enhancement
Difficoltà 4/5 3-5 giorni Idoneità per principianti 55/100
nextcloud-libraries/nextcloud-image-editor#19 ·
I maintainer di solito rispondono entro 1 giorno
-
AI assisted type: enhancement
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
nextcloud-libraries/nextcloud-image-editor#17 ·
I maintainer di solito rispondono entro 1 giorno
-
status: confirmed type: enhancement
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
nextcloud-libraries/nextcloud-image-editor#2 ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di nextcloud-libraries/nextcloud-image-editor
Issue simili
-
priority:high
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
immich-app/immich#32426 ·
I maintainer di solito rispondono entro 1 giorno
-
documentation good first issue hacktoberfest help wanted
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
libredb/libredb-studio#1756 ·
I maintainer di solito rispondono entro 1 giorno
-
state:triage-needed
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
I maintainer di solito rispondono entro 1 giorno