Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@mybricks/comlib-core

Package Overview
Dependencies
Maintainers
13
Versions
61
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@mybricks/comlib-core - npm Package Compare versions

Comparing version 0.0.45-beta.2 to 0.0.45

2

fn.js

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

!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.fn=t():e.fn=t()}(this,(()=>(()=>{"use strict";var __webpack_modules__={178:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{function __WEBPACK_DEFAULT_EXPORT__({data,outputs,inputs,onError}){inputs.from(((val,relOutpus)=>{var _a;const script=null===(_a=data.exchange)||void 0===_a?void 0:_a.script;if(script){let fn,returnVal,isOk;try{eval(`fn = ${script}`),returnVal=fn(val),isOk=!0}catch(e){console.error(e),onError(`数据转换错误:${e.message}`,e)}isOk&&outputs.to(returnVal)}else onError("未配置转换规则")}))}__webpack_require__.d(__webpack_exports__,{A:()=>__WEBPACK_DEFAULT_EXPORT__})}},__webpack_module_cache__={};function __webpack_require__(e){var t=__webpack_module_cache__[e];if(void 0!==t)return t.exports;var r=__webpack_module_cache__[e]={exports:{}};return __webpack_modules__[e](r,r.exports,__webpack_require__),r.exports}__webpack_require__.d=(e,t)=>{for(var r in t)__webpack_require__.o(t,r)&&!__webpack_require__.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},__webpack_require__.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),__webpack_require__.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var __webpack_exports__={};return(()=>{__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{default:()=>p,getCom:()=>l});const e=JSON.parse('{"title":"Fn计算","namespace":"mybricks.core-comlib.fn","author":"CheMingjun","author_name":"车明君","version":"1.0.0","description":"Fn计算","icon":"./icon.png","runtime":"./Fn.tsx","rtType":"js","visibility":false}'),t=JSON.parse('{"visibility":false,"title":"变量","namespace":"mybricks.core-comlib.var","author":"CheMingjun","author_name":"车明君","version":"1.0.0","description":"变量","icon":"./icon.png","data":"./data.json","runtime":"./Var.tsx","editors":"./editors.tsx","rtType":"js","inputs":[{"id":"get","title":"读取","schema":{"type":"any"},"rels":["return"]},{"id":"set","title":"赋值","schema":{"type":"follow"},"rels":["return"]},{"id":"reset","title":"重置","schema":{"type":"any"}}],"outputs":[{"id":"return","title":"完成","schema":{"type":"unknown"}},{"id":"changed","title":"当值发生变化","schema":{"type":"unknown"}}]}');function r(e){if(e)try{const t=Object.prototype.toString.call(e);return["[object Object]","[object Array]"].includes(t)?JSON.parse(JSON.stringify(e)):e}catch(t){return e}return e}const n=JSON.parse('{"title":"类型转换","visibility":false,"namespace":"mybricks.core-comlib.type-change","author":"CheMingjun","author_name":"车明君","version":"1.0.0","description":"类型转换","icon":"./icon.png","runtime":"./rt.tsx","editors":"./editors.tsx","rtType":"js","inputs":[{"id":"from","title":"从","schema":{"type":"follow"},"rels":["to"]}],"outputs":[{"id":"to","title":"到","schema":{"type":"follow"},"conMax":1,"editable":true}]}');var o=__webpack_require__(178);const i=JSON.parse('{"deprecated":true,"visibility":false,"title":"连接器","namespace":"mybricks.core-comlib.connector","author":"MyBricks","author_name":"MyBricks","version":"1.0.0","description":"连接器","runtime":"./runtime.ts","editors":"./editors.tsx","icon":"./icon.svg","rtType":"js-autorun","inputs":[{"id":"call","rels":["then","catch"],"title":"调用","schema":{"type":"object"}}],"outputs":[{"id":"then","title":"结果","schema":{"type":"unknown"}},{"id":"catch","title":"发生错误","schema":{"type":"string"}}]}');function s({env:e,data:t,outputs:r,onError:n},o={}){if(t.connector)try{e.callConnector(t.connector,o,t.connectorConfig).then((e=>{r.then(e)})).catch((e=>{r.catch(e)}))}catch(e){console.error(e),r.catch(`执行错误 ${e.message||e}`)}else r.catch("没有选择接口")}const a=JSON.parse('{"visibility":false,"title":"作用域输入","namespace":"mybricks.core-comlib.frame-input","author":"CheMingjun","author_name":"车明君","version":"1.0.0","description":"作用域输入","rtType":"js","runtime":"./runtime.ts","editors":"./editor.tsx","inputs":[{"id":"getCurValue","title":"获取","schema":{"type":"any"},"rels":["return"]}],"outputs":[{"id":"return","title":"结果","schema":{"type":"follow"}}]}'),c=JSON.parse('{"visibility":false,"title":"打开对话框","namespace":"mybricks.core-comlib.scenes","author":"CheMingjun","author_name":"车明君","version":"1.0.0","description":"切换场景","icon":"./icon.png","runtime":"./runtime.ts","data":"./data.json","rtType":"js","inputs":[{"id":"open","title":"打开","schema":{"type":"any"}}]}'),u=JSON.parse('{"title":"模块","namespace":"mybricks.core-comlib.module","author":"CheMingjun","author_name":"车明君","version":"1.0.0","description":"模块","icon":"./icon.png","data":"./data.json","runtime":"./runtime.tsx","editors":"./editors.ts"}'),_={id:"mybricks-core-comlib",title:"Mybrics核心组件库",author:"CheMingjun",icon:"",version:"1.0.1",comAray:[d({comDef:e,rt:function({inputs:e,outputs:t}){}}),d({comDef:t,rt:function({env:e,data:t,outputs:n,inputs:o,_notifyBindings:i}){o.get(((e,n)=>{const o=r(void 0!==t.val?t.val:t.initValue);n.return(o)})),o.set(((e,o)=>{t.val=e;const s=r(e);n.changed(s,!0),i(s),o.return(s)})),o.reset((()=>{const e=t.initValue;t.val=e;const o=r(e);n.changed(o,!0),i(o)}))}}),d({comDef:n,rt:o.A}),d({comDef:i,rt:function({env:e,data:t,inputs:r,outputs:n,onError:o}){e.runtime&&(t.immediate?s({env:e,data:t,outputs:n}):r.call((r=>{s({env:e,data:t,outputs:n,onError:o},r)})))}}),d({comDef:a,rt:function({env:e,inputs:t}){e.runtime&&t.getCurValue(((e,t)=>{t.return(e)}))}}),d({comDef:c,rt:function({env:e,data:t,inputs:r,_inputs:n,_inputsCallable:o}){r.open((r=>{e.canvas.open(t._sceneId,r,"popup"===t._sceneShowType?null:t.openType),o._open(r)}))}}),d({comDef:u,rt:function({env:e,data:t,inputs:r,outputs:n}){const o=e.getModuleJSON(t.definedId);return e.renderModule(o,{ref(e){const{inputs:i,outputs:s}=o;i.forEach((({id:t})=>{r[t]((r=>{e.inputs[t](r)}))})),s.forEach((({id:t})=>{e.outputs(t,n[t])}));const a=t.configs;for(let t in a)e.inputs[t](a[t]);e.run()},disableAutoRun:!0})}})]},p=_;function l(e){return _.comAray.find((t=>t.namespace===e))}function d({comDef:e,rt:t,data:r}){return Object.assign(e,{runtime:t,data:r})}})(),__webpack_exports__})()));
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.fn=t():e.fn=t()}(this,(()=>(()=>{"use strict";var __webpack_modules__={356:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{function __WEBPACK_DEFAULT_EXPORT__({data,outputs,inputs,onError}){inputs.from(((val,relOutpus)=>{var _a;const script=null===(_a=data.exchange)||void 0===_a?void 0:_a.script;if(script){let fn,returnVal,isOk;try{eval(`fn = ${script}`),returnVal=fn(val),isOk=!0}catch(e){console.error(e),onError(`数据转换错误:${e.message}`,e)}isOk&&outputs.to(returnVal)}else onError("未配置转换规则")}))}__webpack_require__.d(__webpack_exports__,{Z:()=>__WEBPACK_DEFAULT_EXPORT__})}},__webpack_module_cache__={};function __webpack_require__(e){var t=__webpack_module_cache__[e];if(void 0!==t)return t.exports;var r=__webpack_module_cache__[e]={exports:{}};return __webpack_modules__[e](r,r.exports,__webpack_require__),r.exports}__webpack_require__.d=(e,t)=>{for(var r in t)__webpack_require__.o(t,r)&&!__webpack_require__.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},__webpack_require__.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),__webpack_require__.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var __webpack_exports__={};return(()=>{__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{default:()=>_,getCom:()=>l});const e=JSON.parse('{"title":"Fn计算","namespace":"mybricks.core-comlib.fn","author":"CheMingjun","author_name":"车明君","version":"1.0.0","description":"Fn计算","icon":"./icon.png","runtime":"./Fn.tsx","rtType":"js","visibility":false}'),t=JSON.parse('{"visibility":false,"title":"变量","namespace":"mybricks.core-comlib.var","author":"CheMingjun","author_name":"车明君","version":"1.0.0","description":"变量","icon":"./icon.png","data":"./data.json","runtime":"./Var.tsx","editors":"./editors.tsx","rtType":"js","inputs":[{"id":"get","title":"读取","schema":{"type":"any"},"rels":["return"]},{"id":"set","title":"赋值","schema":{"type":"follow"},"rels":["return"]},{"id":"reset","title":"重置","schema":{"type":"any"}}],"outputs":[{"id":"return","title":"完成","schema":{"type":"unknown"}},{"id":"changed","title":"当值发生变化","schema":{"type":"unknown"}}]}');function r(e){if(e)try{const t=Object.prototype.toString.call(e);return["[object Object]","[object Array]"].includes(t)?JSON.parse(JSON.stringify(e)):e}catch(t){return e}return e}const n=JSON.parse('{"title":"类型转换","visibility":false,"namespace":"mybricks.core-comlib.type-change","author":"CheMingjun","author_name":"车明君","version":"1.0.0","description":"类型转换","icon":"./icon.png","runtime":"./rt.tsx","editors":"./editors.tsx","rtType":"js","inputs":[{"id":"from","title":"从","schema":{"type":"follow"},"rels":["to"]}],"outputs":[{"id":"to","title":"到","schema":{"type":"follow"},"conMax":1,"editable":true}]}');var o=__webpack_require__(356);const i=JSON.parse('{"deprecated":true,"visibility":false,"title":"连接器","namespace":"mybricks.core-comlib.connector","author":"MyBricks","author_name":"MyBricks","version":"1.0.0","description":"连接器","runtime":"./runtime.ts","editors":"./editors.tsx","icon":"./icon.svg","rtType":"js-autorun","inputs":[{"id":"call","rels":["then","catch"],"title":"调用","schema":{"type":"object"}}],"outputs":[{"id":"then","title":"结果","schema":{"type":"unknown"}},{"id":"catch","title":"发生错误","schema":{"type":"string"}}]}');function s({env:e,data:t,outputs:r,onError:n},o={}){if(t.connector)try{e.callConnector(t.connector,o,t.connectorConfig).then((e=>{r.then(e)})).catch((e=>{r.catch(e)}))}catch(e){console.error(e),r.catch(`执行错误 ${e.message||e}`)}else r.catch("没有选择接口")}const a=JSON.parse('{"visibility":false,"title":"作用域输入","namespace":"mybricks.core-comlib.frame-input","author":"CheMingjun","author_name":"车明君","version":"1.0.0","description":"作用域输入","rtType":"js","runtime":"./runtime.ts","editors":"./editor.tsx","inputs":[{"id":"getCurValue","title":"获取","schema":{"type":"any"},"rels":["return"]}],"outputs":[{"id":"return","title":"结果","schema":{"type":"follow"}}]}'),c=JSON.parse('{"visibility":false,"title":"打开对话框","namespace":"mybricks.core-comlib.scenes","author":"CheMingjun","author_name":"车明君","version":"1.0.0","description":"切换场景","icon":"./icon.png","runtime":"./runtime.ts","data":"./data.json","rtType":"js","inputs":[{"id":"open","title":"打开","schema":{"type":"any"}}]}'),u=JSON.parse('{"title":"模块","namespace":"mybricks.core-comlib.module","author":"CheMingjun","author_name":"车明君","version":"1.0.0","description":"模块","icon":"./icon.png","data":"./data.json","runtime":"./runtime.tsx","editors":"./editors.ts","outputs":[{"id":"click","title":"单击","description":"点击模块触发的事件","schema":{"type":"any"}}]}'),p={id:"mybricks-core-comlib",title:"Mybrics核心组件库",author:"CheMingjun",icon:"",version:"1.0.1",comAray:[d({comDef:e,rt:function({inputs:e,outputs:t}){}}),d({comDef:t,rt:function({env:e,data:t,outputs:n,inputs:o,_notifyBindings:i}){o.get(((e,n)=>{const o=r(void 0!==t.val?t.val:t.initValue);n.return(o)})),o.set(((e,o)=>{t.val=e;const s=r(e);n.changed(s,!0),i(s),o.return(s)})),o.reset((()=>{const e=t.initValue;t.val=e;const o=r(e);n.changed(o,!0),i(o)}))}}),d({comDef:n,rt:o.Z}),d({comDef:i,rt:function({env:e,data:t,inputs:r,outputs:n,onError:o}){e.runtime&&(t.immediate?s({env:e,data:t,outputs:n}):r.call((r=>{s({env:e,data:t,outputs:n,onError:o},r)})))}}),d({comDef:a,rt:function({env:e,inputs:t}){e.runtime&&t.getCurValue(((e,t)=>{t.return(e)}))}}),d({comDef:c,rt:function({env:e,data:t,inputs:r,_inputs:n,_inputsCallable:o}){r.open((r=>{e.canvas.open(t._sceneId,r,"popup"===t._sceneShowType?null:t.openType),o._open(r)}))}}),d({comDef:u,rt:function({env:e,data:t,inputs:r,outputs:n}){const o=e.getModuleJSON(t.definedId);return e.renderModule(o,{ref(e){const{inputs:i,outputs:s}=o;i.forEach((({id:t})=>{r[t]((r=>{e.inputs[t](r)}))})),s.forEach((({id:t})=>{e.outputs(t,n[t])}));const a=t.configs;for(let t in a)e.inputs[t](a[t]);e.run()},disableAutoRun:!0})}})]},_=p;function l(e){return p.comAray.find((t=>t.namespace===e))}function d({comDef:e,rt:t,data:r}){return Object.assign(e,{runtime:t,data:r})}})(),__webpack_exports__})()));

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

!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react")):"function"==typeof define&&define.amd?define(["react"],t):"object"==typeof exports?exports.index=t(require("react")):e.index=t(e.React)}(this,(__WEBPACK_EXTERNAL_MODULE__12__=>(()=>{"use strict";var __webpack_modules__={178:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{function __WEBPACK_DEFAULT_EXPORT__({data,outputs,inputs,onError}){inputs.from(((val,relOutpus)=>{var _a;const script=null===(_a=data.exchange)||void 0===_a?void 0:_a.script;if(script){let fn,returnVal,isOk;try{eval(`fn = ${script}`),returnVal=fn(val),isOk=!0}catch(e){console.error(e),onError(`数据转换错误:${e.message}`,e)}isOk&&outputs.to(returnVal)}else onError("未配置转换规则")}))}__webpack_require__.d(__webpack_exports__,{A:()=>__WEBPACK_DEFAULT_EXPORT__})},12:e=>{e.exports=__WEBPACK_EXTERNAL_MODULE__12__}},__webpack_module_cache__={};function __webpack_require__(e){var t=__webpack_module_cache__[e];if(void 0!==t)return t.exports;var r=__webpack_module_cache__[e]={exports:{}};return __webpack_modules__[e](r,r.exports,__webpack_require__),r.exports}__webpack_require__.d=(e,t)=>{for(var r in t)__webpack_require__.o(t,r)&&!__webpack_require__.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},__webpack_require__.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),__webpack_require__.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var __webpack_exports__={};return(()=>{function e(e){if(e)try{const t=Object.prototype.toString.call(e);return["[object Object]","[object Array]"].includes(t)?JSON.parse(JSON.stringify(e)):e}catch(t){return e}return e}__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{default:()=>n});var t=__webpack_require__(178);function r({env:e,data:t,outputs:r,onError:o},n={}){if(t.connector)try{e.callConnector(t.connector,n,t.connectorConfig).then((e=>{r.then(e)})).catch((e=>{r.catch(e)}))}catch(e){console.error(e),r.catch(`执行错误 ${e.message||e}`)}else r.catch("没有选择接口")}var o=__webpack_require__(12);const n={id:"mybricks-core-comlib",title:"Mybrics核心组件库",author:"CheMingjun",icon:"",version:"1.0.1",comAray:[{namespace:"mybricks.core-comlib.fn",version:"1.0.0",runtime:function({inputs:e,outputs:t}){},data:{},inputs:[],outputs:[]},{namespace:"mybricks.core-comlib.var",version:"1.0.0",runtime:function({env:t,data:r,outputs:o,inputs:n,_notifyBindings:c}){n.get(((t,o)=>{const n=e(void 0!==r.val?r.val:r.initValue);o.return(n)})),n.set(((t,n)=>{r.val=t;const u=e(t);o.changed(u,!0),c(u),n.return(u)})),n.reset((()=>{const t=r.initValue;r.val=t;const n=e(t);o.changed(n,!0),c(n)}))},data:{},inputs:["get","set","reset"],outputs:["return","changed"]},{namespace:"mybricks.core-comlib.type-change",version:"1.0.0",runtime:t.A,data:{},inputs:["from"],outputs:["to"]},{namespace:"mybricks.core-comlib.connector",version:"1.0.0",runtime:function({env:e,data:t,inputs:o,outputs:n,onError:c}){e.runtime&&(t.immediate?r({env:e,data:t,outputs:n}):o.call((o=>{r({env:e,data:t,outputs:n,onError:c},o)})))},data:{},inputs:["call"],outputs:["then","catch"]},{namespace:"mybricks.core-comlib.frame-input",version:"1.0.0",runtime:function({env:e,inputs:t}){e.runtime&&t.getCurValue(((e,t)=>{t.return(e)}))},data:{},inputs:["getCurValue"],outputs:["return"]},{namespace:"mybricks.core-comlib.scenes",version:"1.0.0",runtime:function({env:e,data:t,inputs:r,_inputs:o,_inputsCallable:n}){r.open((r=>{e.canvas.open(t._sceneId,r,"popup"===t._sceneShowType?null:t.openType),n._open(r)}))},data:{_sceneId:null,_sceneShowType:null,openType:"blank"},inputs:["open"],outputs:[]},{namespace:"mybricks.core-comlib.module",version:"1.0.0",runtime:function({env:e,data:t,style:r,inputs:n,outputs:c}){const[u,i]=(0,o.useState)(),_=(0,o.useMemo)((()=>{const o=e.getModuleJSON(t.definedId);return e.renderModule(o,{ref(u){if(i(u),e.edit){const e=u.style;e&&(r.widthAuto=e.widthAuto,r.widthFull=e.widthFull,r.heightAuto=e.heightAuto,r.heightFull=e.heightFull)}if(e.runtime){const{inputs:e,outputs:r}=o,i=t.configs;for(let e in i)u.inputs[e](i[e]);e.forEach((({id:e})=>{n[e]((t=>{u.inputs[e](t)}))})),r.forEach((({id:e})=>{u.outputs(e,c[e])}))}u.run()},disableAutoRun:!0})}),[]);return(0,o.useMemo)((()=>{if(u&&e.edit){const e=t.configs;for(let t in e)u.inputs[t](e[t])}}),[t.configs,u]),_},data:{},inputs:["show","hide","showOrHide"],outputs:[]},{namespace:"mybricks.core-comlib.group",version:"1.0.0",runtime:function({slots:e,outputs:t}){const r=(0,o.useCallback)((()=>{t.click()}),[]),n=(0,o.useCallback)((()=>{t.dblClick()}),[]);return React.createElement("div",{style:{width:"100%",height:"100%",overflow:"visible"},onClick:r,onDoubleClick:n},e.content.render())},data:{},inputs:["show","hide","showOrHide"],outputs:["click","dblClick"]}]}})(),__webpack_exports__})()));
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react")):"function"==typeof define&&define.amd?define(["react"],t):"object"==typeof exports?exports.index=t(require("react")):e.index=t(e.React)}(this,(__WEBPACK_EXTERNAL_MODULE__359__=>(()=>{"use strict";var __webpack_modules__={356:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{function __WEBPACK_DEFAULT_EXPORT__({data,outputs,inputs,onError}){inputs.from(((val,relOutpus)=>{var _a;const script=null===(_a=data.exchange)||void 0===_a?void 0:_a.script;if(script){let fn,returnVal,isOk;try{eval(`fn = ${script}`),returnVal=fn(val),isOk=!0}catch(e){console.error(e),onError(`数据转换错误:${e.message}`,e)}isOk&&outputs.to(returnVal)}else onError("未配置转换规则")}))}__webpack_require__.d(__webpack_exports__,{Z:()=>__WEBPACK_DEFAULT_EXPORT__})},359:e=>{e.exports=__WEBPACK_EXTERNAL_MODULE__359__}},__webpack_module_cache__={};function __webpack_require__(e){var t=__webpack_module_cache__[e];if(void 0!==t)return t.exports;var r=__webpack_module_cache__[e]={exports:{}};return __webpack_modules__[e](r,r.exports,__webpack_require__),r.exports}__webpack_require__.d=(e,t)=>{for(var r in t)__webpack_require__.o(t,r)&&!__webpack_require__.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},__webpack_require__.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),__webpack_require__.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var __webpack_exports__={};return(()=>{function e(e){if(e)try{const t=Object.prototype.toString.call(e);return["[object Object]","[object Array]"].includes(t)?JSON.parse(JSON.stringify(e)):e}catch(t){return e}return e}__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{default:()=>o});var t=__webpack_require__(356);function r({env:e,data:t,outputs:r,onError:n},o={}){if(t.connector)try{e.callConnector(t.connector,o,t.connectorConfig).then((e=>{r.then(e)})).catch((e=>{r.catch(e)}))}catch(e){console.error(e),r.catch(`执行错误 ${e.message||e}`)}else r.catch("没有选择接口")}var n=__webpack_require__(359);const o={id:"mybricks-core-comlib",title:"Mybrics核心组件库",author:"CheMingjun",icon:"",version:"1.0.1",comAray:[{namespace:"mybricks.core-comlib.fn",version:"1.0.0",runtime:function({inputs:e,outputs:t}){},data:{},inputs:[],outputs:[]},{namespace:"mybricks.core-comlib.var",version:"1.0.0",runtime:function({env:t,data:r,outputs:n,inputs:o,_notifyBindings:c}){o.get(((t,n)=>{const o=e(void 0!==r.val?r.val:r.initValue);n.return(o)})),o.set(((t,o)=>{r.val=t;const u=e(t);n.changed(u,!0),c(u),o.return(u)})),o.reset((()=>{const t=r.initValue;r.val=t;const o=e(t);n.changed(o,!0),c(o)}))},data:{},inputs:["get","set","reset"],outputs:["return","changed"]},{namespace:"mybricks.core-comlib.type-change",version:"1.0.0",runtime:t.Z,data:{},inputs:["from"],outputs:["to"]},{namespace:"mybricks.core-comlib.connector",version:"1.0.0",runtime:function({env:e,data:t,inputs:n,outputs:o,onError:c}){e.runtime&&(t.immediate?r({env:e,data:t,outputs:o}):n.call((n=>{r({env:e,data:t,outputs:o,onError:c},n)})))},data:{},inputs:["call"],outputs:["then","catch"]},{namespace:"mybricks.core-comlib.frame-input",version:"1.0.0",runtime:function({env:e,inputs:t}){e.runtime&&t.getCurValue(((e,t)=>{t.return(e)}))},data:{},inputs:["getCurValue"],outputs:["return"]},{namespace:"mybricks.core-comlib.scenes",version:"1.0.0",runtime:function({env:e,data:t,inputs:r,_inputs:n,_inputsCallable:o}){r.open((r=>{e.canvas.open(t._sceneId,r,"popup"===t._sceneShowType?null:t.openType),o._open(r)}))},data:{_sceneId:null,_sceneShowType:null,openType:"blank"},inputs:["open"],outputs:[]},{namespace:"mybricks.core-comlib.module",version:"1.0.0",runtime:function({env:e,data:t,style:r,inputs:o,outputs:c}){const[u,i]=(0,n.useState)(),_=(0,n.useMemo)((()=>{const n=e.getModuleJSON(t.definedId);return e.renderModule(n,{ref(u){if(i(u),e.edit){const e=u.style;e&&(r.widthAuto=e.widthAuto,r.widthFull=e.widthFull,r.heightAuto=e.heightAuto,r.heightFull=e.heightFull)}if(e.runtime){const{inputs:e,outputs:r}=n,i=t.configs;for(let e in i)u.inputs[e](i[e]);e.forEach((({id:e})=>{o[e]((t=>{u.inputs[e](t)}))})),r.forEach((({id:e})=>{u.outputs(e,c[e])}))}u.run()},disableAutoRun:!0,outputs:c})}),[]);return(0,n.useMemo)((()=>{if(u&&e.edit){const e=t.configs;for(let t in e)u.inputs[t](e[t])}}),[t.configs,u]),_},data:{},inputs:["show","hide","showOrHide"],outputs:["click"]},{namespace:"mybricks.core-comlib.group",version:"1.0.0",runtime:function({slots:e,outputs:t}){const r=(0,n.useCallback)((()=>{t.click()}),[]),o=(0,n.useCallback)((()=>{t.dblClick()}),[]);return React.createElement("div",{style:{width:"100%",height:"100%"},onClick:r,onDoubleClick:o},e.content.render())},data:{},inputs:["show","hide","showOrHide"],outputs:["click","dblClick"]}]}})(),__webpack_exports__})()));
{
"name": "@mybricks/comlib-core",
"version": "0.0.45-beta.2",
"version": "0.0.45",
"description": "MyBricks核心组件库",

@@ -8,2 +8,6 @@ "main": "index.js",

"license": "ISC",
"dependencies": {
"react": "^18.2.0",
"react-dom": "^18.2.0"
},
"scripts": {

@@ -35,6 +39,2 @@ "test": "jest",

},
"peerDependencies": {
"react": "^18.2.0",
"react-dom": "^18.2.0"
},
"publishConfig": {

@@ -41,0 +41,0 @@ "registry": "https://registry.npmjs.org"

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