From bd4ffc5e1d6cd17ef1ce20dcea316286b935d188 Mon Sep 17 00:00:00 2001 From: joyqi Date: Sun, 21 Mar 2021 01:15:19 +0800 Subject: [PATCH] Improve mobile UI --- admin/common-js.php | 2 +- admin/css/style.css | 8 ++++---- admin/src/scss/_header.scss | 4 ++-- admin/src/scss/components/_editor.scss | 3 ++- admin/src/scss/style.scss | 1 - 5 files changed, 9 insertions(+), 9 deletions(-) diff --git a/admin/common-js.php b/admin/common-js.php index 920f2b1f..05f3060b 100644 --- a/admin/common-js.php +++ b/admin/common-js.php @@ -94,7 +94,7 @@ ul.on('click touchend', '.parent a', function (e) { nav.removeClass('noexpanded').addClass('expanded'); - if ($(window).width() < 576) { + if ($(window).width() < 576 && e.type == 'click') { return false; } }).find('.child') diff --git a/admin/css/style.css b/admin/css/style.css index 2871b208..07cd285e 100644 --- a/admin/css/style.css +++ b/admin/css/style.css @@ -191,8 +191,8 @@ select { border: 1px solid #CCC; height: 28px; } .typecho-head-nav button.menu-bar.focus + #typecho-nav-list > ul .child li { border-bottom: 1px solid #383D45; } .typecho-head-nav button.menu-bar.focus + #typecho-nav-list > ul .child li.return { display: block; text-align: center; font-size: 12px; } .typecho-head-nav button.menu-bar.focus + #typecho-nav-list > ul .child li.return a { color: #777; } - .typecho-head-nav button.menu-bar.focus + #typecho-nav-list.expanded { animation: out .3s ease-out forwards; } - .typecho-head-nav button.menu-bar.focus + #typecho-nav-list.noexpanded { animation: in .3s ease-out forwards; } } + .typecho-head-nav button.menu-bar.focus + #typecho-nav-list.expanded { animation: out .15s ease-out forwards; } + .typecho-head-nav button.menu-bar.focus + #typecho-nav-list.noexpanded { animation: in .15s ease-out forwards; } } /** 注脚 */ .typecho-foot { padding: 4em 0 3em; color: #999; line-height: 1.8; text-align: center; } @@ -432,7 +432,7 @@ a.operate-reply { color: #545c30; } .typecho-post-area .submit .right button { margin-left: 5px; } -.typecho-post-area .right { float: right; padding-left: 24px; } +.typecho-post-area .right { float: right; } .typecho-post-area .left { float: left; } @@ -871,7 +871,7 @@ a.operate-reply { color: #545c30; } .preview #btn-cancel-preview { display: inline-block; } -@media (max-width: 575px) { #wmd-spacer2, #wmd-olist-button, #wmd-ulist-button, #wmd-heading-button, #wmd-hr-button, #wmd-more-button, #wmd-spacer3, #wmd-undo-button, #wmd-redo-button, #wmd-spacer4, #wmd-fullscreen-button, #wmd-exit-fullscreen-button { display: none; } } +@media (max-width: 575px) { #wmd-spacer2, #wmd-olist-button, #wmd-ulist-button, #wmd-heading-button, #wmd-hr-button, #wmd-more-button, #wmd-spacer3, #wmd-undo-button, #wmd-redo-button, #wmd-spacer4, #wmd-fullscreen-button, #wmd-exit-fullscreen-button, #btn-fullscreen-upload { display: none; } } /** Jquery Timepicker */ #ui-datepicker-div { display: none; margin-top: -1px; padding: 10px; border: 1px solid #D9D9D6; background: #FFF; } diff --git a/admin/src/scss/_header.scss b/admin/src/scss/_header.scss index e2d45103..d66ed72b 100644 --- a/admin/src/scss/_header.scss +++ b/admin/src/scss/_header.scss @@ -206,11 +206,11 @@ $color-nav-child-focus: #6DA1BB; } &.expanded { - animation: out .3s ease-out forwards; + animation: out .15s ease-out forwards; } &.noexpanded { - animation: in .3s ease-out forwards; + animation: in .15s ease-out forwards; } } } diff --git a/admin/src/scss/components/_editor.scss b/admin/src/scss/components/_editor.scss index a9156336..3805b907 100644 --- a/admin/src/scss/components/_editor.scss +++ b/admin/src/scss/components/_editor.scss @@ -321,7 +321,8 @@ #wmd-redo-button, #wmd-spacer4, #wmd-fullscreen-button, - #wmd-exit-fullscreen-button { + #wmd-exit-fullscreen-button, + #btn-fullscreen-upload { display: none; } } \ No newline at end of file diff --git a/admin/src/scss/style.scss b/admin/src/scss/style.scss index 4ac57820..c95d9f73 100644 --- a/admin/src/scss/style.scss +++ b/admin/src/scss/style.scss @@ -712,7 +712,6 @@ a.operate-reply { .typecho-post-area .right { float: right; - padding-left: 24px; } .typecho-post-area .left {