Skip to content

Commit

Permalink
absolute-center-vertical - configurable position-property
Browse files Browse the repository at this point in the history
  • Loading branch information
Sebastian Langer committed May 27, 2016
1 parent 3b99395 commit 01632c0
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions _mixins/absolute-center.less
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
.absolute-center() {
position: absolute;
.absolute-center(@position: absolute) {
position: @position;
top: 50%;
left: 50%;
.transform(translate(-50%, -50%));
}

.absolute-center-vertical() {
position: absolute;
.absolute-center-horizontal(@position: absolute) {
position: @position;
left: 50%;
.transform(translateX(-50%));
}

.absolute-center-horizontal() {
position: absolute;
.absolute-center-vertical(@position: absolute) {
position: @position;
top: 50%;
.transform(translateY(-50%));
}

0 comments on commit 01632c0

Please sign in to comment.