Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Phill 115 posts 289 karma points
    Jan 20, 2016 @ 19:46
    Phill
    0

    Recommendations for injecting custom admin styles

    Hi there,

    I have a custom css file that I add to /umbraco/views/default.cshtml for every project I work on. It does some simple styling things like reducing the spacing between fields so I don't have to scroll as much, reducing the size of the media picker square, adding a more obvious styling to the required node name field that users often don't see... you get the idea.

    My question is, I add this manualy to the view file but everytime I do an upgrade to an umbraco site this change gets replaced. Does anyone have a recommendation for how I might be able to inject this via code? Maybe something fired via application start handler that would add reference to this css file every time the app starts?

    Any insight would be appreciated. Not a big deal but always looking for things that can make my life easier.

    Thanks in advance. Phill

  • Comment author was deleted

    Jan 20, 2016 @ 19:52

    You can create a plugin and define your stylesheet in a package manifest http://umbraco.github.io/Belle/#/tutorials/manifest

    http://24days.in/umbraco/2015/umbraco-7-back-office-tweaks/

  • Phill 115 posts 289 karma points
    Jan 20, 2016 @ 19:56
    Phill
    0

    Exactly what I was looking for, never thought of going the package route. Will give that a go.

    Thanks a bunch Tim!

  • Comment author was deleted

    Jan 20, 2016 @ 19:58

    sweet, glad I could help :)

Please Sign in or register to post replies

Write your reply to:

Draft