@variousjs/create 1.1.0 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,18 @@
1
+ module.exports = {
2
+ presets: [
3
+ [
4
+ '@babel/env',
5
+ {
6
+ useBuiltIns: 'usage',
7
+ corejs: 3,
8
+ targets: {
9
+ browsers: '> 1%',
10
+ },
11
+ // debug: true,
12
+ },
13
+ ],
14
+ '@babel/preset-react',
15
+ '@babel/preset-typescript',
16
+ ],
17
+ plugins: ['@babel/plugin-transform-runtime'],
18
+ }
package/demo/dist/card.js CHANGED
@@ -1,2 +1,2 @@
1
- define(["react","react-router-dom","antd"],(function(e,t,n){return function(){"use strict";var r={233:function(e,t,n){var r=n(537),o=n.n(r),a=n(645),c=n.n(a)()(o());c.push([e.id,".container_Lng5c {\n margin-top: 30px;\n}\n","",{version:3,sources:["webpack://./src/components/card.less"],names:[],mappings:"AAAA;EACE,gBAAA;AACF",sourcesContent:[".container {\n margin-top: 30px;\n}\n"],sourceRoot:""}]),c.locals={container:"container_Lng5c"},t.Z=c},645:function(e){e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,o,a){"string"==typeof e&&(e=[[null,e,void 0]]);var c={};if(r)for(var i=0;i<this.length;i++){var s=this[i][0];null!=s&&(c[s]=!0)}for(var u=0;u<e.length;u++){var f=[].concat(e[u]);r&&c[f[0]]||(void 0!==a&&(void 0===f[5]||(f[1]="@layer".concat(f[5].length>0?" ".concat(f[5]):""," {").concat(f[1],"}")),f[5]=a),n&&(f[2]?(f[1]="@media ".concat(f[2]," {").concat(f[1],"}"),f[2]=n):f[2]=n),o&&(f[4]?(f[1]="@supports (".concat(f[4],") {").concat(f[1],"}"),f[4]=o):f[4]="".concat(o)),t.push(f))}},t}},537:function(e){e.exports=function(e){var t=e[1],n=e[3];if(!n)return t;if("function"==typeof btoa){var r=btoa(unescape(encodeURIComponent(JSON.stringify(n)))),o="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(r),a="/*# ".concat(o," */"),c=n.sources.map((function(e){return"/*# sourceURL=".concat(n.sourceRoot||"").concat(e," */")}));return[t].concat(c).concat([a]).join("\n")}return[t].join("\n")}},379:function(e){var t=[];function n(e){for(var n=-1,r=0;r<t.length;r++)if(t[r].identifier===e){n=r;break}return n}function r(e,r){for(var a={},c=[],i=0;i<e.length;i++){var s=e[i],u=r.base?s[0]+r.base:s[0],f=a[u]||0,l="".concat(u," ").concat(f);a[u]=f+1;var p=n(l),d={css:s[1],media:s[2],sourceMap:s[3],supports:s[4],layer:s[5]};if(-1!==p)t[p].references++,t[p].updater(d);else{var v=o(d,r);r.byIndex=i,t.splice(i,0,{identifier:l,updater:v,references:1})}c.push(l)}return c}function o(e,t){var n=t.domAPI(t);return n.update(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap&&t.supports===e.supports&&t.layer===e.layer)return;n.update(e=t)}else n.remove()}}e.exports=function(e,o){var a=r(e=e||[],o=o||{});return function(e){e=e||[];for(var c=0;c<a.length;c++){var i=n(a[c]);t[i].references--}for(var s=r(e,o),u=0;u<a.length;u++){var f=n(a[u]);0===t[f].references&&(t[f].updater(),t.splice(f,1))}a=s}}},569:function(e){var t={};e.exports=function(e,n){var r=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},216:function(e){e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},565:function(e,t,n){e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},795:function(e){e.exports=function(e){var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var o=void 0!==n.layer;o&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,o&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var a=n.sourceMap;a&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),t.styleTagTransform(r,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},589:function(e){e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},161:function(t){t.exports=e},439:function(e){e.exports=t},937:function(e){e.exports=n}},o={};function a(e){var t=o[e];if(void 0!==t)return t.exports;var n=o[e]={id:e,exports:{}};return r[e](n,n.exports,a),n.exports}a.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return a.d(t,{a:t}),t},a.d=function(e,t){for(var n in t)a.o(t,n)&&!a.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},a.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},a.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var c={};return function(){a.r(c),a.d(c,{default:function(){return S}});var e=a(161),t=a.n(e),n=a(439),r=a(937),o=a(379),i=a.n(o),s=a(795),u=a.n(s),f=a(569),l=a.n(f),p=a(565),d=a.n(p),v=a(216),m=a.n(v),h=a(589),y=a.n(h),g=a(233),b={};b.styleTagTransform=y(),b.setAttributes=d(),b.insert=l().bind(null,"head"),b.domAPI=u(),b.insertStyleElement=m(),i()(g.Z,b);var x=g.Z&&g.Z.locals?g.Z.locals:void 0;function C(e,t,n,r,o,a,c){try{var i=e[a](c),s=i.value}catch(e){return void n(e)}i.done?t(s):Promise.resolve(s).then(r,o)}function A(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var a=e.apply(t,n);function c(e){C(a,r,o,c,i,"next",e)}function i(e){C(a,r,o,c,i,"throw",e)}c(void 0)}))}}var E=function(e){var o=(0,n.useParams)().id;return t().createElement("div",{className:x.container},t().createElement(r.Card,{hoverable:!0,style:{width:240},cover:t().createElement("img",{alt:"example",src:"https://os.alipayobjects.com/rmsportal/QBnOOoLaAfKPirc.png"}),actions:[o?t().createElement(r.Button,{key:"next",onClick:function(){return e.$dispatch("next","setValue",1)}},"Next"):t().createElement(r.Button,{key:"locale",onClick:function(){return e.$dispatch("store","setLocale","zh"===e.$store.locale?"en":"zh")}},"locale"),t().createElement(r.Button,{key:"store",type:"primary",onClick:A(regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,e.$dispatch("store","setName","".concat(Math.random().toFixed(2)));case 2:r.message.info("changed");case 3:case"end":return t.stop()}}),t)})))},"Store")]},t().createElement(r.Card.Meta,{title:"Route Params",description:o||"none"})))};E.getName=function(e){return r.message.info(e.value)};var S=E}(),c}()}));
1
+ define(["react","react-router-dom","antd"],(function(e,t,n){return function(){"use strict";var r={233:function(e,t,n){var r=n(537),o=n.n(r),a=n(645),c=n.n(a)()(o());c.push([e.id,".container_Lng5c {\n margin-top: 30px;\n}\n","",{version:3,sources:["webpack://./src/components/card.less"],names:[],mappings:"AAAA;EACE,gBAAA;AACF",sourcesContent:[".container {\n margin-top: 30px;\n}\n"],sourceRoot:""}]),c.locals={container:"container_Lng5c"},t.Z=c},645:function(e){e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,o,a){"string"==typeof e&&(e=[[null,e,void 0]]);var c={};if(r)for(var i=0;i<this.length;i++){var s=this[i][0];null!=s&&(c[s]=!0)}for(var u=0;u<e.length;u++){var l=[].concat(e[u]);r&&c[l[0]]||(void 0!==a&&(void 0===l[5]||(l[1]="@layer".concat(l[5].length>0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=a),n&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=n):l[2]=n),o&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=o):l[4]="".concat(o)),t.push(l))}},t}},537:function(e){e.exports=function(e){var t=e[1],n=e[3];if(!n)return t;if("function"==typeof btoa){var r=btoa(unescape(encodeURIComponent(JSON.stringify(n)))),o="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(r),a="/*# ".concat(o," */"),c=n.sources.map((function(e){return"/*# sourceURL=".concat(n.sourceRoot||"").concat(e," */")}));return[t].concat(c).concat([a]).join("\n")}return[t].join("\n")}},379:function(e){var t=[];function n(e){for(var n=-1,r=0;r<t.length;r++)if(t[r].identifier===e){n=r;break}return n}function r(e,r){for(var a={},c=[],i=0;i<e.length;i++){var s=e[i],u=r.base?s[0]+r.base:s[0],l=a[u]||0,p="".concat(u," ").concat(l);a[u]=l+1;var f=n(p),d={css:s[1],media:s[2],sourceMap:s[3],supports:s[4],layer:s[5]};if(-1!==f)t[f].references++,t[f].updater(d);else{var m=o(d,r);r.byIndex=i,t.splice(i,0,{identifier:p,updater:m,references:1})}c.push(p)}return c}function o(e,t){var n=t.domAPI(t);return n.update(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap&&t.supports===e.supports&&t.layer===e.layer)return;n.update(e=t)}else n.remove()}}e.exports=function(e,o){var a=r(e=e||[],o=o||{});return function(e){e=e||[];for(var c=0;c<a.length;c++){var i=n(a[c]);t[i].references--}for(var s=r(e,o),u=0;u<a.length;u++){var l=n(a[u]);0===t[l].references&&(t[l].updater(),t.splice(l,1))}a=s}}},569:function(e){var t={};e.exports=function(e,n){var r=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},216:function(e){e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},565:function(e,t,n){e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},795:function(e){e.exports=function(e){var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var o=void 0!==n.layer;o&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,o&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var a=n.sourceMap;a&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),t.styleTagTransform(r,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},589:function(e){e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},161:function(t){t.exports=e},439:function(e){e.exports=t},937:function(e){e.exports=n}},o={};function a(e){var t=o[e];if(void 0!==t)return t.exports;var n=o[e]={id:e,exports:{}};return r[e](n,n.exports,a),n.exports}a.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return a.d(t,{a:t}),t},a.d=function(e,t){for(var n in t)a.o(t,n)&&!a.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},a.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},a.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var c={};return function(){a.r(c),a.d(c,{default:function(){return A}});var e=a(161),t=a.n(e),n=a(439),r=a(937),o=a(379),i=a.n(o),s=a(795),u=a.n(s),l=a(569),p=a.n(l),f=a(565),d=a.n(f),m=a(216),v=a.n(m),h=a(589),y=a.n(h),g=a(233),b={};b.styleTagTransform=y(),b.setAttributes=d(),b.insert=p().bind(null,"head"),b.domAPI=u(),b.insertStyleElement=v(),i()(g.Z,b);var x=g.Z&&g.Z.locals?g.Z.locals:void 0;const C=e=>{const{id:o}=(0,n.useParams)();return t().createElement("div",{className:x.container},t().createElement(r.Card,{hoverable:!0,style:{width:240},cover:t().createElement("img",{alt:"example",src:"https://os.alipayobjects.com/rmsportal/QBnOOoLaAfKPirc.png"}),actions:[o?t().createElement(r.Button,{key:"next",onClick:()=>e.$dispatch("next","setValue",1)},"Next"):t().createElement(r.Button,{key:"locale",onClick:()=>e.$dispatch("store","setLocale","zh"===e.$store.locale?"en":"zh")},"locale"),t().createElement(r.Button,{key:"store",type:"primary",onClick:async()=>{await e.$dispatch("store","setName",`${Math.random().toFixed(2)}`),r.message.info("changed")}},"Store")]},t().createElement(r.Card.Meta,{title:"Route Params",description:o||"none"})))};C.getName=e=>r.message.info(e);var A=C}(),c}()}));
2
2
  //# sourceMappingURL=card.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"card.js","mappings":"qJAGIA,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,+CAAgD,GAAG,CAAC,QAAU,EAAE,QAAU,CAAC,w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AlF,GAFC,UAMZ,kBAAC,EAAAJ,OAAD,CACE1B,IAAI,QACJ+B,KAAK,UACLJ,QAAO,2BAAE,6GACDZ,EAAMa,UAAU,QAAS,UAAzB,UAAuCI,KAAKC,SAASC,QAAQ,KAD5D,OAEPC,EAAAA,QAAAA,KAAa,WAFN,4CAHX,WAYF,kBAAC,EAAAhB,KAAA,KAAD,CACEiB,MAAM,eACNC,YAAarJ,GAAM,UAK5B,EAED8H,EAAEwB,QAAU,SAACzE,GAAD,OAAOsE,EAAAA,QAAAA,KAAatE,EAAEgD,MAAtB,EAEZ,O","sources":["webpack://@variousjs/create/./src/components/card.less","webpack://@variousjs/create/./node_modules/css-loader/dist/runtime/api.js","webpack://@variousjs/create/./node_modules/css-loader/dist/runtime/sourceMaps.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/insertBySelector.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/insertStyleElement.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/styleDomAPI.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/styleTagTransform.js","webpack://@variousjs/create/external amd {\"root\":\"React\",\"amd\":\"react\"}","webpack://@variousjs/create/external amd {\"root\":\"ReactRouterDOM\",\"amd\":\"react-router-dom\"}","webpack://@variousjs/create/external amd {\"root\":\"antd\",\"amd\":\"antd\"}","webpack://@variousjs/create/webpack/bootstrap","webpack://@variousjs/create/webpack/runtime/compat get default export","webpack://@variousjs/create/webpack/runtime/define property getters","webpack://@variousjs/create/webpack/runtime/hasOwnProperty shorthand","webpack://@variousjs/create/webpack/runtime/make namespace object","webpack://@variousjs/create/./src/components/card.less?0fd9","webpack://@variousjs/create/./src/components/card.tsx"],"sourcesContent":["// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".container_Lng5c {\\n margin-top: 30px;\\n}\\n\", \"\",{\"version\":3,\"sources\":[\"webpack://./src/components/card.less\"],\"names\":[],\"mappings\":\"AAAA;EACE,gBAAA;AACF\",\"sourcesContent\":[\".container {\\n margin-top: 30px;\\n}\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\n___CSS_LOADER_EXPORT___.locals = {\n\t\"container\": \"container_Lng5c\"\n};\nexport default ___CSS_LOADER_EXPORT___;\n","\"use strict\";\n\n/*\n MIT License http://www.opensource.org/licenses/mit-license.php\n Author Tobias Koppers @sokra\n*/\nmodule.exports = function (cssWithMappingToString) {\n var list = []; // return the list of modules as css string\n\n list.toString = function toString() {\n return this.map(function (item) {\n var content = \"\";\n var needLayer = typeof item[5] !== \"undefined\";\n\n if (item[4]) {\n content += \"@supports (\".concat(item[4], \") {\");\n }\n\n if (item[2]) {\n content += \"@media \".concat(item[2], \" {\");\n }\n\n if (needLayer) {\n content += \"@layer\".concat(item[5].length > 0 ? \" \".concat(item[5]) : \"\", \" {\");\n }\n\n content += cssWithMappingToString(item);\n\n if (needLayer) {\n content += \"}\";\n }\n\n if (item[2]) {\n content += \"}\";\n }\n\n if (item[4]) {\n content += \"}\";\n }\n\n return content;\n }).join(\"\");\n }; // import a list of modules into the list\n\n\n list.i = function i(modules, media, dedupe, supports, layer) {\n if (typeof modules === \"string\") {\n modules = [[null, modules, undefined]];\n }\n\n var alreadyImportedModules = {};\n\n if (dedupe) {\n for (var _i = 0; _i < this.length; _i++) {\n var id = this[_i][0];\n\n if (id != null) {\n alreadyImportedModules[id] = true;\n }\n }\n }\n\n for (var _i2 = 0; _i2 < modules.length; _i2++) {\n var item = [].concat(modules[_i2]);\n\n if (dedupe && alreadyImportedModules[item[0]]) {\n continue;\n }\n\n if (typeof layer !== \"undefined\") {\n if (typeof item[5] === \"undefined\") {\n item[5] = layer;\n } else {\n item[1] = \"@layer\".concat(item[5].length > 0 ? \" \".concat(item[5]) : \"\", \" {\").concat(item[1], \"}\");\n item[5] = layer;\n }\n }\n\n if (media) {\n if (!item[2]) {\n item[2] = media;\n } else {\n item[1] = \"@media \".concat(item[2], \" {\").concat(item[1], \"}\");\n item[2] = media;\n }\n }\n\n if (supports) {\n if (!item[4]) {\n item[4] = \"\".concat(supports);\n } else {\n item[1] = \"@supports (\".concat(item[4], \") {\").concat(item[1], \"}\");\n item[4] = supports;\n }\n }\n\n list.push(item);\n }\n };\n\n return list;\n};","\"use strict\";\n\nmodule.exports = function (item) {\n var content = item[1];\n var cssMapping = item[3];\n\n if (!cssMapping) {\n return content;\n }\n\n if (typeof btoa === \"function\") {\n var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(cssMapping))));\n var data = \"sourceMappingURL=data:application/json;charset=utf-8;base64,\".concat(base64);\n var sourceMapping = \"/*# \".concat(data, \" */\");\n var sourceURLs = cssMapping.sources.map(function (source) {\n return \"/*# sourceURL=\".concat(cssMapping.sourceRoot || \"\").concat(source, \" */\");\n });\n return [content].concat(sourceURLs).concat([sourceMapping]).join(\"\\n\");\n }\n\n return [content].join(\"\\n\");\n};","\"use strict\";\n\nvar stylesInDOM = [];\n\nfunction getIndexByIdentifier(identifier) {\n var result = -1;\n\n for (var i = 0; i < stylesInDOM.length; i++) {\n if (stylesInDOM[i].identifier === identifier) {\n result = i;\n break;\n }\n }\n\n return result;\n}\n\nfunction modulesToDom(list, options) {\n var idCountMap = {};\n var identifiers = [];\n\n for (var i = 0; i < list.length; i++) {\n var item = list[i];\n var id = options.base ? item[0] + options.base : item[0];\n var count = idCountMap[id] || 0;\n var identifier = \"\".concat(id, \" \").concat(count);\n idCountMap[id] = count + 1;\n var indexByIdentifier = getIndexByIdentifier(identifier);\n var obj = {\n css: item[1],\n media: item[2],\n sourceMap: item[3],\n supports: item[4],\n layer: item[5]\n };\n\n if (indexByIdentifier !== -1) {\n stylesInDOM[indexByIdentifier].references++;\n stylesInDOM[indexByIdentifier].updater(obj);\n } else {\n var updater = addElementStyle(obj, options);\n options.byIndex = i;\n stylesInDOM.splice(i, 0, {\n identifier: identifier,\n updater: updater,\n references: 1\n });\n }\n\n identifiers.push(identifier);\n }\n\n return identifiers;\n}\n\nfunction addElementStyle(obj, options) {\n var api = options.domAPI(options);\n api.update(obj);\n\n var updater = function updater(newObj) {\n if (newObj) {\n if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap && newObj.supports === obj.supports && newObj.layer === obj.layer) {\n return;\n }\n\n api.update(obj = newObj);\n } else {\n api.remove();\n }\n };\n\n return updater;\n}\n\nmodule.exports = function (list, options) {\n options = options || {};\n list = list || [];\n var lastIdentifiers = modulesToDom(list, options);\n return function update(newList) {\n newList = newList || [];\n\n for (var i = 0; i < lastIdentifiers.length; i++) {\n var identifier = lastIdentifiers[i];\n var index = getIndexByIdentifier(identifier);\n stylesInDOM[index].references--;\n }\n\n var newLastIdentifiers = modulesToDom(newList, options);\n\n for (var _i = 0; _i < lastIdentifiers.length; _i++) {\n var _identifier = lastIdentifiers[_i];\n\n var _index = getIndexByIdentifier(_identifier);\n\n if (stylesInDOM[_index].references === 0) {\n stylesInDOM[_index].updater();\n\n stylesInDOM.splice(_index, 1);\n }\n }\n\n lastIdentifiers = newLastIdentifiers;\n };\n};","\"use strict\";\n\nvar memo = {};\n/* istanbul ignore next */\n\nfunction getTarget(target) {\n if (typeof memo[target] === \"undefined\") {\n var styleTarget = document.querySelector(target); // Special case to return head of iframe instead of iframe itself\n\n if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {\n try {\n // This will throw an exception if access to iframe is blocked\n // due to cross-origin restrictions\n styleTarget = styleTarget.contentDocument.head;\n } catch (e) {\n // istanbul ignore next\n styleTarget = null;\n }\n }\n\n memo[target] = styleTarget;\n }\n\n return memo[target];\n}\n/* istanbul ignore next */\n\n\nfunction insertBySelector(insert, style) {\n var target = getTarget(insert);\n\n if (!target) {\n throw new Error(\"Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.\");\n }\n\n target.appendChild(style);\n}\n\nmodule.exports = insertBySelector;","\"use strict\";\n\n/* istanbul ignore next */\nfunction insertStyleElement(options) {\n var element = document.createElement(\"style\");\n options.setAttributes(element, options.attributes);\n options.insert(element, options.options);\n return element;\n}\n\nmodule.exports = insertStyleElement;","\"use strict\";\n\n/* istanbul ignore next */\nfunction setAttributesWithoutAttributes(styleElement) {\n var nonce = typeof __webpack_nonce__ !== \"undefined\" ? __webpack_nonce__ : null;\n\n if (nonce) {\n styleElement.setAttribute(\"nonce\", nonce);\n }\n}\n\nmodule.exports = setAttributesWithoutAttributes;","\"use strict\";\n\n/* istanbul ignore next */\nfunction apply(styleElement, options, obj) {\n var css = \"\";\n\n if (obj.supports) {\n css += \"@supports (\".concat(obj.supports, \") {\");\n }\n\n if (obj.media) {\n css += \"@media \".concat(obj.media, \" {\");\n }\n\n var needLayer = typeof obj.layer !== \"undefined\";\n\n if (needLayer) {\n css += \"@layer\".concat(obj.layer.length > 0 ? \" \".concat(obj.layer) : \"\", \" {\");\n }\n\n css += obj.css;\n\n if (needLayer) {\n css += \"}\";\n }\n\n if (obj.media) {\n css += \"}\";\n }\n\n if (obj.supports) {\n css += \"}\";\n }\n\n var sourceMap = obj.sourceMap;\n\n if (sourceMap && typeof btoa !== \"undefined\") {\n css += \"\\n/*# sourceMappingURL=data:application/json;base64,\".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), \" */\");\n } // For old IE\n\n /* istanbul ignore if */\n\n\n options.styleTagTransform(css, styleElement, options.options);\n}\n\nfunction removeStyleElement(styleElement) {\n // istanbul ignore if\n if (styleElement.parentNode === null) {\n return false;\n }\n\n styleElement.parentNode.removeChild(styleElement);\n}\n/* istanbul ignore next */\n\n\nfunction domAPI(options) {\n var styleElement = options.insertStyleElement(options);\n return {\n update: function update(obj) {\n apply(styleElement, options, obj);\n },\n remove: function remove() {\n removeStyleElement(styleElement);\n }\n };\n}\n\nmodule.exports = domAPI;","\"use strict\";\n\n/* istanbul ignore next */\nfunction styleTagTransform(css, styleElement) {\n if (styleElement.styleSheet) {\n styleElement.styleSheet.cssText = css;\n } else {\n while (styleElement.firstChild) {\n styleElement.removeChild(styleElement.firstChild);\n }\n\n styleElement.appendChild(document.createTextNode(css));\n }\n}\n\nmodule.exports = styleTagTransform;","module.exports = __WEBPACK_EXTERNAL_MODULE__161__;","module.exports = __WEBPACK_EXTERNAL_MODULE__439__;","module.exports = __WEBPACK_EXTERNAL_MODULE__937__;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","\n import API from \"!../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!../../node_modules/less-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./card.less\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!../../node_modules/less-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./card.less\";\n export default content && content.locals ? content.locals : undefined;\n","import React, { FC } from 'react'\nimport { ComponentProps, Invoker } from '@variousjs/various'\nimport { useParams } from 'react-router-dom'\nimport { Card, Button, message } from 'antd'\nimport { Store } from '../types'\nimport csses from './card.less'\n\nconst H: FC<ComponentProps<Store>> & { getName: Invoker } = (props) => {\n const { id } = useParams<{ id: string }>()\n\n return (\n <div className={csses.container}>\n <Card\n hoverable\n style={{ width: 240 }}\n cover={<img alt=\"example\" src=\"https://os.alipayobjects.com/rmsportal/QBnOOoLaAfKPirc.png\" />}\n actions={[\n id ? <Button\n key=\"next\"\n onClick={() => props.$dispatch('next', 'setValue', 1)}\n >\n Next\n </Button> : <Button\n key=\"locale\"\n onClick={() => props.$dispatch('store', 'setLocale', props.$store.locale === 'zh' ? 'en' : 'zh')}\n >\n locale\n </Button>,\n <Button\n key=\"store\"\n type=\"primary\"\n onClick={async () => {\n await props.$dispatch('store', 'setName', `${Math.random().toFixed(2)}`)\n message.info('changed')\n }}\n >\n Store\n </Button>\n ]}\n >\n <Card.Meta\n title=\"Route Params\"\n description={id || 'none'}\n />\n </Card>\n </div>\n )\n}\n\nH.getName = (e) => message.info(e.value)\n\nexport default H\n"],"names":["___CSS_LOADER_EXPORT___","push","module","id","locals","exports","cssWithMappingToString","list","toString","this","map","item","content","needLayer","concat","length","join","i","modules","media","dedupe","supports","layer","undefined","alreadyImportedModules","_i","_i2","cssMapping","btoa","base64","unescape","encodeURIComponent","JSON","stringify","data","sourceMapping","sourceURLs","sources","source","sourceRoot","stylesInDOM","getIndexByIdentifier","identifier","result","modulesToDom","options","idCountMap","identifiers","base","count","indexByIdentifier","obj","css","sourceMap","references","updater","addElementStyle","byIndex","splice","api","domAPI","update","newObj","remove","lastIdentifiers","newList","index","newLastIdentifiers","_index","memo","insert","style","target","styleTarget","document","querySelector","window","HTMLIFrameElement","contentDocument","head","e","getTarget","Error","appendChild","element","createElement","setAttributes","attributes","styleElement","nonce","setAttribute","insertStyleElement","styleTagTransform","apply","parentNode","removeChild","removeStyleElement","styleSheet","cssText","firstChild","createTextNode","__WEBPACK_EXTERNAL_MODULE__161__","__WEBPACK_EXTERNAL_MODULE__439__","__WEBPACK_EXTERNAL_MODULE__937__","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","__webpack_modules__","n","getter","__esModule","d","a","definition","key","o","Object","defineProperty","enumerable","get","prop","prototype","hasOwnProperty","call","r","Symbol","toStringTag","value","H","props","useParams","className","csses","Card","hoverable","width","cover","alt","src","actions","Button","onClick","$dispatch","$store","locale","type","Math","random","toFixed","message","title","description","getName"],"sourceRoot":""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,kBAAC,EAAAF,OAAD,CACV1B,IAAI,SACJ2B,QAAS,IAAMZ,EAAMa,UAAU,QAAS,YAAqC,OAAxBb,EAAMc,OAAOC,OAAkB,KAAO,OAFjF,UAMZ,kBAAC,EAAAJ,OAAD,CACE1B,IAAI,QACJ+B,KAAK,UACLJ,QAASK,gBACDjB,EAAMa,UAAU,QAAS,UAAY,GAAEK,KAAKC,SAASC,QAAQ,MACnEC,EAAAA,QAAAA,KAAa,UAAb,GALJ,WAYF,kBAAC,EAAAjB,KAAA,KAAD,CACEkB,MAAM,eACNC,YAAatJ,GAAM,UAhC3B,EAuCF8H,EAAEyB,QAAW1E,GAAMuE,EAAAA,QAAAA,KAAavE,GAEhC,O","sources":["webpack://@variousjs/create/./src/components/card.less","webpack://@variousjs/create/./node_modules/css-loader/dist/runtime/api.js","webpack://@variousjs/create/./node_modules/css-loader/dist/runtime/sourceMaps.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/insertBySelector.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/insertStyleElement.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/styleDomAPI.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/styleTagTransform.js","webpack://@variousjs/create/external amd {\"root\":\"React\",\"amd\":\"react\"}","webpack://@variousjs/create/external amd {\"root\":\"ReactRouterDOM\",\"amd\":\"react-router-dom\"}","webpack://@variousjs/create/external amd {\"root\":\"antd\",\"amd\":\"antd\"}","webpack://@variousjs/create/webpack/bootstrap","webpack://@variousjs/create/webpack/runtime/compat get default export","webpack://@variousjs/create/webpack/runtime/define property getters","webpack://@variousjs/create/webpack/runtime/hasOwnProperty shorthand","webpack://@variousjs/create/webpack/runtime/make namespace object","webpack://@variousjs/create/./src/components/card.less?0fd9","webpack://@variousjs/create/./src/components/card.tsx"],"sourcesContent":["// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".container_Lng5c {\\n margin-top: 30px;\\n}\\n\", \"\",{\"version\":3,\"sources\":[\"webpack://./src/components/card.less\"],\"names\":[],\"mappings\":\"AAAA;EACE,gBAAA;AACF\",\"sourcesContent\":[\".container {\\n margin-top: 30px;\\n}\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\n___CSS_LOADER_EXPORT___.locals = {\n\t\"container\": \"container_Lng5c\"\n};\nexport default ___CSS_LOADER_EXPORT___;\n","\"use strict\";\n\n/*\n MIT License http://www.opensource.org/licenses/mit-license.php\n Author Tobias Koppers @sokra\n*/\nmodule.exports = function (cssWithMappingToString) {\n var list = []; // return the list of modules as css string\n\n list.toString = function toString() {\n return this.map(function (item) {\n var content = \"\";\n var needLayer = typeof item[5] !== \"undefined\";\n\n if (item[4]) {\n content += \"@supports (\".concat(item[4], \") {\");\n }\n\n if (item[2]) {\n content += \"@media \".concat(item[2], \" {\");\n }\n\n if (needLayer) {\n content += \"@layer\".concat(item[5].length > 0 ? \" \".concat(item[5]) : \"\", \" {\");\n }\n\n content += cssWithMappingToString(item);\n\n if (needLayer) {\n content += \"}\";\n }\n\n if (item[2]) {\n content += \"}\";\n }\n\n if (item[4]) {\n content += \"}\";\n }\n\n return content;\n }).join(\"\");\n }; // import a list of modules into the list\n\n\n list.i = function i(modules, media, dedupe, supports, layer) {\n if (typeof modules === \"string\") {\n modules = [[null, modules, undefined]];\n }\n\n var alreadyImportedModules = {};\n\n if (dedupe) {\n for (var _i = 0; _i < this.length; _i++) {\n var id = this[_i][0];\n\n if (id != null) {\n alreadyImportedModules[id] = true;\n }\n }\n }\n\n for (var _i2 = 0; _i2 < modules.length; _i2++) {\n var item = [].concat(modules[_i2]);\n\n if (dedupe && alreadyImportedModules[item[0]]) {\n continue;\n }\n\n if (typeof layer !== \"undefined\") {\n if (typeof item[5] === \"undefined\") {\n item[5] = layer;\n } else {\n item[1] = \"@layer\".concat(item[5].length > 0 ? \" \".concat(item[5]) : \"\", \" {\").concat(item[1], \"}\");\n item[5] = layer;\n }\n }\n\n if (media) {\n if (!item[2]) {\n item[2] = media;\n } else {\n item[1] = \"@media \".concat(item[2], \" {\").concat(item[1], \"}\");\n item[2] = media;\n }\n }\n\n if (supports) {\n if (!item[4]) {\n item[4] = \"\".concat(supports);\n } else {\n item[1] = \"@supports (\".concat(item[4], \") {\").concat(item[1], \"}\");\n item[4] = supports;\n }\n }\n\n list.push(item);\n }\n };\n\n return list;\n};","\"use strict\";\n\nmodule.exports = function (item) {\n var content = item[1];\n var cssMapping = item[3];\n\n if (!cssMapping) {\n return content;\n }\n\n if (typeof btoa === \"function\") {\n var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(cssMapping))));\n var data = \"sourceMappingURL=data:application/json;charset=utf-8;base64,\".concat(base64);\n var sourceMapping = \"/*# \".concat(data, \" */\");\n var sourceURLs = cssMapping.sources.map(function (source) {\n return \"/*# sourceURL=\".concat(cssMapping.sourceRoot || \"\").concat(source, \" */\");\n });\n return [content].concat(sourceURLs).concat([sourceMapping]).join(\"\\n\");\n }\n\n return [content].join(\"\\n\");\n};","\"use strict\";\n\nvar stylesInDOM = [];\n\nfunction getIndexByIdentifier(identifier) {\n var result = -1;\n\n for (var i = 0; i < stylesInDOM.length; i++) {\n if (stylesInDOM[i].identifier === identifier) {\n result = i;\n break;\n }\n }\n\n return result;\n}\n\nfunction modulesToDom(list, options) {\n var idCountMap = {};\n var identifiers = [];\n\n for (var i = 0; i < list.length; i++) {\n var item = list[i];\n var id = options.base ? item[0] + options.base : item[0];\n var count = idCountMap[id] || 0;\n var identifier = \"\".concat(id, \" \").concat(count);\n idCountMap[id] = count + 1;\n var indexByIdentifier = getIndexByIdentifier(identifier);\n var obj = {\n css: item[1],\n media: item[2],\n sourceMap: item[3],\n supports: item[4],\n layer: item[5]\n };\n\n if (indexByIdentifier !== -1) {\n stylesInDOM[indexByIdentifier].references++;\n stylesInDOM[indexByIdentifier].updater(obj);\n } else {\n var updater = addElementStyle(obj, options);\n options.byIndex = i;\n stylesInDOM.splice(i, 0, {\n identifier: identifier,\n updater: updater,\n references: 1\n });\n }\n\n identifiers.push(identifier);\n }\n\n return identifiers;\n}\n\nfunction addElementStyle(obj, options) {\n var api = options.domAPI(options);\n api.update(obj);\n\n var updater = function updater(newObj) {\n if (newObj) {\n if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap && newObj.supports === obj.supports && newObj.layer === obj.layer) {\n return;\n }\n\n api.update(obj = newObj);\n } else {\n api.remove();\n }\n };\n\n return updater;\n}\n\nmodule.exports = function (list, options) {\n options = options || {};\n list = list || [];\n var lastIdentifiers = modulesToDom(list, options);\n return function update(newList) {\n newList = newList || [];\n\n for (var i = 0; i < lastIdentifiers.length; i++) {\n var identifier = lastIdentifiers[i];\n var index = getIndexByIdentifier(identifier);\n stylesInDOM[index].references--;\n }\n\n var newLastIdentifiers = modulesToDom(newList, options);\n\n for (var _i = 0; _i < lastIdentifiers.length; _i++) {\n var _identifier = lastIdentifiers[_i];\n\n var _index = getIndexByIdentifier(_identifier);\n\n if (stylesInDOM[_index].references === 0) {\n stylesInDOM[_index].updater();\n\n stylesInDOM.splice(_index, 1);\n }\n }\n\n lastIdentifiers = newLastIdentifiers;\n };\n};","\"use strict\";\n\nvar memo = {};\n/* istanbul ignore next */\n\nfunction getTarget(target) {\n if (typeof memo[target] === \"undefined\") {\n var styleTarget = document.querySelector(target); // Special case to return head of iframe instead of iframe itself\n\n if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {\n try {\n // This will throw an exception if access to iframe is blocked\n // due to cross-origin restrictions\n styleTarget = styleTarget.contentDocument.head;\n } catch (e) {\n // istanbul ignore next\n styleTarget = null;\n }\n }\n\n memo[target] = styleTarget;\n }\n\n return memo[target];\n}\n/* istanbul ignore next */\n\n\nfunction insertBySelector(insert, style) {\n var target = getTarget(insert);\n\n if (!target) {\n throw new Error(\"Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.\");\n }\n\n target.appendChild(style);\n}\n\nmodule.exports = insertBySelector;","\"use strict\";\n\n/* istanbul ignore next */\nfunction insertStyleElement(options) {\n var element = document.createElement(\"style\");\n options.setAttributes(element, options.attributes);\n options.insert(element, options.options);\n return element;\n}\n\nmodule.exports = insertStyleElement;","\"use strict\";\n\n/* istanbul ignore next */\nfunction setAttributesWithoutAttributes(styleElement) {\n var nonce = typeof __webpack_nonce__ !== \"undefined\" ? __webpack_nonce__ : null;\n\n if (nonce) {\n styleElement.setAttribute(\"nonce\", nonce);\n }\n}\n\nmodule.exports = setAttributesWithoutAttributes;","\"use strict\";\n\n/* istanbul ignore next */\nfunction apply(styleElement, options, obj) {\n var css = \"\";\n\n if (obj.supports) {\n css += \"@supports (\".concat(obj.supports, \") {\");\n }\n\n if (obj.media) {\n css += \"@media \".concat(obj.media, \" {\");\n }\n\n var needLayer = typeof obj.layer !== \"undefined\";\n\n if (needLayer) {\n css += \"@layer\".concat(obj.layer.length > 0 ? \" \".concat(obj.layer) : \"\", \" {\");\n }\n\n css += obj.css;\n\n if (needLayer) {\n css += \"}\";\n }\n\n if (obj.media) {\n css += \"}\";\n }\n\n if (obj.supports) {\n css += \"}\";\n }\n\n var sourceMap = obj.sourceMap;\n\n if (sourceMap && typeof btoa !== \"undefined\") {\n css += \"\\n/*# sourceMappingURL=data:application/json;base64,\".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), \" */\");\n } // For old IE\n\n /* istanbul ignore if */\n\n\n options.styleTagTransform(css, styleElement, options.options);\n}\n\nfunction removeStyleElement(styleElement) {\n // istanbul ignore if\n if (styleElement.parentNode === null) {\n return false;\n }\n\n styleElement.parentNode.removeChild(styleElement);\n}\n/* istanbul ignore next */\n\n\nfunction domAPI(options) {\n var styleElement = options.insertStyleElement(options);\n return {\n update: function update(obj) {\n apply(styleElement, options, obj);\n },\n remove: function remove() {\n removeStyleElement(styleElement);\n }\n };\n}\n\nmodule.exports = domAPI;","\"use strict\";\n\n/* istanbul ignore next */\nfunction styleTagTransform(css, styleElement) {\n if (styleElement.styleSheet) {\n styleElement.styleSheet.cssText = css;\n } else {\n while (styleElement.firstChild) {\n styleElement.removeChild(styleElement.firstChild);\n }\n\n styleElement.appendChild(document.createTextNode(css));\n }\n}\n\nmodule.exports = styleTagTransform;","module.exports = __WEBPACK_EXTERNAL_MODULE__161__;","module.exports = __WEBPACK_EXTERNAL_MODULE__439__;","module.exports = __WEBPACK_EXTERNAL_MODULE__937__;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","\n import API from \"!../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!../../node_modules/less-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./card.less\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!../../node_modules/less-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./card.less\";\n export default content && content.locals ? content.locals : undefined;\n","import React, { FC } from 'react'\nimport { ComponentProps, Invoker } from '@variousjs/various'\nimport { useParams } from 'react-router-dom'\nimport { Card, Button, message } from 'antd'\nimport { Store } from '../types'\nimport csses from './card.less'\n\nconst H: FC<ComponentProps<Store>> & { getName: Invoker } = (props) => {\n const { id } = useParams<{ id: string }>()\n\n return (\n <div className={csses.container}>\n <Card\n hoverable\n style={{ width: 240 }}\n cover={<img alt=\"example\" src=\"https://os.alipayobjects.com/rmsportal/QBnOOoLaAfKPirc.png\" />}\n actions={[\n id ? <Button\n key=\"next\"\n onClick={() => props.$dispatch('next', 'setValue', 1)}\n >\n Next\n </Button> : <Button\n key=\"locale\"\n onClick={() => props.$dispatch('store', 'setLocale', props.$store.locale === 'zh' ? 'en' : 'zh')}\n >\n locale\n </Button>,\n <Button\n key=\"store\"\n type=\"primary\"\n onClick={async () => {\n await props.$dispatch('store', 'setName', `${Math.random().toFixed(2)}`)\n message.info('changed')\n }}\n >\n Store\n </Button>\n ]}\n >\n <Card.Meta\n title=\"Route Params\"\n description={id || 'none'}\n />\n </Card>\n </div>\n )\n}\n\nH.getName = (e) => message.info(e)\n\nexport default H\n"],"names":["___CSS_LOADER_EXPORT___","push","module","id","locals","exports","cssWithMappingToString","list","toString","this","map","item","content","needLayer","concat","length","join","i","modules","media","dedupe","supports","layer","undefined","alreadyImportedModules","_i","_i2","cssMapping","btoa","base64","unescape","encodeURIComponent","JSON","stringify","data","sourceMapping","sourceURLs","sources","source","sourceRoot","stylesInDOM","getIndexByIdentifier","identifier","result","modulesToDom","options","idCountMap","identifiers","base","count","indexByIdentifier","obj","css","sourceMap","references","updater","addElementStyle","byIndex","splice","api","domAPI","update","newObj","remove","lastIdentifiers","newList","index","newLastIdentifiers","_index","memo","insert","style","target","styleTarget","document","querySelector","window","HTMLIFrameElement","contentDocument","head","e","getTarget","Error","appendChild","element","createElement","setAttributes","attributes","styleElement","nonce","setAttribute","insertStyleElement","styleTagTransform","apply","parentNode","removeChild","removeStyleElement","styleSheet","cssText","firstChild","createTextNode","__WEBPACK_EXTERNAL_MODULE__161__","__WEBPACK_EXTERNAL_MODULE__439__","__WEBPACK_EXTERNAL_MODULE__937__","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","__webpack_modules__","n","getter","__esModule","d","a","definition","key","o","Object","defineProperty","enumerable","get","prop","prototype","hasOwnProperty","call","r","Symbol","toStringTag","value","H","props","useParams","className","csses","Card","hoverable","width","cover","alt","src","actions","Button","onClick","$dispatch","$store","locale","type","async","Math","random","toFixed","message","title","description","getName"],"sourceRoot":""}
@@ -1,2 +1,2 @@
1
- define(["react","react-router-dom","antd"],(function(e,t,n){return function(){"use strict";var r={674:function(e,t,n){var r=n(537),o=n.n(r),c=n(645),a=n.n(c)()(o());a.push([e.id,".container_moxlt {\n background: #fff;\n padding: 50px;\n}\n.top__WfL2 {\n display: flex;\n align-items: center;\n justify-content: space-between;\n}\n","",{version:3,sources:["webpack://./src/entry/entry.less"],names:[],mappings:"AAAA;EACE,gBAAA;EACA,aAAA;AACF;AACA;EACE,aAAA;EACA,mBAAA;EACA,8BAAA;AACF",sourcesContent:[".container {\n background: #fff;\n padding: 50px;\n}\n.top {\n display: flex;\n align-items: center;\n justify-content: space-between;\n}\n"],sourceRoot:""}]),a.locals={container:"container_moxlt",top:"top__WfL2"},t.Z=a},645:function(e){e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,o,c){"string"==typeof e&&(e=[[null,e,void 0]]);var a={};if(r)for(var i=0;i<this.length;i++){var u=this[i][0];null!=u&&(a[u]=!0)}for(var s=0;s<e.length;s++){var f=[].concat(e[s]);r&&a[f[0]]||(void 0!==c&&(void 0===f[5]||(f[1]="@layer".concat(f[5].length>0?" ".concat(f[5]):""," {").concat(f[1],"}")),f[5]=c),n&&(f[2]?(f[1]="@media ".concat(f[2]," {").concat(f[1],"}"),f[2]=n):f[2]=n),o&&(f[4]?(f[1]="@supports (".concat(f[4],") {").concat(f[1],"}"),f[4]=o):f[4]="".concat(o)),t.push(f))}},t}},537:function(e){e.exports=function(e){var t=e[1],n=e[3];if(!n)return t;if("function"==typeof btoa){var r=btoa(unescape(encodeURIComponent(JSON.stringify(n)))),o="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(r),c="/*# ".concat(o," */"),a=n.sources.map((function(e){return"/*# sourceURL=".concat(n.sourceRoot||"").concat(e," */")}));return[t].concat(a).concat([c]).join("\n")}return[t].join("\n")}},379:function(e){var t=[];function n(e){for(var n=-1,r=0;r<t.length;r++)if(t[r].identifier===e){n=r;break}return n}function r(e,r){for(var c={},a=[],i=0;i<e.length;i++){var u=e[i],s=r.base?u[0]+r.base:u[0],f=c[s]||0,l="".concat(s," ").concat(f);c[s]=f+1;var p=n(l),d={css:u[1],media:u[2],sourceMap:u[3],supports:u[4],layer:u[5]};if(-1!==p)t[p].references++,t[p].updater(d);else{var m=o(d,r);r.byIndex=i,t.splice(i,0,{identifier:l,updater:m,references:1})}a.push(l)}return a}function o(e,t){var n=t.domAPI(t);return n.update(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap&&t.supports===e.supports&&t.layer===e.layer)return;n.update(e=t)}else n.remove()}}e.exports=function(e,o){var c=r(e=e||[],o=o||{});return function(e){e=e||[];for(var a=0;a<c.length;a++){var i=n(c[a]);t[i].references--}for(var u=r(e,o),s=0;s<c.length;s++){var f=n(c[s]);0===t[f].references&&(t[f].updater(),t.splice(f,1))}c=u}}},569:function(e){var t={};e.exports=function(e,n){var r=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},216:function(e){e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},565:function(e,t,n){e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},795:function(e){e.exports=function(e){var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var o=void 0!==n.layer;o&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,o&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var c=n.sourceMap;c&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(c))))," */")),t.styleTagTransform(r,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},589:function(e){e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},161:function(t){t.exports=e},439:function(e){e.exports=t},937:function(e){e.exports=n}},o={};function c(e){var t=o[e];if(void 0!==t)return t.exports;var n=o[e]={id:e,exports:{}};return r[e](n,n.exports,c),n.exports}c.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return c.d(t,{a:t}),t},c.d=function(e,t){for(var n in t)c.o(t,n)&&!c.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},c.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},c.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var a={};return function(){function e(e,t,n,r,o,c,a){try{var i=e[c](a),u=i.value}catch(e){return void n(e)}i.done?t(u):Promise.resolve(u).then(r,o)}function t(t){return function(){var n=this,r=arguments;return new Promise((function(o,c){var a=t.apply(n,r);function i(t){e(a,o,c,i,u,"next",t)}function u(t){e(a,o,c,i,u,"throw",t)}i(void 0)}))}}c.r(a),c.d(a,{Container:function(){return P},Error:function(){return N},Loader:function(){return M},actions:function(){return n},store:function(){return r}});var n={setName:function(e,n){return t(regeneratorRuntime.mark((function t(){var r,o,c,a,i;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e.emit,o=e.getStore,c=n.value,t.next=4,new Promise((function(e){return setTimeout(e,1e3)}));case 4:a=o(),(i=a.user).name=c,r({user:i});case 7:case"end":return t.stop()}}),t)})))()},getName:function(e){return t(regeneratorRuntime.mark((function t(){var n,r,o;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.getStore,r=n(),o=r.user,t.abrupt("return",o.name);case 3:case"end":return t.stop()}}),t)})))()}},r={user:{name:"various"}},o=c(161),i=c.n(o),u=c(439),s=c(379),f=c.n(s),l=c(795),p=c.n(l),d=c(569),m=c.n(d),v=c(565),y=c.n(v),h=c(216),b=c.n(h),g=c(589),A=c.n(g),x=c(674),E={};E.styleTagTransform=A(),E.setAttributes=y(),E.insert=m().bind(null,"head"),E.domAPI=p(),E.insertStyleElement=b(),f()(x.Z,E);var w=x.Z&&x.Z.locals?x.Z.locals:void 0;function C(e){return C="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},C(e)}function S(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function j(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function R(e,t){return R=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},R(e,t)}function O(e,t){if(t&&("object"===C(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function _(e){return _=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},_(e)}var T=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&R(e,t)}(a,e);var t,n,r,o,c=(r=a,o=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=_(r);if(o){var n=_(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return O(this,e)});function a(){return S(this,a),c.apply(this,arguments)}return t=a,(n=[{key:"render",value:function(){var e=this.props,t=e.$component,n=e.$config,r=t("top");return i().createElement("div",{className:w.container},i().createElement(u.HashRouter,null,i().createElement("div",{className:w.top},i().createElement(r,null)),n.pages.map((function(e){var n=e.path,r=e.components;return i().createElement(u.Route,{key:Array.isArray(n)?n.join():n,exact:!0,path:n,component:function(){return r.map((function(e){var n=t(e);return i().createElement("div",{key:e,style:{display:"inline-block",width:300,verticalAlign:"top"}},i().createElement(n,null))}))}})}))))}}])&&j(t.prototype,n),a}(o.Component),P=T,k=c(937);function M(){return i().createElement(k.Spin,null)}var N=function(e){var t=e.reload,n=e.type,r=e.message;return i().createElement(i().Fragment,null,i().createElement(k.Alert,{message:"Error",description:"[".concat(n,"]:").concat(r||"组件错误"),type:"error",style:{marginTop:30}}),t&&i().createElement(k.Button,{onClick:t},"刷新"))}}(),a}()}));
1
+ define(["react","@variousjs/various","react-router-dom","antd"],(function(e,n,t,r){return function(){"use strict";var o={674:function(e,n,t){var r=t(537),o=t.n(r),a=t(645),c=t.n(a)()(o());c.push([e.id,".container_moxlt {\n background: #fff;\n padding: 50px;\n}\n.top__WfL2 {\n display: flex;\n align-items: center;\n justify-content: space-between;\n}\n","",{version:3,sources:["webpack://./src/entry/entry.less"],names:[],mappings:"AAAA;EACE,gBAAA;EACA,aAAA;AACF;AACA;EACE,aAAA;EACA,mBAAA;EACA,8BAAA;AACF",sourcesContent:[".container {\n background: #fff;\n padding: 50px;\n}\n.top {\n display: flex;\n align-items: center;\n justify-content: space-between;\n}\n"],sourceRoot:""}]),c.locals={container:"container_moxlt",top:"top__WfL2"},n.Z=c},645:function(e){e.exports=function(e){var n=[];return n.toString=function(){return this.map((function(n){var t="",r=void 0!==n[5];return n[4]&&(t+="@supports (".concat(n[4],") {")),n[2]&&(t+="@media ".concat(n[2]," {")),r&&(t+="@layer".concat(n[5].length>0?" ".concat(n[5]):""," {")),t+=e(n),r&&(t+="}"),n[2]&&(t+="}"),n[4]&&(t+="}"),t})).join("")},n.i=function(e,t,r,o,a){"string"==typeof e&&(e=[[null,e,void 0]]);var c={};if(r)for(var i=0;i<this.length;i++){var s=this[i][0];null!=s&&(c[s]=!0)}for(var u=0;u<e.length;u++){var l=[].concat(e[u]);r&&c[l[0]]||(void 0!==a&&(void 0===l[5]||(l[1]="@layer".concat(l[5].length>0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=a),t&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=t):l[2]=t),o&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=o):l[4]="".concat(o)),n.push(l))}},n}},537:function(e){e.exports=function(e){var n=e[1],t=e[3];if(!t)return n;if("function"==typeof btoa){var r=btoa(unescape(encodeURIComponent(JSON.stringify(t)))),o="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(r),a="/*# ".concat(o," */"),c=t.sources.map((function(e){return"/*# sourceURL=".concat(t.sourceRoot||"").concat(e," */")}));return[n].concat(c).concat([a]).join("\n")}return[n].join("\n")}},379:function(e){var n=[];function t(e){for(var t=-1,r=0;r<n.length;r++)if(n[r].identifier===e){t=r;break}return t}function r(e,r){for(var a={},c=[],i=0;i<e.length;i++){var s=e[i],u=r.base?s[0]+r.base:s[0],l=a[u]||0,p="".concat(u," ").concat(l);a[u]=l+1;var f=t(p),d={css:s[1],media:s[2],sourceMap:s[3],supports:s[4],layer:s[5]};if(-1!==f)n[f].references++,n[f].updater(d);else{var m=o(d,r);r.byIndex=i,n.splice(i,0,{identifier:p,updater:m,references:1})}c.push(p)}return c}function o(e,n){var t=n.domAPI(n);return t.update(e),function(n){if(n){if(n.css===e.css&&n.media===e.media&&n.sourceMap===e.sourceMap&&n.supports===e.supports&&n.layer===e.layer)return;t.update(e=n)}else t.remove()}}e.exports=function(e,o){var a=r(e=e||[],o=o||{});return function(e){e=e||[];for(var c=0;c<a.length;c++){var i=t(a[c]);n[i].references--}for(var s=r(e,o),u=0;u<a.length;u++){var l=t(a[u]);0===n[l].references&&(n[l].updater(),n.splice(l,1))}a=s}}},569:function(e){var n={};e.exports=function(e,t){var r=function(e){if(void 0===n[e]){var t=document.querySelector(e);if(window.HTMLIFrameElement&&t instanceof window.HTMLIFrameElement)try{t=t.contentDocument.head}catch(e){t=null}n[e]=t}return n[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(t)}},216:function(e){e.exports=function(e){var n=document.createElement("style");return e.setAttributes(n,e.attributes),e.insert(n,e.options),n}},565:function(e,n,t){e.exports=function(e){var n=t.nc;n&&e.setAttribute("nonce",n)}},795:function(e){e.exports=function(e){var n=e.insertStyleElement(e);return{update:function(t){!function(e,n,t){var r="";t.supports&&(r+="@supports (".concat(t.supports,") {")),t.media&&(r+="@media ".concat(t.media," {"));var o=void 0!==t.layer;o&&(r+="@layer".concat(t.layer.length>0?" ".concat(t.layer):""," {")),r+=t.css,o&&(r+="}"),t.media&&(r+="}"),t.supports&&(r+="}");var a=t.sourceMap;a&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),n.styleTagTransform(r,e,n.options)}(n,e,t)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(n)}}}},589:function(e){e.exports=function(e,n){if(n.styleSheet)n.styleSheet.cssText=e;else{for(;n.firstChild;)n.removeChild(n.firstChild);n.appendChild(document.createTextNode(e))}}},161:function(n){n.exports=e},439:function(e){e.exports=t},937:function(e){e.exports=r},437:function(e){e.exports=n}},a={};function c(e){var n=a[e];if(void 0!==n)return n.exports;var t=a[e]={id:e,exports:{}};return o[e](t,t.exports,c),t.exports}c.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return c.d(n,{a:n}),n},c.d=function(e,n){for(var t in n)c.o(n,t)&&!c.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:n[t]})},c.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},c.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};return function(){c.r(i),c.d(i,{Container:function(){return j},Error:function(){return M},Loader:function(){return T},actions:function(){return e},store:function(){return n}});var e={async setName({emit:e,getStore:n},t){await new Promise((e=>setTimeout(e,1e3)));const{user:r}=n();r.name=t,e({user:r})},async getName({getStore:e}){const{user:n}=e();return n.name},async setLocale({emit:e},n){e({locale:n})}},n={user:{name:"various"},locale:"zh"};function t(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}var r=c(161),o=c.n(r),a=c(437),s=c(439),u=c(379),l=c.n(u),p=c(795),f=c.n(p),d=c(569),m=c.n(d),v=c(565),y=c.n(v),g=c(216),h=c.n(g),A=c(589),b=c.n(A),x=c(674),E={};E.styleTagTransform=b(),E.setAttributes=y(),E.insert=m().bind(null,"head"),E.domAPI=f(),E.insertStyleElement=h(),l()(x.Z,E);var C=x.Z&&x.Z.locals?x.Z.locals:void 0;class S extends r.Component{constructor(...e){super(...e),t(this,"config",(0,a.getConfig)()),t(this,"top",(0,r.memo)((0,a.createComponent)("top"))),t(this,"components",this.config.pages.reduce(((e,n)=>(n.components.forEach((n=>{e[n]=(0,r.memo)((0,a.createComponent)(n))})),e)),{}))}render(){const e=this.top,n=this.config;return o().createElement("div",{className:C.container},o().createElement(s.HashRouter,null,o().createElement("div",{className:C.top},o().createElement(e,null)),n.pages.map((({path:e,components:n})=>o().createElement(s.Route,{key:Array.isArray(e)?e.join():e,exact:!0,path:e,component:()=>n.map((e=>{const n=this.components[e];return o().createElement("div",{key:e,style:{display:"inline-block",width:300,verticalAlign:"top"}},o().createElement(n,null))}))})))))}}var j=S,w=c(937);function T(){return o().createElement(w.Spin,null)}var M=({$reload:e,$type:n,$message:t})=>o().createElement(o().Fragment,null,o().createElement(w.Alert,{message:"Error",description:`[${n}]: ${t||"组件错误"}`,type:"error",style:{marginTop:30}}),e&&o().createElement(w.Button,{onClick:e},"刷新"))}(),i}()}));
2
2
  //# sourceMappingURL=entry.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"entry.js","mappings":"qJAGIA,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,+JAAgK,GAAG,CAAC,QAAU,EAAE,QAAU,CAAC,oCAAoC,MAAQ,GAAG,SAAW,2EAA2E,eAAiB,CAAC,oJAAoJ,WAAa,MAE5hBH,EAAwBI,OAAS,CAChC,UAAa,kBACb,IAAO,aAER,O,gBCLAF,EAAOG,QAAU,SAAUC,GACzB,IAAIC,EAAO,GA6FX,OA3FAA,EAAKC,SAAW,WACd,OAAOC,KAAKC,KAAI,SAAUC,GACxB,IAAIC,EAAU,GACVC,OAA+B,IAAZF,EAAK,GA4B5B,OA1BIA,EAAK,KACPC,GAAW,cAAcE,OAAOH,EAAK,GAAI,QAGvCA,EAAK,KACPC,GAAW,UAAUE,OAAOH,EAAK,GAAI,OAGnCE,IACFD,GAAW,SAASE,OAAOH,EAAK,GAAGI,OAAS,EAAI,IAAID,OAAOH,EAAK,IAAM,GAAI,OAG5EC,GAAWN,EAAuBK,GAE9BE,IACFD,GAAW,KAGTD,EAAK,KACPC,GAAW,KAGTD,EAAK,KACPC,GAAW,KAGNA,KACNI,KAAK,KAIVT,EAAKU,EAAI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AASP,GAAjB,Q","sources":["webpack://@variousjs/create/./src/entry/entry.less","webpack://@variousjs/create/./node_modules/css-loader/dist/runtime/api.js","webpack://@variousjs/create/./node_modules/css-loader/dist/runtime/sourceMaps.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/insertBySelector.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/insertStyleElement.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/styleDomAPI.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/styleTagTransform.js","webpack://@variousjs/create/external amd {\"root\":\"React\",\"amd\":\"react\"}","webpack://@variousjs/create/external amd {\"root\":\"ReactRouterDOM\",\"amd\":\"react-router-dom\"}","webpack://@variousjs/create/external amd {\"root\":\"antd\",\"amd\":\"antd\"}","webpack://@variousjs/create/webpack/bootstrap","webpack://@variousjs/create/webpack/runtime/compat get default export","webpack://@variousjs/create/webpack/runtime/define property getters","webpack://@variousjs/create/webpack/runtime/hasOwnProperty shorthand","webpack://@variousjs/create/webpack/runtime/make namespace object","webpack://@variousjs/create/./src/entry/actions.ts","webpack://@variousjs/create/./src/entry/store.ts","webpack://@variousjs/create/./src/entry/entry.less?fe22","webpack://@variousjs/create/./src/entry/container.tsx","webpack://@variousjs/create/./src/entry/loader.tsx","webpack://@variousjs/create/./src/entry/error.tsx"],"sourcesContent":["// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".container_moxlt {\\n background: #fff;\\n padding: 50px;\\n}\\n.top__WfL2 {\\n display: flex;\\n align-items: center;\\n justify-content: space-between;\\n}\\n\", \"\",{\"version\":3,\"sources\":[\"webpack://./src/entry/entry.less\"],\"names\":[],\"mappings\":\"AAAA;EACE,gBAAA;EACA,aAAA;AACF;AACA;EACE,aAAA;EACA,mBAAA;EACA,8BAAA;AACF\",\"sourcesContent\":[\".container {\\n background: #fff;\\n padding: 50px;\\n}\\n.top {\\n display: flex;\\n align-items: center;\\n justify-content: space-between;\\n}\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\n___CSS_LOADER_EXPORT___.locals = {\n\t\"container\": \"container_moxlt\",\n\t\"top\": \"top__WfL2\"\n};\nexport default ___CSS_LOADER_EXPORT___;\n","\"use strict\";\n\n/*\n MIT License http://www.opensource.org/licenses/mit-license.php\n Author Tobias Koppers @sokra\n*/\nmodule.exports = function (cssWithMappingToString) {\n var list = []; // return the list of modules as css string\n\n list.toString = function toString() {\n return this.map(function (item) {\n var content = \"\";\n var needLayer = typeof item[5] !== \"undefined\";\n\n if (item[4]) {\n content += \"@supports (\".concat(item[4], \") {\");\n }\n\n if (item[2]) {\n content += \"@media \".concat(item[2], \" {\");\n }\n\n if (needLayer) {\n content += \"@layer\".concat(item[5].length > 0 ? \" \".concat(item[5]) : \"\", \" {\");\n }\n\n content += cssWithMappingToString(item);\n\n if (needLayer) {\n content += \"}\";\n }\n\n if (item[2]) {\n content += \"}\";\n }\n\n if (item[4]) {\n content += \"}\";\n }\n\n return content;\n }).join(\"\");\n }; // import a list of modules into the list\n\n\n list.i = function i(modules, media, dedupe, supports, layer) {\n if (typeof modules === \"string\") {\n modules = [[null, modules, undefined]];\n }\n\n var alreadyImportedModules = {};\n\n if (dedupe) {\n for (var _i = 0; _i < this.length; _i++) {\n var id = this[_i][0];\n\n if (id != null) {\n alreadyImportedModules[id] = true;\n }\n }\n }\n\n for (var _i2 = 0; _i2 < modules.length; _i2++) {\n var item = [].concat(modules[_i2]);\n\n if (dedupe && alreadyImportedModules[item[0]]) {\n continue;\n }\n\n if (typeof layer !== \"undefined\") {\n if (typeof item[5] === \"undefined\") {\n item[5] = layer;\n } else {\n item[1] = \"@layer\".concat(item[5].length > 0 ? \" \".concat(item[5]) : \"\", \" {\").concat(item[1], \"}\");\n item[5] = layer;\n }\n }\n\n if (media) {\n if (!item[2]) {\n item[2] = media;\n } else {\n item[1] = \"@media \".concat(item[2], \" {\").concat(item[1], \"}\");\n item[2] = media;\n }\n }\n\n if (supports) {\n if (!item[4]) {\n item[4] = \"\".concat(supports);\n } else {\n item[1] = \"@supports (\".concat(item[4], \") {\").concat(item[1], \"}\");\n item[4] = supports;\n }\n }\n\n list.push(item);\n }\n };\n\n return list;\n};","\"use strict\";\n\nmodule.exports = function (item) {\n var content = item[1];\n var cssMapping = item[3];\n\n if (!cssMapping) {\n return content;\n }\n\n if (typeof btoa === \"function\") {\n var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(cssMapping))));\n var data = \"sourceMappingURL=data:application/json;charset=utf-8;base64,\".concat(base64);\n var sourceMapping = \"/*# \".concat(data, \" */\");\n var sourceURLs = cssMapping.sources.map(function (source) {\n return \"/*# sourceURL=\".concat(cssMapping.sourceRoot || \"\").concat(source, \" */\");\n });\n return [content].concat(sourceURLs).concat([sourceMapping]).join(\"\\n\");\n }\n\n return [content].join(\"\\n\");\n};","\"use strict\";\n\nvar stylesInDOM = [];\n\nfunction getIndexByIdentifier(identifier) {\n var result = -1;\n\n for (var i = 0; i < stylesInDOM.length; i++) {\n if (stylesInDOM[i].identifier === identifier) {\n result = i;\n break;\n }\n }\n\n return result;\n}\n\nfunction modulesToDom(list, options) {\n var idCountMap = {};\n var identifiers = [];\n\n for (var i = 0; i < list.length; i++) {\n var item = list[i];\n var id = options.base ? item[0] + options.base : item[0];\n var count = idCountMap[id] || 0;\n var identifier = \"\".concat(id, \" \").concat(count);\n idCountMap[id] = count + 1;\n var indexByIdentifier = getIndexByIdentifier(identifier);\n var obj = {\n css: item[1],\n media: item[2],\n sourceMap: item[3],\n supports: item[4],\n layer: item[5]\n };\n\n if (indexByIdentifier !== -1) {\n stylesInDOM[indexByIdentifier].references++;\n stylesInDOM[indexByIdentifier].updater(obj);\n } else {\n var updater = addElementStyle(obj, options);\n options.byIndex = i;\n stylesInDOM.splice(i, 0, {\n identifier: identifier,\n updater: updater,\n references: 1\n });\n }\n\n identifiers.push(identifier);\n }\n\n return identifiers;\n}\n\nfunction addElementStyle(obj, options) {\n var api = options.domAPI(options);\n api.update(obj);\n\n var updater = function updater(newObj) {\n if (newObj) {\n if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap && newObj.supports === obj.supports && newObj.layer === obj.layer) {\n return;\n }\n\n api.update(obj = newObj);\n } else {\n api.remove();\n }\n };\n\n return updater;\n}\n\nmodule.exports = function (list, options) {\n options = options || {};\n list = list || [];\n var lastIdentifiers = modulesToDom(list, options);\n return function update(newList) {\n newList = newList || [];\n\n for (var i = 0; i < lastIdentifiers.length; i++) {\n var identifier = lastIdentifiers[i];\n var index = getIndexByIdentifier(identifier);\n stylesInDOM[index].references--;\n }\n\n var newLastIdentifiers = modulesToDom(newList, options);\n\n for (var _i = 0; _i < lastIdentifiers.length; _i++) {\n var _identifier = lastIdentifiers[_i];\n\n var _index = getIndexByIdentifier(_identifier);\n\n if (stylesInDOM[_index].references === 0) {\n stylesInDOM[_index].updater();\n\n stylesInDOM.splice(_index, 1);\n }\n }\n\n lastIdentifiers = newLastIdentifiers;\n };\n};","\"use strict\";\n\nvar memo = {};\n/* istanbul ignore next */\n\nfunction getTarget(target) {\n if (typeof memo[target] === \"undefined\") {\n var styleTarget = document.querySelector(target); // Special case to return head of iframe instead of iframe itself\n\n if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {\n try {\n // This will throw an exception if access to iframe is blocked\n // due to cross-origin restrictions\n styleTarget = styleTarget.contentDocument.head;\n } catch (e) {\n // istanbul ignore next\n styleTarget = null;\n }\n }\n\n memo[target] = styleTarget;\n }\n\n return memo[target];\n}\n/* istanbul ignore next */\n\n\nfunction insertBySelector(insert, style) {\n var target = getTarget(insert);\n\n if (!target) {\n throw new Error(\"Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.\");\n }\n\n target.appendChild(style);\n}\n\nmodule.exports = insertBySelector;","\"use strict\";\n\n/* istanbul ignore next */\nfunction insertStyleElement(options) {\n var element = document.createElement(\"style\");\n options.setAttributes(element, options.attributes);\n options.insert(element, options.options);\n return element;\n}\n\nmodule.exports = insertStyleElement;","\"use strict\";\n\n/* istanbul ignore next */\nfunction setAttributesWithoutAttributes(styleElement) {\n var nonce = typeof __webpack_nonce__ !== \"undefined\" ? __webpack_nonce__ : null;\n\n if (nonce) {\n styleElement.setAttribute(\"nonce\", nonce);\n }\n}\n\nmodule.exports = setAttributesWithoutAttributes;","\"use strict\";\n\n/* istanbul ignore next */\nfunction apply(styleElement, options, obj) {\n var css = \"\";\n\n if (obj.supports) {\n css += \"@supports (\".concat(obj.supports, \") {\");\n }\n\n if (obj.media) {\n css += \"@media \".concat(obj.media, \" {\");\n }\n\n var needLayer = typeof obj.layer !== \"undefined\";\n\n if (needLayer) {\n css += \"@layer\".concat(obj.layer.length > 0 ? \" \".concat(obj.layer) : \"\", \" {\");\n }\n\n css += obj.css;\n\n if (needLayer) {\n css += \"}\";\n }\n\n if (obj.media) {\n css += \"}\";\n }\n\n if (obj.supports) {\n css += \"}\";\n }\n\n var sourceMap = obj.sourceMap;\n\n if (sourceMap && typeof btoa !== \"undefined\") {\n css += \"\\n/*# sourceMappingURL=data:application/json;base64,\".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), \" */\");\n } // For old IE\n\n /* istanbul ignore if */\n\n\n options.styleTagTransform(css, styleElement, options.options);\n}\n\nfunction removeStyleElement(styleElement) {\n // istanbul ignore if\n if (styleElement.parentNode === null) {\n return false;\n }\n\n styleElement.parentNode.removeChild(styleElement);\n}\n/* istanbul ignore next */\n\n\nfunction domAPI(options) {\n var styleElement = options.insertStyleElement(options);\n return {\n update: function update(obj) {\n apply(styleElement, options, obj);\n },\n remove: function remove() {\n removeStyleElement(styleElement);\n }\n };\n}\n\nmodule.exports = domAPI;","\"use strict\";\n\n/* istanbul ignore next */\nfunction styleTagTransform(css, styleElement) {\n if (styleElement.styleSheet) {\n styleElement.styleSheet.cssText = css;\n } else {\n while (styleElement.firstChild) {\n styleElement.removeChild(styleElement.firstChild);\n }\n\n styleElement.appendChild(document.createTextNode(css));\n }\n}\n\nmodule.exports = styleTagTransform;","module.exports = __WEBPACK_EXTERNAL_MODULE__161__;","module.exports = __WEBPACK_EXTERNAL_MODULE__439__;","module.exports = __WEBPACK_EXTERNAL_MODULE__937__;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","import { Actions } from '@variousjs/various'\nimport { Store } from '../types'\n\nconst actions: Actions<Store> = {\n async setName({ emit, getStore }, { value }) {\n await new Promise((r) => setTimeout(r, 1000))\n const { user } = getStore()\n user.name = value\n emit({ user })\n },\n async getName({ getStore }) {\n const { user } = getStore()\n return user.name\n },\n}\n\nexport default actions\n","export default {\n user: {\n name: 'various',\n },\n}\n","\n import API from \"!../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!../../node_modules/less-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./entry.less\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!../../node_modules/less-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./entry.less\";\n export default content && content.locals ? content.locals : undefined;\n","import React, { Component, ComponentType } from 'react'\nimport { ContainerProps } from '@variousjs/various'\nimport { HashRouter as Router, Route } from 'react-router-dom'\nimport { Config } from '../types'\nimport csses from './entry.less'\n\nclass Container extends Component<ContainerProps<Config>> {\n render() {\n const { $component, $config } = this.props\n const Top = $component('top')\n\n return (\n <div className={csses.container}>\n <Router>\n <div className={csses.top}>\n <Top />\n </div>\n {\n $config.pages.map(({ path, components }) => {\n const cs = () => components.map((name) => {\n const C = $component(name)\n return (\n <div\n key={name}\n style={{ display: 'inline-block', width: 300, verticalAlign: 'top' }}\n >\n <C />\n </div>\n )\n })\n\n return (\n <Route\n key={Array.isArray(path) ? path.join() : path}\n exact\n path={path}\n component={cs as unknown as ComponentType}\n />\n )\n })\n }\n </Router>\n </div>\n )\n }\n}\n\nexport default Container\n","import React from 'react'\nimport { Spin } from 'antd'\n\nexport default function Loader() {\n return (\n <Spin />\n )\n}\n","import React, { FC } from 'react'\nimport { Alert, Button } from 'antd'\nimport { ErrorProps } from '@variousjs/various'\n\nconst errorComponent: FC<ErrorProps> = ({ reload, type, message }) => (\n <>\n <Alert\n message=\"Error\"\n description={`[${type}]:${message || '组件错误'}`}\n type=\"error\"\n style={{ marginTop: 30 }}\n />\n {\n reload && <Button onClick={reload}>刷新</Button>\n }\n </>\n)\n\nexport default errorComponent\n"],"names":["___CSS_LOADER_EXPORT___","push","module","id","locals","exports","cssWithMappingToString","list","toString","this","map","item","content","needLayer","concat","length","join","i","modules","media","dedupe","supports","layer","undefined","alreadyImportedModules","_i","_i2","cssMapping","btoa","base64","unescape","encodeURIComponent","JSON","stringify","data","sourceMapping","sourceURLs","sources","source","sourceRoot","stylesInDOM","getIndexByIdentifier","identifier","result","modulesToDom","options","idCountMap","identifiers","base","count","indexByIdentifier","obj","css","sourceMap","references","updater","addElementStyle","byIndex","splice","api","domAPI","update","newObj","remove","lastIdentifiers","newList","index","newLastIdentifiers","_index","memo","insert","style","target","styleTarget","document","querySelector","window","HTMLIFrameElement","contentDocument","head","e","getTarget","Error","appendChild","element","createElement","setAttributes","attributes","styleElement","nonce","setAttribute","insertStyleElement","styleTagTransform","apply","parentNode","removeChild","removeStyleElement","styleSheet","cssText","firstChild","createTextNode","__WEBPACK_EXTERNAL_MODULE__161__","__WEBPACK_EXTERNAL_MODULE__439__","__WEBPACK_EXTERNAL_MODULE__937__","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","__webpack_modules__","n","getter","__esModule","d","a","definition","key","o","Object","defineProperty","enumerable","get","prop","prototype","hasOwnProperty","call","r","Symbol","toStringTag","value","setName","emit","getStore","Promise","setTimeout","user","name","getName","Container","props","$component","$config","Top","className","csses","pages","path","components","Route","Array","isArray","exact","component","C","display","width","verticalAlign","Component","Loader","Spin","reload","type","message","Alert","description","marginTop","Button","onClick"],"sourceRoot":""}
1
+ {"version":3,"file":"entry.js","mappings":"4KAGIA,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,+JAAgK,GAAG,CAAC,QAAU,EAAE,QAAU,CAAC,oCAAoC,MAAQ,GAAG,SAAW,2EAA2E,eAAiB,CAAC,oJAAoJ,WAAa,MAE5hBH,EAAwBI,OAAS,CAChC,UAAa,kBACb,IAAO,aAER,K,kBCLAF,EAAOG,QAAU,SAAUC,GACzB,IAAIC,EAAO,GA6FX,OA3FAA,EAAKC,SAAW,WACd,OAAOC,KAAKC,KAAI,SAAUC,GACxB,IAAIC,EAAU,GACVC,OAA+B,IAAZF,EAAK,GA4B5B,OA1BIA,EAAK,KACPC,GAAW,cAAcE,OAAOH,EAAK,GAAI,QAGvCA,EAAK,KACPC,GAAW,UAAUE,OAAOH,EAAK,GAAI,OAGnCE,IACFD,GAAW,SAASE,OAAOH,EAAK,GAAGI,OAAS,EAAI,IAAID,OAAOH,EAAK,IAAM,GAAI,OAG5EC,GAAWN,EAAuBK,GAE9BE,IACFD,GAAW,KAGTD,EAAK,KACPC,GAAW,KAGTD,EAAK,KACPC,GAAW,KAGNA,CACT,IAAGI,KAAK,GACV,EAGAT,EAAKU,EAAI,SAAWC,EAASC,EAAOC,EAAQC,EAAUC,GAC7B,iBAAZJ,IACTA,EAAU,CAAC,CAAC,KAAMA,OAASK,KAG7B,IAAIC,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ACLJ,KAAMA,EACNK,UAjBO,IAAMb,EAAW5I,KAAK8H,IAC/B,MAAM4B,EAAI3J,KAAK6I,WAAWd,GAC1B,OACE,yBACEpB,IAAKoB,EACLjE,MAAO,CAAE8F,QAAS,eAAgBC,MAAO,IAAKC,cAAe,QAE7D,kBAACH,EAAD,MALJ,SAuBb,EAGH,Q,SCvDe,SAASI,IACtB,OACE,kBAAC,EAAAC,KAAD,KAEH,CCWD,MAduC,EAAGC,UAASC,QAAOC,cACxD,oCACE,kBAAC,EAAAC,MAAD,CACEC,QAAQ,QACRC,YAAc,IAAGJ,OAAWC,GAAY,SACxCI,KAAK,QACLzG,MAAO,CAAE0G,UAAW,MAGpBP,GAAW,kBAAC,EAAAQ,OAAD,CAAQC,QAAST,GAAjB,M","sources":["webpack://@variousjs/create/./src/entry/entry.less","webpack://@variousjs/create/./node_modules/css-loader/dist/runtime/api.js","webpack://@variousjs/create/./node_modules/css-loader/dist/runtime/sourceMaps.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/insertBySelector.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/insertStyleElement.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/styleDomAPI.js","webpack://@variousjs/create/./node_modules/style-loader/dist/runtime/styleTagTransform.js","webpack://@variousjs/create/external amd {\"root\":\"React\",\"amd\":\"react\"}","webpack://@variousjs/create/external amd {\"root\":\"ReactRouterDOM\",\"amd\":\"react-router-dom\"}","webpack://@variousjs/create/external amd {\"root\":\"antd\",\"amd\":\"antd\"}","webpack://@variousjs/create/external amd {\"root\":\"various\",\"amd\":\"@variousjs/various\"}","webpack://@variousjs/create/webpack/bootstrap","webpack://@variousjs/create/webpack/runtime/compat get default export","webpack://@variousjs/create/webpack/runtime/define property getters","webpack://@variousjs/create/webpack/runtime/hasOwnProperty shorthand","webpack://@variousjs/create/webpack/runtime/make namespace object","webpack://@variousjs/create/./src/entry/actions.ts","webpack://@variousjs/create/./src/entry/store.ts","webpack://@variousjs/create/./node_modules/@babel/runtime/helpers/esm/defineProperty.js","webpack://@variousjs/create/./src/entry/entry.less?fe22","webpack://@variousjs/create/./src/entry/container.tsx","webpack://@variousjs/create/./src/entry/loader.tsx","webpack://@variousjs/create/./src/entry/error.tsx"],"sourcesContent":["// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".container_moxlt {\\n background: #fff;\\n padding: 50px;\\n}\\n.top__WfL2 {\\n display: flex;\\n align-items: center;\\n justify-content: space-between;\\n}\\n\", \"\",{\"version\":3,\"sources\":[\"webpack://./src/entry/entry.less\"],\"names\":[],\"mappings\":\"AAAA;EACE,gBAAA;EACA,aAAA;AACF;AACA;EACE,aAAA;EACA,mBAAA;EACA,8BAAA;AACF\",\"sourcesContent\":[\".container {\\n background: #fff;\\n padding: 50px;\\n}\\n.top {\\n display: flex;\\n align-items: center;\\n justify-content: space-between;\\n}\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\n___CSS_LOADER_EXPORT___.locals = {\n\t\"container\": \"container_moxlt\",\n\t\"top\": \"top__WfL2\"\n};\nexport default ___CSS_LOADER_EXPORT___;\n","\"use strict\";\n\n/*\n MIT License http://www.opensource.org/licenses/mit-license.php\n Author Tobias Koppers @sokra\n*/\nmodule.exports = function (cssWithMappingToString) {\n var list = []; // return the list of modules as css string\n\n list.toString = function toString() {\n return this.map(function (item) {\n var content = \"\";\n var needLayer = typeof item[5] !== \"undefined\";\n\n if (item[4]) {\n content += \"@supports (\".concat(item[4], \") {\");\n }\n\n if (item[2]) {\n content += \"@media \".concat(item[2], \" {\");\n }\n\n if (needLayer) {\n content += \"@layer\".concat(item[5].length > 0 ? \" \".concat(item[5]) : \"\", \" {\");\n }\n\n content += cssWithMappingToString(item);\n\n if (needLayer) {\n content += \"}\";\n }\n\n if (item[2]) {\n content += \"}\";\n }\n\n if (item[4]) {\n content += \"}\";\n }\n\n return content;\n }).join(\"\");\n }; // import a list of modules into the list\n\n\n list.i = function i(modules, media, dedupe, supports, layer) {\n if (typeof modules === \"string\") {\n modules = [[null, modules, undefined]];\n }\n\n var alreadyImportedModules = {};\n\n if (dedupe) {\n for (var _i = 0; _i < this.length; _i++) {\n var id = this[_i][0];\n\n if (id != null) {\n alreadyImportedModules[id] = true;\n }\n }\n }\n\n for (var _i2 = 0; _i2 < modules.length; _i2++) {\n var item = [].concat(modules[_i2]);\n\n if (dedupe && alreadyImportedModules[item[0]]) {\n continue;\n }\n\n if (typeof layer !== \"undefined\") {\n if (typeof item[5] === \"undefined\") {\n item[5] = layer;\n } else {\n item[1] = \"@layer\".concat(item[5].length > 0 ? \" \".concat(item[5]) : \"\", \" {\").concat(item[1], \"}\");\n item[5] = layer;\n }\n }\n\n if (media) {\n if (!item[2]) {\n item[2] = media;\n } else {\n item[1] = \"@media \".concat(item[2], \" {\").concat(item[1], \"}\");\n item[2] = media;\n }\n }\n\n if (supports) {\n if (!item[4]) {\n item[4] = \"\".concat(supports);\n } else {\n item[1] = \"@supports (\".concat(item[4], \") {\").concat(item[1], \"}\");\n item[4] = supports;\n }\n }\n\n list.push(item);\n }\n };\n\n return list;\n};","\"use strict\";\n\nmodule.exports = function (item) {\n var content = item[1];\n var cssMapping = item[3];\n\n if (!cssMapping) {\n return content;\n }\n\n if (typeof btoa === \"function\") {\n var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(cssMapping))));\n var data = \"sourceMappingURL=data:application/json;charset=utf-8;base64,\".concat(base64);\n var sourceMapping = \"/*# \".concat(data, \" */\");\n var sourceURLs = cssMapping.sources.map(function (source) {\n return \"/*# sourceURL=\".concat(cssMapping.sourceRoot || \"\").concat(source, \" */\");\n });\n return [content].concat(sourceURLs).concat([sourceMapping]).join(\"\\n\");\n }\n\n return [content].join(\"\\n\");\n};","\"use strict\";\n\nvar stylesInDOM = [];\n\nfunction getIndexByIdentifier(identifier) {\n var result = -1;\n\n for (var i = 0; i < stylesInDOM.length; i++) {\n if (stylesInDOM[i].identifier === identifier) {\n result = i;\n break;\n }\n }\n\n return result;\n}\n\nfunction modulesToDom(list, options) {\n var idCountMap = {};\n var identifiers = [];\n\n for (var i = 0; i < list.length; i++) {\n var item = list[i];\n var id = options.base ? item[0] + options.base : item[0];\n var count = idCountMap[id] || 0;\n var identifier = \"\".concat(id, \" \").concat(count);\n idCountMap[id] = count + 1;\n var indexByIdentifier = getIndexByIdentifier(identifier);\n var obj = {\n css: item[1],\n media: item[2],\n sourceMap: item[3],\n supports: item[4],\n layer: item[5]\n };\n\n if (indexByIdentifier !== -1) {\n stylesInDOM[indexByIdentifier].references++;\n stylesInDOM[indexByIdentifier].updater(obj);\n } else {\n var updater = addElementStyle(obj, options);\n options.byIndex = i;\n stylesInDOM.splice(i, 0, {\n identifier: identifier,\n updater: updater,\n references: 1\n });\n }\n\n identifiers.push(identifier);\n }\n\n return identifiers;\n}\n\nfunction addElementStyle(obj, options) {\n var api = options.domAPI(options);\n api.update(obj);\n\n var updater = function updater(newObj) {\n if (newObj) {\n if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap && newObj.supports === obj.supports && newObj.layer === obj.layer) {\n return;\n }\n\n api.update(obj = newObj);\n } else {\n api.remove();\n }\n };\n\n return updater;\n}\n\nmodule.exports = function (list, options) {\n options = options || {};\n list = list || [];\n var lastIdentifiers = modulesToDom(list, options);\n return function update(newList) {\n newList = newList || [];\n\n for (var i = 0; i < lastIdentifiers.length; i++) {\n var identifier = lastIdentifiers[i];\n var index = getIndexByIdentifier(identifier);\n stylesInDOM[index].references--;\n }\n\n var newLastIdentifiers = modulesToDom(newList, options);\n\n for (var _i = 0; _i < lastIdentifiers.length; _i++) {\n var _identifier = lastIdentifiers[_i];\n\n var _index = getIndexByIdentifier(_identifier);\n\n if (stylesInDOM[_index].references === 0) {\n stylesInDOM[_index].updater();\n\n stylesInDOM.splice(_index, 1);\n }\n }\n\n lastIdentifiers = newLastIdentifiers;\n };\n};","\"use strict\";\n\nvar memo = {};\n/* istanbul ignore next */\n\nfunction getTarget(target) {\n if (typeof memo[target] === \"undefined\") {\n var styleTarget = document.querySelector(target); // Special case to return head of iframe instead of iframe itself\n\n if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {\n try {\n // This will throw an exception if access to iframe is blocked\n // due to cross-origin restrictions\n styleTarget = styleTarget.contentDocument.head;\n } catch (e) {\n // istanbul ignore next\n styleTarget = null;\n }\n }\n\n memo[target] = styleTarget;\n }\n\n return memo[target];\n}\n/* istanbul ignore next */\n\n\nfunction insertBySelector(insert, style) {\n var target = getTarget(insert);\n\n if (!target) {\n throw new Error(\"Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.\");\n }\n\n target.appendChild(style);\n}\n\nmodule.exports = insertBySelector;","\"use strict\";\n\n/* istanbul ignore next */\nfunction insertStyleElement(options) {\n var element = document.createElement(\"style\");\n options.setAttributes(element, options.attributes);\n options.insert(element, options.options);\n return element;\n}\n\nmodule.exports = insertStyleElement;","\"use strict\";\n\n/* istanbul ignore next */\nfunction setAttributesWithoutAttributes(styleElement) {\n var nonce = typeof __webpack_nonce__ !== \"undefined\" ? __webpack_nonce__ : null;\n\n if (nonce) {\n styleElement.setAttribute(\"nonce\", nonce);\n }\n}\n\nmodule.exports = setAttributesWithoutAttributes;","\"use strict\";\n\n/* istanbul ignore next */\nfunction apply(styleElement, options, obj) {\n var css = \"\";\n\n if (obj.supports) {\n css += \"@supports (\".concat(obj.supports, \") {\");\n }\n\n if (obj.media) {\n css += \"@media \".concat(obj.media, \" {\");\n }\n\n var needLayer = typeof obj.layer !== \"undefined\";\n\n if (needLayer) {\n css += \"@layer\".concat(obj.layer.length > 0 ? \" \".concat(obj.layer) : \"\", \" {\");\n }\n\n css += obj.css;\n\n if (needLayer) {\n css += \"}\";\n }\n\n if (obj.media) {\n css += \"}\";\n }\n\n if (obj.supports) {\n css += \"}\";\n }\n\n var sourceMap = obj.sourceMap;\n\n if (sourceMap && typeof btoa !== \"undefined\") {\n css += \"\\n/*# sourceMappingURL=data:application/json;base64,\".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), \" */\");\n } // For old IE\n\n /* istanbul ignore if */\n\n\n options.styleTagTransform(css, styleElement, options.options);\n}\n\nfunction removeStyleElement(styleElement) {\n // istanbul ignore if\n if (styleElement.parentNode === null) {\n return false;\n }\n\n styleElement.parentNode.removeChild(styleElement);\n}\n/* istanbul ignore next */\n\n\nfunction domAPI(options) {\n var styleElement = options.insertStyleElement(options);\n return {\n update: function update(obj) {\n apply(styleElement, options, obj);\n },\n remove: function remove() {\n removeStyleElement(styleElement);\n }\n };\n}\n\nmodule.exports = domAPI;","\"use strict\";\n\n/* istanbul ignore next */\nfunction styleTagTransform(css, styleElement) {\n if (styleElement.styleSheet) {\n styleElement.styleSheet.cssText = css;\n } else {\n while (styleElement.firstChild) {\n styleElement.removeChild(styleElement.firstChild);\n }\n\n styleElement.appendChild(document.createTextNode(css));\n }\n}\n\nmodule.exports = styleTagTransform;","module.exports = __WEBPACK_EXTERNAL_MODULE__161__;","module.exports = __WEBPACK_EXTERNAL_MODULE__439__;","module.exports = __WEBPACK_EXTERNAL_MODULE__937__;","module.exports = __WEBPACK_EXTERNAL_MODULE__437__;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","import { Actions } from '@variousjs/various'\nimport { Store } from '../types'\n\nconst actions: Actions<Store> = {\n async setName({ emit, getStore }, value) {\n await new Promise((r) => setTimeout(r, 1000))\n const { user } = getStore()\n user.name = value\n emit({ user })\n },\n async getName({ getStore }) {\n const { user } = getStore()\n return user.name\n },\n async setLocale({ emit }, value) {\n emit({ locale: value })\n }\n}\n\nexport default actions\n","export default {\n user: {\n name: 'various',\n },\n locale: 'zh',\n}\n","export default function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}","\n import API from \"!../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!../../node_modules/less-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./entry.less\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[1].use[1]!../../node_modules/less-loader/dist/cjs.js??ruleSet[1].rules[1].use[2]!./entry.less\";\n export default content && content.locals ? content.locals : undefined;\n","import React, { Component, ComponentType, memo } from 'react'\nimport { createComponent, getConfig } from '@variousjs/various'\nimport { HashRouter as Router, Route } from 'react-router-dom'\nimport { Config } from '../types'\nimport csses from './entry.less'\n\nclass Container extends Component {\n config = getConfig() as Config\n\n top = memo(createComponent('top'))\n\n components = this.config.pages.reduce((prev, current) => {\n current.components.forEach((item) => {\n prev[item] = memo(createComponent(item))\n })\n return prev\n }, {} as Record<string, ReturnType<typeof createComponent>>)\n\n render() {\n const Top = this.top\n const $config = this.config\n\n return (\n <div className={csses.container}>\n <Router>\n <div className={csses.top}>\n <Top />\n </div>\n {\n $config.pages.map(({ path, components }) => {\n const cs = () => components.map((name) => {\n const C = this.components[name]\n return (\n <div\n key={name}\n style={{ display: 'inline-block', width: 300, verticalAlign: 'top' }}\n >\n <C />\n </div>\n )\n })\n\n return (\n <Route\n key={Array.isArray(path) ? path.join() : path}\n exact\n path={path}\n component={cs as unknown as ComponentType}\n />\n )\n })\n }\n </Router>\n </div>\n )\n }\n}\n\nexport default Container\n","import React from 'react'\nimport { Spin } from 'antd'\n\nexport default function Loader() {\n return (\n <Spin />\n )\n}\n","import React, { FC } from 'react'\nimport { Alert, Button } from 'antd'\nimport { ErrorProps } from '@variousjs/various'\n\nconst errorComponent: FC<ErrorProps> = ({ $reload, $type, $message }) => (\n <>\n <Alert\n message=\"Error\"\n description={`[${$type}]: ${$message || '组件错误'}`}\n type=\"error\"\n style={{ marginTop: 30 }}\n />\n {\n $reload && <Button onClick={$reload}>刷新</Button>\n }\n </>\n)\n\nexport default errorComponent\n"],"names":["___CSS_LOADER_EXPORT___","push","module","id","locals","exports","cssWithMappingToString","list","toString","this","map","item","content","needLayer","concat","length","join","i","modules","media","dedupe","supports","layer","undefined","alreadyImportedModules","_i","_i2","cssMapping","btoa","base64","unescape","encodeURIComponent","JSON","stringify","data","sourceMapping","sourceURLs","sources","source","sourceRoot","stylesInDOM","getIndexByIdentifier","identifier","result","modulesToDom","options","idCountMap","identifiers","base","count","indexByIdentifier","obj","css","sourceMap","references","updater","addElementStyle","byIndex","splice","api","domAPI","update","newObj","remove","lastIdentifiers","newList","index","newLastIdentifiers","_index","memo","insert","style","target","styleTarget","document","querySelector","window","HTMLIFrameElement","contentDocument","head","e","getTarget","Error","appendChild","element","createElement","setAttributes","attributes","styleElement","nonce","setAttribute","insertStyleElement","styleTagTransform","apply","parentNode","removeChild","removeStyleElement","styleSheet","cssText","firstChild","createTextNode","__WEBPACK_EXTERNAL_MODULE__161__","__WEBPACK_EXTERNAL_MODULE__439__","__WEBPACK_EXTERNAL_MODULE__937__","__WEBPACK_EXTERNAL_MODULE__437__","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","__webpack_modules__","n","getter","__esModule","d","a","definition","key","o","Object","defineProperty","enumerable","get","prop","prototype","hasOwnProperty","call","r","Symbol","toStringTag","value","async","emit","getStore","Promise","setTimeout","user","name","locale","_defineProperty","configurable","writable","Container","Component","getConfig","createComponent","config","pages","reduce","prev","current","components","forEach","render","Top","top","$config","className","csses","path","Route","Array","isArray","exact","component","C","display","width","verticalAlign","Loader","Spin","$reload","$type","$message","Alert","message","description","type","marginTop","Button","onClick"],"sourceRoot":""}
package/demo/dist/next.js CHANGED
@@ -1,2 +1,2 @@
1
- define(["react","@variousjs/various","antd"],(function(e,t,r){return function(){"use strict";var n={563:function(e,t,r){r.r(t),r.d(t,{default:function(){return j}});var n=r(161),o=r.n(n),u=r(437),i=r(937),c=JSON.parse('{"title":"标题,{name}"}'),a=JSON.parse('{"title":"Title, {name}"}');function f(e){return f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},f(e)}function l(e,t,r,n,o,u,i){try{var c=e[u](i),a=c.value}catch(e){return void r(e)}c.done?t(a):Promise.resolve(a).then(n,o)}function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function p(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function y(e,t){return y=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},y(e,t)}function v(e,t){if(t&&("object"===f(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function b(e){return b=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},b(e)}function m(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var d=new u.Store,h=d.createStore,O=d.connect,w=d.emit,S=d.getStore;h({value:0});var g=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&y(e,t)}(a,e);var t,r,n,u,c=(n=a,u=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=b(n);if(u){var r=b(this).constructor;e=Reflect.construct(t,arguments,r)}else e=t.apply(this,arguments);return v(this,e)});function a(){return s(this,a),c.apply(this,arguments)}return t=a,(r=[{key:"render",value:function(){var e=this.props.$store.user,t=this.props,r=t.value,n=t.$t;return o().createElement(i.Descriptions,{style:{marginTop:30},bordered:!0,title:"Next Component",size:"small"},o().createElement(i.Descriptions.Item,{label:"Store"},e.name),o().createElement(i.Descriptions.Item,{label:"Value"},r),o().createElement(i.Descriptions.Item,{label:"Title"},n("title",{name:"various"})))}}])&&p(t.prototype,r),a}(n.Component);m(g,"setValue",function(){var e,t=(e=regeneratorRuntime.mark((function e(t){var r,n;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:r=t.value,n=S(),w({value:r+n.value},!0);case 3:case"end":return e.stop()}}),e)})),function(){var t=this,r=arguments;return new Promise((function(n,o){var u=e.apply(t,r);function i(e){l(u,n,o,i,c,"next",e)}function c(e){l(u,n,o,i,c,"throw",e)}i(void 0)}))});return function(e){return t.apply(this,arguments)}}()),m(g,"$i18n",(function(){return{localeKey:"locale",resources:{zh:c,en:a}}}));var j=O("value")(g)},161:function(t){t.exports=e},937:function(e){e.exports=r},437:function(e){e.exports=t}},o={};function u(e){var t=o[e];if(void 0!==t)return t.exports;var r=o[e]={exports:{}};return n[e](r,r.exports,u),r.exports}return u.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return u.d(t,{a:t}),t},u.d=function(e,t){for(var r in t)u.o(t,r)&&!u.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},u.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},u.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},u(563)}()}));
1
+ define(["react","@variousjs/various","antd"],(function(e,t,n){return function(){"use strict";var r={698:function(e,t,n){function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n.r(t),n.d(t,{default:function(){return v}});var o=n(161),a=n.n(o),i=n(437),u=n(937),l=JSON.parse('{"title":"标题,{name}"}'),s=JSON.parse('{"title":"Title, {name}"}');const{createStore:c,connect:p,emit:f,getStore:d}=new i.Store;c({value:0});class m extends o.Component{render(){const{user:e}=this.props.$store,{value:t,$t:n}=this.props;return a().createElement(u.Descriptions,{style:{marginTop:30},bordered:!0,title:"Next Component",size:"small"},a().createElement(u.Descriptions.Item,{label:"Store"},e.name),a().createElement(u.Descriptions.Item,{label:"Value"},t),a().createElement(u.Descriptions.Item,{label:"Title"},n("title",{name:"various"})))}}r(m,"setValue",(async e=>{const t=d();f({value:e+t.value},!0)})),r(m,"$i18n",(()=>({localeKey:"locale",resources:{zh:l,en:s}})));var v=p("value")(m)},161:function(t){t.exports=e},937:function(e){e.exports=n},437:function(e){e.exports=t}},o={};function a(e){var t=o[e];if(void 0!==t)return t.exports;var n=o[e]={exports:{}};return r[e](n,n.exports,a),n.exports}return a.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return a.d(t,{a:t}),t},a.d=function(e,t){for(var n in t)a.o(t,n)&&!a.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},a.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},a.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},a(698)}()}));
2
2
  //# sourceMappingURL=next.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"next.js","mappings":"ggD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Z,GAAUA,EAAOa,WAC7B,WAAa,OAAOb,EAAgB,OAAG,EACvC,WAAa,OAAOA,CAAQ,EAE7B,OADAM,EAAoBQ,EAAEF,EAAQ,CAAEG,EAAGH,IAC5BA,CACR,ECNAN,EAAoBQ,EAAI,SAASb,EAASe,GACzC,IAAI,IAAIC,KAAOD,EACXV,EAAoBY,EAAEF,EAAYC,KAASX,EAAoBY,EAAEjB,EAASgB,IAC5EE,OAAOC,eAAenB,EAASgB,EAAK,CAAEI,YAAY,EAAMC,IAAKN,EAAWC,IAG3E,ECPAX,EAAoBY,EAAI,SAASK,EAAKC,GAAQ,OAAOL,OAAOM,UAAUC,eAAeC,KAAKJ,EAAKC,EAAO,ECCtGlB,EAAoBsB,EAAI,SAAS3B,GACX,oBAAX4B,QAA0BA,OAAOC,aAC1CX,OAAOC,eAAenB,EAAS4B,OAAOC,YAAa,CAAEnD,MAAO,WAE7DwC,OAAOC,eAAenB,EAAS,aAAc,CAAEtB,OAAO,GACvD,ECH0B2B,EAAoB,I","sources":["webpack://@variousjs/create/./src/components/next.tsx","webpack://@variousjs/create/external amd {\"root\":\"React\",\"amd\":\"react\"}","webpack://@variousjs/create/external amd {\"root\":\"antd\",\"amd\":\"antd\"}","webpack://@variousjs/create/external amd {\"root\":\"various\",\"amd\":\"@variousjs/various\"}","webpack://@variousjs/create/webpack/bootstrap","webpack://@variousjs/create/webpack/runtime/compat get default export","webpack://@variousjs/create/webpack/runtime/define property getters","webpack://@variousjs/create/webpack/runtime/hasOwnProperty shorthand","webpack://@variousjs/create/webpack/runtime/make namespace object","webpack://@variousjs/create/webpack/startup"],"sourcesContent":["import React, { Component } from 'react'\nimport { ComponentProps, Store, Connect as CT, Invoker, Ii8n } from '@variousjs/various'\nimport { Descriptions } from 'antd'\nimport { Store as GlobalStore } from '../types'\nimport zh from './i18n/zh.json'\nimport en from './i18n/en.json'\n\ntype S = { value: number }\ntype Connect = CT<S>\n\nconst {\n createStore,\n connect,\n emit,\n getStore,\n} = new Store<S>()\n\ncreateStore({ value: 0 })\n\nclass X extends Component<Connect & ComponentProps<GlobalStore>> {\n static setValue: Invoker = async ({ value }) => {\n const store = getStore()\n emit({ value: value + store.value }, true)\n }\n\n static $i18n: Ii8n = () => ({\n localeKey: 'locale',\n resources: { zh, en },\n })\n\n render() {\n const { user } = this.props.$store\n const { value, $t } = this.props\n\n return (\n <Descriptions\n style={{ marginTop: 30 }}\n bordered\n title=\"Next Component\"\n size=\"small\"\n >\n <Descriptions.Item label=\"Store\">{user.name}</Descriptions.Item>\n <Descriptions.Item label=\"Value\">{value}</Descriptions.Item>\n <Descriptions.Item label=\"Title\">{$t('title', { name: 'various' })}</Descriptions.Item>\n </Descriptions>\n )\n }\n}\n\nexport default connect('value')(X)\n","module.exports = __WEBPACK_EXTERNAL_MODULE__161__;","module.exports = __WEBPACK_EXTERNAL_MODULE__937__;","module.exports = __WEBPACK_EXTERNAL_MODULE__437__;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// startup\n// Load entry module and return exports\n// This entry module doesn't tell about it's top-level declarations so it can't be inlined\nvar __webpack_exports__ = __webpack_require__(563);\n"],"names":["Store","createStore","connect","emit","getStore","value","X","user","this","props","$store","$t","Descriptions","style","marginTop","bordered","title","size","label","name","Component","store","localeKey","resources","zh","en","module","exports","__WEBPACK_EXTERNAL_MODULE__161__","__WEBPACK_EXTERNAL_MODULE__937__","__WEBPACK_EXTERNAL_MODULE__437__","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","__webpack_modules__","n","getter","__esModule","d","a","definition","key","o","Object","defineProperty","enumerable","get","obj","prop","prototype","hasOwnProperty","call","r","Symbol","toStringTag"],"sourceRoot":""}
1
+ {"version":3,"file":"next.js","mappings":"wHAAe,SAASA,EAAgBC,EAAKC,EAAKC,GAYhD,OAXID,KAAOD,EACTG,OAAOC,eAAeJ,EAAKC,EAAK,CAC9BC,MAAOA,EACPG,YAAY,EACZC,cAAc,EACdC,UAAU,IAGZP,EAAIC,GAAOC,EAGNF,CACT,C,qKCJA,MAAM,YACJQ,EADI,QAEJC,EAFI,KAGJC,EAHI,SAIJC,GACE,IAAIC,EAAAA,MAERJ,EAAY,CAAEN,MAAO,IAErB,MAAMW,UAAUC,EAAAA,UAWdC,SACE,MAAM,KAAEC,GAASC,KAAKC,MAAMC,QACtB,MAAEjB,EAAF,GAASkB,GAAOH,KAAKC,MAE3B,OACE,kBAAC,EAAAG,aAAD,CACEC,MAAO,CAAEC,UAAW,IACpBC,UAAQ,EACRC,MAAM,iBACNC,KAAK,SAEL,kBAAC,EAAAL,aAAA,KAAD,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EAAI,SAAStB,GACX,oBAAXuB,QAA0BA,OAAOC,aAC1CzD,OAAOC,eAAegC,EAASuB,OAAOC,YAAa,CAAE1D,MAAO,WAE7DC,OAAOC,eAAegC,EAAS,aAAc,CAAElC,OAAO,GACvD,ECH0BuC,EAAoB,I","sources":["webpack://@variousjs/create/./node_modules/@babel/runtime/helpers/esm/defineProperty.js","webpack://@variousjs/create/./src/components/next.tsx","webpack://@variousjs/create/external amd {\"root\":\"React\",\"amd\":\"react\"}","webpack://@variousjs/create/external amd {\"root\":\"antd\",\"amd\":\"antd\"}","webpack://@variousjs/create/external amd {\"root\":\"various\",\"amd\":\"@variousjs/various\"}","webpack://@variousjs/create/webpack/bootstrap","webpack://@variousjs/create/webpack/runtime/compat get default export","webpack://@variousjs/create/webpack/runtime/define property getters","webpack://@variousjs/create/webpack/runtime/hasOwnProperty shorthand","webpack://@variousjs/create/webpack/runtime/make namespace object","webpack://@variousjs/create/webpack/startup"],"sourcesContent":["export default function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}","import React, { Component } from 'react'\nimport { ComponentProps, Store, Invoker, Ii8n } from '@variousjs/various'\nimport { Descriptions } from 'antd'\nimport { Store as GlobalStore } from '../types'\nimport zh from './i18n/zh.json'\nimport en from './i18n/en.json'\n\ntype S = { value: number }\n\nconst {\n createStore,\n connect,\n emit,\n getStore,\n} = new Store<S>()\n\ncreateStore({ value: 0 })\n\nclass X extends Component<S & ComponentProps<GlobalStore>> {\n static setValue: Invoker = async (value) => {\n const store = getStore()\n emit({ value: value + store.value }, true)\n }\n\n static $i18n: Ii8n = () => ({\n localeKey: 'locale',\n resources: { zh, en },\n })\n\n render() {\n const { user } = this.props.$store\n const { value, $t } = this.props\n\n return (\n <Descriptions\n style={{ marginTop: 30 }}\n bordered\n title=\"Next Component\"\n size=\"small\"\n >\n <Descriptions.Item label=\"Store\">{user.name}</Descriptions.Item>\n <Descriptions.Item label=\"Value\">{value}</Descriptions.Item>\n <Descriptions.Item label=\"Title\">{$t('title', { name: 'various' })}</Descriptions.Item>\n </Descriptions>\n )\n }\n}\n\nexport default connect('value')(X)\n","module.exports = __WEBPACK_EXTERNAL_MODULE__161__;","module.exports = __WEBPACK_EXTERNAL_MODULE__937__;","module.exports = __WEBPACK_EXTERNAL_MODULE__437__;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// startup\n// Load entry module and return exports\n// This entry module doesn't tell about it's top-level declarations so it can't be inlined\nvar __webpack_exports__ = __webpack_require__(698);\n"],"names":["_defineProperty","obj","key","value","Object","defineProperty","enumerable","configurable","writable","createStore","connect","emit","getStore","Store","X","Component","render","user","this","props","$store","$t","Descriptions","style","marginTop","bordered","title","size","label","name","async","store","localeKey","resources","zh","en","module","exports","__WEBPACK_EXTERNAL_MODULE__161__","__WEBPACK_EXTERNAL_MODULE__937__","__WEBPACK_EXTERNAL_MODULE__437__","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","__webpack_modules__","n","getter","__esModule","d","a","definition","o","get","prop","prototype","hasOwnProperty","call","r","Symbol","toStringTag"],"sourceRoot":""}
package/demo/dist/top.js CHANGED
@@ -1,2 +1,2 @@
1
- define(["react","react-router-dom","antd"],(function(t,e,r){return function(){"use strict";var n={161:function(e){e.exports=t},439:function(t){t.exports=e},937:function(t){t.exports=r}},o={};function a(t){var e=o[t];if(void 0!==e)return e.exports;var r=o[t]={exports:{}};return n[t](r,r.exports,a),r.exports}a.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return a.d(e,{a:e}),e},a.d=function(t,e){for(var r in e)a.o(e,r)&&!a.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},a.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},a.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var u={};return function(){a.r(u);var t=a(161),e=a.n(t),r=a(439),n=a(937);function o(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}u.default=function(a){var u,i,l=(0,r.useLocation)().pathname,c=(0,r.useHistory)(),f=(u=(0,t.useState)(""),i=2,function(t){if(Array.isArray(t))return t}(u)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,o,a=[],u=!0,i=!1;try{for(r=r.call(t);!(u=(n=r.next()).done)&&(a.push(n.value),!e||a.length!==e);u=!0);}catch(t){i=!0,o=t}finally{try{u||null==r.return||r.return()}finally{if(i)throw o}}return a}}(u,i)||function(t,e){if(t){if("string"==typeof t)return o(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?o(t,e):void 0}}(u,i)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),s=f[0],d=f[1];return(0,t.useEffect)((function(){d(l)}),[]),e().createElement(e().Fragment,null,e().createElement(n.Radio.Group,{size:"large",value:s,onChange:function(t){c.push(t.target.value),d(t.target.value)},buttonStyle:"solid"},a.$config.links.map((function(t){var r=t.path,o=t.name;return e().createElement(n.Radio.Button,{key:r,value:r},o)}))),e().createElement("div",null,"Store:",e().createElement(n.Badge,{style:{marginLeft:10},count:a.$store.user.name}),e().createElement(n.Button,{style:{marginLeft:10},onClick:function(){return a.$dispatch("card","getName","Card")}},"Card Name")))}}(),u}()}));
1
+ define(["react","@variousjs/various","react-router-dom","antd"],(function(e,t,n,r){return function(){"use strict";var o={161:function(t){t.exports=e},439:function(e){e.exports=n},937:function(e){e.exports=r},437:function(e){e.exports=t}},a={};function u(e){var t=a[e];if(void 0!==t)return t.exports;var n=a[e]={exports:{}};return o[e](n,n.exports,u),n.exports}u.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return u.d(t,{a:t}),t},u.d=function(e,t){for(var n in t)u.o(t,n)&&!u.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},u.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},u.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};return function(){u.r(i);var e=u(161),t=u.n(e),n=u(437),r=u(439),o=u(937);i.default=a=>{const u=(0,n.getConfig)(),{pathname:i}=(0,r.useLocation)(),c=(0,r.useHistory)(),[l,s]=(0,e.useState)("");return(0,e.useEffect)((()=>{s(i)}),[]),t().createElement(t().Fragment,null,t().createElement(o.Radio.Group,{size:"large",value:l,onChange:e=>{c.push(e.target.value),s(e.target.value)},buttonStyle:"solid"},u.links.map((({path:e,name:n})=>t().createElement(o.Radio.Button,{key:e,value:e},n)))),t().createElement("div",null,"Store:",t().createElement(o.Badge,{style:{marginLeft:10},count:a.$store.user.name}),t().createElement(o.Button,{style:{marginLeft:10},onClick:()=>a.$dispatch("card","getName","Card")},"Card Name")))}}(),i}()}));
2
2
  //# sourceMappingURL=top.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"top.js","mappings":"kHAAAA,EAAOC,QAAUC,C,kBCAjBF,EAAOC,QAAUE,C,kBCAjBH,EAAOC,QAAUG,C,GCCbC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaP,QAGrB,IAAID,EAASK,EAAyBE,GAAY,CAGjDN,QAAS,CAAC,GAOX,OAHAS,EAAoBH,GAAUP,EAAQA,EAAOC,QAASK,GAG/CN,EAAOC,OACf,CCrBAK,EAAoBK,EAAI,SAASX,GAChC,IAAIY,EAASZ,GAAUA,EAAOa,WAC7B,WAAa,OAAOb,EAAgB,OAAG,EACvC,WAAa,OAAOA,CAAQ,EAE7B,OADAM,EAAoBQ,EAAEF,EAAQ,CAAEG,EAAGH,IAC5BA,CACR,ECNAN,EAAoBQ,EAAI,SAASb,EAASe,GACzC,IAAI,IAAIC,KAAOD,EACXV,EAAoBY,EAAEF,EAAYC,KAASX,EAAoBY,EAAEjB,EAASgB,IAC5EE,OAAOC,eAAenB,EAASgB,EAAK,CAAEI,YAAY,EAAMC,IAAKN,EAAWC,IAG3E,ECPAX,EAAoBY,EAAI,SAASK,EAAKC,GAAQ,OAAOL,OAAOM,UAAUC,eAAeC,KAAKJ,EAAKC,EAAO,ECCtGlB,EAAoBsB,EAAI,SAAS3B,GACX,oBAAX4B,QAA0BA,OAAOC,aAC1CX,OAAOC,eAAenB,EAAS4B,OAAOC,YAAa,CAAEC,MAAO,WAE7DZ,OAAOC,eAAenB,EAAS,aAAc,CAAE8B,OAAO,GACvD,E,oLC+CA,UA/C6C,SAACC,GAC5C,I,IAAQC,GAAaC,EAAAA,EAAAA,eAAbD,SACFE,GAAUC,EAAAA,EAAAA,cAChB,G,GAAwBC,EAAAA,EAAAA,UAAS,I,EAAjC,E,8zBAAOC,EAAP,KAAaC,EAAb,KAWA,OATAC,EAAAA,EAAAA,YAAU,WACRD,EAAQN,EACT,GAAE,IAQD,oCACA,kBAAC,EAAAQ,MAAA,MAAD,CACEC,KAAK,QACLX,MAAOO,EACPK,SAVmB,SAACC,GACtBT,EAAQU,KAAKD,EAAEE,OAAOf,OACtBQ,EAAQK,EAAEE,OAAOf,MAClB,EAQGgB,YAAY,SAGVf,EAAMgB,QAAQC,MAAMC,KAAI,gBAAGZ,EAAH,EAAGA,KAAMa,EAAT,EAASA,KAAT,OACtB,kBAAC,EAAAV,MAAA,OAAD,CAAcxB,IAAKqB,EAAMP,MAAOO,GAC7Ba,EAFmB,KAO5B,sCAEE,kBAAC,EAAAC,MAAD,CACEC,MAAO,CAAEC,WAAY,IACrBC,MAAOvB,EAAMwB,OAAOC,KAAKN,OAEzB,kBAAC,EAAAO,OAAD,CACEL,MAAO,CAAEC,WAAY,IACrBK,QAAS,kBAAM3B,EAAM4B,UAAU,OAAQ,UAAW,OAAzC,GAFX,cASP,C","sources":["webpack://@variousjs/create/external amd {\"root\":\"React\",\"amd\":\"react\"}","webpack://@variousjs/create/external amd {\"root\":\"ReactRouterDOM\",\"amd\":\"react-router-dom\"}","webpack://@variousjs/create/external amd {\"root\":\"antd\",\"amd\":\"antd\"}","webpack://@variousjs/create/webpack/bootstrap","webpack://@variousjs/create/webpack/runtime/compat get default export","webpack://@variousjs/create/webpack/runtime/define property getters","webpack://@variousjs/create/webpack/runtime/hasOwnProperty shorthand","webpack://@variousjs/create/webpack/runtime/make namespace object","webpack://@variousjs/create/./src/components/top.tsx"],"sourcesContent":["module.exports = __WEBPACK_EXTERNAL_MODULE__161__;","module.exports = __WEBPACK_EXTERNAL_MODULE__439__;","module.exports = __WEBPACK_EXTERNAL_MODULE__937__;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","import React, { FC, useState, useEffect } from 'react'\nimport { ComponentProps } from '@variousjs/various'\nimport { useLocation, useHistory } from 'react-router-dom'\nimport { Radio, Badge, Button } from 'antd'\nimport { Config, Store } from '../types'\n\nconst H: FC<ComponentProps<Store, Config>> = (props) => {\n const { pathname } = useLocation()\n const history = useHistory()\n const [path, setPath] = useState('')\n\n useEffect(() => {\n setPath(pathname)\n }, [])\n\n const onRouterChange = (e: any) => {\n history.push(e.target.value)\n setPath(e.target.value)\n }\n\n return (\n <>\n <Radio.Group\n size=\"large\"\n value={path}\n onChange={onRouterChange}\n buttonStyle=\"solid\"\n >\n {\n props.$config.links.map(({ path, name }) => (\n <Radio.Button key={path} value={path}>\n {name}\n </Radio.Button>\n ))\n }\n </Radio.Group>\n <div>\n Store:\n <Badge\n style={{ marginLeft: 10 }}\n count={props.$store.user.name}\n />\n <Button\n style={{ marginLeft: 10 }}\n onClick={() => props.$dispatch('card', 'getName', 'Card')}\n >\n Card Name\n </Button>\n </div>\n </>\n )\n}\n\nexport default H\n"],"names":["module","exports","__WEBPACK_EXTERNAL_MODULE__161__","__WEBPACK_EXTERNAL_MODULE__439__","__WEBPACK_EXTERNAL_MODULE__937__","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","__webpack_modules__","n","getter","__esModule","d","a","definition","key","o","Object","defineProperty","enumerable","get","obj","prop","prototype","hasOwnProperty","call","r","Symbol","toStringTag","value","props","pathname","useLocation","history","useHistory","useState","path","setPath","useEffect","Radio","size","onChange","e","push","target","buttonStyle","$config","links","map","name","Badge","style","marginLeft","count","$store","user","Button","onClick","$dispatch"],"sourceRoot":""}
1
+ {"version":3,"file":"top.js","mappings":"yIAAAA,EAAOC,QAAUC,C,kBCAjBF,EAAOC,QAAUE,C,kBCAjBH,EAAOC,QAAUG,C,kBCAjBJ,EAAOC,QAAUI,C,GCCbC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaR,QAGrB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OAAD,CAAc1B,IAAKsB,EAAMR,MAAOQ,GAC7Ba,MAKT,sCAEE,kBAAC,EAAAC,MAAD,CACEC,MAAO,CAAEC,WAAY,IACrBC,MAAOxB,EAAMyB,OAAOC,KAAKN,OAEzB,kBAAC,EAAAO,OAAD,CACEL,MAAO,CAAEC,WAAY,IACrBK,QAAS,IAAM5B,EAAM6B,UAAU,OAAQ,UAAW,SAFpD,cAtBN,C","sources":["webpack://@variousjs/create/external amd {\"root\":\"React\",\"amd\":\"react\"}","webpack://@variousjs/create/external amd {\"root\":\"ReactRouterDOM\",\"amd\":\"react-router-dom\"}","webpack://@variousjs/create/external amd {\"root\":\"antd\",\"amd\":\"antd\"}","webpack://@variousjs/create/external amd {\"root\":\"various\",\"amd\":\"@variousjs/various\"}","webpack://@variousjs/create/webpack/bootstrap","webpack://@variousjs/create/webpack/runtime/compat get default export","webpack://@variousjs/create/webpack/runtime/define property getters","webpack://@variousjs/create/webpack/runtime/hasOwnProperty shorthand","webpack://@variousjs/create/webpack/runtime/make namespace object","webpack://@variousjs/create/./src/components/top.tsx"],"sourcesContent":["module.exports = __WEBPACK_EXTERNAL_MODULE__161__;","module.exports = __WEBPACK_EXTERNAL_MODULE__439__;","module.exports = __WEBPACK_EXTERNAL_MODULE__937__;","module.exports = __WEBPACK_EXTERNAL_MODULE__437__;","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","import React, { FC, useState, useEffect } from 'react'\nimport { ComponentProps, getConfig } from '@variousjs/various'\nimport { useLocation, useHistory } from 'react-router-dom'\nimport { Radio, Badge, Button } from 'antd'\nimport { Config, Store } from '../types'\n\nconst H: FC<ComponentProps<Store>> = (props) => {\n const $config = getConfig() as Config\n const { pathname } = useLocation()\n const history = useHistory()\n const [path, setPath] = useState('')\n\n useEffect(() => {\n setPath(pathname)\n }, [])\n\n const onRouterChange = (e: any) => {\n history.push(e.target.value)\n setPath(e.target.value)\n }\n\n return (\n <>\n <Radio.Group\n size=\"large\"\n value={path}\n onChange={onRouterChange}\n buttonStyle=\"solid\"\n >\n {\n $config.links.map(({ path, name }) => (\n <Radio.Button key={path} value={path}>\n {name}\n </Radio.Button>\n ))\n }\n </Radio.Group>\n <div>\n Store:\n <Badge\n style={{ marginLeft: 10 }}\n count={props.$store.user.name}\n />\n <Button\n style={{ marginLeft: 10 }}\n onClick={() => props.$dispatch('card', 'getName', 'Card')}\n >\n Card Name\n </Button>\n </div>\n </>\n )\n}\n\nexport default H\n"],"names":["module","exports","__WEBPACK_EXTERNAL_MODULE__161__","__WEBPACK_EXTERNAL_MODULE__439__","__WEBPACK_EXTERNAL_MODULE__937__","__WEBPACK_EXTERNAL_MODULE__437__","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","__webpack_modules__","n","getter","__esModule","d","a","definition","key","o","Object","defineProperty","enumerable","get","obj","prop","prototype","hasOwnProperty","call","r","Symbol","toStringTag","value","props","$config","getConfig","pathname","useLocation","history","useHistory","path","setPath","useState","useEffect","Radio","size","onChange","e","push","target","buttonStyle","links","map","name","Badge","style","marginLeft","count","$store","user","Button","onClick","$dispatch"],"sourceRoot":""}
package/demo/index.html CHANGED
@@ -6,9 +6,9 @@
6
6
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/antd@4.16.13/dist/antd.compact.min.css" />
7
7
  <script>
8
8
  var VARIOUS_CONFIG = {
9
+ env: 'development', // 开发模式,显示所有组件错误
9
10
  root: '#root',
10
11
  entry: './dist/entry.js',
11
- routerMode: 'hash',
12
12
  dependencies: {
13
13
  // 内置依赖,如果不定义会默认使用 unpkg cdn 链接
14
14
  react: 'https://cdn.jsdelivr.net/npm/react@18/umd/react.production.min.js',
@@ -57,6 +57,6 @@ var VARIOUS_CONFIG = {
57
57
  <body>
58
58
  <div id="root"></div>
59
59
  <script src="https://cdn.jsdelivr.net/npm/requirejs@2.3.6/require.js"></script>
60
- <script src="https://cdn.jsdelivr.net/npm/@variousjs/various@1.2.0/dist/index.js"></script>
60
+ <script src="https://cdn.jsdelivr.net/npm/@variousjs/various@3.0.0/dist/index.js"></script>
61
61
  </body>
62
62
  </html>
@@ -261,6 +261,12 @@
261
261
  "@babel/types": "^7.15.4"
262
262
  }
263
263
  },
264
+ "@babel/helper-string-parser": {
265
+ "version": "7.18.10",
266
+ "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.18.10.tgz",
267
+ "integrity": "sha512-XtIfWmeNY3i4t7t4D2t02q50HvqHybPqW2ki1kosnvWCwuCMeo81Jf0gwr85jy/neUdg5XDdeFE/80DXiO+njw==",
268
+ "dev": true
269
+ },
264
270
  "@babel/helper-validator-identifier": {
265
271
  "version": "7.15.7",
266
272
  "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.15.7.tgz",
@@ -914,6 +920,155 @@
914
920
  "@babel/helper-plugin-utils": "^7.14.5"
915
921
  }
916
922
  },
923
+ "@babel/plugin-transform-runtime": {
924
+ "version": "7.18.10",
925
+ "resolved": "https://registry.npmjs.org/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.18.10.tgz",
926
+ "integrity": "sha512-q5mMeYAdfEbpBAgzl7tBre/la3LeCxmDO1+wMXRdPWbcoMjR3GiXlCLk7JBZVVye0bqTGNMbt0yYVXX1B1jEWQ==",
927
+ "dev": true,
928
+ "requires": {
929
+ "@babel/helper-module-imports": "^7.18.6",
930
+ "@babel/helper-plugin-utils": "^7.18.9",
931
+ "babel-plugin-polyfill-corejs2": "^0.3.2",
932
+ "babel-plugin-polyfill-corejs3": "^0.5.3",
933
+ "babel-plugin-polyfill-regenerator": "^0.4.0",
934
+ "semver": "^6.3.0"
935
+ },
936
+ "dependencies": {
937
+ "@babel/compat-data": {
938
+ "version": "7.19.0",
939
+ "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.19.0.tgz",
940
+ "integrity": "sha512-y5rqgTTPTmaF5e2nVhOxw+Ur9HDJLsWb6U/KpgUzRZEdPfE6VOubXBKLdbcUTijzRptednSBDQbYZBOSqJxpJw==",
941
+ "dev": true
942
+ },
943
+ "@babel/helper-compilation-targets": {
944
+ "version": "7.19.0",
945
+ "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.19.0.tgz",
946
+ "integrity": "sha512-Ai5bNWXIvwDvWM7njqsG3feMlL9hCVQsPYXodsZyLwshYkZVJt59Gftau4VrE8S9IT9asd2uSP1hG6wCNw+sXA==",
947
+ "dev": true,
948
+ "requires": {
949
+ "@babel/compat-data": "^7.19.0",
950
+ "@babel/helper-validator-option": "^7.18.6",
951
+ "browserslist": "^4.20.2",
952
+ "semver": "^6.3.0"
953
+ }
954
+ },
955
+ "@babel/helper-define-polyfill-provider": {
956
+ "version": "0.3.2",
957
+ "resolved": "https://registry.npmjs.org/@babel/helper-define-polyfill-provider/-/helper-define-polyfill-provider-0.3.2.tgz",
958
+ "integrity": "sha512-r9QJJ+uDWrd+94BSPcP6/de67ygLtvVy6cK4luE6MOuDsZIdoaPBnfSpbO/+LTifjPckbKXRuI9BB/Z2/y3iTg==",
959
+ "dev": true,
960
+ "requires": {
961
+ "@babel/helper-compilation-targets": "^7.17.7",
962
+ "@babel/helper-plugin-utils": "^7.16.7",
963
+ "debug": "^4.1.1",
964
+ "lodash.debounce": "^4.0.8",
965
+ "resolve": "^1.14.2",
966
+ "semver": "^6.1.2"
967
+ }
968
+ },
969
+ "@babel/helper-module-imports": {
970
+ "version": "7.18.6",
971
+ "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.18.6.tgz",
972
+ "integrity": "sha512-0NFvs3VkuSYbFi1x2Vd6tKrywq+z/cLeYC/RJNFrIX/30Bf5aiGYbtvGXolEktzJH8o5E5KJ3tT+nkxuuZFVlA==",
973
+ "dev": true,
974
+ "requires": {
975
+ "@babel/types": "^7.18.6"
976
+ }
977
+ },
978
+ "@babel/helper-plugin-utils": {
979
+ "version": "7.19.0",
980
+ "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.19.0.tgz",
981
+ "integrity": "sha512-40Ryx7I8mT+0gaNxm8JGTZFUITNqdLAgdg0hXzeVZxVD6nFsdhQvip6v8dqkRHzsz1VFpFAaOCHNn0vKBL7Czw==",
982
+ "dev": true
983
+ },
984
+ "@babel/helper-validator-identifier": {
985
+ "version": "7.18.6",
986
+ "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.18.6.tgz",
987
+ "integrity": "sha512-MmetCkz9ej86nJQV+sFCxoGGrUbU3q02kgLciwkrt9QqEB7cP39oKEY0PakknEO0Gu20SskMRi+AYZ3b1TpN9g==",
988
+ "dev": true
989
+ },
990
+ "@babel/helper-validator-option": {
991
+ "version": "7.18.6",
992
+ "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.18.6.tgz",
993
+ "integrity": "sha512-XO7gESt5ouv/LRJdrVjkShckw6STTaB7l9BrpBaAHDeF5YZT+01PCwmR0SJHnkW6i8OwW/EVWRShfi4j2x+KQw==",
994
+ "dev": true
995
+ },
996
+ "@babel/types": {
997
+ "version": "7.19.0",
998
+ "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.19.0.tgz",
999
+ "integrity": "sha512-YuGopBq3ke25BVSiS6fgF49Ul9gH1x70Bcr6bqRLjWCkcX8Hre1/5+z+IiWOIerRMSSEfGZVB9z9kyq7wVs9YA==",
1000
+ "dev": true,
1001
+ "requires": {
1002
+ "@babel/helper-string-parser": "^7.18.10",
1003
+ "@babel/helper-validator-identifier": "^7.18.6",
1004
+ "to-fast-properties": "^2.0.0"
1005
+ }
1006
+ },
1007
+ "babel-plugin-polyfill-corejs2": {
1008
+ "version": "0.3.2",
1009
+ "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-corejs2/-/babel-plugin-polyfill-corejs2-0.3.2.tgz",
1010
+ "integrity": "sha512-LPnodUl3lS0/4wN3Rb+m+UK8s7lj2jcLRrjho4gLw+OJs+I4bvGXshINesY5xx/apM+biTnQ9reDI8yj+0M5+Q==",
1011
+ "dev": true,
1012
+ "requires": {
1013
+ "@babel/compat-data": "^7.17.7",
1014
+ "@babel/helper-define-polyfill-provider": "^0.3.2",
1015
+ "semver": "^6.1.1"
1016
+ }
1017
+ },
1018
+ "babel-plugin-polyfill-corejs3": {
1019
+ "version": "0.5.3",
1020
+ "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-corejs3/-/babel-plugin-polyfill-corejs3-0.5.3.tgz",
1021
+ "integrity": "sha512-zKsXDh0XjnrUEW0mxIHLfjBfnXSMr5Q/goMe/fxpQnLm07mcOZiIZHBNWCMx60HmdvjxfXcalac0tfFg0wqxyw==",
1022
+ "dev": true,
1023
+ "requires": {
1024
+ "@babel/helper-define-polyfill-provider": "^0.3.2",
1025
+ "core-js-compat": "^3.21.0"
1026
+ }
1027
+ },
1028
+ "babel-plugin-polyfill-regenerator": {
1029
+ "version": "0.4.0",
1030
+ "resolved": "https://registry.npmjs.org/babel-plugin-polyfill-regenerator/-/babel-plugin-polyfill-regenerator-0.4.0.tgz",
1031
+ "integrity": "sha512-RW1cnryiADFeHmfLS+WW/G431p1PsW5qdRdz0SDRi7TKcUgc7Oh/uXkT7MZ/+tGsT1BkczEAmD5XjUyJ5SWDTw==",
1032
+ "dev": true,
1033
+ "requires": {
1034
+ "@babel/helper-define-polyfill-provider": "^0.3.2"
1035
+ }
1036
+ },
1037
+ "browserslist": {
1038
+ "version": "4.21.3",
1039
+ "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.21.3.tgz",
1040
+ "integrity": "sha512-898rgRXLAyRkM1GryrrBHGkqA5hlpkV5MhtZwg9QXeiyLUYs2k00Un05aX5l2/yJIOObYKOpS2JNo8nJDE7fWQ==",
1041
+ "dev": true,
1042
+ "requires": {
1043
+ "caniuse-lite": "^1.0.30001370",
1044
+ "electron-to-chromium": "^1.4.202",
1045
+ "node-releases": "^2.0.6",
1046
+ "update-browserslist-db": "^1.0.5"
1047
+ }
1048
+ },
1049
+ "core-js-compat": {
1050
+ "version": "3.25.1",
1051
+ "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.25.1.tgz",
1052
+ "integrity": "sha512-pOHS7O0i8Qt4zlPW/eIFjwp+NrTPx+wTL0ctgI2fHn31sZOq89rDsmtc/A2vAX7r6shl+bmVI+678He46jgBlw==",
1053
+ "dev": true,
1054
+ "requires": {
1055
+ "browserslist": "^4.21.3"
1056
+ }
1057
+ },
1058
+ "electron-to-chromium": {
1059
+ "version": "1.4.244",
1060
+ "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.244.tgz",
1061
+ "integrity": "sha512-E21saXLt2eTDaTxgUtiJtBUqanF9A32wZasAwDZ8gvrqXoxrBrbwtDCx7c/PQTLp81wj4X0OLDeoGQg7eMo3+w==",
1062
+ "dev": true
1063
+ },
1064
+ "node-releases": {
1065
+ "version": "2.0.6",
1066
+ "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.6.tgz",
1067
+ "integrity": "sha512-PiVXnNuFm5+iYkLBNeq5211hvO38y63T0i2KKh2KnUs3RpzJ+JtODFjkD8yjLwnDkTYF1eKXheUwdssR+NRZdg==",
1068
+ "dev": true
1069
+ }
1070
+ }
1071
+ },
917
1072
  "@babel/plugin-transform-shorthand-properties": {
918
1073
  "version": "7.14.5",
919
1074
  "resolved": "https://registry.npmjs.org/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.14.5.tgz",
@@ -1110,9 +1265,9 @@
1110
1265
  }
1111
1266
  },
1112
1267
  "@babel/runtime": {
1113
- "version": "7.15.4",
1114
- "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.15.4.tgz",
1115
- "integrity": "sha512-99catp6bHCaxr4sJ/DbTGgHS4+Rs2RVd2g7iOap6SLGPDknRK9ztKNsE/Fg6QhSeh1FGE5f6gHGQmvvn3I3xhw==",
1268
+ "version": "7.19.0",
1269
+ "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.19.0.tgz",
1270
+ "integrity": "sha512-eR8Lo9hnDS7tqkO7NsV+mKvCmv5boaXFSZ70DnfhcgiEne8hv9oCEd36Klw74EtizEqLsy4YnW8UWwpBVolHZA==",
1116
1271
  "dev": true,
1117
1272
  "requires": {
1118
1273
  "regenerator-runtime": "^0.13.4"
@@ -1637,12 +1792,12 @@
1637
1792
  }
1638
1793
  },
1639
1794
  "@variousjs/various": {
1640
- "version": "1.2.0",
1641
- "resolved": "https://registry.npmjs.org/@variousjs/various/-/various-1.2.0.tgz",
1642
- "integrity": "sha512-LeYE/o72fmLJSWkfRW4IVobsUmCrsXYth/Ur0jPzHvP88Q6uht6SmQ3bEei9vihB/k/WqAa6IUUzuw78bVbLqw==",
1795
+ "version": "3.0.0",
1796
+ "resolved": "https://registry.npmjs.org/@variousjs/various/-/various-3.0.0.tgz",
1797
+ "integrity": "sha512-IAm1qw1RMggrJIXEYpKRquLCfY/3mZjcbelcLDLMEnuPki7q6q6lwvXcIQqG5Jh58d2bUuQMMwUjnW80wuA54Q==",
1643
1798
  "dev": true,
1644
1799
  "requires": {
1645
- "nycticorax": "^3.0.3"
1800
+ "nycticorax": "^4.1.2"
1646
1801
  }
1647
1802
  },
1648
1803
  "@webassemblyjs/ast": {
@@ -2243,9 +2398,9 @@
2243
2398
  "dev": true
2244
2399
  },
2245
2400
  "caniuse-lite": {
2246
- "version": "1.0.30001335",
2247
- "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001335.tgz",
2248
- "integrity": "sha512-ddP1Tgm7z2iIxu6QTtbZUv6HJxSaV/PZeSrWFZtbY4JZ69tOeNhBCl3HyRQgeNZKE5AOn1kpV7fhljigy0Ty3w==",
2401
+ "version": "1.0.30001435",
2402
+ "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001435.tgz",
2403
+ "integrity": "sha512-kdCkUTjR+v4YAJelyiDTqiu82BDr4W4CP5sgTA0ZBmqn30XfS2ZghPLMowik9TPhS+psWJiUNxsqLyurDbmutA==",
2249
2404
  "dev": true
2250
2405
  },
2251
2406
  "chalk": {
@@ -2375,7 +2530,7 @@
2375
2530
  "concat-map": {
2376
2531
  "version": "0.0.1",
2377
2532
  "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
2378
- "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=",
2533
+ "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==",
2379
2534
  "dev": true
2380
2535
  },
2381
2536
  "connect-history-api-fallback": {
@@ -2437,6 +2592,12 @@
2437
2592
  "is-what": "^3.12.0"
2438
2593
  }
2439
2594
  },
2595
+ "core-js": {
2596
+ "version": "3.25.1",
2597
+ "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.25.1.tgz",
2598
+ "integrity": "sha512-sr0FY4lnO1hkQ4gLDr24K0DGnweGO1QwSj5BpfQjpSJPdqWalja4cTps29Y/PJVG/P7FYlPDkH3hO+Tr0CvDgQ==",
2599
+ "dev": true
2600
+ },
2440
2601
  "core-js-compat": {
2441
2602
  "version": "3.18.1",
2442
2603
  "resolved": "https://registry.npmjs.org/core-js-compat/-/core-js-compat-3.18.1.tgz",
@@ -4406,9 +4567,9 @@
4406
4567
  "dev": true
4407
4568
  },
4408
4569
  "loader-utils": {
4409
- "version": "1.4.0",
4410
- "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-1.4.0.tgz",
4411
- "integrity": "sha512-qH0WSMBtn/oHuwjy/NucEgbx5dbxxnxup9s4PVXJUDHZBQY+s0NWA9rJf53RBnQZxfch7euUui7hpoAPvALZdA==",
4570
+ "version": "1.4.2",
4571
+ "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-1.4.2.tgz",
4572
+ "integrity": "sha512-I5d00Pd/jwMD2QCduo657+YM/6L3KZu++pmX9VFncxaxvHcru9jx1lBaFft+r4Mt2jK0Yhp41XlRAihzPxHNCg==",
4412
4573
  "dev": true,
4413
4574
  "requires": {
4414
4575
  "big.js": "^5.2.2",
@@ -4576,9 +4737,9 @@
4576
4737
  "dev": true
4577
4738
  },
4578
4739
  "minimatch": {
4579
- "version": "3.0.4",
4580
- "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz",
4581
- "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==",
4740
+ "version": "3.1.2",
4741
+ "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz",
4742
+ "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==",
4582
4743
  "dev": true,
4583
4744
  "requires": {
4584
4745
  "brace-expansion": "^1.1.7"
@@ -4723,14 +4884,10 @@
4723
4884
  }
4724
4885
  },
4725
4886
  "nycticorax": {
4726
- "version": "3.0.3",
4727
- "resolved": "https://registry.npmjs.org/nycticorax/-/nycticorax-3.0.3.tgz",
4728
- "integrity": "sha512-qEMyP43EjTpoIc4fOrHIrWFRNQZl8eYNaytHRUYbeiteSvpHcbmJi5HxuIOiUIMRmK9hnr8Mc9+WlbjJMlIdVg==",
4729
- "dev": true,
4730
- "requires": {
4731
- "fast-deep-equal": "^3.1.3",
4732
- "tslib": "^2.3.0"
4733
- }
4887
+ "version": "4.1.2",
4888
+ "resolved": "https://registry.npmjs.org/nycticorax/-/nycticorax-4.1.2.tgz",
4889
+ "integrity": "sha512-F55b3ZoPG+c5IDZBNs653WW8A2xGYVvYknHMKB4Mz+phqZE25q3Pk90t/aHtnyLk7pVDXcAyQPywwuyuG9Gw+A==",
4890
+ "dev": true
4734
4891
  },
4735
4892
  "object-assign": {
4736
4893
  "version": "4.1.1",
@@ -4990,6 +5147,12 @@
4990
5147
  "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==",
4991
5148
  "dev": true
4992
5149
  },
5150
+ "picocolors": {
5151
+ "version": "1.0.0",
5152
+ "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz",
5153
+ "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==",
5154
+ "dev": true
5155
+ },
4993
5156
  "picomatch": {
4994
5157
  "version": "2.3.0",
4995
5158
  "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.0.tgz",
@@ -6201,12 +6364,6 @@
6201
6364
  }
6202
6365
  }
6203
6366
  },
6204
- "tslib": {
6205
- "version": "2.4.0",
6206
- "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.4.0.tgz",
6207
- "integrity": "sha512-d6xOpEDfsi2CZVlPQzGeux8XMwLT9hssAsaPYExaQMuYskwb+x1x7J371tWlbBdWHroy99KnVB6qIkUbs5X3UQ==",
6208
- "dev": true
6209
- },
6210
6367
  "tsutils": {
6211
6368
  "version": "3.21.0",
6212
6369
  "resolved": "https://registry.npmjs.org/tsutils/-/tsutils-3.21.0.tgz",
@@ -6301,6 +6458,16 @@
6301
6458
  "integrity": "sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw=",
6302
6459
  "dev": true
6303
6460
  },
6461
+ "update-browserslist-db": {
6462
+ "version": "1.0.7",
6463
+ "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.7.tgz",
6464
+ "integrity": "sha512-iN/XYesmZ2RmmWAiI4Z5rq0YqSiv0brj9Ce9CfhNE4xIW2h+MFxcgkxIzZ+ShkFPUkjU3gQ+3oypadD3RAMtrg==",
6465
+ "dev": true,
6466
+ "requires": {
6467
+ "escalade": "^3.1.1",
6468
+ "picocolors": "^1.0.0"
6469
+ }
6470
+ },
6304
6471
  "uri-js": {
6305
6472
  "version": "4.4.1",
6306
6473
  "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@variousjs/create",
3
- "version": "1.1.0",
3
+ "version": "2.0.0",
4
4
  "description": "VariousJS boilerplate",
5
5
  "bin": "bin/create.js",
6
6
  "publishConfig": {
@@ -28,16 +28,19 @@
28
28
  "homepage": "https://github.com/variousjs/boilerplate#readme",
29
29
  "devDependencies": {
30
30
  "@babel/core": "^7.15.5",
31
+ "@babel/plugin-transform-runtime": "^7.18.10",
31
32
  "@babel/preset-env": "^7.15.6",
32
33
  "@babel/preset-react": "^7.14.5",
33
34
  "@babel/preset-typescript": "^7.15.0",
35
+ "@babel/runtime": "^7.19.0",
34
36
  "@types/react": "^18.0.15",
35
37
  "@types/react-dom": "^18.0.6",
36
38
  "@types/react-router-dom": "^5.3.3",
37
39
  "@typescript-eslint/eslint-plugin": "^4.31.2",
38
40
  "@typescript-eslint/parser": "^4.31.2",
39
- "@variousjs/various": "^1.2.0",
41
+ "@variousjs/various": "^3.0.0",
40
42
  "babel-loader": "^8.2.2",
43
+ "core-js": "^3.25.1",
41
44
  "css-loader": "^6.3.0",
42
45
  "eslint": "^7.32.0",
43
46
  "eslint-import-resolver-typescript": "^2.5.0",
package/package.json.copy CHANGED
@@ -11,16 +11,19 @@
11
11
  "license": "MIT",
12
12
  "devDependencies": {
13
13
  "@babel/core": "^7.15.5",
14
+ "@babel/plugin-transform-runtime": "^7.18.10",
14
15
  "@babel/preset-env": "^7.15.6",
15
16
  "@babel/preset-react": "^7.14.5",
16
17
  "@babel/preset-typescript": "^7.15.0",
18
+ "@babel/runtime": "^7.19.0",
17
19
  "@types/react": "^18.0.15",
18
20
  "@types/react-dom": "^18.0.6",
19
21
  "@types/react-router-dom": "^5.3.3",
20
22
  "@typescript-eslint/eslint-plugin": "^4.31.2",
21
23
  "@typescript-eslint/parser": "^4.31.2",
22
- "@variousjs/various": "^1.2.0",
24
+ "@variousjs/various": "^3.0.0",
23
25
  "babel-loader": "^8.2.2",
26
+ "core-js": "^3.25.1",
24
27
  "css-loader": "^6.3.0",
25
28
  "eslint": "^7.32.0",
26
29
  "eslint-import-resolver-typescript": "^2.5.0",
@@ -47,6 +47,6 @@ const H: FC<ComponentProps<Store>> & { getName: Invoker } = (props) => {
47
47
  )
48
48
  }
49
49
 
50
- H.getName = (e) => message.info(e.value)
50
+ H.getName = (e) => message.info(e)
51
51
 
52
52
  export default H
@@ -1,12 +1,11 @@
1
1
  import React, { Component } from 'react'
2
- import { ComponentProps, Store, Connect as CT, Invoker, Ii8n } from '@variousjs/various'
2
+ import { ComponentProps, Store, Invoker, Ii8n } from '@variousjs/various'
3
3
  import { Descriptions } from 'antd'
4
4
  import { Store as GlobalStore } from '../types'
5
5
  import zh from './i18n/zh.json'
6
6
  import en from './i18n/en.json'
7
7
 
8
8
  type S = { value: number }
9
- type Connect = CT<S>
10
9
 
11
10
  const {
12
11
  createStore,
@@ -17,8 +16,8 @@ const {
17
16
 
18
17
  createStore({ value: 0 })
19
18
 
20
- class X extends Component<Connect & ComponentProps<GlobalStore>> {
21
- static setValue: Invoker = async ({ value }) => {
19
+ class X extends Component<S & ComponentProps<GlobalStore>> {
20
+ static setValue: Invoker = async (value) => {
22
21
  const store = getStore()
23
22
  emit({ value: value + store.value }, true)
24
23
  }
@@ -1,10 +1,11 @@
1
1
  import React, { FC, useState, useEffect } from 'react'
2
- import { ComponentProps } from '@variousjs/various'
2
+ import { ComponentProps, getConfig } from '@variousjs/various'
3
3
  import { useLocation, useHistory } from 'react-router-dom'
4
4
  import { Radio, Badge, Button } from 'antd'
5
5
  import { Config, Store } from '../types'
6
6
 
7
- const H: FC<ComponentProps<Store, Config>> = (props) => {
7
+ const H: FC<ComponentProps<Store>> = (props) => {
8
+ const $config = getConfig() as Config
8
9
  const { pathname } = useLocation()
9
10
  const history = useHistory()
10
11
  const [path, setPath] = useState('')
@@ -27,7 +28,7 @@ const H: FC<ComponentProps<Store, Config>> = (props) => {
27
28
  buttonStyle="solid"
28
29
  >
29
30
  {
30
- props.$config.links.map(({ path, name }) => (
31
+ $config.links.map(({ path, name }) => (
31
32
  <Radio.Button key={path} value={path}>
32
33
  {name}
33
34
  </Radio.Button>
@@ -2,7 +2,7 @@ import { Actions } from '@variousjs/various'
2
2
  import { Store } from '../types'
3
3
 
4
4
  const actions: Actions<Store> = {
5
- async setName({ emit, getStore }, { value }) {
5
+ async setName({ emit, getStore }, value) {
6
6
  await new Promise((r) => setTimeout(r, 1000))
7
7
  const { user } = getStore()
8
8
  user.name = value
@@ -12,7 +12,7 @@ const actions: Actions<Store> = {
12
12
  const { user } = getStore()
13
13
  return user.name
14
14
  },
15
- async setLocale({ emit }, { value }) {
15
+ async setLocale({ emit }, value) {
16
16
  emit({ locale: value })
17
17
  }
18
18
  }
@@ -1,13 +1,24 @@
1
- import React, { Component, ComponentType } from 'react'
2
- import { ContainerProps } from '@variousjs/various'
1
+ import React, { Component, ComponentType, memo } from 'react'
2
+ import { createComponent, getConfig } from '@variousjs/various'
3
3
  import { HashRouter as Router, Route } from 'react-router-dom'
4
4
  import { Config } from '../types'
5
5
  import csses from './entry.less'
6
6
 
7
- class Container extends Component<ContainerProps<Config>> {
7
+ class Container extends Component {
8
+ config = getConfig() as Config
9
+
10
+ top = memo(createComponent('top'))
11
+
12
+ components = this.config.pages.reduce((prev, current) => {
13
+ current.components.forEach((item) => {
14
+ prev[item] = memo(createComponent(item))
15
+ })
16
+ return prev
17
+ }, {} as Record<string, ReturnType<typeof createComponent>>)
18
+
8
19
  render() {
9
- const { $component, $config } = this.props
10
- const Top = $component('top')
20
+ const Top = this.top
21
+ const $config = this.config
11
22
 
12
23
  return (
13
24
  <div className={csses.container}>
@@ -18,7 +29,7 @@ class Container extends Component<ContainerProps<Config>> {
18
29
  {
19
30
  $config.pages.map(({ path, components }) => {
20
31
  const cs = () => components.map((name) => {
21
- const C = $component(name)
32
+ const C = this.components[name]
22
33
  return (
23
34
  <div
24
35
  key={name}
package/webpack/base.js CHANGED
@@ -65,16 +65,6 @@ const config = {
65
65
  exclude: /node_modules/,
66
66
  use: {
67
67
  loader: 'babel-loader',
68
- options: {
69
- presets: [
70
- '@babel/preset-typescript',
71
- ['@babel/preset-env', {
72
- targets: ['defaults'],
73
- modules: false,
74
- }],
75
- '@babel/preset-react',
76
- ],
77
- },
78
68
  },
79
69
  },
80
70
  {