From 8159d37f3534df609fc890dc1fba55d83e99839d Mon Sep 17 00:00:00 2001 From: "wilbur.yu" Date: Mon, 21 Dec 2020 21:00:19 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BD=BF=20InputNumber=20=E7=BB=84=E4=BB=B6?= =?UTF-8?q?=E7=9A=84=20min(),=20max(),=20step()=20=E6=94=AF=E6=8C=81?= =?UTF-8?q?=E6=B5=AE=E7=82=B9=E7=9A=84=E8=AE=BE=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Components/Form/InputNumber.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/Components/Form/InputNumber.php b/src/Components/Form/InputNumber.php index 1692c3c..a112cd2 100644 --- a/src/Components/Form/InputNumber.php +++ b/src/Components/Form/InputNumber.php @@ -29,7 +29,7 @@ class InputNumber extends Component protected $max = 999999999; /** - * @var int + * @var int|float */ protected $step = 1; protected $stepStrictly = false; @@ -64,10 +64,10 @@ static public function make($value = 0) /** * 设置计数器允许的最小值 - * @param int $min + * @param int|float $min * @return $this */ - public function min(int $min) + public function min($min) { $this->min = $min; return $this; @@ -75,10 +75,10 @@ public function min(int $min) /** * 设置计数器允许的最大值 - * @param int $max + * @param int|float $max * @return $this */ - public function max(int $max) + public function max($max) { $this->max = $max; return $this; @@ -86,10 +86,10 @@ public function max(int $max) /** * 计数器步长 - * @param int $step + * @param int|float $step * @return $this */ - public function step(int $step) + public function step($step) { $this->step = $step; return $this;