aboutsummaryrefslogtreecommitdiffstats
path: root/rest_framework/static
diff options
context:
space:
mode:
authorTom Christie2013-03-18 21:03:05 +0000
committerTom Christie2013-03-18 21:03:05 +0000
commit74fb366c595db87bb71baeffcacfb7d2482e3a18 (patch)
tree2e28cb52542742f32cdd3fbeb625f7f59cba0a3f /rest_framework/static
parent4c6396108704d38f534a16577de59178b1d0df3b (diff)
parent034c4ce4081dd6d15ea47fb8318754321a3faf0c (diff)
downloaddjango-rest-framework-74fb366c595db87bb71baeffcacfb7d2482e3a18.tar.bz2
Merge branch 'master' into resources-routers
Diffstat (limited to 'rest_framework/static')
-rw-r--r--rest_framework/static/rest_framework/css/default.css43
-rw-r--r--rest_framework/static/rest_framework/js/default.js8
2 files changed, 51 insertions, 0 deletions
diff --git a/rest_framework/static/rest_framework/css/default.css b/rest_framework/static/rest_framework/css/default.css
index b2e41b99..d806267b 100644
--- a/rest_framework/static/rest_framework/css/default.css
+++ b/rest_framework/static/rest_framework/css/default.css
@@ -150,6 +150,49 @@ html, body {
margin: 0 auto -60px;
}
+.form-switcher {
+ margin-bottom: 0;
+}
+
+.well {
+ -webkit-box-shadow: none;
+ -moz-box-shadow: none;
+ box-shadow: none;
+}
+
+.well .form-actions {
+ padding-bottom: 0;
+ margin-bottom: 0;
+}
+
+.well form {
+ margin-bottom: 0;
+}
+
+.nav-tabs {
+ border: 0;
+}
+
+.nav-tabs > li {
+ float: right;
+}
+
+.nav-tabs li a {
+ margin-right: 0;
+}
+
+.nav-tabs > .active > a {
+ background: #f5f5f5;
+}
+
+.nav-tabs > .active > a:hover {
+ background: #f5f5f5;
+}
+
+.tabbable.first-tab-active .tab-content
+{
+ border-top-right-radius: 0;
+}
#footer, #push {
height: 60px; /* .push must be the same height as .footer */
diff --git a/rest_framework/static/rest_framework/js/default.js b/rest_framework/static/rest_framework/js/default.js
index ecaccc0f..c74829d7 100644
--- a/rest_framework/static/rest_framework/js/default.js
+++ b/rest_framework/static/rest_framework/js/default.js
@@ -3,3 +3,11 @@ prettyPrint();
$('.js-tooltip').tooltip({
delay: 1000
});
+
+$('a[data-toggle="tab"]:first').on('shown', function (e) {
+ $(e.target).parents('.tabbable').addClass('first-tab-active');
+});
+$('a[data-toggle="tab"]:not(:first)').on('shown', function (e) {
+ $(e.target).parents('.tabbable').removeClass('first-tab-active');
+});
+$('.form-switcher a:first').tab('show');