How to use the handsontable/helpers/dom/element.removeClass function in handsontable

To help you get started, we’ve selected a few handsontable examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Graphite-Docs / graphite / node_modules / handsontable-pro / es / plugins / nestedHeaders / nestedHeaders.js View on Github external
return function (index, TH) {
        TH.removeAttribute('colspan');
        removeClass(TH, 'hiddenHeader');

        // header row is the index of header row counting from the top (=> positive values)
        if (_this.colspanArray[headerRow][index] && _this.colspanArray[headerRow][index].colspan) {
          var colspan = _this.colspanArray[headerRow][index].colspan;
          var fixedColumnsLeft = _this.hot.getSettings().fixedColumnsLeft || 0;
          var topLeftCornerOverlay = _this.hot.view.wt.wtOverlays.topLeftCornerOverlay;
          var leftOverlay = _this.hot.view.wt.wtOverlays.leftOverlay;
          var isInTopLeftCornerOverlay = topLeftCornerOverlay ? topLeftCornerOverlay.clone.wtTable.THEAD.contains(TH) : false;
          var isInLeftOverlay = leftOverlay ? leftOverlay.clone.wtTable.THEAD.contains(TH) : false;

          if (colspan > 1) {
            TH.setAttribute('colspan', isInTopLeftCornerOverlay || isInLeftOverlay ? Math.min(colspan, fixedColumnsLeft - index) : colspan);
          }

          if (isInTopLeftCornerOverlay || isInLeftOverlay && index === fixedColumnsLeft - 1) {
            addClass(TH, 'overlayEdge');
github Graphite-Docs / graphite / node_modules / handsontable-pro / src / plugins / nestedHeaders / nestedHeaders.js View on Github external
return function(index, TH) {
      TH.removeAttribute('colspan');
      removeClass(TH, 'hiddenHeader');

      // header row is the index of header row counting from the top (=> positive values)
      if (_this.colspanArray[headerRow][index] && _this.colspanArray[headerRow][index].colspan) {
        let colspan = _this.colspanArray[headerRow][index].colspan;
        let fixedColumnsLeft = _this.hot.getSettings().fixedColumnsLeft || 0;
        let topLeftCornerOverlay = _this.hot.view.wt.wtOverlays.topLeftCornerOverlay;
        let leftOverlay = _this.hot.view.wt.wtOverlays.leftOverlay;
        let isInTopLeftCornerOverlay = topLeftCornerOverlay ? topLeftCornerOverlay.clone.wtTable.THEAD.contains(TH) : false;
        let isInLeftOverlay = leftOverlay ? leftOverlay.clone.wtTable.THEAD.contains(TH) : false;

        if (colspan > 1) {
          TH.setAttribute('colspan', isInTopLeftCornerOverlay || isInLeftOverlay ? Math.min(colspan, fixedColumnsLeft - index) : colspan);
        }

        if (isInTopLeftCornerOverlay || isInLeftOverlay && index === fixedColumnsLeft - 1) {
          addClass(TH, 'overlayEdge');
github Graphite-Docs / graphite / node_modules / handsontable-pro / es / plugins / nestedHeaders / nestedHeaders.js View on Github external
arrayEach(listTH, function (TH, index, array) {
            if (TH === void 0) {
              return false;
            }

            if (!selectionByHeader && level < levelLimit || selectionByHeader && !isInSelection) {
              if (hasClass(TH, classHighlight)) {
                removeClass(TH, classHighlight);
              }
            } else if (!hasClass(TH, classHighlight)) {
              addClass(TH, classHighlight);
            }
          });
        };
github Graphite-Docs / graphite / node_modules / handsontable-pro / src / plugins / nestedHeaders / nestedHeaders.js View on Github external
arrayEach(listTH, (TH, index, array) => {
          if (TH === void 0) {
            return false;
          }

          if ((!selectionByHeader && level < levelLimit) || (selectionByHeader && !isInSelection)) {
            if (hasClass(TH, classHighlight)) {
              removeClass(TH, classHighlight);
            }

          } else if (!hasClass(TH, classHighlight)) {
            addClass(TH, classHighlight);
          }
        });
      }
github Graphite-Docs / graphite / node_modules / handsontable-pro / src / plugins / hiddenRows / hiddenRows.js View on Github external
onAfterGetRowHeader(row, th) {
    let tr = th.parentNode;

    if (tr) {
      if (this.isHidden(row)) {
        addClass(tr, 'hide');
      } else {
        removeClass(tr, 'hide');
      }
    }

    let firstSectionHidden = true;
    let i = row - 1;

    do {
      if (!this.isHidden(i)) {
        firstSectionHidden = false;
        break;
      }
      i--;
    } while (i >= 0);

    if (firstSectionHidden) {
      addClass(th, 'firstVisibleRow');
github Graphite-Docs / graphite / node_modules / handsontable-pro / es / plugins / filters / filters.js View on Github external
value: function onAfterGetColHeader(col, TH) {
      var physicalColumn = this.t.toPhysicalColumn(col);

      if (this.enabled && this.conditionCollection.hasConditions(physicalColumn)) {
        addClass(TH, 'htFiltersActive');
      } else {
        removeClass(TH, 'htFiltersActive');
      }
    }
github Graphite-Docs / graphite / node_modules / handsontable-pro / src / plugins / filters / filters.js View on Github external
onAfterGetColHeader(col, TH) {
    const physicalColumn = this.t.toPhysicalColumn(col);

    if (this.enabled && this.conditionCollection.hasConditions(physicalColumn)) {
      addClass(TH, 'htFiltersActive');
    } else {
      removeClass(TH, 'htFiltersActive');
    }
  }
github Graphite-Docs / graphite / node_modules / handsontable-pro / es / plugins / hiddenRows / hiddenRows.js View on Github external
value: function onAfterGetRowHeader(row, th) {
      var tr = th.parentNode;

      if (tr) {
        if (this.isHidden(row)) {
          addClass(tr, 'hide');
        } else {
          removeClass(tr, 'hide');
        }
      }

      var firstSectionHidden = true;
      var i = row - 1;

      do {
        if (!this.isHidden(i)) {
          firstSectionHidden = false;
          break;
        }
        i--;
      } while (i >= 0);

      if (firstSectionHidden) {
        addClass(th, 'firstVisibleRow');