Allow stroke width to go to 0. Fixes #14.
rodzic
6f71305dd2
commit
5c903c0794
|
@ -72,7 +72,7 @@ function reactifySvgSymbolElement(
|
|||
let vectorEffect;
|
||||
fill = getColor(ctx, fill);
|
||||
stroke = getColor(ctx, stroke);
|
||||
if (strokeWidth !== undefined && ctx.uniformStrokeWidth) {
|
||||
if (strokeWidth !== undefined && typeof ctx.uniformStrokeWidth === "number") {
|
||||
strokeWidth = ctx.uniformStrokeWidth;
|
||||
vectorEffect = "non-scaling-stroke";
|
||||
}
|
||||
|
|
|
@ -42,7 +42,7 @@ export const SymbolContextWidget: React.FC<{
|
|||
<label htmlFor="strokeWidth">Stroke width: </label>
|
||||
<input
|
||||
type="range"
|
||||
min={0.5}
|
||||
min={0}
|
||||
max={3}
|
||||
step={0.1}
|
||||
value={ctx.uniformStrokeWidth}
|
||||
|
|
Ładowanie…
Reference in New Issue