mapbox/mapbox-gl-js

Dash line has a tail with` round`line cap

Open

#10.218 geöffnet am 16. Dez. 2020

Auf GitHub ansehen
 (0 Kommentare) (0 Reaktionen) (1 zugewiesene Person)JavaScript (2.203 Forks)batch import
bug :lady_beetle:good first issue

Repository-Metriken

Stars
 (10.532 Stars)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

mapbox-gl-js version: v.1.x

Steps to Trigger Behavior

Use the following style, the rendered dash line has a redundant tail

{
"version": 8,
"metadata": {
  "test": {
    "width": 64,
    "height": 64
  }
},
"sources": {
  "geojson": {
    "type": "geojson",
    "data": {
      "type": "LineString",
      "coordinates": [
        [
          -10,
          0
        ],
        [
          10,
          0
        ]
      ]
    }
  }
},
"layers": [
  {
    "id": "line",
    "type": "line",
    "source": "geojson",
    "layout": {
      "line-cap": "round"
    },
    "paint": {
      "line-width": 8,
      "line-dasharray": [1, -2, -1, 1],
      "line-color": "blue"
    }
  }
]
}

Expected Behavior

dash line is rendered without tail.

Actual Behavior

cc: @zmiao

Contributor Guide