File tree Expand file tree Collapse file tree 6 files changed +10
-5
lines changed Expand file tree Collapse file tree 6 files changed +10
-5
lines changed Original file line number Diff line number Diff line change
1
+ if ($this .' .ID' ) { return $this .' .ID' }
2
+ return ' turtle'
Original file line number Diff line number Diff line change 1
1
$segments = @ (
2
2
" <svg xmlns='http://www.w3.org/2000/svg' width='0%' height='0%'>"
3
3
" <defs>"
4
- " <mask id='turtle -mask'>"
4
+ " <mask id='$ ( $this .Id ) -mask'>"
5
5
$this.Symbol.OuterXml -replace ' \<\?[^\>]+\>'
6
6
" </mask>"
7
7
" </defs>"
Original file line number Diff line number Diff line change 1
1
@ (
2
- " <path id='turtle -path' d='$ ( $this.PathData ) ' stroke='$ (
2
+ " <path id='$ ( $this .id ) -path' d='$ ( $this.PathData ) ' stroke='$ (
3
3
if ($this.Stroke ) { $this.Stroke } else { ' currentColor' }
4
4
) ' stroke-width='$ (
5
5
if ($this.StrokeWidth ) { $this.StrokeWidth } else { ' 0.1%' }
Original file line number Diff line number Diff line change 1
1
$segments = @ (
2
2
" <svg xmlns='http://www.w3.org/2000/svg' width='0%' height='0%'>"
3
3
" <defs>"
4
- " <mask id='turtle -mask'>"
4
+ " <mask id='$ ( $this .ID ) -mask'>"
5
5
$this.Pattern.OuterXml -replace ' \<\?[^\>]+\>'
6
6
" </mask>"
7
7
" </defs>"
Original file line number Diff line number Diff line change @@ -15,14 +15,14 @@ param()
15
15
16
16
@ (
17
17
" <svg xmlns='http://www.w3.org/2000/svg' width='100%' height='100%' transform-origin='50% 50%'>"
18
- " <symbol id='turtle -symbol' viewBox='$ ( $this.ViewBox ) ' transform-origin='50% 50%'>"
18
+ " <symbol id='$ ( $this .ID ) -symbol' viewBox='$ ( $this.ViewBox ) ' transform-origin='50% 50%'>"
19
19
$this.PathElement.OuterXml
20
20
" </symbol>"
21
21
$ (
22
22
if ($this.BackgroundColor ) {
23
23
" <rect width='10000%' height='10000%' x='-5000%' y='-5000%' fill='$ ( $this.BackgroundColor ) ' transform-origin='50% 50%' />"
24
24
}
25
25
)
26
- " <use href='#turtle -symbol' width='100%' height='100%' transform-origin='50% 50%' />"
26
+ " <use href='#$ ( $this .ID ) -symbol' width='100%' height='100%' transform-origin='50% 50%' />"
27
27
" </svg>"
28
28
) -join ' ' -as [xml ]
Original file line number Diff line number Diff line change
1
+ param ([string ]$Value )
2
+
3
+ $this | Add-Member NoteProperty ' .ID' $Value - Force
You can’t perform that action at this time.
0 commit comments