handsontable 0.0.0-next-4b40c99-20241108 → 0.0.0-next-e035192-20241108

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of handsontable might be problematic. Click here for more details.

package/focusManager.js CHANGED
@@ -163,12 +163,11 @@ class FocusManager {
163
163
  * @returns {HTMLTextAreaElement|HTMLElement|undefined}
164
164
  */
165
165
  getRefocusElement() {
166
+ var _classPrivateFieldGet2;
166
167
  if (typeof _classPrivateFieldGet(_refocusElementGetter, this) === 'function') {
167
168
  return _classPrivateFieldGet(_refocusElementGetter, this).call(this);
168
- } else {
169
- var _classPrivateFieldGet2;
170
- return (_classPrivateFieldGet2 = _classPrivateFieldGet(_hot, this).getActiveEditor()) === null || _classPrivateFieldGet2 === void 0 ? void 0 : _classPrivateFieldGet2.TEXTAREA;
171
169
  }
170
+ return (_classPrivateFieldGet2 = _classPrivateFieldGet(_hot, this).getActiveEditor()) === null || _classPrivateFieldGet2 === void 0 ? void 0 : _classPrivateFieldGet2.TEXTAREA;
172
171
  }
173
172
 
174
173
  /**
@@ -209,13 +208,12 @@ class FocusManager {
209
208
  refocusToEditorTextarea() {
210
209
  var _classPrivateFieldGet5;
211
210
  let delay = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : _classPrivateFieldGet(_refocusDelay, this);
212
- const refocusElement = this.getRefocusElement();
213
-
214
211
  // Re-focus on the editor's `TEXTAREA` element (or a predefined element) if the `imeFastEdit` option is enabled.
215
- if (_classPrivateFieldGet(_hot, this).getSettings().imeFastEdit && !((_classPrivateFieldGet5 = _classPrivateFieldGet(_hot, this).getActiveEditor()) !== null && _classPrivateFieldGet5 !== void 0 && _classPrivateFieldGet5.isOpened()) && !!refocusElement) {
212
+ if (_classPrivateFieldGet(_hot, this).getSettings().imeFastEdit && !((_classPrivateFieldGet5 = _classPrivateFieldGet(_hot, this).getActiveEditor()) !== null && _classPrivateFieldGet5 !== void 0 && _classPrivateFieldGet5.isOpened())) {
216
213
  if (!_classPrivateFieldGet(_debouncedSelect, this).has(delay)) {
217
214
  _classPrivateFieldGet(_debouncedSelect, this).set(delay, (0, _function.debounce)(() => {
218
- refocusElement.select();
215
+ var _this$getRefocusEleme;
216
+ (_this$getRefocusEleme = this.getRefocusElement()) === null || _this$getRefocusEleme === void 0 || _this$getRefocusEleme.select();
219
217
  }, delay));
220
218
  }
221
219
  _classPrivateFieldGet(_debouncedSelect, this).get(delay)();
package/focusManager.mjs CHANGED
@@ -160,12 +160,11 @@ export class FocusManager {
160
160
  * @returns {HTMLTextAreaElement|HTMLElement|undefined}
161
161
  */
162
162
  getRefocusElement() {
163
+ var _classPrivateFieldGet2;
163
164
  if (typeof _classPrivateFieldGet(_refocusElementGetter, this) === 'function') {
164
165
  return _classPrivateFieldGet(_refocusElementGetter, this).call(this);
165
- } else {
166
- var _classPrivateFieldGet2;
167
- return (_classPrivateFieldGet2 = _classPrivateFieldGet(_hot, this).getActiveEditor()) === null || _classPrivateFieldGet2 === void 0 ? void 0 : _classPrivateFieldGet2.TEXTAREA;
168
166
  }
167
+ return (_classPrivateFieldGet2 = _classPrivateFieldGet(_hot, this).getActiveEditor()) === null || _classPrivateFieldGet2 === void 0 ? void 0 : _classPrivateFieldGet2.TEXTAREA;
169
168
  }
170
169
 
171
170
  /**
@@ -206,13 +205,12 @@ export class FocusManager {
206
205
  refocusToEditorTextarea() {
207
206
  var _classPrivateFieldGet5;
208
207
  let delay = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : _classPrivateFieldGet(_refocusDelay, this);
209
- const refocusElement = this.getRefocusElement();
210
-
211
208
  // Re-focus on the editor's `TEXTAREA` element (or a predefined element) if the `imeFastEdit` option is enabled.
212
- if (_classPrivateFieldGet(_hot, this).getSettings().imeFastEdit && !((_classPrivateFieldGet5 = _classPrivateFieldGet(_hot, this).getActiveEditor()) !== null && _classPrivateFieldGet5 !== void 0 && _classPrivateFieldGet5.isOpened()) && !!refocusElement) {
209
+ if (_classPrivateFieldGet(_hot, this).getSettings().imeFastEdit && !((_classPrivateFieldGet5 = _classPrivateFieldGet(_hot, this).getActiveEditor()) !== null && _classPrivateFieldGet5 !== void 0 && _classPrivateFieldGet5.isOpened())) {
213
210
  if (!_classPrivateFieldGet(_debouncedSelect, this).has(delay)) {
214
211
  _classPrivateFieldGet(_debouncedSelect, this).set(delay, debounce(() => {
215
- refocusElement.select();
212
+ var _this$getRefocusEleme;
213
+ (_this$getRefocusEleme = this.getRefocusElement()) === null || _this$getRefocusEleme === void 0 || _this$getRefocusEleme.select();
216
214
  }, delay));
217
215
  }
218
216
  _classPrivateFieldGet(_debouncedSelect, this).get(delay)();
package/helpers/mixed.js CHANGED
@@ -134,7 +134,7 @@ const domMessages = {
134
134
  function _injectProductInfo(key, element) {
135
135
  const hasValidType = !isEmpty(key);
136
136
  const isNonCommercial = typeof key === 'string' && key.toLowerCase() === 'non-commercial-and-evaluation';
137
- const hotVersion = "0.0.0-next-4b40c99-20241108";
137
+ const hotVersion = "0.0.0-next-e035192-20241108";
138
138
  let keyValidityDate;
139
139
  let consoleMessageState = 'invalid';
140
140
  let domMessageState = 'invalid';
package/helpers/mixed.mjs CHANGED
@@ -124,7 +124,7 @@ const domMessages = {
124
124
  export function _injectProductInfo(key, element) {
125
125
  const hasValidType = !isEmpty(key);
126
126
  const isNonCommercial = typeof key === 'string' && key.toLowerCase() === 'non-commercial-and-evaluation';
127
- const hotVersion = "0.0.0-next-4b40c99-20241108";
127
+ const hotVersion = "0.0.0-next-e035192-20241108";
128
128
  let keyValidityDate;
129
129
  let consoleMessageState = 'invalid';
130
130
  let domMessageState = 'invalid';
package/package.json CHANGED
@@ -10,7 +10,7 @@
10
10
  "url": "https://github.com/handsontable/handsontable/issues"
11
11
  },
12
12
  "author": "Handsoncode <hello@handsontable.com>",
13
- "version": "0.0.0-next-4b40c99-20241108",
13
+ "version": "0.0.0-next-e035192-20241108",
14
14
  "main": "index",
15
15
  "module": "index.mjs",
16
16
  "jsnext:main": "index.mjs",
@@ -49,7 +49,8 @@ export interface SubmenuItemConfig extends Omit<MenuItemConfig, "key"> {
49
49
 
50
50
  export interface DetailedSettings {
51
51
  callback?: (key: string, selection: Selection[], clickEvent: MouseEvent) => void;
52
- items: PredefinedMenuItemKey[] | MenuConfig;
52
+ uiContainer?: HTMLElement,
53
+ items?: PredefinedMenuItemKey[] | MenuConfig;
53
54
  }
54
55
 
55
56
  export type Settings = boolean | PredefinedMenuItemKey[] | DetailedSettings;
@@ -9,6 +9,7 @@ export interface DetailedSettings {
9
9
  copyColumnHeaders?: boolean;
10
10
  copyColumnGroupHeaders?: boolean;
11
11
  copyColumnHeadersOnly?: boolean;
12
+ uiContainer?: HTMLElement;
12
13
  }
13
14
 
14
15
  export type Settings = boolean | DetailedSettings;
@@ -8,7 +8,8 @@ export interface SeparatorObject {
8
8
 
9
9
  export interface DetailedSettings {
10
10
  callback?: (key: string, selection: Selection[], clickEvent: MouseEvent) => void;
11
- items: PredefinedMenuItemKey[] | MenuConfig;
11
+ uiContainer?: HTMLElement,
12
+ items?: PredefinedMenuItemKey[] | MenuConfig;
12
13
  }
13
14
 
14
15
  export type Settings = boolean | PredefinedMenuItemKey[] | DetailedSettings;