Skip to content

Commit 230b706

Browse files
authored
Merge pull request #11 from hamidafghan/ifix-stroke-width
Added stroke width customization
2 parents 8b0bb9c + c61ca90 commit 230b706

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/Models/HasStroke.php

+9
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
trait HasStroke
88
{
99
private $stroke;
10+
private $width;
1011

1112
public function initStroke()
1213
{
@@ -17,6 +18,7 @@ private function defaultStroke()
1718
{
1819
return [
1920
'curve' => 'straight',
21+
'width' => 4
2022
];
2123
}
2224

@@ -34,6 +36,13 @@ public function setStraightCurve()
3436
return $this;
3537
}
3638

39+
public function setStrokeWidth($width)
40+
{
41+
data_set($this->stroke, 'width', $width);
42+
43+
return $this;
44+
}
45+
3746
protected function strokeToArray()
3847
{
3948
return [

0 commit comments

Comments
 (0)