venue-js 1.1.1 → 1.2.0-next.2

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/index.d.mts CHANGED
@@ -3,15 +3,14 @@ export { QueryObserver } from '@tanstack/query-core';
3
3
  import * as geojson from 'geojson';
4
4
  import { Position, Geometry, GeoJsonProperties, Feature, Point, Polygon, MultiPolygon, LineString, GeometryCollection } from 'geojson';
5
5
  import * as maptalks_dist_core_Class from 'maptalks/dist/core/Class';
6
- import * as maptalks_dist_geo_Extent from 'maptalks/dist/geo/Extent';
7
- import { Map, Coordinate as Coordinate$1, Extent } from 'maptalks-gl';
6
+ import { Map } from 'maptalks-gl';
8
7
  import { BaseObject, ThreeLayer } from 'maptalks.three';
9
- import * as maptalks from 'maptalks';
10
- import { Coordinate, Marker, ui, LineString as LineString$1, Polygon as Polygon$1, MultiPolygon as MultiPolygon$1, MultiLineString } from 'maptalks';
11
8
  import { ExtrudePolygonOptionType } from 'maptalks.three/dist/type';
12
9
  import { PolygonOptionsType } from 'maptalks/dist/geometry/Polygon';
13
10
  import { LineStringOptionsType } from 'maptalks/dist/geometry/LineString';
14
- import { MapViewType, MapAnimationOptionsType } from 'maptalks/dist/map/Map';
11
+ import * as maptalks from 'maptalks';
12
+ import { Extent, Marker, ui, LineString as LineString$1, Polygon as Polygon$1, MultiPolygon as MultiPolygon$1, MultiLineString } from 'maptalks';
13
+ import { MapViewType, MapAnimationOptionsType, MapPaddingType } from 'maptalks/dist/map/Map';
15
14
  import { SpriteMaterial, AmbientLight, DirectionalLight } from 'three';
16
15
 
17
16
  type Id = string;
@@ -658,8 +657,10 @@ type Filter = EqFilter | InFilter;
658
657
  type Filters = Record<string, Filter>;
659
658
 
660
659
  interface VenueClientOptions {
660
+ mode?: "delivery" | "preview";
661
661
  projectId: string;
662
- apiKey: string;
662
+ apiKey?: string;
663
+ previewToken?: string;
663
664
  baseUrl?: string;
664
665
  queryClient?: QueryClient;
665
666
  }
@@ -701,8 +702,15 @@ declare const GEOJSON_FEATURE_TYPES: FeatureType[];
701
702
  declare const ALL_FEATURE_TYPES: FeatureType[];
702
703
  declare const defaultFeatureQueryOptionsMap: Record<FeatureType, FeatureQueryOptions>;
703
704
 
704
- declare function fetchFeature<T extends FeatureType = FeatureType>(projectId: string, apiKey: string, featureType: FeatureType, baseUrl?: string): Promise<FeatureResponseMap[T][]>;
705
- declare const safeFetchFeature: <T extends FeatureType = FeatureType>(projectId: string, apiKey: string, featureType: FeatureType, baseUrl?: string) => Promise<FeatureResponseMap[T][]>;
705
+ declare function fetchDeliveryApi<T extends FeatureType = FeatureType>(projectId: string, apiKey: string, featureType: FeatureType, baseUrl?: string): Promise<FeatureResponseMap[T][]>;
706
+ declare function fetchPreviewApi<T extends FeatureType = FeatureType>(projectId: string, previewToken: string, featureType: FeatureType, baseUrl?: string): Promise<FeatureResponseMap[T][]>;
707
+ declare const safeFetchFeature: <T extends FeatureType = FeatureType>(featureType: FeatureType, params: {
708
+ mode: "delivery" | "preview";
709
+ projectId: string;
710
+ apiKey: string;
711
+ previewToken?: string;
712
+ baseUrl: string;
713
+ }) => Promise<FeatureResponseMap[T][]>;
706
714
 
707
715
  declare const getDataClient: (options: VenueClientOptions) => VenueDataClient;
708
716
 
@@ -764,22 +772,36 @@ declare class RendererManager extends EventTarget {
764
772
  clearMarkers(): void;
765
773
  }
766
774
 
775
+ interface CameraManagerOptions {
776
+ defaultView?: MapViewType;
777
+ }
778
+ declare class CameraManager {
779
+ map: Map;
780
+ constructor(map: Map, options?: CameraManagerOptions);
781
+ /** Public methods */
782
+ getView: () => MapViewType;
783
+ setView: (value: MapViewType) => void;
784
+ animateTo: (view: MapViewType, options?: MapAnimationOptionsType, step?: (frame: any) => void) => void;
785
+ setMaxExtent(extent: Extent): Map;
786
+ getFeatureExtent: (feature: any, scaleFactor?: number) => Extent;
787
+ getExtentZoom: (extent: Extent, options?: {
788
+ isFraction?: boolean;
789
+ padding?: MapPaddingType;
790
+ }) => number;
791
+ set maxZoom(value: number);
792
+ set minZoom(value: number);
793
+ }
794
+
767
795
  interface IndoorMapOptions {
768
796
  onMapReady?: () => void;
769
797
  onMapLoading?: () => void;
770
798
  centerCross?: boolean;
771
799
  dataClient: VenueDataClient;
772
- camera?: {
773
- defaultCenter?: [number, number];
774
- defaultZoom?: number;
775
- defaultBearing?: number;
776
- defaultPitch?: number;
777
- };
800
+ camera?: CameraManagerOptions;
778
801
  renderer?: RendererManagerOptions;
779
802
  pixelRatio?: number;
780
803
  locale?: string;
781
804
  }
782
- type AmenityHighlightMode = "2DMarker";
783
805
  type SymbolSet = string | null;
784
806
  interface IHighlightOptions {
785
807
  symbolSet?: SymbolSet;
@@ -792,94 +814,7 @@ interface ISetHighlightElementIdsOptions {
792
814
  highlight3DOptions?: IHighlightOptions;
793
815
  highlight2DOptions?: ISetHighlight2DElementIdsOptions;
794
816
  }
795
- interface IMapExtrudeConfig {
796
- height: number;
797
- category: string;
798
- }
799
- interface ILightConfig {
800
- ambientLight: IMapLightConfig;
801
- directionalLight: IMapLightConfig;
802
- }
803
- interface IMapLightConfig {
804
- color: string;
805
- position?: number[];
806
- intensity: number;
807
- }
808
- interface IExtrudeConfig {
809
- kiosk: IMapExtrudeConfig[];
810
- unit: IMapExtrudeConfig[];
811
- }
812
- interface IShortestPathConfig {
813
- resolution: number;
814
- }
815
- interface IAllVenuesViewConfig {
816
- zoom?: number;
817
- pitch?: number;
818
- center?: Coordinate;
819
- bearing?: number;
820
- }
821
- interface IMapAnimation {
822
- [k: string]: {
823
- enable?: boolean;
824
- speed?: number;
825
- };
826
- }
827
- interface IUnitDistanceModifier {
828
- [k: string]: number;
829
- }
830
- type IGraphOptions = {
831
- baseDistance?: number;
832
- multiplier?: number;
833
- };
834
- type IVerticalGraphOptions = IGraphOptions & {
835
- scaleDistanceByLevel?: boolean;
836
- };
837
- interface IGraphFeatureOptions {
838
- traversal?: IUnitDistanceModifier;
839
- escalator?: IGraphOptions;
840
- ramp?: IGraphOptions;
841
- elevator?: IGraphOptions;
842
- stairs?: IVerticalGraphOptions;
843
- }
844
- interface IMapConfig {
845
- amenity_highlight_mode?: AmenityHighlightMode;
846
- default_zoom?: number;
847
- max_zoom?: number;
848
- min_zoom?: number;
849
- kiosk_pixel_ratio?: number;
850
- mobile_pixel_ratio?: number;
851
- extrude?: IExtrudeConfig;
852
- light?: ILightConfig;
853
- shortest_path?: IShortestPathConfig;
854
- text_marker_type?: "marker" | "ui-marker";
855
- extent_features_scale_factor?: number;
856
- extent_scale_map_view_factor?: number;
857
- all_venues_view?: IAllVenuesViewConfig;
858
- animations?: IMapAnimation[];
859
- prepare_steps?: IGraphFeatureOptions;
860
- }
861
-
862
- interface CameraManagerOptions {
863
- defaultView?: MapViewType;
864
- }
865
- declare class CameraManager {
866
- #private;
867
- map: Map;
868
- constructor(map: Map, options?: CameraManagerOptions);
869
- /** Public methods */
870
- getView: () => MapViewType;
871
- getZoom: () => number;
872
- setView: (value: MapViewType) => void;
873
- flyTo: (center: any, options?: MapAnimationOptionsType & MapViewType) => void;
874
- flyToAndZoomIn: (centerPoint: any, options?: MapAnimationOptionsType & MapViewType) => void;
875
- }
876
817
 
877
- type MapPaddingType = {
878
- paddingLeft: number;
879
- paddingRight: number;
880
- paddingTop: number;
881
- paddingBottom: number;
882
- };
883
818
  declare class IndoorMap extends EventTarget {
884
819
  #private;
885
820
  map: Map | null;
@@ -891,10 +826,10 @@ declare class IndoorMap extends EventTarget {
891
826
  onMapLoading: () => void;
892
827
  constructor(elementId: any, options: IndoorMapOptions);
893
828
  set dataClient(value: any);
894
- on(eventName: string, handler: any): void;
895
829
  /**
896
830
  * Events
897
831
  */
832
+ on(eventName: string, handler: any): void;
898
833
  handleMapClick: ({ coordinate }: {
899
834
  coordinate: any;
900
835
  }) => void;
@@ -910,34 +845,21 @@ declare class IndoorMap extends EventTarget {
910
845
  set mapTheme(value: any);
911
846
  get venues(): any[];
912
847
  set detectVenueInView(value: any);
913
- get ordinals(): any[];
914
- set ordinals(value: any[]);
915
848
  set billboards(value: any);
916
- set mapConfig(value: IMapConfig);
917
849
  set mapDecorations(value: any);
918
- set maxZoom(value: number);
919
- set minZoom(value: number);
920
850
  set groundLabels(value: any);
921
851
  set pixelRatio(value: number);
922
852
  set onClickElement(func: any);
923
853
  set locale(value: string);
924
854
  handleClickElement: (e: any) => void;
925
- setCenter(center: Coordinate$1, padding?: MapPaddingType): void;
926
855
  /**
927
856
  * Change Level & animate to path / geometry / view / etc.
928
857
  * ================================== */
929
858
  changeLevelByOrdinal(ordinal: null | number | number[]): void;
930
- getFeatureExtent: (feature: any, scaleFactor?: number) => Extent;
931
- getExtentCenter: (extent: Extent) => maptalks_dist_geo_Extent.PositionType;
932
- getExtentZoom: (extent: Extent, options?: {
933
- isFraction?: boolean;
934
- padding?: MapPaddingType;
935
- }) => number;
936
859
  findVenueInView: () => {
937
860
  venueId: string;
938
861
  distance: number;
939
862
  };
940
- flyTo: (center: any, options: any) => void;
941
863
  getLineStringBearing: (feature: any) => number;
942
864
  addAnimations(animation: {
943
865
  id: string;
@@ -1005,15 +927,6 @@ declare class IndoorMap extends EventTarget {
1005
927
  /**
1006
928
  * render (frame)
1007
929
  */
1008
- getTargetViewCenter: (targetView: any, options?: {
1009
- offset: {
1010
- top: number;
1011
- left: number;
1012
- right: number;
1013
- bottom: number;
1014
- };
1015
- }) => Coordinate$1;
1016
- setMaxExtent(extent: Extent): Map;
1017
930
  render(): void;
1018
931
  }
1019
932
 
@@ -1211,4 +1124,4 @@ declare const VENUE_EVENTS: {
1211
1124
  VENUE_MOVEINTOVIEW: string;
1212
1125
  };
1213
1126
 
1214
- export { ALL_FEATURE_TYPES, ALWAYS_VISIBLE_FEATURE_TYPES, type AmenityFeature, type AmenityFeaturePopulated, type AmenityGeometry, type AmenityProperties, type AnchorFeature, type AnchorFeaturePopulated, type AnchorGeometry, type AnchorProperties, BASE_LAYER_NAME, DEFAULT_BASE_URL, DEFAULT_HIGHLIGHT_OPTIONS, DEFAULT_LOCALE, DEFAULT_SET_HIGHLIGHT_2DELEMENT_IDS_OPTIONS, DESTINATION_MARKER_ID, type DetailFeature, type DetailGeometry, type DetailProperties, type ElementFeature, type ElementGeometry, type ElementProperties, type EventFeature, type EventGeometry, type EventProperties, type FeaturePopulatedResponseMap, type FeatureQueryOptions, type FeatureResponseMap, type FeatureType, type FilterParams, type FindParams, type FixtureFeature, type FixtureFeaturePopulated, type FixtureGeometry, type FixtureProperties, GEOJSON_FEATURE_TYPES, HIGHLIGHT_LAYER_NAME, IMDF_FEATURE_TYPES, type Id, type ImdfFeature, IndoorMap, type InternalFilterByType, type InternalFindById, type KioskFeature, type KioskFeaturePopulated, type KioskGeometry, type KioskProperties, LAST_USER_LOCATION_ELEMENT_ID_PREFIX, LAYERS, LAYER_FEATURE_TYPE_OBJ, LAYER_OPTIONS, LOCALE_SYMBOL_KEY, type LabelFeature, type LabelGeometry, type LabelProperties, type LevelFeature, type LevelFeaturePopulated, type LevelGeometry, type LevelProperties, MARKER_LAYER_NAME, type Media, type MediaFile, type Model3d, NONIMDF_FEATURE_TYPES, ORIGIN_MARKER_ID, type OccupantFeature, type OccupantFeaturePopulated, type OccupantGeometry, type OccupantProperties, type OpeningFeature, type OpeningFeaturePopulated, type OpeningGeometry, type OpeningProperties, POI_MARKER_LAYER_NAME, type Page, type PolygonalFeature, type PopulatableFeatureType, type PopulatedParams, type PrivilegeFeature, type PrivilegeGeometry, type PrivilegeProperties, type PromotionFeature, type PromotionProperties, type RelationshipFeature, type RelationshipGeometry, type RelationshipProperties, type SectionFeature, type SectionFeaturePopulated, type SectionGeometry, type SectionProperties, type SponsoredContentFeature, type SponsoredContentLegacyType, type SponsoredContentPlacementType, type SponsoredContentStrapiV4ApiResponse, type TaxonomyFeature, type TaxonomyFeaturePopulated, type TaxonomyGeometry, type TaxonomyProperties, USER_LOCATION_ELEMENT_ID, USER_LOCATION_LAYER_NAME, type UnitFeature, type UnitFeaturePopulated, type UnitGeometry, type UnitProperties, VENUE_EVENTS, type VenueClientOptions, type VenueDataClient, type VenueFeature, type VenueFeaturePopulated, type VenueGeometry, type VenueProperties, createPolygonFromLineString, createSpriteMaterialByLabelSymbol, createStyledUIMarkerElement, defaultFeatureQueryOptionsMap, fetchFeature, getBearingBetweenPoints, getCenterFromGeometry, getDataClient, getExtrudeConfigByFeature, getFeatureByLocationId, getLocationByAmenity, getLocationByFeature, getLocationByOccupant, getLocationIdByFeature, getOrdinalByLocationId, getRelatedLocationIdsByFeature, getRelatedLocationsByAmenity, getRelatedLocationsByFeature, getRelatedLocationsByOccupant, getSuitablyValueBetweenBearings, isClickableFeature, safeFetchFeature, styledFeatureGenerator };
1127
+ export { ALL_FEATURE_TYPES, ALWAYS_VISIBLE_FEATURE_TYPES, type AmenityFeature, type AmenityFeaturePopulated, type AmenityGeometry, type AmenityProperties, type AnchorFeature, type AnchorFeaturePopulated, type AnchorGeometry, type AnchorProperties, BASE_LAYER_NAME, DEFAULT_BASE_URL, DEFAULT_HIGHLIGHT_OPTIONS, DEFAULT_LOCALE, DEFAULT_SET_HIGHLIGHT_2DELEMENT_IDS_OPTIONS, DESTINATION_MARKER_ID, type DetailFeature, type DetailGeometry, type DetailProperties, type ElementFeature, type ElementGeometry, type ElementProperties, type EventFeature, type EventGeometry, type EventProperties, type FeaturePopulatedResponseMap, type FeatureQueryOptions, type FeatureResponseMap, type FeatureType, type FilterParams, type FindParams, type FixtureFeature, type FixtureFeaturePopulated, type FixtureGeometry, type FixtureProperties, GEOJSON_FEATURE_TYPES, HIGHLIGHT_LAYER_NAME, IMDF_FEATURE_TYPES, type Id, type ImdfFeature, IndoorMap, type InternalFilterByType, type InternalFindById, type KioskFeature, type KioskFeaturePopulated, type KioskGeometry, type KioskProperties, LAST_USER_LOCATION_ELEMENT_ID_PREFIX, LAYERS, LAYER_FEATURE_TYPE_OBJ, LAYER_OPTIONS, LOCALE_SYMBOL_KEY, type LabelFeature, type LabelGeometry, type LabelProperties, type LevelFeature, type LevelFeaturePopulated, type LevelGeometry, type LevelProperties, MARKER_LAYER_NAME, type Media, type MediaFile, type Model3d, NONIMDF_FEATURE_TYPES, ORIGIN_MARKER_ID, type OccupantFeature, type OccupantFeaturePopulated, type OccupantGeometry, type OccupantProperties, type OpeningFeature, type OpeningFeaturePopulated, type OpeningGeometry, type OpeningProperties, POI_MARKER_LAYER_NAME, type Page, type PolygonalFeature, type PopulatableFeatureType, type PopulatedParams, type PrivilegeFeature, type PrivilegeGeometry, type PrivilegeProperties, type PromotionFeature, type PromotionProperties, type RelationshipFeature, type RelationshipGeometry, type RelationshipProperties, type SectionFeature, type SectionFeaturePopulated, type SectionGeometry, type SectionProperties, type SponsoredContentFeature, type SponsoredContentLegacyType, type SponsoredContentPlacementType, type SponsoredContentStrapiV4ApiResponse, type TaxonomyFeature, type TaxonomyFeaturePopulated, type TaxonomyGeometry, type TaxonomyProperties, USER_LOCATION_ELEMENT_ID, USER_LOCATION_LAYER_NAME, type UnitFeature, type UnitFeaturePopulated, type UnitGeometry, type UnitProperties, VENUE_EVENTS, type VenueClientOptions, type VenueDataClient, type VenueFeature, type VenueFeaturePopulated, type VenueGeometry, type VenueProperties, createPolygonFromLineString, createSpriteMaterialByLabelSymbol, createStyledUIMarkerElement, defaultFeatureQueryOptionsMap, fetchDeliveryApi, fetchPreviewApi, getBearingBetweenPoints, getCenterFromGeometry, getDataClient, getExtrudeConfigByFeature, getFeatureByLocationId, getLocationByAmenity, getLocationByFeature, getLocationByOccupant, getLocationIdByFeature, getOrdinalByLocationId, getRelatedLocationIdsByFeature, getRelatedLocationsByAmenity, getRelatedLocationsByFeature, getRelatedLocationsByOccupant, getSuitablyValueBetweenBearings, isClickableFeature, safeFetchFeature, styledFeatureGenerator };
package/dist/index.d.ts CHANGED
@@ -3,15 +3,14 @@ export { QueryObserver } from '@tanstack/query-core';
3
3
  import * as geojson from 'geojson';
4
4
  import { Position, Geometry, GeoJsonProperties, Feature, Point, Polygon, MultiPolygon, LineString, GeometryCollection } from 'geojson';
5
5
  import * as maptalks_dist_core_Class from 'maptalks/dist/core/Class';
6
- import * as maptalks_dist_geo_Extent from 'maptalks/dist/geo/Extent';
7
- import { Map, Coordinate as Coordinate$1, Extent } from 'maptalks-gl';
6
+ import { Map } from 'maptalks-gl';
8
7
  import { BaseObject, ThreeLayer } from 'maptalks.three';
9
- import * as maptalks from 'maptalks';
10
- import { Coordinate, Marker, ui, LineString as LineString$1, Polygon as Polygon$1, MultiPolygon as MultiPolygon$1, MultiLineString } from 'maptalks';
11
8
  import { ExtrudePolygonOptionType } from 'maptalks.three/dist/type';
12
9
  import { PolygonOptionsType } from 'maptalks/dist/geometry/Polygon';
13
10
  import { LineStringOptionsType } from 'maptalks/dist/geometry/LineString';
14
- import { MapViewType, MapAnimationOptionsType } from 'maptalks/dist/map/Map';
11
+ import * as maptalks from 'maptalks';
12
+ import { Extent, Marker, ui, LineString as LineString$1, Polygon as Polygon$1, MultiPolygon as MultiPolygon$1, MultiLineString } from 'maptalks';
13
+ import { MapViewType, MapAnimationOptionsType, MapPaddingType } from 'maptalks/dist/map/Map';
15
14
  import { SpriteMaterial, AmbientLight, DirectionalLight } from 'three';
16
15
 
17
16
  type Id = string;
@@ -658,8 +657,10 @@ type Filter = EqFilter | InFilter;
658
657
  type Filters = Record<string, Filter>;
659
658
 
660
659
  interface VenueClientOptions {
660
+ mode?: "delivery" | "preview";
661
661
  projectId: string;
662
- apiKey: string;
662
+ apiKey?: string;
663
+ previewToken?: string;
663
664
  baseUrl?: string;
664
665
  queryClient?: QueryClient;
665
666
  }
@@ -701,8 +702,15 @@ declare const GEOJSON_FEATURE_TYPES: FeatureType[];
701
702
  declare const ALL_FEATURE_TYPES: FeatureType[];
702
703
  declare const defaultFeatureQueryOptionsMap: Record<FeatureType, FeatureQueryOptions>;
703
704
 
704
- declare function fetchFeature<T extends FeatureType = FeatureType>(projectId: string, apiKey: string, featureType: FeatureType, baseUrl?: string): Promise<FeatureResponseMap[T][]>;
705
- declare const safeFetchFeature: <T extends FeatureType = FeatureType>(projectId: string, apiKey: string, featureType: FeatureType, baseUrl?: string) => Promise<FeatureResponseMap[T][]>;
705
+ declare function fetchDeliveryApi<T extends FeatureType = FeatureType>(projectId: string, apiKey: string, featureType: FeatureType, baseUrl?: string): Promise<FeatureResponseMap[T][]>;
706
+ declare function fetchPreviewApi<T extends FeatureType = FeatureType>(projectId: string, previewToken: string, featureType: FeatureType, baseUrl?: string): Promise<FeatureResponseMap[T][]>;
707
+ declare const safeFetchFeature: <T extends FeatureType = FeatureType>(featureType: FeatureType, params: {
708
+ mode: "delivery" | "preview";
709
+ projectId: string;
710
+ apiKey: string;
711
+ previewToken?: string;
712
+ baseUrl: string;
713
+ }) => Promise<FeatureResponseMap[T][]>;
706
714
 
707
715
  declare const getDataClient: (options: VenueClientOptions) => VenueDataClient;
708
716
 
@@ -764,22 +772,36 @@ declare class RendererManager extends EventTarget {
764
772
  clearMarkers(): void;
765
773
  }
766
774
 
775
+ interface CameraManagerOptions {
776
+ defaultView?: MapViewType;
777
+ }
778
+ declare class CameraManager {
779
+ map: Map;
780
+ constructor(map: Map, options?: CameraManagerOptions);
781
+ /** Public methods */
782
+ getView: () => MapViewType;
783
+ setView: (value: MapViewType) => void;
784
+ animateTo: (view: MapViewType, options?: MapAnimationOptionsType, step?: (frame: any) => void) => void;
785
+ setMaxExtent(extent: Extent): Map;
786
+ getFeatureExtent: (feature: any, scaleFactor?: number) => Extent;
787
+ getExtentZoom: (extent: Extent, options?: {
788
+ isFraction?: boolean;
789
+ padding?: MapPaddingType;
790
+ }) => number;
791
+ set maxZoom(value: number);
792
+ set minZoom(value: number);
793
+ }
794
+
767
795
  interface IndoorMapOptions {
768
796
  onMapReady?: () => void;
769
797
  onMapLoading?: () => void;
770
798
  centerCross?: boolean;
771
799
  dataClient: VenueDataClient;
772
- camera?: {
773
- defaultCenter?: [number, number];
774
- defaultZoom?: number;
775
- defaultBearing?: number;
776
- defaultPitch?: number;
777
- };
800
+ camera?: CameraManagerOptions;
778
801
  renderer?: RendererManagerOptions;
779
802
  pixelRatio?: number;
780
803
  locale?: string;
781
804
  }
782
- type AmenityHighlightMode = "2DMarker";
783
805
  type SymbolSet = string | null;
784
806
  interface IHighlightOptions {
785
807
  symbolSet?: SymbolSet;
@@ -792,94 +814,7 @@ interface ISetHighlightElementIdsOptions {
792
814
  highlight3DOptions?: IHighlightOptions;
793
815
  highlight2DOptions?: ISetHighlight2DElementIdsOptions;
794
816
  }
795
- interface IMapExtrudeConfig {
796
- height: number;
797
- category: string;
798
- }
799
- interface ILightConfig {
800
- ambientLight: IMapLightConfig;
801
- directionalLight: IMapLightConfig;
802
- }
803
- interface IMapLightConfig {
804
- color: string;
805
- position?: number[];
806
- intensity: number;
807
- }
808
- interface IExtrudeConfig {
809
- kiosk: IMapExtrudeConfig[];
810
- unit: IMapExtrudeConfig[];
811
- }
812
- interface IShortestPathConfig {
813
- resolution: number;
814
- }
815
- interface IAllVenuesViewConfig {
816
- zoom?: number;
817
- pitch?: number;
818
- center?: Coordinate;
819
- bearing?: number;
820
- }
821
- interface IMapAnimation {
822
- [k: string]: {
823
- enable?: boolean;
824
- speed?: number;
825
- };
826
- }
827
- interface IUnitDistanceModifier {
828
- [k: string]: number;
829
- }
830
- type IGraphOptions = {
831
- baseDistance?: number;
832
- multiplier?: number;
833
- };
834
- type IVerticalGraphOptions = IGraphOptions & {
835
- scaleDistanceByLevel?: boolean;
836
- };
837
- interface IGraphFeatureOptions {
838
- traversal?: IUnitDistanceModifier;
839
- escalator?: IGraphOptions;
840
- ramp?: IGraphOptions;
841
- elevator?: IGraphOptions;
842
- stairs?: IVerticalGraphOptions;
843
- }
844
- interface IMapConfig {
845
- amenity_highlight_mode?: AmenityHighlightMode;
846
- default_zoom?: number;
847
- max_zoom?: number;
848
- min_zoom?: number;
849
- kiosk_pixel_ratio?: number;
850
- mobile_pixel_ratio?: number;
851
- extrude?: IExtrudeConfig;
852
- light?: ILightConfig;
853
- shortest_path?: IShortestPathConfig;
854
- text_marker_type?: "marker" | "ui-marker";
855
- extent_features_scale_factor?: number;
856
- extent_scale_map_view_factor?: number;
857
- all_venues_view?: IAllVenuesViewConfig;
858
- animations?: IMapAnimation[];
859
- prepare_steps?: IGraphFeatureOptions;
860
- }
861
-
862
- interface CameraManagerOptions {
863
- defaultView?: MapViewType;
864
- }
865
- declare class CameraManager {
866
- #private;
867
- map: Map;
868
- constructor(map: Map, options?: CameraManagerOptions);
869
- /** Public methods */
870
- getView: () => MapViewType;
871
- getZoom: () => number;
872
- setView: (value: MapViewType) => void;
873
- flyTo: (center: any, options?: MapAnimationOptionsType & MapViewType) => void;
874
- flyToAndZoomIn: (centerPoint: any, options?: MapAnimationOptionsType & MapViewType) => void;
875
- }
876
817
 
877
- type MapPaddingType = {
878
- paddingLeft: number;
879
- paddingRight: number;
880
- paddingTop: number;
881
- paddingBottom: number;
882
- };
883
818
  declare class IndoorMap extends EventTarget {
884
819
  #private;
885
820
  map: Map | null;
@@ -891,10 +826,10 @@ declare class IndoorMap extends EventTarget {
891
826
  onMapLoading: () => void;
892
827
  constructor(elementId: any, options: IndoorMapOptions);
893
828
  set dataClient(value: any);
894
- on(eventName: string, handler: any): void;
895
829
  /**
896
830
  * Events
897
831
  */
832
+ on(eventName: string, handler: any): void;
898
833
  handleMapClick: ({ coordinate }: {
899
834
  coordinate: any;
900
835
  }) => void;
@@ -910,34 +845,21 @@ declare class IndoorMap extends EventTarget {
910
845
  set mapTheme(value: any);
911
846
  get venues(): any[];
912
847
  set detectVenueInView(value: any);
913
- get ordinals(): any[];
914
- set ordinals(value: any[]);
915
848
  set billboards(value: any);
916
- set mapConfig(value: IMapConfig);
917
849
  set mapDecorations(value: any);
918
- set maxZoom(value: number);
919
- set minZoom(value: number);
920
850
  set groundLabels(value: any);
921
851
  set pixelRatio(value: number);
922
852
  set onClickElement(func: any);
923
853
  set locale(value: string);
924
854
  handleClickElement: (e: any) => void;
925
- setCenter(center: Coordinate$1, padding?: MapPaddingType): void;
926
855
  /**
927
856
  * Change Level & animate to path / geometry / view / etc.
928
857
  * ================================== */
929
858
  changeLevelByOrdinal(ordinal: null | number | number[]): void;
930
- getFeatureExtent: (feature: any, scaleFactor?: number) => Extent;
931
- getExtentCenter: (extent: Extent) => maptalks_dist_geo_Extent.PositionType;
932
- getExtentZoom: (extent: Extent, options?: {
933
- isFraction?: boolean;
934
- padding?: MapPaddingType;
935
- }) => number;
936
859
  findVenueInView: () => {
937
860
  venueId: string;
938
861
  distance: number;
939
862
  };
940
- flyTo: (center: any, options: any) => void;
941
863
  getLineStringBearing: (feature: any) => number;
942
864
  addAnimations(animation: {
943
865
  id: string;
@@ -1005,15 +927,6 @@ declare class IndoorMap extends EventTarget {
1005
927
  /**
1006
928
  * render (frame)
1007
929
  */
1008
- getTargetViewCenter: (targetView: any, options?: {
1009
- offset: {
1010
- top: number;
1011
- left: number;
1012
- right: number;
1013
- bottom: number;
1014
- };
1015
- }) => Coordinate$1;
1016
- setMaxExtent(extent: Extent): Map;
1017
930
  render(): void;
1018
931
  }
1019
932
 
@@ -1211,4 +1124,4 @@ declare const VENUE_EVENTS: {
1211
1124
  VENUE_MOVEINTOVIEW: string;
1212
1125
  };
1213
1126
 
1214
- export { ALL_FEATURE_TYPES, ALWAYS_VISIBLE_FEATURE_TYPES, type AmenityFeature, type AmenityFeaturePopulated, type AmenityGeometry, type AmenityProperties, type AnchorFeature, type AnchorFeaturePopulated, type AnchorGeometry, type AnchorProperties, BASE_LAYER_NAME, DEFAULT_BASE_URL, DEFAULT_HIGHLIGHT_OPTIONS, DEFAULT_LOCALE, DEFAULT_SET_HIGHLIGHT_2DELEMENT_IDS_OPTIONS, DESTINATION_MARKER_ID, type DetailFeature, type DetailGeometry, type DetailProperties, type ElementFeature, type ElementGeometry, type ElementProperties, type EventFeature, type EventGeometry, type EventProperties, type FeaturePopulatedResponseMap, type FeatureQueryOptions, type FeatureResponseMap, type FeatureType, type FilterParams, type FindParams, type FixtureFeature, type FixtureFeaturePopulated, type FixtureGeometry, type FixtureProperties, GEOJSON_FEATURE_TYPES, HIGHLIGHT_LAYER_NAME, IMDF_FEATURE_TYPES, type Id, type ImdfFeature, IndoorMap, type InternalFilterByType, type InternalFindById, type KioskFeature, type KioskFeaturePopulated, type KioskGeometry, type KioskProperties, LAST_USER_LOCATION_ELEMENT_ID_PREFIX, LAYERS, LAYER_FEATURE_TYPE_OBJ, LAYER_OPTIONS, LOCALE_SYMBOL_KEY, type LabelFeature, type LabelGeometry, type LabelProperties, type LevelFeature, type LevelFeaturePopulated, type LevelGeometry, type LevelProperties, MARKER_LAYER_NAME, type Media, type MediaFile, type Model3d, NONIMDF_FEATURE_TYPES, ORIGIN_MARKER_ID, type OccupantFeature, type OccupantFeaturePopulated, type OccupantGeometry, type OccupantProperties, type OpeningFeature, type OpeningFeaturePopulated, type OpeningGeometry, type OpeningProperties, POI_MARKER_LAYER_NAME, type Page, type PolygonalFeature, type PopulatableFeatureType, type PopulatedParams, type PrivilegeFeature, type PrivilegeGeometry, type PrivilegeProperties, type PromotionFeature, type PromotionProperties, type RelationshipFeature, type RelationshipGeometry, type RelationshipProperties, type SectionFeature, type SectionFeaturePopulated, type SectionGeometry, type SectionProperties, type SponsoredContentFeature, type SponsoredContentLegacyType, type SponsoredContentPlacementType, type SponsoredContentStrapiV4ApiResponse, type TaxonomyFeature, type TaxonomyFeaturePopulated, type TaxonomyGeometry, type TaxonomyProperties, USER_LOCATION_ELEMENT_ID, USER_LOCATION_LAYER_NAME, type UnitFeature, type UnitFeaturePopulated, type UnitGeometry, type UnitProperties, VENUE_EVENTS, type VenueClientOptions, type VenueDataClient, type VenueFeature, type VenueFeaturePopulated, type VenueGeometry, type VenueProperties, createPolygonFromLineString, createSpriteMaterialByLabelSymbol, createStyledUIMarkerElement, defaultFeatureQueryOptionsMap, fetchFeature, getBearingBetweenPoints, getCenterFromGeometry, getDataClient, getExtrudeConfigByFeature, getFeatureByLocationId, getLocationByAmenity, getLocationByFeature, getLocationByOccupant, getLocationIdByFeature, getOrdinalByLocationId, getRelatedLocationIdsByFeature, getRelatedLocationsByAmenity, getRelatedLocationsByFeature, getRelatedLocationsByOccupant, getSuitablyValueBetweenBearings, isClickableFeature, safeFetchFeature, styledFeatureGenerator };
1127
+ export { ALL_FEATURE_TYPES, ALWAYS_VISIBLE_FEATURE_TYPES, type AmenityFeature, type AmenityFeaturePopulated, type AmenityGeometry, type AmenityProperties, type AnchorFeature, type AnchorFeaturePopulated, type AnchorGeometry, type AnchorProperties, BASE_LAYER_NAME, DEFAULT_BASE_URL, DEFAULT_HIGHLIGHT_OPTIONS, DEFAULT_LOCALE, DEFAULT_SET_HIGHLIGHT_2DELEMENT_IDS_OPTIONS, DESTINATION_MARKER_ID, type DetailFeature, type DetailGeometry, type DetailProperties, type ElementFeature, type ElementGeometry, type ElementProperties, type EventFeature, type EventGeometry, type EventProperties, type FeaturePopulatedResponseMap, type FeatureQueryOptions, type FeatureResponseMap, type FeatureType, type FilterParams, type FindParams, type FixtureFeature, type FixtureFeaturePopulated, type FixtureGeometry, type FixtureProperties, GEOJSON_FEATURE_TYPES, HIGHLIGHT_LAYER_NAME, IMDF_FEATURE_TYPES, type Id, type ImdfFeature, IndoorMap, type InternalFilterByType, type InternalFindById, type KioskFeature, type KioskFeaturePopulated, type KioskGeometry, type KioskProperties, LAST_USER_LOCATION_ELEMENT_ID_PREFIX, LAYERS, LAYER_FEATURE_TYPE_OBJ, LAYER_OPTIONS, LOCALE_SYMBOL_KEY, type LabelFeature, type LabelGeometry, type LabelProperties, type LevelFeature, type LevelFeaturePopulated, type LevelGeometry, type LevelProperties, MARKER_LAYER_NAME, type Media, type MediaFile, type Model3d, NONIMDF_FEATURE_TYPES, ORIGIN_MARKER_ID, type OccupantFeature, type OccupantFeaturePopulated, type OccupantGeometry, type OccupantProperties, type OpeningFeature, type OpeningFeaturePopulated, type OpeningGeometry, type OpeningProperties, POI_MARKER_LAYER_NAME, type Page, type PolygonalFeature, type PopulatableFeatureType, type PopulatedParams, type PrivilegeFeature, type PrivilegeGeometry, type PrivilegeProperties, type PromotionFeature, type PromotionProperties, type RelationshipFeature, type RelationshipGeometry, type RelationshipProperties, type SectionFeature, type SectionFeaturePopulated, type SectionGeometry, type SectionProperties, type SponsoredContentFeature, type SponsoredContentLegacyType, type SponsoredContentPlacementType, type SponsoredContentStrapiV4ApiResponse, type TaxonomyFeature, type TaxonomyFeaturePopulated, type TaxonomyGeometry, type TaxonomyProperties, USER_LOCATION_ELEMENT_ID, USER_LOCATION_LAYER_NAME, type UnitFeature, type UnitFeaturePopulated, type UnitGeometry, type UnitProperties, VENUE_EVENTS, type VenueClientOptions, type VenueDataClient, type VenueFeature, type VenueFeaturePopulated, type VenueGeometry, type VenueProperties, createPolygonFromLineString, createSpriteMaterialByLabelSymbol, createStyledUIMarkerElement, defaultFeatureQueryOptionsMap, fetchDeliveryApi, fetchPreviewApi, getBearingBetweenPoints, getCenterFromGeometry, getDataClient, getExtrudeConfigByFeature, getFeatureByLocationId, getLocationByAmenity, getLocationByFeature, getLocationByOccupant, getLocationIdByFeature, getOrdinalByLocationId, getRelatedLocationIdsByFeature, getRelatedLocationsByAmenity, getRelatedLocationsByFeature, getRelatedLocationsByOccupant, getSuitablyValueBetweenBearings, isClickableFeature, safeFetchFeature, styledFeatureGenerator };