@mappedin/mappedin-js 6.0.1-alpha.14 → 6.0.1-alpha.16

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/lib/esm/index.css CHANGED
@@ -1 +1 @@
1
- .mMapviewHoverLabel{background:rgba(255,255,255,.9);color:#333;padding:10px;font-size:14px;font-weight:700;transition:opacity .3s;font-family:sans-serif}.mappedin-map{position:relative;overflow:hidden}.mappedin__floating-label{position:absolute;top:0;left:0;opacity:0;width:200px;height:200px;will-change:transform;transition:opacity .3s linear}.mappedin__floating-label__icon{position:absolute;top:0;left:0;width:16px;height:16px}.mappedin__floating-label__icon>svg{position:absolute;top:-50%;left:-50%}.mappedin__floating-label__text_holder{font-family:InterUI-Regular,Helvetica,Arial,sans-serif;font-weight:400;font-weight:500;position:absolute;pointer-events:none;word-break:keep-all}.mappedin__floating-label__text_legacy{text-shadow:1px 1px 0px #ffffff,-1px -1px 0px #ffffff,1px -1px 0px #ffffff,-1px 1px 0px #ffffff}.mappedin__floating-label__text_back{-webkit-text-stroke:4px white;color:#fff}.mappedin__floating-label__text_front{color:#000;position:absolute;display:block;width:100%;height:100%;top:0;left:0}.mappedin-tooltip__wrapper{display:flex;width:1px;height:1px;align-items:center;justify-content:center;z-index:1}.mappedin-tooltip{font-family:InterUI-Regular,Helvetica,Arial,sans-serif;font-weight:400;top:0;transition:transform .3s linear;font-weight:700;color:#000;position:absolute;z-index:1;transition:opacity .3s;display:flex;flex-direction:row;will-change:transform,opacity;justify-content:center}.mappedin-tooltip>div{z-index:2;flex-shrink:0;max-width:500px;background:white;border-radius:20px;box-shadow:0 2px 11px #0003}.mappedin-tooltip:before{content:"";width:0;height:0;top:calc(50% - 10px);left:-10px;z-index:1;position:absolute;border-bottom:10px solid transparent;border-top:10px solid transparent}.mappedin-tooltip.tooltip--anchor-top{left:0;top:0}.mappedin-tooltip.tooltip--anchor-top:before{left:calc(50% - 10px);top:calc(100% - 5px);right:auto;border-bottom:10px solid transparent;border-top:10px solid white;border-left:10px solid transparent;border-right:10px solid transparent}.mappedin-tooltip.tooltip--anchor-bottom{left:0;top:0}.mappedin-tooltip.tooltip--anchor-bottom:before{left:calc(50% - 10px);top:-15px;right:auto;border-bottom:10px solid white;border-top:10px solid transparent;border-left:10px solid transparent;border-right:10px solid transparent}.mappedin-tooltip.tooltip--anchor-right{justify-content:flex-start;left:0;top:0}.mappedin-tooltip.tooltip--anchor-right:before{left:-5px;right:auto;border-right:10px solid white}.mappedin-tooltip.tooltip--anchor-left{left:0;top:0}.mappedin-tooltip.tooltip--anchor-left:before{left:auto;right:-5px;border-left:10px solid white}.mappedin-tooltip.tooltip--anchor-top-left{left:7px;top:7px}.mappedin-tooltip.tooltip--anchor-top-left:before{left:auto;right:-7px;top:calc(100% - 13px);border-bottom:10px solid transparent;border-top:10px solid white;border-left:10px solid transparent;border-right:10px solid transparent;transform:rotate(-45deg)}.mappedin-tooltip.tooltip--anchor-top-right{left:-6px;top:7px}.mappedin-tooltip.tooltip--anchor-top-right:before{left:-7px;right:auto;top:calc(100% - 13px);border-bottom:10px solid transparent;border-top:10px solid white;border-left:10px solid transparent;border-right:10px solid transparent;transform:rotate(45deg)}.mappedin-tooltip.tooltip--anchor-bottom-left{left:7px;top:-6px}.mappedin-tooltip.tooltip--anchor-bottom-left:before{left:auto;right:-7px;top:-7px;border-bottom:10px solid white;border-top:10px solid transparent;border-left:10px solid transparent;border-right:10px solid transparent;transform:rotate(45deg)}.mappedin-tooltip.tooltip--anchor-bottom-right{left:-6px;top:-6px}.mappedin-tooltip.tooltip--anchor-bottom-right:before{left:-7px;right:auto;top:-7px;border-bottom:10px solid white;border-top:10px solid transparent;border-left:10px solid transparent;border-right:10px solid transparent;transform:rotate(-45deg)}.mappedin-tooltip.tooltip--visible{opacity:1}.mappedin-tooltip.pointer-events-none{pointer-events:none}.mappedin-tooltip.pointer-events-auto{pointer-events:auto}.mappedin-marker{font-family:InterUI-Regular,Helvetica,Arial,sans-serif;font-weight:400;pointer-events:none;top:0;transition:transform .3s linear;position:absolute;font-weight:700;color:#000;z-index:1;transition:opacity .3s;display:flex;flex-direction:row;will-change:opacity;justify-content:center}.mappedin__smart-collision-engine__container{position:absolute;left:0;top:0;bottom:0;right:0;pointer-events:none;transform-style:preserve-3d;z-index:1;font-family:InterUI-Regular,Helvetica,Arial,sans-serif}.mappedin__smart-collision-engine-debug__container{position:absolute;left:0;top:0;bottom:0;right:0;transition:opacity .3s ease-in-out;pointer-events:none;will-change:opacity}.mappedin__smart-collision-engine-debug__container.interacting{opacity:.2}.outdoor-ctrl-attrib{display:block;position:absolute;visibility:visible;pointer-events:auto;font:9px/11px InterUI-Regular,Helvetica,Arial,sans-serif;transform:translate(0);padding:3px 20px 1px 5px;background-color:#ffffff80;margin:0;min-width:11px;min-height:11px}.outdoor-ctrl-attrib.outdoor-ctrl-attrib-hide{display:none}.outdoor-ctrl-attrib-top-left{top:0;left:1px;float:left;border-bottom-right-radius:4px}.outdoor-ctrl-attrib-top-right{top:0;right:1px;float:right;border-bottom-left-radius:4px}.outdoor-ctrl-attrib-bottom-left{bottom:0;left:1px;float:left;border-top-right-radius:4px}.outdoor-ctrl-attrib-bottom-right{right:0;bottom:1px;float:right;border-top-left-radius:4px}.outdoor-ctrl-attrib-bottom-left,.outdoor-ctrl-attrib-top-left{padding:3px 5px 1px 20px}.outdoor-ctrl-attrib.outdoor-compact{background-color:transparent}.outdoor-ctrl-attrib.outdoor-compact-show{min-width:15px;min-height:15px;box-sizing:border-box;background-color:#ffffff80}.outdoor-ctrl-attrib-inner,.outdoor-ctrl-attrib-inner a{color:#000000bf;text-decoration:none}.outdoor-ctrl-attrib-inner a:hover{color:#017ef1;text-decoration:underline;cursor:pointer}.outdoor-ctrl-attrib.outdoor-compact .outdoor-ctrl-attrib-inner{display:none}.outdoor-ctrl-attrib-button{display:none;cursor:pointer;position:absolute;background-image:url("data:image/svg+xml;charset=utf-8,<svg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill-rule='evenodd' viewBox='0 0 20 20'><circle cx='10' cy='10' r='5.9' style='fill:rgba(255,255,255,1);'/><path style='fill:rgba(0,0,0,0.7);' d='M4 10a6 6 0 1 0 12 0 6 6 0 1 0-12 0m5-3a1 1 0 1 0 2 0 1 1 0 1 0-2 0m0 3a1 1 0 1 1 2 0v3a1 1 0 1 1-2 0'/></svg>");background-size:15px;width:15px;height:15px;box-sizing:border-box;border-radius:50%;outline:none;top:0;right:2px;border:1px}.outdoor-ctrl-attrib summary.outdoor-ctrl-attrib-button{-webkit-appearance:none;appearance:none;list-style:none}.outdoor-ctrl-attrib summary.outdoor-ctrl-attrib-button::-webkit-details-marker{display:none}.outdoor-ctrl-attrib-top-left .outdoor-ctrl-attrib-button,.outdoor-ctrl-attrib-bottom-left .outdoor-ctrl-attrib-button{left:2px}.outdoor-ctrl-attrib.outdoor-compact .outdoor-ctrl-attrib-button,.outdoor-ctrl-attrib.outdoor-compact-show .outdoor-ctrl-attrib-inner{display:block}:root{--pin-shadow-hover-scale: .9;--pin-shadow-width: 12px;--pin-shadow-height: 5px;--pin-shadow-opacity: .35;--pin-drop-animation-duration-ms: .25s}@keyframes drop-pin{0%{transform:translateY(-200%)}to{transform:translateY(0)}}@keyframes pin-shadow{0%{transform:scale(var(--pin-shadow-hover-scale))}to{transform:scale(1)}}.mappedin-dropped-pin-wrapper{position:relative;width:fit-content;height:fit-content;width:36px;height:42px}.mappedin-dropped-pin-wrapper svg{position:absolute;left:calc(50% - var(--pin-shadow-width));animation:drop-pin var(--pin-drop-animation-duration-ms) ease-in}.mappedin-dropped-pin-wrapper>.pin-shadow{position:absolute;left:calc(50% - (var(--pin-shadow-width) / 2));bottom:0;height:var(--pin-shadow-height);width:var(--pin-shadow-width);border-radius:100%;opacity:var(--pin-shadow-opacity);animation:pin-shadow .25s ease-in}@keyframes bounce{0%{transform:translateY(-10px);opacity:0}12.5%{transform:translateY(0);opacity:1}25%{transform:translateY(0)}37.5%{transform:translateY(-10px)}50%{transform:translateY(0)}62.5%{transform:translateY(-10px)}75%{transform:translateY(0)}87.5%{transform:translateY(-10px)}to{transform:translateY(0)}}.mappedin-connection-marker .bouncey{animation:bounce 2.5s linear}.mappedin-connection-marker .arrow--down{transform:rotate(180deg)}.mappedin-connection-marker .connection-circle{display:flex;justify-content:center;align-items:center;border-radius:50%;border:2px solid white;box-shadow:0 2px 8px #00000026}
1
+ .mMapviewHoverLabel{background:rgba(255,255,255,.9);color:#333;padding:10px;font-size:14px;font-weight:700;transition:opacity .3s;font-family:sans-serif}.mappedin-map{position:relative;overflow:hidden}.mappedin__floating-label{position:absolute;top:0;left:0;opacity:0;width:200px;height:200px;will-change:transform;transition:opacity .3s linear}.mappedin__floating-label__icon{position:absolute;top:0;left:0;width:16px;height:16px}.mappedin__floating-label__icon>svg{position:absolute;top:-50%;left:-50%}.mappedin__floating-label__text_holder{font-family:InterUI-Regular,Helvetica,Arial,sans-serif;font-weight:400;font-weight:500;position:absolute;pointer-events:none;word-break:keep-all}.mappedin__floating-label__text_legacy{text-shadow:1px 1px 0px #ffffff,-1px -1px 0px #ffffff,1px -1px 0px #ffffff,-1px 1px 0px #ffffff}.mappedin__floating-label__text_back{-webkit-text-stroke:4px white;color:#fff}.mappedin__floating-label__text_front{color:#000;position:absolute;display:block;width:100%;height:100%;top:0;left:0}.mappedin-tooltip__wrapper{display:flex;width:1px;height:1px;align-items:center;justify-content:center;z-index:1}.mappedin-tooltip{font-family:InterUI-Regular,Helvetica,Arial,sans-serif;font-weight:400;top:0;transition:transform .3s linear;font-weight:700;color:#000;position:absolute;z-index:1;transition:opacity .3s;display:flex;flex-direction:row;will-change:transform,opacity;justify-content:center}.mappedin-tooltip>div{z-index:2;flex-shrink:0;max-width:500px;background:white;border-radius:20px;box-shadow:0 2px 11px #0003}.mappedin-tooltip:before{content:"";width:0;height:0;top:calc(50% - 10px);left:-10px;z-index:1;position:absolute;border-bottom:10px solid transparent;border-top:10px solid transparent}.mappedin-tooltip.tooltip--anchor-top{left:0;top:0}.mappedin-tooltip.tooltip--anchor-top:before{left:calc(50% - 10px);top:calc(100% - 5px);right:auto;border-bottom:10px solid transparent;border-top:10px solid white;border-left:10px solid transparent;border-right:10px solid transparent}.mappedin-tooltip.tooltip--anchor-bottom{left:0;top:0}.mappedin-tooltip.tooltip--anchor-bottom:before{left:calc(50% - 10px);top:-15px;right:auto;border-bottom:10px solid white;border-top:10px solid transparent;border-left:10px solid transparent;border-right:10px solid transparent}.mappedin-tooltip.tooltip--anchor-right{justify-content:flex-start;left:0;top:0}.mappedin-tooltip.tooltip--anchor-right:before{left:-5px;right:auto;border-right:10px solid white}.mappedin-tooltip.tooltip--anchor-left{left:0;top:0}.mappedin-tooltip.tooltip--anchor-left:before{left:auto;right:-5px;border-left:10px solid white}.mappedin-tooltip.tooltip--anchor-top-left{left:7px;top:7px}.mappedin-tooltip.tooltip--anchor-top-left:before{left:auto;right:-7px;top:calc(100% - 13px);border-bottom:10px solid transparent;border-top:10px solid white;border-left:10px solid transparent;border-right:10px solid transparent;transform:rotate(-45deg)}.mappedin-tooltip.tooltip--anchor-top-right{left:-6px;top:7px}.mappedin-tooltip.tooltip--anchor-top-right:before{left:-7px;right:auto;top:calc(100% - 13px);border-bottom:10px solid transparent;border-top:10px solid white;border-left:10px solid transparent;border-right:10px solid transparent;transform:rotate(45deg)}.mappedin-tooltip.tooltip--anchor-bottom-left{left:7px;top:-6px}.mappedin-tooltip.tooltip--anchor-bottom-left:before{left:auto;right:-7px;top:-7px;border-bottom:10px solid white;border-top:10px solid transparent;border-left:10px solid transparent;border-right:10px solid transparent;transform:rotate(45deg)}.mappedin-tooltip.tooltip--anchor-bottom-right{left:-6px;top:-6px}.mappedin-tooltip.tooltip--anchor-bottom-right:before{left:-7px;right:auto;top:-7px;border-bottom:10px solid white;border-top:10px solid transparent;border-left:10px solid transparent;border-right:10px solid transparent;transform:rotate(-45deg)}.mappedin-tooltip.tooltip--visible{opacity:1}.mappedin-tooltip.pointer-events-none{pointer-events:none}.mappedin-tooltip.pointer-events-auto{pointer-events:auto}.mappedin-marker{font-family:InterUI-Regular,Helvetica,Arial,sans-serif;font-weight:400;pointer-events:none;top:0;transition:transform .3s linear;position:absolute;font-weight:700;color:#000;z-index:1;transition:opacity .3s;display:flex;flex-direction:row;will-change:opacity;justify-content:center}:root{--pin-shadow-hover-scale: .9;--pin-shadow-width: 12px;--pin-shadow-height: 5px;--pin-shadow-opacity: .35;--pin-drop-animation-duration-ms: .25s}@keyframes drop-pin{0%{transform:translateY(-200%)}to{transform:translateY(0)}}@keyframes pin-shadow{0%{transform:scale(var(--pin-shadow-hover-scale))}to{transform:scale(1)}}.mappedin-dropped-pin-wrapper{position:relative;width:fit-content;height:fit-content;width:36px;height:42px}.mappedin-dropped-pin-wrapper svg{position:absolute;left:calc(50% - var(--pin-shadow-width));animation:drop-pin var(--pin-drop-animation-duration-ms) ease-in}.mappedin-dropped-pin-wrapper>.pin-shadow{position:absolute;left:calc(50% - (var(--pin-shadow-width) / 2));bottom:0;height:var(--pin-shadow-height);width:var(--pin-shadow-width);border-radius:100%;opacity:var(--pin-shadow-opacity);animation:pin-shadow .25s ease-in}@keyframes bounce{0%{transform:translateY(-10px);opacity:0}12.5%{transform:translateY(0);opacity:1}25%{transform:translateY(0)}37.5%{transform:translateY(-10px)}50%{transform:translateY(0)}62.5%{transform:translateY(-10px)}75%{transform:translateY(0)}87.5%{transform:translateY(-10px)}to{transform:translateY(0)}}.mappedin-connection-marker .bouncey{animation:bounce 2.5s linear}.mappedin-connection-marker .arrow--down{transform:rotate(180deg)}.mappedin-connection-marker .connection-circle{display:flex;justify-content:center;align-items:center;border-radius:50%;border:2px solid white;box-shadow:0 2px 8px #00000026}.mappedin__smart-collision-engine__container{position:absolute;left:0;top:0;bottom:0;right:0;pointer-events:none;transform-style:preserve-3d;z-index:1;font-family:InterUI-Regular,Helvetica,Arial,sans-serif}.mappedin__smart-collision-engine-debug__container{position:absolute;left:0;top:0;bottom:0;right:0;transition:opacity .3s ease-in-out;pointer-events:none;will-change:opacity}.mappedin__smart-collision-engine-debug__container.interacting{opacity:.2}.outdoor-ctrl-attrib{display:block;position:absolute;visibility:visible;pointer-events:auto;font:9px/11px InterUI-Regular,Helvetica,Arial,sans-serif;transform:translate(0);padding:3px 20px 1px 5px;background-color:#ffffff80;margin:0;min-width:11px;min-height:11px}.outdoor-ctrl-attrib.outdoor-ctrl-attrib-hide{display:none}.outdoor-ctrl-attrib-top-left{top:0;left:1px;float:left;border-bottom-right-radius:4px}.outdoor-ctrl-attrib-top-right{top:0;right:1px;float:right;border-bottom-left-radius:4px}.outdoor-ctrl-attrib-bottom-left{bottom:0;left:1px;float:left;border-top-right-radius:4px}.outdoor-ctrl-attrib-bottom-right{right:0;bottom:1px;float:right;border-top-left-radius:4px}.outdoor-ctrl-attrib-bottom-left,.outdoor-ctrl-attrib-top-left{padding:3px 5px 1px 20px}.outdoor-ctrl-attrib.outdoor-compact{background-color:transparent}.outdoor-ctrl-attrib.outdoor-compact-show{min-width:15px;min-height:15px;box-sizing:border-box;background-color:#ffffff80}.outdoor-ctrl-attrib-inner,.outdoor-ctrl-attrib-inner a{color:#000000bf;text-decoration:none}.outdoor-ctrl-attrib-inner a:hover{color:#017ef1;text-decoration:underline;cursor:pointer}.outdoor-ctrl-attrib.outdoor-compact .outdoor-ctrl-attrib-inner{display:none}.outdoor-ctrl-attrib-button{display:none;cursor:pointer;position:absolute;background-image:url("data:image/svg+xml;charset=utf-8,<svg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill-rule='evenodd' viewBox='0 0 20 20'><circle cx='10' cy='10' r='5.9' style='fill:rgba(255,255,255,1);'/><path style='fill:rgba(0,0,0,0.7);' d='M4 10a6 6 0 1 0 12 0 6 6 0 1 0-12 0m5-3a1 1 0 1 0 2 0 1 1 0 1 0-2 0m0 3a1 1 0 1 1 2 0v3a1 1 0 1 1-2 0'/></svg>");background-size:15px;width:15px;height:15px;box-sizing:border-box;border-radius:50%;outline:none;top:0;right:2px;border:1px}.outdoor-ctrl-attrib summary.outdoor-ctrl-attrib-button{-webkit-appearance:none;appearance:none;list-style:none}.outdoor-ctrl-attrib summary.outdoor-ctrl-attrib-button::-webkit-details-marker{display:none}.outdoor-ctrl-attrib-top-left .outdoor-ctrl-attrib-button,.outdoor-ctrl-attrib-bottom-left .outdoor-ctrl-attrib-button{left:2px}.outdoor-ctrl-attrib.outdoor-compact .outdoor-ctrl-attrib-button,.outdoor-ctrl-attrib.outdoor-compact-show .outdoor-ctrl-attrib-inner{display:block}
@@ -18,6 +18,7 @@ declare module '@mappedin/mappedin-js' {
18
18
  import { Floor } from '@mappedin/mappedin-js/maker/src/map-data-objects';
19
19
  import type { ParsedMVF as TMVF } from '@mappedin/mvf';
20
20
  import { TShowWatermarkOptions } from '@mappedin/mappedin-js/packages/legacy-renderer/private/controllers/WatermarkController';
21
+ import { MapViewGeoJson } from '@mappedin/mappedin-js/maker/src/map-view-geojson';
21
22
  /**
22
23
  * Represents all the available antialiasing options.
23
24
  */
@@ -222,6 +223,8 @@ declare module '@mappedin/mappedin-js' {
222
223
  * const mapContainer = document.getQuerySelector('body');
223
224
  * const map = await show3dMap(mapContainer, mapData, { auto: true });
224
225
  */
226
+ export const show3dMapCms: (el: HTMLElement, mapData: MapData, options?: TShow3DMapOptions) => Promise<MapView>;
227
+ export const show3dMapGeojson: (el: HTMLElement, mapData: MapData) => Promise<MapViewGeoJson>;
225
228
  export const show3dMap: (el: HTMLElement, mapData: MapData, options?: TShow3DMapOptions) => Promise<MapView>;
226
229
  export { parseMVF, unzipMVF };
227
230
  export type { MapView, MapData, TEvents, TShow3DMapOptions, TGetMapDataOptions, TAmbientOcclusionOptions, TAntialiasingOptions, TMVF, };
@@ -493,6 +496,16 @@ declare module '@mappedin/mappedin-js/maker/src/events' {
493
496
  */
494
497
  'user-interaction-end': undefined;
495
498
  };
499
+ export type GeoJSONTEvents = TEvents & {
500
+ hover: {
501
+ coordinate: Coordinate;
502
+ spaces: Space[];
503
+ objects: MapObject[];
504
+ markers: Marker[];
505
+ labels: Label[];
506
+ floors: Floor[];
507
+ };
508
+ };
496
509
  }
497
510
 
498
511
  declare module '@mappedin/mappedin-js/packages/get-venue' {
@@ -767,7 +780,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.MVF' {
767
780
  };
768
781
  }[];
769
782
  }
770
- export function convertNodes(mvfNodes: NodeCollection, converters: Map<string, CoordinateConverter>): TNode[];
783
+ export function convertNodes(nodesById: WithIDs<NodeCollection['features'][number]>, converters: Map<string, CoordinateConverter>): TNode[];
771
784
  export function convertNodes_MVFv1(node: MVFv1NodeCollection, map: string, converter: CoordinateConverter): TNode[];
772
785
  type MapExtent = {
773
786
  minLat: number;
@@ -776,7 +789,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.MVF' {
776
789
  maxLong: number;
777
790
  };
778
791
  export function convertPolygons(map: string, mvfObstructions: ObstructionCollection, mvfSpaces: SpaceCollection, deskEntrances: Map<string, TPolygon['entrances']>, styles: WithIDs<MVFStyle>, layerStyles: StyleCollection, converter: CoordinateConverter): TPolygon[];
779
- export function convertVortexes(mvfConnections: Connections): TVortex[];
792
+ export function convertVortexes(mvfConnections: Connections, nodesById: WithIDs<NodeCollection['features'][number]>): TVortex[];
780
793
  export function convertVortexes_MVFv1(mvfConnections: MVFv1ConnectionCollection): TVortex[];
781
794
  export function overrideMVF(mvf: ParsedMVF, override?: Partial<Pick<ParsedMVF, 'styles.json'>>): ParsedMVF;
782
795
  /**
@@ -969,6 +982,143 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controlle
969
982
  export default WatermarkController;
970
983
  }
971
984
 
985
+ declare module '@mappedin/mappedin-js/maker/src/map-view-geojson' {
986
+ import { PubSub } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
987
+ import { GeoJSONTEvents as TEvents } from '@mappedin/mappedin-js/maker/src/events';
988
+ import { Floor, MapObject, Space } from '@mappedin/mappedin-js/maker/src/map-data-objects';
989
+ import MapData from '@mappedin/mappedin-js/maker/src/map-data';
990
+ import { ICamera, ILabels, IMapView, IMarkers, IPaths, TUpdateState, INavigation, TNavigationTarget, TGetDirectionsOptions } from '@mappedin/mappedin-js/maker/src/map-view-interface';
991
+ import { Directions, Label } from '@mappedin/mappedin-js/maker/src/map-view-objects';
992
+ /**
993
+ * Represents a map with all the interactive features, controls, and actions.
994
+ */
995
+ export class MapViewGeoJson extends PubSub<TEvents> implements IMapView {
996
+ #private;
997
+ /**
998
+ * Controls for the map's labels *{@link ILabels}).
999
+ * @type {ILabels}
1000
+ */
1001
+ Labels: ILabels;
1002
+ /**
1003
+ * Controls for the map's markers ({@link IMarkers}).
1004
+ * @type {IMarkers}
1005
+ */
1006
+ Markers: IMarkers;
1007
+ /**
1008
+ * Camera ({@link ICamera}) controls for the map.
1009
+ * @type {ICamera}
1010
+ */
1011
+ Camera: ICamera;
1012
+ /**
1013
+ * Controls for the map's ({@link IPaths}).
1014
+ * @type {IPaths}
1015
+ */
1016
+ Paths: IPaths;
1017
+ /**
1018
+ * Navigation ({@link INavigation}) controls for the map.
1019
+ * @type {INavigation}
1020
+ */
1021
+ Navigation: INavigation;
1022
+ /**
1023
+ * Constructs a {@link MapView} instance
1024
+ *
1025
+ * @param el The HTMLElement where the map will be rendered.
1026
+ * @param options The options to customize the map display.
1027
+ * @internal
1028
+ */
1029
+ constructor(el: HTMLElement, options?: any);
1030
+ /**
1031
+ * @internal - unused until we use GeoJSON API underneath
1032
+ */
1033
+ addMap(mapData: MapData): Promise<MapData>;
1034
+ /**
1035
+ * Updates the state {@link TUpdateState} of a given target on the map.
1036
+ *
1037
+ * The following table maps targets to states.
1038
+ *
1039
+ * | target | state |
1040
+ * |-----------|----------------|
1041
+ * | {@link Label} | {@link TLabelState} |
1042
+ * | {@link MapObject} | {@link TGeometryState} |
1043
+ * | {@link Space} | {@link TGeometryState} |
1044
+ *
1045
+ * @param target The target to update.
1046
+ * @param state The new state to apply to the target.
1047
+ * @example
1048
+ * // Update the color of a space to red.
1049
+ * map.updateState(space, { color: 'red' });
1050
+ */
1051
+ updateState<T extends Space | MapObject | Label>(target: T, state: TUpdateState<T>): void;
1052
+ setHoverColor(c: string): void;
1053
+ getHoverColor(): string;
1054
+ getState(target: Space | Label | MapObject): {
1055
+ interactive: boolean;
1056
+ hoverColor: string | undefined;
1057
+ color: string;
1058
+ initialColor: string;
1059
+ hover: boolean | undefined;
1060
+ opacity: number | undefined;
1061
+ } | {
1062
+ appearance: {
1063
+ margin: number;
1064
+ text: {
1065
+ numLines: number;
1066
+ lineHeight: number;
1067
+ size: number;
1068
+ maxWidth: number;
1069
+ foregroundColor: string;
1070
+ backgroundColor: string;
1071
+ };
1072
+ marker: {
1073
+ size: number;
1074
+ foregroundColor: {
1075
+ active: string;
1076
+ inactive: string;
1077
+ };
1078
+ backgroundColor: {
1079
+ active: string;
1080
+ inactive: string;
1081
+ };
1082
+ iconSize?: number | undefined;
1083
+ icon?: string | undefined;
1084
+ iconVisibilityThreshold?: number | undefined;
1085
+ };
1086
+ };
1087
+ interactive: boolean;
1088
+ opacity: number;
1089
+ } | undefined;
1090
+ /**
1091
+ * Retrieves the current floor of the map.
1092
+ *
1093
+ * @returns The current floor of the map.
1094
+ * @example
1095
+ * // Get the current floor of the map.
1096
+ * const floor = map.currentFloor;
1097
+ */
1098
+ get currentFloor(): Floor;
1099
+ get mapData(): {
1100
+ [key: string]: MapData;
1101
+ };
1102
+ /**
1103
+ * Sets the current floor of the map.
1104
+ */
1105
+ setFloor(floor: Floor | string): void;
1106
+ /**
1107
+ * Retrieves {@link Directions} from one navigatable point {@link TNavigationTarget} to another
1108
+ * {@link TNavigationTarget} on the map.
1109
+ *
1110
+ * @param from The starting point for navigation.
1111
+ * @param to The destination point.
1112
+ * @param options Optional parameters for getting directions.
1113
+ * @returns Directions from the start to the destination point.
1114
+ * @example
1115
+ * // Get directions from space1 to space2.
1116
+ * const directions = await map.getDirections(space1, space2);
1117
+ */
1118
+ getDirections(from: TNavigationTarget | TNavigationTarget[], to: TNavigationTarget | TNavigationTarget[], options?: TGetDirectionsOptions): Directions | undefined;
1119
+ }
1120
+ }
1121
+
972
1122
  declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
973
1123
  import type { Coordinate, Floor, Door, Space, MapObject, PointOfInterest, Connection } from '@mappedin/mappedin-js/maker/src/map-data-objects';
974
1124
  import { Label, Marker, Path, Directions } from '@mappedin/mappedin-js/maker/src/map-view-objects';
@@ -1326,6 +1476,11 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
1326
1476
  * @internal
1327
1477
  */
1328
1478
  auto(): void;
1479
+ /**
1480
+ * Get the current floor
1481
+ */
1482
+ currentFloor: Floor;
1483
+ setFloor(floor: Floor): void;
1329
1484
  /**
1330
1485
  * @internal - unused until we use GeoJSON API underneath
1331
1486
  */
@@ -1352,7 +1507,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
1352
1507
  * // Update the color of a space to red.
1353
1508
  * map.updateState(space, { color: 'red' });
1354
1509
  */
1355
- updateState: <T extends Space | Label>(object: T, state: TUpdateState<T>) => void;
1510
+ updateState: <T extends Space | MapObject | Label>(object: T, state: TUpdateState<T>) => void;
1356
1511
  /**
1357
1512
  * Retrieves {@link Directions} from one navigation point {@link TNavigationTarget} to another
1358
1513
  * {@link TNavigationTarget} on the map.
@@ -1364,7 +1519,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
1364
1519
  * // Get directions from space1 to space2.
1365
1520
  * const directions = await map.getDirections(space1, space2);
1366
1521
  */
1367
- getDirections: (from: TNavigationTarget, to: TNavigationTarget) => void;
1522
+ getDirections: (from: TNavigationTarget | TNavigationTarget[], to: TNavigationTarget | TNavigationTarget[], options?: TGetDirectionsOptions) => Directions | undefined;
1368
1523
  }
1369
1524
  /**
1370
1525
  * Options for controlling the behavior of a {@link Path}.
@@ -1819,6 +1974,7 @@ declare module '@mappedin/mappedin-js/maker/src' {
1819
1974
  import { Floor } from '@mappedin/mappedin-js/maker/src/map-data-objects';
1820
1975
  import type { ParsedMVF as TMVF } from '@mappedin/mvf';
1821
1976
  import { TShowWatermarkOptions } from '@mappedin/mappedin-js/packages/legacy-renderer/private/controllers/WatermarkController';
1977
+ import { MapViewGeoJson } from '@mappedin/mappedin-js/maker/src/map-view-geojson';
1822
1978
  /**
1823
1979
  * Represents all the available antialiasing options.
1824
1980
  */
@@ -2023,6 +2179,8 @@ declare module '@mappedin/mappedin-js/maker/src' {
2023
2179
  * const mapContainer = document.getQuerySelector('body');
2024
2180
  * const map = await show3dMap(mapContainer, mapData, { auto: true });
2025
2181
  */
2182
+ export const show3dMapCms: (el: HTMLElement, mapData: MapData, options?: TShow3DMapOptions) => Promise<MapView>;
2183
+ export const show3dMapGeojson: (el: HTMLElement, mapData: MapData) => Promise<MapViewGeoJson>;
2026
2184
  export const show3dMap: (el: HTMLElement, mapData: MapData, options?: TShow3DMapOptions) => Promise<MapView>;
2027
2185
  export { parseMVF, unzipMVF };
2028
2186
  export type { MapView, MapData, TEvents, TShow3DMapOptions, TGetMapDataOptions, TAmbientOcclusionOptions, TAntialiasingOptions, TMVF, };
@@ -5037,7 +5195,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-objects/label' {
5037
5195
  * Labels are used to provide additional information on the map.
5038
5196
  */
5039
5197
  export class Label implements ILabel {
5040
- id: string;
5198
+ readonly id: string;
5041
5199
  readonly text: any;
5042
5200
  /**
5043
5201
  * @internal
@@ -12714,13 +12872,12 @@ declare module '@mappedin/mappedin-js/maker/src/api-cms/api-cms' {
12714
12872
  import { FloatingLabel, Marker as LegacyMarker } from '@mappedin/mappedin-js/cms/src';
12715
12873
  import { ExportController, JourneyController } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
12716
12874
  import Core from '@mappedin/mappedin-js/packages/legacy-renderer/private/Core';
12717
- import { Coordinate, Door, Floor, MapDataInternal, MapObject, PointOfInterest, Space } from '@mappedin/mappedin-js/maker/src/map-data-objects';
12875
+ import { Coordinate, Floor, MapDataInternal, MapObject, Space } from '@mappedin/mappedin-js/maker/src/map-data-objects';
12718
12876
  import { MapView } from '@mappedin/mappedin-js/maker/src/map-view';
12719
12877
  import { IMapView, ILabels, TUpdateState, IMarkers, ICamera, TNavigationTarget, IPaths, TGetDirectionsOptions } from '@mappedin/mappedin-js/maker/src/map-view-interface';
12720
12878
  import { Marker, Directions, Label } from '@mappedin/mappedin-js/maker/src/map-view-objects';
12721
12879
  import { DefaultTheme } from '@mappedin/mappedin-js/maker/src/themes/default';
12722
12880
  import { Navigation } from '@mappedin/mappedin-js/maker/src/navigation';
12723
- export function getCoordinateFromStuffs(thing: Space | Door | Coordinate | MapObject | PointOfInterest): Coordinate | undefined;
12724
12881
  export function getMappedinCoordinate(coordinate: Coordinate, mvCore: Core): import("../../../packages/get-venue").MappedinCoordinate;
12725
12882
  export class CMSAPI implements IMapView {
12726
12883
  mvCore: Core;