Skip to content

Commit 04043bc

Browse files
committed
fix: inconsistent naming style
Always use two dashes after prefix.
1 parent 1a36094 commit 04043bc

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

css/simple-css-switch.css

+5-5
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@
77
padding: 1em;
88
border: .2em inset #a6a659;
99
}
10-
.s-css-s-button:focus {
10+
.s-css-s--button:focus {
1111
outline: 0 none;
1212
}
13-
.s-css-s-button {
13+
.s-css-s--button {
1414
display: block;
1515
width: 100%;
1616
margin: .2em;
@@ -27,15 +27,15 @@
2727
position: relative;
2828
left: -.5em;
2929
}
30-
.s-css-s-main-css {
30+
.s-css-s--main-css {
3131
color: #eee;
3232
background-color: #2c2c2c;
3333
}
34-
.s-css-s-red-css {
34+
.s-css-s--red-css {
3535
color: #dcd;
3636
background-color: #2e0505;
3737
}
38-
.s-css-s-green-css {
38+
.s-css-s--green-css {
3939
color: #ddd;
4040
background-color: #122112;
4141
}

js/simple-css-switch.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ function simpleCssSwitch() {
55
document.querySelectorAll('.s-css-s--style')
66
);
77
stylesAvailable.forEach(function(style, idx) {
8-
var cssFileAsClass = 's-css-s-' + style.href.split('/').pop().replace('.', '-');
8+
var cssFileAsClass = 's-css-s--' + style.href.split('/').pop().replace('.', '-');
99
var styleOptionButton = document.createElement('button');
1010
styleOptionButton.setAttribute('title', style.title);
11-
styleOptionButton.classList.add('s-css-s-button', cssFileAsClass);
11+
styleOptionButton.classList.add('s-css-s--button', cssFileAsClass);
1212
styleOptionButton.innerText = idx;
1313
styleOptionButton.addEventListener(
1414
'click', function(e) {

0 commit comments

Comments
 (0)