@feltmaps/js-sdk 1.7.0-next.3 → 1.7.0-next.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.
- package/dist/client.cjs +1 -1
- package/dist/client.d.cts +2 -2
- package/dist/client.d.ts +2 -2
- package/dist/client.js +1 -1
- package/dist/{controller-biHGMBte.d.cts → controller-BX0NMWZH.d.cts} +110 -104
- package/dist/{controller-biHGMBte.d.ts → controller-BX0NMWZH.d.ts} +110 -104
- package/dist/handler.cjs +1 -1
- package/dist/handler.d.cts +50 -50
- package/dist/handler.d.ts +50 -50
- package/dist/handler.js +1 -1
- package/package.json +1 -1
package/dist/handler.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var Ge=Object.defineProperty;var Qt=Object.getOwnPropertyDescriptor;var $t=Object.getOwnPropertyNames;var Kt=Object.prototype.hasOwnProperty;var Xt=(a,d)=>{for(var N in d)Ge(a,N,{get:d[N],enumerable:!0})},Yt=(a,d,N,H)=>{if(d&&typeof d=="object"||typeof d=="function")for(let O of $t(d))!Kt.call(a,O)&&O!==N&&Ge(a,O,{get:()=>d[O],enumerable:!(H=Qt(d,O))||H.enumerable});return a};var eo=a=>Yt(Ge({},"__esModule",{value:!0}),a);var fr={};Xt(fr,{createMessageHandler:()=>mr});module.exports=eo(fr);var u=require("zod");var I=require("zod");var z=require("zod");function t(a,d){return z.z.strictObject({type:z.z.literal(a),params:d})}function E(a,d){return z.z.strictObject({eventName:z.z.literal(a),id:z.z.string(),options:d})}function y(a){return z.z.strictObject({eventName:z.z.literal(a),id:z.z.string()})}var p=require("zod"),ce=p.z.number(),ue=p.z.number(),de=p.z.object({latitude:ue,longitude:ce}),A=p.z.tuple([ce,ue]),X=p.z.object({type:p.z.literal("Polygon"),coordinates:p.z.array(p.z.array(A).min(4).refine(a=>a[0][0]===a[a.length-1][0]&&a[0][1]===a[a.length-1][1],"The last point of each ring must be identical to the first"))}),ye=p.z.object({type:p.z.literal("MultiPolygon"),coordinates:p.z.array(X.shape.coordinates)}),to=p.z.object({type:p.z.literal("LineString"),coordinates:p.z.array(A).min(2)}),Y=p.z.object({type:p.z.literal("MultiLineString"),coordinates:p.z.array(to.shape.coordinates)}),Qe=p.z.number().min(1).max(23),F=p.z.tuple([ce,ue,ce,ue]),q=p.z.object({show:p.z.array(p.z.string()).optional(),hide:p.z.array(p.z.string()).optional()}),oo=p.z.enum(["asc","desc"]),ge=p.z.object({attribute:p.z.string(),direction:oo});var e=require("zod");var C=e.z.object({id:e.z.string(),groupId:e.z.string().nullable(),color:e.z.string(),name:e.z.string().nullable(),description:e.z.string().nullable(),attributes:e.z.record(e.z.string(),e.z.unknown()),interaction:e.z.enum(["default","locked"]).optional()}),Se=e.z.object({imageUrl:e.z.string().nullable()}),ze=e.z.object({strokeOpacity:e.z.number(),strokeWidth:e.z.number(),strokeStyle:e.z.enum(["solid","dashed","dotted"])}),no=e.z.enum(["meter","kilometer","foot","mile"]),he=C.extend(Se.shape).extend({type:e.z.literal("Place"),coordinates:A,symbol:e.z.string(),frame:e.z.enum(["frame-circle","frame-square"]).nullable(),hideLabel:e.z.boolean()}),ee=C.extend(Se.shape).extend(ze.shape).extend({type:e.z.literal("Path"),coordinates:Y.shape.coordinates,distanceMarker:e.z.boolean(),routingMode:e.z.enum(["driving","cycling","walking","flying"]).nullable(),endCaps:e.z.boolean()}),te=C.extend(Se.shape).extend(ze.shape).extend({type:e.z.literal("Polygon"),coordinates:X.shape.coordinates,fillOpacity:e.z.number().min(0).max(1),areaMarker:e.z.boolean()}),fe=C.extend(Se.shape).extend(ze.shape).extend({type:e.z.literal("Circle"),center:A,radius:e.z.number(),radiusMarker:e.z.boolean(),radiusDisplayAngle:e.z.number(),radiusDisplayUnit:no.nullable(),fillOpacity:e.z.number().min(0).max(1)}),oe=C.extend({type:e.z.literal("Marker"),coordinates:Y.shape.coordinates,opacity:e.z.number().min(0).max(1),size:e.z.number().min(0).max(100),zoom:e.z.number().min(0).max(23)}),ne=C.extend({type:e.z.literal("Highlighter"),coordinates:ye.shape.coordinates,renderHoles:e.z.boolean(),opacity:e.z.number().min(0).max(1)}),$e=e.z.object({position:A,rotation:e.z.number(),scale:e.z.number(),zoom:e.z.number().min(0).max(23),text:e.z.string(),align:e.z.enum(["left","center","right"]),style:e.z.enum(["italic","light","regular","caps"]),name:e.z.string()}),Pe=C.extend($e.shape).extend({type:e.z.literal("Text")}),Te=C.extend($e.shape).extend({type:e.z.literal("Note"),widthScale:e.z.number().min(0)}),re=C.extend({type:e.z.literal("Image"),coordinates:Y.shape.coordinates,imageUrl:e.z.string(),opacity:e.z.number().min(0).max(1)}).omit({color:!0}),ro=C.extend({type:e.z.literal("Link"),coordinates:Y.shape.coordinates,url:e.z.string()}),J={type:!0,coordinates:!0},U={id:!0},Fe=he.partial().extend(he.pick(J).shape).omit(U),xe=ee.partial().extend(ee.pick(J).shape).omit(U),Ue=te.partial().extend(te.pick(J).shape).omit(U),ke=fe.partial().extend(fe.pick({type:!0,center:!0,radius:!0}).shape).omit(U),ve=oe.partial().extend(oe.pick(J).shape).omit(U),je=ne.partial().extend(ne.pick(J).shape).omit(U),Ve=Pe.partial().omit({...U,name:!0,type:!0}).extend({type:e.z.literal("Text"),text:e.z.string()}),Be=Te.partial().omit({...U,name:!0,type:!0}).extend({type:e.z.literal("Note"),text:e.z.string()}),ao=re.partial().extend(re.pick({...J,imageUrl:!0}).shape).omit(U),Ke=e.z.discriminatedUnion("type",[Fe,xe,Ue,ke,ve,je,ao,Ve,Be]);var Mr=ee.omit({coordinates:!0}),Er=te.omit({coordinates:!0});var Cr=oe.omit({coordinates:!0}),Gr=ne.omit({coordinates:!0});var Pr=re.omit({coordinates:!0}),Tr=ro.omit({coordinates:!0}),k={type:!0,id:!0},io=he.partial().extend(he.pick(k).shape),so=ee.partial().extend(ee.pick(k).shape),lo=te.partial().extend(te.pick(k).shape),po=fe.partial().extend(fe.pick(k).shape),mo=oe.partial().extend(oe.pick(k).shape),co=ne.partial().extend(ne.pick(k).shape),uo=Pe.partial().extend(Pe.pick(k).shape).omit({name:!0}),yo=Te.partial().extend(Te.pick(k).shape).omit({name:!0}),go=re.partial().extend(re.pick(k).shape),Xe=e.z.discriminatedUnion("type",[io,so,lo,po,mo,co,uo,yo,go]),Ye=e.z.object({ids:e.z.array(e.z.string()).optional()}),et=e.z.object({ids:e.z.array(e.z.string()).optional()});var ho=t("getElement",I.z.string()),fo=t("getElementGeometry",I.z.string()),So=t("getElements",Ye.optional()),xo=t("getElementGroup",I.z.string()),bo=t("getElementGroups",et.optional()),Io=t("setElementGroupVisibility",q),Lo=E("onElementChange",I.z.object({id:I.z.string()})),Mo=y("onElementCreate"),Eo=y("onElementCreateEnd"),Co=E("onElementDelete",I.z.object({id:I.z.string()})),Go=E("onElementGroupChange",I.z.object({id:I.z.string()})),Po=t("createElement",Ke),To=t("updateElement",Xe),zo=t("deleteElement",I.z.string()),tt={methods:[ho,fo,So,xo,bo,Io,Po,To,zo],listeners:[Lo,Mo,Eo,Co,Go]};var Fo=y("onPointerClick"),Uo=y("onPointerMove"),ot={methods:null,listeners:[Fo,Uo]};var i=require("zod");var s=require("zod");var ko=s.z.enum(["in","ni"]),vo=s.z.enum(["lt","gt","le","ge","eq","ne","cn","nc","is","isnt"]),wr=s.z.enum(["and","or"]),nt=s.z.union([s.z.number(),s.z.string(),s.z.boolean(),s.z.null()]),rt=s.z.string().or(s.z.null()),jo=s.z.tuple([rt,ko,s.z.array(nt).or(s.z.null())]),Vo=s.z.tuple([rt,vo,nt]),we=s.z.union([jo,Vo]),Oe=s.z.tuple([s.z.lazy(()=>s.z.union([Oe,we,s.z.null(),s.z.boolean()])),s.z.enum(["and","or"]),s.z.lazy(()=>s.z.union([Oe,we,s.z.null(),s.z.boolean()]))]),v=s.z.union([Oe,we,s.z.null(),s.z.boolean()]),j=s.z.union([F,X,ye,s.z.array(A)]);var n=require("zod");var at=n.z.enum(["avg","max","min","sum","median"]),it=n.z.enum(["avg","max","min","sum","count"]),Bo=n.z.object({method:at,attribute:n.z.string()}),wo=n.z.object({methods:n.z.array(n.z.union([at,n.z.literal("count")])),attribute:n.z.string().optional()}),st=n.z.object({boundary:j.optional(),filters:v.optional(),aggregation:Bo.optional()}),lt=n.z.object({layerId:n.z.string(),attribute:n.z.string(),limit:n.z.number().optional(),boundary:j.optional(),filters:v.optional(),values:st.optional()}),Rr=n.z.object({key:n.z.union([n.z.number(),n.z.string(),n.z.boolean()]),value:n.z.number().nullable()}),Oo=n.z.object({type:n.z.literal("equal-intervals"),count:n.z.number()}),Ao=n.z.object({type:n.z.literal("time-interval"),interval:n.z.enum(["hour","day","week","month","year"])}),pt=n.z.object({layerId:n.z.string(),attribute:n.z.string(),steps:n.z.union([Oo,Ao,n.z.array(n.z.number())]),boundary:j.optional(),filters:v.optional(),values:st.optional()}),Dr=n.z.object({min:n.z.number(),max:n.z.number(),value:n.z.number()}),mt=n.z.object({layerId:n.z.string(),boundary:j.optional(),filters:v.optional(),aggregation:wo}),ct=n.z.enum(["h3"]),Ro=n.z.object({type:ct,resolution:n.z.number(),method:it.extract(["count"])}),Do=n.z.object({type:ct,resolution:n.z.number(),method:it.exclude(["count"]),attribute:n.z.string()}),No=n.z.union([Ro,Do]),ut=n.z.object({layerId:n.z.string(),boundary:j.optional(),filters:v.optional(),gridConfig:No});var r=require("zod");var Hr=r.z.enum(["processing","completed","failed","incomplete"]),dt=r.z.object({type:r.z.literal("geoJsonUrl"),url:r.z.string().url(),refreshInterval:r.z.number().min(250).max(5*60*1e3).nullable().optional()}),yt=r.z.object({type:r.z.literal("geoJsonData"),data:r.z.object({}).passthrough().or(r.z.instanceof(ArrayBuffer))}),gt=r.z.object({type:r.z.literal("geoJsonFile"),file:r.z.instanceof(File)}),ht=r.z.object({id:r.z.string(),style:r.z.object({}).passthrough().optional(),shownInLegend:r.z.boolean().optional(),name:r.z.string().optional(),caption:r.z.string().optional(),description:r.z.string().optional(),bounds:F.optional(),source:r.z.union([dt,yt,gt]).optional()}),ft=r.z.object({ids:r.z.array(r.z.string()).optional()}),St=r.z.object({ids:r.z.array(r.z.string()).optional()}),Z=r.z.object({id:r.z.string(),layerId:r.z.string()}),xt=r.z.object({ids:Z.array().optional(),layerIds:r.z.string().array().optional()}),bt=r.z.object({layerIds:r.z.array(r.z.string()).optional(),areaQuery:r.z.union([r.z.object({coordinates:de}),r.z.object({boundary:F})]).optional()}),qo=r.z.object({Point:r.z.object({}).passthrough().optional(),Line:r.z.object({}).passthrough().optional(),Polygon:r.z.object({}).passthrough().optional()}),It=r.z.object({source:r.z.union([dt,yt,gt]),name:r.z.string(),bounds:F.optional(),caption:r.z.string().optional(),description:r.z.string().optional(),geometryStyles:qo.optional()});var Ho=t("getLayer",i.z.string()),Jo=t("getLayers",ft.optional()),Zo=t("setLayerVisibility",q),Wo=E("onLayerChange",i.z.object({id:i.z.string()})),_o=t("setLayerStyle",i.z.object({id:i.z.string(),style:i.z.object({}).passthrough()})),Qo=t("setLayerLegendVisibility",q),$o=t("createLayersFromGeoJson",It),Ko=t("updateLayer",ht),Xo=t("deleteLayer",i.z.string()),Yo=t("getLayerGroup",i.z.string()),en=t("getLayerGroups",St.optional()),tn=t("setLayerGroupVisibility",q),on=t("setLayerGroupLegendVisibility",q),nn=E("onLayerGroupChange",i.z.object({id:i.z.string()})),rn=t("getLegendItem",Z),an=t("getLegendItems",xt.optional()),sn=E("onLegendItemChange",Z),ln=t("setLegendItemVisibility",i.z.object({show:Z.array().optional(),hide:Z.array().optional()})),pn=t("getLayerFilters",i.z.string()),mn=t("setLayerFilters",i.z.object({layerId:i.z.string(),filters:v,note:i.z.string().optional()})),cn=E("onLayerFiltersChange",i.z.object({layerId:i.z.string()})),un=t("getLayerBoundaries",i.z.string()),dn=t("setLayerBoundary",i.z.object({layerIds:i.z.array(i.z.string()),boundary:j.nullable()})),yn=E("onLayerBoundariesChange",i.z.object({layerId:i.z.string()})),gn=t("getRenderedFeatures",bt.optional()),hn=t("getFeature",i.z.object({id:i.z.string().or(i.z.number()),layerId:i.z.string()})),fn=t("getFeatures",i.z.object({layerId:i.z.string(),filters:v.optional(),sorting:ge.optional(),boundary:j.optional(),search:i.z.string().optional(),pagination:i.z.string().optional().nullish()})),Sn=t("getGeoJsonFeature",i.z.object({id:i.z.string().or(i.z.number()),layerId:i.z.string()})),xn=t("getCategoryData",lt),bn=t("getHistogramData",pt),In=t("getAggregates",mt),Ln=t("getPrecomputedAggregates",ut),Mn=t("getLayerSchema",i.z.string()),Lt={methods:[Ho,Jo,Zo,_o,Qo,$o,Xo,Ko,Yo,en,tn,on,rn,an,ln,pn,mn,un,dn,gn,hn,fn,Sn,xn,bn,In,Ln,Mn],listeners:[Wo,nn,sn,cn,yn]};var Mt=require("zod");var En=t("getMapDetails",Mt.z.undefined()),Et={methods:[En],listeners:[]};var ae=require("zod");var V=require("zod"),Ct=V.z.object({id:V.z.string().or(V.z.number()),layerId:V.z.string(),showPopup:V.z.boolean().optional(),fitViewport:V.z.boolean().or(V.z.object({maxZoom:V.z.number()})).optional()});var Cn=t("getSelection",ae.z.undefined()),Gn=y("onSelectionChange"),Pn=t("selectFeature",Ct),Tn=t("clearSelection",ae.z.object({features:ae.z.boolean().optional(),elements:ae.z.boolean().optional()}).optional()),Gt={methods:[Cn,Pn,Tn],listeners:[Gn]};var Ut=require("zod");var g=require("zod");var Pt=["circle","highlighter","line","marker","note","pin","polygon","route","text"],zn=[...Pt,"link"],Tt=g.z.enum(zn),zt=g.z.enum(Pt),Fn=Fe.pick({color:!0,symbol:!0,frame:!0}).extend({afterCreation:g.z.enum(["enter name","add another","select"])}).required(),Un=xe.pick({color:!0,strokeOpacity:!0,strokeWidth:!0,strokeStyle:!0,distanceMarker:!0}).required(),kn=xe.pick({color:!0,routingMode:!0,strokeOpacity:!0,strokeWidth:!0,strokeStyle:!0,distanceMarker:!0,endCaps:!0}).required(),vn=Ue.pick({color:!0,fillOpacity:!0,strokeOpacity:!0,strokeWidth:!0,strokeStyle:!0,areaMarker:!0}).required(),jn=ke.pick({color:!0,fillOpacity:!0,strokeOpacity:!0,strokeWidth:!0,strokeStyle:!0,radiusMarker:!0}).required(),Vn=ve.pick({color:!0,opacity:!0,size:!0}).required(),Bn=je.pick({color:!0,opacity:!0,renderHoles:!0}).extend({size:g.z.number().min(0).max(200)}).required(),wn=Ve.pick({color:!0,align:!0,style:!0}).required(),On=Be.pick({color:!0,align:!0,style:!0}).required(),Ft=g.z.discriminatedUnion("tool",[Fn.partial().extend({tool:g.z.literal("pin")}),Un.partial().extend({tool:g.z.literal("line")}),kn.partial().extend({tool:g.z.literal("route")}),vn.partial().extend({tool:g.z.literal("polygon")}),jn.partial().extend({tool:g.z.literal("circle")}),Vn.partial().extend({tool:g.z.literal("marker")}),Bn.partial().extend({tool:g.z.literal("highlighter")}),wn.partial().extend({tool:g.z.literal("text")}),On.partial().extend({tool:g.z.literal("note")})]);var An=t("setTool",Tt.nullable()),Rn=t("getTool",Ut.z.undefined()),Dn=y("onToolChange"),Nn=t("setToolSettings",Ft),qn=t("getToolSettings",zt),Hn=y("onToolSettingsChange"),kt={methods:[An,Rn,Nn,qn],listeners:[Dn,Hn]};var le=require("zod");var o=require("zod");var R=require("zod"),ie=R.z.union([R.z.object({after:R.z.string()}),R.z.object({before:R.z.string()}),R.z.object({at:R.z.enum(["start","end"])})]);var be=require("zod");var h=require("zod"),vt=h.z.object({onCreate:h.z.function().args().returns(h.z.void()).optional(),onDestroy:h.z.function().args().returns(h.z.void()).optional()}),Jn=h.z.object({onCreate:h.z.string().optional(),onDestroy:h.z.string().optional()}),S=vt.extend({id:h.z.string()}),x=vt.extend({id:h.z.string().optional()}),b=Jn.extend({id:h.z.string().optional()}),Ae=h.z.object({label:h.z.string().optional()}),D={public:S.extend(Ae.shape),input:x.extend(Ae.shape),clonable:b.extend(Ae.shape)};var B={public:S.extend({type:be.z.literal("FlexibleSpace")}),input:x.extend({type:be.z.literal("FlexibleSpace")}),clonable:b.extend({type:be.z.literal("FlexibleSpace")})};var m=require("zod");var L=require("zod");var Re=L.z.object({type:L.z.literal("Button"),label:L.z.string(),variant:L.z.enum(["primary","outlined","transparent","transparentThin"]).optional(),disabled:L.z.boolean().optional()}),G={public:S.extend(Re.shape).extend({onClick:L.z.function().returns(L.z.void())}),input:x.extend(Re.shape).extend({onClick:L.z.function().returns(L.z.void())}),clonable:b.extend(Re.shape).extend({onClick:L.z.string()})};var T=require("zod");var Ie=require("zod");var De=Ie.z.object({type:Ie.z.literal("Text"),content:Ie.z.string()}),P={public:S.extend(De.shape),input:x.extend(De.shape),clonable:b.extend(De.shape)};var Ne=T.z.object({type:T.z.literal("ButtonGroup"),align:T.z.enum(["start","end"]).optional()}),W={public:S.extend(Ne.shape).extend({items:T.z.array(T.z.union([G.public,P.public,B.public]))}),input:x.extend(Ne.shape).extend({items:T.z.array(T.z.union([G.input,P.input,B.input]))}),clonable:b.extend(Ne.shape).extend({items:T.z.array(T.z.union([G.clonable,P.clonable,B.clonable]))})};var Le=require("zod");var _={public:S.extend({type:Le.z.literal("Divider")}),input:x.extend({type:Le.z.literal("Divider")}),clonable:b.extend({type:Le.z.literal("Divider")})};var c=require("zod");var qe=c.z.object({type:c.z.literal("Select"),options:c.z.array(c.z.object({label:c.z.string(),value:c.z.string()})),value:c.z.string().optional(),search:c.z.boolean().optional(),placeholder:c.z.string().optional()}),Q={public:D.public.extend(qe.shape).extend({onChange:c.z.function().args(c.z.object({value:c.z.string()})).returns(c.z.void())}),input:D.input.extend(qe.shape).extend({onChange:c.z.function().args(c.z.object({value:c.z.string()})).returns(c.z.void())}),clonable:D.clonable.extend(qe.shape).extend({onChange:c.z.string()})};var l=require("zod");var He=l.z.object({type:l.z.literal("TextInput"),value:l.z.string(),placeholder:l.z.string().optional()}),$={public:D.public.extend(He.shape).extend({onChange:l.z.function().args(l.z.string()).returns(l.z.void()).optional(),onBlur:l.z.function().args(l.z.string()).returns(l.z.void()).optional(),onFocus:l.z.function().args(l.z.string()).returns(l.z.void()).optional()}),input:D.input.extend(He.shape).extend({onChange:l.z.function().args(l.z.object({value:l.z.string()})).returns(l.z.void()).optional(),onBlur:l.z.function().args(l.z.object({value:l.z.string()})).returns(l.z.void()).optional(),onFocus:l.z.function().args(l.z.object({value:l.z.string()})).returns(l.z.void()).optional()}),clonable:D.clonable.extend(He.shape).extend({onChange:l.z.string().optional(),onBlur:l.z.string().optional(),onFocus:l.z.string().optional()})};var w={public:m.z.discriminatedUnion("type",[P.public,G.public,$.public,_.public,W.public,Q.public]),input:m.z.discriminatedUnion("type",[P.input,G.input,$.input,_.input,W.input,Q.input]),clonable:m.z.discriminatedUnion("type",[P.clonable,G.clonable,$.clonable,_.clonable,W.clonable,Q.clonable])},Je=m.z.object({type:m.z.literal("Panel"),title:m.z.string().optional()}),se={public:S.extend(Je.shape).extend({onClose:m.z.function().returns(m.z.void()).optional(),items:m.z.array(w.public),footer:m.z.array(w.public).optional()}),input:x.extend(Je.partial().shape).extend({onClose:m.z.function().returns(m.z.void()).optional(),items:m.z.array(w.input),footer:m.z.array(w.input).optional()}),clonable:b.extend(Je.partial().shape).extend({onClose:m.z.string().optional(),items:m.z.array(w.clonable),footer:m.z.array(w.clonable).optional()})},Ze={input:m.z.discriminatedUnion("type",[P.input.partial().required({type:!0}),G.input.partial().required({type:!0}),$.input.partial().required({type:!0}),_.input.partial().required({type:!0}),W.input.partial().required({type:!0}),Q.input.partial().required({type:!0})]),clonable:m.z.discriminatedUnion("type",[P.clonable.partial().required({type:!0}),G.clonable.partial().required({type:!0}),$.clonable.partial().required({type:!0}),_.clonable.partial().required({type:!0}),W.clonable.partial().required({type:!0}),Q.clonable.partial().required({type:!0})])};var Aa=o.z.object({panel:se.input,placement:ie.optional()}),jt=o.z.object({panel:se.clonable,placement:ie.optional()}),Ra=se.input.partial().required({id:!0}),Vt=se.clonable.partial().required({id:!0}),Da=o.z.object({panelId:o.z.string(),elements:o.z.array(o.z.object({element:o.z.union([w.input,B.input]),on:o.z.union([o.z.literal("items"),o.z.literal("footer"),o.z.object({id:o.z.string()})]).optional(),placement:ie.optional()}))}),Bt=o.z.object({panelId:o.z.string(),elements:o.z.array(o.z.object({element:o.z.union([w.clonable,B.clonable]),on:o.z.union([o.z.literal("items"),o.z.literal("footer"),o.z.object({id:o.z.string()})]).optional(),placement:ie.optional()}))}),Na=o.z.object({panelId:o.z.string(),elements:o.z.record(o.z.string(),o.z.union([Ze.input,B.input]))}),wt=o.z.object({panelId:o.z.string(),elements:o.z.record(o.z.string(),o.z.union([Ze.clonable,B.clonable]))}),Ot=o.z.object({panelId:o.z.string(),elements:o.z.array(o.z.string())}),At=o.z.object({showLegend:o.z.boolean().optional(),cooperativeGestures:o.z.boolean().optional(),fullScreenButton:o.z.boolean().optional(),geolocation:o.z.boolean().optional(),zoomControls:o.z.boolean().optional(),scaleBar:o.z.boolean().optional()}),Rt=o.z.object({featureSelectPanel:o.z.boolean().optional(),featureHoverPanel:o.z.boolean().optional(),elementSelectPanel:o.z.boolean().optional(),linkClickOpen:o.z.boolean().optional(),imageLightboxOpen:o.z.boolean().optional()});var Zn=t("addPanel",jt),Wn=t("updatePanel",Vt),_n=t("deletePanel",le.z.string()),Qn=t("addPanelElements",Bt),$n=t("updatePanelElements",wt),Kn=t("deletePanelElements",Ot),Xn=t("updateUiControls",At),Yn=t("setOnMapInteractionsUi",Rt),er=t("showLayerDataTable",le.z.object({layerId:le.z.string(),sorting:ge.optional()}).optional()),tr=t("hideLayerDataTable",le.z.undefined()),Dt={methods:[Zn,Wn,_n,Qn,$n,Kn,Xn,Yn,er,tr],listeners:null};var We=require("zod");var pe=require("zod");var Me=pe.z.object({center:de,zoom:Qe}),Nt=pe.z.object({center:Me.shape.center.optional(),zoom:Me.shape.zoom.optional()}),qt=pe.z.object({minZoom:Me.shape.zoom.nullish(),maxZoom:Me.shape.zoom.nullish(),bounds:F.nullish()}).nullable(),Ht=pe.z.object({bounds:F});var or=t("getViewport",We.z.undefined()),nr=t("setViewport",Nt),rr=t("getViewportConstraints",We.z.undefined()),ar=t("setViewportConstraints",qt),ir=t("fitViewportToBounds",Ht),sr=y("onViewportMove"),lr=y("onViewportMoveEnd"),pr=y("onMapIdle"),Jt={methods:[nr,or,rr,ar,ir],listeners:[sr,lr,pr]};var _e=[Dt,Jt,Lt,tt,Gt,ot,kt,Et];function mr(a,d,N){let H=new Map;async function O(M){if(!gr.safeParse(M.data).success){N?.onUnknownMessage?.(M.data);return}let me=_t.safeParse(M.data);if(!me.success){N?.onInvalidMessage?.(M.data,me.error),M.ports[0]?.postMessage(Zt(me.error.message));return}let{data:f}=me;if(f.type==="felt.ready")M.ports[0]?.postMessage(!0);else if(f.type==="felt.addListener"){if(f.event.eventName==="")throw new Error("felt.addListener eventName cannot be empty");let K="options"in f.event?{options:"options"in f.event?f.event.options:void 0,handler:Ce=>{M.ports[0]?.postMessage(Ce)}}:{handler:Ce=>{M.ports[0]?.postMessage(Ce)}},Ee=d.listeners[f.event.eventName](K);H.set(f.event.id,Ee)}else if(f.type==="felt.removeListener")H.get(f.id)?.(),H.delete(f.id);else try{let K=d.methods[f.type],Ee=await K(f.params);M.ports[0]?.postMessage(Ee)}catch(K){M.ports[0]?.postMessage(Zt(K))}}return a.addEventListener("message",O),()=>{a.removeEventListener("message",O)}}var Wt={methods:_e.map(a=>a.methods??[]).flat(),listeners:_e.map(a=>a.listeners??[]).flat()},cr=u.z.discriminatedUnion("eventName",[u.z.strictObject({eventName:u.z.literal("")}),u.z.strictObject({eventName:u.z.literal("onGenericEvent"),id:u.z.string(),options:u.z.object({id:u.z.string()})}),...Wt.listeners]),ur=u.z.strictObject({type:u.z.literal("felt.addListener"),event:cr}),dr=u.z.strictObject({type:u.z.literal("felt.removeListener"),id:u.z.string()}),yr=u.z.strictObject({type:u.z.literal("felt.ready")}),_t=u.z.discriminatedUnion("type",[yr,ur,dr,...Wt.methods]),gr=u.z.object({type:u.z.enum(_t.options.map(a=>a.shape.type.value))});function Zt(a){return{__error__:hr(a)}}function hr(a){return a instanceof Error?a.message:typeof a=="object"&&a!==null&&"message"in a?String(a.message):typeof a=="string"?a:"Unknown error"}0&&(module.exports={createMessageHandler});
|
|
1
|
+
"use strict";var Pe=Object.defineProperty;var Qt=Object.getOwnPropertyDescriptor;var $t=Object.getOwnPropertyNames;var Kt=Object.prototype.hasOwnProperty;var Xt=(a,y)=>{for(var A in y)Pe(a,A,{get:y[A],enumerable:!0})},Yt=(a,y,A,H)=>{if(y&&typeof y=="object"||typeof y=="function")for(let O of $t(y))!Kt.call(a,O)&&O!==A&&Pe(a,O,{get:()=>y[O],enumerable:!(H=Qt(y,O))||H.enumerable});return a};var eo=a=>Yt(Pe({},"__esModule",{value:!0}),a);var fn={};Xt(fn,{createMessageHandler:()=>cn});module.exports=eo(fn);var d=require("zod");var L=require("zod");var z=require("zod");function t(a,y){return z.z.strictObject({type:z.z.literal(a),params:y})}function E(a,y){return z.z.strictObject({eventName:z.z.literal(a),id:z.z.string(),options:y})}function g(a){return z.z.strictObject({eventName:z.z.literal(a),id:z.z.string()})}var m=require("zod"),pe=m.z.number(),de=m.z.number(),ye=m.z.object({latitude:de,longitude:pe}),R=m.z.tuple([pe,de]),X=m.z.object({type:m.z.literal("Polygon"),coordinates:m.z.array(m.z.array(R).min(4).refine(a=>a[0][0]===a[a.length-1][0]&&a[0][1]===a[a.length-1][1],"The last point of each ring must be identical to the first"))}),ge=m.z.object({type:m.z.literal("MultiPolygon"),coordinates:m.z.array(X.shape.coordinates)}),to=m.z.object({type:m.z.literal("LineString"),coordinates:m.z.array(R).min(2)}),Y=m.z.object({type:m.z.literal("MultiLineString"),coordinates:m.z.array(to.shape.coordinates)}),Qe=m.z.number().min(1).max(23),F=m.z.tuple([pe,de,pe,de]),q=m.z.object({show:m.z.array(m.z.string()).optional(),hide:m.z.array(m.z.string()).optional()}),oo=m.z.enum(["asc","desc"]),ue=m.z.object({attribute:m.z.string(),direction:oo});var e=require("zod");var I=e.z.object({id:e.z.string(),groupId:e.z.string().nullable(),color:e.z.string(),name:e.z.string().nullable(),description:e.z.string().nullable(),attributes:e.z.record(e.z.string(),e.z.unknown()),interaction:e.z.enum(["default","locked"]).optional()}),Se=e.z.object({imageUrl:e.z.string().nullable()}),ze=e.z.object({strokeOpacity:e.z.number(),strokeWidth:e.z.number(),strokeStyle:e.z.enum(["solid","dashed","dotted"])}),ro=e.z.enum(["meter","kilometer","foot","mile"]),he=I.extend(Se.shape).extend({type:e.z.literal("Place"),coordinates:R,symbol:e.z.string(),frame:e.z.enum(["frame-circle","frame-square"]).nullable(),hideLabel:e.z.boolean()}),ee=I.extend(Se.shape).extend(ze.shape).extend({type:e.z.literal("Path"),coordinates:Y.shape.coordinates,distanceMarker:e.z.boolean(),routingMode:e.z.enum(["driving","cycling","walking","flying"]).nullable(),endCaps:e.z.boolean()}),te=I.extend(Se.shape).extend(ze.shape).extend({type:e.z.literal("Polygon"),coordinates:X.shape.coordinates,fillOpacity:e.z.number().min(0).max(1),areaMarker:e.z.boolean()}),fe=I.extend(Se.shape).extend(ze.shape).extend({type:e.z.literal("Circle"),center:R,radius:e.z.number(),radiusMarker:e.z.boolean(),radiusDisplayAngle:e.z.number(),radiusDisplayUnit:ro.nullable(),fillOpacity:e.z.number().min(0).max(1)}),oe=I.extend({type:e.z.literal("Marker"),coordinates:Y.shape.coordinates,opacity:e.z.number().min(0).max(1),size:e.z.number().min(0).max(100),zoom:e.z.number().min(0).max(23)}),re=I.extend({type:e.z.literal("Highlighter"),coordinates:ge.shape.coordinates,renderHoles:e.z.boolean(),opacity:e.z.number().min(0).max(1)}),$e=e.z.object({position:R,rotation:e.z.number(),scale:e.z.number(),zoom:e.z.number().min(0).max(23),text:e.z.string(),align:e.z.enum(["left","center","right"]),style:e.z.enum(["italic","light","regular","caps"]),name:e.z.string()}),Ge=I.extend($e.shape).extend({type:e.z.literal("Text")}),Te=I.extend($e.shape).extend({type:e.z.literal("Note"),widthScale:e.z.number().min(0)}),ne=I.extend({type:e.z.literal("Image"),coordinates:Y.shape.coordinates,imageUrl:e.z.string(),opacity:e.z.number().min(0).max(1)}).omit({color:!0}),no=I.extend({type:e.z.literal("Link"),coordinates:Y.shape.coordinates,url:e.z.string()}),J={type:!0,coordinates:!0},U={id:!0},Fe=he.partial().extend(he.pick(J).shape).omit(U),xe=ee.partial().extend(ee.pick(J).shape).omit(U),Ue=te.partial().extend(te.pick(J).shape).omit(U),ke=fe.partial().extend(fe.pick({type:!0,center:!0,radius:!0}).shape).omit(U),ve=oe.partial().extend(oe.pick(J).shape).omit(U),je=re.partial().extend(re.pick(J).shape).omit(U),Ve=Ge.partial().omit({...U,name:!0,type:!0}).extend({type:e.z.literal("Text"),text:e.z.string()}),Be=Te.partial().omit({...U,name:!0,type:!0}).extend({type:e.z.literal("Note"),text:e.z.string()}),ao=ne.partial().extend(ne.pick({...J,imageUrl:!0}).shape).omit(U),Ke=e.z.discriminatedUnion("type",[Fe,xe,Ue,ke,ve,je,ao,Ve,Be]);var Mn=ee.omit({coordinates:!0}),En=te.omit({coordinates:!0});var In=oe.omit({coordinates:!0}),Pn=re.omit({coordinates:!0});var Gn=ne.omit({coordinates:!0}),Tn=no.omit({coordinates:!0}),k={type:!0,id:!0},io=he.partial().extend(he.pick(k).shape),so=ee.partial().extend(ee.pick(k).shape),lo=te.partial().extend(te.pick(k).shape),mo=fe.partial().extend(fe.pick(k).shape),co=oe.partial().extend(oe.pick(k).shape),po=re.partial().extend(re.pick(k).shape),yo=Ge.partial().extend(Ge.pick(k).shape).omit({name:!0}),go=Te.partial().extend(Te.pick(k).shape).omit({name:!0}),uo=ne.partial().extend(ne.pick(k).shape),Xe=e.z.discriminatedUnion("type",[io,so,lo,mo,co,po,yo,go,uo]),Ye=e.z.object({ids:e.z.array(e.z.string()).optional()}),et=e.z.object({ids:e.z.array(e.z.string()).optional()});var ho=t("getElement",L.z.string()),fo=t("getElementGeometry",L.z.string()),So=t("getElements",Ye.optional()),xo=t("getElementGroup",L.z.string()),bo=t("getElementGroups",et.optional()),Lo=t("setElementGroupVisibility",q),Co=E("onElementChange",L.z.object({id:L.z.string()})),Mo=g("onElementCreate"),Eo=g("onElementCreateEnd"),Io=E("onElementDelete",L.z.object({id:L.z.string()})),Po=E("onElementGroupChange",L.z.object({id:L.z.string()})),Go=t("createElement",Ke),To=t("updateElement",Xe),zo=t("deleteElement",L.z.string()),tt={methods:[ho,fo,So,xo,bo,Lo,Go,To,zo],listeners:[Co,Mo,Eo,Io,Po]};var Fo=g("onPointerClick"),Uo=g("onPointerMove"),ot={methods:null,listeners:[Fo,Uo]};var i=require("zod");var s=require("zod");var ko=s.z.enum(["in","ni"]),vo=s.z.enum(["lt","gt","le","ge","eq","ne","cn","nc","is","isnt"]),wn=s.z.enum(["and","or"]),rt=s.z.union([s.z.number(),s.z.string(),s.z.boolean(),s.z.null()]),nt=s.z.string().or(s.z.null()),jo=s.z.tuple([nt,ko,s.z.array(rt).or(s.z.null())]),Vo=s.z.tuple([nt,vo,rt]),we=s.z.union([jo,Vo]),Oe=s.z.tuple([s.z.lazy(()=>s.z.union([Oe,we,s.z.null(),s.z.boolean()])),s.z.enum(["and","or"]),s.z.lazy(()=>s.z.union([Oe,we,s.z.null(),s.z.boolean()]))]),v=s.z.union([Oe,we,s.z.null(),s.z.boolean()]),j=s.z.union([F,X,ge,s.z.array(R)]);var r=require("zod");var at=r.z.enum(["avg","max","min","sum","median"]),it=r.z.enum(["avg","max","min","sum","count"]),Bo=r.z.object({method:at,attribute:r.z.string()}),wo=r.z.object({methods:r.z.array(r.z.union([at,r.z.literal("count")])),attribute:r.z.string().optional()}),st=r.z.object({boundary:j.optional(),filters:v.optional(),aggregation:Bo.optional()}),lt=r.z.object({layerId:r.z.string(),attribute:r.z.string(),limit:r.z.number().optional(),boundary:j.optional(),filters:v.optional(),values:st.optional()}),Dn=r.z.object({key:r.z.union([r.z.number(),r.z.string(),r.z.boolean()]),value:r.z.number().nullable()}),Oo=r.z.object({type:r.z.literal("equal-intervals"),count:r.z.number()}),Ro=r.z.object({type:r.z.literal("time-interval"),interval:r.z.enum(["hour","day","week","month","year"])}),mt=r.z.object({layerId:r.z.string(),attribute:r.z.string(),steps:r.z.union([Oo,Ro,r.z.array(r.z.number())]),boundary:j.optional(),filters:v.optional(),values:st.optional()}),Nn=r.z.object({min:r.z.number(),max:r.z.number(),value:r.z.number()}),ct=r.z.object({layerId:r.z.string(),boundary:j.optional(),filters:v.optional(),aggregation:wo}),pt=r.z.enum(["h3"]),Do=r.z.object({type:pt,resolution:r.z.number(),method:it.extract(["count"])}),No=r.z.object({type:pt,resolution:r.z.number(),method:it.exclude(["count"]),attribute:r.z.string()}),Ao=r.z.union([Do,No]),dt=r.z.object({layerId:r.z.string(),boundary:j.optional(),filters:v.optional(),gridConfig:Ao});var n=require("zod");var Hn=n.z.enum(["processing","completed","failed","incomplete"]),yt=n.z.object({type:n.z.literal("geoJsonUrl"),url:n.z.string().url(),refreshInterval:n.z.number().min(250).max(5*60*1e3).nullable().optional()}),gt=n.z.object({type:n.z.literal("geoJsonData"),data:n.z.object({}).passthrough().or(n.z.instanceof(ArrayBuffer))}),ut=n.z.object({type:n.z.literal("geoJsonFile"),file:n.z.instanceof(File)}),ht=n.z.object({id:n.z.string(),style:n.z.object({}).passthrough().optional(),shownInLegend:n.z.boolean().optional(),name:n.z.string().optional(),caption:n.z.string().optional(),description:n.z.string().optional(),bounds:F.optional(),source:n.z.union([yt,gt,ut]).optional()}),ft=n.z.object({ids:n.z.array(n.z.string()).optional()}),St=n.z.object({ids:n.z.array(n.z.string()).optional()}),Z=n.z.object({id:n.z.string(),layerId:n.z.string()}),xt=n.z.object({ids:Z.array().optional(),layerIds:n.z.string().array().optional()}),bt=n.z.object({layerIds:n.z.array(n.z.string()).optional(),areaQuery:n.z.union([n.z.object({coordinates:ye}),n.z.object({boundary:F})]).optional()}),qo=n.z.object({Point:n.z.object({}).passthrough().optional(),Line:n.z.object({}).passthrough().optional(),Polygon:n.z.object({}).passthrough().optional()}),Lt=n.z.object({source:n.z.union([yt,gt,ut]),name:n.z.string(),bounds:F.optional(),caption:n.z.string().optional(),description:n.z.string().optional(),geometryStyles:qo.optional()});var Ho=t("getLayer",i.z.string()),Jo=t("getLayers",ft.optional()),Zo=t("setLayerVisibility",q),Wo=E("onLayerChange",i.z.object({id:i.z.string()})),_o=t("setLayerStyle",i.z.object({id:i.z.string(),style:i.z.object({}).passthrough()})),Qo=t("setLayerLegendVisibility",q),$o=t("createLayersFromGeoJson",Lt),Ko=t("updateLayer",ht),Xo=t("deleteLayer",i.z.string()),Yo=t("getLayerGroup",i.z.string()),er=t("getLayerGroups",St.optional()),tr=t("setLayerGroupVisibility",q),or=t("setLayerGroupLegendVisibility",q),rr=E("onLayerGroupChange",i.z.object({id:i.z.string()})),nr=t("getLegendItem",Z),ar=t("getLegendItems",xt.optional()),ir=E("onLegendItemChange",Z),sr=t("setLegendItemVisibility",i.z.object({show:Z.array().optional(),hide:Z.array().optional()})),lr=t("getLayerFilters",i.z.string()),mr=t("setLayerFilters",i.z.object({layerId:i.z.string(),filters:v,note:i.z.string().optional()})),cr=E("onLayerFiltersChange",i.z.object({layerId:i.z.string()})),pr=t("getLayerBoundaries",i.z.string()),dr=t("setLayerBoundary",i.z.object({layerIds:i.z.array(i.z.string()),boundary:j.nullable()})),yr=E("onLayerBoundariesChange",i.z.object({layerId:i.z.string()})),gr=t("getRenderedFeatures",bt.optional()),ur=t("getFeature",i.z.object({id:i.z.string().or(i.z.number()),layerId:i.z.string()})),hr=t("getFeatures",i.z.object({layerId:i.z.string(),filters:v.optional(),sorting:ue.optional(),boundary:j.optional(),search:i.z.string().optional(),pagination:i.z.string().optional().nullish()})),fr=t("getGeoJsonFeature",i.z.object({id:i.z.string().or(i.z.number()),layerId:i.z.string()})),Sr=t("getCategoryData",lt),xr=t("getHistogramData",mt),br=t("getAggregates",ct),Lr=t("getPrecomputedAggregates",dt),Cr=t("getLayerSchema",i.z.string()),Ct={methods:[Ho,Jo,Zo,_o,Qo,$o,Xo,Ko,Yo,er,tr,or,nr,ar,sr,lr,mr,pr,dr,gr,ur,hr,fr,Sr,xr,br,Lr,Cr],listeners:[Wo,rr,ir,cr,yr]};var Mt=require("zod");var Mr=t("getMapDetails",Mt.z.undefined()),Et={methods:[Mr],listeners:[]};var ae=require("zod");var V=require("zod"),It=V.z.object({id:V.z.string().or(V.z.number()),layerId:V.z.string(),showPopup:V.z.boolean().optional(),fitViewport:V.z.boolean().or(V.z.object({maxZoom:V.z.number()})).optional()});var Er=t("getSelection",ae.z.undefined()),Ir=g("onSelectionChange"),Pr=t("selectFeature",It),Gr=t("clearSelection",ae.z.object({features:ae.z.boolean().optional(),elements:ae.z.boolean().optional()}).optional()),Pt={methods:[Er,Pr,Gr],listeners:[Ir]};var Ut=require("zod");var u=require("zod");var Gt=["circle","highlighter","line","marker","note","pin","polygon","route","text"],Tr=[...Gt,"link"],Tt=u.z.enum(Tr),zt=u.z.enum(Gt),zr=Fe.pick({color:!0,symbol:!0,frame:!0}).extend({afterCreation:u.z.enum(["enter name","add another","select"])}).required(),Fr=xe.pick({color:!0,strokeOpacity:!0,strokeWidth:!0,strokeStyle:!0,distanceMarker:!0}).required(),Ur=xe.pick({color:!0,routingMode:!0,strokeOpacity:!0,strokeWidth:!0,strokeStyle:!0,distanceMarker:!0,endCaps:!0}).required(),kr=Ue.pick({color:!0,fillOpacity:!0,strokeOpacity:!0,strokeWidth:!0,strokeStyle:!0,areaMarker:!0}).required(),vr=ke.pick({color:!0,fillOpacity:!0,strokeOpacity:!0,strokeWidth:!0,strokeStyle:!0,radiusMarker:!0}).required(),jr=ve.pick({color:!0,opacity:!0,size:!0}).required(),Vr=je.pick({color:!0,opacity:!0,renderHoles:!0}).extend({size:u.z.number().min(0).max(200)}).required(),Br=Ve.pick({color:!0,align:!0,style:!0}).required(),wr=Be.pick({color:!0,align:!0,style:!0}).required(),Ft=u.z.discriminatedUnion("tool",[zr.partial().extend({tool:u.z.literal("pin")}),Fr.partial().extend({tool:u.z.literal("line")}),Ur.partial().extend({tool:u.z.literal("route")}),kr.partial().extend({tool:u.z.literal("polygon")}),vr.partial().extend({tool:u.z.literal("circle")}),jr.partial().extend({tool:u.z.literal("marker")}),Vr.partial().extend({tool:u.z.literal("highlighter")}),Br.partial().extend({tool:u.z.literal("text")}),wr.partial().extend({tool:u.z.literal("note")})]);var Or=t("setTool",Tt.nullable()),Rr=t("getTool",Ut.z.undefined()),Dr=g("onToolChange"),Nr=t("setToolSettings",Ft),Ar=t("getToolSettings",zt),qr=g("onToolSettingsChange"),kt={methods:[Or,Rr,Nr,Ar],listeners:[Dr,qr]};var le=require("zod");var o=require("zod");var D=require("zod"),ie=D.z.union([D.z.object({after:D.z.string()}),D.z.object({before:D.z.string()}),D.z.object({at:D.z.enum(["start","end"])})]);var be=require("zod");var h=require("zod"),vt=h.z.object({onCreate:h.z.function().args().returns(h.z.void()).optional(),onDestroy:h.z.function().args().returns(h.z.void()).optional()}),Hr=h.z.object({onCreate:h.z.string().optional(),onDestroy:h.z.string().optional()}),S=vt.extend({id:h.z.string()}),x=vt.extend({id:h.z.string().optional()}),b=Hr.extend({id:h.z.string().optional()}),Re=h.z.object({label:h.z.string().optional()}),N={read:S.extend(Re.shape),create:x.extend(Re.shape),clonable:b.extend(Re.shape)};var B={read:S.extend({type:be.z.literal("FlexibleSpace")}),create:x.extend({type:be.z.literal("FlexibleSpace")}),clonable:b.extend({type:be.z.literal("FlexibleSpace")})};var c=require("zod");var C=require("zod");var De=C.z.object({type:C.z.literal("Button"),label:C.z.string(),variant:C.z.enum(["primary","outlined","transparent","transparentThin"]).optional(),disabled:C.z.boolean().optional()}),P={read:S.extend(De.shape).extend({onClick:C.z.function().returns(C.z.void())}),create:x.extend(De.shape).extend({onClick:C.z.function().returns(C.z.void())}),clonable:b.extend(De.shape).extend({onClick:C.z.string()})};var T=require("zod");var Le=require("zod");var Ne=Le.z.object({type:Le.z.literal("Text"),content:Le.z.string()}),G={read:S.extend(Ne.shape),create:x.extend(Ne.shape),clonable:b.extend(Ne.shape)};var Ae=T.z.object({type:T.z.literal("ButtonGroup"),align:T.z.enum(["start","end"]).optional()}),W={read:S.extend(Ae.shape).extend({items:T.z.array(T.z.union([P.read,G.read,B.read]))}),create:x.extend(Ae.shape).extend({items:T.z.array(T.z.union([P.create,G.create,B.create]))}),clonable:b.extend(Ae.shape).extend({items:T.z.array(T.z.union([P.clonable,G.clonable,B.clonable]))})};var Ce=require("zod");var _={read:S.extend({type:Ce.z.literal("Divider")}),create:x.extend({type:Ce.z.literal("Divider")}),clonable:b.extend({type:Ce.z.literal("Divider")})};var p=require("zod");var qe=p.z.object({type:p.z.literal("Select"),options:p.z.array(p.z.object({label:p.z.string(),value:p.z.string()})),value:p.z.string().optional(),search:p.z.boolean().optional(),placeholder:p.z.string().optional()}),Q={read:N.read.extend(qe.shape).extend({onChange:p.z.function().args(p.z.object({value:p.z.string()})).returns(p.z.void())}),create:N.create.extend(qe.shape).extend({onChange:p.z.function().args(p.z.object({value:p.z.string()})).returns(p.z.void())}),clonable:N.clonable.extend(qe.shape).extend({onChange:p.z.string()})};var l=require("zod");var He=l.z.object({type:l.z.literal("TextInput"),value:l.z.string(),placeholder:l.z.string().optional()}),$={read:N.read.extend(He.shape).extend({onChange:l.z.function().args(l.z.string()).returns(l.z.void()).optional(),onBlur:l.z.function().args(l.z.string()).returns(l.z.void()).optional(),onFocus:l.z.function().args(l.z.string()).returns(l.z.void()).optional()}),create:N.create.extend(He.shape).extend({onChange:l.z.function().args(l.z.object({value:l.z.string()})).returns(l.z.void()).optional(),onBlur:l.z.function().args(l.z.object({value:l.z.string()})).returns(l.z.void()).optional(),onFocus:l.z.function().args(l.z.object({value:l.z.string()})).returns(l.z.void()).optional()}),clonable:N.clonable.extend(He.shape).extend({onChange:l.z.string().optional(),onBlur:l.z.string().optional(),onFocus:l.z.string().optional()})};var w={read:c.z.discriminatedUnion("type",[G.read,P.read,$.read,_.read,W.read,Q.read]),create:c.z.discriminatedUnion("type",[G.create,P.create,$.create,_.create,W.create,Q.create]),clonable:c.z.discriminatedUnion("type",[G.clonable,P.clonable,$.clonable,_.clonable,W.clonable,Q.clonable])},Je=c.z.object({type:c.z.literal("Panel"),title:c.z.string().optional()}),se={read:S.extend(Je.shape).extend({onClose:c.z.function().returns(c.z.void()).optional(),body:c.z.array(w.read),footer:c.z.array(w.read).optional()}),create:x.extend(Je.partial().shape).extend({onClose:c.z.function().returns(c.z.void()).optional(),body:c.z.array(w.create),footer:c.z.array(w.create).optional()}),clonable:b.extend(Je.partial().shape).extend({onClose:c.z.string().optional(),body:c.z.array(w.clonable),footer:c.z.array(w.clonable).optional()})},Ze={create:c.z.discriminatedUnion("type",[G.create.partial().required({type:!0}),P.create.partial().required({type:!0}),$.create.partial().required({type:!0}),_.create.partial().required({type:!0}),W.create.partial().required({type:!0}),Q.create.partial().required({type:!0})]),clonable:c.z.discriminatedUnion("type",[G.clonable.partial().required({type:!0}),P.clonable.partial().required({type:!0}),$.clonable.partial().required({type:!0}),_.clonable.partial().required({type:!0}),W.clonable.partial().required({type:!0}),Q.clonable.partial().required({type:!0})])};var Ra=o.z.object({panel:se.create,placement:ie.optional()}),jt=o.z.object({panel:se.clonable,placement:ie.optional()}),Da=se.create.partial().required({id:!0}),Vt=se.clonable.partial().required({id:!0}),Na=o.z.object({panelId:o.z.string(),elements:o.z.array(o.z.object({element:o.z.union([w.create,B.create]),container:o.z.union([o.z.literal("body"),o.z.literal("footer"),o.z.object({id:o.z.string()})]).optional(),placement:ie.optional()}))}),Bt=o.z.object({panelId:o.z.string(),elements:o.z.array(o.z.object({element:o.z.union([w.clonable,B.clonable]),container:o.z.union([o.z.literal("body"),o.z.literal("footer"),o.z.object({id:o.z.string()})]).optional(),placement:ie.optional()}))}),Aa=o.z.object({panelId:o.z.string(),elements:o.z.record(o.z.string(),o.z.union([Ze.create,B.create]))}),wt=o.z.object({panelId:o.z.string(),elements:o.z.record(o.z.string(),o.z.union([Ze.clonable,B.clonable]))}),Ot=o.z.object({panelId:o.z.string(),elements:o.z.array(o.z.string())}),Rt=o.z.object({showLegend:o.z.boolean().optional(),cooperativeGestures:o.z.boolean().optional(),fullScreenButton:o.z.boolean().optional(),geolocation:o.z.boolean().optional(),zoomControls:o.z.boolean().optional(),scaleBar:o.z.boolean().optional()}),Dt=o.z.object({featureSelectPanel:o.z.boolean().optional(),featureHoverPanel:o.z.boolean().optional(),elementSelectPanel:o.z.boolean().optional(),linkClickOpen:o.z.boolean().optional(),imageLightboxOpen:o.z.boolean().optional()});var Jr=t("createPanel",jt),Zr=t("updatePanel",Vt),Wr=t("deletePanel",le.z.string()),_r=t("createPanelElements",Bt),Qr=t("updatePanelElements",wt),$r=t("deletePanelElements",Ot),Kr=t("updateUiControls",Rt),Xr=t("setOnMapInteractionsUi",Dt),Yr=t("showLayerDataTable",le.z.object({layerId:le.z.string(),sorting:ue.optional()}).optional()),en=t("hideLayerDataTable",le.z.undefined()),Nt={methods:[Jr,Zr,Wr,_r,Qr,$r,Kr,Xr,Yr,en],listeners:null};var We=require("zod");var me=require("zod");var Me=me.z.object({center:ye,zoom:Qe}),At=me.z.object({center:Me.shape.center.optional(),zoom:Me.shape.zoom.optional()}),qt=me.z.object({minZoom:Me.shape.zoom.nullish(),maxZoom:Me.shape.zoom.nullish(),bounds:F.nullish()}).nullable(),Ht=me.z.object({bounds:F});var tn=t("getViewport",We.z.undefined()),on=t("setViewport",At),rn=t("getViewportConstraints",We.z.undefined()),nn=t("setViewportConstraints",qt),an=t("fitViewportToBounds",Ht),sn=g("onViewportMove"),ln=g("onViewportMoveEnd"),mn=g("onMapIdle"),Jt={methods:[on,tn,rn,nn,an],listeners:[sn,ln,mn]};var _e=[Nt,Jt,Ct,tt,Pt,ot,kt,Et];function cn(a,y,A){let H=new Map;async function O(M){if(!un.safeParse(M.data).success){A?.onUnknownMessage?.(M.data);return}let ce=_t.safeParse(M.data);if(!ce.success){A?.onInvalidMessage?.(M.data,ce.error),M.ports[0]?.postMessage(Zt(ce.error.message));return}let{data:f}=ce;if(f.type==="felt.ready")M.ports[0]?.postMessage(!0);else if(f.type==="felt.addListener"){if(f.event.eventName==="")throw new Error("felt.addListener eventName cannot be empty");let K="options"in f.event?{options:"options"in f.event?f.event.options:void 0,handler:Ie=>{M.ports[0]?.postMessage(Ie)}}:{handler:Ie=>{M.ports[0]?.postMessage(Ie)}},Ee=y.listeners[f.event.eventName](K);H.set(f.event.id,Ee)}else if(f.type==="felt.removeListener")H.get(f.id)?.(),H.delete(f.id);else try{let K=y.methods[f.type],Ee=await K(f.params);M.ports[0]?.postMessage(Ee)}catch(K){M.ports[0]?.postMessage(Zt(K))}}return a.addEventListener("message",O),()=>{a.removeEventListener("message",O)}}var Wt={methods:_e.map(a=>a.methods??[]).flat(),listeners:_e.map(a=>a.listeners??[]).flat()},pn=d.z.discriminatedUnion("eventName",[d.z.strictObject({eventName:d.z.literal("")}),d.z.strictObject({eventName:d.z.literal("onGenericEvent"),id:d.z.string(),options:d.z.object({id:d.z.string()})}),...Wt.listeners]),dn=d.z.strictObject({type:d.z.literal("felt.addListener"),event:pn}),yn=d.z.strictObject({type:d.z.literal("felt.removeListener"),id:d.z.string()}),gn=d.z.strictObject({type:d.z.literal("felt.ready")}),_t=d.z.discriminatedUnion("type",[gn,dn,yn,...Wt.methods]),un=d.z.object({type:d.z.enum(_t.options.map(a=>a.shape.type.value))});function Zt(a){return{__error__:hn(a)}}function hn(a){return a instanceof Error?a.message:typeof a=="object"&&a!==null&&"message"in a?String(a.message):typeof a=="string"?a:"Unknown error"}0&&(module.exports={createMessageHandler});
|
package/dist/handler.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z, ZodError } from 'zod';
|
|
2
|
-
import { bL as UnwrapPromise, F as FeltController, z as zInfer, c as ElementChangeCallbackParams, f as ElementGroupChangeCallbackParams, E as Element, D as MapInteractionEvent, $ as LayerChangeCallbackParams, a2 as LayerGroupChangeCallbackParams, a5 as LegendItemChangeCallbackParams, at as LayerFilters, as as LayerBoundaries, ap as FilterTernary, aO as EntityNode, bn as ToolType, bl as ToolSettingsChangeEvent, bJ as ViewportState, bM as UnionToIntersection, bN as PromiseOrNot } from './controller-
|
|
2
|
+
import { bL as UnwrapPromise, F as FeltController, z as zInfer, c as ElementChangeCallbackParams, f as ElementGroupChangeCallbackParams, E as Element, D as MapInteractionEvent, $ as LayerChangeCallbackParams, a2 as LayerGroupChangeCallbackParams, a5 as LegendItemChangeCallbackParams, at as LayerFilters, as as LayerBoundaries, ap as FilterTernary, aO as EntityNode, bn as ToolType, bl as ToolSettingsChangeEvent, bJ as ViewportState, bM as UnionToIntersection, bN as PromiseOrNot } from './controller-BX0NMWZH.cjs';
|
|
3
3
|
|
|
4
4
|
type FeltControllerFunctions = Omit<FeltController, "iframe">;
|
|
5
5
|
type Method<TRequest extends {
|
|
@@ -4096,8 +4096,8 @@ type ToolsSchema = {
|
|
|
4096
4096
|
};
|
|
4097
4097
|
};
|
|
4098
4098
|
|
|
4099
|
-
declare const
|
|
4100
|
-
type: z.ZodLiteral<"
|
|
4099
|
+
declare const CreatePanelMessage: z.ZodObject<{
|
|
4100
|
+
type: z.ZodLiteral<"createPanel">;
|
|
4101
4101
|
params: z.ZodObject<{
|
|
4102
4102
|
panel: z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
4103
4103
|
onCreate: z.ZodOptional<z.ZodString>;
|
|
@@ -4109,7 +4109,7 @@ declare const AddPanelMessage: z.ZodObject<{
|
|
|
4109
4109
|
title: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
4110
4110
|
}>, {
|
|
4111
4111
|
onClose: z.ZodOptional<z.ZodString>;
|
|
4112
|
-
|
|
4112
|
+
body: z.ZodArray<z.ZodDiscriminatedUnion<"type", [z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
4113
4113
|
onCreate: z.ZodOptional<z.ZodString>;
|
|
4114
4114
|
onDestroy: z.ZodOptional<z.ZodString>;
|
|
4115
4115
|
}, {
|
|
@@ -4686,7 +4686,7 @@ declare const AddPanelMessage: z.ZodObject<{
|
|
|
4686
4686
|
search?: boolean | undefined;
|
|
4687
4687
|
}>]>, "many">>;
|
|
4688
4688
|
}>, "strip", z.ZodTypeAny, {
|
|
4689
|
-
|
|
4689
|
+
body: ({
|
|
4690
4690
|
type: "Text";
|
|
4691
4691
|
content: string;
|
|
4692
4692
|
id?: string | undefined;
|
|
@@ -4839,7 +4839,7 @@ declare const AddPanelMessage: z.ZodObject<{
|
|
|
4839
4839
|
search?: boolean | undefined;
|
|
4840
4840
|
})[] | undefined;
|
|
4841
4841
|
}, {
|
|
4842
|
-
|
|
4842
|
+
body: ({
|
|
4843
4843
|
type: "Text";
|
|
4844
4844
|
content: string;
|
|
4845
4845
|
id?: string | undefined;
|
|
@@ -5013,7 +5013,7 @@ declare const AddPanelMessage: z.ZodObject<{
|
|
|
5013
5013
|
}>]>>;
|
|
5014
5014
|
}, "strip", z.ZodTypeAny, {
|
|
5015
5015
|
panel: {
|
|
5016
|
-
|
|
5016
|
+
body: ({
|
|
5017
5017
|
type: "Text";
|
|
5018
5018
|
content: string;
|
|
5019
5019
|
id?: string | undefined;
|
|
@@ -5175,7 +5175,7 @@ declare const AddPanelMessage: z.ZodObject<{
|
|
|
5175
5175
|
} | undefined;
|
|
5176
5176
|
}, {
|
|
5177
5177
|
panel: {
|
|
5178
|
-
|
|
5178
|
+
body: ({
|
|
5179
5179
|
type: "Text";
|
|
5180
5180
|
content: string;
|
|
5181
5181
|
id?: string | undefined;
|
|
@@ -5339,7 +5339,7 @@ declare const AddPanelMessage: z.ZodObject<{
|
|
|
5339
5339
|
}, z.UnknownKeysParam, z.ZodTypeAny, {
|
|
5340
5340
|
params: {
|
|
5341
5341
|
panel: {
|
|
5342
|
-
|
|
5342
|
+
body: ({
|
|
5343
5343
|
type: "Text";
|
|
5344
5344
|
content: string;
|
|
5345
5345
|
id?: string | undefined;
|
|
@@ -5500,11 +5500,11 @@ declare const AddPanelMessage: z.ZodObject<{
|
|
|
5500
5500
|
at: "start" | "end";
|
|
5501
5501
|
} | undefined;
|
|
5502
5502
|
};
|
|
5503
|
-
type: "
|
|
5503
|
+
type: "createPanel";
|
|
5504
5504
|
}, {
|
|
5505
5505
|
params: {
|
|
5506
5506
|
panel: {
|
|
5507
|
-
|
|
5507
|
+
body: ({
|
|
5508
5508
|
type: "Text";
|
|
5509
5509
|
content: string;
|
|
5510
5510
|
id?: string | undefined;
|
|
@@ -5665,14 +5665,18 @@ declare const AddPanelMessage: z.ZodObject<{
|
|
|
5665
5665
|
at: "start" | "end";
|
|
5666
5666
|
} | undefined;
|
|
5667
5667
|
};
|
|
5668
|
-
type: "
|
|
5668
|
+
type: "createPanel";
|
|
5669
5669
|
}>;
|
|
5670
5670
|
declare const UpdatePanelMessage: z.ZodObject<{
|
|
5671
5671
|
type: z.ZodLiteral<"updatePanel">;
|
|
5672
5672
|
params: z.ZodObject<{
|
|
5673
5673
|
type: z.ZodOptional<z.ZodOptional<z.ZodLiteral<"Panel">>>;
|
|
5674
5674
|
id: z.ZodString;
|
|
5675
|
-
|
|
5675
|
+
onCreate: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
5676
|
+
onDestroy: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
5677
|
+
title: z.ZodOptional<z.ZodOptional<z.ZodOptional<z.ZodString>>>;
|
|
5678
|
+
onClose: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
5679
|
+
body: z.ZodOptional<z.ZodArray<z.ZodDiscriminatedUnion<"type", [z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
5676
5680
|
onCreate: z.ZodOptional<z.ZodString>;
|
|
5677
5681
|
onDestroy: z.ZodOptional<z.ZodString>;
|
|
5678
5682
|
}, {
|
|
@@ -5960,10 +5964,6 @@ declare const UpdatePanelMessage: z.ZodObject<{
|
|
|
5960
5964
|
placeholder?: string | undefined;
|
|
5961
5965
|
search?: boolean | undefined;
|
|
5962
5966
|
}>]>, "many">>;
|
|
5963
|
-
onCreate: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
5964
|
-
onDestroy: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
5965
|
-
title: z.ZodOptional<z.ZodOptional<z.ZodOptional<z.ZodString>>>;
|
|
5966
|
-
onClose: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
5967
5967
|
footer: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodDiscriminatedUnion<"type", [z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
5968
5968
|
onCreate: z.ZodOptional<z.ZodString>;
|
|
5969
5969
|
onDestroy: z.ZodOptional<z.ZodString>;
|
|
@@ -6255,7 +6255,11 @@ declare const UpdatePanelMessage: z.ZodObject<{
|
|
|
6255
6255
|
}, "strip", z.ZodTypeAny, {
|
|
6256
6256
|
id: string;
|
|
6257
6257
|
type?: "Panel" | undefined;
|
|
6258
|
-
|
|
6258
|
+
onCreate?: string | undefined;
|
|
6259
|
+
onDestroy?: string | undefined;
|
|
6260
|
+
title?: string | undefined;
|
|
6261
|
+
onClose?: string | undefined;
|
|
6262
|
+
body?: ({
|
|
6259
6263
|
type: "Text";
|
|
6260
6264
|
content: string;
|
|
6261
6265
|
id?: string | undefined;
|
|
@@ -6328,10 +6332,6 @@ declare const UpdatePanelMessage: z.ZodObject<{
|
|
|
6328
6332
|
placeholder?: string | undefined;
|
|
6329
6333
|
search?: boolean | undefined;
|
|
6330
6334
|
})[] | undefined;
|
|
6331
|
-
onCreate?: string | undefined;
|
|
6332
|
-
onDestroy?: string | undefined;
|
|
6333
|
-
title?: string | undefined;
|
|
6334
|
-
onClose?: string | undefined;
|
|
6335
6335
|
footer?: ({
|
|
6336
6336
|
type: "Text";
|
|
6337
6337
|
content: string;
|
|
@@ -6408,7 +6408,11 @@ declare const UpdatePanelMessage: z.ZodObject<{
|
|
|
6408
6408
|
}, {
|
|
6409
6409
|
id: string;
|
|
6410
6410
|
type?: "Panel" | undefined;
|
|
6411
|
-
|
|
6411
|
+
onCreate?: string | undefined;
|
|
6412
|
+
onDestroy?: string | undefined;
|
|
6413
|
+
title?: string | undefined;
|
|
6414
|
+
onClose?: string | undefined;
|
|
6415
|
+
body?: ({
|
|
6412
6416
|
type: "Text";
|
|
6413
6417
|
content: string;
|
|
6414
6418
|
id?: string | undefined;
|
|
@@ -6481,10 +6485,6 @@ declare const UpdatePanelMessage: z.ZodObject<{
|
|
|
6481
6485
|
placeholder?: string | undefined;
|
|
6482
6486
|
search?: boolean | undefined;
|
|
6483
6487
|
})[] | undefined;
|
|
6484
|
-
onCreate?: string | undefined;
|
|
6485
|
-
onDestroy?: string | undefined;
|
|
6486
|
-
title?: string | undefined;
|
|
6487
|
-
onClose?: string | undefined;
|
|
6488
6488
|
footer?: ({
|
|
6489
6489
|
type: "Text";
|
|
6490
6490
|
content: string;
|
|
@@ -6563,7 +6563,11 @@ declare const UpdatePanelMessage: z.ZodObject<{
|
|
|
6563
6563
|
params: {
|
|
6564
6564
|
id: string;
|
|
6565
6565
|
type?: "Panel" | undefined;
|
|
6566
|
-
|
|
6566
|
+
onCreate?: string | undefined;
|
|
6567
|
+
onDestroy?: string | undefined;
|
|
6568
|
+
title?: string | undefined;
|
|
6569
|
+
onClose?: string | undefined;
|
|
6570
|
+
body?: ({
|
|
6567
6571
|
type: "Text";
|
|
6568
6572
|
content: string;
|
|
6569
6573
|
id?: string | undefined;
|
|
@@ -6636,10 +6640,6 @@ declare const UpdatePanelMessage: z.ZodObject<{
|
|
|
6636
6640
|
placeholder?: string | undefined;
|
|
6637
6641
|
search?: boolean | undefined;
|
|
6638
6642
|
})[] | undefined;
|
|
6639
|
-
onCreate?: string | undefined;
|
|
6640
|
-
onDestroy?: string | undefined;
|
|
6641
|
-
title?: string | undefined;
|
|
6642
|
-
onClose?: string | undefined;
|
|
6643
6643
|
footer?: ({
|
|
6644
6644
|
type: "Text";
|
|
6645
6645
|
content: string;
|
|
@@ -6719,7 +6719,11 @@ declare const UpdatePanelMessage: z.ZodObject<{
|
|
|
6719
6719
|
params: {
|
|
6720
6720
|
id: string;
|
|
6721
6721
|
type?: "Panel" | undefined;
|
|
6722
|
-
|
|
6722
|
+
onCreate?: string | undefined;
|
|
6723
|
+
onDestroy?: string | undefined;
|
|
6724
|
+
title?: string | undefined;
|
|
6725
|
+
onClose?: string | undefined;
|
|
6726
|
+
body?: ({
|
|
6723
6727
|
type: "Text";
|
|
6724
6728
|
content: string;
|
|
6725
6729
|
id?: string | undefined;
|
|
@@ -6792,10 +6796,6 @@ declare const UpdatePanelMessage: z.ZodObject<{
|
|
|
6792
6796
|
placeholder?: string | undefined;
|
|
6793
6797
|
search?: boolean | undefined;
|
|
6794
6798
|
})[] | undefined;
|
|
6795
|
-
onCreate?: string | undefined;
|
|
6796
|
-
onDestroy?: string | undefined;
|
|
6797
|
-
title?: string | undefined;
|
|
6798
|
-
onClose?: string | undefined;
|
|
6799
6799
|
footer?: ({
|
|
6800
6800
|
type: "Text";
|
|
6801
6801
|
content: string;
|
|
@@ -6882,8 +6882,8 @@ declare const DeletePanelMessage: z.ZodObject<{
|
|
|
6882
6882
|
params: string;
|
|
6883
6883
|
type: "deletePanel";
|
|
6884
6884
|
}>;
|
|
6885
|
-
declare const
|
|
6886
|
-
type: z.ZodLiteral<"
|
|
6885
|
+
declare const CreatePanelElementsMessage: z.ZodObject<{
|
|
6886
|
+
type: z.ZodLiteral<"createPanelElements">;
|
|
6887
6887
|
params: z.ZodObject<{
|
|
6888
6888
|
panelId: z.ZodString;
|
|
6889
6889
|
elements: z.ZodArray<z.ZodObject<{
|
|
@@ -7192,7 +7192,7 @@ declare const AddPanelElementsMessage: z.ZodObject<{
|
|
|
7192
7192
|
onCreate?: string | undefined;
|
|
7193
7193
|
onDestroy?: string | undefined;
|
|
7194
7194
|
}>]>;
|
|
7195
|
-
|
|
7195
|
+
container: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"body">, z.ZodLiteral<"footer">, z.ZodObject<{
|
|
7196
7196
|
id: z.ZodString;
|
|
7197
7197
|
}, "strip", z.ZodTypeAny, {
|
|
7198
7198
|
id: string;
|
|
@@ -7304,7 +7304,7 @@ declare const AddPanelElementsMessage: z.ZodObject<{
|
|
|
7304
7304
|
} | {
|
|
7305
7305
|
at: "start" | "end";
|
|
7306
7306
|
} | undefined;
|
|
7307
|
-
|
|
7307
|
+
container?: "body" | "footer" | {
|
|
7308
7308
|
id: string;
|
|
7309
7309
|
} | undefined;
|
|
7310
7310
|
}, {
|
|
@@ -7393,7 +7393,7 @@ declare const AddPanelElementsMessage: z.ZodObject<{
|
|
|
7393
7393
|
} | {
|
|
7394
7394
|
at: "start" | "end";
|
|
7395
7395
|
} | undefined;
|
|
7396
|
-
|
|
7396
|
+
container?: "body" | "footer" | {
|
|
7397
7397
|
id: string;
|
|
7398
7398
|
} | undefined;
|
|
7399
7399
|
}>, "many">;
|
|
@@ -7485,7 +7485,7 @@ declare const AddPanelElementsMessage: z.ZodObject<{
|
|
|
7485
7485
|
} | {
|
|
7486
7486
|
at: "start" | "end";
|
|
7487
7487
|
} | undefined;
|
|
7488
|
-
|
|
7488
|
+
container?: "body" | "footer" | {
|
|
7489
7489
|
id: string;
|
|
7490
7490
|
} | undefined;
|
|
7491
7491
|
}[];
|
|
@@ -7577,7 +7577,7 @@ declare const AddPanelElementsMessage: z.ZodObject<{
|
|
|
7577
7577
|
} | {
|
|
7578
7578
|
at: "start" | "end";
|
|
7579
7579
|
} | undefined;
|
|
7580
|
-
|
|
7580
|
+
container?: "body" | "footer" | {
|
|
7581
7581
|
id: string;
|
|
7582
7582
|
} | undefined;
|
|
7583
7583
|
}[];
|
|
@@ -7671,12 +7671,12 @@ declare const AddPanelElementsMessage: z.ZodObject<{
|
|
|
7671
7671
|
} | {
|
|
7672
7672
|
at: "start" | "end";
|
|
7673
7673
|
} | undefined;
|
|
7674
|
-
|
|
7674
|
+
container?: "body" | "footer" | {
|
|
7675
7675
|
id: string;
|
|
7676
7676
|
} | undefined;
|
|
7677
7677
|
}[];
|
|
7678
7678
|
};
|
|
7679
|
-
type: "
|
|
7679
|
+
type: "createPanelElements";
|
|
7680
7680
|
}, {
|
|
7681
7681
|
params: {
|
|
7682
7682
|
panelId: string;
|
|
@@ -7766,12 +7766,12 @@ declare const AddPanelElementsMessage: z.ZodObject<{
|
|
|
7766
7766
|
} | {
|
|
7767
7767
|
at: "start" | "end";
|
|
7768
7768
|
} | undefined;
|
|
7769
|
-
|
|
7769
|
+
container?: "body" | "footer" | {
|
|
7770
7770
|
id: string;
|
|
7771
7771
|
} | undefined;
|
|
7772
7772
|
}[];
|
|
7773
7773
|
};
|
|
7774
|
-
type: "
|
|
7774
|
+
type: "createPanelElements";
|
|
7775
7775
|
}>;
|
|
7776
7776
|
declare const UpdatePanelElementsMessage: z.ZodObject<{
|
|
7777
7777
|
type: z.ZodLiteral<"updatePanelElements">;
|
|
@@ -8560,10 +8560,10 @@ declare const HideLayerDataTableMessage: z.ZodObject<{
|
|
|
8560
8560
|
}>;
|
|
8561
8561
|
type UiSchema = {
|
|
8562
8562
|
methods: {
|
|
8563
|
-
|
|
8563
|
+
createPanel: Method<zInfer<typeof CreatePanelMessage>>;
|
|
8564
8564
|
updatePanel: Method<zInfer<typeof UpdatePanelMessage>>;
|
|
8565
8565
|
deletePanel: Method<zInfer<typeof DeletePanelMessage>>;
|
|
8566
|
-
|
|
8566
|
+
createPanelElements: Method<zInfer<typeof CreatePanelElementsMessage>>;
|
|
8567
8567
|
updatePanelElements: Method<zInfer<typeof UpdatePanelElementsMessage>>;
|
|
8568
8568
|
deletePanelElements: Method<zInfer<typeof DeletePanelElementsMessage>>;
|
|
8569
8569
|
updateUiControls: Method<zInfer<typeof UiControlsMessage>>;
|