native-document 1.0.159 → 1.0.160

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.
@@ -1,6 +1,5 @@
1
1
  import fs from 'node:fs';
2
2
  import path from 'node:path';
3
- // import { parse } from '@babel/parser';
4
3
  import MagicString from 'magic-string';
5
4
 
6
5
  import { fileURLToPath } from 'node:url';
@@ -1,16 +1,16 @@
1
1
  var NativeComponents = (function (exports) {
2
2
  'use strict';
3
3
 
4
- let DebugManager$2 = {};
4
+ let DebugManager$1 = {};
5
5
  {
6
- DebugManager$2 = {
6
+ DebugManager$1 = {
7
7
  log() {},
8
8
  warn() {},
9
9
  error() {},
10
10
  disable() {}
11
11
  };
12
12
  }
13
- var DebugManager$1 = DebugManager$2;
13
+ var DebugManager$2 = DebugManager$1;
14
14
 
15
15
  class NativeDocumentError extends Error {
16
16
  constructor(message, context = {}) {
@@ -275,7 +275,7 @@ var NativeComponents = (function (exports) {
275
275
  }
276
276
  }
277
277
  if (cleanedCount > 0) {
278
- DebugManager$1.log('Memory Auto Clean', `🧹 Cleaned ${cleanedCount} orphaned observables`);
278
+ DebugManager$2.log('Memory Auto Clean', `🧹 Cleaned ${cleanedCount} orphaned observables`);
279
279
  }
280
280
  }
281
281
  };
@@ -900,7 +900,7 @@ var NativeComponents = (function (exports) {
900
900
  const regex = new RegExp(pattern, flags);
901
901
  return regex.test(String(value));
902
902
  } catch (error){
903
- DebugManager$1.warn('Invalid regex pattern:', pattern, error);
903
+ DebugManager$2.warn('Invalid regex pattern:', pattern, error);
904
904
  return false;
905
905
  }
906
906
  }
@@ -2002,6 +2002,186 @@ var NativeComponents = (function (exports) {
2002
2002
  );
2003
2003
  };
2004
2004
 
2005
+ const STATE = {
2006
+ UNRESOLVED: 'unresolved',
2007
+ PENDING: 'pending',
2008
+ READY: 'ready',
2009
+ REFRESHING: 'refreshing',
2010
+ ERRORED: 'errored',
2011
+ };
2012
+
2013
+ function ObservableResource(fn, deps, config) {
2014
+ this.$fn = (config.debounce > 0) ? debounce(fn, config.debounce) : fn;
2015
+ this.$dependencies = deps;
2016
+ this.$config = config;
2017
+ this.$controller = null;
2018
+ this.$subscriptions = [];
2019
+
2020
+ this.data = config.initial ?? new ObservableItem(null);
2021
+ this.error = new ObservableItem(null);
2022
+ this.state = new ObservableItem(STATE.UNRESOLVED);
2023
+
2024
+ this.loading = ObservableItem.computed(
2025
+ (state) => state === STATE.PENDING || state === STATE.REFRESHING,
2026
+ [this.state]
2027
+ );
2028
+
2029
+ if (config.auto) {
2030
+ if (deps.length > 0) {
2031
+ this.$watchDependencies();
2032
+ return;
2033
+ }
2034
+ this.fetch();
2035
+ }
2036
+ }
2037
+
2038
+ ObservableResource.prototype.$abort = function() {
2039
+ if (this.$controller) {
2040
+ this.$controller.abort();
2041
+ this.$controller = null;
2042
+ }
2043
+ };
2044
+
2045
+ ObservableResource.prototype.$runWithAbortController = function(isRefetch = false) {
2046
+ this.$abort();
2047
+
2048
+ this.$controller = new AbortController();
2049
+ const signal = this.$controller.signal;
2050
+
2051
+ const hasData = this.data.val() !== null;
2052
+ const nextState = isRefetch && hasData ? STATE.REFRESHING : STATE.PENDING;
2053
+
2054
+ this.error.set(null);
2055
+ this.state.set(nextState);
2056
+
2057
+ const depValues = this.$dependencies.map(dep => dep.val());
2058
+ const args = [...depValues, signal];
2059
+
2060
+ Promise.resolve(this.$fn(...args))
2061
+ .then(result => {
2062
+ if (signal.aborted) {
2063
+ return;
2064
+ }
2065
+ this.data.set(result);
2066
+ this.error.set(null);
2067
+ this.state.set(STATE.READY);
2068
+ this.$controller = null;
2069
+ })
2070
+ .catch(err => {
2071
+ if (signal.aborted) {
2072
+ return;
2073
+ }
2074
+ this.error.set(err);
2075
+ this.state.set(STATE.ERRORED);
2076
+ this.$controller = null;
2077
+ });
2078
+ };
2079
+ ObservableResource.prototype.$runWithoutAbortController = function(isRefetch = false) {
2080
+ const hasData = this.data.val() !== null;
2081
+ const nextState = isRefetch && hasData ? STATE.REFRESHING : STATE.PENDING;
2082
+
2083
+ this.error.set(null);
2084
+ this.state.set(nextState);
2085
+
2086
+ const args = this.$dependencies.map(dep => dep.val());
2087
+
2088
+ Promise.resolve(this.$fn(...args))
2089
+ .then(result => {
2090
+ this.data.set(result);
2091
+ this.error.set(null);
2092
+ this.state.set(STATE.READY);
2093
+ })
2094
+ .catch(err => {
2095
+ this.error.set(err);
2096
+ this.state.set(STATE.ERRORED);
2097
+ });
2098
+ };
2099
+
2100
+ ObservableResource.prototype.$run = function(isRefetch = false) {
2101
+ const needsSignal = this.$fn.length > this.$dependencies.length;
2102
+ if(needsSignal) {
2103
+ this.$run = this.$runWithAbortController;
2104
+ return this.$runWithAbortController(isRefetch);
2105
+ }
2106
+ this.$run = this.$runWithoutAbortController;
2107
+
2108
+ return this.$run(isRefetch);
2109
+ };
2110
+
2111
+ ObservableResource.prototype.$watchDependencies = function() {
2112
+ this.$subscriptions.forEach(unsub => unsub());
2113
+ this.$subscriptions = [];
2114
+
2115
+ this.$dependencies.forEach(dep => {
2116
+ const callback = () => this.$run(true);
2117
+ dep.subscribe(callback);
2118
+ this.$subscriptions.push(() => dep.unsubscribe(callback));
2119
+ });
2120
+ if (!this.$config.lazy) {
2121
+ this.$run(false);
2122
+ }
2123
+ };
2124
+
2125
+ ObservableResource.prototype.fetch = function() {
2126
+ this.$run(false);
2127
+ return this;
2128
+ };
2129
+
2130
+ ObservableResource.prototype.refetch = function() {
2131
+ this.$run(true);
2132
+ return this;
2133
+ };
2134
+
2135
+ ObservableResource.prototype.mutate = function(value) {
2136
+ this.data.set(value);
2137
+ this.state.set(STATE.READY);
2138
+ return this;
2139
+ };
2140
+
2141
+ ObservableResource.prototype.destroy = function() {
2142
+ this.$abort();
2143
+ this.$subscriptions.forEach(unsub => unsub());
2144
+ this.$subscriptions = [];
2145
+ };
2146
+
2147
+ ObservableResource.prototype.isReady = function() {
2148
+ return this.state.isEqualTo(STATE.READY);
2149
+ };
2150
+
2151
+ ObservableResource.prototype.isPending = function() {
2152
+ return this.state.isEqualTo(STATE.PENDING);
2153
+ };
2154
+
2155
+ ObservableResource.prototype.isRefreshing = function() {
2156
+ return this.state.isEqualTo(STATE.REFRESHING);
2157
+ };
2158
+
2159
+ ObservableResource.prototype.isErrored = function() {
2160
+ return this.state.isEqualTo(STATE.ERRORED);
2161
+ };
2162
+
2163
+ ObservableResource.prototype.isUnresolved = function() {
2164
+ return this.state.isEqualTo(STATE.UNRESOLVED);
2165
+ };
2166
+
2167
+ ObservableResource.prototype.onSuccess = function(callback) {
2168
+ this.data.subscribe((value) => {
2169
+ if (this.state.val() === STATE.READY) {
2170
+ callback(value);
2171
+ }
2172
+ });
2173
+ return this;
2174
+ };
2175
+
2176
+ ObservableResource.prototype.onError = function(callback) {
2177
+ this.error.subscribe((err) => {
2178
+ if (err !== null) {
2179
+ callback(err);
2180
+ }
2181
+ });
2182
+ return this;
2183
+ };
2184
+
2005
2185
  /**
2006
2186
  *
2007
2187
  * @param {*} value
@@ -2132,9 +2312,9 @@ var NativeComponents = (function (exports) {
2132
2312
  * const computed = Observable.computed(() => { ... }, batch);
2133
2313
  */
2134
2314
  Observable.computed = function(callback, dependencies = []) {
2135
- const initialValue = callback();
2136
- const observable = new ObservableItem(initialValue);
2137
2315
  const getValues = () => dependencies.map((item) => item.val());
2316
+ const initialValue = callback(...getValues());
2317
+ const observable = new ObservableItem(initialValue);
2138
2318
  const updatedValue = nextTick(() => observable.set(callback(...getValues())));
2139
2319
 
2140
2320
  if(Validator.isFunction(dependencies)) {
@@ -2203,6 +2383,15 @@ var NativeComponents = (function (exports) {
2203
2383
  Observable.object = Observable.init;
2204
2384
  Observable.json = Observable.init;
2205
2385
 
2386
+
2387
+ Observable.resource = function(fn, deps = [], options = false) {
2388
+ const config = (typeof options === 'boolean')
2389
+ ? { auto: options, debounce: 0, lazy: false }
2390
+ : { auto: false, debounce: 0, lazy: false, ...options };
2391
+
2392
+ return new ObservableResource(fn, deps, config);
2393
+ };
2394
+
2206
2395
  const BOOLEAN_ATTRIBUTES = new Set([
2207
2396
  'checked',
2208
2397
  'selected',
@@ -2820,7 +3009,7 @@ var NativeComponents = (function (exports) {
2820
3009
  return condition ? ElementCreator.getChild(child) : null;
2821
3010
  }
2822
3011
 
2823
- return DebugManager$1.warn('ShowIf', "ShowIf : condition must be an Observable or boolean / "+comment, condition);
3012
+ return DebugManager$2.warn('ShowIf', "ShowIf : condition must be an Observable or boolean / "+comment, condition);
2824
3013
  }
2825
3014
  const element = Anchor('Show if : '+(comment || ''));
2826
3015
 
@@ -3202,7 +3391,7 @@ var NativeComponents = (function (exports) {
3202
3391
  const method = methods[name];
3203
3392
 
3204
3393
  if (typeof method !== 'function') {
3205
- DebugManager$1.warn(`⚠️ extends(): "${name}" is not a function, skipping`);
3394
+ DebugManager$2.warn(`⚠️ extends(): "${name}" is not a function, skipping`);
3206
3395
  continue;
3207
3396
  }
3208
3397
 
@@ -3212,6 +3401,31 @@ var NativeComponents = (function (exports) {
3212
3401
  return this;
3213
3402
  };
3214
3403
 
3404
+
3405
+ NDElement.prototype.attr = function(name, value) {
3406
+ if(value?.__$Observable) {
3407
+ bindAttributeWithObservable(this.$element, name, value);
3408
+ return this;
3409
+ }
3410
+ this.$element.setAttribute(name, value);
3411
+ };
3412
+
3413
+ NDElement.prototype.attrs = function(attrs) {
3414
+ AttributesWrapper(this.$element, attrs);
3415
+ return this;
3416
+ };
3417
+
3418
+ NDElement.prototype.class = function(classes) {
3419
+ bindClassAttribute(this.$element, classes);
3420
+ return this;
3421
+ };
3422
+
3423
+ NDElement.prototype.style = function(style) {
3424
+ bindStyleAttribute(this.$element, style);
3425
+ return this;
3426
+ };
3427
+
3428
+
3215
3429
  /**
3216
3430
  * Extends the NDElement prototype with new methods available to all NDElement instances.
3217
3431
  * Use this to add global methods to all NDElements.
@@ -3252,17 +3466,17 @@ var NativeComponents = (function (exports) {
3252
3466
  const method = methods[name];
3253
3467
 
3254
3468
  if (typeof method !== 'function') {
3255
- DebugManager$1.warn('NDElement.extend', `"${name}" is not a function, skipping`);
3469
+ DebugManager$2.warn('NDElement.extend', `"${name}" is not a function, skipping`);
3256
3470
  continue;
3257
3471
  }
3258
3472
 
3259
3473
  if (protectedMethods.has(name)) {
3260
- DebugManager$1.error('NDElement.extend', `Cannot override protected method "${name}"`);
3474
+ DebugManager$2.error('NDElement.extend', `Cannot override protected method "${name}"`);
3261
3475
  throw new NativeDocumentError(`Cannot override protected method "${name}"`);
3262
3476
  }
3263
3477
 
3264
3478
  if (NDElement.prototype[name]) {
3265
- DebugManager$1.warn('NDElement.extend', `Overwriting existing prototype method "${name}"`);
3479
+ DebugManager$2.warn('NDElement.extend', `Overwriting existing prototype method "${name}"`);
3266
3480
  }
3267
3481
 
3268
3482
  NDElement.prototype[name] = method;
@@ -3551,7 +3765,7 @@ var NativeComponents = (function (exports) {
3551
3765
  */
3552
3766
  Object.defineProperty(AccordionItem.prototype, 'id', {
3553
3767
  get() {
3554
- this.$description.id;
3768
+ return this.$description.id;
3555
3769
  }
3556
3770
  });
3557
3771
 
@@ -3694,6 +3908,7 @@ var NativeComponents = (function (exports) {
3694
3908
  */
3695
3909
  AccordionItem.prototype.renderContent = function(renderFn) {
3696
3910
  this.$description.renderContent = renderFn;
3911
+ return this;
3697
3912
  };
3698
3913
 
3699
3914
  /**
@@ -3988,7 +4203,7 @@ var NativeComponents = (function (exports) {
3988
4203
 
3989
4204
  Alert.preset = function(name, callback) {
3990
4205
  if (Alert.prototype[name] || Alert[name]) {
3991
- DebugManager$1.warn(`Warning: the ${name} method already exist in Alert.`);
4206
+ DebugManager$2.warn(`Warning: the ${name} method already exist in Alert.`);
3992
4207
  return;
3993
4208
  }
3994
4209
  Alert[name] = (content, props) => callback(new Alert(content, props));
@@ -4302,7 +4517,7 @@ var NativeComponents = (function (exports) {
4302
4517
 
4303
4518
  Avatar.preset = function(name, callback) {
4304
4519
  if (Avatar.prototype[name] || Avatar[name]) {
4305
- DebugManager$1.warn(`Warning: the ${name} method already exists in Avatar.`);
4520
+ DebugManager$2.warn(`Warning: the ${name} method already exists in Avatar.`);
4306
4521
  return;
4307
4522
  }
4308
4523
  Avatar[name] = (label, props) => callback(new Avatar(label, props));
@@ -4724,7 +4939,7 @@ var NativeComponents = (function (exports) {
4724
4939
 
4725
4940
  Badge.preset = function(name, callback) {
4726
4941
  if (Badge.prototype[name] || Badge[name]) {
4727
- DebugManager$1.warn(`Warning: the ${name} method already exists in Badge.`);
4942
+ DebugManager$2.warn(`Warning: the ${name} method already exists in Badge.`);
4728
4943
  return;
4729
4944
  }
4730
4945
  Badge[name] = (content, props) => callback(new Badge(content, props));
@@ -4842,7 +5057,7 @@ var NativeComponents = (function (exports) {
4842
5057
 
4843
5058
  Breadcrumb.preset = function(name, callback) {
4844
5059
  if (Breadcrumb.prototype[name] || Breadcrumb[name]) {
4845
- DebugManager$1.warn(`Warning: the ${name} method already exist in Breadcrumb.`);
5060
+ DebugManager$2.warn(`Warning: the ${name} method already exist in Breadcrumb.`);
4846
5061
  return;
4847
5062
  }
4848
5063
  Breadcrumb[name] = (props) => callback(new Breadcrumb(props));
@@ -4932,7 +5147,7 @@ var NativeComponents = (function (exports) {
4932
5147
 
4933
5148
  Button.preset = function(name, callback) {
4934
5149
  if (Button.prototype[name] || Button[name]) {
4935
- DebugManager$1.warn(`Warning: the ${name} method already exist in Button.`);
5150
+ DebugManager$2.warn(`Warning: the ${name} method already exist in Button.`);
4936
5151
  return;
4937
5152
  }
4938
5153
  Button[name] = (label, props) => callback(new Button(label, props));
@@ -5814,7 +6029,7 @@ var NativeComponents = (function (exports) {
5814
6029
 
5815
6030
  Divider.preset = function(name, callback) {
5816
6031
  if (Divider.prototype[name] || Divider[name]) {
5817
- DebugManager$1.warn(`Warning: the ${name} method already exists in Divider.`);
6032
+ DebugManager$2.warn(`Warning: the ${name} method already exists in Divider.`);
5818
6033
  return;
5819
6034
  }
5820
6035
  Divider[name] = (label, props) => callback(new Divider(label, props));
@@ -6233,7 +6448,7 @@ var NativeComponents = (function (exports) {
6233
6448
 
6234
6449
  Dropdown.preset = function(name, callback) {
6235
6450
  if (Dropdown.prototype[name] || Dropdown[name]) {
6236
- DebugManager$1.warn(`Warning: the ${name} method already exist in Dropdown.`);
6451
+ DebugManager$2.warn(`Warning: the ${name} method already exist in Dropdown.`);
6237
6452
  return;
6238
6453
  }
6239
6454
  Dropdown[name] = (props) => callback(new Dropdown(props));
@@ -10288,7 +10503,7 @@ var NativeComponents = (function (exports) {
10288
10503
 
10289
10504
  Modal.preset = function(name, callback) {
10290
10505
  if (Modal.prototype[name] || Modal[name]) {
10291
- DebugManager$1.warn(`Warning: the ${name} method already exist in Modal.`);
10506
+ DebugManager$2.warn(`Warning: the ${name} method already exist in Modal.`);
10292
10507
  return;
10293
10508
  }
10294
10509
  Modal[name] = (content, props) => callback(new Modal(content, props));
@@ -10539,7 +10754,7 @@ var NativeComponents = (function (exports) {
10539
10754
 
10540
10755
  Pagination.preset = function(name, callback) {
10541
10756
  if (Pagination.prototype[name] || Pagination[name]) {
10542
- DebugManager$1.warn(`Warning: the ${name} method already exist in Pagination.`);
10757
+ DebugManager$2.warn(`Warning: the ${name} method already exist in Pagination.`);
10543
10758
  return;
10544
10759
  }
10545
10760
  Pagination[name] = (props) => callback(new Pagination(props));
@@ -10834,7 +11049,7 @@ var NativeComponents = (function (exports) {
10834
11049
 
10835
11050
  Popover.preset = function(name, callback) {
10836
11051
  if (Popover.prototype[name] || Popover[name]) {
10837
- DebugManager$1.warn(`Warning: the ${name} method already exist in Popover.`);
11052
+ DebugManager$2.warn(`Warning: the ${name} method already exist in Popover.`);
10838
11053
  return;
10839
11054
  }
10840
11055
  Popover[name] = (content, props) => callback(new Popover(content, props));
@@ -11136,7 +11351,7 @@ var NativeComponents = (function (exports) {
11136
11351
 
11137
11352
  Progress.preset = function(name, callback) {
11138
11353
  if (Progress.prototype[name] || Progress[name]) {
11139
- DebugManager$1.warn(`Warning: the ${name} method already exists in Progress.`);
11354
+ DebugManager$2.warn(`Warning: the ${name} method already exists in Progress.`);
11140
11355
  return;
11141
11356
  }
11142
11357
  Progress[name] = (props) => callback(new Progress(props));
@@ -11438,7 +11653,7 @@ var NativeComponents = (function (exports) {
11438
11653
 
11439
11654
  VStack.preset = function(name, callback) {
11440
11655
  if (VStack.prototype[name] || VStack[name]) {
11441
- DebugManager$1.warn(`Warning: the ${name} method already exists in VStack.`);
11656
+ DebugManager$2.warn(`Warning: the ${name} method already exists in VStack.`);
11442
11657
  return;
11443
11658
  }
11444
11659
  VStack[name] = (content, props) => callback(new VStack(content, props));
@@ -11613,7 +11828,7 @@ var NativeComponents = (function (exports) {
11613
11828
 
11614
11829
  FixedStack.preset = function(name, callback) {
11615
11830
  if(FixedStack.prototype[name] || FixedStack[name]) {
11616
- DebugManager$1.warn(`Warning: the ${name} method already exists in FixedStack.`);
11831
+ DebugManager$2.warn(`Warning: the ${name} method already exists in FixedStack.`);
11617
11832
  return;
11618
11833
  }
11619
11834
  FixedStack[name] = (content, props) => callback(new FixedStack(content, props));
@@ -11643,7 +11858,7 @@ var NativeComponents = (function (exports) {
11643
11858
 
11644
11859
  HStack.preset = function(name, callback) {
11645
11860
  if (HStack.prototype[name] || HStack[name]) {
11646
- DebugManager$1.warn(`Warning: the ${name} method already exists in HStack.`);
11861
+ DebugManager$2.warn(`Warning: the ${name} method already exists in HStack.`);
11647
11862
  return;
11648
11863
  }
11649
11864
  HStack[name] = (content, props) => callback(new HStack(content, props));
@@ -11673,7 +11888,7 @@ var NativeComponents = (function (exports) {
11673
11888
 
11674
11889
  AbsoluteStack.preset = function(name, callback) {
11675
11890
  if(AbsoluteStack.prototype[name] || AbsoluteStack[name]) {
11676
- DebugManager$1.warn(`Warning: the ${name} method already exists in AbsoluteStack.`);
11891
+ DebugManager$2.warn(`Warning: the ${name} method already exists in AbsoluteStack.`);
11677
11892
  return;
11678
11893
  }
11679
11894
  AbsoluteStack[name] = (content, props) => callback(new AbsoluteStack(content, props));
@@ -11703,7 +11918,7 @@ var NativeComponents = (function (exports) {
11703
11918
 
11704
11919
  RelativeStack.preset = function(name, callback) {
11705
11920
  if(RelativeStack.prototype[name] || RelativeStack[name]) {
11706
- DebugManager$1.warn(`Warning: the ${name} method already exists in RelativeStack.`);
11921
+ DebugManager$2.warn(`Warning: the ${name} method already exists in RelativeStack.`);
11707
11922
  return;
11708
11923
  }
11709
11924
  RelativeStack[name] = (content, props) => callback(new RelativeStack(content, props));
@@ -12275,7 +12490,7 @@ var NativeComponents = (function (exports) {
12275
12490
 
12276
12491
  Skeleton.preset = function(name, callback) {
12277
12492
  if (Skeleton.prototype[name] || Skeleton[name]) {
12278
- DebugManager$1.warn(`Warning: the ${name} method already exists in Skeleton.`);
12493
+ DebugManager$2.warn(`Warning: the ${name} method already exists in Skeleton.`);
12279
12494
  return;
12280
12495
  }
12281
12496
  Skeleton[name] = (props) => callback(new Skeleton(props));
@@ -12639,7 +12854,7 @@ var NativeComponents = (function (exports) {
12639
12854
 
12640
12855
  Spinner.preset = function(name, callback) {
12641
12856
  if (Spinner.prototype[name] || Spinner[name]) {
12642
- DebugManager$1.warn(`Warning: the ${name} method already exists in Spinner.`);
12857
+ DebugManager$2.warn(`Warning: the ${name} method already exists in Spinner.`);
12643
12858
  return;
12644
12859
  }
12645
12860
  Spinner[name] = (props) => callback(new Spinner(props));
@@ -13209,7 +13424,7 @@ var NativeComponents = (function (exports) {
13209
13424
 
13210
13425
  Stepper.preset = function(name, callback) {
13211
13426
  if (Stepper.prototype[name] || Stepper[name]) {
13212
- DebugManager$1.warn(`Warning: the ${name} method already exist in Stepper.`);
13427
+ DebugManager$2.warn(`Warning: the ${name} method already exist in Stepper.`);
13213
13428
  return;
13214
13429
  }
13215
13430
  Stepper[name] = (props) => callback(new Stepper(props));
@@ -14173,7 +14388,7 @@ var NativeComponents = (function (exports) {
14173
14388
 
14174
14389
  DataTable.prototype.selectedRows = function($obs) {
14175
14390
  if(!$obs.__$isObservableArray) {
14176
- DebugManager$1.warn('Database', 'selectedRow should take an Observable array');
14391
+ DebugManager$2.warn('Database', 'selectedRow should take an Observable array');
14177
14392
  }
14178
14393
  this.$description.$selectedRows = $obs;
14179
14394
  return this;
@@ -14720,7 +14935,7 @@ var NativeComponents = (function (exports) {
14720
14935
 
14721
14936
  Tooltip.preset = function(name, callback) {
14722
14937
  if (Tooltip.prototype[name] || Tooltip[name]) {
14723
- DebugManager$1.warn(`Warning: the ${name} method already exist in Tooltip.`);
14938
+ DebugManager$2.warn(`Warning: the ${name} method already exist in Tooltip.`);
14724
14939
  return;
14725
14940
  }
14726
14941
  Tooltip[name] = (content, props) => callback(new Tooltip(content, props));