Skip to content

Commit

Permalink
Merge pull request #184 from ioos/update_new_ckan
Browse files Browse the repository at this point in the history
Fixes for CKAN 2.8.1
  • Loading branch information
benjwadams authored Sep 24, 2018
2 parents 7c29ac8 + dcc8830 commit 9ac809f
Show file tree
Hide file tree
Showing 4 changed files with 119 additions and 14 deletions.
108 changes: 107 additions & 1 deletion ckanext/ioos_theme/public/ioos_theme.css
Original file line number Diff line number Diff line change
Expand Up @@ -305,4 +305,110 @@ html, body {

#feedback:hover{
left:-2px;
}
}

/* pagination needs to be overwritten because the bootstrap 2 CSS appears to be
* used while the bootstrap 3 classes are appear to be used in the HTML
* elements by the Jinja2 classes */

.pagination-wrapper {
text-align: center;
border-top: 1px solid #eeeeee;
padding-top: 10px;
}
.pagination {
display: inline-block;
padding-left: 0;
margin: 20px 0;
border-radius: 4px;
}
.pagination > li {
display: inline;
}
.pagination > li > a,
.pagination > li > span {
position: relative;
float: left;
padding: 6px 12px;
line-height: 1.42857143;
text-decoration: none;
color: #206b82;
background-color: #ffffff;
border: 1px solid #dddddd;
margin-left: -1px;
}
.pagination > li:first-child > a,
.pagination > li:first-child > span {
margin-left: 0;
border-bottom-left-radius: 4px;
border-top-left-radius: 4px;
}
.pagination > li:last-child > a,
.pagination > li:last-child > span {
border-bottom-right-radius: 4px;
border-top-right-radius: 4px;
}
.pagination > li > a:hover,
.pagination > li > span:hover,
.pagination > li > a:focus,
.pagination > li > span:focus {
z-index: 2;
color: #113845;
background-color: #eeeeee;
border-color: #dddddd;
}
.pagination > .active > a,
.pagination > .active > span,
.pagination > .active > a:hover,
.pagination > .active > span:hover,
.pagination > .active > a:focus,
.pagination > .active > span:focus {
z-index: 3;
color: #ffffff;
background-color: #206b82;
border-color: #206b82;
cursor: default;
}
.pagination > .disabled > span,
.pagination > .disabled > span:hover,
.pagination > .disabled > span:focus,
.pagination > .disabled > a,
.pagination > .disabled > a:hover,
.pagination > .disabled > a:focus {
color: #777777;
background-color: #ffffff;
border-color: #dddddd;
cursor: not-allowed;
}
.pagination-lg > li > a,
.pagination-lg > li > span {
padding: 10px 16px;
font-size: 18px;
line-height: 1.3333333;
}
.pagination-lg > li:first-child > a,
.pagination-lg > li:first-child > span {
border-bottom-left-radius: 6px;
border-top-left-radius: 6px;
}
.pagination-lg > li:last-child > a,
.pagination-lg > li:last-child > span {
border-bottom-right-radius: 6px;
border-top-right-radius: 6px;
}
.pagination-sm > li > a,
.pagination-sm > li > span {
padding: 5px 10px;
font-size: 12px;
line-height: 1.5;
}
.pagination-sm > li:first-child > a,
.pagination-sm > li:first-child > span {
border-bottom-left-radius: 3px;
border-top-left-radius: 3px;
}
.pagination-sm > li:last-child > a,
.pagination-sm > li:last-child > span {
border-bottom-right-radius: 3px;
border-top-right-radius: 3px;
}
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,16 @@
{% endblock %}
{% block resource_item_explore %}
<div class="dropdown btn-group">
<a href="#" class="btn btn-primary dropdown-toggle" data-toggle="dropdown">
<i class="icon-share-alt"></i>
<a class="btn btn-primary dropdown-toggle" data-toggle="dropdown">
<i class="fa fa-share"></i>
{{ _('Explore') }}
<span class="caret"></span>
</a>
<ul class="dropdown-menu">
{% block resource_item_explore_links %}
<li>
<a href="{{ h.url_for('harvest_object_show', id=object_reference) }}" class="resource-url-analytics" target="_blank">
<i class="icon-external-link"></i>
<i class="fa fa-external-link"></i>
{{ _('View Content') }}
</a>
</li>
Expand All @@ -30,4 +30,3 @@
</div>
{% endblock %}
</li>

14 changes: 7 additions & 7 deletions ckanext/ioos_theme/templates/package/snippets/resource_item.html
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@
{% block resource_item_explore %}
{% if not url_is_edit %}
<div class="dropdown btn-group">
<a href="#" class="btn btn-primary dropdown-toggle" data-toggle="dropdown">
<i class="icon-share-alt"></i>
<a class="btn btn-primary dropdown-toggle" data-toggle="dropdown">
<i class="fa fa-share"></i>
{{ _('Explore') }}
<span class="caret"></span>
</a>
Expand All @@ -62,10 +62,10 @@
<li>
<a href="{{ url }}">
{% if res.has_views %}
<i class="icon-bar-chart"></i>
<i class="fa fa-bar-chart-o"></i>
{{ _('Preview') }}
{% else %}
<i class="icon-info-sign"></i>
<i class="fa fa-info-circle"></i>
{{ _('More information') }}
{% endif %}
</a>
Expand All @@ -74,10 +74,10 @@
<li>
<a href="{{ res.url }}" class="resource-url-analytics" target="_blank">
{% if res.has_views %}
<i class="icon-download"></i>
<i class="fa fa-arrow-circle-o-down"></i>
{{ _('Download') }}
{% else %}
<i class="icon-external-link"></i>
<i class="fa fa-external-link"></i>
{{ _('Go to resource') }}
{% endif %}
</a>
Expand All @@ -86,7 +86,7 @@
{% if can_edit %}
<li>
<a href="{{ h.url_for(controller='package', action='resource_edit', id=pkg.name, resource_id=res.id) }}">
<i class="icon-edit"></i>
<i class="fa fa-pencil-square-o"></i>
{{ _('Edit') }}
</a>
</li>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
{% endblock %}
{% block resource_item_explore %}
<div class="dropdown btn-group">
<a href="#" class="btn btn-primary dropdown-toggle" data-toggle="dropdown">
<i class="icon-share-alt"></i>
<a class="btn btn-primary dropdown-toggle" data-toggle="dropdown">
<i class="fa fa-share"></i>
{{ _('Explore') }}
<span class="caret"></span>
</a>
Expand Down

0 comments on commit 9ac809f

Please sign in to comment.