diff --git a/takwimu/context_processors.py b/takwimu/context_processors.py index 3a65cfe1..005152fe 100644 --- a/takwimu/context_processors.py +++ b/takwimu/context_processors.py @@ -35,13 +35,9 @@ def takwimu_stories(request): stories_trending = [] try: - if settings.HURUMAP.get('url') != 'https://takwimu.africa': - with open('data/articles.json') as f: - stories = json.load(f) - else: - client = Medium() - stories = client.get_publication_posts('takwimu-africa', - count=20) + client = Medium() + stories = client.get_publication_posts('takwimu-africa', + count=20) stories_latest = stories[0:3] stories_dict = [i.__dict__ for i in stories] diff --git a/takwimu/settings.py b/takwimu/settings.py index bc07a1b0..c130261f 100644 --- a/takwimu/settings.py +++ b/takwimu/settings.py @@ -28,7 +28,7 @@ 'context_processors'] + [ 'takwimu.context_processors.takwimu_countries', 'takwimu.context_processors.takwimu_stories', - 'takwimu.context_processors.sdgs',] + 'takwimu.context_processors.sdgs'] # ------------------------------------------------------------------------------------- # HURUmap / Wazimap Config diff --git a/takwimu/static/css/takwimu.scss b/takwimu/static/css/takwimu.scss index a3336081..b6b18da8 100644 --- a/takwimu/static/css/takwimu.scss +++ b/takwimu/static/css/takwimu.scss @@ -5,13 +5,13 @@ * * NOTE: Please don't make edits here unless super necessary. */ -@import url('https://fonts.googleapis.com/css?family=Montserrat:300,400,600,700,800,900'); +@import url('https://fonts.googleapis.com/css?family=Lora:400,700|Muli:400,700,900'); -$brand-color-primary: #1f6cc6; -$brand-color-primary-alt: #074c9c; -$brand-color-primary-light: #7ab1f2; -$brand-color-secondary: #1e4a7e; -$brand-color-dark-alt: #46648c; +$brand-color-primary: #29a87c; +$brand-color-primary-alt: #4abc70; +$brand-color-primary-light: #f6fbfa; +$brand-color-secondary: #4abc70; +$brand-color-dark-alt: #8ed3a5; $brand-extend-white: #ffffff; $brand-extend-light: #f8f9fa; $brand-extend-jumbotron: #fafafa; @@ -19,17 +19,54 @@ $brand-extend-black: #000000; $brand-extend-muted: #6c757d; $brand-extend-disabled: #ededec; -html, body, h1, h2, h3, h4, h5, h6, p, * { - font-family: 'Montserrat', sans-serif; +html, body, p, * { + font-family: 'Muli', sans-serif; word-break: break-word; + line-height: initial; +} +h1, h2, h3, h4, h5, h6 { + font-family: 'Lora', serif; + line-height: initial; +} +.font-heading { + font-family: 'Lora', serif; +} +.font-paragraph { + font-family: 'Muli', sans-serif; } -img { - max-width: 100%; +p, .rich-text { + font-size: 20px; + line-height: 41px; +} +a, .breadcrumb-item { + font-size: 18px; + line-height: 43px; +} +.line-height-md { + &, a, .breadcrumb-item, p, .rich-text, * { + line-height: 31px; + } +} +.line-height-sm { + &, a, .breadcrumb-item, p, .rich-text, * { + line-height: 22px; + } +} +.line-height-initial { + &, a, .breadcrumb-item, p, .rich-text, * { + line-height: initial; + } +} +.display-1, .display-2, .display-3, .display-4 { + line-height: initial; +} +.anchorjs-link { + font-size: inherit; } -h1, h2, h3, h4, h5, h6 { - font-weight: bold; +img { + max-width: 100%; } @@ -76,6 +113,12 @@ a { .bg-info { background-color: #2da4c7 !important; } +.bg-black { + background-color: #000; +} +.bg-light { + background-color: #f6fbfa; +} // Text Colours .text-primary { color: $brand-color-primary !important; @@ -92,15 +135,13 @@ a { // Button .btn { - border-radius: 24px; + border-radius: 12px; padding: .375rem 1.25rem; max-width: 100%; text-overflow: ellipsis; overflow: hidden; } -.btn-lg { - padding: .5rem 1.5rem; -} + // Button - colours .btn-primary { background-color: $brand-color-primary; @@ -134,17 +175,22 @@ a { } } } +.btn-link { + color: $brand-color-primary-alt; + &:hover { + color: $brand-color-primary; + } +} .nav-pills.nav-pills-alt .nav-link { - color: #929292; + color: #4a4a4a; } .nav-pills.nav-pills-alt .nav-link.active, .nav-pills.nav-pills-alt .show>.nav-link { background-color: transparent; color: $brand-color-primary; border-bottom: 3px $brand-color-primary solid; border-radius: 0; - color: #4a4a4a; - font-weight: 900; + color: $brand-extend-black; } @@ -164,6 +210,28 @@ body { background-color: $brand-color-secondary !important; border-color: $brand-color-secondary !important; } +.leaflet-container a { + font-size: 11px; + line-height: initial; + color: $brand-color-primary; +} +.leaflet-bar a, .leaflet-control-layers-toggle { + font-size: initial; + line-height: initial; +} + +// Profile + +.caption { + font-size: inherit; + line-height: inherit; + margin: 0; padding: 0; + margin-bottom: 15px; + a { + font-size: inherit; + line-height: inherit; + } +} @@ -253,12 +321,13 @@ body { border-bottom: 5px solid transparent; cursor: pointer; text-decoration: none; - .border-left { - border-left: 1px solid rgba(255, 255, 255, 0.25)!important; + &.border-left, .border-left { + border-left: 1px solid rgba(255, 255, 255, 0.3)!important; } &:hover, &.active { background: $brand-color-dark-alt; border-bottom: 5px solid $brand-extend-white; + color: $brand-extend-white !important; + a div { border-left: 1px solid transparent !important; } @@ -267,11 +336,47 @@ body { } } &.active { - background: $brand-color-primary; - border-bottom: 5px solid transparent; + border-bottom: 5px solid $brand-extend-white; } } +// Support Services Button + +.support-services-button:hover { + background-color: $brand-color-primary-alt !important; +} + .support-services-button a:hover { + text-decoration: none !important; + color: $brand-extend-white !important; + } +.support-services-button u { + text-decoration: none; + border-bottom: 2px solid #fff; + display: inline-block; +} + + +// Updates section + +.updates a { + font-weight: bold; + color: $brand-color-primary; + text-decoration: underline; +} + +.updates .col-md-6:hover { + background-color: #e8e8e8;; +} +.updates .col-md-6:hover + .col div { + border-left: 2px dashed transparent!important; +} + +// Country Map SVG +.country-map.svg { + path { + fill: $brand-color-primary; + } +} /* ----------------------------------------- * Main Navbar @@ -297,8 +402,11 @@ body { } .nav-link { white-space: nowrap; + font-size: 18px; svg { margin-left: .255em; + margin-right: .255em; + margin-bottom: -2px; } } @@ -317,7 +425,7 @@ body { position: relative; top: -10px; margin-bottom: -10px; span { - border-bottom: 10px solid $brand-color-primary-alt; + border-bottom: 10px solid $brand-color-primary; border-left: 10px solid transparent; border-right: 10px solid transparent; } @@ -328,7 +436,7 @@ body { display: none; position: absolute; left: 0; width: 100vw; z-index: 3000; - background-color: $brand-color-primary-alt; + background-color: $brand-color-primary; a { color: $brand-extend-light; @@ -368,6 +476,62 @@ body { } +/* ----------------------------------------------- + * PAGE: Homepage + * ----------------------------------------------- */ + +// Carousel + +#carousel-homepage-hero { + line-height: 31px; +} +#carousel-homepage-hero .icon-wrap { + border-radius: 999px; + height: 50px; width: 50px; + text-align: center; + text-align: center; + overflow: hidden; +} + #carousel-homepage-hero .country-flag.svg { + height: 50px; + width: 50px; + opacity: 0.76; + mix-blend-mode: screen; + filter: saturate(0%); + } + #carousel-homepage-hero svg#beta { + padding: 10px; + opacity: 1.0; + filter: none; + mix-blend-mode: normal; + background: #fff; + } + +#carousel-homepage-hero .carousel-item .btn { + background-color: rgba(255, 255, 255, 0.28); +} +#carousel-homepage-hero .carousel-item .btn:hover { + background-color: rgba(255, 255, 255, 0.6); + border-color: transparent; +} +.carousel-indicators li { + position: relative; + -ms-flex: 0 1 auto; + flex: 0 1 auto; + width: 10px; + height: 10px; + margin-right: 3px; + margin-left: 3px; + text-indent: -999px; + cursor: pointer; + border-radius:10px; + background-color:white; +} +.carousel-indicators .active { + background-color: $brand-color-primary-alt; +} + + /* ----------------------------------------------- * PAGE: Profile Page * ----------------------------------------------- */ @@ -414,20 +578,22 @@ body { .dataindicators-nav { .nav-pills { - background-color: #1f6cc6; + background-color: $brand-color-primary; .nav-link.active, .show > .nav-link { - background-color: transparent; + background-color: rgba($color: $brand-extend-light, $alpha: 0.1); font-weight: bold; } } .nav-link { color: #f0f0f0; + line-height: 2; &:hover { - color: #f0f0f0;; + color: #fff; + background-color: rgba($color: $brand-extend-light, $alpha: 0.1); } .fa-eye { display: none; - margin-left: -2em; + margin-left: -35px; position: absolute; } &[aria-selected=true] .fa-eye { @@ -441,6 +607,7 @@ body { .nav-item { .nav-link { font-size: 14px; + line-height: 2; border-radius: 0; &.active { font-weight: bold; @@ -456,6 +623,11 @@ body { } } +.dataview-entities { + font-size: 80%; + line-height: 2; +} + // Profile Page > Sections List .profile.page .profilesections-list .sections-list { @@ -503,9 +675,9 @@ body { } &:hover,&:focus { - color: $brand-color-secondary; + color: $brand-color-primary; svg { - filter: $brand-color-secondary; /* IE6-9 */ + filter: $brand-color-primary; /* IE6-9 */ -webkit-filter: grayscale(1); /* Google Chrome, Safari 6+ & Opera 15+ */ filter: grayscale(1); /* Microsoft Edge and Firefox 35+ */ } @@ -615,6 +787,9 @@ body { } + + + // Extra small devices (portrait phones, less than 576px) // No media query for `xs` since this is the default in Bootstrap @@ -658,4 +833,9 @@ body { * during development */ // body { background: grey;} + + // Container fluid max-width: + .container { + max-width: 1249px; + } } diff --git a/takwimu/static/img/bg/africanparliament-detail.jpg b/takwimu/static/img/bg/africanparliament-detail.jpg new file mode 100644 index 00000000..f3b9b74d Binary files /dev/null and b/takwimu/static/img/bg/africanparliament-detail.jpg differ diff --git a/takwimu/static/img/bg/africanparliament-homepage.jpg b/takwimu/static/img/bg/africanparliament-homepage.jpg new file mode 100644 index 00000000..29b9a6d8 Binary files /dev/null and b/takwimu/static/img/bg/africanparliament-homepage.jpg differ diff --git a/takwimu/static/img/bg/globe-icon.jpg b/takwimu/static/img/bg/globe-icon.jpg new file mode 100644 index 00000000..0f9d9eba Binary files /dev/null and b/takwimu/static/img/bg/globe-icon.jpg differ diff --git a/takwimu/static/img/bg/parliament.jpg b/takwimu/static/img/bg/parliament.jpg new file mode 100644 index 00000000..73b11def Binary files /dev/null and b/takwimu/static/img/bg/parliament.jpg differ diff --git a/takwimu/static/img/bg/profile-hero-line.png b/takwimu/static/img/bg/profile-hero-line.png new file mode 100644 index 00000000..db631eeb Binary files /dev/null and b/takwimu/static/img/bg/profile-hero-line.png differ diff --git a/takwimu/static/img/icons/a-chart.png b/takwimu/static/img/icons/a-chart.png new file mode 100644 index 00000000..22cb66ad Binary files /dev/null and b/takwimu/static/img/icons/a-chart.png differ diff --git a/takwimu/static/img/icons/a-chart.svg b/takwimu/static/img/icons/a-chart.svg new file mode 100644 index 00000000..88e0e3a8 --- /dev/null +++ b/takwimu/static/img/icons/a-chart.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/takwimu/static/img/icons/a-chart@2x.png b/takwimu/static/img/icons/a-chart@2x.png new file mode 100644 index 00000000..26badc89 Binary files /dev/null and b/takwimu/static/img/icons/a-chart@2x.png differ diff --git a/takwimu/static/img/icons/a-chart@3x.png b/takwimu/static/img/icons/a-chart@3x.png new file mode 100644 index 00000000..82eb6e37 Binary files /dev/null and b/takwimu/static/img/icons/a-chart@3x.png differ diff --git a/takwimu/static/img/icons/file-paragraph.png b/takwimu/static/img/icons/file-paragraph.png new file mode 100644 index 00000000..ad412289 Binary files /dev/null and b/takwimu/static/img/icons/file-paragraph.png differ diff --git a/takwimu/static/img/icons/file-paragraph.svg b/takwimu/static/img/icons/file-paragraph.svg new file mode 100644 index 00000000..30151607 --- /dev/null +++ b/takwimu/static/img/icons/file-paragraph.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/takwimu/static/img/icons/file-paragraph@2x.png b/takwimu/static/img/icons/file-paragraph@2x.png new file mode 100644 index 00000000..f3e8a10b Binary files /dev/null and b/takwimu/static/img/icons/file-paragraph@2x.png differ diff --git a/takwimu/static/img/icons/file-paragraph@3x.png b/takwimu/static/img/icons/file-paragraph@3x.png new file mode 100644 index 00000000..caafd02b Binary files /dev/null and b/takwimu/static/img/icons/file-paragraph@3x.png differ diff --git a/takwimu/templates/404.html b/takwimu/templates/404.html index 9baf9c4a..4ae8468d 100644 --- a/takwimu/templates/404.html +++ b/takwimu/templates/404.html @@ -11,8 +11,7 @@

404 Not found

Why not try one of the following instead?

-
- Explore country profiles + diff --git a/takwimu/templates/homepage.html b/takwimu/templates/homepage.html index b3c9d300..fec9b401 100644 --- a/takwimu/templates/homepage.html +++ b/takwimu/templates/homepage.html @@ -11,22 +11,11 @@ {% block header %} {% include 'takwimu/_includes/navbar/_index.html' %} {% block header_content %} -
-
+
+
- -

Find data by - Country

-

+

Find data by Country

+

All Takwimu data comes with analysis from our expert team, providing you with the insights you need.

@@ -37,14 +26,7 @@

Find data by {% block content_container %}
-
-

Browse by Map

-

The data view on pages shown by navigating with this map are still work in progress. Please treat them as a sneak peak of what to expect in future releases. We'd though still want your feedback on them though.

- -
+
@@ -72,24 +54,9 @@

Find data by .country-container:nth-of-type(odd) { background-color: #fff; } - .country-container:nth-of-type(even) { background-color: #f4f4f4; } - .breadcrumb { - padding: 1rem; - } - .breadcrumb-item { - padding-left: .1rem; - letter-spacing: 0; - font-size: 14px; - } - .breadcrumb-item+.breadcrumb-item::before { - display: inline-block; - padding-right: .1rem; - color: #fff; - content: "\00BB"; - } {% endblock body %} diff --git a/takwimu/templates/takwimu/_includes/footer.html b/takwimu/templates/takwimu/_includes/footer.html index 6fdbd121..2f51799c 100644 --- a/takwimu/templates/takwimu/_includes/footer.html +++ b/takwimu/templates/takwimu/_includes/footer.html @@ -1,13 +1,12 @@ {% load staticfiles %} {% load datastructuretags %} -
+

- +

@@ -15,14 +14,14 @@
-

Actionable +

Actionable insights
+ style="background: rgba(255, 255, 255, 0.4); height: 10px; width: 104px; bottom: 1px; left: -3px; -webkit-transform: skew(340deg); -moz-transform: skew(340deg); -o-transform: skew(340deg);">
- for African changemakers. + for
African changemakers.

@@ -30,16 +29,13 @@

Actionable
An initiative by:
@@ -57,11 +53,11 @@
Supp
-
-

Takwimu provides quality insights and data-driven analysis to empower African development champions.

+
+

Takwimu provides quality insights and data-driven analysis to empower African development champions.

-

Explore data and analysis by country, topic , and SDG indicator, discover expert insights on key development issues, and see how we created Takwimu. +

Explore data and analysis by country, topic , and SDG indicator, discover expert insights on key development issues, and see how we created Takwimu.

@@ -70,15 +66,15 @@
Supp
-
{% endfor %} diff --git a/takwimu/templates/takwimu/_includes/sections/updates.html b/takwimu/templates/takwimu/_includes/sections/updates.html index d3e85e90..7332e7a5 100644 --- a/takwimu/templates/takwimu/_includes/sections/updates.html +++ b/takwimu/templates/takwimu/_includes/sections/updates.html @@ -4,12 +4,12 @@
-

+


+ style="width: auto; height: 45px;"/>
Stay up-to-date -

-

+

+

To be notified when new data is published on Takwimu, subscribe to our RSS feed or @@ -22,13 +22,12 @@

-

+


- + style="width: auto; height: 50px;"/>
Join the discussion -

-

+

+

Contribute to Takwimu by sharing your thoughts and ideas on twitter

@@ -36,19 +35,3 @@

- - diff --git a/takwimu/templates/takwimu/_layouts/_base.html b/takwimu/templates/takwimu/_layouts/_base.html index b029db3b..f39cd0db 100644 --- a/takwimu/templates/takwimu/_layouts/_base.html +++ b/takwimu/templates/takwimu/_layouts/_base.html @@ -56,7 +56,7 @@ - + diff --git a/takwimu/templates/takwimu/about/index.html b/takwimu/templates/takwimu/about/index.html index 67683b6f..4a9e6627 100644 --- a/takwimu/templates/takwimu/about/index.html +++ b/takwimu/templates/takwimu/about/index.html @@ -1,25 +1,68 @@ {% extends 'takwimu/_layouts/page.html' %} -{% load wagtailcore_tags %} +{% load wagtailcore_tags static %} {% block content %} -
- Home » About Takwimu -
-
+
-

About Takwimu

+

About Us

+
+

On this page

+ About Takwimu + Services +
+ +
+ +

About Takwimu

+
{{ settings.takwimu.AboutUsSetting.about_us | richtext }} -
-
-
-
-

Services for...

-
- {% include 'takwimu/_includes/sections/support-services/tabs.html' %} +
+

The Partnership

+

africapractice, Code for Africa and iHub came together to create Takwimu.

+ + +
Supported by:
+ + Bill and Melinda Gates Foundation + + + +
-
- {% include 'takwimu/_includes/partners.html' %} +
+ +

Services

+
+ +

We understand that access to data and analysis is not enough - there is a gulf between looking at a web page and being able to harness information to make your work easier and your efforts more effective.

+

Our Standard Services are free; currently they include using advanced tools to download data visuals, create alerts, manage collections, access data over API and attend best practice webinars.

+

Our Premium Services add further value by customising and packaging analysis and related data to your specific requirements as well as the option to showcase your own content to a growing African and international audience. We will usually charge for Premium services and use this income to re-invest in the Takwimu platform.

+ + {% for service in settings.takwimu.SupportServicesSetting.services %} + {% if service.value.category != "Persona" %} +

{{ service.value.title }}

+ {{ service.value.description | richtext }} + {% endif %} + {% endfor %} +
+
{% include 'takwimu/_includes/sections/support-services/button.html' %} diff --git a/takwimu/templates/takwimu/about/support_services.html b/takwimu/templates/takwimu/about/support_services.html index 07dd953c..8039ecf7 100644 --- a/takwimu/templates/takwimu/about/support_services.html +++ b/takwimu/templates/takwimu/about/support_services.html @@ -3,26 +3,11 @@ {% block content %} -
-
- -
-
-
-

+

Takwimu Services

Takwimu offers both free and premium services designed to help our users access and use high quality data and analysis.

diff --git a/takwimu/templates/takwimu/about_page.html b/takwimu/templates/takwimu/about_page.html deleted file mode 100644 index d5766ca9..00000000 --- a/takwimu/templates/takwimu/about_page.html +++ /dev/null @@ -1,17 +0,0 @@ -{% extends 'takwimu/_layouts/page.html' %} -{% load wagtailcore_tags %} - -{% block content %} - -
-

About Us

- {{ settings.takwimu.AboutUsSettings.about_us | richtext }} -
- -{% include 'takwimu/_includes/partners.html' %} - -{% include 'takwimu/_includes/sections/support-services/button.html' %} - -{% include 'takwimu/_includes/sections/updates.html' %} - -{% endblock %} diff --git a/takwimu/templates/takwimu/contact_us_page.html b/takwimu/templates/takwimu/contact_us_page.html index a8fc415d..fef35728 100644 --- a/takwimu/templates/takwimu/contact_us_page.html +++ b/takwimu/templates/takwimu/contact_us_page.html @@ -6,7 +6,7 @@
-

Contact Us

+

Contact Us

We'd love to hear from you. You can reach us at:

@@ -24,7 +24,7 @@

Address

Social

    - {% to_list 'facebook' 'twitter' 'medium' 'youtube' 'instagram' 'github' as social_medias %} + {% to_list 'twitter' 'medium' 'facebook' 'github' as social_medias %} {% for social_media in social_medias %} {% if settings.takwimu.SocialMediaSetting|object_value:social_media %}
  • @@ -52,6 +52,4 @@

    Social

    {% include 'takwimu/_includes/sections/updates.html' %} - - {% endblock %} diff --git a/takwimu/templates/takwimu/sdg_topic_page.html b/takwimu/templates/takwimu/sdg_topic_page.html index 644e012f..d00e476d 100644 --- a/takwimu/templates/takwimu/sdg_topic_page.html +++ b/takwimu/templates/takwimu/sdg_topic_page.html @@ -3,15 +3,12 @@ {% load staticfiles %} {% block content %} -
    -
    +
    +
    -

    Find data by SDG Indicator

    -

    +

    Find data by SDG Indicator

    +

    All Takwimu data comes with analysis from our expert team, providing you with the insights you need.

    -
    +
    {% include 'takwimu/_includes/sections/sdg/nav.html' %}
    -
    +
    {% include 'takwimu/_includes/sections/sdg/index.html' %}
    diff --git a/takwimu/templates/takwimu/topic_page.html b/takwimu/templates/takwimu/topic_page.html index 1f20ca63..a2efe71e 100644 --- a/takwimu/templates/takwimu/topic_page.html +++ b/takwimu/templates/takwimu/topic_page.html @@ -3,15 +3,12 @@ {% load staticfiles %} {% block content %} -
    -
    +
    +
    -

    Find data by topic

    -

    +

    Find data by topic

    +

    All Takwimu data comes with analysis from our expert team, providing you with the insights you need.

    @@ -37,19 +34,20 @@

    Find data by topi

    +
    +
    +

    Explore the data by country

    +
    +
    + {% include 'takwimu/_includes/sections/explore/countries.html' %} +
    +
    + {% include 'takwimu/_includes/sections/support-services/button.html' %} {% include 'takwimu/_includes/sections/stories/index.html' %} -
    -
    -

    Explore the data by country

    -
    -
    - {% include 'takwimu/_includes/sections/explore/countries.html' %} -
    -
    {% include 'takwimu/_includes/sections/updates.html' %}