From 357b1d56d10cb63c80600b12c9ab5f023c01d4f2 Mon Sep 17 00:00:00 2001 From: Vladimir Kharlampidi Date: Wed, 5 Oct 2022 10:54:38 +0300 Subject: [PATCH] feat(text-editor): m3 styles --- .../text-editor/text-editor-vars.less | 19 +++++++++++-------- .../components/text-editor/text-editor.less | 1 - 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/src/core/components/text-editor/text-editor-vars.less b/src/core/components/text-editor/text-editor-vars.less index 6287e3d7e3..44f4407af7 100644 --- a/src/core/components/text-editor/text-editor-vars.less +++ b/src/core/components/text-editor/text-editor-vars.less @@ -9,37 +9,40 @@ --f7-text-editor-button-size: 28px; --f7-text-editor-button-icon-size: 20px; --f7-text-editor-button-margin: 2px; - --f7-text-editor-button-border-radius: 2px; .light-vars({ --f7-text-editor-text-color: #000; --f7-text-editor-bg-color: #fff; - --f7-text-editor-border-color: rgba(0,0,0,0.1); - --f7-text-editor-toolbar-bg-color: #fff; - --f7-text-editor-button-text-color: #333; --f7-text-editor-button-divider-color: rgba(0,0,0,0.15); --f7-text-editor-placeholder-color: rgba(0,0,0,0.35); }); .dark-vars({ --f7-text-editor-bg-color: #121212; - --f7-text-editor-border-color: rgba(255,255,255,0.1); - --f7-text-editor-toolbar-bg-color: #202020; --f7-text-editor-text-color: #fff; --f7-text-editor-placeholder-color: rgba(255,255,255,0.35); - --f7-text-editor-button-text-color: #fff; --f7-text-editor-button-divider-color: rgba(255,255,255,0.15); }); } .ios-vars({ --f7-text-editor-toolbar-padding: 6px; + --f7-text-editor-button-border-radius: 2px; .light-vars({ --f7-text-editor-toolbar-border-color: rgba(0,0,0,0.25); + --f7-text-editor-toolbar-bg-color: #fff; + --f7-text-editor-border-color: rgba(0,0,0,0.1); + --f7-text-editor-button-text-color: #333; }); .dark-vars({ --f7-text-editor-toolbar-bg-color: #121212; --f7-text-editor-toolbar-border-color: rgba(255,255,255,0.1); + --f7-text-editor-toolbar-bg-color: #202020; + --f7-text-editor-border-color: rgba(255,255,255,0.1); + --f7-text-editor-button-text-color: #fff; }); }); .md-vars({ + --f7-text-editor-button-border-radius: 8px; --f7-text-editor-toolbar-padding: 8px; - --f7-text-editor-toolbar-box-shadow: 0px 2px 3px -1px rgba(0,0,0,0.25); + --f7-text-editor-toolbar-bg-color: var(--f7-md-surface-1); + --f7-text-editor-border-color: var(--f7-md-outline); + --f7-text-editor-button-text-color: var(--f7-md-on-surface); }); diff --git a/src/core/components/text-editor/text-editor.less b/src/core/components/text-editor/text-editor.less index 5346e5af4b..f71c95267b 100644 --- a/src/core/components/text-editor/text-editor.less +++ b/src/core/components/text-editor/text-editor.less @@ -27,7 +27,6 @@ top: 0; padding: var(--f7-text-editor-toolbar-padding); flex-shrink: 0; - box-shadow: var(--f7-text-editor-toolbar-box-shadow); box-sizing: border-box; .hairline(bottom, var(--f7-text-editor-toolbar-border-color)); }