@eodash/eodash 5.0.0-rc.2.2 → 5.0.0-rc.2.4

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.
Files changed (53) hide show
  1. package/core/client/components/EodashOverlay.vue +56 -0
  2. package/core/client/components/Footer.vue +1 -15
  3. package/core/client/composables/EodashProcess.js +4 -0
  4. package/core/client/eodash.js +4 -7
  5. package/core/client/eodashSTAC/EodashCollection.js +62 -31
  6. package/core/client/eodashSTAC/createLayers.js +15 -2
  7. package/core/client/eodashSTAC/helpers.js +1 -2
  8. package/core/client/types.ts +1 -1
  9. package/core/client/utils/states.js +43 -0
  10. package/core/client/views/Dashboard.vue +4 -1
  11. package/core/client/vite-env.d.ts +13 -0
  12. package/dist/client/{DashboardLayout-ByVMURpM.js → DashboardLayout-D1UcB3RV.js} +3 -3
  13. package/dist/client/{DynamicWebComponent-BRQQ5AXV.js → DynamicWebComponent-DtZ_mHL9.js} +2 -2
  14. package/dist/client/{EodashDatePicker-DyLo_JUC.js → EodashDatePicker-CYU0MZX5.js} +3 -3
  15. package/dist/client/{EodashItemFilter-BR572AaH.js → EodashItemFilter-SE9oW3oZ.js} +3 -3
  16. package/dist/client/{EodashLayerControl-C_mi-Hoo.js → EodashLayerControl-BuGe29Nt.js} +11 -4
  17. package/dist/client/{EodashLayoutSwitcher-D4ooLbys.js → EodashLayoutSwitcher-6wLl-Gtd.js} +3 -3
  18. package/dist/client/{EodashMap-CGFv4e85.js → EodashMap-DhVCoYMi.js} +11 -4
  19. package/dist/client/{EodashMapBtns-_M7SW7Is.js → EodashMapBtns-BWWu6eHG.js} +5 -5
  20. package/dist/client/{EodashProcess-ZQAMi9Pc.js → EodashProcess-GSj_LMsK.js} +23 -18
  21. package/dist/client/{EodashStacInfo-CwOCcsGl.js → EodashStacInfo-DjRSGLHM.js} +2 -2
  22. package/dist/client/{EodashTools-C_X0RPIp.js → EodashTools-CJ4hBH_X.js} +5 -5
  23. package/dist/client/{ExportState-DNUSRJSJ.js → ExportState-BqnlEpzR.js} +5 -5
  24. package/dist/client/Footer-C_3WrfI4.js +119 -0
  25. package/dist/client/{Header-BcHAtFqr.js → Header-D_hcGpNG.js} +4 -4
  26. package/dist/client/{IframeWrapper-BgM9aU8f.js → IframeWrapper-XzQDZy0T.js} +1 -1
  27. package/dist/client/{MobileLayout-CUHZFLDY.js → MobileLayout-CDbupC9v.js} +6 -6
  28. package/dist/client/{PopUp-CEmhdNIj.js → PopUp-Ba6mY2jQ.js} +5 -4
  29. package/dist/client/{VImg-Cdaw92OV.js → VImg-Yc9F9pYq.js} +4 -4
  30. package/dist/client/{VMain-B7G2T3Zv.js → VMain-BiS7HPEk.js} +1 -1
  31. package/dist/client/{VOverlay-Mf1pOmgW.js → VOverlay-B9mxXaCv.js} +4 -4
  32. package/dist/client/{VTooltip-9810qjB2.js → VTooltip-XJLaLrZQ.js} +3 -3
  33. package/dist/client/{WidgetsContainer-GUwXMh9d.js → WidgetsContainer-DRVb_73N.js} +2 -2
  34. package/dist/client/{asWebComponent--e4yqM3f.js → asWebComponent-DZpMGxEY.js} +329 -170
  35. package/dist/client/eo-dash.css +2 -2
  36. package/dist/client/eo-dash.js +1 -1
  37. package/dist/client/{forwardRefs-B9UH8QZK.js → forwardRefs-BtkfywIE.js} +1 -1
  38. package/dist/client/{index-D-lbt2my.js → index-f55xuyof.js} +3 -1
  39. package/dist/client/{transition-CTjQmgIS.js → transition-CtL4BoVi.js} +2 -2
  40. package/dist/node/cli.js +2 -2
  41. package/dist/types/core/client/components/EodashOverlay.vue.d.ts +2 -0
  42. package/dist/types/core/client/components/MobileLayout.vue.d.ts +254 -241
  43. package/dist/types/core/client/eodashSTAC/EodashCollection.d.ts +40 -15
  44. package/dist/types/core/client/eodashSTAC/createLayers.d.ts +23 -3
  45. package/dist/types/core/client/eodashSTAC/helpers.d.ts +3 -78
  46. package/dist/types/core/client/utils/states.d.ts +43 -0
  47. package/dist/types/widgets/PopUp.vue.d.ts +2 -2
  48. package/package.json +20 -20
  49. package/widgets/EodashItemFilter.vue +1 -1
  50. package/widgets/EodashLayerControl.vue +7 -0
  51. package/widgets/EodashMap.vue +8 -1
  52. package/widgets/EodashProcess.vue +18 -13
  53. package/dist/client/Footer-FUp1Te0L.js +0 -141
@@ -1,2 +1,2 @@
1
- export { aX as EodashConstructor, aY as register, aZ as store } from './asWebComponent--e4yqM3f.js';
1
+ export { aX as EodashConstructor, aY as register, aZ as store } from './asWebComponent-DZpMGxEY.js';
2
2
  import 'vue';
@@ -1,5 +1,5 @@
1
1
  import { shallowRef, computed, watch } from 'vue';
2
- import { p as propsFactory, aI as getCurrentInstance } from './asWebComponent--e4yqM3f.js';
2
+ import { p as propsFactory, aI as getCurrentInstance } from './asWebComponent-DZpMGxEY.js';
3
3
 
4
4
  class Box {
5
5
  constructor(_ref) {
@@ -1,5 +1,5 @@
1
1
  import { TransitionGroup, Transition, h, camelize } from 'vue';
2
- import { g as genericComponent, p as propsFactory } from './asWebComponent--e4yqM3f.js';
2
+ import { g as genericComponent, p as propsFactory } from './asWebComponent-DZpMGxEY.js';
3
3
 
4
4
  // Utilities
5
5
  const makeTransitionProps = propsFactory({
@@ -130,6 +130,7 @@ function ExpandTransitionGenerator () {
130
130
  },
131
131
  onEnter(el) {
132
132
  const initialStyle = el._initialStyle;
133
+ if (!initialStyle) return;
133
134
  el.style.setProperty('transition', 'none', 'important');
134
135
  // Hide overflow to account for collapsed margins in the calculated height
135
136
  el.style.overflow = 'hidden';
@@ -169,6 +170,7 @@ function ExpandTransitionGenerator () {
169
170
  resetStyles(el);
170
171
  }
171
172
  function resetStyles(el) {
173
+ if (!el._initialStyle) return;
172
174
  const size = el._initialStyle[sizeProperty];
173
175
  el.style.overflow = el._initialStyle.overflow;
174
176
  if (size != null) el.style[sizeProperty] = size;
@@ -1,5 +1,5 @@
1
- import { h, mergeProps, TransitionGroup, Transition } from 'vue';
2
- import { p as propsFactory } from './asWebComponent--e4yqM3f.js';
1
+ import { TransitionGroup, Transition, h, mergeProps } from 'vue';
2
+ import { p as propsFactory } from './asWebComponent-DZpMGxEY.js';
3
3
 
4
4
  // Utilities
5
5
  const makeTransitionProps = propsFactory({
package/dist/node/cli.js CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{createLogger as S,defineConfig as b,searchForWorkspaceRoot as W,mergeConfig as F,createServer as O,preview as U,build as L}from"vite";import{readFileSync as y,existsSync as u}from"fs";import t from"path";import{Command as N}from"commander";import{fileURLToPath as A}from"url";import{readFile as E,writeFile as I,rm as T,cp as $}from"fs/promises";import H from"@vitejs/plugin-vue";import M,{transformAssetUrls as J}from"vite-plugin-vuetify";const h=new N("eodash"),c=w(),s=w(process.cwd());JSON.parse(y(t.join(s,"package.json"),"utf-8"));const j=JSON.parse(y(t.join(c,"package.json"),"utf-8"))??{},R=["commander","vite","@vitejs/plugin-vue","vite-plugin-vuetify","axios"],V=Object.keys(j?.dependencies).filter(e=>!R.includes(e));h.version(j.version,"-v, --version","output the current version"),h.option("--publicDir <path>","path to statically served assets folder").option("--no-publicDir","stop serving static assets").option("--outDir <path>","minified output folder").option("-e, --entryPoint <path>","file exporting `createEodash`").option("-w, --widgets <path>","folder that contains vue components as internal widgets").option("--cacheDir <path>","cache folder").option("-r, --runtime <path>","file exporting eodash client runtime config").option("-b, --base <path>","base public path").option("-p, --port <port>","serving port").option("-o, --open","open default browser when the server starts").option("-c, --config <path>","path to eodash server and build configuration file").option("--host [IP address]","specify which IP addresses the server should listen on").option("-l, --lib","builds eodash as a web component library").option("--no-lib","builds eodash as an SPA").option("--no-host","do not expose server to the network").parse(process.argv);const i=await B(h.opts(),process.argv?.[2]),z=i.publicDir?t.resolve(s,i.publicDir):t.join(s,"./public"),m=t.join(s,"/src"),p=i.runtime?t.resolve(s,i.runtime):t.join(m,"./runtime.js"),f=i.entryPoint?t.resolve(s,i.entryPoint):t.join(m,"/main.js"),x=i.widgets?t.resolve(s,i.widgets):t.join(m,"widgets"),D=t.join(s,"/.eodash"),v=i.outDir?t.resolve(s,i.outDir):t.join(D,"/dist"),Y=i.cacheDir?t.resolve(s,i.cacheDir):t.join(D,"cache"),g=S(void 0,{prefix:"[eodash]"});async function B(e,a){let r=e.config?t.resolve(s,e.config):t.join(s,"eodash.config.js"),o={};return u(r)?o=await import(r).then(n=>n.default instanceof Function?n.default():n.default).catch(n=>{console.error(n)}):r=null,{base:e.base??o?.base,port:Number(e.port??o?.[a]?.port),host:e.host??o?.[a]?.host,open:e.open??o?.[a]?.open,cacheDir:e.cacheDir??o?.cacheDir,entryPoint:e.entryPoint??o?.entryPoint,outDir:e.outDir??o?.outDir,publicDir:e.publicDir??o?.publicDir,runtime:e.runtime??o?.runtime,widgets:e.widgets??o?.widgets,lib:e.lib??o?.lib,vite:o.vite}}function w(e=import.meta.dirname??t.dirname(A(import.meta.url))){if(e?.split("/").length)return u(t.resolve(e,"package.json"))?e:w(t.resolve(e,".."));throw new Error("no package root found from "+e)}const P=`
2
+ import{createLogger as S,defineConfig as b,searchForWorkspaceRoot as W,mergeConfig as F,preview as O,createServer as U,build as L}from"vite";import{readFileSync as y,existsSync as u}from"fs";import t from"path";import{Command as N}from"commander";import{fileURLToPath as A}from"url";import{readFile as E,writeFile as I,rm as T,cp as $}from"fs/promises";import H from"@vitejs/plugin-vue";import M,{transformAssetUrls as J}from"vite-plugin-vuetify";const h=new N("eodash"),c=w(),s=w(process.cwd());JSON.parse(y(t.join(s,"package.json"),"utf-8"));const j=JSON.parse(y(t.join(c,"package.json"),"utf-8"))??{},R=["commander","vite","@vitejs/plugin-vue","vite-plugin-vuetify","axios"],V=Object.keys(j?.dependencies).filter(e=>!R.includes(e));h.version(j.version,"-v, --version","output the current version"),h.option("--publicDir <path>","path to statically served assets folder").option("--no-publicDir","stop serving static assets").option("--outDir <path>","minified output folder").option("-e, --entryPoint <path>","file exporting `createEodash`").option("-w, --widgets <path>","folder that contains vue components as internal widgets").option("--cacheDir <path>","cache folder").option("-r, --runtime <path>","file exporting eodash client runtime config").option("-b, --base <path>","base public path").option("-p, --port <port>","serving port").option("-o, --open","open default browser when the server starts").option("-c, --config <path>","path to eodash server and build configuration file").option("--host [IP address]","specify which IP addresses the server should listen on").option("-l, --lib","builds eodash as a web component library").option("--no-lib","builds eodash as an SPA").option("--no-host","do not expose server to the network").parse(process.argv);const i=await B(h.opts(),process.argv?.[2]),z=i.publicDir?t.resolve(s,i.publicDir):t.join(s,"./public"),m=t.join(s,"/src"),p=i.runtime?t.resolve(s,i.runtime):t.join(m,"./runtime.js"),f=i.entryPoint?t.resolve(s,i.entryPoint):t.join(m,"/main.js"),x=i.widgets?t.resolve(s,i.widgets):t.join(m,"widgets"),D=t.join(s,"/.eodash"),v=i.outDir?t.resolve(s,i.outDir):t.join(D,"/dist"),Y=i.cacheDir?t.resolve(s,i.cacheDir):t.join(D,"cache"),g=S(void 0,{prefix:"[eodash]"});async function B(e,a){let r=e.config?t.resolve(s,e.config):t.join(s,"eodash.config.js"),o={};return u(r)?o=await import(r).then(n=>n.default instanceof Function?n.default():n.default).catch(n=>{console.error(n)}):r=null,{base:e.base??o?.base,port:Number(e.port??o?.[a]?.port),host:e.host??o?.[a]?.host,open:e.open??o?.[a]?.open,cacheDir:e.cacheDir??o?.cacheDir,entryPoint:e.entryPoint??o?.entryPoint,outDir:e.outDir??o?.outDir,publicDir:e.publicDir??o?.publicDir,runtime:e.runtime??o?.runtime,widgets:e.widgets??o?.widgets,lib:e.lib??o?.lib,vite:o.vite}}function w(e=import.meta.dirname??t.dirname(A(import.meta.url))){if(e?.split("/").length)return u(t.resolve(e,"package.json"))?e:w(t.resolve(e,".."));throw new Error("no package root found from "+e)}const P=`
3
3
  <!DOCTYPE html>
4
4
  <html lang="en" style="overflow: hidden">
5
5
 
@@ -17,4 +17,4 @@ ${i.lib?`<eo-dash style="height:100dvh;"/>
17
17
  <script type="module" src="${t.resolve(`/@fs/${c}`,"core/client/render.js")}"><\/script>
18
18
  `}
19
19
  </body>
20
- </html>`,C=b(async({mode:e,command:a})=>({base:i.base??"",cacheDir:Y,plugins:[H({template:{transformAssetUrls:J,compilerOptions:{isCustomElement:r=>!r.includes("v-")&&r.includes("-")}}}),M({autoImport:!0}),e==="development"&&{name:"inject-html",configureServer:G}],customLogger:g,define:{"process.env":{}},resolve:{alias:{"@":t.join(c,"core/client"),"^":t.join(c,"widgets"),"user:config":f,"user:widgets":x},extensions:[".js",".json",".jsx",".mjs",".ts",".tsx",".vue"]},server:{allowedHosts:!0,warmup:{clientFiles:[t.join(c,"core/client/**"),f]},port:i.port??3e3,open:i.open,fs:{allow:[W(process.cwd())]},host:i.host},root:c,...e==="development"&&{optimizeDeps:{include:["webfontloader","vuetify","vue","pinia","stac-js","urijs","loglevel","vega","vega-lite","vega-embed","@eox/map","@eox/map/src/plugins/advancedLayersAndSources","@eox/layercontrol","@eox/drawtools","@eox/chart","@eox/jsonform","@eox/layout","@eox/itemfilter","@eox/timecontrol","@eox/stacinfo","color-legend-element","@eox/map","@eox/map/src/plugins/advancedLayersAndSources","@eox/layercontrol","@eox/timecontrol","@eox/jsonform","@eox/layout","@eox/itemfilter","@eox/stacinfo"],noDiscovery:!0}},publicDir:i.publicDir===!1?!1:z,build:{outDir:v,emptyOutDir:!0,target:"esnext",cssMinify:!0,...i.lib&&a==="build"&&{minify:!1,lib:{entry:t.join(c,"core/client/asWebComponent.js"),fileName:"eo-dash",formats:["es"],name:"@eodash/eodash"},rollupOptions:{input:t.join(c,"core/client/asWebComponent.js"),external:r=>{const o=r.includes("vuetify")||r.endsWith(".css")||r.endsWith("styles"),n=V.some(l=>r.startsWith(l));return!o&&n}}}}})),k=b(async e=>i.vite?F(await C(e),i.vite):C(e));async function G(e){e.watcher.add([f,p,t.join(x,"**/*.vue")]);let a="";const r=g.info;return g.info=(o,n)=>{if(o.includes("core")){const l=o.split("/")[0].split(" ");l.pop();const d=l.join(" ")+" "+a.replace(s,"");return r(d,n)}return r(o,n)},e.watcher.on("change",async o=>{a=o,o===p&&e.ws.send({type:"full-reload",path:o})}),()=>{e.middlewares.use(async(o,n,l)=>{if(o.originalUrl==="/@fs/config.js"||o.originalUrl==="/config.js"){n.statusCode=200,n.setHeader("Content-Type","text/javascript"),u(p)&&await E(p).then(d=>{n.write(d)}),n.end();return}if(o.url?.endsWith(".html")){n.statusCode=200,n.setHeader("Content-Type","text/html");const d=await e.transformIndexHtml(o.url,P,o.originalUrl);n.end(d);return}l()})}}const K=async()=>{const e=await O(await k({mode:"development",command:"serve"}));await e.listen(),e.printUrls(),e.bindCLIShortcuts({print:!0})},Q=async()=>{const e=async()=>{const a=await k({mode:"production",command:"build"});await L(a),u(p)&&await $(p,t.join(v,"config.js"),{recursive:!0}).catch(r=>{console.error(r)})};if(i.lib)await e();else{const a=t.join(c,"/index.html");await I(a,P).then(async()=>{await e(),await T(a).catch(()=>{console.error("failed to remove index.html")})})}};async function X(){(await U({root:s,base:i.base??"",preview:{port:isNaN(i.port)?8080:i.port,open:i.open,host:i.host},build:{outDir:v}})).printUrls()}const Z=process.argv?.[2];(async()=>{switch(Z){case"dev":await K();break;case"build":await Q();break;case"preview":await X();break;default:console.error("command not found");break}})();
20
+ </html>`,C=b(async({mode:e,command:a})=>({base:i.base??"",cacheDir:Y,plugins:[H({template:{transformAssetUrls:J,compilerOptions:{isCustomElement:r=>!r.includes("v-")&&r.includes("-")}}}),M({autoImport:!0}),e==="development"&&{name:"inject-html",configureServer:G}],customLogger:g,define:{"process.env":{}},resolve:{alias:{"@":t.join(c,"core/client"),"^":t.join(c,"widgets"),"user:config":f,"user:widgets":x},extensions:[".js",".json",".jsx",".mjs",".ts",".tsx",".vue"]},server:{allowedHosts:!0,warmup:{clientFiles:[t.join(c,"core/client/**"),f]},port:i.port??3e3,open:i.open,fs:{allow:[W(process.cwd())]},host:i.host},root:c,...e==="development"&&{optimizeDeps:{include:["webfontloader","vuetify","vue","pinia","stac-js","urijs","loglevel","vega","vega-lite","vega-embed","@eox/map","@eox/map/src/plugins/advancedLayersAndSources","@eox/layercontrol","@eox/drawtools","@eox/chart","@eox/jsonform","@eox/layout","@eox/itemfilter","@eox/timecontrol","@eox/stacinfo","color-legend-element","@eox/map","@eox/map/src/plugins/advancedLayersAndSources","@eox/layercontrol","@eox/timecontrol","@eox/jsonform","@eox/layout","@eox/itemfilter","@eox/stacinfo"],noDiscovery:!0}},publicDir:i.publicDir===!1?!1:z,build:{outDir:v,emptyOutDir:!0,target:"esnext",cssMinify:!0,...i.lib&&a==="build"&&{minify:!1,lib:{entry:t.join(c,"core/client/asWebComponent.js"),fileName:"eo-dash",formats:["es"],name:"@eodash/eodash"},rollupOptions:{input:t.join(c,"core/client/asWebComponent.js"),external:r=>{const o=r.includes("vuetify")||r.endsWith(".css")||r.endsWith("styles"),n=V.some(l=>r.startsWith(l));return!o&&n}}}}})),k=b(async e=>i.vite?F(await C(e),i.vite):C(e));async function G(e){e.watcher.add([f,p,t.join(x,"**/*.vue")]);let a="";const r=g.info;return g.info=(o,n)=>{if(o.includes("core")){const l=o.split("/")[0].split(" ");l.pop();const d=l.join(" ")+" "+a.replace(s,"");return r(d,n)}return r(o,n)},e.watcher.on("change",async o=>{a=o,o===p&&e.ws.send({type:"full-reload",path:o})}),()=>{e.middlewares.use(async(o,n,l)=>{if(o.originalUrl==="/@fs/config.js"||o.originalUrl==="/config.js"){n.statusCode=200,n.setHeader("Content-Type","text/javascript"),u(p)&&await E(p).then(d=>{n.write(d)}),n.end();return}if(o.url?.endsWith(".html")){n.statusCode=200,n.setHeader("Content-Type","text/html");const d=await e.transformIndexHtml(o.url,P,o.originalUrl);n.end(d);return}l()})}}const K=async()=>{const e=await U(await k({mode:"development",command:"serve"}));await e.listen(),e.printUrls(),e.bindCLIShortcuts({print:!0})},Q=async()=>{const e=async()=>{const a=await k({mode:"production",command:"build"});await L(a),u(p)&&await $(p,t.join(v,"config.js"),{recursive:!0}).catch(r=>{console.error(r)})};if(i.lib)await e();else{const a=t.join(c,"/index.html");await I(a,P).then(async()=>{await e(),await T(a).catch(()=>{console.error("failed to remove index.html")})})}};async function X(){(await O({root:s,base:i.base??"",preview:{port:isNaN(i.port)?8080:i.port,open:i.open,host:i.host},build:{outDir:v}})).printUrls()}const Z=process.argv?.[2];(async()=>{switch(Z){case"dev":await K();break;case"build":await Q();break;case"preview":await X();break;default:console.error("command not found");break}})();
@@ -0,0 +1,2 @@
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
2
+ export default _default;