igniteui-angular 21.2.11 → 21.2.12

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.
@@ -15556,7 +15556,7 @@ class IgxPivotDateDimension {
15556
15556
  memberFunction: (rec) => {
15557
15557
  const recordValue = PivotUtil.extractValueFromDimension(inBaseDimension, rec);
15558
15558
  const dateValue = recordValue ? getDateFormatter().createDateFromValue(recordValue) : null;
15559
- return recordValue ? getDateFormatter().formatDateTime(dateValue, undefined, { month: 'long' }) : rec['Months'];
15559
+ return recordValue ? getDateFormatter().formatDateTime(dateValue, this.locale, { month: 'long' }) : rec['Months'];
15560
15560
  },
15561
15561
  enabled: true,
15562
15562
  childLevel: baseDimension
@@ -22037,6 +22037,7 @@ const HEADER_KEYS = new Set([...Array.from(NAVIGATION_KEYS), 'escape', 'esc', 'l
22037
22037
  /** This symbol corresponds to the Alt + L combination under MAC. */
22038
22038
  '¬']);
22039
22039
 
22040
+ const VERTICAL_VIRTUALIZATION_NAV_KEYS = new Set(['arrowup', 'up', 'arrowdown', 'down', 'home', 'end']);
22040
22041
  /** @hidden */
22041
22042
  class IgxGridNavigationService {
22042
22043
  get activeNode() {
@@ -22099,8 +22100,7 @@ class IgxGridNavigationService {
22099
22100
  this.grid.selectionService.keyboardStateOnKeydown(this.activeNode, shift, shift && key === 'tab');
22100
22101
  }
22101
22102
  const position = this.getNextPosition(this.activeNode.row, this.activeNode.column, key, shift, ctrl, event);
22102
- const shouldNotifyVirtualizedKeyboardSelection = ctrl && (key === 'arrowup' || key === 'up' || key === 'arrowdown' || key === 'down') &&
22103
- this.shouldPerformVerticalScroll(position.rowIndex, position.colIndex);
22103
+ const shouldNotifyVirtualizedKeyboardSelection = this.shouldNotifyVirtualizedKeyboardSelection(key, position.rowIndex, position.colIndex);
22104
22104
  if (NAVIGATION_KEYS.has(key)) {
22105
22105
  event.preventDefault();
22106
22106
  this.navigateInBody(position.rowIndex, position.colIndex, (obj) => {
@@ -22216,6 +22216,15 @@ class IgxGridNavigationService {
22216
22216
  return !targetRow || targetRow.offsetTop < Math.abs(this.containerTopOffset)
22217
22217
  || containerHeight && endTopOffset - containerHeight > 5;
22218
22218
  }
22219
+ shouldNotifyVirtualizedKeyboardSelection(key, rowIndex, visibleColIndex) {
22220
+ // Any navigation key that ends up scrolling activates the target cell from the
22221
+ // virtualization scroll callback, which runs outside Angular's knowledge, so the
22222
+ // grid must be notified explicitly regardless of the ctrl modifier.
22223
+ const shouldCheckVerticalScroll = VERTICAL_VIRTUALIZATION_NAV_KEYS.has(key);
22224
+ const shouldCheckHorizontalScroll = HORIZONTAL_NAV_KEYS.has(key);
22225
+ return (shouldCheckVerticalScroll && this.shouldPerformVerticalScroll(rowIndex, visibleColIndex)) ||
22226
+ (shouldCheckHorizontalScroll && this.shouldPerformHorizontalScroll(visibleColIndex, rowIndex));
22227
+ }
22219
22228
  performVerticalScrollToCell(rowIndex, visibleColIndex = -1, cb) {
22220
22229
  if (!this.shouldPerformVerticalScroll(rowIndex, visibleColIndex)) {
22221
22230
  if (cb) {