Skip to content

Commit c8ea6bb

Browse files
author
Emmanouil Konstantinidis
committed
Responsiveness
1 parent f8ef8e3 commit c8ea6bb

File tree

3 files changed

+32
-22
lines changed

3 files changed

+32
-22
lines changed

rest_framework_docs/static/rest_framework_docs/css/style.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

rest_framework_docs/static/rest_framework_docs/less/style.less

Lines changed: 30 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -94,29 +94,39 @@ body {
9494
}
9595

9696
.methods {
97-
margin-bottom: 0;
97+
margin: 10px 0 5px;
9898

99-
.method {
100-
padding: 4px 8px;
101-
color: #FFF;
99+
@media (min-width: @screen-md-min) {
100+
text-align: right;
101+
margin: 0;
102+
}
102103

103-
&.get { background-color: @GetColor; }
104-
&.post { background-color: @PostColor; }
105-
&.patch { background-color: @PutColor; }
106-
&.put { background-color: @PatchColor; }
107-
&.delete { background-color: @DeleteColor; }
108-
&.options { background-color: @OptionsColor; }
109-
110-
&.plug {
111-
color: @brand-primary;
112-
border: 1px solid @brand-primary;
113-
.BorderRadius(50%);
114-
font-size: 14px;
115-
width: 30px;
116-
height: 29px;
117-
margin-left: 10px;
118-
}
104+
.method {
105+
padding: 4px 8px;
106+
margin-top: 5px;
107+
color: #FFF;
108+
109+
@media (min-width: @screen-md-min) {
110+
margin-top: 0;
119111
}
112+
113+
&.get { background-color: @GetColor; }
114+
&.post { background-color: @PostColor; }
115+
&.patch { background-color: @PutColor; }
116+
&.put { background-color: @PatchColor; }
117+
&.delete { background-color: @DeleteColor; }
118+
&.options { background-color: @OptionsColor; }
119+
120+
&.plug {
121+
color: @brand-primary;
122+
border: 1px solid @brand-primary;
123+
.BorderRadius(50%);
124+
font-size: 14px;
125+
width: 30px;
126+
height: 29px;
127+
margin-left: 10px;
128+
}
129+
}
120130
}
121131
}
122132

rest_framework_docs/templates/rest_framework_docs/home.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ <h4 class="panel-title title">
3636
</h4>
3737
</div>
3838

39-
<div class="col-md-5 text-right">
39+
<div class="col-md-5">
4040
<ul class="list-inline methods">
4141
{% for method in endpoint.allowed_methods %}
4242
<li class="method {{ method|lower }}">{{ method }}</li>

0 commit comments

Comments
 (0)