@websy/websy-designs 1.11.9 → 1.11.10

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.
@@ -267,6 +267,9 @@ class ButtonGroup {
267
267
  this.options.activeItem = -1
268
268
  event.target.classList.remove('active')
269
269
  }
270
+ if (this.options.onClick) {
271
+ this.options.onClick(this.options.items[index], index, event, this)
272
+ }
270
273
  }
271
274
  }
272
275
  on (event, fn) {
@@ -4851,6 +4854,9 @@ class WebsyRouter {
4851
4854
  if (this.options.views[view].load) {
4852
4855
  this.options.views[view].load(callbackFn)
4853
4856
  }
4857
+ else if (callbackFn) {
4858
+ callbackFn()
4859
+ }
4854
4860
  }
4855
4861
  initView (view) {
4856
4862
  return new Promise((resolve, reject) => {
@@ -312,6 +312,9 @@ var ButtonGroup = /*#__PURE__*/function () {
312
312
  this.options.activeItem = -1;
313
313
  event.target.classList.remove('active');
314
314
  }
315
+ if (this.options.onClick) {
316
+ this.options.onClick(this.options.items[index], index, event, this);
317
+ }
315
318
  }
316
319
  }
317
320
  }, {
@@ -4680,6 +4683,8 @@ var WebsyRouter = /*#__PURE__*/function () {
4680
4683
  value: function preloadView(view, callbackFn) {
4681
4684
  if (this.options.views[view].load) {
4682
4685
  this.options.views[view].load(callbackFn);
4686
+ } else if (callbackFn) {
4687
+ callbackFn();
4683
4688
  }
4684
4689
  }
4685
4690
  }, {