Skip to content

Commit 1bfc9a2

Browse files
author
rakeshAlgo
committed
change label for page edition/ statuses
1 parent 1a5f594 commit 1bfc9a2

File tree

5 files changed

+34
-16
lines changed

5 files changed

+34
-16
lines changed

preview-src/index.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ This section does not have any edition or status labels at the start.
191191

192192
* This is the first item in a list.
193193

194-
* [.community]#{community}# This is the second item in a list.
194+
* [.edition]#{community}# This is the second item in a list.
195195
This item is only applicable to community edition.
196196

197197
* This is the third item in the list.
@@ -245,7 +245,7 @@ return thisAirline; // <2>
245245

246246
[#vbucket-stats]
247247
== Monitoring `vBucket` Resources
248-
248+
[.table-ui]
249249
[cols="1,3"]
250250
|===
251251
| Statistic | Description

src/css/contributor.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
flex-wrap: wrap;
55
margin: 15px 0 0;
66
visibility: hidden;
7+
display: none;
78
}
89

910
.contributor-list-box.show {

src/css/labels.css

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
.doc .edition,
1919
.doc .status,
20-
.doc .community {
20+
.doc .edition.page-edition {
2121
max-width: fit-content;
2222
font-size: var(--labels-font-size);
2323
font-weight: var(--weight-bold);
@@ -47,7 +47,7 @@
4747
.doc .labels li,
4848
.doc .edition,
4949
.doc .status,
50-
.doc .community {
50+
.doc .edition.page-edition {
5151
color: #fff;
5252
display: inline-block;
5353
padding: 6px;
@@ -59,7 +59,7 @@
5959
.doc .labels li a,
6060
.doc .edition a,
6161
.doc .status a,
62-
.doc .community a {
62+
.doc .edition.page-edition a {
6363
text-decoration: none;
6464
font-family: "Source Sans Pro", sans-serif;
6565
}
@@ -87,7 +87,7 @@
8787
opacity: 0.6;
8888
}
8989

90-
.doc .community {
90+
.doc .edition.page-edition {
9191
color: #999;
9292
border: 1px solid #999;
9393
border-radius: 3px;
@@ -102,13 +102,13 @@
102102
color: var(--color-brand-caution);
103103
}
104104

105-
.doc .community a {
105+
.doc .edition.page-edition a {
106106
color: #999;
107107
}
108108

109109
.doc .edition:hover,
110110
.doc .status:hover,
111-
.doc .community:hover {
111+
.doc .edition.page-edition:hover {
112112
opacity: 1;
113113
}
114114

src/css/table.css

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -99,13 +99,13 @@ table.tableblock .title {
9999
border-bottom: none;
100100
}
101101

102-
/* table.merged-cells-table tr:hover {
102+
/* table.table-merge-cells tr:hover {
103103
background-color: var(--color-brand-gray7);
104104
}
105105
*/
106106

107-
table.description-cell-table tr th:last-child,
108-
table.description-cell-table tr td:last-child {
107+
table.table-tutorial tr th:last-child,
108+
table.table-tutorial tr td:last-child {
109109
background-color: var(--color-brand-gray7);
110110
}
111111

@@ -144,7 +144,7 @@ table.description-cell-table tr td:last-child {
144144
display: table-row;
145145
}
146146

147-
table.merged-cells-table tbody tr:nth-child(even) {
147+
table.table-merge-cells tbody tr:nth-child(even) {
148148
background-color: var(--color-brand-gray7);
149149
}
150150

@@ -158,13 +158,13 @@ table.description-cell-table tr td:last-child {
158158
width: auto;
159159
}
160160

161-
table.merged-cells-table tr td:first-child,
162-
table.description-cell-table tr td:first-child {
161+
table.table-merge-cells tr td:first-child,
162+
table.table-tutorial tr td:first-child {
163163
border-left: 0;
164164
}
165165

166-
table.merged-cells-table tr td,
167-
table.description-cell-table tr td {
166+
table.table-merge-cells tr td,
167+
table.table-tutorial tr td {
168168
border-left: 1px solid var(--color-brand-gray8);
169169
}
170170
}

src/js/11-page-customize.js

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
;
2+
(function ($) {
3+
'use strict'
4+
// for label edition/statuses
5+
var $labels = $('.edition').find('a')
6+
7+
console.log($labels.length)
8+
9+
for (var i = 0; i < $labels.length; i++) {
10+
console.log(i, 445, $labels[i])
11+
if ($labels[i].text.toLocaleLowerCase().indexOf('community') !== -1) {
12+
$labels[i].parentNode.classList.add('page-edition')
13+
}
14+
}
15+
16+
/*eslint-env jquery*/
17+
})(jQuery)

0 commit comments

Comments
 (0)