@vitus-labs/core 0.23.0-alpha.0 → 0.23.0-alpha.1

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.
@@ -6424,7 +6424,7 @@ var drawChart = (function (exports) {
6424
6424
  </script>
6425
6425
  <script>
6426
6426
  /*<!--*/
6427
- const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-core.js","children":[{"name":"src","children":[{"uid":"068a-1","name":"config.ts"},{"uid":"068a-3","name":"isEmpty.ts"},{"uid":"068a-5","name":"context.tsx"},{"uid":"068a-7","name":"compose.ts"},{"uid":"068a-9","name":"renderContent.ts"},{"uid":"068a-11","name":"htmlTags.ts"},{"uid":"068a-13","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"068a-1":{"renderedLength":810,"gzipLength":294,"brotliLength":0,"mainUid":"068a-0"},"068a-3":{"renderedLength":358,"gzipLength":180,"brotliLength":0,"mainUid":"068a-2"},"068a-5":{"renderedLength":783,"gzipLength":332,"brotliLength":0,"mainUid":"068a-4"},"068a-7":{"renderedLength":207,"gzipLength":153,"brotliLength":0,"mainUid":"068a-6"},"068a-9":{"renderedLength":893,"gzipLength":284,"brotliLength":0,"mainUid":"068a-8"},"068a-11":{"renderedLength":1691,"gzipLength":494,"brotliLength":0,"mainUid":"068a-10"},"068a-13":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"068a-12"}},"nodeMetas":{"068a-0":{"id":"/src/config.ts","moduleParts":{"vitus-labs-core.js":"068a-1"},"imported":[{"uid":"068a-16"}],"importedBy":[{"uid":"068a-12"},{"uid":"068a-4"}]},"068a-2":{"id":"/src/isEmpty.ts","moduleParts":{"vitus-labs-core.js":"068a-3"},"imported":[],"importedBy":[{"uid":"068a-12"},{"uid":"068a-4"},{"uid":"068a-8"}]},"068a-4":{"id":"/src/context.tsx","moduleParts":{"vitus-labs-core.js":"068a-5"},"imported":[{"uid":"068a-17"},{"uid":"068a-0"},{"uid":"068a-2"}],"importedBy":[{"uid":"068a-12"}]},"068a-6":{"id":"/src/compose.ts","moduleParts":{"vitus-labs-core.js":"068a-7"},"imported":[],"importedBy":[{"uid":"068a-12"}]},"068a-8":{"id":"/src/renderContent.ts","moduleParts":{"vitus-labs-core.js":"068a-9"},"imported":[{"uid":"068a-18"},{"uid":"068a-17"},{"uid":"068a-2"}],"importedBy":[{"uid":"068a-12"}]},"068a-10":{"id":"/src/htmlTags.ts","moduleParts":{"vitus-labs-core.js":"068a-11"},"imported":[],"importedBy":[{"uid":"068a-12"}]},"068a-12":{"id":"/src/index.ts","moduleParts":{"vitus-labs-core.js":"068a-13"},"imported":[{"uid":"068a-14"},{"uid":"068a-15"},{"uid":"068a-0"},{"uid":"068a-4"},{"uid":"068a-6"},{"uid":"068a-2"},{"uid":"068a-8"},{"uid":"068a-10"}],"importedBy":[],"isEntry":true},"068a-14":{"id":"lodash","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-12"}],"isExternal":true},"068a-15":{"id":"moize","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-12"}],"isExternal":true},"068a-16":{"id":"styled-components","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-0"}],"isExternal":true},"068a-17":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-4"},{"uid":"068a-8"}],"isExternal":true},"068a-18":{"id":"react-is","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-8"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6427
+ const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-core.js","children":[{"name":"src","children":[{"uid":"83f7-1","name":"config.ts"},{"uid":"83f7-3","name":"isEmpty.ts"},{"uid":"83f7-5","name":"context.tsx"},{"uid":"83f7-7","name":"compose.ts"},{"uid":"83f7-9","name":"renderContent.ts"},{"uid":"83f7-11","name":"htmlTags.ts"},{"uid":"83f7-13","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"83f7-1":{"renderedLength":810,"gzipLength":294,"brotliLength":0,"mainUid":"83f7-0"},"83f7-3":{"renderedLength":358,"gzipLength":180,"brotliLength":0,"mainUid":"83f7-2"},"83f7-5":{"renderedLength":783,"gzipLength":332,"brotliLength":0,"mainUid":"83f7-4"},"83f7-7":{"renderedLength":207,"gzipLength":153,"brotliLength":0,"mainUid":"83f7-6"},"83f7-9":{"renderedLength":893,"gzipLength":284,"brotliLength":0,"mainUid":"83f7-8"},"83f7-11":{"renderedLength":1691,"gzipLength":494,"brotliLength":0,"mainUid":"83f7-10"},"83f7-13":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"83f7-12"}},"nodeMetas":{"83f7-0":{"id":"/src/config.ts","moduleParts":{"vitus-labs-core.js":"83f7-1"},"imported":[{"uid":"83f7-16"}],"importedBy":[{"uid":"83f7-12"},{"uid":"83f7-4"}]},"83f7-2":{"id":"/src/isEmpty.ts","moduleParts":{"vitus-labs-core.js":"83f7-3"},"imported":[],"importedBy":[{"uid":"83f7-12"},{"uid":"83f7-4"},{"uid":"83f7-8"}]},"83f7-4":{"id":"/src/context.tsx","moduleParts":{"vitus-labs-core.js":"83f7-5"},"imported":[{"uid":"83f7-17"},{"uid":"83f7-0"},{"uid":"83f7-2"}],"importedBy":[{"uid":"83f7-12"}]},"83f7-6":{"id":"/src/compose.ts","moduleParts":{"vitus-labs-core.js":"83f7-7"},"imported":[],"importedBy":[{"uid":"83f7-12"}]},"83f7-8":{"id":"/src/renderContent.ts","moduleParts":{"vitus-labs-core.js":"83f7-9"},"imported":[{"uid":"83f7-18"},{"uid":"83f7-17"},{"uid":"83f7-2"}],"importedBy":[{"uid":"83f7-12"}]},"83f7-10":{"id":"/src/htmlTags.ts","moduleParts":{"vitus-labs-core.js":"83f7-11"},"imported":[],"importedBy":[{"uid":"83f7-12"}]},"83f7-12":{"id":"/src/index.ts","moduleParts":{"vitus-labs-core.js":"83f7-13"},"imported":[{"uid":"83f7-14"},{"uid":"83f7-15"},{"uid":"83f7-0"},{"uid":"83f7-4"},{"uid":"83f7-6"},{"uid":"83f7-2"},{"uid":"83f7-8"},{"uid":"83f7-10"}],"importedBy":[],"isEntry":true},"83f7-14":{"id":"lodash","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-12"}],"isExternal":true},"83f7-15":{"id":"moize","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-12"}],"isExternal":true},"83f7-16":{"id":"styled-components","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-0"}],"isExternal":true},"83f7-17":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-4"},{"uid":"83f7-8"}],"isExternal":true},"83f7-18":{"id":"react-is","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-8"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6428
6428
 
6429
6429
  const run = () => {
6430
6430
  const width = window.innerWidth;
@@ -6424,7 +6424,7 @@ var drawChart = (function (exports) {
6424
6424
  </script>
6425
6425
  <script>
6426
6426
  /*<!--*/
6427
- const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-core.module.js","children":[{"name":"src","children":[{"uid":"068a-20","name":"config.ts"},{"uid":"068a-22","name":"isEmpty.ts"},{"uid":"068a-24","name":"context.tsx"},{"uid":"068a-26","name":"compose.ts"},{"uid":"068a-28","name":"renderContent.ts"},{"uid":"068a-30","name":"htmlTags.ts"},{"uid":"068a-32","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"068a-20":{"renderedLength":763,"gzipLength":273,"brotliLength":0,"mainUid":"068a-19"},"068a-22":{"renderedLength":358,"gzipLength":180,"brotliLength":0,"mainUid":"068a-21"},"068a-24":{"renderedLength":671,"gzipLength":314,"brotliLength":0,"mainUid":"068a-23"},"068a-26":{"renderedLength":207,"gzipLength":153,"brotliLength":0,"mainUid":"068a-25"},"068a-28":{"renderedLength":835,"gzipLength":269,"brotliLength":0,"mainUid":"068a-27"},"068a-30":{"renderedLength":1691,"gzipLength":494,"brotliLength":0,"mainUid":"068a-29"},"068a-32":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"068a-31"}},"nodeMetas":{"068a-19":{"id":"/src/config.ts","moduleParts":{"vitus-labs-core.module.js":"068a-20"},"imported":[{"uid":"068a-35"}],"importedBy":[{"uid":"068a-31"},{"uid":"068a-23"}]},"068a-21":{"id":"/src/isEmpty.ts","moduleParts":{"vitus-labs-core.module.js":"068a-22"},"imported":[],"importedBy":[{"uid":"068a-31"},{"uid":"068a-23"},{"uid":"068a-27"}]},"068a-23":{"id":"/src/context.tsx","moduleParts":{"vitus-labs-core.module.js":"068a-24"},"imported":[{"uid":"068a-36"},{"uid":"068a-19"},{"uid":"068a-21"}],"importedBy":[{"uid":"068a-31"}]},"068a-25":{"id":"/src/compose.ts","moduleParts":{"vitus-labs-core.module.js":"068a-26"},"imported":[],"importedBy":[{"uid":"068a-31"}]},"068a-27":{"id":"/src/renderContent.ts","moduleParts":{"vitus-labs-core.module.js":"068a-28"},"imported":[{"uid":"068a-37"},{"uid":"068a-36"},{"uid":"068a-21"}],"importedBy":[{"uid":"068a-31"}]},"068a-29":{"id":"/src/htmlTags.ts","moduleParts":{"vitus-labs-core.module.js":"068a-30"},"imported":[],"importedBy":[{"uid":"068a-31"}]},"068a-31":{"id":"/src/index.ts","moduleParts":{"vitus-labs-core.module.js":"068a-32"},"imported":[{"uid":"068a-33"},{"uid":"068a-34"},{"uid":"068a-19"},{"uid":"068a-23"},{"uid":"068a-25"},{"uid":"068a-21"},{"uid":"068a-27"},{"uid":"068a-29"}],"importedBy":[],"isEntry":true},"068a-33":{"id":"lodash","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-31"}],"isExternal":true},"068a-34":{"id":"moize","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-31"}],"isExternal":true},"068a-35":{"id":"styled-components","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-19"}],"isExternal":true},"068a-36":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-23"},{"uid":"068a-27"}],"isExternal":true},"068a-37":{"id":"react-is","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-27"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6427
+ const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-core.module.js","children":[{"name":"src","children":[{"uid":"83f7-20","name":"config.ts"},{"uid":"83f7-22","name":"isEmpty.ts"},{"uid":"83f7-24","name":"context.tsx"},{"uid":"83f7-26","name":"compose.ts"},{"uid":"83f7-28","name":"renderContent.ts"},{"uid":"83f7-30","name":"htmlTags.ts"},{"uid":"83f7-32","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"83f7-20":{"renderedLength":763,"gzipLength":273,"brotliLength":0,"mainUid":"83f7-19"},"83f7-22":{"renderedLength":358,"gzipLength":180,"brotliLength":0,"mainUid":"83f7-21"},"83f7-24":{"renderedLength":671,"gzipLength":314,"brotliLength":0,"mainUid":"83f7-23"},"83f7-26":{"renderedLength":207,"gzipLength":153,"brotliLength":0,"mainUid":"83f7-25"},"83f7-28":{"renderedLength":835,"gzipLength":269,"brotliLength":0,"mainUid":"83f7-27"},"83f7-30":{"renderedLength":1691,"gzipLength":494,"brotliLength":0,"mainUid":"83f7-29"},"83f7-32":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"83f7-31"}},"nodeMetas":{"83f7-19":{"id":"/src/config.ts","moduleParts":{"vitus-labs-core.module.js":"83f7-20"},"imported":[{"uid":"83f7-35"}],"importedBy":[{"uid":"83f7-31"},{"uid":"83f7-23"}]},"83f7-21":{"id":"/src/isEmpty.ts","moduleParts":{"vitus-labs-core.module.js":"83f7-22"},"imported":[],"importedBy":[{"uid":"83f7-31"},{"uid":"83f7-23"},{"uid":"83f7-27"}]},"83f7-23":{"id":"/src/context.tsx","moduleParts":{"vitus-labs-core.module.js":"83f7-24"},"imported":[{"uid":"83f7-36"},{"uid":"83f7-19"},{"uid":"83f7-21"}],"importedBy":[{"uid":"83f7-31"}]},"83f7-25":{"id":"/src/compose.ts","moduleParts":{"vitus-labs-core.module.js":"83f7-26"},"imported":[],"importedBy":[{"uid":"83f7-31"}]},"83f7-27":{"id":"/src/renderContent.ts","moduleParts":{"vitus-labs-core.module.js":"83f7-28"},"imported":[{"uid":"83f7-37"},{"uid":"83f7-36"},{"uid":"83f7-21"}],"importedBy":[{"uid":"83f7-31"}]},"83f7-29":{"id":"/src/htmlTags.ts","moduleParts":{"vitus-labs-core.module.js":"83f7-30"},"imported":[],"importedBy":[{"uid":"83f7-31"}]},"83f7-31":{"id":"/src/index.ts","moduleParts":{"vitus-labs-core.module.js":"83f7-32"},"imported":[{"uid":"83f7-33"},{"uid":"83f7-34"},{"uid":"83f7-19"},{"uid":"83f7-23"},{"uid":"83f7-25"},{"uid":"83f7-21"},{"uid":"83f7-27"},{"uid":"83f7-29"}],"importedBy":[],"isEntry":true},"83f7-33":{"id":"lodash","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-31"}],"isExternal":true},"83f7-34":{"id":"moize","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-31"}],"isExternal":true},"83f7-35":{"id":"styled-components","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-19"}],"isExternal":true},"83f7-36":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-23"},{"uid":"83f7-27"}],"isExternal":true},"83f7-37":{"id":"react-is","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-27"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6428
6428
 
6429
6429
  const run = () => {
6430
6430
  const width = window.innerWidth;
@@ -6424,7 +6424,7 @@ var drawChart = (function (exports) {
6424
6424
  </script>
6425
6425
  <script>
6426
6426
  /*<!--*/
6427
- const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-core.umd.js","children":[{"name":"src","children":[{"uid":"068a-39","name":"config.ts"},{"uid":"068a-41","name":"isEmpty.ts"},{"uid":"068a-43","name":"context.tsx"},{"uid":"068a-45","name":"compose.ts"},{"uid":"068a-47","name":"renderContent.ts"},{"uid":"068a-49","name":"htmlTags.ts"},{"uid":"068a-51","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"068a-39":{"renderedLength":872,"gzipLength":297,"brotliLength":0,"mainUid":"068a-38"},"068a-41":{"renderedLength":388,"gzipLength":181,"brotliLength":0,"mainUid":"068a-40"},"068a-43":{"renderedLength":809,"gzipLength":332,"brotliLength":0,"mainUid":"068a-42"},"068a-45":{"renderedLength":213,"gzipLength":155,"brotliLength":0,"mainUid":"068a-44"},"068a-47":{"renderedLength":947,"gzipLength":287,"brotliLength":0,"mainUid":"068a-46"},"068a-49":{"renderedLength":1939,"gzipLength":500,"brotliLength":0,"mainUid":"068a-48"},"068a-51":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"068a-50"}},"nodeMetas":{"068a-38":{"id":"/src/config.ts","moduleParts":{"vitus-labs-core.umd.js":"068a-39"},"imported":[{"uid":"068a-54"}],"importedBy":[{"uid":"068a-50"},{"uid":"068a-42"}]},"068a-40":{"id":"/src/isEmpty.ts","moduleParts":{"vitus-labs-core.umd.js":"068a-41"},"imported":[],"importedBy":[{"uid":"068a-50"},{"uid":"068a-42"},{"uid":"068a-46"}]},"068a-42":{"id":"/src/context.tsx","moduleParts":{"vitus-labs-core.umd.js":"068a-43"},"imported":[{"uid":"068a-55"},{"uid":"068a-38"},{"uid":"068a-40"}],"importedBy":[{"uid":"068a-50"}]},"068a-44":{"id":"/src/compose.ts","moduleParts":{"vitus-labs-core.umd.js":"068a-45"},"imported":[],"importedBy":[{"uid":"068a-50"}]},"068a-46":{"id":"/src/renderContent.ts","moduleParts":{"vitus-labs-core.umd.js":"068a-47"},"imported":[{"uid":"068a-56"},{"uid":"068a-55"},{"uid":"068a-40"}],"importedBy":[{"uid":"068a-50"}]},"068a-48":{"id":"/src/htmlTags.ts","moduleParts":{"vitus-labs-core.umd.js":"068a-49"},"imported":[],"importedBy":[{"uid":"068a-50"}]},"068a-50":{"id":"/src/index.ts","moduleParts":{"vitus-labs-core.umd.js":"068a-51"},"imported":[{"uid":"068a-52"},{"uid":"068a-53"},{"uid":"068a-38"},{"uid":"068a-42"},{"uid":"068a-44"},{"uid":"068a-40"},{"uid":"068a-46"},{"uid":"068a-48"}],"importedBy":[],"isEntry":true},"068a-52":{"id":"lodash","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-50"}],"isExternal":true},"068a-53":{"id":"moize","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-50"}],"isExternal":true},"068a-54":{"id":"styled-components","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-38"}],"isExternal":true},"068a-55":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-42"},{"uid":"068a-46"}],"isExternal":true},"068a-56":{"id":"react-is","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-46"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6427
+ const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-core.umd.js","children":[{"name":"src","children":[{"uid":"83f7-39","name":"config.ts"},{"uid":"83f7-41","name":"isEmpty.ts"},{"uid":"83f7-43","name":"context.tsx"},{"uid":"83f7-45","name":"compose.ts"},{"uid":"83f7-47","name":"renderContent.ts"},{"uid":"83f7-49","name":"htmlTags.ts"},{"uid":"83f7-51","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"83f7-39":{"renderedLength":872,"gzipLength":297,"brotliLength":0,"mainUid":"83f7-38"},"83f7-41":{"renderedLength":388,"gzipLength":181,"brotliLength":0,"mainUid":"83f7-40"},"83f7-43":{"renderedLength":809,"gzipLength":332,"brotliLength":0,"mainUid":"83f7-42"},"83f7-45":{"renderedLength":213,"gzipLength":155,"brotliLength":0,"mainUid":"83f7-44"},"83f7-47":{"renderedLength":947,"gzipLength":287,"brotliLength":0,"mainUid":"83f7-46"},"83f7-49":{"renderedLength":1939,"gzipLength":500,"brotliLength":0,"mainUid":"83f7-48"},"83f7-51":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"83f7-50"}},"nodeMetas":{"83f7-38":{"id":"/src/config.ts","moduleParts":{"vitus-labs-core.umd.js":"83f7-39"},"imported":[{"uid":"83f7-54"}],"importedBy":[{"uid":"83f7-50"},{"uid":"83f7-42"}]},"83f7-40":{"id":"/src/isEmpty.ts","moduleParts":{"vitus-labs-core.umd.js":"83f7-41"},"imported":[],"importedBy":[{"uid":"83f7-50"},{"uid":"83f7-42"},{"uid":"83f7-46"}]},"83f7-42":{"id":"/src/context.tsx","moduleParts":{"vitus-labs-core.umd.js":"83f7-43"},"imported":[{"uid":"83f7-55"},{"uid":"83f7-38"},{"uid":"83f7-40"}],"importedBy":[{"uid":"83f7-50"}]},"83f7-44":{"id":"/src/compose.ts","moduleParts":{"vitus-labs-core.umd.js":"83f7-45"},"imported":[],"importedBy":[{"uid":"83f7-50"}]},"83f7-46":{"id":"/src/renderContent.ts","moduleParts":{"vitus-labs-core.umd.js":"83f7-47"},"imported":[{"uid":"83f7-56"},{"uid":"83f7-55"},{"uid":"83f7-40"}],"importedBy":[{"uid":"83f7-50"}]},"83f7-48":{"id":"/src/htmlTags.ts","moduleParts":{"vitus-labs-core.umd.js":"83f7-49"},"imported":[],"importedBy":[{"uid":"83f7-50"}]},"83f7-50":{"id":"/src/index.ts","moduleParts":{"vitus-labs-core.umd.js":"83f7-51"},"imported":[{"uid":"83f7-52"},{"uid":"83f7-53"},{"uid":"83f7-38"},{"uid":"83f7-42"},{"uid":"83f7-44"},{"uid":"83f7-40"},{"uid":"83f7-46"},{"uid":"83f7-48"}],"importedBy":[],"isEntry":true},"83f7-52":{"id":"lodash","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-50"}],"isExternal":true},"83f7-53":{"id":"moize","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-50"}],"isExternal":true},"83f7-54":{"id":"styled-components","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-38"}],"isExternal":true},"83f7-55":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-42"},{"uid":"83f7-46"}],"isExternal":true},"83f7-56":{"id":"react-is","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-46"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6428
6428
 
6429
6429
  const run = () => {
6430
6430
  const width = window.innerWidth;
@@ -6424,7 +6424,7 @@ var drawChart = (function (exports) {
6424
6424
  </script>
6425
6425
  <script>
6426
6426
  /*<!--*/
6427
- const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-core.umd.min.js","children":[{"name":"src","children":[{"uid":"068a-58","name":"config.ts"},{"uid":"068a-60","name":"isEmpty.ts"},{"uid":"068a-62","name":"context.tsx"},{"uid":"068a-64","name":"compose.ts"},{"uid":"068a-66","name":"renderContent.ts"},{"uid":"068a-68","name":"htmlTags.ts"},{"uid":"068a-70","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"068a-58":{"renderedLength":872,"gzipLength":297,"brotliLength":0,"mainUid":"068a-57"},"068a-60":{"renderedLength":388,"gzipLength":181,"brotliLength":0,"mainUid":"068a-59"},"068a-62":{"renderedLength":809,"gzipLength":332,"brotliLength":0,"mainUid":"068a-61"},"068a-64":{"renderedLength":213,"gzipLength":155,"brotliLength":0,"mainUid":"068a-63"},"068a-66":{"renderedLength":947,"gzipLength":287,"brotliLength":0,"mainUid":"068a-65"},"068a-68":{"renderedLength":1939,"gzipLength":500,"brotliLength":0,"mainUid":"068a-67"},"068a-70":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"068a-69"}},"nodeMetas":{"068a-57":{"id":"/src/config.ts","moduleParts":{"vitus-labs-core.umd.min.js":"068a-58"},"imported":[{"uid":"068a-73"}],"importedBy":[{"uid":"068a-69"},{"uid":"068a-61"}]},"068a-59":{"id":"/src/isEmpty.ts","moduleParts":{"vitus-labs-core.umd.min.js":"068a-60"},"imported":[],"importedBy":[{"uid":"068a-69"},{"uid":"068a-61"},{"uid":"068a-65"}]},"068a-61":{"id":"/src/context.tsx","moduleParts":{"vitus-labs-core.umd.min.js":"068a-62"},"imported":[{"uid":"068a-74"},{"uid":"068a-57"},{"uid":"068a-59"}],"importedBy":[{"uid":"068a-69"}]},"068a-63":{"id":"/src/compose.ts","moduleParts":{"vitus-labs-core.umd.min.js":"068a-64"},"imported":[],"importedBy":[{"uid":"068a-69"}]},"068a-65":{"id":"/src/renderContent.ts","moduleParts":{"vitus-labs-core.umd.min.js":"068a-66"},"imported":[{"uid":"068a-75"},{"uid":"068a-74"},{"uid":"068a-59"}],"importedBy":[{"uid":"068a-69"}]},"068a-67":{"id":"/src/htmlTags.ts","moduleParts":{"vitus-labs-core.umd.min.js":"068a-68"},"imported":[],"importedBy":[{"uid":"068a-69"}]},"068a-69":{"id":"/src/index.ts","moduleParts":{"vitus-labs-core.umd.min.js":"068a-70"},"imported":[{"uid":"068a-71"},{"uid":"068a-72"},{"uid":"068a-57"},{"uid":"068a-61"},{"uid":"068a-63"},{"uid":"068a-59"},{"uid":"068a-65"},{"uid":"068a-67"}],"importedBy":[],"isEntry":true},"068a-71":{"id":"lodash","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-69"}],"isExternal":true},"068a-72":{"id":"moize","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-69"}],"isExternal":true},"068a-73":{"id":"styled-components","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-57"}],"isExternal":true},"068a-74":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-61"},{"uid":"068a-65"}],"isExternal":true},"068a-75":{"id":"react-is","moduleParts":{},"imported":[],"importedBy":[{"uid":"068a-65"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6427
+ const data = {"version":2,"tree":{"name":"root","children":[{"name":"vitus-labs-core.umd.min.js","children":[{"name":"src","children":[{"uid":"83f7-58","name":"config.ts"},{"uid":"83f7-60","name":"isEmpty.ts"},{"uid":"83f7-62","name":"context.tsx"},{"uid":"83f7-64","name":"compose.ts"},{"uid":"83f7-66","name":"renderContent.ts"},{"uid":"83f7-68","name":"htmlTags.ts"},{"uid":"83f7-70","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"83f7-58":{"renderedLength":872,"gzipLength":297,"brotliLength":0,"mainUid":"83f7-57"},"83f7-60":{"renderedLength":388,"gzipLength":181,"brotliLength":0,"mainUid":"83f7-59"},"83f7-62":{"renderedLength":809,"gzipLength":332,"brotliLength":0,"mainUid":"83f7-61"},"83f7-64":{"renderedLength":213,"gzipLength":155,"brotliLength":0,"mainUid":"83f7-63"},"83f7-66":{"renderedLength":947,"gzipLength":287,"brotliLength":0,"mainUid":"83f7-65"},"83f7-68":{"renderedLength":1939,"gzipLength":500,"brotliLength":0,"mainUid":"83f7-67"},"83f7-70":{"renderedLength":0,"gzipLength":0,"brotliLength":0,"mainUid":"83f7-69"}},"nodeMetas":{"83f7-57":{"id":"/src/config.ts","moduleParts":{"vitus-labs-core.umd.min.js":"83f7-58"},"imported":[{"uid":"83f7-73"}],"importedBy":[{"uid":"83f7-69"},{"uid":"83f7-61"}]},"83f7-59":{"id":"/src/isEmpty.ts","moduleParts":{"vitus-labs-core.umd.min.js":"83f7-60"},"imported":[],"importedBy":[{"uid":"83f7-69"},{"uid":"83f7-61"},{"uid":"83f7-65"}]},"83f7-61":{"id":"/src/context.tsx","moduleParts":{"vitus-labs-core.umd.min.js":"83f7-62"},"imported":[{"uid":"83f7-74"},{"uid":"83f7-57"},{"uid":"83f7-59"}],"importedBy":[{"uid":"83f7-69"}]},"83f7-63":{"id":"/src/compose.ts","moduleParts":{"vitus-labs-core.umd.min.js":"83f7-64"},"imported":[],"importedBy":[{"uid":"83f7-69"}]},"83f7-65":{"id":"/src/renderContent.ts","moduleParts":{"vitus-labs-core.umd.min.js":"83f7-66"},"imported":[{"uid":"83f7-75"},{"uid":"83f7-74"},{"uid":"83f7-59"}],"importedBy":[{"uid":"83f7-69"}]},"83f7-67":{"id":"/src/htmlTags.ts","moduleParts":{"vitus-labs-core.umd.min.js":"83f7-68"},"imported":[],"importedBy":[{"uid":"83f7-69"}]},"83f7-69":{"id":"/src/index.ts","moduleParts":{"vitus-labs-core.umd.min.js":"83f7-70"},"imported":[{"uid":"83f7-71"},{"uid":"83f7-72"},{"uid":"83f7-57"},{"uid":"83f7-61"},{"uid":"83f7-63"},{"uid":"83f7-59"},{"uid":"83f7-65"},{"uid":"83f7-67"}],"importedBy":[],"isEntry":true},"83f7-71":{"id":"lodash","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-69"}],"isExternal":true},"83f7-72":{"id":"moize","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-69"}],"isExternal":true},"83f7-73":{"id":"styled-components","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-57"}],"isExternal":true},"83f7-74":{"id":"react","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-61"},{"uid":"83f7-65"}],"isExternal":true},"83f7-75":{"id":"react-is","moduleParts":{},"imported":[],"importedBy":[{"uid":"83f7-65"}],"isExternal":true}},"env":{"rollup":"2.67.1"},"options":{"gzip":true,"brotli":false,"sourcemap":false}};
6428
6428
 
6429
6429
  const run = () => {
6430
6430
  const width = window.innerWidth;
@@ -1 +1 @@
1
- {"version":3,"file":"vitus-labs-core.umd.min.js","sources":["../src/config.ts","../src/isEmpty.ts","../src/context.tsx","../src/compose.ts","../src/htmlTags.ts","../src/renderContent.ts"],"sourcesContent":["import { ComponentType } from 'react'\nimport styled, {\n css,\n ThemeProvider,\n ThemedCssFunction,\n StyledInterface,\n DefaultTheme,\n ThemeProviderComponent,\n} from 'styled-components'\nimport type { HTMLTags } from '~/htmlTags'\n\nconst OPTIONS: Internal = {\n styled,\n css,\n styledContext: ThemeProvider,\n component: 'div',\n textComponent: 'span',\n} as Internal\n\ntype Init = ({\n styled,\n css,\n context,\n component,\n textComponent,\n}: {\n styled: any\n css: any\n context: any\n component?: ComponentType | HTMLTags\n textComponent?: ComponentType | HTMLTags\n}) => void\n\nconst init: Init = ({\n styled,\n css,\n context,\n component = 'div',\n textComponent = 'span',\n}) => {\n OPTIONS.css = css\n OPTIONS.styled = styled\n OPTIONS.styledContext = context\n OPTIONS.component = component\n OPTIONS.textComponent = textComponent\n}\n\ninterface Internal {\n css: ThemedCssFunction<DefaultTheme>\n styled: StyledInterface\n styledContext: ThemeProviderComponent<any, any>\n component: any\n textComponent: any\n}\n\nconst internal: Internal = Object.freeze({\n get css() {\n return OPTIONS.css\n },\n get styled() {\n return OPTIONS.styled\n },\n get styledContext() {\n return OPTIONS.styledContext\n },\n get component() {\n return OPTIONS.component\n },\n get textComponent() {\n return OPTIONS.textComponent\n },\n})\n\nexport { init }\nexport default internal\n","export type IsEmpty = <T extends Record<string, unknown> | unknown[] | null>(\n param?: T\n) => null | undefined extends T ? true : keyof T extends never ? true : false\n\nconst isEmpty: IsEmpty = (param) => {\n if (!param) return true\n\n if (typeof param !== 'object') {\n return true as any\n }\n\n if (Array.isArray(param) && param.length === 0) {\n return true\n }\n\n if (\n Object.entries(param as any).length === 0 &&\n param.constructor === Object\n ) {\n return true\n }\n\n return false\n}\n\nexport default isEmpty\n","import React, { createContext, FC, useMemo } from 'react'\nimport config from '~/config'\nimport isEmpty from '~/isEmpty'\n\nconst context = createContext<any>({})\nconst VitusLabsProvider = context.Provider\n\ntype Theme = Partial<\n {\n rootSize: number\n breakpoints: Record<string, number | string>\n } & Record<string, any>\n>\n\ntype ProviderType = Partial<\n {\n theme: Theme\n } & Record<string, any>\n>\n\nconst Provider: FC<ProviderType> = ({ theme, children, ...props }) => {\n // eslint-disable-next-line react/jsx-no-useless-fragment\n if (!theme || isEmpty(theme)) return <>{children}</>\n\n const StyledContext = useMemo(() => config.styledContext, [])\n\n if (StyledContext) {\n return (\n <VitusLabsProvider value={{ theme, ...props }}>\n <StyledContext theme={theme}>{children}</StyledContext>\n </VitusLabsProvider>\n )\n }\n\n return (\n <VitusLabsProvider value={{ theme, ...props }}>\n {children}\n </VitusLabsProvider>\n )\n}\n\nexport { context }\n\nexport default Provider\n","// const compose = <R>(fn1: (a: R) => R, ...fns: Array<(a: R) => R>) =>\n// fns.reduce((a, b) => (value) => a(b(value)), fn1)\n\n// const compose = (funcs) =>\n// funcs.reduce(\n// (a, b) => (...args) => a(b(...args)),\n// (arg) => arg\n// )\n\ntype ArityOneFn = (arg: any) => any\ntype PickLastInTuple<T extends any[]> = T extends [\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n ...rest: infer U,\n argn: infer L\n]\n ? L\n : any\ntype FirstFnParameterType<T extends any[]> = Parameters<PickLastInTuple<T>>[any]\ntype LastFnReturnType<T extends any[]> = ReturnType<T[0]>\n\nconst compose =\n <T extends ArityOneFn[]>(...fns: T) =>\n (p: FirstFnParameterType<T>): LastFnReturnType<T> =>\n fns.reduceRight((acc: any, cur: any) => cur(acc), p)\n\nexport default compose\n","const TAGS = [\n 'a',\n 'abbr',\n // 'acronym',\n 'address',\n // 'applet',\n 'area',\n 'article',\n 'aside',\n 'audio',\n 'b',\n 'base',\n // 'basefont',\n 'bdi',\n 'bdo',\n 'big',\n 'blockquote',\n 'body',\n 'br',\n 'button',\n 'canvas',\n 'caption',\n // 'center',\n 'cite',\n 'code',\n 'col',\n 'colgroup',\n 'data',\n 'datalist',\n 'dd',\n 'del',\n 'details',\n 'dfn',\n 'dialog',\n // 'dir',\n 'div',\n 'dl',\n 'dt',\n 'em',\n 'embed',\n 'fieldset',\n 'figcaption',\n 'figure',\n // 'font',\n 'footer',\n 'form',\n // 'frame',\n // 'frameset',\n 'h1',\n 'h2',\n 'h3',\n 'h4',\n 'h5',\n 'h6',\n 'head',\n 'header',\n 'hr',\n 'html',\n 'i',\n 'iframe',\n 'img',\n 'input',\n 'ins',\n 'kbd',\n 'label',\n 'legend',\n 'li',\n 'link',\n 'main',\n 'map',\n 'mark',\n 'meta',\n 'meter',\n 'nav',\n // 'noframes',\n 'noscript',\n 'object',\n 'ol',\n 'optgroup',\n 'option',\n 'output',\n 'p',\n 'param',\n 'picture',\n 'pre',\n 'progress',\n 'q',\n 'rp',\n 'rt',\n 'ruby',\n 's',\n 'samp',\n 'script',\n 'section',\n 'select',\n 'small',\n 'source',\n 'span',\n // 'strike',\n 'strong',\n 'style',\n 'sub',\n 'summary',\n 'sup',\n 'svg',\n 'table',\n 'tbody',\n 'td',\n 'template',\n 'textarea',\n 'tfoot',\n 'th',\n 'thead',\n 'time',\n // 'title',\n 'tr',\n 'track',\n // 'tt',\n 'u',\n 'ul',\n 'var',\n 'video',\n 'wbr',\n] as const\n\nconst TEXT_TAGS = [\n 'abbr',\n 'b',\n 'bdi',\n 'bdo',\n 'big',\n 'blockquote',\n 'cite',\n 'code',\n 'dl',\n 'dt',\n 'em',\n 'figcaption',\n 'h1',\n 'h2',\n 'h3',\n 'h4',\n 'h5',\n 'h6',\n 'i',\n 'ins',\n 'kbd',\n 'label',\n 'legend',\n 'li',\n 'p',\n 'pre',\n 'q',\n 'rp',\n 'rt',\n 's',\n 'small',\n 'span',\n 'strong',\n 'sub',\n 'summary',\n 'sup',\n 'time',\n 'u',\n] as const\n\nexport type HTMLTags = typeof TAGS[number]\n\nexport type HTMLTagsText = typeof TEXT_TAGS[number]\n\nexport default TAGS\n","import { isValidElementType, isFragment } from 'react-is'\nimport { createElement, isValidElement, cloneElement, ReactNode } from 'react'\nimport isEmpty from './isEmpty'\n\ntype CreateTypes = Parameters<typeof createElement>[0]\ntype CloneTypes = Parameters<typeof cloneElement>[0]\n\nexport type RenderContent = (\n content?: CreateTypes | CloneTypes | ReactNode | ReactNode[],\n attachProps?: Record<string, any>\n) => ReturnType<typeof createElement> | ReturnType<typeof cloneElement> | null\n\nconst renderContent: RenderContent = (content, attachProps) => {\n if (!content) return null as any\n\n if (typeof content === 'string' && isValidElement(content)) {\n return attachProps\n ? createElement(content, attachProps)\n : createElement(content)\n }\n\n if (['number', 'boolean', 'string'].includes(typeof content)) {\n return content\n }\n\n if (Array.isArray(content) || isFragment(content)) {\n return content\n }\n\n if (isValidElementType(content)) {\n return attachProps\n ? createElement(content, attachProps)\n : createElement(content)\n }\n\n if (isValidElement(content)) {\n if (isEmpty(attachProps)) {\n return content\n }\n\n return cloneElement(content, attachProps)\n }\n\n return content\n}\n\nexport default renderContent\n"],"names":["OPTIONS","styled","css","styledContext","ThemeProvider","component","textComponent","internal","Object","freeze","isEmpty","param","Array","isArray","length","entries","constructor","context","createContext","VitusLabsProvider","Provider","theme","children","props","React","StyledContext","useMemo","config","value","fns","p","reduceRight","acc","cur","content","attachProps","isValidElement","createElement","includes","isFragment","isValidElementType","cloneElement"],"mappings":"yiBAWA,MAAMA,EAAoB,QACxBC,cACAC,MACAC,cAAeC,gBACfC,UAAW,MACXC,cAAe,QAuCXC,EAAqBC,OAAOC,OAAO,CACvCP,UACE,OAAOF,EAAQE,KAEjBD,aACE,OAAOD,EAAQC,QAEjBE,oBACE,OAAOH,EAAQG,eAEjBE,gBACE,OAAOL,EAAQK,WAEjBC,oBACE,OAAON,EAAQM,iBCjEbI,EAAoBC,IACnBA,IAEgB,iBAAVA,OAIPC,MAAMC,QAAQF,IAA2B,IAAjBA,EAAMG,SAKQ,IAAxCN,OAAOO,QAAQJ,GAAcG,QAC7BH,EAAMK,cAAgBR,SCbpBS,EAAUC,gBAAmB,IAC7BC,EAAoBF,EAAQG,kkBAeC,EAAGC,MAAAA,EAAOC,SAAAA,KAAaC,MAExD,IAAKF,GAASX,EAAQW,GAAQ,OAAOG,gDAAGF,GAExC,MAAMG,EAAgBC,WAAQ,IAAMC,EAAOxB,eAAe,IAE1D,OAAIsB,EAEAD,wBAACL,GAAkBS,MAAO,CAAEP,MAAAA,KAAUE,IACpCC,wBAACC,GAAcJ,MAAOA,GAAQC,IAMlCE,wBAACL,GAAkBS,MAAO,CAAEP,MAAAA,KAAUE,IACnCD,cCfL,IAA4BO,IAC3BC,GACCD,EAAIE,aAAY,CAACC,EAAUC,IAAaA,EAAID,IAAMF,qCCvBzC,CACX,IACA,OAEA,UAEA,OACA,UACA,QACA,QACA,IACA,OAEA,MACA,MACA,MACA,aACA,OACA,KACA,SACA,SACA,UAEA,OACA,OACA,MACA,WACA,OACA,WACA,KACA,MACA,UACA,MACA,SAEA,MACA,KACA,KACA,KACA,QACA,WACA,aACA,SAEA,SACA,OAGA,KACA,KACA,KACA,KACA,KACA,KACA,OACA,SACA,KACA,OACA,IACA,SACA,MACA,QACA,MACA,MACA,QACA,SACA,KACA,OACA,OACA,MACA,OACA,OACA,QACA,MAEA,WACA,SACA,KACA,WACA,SACA,SACA,IACA,QACA,UACA,MACA,WACA,IACA,KACA,KACA,OACA,IACA,OACA,SACA,UACA,SACA,QACA,SACA,OAEA,SACA,QACA,MACA,UACA,MACA,MACA,QACA,QACA,KACA,WACA,WACA,QACA,KACA,QACA,OAEA,KACA,QAEA,IACA,KACA,MACA,QACA,cJzFiB,EACjB7B,OAAAA,EACAC,IAAAA,EACAe,QAAAA,EACAZ,UAAAA,EAAY,MACZC,cAAAA,EAAgB,WAEhBN,EAAQE,IAAMA,EACdF,EAAQC,OAASA,EACjBD,EAAQG,cAAgBc,EACxBjB,EAAQK,UAAYA,EACpBL,EAAQM,cAAgBA,+BKhCW,CAAC4B,EAASC,IACxCD,EAEkB,iBAAZA,GAAwBE,iBAAeF,GACzCC,EACHE,gBAAcH,EAASC,GACvBE,gBAAcH,GAGhB,CAAC,SAAU,UAAW,UAAUI,gBAAgBJ,IAIhDtB,MAAMC,QAAQqB,IAAYK,aAAWL,GAHhCA,EAOLM,qBAAmBN,GACdC,EACHE,gBAAcH,EAASC,GACvBE,gBAAcH,GAGhBE,iBAAeF,GACbxB,EAAQyB,GACHD,EAGFO,eAAaP,EAASC,GAGxBD,EA9Bc"}
1
+ {"version":3,"file":"vitus-labs-core.umd.min.js","sources":["../src/config.ts","../src/isEmpty.ts","../src/context.tsx","../src/compose.ts","../src/htmlTags.ts","../src/renderContent.ts"],"sourcesContent":["import { ComponentType } from 'react'\nimport styled, {\n css,\n ThemeProvider,\n ThemedCssFunction,\n StyledInterface,\n DefaultTheme,\n ThemeProviderComponent,\n} from 'styled-components'\nimport type { HTMLTags } from '~/htmlTags'\n\nconst OPTIONS: Internal = {\n styled,\n css,\n styledContext: ThemeProvider,\n component: 'div',\n textComponent: 'span',\n} as Internal\n\ntype Init = ({\n styled,\n css,\n context,\n component,\n textComponent,\n}: {\n styled: any\n css: any\n context: any\n component?: ComponentType | HTMLTags\n textComponent?: ComponentType | HTMLTags\n}) => void\n\nconst init: Init = ({\n styled,\n css,\n context,\n component = 'div',\n textComponent = 'span',\n}) => {\n OPTIONS.css = css\n OPTIONS.styled = styled\n OPTIONS.styledContext = context\n OPTIONS.component = component\n OPTIONS.textComponent = textComponent\n}\n\ninterface Internal {\n css: ThemedCssFunction<DefaultTheme>\n styled: StyledInterface\n styledContext: ThemeProviderComponent<any, any>\n component: any\n textComponent: any\n}\n\nconst internal: Internal = Object.freeze({\n get css() {\n return OPTIONS.css\n },\n get styled() {\n return OPTIONS.styled\n },\n get styledContext() {\n return OPTIONS.styledContext\n },\n get component() {\n return OPTIONS.component\n },\n get textComponent() {\n return OPTIONS.textComponent\n },\n})\n\nexport { init }\nexport default internal\n","export type IsEmpty = <T extends Record<string, unknown> | unknown[] | null>(\n param?: T\n) => null | undefined extends T ? true : keyof T extends never ? true : false\n\nconst isEmpty: IsEmpty = (param) => {\n if (!param) return true\n\n if (typeof param !== 'object') {\n return true as any\n }\n\n if (Array.isArray(param) && param.length === 0) {\n return true\n }\n\n if (\n Object.entries(param as any).length === 0 &&\n param.constructor === Object\n ) {\n return true\n }\n\n return false\n}\n\nexport default isEmpty\n","import React, { createContext, FC, useMemo } from 'react'\nimport config from '~/config'\nimport isEmpty from '~/isEmpty'\n\nconst context = createContext<any>({})\nconst VitusLabsProvider = context.Provider\n\ntype Theme = Partial<\n {\n rootSize: number\n breakpoints: Record<string, number | string>\n } & Record<string, any>\n>\n\ntype ProviderType = Partial<\n {\n theme: Theme\n } & Record<string, any>\n>\n\nconst Provider: FC<ProviderType> = ({ theme, children, ...props }) => {\n // eslint-disable-next-line react/jsx-no-useless-fragment\n if (!theme || isEmpty(theme)) return <>{children}</>\n\n const StyledContext = useMemo(() => config.styledContext, [])\n\n if (StyledContext) {\n return (\n <VitusLabsProvider value={{ theme, ...props }}>\n <StyledContext theme={theme}>{children}</StyledContext>\n </VitusLabsProvider>\n )\n }\n\n return (\n <VitusLabsProvider value={{ theme, ...props }}>\n {children}\n </VitusLabsProvider>\n )\n}\n\nexport { context }\n\nexport default Provider\n","// const compose = <R>(fn1: (a: R) => R, ...fns: Array<(a: R) => R>) =>\n// fns.reduce((a, b) => (value) => a(b(value)), fn1)\n\n// const compose = (funcs) =>\n// funcs.reduce(\n// (a, b) => (...args) => a(b(...args)),\n// (arg) => arg\n// )\n\ntype ArityOneFn = (arg: any) => any\ntype PickLastInTuple<T extends any[]> = T extends [\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n ...rest: infer U,\n argn: infer L\n]\n ? L\n : any\ntype FirstFnParameterType<T extends any[]> = Parameters<PickLastInTuple<T>>[any]\ntype LastFnReturnType<T extends any[]> = ReturnType<T[0]>\n\nconst compose =\n <T extends ArityOneFn[]>(...fns: T) =>\n (p: FirstFnParameterType<T>): LastFnReturnType<T> =>\n fns.reduceRight((acc: any, cur: any) => cur(acc), p)\n\nexport default compose\n","const TAGS = [\n 'a',\n 'abbr',\n // 'acronym',\n 'address',\n // 'applet',\n 'area',\n 'article',\n 'aside',\n 'audio',\n 'b',\n 'base',\n // 'basefont',\n 'bdi',\n 'bdo',\n 'big',\n 'blockquote',\n 'body',\n 'br',\n 'button',\n 'canvas',\n 'caption',\n // 'center',\n 'cite',\n 'code',\n 'col',\n 'colgroup',\n 'data',\n 'datalist',\n 'dd',\n 'del',\n 'details',\n 'dfn',\n 'dialog',\n // 'dir',\n 'div',\n 'dl',\n 'dt',\n 'em',\n 'embed',\n 'fieldset',\n 'figcaption',\n 'figure',\n // 'font',\n 'footer',\n 'form',\n // 'frame',\n // 'frameset',\n 'h1',\n 'h2',\n 'h3',\n 'h4',\n 'h5',\n 'h6',\n 'head',\n 'header',\n 'hr',\n 'html',\n 'i',\n 'iframe',\n 'img',\n 'input',\n 'ins',\n 'kbd',\n 'label',\n 'legend',\n 'li',\n 'link',\n 'main',\n 'map',\n 'mark',\n 'meta',\n 'meter',\n 'nav',\n // 'noframes',\n 'noscript',\n 'object',\n 'ol',\n 'optgroup',\n 'option',\n 'output',\n 'p',\n 'param',\n 'picture',\n 'pre',\n 'progress',\n 'q',\n 'rp',\n 'rt',\n 'ruby',\n 's',\n 'samp',\n 'script',\n 'section',\n 'select',\n 'small',\n 'source',\n 'span',\n // 'strike',\n 'strong',\n 'style',\n 'sub',\n 'summary',\n 'sup',\n 'svg',\n 'table',\n 'tbody',\n 'td',\n 'template',\n 'textarea',\n 'tfoot',\n 'th',\n 'thead',\n 'time',\n // 'title',\n 'tr',\n 'track',\n // 'tt',\n 'u',\n 'ul',\n 'var',\n 'video',\n 'wbr',\n] as const\n\nconst TEXT_TAGS = [\n 'abbr',\n 'b',\n 'bdi',\n 'bdo',\n 'big',\n 'blockquote',\n 'cite',\n 'code',\n 'dl',\n 'dt',\n 'em',\n 'figcaption',\n 'h1',\n 'h2',\n 'h3',\n 'h4',\n 'h5',\n 'h6',\n 'i',\n 'ins',\n 'kbd',\n 'label',\n 'legend',\n 'li',\n 'p',\n 'pre',\n 'q',\n 'rp',\n 'rt',\n 's',\n 'small',\n 'span',\n 'strong',\n 'sub',\n 'summary',\n 'sup',\n 'time',\n 'u',\n] as const\n\nexport type HTMLTags = typeof TAGS[number]\n\nexport type HTMLTagsText = typeof TEXT_TAGS[number]\n\nexport default TAGS\n","import { isValidElementType, isFragment } from 'react-is'\nimport { createElement, isValidElement, cloneElement, ReactNode } from 'react'\nimport isEmpty from './isEmpty'\n\ntype CreateTypes = Parameters<typeof createElement>[0]\ntype CloneTypes = Parameters<typeof cloneElement>[0]\n\nexport type RenderContent = (\n content?: CreateTypes | CloneTypes | ReactNode | ReactNode[],\n attachProps?: Record<string, any>\n) => ReturnType<typeof createElement> | ReturnType<typeof cloneElement> | null\n\nconst renderContent: RenderContent = (content, attachProps) => {\n if (!content) return null as any\n\n if (typeof content === 'string' && isValidElement(content)) {\n return attachProps\n ? createElement(content, attachProps)\n : createElement(content)\n }\n\n if (['number', 'boolean', 'string'].includes(typeof content)) {\n return content\n }\n\n if (Array.isArray(content) || isFragment(content)) {\n return content\n }\n\n if (isValidElementType(content)) {\n return attachProps\n ? createElement(content, attachProps)\n : createElement(content)\n }\n\n if (isValidElement(content)) {\n if (isEmpty(attachProps)) {\n return content\n }\n\n return cloneElement(content, attachProps)\n }\n\n return content\n}\n\nexport default renderContent\n"],"names":["OPTIONS","styled","css","styledContext","ThemeProvider","component","textComponent","internal","Object","freeze","isEmpty","param","Array","isArray","length","entries","constructor","context","createContext","VitusLabsProvider","Provider","theme","children","props","React","StyledContext","useMemo","config","value","fns","p","reduceRight","acc","cur","content","attachProps","isValidElement","createElement","includes","isFragment","isValidElementType","cloneElement"],"mappings":"yiBAWA,MAAMA,EAAoB,QACxBC,cACAC,MACAC,cAAeC,gBACfC,UAAW,MACXC,cAAe,QAuCXC,EAAqBC,OAAOC,OAAO,CACnCP,UACF,OAAOF,EAAQE,KAEbD,aACF,OAAOD,EAAQC,QAEbE,oBACF,OAAOH,EAAQG,eAEbE,gBACF,OAAOL,EAAQK,WAEbC,oBACF,OAAON,EAAQM,iBCjEbI,EAAoBC,IACnBA,IAEgB,iBAAVA,OAIPC,MAAMC,QAAQF,IAA2B,IAAjBA,EAAMG,SAKQ,IAAxCN,OAAOO,QAAQJ,GAAcG,QAC7BH,EAAMK,cAAgBR,SCbpBS,EAAUC,gBAAmB,IAC7BC,EAAoBF,EAAQG,kkBAeC,EAAGC,MAAAA,EAAOC,SAAAA,KAAaC,MAExD,IAAKF,GAASX,EAAQW,GAAQ,OAAOG,gDAAGF,GAExC,MAAMG,EAAgBC,WAAQ,IAAMC,EAAOxB,eAAe,IAE1D,OAAIsB,EAEAD,wBAACL,GAAkBS,MAAO,CAAEP,MAAAA,KAAUE,IACpCC,wBAACC,GAAcJ,MAAOA,GAAQC,IAMlCE,wBAACL,GAAkBS,MAAO,CAAEP,MAAAA,KAAUE,IACnCD,cCfL,IAA4BO,IAC3BC,GACCD,EAAIE,aAAY,CAACC,EAAUC,IAAaA,EAAID,IAAMF,qCCvBzC,CACX,IACA,OAEA,UAEA,OACA,UACA,QACA,QACA,IACA,OAEA,MACA,MACA,MACA,aACA,OACA,KACA,SACA,SACA,UAEA,OACA,OACA,MACA,WACA,OACA,WACA,KACA,MACA,UACA,MACA,SAEA,MACA,KACA,KACA,KACA,QACA,WACA,aACA,SAEA,SACA,OAGA,KACA,KACA,KACA,KACA,KACA,KACA,OACA,SACA,KACA,OACA,IACA,SACA,MACA,QACA,MACA,MACA,QACA,SACA,KACA,OACA,OACA,MACA,OACA,OACA,QACA,MAEA,WACA,SACA,KACA,WACA,SACA,SACA,IACA,QACA,UACA,MACA,WACA,IACA,KACA,KACA,OACA,IACA,OACA,SACA,UACA,SACA,QACA,SACA,OAEA,SACA,QACA,MACA,UACA,MACA,MACA,QACA,QACA,KACA,WACA,WACA,QACA,KACA,QACA,OAEA,KACA,QAEA,IACA,KACA,MACA,QACA,cJzFiB,EACjB7B,OAAAA,EACAC,IAAAA,EACAe,QAAAA,EACAZ,UAAAA,EAAY,MACZC,cAAAA,EAAgB,WAEhBN,EAAQE,IAAMA,EACdF,EAAQC,OAASA,EACjBD,EAAQG,cAAgBc,EACxBjB,EAAQK,UAAYA,EACpBL,EAAQM,cAAgBA,+BKhCW,CAAC4B,EAASC,IACxCD,EAEkB,iBAAZA,GAAwBE,iBAAeF,GACzCC,EACHE,gBAAcH,EAASC,GACvBE,gBAAcH,GAGhB,CAAC,SAAU,UAAW,UAAUI,gBAAgBJ,IAIhDtB,MAAMC,QAAQqB,IAAYK,aAAWL,GAHhCA,EAOLM,qBAAmBN,GACdC,EACHE,gBAAcH,EAASC,GACvBE,gBAAcH,GAGhBE,iBAAeF,GACbxB,EAAQyB,GACHD,EAGFO,eAAaP,EAASC,GAGxBD,EA9Bc"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vitus-labs/core",
3
- "version": "0.23.0-alpha.0",
3
+ "version": "0.23.0-alpha.1",
4
4
  "license": "MIT",
5
5
  "author": "Vit Bokisch <vit@bokisch.cz>",
6
6
  "maintainers": [
@@ -67,5 +67,5 @@
67
67
  "@vitus-labs/tools-typescript": "^0.26.0",
68
68
  "styled-components": "^5.3.3"
69
69
  },
70
- "gitHead": "e09e4864be0d9c7eda8f0c09cf7ecdce5670d47a"
70
+ "gitHead": "4b63adee8a306086cec6ec74fe5c23ff6af8372d"
71
71
  }