@websy/websy-designs 1.4.19 → 1.4.21
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/server/helpers/v1/pgHelper.js +1 -1
- package/dist/websy-designs-es6.debug.js +7 -1
- package/dist/websy-designs-es6.js +10 -1
- package/dist/websy-designs-es6.min.js +1 -1
- package/dist/websy-designs.debug.js +8 -2
- package/dist/websy-designs.js +11 -2
- package/dist/websy-designs.min.js +1 -1
- package/package.json +1 -1
|
@@ -4626,7 +4626,7 @@ class WebsySearch {
|
|
|
4626
4626
|
el.innerHTML = `
|
|
4627
4627
|
<div class='websy-search-input-container'>
|
|
4628
4628
|
${this.options.searchIcon}
|
|
4629
|
-
<input id='${this.elementId}_search' class='websy-search-input' placeholder='${this.options.placeholder || 'Search'}'>
|
|
4629
|
+
<input id='${this.elementId}_search' class='websy-search-input' placeholder='${this.options.placeholder || 'Search'}' value='${this.options.initialValue || ''}'>
|
|
4630
4630
|
<div class='clear ${this.options.clearAlwaysOn === true ? '' : 'websy-hidden'}' id='${this.elementId}_clear'>
|
|
4631
4631
|
${this.options.clearIcon}
|
|
4632
4632
|
</div>
|
|
@@ -6220,6 +6220,9 @@ class WebsyTable3 {
|
|
|
6220
6220
|
// this.rowCount = this.data.length
|
|
6221
6221
|
}
|
|
6222
6222
|
buildBodyHtml (data = [], useWidths = false) {
|
|
6223
|
+
if (!this.options.columns) {
|
|
6224
|
+
return ''
|
|
6225
|
+
}
|
|
6223
6226
|
if (data.length === 0) {
|
|
6224
6227
|
return ''
|
|
6225
6228
|
}
|
|
@@ -6324,6 +6327,9 @@ class WebsyTable3 {
|
|
|
6324
6327
|
return bodyHtml
|
|
6325
6328
|
}
|
|
6326
6329
|
buildHeaderHtml (useWidths = false) {
|
|
6330
|
+
if (!this.options.columns) {
|
|
6331
|
+
return ''
|
|
6332
|
+
}
|
|
6327
6333
|
let headerHtml = ''
|
|
6328
6334
|
let sizingColumns = this.options.columns[this.options.columns.length - 1]
|
|
6329
6335
|
if (useWidths === true) {
|
|
@@ -6709,7 +6715,7 @@ class WebsyTable3 {
|
|
|
6709
6715
|
renderTotals () {
|
|
6710
6716
|
let headEl = document.getElementById(`${this.elementId}_tableHeader`)
|
|
6711
6717
|
let totalHtml = this.buildTotalHtml(true)
|
|
6712
|
-
if (this.options.showTotalsAbove === true) {
|
|
6718
|
+
if (this.options.showTotalsAbove === true && headEl) {
|
|
6713
6719
|
headEl.innerHTML += totalHtml
|
|
6714
6720
|
}
|
|
6715
6721
|
else {
|
package/dist/websy-designs.js
CHANGED
|
@@ -5119,7 +5119,7 @@ var WebsySearch = /*#__PURE__*/function () {
|
|
|
5119
5119
|
el.addEventListener('click', this.handleClick.bind(this));
|
|
5120
5120
|
el.addEventListener('keyup', this.handleKeyUp.bind(this));
|
|
5121
5121
|
el.addEventListener('keyup', this.handleKeyDown.bind(this));
|
|
5122
|
-
el.innerHTML = "\n <div class='websy-search-input-container'>\n ".concat(this.options.searchIcon, "\n <input id='").concat(this.elementId, "_search' class='websy-search-input' placeholder='").concat(this.options.placeholder || 'Search', "'>\n <div class='clear ").concat(this.options.clearAlwaysOn === true ? '' : 'websy-hidden', "' id='").concat(this.elementId, "_clear'>\n ").concat(this.options.clearIcon, "\n </div>\n </div>\n ");
|
|
5122
|
+
el.innerHTML = "\n <div class='websy-search-input-container'>\n ".concat(this.options.searchIcon, "\n <input id='").concat(this.elementId, "_search' class='websy-search-input' placeholder='").concat(this.options.placeholder || 'Search', "' value='").concat(this.options.initialValue || '', "'>\n <div class='clear ").concat(this.options.clearAlwaysOn === true ? '' : 'websy-hidden', "' id='").concat(this.elementId, "_clear'>\n ").concat(this.options.clearIcon, "\n </div>\n </div>\n ");
|
|
5123
5123
|
} else {
|
|
5124
5124
|
console.log('No element found with Id', elementId);
|
|
5125
5125
|
}
|
|
@@ -6803,6 +6803,10 @@ var WebsyTable3 = /*#__PURE__*/function () {
|
|
|
6803
6803
|
var data = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
6804
6804
|
var useWidths = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
6805
6805
|
|
|
6806
|
+
if (!this.options.columns) {
|
|
6807
|
+
return '';
|
|
6808
|
+
}
|
|
6809
|
+
|
|
6806
6810
|
if (data.length === 0) {
|
|
6807
6811
|
return '';
|
|
6808
6812
|
}
|
|
@@ -6899,6 +6903,11 @@ var WebsyTable3 = /*#__PURE__*/function () {
|
|
|
6899
6903
|
var _this41 = this;
|
|
6900
6904
|
|
|
6901
6905
|
var useWidths = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
|
|
6906
|
+
|
|
6907
|
+
if (!this.options.columns) {
|
|
6908
|
+
return '';
|
|
6909
|
+
}
|
|
6910
|
+
|
|
6902
6911
|
var headerHtml = '';
|
|
6903
6912
|
var sizingColumns = this.options.columns[this.options.columns.length - 1];
|
|
6904
6913
|
|
|
@@ -7355,7 +7364,7 @@ var WebsyTable3 = /*#__PURE__*/function () {
|
|
|
7355
7364
|
var headEl = document.getElementById("".concat(this.elementId, "_tableHeader"));
|
|
7356
7365
|
var totalHtml = this.buildTotalHtml(true);
|
|
7357
7366
|
|
|
7358
|
-
if (this.options.showTotalsAbove === true) {
|
|
7367
|
+
if (this.options.showTotalsAbove === true && headEl) {
|
|
7359
7368
|
headEl.innerHTML += totalHtml;
|
|
7360
7369
|
} else {
|
|
7361
7370
|
var footerEl = document.getElementById("".concat(this.elementId, "_tableFooter"));
|