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

Fix menu state #331

Draft
wants to merge 69 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
69 commits
Select commit Hold shift + click to select a range
c6844a1
remove next page from page tools
smth Apr 24, 2015
89a4a4b
analytics
smth Apr 27, 2015
7103a8f
heading links
smth Jun 8, 2015
0764876
homepage text in single row
smth Apr 27, 2015
cad1b21
Prevent FOUC in menu
smth Apr 28, 2015
6cfbe56
Prevent FOUC in menu - only when js detected
smth Apr 28, 2015
d84ab52
small screen tweaks
smth Apr 28, 2015
415b06b
tidy homepgae layout
smth Apr 29, 2015
bf29592
heading link styling
smth Apr 16, 2015
ef60641
prep for ok panel
smth Apr 30, 2015
e33f839
equalise home columns
smth May 6, 2015
490baee
less padding on home page paragraphs
smth May 6, 2015
950cc7d
pre header
smth May 6, 2015
d06fd8e
pre-heading tweak
smth May 6, 2015
b4f357f
Merge branch 'gh-pages'
smth Jun 9, 2015
a3fff49
removed lots of content
smth Jun 9, 2015
2748402
branches readme
smth Jun 9, 2015
bd6edc8
remove cname
smth Jun 9, 2015
d8f56c8
remove duplicate config
smth Jun 10, 2015
4511447
home heading variable
smth Jun 10, 2015
107ece2
give banner images generic names
smth Jun 10, 2015
365e54e
remove ok-ribbon image
smth Jun 10, 2015
578f6bc
use remote ok ribbon
smth Jun 10, 2015
6bd3066
remove ok panel js
smth Jun 10, 2015
95b4639
move related projects to config
smth Jun 11, 2015
69a01e6
configurable lead paragraph
smth Jun 11, 2015
1cd560b
and theme to list of branches
smth Jun 11, 2015
6e691b4
whitespace
smth Nov 26, 2015
12856a8
add problems to solutions
smth Nov 26, 2015
bad4eab
Example problem usage
smth Nov 26, 2015
0d45240
don't break if no tags
smth Nov 26, 2015
1ef3e1b
Create The-Intersection-of-Ride-sharing-and-Public-Transit
morchickit Dec 6, 2015
24ff809
Delete The-Intersection-of-Ride-sharing-and-Public-Transit
morchickit Dec 6, 2015
4b83262
Create index.md
morchickit Dec 6, 2015
2af9d29
Update index.md
morchickit Dec 6, 2015
fb13ba5
Create index.md
morchickit Dec 6, 2015
aba1b73
Delete index.md
morchickit Dec 7, 2015
a4d6f49
Delete index.md
morchickit Dec 7, 2015
1eaf404
add solution
smth Dec 7, 2015
5cce5e4
whitespace
smth Dec 7, 2015
cf0d47a
fix breaking page when no app image
smth Dec 7, 2015
795dd18
white space
smth Dec 15, 2015
ab11e31
add solutions back link
smth Dec 15, 2015
187a7ab
whitespace
smth Dec 16, 2015
f269a4e
update credit links
smth Dec 16, 2015
134b760
Add OD4D logo. Closes #233
smth Dec 16, 2015
c122285
whitespace
smth Dec 16, 2015
e2e5272
google-site-verification
smth Dec 16, 2015
6a66eb8
replace solution
smth Jan 4, 2016
d58ef72
whitespace
smth Jan 4, 2016
ba43019
data used in box
smth Jan 4, 2016
8e36c6d
add gemfile
smth May 9, 2016
31a866c
OKI logos
smth May 10, 2016
f108555
replace missing opening div
smth May 10, 2016
73ae40d
ribbon position fix
smth May 19, 2016
11d3ea2
less specific ribbon position fix
smth May 20, 2016
d4cefbd
new OK Panel markup
smth May 20, 2016
bdd52b3
hashchange WIP
smth Aug 15, 2016
7a7cd2c
hashchange working
smth Aug 15, 2016
6057b48
remove parentheses from solutions filters
smth Aug 15, 2016
5f9c642
add missing overviews code
smth Aug 15, 2016
16ca0d6
replace ampersand in filters
smth Aug 15, 2016
a0a6810
add solutions banner
smth Aug 16, 2016
a45fad0
grid bg colour
smth Aug 16, 2016
c21b112
app image bg position
smth Aug 16, 2016
3a41791
banner info link
smth Aug 17, 2016
ed95c76
replace Google analytics code with consent code
smth May 21, 2018
bd25b0e
use assets URL
smth May 21, 2018
8634575
fix unintentionally collapsed menu
smth May 22, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 0 additions & 1 deletion CNAME

This file was deleted.

3 changes: 3 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
source "https://rubygems.org"

gem 'jekyll-redirect-from', '~> 0.10.0'
41 changes: 41 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
GEM
remote: https://rubygems.org/
specs:
colorator (0.1)
ffi (1.9.10)
jekyll (3.1.3)
colorator (~> 0.1)
jekyll-sass-converter (~> 1.0)
jekyll-watch (~> 1.1)
kramdown (~> 1.3)
liquid (~> 3.0)
mercenary (~> 0.3.3)
rouge (~> 1.7)
safe_yaml (~> 1.0)
jekyll-redirect-from (0.10.0)
jekyll (>= 2.0)
jekyll-sass-converter (1.4.0)
sass (~> 3.4)
jekyll-watch (1.4.0)
listen (~> 3.0, < 3.1)
kramdown (1.11.1)
liquid (3.0.6)
listen (3.0.7)
rb-fsevent (>= 0.9.3)
rb-inotify (>= 0.9.7)
mercenary (0.3.6)
rb-fsevent (0.9.7)
rb-inotify (0.9.7)
ffi (>= 0.5.0)
rouge (1.10.1)
safe_yaml (1.0.4)
sass (3.4.22)

PLATFORMS
ruby

DEPENDENCIES
jekyll-redirect-from (~> 0.10.0)

BUNDLED WITH
1.12.3
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,10 @@ Currently, the English glossary has been organized. To expand this pattern to ot
* Copy the English terms directory into your target language directory
* If your current index.md has translated glossary terms, then add them to the appropriate page under 'terms', replacing the English text that was copied over from 'en'.
* Then, replace your target language's index.md file with the 'en' one, changing the `lang` value to that of your target language.

### Branches

- **gh-pages** - live site
- **master** - minimal content, to speed up building (for development)
- **theme** - no site specific content, used to create new sites

35 changes: 32 additions & 3 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: The Open Data Handbook
short_title: Open Data Handbook
description: |
Guides, case studies and resources for government & civil society
Guides, case studies and resources for government & civil society
on the “what, why & how” of open data.
baseurl: ""
url: "http://opendatahandbook.org" # the base hostname & protocol for your site
Expand All @@ -17,7 +17,7 @@ gems:
devs:
-
name: Sam Smith
github: mintcanary
github: smth
-
name: Rufus Pollock
github: rgrp
Expand Down Expand Up @@ -49,7 +49,7 @@ contributors:
link: http://www.zylstra.org/blog/
-
name: Sam Smith
link: http://samsmith.name/
link: http://smth.uk/

supporters:
-
Expand All @@ -62,9 +62,15 @@ supporters:
logo: worldbank.png
footer_logo: worldbank-footer.png
url: http://www.worldbank.org/
-
name: OD4D
logo: od4d.png
footer_logo: od4d-footer.png
url: http://od4d.net/


googleanalytics: UA-8271754-28
google_verification: U6RmQ0BoQ9f1Omog3Mnas-Yd1At38pTDZbM1AtnOpnc

# Build settings
markdown: kramdown
Expand Down Expand Up @@ -275,3 +281,26 @@ defaults:
values:
layout: page
edit: true

related_projects:
-
name: OpenGovernmentData.org
link: http://opengovernmentdata.org/
-
name: The DataHub
link: http://datahub.io/
-
name: DataCatalogs.org
link: http://datacatalogs.org/
-
name: OpenSpending.org
link: http://openspending.org/
-
name: SchoolOfData.org
link: http://schoolofdata.org/
-
name: OpenDefinition.org
link: http://opendefinition.org/
-
name: Introducing Open Data
link: http://okfn.org/opendata/
13 changes: 13 additions & 0 deletions _data/problems.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
- problem: Gentrification
p_overview: |
Gentrification, or the rampant increase in property value of lower and lower-middle class neighborhoods, is widespread throughout the United States and the rest of the developing world. The increased valuation of property is not in itself what causes displacement, but rather the drastic increase in property taxes that accompanies it.

It is difficult to fully realize the systematic nature with which this displacement is occurring without a birdseye of the view of the phenomena. Gentrification is diffuse and on individual level basis hard to identify and thus difficult to create an awareness and advocacy campaigns.

In short, every awareness and advocacy needs a medium and way to construct a message that is accessible and impactful to the non-expert concerned citizen before any substantive change can occur.

- problem: Incarceration Rates
p_overview: |
Incarceration in the United States is an 80 billion dollar a year business. It has some of the most lengthy sentences and highest per capita prisoner ratios in the world. America’s prison system is driven by profit and not by rehabilitation and public welfare.

Those in prison are a voiceless population, whose inability to capture the public’s attention is reinforced by their low socio-economic and non-white status.
22 changes: 10 additions & 12 deletions _includes/footer.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

<div>
<div class="primary">
<a href="https://okfn.org/" rel="external"><img src="{{ "/img/open-knowledge.png" | prepend: site.baseurl }}" width="145" height="32" alt="Open Knowledge"></a>
<a href="https://okfn.org/" rel="external"><img src="//a.okfn.org/img/oki/landscape-grey-468x122.png" width="123" height="32" alt="Open Knowledge International"></a>

{% if site.supporters %}
<div class="supporters">
<h6>Supported by</h6>
Expand All @@ -15,7 +15,7 @@ <h6>Supported by</h6>
</div>
{% endif %}
</div>

<div class="secondary">
<ul>
<li><a href="{{ site.baseurl }}/contribute/">Contribute</a></li>
Expand All @@ -24,20 +24,18 @@ <h6>Supported by</h6>
<li class="button"><a href="http://opendefinition.org/" rel="external"><img src="{{ site.baseurl }}/img/open-content.svg" width="80" height="15" alt="Open Content"/></a></li>
</ul>
</div>

<div class="tertiary">
{% if site.related_projects %}
<div>
<h6>Related Projects</h6>
<ul>
<li><a href="http://opengovernmentdata.org/">OpenGovernmentData.org</a></li>
<li><a href="http://datahub.io/">The DataHub</a></li>
<li><a href="http://datacatalogs.org/">DataCatalogs.org</a></li>
<li><a href="http://openspending.org/">OpenSpending.org</a></li>
<li><a href="http://schoolofdata.org/">SchoolOfData.org</a></li>
<li><a href="http://opendefinition.org/" title="defining open data">OpenDefinition.org</a></li>
<li><a href="http://okfn.org/opendata/" title="introduction to open data">Introducing Open Data</a></li>
{% for project in site.related_projects %}
<li><a href="{{ project.link }}">{{ project.name }}</a></li>
{% endfor %}
</ul>
</div>
{% endif %}
<ul class="icons">
{% if site.paypal %}
<li class="donate"><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business={{ site.paypal }}&lc=GB&item_name={{ site.short_title }}%20Donation%20to%20Open%20Knowledge&no_note=0&currency_code=USD&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHostedGuest" rel="external"><span>Donate</span></a></li>
Expand All @@ -50,6 +48,6 @@ <h6>Related Projects</h6>
{% endif %}
</ul>
</div>

</div>
</footer>
20 changes: 16 additions & 4 deletions _includes/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,32 @@
<title>{% if page.title %}{{ page.title }}{% else %}{{ site.title }}{% endif %}</title>
<meta name="description" content="{{ site.description }}">
<meta name="viewport" content="width=device-width, initial-scale=1">
{% if site.google_verification %}
<meta name="google-site-verification" content="{{ site.google_verification }}" />
{% endif %}

<link rel="apple-touch-icon" href="apple-touch-icon.png">
<!-- Place favicon.ico in the root directory -->
<link rel="stylesheet" href="//cdn.rawgit.com/okfn/ok-panel/v1.0.0/assets/css/frontend.css">

<link rel="stylesheet" href="//a.okfn.org/html/oki/panel/assets/css/frontend.css">

<link rel="stylesheet" href="{{ "/css/main.css" | prepend: site.baseurl }}">
{% if page.wide %}
{% if page.wide != "false" and layout.wide != "false" %}
<link rel="stylesheet" href="{{ "/css/widescreen.css" | prepend: site.baseurl }}" media="all and (min-width: 1280px)">
{% endif %}
<link href='http://fonts.googleapis.com/css?family=Lato:100,300,400,700,900,100italic,300italic,400italic,700italic,900italic' rel='stylesheet' type='text/css'>

<link href='http://fonts.googleapis.com/css?family=Lora:400,700,400italic,700italic' rel='stylesheet' type='text/css'>

<link rel="canonical" href="{{ page.url | replace:'index.html','' | prepend: site.baseurl | prepend: site.url }}">
<script src="{{ "/js/vendor/modernizr-2.8.3.min.js" | prepend: site.baseurl }}"></script>

{% if site.googleanalytics %}
<script>
var okiConsent = {
analyticsTrackingID: '{{ site.googleanalytics }}'
}
</script>
<script src="https://a.okfn.org/html/oki/consent/assets/js/consent.js"></script>
{% endif %}
</head>
113 changes: 73 additions & 40 deletions _includes/header.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
{% assign glossary = site.meta.glossary %}
{% assign value-stories = site.meta.value-stories %}
{% assign resources = site.meta.resources %}
{% assign contribute = site.meta.contribute %}
{% assign guide_entry_point = site.baseurl | append: '/' | append: guide.label | append: '/' | append: page.lang | append: '/' | append: guide.toc.entry_point | append: '/' %}
{% assign glossary_entry_point = site.baseurl | append: '/' | append: glossary.label | append: '/' | append: page.lang | append: '/' %}
{% assign value-stories_entry_point = site.baseurl | append: '/' | append: value-stories.label | append: '/' | append: page.lang | append: '/' %}
Expand Down Expand Up @@ -129,64 +130,96 @@

</li>
<!-- end navigation for resources section -->

<!-- start navigation for apps section -->
<li class="apps-menu{% if page.url contains 'solutions' %} Selected{% endif %}">
<a href="{{ apps_entry_point }}">Solutions</a>
<ul class="app-sub-menu">
<li class="search">
<input type="search" placeholder="Search" class="quicksearch">
</li>
{% capture appthemes %}{% for page in site.pages %}{% if page.section == 'solutions' %}{{ page.themes }},{% endif %}{% endfor %}{% endcapture %}
{% assign appthemesArray = appthemes | split: "," %}
{% assign appthemeslist = appthemesArray[1] %}
{% for at in appthemesArray %}
{% unless appthemeslist contains at %}
{% capture appthemeslist %}{{ appthemeslist }}@@{{ at }}{% endcapture %}
{% endunless %}
{% endfor %}
{% assign appthemessorted = appthemeslist | split: '@@' | sort %}
{% capture appproblems %}{% for page in site.pages %}{% if page.section == 'solutions' %}{% if page.problem %}{{ page.problem }},{% endif %}{% endif %}{% endfor %}{% endcapture %}
{% if appproblems != '' %}
{% assign appproblemsArray = appproblems | split: "," %}
{% assign appproblemslist = appproblemsArray[1] %}
{% for at in appproblemsArray %}
{% unless appproblemslist contains at %}
{% capture appproblemslist %}{{ appproblemslist }}@@{{ at }}{% endcapture %}
{% endunless %}
{% endfor %}
{% assign appproblemssorted = appproblemslist | split: '@@' | sort %}

<li class="problems filter active">
<a>Problems</a>
<span class="filter-items">
{% for appproblem in appproblemssorted %}
<a data-filter=".selector-problem-{{ appproblem | downcase | replace:' ','' | replace:'(','' | replace:')','' | replace:'&','and'}}" data-pid=".problem-{{ appproblem | downcase | replace:' ','' | replace:'(','' | replace:')','' | replace:'&','and'}}">{{ appproblem }}</a>
{% endfor %}
</span>
</li>
{% endif %}

<li class="filter">
<a>Themes</a>
<span class="filter-items">
{% for apptheme in appthemessorted %}
<a data-filter=".selector-theme-{{ apptheme | downcase | replace:' ','' }}">{{ apptheme }}</a>
{% capture appthemes %}{% for page in site.pages %}{% if page.section == 'solutions' %}{% if page.themes %}{{ page.themes }},{% endif %}{% endif %}{% endfor %}{% endcapture %}
{% if appthemes != '' %}
{% assign appthemesArray = appthemes | split: "," %}
{% assign appthemeslist = appthemesArray[1] %}
{% for at in appthemesArray %}
{% unless appthemeslist contains at %}
{% capture appthemeslist %}{{ appthemeslist }}@@{{ at }}{% endcapture %}
{% endunless %}
{% endfor %}
</span>
</li>

{% capture apptags %}{% for page in site.pages %}{% if page.section == 'solutions' %}{{ page.tags }},{% endif %}{% endfor %}{% endcapture %}
{% assign apptagsArray = apptags | split: "," %}
{% assign apptagslist = apptagsArray[1] %}
{% for at in apptagsArray %}
{% unless apptagslist contains at %}
{% capture apptagslist %}{{ apptagslist }}@@{{ at }}{% endcapture %}
{% endunless %}
{% endfor %}
{% assign apptagssorted = apptagslist | split: '@@' | sort %}
{% assign appthemessorted = appthemeslist | split: '@@' | sort %}

<li class="filter">
<a>Themes</a>
<span class="filter-items">
{% for apptheme in appthemessorted %}
<a data-filter=".selector-theme-{{ apptheme | downcase | replace:' ','' | replace:'(','' | replace:')','' | replace:'&','and' }}">{{ apptheme }}</a>
{% endfor %}
</span>
</li>
{% endif %}

<li class="filter">
<a>Tags</a>
<span class="filter-items">
{% for apptag in apptagssorted %}
<a data-filter=".selector-tag-{{ apptag | downcase | replace:' ','' }}">{{ apptag }}</a>
{% capture apptags %}{% for page in site.pages %}{% if page.section == 'solutions' %}{% if page.tags %}{{ page.tags }},{% endif %}{% endif %}{% endfor %}{% endcapture %}
{% if apptags != '' %}
{% assign apptagsArray = apptags | split: "," %}
{% assign apptagslist = apptagsArray[1] %}
{% for at in apptagsArray %}
{% unless apptagslist contains at %}
{% capture apptagslist %}{{ apptagslist }}@@{{ at }}{% endcapture %}
{% endunless %}
{% endfor %}
</span>
</li>
{% assign apptagssorted = apptagslist | split: '@@' | sort %}

<li class="filter">
<a>Tags</a>
<span class="filter-items">
{% for apptag in apptagssorted %}
<a data-filter=".selector-tag-{{ apptag | downcase | replace:' ','' | replace:'(','' | replace:')','' | replace:'&','and' }}">{{ apptag }}</a>
{% endfor %}
</span>
</li>
{% endif %}
</ul>
{% if page.section == 'solutions' %}
<ul>
<li><a href="{{ apps_entry_point }}">Solutions Bank</a></li>
</ul>
{% endif %}
</li>

<!-- start navigation for contribute section -->
<li class="{% if page.url contains 'contribute' %}Selected{% endif %}">
<a href="{{ "/contribute/" | prepend: site.baseurl }}">Contribute</a>
<ul>
{% for contribute_page in site.pages %}
{% if contribute_page.section == 'contribute' %}
<li {% if contribute_page.url == page.url %} class="Selected"{% endif %}>
<a href="{{ contribute_page.url }}">{{ contribute_page.title }}</a>
</li>
{% for chapter in contribute.toc.chapters %}
{% assign chapter_url = site.baseurl | append: '/' | append: contribute.label | append: '/' %}
{% if chapter.slug %}
{% assign chapter_url = chapter_url | append: chapter.slug | append: '/' %}
{% endif %}
<li {% if chapter_url == page.url %} class="Selected"{% endif %}>
<a href="{{ chapter_url }}">{{ chapter.title }}</a>
</li>
{% endfor %}
</ul>
</li>
Expand Down
Loading