@websy/websy-designs 1.7.0 → 1.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/websy-designs-es6.debug.js +27 -14
- package/dist/websy-designs-es6.js +41 -14
- package/dist/websy-designs-es6.min.js +1 -1
- package/dist/websy-designs.debug.js +27 -14
- package/dist/websy-designs.js +41 -14
- package/dist/websy-designs.min.css +1 -1
- package/dist/websy-designs.min.js +1 -1
- package/package.json +1 -1
|
@@ -2235,7 +2235,7 @@ class WebsyForm {
|
|
|
2235
2235
|
if (f.component) {
|
|
2236
2236
|
componentsToProcess.push(f)
|
|
2237
2237
|
html += `
|
|
2238
|
-
${i > 0 ? '-->' : ''}<div id='${this.elementId}_${f.field}_inputContainer' class='websy-input-container ${f.classes
|
|
2238
|
+
${i > 0 ? '-->' : ''}<div id='${this.elementId}_${f.field}_inputContainer' class='websy-input-container ${f.classes ? f.classes.join(' ') : ''}'>
|
|
2239
2239
|
${f.label ? `<label for="${f.field}">${f.label}</label>` : ''}${f.required === true ? '<span class="websy-form-required-value">*</span>' : ''}
|
|
2240
2240
|
<div id='${this.elementId}_input_${f.field}_component' class='form-component'></div>
|
|
2241
2241
|
<span id='${this.elementId}_${f.field}_error' class='websy-form-validation-error'></span>
|
|
@@ -2244,7 +2244,7 @@ class WebsyForm {
|
|
|
2244
2244
|
}
|
|
2245
2245
|
else if (f.type === 'longtext') {
|
|
2246
2246
|
html += `
|
|
2247
|
-
${i > 0 ? '-->' : ''}<div id='${this.elementId}_${f.field}_inputContainer' class='websy-input-container ${f.classes
|
|
2247
|
+
${i > 0 ? '-->' : ''}<div id='${this.elementId}_${f.field}_inputContainer' class='websy-input-container ${f.classes ? f.classes.join(' ') : ''}'>
|
|
2248
2248
|
${f.label ? `<label for="${f.field}">${f.label}</label>` : ''}${f.required === true ? '<span class="websy-form-required-value">*</span>' : ''}
|
|
2249
2249
|
<textarea
|
|
2250
2250
|
id="${this.elementId}_input_${f.field}"
|
|
@@ -2262,7 +2262,7 @@ class WebsyForm {
|
|
|
2262
2262
|
}
|
|
2263
2263
|
else {
|
|
2264
2264
|
html += `
|
|
2265
|
-
${i > 0 ? '-->' : ''}<div id='${this.elementId}_${f.field}_inputContainer' class='websy-input-container ${f.classes
|
|
2265
|
+
${i > 0 ? '-->' : ''}<div id='${this.elementId}_${f.field}_inputContainer' class='websy-input-container ${f.classes ? f.classes.join(' ') : ''}'>
|
|
2266
2266
|
${f.label ? `<label for="${f.field}">${f.label}</label>` : ''}${f.required === true ? '<span class="websy-form-required-value">*</span>' : ''}
|
|
2267
2267
|
<input
|
|
2268
2268
|
id="${this.elementId}_input_${f.field}"
|
|
@@ -2290,11 +2290,11 @@ class WebsyForm {
|
|
|
2290
2290
|
`
|
|
2291
2291
|
}
|
|
2292
2292
|
html += `
|
|
2293
|
-
--><button class="websy-btn submit ${this.options.submit.classes
|
|
2293
|
+
--><button class="websy-btn submit ${this.options.submit.classes ? this.options.submit.classes.join(' ') : ''}">${this.options.submit.text || 'Save'}</button>${this.options.cancel ? '<!--' : ''}
|
|
2294
2294
|
`
|
|
2295
2295
|
if (this.options.cancel) {
|
|
2296
2296
|
html += `
|
|
2297
|
-
--><button class="websy-btn cancel ${this.options.cancel.classes
|
|
2297
|
+
--><button class="websy-btn cancel ${this.options.cancel.classes ? this.options.cancel.classes.join(' ') : ''}">${this.options.cancel.text || 'Cancel'}</button>
|
|
2298
2298
|
`
|
|
2299
2299
|
}
|
|
2300
2300
|
html += `
|
|
@@ -7291,6 +7291,9 @@ this.render()
|
|
|
7291
7291
|
/* global d3 options WebsyUtils */
|
|
7292
7292
|
if (typeof options !== 'undefined') {
|
|
7293
7293
|
this.options = Object.assign({}, this.options, options)
|
|
7294
|
+
if (this.options.legendOptions) {
|
|
7295
|
+
this.legend.setOptions(this.options.legendOptions)
|
|
7296
|
+
}
|
|
7294
7297
|
}
|
|
7295
7298
|
if (!this.options.data) {
|
|
7296
7299
|
// tell the user no data has been provided
|
|
@@ -7352,12 +7355,19 @@ else {
|
|
|
7352
7355
|
}
|
|
7353
7356
|
if (this.options.legendPosition === 'top' || this.options.legendPosition === 'bottom') {
|
|
7354
7357
|
this.legendArea.style('width', '100%')
|
|
7358
|
+
if (this.legend.options.maxSize) {
|
|
7359
|
+
this.legendArea.style('height', `${this.legend.options.maxSize}px`)
|
|
7360
|
+
}
|
|
7355
7361
|
this.legend.options.align = 'center'
|
|
7356
7362
|
}
|
|
7357
7363
|
if (this.options.legendPosition === 'left' || this.options.legendPosition === 'right') {
|
|
7364
|
+
let longestLegendValue = legendData.reduce((a, b) => a.length > (b.value || '').length ? a : b.value, '')
|
|
7358
7365
|
this.legend.options.align = 'left'
|
|
7359
7366
|
this.legendArea.style('height', '100%')
|
|
7360
|
-
this.legendArea.style('width', this.legend.testWidth(
|
|
7367
|
+
this.legendArea.style('width', this.legend.testWidth(longestLegendValue) + 'px')
|
|
7368
|
+
if (this.legend.options.maxSize) {
|
|
7369
|
+
this.legendArea.style('width', `${this.legend.options.maxSize}px`)
|
|
7370
|
+
}
|
|
7361
7371
|
}
|
|
7362
7372
|
this.legend.data = legendData
|
|
7363
7373
|
let legendSize = this.legend.getSize()
|
|
@@ -7546,7 +7556,7 @@ else {
|
|
|
7546
7556
|
this.brushBandPadding = this.totalBandPadding / this.options.data.left.data.length
|
|
7547
7557
|
}
|
|
7548
7558
|
plotable = this.plotHeight - this.totalBandPadding
|
|
7549
|
-
noOfPoints = this.options.grouping === 'grouped' ? this.options.data.left.totalValueCount : this.options.data.left.data.length
|
|
7559
|
+
noOfPoints = this.options.grouping === 'grouped' && this.options.allowUnevenBands === true ? this.options.data.left.totalValueCount : this.options.data.left.data.length
|
|
7550
7560
|
noOfGroups = this.options.data.left.data.length
|
|
7551
7561
|
}
|
|
7552
7562
|
else {
|
|
@@ -7563,7 +7573,7 @@ else {
|
|
|
7563
7573
|
this.brushBandPadding = this.totalBandPadding / this.options.data.bottom.data.length
|
|
7564
7574
|
}
|
|
7565
7575
|
plotable = this.plotWidth - this.totalBandPadding
|
|
7566
|
-
noOfPoints = this.options.grouping === 'grouped' ? this.options.data.bottom.totalValueCount : this.options.data.bottom.data.length
|
|
7576
|
+
noOfPoints = this.options.grouping === 'grouped' && this.options.allowUnevenBands === true ? this.options.data.bottom.totalValueCount : this.options.data.bottom.data.length
|
|
7567
7577
|
noOfGroups = this.options.data.bottom.data.length
|
|
7568
7578
|
}
|
|
7569
7579
|
if (plotable / noOfPoints > this.options.maxBandWidth) {
|
|
@@ -7717,7 +7727,7 @@ else {
|
|
|
7717
7727
|
let pos = i * proposedBandWidth
|
|
7718
7728
|
this[`custom${customRangeSide}DetailRange`].push(start + adjustment + pos)
|
|
7719
7729
|
}
|
|
7720
|
-
acc += (this.options.grouping !== 'stacked' ? (d.valueCount || 1) : 1)
|
|
7730
|
+
acc += (this.options.grouping !== 'stacked' && this.options.allowUnevenBands === true ? (d.valueCount || 1) : 1)
|
|
7721
7731
|
let end = (this.widthForCalc / noOfPoints) * acc
|
|
7722
7732
|
// this.customBottomBrushRange.push((end + adjustment) * (this.plotWidth / this.widthForCalc))
|
|
7723
7733
|
return end + adjustment
|
|
@@ -7725,7 +7735,7 @@ else {
|
|
|
7725
7735
|
acc = 0
|
|
7726
7736
|
this[`custom${customRangeSide}BrushRange`] = [0, ...this.options.data[customRangeSideLC].data.map((d, index, arr) => {
|
|
7727
7737
|
let adjustment = (this.brushBandPadding * index) + this.brushBandPadding
|
|
7728
|
-
acc += (this.options.grouping !== 'stacked' ? (d.valueCount || 1) : 1)
|
|
7738
|
+
acc += (this.options.grouping !== 'stacked' && this.options.allowUnevenBands === true ? (d.valueCount || 1) : 1)
|
|
7729
7739
|
return ((this.options.orientation === 'vertical' ? this.plotWidth : this.plotHeight) / noOfPoints) * acc
|
|
7730
7740
|
})]
|
|
7731
7741
|
}
|
|
@@ -8704,8 +8714,8 @@ symbols.exit()
|
|
|
8704
8714
|
symbols
|
|
8705
8715
|
.attr('d', d => drawSymbol(d.y.size || series.symbolSize)(d))
|
|
8706
8716
|
.transition(this.transition)
|
|
8707
|
-
.attr('fill', series.fillSymbols ? series.color : 'white')
|
|
8708
|
-
.attr('stroke', series.color)
|
|
8717
|
+
.attr('fill', d => series.fillSymbols ? d.y.color || series.color : 'white')
|
|
8718
|
+
.attr('stroke', d => d.y.color || series.color)
|
|
8709
8719
|
.attr('transform', d => {
|
|
8710
8720
|
// let adjustment = (this.options.data[xAxis].scale === 'Time' || this.options.data[xAxis].scale === 'Linear') ? 0 : this.options.data[xAxis].bandWidth / 2
|
|
8711
8721
|
// if (this.options.orientation === 'horizontal') {
|
|
@@ -8733,8 +8743,8 @@ symbols.enter()
|
|
|
8733
8743
|
.append('path')
|
|
8734
8744
|
.attr('d', d => drawSymbol(d.y.size || series.symbolSize)(d))
|
|
8735
8745
|
// .transition(this.transition)
|
|
8736
|
-
.attr('fill', series.fillSymbols ? series.color : 'white')
|
|
8737
|
-
.attr('stroke', series.color)
|
|
8746
|
+
.attr('fill', d => series.fillSymbols ? d.y.color || series.color : 'white')
|
|
8747
|
+
.attr('stroke', d => d.y.color || series.color)
|
|
8738
8748
|
.attr('class', d => { return `symbol symbol_${series.key}` })
|
|
8739
8749
|
.attr('transform', d => {
|
|
8740
8750
|
let xIndex = this[xAxis + 'Axis'].domain().indexOf(d.x.value)
|
|
@@ -8975,6 +8985,9 @@ class WebsyLegend {
|
|
|
8975
8985
|
el.innerHTML = html
|
|
8976
8986
|
}
|
|
8977
8987
|
}
|
|
8988
|
+
setOptions (options) {
|
|
8989
|
+
this.options = Object.assign({}, this.options, options)
|
|
8990
|
+
}
|
|
8978
8991
|
testWidth (v) {
|
|
8979
8992
|
let html = this.getLegendItemHTML({value: v})
|
|
8980
8993
|
const el = document.createElement('div')
|
|
@@ -2508,11 +2508,11 @@ var WebsyForm = /*#__PURE__*/function () {
|
|
|
2508
2508
|
|
|
2509
2509
|
if (f.component) {
|
|
2510
2510
|
componentsToProcess.push(f);
|
|
2511
|
-
html += "\n ".concat(i > 0 ? '-->' : '', "<div id='").concat(_this16.elementId, "_").concat(f.field, "_inputContainer' class='websy-input-container ").concat(f.classes
|
|
2511
|
+
html += "\n ".concat(i > 0 ? '-->' : '', "<div id='").concat(_this16.elementId, "_").concat(f.field, "_inputContainer' class='websy-input-container ").concat(f.classes ? f.classes.join(' ') : '', "'>\n ").concat(f.label ? "<label for=\"".concat(f.field, "\">").concat(f.label, "</label>") : '').concat(f.required === true ? '<span class="websy-form-required-value">*</span>' : '', "\n <div id='").concat(_this16.elementId, "_input_").concat(f.field, "_component' class='form-component'></div>\n <span id='").concat(_this16.elementId, "_").concat(f.field, "_error' class='websy-form-validation-error'></span>\n </div><!--\n ");
|
|
2512
2512
|
} else if (f.type === 'longtext') {
|
|
2513
|
-
html += "\n ".concat(i > 0 ? '-->' : '', "<div id='").concat(_this16.elementId, "_").concat(f.field, "_inputContainer' class='websy-input-container ").concat(f.classes
|
|
2513
|
+
html += "\n ".concat(i > 0 ? '-->' : '', "<div id='").concat(_this16.elementId, "_").concat(f.field, "_inputContainer' class='websy-input-container ").concat(f.classes ? f.classes.join(' ') : '', "'>\n ").concat(f.label ? "<label for=\"".concat(f.field, "\">").concat(f.label, "</label>") : '').concat(f.required === true ? '<span class="websy-form-required-value">*</span>' : '', "\n <textarea\n id=\"").concat(_this16.elementId, "_input_").concat(f.field, "\"\n ").concat(f.required === true ? 'required' : '', " \n placeholder=\"").concat(f.placeholder || '', "\"\n data-user-type=\"").concat(f.type, "\"\n data-index=\"").concat(i, "\"\n name=\"").concat(f.field, "\" \n ").concat((f.attributes || []).join(' '), "\n class=\"websy-input websy-textarea\"\n ></textarea>\n <span id='").concat(_this16.elementId, "_").concat(f.field, "_error' class='websy-form-validation-error'></span>\n </div><!--\n ");
|
|
2514
2514
|
} else {
|
|
2515
|
-
html += "\n ".concat(i > 0 ? '-->' : '', "<div id='").concat(_this16.elementId, "_").concat(f.field, "_inputContainer' class='websy-input-container ").concat(f.classes
|
|
2515
|
+
html += "\n ".concat(i > 0 ? '-->' : '', "<div id='").concat(_this16.elementId, "_").concat(f.field, "_inputContainer' class='websy-input-container ").concat(f.classes ? f.classes.join(' ') : '', "'>\n ").concat(f.label ? "<label for=\"".concat(f.field, "\">").concat(f.label, "</label>") : '').concat(f.required === true ? '<span class="websy-form-required-value">*</span>' : '', "\n <input \n id=\"").concat(_this16.elementId, "_input_").concat(f.field, "\"\n ").concat(f.required === true ? 'required' : '', " \n type=\"").concat((f.type === 'expiry' ? 'text' : f.type === 'cvv' ? 'number' : f.type) || 'text', "\" \n data-user-type=\"").concat(f.type, "\"\n data-index=\"").concat(i, "\"\n class=\"websy-input\" \n ").concat((f.attributes || []).join(' '), "\n name=\"").concat(f.field, "\" \n placeholder=\"").concat(f.placeholder || '', "\"\n value=\"").concat(f.value || '', "\"\n valueAsDate=\"").concat(f.type === 'date' ? f.value : '', "\"\n oninvalidx=\"this.setCustomValidity('").concat(f.invalidMessage || 'Please fill in this field.', "')\"\n />\n <span id='").concat(_this16.elementId, "_").concat(f.field, "_error' class='websy-form-validation-error'></span>\n </div><!--\n ");
|
|
2516
2516
|
}
|
|
2517
2517
|
});
|
|
2518
2518
|
|
|
@@ -2520,10 +2520,10 @@ var WebsyForm = /*#__PURE__*/function () {
|
|
|
2520
2520
|
html += "\n --><div id='".concat(this.elementId, "_recaptcha' data-sitekey='").concat(ENVIRONMENT.RECAPTCHA_KEY, "' class='websy-form-recaptcha'></div>\n <div id='").concat(this.elementId, "_recaptchaError' class='websy-alert websy-alert-error websy-hidden'>Invalid recaptcha response</div><!--\n ");
|
|
2521
2521
|
}
|
|
2522
2522
|
|
|
2523
|
-
html += "\n --><button class=\"websy-btn submit ".concat(this.options.submit.classes
|
|
2523
|
+
html += "\n --><button class=\"websy-btn submit ".concat(this.options.submit.classes ? this.options.submit.classes.join(' ') : '', "\">").concat(this.options.submit.text || 'Save', "</button>").concat(this.options.cancel ? '<!--' : '', "\n ");
|
|
2524
2524
|
|
|
2525
2525
|
if (this.options.cancel) {
|
|
2526
|
-
html += "\n --><button class=\"websy-btn cancel ".concat(this.options.cancel.classes
|
|
2526
|
+
html += "\n --><button class=\"websy-btn cancel ".concat(this.options.cancel.classes ? this.options.cancel.classes.join(' ') : '', "\">").concat(this.options.cancel.text || 'Cancel', "</button>\n ");
|
|
2527
2527
|
}
|
|
2528
2528
|
|
|
2529
2529
|
html += " \n </form>\n <div id=\"".concat(this.elementId, "_validationFail\" class=\"websy-validation-failure\"></div>\n ");
|
|
@@ -8040,6 +8040,10 @@ var WebsyChart = /*#__PURE__*/function () {
|
|
|
8040
8040
|
/* global d3 options WebsyUtils */
|
|
8041
8041
|
if (typeof options !== 'undefined') {
|
|
8042
8042
|
this.options = _extends({}, this.options, options);
|
|
8043
|
+
|
|
8044
|
+
if (this.options.legendOptions) {
|
|
8045
|
+
this.legend.setOptions(this.options.legendOptions);
|
|
8046
|
+
}
|
|
8043
8047
|
}
|
|
8044
8048
|
|
|
8045
8049
|
if (!this.options.data) {// tell the user no data has been provided
|
|
@@ -8117,15 +8121,25 @@ var WebsyChart = /*#__PURE__*/function () {
|
|
|
8117
8121
|
|
|
8118
8122
|
if (this.options.legendPosition === 'top' || this.options.legendPosition === 'bottom') {
|
|
8119
8123
|
this.legendArea.style('width', '100%');
|
|
8124
|
+
|
|
8125
|
+
if (this.legend.options.maxSize) {
|
|
8126
|
+
this.legendArea.style('height', "".concat(this.legend.options.maxSize, "px"));
|
|
8127
|
+
}
|
|
8128
|
+
|
|
8120
8129
|
this.legend.options.align = 'center';
|
|
8121
8130
|
}
|
|
8122
8131
|
|
|
8123
8132
|
if (this.options.legendPosition === 'left' || this.options.legendPosition === 'right') {
|
|
8133
|
+
var longestLegendValue = legendData.reduce(function (a, b) {
|
|
8134
|
+
return a.length > (b.value || '').length ? a : b.value;
|
|
8135
|
+
}, '');
|
|
8124
8136
|
this.legend.options.align = 'left';
|
|
8125
8137
|
this.legendArea.style('height', '100%');
|
|
8126
|
-
this.legendArea.style('width', this.legend.testWidth(
|
|
8127
|
-
|
|
8128
|
-
|
|
8138
|
+
this.legendArea.style('width', this.legend.testWidth(longestLegendValue) + 'px');
|
|
8139
|
+
|
|
8140
|
+
if (this.legend.options.maxSize) {
|
|
8141
|
+
this.legendArea.style('width', "".concat(this.legend.options.maxSize, "px"));
|
|
8142
|
+
}
|
|
8129
8143
|
}
|
|
8130
8144
|
|
|
8131
8145
|
this.legend.data = legendData;
|
|
@@ -8346,7 +8360,7 @@ var WebsyChart = /*#__PURE__*/function () {
|
|
|
8346
8360
|
}
|
|
8347
8361
|
|
|
8348
8362
|
plotable = this.plotHeight - this.totalBandPadding;
|
|
8349
|
-
noOfPoints = this.options.grouping === 'grouped' ? this.options.data.left.totalValueCount : this.options.data.left.data.length;
|
|
8363
|
+
noOfPoints = this.options.grouping === 'grouped' && this.options.allowUnevenBands === true ? this.options.data.left.totalValueCount : this.options.data.left.data.length;
|
|
8350
8364
|
noOfGroups = this.options.data.left.data.length;
|
|
8351
8365
|
} else {
|
|
8352
8366
|
this.options.data.bottom.totalValueCount = this.options.data.bottom.data.reduce(function (a, b) {
|
|
@@ -8365,7 +8379,7 @@ var WebsyChart = /*#__PURE__*/function () {
|
|
|
8365
8379
|
}
|
|
8366
8380
|
|
|
8367
8381
|
plotable = this.plotWidth - this.totalBandPadding;
|
|
8368
|
-
noOfPoints = this.options.grouping === 'grouped' ? this.options.data.bottom.totalValueCount : this.options.data.bottom.data.length;
|
|
8382
|
+
noOfPoints = this.options.grouping === 'grouped' && this.options.allowUnevenBands === true ? this.options.data.bottom.totalValueCount : this.options.data.bottom.data.length;
|
|
8369
8383
|
noOfGroups = this.options.data.bottom.data.length;
|
|
8370
8384
|
}
|
|
8371
8385
|
|
|
@@ -8496,7 +8510,7 @@ var WebsyChart = /*#__PURE__*/function () {
|
|
|
8496
8510
|
_this46["custom".concat(customRangeSide, "DetailRange")].push(start + adjustment + pos);
|
|
8497
8511
|
}
|
|
8498
8512
|
|
|
8499
|
-
acc += _this46.options.grouping !== 'stacked' ? d.valueCount || 1 : 1;
|
|
8513
|
+
acc += _this46.options.grouping !== 'stacked' && _this46.options.allowUnevenBands === true ? d.valueCount || 1 : 1;
|
|
8500
8514
|
var end = _this46.widthForCalc / noOfPoints * acc; // this.customBottomBrushRange.push((end + adjustment) * (this.plotWidth / this.widthForCalc))
|
|
8501
8515
|
|
|
8502
8516
|
return end + adjustment;
|
|
@@ -8504,7 +8518,7 @@ var WebsyChart = /*#__PURE__*/function () {
|
|
|
8504
8518
|
acc = 0;
|
|
8505
8519
|
this["custom".concat(customRangeSide, "BrushRange")] = [0].concat(_toConsumableArray(this.options.data[customRangeSideLC].data.map(function (d, index, arr) {
|
|
8506
8520
|
var adjustment = _this46.brushBandPadding * index + _this46.brushBandPadding;
|
|
8507
|
-
acc += _this46.options.grouping !== 'stacked' ? d.valueCount || 1 : 1;
|
|
8521
|
+
acc += _this46.options.grouping !== 'stacked' && _this46.options.allowUnevenBands === true ? d.valueCount || 1 : 1;
|
|
8508
8522
|
return (_this46.options.orientation === 'vertical' ? _this46.plotWidth : _this46.plotHeight) / noOfPoints * acc;
|
|
8509
8523
|
})));
|
|
8510
8524
|
} // }
|
|
@@ -9428,7 +9442,11 @@ var WebsyChart = /*#__PURE__*/function () {
|
|
|
9428
9442
|
|
|
9429
9443
|
symbols.attr('d', function (d) {
|
|
9430
9444
|
return drawSymbol(d.y.size || series.symbolSize)(d);
|
|
9431
|
-
}).transition(this.transition).attr('fill',
|
|
9445
|
+
}).transition(this.transition).attr('fill', function (d) {
|
|
9446
|
+
return series.fillSymbols ? d.y.color || series.color : 'white';
|
|
9447
|
+
}).attr('stroke', function (d) {
|
|
9448
|
+
return d.y.color || series.color;
|
|
9449
|
+
}).attr('transform', function (d) {
|
|
9432
9450
|
// let adjustment = (this.options.data[xAxis].scale === 'Time' || this.options.data[xAxis].scale === 'Linear') ? 0 : this.options.data[xAxis].bandWidth / 2
|
|
9433
9451
|
// if (this.options.orientation === 'horizontal') {
|
|
9434
9452
|
// return `translate(${this[`${yAxis}Axis`](isNaN(d.y.value) ? 0 : d.y.value)}, ${this[`${xAxis}Axis`](this.parseX(d.x.value)) + adjustment})`
|
|
@@ -9457,7 +9475,11 @@ var WebsyChart = /*#__PURE__*/function () {
|
|
|
9457
9475
|
symbols.enter().append('path').attr('d', function (d) {
|
|
9458
9476
|
return drawSymbol(d.y.size || series.symbolSize)(d);
|
|
9459
9477
|
}) // .transition(this.transition)
|
|
9460
|
-
.attr('fill',
|
|
9478
|
+
.attr('fill', function (d) {
|
|
9479
|
+
return series.fillSymbols ? d.y.color || series.color : 'white';
|
|
9480
|
+
}).attr('stroke', function (d) {
|
|
9481
|
+
return d.y.color || series.color;
|
|
9482
|
+
}).attr('class', function (d) {
|
|
9461
9483
|
return "symbol symbol_".concat(series.key);
|
|
9462
9484
|
}).attr('transform', function (d) {
|
|
9463
9485
|
var xIndex = _this52[xAxis + 'Axis'].domain().indexOf(d.x.value);
|
|
@@ -9715,6 +9737,11 @@ var WebsyLegend = /*#__PURE__*/function () {
|
|
|
9715
9737
|
el.innerHTML = html;
|
|
9716
9738
|
}
|
|
9717
9739
|
}
|
|
9740
|
+
}, {
|
|
9741
|
+
key: "setOptions",
|
|
9742
|
+
value: function setOptions(options) {
|
|
9743
|
+
this.options = _extends({}, this.options, options);
|
|
9744
|
+
}
|
|
9718
9745
|
}, {
|
|
9719
9746
|
key: "testWidth",
|
|
9720
9747
|
value: function testWidth(v) {
|