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-sheet__js__fragment__dialogs.js
/*** module: node_modules/absol-sheet/js/fragment/dialogs.js ***/
"use strict";

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

var _SCore = require("../dom/SCore");

var _Dom = _interopRequireDefault(require("absol/src/HTML5/Dom"));

require("../../css/dialogs.css");


function selectRowHeight(opt) {
  var okBtn = (0, _SCore._)({
    tag: 'button',
    style: {
      display: 'block',
      width: '80px'
    },
    child: {
      text: "OK"
    }
  });
  var cancelBtn = (0, _SCore._)({
    tag: 'button',
    style: {
      display: 'block',
      width: '80px',
      marginTop: '5px'
    },
    child: {
      text: "Cancel"
    }
  });
  var valueInput = (0, _SCore._)({
    tag: 'input',
    attr: {
      type: 'number',
      step: '0.5',
      min: '0',
      value: opt.value + ''
    },
    style: {
      marginLeft: '5px',
      width: '50px'
    }
  });
  var standardCBx = (0, _SCore._)('checkboxbutton').on('change', function (event) {
    if (this.checked) {
      valueInput.value = opt.standard;
    }
  });
  var windowElt = (0, _SCore._)({
    tag: 'onscreenwindow',
    class: ['asht-window', 'asht-select-row-width-window'],
    style: {
      top: '30vh',
      left: '30vw',
      width: '250px',
      height: '85px',
      zIndex: 1e9
    },
    props: {
      windowTitle: 'Row Height',
      windowIcon: 'span.mdi.mdi-table-row-height'
    },
    child: {
      class: 'asht-select-row-width-window-content',
      style: {
        whiteSpace: 'nowrap'
      },
      child: [{
        style: {
          verticalAlign: 'top',
          display: 'inline-block'
        },
        child: [{
          child: [{
            tag: 'span',
            child: {
              text: "Row Height:"
            }
          }, valueInput]
        }, {
          child: [standardCBx, {
            tag: 'span',
            style: {
              marginLeft: '5px'
            },
            child: {
              text: 'Standard Height'
            }
          }]
        }]
      }, {
        style: {
          verticalAlign: 'top',
          display: 'inline-block',
          marginLeft: '10px'
        },
        child: [okBtn, cancelBtn]
      }]
    }
  });
  var blinkTO = -1;
  var modal = (0, _SCore._)({
    class: 'asht-modal',
    style: {
      zIndex: 1e9
    },
    child: windowElt,
    on: {
      mousedown: function () {
        if (blinkTO >= 0) clearTimeout(blinkTO);
        windowElt.removeClass('as-blink');
      },
      click: function (event) {
        if (event.target === this) {
          windowElt.addClass('as-blink');
          blinkTO = setTimeout(function () {
            blinkTO = -1;
            windowElt.removeClass('as-blink');
          }, 1000);
        }
      }
    }
  });
  modal.addTo(document.body);
  return new Promise(function (resolve, reject) {
    okBtn.once('click', function () {
      modal.remove();
      resolve(parseFloat(valueInput.value));
    });
    cancelBtn.once('click', function () {
      modal.remove();
      reject();
    });
  });
}

VaKeR 2022