VaKeR CYBER ARMY
Logo of a company Server : Apache/2.4.41 (Ubuntu)
System : Linux absol.cf 5.4.0-198-generic #218-Ubuntu SMP Fri Sep 27 20:18:53 UTC 2024 x86_64
User : www-data ( 33)
PHP Version : 7.4.33
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Directory :  /var/www/html/libs/absol-full/dist/js/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /var/www/html/libs/absol-full/dist/js/mdls__absol-acomp__js__dynamictable__DTTable.js
/*** module: node_modules/absol-acomp/js/dynamictable/DTTable.js ***/
"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;

var _DTHead = _interopRequireDefault(require("./DTHead"));

var _DTBody = _interopRequireDefault(require("./DTBody"));

var _ACore = require("../../ACore");


/***
 *
 * @param {DynamicTable} elt
 * @param {} data
 * @constructor
 */
function DTTable(wrapper, data) {
  this.wrapper = wrapper;
  this._elt = null;
  this._fixedXElt = null;
  this._fixedXYElt = null;
  this._fixedYElt = null;
  /***
   *
   * @type {DTDataTable|null|*|string}
   */

  this.adapter = this.wrapper._adapter;
  this.data = data;
  this.header = new _DTHead.default(this, this.data.head);
  this.body = new _DTBody.default(this, this.data.body);
}

DTTable.prototype.updateCopyEltSize = function () {
  if (!this._fixedYElt) return;

  var bound = this._elt.getBoundingClientRect();

  this._fixedYElt.parentElement.addStyle('width', bound.width + 'px');

  this.header.updateCopyEltSize();
  this.body.updateCopyEltSize();
};

DTTable.prototype.revokeResource = function () {
  this.wrapper = null;
  this._elt = null;
  this.adapter = null;
  this.data = null;
  this.body.revokeResource();
};

Object.defineProperty(DTTable.prototype, 'elt', {
  get: function () {
    if (this._elt) return this._elt;
    this._elt = (0, _ACore._)({
      tag: 'table',
      class: 'as-dynamic-table',
      child: [this.header.copyElt, this.body.elt]
    });
    return this._elt;
  }
});
Object.defineProperty(DTTable.prototype, 'fixedXElt', {
  get: function () {
    if (this._fixedXElt) return this._fixedXElt;
    this._fixedXElt = (0, _ACore._)({
      elt: this.elt.cloneNode(false),
      class: 'as-fixed-x',
      child: [this.header.fixedXElt, this.body.fixedXElt]
    });
    return this._fixedXElt;
  }
});
Object.defineProperty(DTTable.prototype, 'fixedYElt', {
  get: function () {
    if (this._fixedYElt) return this._fixedYElt;
    this._fixedYElt = (0, _ACore._)({
      elt: this.elt.cloneNode(false),
      class: 'as-dt-fixed-y',
      child: [this.header.elt]
    });
    return this._fixedYElt;
  }
});
Object.defineProperty(DTTable.prototype, 'fixedXYElt', {
  get: function () {
    if (this._fixedXYElt) return this._fixedXYElt;
    this._fixedXYElt = (0, _ACore._)({
      elt: this.elt.cloneNode(false),
      class: 'as-dt-fixed-y',
      child: [this.header.fixedXYElt]
    });
    return this._fixedXYElt;
  }
});
var _default = DTTable;
exports.default = _default;

VaKeR 2022