New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

dom-render

Package Overview
Dependencies
Maintainers
1
Versions
98
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dom-render - npm Package Compare versions

Comparing version 1.0.92 to 1.0.93

2

components/ComponentSet.d.ts

@@ -1,2 +0,2 @@

export declare type ComponentSetConfig = {
export type ComponentSetConfig = {
objPath?: string | null;

@@ -3,0 +3,0 @@ };

@@ -9,3 +9,3 @@ import { ConstructorType } from '../types/Types';

import { OperatorAround } from '../operators/OperatorExecuter';
export declare type Config = {
export type Config = {
window: Window;

@@ -28,2 +28,5 @@ targetElements?: TargetElement[];

messenger?: Messenger;
eventVariables?: {
[n: string]: any;
};
applyEvents?: {

@@ -30,0 +33,0 @@ attrName: string;

import { RawSet } from '../rawsets/RawSet';
export declare type TargetAttr = {
export type TargetAttr = {
name: string;

@@ -4,0 +4,0 @@ callBack: (target: Element, attrValue: string, obj: any, rawSet: RawSet) => DocumentFragment;

@@ -6,3 +6,3 @@ import { RawSet } from '../rawsets/RawSet';

import { Render } from '../rawsets/Render';
export declare type TargetElement = {
export type TargetElement = {
name: string;

@@ -9,0 +9,0 @@ template?: string;

@@ -17,3 +17,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -78,5 +78,5 @@ if (y = 0, t) op = [op[0] & 2, t.value];

var _this = this;
var _a, _b;
var _a;
this._domRender_proxy = objProxy;
(_b = (_a = objProxy) === null || _a === void 0 ? void 0 : _a.onProxyDomRender) === null || _b === void 0 ? void 0 : _b.call(_a, this.config);
(_a = objProxy === null || objProxy === void 0 ? void 0 : objProxy.onProxyDomRender) === null || _a === void 0 ? void 0 : _a.call(objProxy, this.config);
var obj = objProxy._DomRender_origin;

@@ -301,3 +301,3 @@ if (obj) {

DomRenderProxy.prototype.set = function (target, p, value, receiver) {
var _a, _b, _c;
var _a, _b;
if (typeof p === 'string' && p !== '__domrender_components' && excludeGetSetPropertys.includes(p)) {

@@ -323,3 +323,3 @@ target[p] = value;

if (('onBeforeReturnSet' in receiver) && typeof p === 'string' && !((_a = this.config.proxyExcludeOnBeforeReturnSets) !== null && _a !== void 0 ? _a : []).concat(excludeGetSetPropertys).includes(p)) {
(_c = (_b = receiver) === null || _b === void 0 ? void 0 : _b.onBeforeReturnSet) === null || _c === void 0 ? void 0 : _c.call(_b, p, value, fullPath);
(_b = receiver === null || receiver === void 0 ? void 0 : receiver.onBeforeReturnSet) === null || _b === void 0 ? void 0 : _b.call(receiver, p, value, fullPath);
}

@@ -329,3 +329,3 @@ return true;

DomRenderProxy.prototype.get = function (target, p, receiver) {
var _a, _b, _c;
var _a, _b;
// console.log('get-->', target, p, receiver);

@@ -361,3 +361,3 @@ if (p === '_DomRender_origin') {

if (('onBeforeReturnGet' in receiver) && typeof p === 'string' && !((_a = this.config.proxyExcludeOnBeforeReturnGets) !== null && _a !== void 0 ? _a : []).concat(excludeGetSetPropertys).includes(p)) {
(_c = (_b = receiver) === null || _b === void 0 ? void 0 : _b.onBeforeReturnGet) === null || _c === void 0 ? void 0 : _c.call(_b, p, it_2, this.root([p], it_2, false));
(_b = receiver === null || receiver === void 0 ? void 0 : receiver.onBeforeReturnGet) === null || _b === void 0 ? void 0 : _b.call(receiver, p, it_2, this.root([p], it_2, false));
}

@@ -364,0 +364,0 @@ return it_2;

@@ -47,3 +47,4 @@ import { Config } from '../configs/Config';

} | undefined;
getBindScript(config?: Config): string;
}
export declare const eventManager: EventManager;
"use strict";
var __assign = (this && this.__assign) || function () {
__assign = Object.assign || function(t) {
for (var s, i = 1, n = arguments.length; i < n; i++) {
s = arguments[i];
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
t[p] = s[p];
}
return t;
};
return __assign.apply(this, arguments);
};
Object.defineProperty(exports, "__esModule", { value: true });

@@ -49,3 +60,4 @@ exports.eventManager = exports.EventManager = void 0;

range: Range_1.Range.range,
scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj)
scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj),
// ...EventManager.eventVariables
})

@@ -137,3 +149,3 @@ }));

if (mapScript_1) {
setValue = ScriptUtils_1.ScriptUtils.eval("".concat(_this.bindScript, " return ").concat(mapScript_1), Object.assign(bindObj_1, { __render: Object.freeze({ element: it, target: bindObj_1, range: Range_1.Range.range, value: setValue, scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj) }) }));
setValue = ScriptUtils_1.ScriptUtils.eval("".concat(_this.getBindScript(config), " return ").concat(mapScript_1), Object.assign(bindObj_1, { __render: Object.freeze(__assign({ element: it, target: bindObj_1, range: Range_1.Range.range, value: setValue, scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj) }, config === null || config === void 0 ? void 0 : config.eventVariables)) }));
}

@@ -146,32 +158,11 @@ getValue(setValue);

if (mapScript_1) {
setValue = ScriptUtils_1.ScriptUtils.eval("".concat(_this.bindScript, " return ").concat(mapScript_1), Object.assign(bindObj_1, { __render: Object.freeze({ element: it, target: bindObj_1, range: Range_1.Range.range, value: setValue, scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj) }) }));
setValue = ScriptUtils_1.ScriptUtils.eval("".concat(_this.getBindScript(config), " return ").concat(mapScript_1), Object.assign(bindObj_1, { __render: Object.freeze(__assign({ element: it, target: bindObj_1, range: Range_1.Range.range, value: setValue, scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj) }, config === null || config === void 0 ? void 0 : config.eventVariables)) }));
}
it.value = setValue;
// this.setValue(obj, varName, setValue)
}
// } else if (getValue) { // 이구분이 있어야되나?? 없어도될것같은데..
// let setValue = getValue;
// if (inMapScript) {
// setValue = ScriptUtils.eval(`${this.bindScript} return ${inMapScript}`, Object.assign(bindObj, {__render: Object.freeze({element: it, target: bindObj, range: Range.range, value: setValue, scripts: EventManager.setBindProperty(config?.scripts, obj)})}));
// }
// this.setValue(obj, varName, setValue)
// } else {
// let setValue = it.value;
// if (mapScript) {
// setValue = ScriptUtils.eval(`${this.bindScript} return ${mapScript}`, Object.assign(bindObj, {__render: Object.freeze({element: it, target: bindObj, range: Range.range, value: setValue, scripts: EventManager.setBindProperty(config?.scripts, obj)})}));
// }
// this.setValue(obj, varName, setValue)
// }
it.addEventListener('input', function (event) {
var value = it.value;
if (mapScript_1) {
value = ScriptUtils_1.ScriptUtils.eval("".concat(_this.bindScript, " return ").concat(mapScript_1), Object.assign(bindObj_1, {
__render: Object.freeze({
event: event,
element: it,
attribute: DomUtils_1.DomUtils.getAttributeToObject(it),
target: event.target,
range: Range_1.Range.range,
scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj)
})
value = ScriptUtils_1.ScriptUtils.eval("".concat(_this.getBindScript(config), " return ").concat(mapScript_1), Object.assign(bindObj_1, {
__render: Object.freeze(__assign({ event: event, element: it, attribute: DomUtils_1.DomUtils.getAttributeToObject(it), target: event.target, range: Range_1.Range.range, scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj) }, config === null || config === void 0 ? void 0 : config.eventVariables))
}));

@@ -195,7 +186,4 @@ }

if (script) {
ScriptUtils_1.ScriptUtils.eval("".concat(_this.bindScript, "; ").concat(script, " "), Object.assign(obj, {
__render: Object.freeze({
element: it,
attribute: DomUtils_1.DomUtils.getAttributeToObject(it)
})
ScriptUtils_1.ScriptUtils.eval("".concat(_this.getBindScript(config), "; ").concat(script, " "), Object.assign(obj, {
__render: Object.freeze(__assign({ element: it, attribute: DomUtils_1.DomUtils.getAttributeToObject(it) }, config === null || config === void 0 ? void 0 : config.eventVariables))
}));

@@ -235,3 +223,3 @@ // console.log('onInit--->', obj, varName, it)

if (mapScript) {
setValue = ScriptUtils_1.ScriptUtils.eval("".concat(_this.bindScript, " return ").concat(mapScript), Object.assign(bindObj, { __render: Object.freeze({ element: it, target: bindObj, range: Range_1.Range.range, value: setValue, scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj) }) }));
setValue = ScriptUtils_1.ScriptUtils.eval("".concat(_this.getBindScript(config), " return ").concat(mapScript), Object.assign(bindObj, { __render: Object.freeze(__assign({ element: it, target: bindObj, range: Range_1.Range.range, value: setValue, scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj) }, config === null || config === void 0 ? void 0 : config.eventVariables)) }));
}

@@ -243,3 +231,3 @@ getValue(setValue);

if (mapScript) {
setValue = ScriptUtils_1.ScriptUtils.eval("".concat(_this.bindScript, " return ").concat(mapScript), Object.assign(bindObj, { __render: Object.freeze({ element: it, target: bindObj, range: Range_1.Range.range, value: setValue, scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj) }) }));
setValue = ScriptUtils_1.ScriptUtils.eval("".concat(_this.getBindScript(config), " return ").concat(mapScript), Object.assign(bindObj, { __render: Object.freeze(__assign({ element: it, target: bindObj, range: Range_1.Range.range, value: setValue, scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj) }, config === null || config === void 0 ? void 0 : config.eventVariables)) }));
}

@@ -395,17 +383,9 @@ it.value = setValue;

var thisTarget = Object.assign(obj, {
__render: Object.freeze({
event: event,
element: it,
target: event.target,
range: Range_1.Range.range,
attribute: DomUtils_1.DomUtils.getAttributeToObject(it),
router: config === null || config === void 0 ? void 0 : config.router,
scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj)
})
__render: Object.freeze(__assign({ event: event, element: it, target: event.target, range: Range_1.Range.range, attribute: DomUtils_1.DomUtils.getAttributeToObject(it), router: config === null || config === void 0 ? void 0 : config.router, scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj) }, config === null || config === void 0 ? void 0 : config.eventVariables))
});
if (filterScript) {
filter = ScriptUtils_1.ScriptUtils.eval("".concat(_this.bindScript, " return ").concat(filterScript), thisTarget);
filter = ScriptUtils_1.ScriptUtils.eval("".concat(_this.getBindScript(config), " return ").concat(filterScript), thisTarget);
}
if (filter) {
ScriptUtils_1.ScriptUtils.eval("".concat(_this.bindScript, " ").concat(script, " "), thisTarget);
ScriptUtils_1.ScriptUtils.eval("".concat(_this.getBindScript(config), " ").concat(script, " "), thisTarget);
}

@@ -433,12 +413,4 @@ });

it.addEventListener(eventName.trim(), function (event) {
ScriptUtils_1.ScriptUtils.eval("const $params = this.__render.params; ".concat(_this.bindScript, " ").concat(script_1, " "), Object.assign(obj, {
__render: Object.freeze({
event: event,
element: it,
attribute: DomUtils_1.DomUtils.getAttributeToObject(it),
target: event.target,
range: Range_1.Range.range,
scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj),
params: params_1
})
ScriptUtils_1.ScriptUtils.eval("const $params = this.__render.params; ".concat(_this.getBindScript(config), " ").concat(script_1, " "), Object.assign(obj, {
__render: Object.freeze(__assign({ event: event, element: it, attribute: DomUtils_1.DomUtils.getAttributeToObject(it), target: event.target, range: Range_1.Range.range, scripts: EventManager.setBindProperty(config === null || config === void 0 ? void 0 : config.scripts, obj), params: params_1 }, config === null || config === void 0 ? void 0 : config.eventVariables))
}));

@@ -520,2 +492,18 @@ });

};
EventManager.prototype.getBindScript = function (config) {
var _this = this;
if (config === null || config === void 0 ? void 0 : config.eventVariables) {
var bindScript = Object.entries(config.eventVariables).filter(function (_a) {
var key = _a[0], value = _a[1];
return !_this.bindScript.includes("const ".concat(key));
}).map(function (_a) {
var key = _a[0], value = _a[1];
return "const ".concat(key, " = this.__render.").concat(key, ";");
}).join(';');
return this.bindScript + '' + bindScript;
}
else {
return this.bindScript;
}
};
EventManager.ownerVariablePathAttrName = 'dr-owner-variable-path';

@@ -522,0 +510,0 @@ EventManager.attrPrefix = 'dr-';

@@ -8,7 +8,7 @@ import { ConstructorType } from '../types/Types';

}
export declare type ChannelData = {
export type ChannelData = {
channel: Channel;
data?: (any | undefined);
};
export declare type ChannelMetaData = {
export type ChannelMetaData = {
channel?: Channel;

@@ -51,3 +51,3 @@ action?: string;

}
declare type MessengerEventDetail = {
type MessengerEventDetail = {
key: string | object | ConstructorType<any>;

@@ -58,3 +58,3 @@ data?: any;

};
declare type MessengerSubscribeEventDetail = {
type MessengerSubscribeEventDetail = {
obj: any;

@@ -61,0 +61,0 @@ key?: string | object | ConstructorType<any>;

@@ -43,3 +43,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -46,0 +46,0 @@ if (y = 0, t) op = [op[0] & 2, t.value];

@@ -43,3 +43,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -74,6 +74,4 @@ if (y = 0, t) op = [op[0] & 2, t.value];

function DrAppender(rawSet, render, returnContainer, elementSource, source, afterCallBack) {
var _this = this;
source.operatorAround = undefined;
_this = _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
return _this;
return _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
}

@@ -80,0 +78,0 @@ DrAppender.prototype.executeAttrRequire = function (attr) {

@@ -43,3 +43,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -74,6 +74,4 @@ if (y = 0, t) op = [op[0] & 2, t.value];

function DrFor(rawSet, render, returnContainer, elementSource, source, afterCallBack) {
var _this = this;
source.operatorAround = undefined;
_this = _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
return _this;
return _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
}

@@ -80,0 +78,0 @@ DrFor.prototype.executeAttrRequire = function (attr) {

@@ -43,3 +43,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -46,0 +46,0 @@ if (y = 0, t) op = [op[0] & 2, t.value];

@@ -43,3 +43,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -74,6 +74,4 @@ if (y = 0, t) op = [op[0] & 2, t.value];

function DrForOf(rawSet, render, returnContainer, elementSource, source, afterCallBack) {
var _this = this;
source.operatorAround = undefined;
_this = _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
return _this;
return _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
}

@@ -80,0 +78,0 @@ DrForOf.prototype.executeAttrRequire = function (attr) {

@@ -43,3 +43,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -74,6 +74,4 @@ if (y = 0, t) op = [op[0] & 2, t.value];

function DrIf(rawSet, render, returnContainer, elementSource, source, afterCallBack) {
var _this = this;
source.operatorAround = undefined;
_this = _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
return _this;
return _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
}

@@ -80,0 +78,0 @@ DrIf.prototype.executeAttrRequire = function (attr) {

@@ -43,3 +43,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -46,0 +46,0 @@ if (y = 0, t) op = [op[0] & 2, t.value];

@@ -43,3 +43,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -46,0 +46,0 @@ if (y = 0, t) op = [op[0] & 2, t.value];

@@ -32,3 +32,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -60,6 +60,4 @@ if (y = 0, t) op = [op[0] & 2, t.value];

function DrPre(rawSet, render, returnContainer, elementSource, source, afterCallBack) {
var _this = this;
source.operatorAround = undefined;
_this = _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack) || this;
return _this;
return _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack) || this;
}

@@ -66,0 +64,0 @@ DrPre.prototype.execute = function (value) {

@@ -43,3 +43,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -75,6 +75,4 @@ if (y = 0, t) op = [op[0] & 2, t.value];

function DrRepeat(rawSet, render, returnContainer, elementSource, source, afterCallBack) {
var _this = this;
source.operatorAround = undefined;
_this = _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
return _this;
return _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
}

@@ -81,0 +79,0 @@ DrRepeat.prototype.executeAttrRequire = function (attr) {

@@ -32,3 +32,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -61,6 +61,4 @@ if (y = 0, t) op = [op[0] & 2, t.value];

function DrTargetAttr(rawSet, render, returnContainer, elementSource, source, afterCallBack) {
var _this = this;
source.operatorAround = undefined;
_this = _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
return _this;
return _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
}

@@ -67,0 +65,0 @@ DrTargetAttr.prototype.execute = function () {

@@ -32,3 +32,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -62,6 +62,4 @@ if (y = 0, t) op = [op[0] & 2, t.value];

function DrTargetElement(rawSet, render, returnContainer, elementSource, source, afterCallBack) {
var _this = this;
source.operatorAround = undefined;
_this = _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
return _this;
return _super.call(this, rawSet, render, returnContainer, elementSource, source, afterCallBack, false) || this;
}

@@ -68,0 +66,0 @@ DrTargetElement.prototype.execute = function () {

@@ -32,3 +32,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -35,0 +35,0 @@ if (y = 0, t) op = [op[0] & 2, t.value];

@@ -8,3 +8,3 @@ import { AttrInitCallBack } from '../rawsets/AttrInitCallBack';

import { Config } from '../configs/Config';
export declare type OperatorAround = {
export type OperatorAround = {
beforeAttr?: (value: string | null | undefined, opratorExecutor: OperatorExecuter) => string | null | undefined;

@@ -19,3 +19,3 @@ before?: (data: any, opratorExecutor: OperatorExecuter) => any;

}
export declare type AfterCallBack = {
export type AfterCallBack = {
onAttrInitCallBacks: AttrInitCallBack[];

@@ -25,7 +25,7 @@ onElementInitCallBacks: ElementInitCallBack[];

};
export declare type ReturnContainer = {
export type ReturnContainer = {
raws: RawSet[];
fag: DocumentFragment;
};
export declare type ElementSource = {
export type ElementSource = {
element: Element;

@@ -36,3 +36,3 @@ attrs: Attrs;

};
export declare type Source = {
export type Source = {
config: Config;

@@ -39,0 +39,0 @@ operatorAround?: OperatorAround;

@@ -17,3 +17,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -20,0 +20,0 @@ if (y = 0, t) op = [op[0] & 2, t.value];

@@ -32,3 +32,3 @@ "use strict";

if (f) throw new TypeError("Generator is already executing.");
while (_) try {
while (g && (g = 0, op[0] && (_ = 0)), _) try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;

@@ -35,0 +35,0 @@ if (y = 0, t) op = [op[0] & 2, t.value];

{
"name": "dom-render",
"version": "1.0.92",
"version": "1.0.93",
"main": "DomRender.js",

@@ -5,0 +5,0 @@ "license": "MIT",

@@ -1,2 +0,2 @@

export declare type AttrInitCallBack = {
export type AttrInitCallBack = {
attrName: string;

@@ -3,0 +3,0 @@ attrValue: string;

@@ -1,2 +0,2 @@

export declare type Attrs = {
export type Attrs = {
dr: string | null;

@@ -3,0 +3,0 @@ drIf: string | null;

import { Router } from '../routers/Router';
import { Attrs } from './Attrs';
import { RawSet } from './RawSet';
export declare type CreatorMetaData = {
export type CreatorMetaData = {
thisVariableName?: string | null;

@@ -6,0 +6,0 @@ thisFullVariableName?: string | null;

import { TargetElement } from '../configs/TargetElement';
import { CreatorMetaData } from './CreatorMetaData';
export declare type ElementInitCallBack = {
export type ElementInitCallBack = {
name: string;

@@ -5,0 +5,0 @@ obj: any;

import { CreatorMetaData } from './CreatorMetaData';
import { Router } from '../routers/Router';
import { RawSet } from './RawSet';
export declare type Render = {
export type Render = {
rawset?: RawSet;

@@ -6,0 +6,0 @@ scripts?: {

@@ -1,2 +0,2 @@

export declare type RouteData = {
export type RouteData = {
path: string;

@@ -3,0 +3,0 @@ url: string;

@@ -1,2 +0,2 @@

export declare type Attr = {
export type Attr = {
name: string;

@@ -3,0 +3,0 @@ value: any;

@@ -1,2 +0,2 @@

export declare type Attr = {
export type Attr = {
name: string;

@@ -3,0 +3,0 @@ value: any;

@@ -27,5 +27,5 @@ "use strict";

EmptyValidator.prototype.valid = function () {
var _a, _b;
var _a;
var value = this.value;
return value === undefined || value === null || ((_b = (_a = value) === null || _a === void 0 ? void 0 : _a.length) !== null && _b !== void 0 ? _b : 0) <= 0;
return value === undefined || value === null || ((_a = value === null || value === void 0 ? void 0 : value.length) !== null && _a !== void 0 ? _a : 0) <= 0;
};

@@ -32,0 +32,0 @@ return EmptyValidator;

@@ -27,6 +27,6 @@ "use strict";

NotEmptyValidator.prototype.valid = function () {
var _a, _b;
var _a;
var value = this.value;
// console.log('NotEmptyValidator', value, value !== undefined && value !== null && ((value as any)?.length ?? 0) > 0)
return value !== undefined && value !== null && ((_b = (_a = value) === null || _a === void 0 ? void 0 : _a.length) !== null && _b !== void 0 ? _b : 0) > 0;
return value !== undefined && value !== null && ((_a = value === null || value === void 0 ? void 0 : value.length) !== null && _a !== void 0 ? _a : 0) > 0;
};

@@ -33,0 +33,0 @@ return NotEmptyValidator;

@@ -1,3 +0,3 @@

export declare type Valid<T = any, E = Element> = (value?: T, target?: E, event?: Event) => boolean;
export declare type ValidAction<T = any, E = Element> = (valid: boolean, value?: T, target?: E, event?: Event) => void;
export type Valid<T = any, E = Element> = (value?: T, target?: E, event?: Event) => boolean;
export type ValidAction<T = any, E = Element> = (valid: boolean, value?: T, target?: E, event?: Event) => void;
export declare abstract class Validator<T = any, E = Element> {

@@ -4,0 +4,0 @@ protected _value?: T | undefined;

import { Validator } from './Validator';
export declare type MakeValidator<T = any, E = Element> = (value: T, target: E, event?: Event) => Validator<T, E>;
export type MakeValidator<T = any, E = Element> = (value: T, target: E, event?: Event) => Validator<T, E>;
export declare abstract class ValidatorArray<T = any, E = Element> extends Validator<Validator<T, E>[], E> {

@@ -4,0 +4,0 @@ private _makeValidatorFactory;

import { Validator } from './Validator';
import { MultipleValidator } from './MultipleValidator';
export declare type ValidMulltiple<T = any, E = Element> = (validators: Validator<T, E>[], value?: T, target?: E, event?: Event) => boolean;
export type ValidMulltiple<T = any, E = Element> = (validators: Validator<T, E>[], value?: T, target?: E, event?: Event) => boolean;
export declare class ValidMultipleValidator<T = any, E = Element> extends MultipleValidator<T, E> {

@@ -5,0 +5,0 @@ validMultipleCallback: ValidMulltiple<T, E>;

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc