ods-component-lib 1.18.7 → 1.18.8
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/components/devextreme/OdsRemoteDataGrid.d.ts +10 -3
- package/dist/index.js +678 -57
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +679 -58
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Alert, AutoComplete, Button, Dropdown, Calendar, Card as Card$1, Checkbox, DatePicker, Divider, Input, Form, Image, InputNumber, List, Modal, notification, Radio, Rate, Select, Space, Spin, Switch, Tabs, Table, Tag, Timeline, TimePicker, Typography, theme } from 'antd';
|
|
2
2
|
import styled, { ThemeProvider } from 'styled-components';
|
|
3
|
-
import React, { useState, useRef, useEffect } from 'react';
|
|
3
|
+
import React, { useState, useRef, useEffect, useMemo, useCallback } from 'react';
|
|
4
4
|
import Marquee from 'react-fast-marquee';
|
|
5
5
|
import Card from 'antd/es/card/Card';
|
|
6
6
|
import { EyeTwoTone, EyeInvisibleOutlined, FrownOutlined, MehOutlined, SmileOutlined, HeartOutlined, UserOutlined, LockOutlined } from '@ant-design/icons';
|
|
@@ -16532,13 +16532,589 @@ function _finallyRethrows(body, finalizer) {
|
|
|
16532
16532
|
return finalizer(false, result);
|
|
16533
16533
|
}
|
|
16534
16534
|
|
|
16535
|
+
/**
|
|
16536
|
+
* Checks if `value` is the
|
|
16537
|
+
* [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)
|
|
16538
|
+
* of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)
|
|
16539
|
+
*
|
|
16540
|
+
* @static
|
|
16541
|
+
* @memberOf _
|
|
16542
|
+
* @since 0.1.0
|
|
16543
|
+
* @category Lang
|
|
16544
|
+
* @param {*} value The value to check.
|
|
16545
|
+
* @returns {boolean} Returns `true` if `value` is an object, else `false`.
|
|
16546
|
+
* @example
|
|
16547
|
+
*
|
|
16548
|
+
* _.isObject({});
|
|
16549
|
+
* // => true
|
|
16550
|
+
*
|
|
16551
|
+
* _.isObject([1, 2, 3]);
|
|
16552
|
+
* // => true
|
|
16553
|
+
*
|
|
16554
|
+
* _.isObject(_.noop);
|
|
16555
|
+
* // => true
|
|
16556
|
+
*
|
|
16557
|
+
* _.isObject(null);
|
|
16558
|
+
* // => false
|
|
16559
|
+
*/
|
|
16560
|
+
function isObject(value) {
|
|
16561
|
+
var type = typeof value;
|
|
16562
|
+
return value != null && (type == 'object' || type == 'function');
|
|
16563
|
+
}
|
|
16564
|
+
|
|
16565
|
+
var isObject_1 = isObject;
|
|
16566
|
+
|
|
16567
|
+
/** Detect free variable `global` from Node.js. */
|
|
16568
|
+
var freeGlobal = typeof commonjsGlobal == 'object' && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal;
|
|
16569
|
+
|
|
16570
|
+
var _freeGlobal = freeGlobal;
|
|
16571
|
+
|
|
16572
|
+
/** Detect free variable `self`. */
|
|
16573
|
+
var freeSelf = typeof self == 'object' && self && self.Object === Object && self;
|
|
16574
|
+
|
|
16575
|
+
/** Used as a reference to the global object. */
|
|
16576
|
+
var root = _freeGlobal || freeSelf || Function('return this')();
|
|
16577
|
+
|
|
16578
|
+
var _root = root;
|
|
16579
|
+
|
|
16580
|
+
/**
|
|
16581
|
+
* Gets the timestamp of the number of milliseconds that have elapsed since
|
|
16582
|
+
* the Unix epoch (1 January 1970 00:00:00 UTC).
|
|
16583
|
+
*
|
|
16584
|
+
* @static
|
|
16585
|
+
* @memberOf _
|
|
16586
|
+
* @since 2.4.0
|
|
16587
|
+
* @category Date
|
|
16588
|
+
* @returns {number} Returns the timestamp.
|
|
16589
|
+
* @example
|
|
16590
|
+
*
|
|
16591
|
+
* _.defer(function(stamp) {
|
|
16592
|
+
* console.log(_.now() - stamp);
|
|
16593
|
+
* }, _.now());
|
|
16594
|
+
* // => Logs the number of milliseconds it took for the deferred invocation.
|
|
16595
|
+
*/
|
|
16596
|
+
var now = function() {
|
|
16597
|
+
return _root.Date.now();
|
|
16598
|
+
};
|
|
16599
|
+
|
|
16600
|
+
var now_1 = now;
|
|
16601
|
+
|
|
16602
|
+
/** Used to match a single whitespace character. */
|
|
16603
|
+
var reWhitespace = /\s/;
|
|
16604
|
+
|
|
16605
|
+
/**
|
|
16606
|
+
* Used by `_.trim` and `_.trimEnd` to get the index of the last non-whitespace
|
|
16607
|
+
* character of `string`.
|
|
16608
|
+
*
|
|
16609
|
+
* @private
|
|
16610
|
+
* @param {string} string The string to inspect.
|
|
16611
|
+
* @returns {number} Returns the index of the last non-whitespace character.
|
|
16612
|
+
*/
|
|
16613
|
+
function trimmedEndIndex(string) {
|
|
16614
|
+
var index = string.length;
|
|
16615
|
+
|
|
16616
|
+
while (index-- && reWhitespace.test(string.charAt(index))) {}
|
|
16617
|
+
return index;
|
|
16618
|
+
}
|
|
16619
|
+
|
|
16620
|
+
var _trimmedEndIndex = trimmedEndIndex;
|
|
16621
|
+
|
|
16622
|
+
/** Used to match leading whitespace. */
|
|
16623
|
+
var reTrimStart = /^\s+/;
|
|
16624
|
+
|
|
16625
|
+
/**
|
|
16626
|
+
* The base implementation of `_.trim`.
|
|
16627
|
+
*
|
|
16628
|
+
* @private
|
|
16629
|
+
* @param {string} string The string to trim.
|
|
16630
|
+
* @returns {string} Returns the trimmed string.
|
|
16631
|
+
*/
|
|
16632
|
+
function baseTrim(string) {
|
|
16633
|
+
return string
|
|
16634
|
+
? string.slice(0, _trimmedEndIndex(string) + 1).replace(reTrimStart, '')
|
|
16635
|
+
: string;
|
|
16636
|
+
}
|
|
16637
|
+
|
|
16638
|
+
var _baseTrim = baseTrim;
|
|
16639
|
+
|
|
16640
|
+
/** Built-in value references. */
|
|
16641
|
+
var Symbol$1 = _root.Symbol;
|
|
16642
|
+
|
|
16643
|
+
var _Symbol = Symbol$1;
|
|
16644
|
+
|
|
16645
|
+
/** Used for built-in method references. */
|
|
16646
|
+
var objectProto = Object.prototype;
|
|
16647
|
+
|
|
16648
|
+
/** Used to check objects for own properties. */
|
|
16649
|
+
var hasOwnProperty = objectProto.hasOwnProperty;
|
|
16650
|
+
|
|
16651
|
+
/**
|
|
16652
|
+
* Used to resolve the
|
|
16653
|
+
* [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
|
|
16654
|
+
* of values.
|
|
16655
|
+
*/
|
|
16656
|
+
var nativeObjectToString = objectProto.toString;
|
|
16657
|
+
|
|
16658
|
+
/** Built-in value references. */
|
|
16659
|
+
var symToStringTag = _Symbol ? _Symbol.toStringTag : undefined;
|
|
16660
|
+
|
|
16661
|
+
/**
|
|
16662
|
+
* A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.
|
|
16663
|
+
*
|
|
16664
|
+
* @private
|
|
16665
|
+
* @param {*} value The value to query.
|
|
16666
|
+
* @returns {string} Returns the raw `toStringTag`.
|
|
16667
|
+
*/
|
|
16668
|
+
function getRawTag(value) {
|
|
16669
|
+
var isOwn = hasOwnProperty.call(value, symToStringTag),
|
|
16670
|
+
tag = value[symToStringTag];
|
|
16671
|
+
|
|
16672
|
+
try {
|
|
16673
|
+
value[symToStringTag] = undefined;
|
|
16674
|
+
var unmasked = true;
|
|
16675
|
+
} catch (e) {}
|
|
16676
|
+
|
|
16677
|
+
var result = nativeObjectToString.call(value);
|
|
16678
|
+
if (unmasked) {
|
|
16679
|
+
if (isOwn) {
|
|
16680
|
+
value[symToStringTag] = tag;
|
|
16681
|
+
} else {
|
|
16682
|
+
delete value[symToStringTag];
|
|
16683
|
+
}
|
|
16684
|
+
}
|
|
16685
|
+
return result;
|
|
16686
|
+
}
|
|
16687
|
+
|
|
16688
|
+
var _getRawTag = getRawTag;
|
|
16689
|
+
|
|
16690
|
+
/** Used for built-in method references. */
|
|
16691
|
+
var objectProto$1 = Object.prototype;
|
|
16692
|
+
|
|
16693
|
+
/**
|
|
16694
|
+
* Used to resolve the
|
|
16695
|
+
* [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
|
|
16696
|
+
* of values.
|
|
16697
|
+
*/
|
|
16698
|
+
var nativeObjectToString$1 = objectProto$1.toString;
|
|
16699
|
+
|
|
16700
|
+
/**
|
|
16701
|
+
* Converts `value` to a string using `Object.prototype.toString`.
|
|
16702
|
+
*
|
|
16703
|
+
* @private
|
|
16704
|
+
* @param {*} value The value to convert.
|
|
16705
|
+
* @returns {string} Returns the converted string.
|
|
16706
|
+
*/
|
|
16707
|
+
function objectToString(value) {
|
|
16708
|
+
return nativeObjectToString$1.call(value);
|
|
16709
|
+
}
|
|
16710
|
+
|
|
16711
|
+
var _objectToString = objectToString;
|
|
16712
|
+
|
|
16713
|
+
/** `Object#toString` result references. */
|
|
16714
|
+
var nullTag = '[object Null]',
|
|
16715
|
+
undefinedTag = '[object Undefined]';
|
|
16716
|
+
|
|
16717
|
+
/** Built-in value references. */
|
|
16718
|
+
var symToStringTag$1 = _Symbol ? _Symbol.toStringTag : undefined;
|
|
16719
|
+
|
|
16720
|
+
/**
|
|
16721
|
+
* The base implementation of `getTag` without fallbacks for buggy environments.
|
|
16722
|
+
*
|
|
16723
|
+
* @private
|
|
16724
|
+
* @param {*} value The value to query.
|
|
16725
|
+
* @returns {string} Returns the `toStringTag`.
|
|
16726
|
+
*/
|
|
16727
|
+
function baseGetTag(value) {
|
|
16728
|
+
if (value == null) {
|
|
16729
|
+
return value === undefined ? undefinedTag : nullTag;
|
|
16730
|
+
}
|
|
16731
|
+
return (symToStringTag$1 && symToStringTag$1 in Object(value))
|
|
16732
|
+
? _getRawTag(value)
|
|
16733
|
+
: _objectToString(value);
|
|
16734
|
+
}
|
|
16735
|
+
|
|
16736
|
+
var _baseGetTag = baseGetTag;
|
|
16737
|
+
|
|
16738
|
+
/**
|
|
16739
|
+
* Checks if `value` is object-like. A value is object-like if it's not `null`
|
|
16740
|
+
* and has a `typeof` result of "object".
|
|
16741
|
+
*
|
|
16742
|
+
* @static
|
|
16743
|
+
* @memberOf _
|
|
16744
|
+
* @since 4.0.0
|
|
16745
|
+
* @category Lang
|
|
16746
|
+
* @param {*} value The value to check.
|
|
16747
|
+
* @returns {boolean} Returns `true` if `value` is object-like, else `false`.
|
|
16748
|
+
* @example
|
|
16749
|
+
*
|
|
16750
|
+
* _.isObjectLike({});
|
|
16751
|
+
* // => true
|
|
16752
|
+
*
|
|
16753
|
+
* _.isObjectLike([1, 2, 3]);
|
|
16754
|
+
* // => true
|
|
16755
|
+
*
|
|
16756
|
+
* _.isObjectLike(_.noop);
|
|
16757
|
+
* // => false
|
|
16758
|
+
*
|
|
16759
|
+
* _.isObjectLike(null);
|
|
16760
|
+
* // => false
|
|
16761
|
+
*/
|
|
16762
|
+
function isObjectLike(value) {
|
|
16763
|
+
return value != null && typeof value == 'object';
|
|
16764
|
+
}
|
|
16765
|
+
|
|
16766
|
+
var isObjectLike_1 = isObjectLike;
|
|
16767
|
+
|
|
16768
|
+
/** `Object#toString` result references. */
|
|
16769
|
+
var symbolTag = '[object Symbol]';
|
|
16770
|
+
|
|
16771
|
+
/**
|
|
16772
|
+
* Checks if `value` is classified as a `Symbol` primitive or object.
|
|
16773
|
+
*
|
|
16774
|
+
* @static
|
|
16775
|
+
* @memberOf _
|
|
16776
|
+
* @since 4.0.0
|
|
16777
|
+
* @category Lang
|
|
16778
|
+
* @param {*} value The value to check.
|
|
16779
|
+
* @returns {boolean} Returns `true` if `value` is a symbol, else `false`.
|
|
16780
|
+
* @example
|
|
16781
|
+
*
|
|
16782
|
+
* _.isSymbol(Symbol.iterator);
|
|
16783
|
+
* // => true
|
|
16784
|
+
*
|
|
16785
|
+
* _.isSymbol('abc');
|
|
16786
|
+
* // => false
|
|
16787
|
+
*/
|
|
16788
|
+
function isSymbol(value) {
|
|
16789
|
+
return typeof value == 'symbol' ||
|
|
16790
|
+
(isObjectLike_1(value) && _baseGetTag(value) == symbolTag);
|
|
16791
|
+
}
|
|
16792
|
+
|
|
16793
|
+
var isSymbol_1 = isSymbol;
|
|
16794
|
+
|
|
16795
|
+
/** Used as references for various `Number` constants. */
|
|
16796
|
+
var NAN = 0 / 0;
|
|
16797
|
+
|
|
16798
|
+
/** Used to detect bad signed hexadecimal string values. */
|
|
16799
|
+
var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
|
|
16800
|
+
|
|
16801
|
+
/** Used to detect binary string values. */
|
|
16802
|
+
var reIsBinary = /^0b[01]+$/i;
|
|
16803
|
+
|
|
16804
|
+
/** Used to detect octal string values. */
|
|
16805
|
+
var reIsOctal = /^0o[0-7]+$/i;
|
|
16806
|
+
|
|
16807
|
+
/** Built-in method references without a dependency on `root`. */
|
|
16808
|
+
var freeParseInt = parseInt;
|
|
16809
|
+
|
|
16810
|
+
/**
|
|
16811
|
+
* Converts `value` to a number.
|
|
16812
|
+
*
|
|
16813
|
+
* @static
|
|
16814
|
+
* @memberOf _
|
|
16815
|
+
* @since 4.0.0
|
|
16816
|
+
* @category Lang
|
|
16817
|
+
* @param {*} value The value to process.
|
|
16818
|
+
* @returns {number} Returns the number.
|
|
16819
|
+
* @example
|
|
16820
|
+
*
|
|
16821
|
+
* _.toNumber(3.2);
|
|
16822
|
+
* // => 3.2
|
|
16823
|
+
*
|
|
16824
|
+
* _.toNumber(Number.MIN_VALUE);
|
|
16825
|
+
* // => 5e-324
|
|
16826
|
+
*
|
|
16827
|
+
* _.toNumber(Infinity);
|
|
16828
|
+
* // => Infinity
|
|
16829
|
+
*
|
|
16830
|
+
* _.toNumber('3.2');
|
|
16831
|
+
* // => 3.2
|
|
16832
|
+
*/
|
|
16833
|
+
function toNumber(value) {
|
|
16834
|
+
if (typeof value == 'number') {
|
|
16835
|
+
return value;
|
|
16836
|
+
}
|
|
16837
|
+
if (isSymbol_1(value)) {
|
|
16838
|
+
return NAN;
|
|
16839
|
+
}
|
|
16840
|
+
if (isObject_1(value)) {
|
|
16841
|
+
var other = typeof value.valueOf == 'function' ? value.valueOf() : value;
|
|
16842
|
+
value = isObject_1(other) ? (other + '') : other;
|
|
16843
|
+
}
|
|
16844
|
+
if (typeof value != 'string') {
|
|
16845
|
+
return value === 0 ? value : +value;
|
|
16846
|
+
}
|
|
16847
|
+
value = _baseTrim(value);
|
|
16848
|
+
var isBinary = reIsBinary.test(value);
|
|
16849
|
+
return (isBinary || reIsOctal.test(value))
|
|
16850
|
+
? freeParseInt(value.slice(2), isBinary ? 2 : 8)
|
|
16851
|
+
: (reIsBadHex.test(value) ? NAN : +value);
|
|
16852
|
+
}
|
|
16853
|
+
|
|
16854
|
+
var toNumber_1 = toNumber;
|
|
16855
|
+
|
|
16856
|
+
/** Error message constants. */
|
|
16857
|
+
var FUNC_ERROR_TEXT = 'Expected a function';
|
|
16858
|
+
|
|
16859
|
+
/* Built-in method references for those with the same name as other `lodash` methods. */
|
|
16860
|
+
var nativeMax = Math.max,
|
|
16861
|
+
nativeMin = Math.min;
|
|
16862
|
+
|
|
16863
|
+
/**
|
|
16864
|
+
* Creates a debounced function that delays invoking `func` until after `wait`
|
|
16865
|
+
* milliseconds have elapsed since the last time the debounced function was
|
|
16866
|
+
* invoked. The debounced function comes with a `cancel` method to cancel
|
|
16867
|
+
* delayed `func` invocations and a `flush` method to immediately invoke them.
|
|
16868
|
+
* Provide `options` to indicate whether `func` should be invoked on the
|
|
16869
|
+
* leading and/or trailing edge of the `wait` timeout. The `func` is invoked
|
|
16870
|
+
* with the last arguments provided to the debounced function. Subsequent
|
|
16871
|
+
* calls to the debounced function return the result of the last `func`
|
|
16872
|
+
* invocation.
|
|
16873
|
+
*
|
|
16874
|
+
* **Note:** If `leading` and `trailing` options are `true`, `func` is
|
|
16875
|
+
* invoked on the trailing edge of the timeout only if the debounced function
|
|
16876
|
+
* is invoked more than once during the `wait` timeout.
|
|
16877
|
+
*
|
|
16878
|
+
* If `wait` is `0` and `leading` is `false`, `func` invocation is deferred
|
|
16879
|
+
* until to the next tick, similar to `setTimeout` with a timeout of `0`.
|
|
16880
|
+
*
|
|
16881
|
+
* See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)
|
|
16882
|
+
* for details over the differences between `_.debounce` and `_.throttle`.
|
|
16883
|
+
*
|
|
16884
|
+
* @static
|
|
16885
|
+
* @memberOf _
|
|
16886
|
+
* @since 0.1.0
|
|
16887
|
+
* @category Function
|
|
16888
|
+
* @param {Function} func The function to debounce.
|
|
16889
|
+
* @param {number} [wait=0] The number of milliseconds to delay.
|
|
16890
|
+
* @param {Object} [options={}] The options object.
|
|
16891
|
+
* @param {boolean} [options.leading=false]
|
|
16892
|
+
* Specify invoking on the leading edge of the timeout.
|
|
16893
|
+
* @param {number} [options.maxWait]
|
|
16894
|
+
* The maximum time `func` is allowed to be delayed before it's invoked.
|
|
16895
|
+
* @param {boolean} [options.trailing=true]
|
|
16896
|
+
* Specify invoking on the trailing edge of the timeout.
|
|
16897
|
+
* @returns {Function} Returns the new debounced function.
|
|
16898
|
+
* @example
|
|
16899
|
+
*
|
|
16900
|
+
* // Avoid costly calculations while the window size is in flux.
|
|
16901
|
+
* jQuery(window).on('resize', _.debounce(calculateLayout, 150));
|
|
16902
|
+
*
|
|
16903
|
+
* // Invoke `sendMail` when clicked, debouncing subsequent calls.
|
|
16904
|
+
* jQuery(element).on('click', _.debounce(sendMail, 300, {
|
|
16905
|
+
* 'leading': true,
|
|
16906
|
+
* 'trailing': false
|
|
16907
|
+
* }));
|
|
16908
|
+
*
|
|
16909
|
+
* // Ensure `batchLog` is invoked once after 1 second of debounced calls.
|
|
16910
|
+
* var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 });
|
|
16911
|
+
* var source = new EventSource('/stream');
|
|
16912
|
+
* jQuery(source).on('message', debounced);
|
|
16913
|
+
*
|
|
16914
|
+
* // Cancel the trailing debounced invocation.
|
|
16915
|
+
* jQuery(window).on('popstate', debounced.cancel);
|
|
16916
|
+
*/
|
|
16917
|
+
function debounce(func, wait, options) {
|
|
16918
|
+
var lastArgs,
|
|
16919
|
+
lastThis,
|
|
16920
|
+
maxWait,
|
|
16921
|
+
result,
|
|
16922
|
+
timerId,
|
|
16923
|
+
lastCallTime,
|
|
16924
|
+
lastInvokeTime = 0,
|
|
16925
|
+
leading = false,
|
|
16926
|
+
maxing = false,
|
|
16927
|
+
trailing = true;
|
|
16928
|
+
|
|
16929
|
+
if (typeof func != 'function') {
|
|
16930
|
+
throw new TypeError(FUNC_ERROR_TEXT);
|
|
16931
|
+
}
|
|
16932
|
+
wait = toNumber_1(wait) || 0;
|
|
16933
|
+
if (isObject_1(options)) {
|
|
16934
|
+
leading = !!options.leading;
|
|
16935
|
+
maxing = 'maxWait' in options;
|
|
16936
|
+
maxWait = maxing ? nativeMax(toNumber_1(options.maxWait) || 0, wait) : maxWait;
|
|
16937
|
+
trailing = 'trailing' in options ? !!options.trailing : trailing;
|
|
16938
|
+
}
|
|
16939
|
+
|
|
16940
|
+
function invokeFunc(time) {
|
|
16941
|
+
var args = lastArgs,
|
|
16942
|
+
thisArg = lastThis;
|
|
16943
|
+
|
|
16944
|
+
lastArgs = lastThis = undefined;
|
|
16945
|
+
lastInvokeTime = time;
|
|
16946
|
+
result = func.apply(thisArg, args);
|
|
16947
|
+
return result;
|
|
16948
|
+
}
|
|
16949
|
+
|
|
16950
|
+
function leadingEdge(time) {
|
|
16951
|
+
// Reset any `maxWait` timer.
|
|
16952
|
+
lastInvokeTime = time;
|
|
16953
|
+
// Start the timer for the trailing edge.
|
|
16954
|
+
timerId = setTimeout(timerExpired, wait);
|
|
16955
|
+
// Invoke the leading edge.
|
|
16956
|
+
return leading ? invokeFunc(time) : result;
|
|
16957
|
+
}
|
|
16958
|
+
|
|
16959
|
+
function remainingWait(time) {
|
|
16960
|
+
var timeSinceLastCall = time - lastCallTime,
|
|
16961
|
+
timeSinceLastInvoke = time - lastInvokeTime,
|
|
16962
|
+
timeWaiting = wait - timeSinceLastCall;
|
|
16963
|
+
|
|
16964
|
+
return maxing
|
|
16965
|
+
? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke)
|
|
16966
|
+
: timeWaiting;
|
|
16967
|
+
}
|
|
16968
|
+
|
|
16969
|
+
function shouldInvoke(time) {
|
|
16970
|
+
var timeSinceLastCall = time - lastCallTime,
|
|
16971
|
+
timeSinceLastInvoke = time - lastInvokeTime;
|
|
16972
|
+
|
|
16973
|
+
// Either this is the first call, activity has stopped and we're at the
|
|
16974
|
+
// trailing edge, the system time has gone backwards and we're treating
|
|
16975
|
+
// it as the trailing edge, or we've hit the `maxWait` limit.
|
|
16976
|
+
return (lastCallTime === undefined || (timeSinceLastCall >= wait) ||
|
|
16977
|
+
(timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait));
|
|
16978
|
+
}
|
|
16979
|
+
|
|
16980
|
+
function timerExpired() {
|
|
16981
|
+
var time = now_1();
|
|
16982
|
+
if (shouldInvoke(time)) {
|
|
16983
|
+
return trailingEdge(time);
|
|
16984
|
+
}
|
|
16985
|
+
// Restart the timer.
|
|
16986
|
+
timerId = setTimeout(timerExpired, remainingWait(time));
|
|
16987
|
+
}
|
|
16988
|
+
|
|
16989
|
+
function trailingEdge(time) {
|
|
16990
|
+
timerId = undefined;
|
|
16991
|
+
|
|
16992
|
+
// Only invoke if we have `lastArgs` which means `func` has been
|
|
16993
|
+
// debounced at least once.
|
|
16994
|
+
if (trailing && lastArgs) {
|
|
16995
|
+
return invokeFunc(time);
|
|
16996
|
+
}
|
|
16997
|
+
lastArgs = lastThis = undefined;
|
|
16998
|
+
return result;
|
|
16999
|
+
}
|
|
17000
|
+
|
|
17001
|
+
function cancel() {
|
|
17002
|
+
if (timerId !== undefined) {
|
|
17003
|
+
clearTimeout(timerId);
|
|
17004
|
+
}
|
|
17005
|
+
lastInvokeTime = 0;
|
|
17006
|
+
lastArgs = lastCallTime = lastThis = timerId = undefined;
|
|
17007
|
+
}
|
|
17008
|
+
|
|
17009
|
+
function flush() {
|
|
17010
|
+
return timerId === undefined ? result : trailingEdge(now_1());
|
|
17011
|
+
}
|
|
17012
|
+
|
|
17013
|
+
function debounced() {
|
|
17014
|
+
var time = now_1(),
|
|
17015
|
+
isInvoking = shouldInvoke(time);
|
|
17016
|
+
|
|
17017
|
+
lastArgs = arguments;
|
|
17018
|
+
lastThis = this;
|
|
17019
|
+
lastCallTime = time;
|
|
17020
|
+
|
|
17021
|
+
if (isInvoking) {
|
|
17022
|
+
if (timerId === undefined) {
|
|
17023
|
+
return leadingEdge(lastCallTime);
|
|
17024
|
+
}
|
|
17025
|
+
if (maxing) {
|
|
17026
|
+
// Handle invocations in a tight loop.
|
|
17027
|
+
clearTimeout(timerId);
|
|
17028
|
+
timerId = setTimeout(timerExpired, wait);
|
|
17029
|
+
return invokeFunc(lastCallTime);
|
|
17030
|
+
}
|
|
17031
|
+
}
|
|
17032
|
+
if (timerId === undefined) {
|
|
17033
|
+
timerId = setTimeout(timerExpired, wait);
|
|
17034
|
+
}
|
|
17035
|
+
return result;
|
|
17036
|
+
}
|
|
17037
|
+
debounced.cancel = cancel;
|
|
17038
|
+
debounced.flush = flush;
|
|
17039
|
+
return debounced;
|
|
17040
|
+
}
|
|
17041
|
+
|
|
17042
|
+
var debounce_1 = debounce;
|
|
17043
|
+
|
|
17044
|
+
/** Error message constants. */
|
|
17045
|
+
var FUNC_ERROR_TEXT$1 = 'Expected a function';
|
|
17046
|
+
|
|
17047
|
+
/**
|
|
17048
|
+
* Creates a throttled function that only invokes `func` at most once per
|
|
17049
|
+
* every `wait` milliseconds. The throttled function comes with a `cancel`
|
|
17050
|
+
* method to cancel delayed `func` invocations and a `flush` method to
|
|
17051
|
+
* immediately invoke them. Provide `options` to indicate whether `func`
|
|
17052
|
+
* should be invoked on the leading and/or trailing edge of the `wait`
|
|
17053
|
+
* timeout. The `func` is invoked with the last arguments provided to the
|
|
17054
|
+
* throttled function. Subsequent calls to the throttled function return the
|
|
17055
|
+
* result of the last `func` invocation.
|
|
17056
|
+
*
|
|
17057
|
+
* **Note:** If `leading` and `trailing` options are `true`, `func` is
|
|
17058
|
+
* invoked on the trailing edge of the timeout only if the throttled function
|
|
17059
|
+
* is invoked more than once during the `wait` timeout.
|
|
17060
|
+
*
|
|
17061
|
+
* If `wait` is `0` and `leading` is `false`, `func` invocation is deferred
|
|
17062
|
+
* until to the next tick, similar to `setTimeout` with a timeout of `0`.
|
|
17063
|
+
*
|
|
17064
|
+
* See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)
|
|
17065
|
+
* for details over the differences between `_.throttle` and `_.debounce`.
|
|
17066
|
+
*
|
|
17067
|
+
* @static
|
|
17068
|
+
* @memberOf _
|
|
17069
|
+
* @since 0.1.0
|
|
17070
|
+
* @category Function
|
|
17071
|
+
* @param {Function} func The function to throttle.
|
|
17072
|
+
* @param {number} [wait=0] The number of milliseconds to throttle invocations to.
|
|
17073
|
+
* @param {Object} [options={}] The options object.
|
|
17074
|
+
* @param {boolean} [options.leading=true]
|
|
17075
|
+
* Specify invoking on the leading edge of the timeout.
|
|
17076
|
+
* @param {boolean} [options.trailing=true]
|
|
17077
|
+
* Specify invoking on the trailing edge of the timeout.
|
|
17078
|
+
* @returns {Function} Returns the new throttled function.
|
|
17079
|
+
* @example
|
|
17080
|
+
*
|
|
17081
|
+
* // Avoid excessively updating the position while scrolling.
|
|
17082
|
+
* jQuery(window).on('scroll', _.throttle(updatePosition, 100));
|
|
17083
|
+
*
|
|
17084
|
+
* // Invoke `renewToken` when the click event is fired, but not more than once every 5 minutes.
|
|
17085
|
+
* var throttled = _.throttle(renewToken, 300000, { 'trailing': false });
|
|
17086
|
+
* jQuery(element).on('click', throttled);
|
|
17087
|
+
*
|
|
17088
|
+
* // Cancel the trailing throttled invocation.
|
|
17089
|
+
* jQuery(window).on('popstate', throttled.cancel);
|
|
17090
|
+
*/
|
|
17091
|
+
function throttle(func, wait, options) {
|
|
17092
|
+
var leading = true,
|
|
17093
|
+
trailing = true;
|
|
17094
|
+
|
|
17095
|
+
if (typeof func != 'function') {
|
|
17096
|
+
throw new TypeError(FUNC_ERROR_TEXT$1);
|
|
17097
|
+
}
|
|
17098
|
+
if (isObject_1(options)) {
|
|
17099
|
+
leading = 'leading' in options ? !!options.leading : leading;
|
|
17100
|
+
trailing = 'trailing' in options ? !!options.trailing : trailing;
|
|
17101
|
+
}
|
|
17102
|
+
return debounce_1(func, wait, {
|
|
17103
|
+
'leading': leading,
|
|
17104
|
+
'maxWait': wait,
|
|
17105
|
+
'trailing': trailing
|
|
17106
|
+
});
|
|
17107
|
+
}
|
|
17108
|
+
|
|
17109
|
+
var throttle_1 = throttle;
|
|
17110
|
+
|
|
16535
17111
|
var exportFormats$3 = ['xlsx'];
|
|
16536
17112
|
var totalPageCount = 1;
|
|
16537
17113
|
var loadedPageCount = 1;
|
|
16538
17114
|
var totalRecordCount = 0;
|
|
16539
17115
|
var useToken$1 = theme.useToken;
|
|
16540
17116
|
var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
16541
|
-
var _props$axiosRequest2, _props$selectOptions, _props$selectOptions$, _props$selectOptions2, _props$selectOptions$2, _props$selectOptions3;
|
|
17117
|
+
var _props$axiosRequest2, _props$axiosRequest4, _props$axiosRequest5, _props$axiosRequest6, _props$axiosRequest7, _props$axiosRequest8, _props$axiosRequest9, _props$selectOptions, _props$selectOptions$, _props$selectOptions2, _props$selectOptions$2, _props$selectOptions3;
|
|
16542
17118
|
var _useToken = useToken$1(),
|
|
16543
17119
|
token = _useToken.token;
|
|
16544
17120
|
var _useState = useState([]),
|
|
@@ -16551,12 +17127,6 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16551
17127
|
var gridRef = useRef(null);
|
|
16552
17128
|
var _useState3 = useState(0),
|
|
16553
17129
|
filteredRowCount = _useState3[0];
|
|
16554
|
-
var _useState4 = useState([]),
|
|
16555
|
-
kebabMenuButtons = _useState4[0],
|
|
16556
|
-
setKebabMenuButtons = _useState4[1];
|
|
16557
|
-
var _useState5 = useState([]),
|
|
16558
|
-
actionButtons = _useState5[0],
|
|
16559
|
-
setActionButtons = _useState5[1];
|
|
16560
17130
|
var headers = new Headers({
|
|
16561
17131
|
'Content-Type': 'application/json',
|
|
16562
17132
|
'Authorization': 'Bearer ' + (props.axiosRequest ? props.axiosRequest.token : ""),
|
|
@@ -16564,14 +17134,14 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16564
17134
|
});
|
|
16565
17135
|
useEffect(function () {
|
|
16566
17136
|
var _props$axiosRequest;
|
|
16567
|
-
if (
|
|
17137
|
+
if (Object.keys((_props$axiosRequest = props.axiosRequest) === null || _props$axiosRequest === void 0 ? void 0 : _props$axiosRequest.requestData).length > 0) {
|
|
16568
17138
|
totalPageCount = 1;
|
|
16569
17139
|
loadedPageCount = 1;
|
|
16570
17140
|
totalRecordCount = 0;
|
|
16571
17141
|
setData([]);
|
|
16572
17142
|
fetchData();
|
|
16573
17143
|
}
|
|
16574
|
-
}, [
|
|
17144
|
+
}, [(_props$axiosRequest2 = props.axiosRequest) === null || _props$axiosRequest2 === void 0 ? void 0 : _props$axiosRequest2.requestData]);
|
|
16575
17145
|
useEffect(function () {
|
|
16576
17146
|
locale(localStorage.getItem("locale"));
|
|
16577
17147
|
loadMessages(JSON.parse(localStorage.getItem("localTranslation")));
|
|
@@ -16579,14 +17149,26 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16579
17149
|
gridRef.current.instance.updateDimensions();
|
|
16580
17150
|
}
|
|
16581
17151
|
}, []);
|
|
16582
|
-
|
|
17152
|
+
var actionButtons = useMemo(function () {
|
|
17153
|
+
if (props.actionButtonGroup) {
|
|
17154
|
+
if (props.actionButtonGroup.length >= 2 && !props.edit) {
|
|
17155
|
+
return props.actionButtonGroup.slice(0, 2);
|
|
17156
|
+
} else {
|
|
17157
|
+
return props.actionButtonGroup;
|
|
17158
|
+
}
|
|
17159
|
+
} else {
|
|
17160
|
+
return [];
|
|
17161
|
+
}
|
|
17162
|
+
}, [props.actionButtonGroup]);
|
|
17163
|
+
var kebabMenuButtons = useMemo(function () {
|
|
16583
17164
|
if (props.actionButtonGroup) {
|
|
16584
17165
|
if (props.actionButtonGroup.length >= 2 && !props.edit) {
|
|
16585
|
-
|
|
16586
|
-
setKebabMenuButtons(props.actionButtonGroup.slice(2, props.actionButtonGroup.length));
|
|
17166
|
+
return props.actionButtonGroup.slice(2, props.actionButtonGroup.length);
|
|
16587
17167
|
} else {
|
|
16588
|
-
|
|
17168
|
+
return [];
|
|
16589
17169
|
}
|
|
17170
|
+
} else {
|
|
17171
|
+
return [];
|
|
16590
17172
|
}
|
|
16591
17173
|
}, [props.actionButtonGroup]);
|
|
16592
17174
|
var handleRef = function handleRef(instance) {
|
|
@@ -16594,8 +17176,10 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16594
17176
|
gridRef.current = instance;
|
|
16595
17177
|
}
|
|
16596
17178
|
};
|
|
16597
|
-
var fetchData = function
|
|
17179
|
+
var fetchData = useCallback(function () {
|
|
16598
17180
|
try {
|
|
17181
|
+
var _props$axiosRequest3;
|
|
17182
|
+
if (Object.keys((_props$axiosRequest3 = props.axiosRequest) === null || _props$axiosRequest3 === void 0 ? void 0 : _props$axiosRequest3.requestData).length === 0) return Promise.resolve();
|
|
16599
17183
|
setIsLoading(true);
|
|
16600
17184
|
var _temp2 = function () {
|
|
16601
17185
|
if (props.isServerSide) {
|
|
@@ -16637,21 +17221,8 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16637
17221
|
} catch (e) {
|
|
16638
17222
|
return Promise.reject(e);
|
|
16639
17223
|
}
|
|
16640
|
-
};
|
|
16641
|
-
var
|
|
16642
|
-
setTimeout(function () {
|
|
16643
|
-
var dxScrollable = e.component.getScrollable();
|
|
16644
|
-
if (dxScrollable != null) {
|
|
16645
|
-
dxScrollable.off("scroll");
|
|
16646
|
-
dxScrollable.on("scroll", function (args) {
|
|
16647
|
-
if (args.reachedBottom) {
|
|
16648
|
-
getServerSide("reachedBottom");
|
|
16649
|
-
}
|
|
16650
|
-
});
|
|
16651
|
-
}
|
|
16652
|
-
}, 10);
|
|
16653
|
-
};
|
|
16654
|
-
var onEditorPreparing = function onEditorPreparing(e) {
|
|
17224
|
+
}, [(_props$axiosRequest4 = props.axiosRequest) === null || _props$axiosRequest4 === void 0 ? void 0 : _props$axiosRequest4.requestData, (_props$axiosRequest5 = props.axiosRequest) === null || _props$axiosRequest5 === void 0 ? void 0 : _props$axiosRequest5.apiUrl, (_props$axiosRequest6 = props.axiosRequest) === null || _props$axiosRequest6 === void 0 ? void 0 : _props$axiosRequest6.environmentUrl, (_props$axiosRequest7 = props.axiosRequest) === null || _props$axiosRequest7 === void 0 ? void 0 : _props$axiosRequest7.requestQueryString, (_props$axiosRequest8 = props.axiosRequest) === null || _props$axiosRequest8 === void 0 ? void 0 : _props$axiosRequest8.requestType, props.pageSize, props.isServerSide]);
|
|
17225
|
+
var onEditorPreparing = useCallback(function (e) {
|
|
16655
17226
|
if (e.row !== undefined && e.parentType === 'dataRow') {
|
|
16656
17227
|
if (props.isServerSide) {
|
|
16657
17228
|
var disableScrolling = function disableScrolling() {
|
|
@@ -16664,19 +17235,34 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16664
17235
|
e.editorOptions.onFocusOut = enableScrolling;
|
|
16665
17236
|
}
|
|
16666
17237
|
}
|
|
16667
|
-
};
|
|
16668
|
-
var getServerSide = function
|
|
16669
|
-
|
|
16670
|
-
|
|
16671
|
-
|
|
16672
|
-
|
|
16673
|
-
|
|
16674
|
-
|
|
16675
|
-
|
|
17238
|
+
}, [props.isServerSide]);
|
|
17239
|
+
var getServerSide = useCallback(function (type) {
|
|
17240
|
+
try {
|
|
17241
|
+
var run = throttle_1(function (type) {
|
|
17242
|
+
try {
|
|
17243
|
+
return Promise.resolve(function () {
|
|
17244
|
+
if (type === "reachedBottom") {
|
|
17245
|
+
return function () {
|
|
17246
|
+
if (totalPageCount <= loadedPageCount) {} else {
|
|
17247
|
+
loadedPageCount = loadedPageCount + 1;
|
|
17248
|
+
return Promise.resolve(fetchData()).then(function () {});
|
|
17249
|
+
}
|
|
17250
|
+
}();
|
|
17251
|
+
}
|
|
17252
|
+
}());
|
|
17253
|
+
} catch (e) {
|
|
17254
|
+
return Promise.reject(e);
|
|
17255
|
+
}
|
|
17256
|
+
}, 5000, {
|
|
17257
|
+
trailing: false
|
|
17258
|
+
});
|
|
17259
|
+
run(type);
|
|
17260
|
+
return Promise.resolve();
|
|
17261
|
+
} catch (e) {
|
|
17262
|
+
return Promise.reject(e);
|
|
16676
17263
|
}
|
|
16677
|
-
|
|
16678
|
-
|
|
16679
|
-
var onExporting = function onExporting(e) {
|
|
17264
|
+
}, [totalPageCount, loadedPageCount, fetchData]);
|
|
17265
|
+
var onExporting = useCallback(function (e) {
|
|
16680
17266
|
if (e.format === 'xlsx') {
|
|
16681
17267
|
var workbook = new Workbook();
|
|
16682
17268
|
exportDataGrid({
|
|
@@ -16700,8 +17286,8 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16700
17286
|
doc.save(fileName + '.pdf');
|
|
16701
17287
|
});
|
|
16702
17288
|
}
|
|
16703
|
-
};
|
|
16704
|
-
var customLoad = function
|
|
17289
|
+
}, [fileName]);
|
|
17290
|
+
var customLoad = useCallback(function () {
|
|
16705
17291
|
var state = JSON.parse(localStorage.getItem(props.exportFileName + "Storage"));
|
|
16706
17292
|
if (localStorage.getItem(props.exportFileName + "Storage")) {
|
|
16707
17293
|
state.selectedRowKeys = [];
|
|
@@ -16712,8 +17298,8 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16712
17298
|
};
|
|
16713
17299
|
}
|
|
16714
17300
|
return state;
|
|
16715
|
-
};
|
|
16716
|
-
var customSave = function
|
|
17301
|
+
}, [props.filterEnabledShow]);
|
|
17302
|
+
var customSave = useCallback(function (state) {
|
|
16717
17303
|
state.selectedRowKeys = [];
|
|
16718
17304
|
if (props.filterEnabledShow) state.filterPanel = {
|
|
16719
17305
|
filterEnabled: false
|
|
@@ -16721,8 +17307,8 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16721
17307
|
filterEnabled: true
|
|
16722
17308
|
};
|
|
16723
17309
|
localStorage.setItem(props.exportFileName + "Storage", JSON.stringify(state));
|
|
16724
|
-
};
|
|
16725
|
-
var onEditorPrepared = function
|
|
17310
|
+
}, [props.filterEnabledShow]);
|
|
17311
|
+
var onEditorPrepared = useCallback(function (info) {
|
|
16726
17312
|
if (info.parentType === 'filterRow' && info.editorName === "dxSelectBox" && info.dataField === "IsActive") {
|
|
16727
17313
|
if (info.dataSource != null && info.dataSource.length > 0) {
|
|
16728
17314
|
info.showAllText = info.dataSource.find(function (i) {
|
|
@@ -16736,8 +17322,8 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16736
17322
|
}).label;
|
|
16737
17323
|
}
|
|
16738
17324
|
}
|
|
16739
|
-
};
|
|
16740
|
-
var renderTotal = function
|
|
17325
|
+
}, []);
|
|
17326
|
+
var renderTotal = useCallback(function () {
|
|
16741
17327
|
var totalloaded = 0;
|
|
16742
17328
|
if (data.length < 50) {
|
|
16743
17329
|
totalloaded = data.length;
|
|
@@ -16751,15 +17337,15 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16751
17337
|
result = totalRecordCount > 0 ? totalloaded + " Loaded - " + totalRecordCount + " Total" : "";
|
|
16752
17338
|
}
|
|
16753
17339
|
return result;
|
|
16754
|
-
};
|
|
16755
|
-
var renderTotalPaging = function
|
|
17340
|
+
}, [data, filteredRowCount, loadedPageCount, props.pageSize, totalRecordCount]);
|
|
17341
|
+
var renderTotalPaging = useCallback(function () {
|
|
16756
17342
|
var result = "";
|
|
16757
17343
|
if (totalPageCount > 1) {
|
|
16758
17344
|
result = loadedPageCount + " / " + totalPageCount;
|
|
16759
17345
|
}
|
|
16760
17346
|
return result;
|
|
16761
|
-
};
|
|
16762
|
-
var actionCellRender = function
|
|
17347
|
+
}, [loadedPageCount, totalPageCount]);
|
|
17348
|
+
var actionCellRender = useMemo(function () {
|
|
16763
17349
|
return React.createElement(DropDownButton, {
|
|
16764
17350
|
icon: server_browser.renderToString(React.createElement(DynamicIcon, {
|
|
16765
17351
|
iconName: 'kebabMenu'
|
|
@@ -16769,11 +17355,45 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16769
17355
|
return e.itemData.onClick();
|
|
16770
17356
|
}
|
|
16771
17357
|
});
|
|
17358
|
+
}, [kebabMenuButtons]);
|
|
17359
|
+
var onScrollEnd = useCallback(function () {
|
|
17360
|
+
getServerSide("reachedBottom");
|
|
17361
|
+
}, [(_props$axiosRequest9 = props.axiosRequest) === null || _props$axiosRequest9 === void 0 ? void 0 : _props$axiosRequest9.requestData, getServerSide]);
|
|
17362
|
+
var handleScroll = function handleScroll(e) {
|
|
17363
|
+
var run = debounce_1(function (e) {
|
|
17364
|
+
var _scrollable$scrollTop, _scrollable$clientHei, _scrollable$scrollHei;
|
|
17365
|
+
var scrollable = e.target;
|
|
17366
|
+
var top = (_scrollable$scrollTop = scrollable === null || scrollable === void 0 ? void 0 : scrollable.scrollTop) != null ? _scrollable$scrollTop : 0;
|
|
17367
|
+
var height = (_scrollable$clientHei = scrollable === null || scrollable === void 0 ? void 0 : scrollable.clientHeight) != null ? _scrollable$clientHei : 0;
|
|
17368
|
+
var scrollHeight = (_scrollable$scrollHei = scrollable === null || scrollable === void 0 ? void 0 : scrollable.scrollHeight) != null ? _scrollable$scrollHei : 0;
|
|
17369
|
+
var maxHeight = Math.max(top, height, scrollHeight) - 1;
|
|
17370
|
+
var reachedBottom = Math.ceil(top + height) >= maxHeight;
|
|
17371
|
+
console.log("reachedBottom", Math.ceil(top + height), maxHeight, reachedBottom);
|
|
17372
|
+
var lastScrollTop = 0;
|
|
17373
|
+
if (top < lastScrollTop) {
|
|
17374
|
+
return;
|
|
17375
|
+
}
|
|
17376
|
+
lastScrollTop = top <= 0 ? 0 : top;
|
|
17377
|
+
if (reachedBottom) {
|
|
17378
|
+
onScrollEnd();
|
|
17379
|
+
}
|
|
17380
|
+
}, 200);
|
|
17381
|
+
run(e);
|
|
16772
17382
|
};
|
|
17383
|
+
useEffect(function () {
|
|
17384
|
+
var scrollable = document.querySelector('.dx-scrollable-container');
|
|
17385
|
+
if (scrollable) {
|
|
17386
|
+
scrollable.addEventListener('scrollend', handleScroll);
|
|
17387
|
+
}
|
|
17388
|
+
return function () {
|
|
17389
|
+
if (scrollable) {
|
|
17390
|
+
scrollable.removeEventListener('scrollend', handleScroll);
|
|
17391
|
+
}
|
|
17392
|
+
};
|
|
17393
|
+
}, [data.length]);
|
|
16773
17394
|
return React.createElement(React.Fragment, null, React.createElement(DataGrid$1, {
|
|
16774
17395
|
keyExpr: props.keyExpr,
|
|
16775
17396
|
dataSource: props.isServerSide ? data : props.dataSource,
|
|
16776
|
-
onContentReady: onContentReady,
|
|
16777
17397
|
showBorders: true,
|
|
16778
17398
|
columnAutoWidth: false,
|
|
16779
17399
|
onEditorPreparing: onEditorPreparing,
|
|
@@ -16841,7 +17461,9 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16841
17461
|
caption: "",
|
|
16842
17462
|
type: "buttons",
|
|
16843
17463
|
showInColumnChooser: false,
|
|
16844
|
-
cellRender:
|
|
17464
|
+
cellRender: function cellRender() {
|
|
17465
|
+
return actionCellRender;
|
|
17466
|
+
}
|
|
16845
17467
|
}), props.edit && React.createElement(Editing, {
|
|
16846
17468
|
mode: props.edit.mode,
|
|
16847
17469
|
allowUpdating: props.edit.allowUpdating,
|
|
@@ -16959,7 +17581,6 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
|
|
|
16959
17581
|
customSave: customSave
|
|
16960
17582
|
})));
|
|
16961
17583
|
};
|
|
16962
|
-
var OdsRemoteDataGrid$1 = React.memo(OdsRemoteDataGrid);
|
|
16963
17584
|
|
|
16964
|
-
export { DxTreeList, DxTreeView, OdsAlert, OdsAutoComplete, OdsBannerAlert, OdsBasicForm, OdsBasicTable, OdsButton, OdsCalendar, OdsCard, OdsCheckbox, OdsCheckboxGroup, OdsCollapse, OdsCustomMultiSelect, OdsDataGrid, OdsDataGridNew, OdsDateRangePicker, OdsDateRangePicker as OdsDatepicker, OdsDisplayGrid, OdsDivider, OdsCollapse as OdsDropdown, OdsDropdownButton, OdsImage, OdsInput, OdsInputNumber, OdsLink, OdsList, OdsLogin, OdsMessage, OdsModal, OdsNotification, OdsParagraph, OdsPassword, OdsPhoneInput, OdsProfDataGrid, OdsRadio, OdsRadioGroup, OdsRangeTimepicker, OdsRate, OdsRemoteDataGrid
|
|
17585
|
+
export { DxTreeList, DxTreeView, OdsAlert, OdsAutoComplete, OdsBannerAlert, OdsBasicForm, OdsBasicTable, OdsButton, OdsCalendar, OdsCard, OdsCheckbox, OdsCheckboxGroup, OdsCollapse, OdsCustomMultiSelect, OdsDataGrid, OdsDataGridNew, OdsDateRangePicker, OdsDateRangePicker as OdsDatepicker, OdsDisplayGrid, OdsDivider, OdsCollapse as OdsDropdown, OdsDropdownButton, OdsImage, OdsInput, OdsInputNumber, OdsLink, OdsList, OdsLogin, OdsMessage, OdsModal, OdsNotification, OdsParagraph, OdsPassword, OdsPhoneInput, OdsProfDataGrid, OdsRadio, OdsRadioGroup, OdsRangeTimepicker, OdsRate, OdsRemoteDataGrid, OdsSearch, OdsSelect, OdsSelectableTable, OdsSpin, OdsSwitch, OdsTab, OdsBasicTable as OdsTable, OdsTag, OdsText, OdsTextArea, OdsTimeline, OdsTimepicker, OdsTitle };
|
|
16965
17586
|
//# sourceMappingURL=index.modern.js.map
|