From 609cd2cf4543565ec1007d5020edcb7021e12699 Mon Sep 17 00:00:00 2001 From: goodmice Date: Wed, 28 Dec 2022 18:23:02 +0500 Subject: [PATCH] =?UTF-8?q?=D0=92=D1=8B=D0=B4=D0=B5=D0=BB=D0=B5=D0=BD=20?= =?UTF-8?q?=D1=84=D0=B0=D0=B9=D0=BB=20=D0=BF=D0=BE=D0=B4=20=D0=BC=D0=B8?= =?UTF-8?q?=D0=BA=D1=81=D0=B8=D0=BD=D1=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/styles/index.less | 19 +++++++------------ src/styles/mixins.less | 13 +++++++++++++ 2 files changed, 20 insertions(+), 12 deletions(-) create mode 100644 src/styles/mixins.less diff --git a/src/styles/index.less b/src/styles/index.less index efe2883..c80db0c 100644 --- a/src/styles/index.less +++ b/src/styles/index.less @@ -1,5 +1,6 @@ -@import 'include/antd_theme.less'; -@import 'fonts.less'; +@import './include/antd_theme.less'; +@import './fonts'; +@import './mixins'; body { margin: 0; @@ -43,14 +44,8 @@ body { width: 100%; } -.noselect { - -webkit-touch-callout: none; /* iOS Safari */ - -webkit-user-select: none; /* Safari */ - -khtml-user-select: none; /* Konqueror HTML */ - -moz-user-select: none; /* Old versions of Firefox */ - -ms-user-select: none; /* Internet Explorer/Edge */ - user-select: none; /* Non-prefixed version, currently - supported by Chrome, Edge, Opera and Firefox */ -} - .pointer { cursor: pointer } + +.no-select { + .no-select(); +} diff --git a/src/styles/mixins.less b/src/styles/mixins.less new file mode 100644 index 0000000..94ccc9a --- /dev/null +++ b/src/styles/mixins.less @@ -0,0 +1,13 @@ +.no-select () { + -webkit-touch-callout: none; /* iOS Safari */ + -webkit-user-select: none; /* Safari */ + -khtml-user-select: none; /* Konqueror HTML */ + -moz-user-select: none; /* Old versions of Firefox */ + -ms-user-select: none; /* Internet Explorer/Edge */ + user-select: none; /* Non-prefixed version, currently + supported by Chrome, Edge, Opera and Firefox */ +} + +.no-events () { + pointer-events: none; +}