Change the appearance of a comment #244
-
Hello Danirus! I have a question: I would like to slightly change the look of the comment, for example like this: Name Where can I change the html to change the comment template? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 14 replies
-
Hi @ogurec-ogurec , for the current version the answer depends on how you use the app. If you use the render_xtdcomment_tree tag the template to rewrite is And finally, when you don't use nested comments nor the ReactJS plugin, but the template tag Based on the image you post I can see you use nested comments, so it's either |
Beta Was this translation helpful? Give feedback.
-
Can you please tell me how you can check that this is a child comment, and for example set the avatar class - "avatar-children". In other words, separate the rendering of the child comment and the normal comment? @danirus |
Beta Was this translation helpful? Give feedback.
Hi @ogurec-ogurec , for the current version the answer depends on how you use the app. If you use the render_xtdcomment_tree tag the template to rewrite is
django_comments_xtd/comment_tree.html
. But if you use the ReactJS plugin, the code that renders the comment is in thecomment.jsx
file, instatic/django_comments_xtd/js/src/
.And finally, when you don't use nested comments nor the ReactJS plugin, but the template tag
render_comment_list
, from the parent app django-comments. In this case the template used iscomments/list.html
.Based on the image you post I can see you use nested comments, so it's either
comment_tree.html
or thecomment.jsx
file.