From 7230fcffdd934d3f341224540e274db82c23c84b Mon Sep 17 00:00:00 2001 From: dingyongliang Date: Mon, 10 Apr 2023 14:06:09 +0800 Subject: [PATCH] * zin: add .menu-dtable-actions style. --- module/project/ui/browse.html.php | 2 +- zin/wg/dtable/css/v1.css | 5 +++++ zin/wg/dtable/v1.php | 5 +++++ 3 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 zin/wg/dtable/css/v1.css diff --git a/module/project/ui/browse.html.php b/module/project/ui/browse.html.php index a3a3629671..d2ec2e9b0f 100644 --- a/module/project/ui/browse.html.php +++ b/module/project/ui/browse.html.php @@ -51,7 +51,7 @@ foreach($setting as $value) 'delete' => array('icon'=> 'icon-trash', 'hint'=> '删除', 'text' => '删除'), 'other' => array('type'=> 'dropdown', 'hint'=> '其他操作', 'caret' => true), 'link' => array('icon'=> 'icon-link', 'text'=> '关联产品', 'name' => 'link'), - 'more' => array('icon'=> 'icon-ellipsis-v', 'hint'=> '更多', 'type' => 'dropdown', 'caret' => false, 'className' => 'menu-dtable-actions'), + 'more' => array('icon'=> 'icon-ellipsis-v', 'hint'=> '更多', 'type' => 'dropdown', 'caret' => false), 'whitelist' => array('icon'=> 'icon-shield-check', 'text'=> '项目白名单', 'name' => 'whitelist'), ); break; diff --git a/zin/wg/dtable/css/v1.css b/zin/wg/dtable/css/v1.css new file mode 100644 index 0000000000..5f1714c784 --- /dev/null +++ b/zin/wg/dtable/css/v1.css @@ -0,0 +1,5 @@ +.menu.menu-dtable-actions {display: flex; min-width: auto;} +.menu.menu-dtable-actions .icon {position: static!important; opacity: 1!important;} +.menu.menu-dtable-actions span.text {display: none;} +.menu.menu-dtable-actions > .menu-item > a {padding: 0;} +.menu.menu-dtable-actions > .menu-item > a:hover {background: none; color: var(--menu-hover-bg);} diff --git a/zin/wg/dtable/v1.php b/zin/wg/dtable/v1.php index 4231861ffd..7ee6affaea 100644 --- a/zin/wg/dtable/v1.php +++ b/zin/wg/dtable/v1.php @@ -5,6 +5,11 @@ class dtable extends wg { static $defineProps = 'className?:string="shadow rounded"'; + public static function getPageCSS() + { + return file_get_contents(__DIR__ . DS . 'css' . DS . 'v1.css'); + } + protected function build() { return zui::dtable(inherit($this));