Skip to content

Commit

Permalink
issue36: another session on code cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
anvk committed May 13, 2016
1 parent 596d312 commit ff8806e
Show file tree
Hide file tree
Showing 15 changed files with 185 additions and 295 deletions.
25 changes: 19 additions & 6 deletions assets/a11yAccordion-dark.less
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,24 @@
@dark-areaBackground: #383330;
@dark-textColor: #F2F2EB;
@dark-linkColor: #BFB7AE;
@dark-triangleColor: #F2F2EB;

.dark-a11yAccordion-header {
.a11yAccordion-theme(@dark-headerBackground, @dark-textColor, @dark-linkColor);
}
.a11yAccordion-dark {
.a11yAccordionSearch {
background-image: url('../imgs/search-dark.png') !important;
color: @dark-textColor;
background-color: @dark-areaBackground;
}

.a11yAccordion-header {
.a11yAccordion-theme(@dark-headerBackground, @dark-textColor, @dark-linkColor);

.dark-a11yAccordion-area {
.a11yAccordion-theme(@dark-areaBackground, @dark-textColor, @dark-linkColor);
}
.a11yAccordion-triangle {
border-top-color: @dark-triangleColor;
}
}

.a11yAccordion-area {
.a11yAccordion-theme(@dark-areaBackground, @dark-textColor, @dark-linkColor);
}
}
18 changes: 12 additions & 6 deletions assets/a11yAccordion-light.less
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,18 @@
@light-areaBackground: #FFFEFD;
@light-textColor: #261E14;
@light-linkColor: #595048;
@light-triangleColor: yellow;
@light-triangleColor: #261E14;

.light-a11yAccordion-header {
.a11yAccordion-theme(@light-headerBackground, @light-textColor, @light-linkColor);
}
.a11yAccordion-light {
.a11yAccordion-header {
.a11yAccordion-theme(@light-headerBackground, @light-textColor, @light-linkColor);

.light-a11yAccordion-area {
.a11yAccordion-theme(@light-areaBackground, @light-textColor, @light-linkColor);
.a11yAccordion-triangle {
border-top-color: @light-triangleColor;
}
}

.a11yAccordion-area {
.a11yAccordion-theme(@light-areaBackground, @light-textColor, @light-linkColor);
}
}
28 changes: 16 additions & 12 deletions assets/a11yAccordion.less
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,20 @@
@shadowColor: #888;
@borderRadius: 7px;

.a11yAccordion-theme(@background, @text, @link) {
background-color: @background;
color: @text;
a, a:visited {
color: @link;
}
}

.a11y-AT() {
left: -900px;
top: -900px;
position: absolute;
}

.a11yAccordion-centralPos() {
margin-left: auto;
margin-right: auto;
Expand Down Expand Up @@ -42,9 +56,7 @@
.a11yAccordionItemHeaderLink {
float: right;
.a11yAccordionItemHeaderLinkHiddenLabel {
left: -900px;
top: -900px;
position: absolute;
.a11y-AT();
}
.a11yAccordion-triangle {
width: 0;
Expand All @@ -53,7 +65,7 @@
margin-top: 5px;
border-left: 8px solid transparent;
border-right: 8px solid transparent;
border-top: 8px solid black;
border-top: 8px solid;
float: right;
-moz-transition: -moz-transform .3s;
-webkit-transition: -webkit-transform .3s;
Expand Down Expand Up @@ -83,13 +95,5 @@
}
}

.a11yAccordion-theme(@background, @text, @link) {
background-color: @background;
color: @text;
a, a:visited {
color: @link;
}
}

@import "a11yAccordion-dark.less";
@import "a11yAccordion-light.less";
Binary file added assets/imgs/search-dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion dist/css/a11yAccordion.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file added dist/imgs/search-dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit ff8806e

Please sign in to comment.