![]() 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 : |
/*** module: node_modules/absol-poser/dom/editor/APEditableAnswerCtn.js ***/ "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; require("../../css/editableanswerctn.css"); var _Core = _interopRequireWildcard(require("../Core")); var _Board = _interopRequireDefault(require("absol-acomp/js/Board")); var _BoardTable = require("absol-acomp/js/BoardTable"); var _EventEmitter = require("absol/src/HTML5/EventEmitter"); /*** * @extends AElement * @constructor */ function APEditableAnswerCtn() { this.$editableAnswer = (0, _Core.$)('.ap-editable-answer', this); this.$removeBtn = (0, _Core.$)('.ap-editable-answer-ctn-remove-bt-ctn > button', this).on('click', this.eventHandler.pressRemove); } APEditableAnswerCtn.tag = 'APEditableAnswerCtn'.toLowerCase(); APEditableAnswerCtn.render = function () { return (0, _Core._)({ tag: _Board.default.tag, extendEvent: ['pressremove'], class: 'ap-editable-answer-ctn', child: [{ class: ['ap-editable-answer-ctn-drag-zone', _BoardTable.DRAG_ZONE_CLASS_NAME], child: '<i class="material-icons drag-icon-button">drag_indicator</i>', on: { contextmenu: function (event) { if ((0, _EventEmitter.isMouseRight)(event)) event.preventDefault(); } } }, { class: 'ap-editable-answer' }, { class: 'ap-editable-answer-ctn-remove-bt-ctn', child: { tag: 'button', class: 'ap-button', child: 'span.mdi.mdi-close' } }] }); }; APEditableAnswerCtn.prototype.addChild = function (child) { this.$editableAnswer.selfReplace(child); this.$editableAnswer = child; }; APEditableAnswerCtn.eventHandler = {}; APEditableAnswerCtn.eventHandler.pressRemove = function (event) { this.emit('pressremove', { type: 'pressremove', target: this, originalEvent: event }, this); }; _Core.default.install(APEditableAnswerCtn); var _default = APEditableAnswerCtn; exports.default = _default;