Added extra 'task_list' option, the html does not preform like github.
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 48/100
Línea de trabajo
Comienza en markdown2.py alrededor de la línea 1689 e inspecciona la generación de HTML de task_list y las pruebas o ejemplos cercanos. Compara el marcado de la lista de tareas generado con el comportamiento de GitHub; se considera completado cuando los elementos sin marcar y marcados se renderizan sin el marcador de lista no deseado, conservando su texto y el estado de su casilla de verificación.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
I add 'task_list' option, and the html performed like this:
-
- task list item
but the github task list item performed like this:
- task list item
- task list item
never mind that I used the wrong markdown syntax to show the result, for I can not insert the image.
I found the html converted by markdown2 is like blow:
<li><p><input type="checkbox" class="task-list-item-checkbox" %sdisabled>%s</p></li>
and it will be format with the "checked" status and the real text after "- [ ]" or "- [x]", but the above html code can not performed like github, because the task list items at github do not have the list leader, while the list items of above html will have.
I want to make it perform like github, but the generate rule does not leave me any space to make me write the class selector to modify the performance of the items of task list. So I think why not change the generate style to make it performed like github like below:
return "<li class='task-list-item'>%s</li>\n" % item
//line 1689 at markdown2.py
So I can write class selector to make it perform like github.
.markdown-body .task-list-item {
list-style-type: none;
}
or change like blow:
return "<li style='list-style-type: none;'>%s</li>\n" % item
No need to write CSS handly.
- Lenguaje dominante
- Python
- Estrellas
- 2.8k
- Forks
- 459
- Merge medio
- 2 d 19 h
- PR fusionados (30 d)
- 4
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
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 trentm/python-markdown2
-
Add py.typed marker Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
trentm/python-markdown2#696 ·
-
More XSS's in safe mode Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 48/100
trentm/python-markdown2#726 ·
-
Bug
Dificultad 4/5 3-5 días Aptitud para principiantes 55/100
trentm/python-markdown2#707 ·
-
Bug
Dificultad 3/5 1-2 días Aptitud para principiantes 58/100
trentm/python-markdown2#688 · 4 comentarios ·
-
Bug
Dificultad 3/5 1-2 días Aptitud para principiantes 58/100
trentm/python-markdown2#679 · 2 comentarios ·
Todos los issues de trentm/python-markdown2
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
gradio-app/gradio#13895 ·
-
build-error
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
spack/spack-packages#6713 ·
-
Use issue templates Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
ActivityWatch/activitywatch#1464 · 1 reacción ·
-
[Bug]: The ckg tool drops the return type of every decorated Python method in class search results Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
bytedance/trae-agent#483 ·