Comments (1)
By the moment I have found a workaround to fix this.
1-. Create base_site.html
You have to create the file admin/base_site.html
in the template root folder. Something like this:
└── templates/ <- Template folder that you can set it on your Django settings.
└── admin/
└── base_site.html
The base_site.html
file must inherit the default Django base file, and the extend it with a custom css:
{% extends 'admin/base.html' %}
{% load static %}
{% block extrastyle %}
<link rel='stylesheet' href='{% static 'admin.css' %}'>
{% endblock %}
2-. Create the CSS file
This css file must be on the static folder (this is an example path, but you can use what ever path you want, but is mandatory to be in static folder):
└── static/ <- Static folder that you can set it on your Django settings.
└── css/
└── admin_extra.css
The css file must have this styles (feel free to modify it according your needs):
.related-widget-wrapper {
display: flex;
flex-wrap: wrap;
justify-content: flex-start;
}
.related-widget-wrapper select {
width: 20rem;
height: 15rem;
margin-right: 3rem;
}
.related-widget-wrapper [class*="--multiple"] [class*="selection"] {
width: 20rem;
height: 15rem;
}
@media screen and (max-width: 480px) {
.related-widget-wrapper {
flex-direction: column;
}
.related-widget-wrapper select {
width: 100%;
margin-right: 0;
}
.related-widget-wrapper [class*="--multiple"] [class*="selection"] {
width: 100%;
}
}
🚀 Results
These settings results in this output:
And it's also kind of responsive as it restructures itself on window size changes. You can modify it for more several responsiveness.
from django-jet-reboot.
Related Issues (20)
- django-jet-reboot does not render horizontal_filters in two columns like in the default django admin template
- Logout fails due to it being a GET request not a POST request
- Future Maintenance or Alternatives? HOT 1
- InlineTabular and ManyToMany Form Field Layout messed up.
- AccessTokenWidget.render() got an unexpected keyword argument 'renderer' HOT 1
- No collaboration info HOT 1
- Uncaught ReferenceError: DateTimeShortcuts is not defined HOT 1
- custom dashboard error HOT 1
- UI breaks after logging out HOT 3
- some view error on microsoft edge browser HOT 1
- Side menu item corresponding to the currently active page is not being visually highlighted
- in jet/dashboard/dashboard_modules/google_analytics.py add renderer=None
- Does Google analytics work Ga4
- Popup is opening in new window in list view HOT 1
- Doesnt support django 4.2.4 HOT 2
- Consider `@media (prefers-color-scheme: dark)` for themes
- Serving jet staticfiles with Django storages adding "amp;" to query string params resulting in 403 unautharized access HOT 5
- Custom user issue HOT 1
- Disable django-jet-reboot for a given admin site HOT 1
- Migration DatabaseError: ORA-00957: duplicate column name
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from django-jet-reboot.