mahal_map 2.2.2 → 2.2.3
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/README.md +1772 -1754
- package/dist/index.d.mts +48 -23
- package/dist/index.d.ts +48 -23
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/dist/mahal_map.sdk.js +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -469,31 +469,52 @@ interface ISearchByLocationParam {
|
|
|
469
469
|
token: string;
|
|
470
470
|
type?: string;
|
|
471
471
|
}
|
|
472
|
+
/**
|
|
473
|
+
* Тип объекта в ответе геокодера. Регистр у сервиса плавает: обратный геокодинг отдаёт
|
|
474
|
+
* `"Address"`, прямой — `"address"`. Сравнивайте через `type.toLowerCase()`.
|
|
475
|
+
*/
|
|
476
|
+
type SearchResultType = "poi" | "locality" | "address" | "Address" | (string & {});
|
|
477
|
+
/** Адрес объекта. Любое поле может отсутствовать — сервис отдаёт только то, что знает. */
|
|
478
|
+
interface ISearchDetailAddress {
|
|
479
|
+
/** Область: `вилоят`, `Суғд`. */
|
|
480
|
+
subject_type?: string;
|
|
481
|
+
subject_name?: string;
|
|
482
|
+
/** Город: `шаҳр`, `Хуҷанд`. Так город приходит в обратном геокодинге. */
|
|
483
|
+
city_type?: string;
|
|
484
|
+
city?: string;
|
|
485
|
+
/** Район / ноҳия. */
|
|
486
|
+
region_type?: string;
|
|
487
|
+
region?: string;
|
|
488
|
+
/** Населённый пункт — встречается в ответах вместо `city`. */
|
|
489
|
+
settlement_type?: string;
|
|
490
|
+
settlement?: string;
|
|
491
|
+
/** Посёлок / махалля. */
|
|
492
|
+
village_type?: string;
|
|
493
|
+
village?: string;
|
|
494
|
+
/** Улица: `кӯчаи`, `Камоли Хуҷандӣ`. */
|
|
495
|
+
street_type?: string;
|
|
496
|
+
street_name?: string;
|
|
497
|
+
/** Номер дома. У многих POI его нет. */
|
|
498
|
+
number?: string;
|
|
499
|
+
}
|
|
500
|
+
interface ISearchDetailInfo {
|
|
501
|
+
name?: string;
|
|
502
|
+
short_name?: string;
|
|
503
|
+
categories?: string;
|
|
504
|
+
translate_ru?: string;
|
|
505
|
+
description?: string;
|
|
506
|
+
phone?: string;
|
|
507
|
+
website?: string;
|
|
508
|
+
}
|
|
472
509
|
interface ISearchResponse {
|
|
473
510
|
latitude: number;
|
|
474
511
|
longitude: number;
|
|
475
|
-
type:
|
|
512
|
+
type: SearchResultType;
|
|
513
|
+
/** Расстояние от точки запроса в метрах (обратный геокодинг). */
|
|
476
514
|
distance: number | null;
|
|
477
|
-
detailInfo:
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
categories?: string;
|
|
481
|
-
translate_ru?: string;
|
|
482
|
-
description?: string;
|
|
483
|
-
} | null;
|
|
484
|
-
detailAddress: {
|
|
485
|
-
subject_type?: string;
|
|
486
|
-
subject_name?: string;
|
|
487
|
-
region_type?: string;
|
|
488
|
-
region?: string;
|
|
489
|
-
settlement_type?: string;
|
|
490
|
-
settlement?: string;
|
|
491
|
-
village_type?: string;
|
|
492
|
-
village?: string;
|
|
493
|
-
street_type?: string;
|
|
494
|
-
street_name?: string;
|
|
495
|
-
number: string;
|
|
496
|
-
} | [];
|
|
515
|
+
detailInfo: ISearchDetailInfo | null;
|
|
516
|
+
/** Пустой массив — адрес неизвестен. */
|
|
517
|
+
detailAddress: ISearchDetailAddress | [];
|
|
497
518
|
}
|
|
498
519
|
interface ICheckJSApiParam {
|
|
499
520
|
token: string;
|
|
@@ -848,7 +869,11 @@ declare function Router(param: number[][], typeData: string, token: string): Pro
|
|
|
848
869
|
|
|
849
870
|
declare function Search(param: string, token: string, additionalParam?: IAdditionalParamType): Promise<ISearchResponse[]>;
|
|
850
871
|
declare function SearchPoi(param: string, token: string, additionalParam?: IAdditionalParamType): Promise<ISearchResponse[]>;
|
|
851
|
-
|
|
872
|
+
/**
|
|
873
|
+
* Обратный геокодинг. В отличие от Search/SearchPoi возвращает тело ответа целиком:
|
|
874
|
+
* `{ success, data: ISearchResponse[], message }` — объекты рядом с точкой, по `distance`.
|
|
875
|
+
*/
|
|
876
|
+
declare function SearchByLocation(params: ISearchByLocationParam): Promise<IResponse<ISearchResponse[]>>;
|
|
852
877
|
declare function CheckJSApi(token: string): Promise<ICheckJSApiResponse>;
|
|
853
878
|
|
|
854
879
|
declare const index$2_CheckJSApi: typeof CheckJSApi;
|
|
@@ -1105,4 +1130,4 @@ declare namespace index {
|
|
|
1105
1130
|
export { index_checkCoordinates as checkCoordinates, index_debounce as debounce, index_geojsonPolyline as geojsonPolyline, index_geometryPolyline as geometryPolyline, index_trimValue as trimValue };
|
|
1106
1131
|
}
|
|
1107
1132
|
|
|
1108
|
-
export { CheckJSApi, type IAdditionalParamType, type ICheckJSApiParam, type ICheckJSApiResponse, type IMahalMapOptions, type IMapMarker, type IMaps3DBuildingClickInfo, type IMaps3DBuildingsController, type IMaps3DBuildingsOptions, type IMaps3DClosuresOptions, type IMaps3DDiagnostics, type IMaps3DHoverStyle, type IMaps3DIndoorOptions, type IMaps3DLayer, type IMaps3DLayerOptions, type IMaps3DLayerParams, type IMaps3DLayerState, type IMaps3DMapOptionsInput, type IMaps3DMapOptionsResult, type IMaps3DObjectsLightOptions, type IMaps3DParkingHoverStyle, type IMaps3DParkingInfo, type IMaps3DPlacesOptions, type IMaps3DRoadHit, type IMaps3DSelectionStyle, type IMaps3DTrafficOptions, type IMaps3DTransformRequestOptions, type IResponse, type IRoute, type ISearchByLocationParam, type ISearchParam, type ISearchResponse, MahalMap, MahalMapDefaultMarker, type MahalMapDefaultMarkerProps, type MapEngine, type MapLanguage, type MapStyleFamily, type Maps3DBuildingDetail, type Maps3DCtor, type Maps3DLayerId, type Maps3DParkingSubtype, type Maps3DTerrainMode, type Maps3DThemeName, type Maps3DTransformRequest, type MeasureIcons, type MeasureLabels, type MeasureMode, type MeasurePoint, type MeasureShape, type MeasureState, type MeasureStyleOptions, MeasureTool, type MeasureToolOptions, Router, Search, SearchByLocation, SearchPoi, type Theme, index$2 as keyUtils, index$1 as measureUtils, index as utils };
|
|
1133
|
+
export { CheckJSApi, type IAdditionalParamType, type ICheckJSApiParam, type ICheckJSApiResponse, type IMahalMapOptions, type IMapMarker, type IMaps3DBuildingClickInfo, type IMaps3DBuildingsController, type IMaps3DBuildingsOptions, type IMaps3DClosuresOptions, type IMaps3DDiagnostics, type IMaps3DHoverStyle, type IMaps3DIndoorOptions, type IMaps3DLayer, type IMaps3DLayerOptions, type IMaps3DLayerParams, type IMaps3DLayerState, type IMaps3DMapOptionsInput, type IMaps3DMapOptionsResult, type IMaps3DObjectsLightOptions, type IMaps3DParkingHoverStyle, type IMaps3DParkingInfo, type IMaps3DPlacesOptions, type IMaps3DRoadHit, type IMaps3DSelectionStyle, type IMaps3DTrafficOptions, type IMaps3DTransformRequestOptions, type IResponse, type IRoute, type ISearchByLocationParam, type ISearchDetailAddress, type ISearchDetailInfo, type ISearchParam, type ISearchResponse, MahalMap, MahalMapDefaultMarker, type MahalMapDefaultMarkerProps, type MapEngine, type MapLanguage, type MapStyleFamily, type Maps3DBuildingDetail, type Maps3DCtor, type Maps3DLayerId, type Maps3DParkingSubtype, type Maps3DTerrainMode, type Maps3DThemeName, type Maps3DTransformRequest, type MeasureIcons, type MeasureLabels, type MeasureMode, type MeasurePoint, type MeasureShape, type MeasureState, type MeasureStyleOptions, MeasureTool, type MeasureToolOptions, Router, Search, SearchByLocation, SearchPoi, type SearchResultType, type Theme, index$2 as keyUtils, index$1 as measureUtils, index as utils };
|
package/dist/index.d.ts
CHANGED
|
@@ -469,31 +469,52 @@ interface ISearchByLocationParam {
|
|
|
469
469
|
token: string;
|
|
470
470
|
type?: string;
|
|
471
471
|
}
|
|
472
|
+
/**
|
|
473
|
+
* Тип объекта в ответе геокодера. Регистр у сервиса плавает: обратный геокодинг отдаёт
|
|
474
|
+
* `"Address"`, прямой — `"address"`. Сравнивайте через `type.toLowerCase()`.
|
|
475
|
+
*/
|
|
476
|
+
type SearchResultType = "poi" | "locality" | "address" | "Address" | (string & {});
|
|
477
|
+
/** Адрес объекта. Любое поле может отсутствовать — сервис отдаёт только то, что знает. */
|
|
478
|
+
interface ISearchDetailAddress {
|
|
479
|
+
/** Область: `вилоят`, `Суғд`. */
|
|
480
|
+
subject_type?: string;
|
|
481
|
+
subject_name?: string;
|
|
482
|
+
/** Город: `шаҳр`, `Хуҷанд`. Так город приходит в обратном геокодинге. */
|
|
483
|
+
city_type?: string;
|
|
484
|
+
city?: string;
|
|
485
|
+
/** Район / ноҳия. */
|
|
486
|
+
region_type?: string;
|
|
487
|
+
region?: string;
|
|
488
|
+
/** Населённый пункт — встречается в ответах вместо `city`. */
|
|
489
|
+
settlement_type?: string;
|
|
490
|
+
settlement?: string;
|
|
491
|
+
/** Посёлок / махалля. */
|
|
492
|
+
village_type?: string;
|
|
493
|
+
village?: string;
|
|
494
|
+
/** Улица: `кӯчаи`, `Камоли Хуҷандӣ`. */
|
|
495
|
+
street_type?: string;
|
|
496
|
+
street_name?: string;
|
|
497
|
+
/** Номер дома. У многих POI его нет. */
|
|
498
|
+
number?: string;
|
|
499
|
+
}
|
|
500
|
+
interface ISearchDetailInfo {
|
|
501
|
+
name?: string;
|
|
502
|
+
short_name?: string;
|
|
503
|
+
categories?: string;
|
|
504
|
+
translate_ru?: string;
|
|
505
|
+
description?: string;
|
|
506
|
+
phone?: string;
|
|
507
|
+
website?: string;
|
|
508
|
+
}
|
|
472
509
|
interface ISearchResponse {
|
|
473
510
|
latitude: number;
|
|
474
511
|
longitude: number;
|
|
475
|
-
type:
|
|
512
|
+
type: SearchResultType;
|
|
513
|
+
/** Расстояние от точки запроса в метрах (обратный геокодинг). */
|
|
476
514
|
distance: number | null;
|
|
477
|
-
detailInfo:
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
categories?: string;
|
|
481
|
-
translate_ru?: string;
|
|
482
|
-
description?: string;
|
|
483
|
-
} | null;
|
|
484
|
-
detailAddress: {
|
|
485
|
-
subject_type?: string;
|
|
486
|
-
subject_name?: string;
|
|
487
|
-
region_type?: string;
|
|
488
|
-
region?: string;
|
|
489
|
-
settlement_type?: string;
|
|
490
|
-
settlement?: string;
|
|
491
|
-
village_type?: string;
|
|
492
|
-
village?: string;
|
|
493
|
-
street_type?: string;
|
|
494
|
-
street_name?: string;
|
|
495
|
-
number: string;
|
|
496
|
-
} | [];
|
|
515
|
+
detailInfo: ISearchDetailInfo | null;
|
|
516
|
+
/** Пустой массив — адрес неизвестен. */
|
|
517
|
+
detailAddress: ISearchDetailAddress | [];
|
|
497
518
|
}
|
|
498
519
|
interface ICheckJSApiParam {
|
|
499
520
|
token: string;
|
|
@@ -848,7 +869,11 @@ declare function Router(param: number[][], typeData: string, token: string): Pro
|
|
|
848
869
|
|
|
849
870
|
declare function Search(param: string, token: string, additionalParam?: IAdditionalParamType): Promise<ISearchResponse[]>;
|
|
850
871
|
declare function SearchPoi(param: string, token: string, additionalParam?: IAdditionalParamType): Promise<ISearchResponse[]>;
|
|
851
|
-
|
|
872
|
+
/**
|
|
873
|
+
* Обратный геокодинг. В отличие от Search/SearchPoi возвращает тело ответа целиком:
|
|
874
|
+
* `{ success, data: ISearchResponse[], message }` — объекты рядом с точкой, по `distance`.
|
|
875
|
+
*/
|
|
876
|
+
declare function SearchByLocation(params: ISearchByLocationParam): Promise<IResponse<ISearchResponse[]>>;
|
|
852
877
|
declare function CheckJSApi(token: string): Promise<ICheckJSApiResponse>;
|
|
853
878
|
|
|
854
879
|
declare const index$2_CheckJSApi: typeof CheckJSApi;
|
|
@@ -1105,4 +1130,4 @@ declare namespace index {
|
|
|
1105
1130
|
export { index_checkCoordinates as checkCoordinates, index_debounce as debounce, index_geojsonPolyline as geojsonPolyline, index_geometryPolyline as geometryPolyline, index_trimValue as trimValue };
|
|
1106
1131
|
}
|
|
1107
1132
|
|
|
1108
|
-
export { CheckJSApi, type IAdditionalParamType, type ICheckJSApiParam, type ICheckJSApiResponse, type IMahalMapOptions, type IMapMarker, type IMaps3DBuildingClickInfo, type IMaps3DBuildingsController, type IMaps3DBuildingsOptions, type IMaps3DClosuresOptions, type IMaps3DDiagnostics, type IMaps3DHoverStyle, type IMaps3DIndoorOptions, type IMaps3DLayer, type IMaps3DLayerOptions, type IMaps3DLayerParams, type IMaps3DLayerState, type IMaps3DMapOptionsInput, type IMaps3DMapOptionsResult, type IMaps3DObjectsLightOptions, type IMaps3DParkingHoverStyle, type IMaps3DParkingInfo, type IMaps3DPlacesOptions, type IMaps3DRoadHit, type IMaps3DSelectionStyle, type IMaps3DTrafficOptions, type IMaps3DTransformRequestOptions, type IResponse, type IRoute, type ISearchByLocationParam, type ISearchParam, type ISearchResponse, MahalMap, MahalMapDefaultMarker, type MahalMapDefaultMarkerProps, type MapEngine, type MapLanguage, type MapStyleFamily, type Maps3DBuildingDetail, type Maps3DCtor, type Maps3DLayerId, type Maps3DParkingSubtype, type Maps3DTerrainMode, type Maps3DThemeName, type Maps3DTransformRequest, type MeasureIcons, type MeasureLabels, type MeasureMode, type MeasurePoint, type MeasureShape, type MeasureState, type MeasureStyleOptions, MeasureTool, type MeasureToolOptions, Router, Search, SearchByLocation, SearchPoi, type Theme, index$2 as keyUtils, index$1 as measureUtils, index as utils };
|
|
1133
|
+
export { CheckJSApi, type IAdditionalParamType, type ICheckJSApiParam, type ICheckJSApiResponse, type IMahalMapOptions, type IMapMarker, type IMaps3DBuildingClickInfo, type IMaps3DBuildingsController, type IMaps3DBuildingsOptions, type IMaps3DClosuresOptions, type IMaps3DDiagnostics, type IMaps3DHoverStyle, type IMaps3DIndoorOptions, type IMaps3DLayer, type IMaps3DLayerOptions, type IMaps3DLayerParams, type IMaps3DLayerState, type IMaps3DMapOptionsInput, type IMaps3DMapOptionsResult, type IMaps3DObjectsLightOptions, type IMaps3DParkingHoverStyle, type IMaps3DParkingInfo, type IMaps3DPlacesOptions, type IMaps3DRoadHit, type IMaps3DSelectionStyle, type IMaps3DTrafficOptions, type IMaps3DTransformRequestOptions, type IResponse, type IRoute, type ISearchByLocationParam, type ISearchDetailAddress, type ISearchDetailInfo, type ISearchParam, type ISearchResponse, MahalMap, MahalMapDefaultMarker, type MahalMapDefaultMarkerProps, type MapEngine, type MapLanguage, type MapStyleFamily, type Maps3DBuildingDetail, type Maps3DCtor, type Maps3DLayerId, type Maps3DParkingSubtype, type Maps3DTerrainMode, type Maps3DThemeName, type Maps3DTransformRequest, type MeasureIcons, type MeasureLabels, type MeasureMode, type MeasurePoint, type MeasureShape, type MeasureState, type MeasureStyleOptions, MeasureTool, type MeasureToolOptions, Router, Search, SearchByLocation, SearchPoi, type SearchResultType, type Theme, index$2 as keyUtils, index$1 as measureUtils, index as utils };
|