Просмотр исходного кода

#3661 Move tailwind in core templates - Buttons.

RomanL 4 лет назад
Родитель
Сommit
cf933754d1

+ 6 - 6
inc/js/classes/BxDolMenuMoreAuto.js

@@ -121,10 +121,10 @@ BxDolMenuMoreAuto.prototype._moveToSubmenu = function(oMenu, oItemMore, oItemMor
             oItem.addClass('bx-def-color-bg-hl-hover');
             oItem.find('a').each(function() {
                 if($(this).hasClass('bx-btn'))
-                    $(this).removeClass('bx-btn').addClass('!bx-btn');
+                    $(this).removeClass('bx-btn').addClass('bx-nobtn');
 
                 if($(this).hasClass('bx-btn-height'))
-                    $(this).removeClass('bx-btn-height').addClass('!bx-btn-height');
+                    $(this).removeClass('bx-btn-height').addClass('bx-nobtn-height');
             });
 
             if(!oSubmenuItemFirst.length)
@@ -163,11 +163,11 @@ BxDolMenuMoreAuto.prototype._moveFromSubmenu = function(oMenu, oItemMore, oItemM
 
         oItem.removeClass('bx-def-color-bg-hl-hover');
         oItem.find('a').each(function() {
-            if($(this).hasClass('!bx-btn'))
-                $(this).removeClass('!bx-btn').addClass('bx-btn');
+            if($(this).hasClass('bx-nobtn'))
+                $(this).removeClass('bx-nobtn').addClass('bx-btn');
 
-            if($(this).hasClass('!bx-btn-height'))
-                $(this).removeClass('!bx-btn-height').addClass('bx-btn-height');
+            if($(this).hasClass('bx-nobtn-height'))
+                $(this).removeClass('bx-nobtn-height').addClass('bx-btn-height');
         });
 
         oItemMore.before(oItem.detach());

+ 0 - 1
modules/boonex/decorous/data/template/system/css/common.css

@@ -31,7 +31,6 @@
 }
 .bx-btn .sys-icon {
     font-size: 0.875rem !important;
-    line-height: 1.9rem !important;
 }
 
 @keyframes loadingCircle{100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}[bx-click-animating='true']{position:relative}html{--bx-wave-shadow-color:#1890ff}

+ 3 - 0
modules/boonex/decorous/data/template/system/css/default.less

@@ -836,6 +836,9 @@
         font-size: @bx-font-size-button;
         font-weight: @bx-font-weight-button;
         color: @bx-font-color-button;
+        
+        padding-top: 0px;
+        padding-bottom: 0px;
     }
     .bx-btn-height {
         height: @bx-height-button;

+ 0 - 7
modules/boonex/lucid/data/template/system/css/common.css

@@ -6,13 +6,6 @@
     border-bottom: 1px solid transparent;
 }
 
-/* --- Buttons --- */
-.bx-btn i,
-.bx-btn u {
-    display: inline-block;
-    vertical-align: top !important;
-}
-
 /* --- Popup boxes --- */
 .bx-popup {    
 	-moz-box-shadow: none;

+ 3 - 0
modules/boonex/lucid/data/template/system/css/default.less

@@ -890,6 +890,9 @@
         font-size: @bx-font-size-button;
         font-weight: @bx-font-weight-button;
         color: @bx-font-color-button;
+        
+        padding-top: 0px;
+        padding-bottom: 0px;
     }
     .bx-btn.bx-btn-primary {
         .box-sizing(@base-input-box-sizing);

+ 4 - 0
modules/boonex/ocean/data/template/system/css/menu.css

@@ -52,4 +52,8 @@ ul.bx-menu-toolbar li a .sys-icon-a {
 .bx-menu-main-submenu.bx-menu-more-auto .bx-menu-submenu-more-auto .bx-menu-item .bx-btn,
 .bx-menu-custom.bx-menu-custom-hor.bx-menu-more-auto .bx-menu-submenu-more-auto .bx-menu-item .bx-btn {
     color: #29789c;
+}
+
+.bx-menu-main-submenu.bx-menu-more-auto .bx-menu-item.bx-menu-item-more-auto a, .bx-menu-custom.bx-menu-custom-hor.bx-menu-more-auto .bx-menu-item.bx-menu-item-more-auto a {
+    padding: 0.5rem;
 }

+ 0 - 6
modules/boonex/protean/data/template/system/css/common.css

@@ -5,12 +5,6 @@ a {
     transition: color .1s ease;
 }
 
-/* --- Buttons --- */
-.bx-btn i,
-.bx-btn u {
-    vertical-align: top !important;
-}
-
 /* --- Loading indicator --- */
 .bx-loading-ajax-btn {
     margin-left: 10px;

+ 4 - 1
modules/boonex/protean/data/template/system/css/default.less

@@ -796,6 +796,9 @@
         font-size: @bx-font-size-button;
         font-weight: @bx-font-weight-button;
         color: @bx-font-color-button;
+        
+        padding-top: 0px;
+        padding-bottom: 0px;
     }
     .bx-btn.bx-btn-primary {
         .box-sizing(@base-input-box-sizing);
@@ -1050,7 +1053,7 @@
         .box-sizing(@base-input-box-sizing);
 
         height: @bx-height-button-small;
-        line-height: (@bx-height-button-small - 0.125 * @bx-border-width-button-small);
+        line-height: (@bx-height-button-small - 0.125 * @bx-border-width-button-small - 0.5rem);
 
         .background-color (@bx-color-button-small);
 

+ 3 - 4
template/css/common.css

@@ -758,10 +758,6 @@ svg .gray .outer .p2 {
     background-color: #79bd9a;
     text-decoration:none;
 }
-.bx-btn{
-	padding-top:0px;
-	padding-bottom:0px;    
-}
 A.bx-btn{
     display: inline-block
 }
@@ -773,6 +769,9 @@ A.bx-btn{
     background-size:1.2em 1.2em;
     background-position:center center;
 }
+.bx-btn .bx-def-valign-center{
+    height: 100%;
+}
 .bx-btn u {
     margin-left: 10px;
     text-decoration: none;

+ 0 - 17
template/css/editor.less

@@ -1,20 +1,3 @@
-@import 'default.less';
-
-body, td, pre {
-    .bx-def-font;
-}
-
-h1 {
-	.bx-def-font-h1;
-}
-
-h2 {
-	.bx-def-font-h2;
-}
-
-h3 {
-	.bx-def-font-h3;
-}
 
 blockquote {
     /* NOTE: copied from common.css */

+ 3 - 3
template/scripts/BxBaseServices.php

@@ -78,9 +78,9 @@ class BxBaseServices extends BxDol implements iBxDolProfileService
                 /**
                  * Note. For now Tailwind isn't needed in Studio.
                  */
-                list($sPageUrl, $sPageParams) = bx_get_base_url_inline();
-                if(!empty($sPageUrl) && strncmp($sPageUrl, BX_DOL_URL_STUDIO, strlen(BX_DOL_URL_STUDIO)) == 0)
-                    break;
+                //list($sPageUrl, $sPageParams) = bx_get_base_url_inline();
+               // if(!empty($sPageUrl) && strncmp($sPageUrl, BX_DOL_URL_STUDIO, strlen(BX_DOL_URL_STUDIO)) == 0)
+                //    break;
 
                 $sResult = '{dir_plugins_public}tailwind/css/|tailwind.min.css';
                 break;