canvas-datagrid 0.4.4 → 0.4.5

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.
@@ -1839,10 +1839,10 @@ __webpack_require__.r(__webpack_exports__);
1839
1839
 
1840
1840
  /* harmony default export */ function __WEBPACK_DEFAULT_EXPORT__(self) {
1841
1841
  self.defaults = {
1842
- attributes: [['allowColumnReordering', true], ['allowColumnResize', true], ['allowColumnResizeFromCell', false], ['allowFreezingRows', false], ['allowFreezingColumns', false], ['allowMovingSelection', true], ['allowRowHeaderResize', true], ['allowRowReordering', false], ['allowRowResize', true], ['allowRowResizeFromCell', false], ['allowSorting', true], ['allowGroupingRows', true], ['allowGroupingColumns', true], ['animationDurationShowContextMenu', 50], ['animationDurationHideContextMenu', 50], ['autoGenerateSchema', false], ['autoResizeColumns', false], ['autoResizeRows', false], ['autoScrollOnMousemove', false], ['autoScrollMargin', 5], ['blanksText', '(Blanks)'], ['borderDragBehavior', 'none'], ['borderResizeZone', 10], ['clearSettingsOptionText', 'Clear saved settings'], ['columnHeaderClickBehavior', 'sort'], ['columnSelectorHiddenText', '   '], ['columnSelectorText', 'Add/Remove columns'], ['columnSelectorVisibleText', "\u2713"], ['contextHoverScrollAmount', 2], ['contextHoverScrollRateMs', 5], ['copyHeadersOnSelectAll', true], ['copyText', 'Copy'], ['debug', false], ['editable', true], ['ellipsisText', '...'], ['filterOptionText', 'Filter %s'], ['filterTextPrefix', '(filtered) '], ['filterFrozenRows', true], ['globalRowResize', false], ['hideColumnText', 'Hide %s'], ['showUnhideColumnsIndicator', false], ['showUnhideRowsIndicator', false], ['showHideRow', 'Hide row %s'], ['showHideRows', 'Hide rows %s'], ['hoverMode', 'cell'], ['keepFocusOnMouseOut', false], ['maxAutoCompleteItems', 200], ['multiLine', false], ['name', ''], ['pageUpDownOverlap', 1], ['pasteText', 'Paste'], ['persistantSelectionMode', false], ['removeFilterOptionText', 'Remove filter on %s'], ['reorderDeadZone', 3], ['resizeScrollZone', 20], ['rowGrabZoneSize', 5], ['columnGrabZoneSize', 30], ['saveAppearance', true], ['scrollAnimationPPSThreshold', 0.75], ['scrollPointerLock', false], ['scrollRepeatRate', 75], ['selectionFollowsActiveCell', false], ['selectionHandleBehavior', 'none'], ['selectionMode', 'cell'], ['selectionScrollIncrement', 20], ['selectionScrollZone', 20], ['showClearSettingsOption', true], ['showColumnHeaders', true], ['showColumnSelector', true], ['showCopy', false], ['showFilter', true], ['showFilterInCell', false], ['showNewRow', false], ['showOrderByOption', true], ['showOrderByOptionTextAsc', 'Order by %s ascending'], ['showOrderByOptionTextDesc', 'Order by %s descending'], //#region grouping
1842
+ attributes: [['allowColumnReordering', true], ['allowColumnResize', true], ['allowColumnResizeFromCell', false], ['allowFreezingRows', false], ['allowFreezingColumns', false], ['allowMovingSelection', true], ['allowRowHeaderResize', true], ['allowRowReordering', false], ['allowRowResize', true], ['allowRowResizeFromCell', false], ['allowSorting', true], ['allowGroupingRows', true], ['allowGroupingColumns', true], ['animationDurationShowContextMenu', 50], ['animationDurationHideContextMenu', 50], ['autoGenerateSchema', false], ['autoResizeColumns', false], ['autoResizeRows', false], ['autoScrollOnMousemove', false], ['autoScrollMargin', 5], ['allowShrinkingSelection', false], ['blanksText', '(Blanks)'], ['borderDragBehavior', 'none'], ['borderResizeZone', 10], ['clearCellsWhenShrinkingSelection', false], ['clearSettingsOptionText', 'Clear saved settings'], ['columnHeaderClickBehavior', 'sort'], ['columnSelectorHiddenText', '   '], ['columnSelectorText', 'Add/Remove columns'], ['columnSelectorVisibleText', "\u2713"], ['contextHoverScrollAmount', 2], ['contextHoverScrollRateMs', 5], ['copyHeadersOnSelectAll', true], ['copyText', 'Copy'], ['debug', false], ['editable', true], ['ellipsisText', '...'], ['filterOptionText', 'Filter %s'], ['filterTextPrefix', '(filtered) '], ['filterFrozenRows', true], ['globalRowResize', false], ['hideColumnText', 'Hide %s'], ['showUnhideColumnsIndicator', false], ['showUnhideRowsIndicator', false], ['showHideRow', 'Hide row %s'], ['showHideRows', 'Hide rows %s'], ['hoverMode', 'cell'], ['keepFocusOnMouseOut', false], ['maxAutoCompleteItems', 200], ['multiLine', false], ['name', ''], ['pageUpDownOverlap', 1], ['pasteText', 'Paste'], ['persistantSelectionMode', false], ['removeFilterOptionText', 'Remove filter on %s'], ['reorderDeadZone', 3], ['resizeScrollZone', 20], ['rowGrabZoneSize', 5], ['columnGrabZoneSize', 30], ['saveAppearance', true], ['scrollAnimationPPSThreshold', 0.75], ['scrollPointerLock', false], ['scrollRepeatRate', 75], ['selectionFollowsActiveCell', false], ['selectionHandleBehavior', 'none'], ['selectionMode', 'cell'], ['selectionScrollIncrement', 20], ['selectionScrollZone', 20], ['showClearSettingsOption', true], ['showColumnHeaders', true], ['showColumnSelector', true], ['showCopy', false], ['showFilter', true], ['showFilterInCell', false], ['showNewRow', false], ['showOrderByOption', true], ['showOrderByOptionTextAsc', 'Order by %s ascending'], ['showOrderByOptionTextDesc', 'Order by %s descending'], //#region grouping
1843
1843
  ['showGroupColumns', 'Group columns %s'], ['showGroupRows', 'Group rows %s'], ['showRemoveGroupColumns', 'Remove group %s'], ['showRemoveGroupRows', 'Remove group %s'], ['showRemoveAllGroupColumns', 'Remove all column groups'], ['showRemoveAllGroupRows', 'Remove all row groups'], ['showExpandAllGroupColumns', 'Expand all column groups'], ['showExpandAllGroupRows', 'Expand all row groups'], ['showCollapseAllGroupColumns', 'Collapse all column groups'], ['showCollapseAllGroupRows', 'Collapse all row groups'], ['columnGroupIndicatorPosition', 'right'], ['rowGroupIndicatorPosition', 'bottom'], //#endregion grouping
1844
1844
  ['showPaste', false], ['showPerformance', false], ['showRowHeaders', true], ['showRowNumbers', true], ['showRowNumberGaps', true], ['singleSelectionMode', false], ['snapToRow', false], ['sortFrozenRows', true], ['touchContextMenuTimeMs', 800], ['touchDeadZone', 3], ['touchEasingMethod', 'easeOutQuad'], ['touchReleaseAcceleration', 1000], ['touchReleaseAnimationDurationMs', 2000], ['touchScrollZone', 20], ['touchSelectHandleZone', 20], ['touchZoomSensitivity', 0.005], ['touchZoomMin', 0.5], ['touchZoomMax', 1.75], ['maxPixelRatio', 2], ['tree', false], ['treeHorizontalScroll', false], ['rowTree', []], ['rowTreeColIndex', 0], ['columnTree', []], ['columnTreeRowStartIndex', 0], ['columnTreeRowEndIndex', 0]],
1845
- styles: [['activeCellBackgroundColor', 'rgba(255, 255, 255, 1)'], ['activeCellBorderColor', 'rgba(110, 168, 255, 1)'], ['activeCellBorderWidth', 1], ['activeCellColor', 'rgba(0, 0, 0, 1)'], ['activeCellFont', '16px sans-serif'], ['activeCellHoverBackgroundColor', 'rgba(255, 255, 255, 1)'], ['activeCellHorizontalAlignment', 'left'], ['activeCellHoverColor', 'rgba(0, 0, 0, 1)'], ['activeCellOverlayBorderColor', 'rgba(66, 133, 244, 1)'], ['activeCellOverlayBorderWidth', 1], ['activeCellPaddingBottom', 5], ['activeCellPaddingLeft', 5], ['activeCellPaddingRight', 5], ['activeCellPaddingTop', 5], ['activeCellSelectedBackgroundColor', 'rgba(236, 243, 255, 1)'], ['activeCellSelectedColor', 'rgba(0, 0, 0, 1)'], ['activeCellVerticalAlignment', 'center'], ['activeColumnHeaderCellBackgroundColor', 'rgba(225, 225, 225, 1)'], ['activeColumnHeaderCellColor', 'rgba(0, 0, 0, 1)'], ['activeRowHeaderCellBackgroundColor', 'rgba(225, 225, 225, 1)'], ['activeRowHeaderCellColor', 'rgba(0, 0, 0, 1)'], ['autocompleteBottomMargin', 60], ['autosizeHeaderCellPadding', 8], ['autosizePadding', 5], ['buttonActiveBackgroundColor', 'rgba(255, 255, 255, 1)'], ['buttonActiveBorderColor', 'rgba(110, 168, 255, 1)'], ['buttonArrowColor', 'rgba(50, 50, 50, 1)'], ['buttonArrowDownHTML', '▼'], ['buttonZIndex', 10000], ['buttonBackgroundColor', 'rgba(255, 255, 255, 1)'], ['buttonBorderColor', 'rgba(172, 172, 172, 1)'], ['buttonHoverBackgroundColor', 'rgba(240, 240, 240, 1)'], ['buttonMenuWindowMargin', 30], ['buttonPadding', '3px'], ['cellAutoResizePadding', 13], ['cellBackgroundColor', 'rgba(255, 255, 255, 1)'], ['cellBorderColor', 'rgba(195, 199, 202, 1)'], ['cellBorderWidth', 1], ['cellColor', 'rgba(0, 0, 0, 1)'], ['cellFont', '16px sans-serif'], ['cellGridHeight', 250], ['cellHeight', 24], ['cellHeightWithChildGrid', 150], ['cellHorizontalAlignment', 'left'], ['cellHoverBackgroundColor', 'rgba(255, 255, 255, 1)'], ['cellHoverColor', 'rgba(0, 0, 0, 1)'], ['cellPaddingBottom', 5], ['cellPaddingLeft', 5], ['cellPaddingRight', 5], ['cellPaddingTop', 5], ['cellSelectedBackgroundColor', 'rgba(236, 243, 255, 1)'], ['cellSelectedColor', 'rgba(0, 0, 0, 1)'], ['cellTreeIconBorderColor', 'rgba(162, 174, 207, 1)'], ['cellTreeIconFillColor', 'rgba(240, 240, 240, 1)'], ['cellTreeIconHoverFillColor', 'rgba(198, 217, 233, 1)'], ['cellTreeIconLineColor', 'rgba(43, 53, 81, 1)'], ['cellTreeIconLineWidth', 1.5], ['cellTreeIconMarginLeft', 0], ['cellTreeIconMarginRight', 5], ['cellTreeIconMarginTop', 6], ['cellTreeIconWidth', 13], ['cellVerticalAlignment', 'center'], ['cellWidth', 250], ['cellWidthWithChildGrid', 250], ['cellWhiteSpace', 'nowrap'], ['cellLineHeight', 1], ['cellLineSpacing', 3], ['childContextMenuArrowColor', 'rgba(43, 48, 43, 1)'], ['childContextMenuArrowHTML', '►'], ['childContextMenuMarginLeft', -11], ['childContextMenuMarginTop', -6], ['columnGroupRowHeight', 25], ['columnHeaderCellBackgroundColor', 'rgba(240, 240, 240, 1)'], ['columnHeaderCellBorderColor', 'rgba(172, 172, 172, 1)'], ['columnHeaderCellBorderWidth', 1], ['columnHeaderCellCapBackgroundColor', 'rgba(240, 240, 240, 1)'], ['columnHeaderCellCapBorderColor', 'rgba(172, 172, 172, 1)'], ['columnHeaderCellCapBorderWidth', 1], ['columnHeaderCellColor', 'rgba(50, 50, 50, 1)'], ['columnHeaderCellFont', '16px sans-serif'], ['columnHeaderCellHeight', 25], ['columnHeaderCellHorizontalAlignment', 'left'], ['columnHeaderCellHoverBackgroundColor', 'rgba(235, 235, 235, 1)'], ['columnHeaderCellHoverColor', 'rgba(0, 0, 0, 1)'], ['columnHeaderCellPaddingBottom', 5], ['columnHeaderCellPaddingLeft', 5], ['columnHeaderCellPaddingRight', 5], ['columnHeaderCellPaddingTop', 5], ['columnHeaderCellVerticalAlignment', 'center'], ['columnHeaderOrderByArrowBorderColor', 'rgba(195, 199, 202, 1)'], ['columnHeaderOrderByArrowBorderWidth', 1], ['columnHeaderOrderByArrowColor', 'rgba(155, 155, 155, 1)'], ['columnHeaderOrderByArrowHeight', 8], ['columnHeaderOrderByArrowMarginLeft', 0], ['columnHeaderOrderByArrowMarginRight', 5], ['columnHeaderOrderByArrowMarginTop', 6], ['columnHeaderOrderByArrowWidth', 13], ['contextFilterButtonBorder', 'solid 1px rgba(158, 163, 169, 1)'], ['contextFilterButtonBorderRadius', '3px'], ['contextFilterButtonHTML', '▼'], ['contextFilterInputBackground', 'rgba(255,255,255,1)'], ['contextFilterInputBorder', 'solid 1px rgba(158, 163, 169, 1)'], ['contextFilterInputBorderRadius', '0'], ['contextFilterInputColor', 'rgba(0,0,0,1)'], ['contextFilterInputFontFamily', 'sans-serif'], ['contextFilterInputFontSize', '14px'], ['contextFilterInvalidRegExpBackground', 'rgba(180, 6, 1, 1)'], ['contextFilterInvalidRegExpColor', 'rgba(255, 255, 255, 1)'], ['contextMenuArrowColor', 'rgba(43, 48, 43, 1)'], ['contextMenuArrowDownHTML', '▼'], ['contextMenuArrowUpHTML', '▲'], ['contextMenuBackground', 'rgba(240, 240, 240, 1)'], ['contextMenuBorder', 'solid 1px rgba(158, 163, 169, 1)'], ['contextMenuBorderRadius', '3px'], ['contextMenuChildArrowFontSize', '12px'], ['contextMenuColor', 'rgba(43, 48, 43, 1)'], ['contextMenuCursor', 'default'], ['contextMenuFilterButtonFontFamily', 'sans-serif'], ['contextMenuFilterButtonFontSize', '10px'], ['contextMenuFilterInvalidExpresion', 'rgba(237, 155, 156, 1)'], ['contextMenuFontFamily', 'sans-serif'], ['contextMenuFontSize', '16px'], ['contextMenuHoverBackground', 'rgba(182, 205, 250, 1)'], ['contextMenuHoverColor', 'rgba(43, 48, 153, 1)'], ['contextMenuItemBorderRadius', '3px'], ['contextMenuItemMargin', '2px'], ['contextMenuLabelDisplay', 'inline-block'], ['contextMenuLabelMargin', '0 3px 0 0'], ['contextMenuLabelMaxWidth', '700px'], ['contextMenuLabelMinWidth', '75px'], ['contextMenuMarginLeft', 3], ['contextMenuMarginTop', -3], ['contextMenuOpacity', '0.98'], ['contextMenuPadding', '2px'], ['contextMenuWindowMargin', 30], ['contextMenuZIndex', 10000], ['cornerCellBackgroundColor', 'rgba(240, 240, 240, 1)'], ['cornerCellBorderColor', 'rgba(202, 202, 202, 1)'], ['debugBackgroundColor', 'rgba(0, 0, 0, .0)'], ['debugColor', 'rgba(255, 15, 24, 1)'], ['debugEntitiesColor', 'rgba(76, 231, 239, 1.00)'], ['debugFont', '11px sans-serif'], ['debugPerfChartBackground', 'rgba(29, 25, 26, 1.00)'], ['debugPerfChartTextColor', 'rgba(255, 255, 255, 0.8)'], ['debugPerformanceColor', 'rgba(252, 255, 37, 1.00)'], ['debugScrollHeightColor', 'rgba(248, 33, 103, 1.00)'], ['debugScrollWidthColor', 'rgba(66, 255, 27, 1.00)'], ['debugTouchPPSXColor', 'rgba(246, 102, 24, 1.00)'], ['debugTouchPPSYColor', 'rgba(186, 0, 255, 1.00)'], ['display', 'inline-block'], ['editCellBackgroundColor', 'white'], ['editCellBorder', 'solid 1px rgba(110, 168, 255, 1)'], ['editCellBoxShadow', '0 2px 5px rgba(0,0,0,0.4)'], ['editCellColor', 'black'], ['editCellFontFamily', 'sans-serif'], ['editCellFontSize', '16px'], ['editCellPaddingLeft', 4], ['editCellZIndex', 10000], ['filterButtonActiveBackgroundColor', 'rgba(225, 225, 225, 1)'], ['filterButtonArrowBorderColor', 'rgba(195, 199, 202, 1)'], ['filterButtonArrowBorderWidth', 1], ['filterButtonArrowClickRadius', 5], ['filterButtonArrowColor', 'rgba(50, 50, 50, 1)'], ['filterButtonArrowHeight', 5], ['filterButtonArrowWidth', 8], ['filterButtonBackgroundColor', 'rgba(240, 240, 240, 1)'], ['filterButtonBorderColor', 'rgba(172, 172, 172, 1)'], ['filterButtonBorderRadius', 3], ['filterButtonHeight', 20], ['filterButtonHoverBackgroundColor', 'rgba(235, 235, 235, 1)'], ['filterButtonMenuOffsetTop', 10], ['filterButtonWidth', 20], ['frozenMarkerHoverColor', 'rgba(165, 198, 254, 1)'], ['frozenMarkerHoverBorderColor', 'rgba(165, 198, 254, 1)'], ['frozenMarkerActiveColor', 'rgba(165, 198, 254, 0.2)'], ['frozenMarkerActiveBorderColor', 'rgba(165, 198, 254, 0.5)'], ['frozenMarkerActiveHeaderColor', 'rgba(165, 198, 254, 1)'], ['frozenMarkerColor', 'rgba(221, 221, 221, 1)'], ['frozenMarkerBorderColor', 'rgba(221, 221, 221, 1)'], ['frozenMarkerBorderWidth', 1], ['frozenMarkerHeaderColor', 'rgba(188, 188, 188, 1)'], ['frozenMarkerWidth', 4], ['groupingAreaBackgroundColor', 'rgba(240, 240, 240, 1)'], ['gridBackgroundColor', 'rgba(240, 240, 240, 1)'], ['gridBorderCollapse', 'collapse'], ['gridBorderColor', 'rgba(202, 202, 202, 1)'], ['gridBorderWidth', 1], ['groupIndicatorColor', 'rgba(155, 155, 155, 1)'], ['groupIndicatorBackgroundColor', 'rgba(255, 255, 255, 1)'], ['height', 'auto'], ['maxHeight', 'inherit'], ['maxWidth', 'inherit'], ['minColumnWidth', 45], ['minHeight', 'inherit'], ['minRowHeight', 24], ['minWidth', 'inherit'], ['mobileContextMenuMargin', 10], ['mobileEditInputHeight', 30], ['mobileEditFontFamily', 'sans-serif'], ['mobileEditFontSize', '16px'], ['moveOverlayBorderWidth', 1], ['moveOverlayBorderColor', 'rgba(66, 133, 244, 1)'], ['moveOverlayBorderSegments', '12, 7'], ['name', 'default'], ['overflowY', 'auto'], ['overflowX', 'auto'], ['reorderMarkerBackgroundColor', 'rgba(0, 0, 0, 0.1)'], ['reorderMarkerBorderColor', 'rgba(0, 0, 0, 0.2)'], ['reorderMarkerBorderWidth', 1.25], ['reorderMarkerIndexBorderColor', 'rgba(66, 133, 244, 1)'], ['reorderMarkerIndexBorderWidth', 2.75], ['rowGroupColumnWidth', 25], ['rowHeaderCellBackgroundColor', 'rgba(240, 240, 240, 1)'], ['rowHeaderCellBorderColor', 'rgba(200, 200, 200, 1)'], ['rowHeaderCellBorderWidth', 1], ['rowHeaderCellColor', 'rgba(50, 50, 50, 1)'], ['rowHeaderCellFont', '16px sans-serif'], ['rowHeaderCellHeight', 25], ['rowHeaderCellHorizontalAlignment', 'left'], ['rowHeaderCellHoverBackgroundColor', 'rgba(235, 235, 235, 1)'], ['rowHeaderCellHoverColor', 'rgba(0, 0, 0, 1)'], ['rowHeaderCellPaddingBottom', 5], ['rowHeaderCellPaddingLeft', 5], ['rowHeaderCellPaddingRight', 5], ['rowHeaderCellPaddingTop', 5], ['rowHeaderCellRowNumberGapHeight', 5], ['rowHeaderCellRowNumberGapColor', 'rgba(50, 50, 50, 1)'], ['rowHeaderCellSelectedBackgroundColor', 'rgba(217, 217, 217, 1)'], ['rowHeaderCellSelectedColor', 'rgba(50, 50, 50, 1)'], ['rowHeaderCellVerticalAlignment', 'center'], ['rowHeaderCellWidth', 57], ['scrollBarActiveColor', 'rgba(125, 125, 125, 1)'], ['scrollBarBackgroundColor', 'rgba(240, 240, 240, 1)'], ['scrollBarBorderColor', 'rgba(202, 202, 202, 1)'], ['scrollBarBorderWidth', 0.5], ['scrollBarBoxBorderRadius', 4.125], ['scrollBarBoxColor', 'rgba(192, 192, 192, 1)'], ['scrollBarBoxMargin', 2], ['scrollBarBoxMinSize', 15], ['scrollBarBoxWidth', 8], ['scrollBarCornerBackgroundColor', 'rgba(240, 240, 240, 1)'], ['scrollBarCornerBorderColor', 'rgba(202, 202, 202, 1)'], ['scrollBarWidth', 11], ['selectionHandleBorderColor', 'rgba(255, 255, 255, 1)'], ['selectionHandleBorderWidth', 1.5], ['selectionHandleColor', 'rgba(66, 133, 244, 1)'], ['selectionHandleSize', 8], ['selectionHandleType', 'square'], ['selectionOverlayBorderColor', 'rgba(66, 133, 244, 1)'], ['selectionOverlayBorderWidth', 1], ['treeArrowBorderColor', 'rgba(195, 199, 202, 1)'], ['treeArrowBorderWidth', 1], ['treeArrowClickRadius', 5], ['treeArrowColor', 'rgba(155, 155, 155, 1)'], ['treeArrowHeight', 8], ['treeArrowMarginLeft', 0], ['treeArrowMarginRight', 5], ['treeArrowMarginTop', 6], ['treeArrowWidth', 13], ['treeGridHeight', 250], ['unhideIndicatorColor', 'rgba(0, 0, 0, 1)'], ['unhideIndicatorBackgroundColor', 'rgba(255, 255, 255, 1)'], ['unhideIndicatorBorderColor', 'rgba(174, 193, 232, 1)'], ['unhideIndicatorSize', 16], ['width', 'auto']]
1845
+ styles: [['activeCellBackgroundColor', 'rgba(255, 255, 255, 1)'], ['activeCellBorderColor', 'rgba(110, 168, 255, 1)'], ['activeCellBorderWidth', 1], ['activeCellColor', 'rgba(0, 0, 0, 1)'], ['activeCellFont', '16px sans-serif'], ['activeCellHoverBackgroundColor', 'rgba(255, 255, 255, 1)'], ['activeCellHorizontalAlignment', 'left'], ['activeCellHoverColor', 'rgba(0, 0, 0, 1)'], ['activeCellOverlayBorderColor', 'rgba(66, 133, 244, 1)'], ['activeCellOverlayBorderWidth', 1], ['activeCellPaddingBottom', 5], ['activeCellPaddingLeft', 5], ['activeCellPaddingRight', 5], ['activeCellPaddingTop', 5], ['activeCellSelectedBackgroundColor', 'rgba(236, 243, 255, 1)'], ['activeCellSelectedColor', 'rgba(0, 0, 0, 1)'], ['activeCellVerticalAlignment', 'center'], ['activeColumnHeaderCellBackgroundColor', 'rgba(225, 225, 225, 1)'], ['activeColumnHeaderCellColor', 'rgba(0, 0, 0, 1)'], ['activeRowHeaderCellBackgroundColor', 'rgba(225, 225, 225, 1)'], ['activeRowHeaderCellColor', 'rgba(0, 0, 0, 1)'], ['autocompleteBottomMargin', 60], ['autosizeHeaderCellPadding', 8], ['autosizePadding', 5], ['buttonActiveBackgroundColor', 'rgba(255, 255, 255, 1)'], ['buttonActiveBorderColor', 'rgba(110, 168, 255, 1)'], ['buttonArrowColor', 'rgba(50, 50, 50, 1)'], ['buttonArrowDownHTML', '▼'], ['buttonZIndex', 10000], ['buttonBackgroundColor', 'rgba(255, 255, 255, 1)'], ['buttonBorderColor', 'rgba(172, 172, 172, 1)'], ['buttonHoverBackgroundColor', 'rgba(240, 240, 240, 1)'], ['buttonMenuWindowMargin', 30], ['buttonPadding', '3px'], ['cellAutoResizePadding', 13], ['cellBackgroundColor', 'rgba(255, 255, 255, 1)'], ['cellBorderColor', 'rgba(195, 199, 202, 1)'], ['cellBorderWidth', 1], ['cellColor', 'rgba(0, 0, 0, 1)'], ['cellFont', '16px sans-serif'], ['cellGridHeight', 250], ['cellHeight', 24], ['cellHeightWithChildGrid', 150], ['cellHorizontalAlignment', 'left'], ['cellHoverBackgroundColor', 'rgba(255, 255, 255, 1)'], ['cellHoverColor', 'rgba(0, 0, 0, 1)'], ['cellPaddingBottom', 5], ['cellPaddingLeft', 5], ['cellPaddingRight', 5], ['cellPaddingTop', 5], ['cellSelectedBackgroundColor', 'rgba(236, 243, 255, 1)'], ['cellSelectedColor', 'rgba(0, 0, 0, 1)'], ['cellTreeIconBorderColor', 'rgba(162, 174, 207, 1)'], ['cellTreeIconFillColor', 'rgba(240, 240, 240, 1)'], ['cellTreeIconHoverFillColor', 'rgba(198, 217, 233, 1)'], ['cellTreeIconLineColor', 'rgba(43, 53, 81, 1)'], ['cellTreeIconLineWidth', 1.5], ['cellTreeIconMarginLeft', 0], ['cellTreeIconMarginRight', 5], ['cellTreeIconMarginTop', 6], ['cellTreeIconWidth', 13], ['cellVerticalAlignment', 'center'], ['cellWidth', 250], ['cellWidthWithChildGrid', 250], ['cellWhiteSpace', 'nowrap'], ['cellLineHeight', 1], ['cellLineSpacing', 3], ['childContextMenuArrowColor', 'rgba(43, 48, 43, 1)'], ['childContextMenuArrowHTML', '►'], ['childContextMenuMarginLeft', -11], ['childContextMenuMarginTop', -6], ['columnGroupRowHeight', 25], ['columnHeaderCellBackgroundColor', 'rgba(240, 240, 240, 1)'], ['columnHeaderCellBorderColor', 'rgba(172, 172, 172, 1)'], ['columnHeaderCellBorderWidth', 1], ['columnHeaderCellCapBackgroundColor', 'rgba(240, 240, 240, 1)'], ['columnHeaderCellCapBorderColor', 'rgba(172, 172, 172, 1)'], ['columnHeaderCellCapBorderWidth', 1], ['columnHeaderCellColor', 'rgba(50, 50, 50, 1)'], ['columnHeaderCellFont', '16px sans-serif'], ['columnHeaderCellHeight', 25], ['columnHeaderCellHorizontalAlignment', 'left'], ['columnHeaderCellHoverBackgroundColor', 'rgba(235, 235, 235, 1)'], ['columnHeaderCellHoverColor', 'rgba(0, 0, 0, 1)'], ['columnHeaderCellPaddingBottom', 5], ['columnHeaderCellPaddingLeft', 5], ['columnHeaderCellPaddingRight', 5], ['columnHeaderCellPaddingTop', 5], ['columnHeaderCellVerticalAlignment', 'center'], ['columnHeaderOrderByArrowBorderColor', 'rgba(195, 199, 202, 1)'], ['columnHeaderOrderByArrowBorderWidth', 1], ['columnHeaderOrderByArrowColor', 'rgba(155, 155, 155, 1)'], ['columnHeaderOrderByArrowHeight', 8], ['columnHeaderOrderByArrowMarginLeft', 0], ['columnHeaderOrderByArrowMarginRight', 5], ['columnHeaderOrderByArrowMarginTop', 6], ['columnHeaderOrderByArrowWidth', 13], ['contextFilterButtonBorder', 'solid 1px rgba(158, 163, 169, 1)'], ['contextFilterButtonBorderRadius', '3px'], ['contextFilterButtonHTML', '▼'], ['contextFilterInputBackground', 'rgba(255,255,255,1)'], ['contextFilterInputBorder', 'solid 1px rgba(158, 163, 169, 1)'], ['contextFilterInputBorderRadius', '0'], ['contextFilterInputColor', 'rgba(0,0,0,1)'], ['contextFilterInputFontFamily', 'sans-serif'], ['contextFilterInputFontSize', '14px'], ['contextFilterInvalidRegExpBackground', 'rgba(180, 6, 1, 1)'], ['contextFilterInvalidRegExpColor', 'rgba(255, 255, 255, 1)'], ['contextMenuArrowColor', 'rgba(43, 48, 43, 1)'], ['contextMenuArrowDownHTML', '▼'], ['contextMenuArrowUpHTML', '▲'], ['contextMenuBackground', 'rgba(240, 240, 240, 1)'], ['contextMenuBorder', 'solid 1px rgba(158, 163, 169, 1)'], ['contextMenuBorderRadius', '3px'], ['contextMenuChildArrowFontSize', '12px'], ['contextMenuColor', 'rgba(43, 48, 43, 1)'], ['contextMenuCursor', 'default'], ['contextMenuFilterButtonFontFamily', 'sans-serif'], ['contextMenuFilterButtonFontSize', '10px'], ['contextMenuFilterInvalidExpresion', 'rgba(237, 155, 156, 1)'], ['contextMenuFontFamily', 'sans-serif'], ['contextMenuFontSize', '16px'], ['contextMenuHoverBackground', 'rgba(182, 205, 250, 1)'], ['contextMenuHoverColor', 'rgba(43, 48, 153, 1)'], ['contextMenuItemBorderRadius', '3px'], ['contextMenuItemMargin', '2px'], ['contextMenuLabelDisplay', 'inline-block'], ['contextMenuLabelMargin', '0 3px 0 0'], ['contextMenuLabelMaxWidth', '700px'], ['contextMenuLabelMinWidth', '75px'], ['contextMenuMarginLeft', 3], ['contextMenuMarginTop', -3], ['contextMenuOpacity', '0.98'], ['contextMenuPadding', '2px'], ['contextMenuWindowMargin', 30], ['contextMenuZIndex', 10000], ['cornerCellBackgroundColor', 'rgba(240, 240, 240, 1)'], ['cornerCellBorderColor', 'rgba(202, 202, 202, 1)'], ['debugBackgroundColor', 'rgba(0, 0, 0, .0)'], ['debugColor', 'rgba(255, 15, 24, 1)'], ['debugEntitiesColor', 'rgba(76, 231, 239, 1.00)'], ['debugFont', '11px sans-serif'], ['debugPerfChartBackground', 'rgba(29, 25, 26, 1.00)'], ['debugPerfChartTextColor', 'rgba(255, 255, 255, 0.8)'], ['debugPerformanceColor', 'rgba(252, 255, 37, 1.00)'], ['debugScrollHeightColor', 'rgba(248, 33, 103, 1.00)'], ['debugScrollWidthColor', 'rgba(66, 255, 27, 1.00)'], ['debugTouchPPSXColor', 'rgba(246, 102, 24, 1.00)'], ['debugTouchPPSYColor', 'rgba(186, 0, 255, 1.00)'], ['display', 'inline-block'], ['editCellBackgroundColor', 'white'], ['editCellBorder', 'solid 1px rgba(110, 168, 255, 1)'], ['editCellBoxShadow', '0 2px 5px rgba(0,0,0,0.4)'], ['editCellColor', 'black'], ['editCellFontFamily', 'sans-serif'], ['editCellFontSize', '16px'], ['editCellPaddingLeft', 4], ['editCellZIndex', 10000], ['filterButtonActiveBackgroundColor', 'rgba(225, 225, 225, 1)'], ['filterButtonArrowBorderColor', 'rgba(195, 199, 202, 1)'], ['filterButtonArrowBorderWidth', 1], ['filterButtonArrowClickRadius', 5], ['filterButtonArrowColor', 'rgba(50, 50, 50, 1)'], ['filterButtonArrowHeight', 5], ['filterButtonArrowWidth', 8], ['filterButtonBackgroundColor', 'rgba(240, 240, 240, 1)'], ['filterButtonBorderColor', 'rgba(172, 172, 172, 1)'], ['filterButtonBorderRadius', 3], ['filterButtonHeight', 20], ['filterButtonHoverBackgroundColor', 'rgba(235, 235, 235, 1)'], ['filterButtonMenuOffsetTop', 10], ['filterButtonWidth', 20], ['frozenMarkerHoverColor', 'rgba(165, 198, 254, 1)'], ['frozenMarkerHoverBorderColor', 'rgba(165, 198, 254, 1)'], ['frozenMarkerActiveColor', 'rgba(165, 198, 254, 0.2)'], ['frozenMarkerActiveBorderColor', 'rgba(165, 198, 254, 0.5)'], ['frozenMarkerActiveHeaderColor', 'rgba(165, 198, 254, 1)'], ['frozenMarkerColor', 'rgba(221, 221, 221, 1)'], ['frozenMarkerBorderColor', 'rgba(221, 221, 221, 1)'], ['frozenMarkerBorderWidth', 1], ['frozenMarkerHeaderColor', 'rgba(188, 188, 188, 1)'], ['frozenMarkerWidth', 4], ['groupingAreaBackgroundColor', 'rgba(240, 240, 240, 1)'], ['gridBackgroundColor', 'rgba(240, 240, 240, 1)'], ['gridBorderCollapse', 'collapse'], ['gridBorderColor', 'rgba(202, 202, 202, 1)'], ['gridBorderWidth', 1], ['groupIndicatorColor', 'rgba(155, 155, 155, 1)'], ['groupIndicatorBackgroundColor', 'rgba(255, 255, 255, 1)'], ['height', 'auto'], ['maxHeight', 'inherit'], ['maxWidth', 'inherit'], ['minColumnWidth', 45], ['minHeight', 'inherit'], ['minRowHeight', 24], ['minWidth', 'inherit'], ['mobileContextMenuMargin', 10], ['mobileEditInputHeight', 30], ['mobileEditFontFamily', 'sans-serif'], ['mobileEditFontSize', '16px'], ['moveOverlayBorderWidth', 1], ['moveOverlayBorderColor', 'rgba(66, 133, 244, 1)'], ['moveOverlayBorderSegments', '12, 7'], ['name', 'default'], ['overflowY', 'auto'], ['overflowX', 'auto'], ['reorderMarkerBackgroundColor', 'rgba(0, 0, 0, 0.1)'], ['reorderMarkerBorderColor', 'rgba(0, 0, 0, 0.2)'], ['reorderMarkerBorderWidth', 1.25], ['reorderMarkerIndexBorderColor', 'rgba(66, 133, 244, 1)'], ['reorderMarkerIndexBorderWidth', 2.75], ['rowGroupColumnWidth', 25], ['rowHeaderCellBackgroundColor', 'rgba(240, 240, 240, 1)'], ['rowHeaderCellBorderColor', 'rgba(200, 200, 200, 1)'], ['rowHeaderCellBorderWidth', 1], ['rowHeaderCellColor', 'rgba(50, 50, 50, 1)'], ['rowHeaderCellFont', '16px sans-serif'], ['rowHeaderCellHeight', 25], ['rowHeaderCellHorizontalAlignment', 'left'], ['rowHeaderCellHoverBackgroundColor', 'rgba(235, 235, 235, 1)'], ['rowHeaderCellHoverColor', 'rgba(0, 0, 0, 1)'], ['rowHeaderCellPaddingBottom', 5], ['rowHeaderCellPaddingLeft', 5], ['rowHeaderCellPaddingRight', 5], ['rowHeaderCellPaddingTop', 5], ['rowHeaderCellRowNumberGapHeight', 5], ['rowHeaderCellRowNumberGapColor', 'rgba(50, 50, 50, 1)'], ['rowHeaderCellSelectedBackgroundColor', 'rgba(217, 217, 217, 1)'], ['rowHeaderCellSelectedColor', 'rgba(50, 50, 50, 1)'], ['rowHeaderCellVerticalAlignment', 'center'], ['rowHeaderCellWidth', 57], ['scrollBarActiveColor', 'rgba(125, 125, 125, 1)'], ['scrollBarBackgroundColor', 'rgba(240, 240, 240, 1)'], ['scrollBarBorderColor', 'rgba(202, 202, 202, 1)'], ['scrollBarBorderWidth', 0.5], ['scrollBarBoxBorderRadius', 4.125], ['scrollBarBoxColor', 'rgba(192, 192, 192, 1)'], ['scrollBarBoxMargin', 2], ['scrollBarBoxMinSize', 15], ['scrollBarBoxWidth', 8], ['scrollBarCornerBackgroundColor', 'rgba(240, 240, 240, 1)'], ['scrollBarCornerBorderColor', 'rgba(202, 202, 202, 1)'], ['scrollBarWidth', 11], ['selectionHandleBorderColor', 'rgba(255, 255, 255, 1)'], ['selectionHandleBorderWidth', 1.5], ['selectionHandleColor', 'rgba(66, 133, 244, 1)'], ['selectionHandleSize', 8], ['selectionHandleType', 'square'], ['fillOverlayBorderColor', 'rgba(127, 127, 127, 1)'], ['fillOverlayBorderWidth', 2], ['selectionOverlayBorderColor', 'rgba(66, 133, 244, 1)'], ['selectionOverlayBorderWidth', 1], ['treeArrowBorderColor', 'rgba(195, 199, 202, 1)'], ['treeArrowBorderWidth', 1], ['treeArrowClickRadius', 5], ['treeArrowColor', 'rgba(155, 155, 155, 1)'], ['treeArrowHeight', 8], ['treeArrowMarginLeft', 0], ['treeArrowMarginRight', 5], ['treeArrowMarginTop', 6], ['treeArrowWidth', 13], ['treeGridHeight', 250], ['unhideIndicatorColor', 'rgba(0, 0, 0, 1)'], ['unhideIndicatorBackgroundColor', 'rgba(255, 255, 255, 1)'], ['unhideIndicatorBorderColor', 'rgba(174, 193, 232, 1)'], ['unhideIndicatorSize', 16], ['width', 'auto']]
1846
1846
  };
1847
1847
  }
1848
1848
 
@@ -3650,9 +3650,18 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
3650
3650
  cell.selectionHandle = 'tr';
3651
3651
  }
3652
3652
 
3653
- if (cell.selectionBorderTop && cell.selectionBorderLeft && self.mobile) {
3654
- selectionHandles.push([cell, 'tl']);
3655
- cell.selectionHandle = 'tl';
3653
+ if (cell.selectionBorderTop && cell.selectionBorderLeft) {
3654
+ if (self.mobile) {
3655
+ selectionHandles.push([cell, 'tl']);
3656
+ cell.selectionHandle = 'tl';
3657
+ }
3658
+
3659
+ if (self.fillOverlay.handle) {
3660
+ self.fillOverlay.snapTo = {
3661
+ x: cell.x,
3662
+ y: cell.y
3663
+ };
3664
+ }
3656
3665
  }
3657
3666
 
3658
3667
  if (cell.selectionBorderBottom && cell.selectionBorderLeft && self.mobile) {
@@ -3663,6 +3672,23 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
3663
3672
  if (cell.selectionBorderBottom && cell.selectionBorderRight && (self.attributes.selectionHandleBehavior !== 'none' || self.mobile)) {
3664
3673
  selectionHandles.push([cell, 'br']);
3665
3674
  cell.selectionHandle = 'br';
3675
+
3676
+ if (self.fillOverlay.handle) {
3677
+ self.fillOverlay.handle.x = cell.x + cell.width;
3678
+ self.fillOverlay.handle.y = cell.y + cell.height;
3679
+ }
3680
+ }
3681
+
3682
+ if (self.fillOverlay.handle) {
3683
+ // Some corners may not be displaying, so we get at least
3684
+ // one correct axis in order to display a fill overlay.
3685
+ if (self.fillOverlay.snapTo.x === -1 && cell.selectionBorderLeft) {
3686
+ self.fillOverlay.snapTo.x = cell.x;
3687
+ }
3688
+
3689
+ if (self.fillOverlay.snapTo.y === -1 && cell.selectionBorderTop) {
3690
+ self.fillOverlay.snapTo.y = cell.y;
3691
+ }
3666
3692
  }
3667
3693
  }
3668
3694
  }
@@ -5118,11 +5144,12 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
5118
5144
  }
5119
5145
 
5120
5146
  function drawSelectionBorders() {
5121
- self.ctx.lineWidth = self.style.selectionOverlayBorderWidth;
5122
- self.ctx.strokeStyle = self.style.selectionOverlayBorderColor;
5123
-
5124
5147
  function dsb(c) {
5125
- addBorderLine(c[0], c[1]);
5148
+ if (!self.fillOverlay.handle) {
5149
+ self.ctx.lineWidth = self.style.selectionOverlayBorderWidth;
5150
+ self.ctx.strokeStyle = self.style.selectionOverlayBorderColor;
5151
+ addBorderLine(c[0], c[1]);
5152
+ }
5126
5153
  }
5127
5154
 
5128
5155
  selectionBorders.filter(function (c) {
@@ -5146,10 +5173,11 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
5146
5173
  return c[0].rowIndex < self.frozenRow && c[0].columnIndex >= self.frozenColumn;
5147
5174
  }).forEach(dsb);
5148
5175
  self.ctx.restore();
5176
+ drawFillOverlay();
5149
5177
  }
5150
5178
 
5151
5179
  function drawSelectionHandles() {
5152
- if (self.mobile || self.attributes.allowMovingSelection) {
5180
+ if ((self.mobile || self.attributes.allowMovingSelection) && self.attributes.editable) {
5153
5181
  self.ctx.lineWidth = self.style.selectionHandleBorderWidth;
5154
5182
  self.ctx.strokeStyle = self.style.selectionHandleBorderColor;
5155
5183
  self.ctx.fillStyle = self.style.selectionHandleColor;
@@ -5169,6 +5197,47 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
5169
5197
  }
5170
5198
  }
5171
5199
 
5200
+ function drawFillOverlay() {
5201
+ if (!self.fillOverlay.handle || !self.fillOverlay.snapTo) {
5202
+ return;
5203
+ }
5204
+
5205
+ self.ctx.save();
5206
+ var overlay = self.fillOverlay;
5207
+ var handle = overlay.handle;
5208
+ var toX = overlay.snapTo.x;
5209
+ var toY = overlay.snapTo.y; // The cell that the cursor is moving over. This may be unavailable
5210
+ // when the cursor is outside the grid or is pointing to something else.
5211
+ //
5212
+ // When unavailable, we use the actual position of the cursor to draw
5213
+ // the overlay.
5214
+
5215
+ var snap = overlay.snap; // Calculate the X, Y coordinates of the cursor with snap positions and
5216
+ // the direction of the movement in mind.
5217
+ //
5218
+ // When the movement is horizontal, we get the Y coordinate from the handle,
5219
+ // and vice-versa.
5220
+
5221
+ var cursorX = overlay.direction === 'x' ? snap ? snap.x + (overlay.x < toX ? 0 : snap.width) : overlay.x : handle.x;
5222
+ var cursorY = overlay.direction === undefined || overlay.direction === 'y' ? snap ? snap.y + (overlay.y < toY ? 0 : snap.height) : overlay.y : handle.y; // The final coordinates of the rect. We use 'minX' and 'minY' to avoid
5223
+ // drawing on the frozen area.
5224
+
5225
+ var x = Math.max(Math.min(toX, cursorX), overlay.minX);
5226
+ var y = Math.max(Math.min(toY, cursorY), overlay.minY); // Width and height of the rect are the difference between the
5227
+ // coordinates of both the rect and the cursor. The user may be pointing
5228
+ // behind and/or upwards of the rect, so we need to take that into
5229
+ // account.
5230
+
5231
+ var width = Math.max(toX, cursorX) - x;
5232
+ var height = Math.max(toY, cursorY) - y;
5233
+ self.ctx.strokeStyle = self.style.fillOverlayBorderColor;
5234
+ self.ctx.lineWidth = self.style.fillOverlayBorderWidth;
5235
+ self.ctx.setLineDash([3, 3]);
5236
+ strokeRect(x, y, width, height);
5237
+ self.ctx.setLineDash([]);
5238
+ self.ctx.restore();
5239
+ }
5240
+
5172
5241
  function drawActiveCell() {
5173
5242
  if (!aCell) {
5174
5243
  return;
@@ -5527,6 +5596,12 @@ __webpack_require__.r(__webpack_exports__);
5527
5596
  /*globals define: true, MutationObserver: false, requestAnimationFrame: false, performance: false, btoa: false*/
5528
5597
 
5529
5598
 
5599
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
5600
+
5601
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
5602
+
5603
+ function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
5604
+
5530
5605
  function _createForOfIteratorHelper(o, allowArrayLike) { var it; if (typeof Symbol === "undefined" || o[Symbol.iterator] == null) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = o[Symbol.iterator](); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it["return"] != null) it["return"](); } finally { if (didErr) throw err; } } }; }
5531
5606
 
5532
5607
  function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
@@ -5970,6 +6045,8 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
5970
6045
  y = self.mouse.y,
5971
6046
  cell = self.getCellAt(x, y),
5972
6047
  delta,
6048
+ disallowVerticalAutoScroll = false,
6049
+ disallowHorizontalAutoScroll = false,
5973
6050
  ev = {
5974
6051
  NativeEvent: e,
5975
6052
  cell: cell,
@@ -6199,10 +6276,24 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
6199
6276
  }
6200
6277
  }
6201
6278
  }
6279
+ } else if (self.movingSelectionHandle) {
6280
+ delta = {
6281
+ x: Math.abs(self.dragStart.x - x),
6282
+ y: Math.abs(self.dragStart.y - y)
6283
+ }; // Disallow auto-scroll to the direction that overlay is not
6284
+ // moving towards.
6285
+
6286
+ if (self.fillOverlay.direction === 'y') {
6287
+ disallowHorizontalAutoScroll = true;
6288
+ } else if (self.fillOverlay.direction === 'x') {
6289
+ disallowVerticalAutoScroll = true;
6290
+ }
6291
+ }
6202
6292
 
6203
- if (self.attributes.autoScrollOnMousemove) {
6204
- var movedVertically = delta.y > self.attributes.autoScrollMargin;
6205
- var movedHorizontally = delta.x > self.attributes.autoScrollMargin;
6293
+ if (delta) {
6294
+ if (self.attributes.autoScrollOnMousemove || disallowVerticalAutoScroll || disallowHorizontalAutoScroll) {
6295
+ var movedVertically = !disallowVerticalAutoScroll && delta.y > self.attributes.autoScrollMargin;
6296
+ var movedHorizontally = !disallowHorizontalAutoScroll && delta.x > self.attributes.autoScrollMargin;
6206
6297
  if (movedVertically && !movedHorizontally) self.autoScrollZone(e, -1, y, ctrl);else if (movedHorizontally && !movedVertically) self.autoScrollZone(e, x, -1, ctrl);else if (movedHorizontally && movedVertically) self.autoScrollZone(e, x, y, ctrl);
6207
6298
  } else {
6208
6299
  self.autoScrollZone(e, x, y, ctrl);
@@ -6780,7 +6871,8 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
6780
6871
  var ctrl = e.ctrlKey || e.metaKey,
6781
6872
  move = /-move/.test(self.dragMode),
6782
6873
  freeze = /frozen-row-marker|frozen-column-marker/.test(self.dragMode),
6783
- resize = /-resize/.test(self.dragMode);
6874
+ resize = /-resize/.test(self.dragMode),
6875
+ selectionHandleMove = /selection-handle-br/.test(self.dragMode);
6784
6876
  var onUnhideIndicator = self.hovers && self.hovers.unhideIndicator;
6785
6877
  self.dragStart = overridePos || self.getLayerPos(e);
6786
6878
  self.scrollStart = {
@@ -6790,7 +6882,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
6790
6882
  self.dragStartObject = self.getCellAt(self.dragStart.x, self.dragStart.y);
6791
6883
  self.dragAddToSelection = !self.dragStartObject.selected;
6792
6884
 
6793
- if (!ctrl && !e.shiftKey && !/(vertical|horizontal)-scroll-(bar|box)/.test(self.dragStartObject.context) && self.currentCell && !self.currentCell.isColumnHeader && !move && !freeze && !resize) {
6885
+ if (!ctrl && !e.shiftKey && !/(vertical|horizontal)-scroll-(bar|box)/.test(self.dragStartObject.context) && self.currentCell && !self.currentCell.isColumnHeader && !move && !freeze && !resize && !selectionHandleMove) {
6794
6886
  if (!(self.dragMode == 'row-reorder' && self.isMultiRowsSelected) && !(self.currentCell.hovered && self.hovers.onFilterButton)) {
6795
6887
  self.selections = [];
6796
6888
  self.selectedRows = [];
@@ -6838,6 +6930,31 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
6838
6930
  return;
6839
6931
  }
6840
6932
 
6933
+ if (selectionHandleMove) {
6934
+ self.movingSelectionHandle = true;
6935
+ self.fillOverlay = {
6936
+ handle: {
6937
+ x: self.dragStartObject.x + self.dragStartObject.width / 2,
6938
+ y: self.dragStartObject.y + self.dragStartObject.height / 2
6939
+ },
6940
+ snapTo: {
6941
+ x: -1,
6942
+ y: -1
6943
+ },
6944
+ selection: self.getSelectionBounds()
6945
+ };
6946
+
6947
+ if (self.dispatchEvent('beginselectionhandlemove', {
6948
+ NativeEvent: e
6949
+ })) {
6950
+ return;
6951
+ }
6952
+
6953
+ window.addEventListener('mousemove', self.selectionHandleMove, false);
6954
+ window.addEventListener('mouseup', self.stopSelectionHandleMove, false);
6955
+ return self.selectionHandleMove(e);
6956
+ }
6957
+
6841
6958
  if (move) {
6842
6959
  self.draggingItem = self.dragItem;
6843
6960
  self.movingSelection = self.selections.concat([]);
@@ -7273,17 +7390,22 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
7273
7390
  };
7274
7391
 
7275
7392
  self.pasteData = function (pasteValue, mimeType, startRowIndex, startColIndex) {
7393
+ var minRowsLength = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : 0;
7394
+ var minColumnsLength = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : 0;
7395
+
7276
7396
  if (mimeType === 'text/html' && !(0,_util__WEBPACK_IMPORTED_MODULE_1__.isSupportedHtml)(pasteValue)) {
7277
7397
  console.warn('Unrecognized HTML format. HTML must be a simple table, e.g.: <table><tr><td>data</td></tr></table>.');
7278
7398
  console.warn('Data with the mime type text/html not in this format will not be imported as row data.');
7279
7399
  return;
7280
7400
  }
7281
7401
 
7282
- var schema = self.getSchema();
7283
- var rows = (0,_util__WEBPACK_IMPORTED_MODULE_1__.parseData)(pasteValue, mimeType); // selected cell. This mimics Excel's paste functionality, and works
7402
+ self.selectedRows = [];
7403
+ self.selectedColumns = [];
7404
+ var rows = (0,_util__WEBPACK_IMPORTED_MODULE_1__.parseData)(pasteValue, mimeType);
7405
+ var columnsLength = rows[0].length; // selected cell. This mimics Excel's paste functionality, and works
7284
7406
  // as a poor-man's fill-down.
7285
7407
 
7286
- if (rows.length === 1 && rows[0].length === 1) {
7408
+ if (rows.length === 1 && columnsLength === 1 && minRowsLength <= 1 && minColumnsLength <= 1) {
7287
7409
  var cellData = rows[0][0].value.map(function (item) {
7288
7410
  return item.value;
7289
7411
  }).join();
@@ -7291,66 +7413,169 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
7291
7413
  data[rowIndex][colName] = cellData;
7292
7414
  });
7293
7415
  } else {
7294
- var selections = [];
7295
- self.selectedRows = [];
7296
- self.selectedColumns = [];
7416
+ var direction = null;
7417
+
7418
+ if (minRowsLength > rows.length && minColumnsLength > columnsLength) {
7419
+ direction = 'both';
7420
+ } else if (minRowsLength > rows.length) {
7421
+ direction = 'vertical';
7422
+ } else if (minColumnsLength > columnsLength) {
7423
+ direction = 'horizontal';
7424
+ }
7425
+
7426
+ self.insert({
7427
+ rows: rows,
7428
+ startRowIndex: startRowIndex,
7429
+ startColumnIndex: startColIndex,
7430
+ minRowsLength: minRowsLength,
7431
+ minColumnsLength: minColumnsLength,
7432
+ reverseRows: false,
7433
+ reverseColumns: false,
7434
+ clearSelections: true,
7435
+ alwaysFilling: false,
7436
+ direction: direction
7437
+ });
7438
+ } // selections is a sparse array, so we condense:
7297
7439
 
7298
- for (var rowIndex = 0; rowIndex < rows.length; rowIndex++) {
7299
- // Rows may have been moved by user, so get the actual row index
7300
- // (instead of the row index at which the row is rendered):
7301
- var realRowIndex = self.orders.rows[startRowIndex + rowIndex];
7302
- var cells = rows[rowIndex];
7303
- var existingRowData = self.viewData[realRowIndex];
7304
- var newRowData = Object.assign({}, existingRowData);
7440
+
7441
+ var affectedCells = [];
7442
+ self.selections.forEach(function (row, rowIndex) {
7443
+ if (rowIndex === undefined) return;
7444
+ row.forEach(function (columnIndex) {
7445
+ affectedCells.push([rowIndex, columnIndex, self.getBoundRowIndexFromViewRowIndex(rowIndex), self.getBoundColumnIndexFromViewColumnIndex(columnIndex)]);
7446
+ });
7447
+ });
7448
+ self.dispatchEvent('afterpaste', {
7449
+ cells: affectedCells
7450
+ });
7451
+ return rows.length;
7452
+ };
7453
+
7454
+ self.insert = function (_ref) {
7455
+ var _ref$rows = _ref.rows,
7456
+ rows = _ref$rows === void 0 ? [] : _ref$rows,
7457
+ _ref$startRowIndex = _ref.startRowIndex,
7458
+ startRowIndex = _ref$startRowIndex === void 0 ? 0 : _ref$startRowIndex,
7459
+ _ref$startColumnIndex = _ref.startColumnIndex,
7460
+ startColumnIndex = _ref$startColumnIndex === void 0 ? 0 : _ref$startColumnIndex,
7461
+ _ref$minRowsLength = _ref.minRowsLength,
7462
+ minRowsLength = _ref$minRowsLength === void 0 ? 0 : _ref$minRowsLength,
7463
+ _ref$minColumnsLength = _ref.minColumnsLength,
7464
+ minColumnsLength = _ref$minColumnsLength === void 0 ? 0 : _ref$minColumnsLength,
7465
+ _ref$reverseRows = _ref.reverseRows,
7466
+ reverseRows = _ref$reverseRows === void 0 ? false : _ref$reverseRows,
7467
+ _ref$reverseColumns = _ref.reverseColumns,
7468
+ reverseColumns = _ref$reverseColumns === void 0 ? false : _ref$reverseColumns,
7469
+ _ref$clearSelections = _ref.clearSelections,
7470
+ clearSelections = _ref$clearSelections === void 0 ? false : _ref$clearSelections,
7471
+ _ref$alwaysFilling = _ref.alwaysFilling,
7472
+ alwaysFilling = _ref$alwaysFilling === void 0 ? false : _ref$alwaysFilling,
7473
+ _ref$direction = _ref.direction,
7474
+ direction = _ref$direction === void 0 ? 'both' : _ref$direction;
7475
+ var schema = self.getSchema();
7476
+ var rowsLength = Math.max(rows.length, minRowsLength);
7477
+ var fillCellCallback = self.fillCellCallback;
7478
+ var selections = clearSelections ? [] : self.selections;
7479
+ var filledCells = [];
7480
+
7481
+ for (var rowPosReal = 0, rowDataPos = 0; rowPosReal < rowsLength; rowPosReal++, rowDataPos++) {
7482
+ if (rowDataPos >= rows.length) {
7483
+ rowDataPos = 0;
7484
+ }
7485
+
7486
+ var fillingRow = rowPosReal >= rows.length;
7487
+ var rowPosition = reverseRows ? rowsLength - rowPosReal - 1 : rowPosReal; // Rows may have been moved by user, so get the actual row index
7488
+ // (instead of the row index at which the row is rendered):
7489
+
7490
+ var realRowIndex = self.orders.rows[startRowIndex + rowPosition];
7491
+ var cells = rows[rowDataPos];
7492
+ var cellsLength = Math.max(cells.length, minColumnsLength);
7493
+ var existingRowData = self.viewData[realRowIndex];
7494
+ var newRowData = Object.assign({}, existingRowData);
7495
+ var fillArgs = fillCellCallback ? {
7496
+ rows: rows,
7497
+ direction: direction,
7498
+ rowData: newRowData,
7499
+ existingRowData: existingRowData,
7500
+ rowIndex: realRowIndex,
7501
+ rowOffset: rowDataPos,
7502
+ cells: cells,
7503
+ reversed: direction === 'horizontal' ? reverseColumns : reverseRows,
7504
+ isFillingRow: fillingRow || alwaysFilling,
7505
+ fillingRowPosition: alwaysFilling ? rowPosReal : fillingRow ? rowPosReal - rows.length : -1,
7506
+ fillingRowLength: alwaysFilling ? rowsLength : fillingRow ? rowsLength - rows.length : -1
7507
+ } : undefined;
7508
+ self.selectedRows.push(realRowIndex);
7509
+
7510
+ if (selections[realRowIndex] === undefined) {
7305
7511
  selections[realRowIndex] = [];
7306
- self.selectedRows.push(realRowIndex);
7512
+ }
7307
7513
 
7308
- for (var colIndex = 0; colIndex < cells.length; colIndex++) {
7309
- var column = schema[startColIndex + colIndex];
7514
+ for (var colPosReal = 0, cellDataPos = 0; colPosReal < cellsLength; colPosReal++, cellDataPos++) {
7515
+ if (cellDataPos >= cells.length) {
7516
+ cellDataPos = 0;
7517
+ }
7310
7518
 
7311
- if (!column) {
7312
- console.warn('Paste data exceeded grid bounds. Skipping.');
7313
- continue;
7314
- }
7519
+ var fillingColumn = colPosReal >= cells.length;
7520
+ var colPosition = reverseColumns ? cellsLength - colPosReal - 1 : colPosReal;
7521
+ var columnIndex = startColumnIndex + colPosition;
7522
+ var column = schema[columnIndex];
7315
7523
 
7316
- var columnName = column.name;
7317
- var cellData = cells[colIndex].value.map(function (item) {
7524
+ if (!column) {
7525
+ console.warn('Paste data exceeded grid bounds. Skipping.');
7526
+ continue;
7527
+ }
7528
+
7529
+ var columnName = column.name;
7530
+ var cellData = cells[cellDataPos];
7531
+
7532
+ if (cellData && cellData.value) {
7533
+ cellData = cellData.value.map(function (item) {
7318
7534
  return item.value;
7319
7535
  }).join('');
7536
+ }
7320
7537
 
7321
- if (cellData === undefined || cellData === null) {
7322
- newRowData[columnName] = existingRowData[columnName];
7323
- continue;
7324
- }
7538
+ var existingCellData = existingRowData[columnName];
7325
7539
 
7326
- selections[realRowIndex].push(startColIndex + colIndex);
7327
- newRowData[columnName] = cellData;
7328
- if (self.selectedColumns.indexOf(startColIndex + colIndex) === -1) self.selectedColumns.push(startColIndex + colIndex);
7540
+ if (fillCellCallback && (fillingColumn || fillingRow || alwaysFilling)) {
7541
+ newRowData[columnName] = fillCellCallback(_objectSpread(_objectSpread({}, fillArgs), {}, {
7542
+ column: column,
7543
+ columnIndex: columnIndex,
7544
+ columnOffset: cellDataPos,
7545
+ newCellData: cellData,
7546
+ existingCellData: existingCellData,
7547
+ isFillingColumn: fillingColumn || alwaysFilling,
7548
+ fillingColumnPosition: alwaysFilling ? colPosReal : fillingColumn ? colPosReal - cells.length : -1,
7549
+ fillingColumnLength: alwaysFilling ? cellsLength : fillingColumn ? cellsLength - cells.length : -1
7550
+ }));
7551
+ } else {
7552
+ newRowData[columnName] = cellData === undefined || cellData === null ? existingCellData : cellData;
7329
7553
  }
7330
7554
 
7331
- self.originalData[self.boundRowIndexMap.get(realRowIndex)] = newRowData; // Update view date here to avoid a full refresh of `viewData`.
7332
- // To stay in line with Excel and Google Sheet behaviour,
7333
- // don't perform a full refresh (and filter/sort results)
7334
- // as this would make any pasted values disappear and/or suddenly change position.
7555
+ selections[realRowIndex].push(columnIndex);
7556
+
7557
+ if (alwaysFilling || fillingRow || fillingColumn) {
7558
+ filledCells.push([realRowIndex, columnIndex, self.getBoundRowIndexFromViewRowIndex(realRowIndex), self.getBoundColumnIndexFromViewColumnIndex(columnIndex)]);
7559
+ }
7335
7560
 
7336
- self.viewData[realRowIndex] = newRowData;
7561
+ if (self.selectedColumns.indexOf(columnIndex) === -1) self.selectedColumns.push(columnIndex);
7337
7562
  }
7338
7563
 
7339
- self.selections = selections;
7340
- } // selections is a sparse array, so we condense:
7564
+ self.originalData[self.boundRowIndexMap.get(realRowIndex)] = newRowData; // Update view date here to avoid a full refresh of `viewData`.
7565
+ // To stay in line with Excel and Google Sheet behaviour,
7566
+ // don't perform a full refresh (and filter/sort results)
7567
+ // as this would make any pasted values disappear and/or suddenly change position.
7341
7568
 
7569
+ self.viewData[realRowIndex] = newRowData;
7570
+ }
7342
7571
 
7343
- var affectedCells = [];
7344
- self.selections.forEach(function (row, rowIndex) {
7345
- if (rowIndex === undefined) return;
7346
- row.forEach(function (columnIndex) {
7347
- affectedCells.push([rowIndex, columnIndex, self.getBoundRowIndexFromViewRowIndex(rowIndex), self.getBoundColumnIndexFromViewColumnIndex(columnIndex)]);
7572
+ self.selections = selections;
7573
+
7574
+ if (filledCells.length > 0 || alwaysFilling) {
7575
+ self.dispatchEvent('afterfill', {
7576
+ filledCells: filledCells
7348
7577
  });
7349
- });
7350
- self.dispatchEvent('afterpaste', {
7351
- cells: affectedCells
7352
- });
7353
- return rows.length;
7578
+ }
7354
7579
  };
7355
7580
 
7356
7581
  self.getNextVisibleColumnIndex = function (visibleColumnIndex) {
@@ -7379,6 +7604,24 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
7379
7604
  return -1;
7380
7605
  };
7381
7606
 
7607
+ self.getSelectionIndex = function () {
7608
+ for (var rowIndex = 0, len = self.selections.length; rowIndex < len; rowIndex++) {
7609
+ var row = self.selections[rowIndex];
7610
+
7611
+ if (row) {
7612
+ if (row[0] === undefined) break;
7613
+ return {
7614
+ row: rowIndex,
7615
+ column: row[0] < 0 ? row[1] : row[0],
7616
+ rowLength: len - rowIndex,
7617
+ columnLength: row.length - (row[0] < 0 ? 1 : 0)
7618
+ };
7619
+ }
7620
+ }
7621
+
7622
+ return null;
7623
+ };
7624
+
7382
7625
  self.paste = function (event) {
7383
7626
  if (!self.attributes.editable) {
7384
7627
  return;
@@ -7412,24 +7655,14 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
7412
7655
  return;
7413
7656
  }
7414
7657
 
7415
- var itemToPaste = pasteableItems[0];
7416
- var startCell = [];
7417
-
7418
- for (var rowIndex = 0, len = self.selections.length; rowIndex < len; rowIndex++) {
7419
- var row = self.selections[rowIndex];
7420
-
7421
- if (row) {
7422
- if (row[0] === undefined) return;
7423
- startCell = [rowIndex, row[0] < 0 ? row[1] : row[0]];
7424
- break;
7425
- }
7426
- } // itemToPaste is cleared once accessed (getData or getAsString),
7658
+ var selectionIndex = self.getSelectionIndex();
7659
+ if (!selectionIndex) return;
7660
+ var itemToPaste = pasteableItems[0]; // itemToPaste is cleared once accessed (getData or getAsString),
7427
7661
  // so we need to store the type here, before reading its value:
7428
7662
 
7429
-
7430
7663
  var pasteType = itemToPaste.type;
7431
7664
  itemToPaste.getAsString(function (pasteValue) {
7432
- self.pasteData(pasteValue, pasteType, startCell[0], startCell[1]);
7665
+ self.pasteData(pasteValue, pasteType, selectionIndex.row, selectionIndex.column, selectionIndex.rowLength, selectionIndex.columnLength);
7433
7666
  self.draw();
7434
7667
  });
7435
7668
  };
@@ -7473,6 +7706,145 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
7473
7706
  event.preventDefault();
7474
7707
  };
7475
7708
 
7709
+ self.selectionHandleMove = function (e) {
7710
+ if (!self.movingSelectionHandle) {
7711
+ return;
7712
+ }
7713
+
7714
+ var clippingRect = self.getClippingRect(e);
7715
+ var rowIndex = self.currentCell.rowIndex;
7716
+ var columnIndex = self.currentCell.columnIndex;
7717
+ var isInSelectionBounds = rowIndex >= -1 && columnIndex >= -1 && self.fillOverlay.selection.left <= columnIndex && self.fillOverlay.selection.right >= columnIndex && self.fillOverlay.selection.top <= rowIndex && self.fillOverlay.selection.bottom >= rowIndex;
7718
+ self.fillOverlay.minX = clippingRect.x;
7719
+ self.fillOverlay.minY = clippingRect.y;
7720
+ self.fillOverlay.x = Math.max(clippingRect.x, e.clientX);
7721
+ self.fillOverlay.y = Math.max(clippingRect.y, e.clientY); // If we are in the selection bounds, allow user to change directions.
7722
+
7723
+ if (isInSelectionBounds) {
7724
+ self.fillOverlay.lastInBoundsLocation = {
7725
+ x: e.clientX,
7726
+ y: e.clientY
7727
+ };
7728
+ } else if (self.fillOverlay.lastInBoundsLocation || !self.fillOverlay.direction) {
7729
+ var lastInBoundsLocation = self.fillOverlay.lastInBoundsLocation;
7730
+ self.fillOverlay.lastInBoundsLocation = undefined;
7731
+ var x = lastInBoundsLocation ? lastInBoundsLocation.x : self.fillOverlay.handle.x;
7732
+ var y = lastInBoundsLocation ? lastInBoundsLocation.y : self.fillOverlay.handle.y;
7733
+ var dx = Math.abs(e.clientX - x);
7734
+ var dy = Math.abs(e.clientY - y);
7735
+
7736
+ if (dx > 5 || dy > 5) {
7737
+ self.fillOverlay.direction = dx > dy ? 'x' : 'y';
7738
+ }
7739
+ }
7740
+
7741
+ if (rowIndex >= 0) {
7742
+ self.fillOverlay.rowIndex = rowIndex;
7743
+ }
7744
+
7745
+ if (columnIndex >= 0) {
7746
+ self.fillOverlay.columnIndex = columnIndex;
7747
+
7748
+ if (rowIndex === -1 && self.visibleRows.length) {
7749
+ self.fillOverlay.rowIndex = self.visibleRows[0];
7750
+ }
7751
+ }
7752
+
7753
+ if (rowIndex >= -1 && columnIndex >= -1) {
7754
+ self.fillOverlay.snap = self.currentCell;
7755
+ } else {
7756
+ self.fillOverlay.snap = undefined;
7757
+ }
7758
+ };
7759
+
7760
+ self.stopSelectionHandleMove = function (e) {
7761
+ if (!self.fillOverlay.handle) {
7762
+ return false;
7763
+ }
7764
+
7765
+ self.ignoreNextClick = true;
7766
+ window.removeEventListener('mousemove', self.selectionHandleMove, false);
7767
+ window.removeEventListener('mouseup', self.stopSelectionHandleMove, false);
7768
+ var overlay = self.fillOverlay;
7769
+ var selectionIndex = self.getSelectionIndex();
7770
+ var bounds = overlay.selection;
7771
+ if (!selectionIndex) return;
7772
+ self.movingSelectionHandle = undefined;
7773
+ self.fillOverlay = {};
7774
+
7775
+ if (overlay.rowIndex >= 0 && overlay.columnIndex >= 0) {
7776
+ var boundsOld = _objectSpread({}, bounds);
7777
+
7778
+ var isVertical = overlay.direction === 'y';
7779
+ var isHorizontal = overlay.direction === 'x';
7780
+ var startRow,
7781
+ rowLength,
7782
+ startColumn,
7783
+ columnLength,
7784
+ reverseVertically = false,
7785
+ reverseHorizontally = false;
7786
+
7787
+ if (isVertical) {
7788
+ if (overlay.rowIndex < bounds.top) {
7789
+ bounds.top = overlay.rowIndex;
7790
+ reverseVertically = true;
7791
+ } else if (overlay.rowIndex > bounds.bottom) {
7792
+ bounds.bottom = overlay.rowIndex;
7793
+ }
7794
+
7795
+ startRow = bounds.top < boundsOld.top ? bounds.top : boundsOld.bottom + 1;
7796
+ rowLength = bounds.top < boundsOld.top ? boundsOld.top - bounds.top : bounds.bottom - boundsOld.bottom;
7797
+ startColumn = selectionIndex.column;
7798
+ columnLength = selectionIndex.columnLength;
7799
+ } else if (isHorizontal) {
7800
+ if (overlay.columnIndex < bounds.left) {
7801
+ bounds.left = overlay.columnIndex;
7802
+ reverseHorizontally = true;
7803
+ } else if (overlay.columnIndex > bounds.right) {
7804
+ bounds.right = overlay.columnIndex;
7805
+ }
7806
+
7807
+ startColumn = bounds.left < boundsOld.left ? bounds.left : boundsOld.right + 1;
7808
+ columnLength = bounds.left < boundsOld.left ? boundsOld.left - bounds.left : bounds.right - boundsOld.right;
7809
+ startRow = selectionIndex.row;
7810
+ rowLength = selectionIndex.rowLength;
7811
+ }
7812
+
7813
+ if (bounds.left <= bounds.right && bounds.top <= bounds.bottom && (bounds.left < boundsOld.left || bounds.top < boundsOld.top || bounds.right > boundsOld.right || bounds.bottom > boundsOld.bottom)) {
7814
+ var schema = self.getSchema();
7815
+ var rows = [];
7816
+
7817
+ for (var rowIndex = 0; rowIndex < Math.min(rowLength, selectionIndex.rowLength); rowIndex++) {
7818
+ var rowData = self.viewData[selectionIndex.row + rowIndex];
7819
+ rows[rowIndex] = [];
7820
+
7821
+ for (var columnIndex = 0; columnIndex < Math.min(columnLength, selectionIndex.columnLength); columnIndex++) {
7822
+ var column = schema[selectionIndex.column + columnIndex];
7823
+ if (!column) continue;
7824
+ var cellData = rowData[column.name];
7825
+ rows[rowIndex][columnIndex] = cellData;
7826
+ }
7827
+ }
7828
+
7829
+ self.insert({
7830
+ rows: rows,
7831
+ startRowIndex: startRow,
7832
+ startColumnIndex: startColumn,
7833
+ minRowsLength: rowLength,
7834
+ minColumnsLength: columnLength,
7835
+ reverseRows: reverseVertically,
7836
+ reverseColumns: reverseHorizontally,
7837
+ clearSelections: false,
7838
+ alwaysFilling: true,
7839
+ direction: isHorizontal ? 'horizontal' : 'vertical'
7840
+ });
7841
+ self.draw();
7842
+ }
7843
+ }
7844
+
7845
+ return true;
7846
+ };
7847
+
7476
7848
  return;
7477
7849
  }
7478
7850
 
@@ -7885,6 +8257,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
7885
8257
  self.selections = [];
7886
8258
  self.selectedRows = [];
7887
8259
  self.selectedColumns = [];
8260
+ self.fillOverlay = {};
7888
8261
  self.filterable = {
7889
8262
  rows: [],
7890
8263
  columns: []
@@ -9973,6 +10346,14 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
9973
10346
  self.cellGridAttributes = value;
9974
10347
  }
9975
10348
  });
10349
+ Object.defineProperty(self.intf, 'fillCellCallback', {
10350
+ get: function get() {
10351
+ return self.fillCellCallback;
10352
+ },
10353
+ set: function setFillCellCallback(value) {
10354
+ self.fillCellCallback = value;
10355
+ }
10356
+ });
9976
10357
  Object.defineProperty(self.intf, 'ctx', {
9977
10358
  get: function get() {
9978
10359
  return self.ctx;
@@ -10414,7 +10795,7 @@ if (window && !window.canvasDatagrid && !window.require && // Present to exclude
10414
10795
  function canvasDatagrid(args) {
10415
10796
  args = args || {};
10416
10797
  var i,
10417
- tKeys = ['style', 'formatters', 'sorters', 'filters', 'treeGridAttributes', 'cellGridAttributes', 'data', 'schema'];
10798
+ tKeys = ['style', 'formatters', 'sorters', 'filters', 'treeGridAttributes', 'cellGridAttributes', 'fillCellCallback', 'data', 'schema'];
10418
10799
 
10419
10800
  if (window.customElements) {
10420
10801
  i = document.createElement('canvas-datagrid');
@@ -11354,8 +11735,8 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
11354
11735
  * @memberof canvasDatagrid
11355
11736
  * @name hideColumns
11356
11737
  * @method
11357
- * @param {number} beginColumnOrderIndex
11358
- * @param {number} [endColumnOrderIndex]
11738
+ * @param {number} beginColumnOrderIndex The begin column order index
11739
+ * @param {number} [endColumnOrderIndex] The end column order index
11359
11740
  */
11360
11741
 
11361
11742
 
@@ -11393,8 +11774,8 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
11393
11774
  * @memberof canvasDatagrid
11394
11775
  * @name unhideColumns
11395
11776
  * @method
11396
- * @param {number} beginColumnOrderIndex
11397
- * @param {number} [endColumnOrderIndex]
11777
+ * @param {number} beginColumnOrderIndex The begin column order index
11778
+ * @param {number} [endColumnOrderIndex] The end column order index
11398
11779
  */
11399
11780
 
11400
11781
 
@@ -11421,8 +11802,8 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
11421
11802
  * @memberof canvasDatagrid
11422
11803
  * @name hideRows
11423
11804
  * @method
11424
- * @param {number} beginRowIndex
11425
- * @param {number} endRowIndex
11805
+ * @param {number} beginRowIndex The begin row index
11806
+ * @param {number} endRowIndex The end row index
11426
11807
  */
11427
11808
 
11428
11809
 
@@ -11434,8 +11815,8 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
11434
11815
  * @memberof canvasDatagrid
11435
11816
  * @name unhideRows
11436
11817
  * @method
11437
- * @param {number} beginRowIndex
11438
- * @param {number} endRowIndex
11818
+ * @param {number} beginRowIndex The begin row index
11819
+ * @param {number} endRowIndex The end row index
11439
11820
  */
11440
11821
 
11441
11822