Selection.modify() taking optional strings doesn't make sense to me
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 25/100
Línea de trabajo
Start with the Selection.modify() definition in the linked Selection API specification and compare the optional-argument behavior described there with the WebKit, Blink, and Gecko behavior noted in the issue. Determine whether the specification should require arguments or clarify the silent-abort behavior; the work is done when the issue's proposed resolution is reflected in the specification.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
https://w3c.github.io/selection-api/#dom-selection-modify says:
undefined modify(optional DOMString alter, optional DOMString direction, optional DOMString granularity);
However it also says:
If alter is not ASCII case-insensitive match with "extend" or "move", abort these steps.
If direction is not ASCII case-insensitive match with "forward", "backward", "left", or "right", abort these steps.
If granularity is not ASCII case-insensitive match with "character", "word", "sentence", "line", "paragraph", "lineboundary", "sentenceboundary", "paragraphboundary", "documentboundary", abort these steps.
So, basically, it early returns without errors if any of the arguments don't match. That doesn't make a lot of sense to me.
That seems to match WebKit and Blink's implementation. Gecko however throws a reasonable error and makes the strings mandatory.
I think the Gecko behavior is preferable, but if we're going with the "silent error" behavior of WebKit / Blink, maybe we should clarify it as a compatibility quirk (since it's really odd).
cc @rniwa @smaug---- @foolip
- Lenguaje dominante
- HTML
- Estrellas
- 49
- Forks
- 30
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de w3c/selection-api
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
w3c/selection-api#354 ·
-
Agenda+
Dificultad 3/5 1-2 días Aptitud para principiantes 48/100
w3c/selection-api#361 · 2 comentarios ·
-
Remove single range restriction for selection interface apisQuizá libre de nuevo @sambandaru la tomó hace 138 días y no hay ningún pull request abierto. Abierto
w3c/selection-api#358 · 2 comentarios · 1 asignado ·
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
w3c/selection-api#355 ·
-
the steps of Selection.extend() does not check whether the given offset is valid in the containerAbierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 55/100
w3c/selection-api#353 · 1 comentario ·
Todos los issues de w3c/selection-api
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
openfoodfacts/score-my-recipe#80 ·
Los mantenedores suelen responder en 2 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
snapshot-labs/stamp#702 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 86/100
-
Cainophile EXIT handler crashes on its own password redaction and logs the DB password in clear textAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 2 días
-
Dev worker sometimes never starts: `runScript`'s `withUtf8` waits on the stdin GHCi is readingAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
digitallyinduced/ihp#2832 ·
Los mantenedores suelen responder en 1 día