Skip to content

Commit 90d5925

Browse files
committed
Add GitHub sponsor button
1 parent 0bf63dc commit 90d5925

File tree

15 files changed

+200
-56
lines changed

15 files changed

+200
-56
lines changed

docs/_data/expo.json

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
{
22
"by_id": {
3+
"sinuous": {
4+
"name": "Sinuous",
5+
"url": "https://sinuous.netlify.com/",
6+
"date": "21 Sep 2019"
7+
},
38
"divjoy": {
49
"name": "Divjoy",
510
"url": "https://divjoy.com/",
@@ -50,7 +55,6 @@
5055
},
5156
"mynameismirko2018": {
5257
"name": "mynameismirko",
53-
"highlighted": true,
5458
"url": "http://2018.mynameismirko.it/",
5559
"date": "26 Jan 2019"
5660
},
@@ -347,6 +351,7 @@
347351
"bulmaplay",
348352
"filegator",
349353
"counternetwork",
354+
"sinuous",
350355
"agilox",
351356
"pingstack",
352357
"mynameismirko2018",

docs/_data/links.json

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -482,26 +482,46 @@
482482
},
483483
"videos": {
484484
"name": "Videos",
485+
"color": "success",
486+
"icon": "play-circle",
487+
"title": "Videos",
485488
"path": "/videos"
486489
},
487490
"blog": {
488491
"name": "Blog",
492+
"title": "Blog",
493+
"subtitle": "Stay updated with new features",
494+
"color": "orange",
495+
"icon": "rss",
489496
"path": "/blog"
490497
},
491498
"expo": {
492499
"name": "Expo",
500+
"title": "Expo",
493501
"subtitle": "Official Bulma showcase",
494502
"icon": "star",
495503
"color": "star",
496504
"path": "/expo"
497505
},
498506
"love": {
499507
"name": "Love",
508+
"title": "Love",
500509
"subtitle": "Fans of Bulma around the world",
501510
"color": "danger",
502511
"icon": "heart",
503512
"path": "/love"
504513
},
514+
"backers": {
515+
"id": "backers",
516+
"name": "Patreon Backers",
517+
"title": "Backers",
518+
"color": "patreon",
519+
"icon": "patreon",
520+
"path": "/backers",
521+
"icon_brand": true,
522+
"subtitle": "Everyone who is supporting Bulma",
523+
"description": "Everyone who is supporting Bulma"
524+
},
505525
"more": {
506526
"name": "More",
507527
"path": "/more"
@@ -543,8 +563,15 @@
543563
"path": "/extensions"
544564
}
545565
},
566+
"navbar": [
567+
"videos",
568+
"expo",
569+
"love",
570+
"backers"
571+
],
546572
"more": [
547-
"patreon-backers",
573+
"backers",
574+
"blog",
548575
"made-with-bulma",
549576
"bootstrap",
550577
"extensions",

docs/_includes/components/categories.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
<a class="bd-category-name {% if category_id == current_link_id %}is-active{% endif %}" href="{{ site.url }}{{ category_link.path }}">
1515
<strong>{{ category_link.name }}</strong>
1616
{% if category_link.name == 'Customize' %}
17-
<span class="tag is-success">
17+
<span class="tag bd-mini-tag is-success">
1818
New!
1919
</span>
2020
{% endif %}

docs/_includes/elements/github.html

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<a class="button bd-github-button" href="https://github.com/users/jgthms/sponsorship" target="_blank">
2+
<span class="icon">
3+
<i class="fas fa-heart"></i>
4+
</span>
5+
<strong>Sponsor</strong>
6+
<em class="tag bd-mini-tag is-small is-success">New!</em>
7+
</a>

docs/_includes/footer/support.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ <h4 class="bd-footer-title">
3838
<strong>Monthly</strong> donation
3939
</p>
4040
<div class="bd-footer-donation-action">
41+
{% include elements/github.html %}
4142
{% include elements/patreon.html %}
4243
</div>
4344
</div>

docs/_includes/global/navbar.html

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,18 +33,19 @@
3333
<span class="is-hidden-touch is-hidden-widescreen">
3434
Docs
3535
</span>
36-
<span class="is-hidden-desktop-only">
36+
<span class="is-hidden-tablet-only is-hidden-desktop-only">
3737
Documentation
3838
</span>
3939
</a>
4040

41-
{% for item in site.data.global.navbar_items %}
42-
<a class="navbar-item bd-navbar-item-{{ item.id }} {% if page.route == item.id %}is-active{% endif %}" href="{{ site.url }}/{{ item.id }}/">
43-
<span class="icon {{ item.color }}">
44-
<i class="{{ item.fa_type }} {{ item.fa_icon }}"></i>
41+
{% for link_id in site.data.links.navbar %}
42+
{% assign link = site.data.links.by_id[link_id] %}
43+
<a class="navbar-item bd-navbar-item-{{ link.id }} {% if page.route == link.id %}is-active{% endif %}" href="{{ site.url }}{{ link.path }}/">
44+
<span class="icon has-text-{{ link.color }}">
45+
<i class="{% if link.icon_brand %}fab{% elsif link.icon_regular %}far{% else %}fas{% endif %} fa-{{ link.icon }}"></i>
4546
</span>
4647

47-
<span>{{ item.title }}</span>
48+
<span>{{ link.title }}</span>
4849
</a>
4950
{% endfor %}
5051

@@ -57,7 +58,7 @@
5758
<div id="moreDropdown" class="navbar-dropdown">
5859
{% for link_id in site.data.links.more %}
5960
{% assign link = site.data.links.by_id[link_id] %}
60-
<a class="navbar-item {% if page.route == link_id %}is-active{% endif %}" href="{{ site.url }}/{{ link.path }}">
61+
<a class="navbar-item {% if page.route == link_id %}is-active{% endif %}" href="{{ site.url }}{{ link.path }}">
6162
<span>
6263
<span class="icon has-text-{{ link.color }}">
6364
<i class="{% if link.icon_brand %}fab{% elsif link.icon_regular %}far{% else %}fas{% endif %} fa-{{ link.icon }}"></i>
@@ -90,6 +91,9 @@
9091

9192
<div class="navbar-item">
9293
<div class="field is-grouped is-grouped-multiline">
94+
<p class="control">
95+
{% include elements/github.html %}
96+
</p>
9397
<p class="control">
9498
{% include elements/patreon.html %}
9599
</p>

docs/_sass/footer.sass

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@
6060

6161
+tablet
6262
.bd-footer-donation
63-
width: 240px
63+
padding: 0.75rem 1.5rem
6464

6565
.bd-footer-donation-title
6666
color: $grey-light
@@ -71,6 +71,11 @@
7171
.bd-footer-donation-action
7272
@extend %center
7373
height: 70px
74+
.bd-github-button
75+
margin-right: 0.5rem
76+
.bd-github-button,
77+
.bd-patreon-button
78+
flex-shrink: 0
7479
.paypal-form
7580
height: 30px
7681
img

docs/_sass/global.sass

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,30 @@ svg
3737
p:first-child
3838
margin-right: 1em
3939

40+
.bd-github-button
41+
background-color: #eff3f6
42+
background-image: linear-gradient(-180deg,#fafbfc,#eff3f6 90%)
43+
border-color: #1b1f2333
44+
color: #24292e
45+
font-size: 0.875rem
46+
height: auto
47+
padding: calc(0.5em - 1px) 1em
48+
position: relative
49+
strong
50+
font-weight: $weight-semibold
51+
margin-top: -2px
52+
.icon
53+
color: #ea4aaa
54+
.tag
55+
font-size: 0.5rem
56+
font-style: normal
57+
margin: -1px -8px 0 7px
58+
&:hover
59+
background-color: #e6ebf1
60+
background-image: linear-gradient(-180deg, #f0f3f6, #e6ebf1 90%)
61+
background-position: -.5em
62+
border-color: #1b1f2359
63+
4064
.bd-patreon-button
4165
display: inline-block
4266
position: relative
@@ -135,3 +159,13 @@ $carbon-poweredby-height: 20px
135159
right: 0
136160
&:hover
137161
text-decoration: underline
162+
163+
+until($widescreen)
164+
#navMenuLove .bd-navbar-item-backers
165+
display: none
166+
167+
+widescreen
168+
#moreDropdown
169+
.navbar-item:first-child,
170+
.navbar-divider:nth-child(2)
171+
display: none

docs/_sass/main.sass

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -165,19 +165,21 @@
165165
transition-duration: $speed
166166
transition-property: transform
167167

168+
.tag.bd-mini-tag
169+
border-radius: 2px !important
170+
font-family: Verdana, sans-serif
171+
font-size: 0.5rem
172+
font-weight: bold
173+
height: 2.25em
174+
vertical-align: text-bottom
175+
168176
.bd-category-name
169177
color: $text-strong
170178
position: relative
171179
&.is-active
172180
color: $link
173-
.tag
174-
border-radius: 2px
175-
font-family: Verdana
176-
font-size: 0.5rem
177-
font-weight: bold
178-
height: 2.25em
181+
.bd-mini-tag
179182
margin-left: 0.5em
180-
vertical-align: text-bottom
181183

182184
.bd-category-list
183185
@extend %bd-list

docs/backers.html

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
route: backers
55
breadcrumb:
66
- home
7-
- more
87
- patreon-backers
98
---
109

0 commit comments

Comments
 (0)