Compare commits
17 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 73c9a54d94 | |||
| eff414b40c | |||
| ccbf76dc5a | |||
| 5b6e83751b | |||
| 572294f646 | |||
| 4e18d36c79 | |||
| ee9994231b | |||
| fb4cfdb772 | |||
| 8535232598 | |||
| abbb666eae | |||
| d48fc882f1 | |||
| f968bd9ffa | |||
| c0592276de | |||
| 451679d565 | |||
| e579134152 | |||
| 6e57cf558c | |||
| d00428c30a |
@@ -55,3 +55,5 @@ docs/_build/
|
||||
|
||||
# PyBuilder
|
||||
target/
|
||||
screenshots
|
||||
TODO.txt
|
||||
|
||||
@@ -9,15 +9,19 @@ env:
|
||||
- TOX_ENV=py34-18
|
||||
- TOX_ENV=py34-19
|
||||
- TOX_ENV=py34-110
|
||||
- TOX_ENV=py34-20
|
||||
- TOX_ENV=py34-master
|
||||
- TOX_ENV=py35-18
|
||||
- TOX_ENV=py35-19
|
||||
- TOX_ENV=py35-110
|
||||
- TOX_ENV=py35-20
|
||||
- TOX_ENV=py35-master
|
||||
matrix:
|
||||
include:
|
||||
- python: "3.6"
|
||||
env: TOX_ENV=py36-111
|
||||
- python: "3.6"
|
||||
env: TOX_ENV=py36-20
|
||||
- python: "3.6"
|
||||
env: TOX_ENV=py36-master
|
||||
allow_failures:
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
[](https://travis-ci.org/fabiocaccamo/django-admin-interface)
|
||||
[](https://codecov.io/gh/fabiocaccamo/django-admin-interface)
|
||||
[](https://landscape.io/github/fabiocaccamo/django-admin-interface/master)
|
||||
[](https://requires.io/github/fabiocaccamo/django-admin-interface/requirements/?branch=master)
|
||||
[](https://badge.fury.io/py/django-admin-interface)
|
||||
[](https://img.shields.io/pypi/pyversions/django-admin-interface.svg)
|
||||
[](https://img.shields.io/pypi/l/django-admin-interface.svg)
|
||||
@@ -9,17 +8,24 @@
|
||||
# django-admin-interface
|
||||
django-admin-interface is a modern **responsive flat admin interface customizable by the admin itself**.
|
||||
|
||||

|
||||
|
||||
## Features
|
||||
- Beautiful default **django-theme**
|
||||
- Themes management and customization *(you can **customize admin title, logo and colors**)*
|
||||
- Responsive
|
||||
- List filter dropdown *(optional)*
|
||||
- `NEW` **Related modal** *(instead of the old popup window, optional)*
|
||||
- Style optimizations for: `django-ckeditor`, `django-modeltranslation`, `sorl-thumbnail`
|
||||
- `NEW` **Enviroment label** *(development, testing, staging, production)*
|
||||
- Style optimizations for:
|
||||
- `django-ckeditor`
|
||||
- `django-modeltranslation`
|
||||
- `django-tabbed-admin`
|
||||
- `sorl-thumbnail`
|
||||
|
||||
## Requirements
|
||||
- Python 2.7, 3.4, 3.5, 3.6
|
||||
- Django 1.7, 1.8, 1.9, 1.10, 1.11
|
||||
- Django 1.7, 1.8, 1.9, 1.10, 1.11, 2.0
|
||||
|
||||
## Installation
|
||||
- Run `pip install django-admin-interface`
|
||||
@@ -28,7 +34,7 @@ django-admin-interface is a modern **responsive flat admin interface customizabl
|
||||
INSTALLED_APPS = (
|
||||
#...
|
||||
'admin_interface',
|
||||
'flat_responsive',
|
||||
'flat_responsive', # only if django version < 2.0
|
||||
'flat', # only if django version < 1.9
|
||||
'colorfield',
|
||||
#...
|
||||
|
||||
+14
-6
@@ -1,4 +1,4 @@
|
||||
|Build Status| |codecov| |Code Health| |Requirements Status| |PyPI version| |Py versions| |License|
|
||||
|Build Status| |codecov| |Code Health| |PyPI version| |Py versions| |License|
|
||||
|
||||
django-admin-interface
|
||||
======================
|
||||
@@ -6,6 +6,9 @@ django-admin-interface
|
||||
django-admin-interface is a modern **responsive flat admin interface
|
||||
customizable by the admin itself**.
|
||||
|
||||
|django-admin-interface_preview|
|
||||
---------------------------------
|
||||
|
||||
Features
|
||||
--------
|
||||
|
||||
@@ -14,19 +17,24 @@ Features
|
||||
- Responsive
|
||||
- List filter dropdown *(optional)*
|
||||
- ``NEW`` **Related modal** (instead of the old popup window, optional)
|
||||
- Style optimizations for: ``django-ckeditor``, ``django-modeltranslation``, ``sorl-thumbnail``
|
||||
- ``NEW`` **Enviroment label** (development, testing, staging, production)
|
||||
- Style optimizations for:
|
||||
- `django-ckeditor`
|
||||
- `django-modeltranslation`
|
||||
- `django-tabbed-admin`
|
||||
- `sorl-thumbnail`
|
||||
|
||||
Requirements
|
||||
------------
|
||||
|
||||
- Python 2.7, 3.4, 3.5, 3.6
|
||||
- Django 1.7, 1.8, 1.9, 1.10, 1.11
|
||||
- Django 1.7, 1.8, 1.9, 1.10, 1.11, 2.0
|
||||
|
||||
Installation
|
||||
------------
|
||||
|
||||
- Run ``pip install django-admin-interface``
|
||||
- Add ``admin_interface``, ``flat_responsive``, ``flat`` *(only if django version < 1.9)* and ``colorfield`` to ``settings.INSTALLED_APPS`` **before** ``django.contrib.admin``
|
||||
- Add ``admin_interface``, ``flat_responsive`` *(only if django version < 2.0)*, ``flat`` *(only if django version < 1.9)* and ``colorfield`` to ``settings.INSTALLED_APPS`` **before** ``django.contrib.admin``
|
||||
- Run ``python manage.py migrate``
|
||||
- Run ``python manage.py collectstatic``
|
||||
- Restart your application server
|
||||
@@ -127,14 +135,14 @@ Released under **MIT License**.
|
||||
|
||||
.. |Code Health| image:: https://landscape.io/github/fabiocaccamo/django-admin-interface/master/landscape.svg?style=flat
|
||||
|
||||
.. |Requirements Status| image:: https://requires.io/github/fabiocaccamo/django-admin-interface/requirements.svg?branch=master
|
||||
|
||||
.. |PyPI version| image:: https://badge.fury.io/py/django-admin-interface.svg
|
||||
|
||||
.. |Py versions| image:: https://img.shields.io/pypi/pyversions/django-admin-interface.svg
|
||||
|
||||
.. |License| image:: https://img.shields.io/pypi/l/django-admin-interface.svg
|
||||
|
||||
.. |django-admin-interface_preview| image:: https://user-images.githubusercontent.com/1035294/35631521-64b0cab8-06a4-11e8-8f57-c04fdfbb7e8b.gif
|
||||
|
||||
.. |django-admin-interface_login| image:: https://cloud.githubusercontent.com/assets/1035294/11240233/55c8d4ba-8df1-11e5-9568-00fdc987ede8.gif
|
||||
|
||||
.. |django-admin-interface_dashboard| image:: https://cloud.githubusercontent.com/assets/1035294/11240239/627c0362-8df1-11e5-81fa-216366a5d8da.gif
|
||||
|
||||
@@ -15,6 +15,13 @@ class ThemeAdmin(admin.ModelAdmin):
|
||||
'classes': ('wide', ),
|
||||
'fields': ('name', 'active', )
|
||||
}),
|
||||
('Enviroment', {
|
||||
'classes': ('wide', ),
|
||||
'fields': (
|
||||
'env',
|
||||
'env_visible',
|
||||
)
|
||||
}),
|
||||
('Logo', {
|
||||
'classes': ('wide', ),
|
||||
'fields': (
|
||||
|
||||
@@ -4,12 +4,12 @@
|
||||
"fields": {
|
||||
"name": "USWDS",
|
||||
"active": true,
|
||||
"title": "Site administration",
|
||||
"title": "Django administration",
|
||||
"title_color": "#FFFFFF",
|
||||
"title_visible": true,
|
||||
"title_visible": false,
|
||||
"logo": "",
|
||||
"logo_color": "#FFFFFF",
|
||||
"logo_visible": false,
|
||||
"logo_visible": true,
|
||||
"css_header_background_color": "#112E51",
|
||||
"css_header_text_color": "#FFFFFF",
|
||||
"css_header_link_color": "#FFFFFF",
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Generated by Django 1.11 on 2018-01-31 11:00
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('admin_interface', '0008_change_related_modal_background_opacity_type'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='theme',
|
||||
name='env',
|
||||
field=models.CharField(choices=[('development', 'Development'), ('testing', 'Testing'), ('staging', 'Staging'), ('production', 'Production')], default='development', max_length=50, verbose_name='enviroment'),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='theme',
|
||||
name='env_visible',
|
||||
field=models.BooleanField(default=True, verbose_name='visible'),
|
||||
),
|
||||
]
|
||||
@@ -73,6 +73,19 @@ class Theme(models.Model):
|
||||
upload_to='admin-interface/favicon/', blank=True,
|
||||
help_text='(.ico|.png|.gif - 16x16|32x32 px)', verbose_name='favicon')
|
||||
|
||||
env_choices = (
|
||||
('development', 'Development', ),
|
||||
('testing', 'Testing', ),
|
||||
('staging', 'Staging', ),
|
||||
('production', 'Production', ),
|
||||
)
|
||||
env = models.CharField(
|
||||
max_length=50,
|
||||
choices=env_choices,
|
||||
default='development', verbose_name='enviroment')
|
||||
env_visible = models.BooleanField(
|
||||
default=True, verbose_name='visible')
|
||||
|
||||
css_header_background_color = ColorField(
|
||||
blank=True, default='#0C4B33', help_text='#0C4B33',
|
||||
max_length=10, verbose_name='background color')
|
||||
|
||||
@@ -19,8 +19,10 @@ https://github.com/fabiocaccamo/django-admin-interface
|
||||
{% include "admin_interface/css/list-filter-dropdown.css" %}
|
||||
{% include "admin_interface/css/recent-actions.css" %}
|
||||
{% include "admin_interface/css/related-modal.css" %}
|
||||
{% include "admin_interface/css/jquery.ui.tabs.css" %}
|
||||
{% include "admin_interface/css/modeltranslation.css" %}
|
||||
{% include "admin_interface/css/sorl-thumbnail.css" %}
|
||||
{% include "admin_interface/css/tabbed-admin.css" %}
|
||||
{% include "admin_interface/css/ckeditor.css" %}
|
||||
{% include "admin_interface/css/tinymce.css" %}
|
||||
|
||||
@@ -64,4 +66,9 @@ https://github.com/fabiocaccamo/django-admin-interface
|
||||
<span>{% if theme.title %}{% trans theme.title %}{% else %}{% trans 'Django administration' %}{% endif %}</span>
|
||||
{% endif %}
|
||||
</h1>
|
||||
{% endblock %}
|
||||
|
||||
{% block welcome-msg %}
|
||||
{% get_admin_interface_theme as theme %}
|
||||
{% if theme.env_visible %}<span class="enviroment-label {{ theme.env }}"></span> - {% endif %}{{ block.super }}<br>
|
||||
{% endblock %}
|
||||
@@ -308,79 +308,28 @@ body.admin-interface .paginator a.showall:visited {
|
||||
width: 100% !important;
|
||||
flex: 0 1 auto;
|
||||
}
|
||||
.admin-interface .aligned .form-row input[type="file"] {
|
||||
width: 100% !important;
|
||||
}
|
||||
}
|
||||
|
||||
/* improve responsive selector */
|
||||
|
||||
/* fix [stacked, not-stacked] equalize horizontal and vertical select padding for selector (stacked and not) */
|
||||
/* fix [stacked, not-stacked] equalize horizontal and vertical select padding for selector */
|
||||
.admin-interface .selector .selector-available select,
|
||||
.admin-interface .selector .selector-chosen select {
|
||||
padding: 7px 10px;
|
||||
display: block;
|
||||
}
|
||||
|
||||
/* fix [not-stacked] selector */
|
||||
.admin-interface .selector:not(.stacked) {
|
||||
width: auto;
|
||||
margin-right: 10px;
|
||||
/* fix [stacked, not-stacked] select options text overflow */
|
||||
.admin-interface .selector .selector-available select option,
|
||||
.admin-interface .selector .selector-chosen select option {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
/* fix [not-stacked] equalize selectors height by adding the height of the .selector-available filter-bar */
|
||||
.admin-interface .selector:not(.stacked) .selector-chosen select {
|
||||
height: calc(46px + 17.2em) !important;
|
||||
}
|
||||
|
||||
@media (max-width: 1024px){
|
||||
.admin-interface .related-widget-wrapper-link + .selector:not(.stacked) {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-width: 767px) and (max-width: 1124px){
|
||||
|
||||
.admin-interface .selector:not(.stacked) .selector-available,
|
||||
.admin-interface .selector:not(.stacked) .selector-chosen {
|
||||
width: 285px;
|
||||
flex: 0 1 auto;
|
||||
}
|
||||
.admin-interface .selector:not(.stacked) .selector-filter {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.admin-interface .selector:not(.stacked) .selector-filter label {
|
||||
margin: 0;
|
||||
}
|
||||
.admin-interface .selector:not(.stacked) .selector-available input {
|
||||
width: auto;
|
||||
flex: 1 1;
|
||||
}
|
||||
.admin-interface .selector:not(.stacked) select {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
/* fix [not-stacked] in tabular inline context */
|
||||
.admin-interface .tabular.inline-related .selector:not(.stacked) {
|
||||
width: 795px;
|
||||
float: none;
|
||||
display: inline-block;
|
||||
margin-right: 22px;
|
||||
}
|
||||
|
||||
.admin-interface .tabular.inline-related .form-row .related-widget-wrapper-link:first-child {
|
||||
float: right;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
/* fix [stacked] in tabular inline context */
|
||||
.admin-interface .tabular.inline-related .selector.stacked {
|
||||
width: 480px;
|
||||
float: none;
|
||||
display: inline-block;
|
||||
margin-right: 22px;
|
||||
}
|
||||
|
||||
/* fix [stacked] chooser align center */
|
||||
.admin-interface .selector.stacked .selector-chooser {
|
||||
margin-left:calc(50% - 30px);
|
||||
}
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1,144 @@
|
||||
/*
|
||||
* jQuery UI CSS Framework
|
||||
* Copyright (c) 2010 AUTHORS.txt (http://jqueryui.com/about)
|
||||
* Dual licensed under the MIT (MIT-LICENSE.txt) and GPL (GPL-LICENSE.txt) licenses.
|
||||
* http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.2/themes/base/jquery.ui.core.css
|
||||
*/
|
||||
|
||||
/*
|
||||
backward compatibility:
|
||||
.ui-tabs-selected: jquery ui < 1.10
|
||||
.ui-tabs-active classes jquery ui >= 1.10
|
||||
*/
|
||||
|
||||
/* Layout helpers
|
||||
----------------------------------*/
|
||||
.ui-helper-hidden { display: none; }
|
||||
.ui-helper-hidden-accessible { position: absolute; left: -99999999px; }
|
||||
.ui-helper-reset { margin: 0; padding: 0; border: 0; outline: 0; line-height: 1.3; text-decoration: none; font-size: 100%; list-style: none; }
|
||||
.ui-helper-clearfix:after { content: "."; display: block; height: 0; clear: both; visibility: hidden; }
|
||||
.ui-helper-clearfix { display: inline-block; }
|
||||
/* required comment for clearfix to work in Opera \*/
|
||||
* html .ui-helper-clearfix { height:1%; }
|
||||
.ui-helper-clearfix { display:block; }
|
||||
.ui-helper-zfix { width: 100%; height: 100%; top: 0; left: 0; position: absolute; opacity: 0; filter:Alpha(Opacity=0); }
|
||||
.ui-state-disabled { cursor: default !important; }
|
||||
.ui-icon { display: block; text-indent: -99999px; overflow: hidden; background-repeat: no-repeat; }
|
||||
/* http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.2/themes/base/jquery.ui.tabs.css */
|
||||
.ui-widget-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
|
||||
.ui-tabs { position: relative; padding: .2em; zoom: 1; } /* position: relative prevents IE scroll bug (element with position: relative inside container with overflow: auto appear as "fixed") */
|
||||
.ui-tabs .ui-tabs-nav { margin: 0; padding: .2em .2em 0; }
|
||||
.ui-tabs .ui-tabs-nav li { list-style: none; float: left; position: relative; top: 1px; margin: 0 .2em 1px 0; border-bottom: 0 !important; padding: 0; white-space: nowrap; }
|
||||
.ui-tabs .ui-tabs-nav li a { float: left; padding: .5em 1em; text-decoration: none; }
|
||||
.ui-tabs .ui-tabs-nav li.ui-tabs-active, .ui-tabs .ui-tabs-nav li.ui-tabs-selected { margin-bottom: 0; padding-bottom: 1px; }
|
||||
.ui-tabs .ui-tabs-nav li.ui-tabs-active a, .ui-tabs .ui-tabs-nav li.ui-tabs-selected a, .ui-tabs .ui-tabs-nav li.ui-state-disabled a, .ui-tabs .ui-tabs-nav li.ui-state-processing a { cursor: text; }
|
||||
.ui-tabs .ui-tabs-nav li a, .ui-tabs.ui-tabs-collapsible .ui-tabs-nav li.ui-tabs-selected a { cursor: pointer; } /* first selector in group seems obsolete, but required to overcome bug in Opera applying cursor: text overall if defined elsewhere... */
|
||||
.ui-tabs .ui-tabs-panel { display: block; border-width: 0; padding: 1em 1.4em; background: none; }
|
||||
.ui-tabs .ui-tabs-hide {
|
||||
position: absolute;
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* Custom tabs theme */
|
||||
.admin-interface .ui-tabs {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.admin-interface .ui-tabs,
|
||||
.admin-interface .ui-tabs .ui-widget-header,
|
||||
.admin-interface .ui-tabs .ui-widget-header .ui-state-default {
|
||||
border: none;
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.admin-interface .ui-tabs .ui-tabs-nav {
|
||||
padding: 10px 0 0 10px;
|
||||
border-bottom: none;
|
||||
}
|
||||
.admin-interface .ui-tabs .ui-tabs-nav li {
|
||||
margin: 0 0 0 -1px;
|
||||
}
|
||||
.admin-interface .ui-tabs .ui-tabs-nav li.required {
|
||||
font-weight: bold;
|
||||
}
|
||||
.admin-interface .ui-tabs .ui-tabs-nav li a {
|
||||
border: 1px solid #eeeeee;
|
||||
background-color: #f8f8f8;
|
||||
border-bottom: none;
|
||||
color: #666666;
|
||||
padding: 7px 14px 8px 14px;
|
||||
margin-top: 1px;
|
||||
-moz-border-radius-topright: 4px;
|
||||
-webkit-border-top-right-radius: 4px;
|
||||
-moz-border-radius-topleft: 4px;
|
||||
-webkit-border-top-left-radius: 4px;
|
||||
border-top-left-radius: 4px;
|
||||
border-top-right-radius: 4px;
|
||||
font-size: 12px;
|
||||
text-transform: uppercase;
|
||||
outline: none;
|
||||
}
|
||||
|
||||
.admin-interface .ui-tabs .ui-tabs-nav li.ui-tabs-active a,
|
||||
.admin-interface .ui-tabs .ui-tabs-nav li.ui-tabs-selected a {
|
||||
padding: 8px 14px 8px 14px;
|
||||
margin-top: 0px;
|
||||
margin-bottom: -1px;
|
||||
font-weight: bold;
|
||||
background-color: #FFFFFF;
|
||||
color: {{ theme.css_module_background_color }};
|
||||
border-bottom: 1px solid #FFFFFF;
|
||||
}
|
||||
|
||||
.admin-interface .ui-tabs .ui-tabs-panel {
|
||||
border: 1px solid #eeeeee;
|
||||
border-radius: 4px;
|
||||
padding: 10px;
|
||||
margin-bottom: 30px;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.admin-interface .inline-group .tabular .ui-tabs .ui-tabs-panel {
|
||||
padding: 8px;
|
||||
}
|
||||
|
||||
.admin-interface .inline-group .tabular .ui-tabs .ui-tabs-nav {
|
||||
padding-left: 4px;
|
||||
}
|
||||
|
||||
.admin-interface .inline-group .tabular tr td {
|
||||
vertical-align: bottom;
|
||||
}
|
||||
|
||||
.admin-interface .inline-group .tabular tr.has_original td.original,
|
||||
.admin-interface .inline-group .tabular tr td.delete {
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
.admin-interface .inline-group .tabular .datetime > input {
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
.admin-interface .inline-group .tabular .datetime br {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.admin-interface #changelist .row1:not(.selected):hover,
|
||||
.admin-interface #changelist .row2:not(.selected):hover {
|
||||
background: #f9f9f9;
|
||||
}
|
||||
|
||||
.admin-interface .row2 {
|
||||
background: #fcfcfc;
|
||||
}
|
||||
|
||||
.admin-interface .row2 .ui-tabs .ui-tabs-nav li a {
|
||||
background-color: #f5f5f5;
|
||||
border: 1px solid #ebebeb;
|
||||
}
|
||||
|
||||
.admin-interface .row2 .ui-tabs .ui-tabs-nav li.ui-tabs-active a,
|
||||
.admin-interface .row2 .ui-tabs .ui-tabs-nav li.ui-tabs-selected a {
|
||||
background-color: #fcfcfc;
|
||||
border-bottom: 1px solid #fcfcfc;
|
||||
}
|
||||
@@ -1,65 +1,17 @@
|
||||
/*
|
||||
django-modeltranslation support
|
||||
https://github.com/deschler/django-modeltranslation/pull/313/commits
|
||||
https://github.com/deschler/django-modeltranslation
|
||||
*/
|
||||
|
||||
.admin-interface #content h1 select {
|
||||
text-transform:uppercase;
|
||||
margin-left:15px;
|
||||
text-transform: uppercase;
|
||||
margin-left: 15px;
|
||||
min-width: 50px;
|
||||
}
|
||||
|
||||
.admin-interface .ui-tabs .ui-tabs-nav {
|
||||
padding:10px 0 0 10px;
|
||||
.admin-interface .ui-tabs .ui-tabs-panel[id^=tab_id_] {
|
||||
border: none;
|
||||
border-top: 1px solid #eeeeee;
|
||||
padding: 0;
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.admin-interface .ui-tabs .ui-tabs-nav li {
|
||||
margin-left:-1px;
|
||||
}
|
||||
|
||||
.admin-interface .ui-tabs .ui-tabs-nav li a {
|
||||
outline:none;
|
||||
background-color:#f8f8f8;
|
||||
border:1px solid #eeeeee;
|
||||
border-bottom:none;
|
||||
text-transform:uppercase;
|
||||
|
||||
padding:7px 14px 8px 14px;
|
||||
margin-top:1px;
|
||||
}
|
||||
|
||||
.admin-interface .ui-tabs .ui-tabs-nav li.ui-tabs-active a,
|
||||
.admin-interface .ui-tabs .ui-tabs-nav li.ui-tabs-selected a {
|
||||
|
||||
padding:8px 14px 8px 14px;
|
||||
margin-top:0px;
|
||||
margin-bottom:-1px;
|
||||
font-weight: bold;
|
||||
background-color:#FFFFFF;
|
||||
color:{{ theme.css_module_background_color }};
|
||||
|
||||
border-bottom:1px solid #FFFFFF;
|
||||
}
|
||||
|
||||
.admin-interface .inline-group .tabular .ui-tabs .ui-tabs-panel {
|
||||
padding:8px;
|
||||
}
|
||||
|
||||
.admin-interface #changelist .row1:not(.selected):hover,
|
||||
.admin-interface #changelist .row2:not(.selected):hover {
|
||||
background:#f9f9f9;
|
||||
}
|
||||
|
||||
.admin-interface .row2 {
|
||||
background:#fcfcfc;
|
||||
}
|
||||
|
||||
.admin-interface .row2 .ui-tabs .ui-tabs-nav li a {
|
||||
background-color:#f5f5f5;
|
||||
border:1px solid #ebebeb;
|
||||
}
|
||||
|
||||
.admin-interface .row2 .ui-tabs .ui-tabs-nav li.ui-tabs-active a,
|
||||
.admin-interface .row2 .ui-tabs .ui-tabs-nav li.ui-tabs-selected a {
|
||||
background-color:#fcfcfc;
|
||||
border-bottom:1px solid #fcfcfc;
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
/*
|
||||
django-tabbed-admin support
|
||||
https://github.com/omji/django-tabbed-admin
|
||||
*/
|
||||
|
||||
/* Hide tabs until ready */
|
||||
/*
|
||||
.admin-interface #tabs ul {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.admin-interface #tabs ul.ui-tabs-nav {
|
||||
display: block;
|
||||
}
|
||||
*/
|
||||
|
||||
.admin-interface .ui-tabs .ui-tabs-panel[id^=tabs] .module.aligned:last-child {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.admin-interface .ui-tabs .ui-tabs-panel[id^=tabs] .module.aligned:last-child .form-row:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
|
||||
@media (max-width: 350px){
|
||||
.admin-interface .ui-tabs .ui-tabs-panel[id^=tabs] .vTextField,
|
||||
.admin-interface .inline-related .vTextField {
|
||||
width: 17em;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 767px){
|
||||
/* fix horizontal overflow - responsive.css:563 */
|
||||
.admin-interface .ui-tabs .ui-tabs-panel[id^=tabs] .aligned .form-row > div:not([class]) {
|
||||
width: 100% !important;
|
||||
}
|
||||
}
|
||||
@@ -1,21 +1,20 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from django import template
|
||||
from django import template, VERSION
|
||||
|
||||
from admin_interface.models import Theme
|
||||
from admin_interface.version import __version__
|
||||
|
||||
register = template.Library()
|
||||
|
||||
try:
|
||||
assignment_tag = register.assignment_tag
|
||||
except AttributeError:
|
||||
assignment_tag = register.simple_tag
|
||||
if VERSION < (1, 9):
|
||||
simple_tag = register.assignment_tag
|
||||
else:
|
||||
simple_tag = register.simple_tag
|
||||
|
||||
|
||||
@assignment_tag(takes_context=True)
|
||||
@simple_tag(takes_context=True)
|
||||
def get_admin_interface_theme(context):
|
||||
|
||||
theme = None
|
||||
request = context.get('request', None)
|
||||
|
||||
@@ -31,6 +30,6 @@ def get_admin_interface_theme(context):
|
||||
return theme
|
||||
|
||||
|
||||
@assignment_tag(takes_context=False)
|
||||
@simple_tag(takes_context=False)
|
||||
def get_admin_interface_version():
|
||||
return __version__
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
__version__ = '0.5.9'
|
||||
__version__ = '0.6.3'
|
||||
|
||||
@@ -45,6 +45,7 @@ setup(
|
||||
'Framework :: Django :: 1.9',
|
||||
'Framework :: Django :: 1.10',
|
||||
'Framework :: Django :: 1.11',
|
||||
'Framework :: Django :: 2.0',
|
||||
'Intended Audience :: Developers',
|
||||
'License :: OSI Approved :: MIT License',
|
||||
'Natural Language :: English',
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
[tox]
|
||||
envlist =
|
||||
py27-{17,18,19,110,111},
|
||||
py34-{17,18,19,110,111,master},
|
||||
py35-{18,19,110,111,master},
|
||||
py36-{18,19,110,111,master},
|
||||
py34-{17,18,19,110,111,20,master},
|
||||
py35-{18,19,110,111,20,master},
|
||||
py36-{18,19,110,111,20,master},
|
||||
[testenv]
|
||||
passenv = CI TRAVIS TRAVIS_*
|
||||
deps =
|
||||
@@ -12,10 +12,11 @@ deps =
|
||||
19: Django >= 1.9, < 1.10
|
||||
110: Django >= 1.10, < 1.11
|
||||
111: Django >= 1.11, < 1.12
|
||||
20: Django >= 2.0, < 2.1
|
||||
master: https://github.com/django/django/archive/master.tar.gz
|
||||
coverage
|
||||
codecov
|
||||
commands =
|
||||
coverage run --append --source=admin_interface setup.py test
|
||||
coverage report -m
|
||||
codecov
|
||||
codecov
|
||||
Reference in New Issue
Block a user