funda-ui 4.4.15 → 4.4.35

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.
Files changed (50) hide show
  1. package/EventCalendar/index.css +114 -114
  2. package/EventCalendar/index.d.ts +1 -0
  3. package/EventCalendar/index.js +116 -84
  4. package/EventCalendarTimeline/index.css +274 -270
  5. package/EventCalendarTimeline/index.d.ts +3 -0
  6. package/EventCalendarTimeline/index.js +641 -224
  7. package/MultipleCheckboxes/index.js +11 -11
  8. package/MultipleSelect/index.js +11 -11
  9. package/NativeSelect/index.js +11 -11
  10. package/Radio/index.js +11 -11
  11. package/Select/index.js +11 -11
  12. package/Table/index.css +1 -0
  13. package/Table/index.js +36 -7
  14. package/TagInput/index.d.ts +1 -0
  15. package/TagInput/index.js +20 -2
  16. package/Tree/index.js +11 -11
  17. package/Utils/object.js +11 -11
  18. package/Utils/os.d.ts +2 -0
  19. package/Utils/os.js +104 -0
  20. package/lib/cjs/EventCalendar/index.d.ts +1 -0
  21. package/lib/cjs/EventCalendar/index.js +116 -84
  22. package/lib/cjs/EventCalendarTimeline/index.d.ts +3 -0
  23. package/lib/cjs/EventCalendarTimeline/index.js +641 -224
  24. package/lib/cjs/MultipleCheckboxes/index.js +11 -11
  25. package/lib/cjs/MultipleSelect/index.js +11 -11
  26. package/lib/cjs/NativeSelect/index.js +11 -11
  27. package/lib/cjs/Radio/index.js +11 -11
  28. package/lib/cjs/Select/index.js +11 -11
  29. package/lib/cjs/Table/index.js +36 -7
  30. package/lib/cjs/TagInput/index.d.ts +1 -0
  31. package/lib/cjs/TagInput/index.js +20 -2
  32. package/lib/cjs/Tree/index.js +11 -11
  33. package/lib/cjs/Utils/object.js +11 -11
  34. package/lib/cjs/Utils/os.d.ts +2 -0
  35. package/lib/cjs/Utils/os.js +104 -0
  36. package/lib/css/EventCalendar/index.css +114 -114
  37. package/lib/css/EventCalendarTimeline/index.css +274 -270
  38. package/lib/css/Table/index.css +1 -0
  39. package/lib/esm/EventCalendar/index.scss +81 -81
  40. package/lib/esm/EventCalendar/index.tsx +136 -98
  41. package/lib/esm/EventCalendarTimeline/index.scss +226 -221
  42. package/lib/esm/EventCalendarTimeline/index.tsx +445 -207
  43. package/lib/esm/ModalDialog/index.tsx +0 -1
  44. package/lib/esm/Table/Table.tsx +0 -1
  45. package/lib/esm/Table/index.scss +2 -0
  46. package/lib/esm/Table/utils/hooks/useTableDraggable.tsx +47 -6
  47. package/lib/esm/TagInput/index.tsx +23 -1
  48. package/lib/esm/Utils/libs/object.ts +67 -67
  49. package/lib/esm/Utils/libs/os.ts +63 -0
  50. package/package.json +1 -1
@@ -3191,6 +3191,146 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
3191
3191
 
3192
3192
  /***/ }),
3193
3193
 
3194
+ /***/ 13:
3195
+ /***/ (function(module, exports, __webpack_require__) {
3196
+
3197
+ /* module decorator */ module = __webpack_require__.nmd(module);
3198
+ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
3199
+ (function webpackUniversalModuleDefinition(root, factory) {
3200
+ if (( false ? 0 : _typeof(exports)) === 'object' && ( false ? 0 : _typeof(module)) === 'object') module.exports = factory();else if (true) !(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory),
3201
+ __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?
3202
+ (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),
3203
+ __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));else {}
3204
+ })(this, function () {
3205
+ return (/******/function () {
3206
+ // webpackBootstrap
3207
+ /******/
3208
+ "use strict";
3209
+
3210
+ /******/ // The require scope
3211
+ /******/
3212
+ var __nested_webpack_require_987__ = {};
3213
+ /******/
3214
+ /************************************************************************/
3215
+ /******/ /* webpack/runtime/define property getters */
3216
+ /******/
3217
+ (function () {
3218
+ /******/ // define getter functions for harmony exports
3219
+ /******/__nested_webpack_require_987__.d = function (exports, definition) {
3220
+ /******/for (var key in definition) {
3221
+ /******/if (__nested_webpack_require_987__.o(definition, key) && !__nested_webpack_require_987__.o(exports, key)) {
3222
+ /******/Object.defineProperty(exports, key, {
3223
+ enumerable: true,
3224
+ get: definition[key]
3225
+ });
3226
+ /******/
3227
+ }
3228
+ /******/
3229
+ }
3230
+ /******/
3231
+ };
3232
+ /******/
3233
+ })();
3234
+ /******/
3235
+ /******/ /* webpack/runtime/hasOwnProperty shorthand */
3236
+ /******/
3237
+ (function () {
3238
+ /******/__nested_webpack_require_987__.o = function (obj, prop) {
3239
+ return Object.prototype.hasOwnProperty.call(obj, prop);
3240
+ };
3241
+ /******/
3242
+ })();
3243
+ /******/
3244
+ /******/ /* webpack/runtime/make namespace object */
3245
+ /******/
3246
+ (function () {
3247
+ /******/ // define __esModule on exports
3248
+ /******/__nested_webpack_require_987__.r = function (exports) {
3249
+ /******/if (typeof Symbol !== 'undefined' && Symbol.toStringTag) {
3250
+ /******/Object.defineProperty(exports, Symbol.toStringTag, {
3251
+ value: 'Module'
3252
+ });
3253
+ /******/
3254
+ }
3255
+ /******/
3256
+ Object.defineProperty(exports, '__esModule', {
3257
+ value: true
3258
+ });
3259
+ /******/
3260
+ };
3261
+ /******/
3262
+ })();
3263
+ /******/
3264
+ /************************************************************************/
3265
+ var __webpack_exports__ = {};
3266
+ __nested_webpack_require_987__.r(__webpack_exports__);
3267
+ /* harmony export */
3268
+ __nested_webpack_require_987__.d(__webpack_exports__, {
3269
+ /* harmony export */"default": function _default() {
3270
+ return __WEBPACK_DEFAULT_EXPORT__;
3271
+ }
3272
+ /* harmony export */
3273
+ });
3274
+ /*
3275
+ * Determine whether it is a special platform
3276
+ *
3277
+ * @private
3278
+ */
3279
+ function getOs() {
3280
+ if (typeof window === 'undefined') return {};
3281
+ var os;
3282
+ if (typeof window !== "undefined") {
3283
+ var _getOs = function _getOs() {
3284
+ var _navigator = window.navigator;
3285
+ var platform = function platform() {
3286
+ // 2022 way of detecting. Note : this userAgentData feature is available only in secure contexts (HTTPS)
3287
+ if (typeof _navigator.userAgentData !== 'undefined' && _navigator.userAgentData != null) {
3288
+ return _navigator.userAgentData.platform;
3289
+ }
3290
+ // Deprecated but still works for most of the browser
3291
+ if (typeof _navigator.platform !== 'undefined') {
3292
+ if (typeof _navigator.userAgent !== 'undefined' && /android/.test(_navigator.userAgent.toLowerCase())) {
3293
+ // android device’s _navigator.platform is often set as 'linux', so const’s use userAgent for them
3294
+ return 'android';
3295
+ }
3296
+ return _navigator.platform;
3297
+ }
3298
+ return 'unknown';
3299
+ };
3300
+ var _platform = platform().toLowerCase();
3301
+ var isOSX = /mac/.test(_platform); // Mac desktop
3302
+ var isIOS = ['iphone', 'ipad', 'ipod'].indexOf(_platform) === -1 ? false : true; // Mac iOs
3303
+ var isApple = isOSX || isIOS; // Apple device (desktop or iOS)
3304
+ var isWindows = /win/.test(_platform); // Windows
3305
+ var isAndroid = /android/.test(_platform); // Android
3306
+ var isLinux = /linux/.test(_platform); // Linux
3307
+
3308
+ return {
3309
+ isOSX: isOSX,
3310
+ isIOS: isIOS,
3311
+ isApple: isApple,
3312
+ isWindows: isWindows,
3313
+ isAndroid: isAndroid,
3314
+ isLinux: isLinux
3315
+ };
3316
+ };
3317
+ os = _getOs();
3318
+ } else {
3319
+ os = {};
3320
+ }
3321
+ return os;
3322
+ }
3323
+ /* harmony default export */
3324
+ var __WEBPACK_DEFAULT_EXPORT__ = getOs;
3325
+ /******/
3326
+ return __webpack_exports__;
3327
+ /******/
3328
+ }()
3329
+ );
3330
+ });
3331
+
3332
+ /***/ }),
3333
+
3194
3334
  /***/ 761:
3195
3335
  /***/ (function(module, exports, __webpack_require__) {
3196
3336
 
@@ -3719,6 +3859,8 @@ __webpack_require__.r(__webpack_exports__);
3719
3859
  /* harmony import */ var funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__);
3720
3860
  /* harmony import */ var funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(188);
3721
3861
  /* harmony import */ var funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__);
3862
+ /* harmony import */ var funda_utils_dist_cjs_os__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(13);
3863
+ /* harmony import */ var funda_utils_dist_cjs_os__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(funda_utils_dist_cjs_os__WEBPACK_IMPORTED_MODULE_8__);
3722
3864
  function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
3723
3865
  function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return exports; }; var exports = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, defineProperty = Object.defineProperty || function (obj, key, desc) { obj[key] = desc.value; }, $Symbol = "function" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || "@@iterator", asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator", toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag"; function define(obj, key, value) { return Object.defineProperty(obj, key, { value: value, enumerable: !0, configurable: !0, writable: !0 }), obj[key]; } try { define({}, ""); } catch (err) { define = function define(obj, key, value) { return obj[key] = value; }; } function wrap(innerFn, outerFn, self, tryLocsList) { var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []); return defineProperty(generator, "_invoke", { value: makeInvokeMethod(innerFn, self, context) }), generator; } function tryCatch(fn, obj, arg) { try { return { type: "normal", arg: fn.call(obj, arg) }; } catch (err) { return { type: "throw", arg: err }; } } exports.wrap = wrap; var ContinueSentinel = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var IteratorPrototype = {}; define(IteratorPrototype, iteratorSymbol, function () { return this; }); var getProto = Object.getPrototypeOf, NativeIteratorPrototype = getProto && getProto(getProto(values([]))); NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype); var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype); function defineIteratorMethods(prototype) { ["next", "throw", "return"].forEach(function (method) { define(prototype, method, function (arg) { return this._invoke(method, arg); }); }); } function AsyncIterator(generator, PromiseImpl) { function invoke(method, arg, resolve, reject) { var record = tryCatch(generator[method], generator, arg); if ("throw" !== record.type) { var result = record.arg, value = result.value; return value && "object" == _typeof(value) && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) { invoke("next", value, resolve, reject); }, function (err) { invoke("throw", err, resolve, reject); }) : PromiseImpl.resolve(value).then(function (unwrapped) { result.value = unwrapped, resolve(result); }, function (error) { return invoke("throw", error, resolve, reject); }); } reject(record.arg); } var previousPromise; defineProperty(this, "_invoke", { value: function value(method, arg) { function callInvokeWithMethodAndArg() { return new PromiseImpl(function (resolve, reject) { invoke(method, arg, resolve, reject); }); } return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(innerFn, self, context) { var state = "suspendedStart"; return function (method, arg) { if ("executing" === state) throw new Error("Generator is already running"); if ("completed" === state) { if ("throw" === method) throw arg; return doneResult(); } for (context.method = method, context.arg = arg;;) { var delegate = context.delegate; if (delegate) { var delegateResult = maybeInvokeDelegate(delegate, context); if (delegateResult) { if (delegateResult === ContinueSentinel) continue; return delegateResult; } } if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) { if ("suspendedStart" === state) throw state = "completed", context.arg; context.dispatchException(context.arg); } else "return" === context.method && context.abrupt("return", context.arg); state = "executing"; var record = tryCatch(innerFn, self, context); if ("normal" === record.type) { if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue; return { value: record.arg, done: context.done }; } "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg); } }; } function maybeInvokeDelegate(delegate, context) { var methodName = context.method, method = delegate.iterator[methodName]; if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator["return"] && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel; var record = tryCatch(method, delegate.iterator, context.arg); if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel; var info = record.arg; return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel); } function pushTryEntry(locs) { var entry = { tryLoc: locs[0] }; 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry); } function resetTryEntry(entry) { var record = entry.completion || {}; record.type = "normal", delete record.arg, entry.completion = record; } function Context(tryLocsList) { this.tryEntries = [{ tryLoc: "root" }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0); } function values(iterable) { if (iterable) { var iteratorMethod = iterable[iteratorSymbol]; if (iteratorMethod) return iteratorMethod.call(iterable); if ("function" == typeof iterable.next) return iterable; if (!isNaN(iterable.length)) { var i = -1, next = function next() { for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next; return next.value = undefined, next.done = !0, next; }; return next.next = next; } } return { next: doneResult }; } function doneResult() { return { value: undefined, done: !0 }; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), defineProperty(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) { var ctor = "function" == typeof genFun && genFun.constructor; return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name)); }, exports.mark = function (genFun) { return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun; }, exports.awrap = function (arg) { return { __await: arg }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () { return this; }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) { void 0 === PromiseImpl && (PromiseImpl = Promise); var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl); return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) { return result.done ? result.value : iter.next(); }); }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () { return this; }), define(Gp, "toString", function () { return "[object Generator]"; }), exports.keys = function (val) { var object = Object(val), keys = []; for (var key in object) keys.push(key); return keys.reverse(), function next() { for (; keys.length;) { var key = keys.pop(); if (key in object) return next.value = key, next.done = !1, next; } return next.done = !0, next; }; }, exports.values = values, Context.prototype = { constructor: Context, reset: function reset(skipTempReset) { if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined); }, stop: function stop() { this.done = !0; var rootRecord = this.tryEntries[0].completion; if ("throw" === rootRecord.type) throw rootRecord.arg; return this.rval; }, dispatchException: function dispatchException(exception) { if (this.done) throw exception; var context = this; function handle(loc, caught) { return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught; } for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i], record = entry.completion; if ("root" === entry.tryLoc) return handle("end"); if (entry.tryLoc <= this.prev) { var hasCatch = hasOwn.call(entry, "catchLoc"), hasFinally = hasOwn.call(entry, "finallyLoc"); if (hasCatch && hasFinally) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } else if (hasCatch) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); } else { if (!hasFinally) throw new Error("try statement without catch or finally"); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } } } }, abrupt: function abrupt(type, arg) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) { var finallyEntry = entry; break; } } finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null); var record = finallyEntry ? finallyEntry.completion : {}; return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record); }, complete: function complete(record, afterLoc) { if ("throw" === record.type) throw record.arg; return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel; }, finish: function finish(finallyLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel; } }, "catch": function _catch(tryLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc === tryLoc) { var record = entry.completion; if ("throw" === record.type) { var thrown = record.arg; resetTryEntry(entry); } return thrown; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(iterable, resultName, nextLoc) { return this.delegate = { iterator: values(iterable), resultName: resultName, nextLoc: nextLoc }, "next" === this.method && (this.arg = undefined), ContinueSentinel; } }, exports; }
3724
3866
  function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
@@ -3741,6 +3883,7 @@ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
3741
3883
 
3742
3884
 
3743
3885
 
3886
+
3744
3887
  var EventCalendarTimeline = function EventCalendarTimeline(props) {
3745
3888
  var contentRef = props.contentRef,
3746
3889
  calendarWrapperClassName = props.calendarWrapperClassName,
@@ -3806,7 +3949,10 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
3806
3949
  onCellMouseLeave = props.onCellMouseLeave,
3807
3950
  onCellMouseUp = props.onCellMouseUp,
3808
3951
  onCellClick = props.onCellClick,
3952
+ onCellDoubleClick = props.onCellDoubleClick,
3809
3953
  onKeyPressed = props.onKeyPressed,
3954
+ onKeyCopy = props.onKeyCopy,
3955
+ onKeyPaste = props.onKeyPaste,
3810
3956
  tableListSectionTitle = props.tableListSectionTitle,
3811
3957
  tableCellMinWidth = props.tableCellMinWidth,
3812
3958
  tableTooltipDirection = props.tableTooltipDirection,
@@ -3833,12 +3979,13 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
3833
3979
  var day = date.getDate();
3834
3980
  return month + ' ' + day;
3835
3981
  };
3982
+ var START_WEEK_ON = 1; // represents "Monday/1" in JavaScript
3836
3983
 
3837
3984
  // orginal data
3838
3985
  var _useState = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)([]),
3839
3986
  _useState2 = _slicedToArray(_useState, 2),
3840
- val = _useState2[0],
3841
- setVal = _useState2[1];
3987
+ orginalData = _useState2[0],
3988
+ setOrginalData = _useState2[1];
3842
3989
 
3843
3990
  //
3844
3991
  var FILL_BLANK_DATE_DISABLD = typeof forwardAndBackFillDisabled === 'undefined' ? true : forwardAndBackFillDisabled;
@@ -3916,34 +4063,54 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
3916
4063
  var scrollBodyRef = (0,react__WEBPACK_IMPORTED_MODULE_0__.useRef)(null);
3917
4064
  var scrollListRef = (0,react__WEBPACK_IMPORTED_MODULE_0__.useRef)(null);
3918
4065
 
3919
- // Open temporary storage for pop-ups
3920
- var _useState27 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(-1),
4066
+ // Temporary date
4067
+ var _useState27 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(''),
3921
4068
  _useState28 = _slicedToArray(_useState27, 2),
3922
- tableRowNum = _useState28[0],
3923
- setTableRowNum = _useState28[1];
4069
+ tempDate = _useState28[0],
4070
+ setTempDate = _useState28[1];
4071
+
4072
+ // Open temporary storage for pop-ups
3924
4073
  var _useState29 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(-1),
3925
4074
  _useState30 = _slicedToArray(_useState29, 2),
3926
- tableCellId = _useState30[0],
3927
- setTableCellId = _useState30[1];
4075
+ tableRowNum = _useState30[0],
4076
+ setTableRowNum = _useState30[1];
4077
+ var _useState31 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(-1),
4078
+ _useState32 = _slicedToArray(_useState31, 2),
4079
+ tableCellId = _useState32[0],
4080
+ setTableCellId = _useState32[1];
3928
4081
 
3929
4082
  // table grid tooltip
3930
4083
  var CELL_TOOLTIP_EXCEEDED_SIDE_POS_OFFSET = Number(tableTooltipExceededSidePosOffset) || 15;
3931
4084
  var CELL_TOOLTIP_POS_OFFSET = typeof tableTooltipOffset === 'undefined' ? 10 : tableTooltipOffset;
3932
4085
  var tableTooltipModalRef = (0,react__WEBPACK_IMPORTED_MODULE_0__.useRef)(null);
3933
- var _useState31 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(false),
3934
- _useState32 = _slicedToArray(_useState31, 2),
3935
- isShowTableTooltip = _useState32[0],
3936
- setIsShowTableTooltip = _useState32[1];
3937
- var _useState33 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(null),
4086
+ var _useState33 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(false),
3938
4087
  _useState34 = _slicedToArray(_useState33, 2),
3939
- tableTooltipContent = _useState34[0],
3940
- setTableTooltipContent = _useState34[1];
4088
+ isShowTableTooltip = _useState34[0],
4089
+ setIsShowTableTooltip = _useState34[1];
4090
+ var _useState35 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(null),
4091
+ _useState36 = _slicedToArray(_useState35, 2),
4092
+ tableTooltipContent = _useState36[0],
4093
+ setTableTooltipContent = _useState36[1];
3941
4094
 
3942
4095
  // appearance mode
3943
- var _useState35 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(appearance),
3944
- _useState36 = _slicedToArray(_useState35, 2),
3945
- appearanceMode = _useState36[0],
3946
- setAppearanceMode = _useState36[1];
4096
+ var _useState37 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(appearance),
4097
+ _useState38 = _slicedToArray(_useState37, 2),
4098
+ appearanceMode = _useState38[0],
4099
+ setAppearanceMode = _useState38[1];
4100
+ var findMondayAndTruncate = function findMondayAndTruncate(dates) {
4101
+ var _res = dates.map(function (s) {
4102
+ return new Date(s);
4103
+ });
4104
+ // Find the first Monday in the sequence
4105
+ for (var i = 0; i < _res.length; i++) {
4106
+ var _date2 = _res[i];
4107
+ if (_date2.getDay() === START_WEEK_ON) {
4108
+ // Return dates starting from Monday onwards
4109
+ return dates.slice(i);
4110
+ }
4111
+ }
4112
+ return []; // Return empty array if no Monday found
4113
+ };
3947
4114
 
3948
4115
  // exposes the following methods
3949
4116
  (0,react__WEBPACK_IMPORTED_MODULE_0__.useImperativeHandle)(contentRef, function () {
@@ -3960,6 +4127,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
3960
4127
  resetSelectedCells: function resetSelectedCells() {
3961
4128
  // reset selection area
3962
4129
  setSelectedCells([]);
4130
+ setCopiedCells(null);
3963
4131
  }
3964
4132
  };
3965
4133
  }, [contentRef]);
@@ -3972,10 +4140,10 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
3972
4140
  //================================================================
3973
4141
  // Weekly calendar
3974
4142
  //================================================================
3975
- var _useState37 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(0),
3976
- _useState38 = _slicedToArray(_useState37, 2),
3977
- weekOffset = _useState38[0],
3978
- setWeekOffset = _useState38[1];
4143
+ var _useState39 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(0),
4144
+ _useState40 = _slicedToArray(_useState39, 2),
4145
+ weekOffset = _useState40[0],
4146
+ setWeekOffset = _useState40[1];
3979
4147
  var handleNextWeek = function handleNextWeek() {
3980
4148
  setWeekOffset(weekOffset + 1);
3981
4149
  return weekOffset + 1;
@@ -3985,29 +4153,26 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
3985
4153
  return weekOffset - 1;
3986
4154
  };
3987
4155
  var weekDates = (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getWeekDatesFromMon)(weekOffset);
3988
- var _useState39 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)([]),
3989
- _useState40 = _slicedToArray(_useState39, 2),
3990
- displayWeekForHeader = _useState40[0],
3991
- setDisplayWeekForHeader = _useState40[1];
4156
+ var _useState41 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)([]),
4157
+ _useState42 = _slicedToArray(_useState41, 2),
4158
+ displayWeekForHeader = _useState42[0],
4159
+ setDisplayWeekForHeader = _useState42[1];
3992
4160
 
3993
4161
  //================================================================
3994
4162
  // Drag to activate the selection area
3995
4163
  //================================================================
3996
- var _useState41 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(false),
3997
- _useState42 = _slicedToArray(_useState41, 2),
3998
- isSelecting = _useState42[0],
3999
- setIsSelecting = _useState42[1];
4000
- var _useState43 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)([]),
4164
+ var _useState43 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(false),
4001
4165
  _useState44 = _slicedToArray(_useState43, 2),
4002
- selectedCells = _useState44[0],
4003
- setSelectedCells = _useState44[1];
4004
- var _useState45 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(null),
4166
+ isSelecting = _useState44[0],
4167
+ setIsSelecting = _useState44[1];
4168
+ var _useState45 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)([]),
4005
4169
  _useState46 = _slicedToArray(_useState45, 2),
4006
- startCell = _useState46[0],
4007
- setStartCell = _useState46[1];
4008
- function handleTableMainMouseUp(e) {
4009
- setIsSelecting(false);
4010
- }
4170
+ selectedCells = _useState46[0],
4171
+ setSelectedCells = _useState46[1];
4172
+ var _useState47 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(null),
4173
+ _useState48 = _slicedToArray(_useState47, 2),
4174
+ startCell = _useState48[0],
4175
+ setStartCell = _useState48[1];
4011
4176
 
4012
4177
  // Determine whether it is a selected cell
4013
4178
  var isCellSelected = function isCellSelected(row, col) {
@@ -4021,9 +4186,59 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4021
4186
  });
4022
4187
  };
4023
4188
 
4024
- // Selecting now
4025
- function handleTableMainCellMouseEnter(e, row, col) {
4189
+ // Start selecting
4190
+ var handleTableMainCellMouseDown = function handleTableMainCellMouseDown(e, row, col, colsOffset) {
4191
+ var isMultiSelect = e.ctrlKey || e.metaKey; // Check whether the Ctrl or Command key is pressed
4192
+
4193
+ setIsSelecting(true);
4194
+ setStartCell({
4195
+ row: row,
4196
+ col: col
4197
+ });
4026
4198
  var _el = e.currentTarget;
4199
+ setIsSelecting(true);
4200
+ setStartCell({
4201
+ row: row,
4202
+ col: col
4203
+ });
4204
+ setSelectedCells(function (prevSelectedCells) {
4205
+ if (isMultiSelect) {
4206
+ // Multi-select mode: Add or remove cells
4207
+ //++++++++++
4208
+ var cellExists = prevSelectedCells.some(function (_ref3) {
4209
+ var r = _ref3.row,
4210
+ c = _ref3.col;
4211
+ return r === row && c === col;
4212
+ });
4213
+ if (cellExists) {
4214
+ return prevSelectedCells.filter(function (_ref4) {
4215
+ var r = _ref4.row,
4216
+ c = _ref4.col;
4217
+ return !(r === row && c === col);
4218
+ });
4219
+ } else {
4220
+ return [].concat(_toConsumableArray(prevSelectedCells), [{
4221
+ rowData: JSON.parse(_el.dataset.rowinfo),
4222
+ date: _el.dataset.date,
4223
+ row: row,
4224
+ col: col
4225
+ }]);
4226
+ }
4227
+ } else {
4228
+ // Radio Mode: Clear the previous selection, select only the current cell
4229
+ //++++++++++
4230
+ return [{
4231
+ rowData: JSON.parse(_el.dataset.rowinfo),
4232
+ date: _el.dataset.date,
4233
+ row: row,
4234
+ col: col
4235
+ }];
4236
+ }
4237
+ });
4238
+ };
4239
+
4240
+ // Selecting now
4241
+ var handleTableMainCellMouseEnter = function handleTableMainCellMouseEnter(e, row, col, colsOffset) {
4027
4242
  if (isSelecting && startCell) {
4028
4243
  //########## MODE: WEEK #############
4029
4244
  var curDateList = [];
@@ -4056,10 +4271,10 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4056
4271
  for (var r = minRow; r <= maxRow; r++) {
4057
4272
  for (var c = minCol; c <= maxCol; c++) {
4058
4273
  // query date and row data
4059
- var curRowData = val[r];
4274
+ var curRowData = orginalData[r];
4060
4275
  newSelectedCells.push({
4061
4276
  rowData: curRowData === null || curRowData === void 0 ? void 0 : curRowData.listSection,
4062
- date: curDateList[c],
4277
+ date: curDateList[c - colsOffset],
4063
4278
  row: r,
4064
4279
  col: c
4065
4280
  });
@@ -4067,23 +4282,155 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4067
4282
  }
4068
4283
  setSelectedCells(newSelectedCells);
4069
4284
  }
4070
- }
4285
+ };
4071
4286
 
4072
4287
  // Stop selecting
4073
- function handleTableMainCellMouseDown(e, row, col) {
4074
- var _el = e.currentTarget;
4075
- setIsSelecting(true);
4076
- setStartCell({
4077
- row: row,
4078
- col: col
4079
- });
4080
- setSelectedCells([{
4081
- rowData: JSON.parse(_el.dataset.rowinfo),
4082
- date: _el.dataset.date,
4083
- row: row,
4084
- col: col
4085
- }]);
4086
- }
4288
+ var handleTableMainMouseUp = function handleTableMainMouseUp(e) {
4289
+ setIsSelecting(false);
4290
+ };
4291
+
4292
+ //================================================================
4293
+ // Copy & Paste
4294
+ //================================================================
4295
+ var _useState49 = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(null),
4296
+ _useState50 = _slicedToArray(_useState49, 2),
4297
+ copiedCells = _useState50[0],
4298
+ setCopiedCells = _useState50[1];
4299
+ var handleWrapperKeyDown = function handleWrapperKeyDown(e) {
4300
+ var isMac = funda_utils_dist_cjs_os__WEBPACK_IMPORTED_MODULE_8___default()().isOSX;
4301
+
4302
+ //########## MODE: WEEK #############
4303
+ var curDateList = [];
4304
+ if (appearanceMode === 'week') {
4305
+ curDateList = weekDates.map(function (v) {
4306
+ return (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)(v);
4307
+ });
4308
+ }
4309
+ //########## /MODE: WEEK #############
4310
+
4311
+ //########## MODE: MONTH #############
4312
+ if (appearanceMode === 'month') {
4313
+ curDateList = (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getMonthDates)(year, month + 1);
4314
+ }
4315
+ //########## /MODE: MONTH #############
4316
+
4317
+ // Listen for copy
4318
+ if (isMac && e.metaKey && e.key === 'c' || !isMac && e.ctrlKey && e.key === 'c') {
4319
+ if (selectedCells.length > 0) {
4320
+ // Gets the structure of the selected area
4321
+ var _selectedCellsCoordinates = selectedCells.map(function (_ref5) {
4322
+ var r = _ref5.row,
4323
+ c = _ref5.col;
4324
+ return [r, c];
4325
+ });
4326
+ var _selectedCellsCoordin = _selectedCellsCoordinates.reduce(function (_ref6, _ref7) {
4327
+ var _ref8 = _slicedToArray(_ref6, 2),
4328
+ min = _ref8[0],
4329
+ max = _ref8[1];
4330
+ var _ref9 = _slicedToArray(_ref7, 1),
4331
+ r = _ref9[0];
4332
+ return [Math.min(min, r), Math.max(max, r)];
4333
+ }, [Infinity, -Infinity]),
4334
+ _selectedCellsCoordin2 = _slicedToArray(_selectedCellsCoordin, 2),
4335
+ minRow = _selectedCellsCoordin2[0],
4336
+ maxRow = _selectedCellsCoordin2[1];
4337
+ var _selectedCellsCoordin3 = _selectedCellsCoordinates.reduce(function (_ref10, _ref11) {
4338
+ var _ref12 = _slicedToArray(_ref10, 2),
4339
+ min = _ref12[0],
4340
+ max = _ref12[1];
4341
+ var _ref13 = _slicedToArray(_ref11, 2),
4342
+ _ = _ref13[0],
4343
+ c = _ref13[1];
4344
+ return [Math.min(min, c), Math.max(max, c)];
4345
+ }, [Infinity, -Infinity]),
4346
+ _selectedCellsCoordin4 = _slicedToArray(_selectedCellsCoordin3, 2),
4347
+ minCol = _selectedCellsCoordin4[0],
4348
+ maxCol = _selectedCellsCoordin4[1];
4349
+
4350
+ /*
4351
+ [Be equal to:]
4352
+ // Suppose _selectedCellsCoordinates is an array of selected cells, each of which is in the form of [row, col].
4353
+ let minRow = Infinity;
4354
+ let maxRow = -Infinity;
4355
+ let minCol = Infinity;
4356
+ let maxCol = -Infinity;
4357
+ for (const [row, col] of _selectedCellsCoordinates) {
4358
+ if (row < minRow) minRow = row;
4359
+ if (row > maxRow) maxRow = row;
4360
+ if (col < minCol) minCol = col;
4361
+ if (col > maxCol) maxCol = col;
4362
+ }
4363
+ */
4364
+
4365
+ // Calculate the offset and adjust the cell coordinates
4366
+ var adjustedCells = _selectedCellsCoordinates.map(function (_ref14) {
4367
+ var _ref15 = _slicedToArray(_ref14, 2),
4368
+ r = _ref15[0],
4369
+ c = _ref15[1];
4370
+ return [r - minRow, c - minCol];
4371
+ });
4372
+
4373
+ // The copy result is independent of the data
4374
+ setCopiedCells({
4375
+ structure: {
4376
+ rows: maxRow - minRow + 1,
4377
+ cols: maxCol - minCol + 1
4378
+ },
4379
+ offset: {
4380
+ row: minRow,
4381
+ col: minCol
4382
+ },
4383
+ cells: adjustedCells
4384
+ });
4385
+
4386
+ //
4387
+ onKeyCopy === null || onKeyCopy === void 0 ? void 0 : onKeyCopy(e, selectedCells);
4388
+ }
4389
+ }
4390
+
4391
+ // Listen for paste
4392
+ if (isMac && e.metaKey && e.key === 'v' || !isMac && e.ctrlKey && e.key === 'v') {
4393
+ if (copiedCells && selectedCells.length > 0) {
4394
+ var _getCells = getCells(),
4395
+ rowsTotal = _getCells.rowsTotal,
4396
+ colsTotal = _getCells.colsTotal,
4397
+ forwardFillTotal = _getCells.forwardFillTotal;
4398
+ var _selectedCells$ = selectedCells[0],
4399
+ targetRow = _selectedCells$.row,
4400
+ targetCol = _selectedCells$.col; // the first position
4401
+ var newSelectedCellsCoordinates = copiedCells.cells.map(function (_ref16) {
4402
+ var _ref17 = _slicedToArray(_ref16, 2),
4403
+ r = _ref17[0],
4404
+ c = _ref17[1];
4405
+ return [targetRow + r, targetCol + c];
4406
+ }).filter(function (_ref18) {
4407
+ var _ref19 = _slicedToArray(_ref18, 2),
4408
+ r = _ref19[0],
4409
+ c = _ref19[1];
4410
+ return r < rowsTotal && c < colsTotal;
4411
+ }); // Make sure you don't go beyond the scope of the table
4412
+
4413
+ // query date and row data
4414
+ var newSelectedCells = [];
4415
+ newSelectedCellsCoordinates.forEach(function (item) {
4416
+ var _item = _slicedToArray(item, 2),
4417
+ r = _item[0],
4418
+ c = _item[1];
4419
+ var curRowData = orginalData[r];
4420
+ newSelectedCells.push({
4421
+ rowData: curRowData === null || curRowData === void 0 ? void 0 : curRowData.listSection,
4422
+ date: curDateList[c - forwardFillTotal],
4423
+ row: r,
4424
+ col: c
4425
+ });
4426
+ });
4427
+ setSelectedCells(newSelectedCells);
4428
+
4429
+ //
4430
+ onKeyPaste === null || onKeyPaste === void 0 ? void 0 : onKeyPaste(e, newSelectedCells);
4431
+ }
4432
+ }
4433
+ };
4087
4434
 
4088
4435
  //================================================================
4089
4436
  // Other
@@ -4162,7 +4509,12 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4162
4509
  week: [_daysIndicator[_dayOfWeek] - 1]
4163
4510
  });
4164
4511
  });
4165
- return curWeek;
4512
+ return {
4513
+ rowsTotal: orginalData.length,
4514
+ colsTotal: curWeek.length,
4515
+ forwardFillTotal: 0,
4516
+ list: curWeek
4517
+ };
4166
4518
  }
4167
4519
  //########## /MODE: WEEK #############
4168
4520
 
@@ -4180,9 +4532,9 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4180
4532
 
4181
4533
  // next month
4182
4534
  if (type === 'back') {
4183
- var _date2 = new Date(year, currentMonth + 1, day);
4184
- currentMonth = _date2.getMonth();
4185
- currentStartDay = getStartDayOfMonth(_date2);
4535
+ var _date3 = new Date(year, currentMonth + 1, day);
4536
+ currentMonth = _date3.getMonth();
4537
+ currentStartDay = getStartDayOfMonth(_date3);
4186
4538
  }
4187
4539
 
4188
4540
  //
@@ -4223,75 +4575,91 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4223
4575
  return (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)(v);
4224
4576
  });
4225
4577
  };
4226
- return _tempCells.map(function (_, j) {
4227
- var _col = allDays.slice(j * 7, (j + 1) * 7);
4228
4578
 
4229
- // back fill
4230
- var backFillArr = [];
4231
- for (var k = 0; k < 7 - _col.length; k++) {
4232
- backFillArr.push(null);
4233
- }
4234
- _col.splice.apply(_col, [_col.length, 0].concat(_toConsumableArray(backFillArr)));
4579
+ // The remaining date of the previous month
4580
+ // If the number is 7, the calendar does not include the date of the previous month
4581
+ var remainPrevDate = findMondayAndTruncate(_getForwardFill(year, month + 1));
4582
+ var remainPrevDateTotal = remainPrevDate.length === 7 ? 0 : remainPrevDate.length;
4583
+ return {
4584
+ rowsTotal: orginalData.length,
4585
+ colsTotal: allDays.length,
4586
+ forwardFillTotal: remainPrevDateTotal,
4587
+ list: _tempCells.map(function (_, j) {
4588
+ var _col = allDays.slice(j * 7, (j + 1) * 7);
4589
+
4590
+ // back fill
4591
+ var backFillArr = [];
4592
+ for (var k = 0; k < 7 - _col.length; k++) {
4593
+ backFillArr.push(null);
4594
+ }
4595
+ _col.splice.apply(_col, [_col.length, 0].concat(_toConsumableArray(backFillArr)));
4235
4596
 
4236
- //
4237
- var isFirstGroup = j === 0;
4238
- var isLastGroup = j === _tempCells.length - 1;
4597
+ //
4598
+ var isFirstGroup = j === 0;
4599
+ var isLastGroup = j === _tempCells.length - 1;
4239
4600
 
4240
- // forward fill
4241
- var __forwardFillDate = _getForwardFill(year, month + 1);
4601
+ // forward fill
4602
+ var __forwardFillDate = _getForwardFill(year, month + 1);
4242
4603
 
4243
- // back fill
4244
- var __backFillDate = _getBackFill(year, month + 1);
4245
- var _getDateShow = function _getDateShow(_dayIndex, _m, _startDay, _month) {
4246
- var currentDay = typeof _dayIndex === 'number' ? _dayIndex - (_startDay - 2) : 0; // ..., -3, -2, -1, 0, 1, 2, 3, 4, 5, 6, 7, ...
4604
+ // back fill
4605
+ var __backFillDate = _getBackFill(year, month + 1);
4606
+ var _getDateShow = function _getDateShow(_dayIndex, _m, _startDay, _month) {
4607
+ var currentDay = typeof _dayIndex === 'number' ? _dayIndex - (_startDay - 2) : 0; // ..., -3, -2, -1, 0, 1, 2, 3, 4, 5, 6, 7, ...
4247
4608
 
4248
- // date
4249
- var _dateShow = currentDay > 0 ? "".concat(year, "-").concat(_month + 1, "-").concat(currentDay) : '';
4609
+ // date
4610
+ var _dateShow = currentDay > 0 ? "".concat(year, "-").concat(_month + 1, "-").concat(currentDay) : '';
4250
4611
 
4251
- // forward & back
4252
- if (isFirstGroup && _dateShow === '') {
4253
- _dateShow = __forwardFillDate.at(currentDay - 1);
4254
- }
4255
- if (isLastGroup && _dateShow === '') {
4256
- _dateShow = __backFillDate.at(_m);
4257
- }
4258
- return {
4259
- date: (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)(_dateShow),
4260
- firstGroup: isFirstGroup,
4261
- lastGroup: isLastGroup,
4262
- validDisplayDate: currentDay > 0 && currentDay <= days[month]
4612
+ // forward & back
4613
+ if (isFirstGroup && _dateShow === '') {
4614
+ _dateShow = __forwardFillDate.at(currentDay - 1);
4615
+ }
4616
+ if (isLastGroup && _dateShow === '') {
4617
+ _dateShow = __backFillDate.at(_m);
4618
+ }
4619
+ return {
4620
+ date: (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)(_dateShow),
4621
+ firstGroup: isFirstGroup,
4622
+ lastGroup: isLastGroup,
4623
+ validDisplayDate: currentDay > 0 && currentDay <= days[month]
4624
+ };
4263
4625
  };
4264
- };
4265
4626
 
4266
- //
4267
- return {
4268
- month: currentMonth,
4269
- startDay: currentStartDay,
4270
- row: j,
4271
- col: _col,
4272
- dateInfo: _col.map(function (k, m) {
4273
- var _lastWeekDays = _col.filter(Boolean).length;
4274
- return _getDateShow(k, m - _lastWeekDays, currentStartDay, currentMonth);
4275
- }),
4276
- weekDisplay: _col.map(function (k, m) {
4277
- return WEEK[m];
4278
- }),
4279
- week: _col.map(function (k, m) {
4280
- return m;
4281
- })
4282
- };
4283
- });
4627
+ //
4628
+ return {
4629
+ month: currentMonth,
4630
+ startDay: currentStartDay,
4631
+ row: j,
4632
+ col: _col,
4633
+ dateInfo: _col.map(function (k, m) {
4634
+ var _lastWeekDays = _col.filter(Boolean).length;
4635
+ return _getDateShow(k, m - _lastWeekDays, currentStartDay, currentMonth);
4636
+ }),
4637
+ weekDisplay: _col.map(function (k, m) {
4638
+ return WEEK[m];
4639
+ }),
4640
+ week: _col.map(function (k, m) {
4641
+ return m;
4642
+ })
4643
+ };
4644
+ })
4645
+ };
4284
4646
  }
4285
4647
  //########## /MODE: MONTH #############
4286
4648
 
4287
- return [];
4649
+ return {
4650
+ rowsTotal: 0,
4651
+ colsTotal: 0,
4652
+ forwardFillTotal: 0,
4653
+ list: []
4654
+ };
4288
4655
  };
4289
4656
  var queryItemObj = function queryItemObj() {
4290
- var curRowData = val[tableRowNum];
4657
+ var curRowData = orginalData[tableRowNum];
4658
+ var curDate = tempDate !== '' ? tempDate : "".concat(year, "-").concat(month + 1, "-").concat(day);
4291
4659
  if (curRowData) {
4292
4660
  var eventSourcesData = curRowData.eventSources;
4293
4661
  var _rowData = eventSourcesData.filter(function (item) {
4294
- return (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)(item.date) === (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)("".concat(year, "-").concat(month + 1, "-").concat(day));
4662
+ return (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)(item.date) === (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)(curDate);
4295
4663
  });
4296
4664
  var _currentData = undefined;
4297
4665
  if (_rowData[0]) {
@@ -4301,7 +4669,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4301
4669
  _currentData = {
4302
4670
  rowData: curRowData.listSection,
4303
4671
  id: 0,
4304
- date: (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)("".concat(year, "-").concat(month + 1, "-").concat(day))
4672
+ date: (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)(curDate)
4305
4673
  };
4306
4674
  } else {
4307
4675
  // edit or delete
@@ -4313,7 +4681,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4313
4681
  return _rowData[0] ? _currentData : {
4314
4682
  rowData: curRowData.listSection,
4315
4683
  id: 0,
4316
- date: (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)("".concat(year, "-").concat(month + 1, "-").concat(day))
4684
+ date: (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)(curDate)
4317
4685
  };
4318
4686
  }
4319
4687
  };
@@ -4386,7 +4754,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4386
4754
  }
4387
4755
 
4388
4756
  // Determine whether it exceeds the far right or left side of the screen
4389
- var _modalContent = _tableTooltipModalRef.querySelector('.e-cal-timeline-table__cell-tooltipcontent');
4757
+ var _modalContent = _tableTooltipModalRef.querySelector('.custom-event-tl-table__cell-tooltipcontent');
4390
4758
  var _modalBox = _modalContent.getBoundingClientRect();
4391
4759
  if (typeof _modalContent.dataset.offset === 'undefined' && _modalBox.left > 0) {
4392
4760
  // 10 pixels is used to account for some bias in mobile devices
@@ -4582,7 +4950,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4582
4950
  // ================================================================
4583
4951
 
4584
4952
  function generateListSectionUi() {
4585
- return val.map(function (item, i) {
4953
+ return orginalData.map(function (item, i) {
4586
4954
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("tr", {
4587
4955
  key: i,
4588
4956
  role: "row",
@@ -4590,9 +4958,9 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4590
4958
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("td", {
4591
4959
  role: "gridcell",
4592
4960
  "data-resource-index": i,
4593
- className: "e-cal-timeline-table__datagrid-cell"
4961
+ className: "custom-event-tl-table__datagrid-cell"
4594
4962
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
4595
- className: "e-cal-timeline-table__cell-cushion e-cal-timeline-table__cell-cushion-title",
4963
+ className: "custom-event-tl-table__cell-cushion custom-event-tl-table__cell-cushion-title",
4596
4964
  dangerouslySetInnerHTML: {
4597
4965
  __html: item.listSection.title
4598
4966
  }
@@ -4606,7 +4974,10 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4606
4974
  var showEvents = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;
4607
4975
  // colIndex
4608
4976
  var colIndex = 0;
4609
- return getCells().map(function (item, j) {
4977
+ var _getCells2 = getCells(),
4978
+ forwardFillTotal = _getCells2.forwardFillTotal,
4979
+ cellsList = _getCells2.list;
4980
+ return cellsList.map(function (item, j) {
4610
4981
  return item.col.map(function (dayIndex, i) {
4611
4982
  colIndex++;
4612
4983
 
@@ -4627,7 +4998,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4627
4998
  var _currentData = eventSourcesData.filter(function (item) {
4628
4999
  return (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.getCalendarDate)(item.date) === _dateShow;
4629
5000
  });
4630
- var isLastCol = colIndex === 7 * getCells().length;
5001
+ var isLastCol = colIndex === 7 * cellsList.length;
4631
5002
  var isInteractive = item.dateInfo[i].validDisplayDate; // The date on which the user interaction can occur, e.g. click, modify
4632
5003
  var isForward = item.dateInfo[i].firstGroup && !isInteractive;
4633
5004
  var isBack = item.dateInfo[i].lastGroup && !isInteractive;
@@ -4637,7 +5008,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4637
5008
  if (!showEvents) {
4638
5009
  var _thContent = function _thContent() {
4639
5010
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("th", {
4640
- className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('e-cal-timeline-table__cell-cushion-headercontent__container', {
5011
+ className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('custom-event-tl-table__cell-cushion-headercontent__container', {
4641
5012
  'empty': !isInteractive,
4642
5013
  'today': d === now.getDate(),
4643
5014
  'selected': d === day,
@@ -4668,6 +5039,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4668
5039
 
4669
5040
  // reset selection area
4670
5041
  setSelectedCells([]);
5042
+ setCopiedCells(null);
4671
5043
 
4672
5044
  //
4673
5045
  if (isInteractive) {
@@ -4686,6 +5058,9 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4686
5058
  } : _currentData[0], function () {
4687
5059
  return setShowEdit(true);
4688
5060
  }, 'normal');
5061
+
5062
+ // set temporary date
5063
+ setTempDate(_dateShow);
4689
5064
  }
4690
5065
  }
4691
5066
  },
@@ -4696,7 +5071,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4696
5071
  onCellMouseUp === null || onCellMouseUp === void 0 ? void 0 : onCellMouseUp(e, selectedCells);
4697
5072
  }
4698
5073
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
4699
- className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('e-cal-timeline-table__cell-cushion e-cal-timeline-table__cell-cushion-headercontent', {
5074
+ className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('custom-event-tl-table__cell-cushion custom-event-tl-table__cell-cushion-headercontent', {
4700
5075
  'disabled': !isInteractive
4701
5076
  }),
4702
5077
  style: {
@@ -4723,18 +5098,18 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4723
5098
  var _items = _currentData[0].list;
4724
5099
  return _items.map(function (cellItem, cellItemIndex) {
4725
5100
  var _eventContentTooltip = typeof cellItem.dataTooltip === 'undefined' ? '' : /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
4726
- className: "e-cal-timeline__day__event-tooltipcontent",
5101
+ className: "custom-event-tl__day__event-tooltipcontent",
4727
5102
  dangerouslySetInnerHTML: {
4728
5103
  __html: cellItem.dataTooltip
4729
5104
  }
4730
5105
  }));
4731
5106
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
4732
- className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)("e-cal-timeline-table__cell-cushion-content__item e-cal-timeline-table__cell-cushion-content__item-".concat(cellItemIndex), {
5107
+ className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)("custom-event-tl-table__cell-cushion-content__item custom-event-tl-table__cell-cushion-content__item-".concat(cellItemIndex), {
4733
5108
  'first': cellItemIndex === 0,
4734
5109
  'last': cellItemIndex === _items.length - 1
4735
5110
  }),
4736
5111
  key: "cell-item-".concat(rowIndex, "-").concat(cellItemIndex, "}"),
4737
- "data-overlay-id": "e-cal-timeline-table__cell-tooltipwrapper-".concat(idRes),
5112
+ "data-overlay-id": "custom-event-tl-table__cell-tooltipwrapper-".concat(idRes),
4738
5113
  "data-cell-item-index": cellItemIndex,
4739
5114
  "data-date": _dateShow,
4740
5115
  "data-day": _dateDayShow,
@@ -4779,17 +5154,20 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4779
5154
  onModalEditOpen === null || onModalEditOpen === void 0 ? void 0 : onModalEditOpen(cellItem, function () {
4780
5155
  return setShowEdit(true);
4781
5156
  }, 'normal');
5157
+
5158
+ // set temporary date
5159
+ setTempDate(_dateShow);
4782
5160
  }
4783
5161
  }
4784
5162
  }
4785
5163
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
4786
- className: "e-cal-timeline__day__event",
5164
+ className: "custom-event-tl__day__event",
4787
5165
  style: typeof cellItem !== 'undefined' && cellItem.eventStyles !== 'undefined' ? cellItem.eventStyles : {},
4788
5166
  dangerouslySetInnerHTML: typeof cellItem.data === 'string' ? {
4789
5167
  __html: cellItem.data
4790
5168
  } : undefined
4791
5169
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().isValidElement(cellItem.data) ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, cellItem.data) : null), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
4792
- className: "e-cal-timeline__day__eventdel ".concat(cellCloseBtnClassName || '')
5170
+ className: "custom-event-tl__day__eventdel ".concat(cellCloseBtnClassName || '')
4793
5171
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("a", {
4794
5172
  href: "#",
4795
5173
  tabIndex: -1,
@@ -4825,6 +5203,9 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4825
5203
  onModalDeleteOpen === null || onModalDeleteOpen === void 0 ? void 0 : onModalDeleteOpen(_existsContent, function () {
4826
5204
  return setShowDelete(true);
4827
5205
  });
5206
+
5207
+ // set temporary date
5208
+ setTempDate(_dateShow);
4828
5209
  }
4829
5210
  }
4830
5211
  }
@@ -4832,9 +5213,9 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4832
5213
  });
4833
5214
  };
4834
5215
  var _tdContent = function _tdContent() {
4835
- var _val$rowIndex;
5216
+ var _orginalData$rowIndex;
4836
5217
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("td", {
4837
- className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('e-cal-timeline-table__cell-cushion-content__container e-cal-timeline-table__cell-tooltiptrigger', {
5218
+ className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('custom-event-tl-table__cell-cushion-content__container custom-event-tl-table__cell-tooltiptrigger', {
4838
5219
  'has-event': eventSourcesData && _currentData.length > 0,
4839
5220
  'empty': !isInteractive,
4840
5221
  'today': d === now.getDate(),
@@ -4844,7 +5225,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4844
5225
  key: "col" + i,
4845
5226
  "data-index": colIndex - 1,
4846
5227
  colSpan: 1,
4847
- "data-rowinfo": JSON.stringify((_val$rowIndex = val[rowIndex]) === null || _val$rowIndex === void 0 ? void 0 : _val$rowIndex.listSection),
5228
+ "data-rowinfo": JSON.stringify((_orginalData$rowIndex = orginalData[rowIndex]) === null || _orginalData$rowIndex === void 0 ? void 0 : _orginalData$rowIndex.listSection),
4848
5229
  "data-date": _dateShow,
4849
5230
  "data-day": _dateDayShow,
4850
5231
  "data-week": weekDay,
@@ -4853,13 +5234,13 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4853
5234
  onCellMouseEnter === null || onCellMouseEnter === void 0 ? void 0 : onCellMouseEnter(e);
4854
5235
 
4855
5236
  //
4856
- if (multipleCells) handleTableMainCellMouseEnter(e, rowIndex, dayIndex);
5237
+ if (multipleCells) handleTableMainCellMouseEnter(e, rowIndex, dayIndex, forwardFillTotal);
4857
5238
  },
4858
5239
  onMouseDown: function onMouseDown(e) {
4859
- var _val$rowIndex2;
5240
+ var _orginalData$rowIndex2;
4860
5241
  //
4861
5242
  onCellClick === null || onCellClick === void 0 ? void 0 : onCellClick(e, {
4862
- rowData: (_val$rowIndex2 = val[rowIndex]) === null || _val$rowIndex2 === void 0 ? void 0 : _val$rowIndex2.listSection,
5243
+ rowData: (_orginalData$rowIndex2 = orginalData[rowIndex]) === null || _orginalData$rowIndex2 === void 0 ? void 0 : _orginalData$rowIndex2.listSection,
4863
5244
  date: _dateShow,
4864
5245
  row: rowIndex,
4865
5246
  col: dayIndex
@@ -4868,7 +5249,17 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4868
5249
  handleDayChange(e, d); // update current day
4869
5250
  onChangeDate === null || onChangeDate === void 0 ? void 0 : onChangeDate(e, null);
4870
5251
  }
4871
- if (multipleCells) handleTableMainCellMouseDown(e, rowIndex, dayIndex);
5252
+ if (multipleCells) handleTableMainCellMouseDown(e, rowIndex, dayIndex, forwardFillTotal);
5253
+ },
5254
+ onDoubleClick: function onDoubleClick(e) {
5255
+ var _orginalData$rowIndex3;
5256
+ //
5257
+ onCellDoubleClick === null || onCellDoubleClick === void 0 ? void 0 : onCellDoubleClick(e, {
5258
+ rowData: (_orginalData$rowIndex3 = orginalData[rowIndex]) === null || _orginalData$rowIndex3 === void 0 ? void 0 : _orginalData$rowIndex3.listSection,
5259
+ date: _dateShow,
5260
+ row: rowIndex,
5261
+ col: dayIndex
5262
+ });
4872
5263
  },
4873
5264
  onMouseLeave: function onMouseLeave(e) {
4874
5265
  onCellMouseLeave === null || onCellMouseLeave === void 0 ? void 0 : onCellMouseLeave(e);
@@ -4877,7 +5268,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4877
5268
  onCellMouseUp === null || onCellMouseUp === void 0 ? void 0 : onCellMouseUp(e, selectedCells);
4878
5269
  }
4879
5270
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
4880
- className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('e-cal-timeline-table__cell-cushion e-cal-timeline-table__cell-cushion-content', {
5271
+ className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('custom-event-tl-table__cell-cushion custom-event-tl-table__cell-cushion-content', {
4881
5272
  'disabled': !isInteractive
4882
5273
  }),
4883
5274
  style: {
@@ -4888,7 +5279,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4888
5279
  userSelect: 'none'
4889
5280
  }
4890
5281
  }, "\xA0")), isForward || isBack ? null : /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
4891
- className: "e-cal-timeline__day__eventadd ".concat(cellAddBtnClassName || '')
5282
+ className: "custom-event-tl__day__eventadd ".concat(cellAddBtnClassName || '')
4892
5283
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("a", {
4893
5284
  href: "#",
4894
5285
  tabIndex: -1,
@@ -4924,6 +5315,9 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4924
5315
  }, function () {
4925
5316
  return setShowEdit(true);
4926
5317
  }, 'new');
5318
+
5319
+ // set temporary date
5320
+ setTempDate(_dateShow);
4927
5321
  }
4928
5322
  }
4929
5323
  }
@@ -4973,7 +5367,10 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
4973
5367
  } else {
4974
5368
  // colIndex
4975
5369
  var colIndex = 0;
4976
- return getCells().map(function (item, j) {
5370
+ var _getCells3 = getCells(),
5371
+ forwardFillTotal = _getCells3.forwardFillTotal,
5372
+ cellsList = _getCells3.list;
5373
+ return cellsList.map(function (item, j) {
4977
5374
  return item.col.map(function (dayIndex, i) {
4978
5375
  colIndex++;
4979
5376
 
@@ -5028,8 +5425,8 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5028
5425
  var tableGridEl = tableGridRef.current;
5029
5426
 
5030
5427
  // initialize cell height
5031
- var headerTitleTrElements = tableGridEl.querySelector('.e-cal-timeline-table__datagrid-body__title tbody').getElementsByTagName('tr');
5032
- var trElements = tableGridEl.querySelector('.e-cal-timeline-table__datagrid-body__content tbody').getElementsByTagName('tr');
5428
+ var headerTitleTrElements = tableGridEl.querySelector('.custom-event-tl-table__datagrid-body__title tbody').getElementsByTagName('tr');
5429
+ var trElements = tableGridEl.querySelector('.custom-event-tl-table__datagrid-body__content tbody').getElementsByTagName('tr');
5033
5430
  for (var i = 0; i < headerTitleTrElements.length; i++) {
5034
5431
  var targetElement = headerTitleTrElements[i].offsetHeight > trElements[i].offsetHeight ? headerTitleTrElements[i] : trElements[i];
5035
5432
  var tdOHeight = window.getComputedStyle(targetElement).height;
@@ -5040,9 +5437,12 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5040
5437
  function tableGridInit() {
5041
5438
  //
5042
5439
  if (tableGridRef.current === null) return;
5440
+ var _getCells4 = getCells(),
5441
+ forwardFillTotal = _getCells4.forwardFillTotal,
5442
+ cellsList = _getCells4.list;
5043
5443
  var tableGridEl = tableGridRef.current;
5044
5444
  var _curCellMinWidth = CELL_MIN_W;
5045
- var _curColCount = FILL_BLANK_DATE_DISABLD ? days[month] : 7 * getCells().length;
5445
+ var _curColCount = FILL_BLANK_DATE_DISABLD ? days[month] : 7 * cellsList.length;
5046
5446
  if (appearanceMode === 'week') {
5047
5447
  _curColCount = 7;
5048
5448
  }
@@ -5054,15 +5454,15 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5054
5454
  //--------------
5055
5455
  if (appearanceMode === 'week') {
5056
5456
  var tableMaxWidth = tableGridEl.clientWidth;
5057
- var tableHeaderTitleWidth = tableGridEl.querySelector('.e-cal-timeline-table__cell-cushion-headertitle').clientWidth;
5058
- var tableDividerWidth = tableGridEl.querySelector('.e-cal-timeline-table__timeline-divider').clientWidth;
5457
+ var tableHeaderTitleWidth = tableGridEl.querySelector('.custom-event-tl-table__cell-cushion-headertitle').clientWidth;
5458
+ var tableDividerWidth = tableGridEl.querySelector('.custom-event-tl-table__timeline-divider').clientWidth;
5059
5459
  var tableBorderWidth = 4;
5060
5460
  var scrollMaxWidth = tableMaxWidth - tableHeaderTitleWidth - tableDividerWidth - tableBorderWidth;
5061
5461
  _curCellMinWidth = scrollMaxWidth / 7;
5062
5462
  _curColCount = 7;
5063
5463
 
5064
5464
  // header
5065
- tableGridEl.querySelectorAll('.e-cal-timeline-table__cell-cushion-headercontent__container, .e-cal-timeline-table__cell-cushion-content').forEach(function (node) {
5465
+ tableGridEl.querySelectorAll('.custom-event-tl-table__cell-cushion-headercontent__container, .custom-event-tl-table__cell-cushion-content').forEach(function (node) {
5066
5466
  node.style.width = _curCellMinWidth + 'px';
5067
5467
  });
5068
5468
  }
@@ -5081,17 +5481,17 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5081
5481
  //****************
5082
5482
  // initialize "header & main" cells
5083
5483
  //--------------
5084
- var headerThContentContainers = tableGridEl.querySelector('.e-cal-timeline-table__datagrid-header__content tbody').getElementsByTagName('th');
5484
+ var headerThContentContainers = tableGridEl.querySelector('.custom-event-tl-table__datagrid-header__content tbody').getElementsByTagName('th');
5085
5485
  for (var i = 0; i < headerThContentContainers.length; i++) {
5086
- var curHeaderThContent = headerThContentContainers[i].querySelector('.e-cal-timeline-table__cell-cushion-headercontent');
5486
+ var curHeaderThContent = headerThContentContainers[i].querySelector('.custom-event-tl-table__cell-cushion-headercontent');
5087
5487
  if (curHeaderThContent !== null) curHeaderThContent.style.width = _curCellMinWidth + 'px';
5088
5488
  }
5089
- var mainTdContentContainers = tableGridEl.querySelector('.e-cal-timeline-table__datagrid-body__content tbody').getElementsByTagName('td');
5489
+ var mainTdContentContainers = tableGridEl.querySelector('.custom-event-tl-table__datagrid-body__content tbody').getElementsByTagName('td');
5090
5490
  for (var _i2 = 0; _i2 < mainTdContentContainers.length; _i2++) {
5091
- var _curHeaderThContent = mainTdContentContainers[_i2].querySelector('.e-cal-timeline-table__cell-cushion-content');
5491
+ var _curHeaderThContent = mainTdContentContainers[_i2].querySelector('.custom-event-tl-table__cell-cushion-content');
5092
5492
  if (_curHeaderThContent !== null) _curHeaderThContent.style.width = _curCellMinWidth + 'px';
5093
5493
  }
5094
- var mainTdContentCols = tableGridEl.querySelector('.e-cal-timeline-table__datagrid-body__content colgroup').getElementsByTagName('col');
5494
+ var mainTdContentCols = tableGridEl.querySelector('.custom-event-tl-table__datagrid-body__content colgroup').getElementsByTagName('col');
5095
5495
  for (var _i3 = 0; _i3 < mainTdContentCols.length; _i3++) {
5096
5496
  mainTdContentCols[_i3].style.minWidth = _curCellMinWidth + 'px';
5097
5497
  }
@@ -5101,20 +5501,20 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5101
5501
  //****************
5102
5502
  // initialize scrollable wrapper (width)
5103
5503
  //--------------
5104
- var _scrollableWrapper = tableGridEl.querySelectorAll('.e-cal-timeline-table__scroller-harness');
5504
+ var _scrollableWrapper = tableGridEl.querySelectorAll('.custom-event-tl-table__scroller-harness');
5105
5505
  [].slice.call(_scrollableWrapper).forEach(function (el) {
5106
5506
  var scrollType = el.dataset.scroll;
5107
5507
  if (appearanceMode === 'week') {
5108
- el.classList.add('e-cal-timeline-table__scroller-harness--hideX');
5508
+ el.classList.add('custom-event-tl-table__scroller-harness--hideX');
5109
5509
  }
5110
5510
  if (appearanceMode === 'month') {
5111
- el.classList.remove('e-cal-timeline-table__scroller-harness--hideX');
5511
+ el.classList.remove('custom-event-tl-table__scroller-harness--hideX');
5112
5512
  }
5113
5513
  if (scrollType !== 'list') {
5114
- var _content = el.querySelector('.e-cal-timeline-table__scroller');
5514
+ var _content = el.querySelector('.custom-event-tl-table__scroller');
5115
5515
  var _tableMaxWidth = tableGridEl.clientWidth;
5116
- var _tableHeaderTitleWidth = tableGridEl.querySelector('.e-cal-timeline-table__cell-cushion-headertitle').clientWidth;
5117
- var _tableDividerWidth = tableGridEl.querySelector('.e-cal-timeline-table__timeline-divider').clientWidth;
5516
+ var _tableHeaderTitleWidth = tableGridEl.querySelector('.custom-event-tl-table__cell-cushion-headertitle').clientWidth;
5517
+ var _tableDividerWidth = tableGridEl.querySelector('.custom-event-tl-table__timeline-divider').clientWidth;
5118
5518
  var _tableBorderWidth = 4;
5119
5519
  var _scrollMaxWidth = _tableMaxWidth - _tableHeaderTitleWidth - _tableDividerWidth - _tableBorderWidth;
5120
5520
  el.dataset.width = _scrollMaxWidth;
@@ -5128,10 +5528,10 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5128
5528
  //****************
5129
5529
  // initialize cell width
5130
5530
  //--------------
5131
- var tdElementMaxWidth = typeof mainTdContentContainers[0] === 'undefined' ? 0 : parseFloat(window.getComputedStyle(mainTdContentContainers[0].querySelector('.e-cal-timeline-table__cell-cushion-content')).maxWidth);
5531
+ var tdElementMaxWidth = typeof mainTdContentContainers[0] === 'undefined' ? 0 : parseFloat(window.getComputedStyle(mainTdContentContainers[0].querySelector('.custom-event-tl-table__cell-cushion-content')).maxWidth);
5132
5532
  if (Array.isArray(eventsValue) && eventsValue.length > 0) {
5133
5533
  for (var _i4 = 0; _i4 < headerThContentContainers.length; _i4++) {
5134
- var _curHeaderThContent2 = headerThContentContainers[_i4].querySelector('.e-cal-timeline-table__cell-cushion-headercontent');
5534
+ var _curHeaderThContent2 = headerThContentContainers[_i4].querySelector('.custom-event-tl-table__cell-cushion-headercontent');
5135
5535
  var curHeaderThContentMaxWidth = parseFloat(window.getComputedStyle(_curHeaderThContent2).width);
5136
5536
  var targetElement = headerThContentContainers[_i4].offsetWidth > mainTdContentContainers[_i4].offsetWidth ? headerThContentContainers[_i4] : mainTdContentContainers[_i4];
5137
5537
  var tdOwidth = parseFloat(window.getComputedStyle(targetElement).width);
@@ -5148,7 +5548,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5148
5548
 
5149
5549
  // Prevent the width from being +1 each time it is initialized
5150
5550
  tdOwidth = tdOwidth - 1;
5151
- headerThContentContainers[_i4].querySelector('.e-cal-timeline-table__cell-cushion-headercontent').style.width = tdOwidth + 'px';
5551
+ headerThContentContainers[_i4].querySelector('.custom-event-tl-table__cell-cushion-headercontent').style.width = tdOwidth + 'px';
5152
5552
  mainTdContentCols[_i4].style.minWidth = tdOwidth + 'px';
5153
5553
  }
5154
5554
  }
@@ -5159,7 +5559,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5159
5559
  // initialize max width of table content
5160
5560
  //--------------
5161
5561
  if (scrollBodyRef.current !== null && scrollHeaderRef.current !== null) {
5162
- var tableContentWidth = window.getComputedStyle(tableGridEl.querySelector('.e-cal-timeline-table__datagrid-body__content')).width;
5562
+ var tableContentWidth = window.getComputedStyle(tableGridEl.querySelector('.custom-event-tl-table__datagrid-body__content')).width;
5163
5563
  var scrollBodyEl = scrollBodyRef.current;
5164
5564
  var scrollHeaderEl = scrollHeaderRef.current;
5165
5565
  scrollBodyEl.style.width = tableContentWidth;
@@ -5170,7 +5570,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5170
5570
  //
5171
5571
  var tableWrapperMaxWidthLatest = tableGridEl.clientWidth;
5172
5572
  if (tableWrapperMaxWidthLatest > parseFloat(tableContentWidth)) {
5173
- tableGridEl.querySelector('.e-cal-timeline-table__timeline-table').style.width = tableContentWidth;
5573
+ tableGridEl.querySelector('.custom-event-tl-table__timeline-table').style.width = tableContentWidth;
5174
5574
  }
5175
5575
  }
5176
5576
 
@@ -5211,20 +5611,20 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5211
5611
  //--------------
5212
5612
  if (appearanceMode === 'week') {
5213
5613
  var _tableMaxWidth2 = tableGridEl.clientWidth;
5214
- var _tableHeaderTitleWidth2 = tableGridEl.querySelector('.e-cal-timeline-table__cell-cushion-headertitle').clientWidth;
5215
- var _tableDividerWidth2 = tableGridEl.querySelector('.e-cal-timeline-table__timeline-divider').clientWidth;
5614
+ var _tableHeaderTitleWidth2 = tableGridEl.querySelector('.custom-event-tl-table__cell-cushion-headertitle').clientWidth;
5615
+ var _tableDividerWidth2 = tableGridEl.querySelector('.custom-event-tl-table__timeline-divider').clientWidth;
5216
5616
  var _tableBorderWidth2 = 4;
5217
5617
  var _scrollMaxWidth2 = _tableMaxWidth2 - _tableHeaderTitleWidth2 - _tableDividerWidth2 - _tableBorderWidth2;
5218
5618
  _curCellMinWidth = _scrollMaxWidth2 / 7;
5219
5619
  _curColCount = 7;
5220
5620
 
5221
5621
  // header content
5222
- tableGridEl.querySelectorAll('.e-cal-timeline-table__cell-cushion-headercontent__container, .e-cal-timeline-table__cell-cushion-headercontent').forEach(function (node) {
5622
+ tableGridEl.querySelectorAll('.custom-event-tl-table__cell-cushion-headercontent__container, .custom-event-tl-table__cell-cushion-headercontent').forEach(function (node) {
5223
5623
  node.style.width = _curCellMinWidth + 'px';
5224
5624
  });
5225
5625
 
5226
5626
  // main content
5227
- tableGridEl.querySelectorAll('.e-cal-timeline-table__cell-cushion-content').forEach(function (node) {
5627
+ tableGridEl.querySelectorAll('.custom-event-tl-table__cell-cushion-content').forEach(function (node) {
5228
5628
  node.style.width = _curCellMinWidth + 'px';
5229
5629
  });
5230
5630
  }
@@ -5235,9 +5635,9 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5235
5635
 
5236
5636
  // initialize scrollable wrapper (width & height)
5237
5637
  //--------------
5238
- var _scrollableWrapper = tableGridEl.querySelectorAll('.e-cal-timeline-table__scroller-harness');
5638
+ var _scrollableWrapper = tableGridEl.querySelectorAll('.custom-event-tl-table__scroller-harness');
5239
5639
  [].slice.call(_scrollableWrapper).forEach(function (el) {
5240
- var _content = el.querySelector('.e-cal-timeline-table__scroller');
5640
+ var _content = el.querySelector('.custom-event-tl-table__scroller');
5241
5641
  el.removeAttribute('data-width');
5242
5642
  el.removeAttribute('style');
5243
5643
  _content.removeAttribute('style');
@@ -5245,8 +5645,8 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5245
5645
 
5246
5646
  // initialize cell height
5247
5647
  //--------------
5248
- var headerTitleTrElements = tableGridEl.querySelector('.e-cal-timeline-table__datagrid-body__title tbody').getElementsByTagName('tr');
5249
- var trElements = tableGridEl.querySelector('.e-cal-timeline-table__datagrid-body__content tbody').getElementsByTagName('tr');
5648
+ var headerTitleTrElements = tableGridEl.querySelector('.custom-event-tl-table__datagrid-body__title tbody').getElementsByTagName('tr');
5649
+ var trElements = tableGridEl.querySelector('.custom-event-tl-table__datagrid-body__content tbody').getElementsByTagName('tr');
5250
5650
  for (var i = 0; i < headerTitleTrElements.length; i++) {
5251
5651
  headerTitleTrElements[i].removeAttribute('style');
5252
5652
  trElements[i].removeAttribute('style');
@@ -5276,15 +5676,18 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5276
5676
  });
5277
5677
  }, [year]);
5278
5678
  (0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {
5679
+ var _getCells5 = getCells(),
5680
+ forwardFillTotal = _getCells5.forwardFillTotal,
5681
+ cellsList = _getCells5.list;
5279
5682
  if (typeof appearanceWeekTmpl === 'function') {
5280
- setDisplayWeekForHeader([getCells().at(0).dateInfo[0].date, getCells().at(-1).dateInfo[0].date]);
5683
+ setDisplayWeekForHeader([cellsList.at(0).dateInfo[0].date, cellsList.at(-1).dateInfo[0].date]);
5281
5684
  } else {
5282
- setDisplayWeekForHeader([formatToEnglishMonthDay(getCells().at(0).dateInfo[0].date), formatToEnglishMonthDay(getCells().at(-1).dateInfo[0].date)]);
5685
+ setDisplayWeekForHeader([formatToEnglishMonthDay(cellsList.at(0).dateInfo[0].date), formatToEnglishMonthDay(cellsList.at(-1).dateInfo[0].date)]);
5283
5686
  }
5284
5687
  }, [weekOffset]);
5285
5688
  (0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {
5286
5689
  // update events value
5287
- if (Array.isArray(eventsValue) && eventsValue.length > 0) setVal(eventsValue);
5690
+ if (Array.isArray(eventsValue) && eventsValue.length > 0) setOrginalData(eventsValue);
5288
5691
 
5289
5692
  // update current today
5290
5693
  if (typeof customTodayDate !== 'undefined' && (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.isValidDate)(customTodayDate)) {
@@ -5294,19 +5697,26 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5294
5697
 
5295
5698
  // Call a function when the list has been rendered completely
5296
5699
  onListRenderComplete === null || onListRenderComplete === void 0 ? void 0 : onListRenderComplete();
5700
+ }, [eventsValue, customTodayDate, appearanceMode]);
5701
+ (0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {
5702
+ // !!!Please do not use dependencies
5297
5703
  return function () {
5298
5704
  // reset table grid
5299
5705
  tableGridReset();
5706
+
5707
+ // reset selection area
5708
+ setSelectedCells([]);
5709
+ setCopiedCells(null);
5300
5710
  };
5301
- }, [eventsValue, customTodayDate, appearanceMode]);
5711
+ }, []);
5302
5712
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5303
- className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)("e-cal-timeline__wrapper e-cal-timeline__wrapper--".concat(appearanceMode), calendarWrapperClassName)
5713
+ className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)("custom-event-tl__wrapper custom-event-tl__wrapper--".concat(appearanceMode), calendarWrapperClassName)
5304
5714
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5305
- className: "e-cal-timeline__header bg-body-tertiary"
5715
+ className: "custom-event-tl__header bg-body-tertiary"
5306
5716
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
5307
5717
  tabIndex: -1,
5308
5718
  type: "button",
5309
- className: "e-cal-timeline__btn e-cal-timeline__btn--prev",
5719
+ className: "custom-event-tl__btn custom-event-tl__btn--prev",
5310
5720
  onClick: handlePrevChange
5311
5721
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("svg", {
5312
5722
  width: "20px",
@@ -5317,13 +5727,13 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5317
5727
  d: "M14.2893 5.70708C13.8988 5.31655 13.2657 5.31655 12.8751 5.70708L7.98768 10.5993C7.20729 11.3805 7.2076 12.6463 7.98837 13.427L12.8787 18.3174C13.2693 18.7079 13.9024 18.7079 14.293 18.3174C14.6835 17.9269 14.6835 17.2937 14.293 16.9032L10.1073 12.7175C9.71678 12.327 9.71678 11.6939 10.1073 11.3033L14.2893 7.12129C14.6799 6.73077 14.6799 6.0976 14.2893 5.70708Z",
5318
5728
  fill: "#000"
5319
5729
  }))), appearanceMode === 'week' ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5320
- className: "e-cal-timeline__header__info"
5730
+ className: "custom-event-tl__header__info"
5321
5731
  }, typeof appearanceWeekTmpl === 'function' ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, appearanceWeekTmpl(displayWeekForHeader[0], displayWeekForHeader[1])) : /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, displayWeekForHeader[0], " - ", displayWeekForHeader[1]))) : null, appearanceMode === 'month' ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5322
- className: "e-cal-timeline__header__btns"
5732
+ className: "custom-event-tl__header__btns"
5323
5733
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
5324
5734
  tabIndex: -1,
5325
5735
  type: "button",
5326
- className: "e-cal-timeline__btn ".concat(winMonth ? 'active' : ''),
5736
+ className: "custom-event-tl__btn ".concat(winMonth ? 'active' : ''),
5327
5737
  onClick: handleShowWinMonth
5328
5738
  }, MONTHS[month], /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("svg", {
5329
5739
  width: "12px",
@@ -5335,7 +5745,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5335
5745
  }))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
5336
5746
  tabIndex: -1,
5337
5747
  type: "button",
5338
- className: "e-cal-timeline__btn ".concat(winYear ? 'active' : ''),
5748
+ className: "custom-event-tl__btn ".concat(winYear ? 'active' : ''),
5339
5749
  onClick: handleShowWinYear
5340
5750
  }, year, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("svg", {
5341
5751
  width: "12px",
@@ -5347,7 +5757,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5347
5757
  }))))) : null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
5348
5758
  tabIndex: -1,
5349
5759
  type: "button",
5350
- className: "e-cal-timeline__btn e-cal-timeline__btn--next",
5760
+ className: "custom-event-tl__btn custom-event-tl__btn--next",
5351
5761
  onClick: handleNextChange
5352
5762
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("svg", {
5353
5763
  width: "20px",
@@ -5358,66 +5768,69 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5358
5768
  d: "M9.71069 18.2929C10.1012 18.6834 10.7344 18.6834 11.1249 18.2929L16.0123 13.4006C16.7927 12.6195 16.7924 11.3537 16.0117 10.5729L11.1213 5.68254C10.7308 5.29202 10.0976 5.29202 9.70708 5.68254C9.31655 6.07307 9.31655 6.70623 9.70708 7.09676L13.8927 11.2824C14.2833 11.6729 14.2833 12.3061 13.8927 12.6966L9.71069 16.8787C9.32016 17.2692 9.32016 17.9023 9.71069 18.2929Z",
5359
5769
  fill: "#000"
5360
5770
  })))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5361
- className: "e-cal-timeline__body"
5771
+ className: "custom-event-tl__body"
5362
5772
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5363
- className: "e-cal-timeline__row"
5773
+ className: "custom-event-tl__row"
5364
5774
  })), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5365
- className: "e-cal-timeline__month-wrapper shadow p-3 mb-5 bg-body-tertiary rounded ".concat(winMonth ? 'active' : '')
5775
+ className: "custom-event-tl__month-wrapper shadow p-3 mb-5 bg-body-tertiary rounded ".concat(winMonth ? 'active' : '')
5366
5776
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5367
- className: "e-cal-timeline__month-container"
5777
+ className: "custom-event-tl__month-container"
5368
5778
  }, MONTHS_FULL.map(function (month, index) {
5369
5779
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5370
5780
  "data-month": (0,funda_utils_dist_cjs_date__WEBPACK_IMPORTED_MODULE_6__.padZero)(index + 1),
5371
- className: "e-cal-timeline__month ".concat(selectedMonth === index ? ' selected' : ''),
5781
+ className: "custom-event-tl__month ".concat(selectedMonth === index ? ' selected' : ''),
5372
5782
  key: month + index,
5373
5783
  onClick: function onClick() {
5374
5784
  handleMonthChange(index);
5375
5785
  }
5376
5786
  }, month);
5377
5787
  }))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5378
- className: "e-cal-timeline__year-wrapper shadow p-3 mb-5 bg-body-tertiary rounded ".concat(winYear ? 'active' : '')
5788
+ className: "custom-event-tl__year-wrapper shadow p-3 mb-5 bg-body-tertiary rounded ".concat(winYear ? 'active' : '')
5379
5789
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5380
- className: "e-cal-timeline__year-container bg-body-tertiary"
5790
+ className: "custom-event-tl__year-container bg-body-tertiary"
5381
5791
  }, yearsArray.map(function (year, index) {
5382
5792
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5383
5793
  "data-year": year,
5384
- className: "e-cal-timeline__year ".concat(selectedYear === year ? ' selected' : ''),
5794
+ className: "custom-event-tl__year ".concat(selectedYear === year ? ' selected' : ''),
5385
5795
  key: year + index,
5386
5796
  onClick: function onClick() {
5387
5797
  handleYearChange(year);
5388
5798
  }
5389
5799
  }, year);
5390
5800
  }))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5391
- className: "e-cal-timeline__today-wrapper p-2"
5801
+ className: "custom-event-tl__today-wrapper p-2"
5392
5802
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
5393
5803
  tabIndex: -1,
5394
5804
  type: "button",
5395
- className: "e-cal-timeline__btn e-cal-timeline__btn--today",
5805
+ className: "custom-event-tl__btn custom-event-tl__btn--today",
5396
5806
  onClick: handleTodayChange
5397
5807
  }, langToday || 'Today'), appearanceToggle ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
5398
5808
  tabIndex: -1,
5399
5809
  type: "button",
5400
- className: "e-cal-timeline__btn e-cal-timeline__btn--appearance ".concat(appearanceMode === 'month' ? 'active' : ''),
5810
+ className: "custom-event-tl__btn custom-event-tl__btn--appearance ".concat(appearanceMode === 'month' ? 'active' : ''),
5401
5811
  "data-mode": "month",
5402
5812
  onClick: handleAppearanceChange
5403
5813
  }, langAppearanceLabelMonth || 'Month'), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
5404
5814
  tabIndex: -1,
5405
5815
  type: "button",
5406
- className: "e-cal-timeline__btn e-cal-timeline__btn--appearance ".concat(appearanceMode === 'week' ? 'active' : ''),
5816
+ className: "custom-event-tl__btn custom-event-tl__btn--appearance ".concat(appearanceMode === 'week' ? 'active' : ''),
5407
5817
  "data-mode": "week",
5408
5818
  onClick: handleAppearanceChange
5409
- }, langAppearanceLabelWeek || 'Week')) : null)), val.length === 0 ? null : /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5819
+ }, langAppearanceLabelWeek || 'Week')) : null)), orginalData.length === 0 ? null : /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5410
5820
  ref: tableGridRef,
5411
- className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)("e-cal-timeline-table__timeline-table__wrapper e-cal-timeline-table__timeline-table__wrapper--".concat(appearanceMode, " invisible"), tableWrapperClassName),
5821
+ className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)("custom-event-tl-table__timeline-table__wrapper custom-event-tl-table__timeline-table__wrapper--".concat(appearanceMode, " invisible"), tableWrapperClassName),
5412
5822
  onKeyDown: function onKeyDown(e) {
5413
5823
  onKeyPressed === null || onKeyPressed === void 0 ? void 0 : onKeyPressed(e, selectedCells);
5824
+
5825
+ // Copy & Paste
5826
+ handleWrapperKeyDown(e);
5414
5827
  },
5415
5828
  tabIndex: -1 // require "tabIndex" attribute
5416
5829
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("table", {
5417
5830
  role: "grid",
5418
- className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)("e-cal-timeline-table__timeline-table", tableClassName)
5831
+ className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)("custom-event-tl-table__timeline-table", tableClassName)
5419
5832
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("colgroup", null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("col", {
5420
- className: "e-cal-timeline-table__datagrid-header"
5833
+ className: "custom-event-tl-table__datagrid-header"
5421
5834
  }), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("col", null), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("col", null)), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("thead", {
5422
5835
  className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)(tableHeadClassName),
5423
5836
  ref: tableGridHeaderRef,
@@ -5427,10 +5840,10 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5427
5840
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("th", {
5428
5841
  role: "presentation"
5429
5842
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5430
- className: "e-cal-timeline-table__timeline-header e-cal-timeline-table__timeline-headertitle"
5843
+ className: "custom-event-tl-table__timeline-header custom-event-tl-table__timeline-headertitle"
5431
5844
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("table", {
5432
5845
  role: "presentation",
5433
- className: "e-cal-timeline-table__datagrid-header__title"
5846
+ className: "custom-event-tl-table__datagrid-header__title"
5434
5847
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("colgroup", null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("col", null)), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("thead", {
5435
5848
  role: "presentation"
5436
5849
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("tr", {
@@ -5438,55 +5851,55 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5438
5851
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("th", {
5439
5852
  role: "columnheader"
5440
5853
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5441
- className: "e-cal-timeline-table__cell-cushion e-cal-timeline-table__cell-cushion-headertitle"
5854
+ className: "custom-event-tl-table__cell-cushion custom-event-tl-table__cell-cushion-headertitle"
5442
5855
  }, tableListSectionTitle || ''))))))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("th", {
5443
5856
  role: "presentation",
5444
- className: "e-cal-timeline-table__timeline-divider"
5857
+ className: "custom-event-tl-table__timeline-divider"
5445
5858
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", null)), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("th", {
5446
5859
  role: "presentation"
5447
5860
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5448
5861
  ref: scrollHeaderRef,
5449
- className: "e-cal-timeline-table__scroller-harness e-cal-timeline-table__scroller-harness--hide",
5862
+ className: "custom-event-tl-table__scroller-harness custom-event-tl-table__scroller-harness--hide",
5450
5863
  "data-scroll": "header",
5451
5864
  onScroll: syncTableScrollHeader
5452
5865
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5453
- className: "e-cal-timeline-table__scroller"
5866
+ className: "custom-event-tl-table__scroller"
5454
5867
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5455
- className: "e-cal-timeline-table__timeline-header"
5868
+ className: "custom-event-tl-table__timeline-header"
5456
5869
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("table", {
5457
- className: "e-cal-timeline-table__datagrid-header__content e-cal-timeline-table__scrollgrid-sync-table"
5870
+ className: "custom-event-tl-table__datagrid-header__content custom-event-tl-table__scrollgrid-sync-table"
5458
5871
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("tbody", null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("tr", null, generateDaysUi()))))))))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("tbody", {
5459
5872
  className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)(tableBodyClassName),
5460
5873
  role: "rowgroup"
5461
5874
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("tr", {
5462
5875
  role: "presentation",
5463
- className: "e-cal-timeline-table__list-section"
5876
+ className: "custom-event-tl-table__list-section"
5464
5877
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("td", {
5465
5878
  role: "presentation",
5466
5879
  className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)(tableListStartClassName)
5467
5880
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5468
5881
  ref: scrollListRef,
5469
- className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('e-cal-timeline-table__scroller-harness', {
5882
+ className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('custom-event-tl-table__scroller-harness', {
5470
5883
  'autoscroll': AUTO_SCROLL
5471
5884
  }),
5472
5885
  "data-scroll": "list",
5473
5886
  onScroll: syncTableScrollList
5474
5887
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5475
- className: "e-cal-timeline-table__scroller"
5888
+ className: "custom-event-tl-table__scroller"
5476
5889
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("table", {
5477
5890
  role: "presentation",
5478
- className: "e-cal-timeline-table__datagrid-body__title e-cal-timeline-table__scrollgrid-sync-table"
5891
+ className: "custom-event-tl-table__datagrid-body__title custom-event-tl-table__scrollgrid-sync-table"
5479
5892
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("colgroup", null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("col", null)), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("tbody", {
5480
5893
  role: "presentation"
5481
5894
  }, generateListSectionUi()))))), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("td", {
5482
5895
  role: "presentation",
5483
- className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('e-cal-timeline-table__timeline-divider', tableListDividerClassName)
5896
+ className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('custom-event-tl-table__timeline-divider', tableListDividerClassName)
5484
5897
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", null)), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("td", {
5485
5898
  role: "presentation",
5486
5899
  className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)(tableListEndClassName)
5487
5900
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5488
5901
  ref: scrollBodyRef,
5489
- className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('e-cal-timeline-table__scroller-harness', {
5902
+ className: (0,funda_utils_dist_cjs_cls__WEBPACK_IMPORTED_MODULE_7__.combinedCls)('custom-event-tl-table__scroller-harness', {
5490
5903
  'autoscroll': AUTO_SCROLL
5491
5904
  }),
5492
5905
  "data-scroll": "body",
@@ -5496,15 +5909,15 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5496
5909
  onMouseUp: BODY_DRAG ? handleTableDragEnd : function () {},
5497
5910
  onMouseLeave: BODY_DRAG ? handleTableDragEnd : function () {}
5498
5911
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5499
- className: "e-cal-timeline-table__scroller"
5912
+ className: "custom-event-tl-table__scroller"
5500
5913
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5501
- className: "e-cal-timeline-table__timeline-body"
5914
+ className: "custom-event-tl-table__timeline-body"
5502
5915
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("table", {
5503
- className: "e-cal-timeline-table__datagrid-body__content e-cal-timeline-table__scrollgrid-sync-table"
5916
+ className: "custom-event-tl-table__datagrid-body__content custom-event-tl-table__scrollgrid-sync-table"
5504
5917
  /* Drag to activate the selection area */,
5505
5918
  onMouseLeave: multipleCells ? handleTableMainMouseUp : undefined,
5506
5919
  onMouseUp: multipleCells ? handleTableMainMouseUp : undefined
5507
- }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("colgroup", null, generateColUi()), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("tbody", null, val.map(function (item, i) {
5920
+ }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("colgroup", null, generateColUi()), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("tbody", null, orginalData.map(function (item, i) {
5508
5921
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("tr", {
5509
5922
  key: i
5510
5923
  }, generateDaysUi(item.eventSources, item.listSection, i, true));
@@ -5521,10 +5934,12 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5521
5934
  setTimeout(function () {
5522
5935
  setShowDelete(false);
5523
5936
  onModalDeleteClose === null || onModalDeleteClose === void 0 ? void 0 : onModalDeleteClose(queryItemObj());
5937
+ // set temporary date
5938
+ setTempDate('');
5524
5939
  }, 350);
5525
5940
  },
5526
5941
  onSubmit: /*#__PURE__*/function () {
5527
- var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(e, closewin, data) {
5942
+ var _ref20 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(e, closewin, data) {
5528
5943
  return _regeneratorRuntime().wrap(function _callee$(_context) {
5529
5944
  while (1) switch (_context.prev = _context.next) {
5530
5945
  case 0:
@@ -5541,7 +5956,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5541
5956
  }, _callee);
5542
5957
  }));
5543
5958
  return function (_x2, _x3, _x4) {
5544
- return _ref3.apply(this, arguments);
5959
+ return _ref20.apply(this, arguments);
5545
5960
  };
5546
5961
  }()
5547
5962
  }, modalDeleteContent || 'Are you sure?'), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((funda_modaldialog__WEBPACK_IMPORTED_MODULE_2___default()), {
@@ -5560,10 +5975,12 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5560
5975
  setTimeout(function () {
5561
5976
  setShowEdit(false);
5562
5977
  onModalEditClose === null || onModalEditClose === void 0 ? void 0 : onModalEditClose(queryItemObj());
5978
+ // set temporary date
5979
+ setTempDate('');
5563
5980
  }, 350);
5564
5981
  },
5565
5982
  onSubmit: /*#__PURE__*/function () {
5566
- var _ref4 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(e, closewin, data) {
5983
+ var _ref21 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(e, closewin, data) {
5567
5984
  return _regeneratorRuntime().wrap(function _callee2$(_context2) {
5568
5985
  while (1) switch (_context2.prev = _context2.next) {
5569
5986
  case 0:
@@ -5580,7 +5997,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5580
5997
  }, _callee2);
5581
5998
  }));
5582
5999
  return function (_x5, _x6, _x7) {
5583
- return _ref4.apply(this, arguments);
6000
+ return _ref21.apply(this, arguments);
5584
6001
  };
5585
6002
  }()
5586
6003
  }, modalContent)) : null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((funda_root_portal__WEBPACK_IMPORTED_MODULE_1___default()), {
@@ -5588,8 +6005,8 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5588
6005
  containerClassName: "EventCalendarTimeline-TooltipModal"
5589
6006
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5590
6007
  ref: tableTooltipModalRef,
5591
- id: "e-cal-timeline-table__cell-tooltipwrapper-".concat(idRes),
5592
- className: "e-cal-timeline-table__cell-tooltipwrapper d-inline-block ".concat(isShowTableTooltip ? 'active' : ''),
6008
+ id: "custom-event-tl-table__cell-tooltipwrapper-".concat(idRes),
6009
+ className: "custom-event-tl-table__cell-tooltipwrapper d-inline-block ".concat(isShowTableTooltip ? 'active' : ''),
5593
6010
  role: "tooltip",
5594
6011
  "data-microtip-position": tableTooltipDirection || 'bottom',
5595
6012
  "data-microtip-size": tableTooltipSize || 'auto',
@@ -5597,7 +6014,7 @@ var EventCalendarTimeline = function EventCalendarTimeline(props) {
5597
6014
  display: 'none'
5598
6015
  }
5599
6016
  }, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
5600
- className: "e-cal-timeline-table__cell-tooltipcontent"
6017
+ className: "custom-event-tl-table__cell-tooltipcontent"
5601
6018
  }, tableTooltipContent))));
5602
6019
  };
5603
6020
  /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (EventCalendarTimeline);