[ckan-changes] commit/ckan: rgrp: [css, js][s]: (refs #1294) hide fieldsets on add dataset using css rather than js to avoid 'flash' as js hides it.

Bitbucket commits-noreply at bitbucket.org
Wed Sep 14 19:37:23 UTC 2011


1 new changeset in ckan:

http://bitbucket.org/okfn/ckan/changeset/b3bdd5807837/
changeset:   b3bdd5807837
user:        rgrp
date:        2011-09-14 21:37:15
summary:     [css,js][s]: (refs #1294) hide fieldsets on add dataset using css rather than js to avoid 'flash' as js hides it.
affected #:  2 files (413 bytes)

--- a/ckan/public/css/style.css	Wed Sep 14 19:16:25 2011 +0100
+++ b/ckan/public/css/style.css	Wed Sep 14 20:37:15 2011 +0100
@@ -704,6 +704,10 @@
 /* = Edit Dataset Page = */
 /* ===================== */
 
+body.package.edit .edit-summary {
+  display: none;
+}
+
 body.edit.package div#content {
   margin-right: 0px;
 }
@@ -803,6 +807,19 @@
 /* = Add Dataset Page = */
 /* ==================== */
 
+/* do this here to avoid js flash when we hide in js */
+body.package.new form fieldset {
+  display: none;
+}
+
+body.package.new form fieldset#basic-information {
+  display: block;
+}
+
+body.package.new .edit-summary {
+  display: none;
+}
+
 body.package.new dt.homepage-label,
 body.package.new dd.homepage-field,
 body.package.new dd.homepage-instructions 


--- a/ckan/public/scripts/application.js	Wed Sep 14 19:16:25 2011 +0100
+++ b/ckan/public/scripts/application.js	Wed Sep 14 20:37:15 2011 +0100
@@ -20,9 +20,6 @@
 
     var isDatasetNew = $('body.package.new').length > 0;
     if (isDatasetNew) {
-      $('#content fieldset').hide();
-      $('#content fieldset#basic-information').show();
-      $('.edit-summary').hide();
       $('#save').val("Add Dataset")
     }

Repository URL: https://bitbucket.org/okfn/ckan/

--

This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.




More information about the ckan-changes mailing list