From 01632c0fa6170df8ee9d3fc9c0b42449d013d284 Mon Sep 17 00:00:00 2001 From: Sebastian Langer Date: Fri, 27 May 2016 13:43:55 +0200 Subject: [PATCH] absolute-center-vertical - configurable position-property --- _mixins/absolute-center.less | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/_mixins/absolute-center.less b/_mixins/absolute-center.less index 1258e4e..100015f 100644 --- a/_mixins/absolute-center.less +++ b/_mixins/absolute-center.less @@ -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%)); }