Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add responsiveness, fixes a few bugs #2

Open
wants to merge 1 commit into
base: release-1.0
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 39 additions & 3 deletions ckanext/surrey/fanstatic_library/css/surrey.css
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,23 @@ font-weight: normal;
width: 450px;
float: right;
margin-right: 15px;
height: 130px;
line-height: 130px;
height: 130px;
line-height: 130px;
display: block;
}
@media only screen and (max-width: 551px){
.intro-text header {
display: none;

}
}
@media only screen and (max-width: 991px){
.intro-text header{
float:none;
width:100%;
height:auto;
}
}
.intro-text header a {
text-decoration: underline;
color: #fff;
Expand All @@ -39,12 +51,29 @@ color: #fff;
.intro-text header p {
display: inline-block;
vertical-align: middle;
line-height: 140%;
line-height: 140%;
}

.intro-image img {
margin-top: 20px;
}

@media only screen and (max-width:991px){
.intro-image img{
margin-top:0px;
padding-top:0px;
}
}

@media only screen and (max-width:551px){
.intro-image img{
width:80%;
margin-top:20px;
margin-left:auto;
margin-right:auto;

}
}
.masonry .media-image, .masonry .media-heading {
display: block;
margin: auto;
Expand Down Expand Up @@ -194,6 +223,13 @@ body {
background: #363636 url("/base/images/bg.png");
}

@media only screen and (max-width:768px) {
.site-footer .row{
margin-left:50px;
}

}

.resource-item {
margin-top: 12px;
margin-bottom: 12px;
Expand Down
12 changes: 4 additions & 8 deletions ckanext/surrey/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,20 +40,16 @@ def dataset_facets(self, facets_dict, package_type):
default_facet_titles = {
'groups': tk._('Categories'),
'tags': tk._('Tags'),
'res_format': tk._('Formats')
'res_format': tk._('Formats'),
#'license_id': tk._('License'),
}
return default_facet_titles

def group_facets(self, facets_dict, group_type, package_type):

default_facet_titles = {
'groups': tk._('Categories'),
'tags': tk._('Tags'),
'res_format': tk._('Formats')
#'license_id': tk._('License'),
}
return default_facet_titles
facets_dict.pop('license_id')
facets_dict.pop('organization')
return facets_dict

class SurreyExtraPagesPlugin(plugins.SingletonPlugin):

Expand Down
2 changes: 1 addition & 1 deletion ckanext/surrey/templates/group/snippets/info.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ <h1 class="heading">{{ group.display_name }}</h1>
</dl>
<dl>
<dt>{{ _('Datasets') }}</dt>
<dd>{{ h.SI_number_span(group.packages|length) }}</dd>
<dd>{{ h.SI_number_span(group.package_count) }}</dd>
</dl>
</div>
<div class="follow_button">
Expand Down
1 change: 0 additions & 1 deletion ckanext/surrey/templates/header.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,4 @@
('follow', _('Subscribe')),
('contact', _('Contact'))
)}}
<li><a href="/pages/city-of-surrey-geospatial-data-disclaimer">Disclaimer</a></li>
{% endblock %}