Skip to content

Commit 5ef9b94

Browse files
committed
adapt to django admin css & merged #63
1 parent 79bed6f commit 5ef9b94

File tree

9 files changed

+94
-10
lines changed

9 files changed

+94
-10
lines changed

README.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -155,8 +155,9 @@ to get ``IMGUR_CLIENT_ID`` and ``IMGUR_API_KEY``.
155155
MARTOR_SEARCH_USERS_URL = '/martor/search-user/' # default
156156

157157
# Markdown Extensions
158-
MARTOR_MARKDOWN_BASE_EMOJI_URL = 'https://www.webfx.com/tools/emoji-cheat-sheet/graphics/emojis/' # default
159-
MARTOR_MARKDOWN_BASE_MENTION_URL = 'https://python.web.id/author/' # default (change this)
158+
# MARTOR_MARKDOWN_BASE_EMOJI_URL = 'https://www.webfx.com/tools/emoji-cheat-sheet/graphics/emojis/' # from webfx
159+
MARTOR_MARKDOWN_BASE_EMOJI_URL = 'https://github.githubassets.com/images/icons/emoji/' # default from github
160+
MARTOR_MARKDOWN_BASE_MENTION_URL = 'https://python.web.id/author/' # please change this to your domain
160161

161162
Check this setting is not set else csrf will not be sent over ajax calls:
162163

martor/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# -*- coding: utf-8 -*-
22

3-
__VERSION__ = '1.3.9'
3+
__VERSION__ = '1.4.0'
44
__AUTHOR__ = 'Agus Makmun (Summon Agus)'
55
__AUTHOR_EMAIL__ = '[email protected]'

martor/settings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@
6969

7070
# Markdown Extensions
7171
MARTOR_MARKDOWN_BASE_EMOJI_URL = getattr(
72-
settings, 'MARTOR_MARKDOWN_BASE_EMOJI_URL', 'https://www.webfx.com/tools/emoji-cheat-sheet/graphics/emojis/'
72+
settings, 'MARTOR_MARKDOWN_BASE_EMOJI_URL', 'https://github.githubassets.com/images/icons/emoji/'
7373
)
7474
# to use static and keep backward compatibility
7575
# set to true if using bucket like storage engine
Lines changed: 74 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,74 @@
1+
/*
2+
CSS to handle inside admin django
3+
by following the default `admin/css/base.css` from django
4+
*/
5+
6+
body {
7+
margin: 0;
8+
padding: 0;
9+
font-size: 14px;
10+
color: #333;
11+
background: #fff;
12+
}
13+
14+
#container {
15+
-webkit-box-sizing: unset;
16+
box-sizing: unset;
17+
}
18+
19+
body, h1, h2, h3, h4, h5,
20+
button, input, optgroup, select {
21+
font-family: "Roboto","Lucida Grande","DejaVu Sans","Bitstream Vera Sans",Verdana,Arial,sans-serif;
22+
}
23+
24+
h1, h2, h3, h4, h5 {
25+
font-weight: bold!important;
26+
line-height: unset!important;
27+
}
28+
29+
h1 {
30+
margin: 0 0 20px!important;
31+
font-weight: 300!important;
32+
font-size: 20px!important;
33+
color: #333!important;
34+
}
35+
36+
h2 {
37+
font-size: 16px!important;
38+
margin: 1em 0 .5em 0!important;
39+
}
40+
41+
h2.subhead {
42+
font-weight: normal!important;
43+
margin-top: 0!important;
44+
}
45+
46+
h3 {
47+
font-size: 14px!important;
48+
margin: .8em 0 .3em 0!important;
49+
color: #333!important;
50+
font-weight: bold!important;
51+
}
52+
53+
h4 {
54+
font-size: 12px!important;
55+
margin: 1em 0 .8em 0!important;
56+
padding-bottom: 3px!important;
57+
}
58+
59+
h5 {
60+
font-size: 10px!important;
61+
margin: 1.5em 0 .5em 0!important;
62+
color: #333!important;
63+
text-transform: uppercase!important;
64+
letter-spacing: 1px!important;
65+
}
66+
67+
.button, input[type=submit], input[type=button], .submit-row input, a.button {
68+
padding: 5px 15px;
69+
}
70+
71+
.ui.tabular.menu+.attached:not(.top).segment,
72+
.ui.tabular.menu+.attached:not(.top).segment+.attached:not(.top).segment {
73+
width: auto;
74+
}

martor/static/martor/css/martor-admin.min.css

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

martor/static/martor/css/martor.min.css

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

martor/static/martor/js/martor.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
2-
* Name : Martor v1.3.9
2+
* Name : Martor v1.4.0
33
* Created by : Agus Makmun (Summon Agus)
4-
* Release date : 25-Feb-2019
4+
* Release date : 02-Mar-2019
55
* License : GNU GENERAL PUBLIC LICENSE Version 3, 29 June 2007
66
* Repository : https://github.com/agusmakmun/django-markdown-editor
77
**/

martor/static/martor/js/martor.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

martor/widgets.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ class Media:
4343
'plugins/css/semantic.min.css',
4444
'plugins/css/resizable.min.css',
4545
'martor/css/martor.min.css',
46+
'martor/css/martor-admin.min.css'
4647
)
4748
}
4849
js = (

0 commit comments

Comments
 (0)