#32324: Adding more blocks to the contrib.admin site.
-------------------------------------+-------------------------------------
     Reporter:  Muskan Vaswan        |                    Owner:  Muskan
         Type:                       |  Vaswan
  Cleanup/optimization               |                   Status:  closed
    Component:  contrib.admin        |                  Version:  3.1
     Severity:  Normal               |               Resolution:  invalid
     Keywords:  admin customize      |             Triage Stage:
                                     |  Unreviewed
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  1                    |                    UI/UX:  1
-------------------------------------+-------------------------------------

Comment (by Muskan Vaswan):

 That was an example... Also adding the entire header inside a block
 improves flexibility as it allows the user to change the entire topbar in
 one go rather changing singular elements. Not to mention currently if the
 user wants to make an entirely new topbar... ideally making the old one
 disappear entirely they would have to override and extend two files, that
 is, base_site.html for (branding block) and base.html (for the user_tools
 block) both and it still doesn't entirely dissapear. Which could simply be
 accomplished by adding a block for the entire header and the user could
 simply extend the base.html and `{% block header %}{% endblock %}`.
 Another example is if the user wants to change the add_url for a
 particular model having more blocks would be very helpful.
 Replying to [comment:2 Mariusz Felisiak]:
 > > For example, the user can overwrite the entire navbar if the header
 was put inside {% block header %} simply by extending the template.
 >
 > The navigation sidebar is already in a separate block `nav-sidebar` and
 use a separate template, so it's easy to customize, see
 [https://code.djangoproject.com/ticket/31856?cnum_edit=1#comment:1
 comment]. Also, `header` already contains blocks for each element so I
 don't see how adding another `block` around existing blocks can increase
 flexibility.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/32324#comment:3>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/070.c72d430deec5806a5d574f2cea5877cb%40djangoproject.com.

Reply via email to