Fixes to item embedding in pages. In particular, fixed the editor color changes that were occurring when moving the cursor through embedded items.

This commit is contained in:
Jeremy Goecks
2010-03-16 12:00:10 -04:00
parent e42519ff2b
commit 9786652aa9
6 changed files with 51 additions and 16 deletions
+10 -6
View File
@@ -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;}
+24 -1
View File
@@ -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 {
+9 -3
View File
@@ -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; }
+1 -1
View File
@@ -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/>
+6 -5
View File
@@ -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();
+1
View File
@@ -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", "" )}