From 423a240b489c73ac4c61ead47334c2a13e189097 Mon Sep 17 00:00:00 2001 From: Maxim Kadushkin Date: Fri, 20 Nov 2020 23:54:56 +0300 Subject: [PATCH] [common] added script for addaptive border --- apps/common/main/resources/less/asc-mixins.less | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/apps/common/main/resources/less/asc-mixins.less b/apps/common/main/resources/less/asc-mixins.less index dd8ec7a1a..2cfbd80ea 100644 --- a/apps/common/main/resources/less/asc-mixins.less +++ b/apps/common/main/resources/less/asc-mixins.less @@ -280,3 +280,19 @@ } } } + +.adaptive-solid-border(@width, @color, @borderside: all) { + @lb-border: if((@borderside = all), border, e('border-@{borderside}')); + @lb-border-width: if((@borderside = all), border-width, e('border-@{borderside}-width')); + + @{lb-border}: @width solid @color; + + @media only screen { + @media (-webkit-min-device-pixel-ratio: 1.5) and (-webkit-max-device-pixel-ratio: 1.9), + (min-resolution: 1.5dppx) and (max-resolution: 1.9dppx), + (min-resolution: 144dpi) and (max-resolution: 191dpi) + { + @{lb-border-width}: (@width / 1.5); + } + } +}