From eb279822cc75ed21f93d3e3315b2cfd4978acb0d Mon Sep 17 00:00:00 2001 From: liugang Date: Mon, 19 Jun 2023 15:47:00 +0800 Subject: [PATCH] + bug: add common files to generate props of page header. --- module/bug/css/common.ui.css | 2 ++ module/bug/ui/common.html.php | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+) create mode 100644 module/bug/css/common.ui.css create mode 100644 module/bug/ui/common.html.php diff --git a/module/bug/css/common.ui.css b/module/bug/css/common.ui.css new file mode 100644 index 0000000000..7c56615804 --- /dev/null +++ b/module/bug/css/common.ui.css @@ -0,0 +1,2 @@ +.panel-heading.modal-heading {justify-content: flex-start; padding-bottom: 0px;} +.panel-heading.modal-heading .panel-title {font-weight: 400; justify-content: flex-end; width: 5rem; font-size: var(--font-size-page)} diff --git a/module/bug/ui/common.html.php b/module/bug/ui/common.html.php new file mode 100644 index 0000000000..1f12992206 --- /dev/null +++ b/module/bug/ui/common.html.php @@ -0,0 +1,34 @@ + + * @package bug + * @link https://www.zentao.net + */ +namespace zin; + +function setCommonProps($bug, $title) +{ + $items[] = set::shadow(false); + $items[] = set::title($title); + $items[] = set::headingClass('modal-heading'); + $items[] = set::class('border-b'); + $items[] = set::actions(array('submit')); + $items[] = set::submitBtnText($title); + $items[] = to::headingActions + ( + entityLabel + ( + setClass('my-3 gap-x-3'), + set::level(1), + set::text($bug->title), + set::entityID($bug->id), + set::reverse(true), + ) + ); + + return $items; +}