UI, history: Remove older history style rules ('historyItem*', etc.) from less and mako files that used them

This commit is contained in:
Carl Eberhard
2015-07-31 15:17:43 -04:00
parent ed29f74147
commit 78d0edf9e0
8 changed files with 91 additions and 210 deletions
-173
View File
@@ -807,179 +807,6 @@
// ---------------------------------------------------------------------------- older styles // ---------------------------------------------------------------------------- older styles
//TODO: these may still apply in mobile display, workflow stuff
body.historyPage {
background: @side-panel-bg;
color: @base-text-color;
margin: 5px;
border: 0;
padding: 0;
}
// Control links at top of history
div.historyLinks {
margin: 5px 5px;
}
// Default history item appearance
div.historyItem {
margin: 0px -5px;
padding: 8px 10px;
border-top: solid @border-default-color 1px;
// border-left: solid @state-queued-border 5px;
border-right: none;
word-wrap: break-word;
background: @state-default-bg;
.state-icon {
display: inline-block;
vertical-align: middle;
width: 16px;
height: 16px;
background-position: 0 1px;
background-repeat: no-repeat;
}
.historyItemTitle {
font-weight: bold;
line-height: 16px;
}
}
.historyItemContainer:last-child div.historyItem {
border-bottom: solid @border-default-color 1px;
}
// Nested history items
div.historyItem div.historyItem {
margin-right: -11px;
}
// Change background/border color depending on state
div.historyItem-ok,
div.historyItem-failed_metadata {
background: @state-success-bg;
.state-icon {
display: none;
}
}
div.historyItem-error {
background: @state-danger-bg;
.state-icon {
.sprite(@data-error);
}
}
div.historyItem-empty {
background: @state-danger-bg;
.state-icon {
.sprite(@data-empty);
}
}
div.historyItem-running {
background: @state-running-bg;
.state-icon {
background-image: url(data_running.gif);
}
}
div.historyItem-setting_metadata {
background: @state-running-bg;
.state-icon {
background-image: url(data_running.gif);
}
}
div.historyItem-upload {
background: @state-info-bg;
.state-icon {
background-image: url(data_upload.gif);
}
}
div.historyItem-queued {
background: @state-default-bg;
.state-icon {
.sprite(@data-queued);
}
}
div.historyItem-noPermission {
filter: alpha(opacity=60);
-moz-opacity: .60;
opacity: .60;
.state-icon {
line-height: 16px;
.fa-icon;
&:before {
content: "\f05e";
}
}
}
div.historyItem-paused {
background: @state-paused-bg;
.state-icon {
line-height: 16px;
.fa-icon;
&:before {
content: "\f04c";
}
}
}
div.historyItem-new {
.state-icon {
line-height: 16px;
.fa-icon;
&:before {
content: "\f071";
}
}
}
// Special case for showing the spinner but not changing the background
div.historyItemTitleBar.spinner .state-icon {
background: url(data_running.gif) 0 1px no-repeat !important;
}
// Buttons
div.historyItemButtons {
float: right;
.icon-button.display {
.sprite(@eye-icon);
}
.icon-button.display:hover {
.sprite(@eye-icon-dark);
}
.icon-button.display_disabled {
.sprite(@eye-icon-grey);
}
.icon-button.delete {
.sprite(@delete-icon);
}
.icon-button.delete:hover {
.sprite(@delete-icon-dark);
}
.icon-button.delete_disabled {
.sprite(@delete-icon-grey);
}
.icon-button.edit {
.sprite(@pencil-icon);
}
.icon-button.edit:hover {
.sprite(@pencil-icon-dark);
}
.icon-button.edit_disabled {
.sprite(@pencil-icon-grey);
}
}
div.historyItemBody div {
padding-top: 2px;
}
pre.peek { pre.peek {
background: white; background: white;
color: black; color: black;
File diff suppressed because one or more lines are too long
+2 -8
View File
@@ -70,8 +70,8 @@
border-top: 4px solid #DDDDDD; border-top: 4px solid #DDDDDD;
} }
## Make sure that history items and workflow steps do not get too long. ## Make sure that workflow steps do not get too long.
.historyItemContainer, .toolForm { .toolForm {
max-width: 500px; max-width: 500px;
} }
@@ -81,12 +81,6 @@
margin-bottom: 10px; margin-bottom: 10px;
} }
## Add border to history item container.
.historyItemContainer {
padding-right: 3px;
border-right-style: solid;
border-right-color: #66AA66;
}
</style> </style>
</%def> </%def>
+22 -1
View File
@@ -13,6 +13,27 @@
<%def name="stylesheets()"> <%def name="stylesheets()">
${parent.stylesheets()} ${parent.stylesheets()}
<style> <style>
div.historyItem {
margin: 0px -5px;
padding: 8px 10px;
border-top: solid #999 1px;
border-right: none;
word-wrap: break-word;
background: @state-default-bg;
}
div.historyItem .state-icon {
display: inline-block;
vertical-align: middle;
width: 16px;
height: 16px;
background-position: 0 1px;
background-repeat: no-repeat;
}
div.historyItem .historyItemTitle {
font-weight: bold;
line-height: 16px;
}
.searchResult { .searchResult {
border-style:dashed; border-style:dashed;
border-width:1px; border-width:1px;
@@ -55,7 +76,7 @@
success : function(data) { success : function(data) {
var p = $("#output"); var p = $("#output");
p.empty(); p.empty();
_.each(data.results, function(doc){ _.each(data.results, search_format_output
var div_class = "historyItem"; var div_class = "historyItem";
var a = $("<div class='" + div_class + "'>") var a = $("<div class='" + div_class + "'>")
a.append($("<div>").append(doc['model_class'])); a.append($("<div>").append(doc['model_class']));
@@ -28,6 +28,15 @@
${parent.javascripts()} ${parent.javascripts()}
</%def> </%def>
<%def name="stylesheets()">
${parent.stylesheets()}
<style>
.ldda-peek {
padding-top: 2px;
}
</style>
</%def>
%if current_version: %if current_version:
<b><i>This is the latest version of this library dataset</i></b> <b><i>This is the latest version of this library dataset</i></b>
%else: %else:
@@ -168,7 +177,7 @@
%endfor %endfor
%if ldda.peek != "no peek": %if ldda.peek != "no peek":
<div class="form-row"> <div class="form-row">
<div id="info${ trans.security.encode_id( ldda.id ) | h}" class="historyItemBody"> <div id="info${ trans.security.encode_id( ldda.id ) | h}" class="ldda-peek">
<label>Peek:</label> <label>Peek:</label>
<div><pre id="peek${ trans.security.encode_id( ldda.id ) | h}" class="peek">${util.unicodify( ldda.display_peek() )}</pre></div> <div><pre id="peek${ trans.security.encode_id( ldda.id ) | h}" class="peek">${util.unicodify( ldda.display_peek() )}</pre></div>
</div> </div>
@@ -2,6 +2,16 @@
<%namespace file="/message.mako" import="render_msg" /> <%namespace file="/message.mako" import="render_msg" />
<%namespace file="/dataset/security_common.mako" import="render_permission_form" /> <%namespace file="/dataset/security_common.mako" import="render_permission_form" />
<%def name="stylesheets()">
${parent.stylesheets()}
<style>
.ldda-title {
font-weight: bold;
line-height: 16px;
}
</style>
</%def>
<% <%
if len( lddas ) > 1: if len( lddas ) > 1:
name_str = '%d selected datasets' % len( lddas ) name_str = '%d selected datasets' % len( lddas )
@@ -27,7 +37,7 @@
<tr> <tr>
<td> <td>
<div class="rowTitle"> <div class="rowTitle">
<span class="historyItemTitle"><b>${ldd_assoc.name | h}</b></span> <span class="ldda-title"><b>${ldd_assoc.name | h}</b></span>
<a id="ldda-${ldd_assoc.id | h}-popup" class="popup-arrow" style="display: none;">&#9660;</a> <a id="ldda-${ldd_assoc.id | h}-popup" class="popup-arrow" style="display: none;">&#9660;</a>
</div> </div>
<div popupmenu="ldd_assoc-${ldd_assoc.id | h}-popup"> <div popupmenu="ldd_assoc-${ldd_assoc.id | h}-popup">
@@ -5,6 +5,20 @@
${ _( 'Galaxy History' ) } ${ _( 'Galaxy History' ) }
</%def> </%def>
<%def name="stylesheets()">
${ parent.stylesheets() }
<style>
.historyPage {
background: #DFE5F9;
color: #333;
margin: 5px;
border: 0;
padding: 0;
}
</style>
</%def>
## ----------------------------------------------------------------------------- ## -----------------------------------------------------------------------------
<%def name="javascripts()"> <%def name="javascripts()">
${ parent.javascripts() } ${ parent.javascripts() }
@@ -12,8 +12,14 @@
margin-top: 10px; margin-top: 10px;
margin-bottom: 10px; margin-bottom: 10px;
} }
div.historyItem { .list-item.dataset.history-content {
margin-right: 0; padding: 8px 10px;
}
.list-item.dataset.history-content .title-bar {
cursor: auto;
}
input[type="checkbox"].as-input {
margin-left: 8px;
} }
th { th {
border-bottom: solid black 1px; border-bottom: solid black 1px;
@@ -43,26 +49,26 @@
%else: %else:
<% data_state = data.state %> <% data_state = data.state %>
%endif %endif
<div class="historyItemWrapper historyItem historyItem-${data_state}" id="historyItem-$data.id"> <% encoded_id = trans.app.security.encode_id( data.id ) %>
<table cellpadding="0" cellspacing="0" border="0" width="100%"> <table cellpadding="0" cellspacing="0" border="0" width="100%">
<tr> <tr>
%if data_state != 'ok': <td>
<td style="width: 20px;"> <div class="list-item dataset history-content state-${ data.state }" id="dataset-${ encoded_id }">
<div style='padding-right: 5px;'><img src="${h.url_for( str( '/static/style/data_%s.png' % data_state ) )}" border="0" align="middle"></div> <div class="title-bar clear">
</td> <div class="title">
%endif <span class="hid">${data.hid}</span>
<td> <span class="name">${data.display_name()}</span>
<div style="overflow: hidden;"> </div>
<span class="historyItemTitle"><b>${data.hid}: ${data.display_name()}</b></span>
</div> </div>
</td> %if disabled:
</tr> <input type="checkbox" id="as-input-${ encoded_id }" class="as-input"
</table> name="${data.history_content_type}_ids" value="${data.hid}" checked="true" />
%if disabled: <label for="as-input-${ encoded_id }" >${_('Treat as input dataset')}</label>
<hr> %endif
<div><input type="checkbox" name="${data.history_content_type}_ids" value="${data.hid}" checked="true" />${_('Treat as input dataset')}</div> </div>
%endif </td>
</div> </tr>
</table>
</%def> </%def>
<p>The following list contains each tool that was run to create the <p>The following list contains each tool that was run to create the
@@ -88,7 +94,7 @@ into a workflow will be shown in gray.</p>
</p> </p>
<table border="0" cellspacing="0"> <table border="0" cellspacing="0">
<tr> <tr>
<th style="width: 47.5%">${_('Tool')}</th> <th style="width: 47.5%">${_('Tool')}</th>
<th style="width: 5%"></th> <th style="width: 5%"></th>
@@ -104,7 +110,7 @@ into a workflow will be shown in gray.</p>
cls += " toolFormDisabled" cls += " toolFormDisabled"
disabled = True disabled = True
tool_name = getattr( job, 'name', tool_name ) tool_name = getattr( job, 'name', tool_name )
else: else:
tool = app.toolbox.get_tool( job.tool_id ) tool = app.toolbox.get_tool( job.tool_id )
if tool: if tool:
tool_name = tool.name tool_name = tool.name
@@ -120,7 +126,7 @@ into a workflow will be shown in gray.</p>
if disabled: if disabled:
disabled_why = getattr( job, 'disabled_why', "This tool cannot be used in workflows" ) disabled_why = getattr( job, 'disabled_why', "This tool cannot be used in workflows" )
%> %>
<tr> <tr>
<td> <td>
<div class="${cls}"> <div class="${cls}">
@@ -143,7 +149,7 @@ into a workflow will be shown in gray.</p>
</td> </td>
<td> <td>
%for _, data in datasets: %for _, data in datasets:
<div>${history_item( data, disabled )}</div> <div>${history_item( data, disabled )}</div>
%endfor %endfor
</td> </td>
</tr> </tr>