From c61ca90905f43436b7888f24ec11e35ce901acb0 Mon Sep 17 00:00:00 2001 From: hamidafghan Date: Tue, 24 Nov 2020 10:36:09 +0430 Subject: [PATCH] Add stroke width --- src/Models/HasStroke.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/Models/HasStroke.php b/src/Models/HasStroke.php index 54cb923..f8f12b7 100644 --- a/src/Models/HasStroke.php +++ b/src/Models/HasStroke.php @@ -7,6 +7,7 @@ trait HasStroke { private $stroke; + private $width; public function initStroke() { @@ -17,6 +18,7 @@ private function defaultStroke() { return [ 'curve' => 'straight', + 'width' => 4 ]; } @@ -34,6 +36,13 @@ public function setStraightCurve() return $this; } + public function setStrokeWidth($width) + { + data_set($this->stroke, 'width', $width); + + return $this; + } + protected function strokeToArray() { return [