Wagtail CMS: Adding custom CSS and JavaScript to Your Admin area

  Рет қаралды 8,690

Coding For Everybody

Coding For Everybody

5 жыл бұрын

Customizing the styling and adding some additional JavaScript functionality to your Wagtail CMS Admin (backend) is often a good idea for user experience and a higher perceived value for clients. In this tutorial I'll show you how to add a custom .css and .js file to your /admin/ area using Wagtail Hooks so you can give your clients a truly customized experience.
Tutorial: learnwagtail.com/tutorials/ad...
Git Commit: github.com/CodingForEverybody...
Learn Wagtail from scratch with the official Wagtail for Beginners Course
learnwagtail.com/wagtail-for-...
Used in this video: Wagtail 2.4, Python 3.7, Django 2.1.5
Outro Template made by Grabster - / grabstertv
#Wagtail #Django #Python

Пікірлер: 24
@werewolf6031
@werewolf6031 Жыл бұрын
Thank you so much for this seires. I have been using your videos to learn wagtail while working on this website for work. I had no Django or Wagtail exp and by far your content has saved my life.
@JakeJLivingston
@JakeJLivingston 4 жыл бұрын
Looks like django.contrib.staticfiles.templatetags.staticfiles is no longer a thing. If anyone sees an error, that library got moved. It's now at django.templatetags.static
@CodingForEverybody
@CodingForEverybody 4 жыл бұрын
Good to note! Is this for the Django 3.0 update?
@redditcamp543
@redditcamp543 3 жыл бұрын
Thank you, was hoping to find it in comments :P
@dannyisrael
@dannyisrael 4 жыл бұрын
thank you :)
@uenmedia4528
@uenmedia4528 5 жыл бұрын
Hello, Thanks for the awesome wagtail tutorials. Could you please cover multilingual websites on wagtail too?
@CodingForEverybody
@CodingForEverybody 5 жыл бұрын
Multilingual is on my list of videos to make!
@gimmzy
@gimmzy 4 жыл бұрын
How about searching? Would be cool.
@hazhohuman
@hazhohuman 4 жыл бұрын
Hi kalob, thanks for your efforts, but I need to add a form of text_area in Dashboard as a snippet, in order to add a custom CSS to the DB and get it's value into the template directly after all other static css links, kindly explain or make a video, thanks in advance
@CodingForEverybody
@CodingForEverybody 4 жыл бұрын
This should help: learnwagtail.com/tutorials/adding-global-site-settings-your-wagtail-website/
@oussamaladhari550
@oussamaladhari550 5 жыл бұрын
we can not use any existing app to add the wagtail_hooks file? do we have to create a new app for that purpose only? and have to be named core?
@CodingForEverybody
@CodingForEverybody 5 жыл бұрын
Yes you can use any existing app as long as its enabled in your INSTALLED_APPS. You don't need a new app and it does not need to be called `core`. Wagtail will look for `wagtail_hooks.py` automatically though so make sure you name it that file, and put it in any app.
@oussamaladhari550
@oussamaladhari550 5 жыл бұрын
@@CodingForEverybody thank you very much, for your great tutorials and fast reply! actually, I tried it and it worked as you said ! again thank you for all your efforts
@CodingForEverybody
@CodingForEverybody 5 жыл бұрын
@@oussamaladhari550 Glad I could help :)
@magdagaj
@magdagaj 4 жыл бұрын
@@CodingForEverybody is there a way to rename wagtail_hooks.py file? I would like to keep it inside the app with wagtail hooks for the editor. Is it possible?
@helderandrade1476
@helderandrade1476 5 жыл бұрын
Hii, it is possible to change wagtail's logo on the side nav?
@CodingForEverybody
@CodingForEverybody 5 жыл бұрын
Yes, it absolutely is! You'll need to create a new template file and save it as templates/watailadmin/home/base.html. Then add this code to it: ``` {% extends "wagtailadmin/base.html" %} {% load staticfiles %} {% block branding_logo %} ... your image or svg goes here :) {% endblock branding_logo %} ```
@helderandrade1476
@helderandrade1476 5 жыл бұрын
@@CodingForEverybody Thnx man! rlly apreciate it! learning a lot from you :D
@dannyisrael
@dannyisrael 4 жыл бұрын
@@CodingForEverybody wow thank you
@victortang9834
@victortang9834 4 жыл бұрын
do you know how to customize Richtext image formats ?
@CodingForEverybody
@CodingForEverybody 4 жыл бұрын
You can unassign the full/left/right richtext image options and create new ones. You'll need de-register the old ones and register the new ones.
@victortang9834
@victortang9834 4 жыл бұрын
@@CodingForEverybody hey Thanks for your reply, your videos really helped a lot, actually I did as you said and it works, but what is the next step? How to hook the css to the recreated format, is it the same method as you mentioned in this video?
@ZKITPO
@ZKITPO Жыл бұрын
"from django.contrib.staticfiles.templatetags.staticfiles import static" got deprecated. The newer version: from django.templatetags.static import static
Adding Global Site Settings to Your Wagtail CMS Website
16:43
Coding For Everybody
Рет қаралды 10 М.
Wagtail CMS: Registering Snippets using Django Models
13:35
Coding For Everybody
Рет қаралды 10 М.
Beautiful gymnastics 😍☺️
00:15
Lexa_Merin
Рет қаралды 12 МЛН
🤔Какой Орган самый длинный ? #shorts
00:42
THEY made a RAINBOW M&M 🤩😳 LeoNata family #shorts
00:49
LeoNata Family
Рет қаралды 42 МЛН
WHO LAUGHS LAST LAUGHS BEST 😎 #comedy
00:18
HaHaWhat
Рет қаралды 23 МЛН
Web Developer Roadmap (2024) - Everything is Changing
25:02
ByteGrad
Рет қаралды 314 М.
Top 10 CSS One Liners That Will Blow Your Mind
13:34
developedbyed
Рет қаралды 925 М.
How to Add a Basic StreamField to your Wagtail CMS Page
19:34
Coding For Everybody
Рет қаралды 26 М.
How to Use ListBlocks in Wagtail CMS to Create Repeating StreamField Content
19:52
Premature Optimization
12:39
CodeAesthetic
Рет қаралды 773 М.
Registering Django Models with Wagtails ModelAdmin
12:17
Coding For Everybody
Рет қаралды 13 М.
I built the same app 10 times // Which JS Framework is best?
21:58
Fireship
Рет қаралды 2,5 МЛН
Why Signals Are Better Than React Hooks
16:30
Web Dev Simplified
Рет қаралды 464 М.
Wagtailify Your Static Website: Child Pages and StreamField Introduction
15:33
Beautiful gymnastics 😍☺️
00:15
Lexa_Merin
Рет қаралды 12 МЛН