From d79c4887a977fd05397ffbd09de678b865987c00 Mon Sep 17 00:00:00 2001 From: Zhangyu Date: Thu, 18 Apr 2024 02:25:53 +0000 Subject: [PATCH] + zin: add thinkstepdetail wg. --- lib/zin/func.php | 1 + lib/zin/wg/thinkstepdetail/v1.php | 68 +++++++++++++++++++++++++++++++ 2 files changed, 69 insertions(+) create mode 100644 lib/zin/wg/thinkstepdetail/v1.php diff --git a/lib/zin/func.php b/lib/zin/func.php index a849bc65cf..4c6bc7b251 100644 --- a/lib/zin/func.php +++ b/lib/zin/func.php @@ -197,3 +197,4 @@ function thinkCheckbox(): thinkCheckbox {return createWg('thinkCheckbox', func_g function thinkOptions(): thinkOptions{return createWg('thinkOptions', func_get_args());} function thinkTableInput(): thinkTableInput {return createWg('thinkTableInput', func_get_args());} function thinkInput(): thinkInput {return createWg('thinkInput', func_get_args());} +function thinkStepDetail(): thinkStepDetail {return createWg('thinkStepDetail', func_get_args());} diff --git a/lib/zin/wg/thinkstepdetail/v1.php b/lib/zin/wg/thinkstepdetail/v1.php new file mode 100644 index 0000000000..f3431f4ff7 --- /dev/null +++ b/lib/zin/wg/thinkstepdetail/v1.php @@ -0,0 +1,68 @@ +prop(array('title', 'desc')); + return div + ( + div + ( + setClass('flex items-start justify-between'), + setStyle(array('padding' => '24px 48px 8px')), + div + ( + setClass('text-md leading-6 font-medium'), + setStyle(array('color' => '#313C52')), + $title + ), + div + ( + setClass('w-12 ml-2'), + setStyle(array('min-width' => '48px')), + a + ( + icon('edit', setClass('border-0 mr-2 w-4')) + ), + a + ( + icon('trash', setClass('border-0 w-4')) + ) + ) + ), + div + ( + setClass('text-sm leading-6'), + setStyle(array('color' => '#9EA3B0', 'padding' => '0 48px')), + $desc + ) + ); + } + + protected function buildBody(): array + { + return array( + $this->detailHeading(), + ); + } + protected function build(): array + { + return array + ( + $this->buildBody() + ); + } +}