Skip to content
This repository has been archived by the owner on Oct 6, 2023. It is now read-only.

Commit

Permalink
add the case of 'esriSLSNull' style for outline (#128)
Browse files Browse the repository at this point in the history
* add the case of 'esriSLSNull' style

* passing tests

PolygonSymbolSpec.js

* passing tests
  • Loading branch information
ynunokawa authored and jgravois committed Aug 17, 2016
1 parent 4cb299b commit 08835ff
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Symbols/PointSymbol.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ export var PointSymbol = Symbol.extend({
},

_fillStyles: function () {
if (this._symbolJson.outline && this._symbolJson.size > 0) {
if (this._symbolJson.outline && this._symbolJson.size > 0 && this._symbolJson.outline.style !== 'esriSLSNull') {
this._styles.stroke = true;
this._styles.weight = this.pixelValue(this._symbolJson.outline.width);
this._styles.color = this.colorValue(this._symbolJson.outline.color);
Expand Down
6 changes: 5 additions & 1 deletion src/Symbols/PolygonSymbol.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,11 @@ export var PolygonSymbol = Symbol.extend({
initialize: function (symbolJson, options) {
Symbol.prototype.initialize.call(this, symbolJson, options);
if (symbolJson) {
this._lineStyles = lineSymbol(symbolJson.outline, options).style();
if (symbolJson.outline && symbolJson.outline.style === 'esriSLSNull') {
this._lineStyles = { weight: 0 };
} else {
this._lineStyles = lineSymbol(symbolJson.outline, options).style();
}
this._fillStyles();
}
},
Expand Down

0 comments on commit 08835ff

Please sign in to comment.