mirror of
https://github.com/esiur/iui.git
synced 2025-05-06 06:42:58 +00:00
1.2.3
This commit is contained in:
parent
c980418197
commit
8070c96095
58
build/iui.js
58
build/iui.js
@ -2370,7 +2370,7 @@ var _default = _IUI.IUI.module( /*#__PURE__*/function (_IUIElement) {
|
|||||||
return _IUI.IUI.create(this);
|
return _IUI.IUI.create(this);
|
||||||
|
|
||||||
case 16:
|
case 16:
|
||||||
_IUI.IUI.bind(this, true, "include:" + src, _IUI.IUI.extend(this._i__bindings.scope, this.scope, true));
|
_IUI.IUI.bind(this, true, "include:" + src, this.scope);
|
||||||
|
|
||||||
this.refs._build();
|
this.refs._build();
|
||||||
|
|
||||||
@ -9220,12 +9220,20 @@ var _class, _temp;
|
|||||||
|
|
||||||
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
||||||
|
|
||||||
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
||||||
|
|
||||||
|
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
||||||
|
|
||||||
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
||||||
|
|
||||||
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
||||||
|
|
||||||
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
||||||
|
|
||||||
|
function _get(target, property, receiver) { if (typeof Reflect !== "undefined" && Reflect.get) { _get = Reflect.get; } else { _get = function _get(target, property, receiver) { var base = _superPropBase(target, property); if (!base) return; var desc = Object.getOwnPropertyDescriptor(base, property); if (desc.get) { return desc.get.call(receiver); } return desc.value; }; } return _get(target, property, receiver || target); }
|
||||||
|
|
||||||
|
function _superPropBase(object, property) { while (!Object.prototype.hasOwnProperty.call(object, property)) { object = _getPrototypeOf(object); if (object === null) break; } return object; }
|
||||||
|
|
||||||
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
||||||
|
|
||||||
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
||||||
@ -9270,16 +9278,27 @@ var _default = _IUI.IUI.module((_temp = _class = /*#__PURE__*/function (_IUIElem
|
|||||||
|
|
||||||
_createClass(IUIWindow, [{
|
_createClass(IUIWindow, [{
|
||||||
key: "create",
|
key: "create",
|
||||||
value: function create() {
|
value: function () {
|
||||||
var self = this;
|
var _create = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee() {
|
||||||
|
var self, f, b;
|
||||||
|
return regeneratorRuntime.wrap(function _callee$(_context) {
|
||||||
|
while (1) {
|
||||||
|
switch (_context.prev = _context.next) {
|
||||||
|
case 0:
|
||||||
|
_context.next = 2;
|
||||||
|
return _get(_getPrototypeOf(IUIWindow.prototype), "create", this).call(this);
|
||||||
|
|
||||||
|
case 2:
|
||||||
|
//debugger;
|
||||||
|
self = this;
|
||||||
this.tabIndex = 0; // create header
|
this.tabIndex = 0; // create header
|
||||||
|
|
||||||
this._header = document.createElement("div");
|
this._header = document.createElement("div");
|
||||||
this._header.className = this.cssClass + "-header";
|
this._header.className = this.cssClass + "-header";
|
||||||
if (this.draggable) this._header.setAttribute("draggable", true);
|
if (this.draggable) this._header.setAttribute("draggable", true);
|
||||||
var f = this.getElementsByClassName(this.cssClass + "-footer");
|
f = this.getElementsByClassName(this.cssClass + "-footer");
|
||||||
this._footer = f.length > 0 ? f[0] : null;
|
this._footer = f.length > 0 ? f[0] : null;
|
||||||
var b = this.getElementsByClassName(this.cssClass + "-body"); //this.body = b.length > 0 ? b[0]: null;
|
b = this.getElementsByClassName(this.cssClass + "-body"); //this.body = b.length > 0 ? b[0]: null;
|
||||||
|
|
||||||
if (b.length == 0) {
|
if (b.length == 0) {
|
||||||
this._body = document.createElement("div");
|
this._body = document.createElement("div");
|
||||||
@ -9290,16 +9309,16 @@ var _default = _IUI.IUI.module((_temp = _class = /*#__PURE__*/function (_IUIElem
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.insertAdjacentElement("afterBegin", this._body);
|
this.insertAdjacentElement("afterBegin", this._body);
|
||||||
} else this._body = b[0];
|
} else this._body = b[0]; //if (this.icon) {
|
||||||
|
|
||||||
|
|
||||||
if (this.icon) {
|
|
||||||
this._icon = document.createElement("div");
|
this._icon = document.createElement("div");
|
||||||
this._icon.className = this.cssClass + "-icon"; //this._icon.src = this.icon;
|
this._icon.className = this.cssClass + "-icon";
|
||||||
|
|
||||||
this._icon.style.setProperty("--icon", "url('".concat(this.icon, "')"));
|
this._icon.style.setProperty("--icon", "url('".concat(this.icon, "')"));
|
||||||
|
|
||||||
this._header.appendChild(this._icon);
|
this._header.appendChild(this._icon); //}
|
||||||
}
|
|
||||||
|
|
||||||
this._caption = document.createElement("div");
|
this._caption = document.createElement("div");
|
||||||
this._caption.className = this.cssClass + "-caption";
|
this._caption.className = this.cssClass + "-caption";
|
||||||
@ -9329,7 +9348,21 @@ var _default = _IUI.IUI.module((_temp = _class = /*#__PURE__*/function (_IUIElem
|
|||||||
|
|
||||||
|
|
||||||
this.insertAdjacentElement("afterBegin", this._header);
|
this.insertAdjacentElement("afterBegin", this._header);
|
||||||
|
|
||||||
|
case 28:
|
||||||
|
case "end":
|
||||||
|
return _context.stop();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
}, _callee, this);
|
||||||
|
}));
|
||||||
|
|
||||||
|
function create() {
|
||||||
|
return _create.apply(this, arguments);
|
||||||
|
}
|
||||||
|
|
||||||
|
return create;
|
||||||
|
}()
|
||||||
}, {
|
}, {
|
||||||
key: "setHeaderVisible",
|
key: "setHeaderVisible",
|
||||||
value: function setHeaderVisible(value) {
|
value: function setHeaderVisible(value) {
|
||||||
@ -9344,6 +9377,11 @@ var _default = _IUI.IUI.module((_temp = _class = /*#__PURE__*/function (_IUIElem
|
|||||||
key: "icon",
|
key: "icon",
|
||||||
get: function get() {
|
get: function get() {
|
||||||
return this.getAttribute("icon");
|
return this.getAttribute("icon");
|
||||||
|
},
|
||||||
|
set: function set(value) {
|
||||||
|
this._icon.style.setProperty("--icon", "url('".concat(value, "')"));
|
||||||
|
|
||||||
|
this.setAttribute("icon", value);
|
||||||
}
|
}
|
||||||
/*
|
/*
|
||||||
setFocus(v) {
|
setFocus(v) {
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@esiur/iui",
|
"name": "@esiur/iui",
|
||||||
"version": "1.2.2",
|
"version": "1.2.3",
|
||||||
"description": "Interactive User Interface",
|
"description": "Interactive User Interface",
|
||||||
"main": "iui.js",
|
"main": "iui.js",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user