Skip to content

Commit 6d23add

Browse files
Name every shape
1 parent 7a67cc6 commit 6d23add

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

src/Components/ChartShape.php

+4-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,10 @@ public function __construct(
3232

3333
protected function initialize(): static
3434
{
35-
$this->shape = $this->slide->raw()->createChartShape();
35+
$this->shape = $this->slide
36+
->raw()
37+
->createChartShape()
38+
->setName(str()->random());
3639

3740
return $this;
3841
}

src/Components/Table/Table.php

+7-3
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,18 @@ class Table extends Component
1818
WithShape;
1919

2020
public function __construct(
21-
protected int $columns = 1,
21+
protected int $columns = 1,
2222
protected array $rows = [],
23-
) {
23+
)
24+
{
2425
}
2526

2627
protected function initialize(): static
2728
{
28-
$this->shape = $this->slide->raw()->createTableShape($this->columns);
29+
$this->shape = $this->slide
30+
->raw()
31+
->createTableShape($this->columns)
32+
->setName(str()->random());
2933

3034
return $this;
3135
}

0 commit comments

Comments
 (0)