@linzjs/step-ag-grid 7.3.1 → 7.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -2012,6 +2012,7 @@ var GridContext = React.createContext({
2012
2012
  }); },
2013
2013
  ensureRowVisible: function () {
2014
2014
  console.error("no context provider for ensureRowVisible");
2015
+ return true;
2015
2016
  },
2016
2017
  ensureSelectedRowIsVisible: function () {
2017
2018
  console.error("no context provider for ensureSelectedRowIsVisible");
@@ -2227,9 +2228,12 @@ var GridContextProvider = function (props) {
2227
2228
  return gridApiOp(function (gridApi) { return isNotEmpty(gridApi.getEditingCells()); }, function () { return false; });
2228
2229
  };
2229
2230
  var ensureRowVisible = function (id) {
2230
- gridApiOp(function (gridApi) {
2231
+ return gridApiOp(function (gridApi) {
2231
2232
  var node = gridApi.getRowNode("".concat(id));
2232
- node && gridApi.ensureNodeVisible(node);
2233
+ if (!node)
2234
+ return false;
2235
+ gridApi.ensureNodeVisible(node);
2236
+ return true;
2233
2237
  });
2234
2238
  };
2235
2239
  /**
@@ -4267,7 +4271,7 @@ var GridFormTextArea = function (props) {
4267
4271
  invalid: invalid,
4268
4272
  save: save
4269
4273
  }).popoverWrapper;
4270
- return popoverWrapper(jsxRuntime.jsx("div", __assign({ style: { display: "flex", flexDirection: "row", width: (_b = props.width) !== null && _b !== void 0 ? _b : 240 } }, { children: jsxRuntime.jsx(TextAreaInput, { value: value, onChange: function (e) { return setValue(e.target.value); }, error: invalid(), placeholder: props.placeholder, helpText: helpText }) })));
4274
+ return popoverWrapper(jsxRuntime.jsx("div", __assign({ className: "subComponent", style: { display: "flex", flexDirection: "row", width: (_b = props.width) !== null && _b !== void 0 ? _b : 240 } }, { children: jsxRuntime.jsx(TextAreaInput, { value: value, onChange: function (e) { return setValue(e.target.value); }, error: invalid(), placeholder: props.placeholder, helpText: helpText }) })));
4271
4275
  };
4272
4276
 
4273
4277
  var GridPopoverTextArea = function (colDef, params) { return GridCell(colDef, __assign({ editor: GridFormTextArea }, params)); };
@@ -4304,7 +4308,7 @@ var GridFormTextInput = function (props) {
4304
4308
  invalid: invalid,
4305
4309
  save: save
4306
4310
  }).popoverWrapper;
4307
- return popoverWrapper(jsxRuntime.jsx("div", __assign({ style: { display: "flex", flexDirection: "row", width: (_b = props.width) !== null && _b !== void 0 ? _b : 240 }, className: "FormTest" }, { children: jsxRuntime.jsx(TextInputFormatted, { value: value, onChange: function (e) { return setValue(e.target.value); }, error: invalid(), formatted: props.units, style: { width: "100%" }, placeholder: props.placeholder, helpText: helpText }) })));
4311
+ return popoverWrapper(jsxRuntime.jsx("div", __assign({ style: { display: "flex", flexDirection: "row", width: (_b = props.width) !== null && _b !== void 0 ? _b : 240 }, className: "FormTest subComponent" }, { children: jsxRuntime.jsx(TextInputFormatted, { value: value, onChange: function (e) { return setValue(e.target.value); }, error: invalid(), formatted: props.units, style: { width: "100%" }, placeholder: props.placeholder, helpText: helpText }) })));
4308
4312
  };
4309
4313
 
4310
4314
  var GridPopoverTextInput = function (colDef, params) {
@@ -24371,6 +24375,11 @@ var findQuick = function (filter, container) { return __awaiter(void 0, void 0,
24371
24375
  });
24372
24376
  }); };
24373
24377
 
24378
+ var countRows = function (within) { return __awaiter(void 0, void 0, void 0, function () {
24379
+ return __generator(this, function (_a) {
24380
+ return [2 /*return*/, getAllQuick({ tagName: "div[row-id]:not(:empty)" }, within).length];
24381
+ });
24382
+ }); };
24374
24383
  var findRow = function (rowId, within) { return __awaiter(void 0, void 0, void 0, function () {
24375
24384
  return __generator(this, function (_a) {
24376
24385
  return [2 /*return*/, findQuick({ tagName: "div[row-id='".concat(rowId, "']:not(:empty)") }, within)];
@@ -24423,7 +24432,7 @@ var findCell = function (rowId, colId, within) { return __awaiter(void 0, void 0
24423
24432
  }
24424
24433
  });
24425
24434
  }); };
24426
- var cellContains = function (rowId, colId, text, within) { return __awaiter(void 0, void 0, void 0, function () {
24435
+ var findCellContains = function (rowId, colId, text, within) { return __awaiter(void 0, void 0, void 0, function () {
24427
24436
  return __generator(this, function (_a) {
24428
24437
  switch (_a.label) {
24429
24438
  case 0: return [4 /*yield*/, waitForWrapper(function () { return __awaiter(void 0, void 0, void 0, function () {
@@ -24437,7 +24446,7 @@ var cellContains = function (rowId, colId, text, within) { return __awaiter(void
24437
24446
  case 2: return [2 /*return*/, _a.sent()];
24438
24447
  }
24439
24448
  });
24440
- }); })];
24449
+ }); }, { timeout: 10000 })];
24441
24450
  case 1: return [2 /*return*/, _a.sent()];
24442
24451
  }
24443
24452
  });
@@ -24614,6 +24623,7 @@ var typeOtherInput = function (value) { return __awaiter(void 0, void 0, void 0,
24614
24623
  return [4 /*yield*/, findQuick({ classes: ".subComponent", child: { tagName: "input[type='text']" } }, openMenu)];
24615
24624
  case 2:
24616
24625
  otherInput = _a.sent();
24626
+ userEvent.clear(otherInput);
24617
24627
  userEvent.type(otherInput, value);
24618
24628
  return [2 /*return*/];
24619
24629
  }
@@ -24629,6 +24639,7 @@ var typeOtherTextArea = function (value) { return __awaiter(void 0, void 0, void
24629
24639
  return [4 /*yield*/, findQuick({ classes: ".subComponent", child: { tagName: "textarea" } }, openMenu)];
24630
24640
  case 2:
24631
24641
  otherTextArea = _a.sent();
24642
+ userEvent.clear(otherTextArea);
24632
24643
  userEvent.type(otherTextArea, value);
24633
24644
  return [2 /*return*/];
24634
24645
  }
@@ -24715,16 +24726,17 @@ exports.bearingCorrectionValueFormatter = bearingCorrectionValueFormatter;
24715
24726
  exports.bearingNumberParser = bearingNumberParser;
24716
24727
  exports.bearingStringValidator = bearingStringValidator;
24717
24728
  exports.bearingValueFormatter = bearingValueFormatter;
24718
- exports.cellContains = cellContains;
24719
24729
  exports.clickActionButton = clickActionButton;
24720
24730
  exports.clickMenuOption = clickMenuOption;
24721
24731
  exports.clickMultiSelectOption = clickMultiSelectOption;
24722
24732
  exports.closeMenu = closeMenu;
24723
24733
  exports.convertDDToDMS = convertDDToDMS;
24734
+ exports.countRows = countRows;
24724
24735
  exports.deselectRow = deselectRow;
24725
24736
  exports.editCell = editCell;
24726
24737
  exports.findActionButton = findActionButton;
24727
24738
  exports.findCell = findCell;
24739
+ exports.findCellContains = findCellContains;
24728
24740
  exports.findMenuOption = findMenuOption;
24729
24741
  exports.findMultiSelectOption = findMultiSelectOption;
24730
24742
  exports.findRow = findRow;