Skip to content

Commit 8192ef6

Browse files
re-fortkazupon
authored andcommitted
add carbon cpc ads (vuejs#347)
# Conflicts: # themes/vue/layout/page.ejs
1 parent 28ed050 commit 8192ef6

File tree

4 files changed

+84
-31
lines changed

4 files changed

+84
-31
lines changed

themes/vue/layout/page.ejs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,5 +36,10 @@
3636
<% }) %>
3737
</div>
3838
<% } %>
39-
<div class="footer">間違いを見つけた、またはドキュメントに貢献したいですか?<a href="https://github.com/vuejs/jp.vuejs.org/blob/lang-ja/src/<%- page.path.replace(/\.html$/, '.md') %>" target="_blank">Github 上でこのページを編集する</a> か、<a href="https://github.com/vuejs/jp.vuejs.org" target="_blank">Github からこのサイトを Fork してプルリクエストしましょう</a>!</div>
39+
<div class="footer">
40+
<%- partial('partials/ad-text') %>
41+
間違いを見つけた、またはドキュメントに貢献したいですか?
42+
<a href="https://github.com/vuejs/jp.vuejs.org/blob/lang-ja/src/<%- page.path.replace(/\.html$/, '.md') %>" target="_blank">Github 上でこのページを編集する</a> か、<a href="https://github.com/vuejs/jp.vuejs.org" target="_blank">Github からこのサイトを Fork してプルリクエストしましょう
43+
</a>!
44+
</div>
4045
</div>
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<script src="//m.servedby-buysellads.com/monetization.js" type="text/javascript"></script>
2+
<div class="bsa-cpc"></div>
3+
<script>
4+
(function(){
5+
if(typeof _bsa !== 'undefined' && _bsa) {
6+
_bsa.init('default', 'CKYD62QM', 'placement:vuejsorg', {
7+
target: '.bsa-cpc',
8+
align: 'horizontal',
9+
disable_css: 'true'
10+
});
11+
}
12+
})();
13+
</script>

themes/vue/source/css/_ad.styl

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
// main ad placement (bottom right)
2+
#ad
3+
width: 125px
4+
// text-align: center
5+
position: fixed
6+
z-index: 99
7+
bottom: 10px
8+
right: 10px
9+
padding: 10px
10+
background-color: #fff
11+
border-radius: 3px
12+
font-size: 13px
13+
a
14+
display: inline-block
15+
color: $light
16+
font-weight: normal
17+
span
18+
color: $light
19+
display: inline-block
20+
margin-bottom: 5px
21+
img
22+
width: 125px
23+
.carbon-img, .carbon-text
24+
display: block
25+
margin-bottom: 6px
26+
font-weight: normal
27+
color: $medium
28+
.carbon-poweredby
29+
color: #aaa
30+
font-weight: normal
31+
32+
// text ad (below page title)
33+
.bsa-cpc
34+
font-size 1em
35+
background-color #f8f8f8
36+
padding 10px 15px
37+
margin-bottom 20px
38+
a._default_
39+
color #666
40+
font-weight 400
41+
line-height 1
42+
.default-image, .default-title, .default-description
43+
display inline
44+
vertical-align middle
45+
margin-right 6px
46+
.default-image
47+
img
48+
height 20px
49+
border-radius 3px
50+
vertical-align middle
51+
position relative
52+
top -1px
53+
.default-title
54+
font-weight 600
55+
.default-description:after
56+
font-size .85em
57+
content "Sponsored"
58+
color $info
59+
border 1px solid $info
60+
border-radius 3px
61+
padding 0 4px 1px
62+
margin-left 6px
63+
.default-ad
64+
display none

themes/vue/source/css/_common.styl

Lines changed: 1 addition & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
@import "_settings"
22
@import "_syntax"
3+
@import "_ad"
34

45
body
56
font-family: $body-font
@@ -109,36 +110,6 @@ a.button
109110
padding: 0 60px 30px
110111
overflow-x: hidden
111112

112-
#ad
113-
width: 125px
114-
// text-align: center
115-
position: fixed
116-
z-index: 99
117-
bottom: 10px
118-
right: 10px
119-
padding: 10px
120-
background-color: #fff
121-
border-radius: 3px
122-
font-size: 13px
123-
a
124-
display: inline-block
125-
color: $light
126-
font-weight: normal
127-
span
128-
color: $light
129-
display: inline-block
130-
margin-bottom: 5px
131-
img
132-
width: 125px
133-
.carbon-img, .carbon-text
134-
display: block
135-
margin-bottom: 6px
136-
font-weight: normal
137-
color: $medium
138-
.carbon-poweredby
139-
color: #aaa
140-
font-weight: normal
141-
142113
#nav
143114
.nav-link
144115
cursor: pointer

0 commit comments

Comments
 (0)