From ec62582770d206977c282410a1de3788e793fb83 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philipp=20Ku=CC=88hn?= Date: Sat, 5 Dec 2020 23:27:50 +0100 Subject: [PATCH] add color and size --- docs/src/demos/Examples/Drawing/Component.vue | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/docs/src/demos/Examples/Drawing/Component.vue b/docs/src/demos/Examples/Drawing/Component.vue index 08437e25..c12e192d 100644 --- a/docs/src/demos/Examples/Drawing/Component.vue +++ b/docs/src/demos/Examples/Drawing/Component.vue @@ -1,5 +1,12 @@ @@ -35,6 +44,8 @@ export default { data() { return { + color: '#000000', + size: 2, currentId: uuid(), ptdata: [], path: null, @@ -63,6 +74,8 @@ export default { ...lines, { id: this.currentId, + color: this.color, + size: this.size, d, }, ], @@ -81,6 +94,8 @@ export default { .data([this.ptdata]) .attr('id', `id-${this.currentId}`) .attr('d', this.line) + .attr('stroke', this.color) + .attr('stroke-width', this.size) const moveEvent = event.type === 'mousedown' ? 'mousemove' @@ -139,8 +154,8 @@ export default { path { fill: none; - stroke: #000; - stroke-width: 2; + stroke-linecap: round; + stroke-linejoin: round; } }