details:
http://www.bx.psu.edu/hg/galaxy/rev/d776beca95f8
changeset: 3536:d776beca95f8
user: jeremy goecks <jeremy.goecks(a)emory.edu>
date: Tue Mar 16 12:00:10 2010 -0400
description:
Fixes to item embedding in pages. In particular, fixed the editor color changes that were
occurring when moving the cursor through embedded items.
diffstat:
static/june_2007_style/blue/embed_item.css | 16 ++++++++++------
static/june_2007_style/embed_item.css.tmpl | 25 ++++++++++++++++++++++++-
static/wymeditor/iframe/galaxy/wymiframe.css | 12 +++++++++---
templates/embed_base.mako | 2 +-
templates/page/editor.mako | 11 ++++++-----
templates/workflow/embed.mako | 1 +
6 files changed, 51 insertions(+), 16 deletions(-)
diffs (177 lines):
diff -r 15fd40238cef -r d776beca95f8 static/june_2007_style/blue/embed_item.css
--- a/static/june_2007_style/blue/embed_item.css Tue Mar 16 09:50:13 2010 -0400
+++ b/static/june_2007_style/blue/embed_item.css Tue Mar 16 12:00:10 2010 -0400
@@ -1,10 +1,14 @@
-.embedded-item{margin-left:auto;margin-right:auto;width:90%;padding:
0.5em;-moz-border-radius:0.5em;-webkit-border-radius:0.5em;border-radius:0.5em;}
-.embedded-item.history{background-color:#C1C9E5}
-.embedded-item.dataset{background-color:#CFC}
-.embedded-item.workflow{background-color:#EBD9B2}
+.embedded-item{margin-left:auto;margin-right:auto;width:90%;-moz-border-radius:0.5em;-webkit-border-radius:0.5em;border-radius:0.5em;}
+.embedded-item.display {padding: 0.5em;}
+.embedded-item.history{background-color:#C1C9E5}
+.embedded-item.history p{background:#C1C9E5 no-repeat 2px
2px;margin-top:0;margin-bottom:0;}
+.embedded-item.dataset{background-color:#CFC}
+.embedded-item.dataset p{background:#CFC no-repeat 2px
2px;margin-top:0;margin-bottom:0;}
+.embedded-item.workflow{background-color:#EBD9B2}
+.embedded-item.workflow p{background:#EBD9B2 no-repeat 2px
2px;margin-top:0;margin-bottom:0;}
.embedded-item.placeholder{}
-.embedded-item .item-content{max-height:25em;overflow:auto;}
-.embedded-item .title{vertical-align:top;text-align:center;}
+.embedded-item .item-content{max-height:25em;overflow:auto;display:none;}
+.embedded-item .title{vertical-align:top;text-align:center;font-weight:bold;}
.embedded-item.placeholder .content{padding: 1em
1em;font-style:italic;text-align:center;}
table.annotated-item{width:100%;border-collapse:collapse;}
table.annotated-item td,th{padding:0;}
diff -r 15fd40238cef -r d776beca95f8 static/june_2007_style/embed_item.css.tmpl
--- a/static/june_2007_style/embed_item.css.tmpl Tue Mar 16 09:50:13 2010 -0400
+++ b/static/june_2007_style/embed_item.css.tmpl Tue Mar 16 12:00:10 2010 -0400
@@ -1,35 +1,58 @@
+
.embedded-item {
margin-left:auto;
margin-right:auto;
width:90%;
- padding: 0.5em;
-moz-border-radius:0.5em;
-webkit-border-radius:0.5em;
border-radius:0.5em;
}
+.embedded-item.display {
+ padding: 0.5em;
+}
+
.embedded-item.history {
background-color:#C1C9E5
}
+.embedded-item.history p {
+ background:#C1C9E5 no-repeat 2px 2px;
+ margin-top:0;
+ margin-bottom:0;
+}
+
.embedded-item.dataset {
background-color:#CFC
}
+.embedded-item.dataset p {
+ background:#CFC no-repeat 2px 2px;
+ margin-top:0;margin-bottom:0;
+}
+
.embedded-item.workflow {
background-color:#EBD9B2
}
+.embedded-item.workflow p {
+ background:#EBD9B2 no-repeat 2px 2px;
+ margin-top:0;
+ margin-bottom:0;
+}
+
.embedded-item.placeholder{}
.embedded-item .item-content {
max-height: 25em;
overflow: auto;
+ display: none;
}
.embedded-item .title {
vertical-align:top;
text-align:center;
+ font-weight: bold;
}
.embedded-item.placeholder .content {
diff -r 15fd40238cef -r d776beca95f8 static/wymeditor/iframe/galaxy/wymiframe.css
--- a/static/wymeditor/iframe/galaxy/wymiframe.css Tue Mar 16 09:50:13 2010 -0400
+++ b/static/wymeditor/iframe/galaxy/wymiframe.css Tue Mar 16 12:00:10 2010 -0400
@@ -1,3 +1,7 @@
+/*
+ * JG: edited to remove '!important' from rules so that embedded Galaxy items can
have unique background colors.
+ */
+
/*
* WYMeditor : what you see is What You Mean web-based editor
* Copyright (c) 2005 - 2009 Jean-Francois Hovinne,
http://www.wymeditor.org/
@@ -33,9 +37,9 @@
ol,
table,
blockquote,
- pre { background: #FFFFFF no-repeat 2px 2px !important;
- padding:8px 5px 5px !important;
- margin:10px !important; }
+ pre { background: #FFFFFF no-repeat 2px 2px; /* JG removed: !important */
+ padding:8px 5px 5px; /* JG removed: !important */
+ margin:10px} /* JG removed: !important */
td { background: #F0F4F8; }
th { background: #ffffcc; }
ul,
@@ -52,6 +56,7 @@
td { height: 1.6em; }
/* labels */
+/* JG commented out:
p { background-image: url(lbl-p.png); }
h1 { background-image: url(lbl-h1.png); }
h2 { background-image: url(lbl-h2.png); }
@@ -61,6 +66,7 @@
h6 { background-image: url(lbl-h6.png); }
blockquote{ background-image: url(lbl-blockquote.png); }
pre { background-image: url(lbl-pre.png); }
+*/
/* specific HTML elements */
caption { text-align: left; }
diff -r 15fd40238cef -r d776beca95f8 templates/embed_base.mako
--- a/templates/embed_base.mako Tue Mar 16 09:50:13 2010 -0400
+++ b/templates/embed_base.mako Tue Mar 16 12:00:10 2010 -0400
@@ -6,7 +6,7 @@
<%namespace file="/display_common.mako" import="*" />
## HTML structure.
-<div class='embedded-item ${get_class_display_name( item.__class__
).lower()}'>
+<div class='embedded-item display ${get_class_display_name( item.__class__
).lower()}'>
<div class='title'>
${self.render_title( item )}
<hr/>
diff -r 15fd40238cef -r d776beca95f8 templates/page/editor.mako
--- a/templates/page/editor.mako Tue Mar 16 09:50:13 2010 -0400
+++ b/templates/page/editor.mako Tue Mar 16 12:00:10 2010 -0400
@@ -459,17 +459,18 @@
// all non-standard attributes when it returns its
content (e.g. it will not return an element attribute of the form
// item_class='History').
var item_embed_html =
- "<p> \
+ "\
<div id='" + item_info.iclass +
"-" + item_id + "' class='embedded-item " +
item_info.singular.toLowerCase() +
" placeholder'> \
- <div class='title'> Embedded
Galaxy " + item_info.singular + " '" + item_name +
"'</div> \
- <div class='content'> \
+ <p class='title'>Embedded
Galaxy " + item_info.singular + " '" + item_name +
"'</p> \
+ <p class='content'> \
[Do not edit this block; Galaxy will fill
it in with the annotated " +
item_info.singular.toLowerCase() + "
when it is displayed.]</div> \
- </div> \
- </div></p>";
+ </p> \
+ </div><p></p>";
// Insert embedded representation into document.
+ // TODO: maybe try replace() instead to handle
indenting?
wym.insert(item_embed_html);
});
hide_modal();
diff -r 15fd40238cef -r d776beca95f8 templates/workflow/embed.mako
--- a/templates/workflow/embed.mako Tue Mar 16 09:50:13 2010 -0400
+++ b/templates/workflow/embed.mako Tue Mar 16 12:00:10 2010 -0400
@@ -4,6 +4,7 @@
%>
<%def name="render_summary_content( workflow, steps )">
+
## <ul>
## <% num_steps = len ( steps ) %>
## <li>${num_steps} step${iff( num_steps != 1, "s", ""
)}