3
3
* @supermapgis/vue-iclient.(https://iclient.supermap.io)
4
4
* Copyright© 2000 - 2024 SuperMap Software Co.Ltd
5
5
* license: Apache-2.0
6
- * version: v12.0.0 -r
6
+ * version: v12.0.1 -r
7
7
*
8
8
*/
9
9
(function webpackUniversalModuleDefinition(root, factory) {
@@ -58443,6 +58443,9 @@ var _default = exports.default = {
58443
58443
realTime: '实时',
58444
58444
errorCoordinate: '坐标格式不正确'
58445
58445
},
58446
+ baseLayerSwitcher: {
58447
+ title: '底图切换'
58448
+ },
58446
58449
// layer
58447
58450
dataFlow: {
58448
58451
dataSubscriptionFailed: '数据订阅失败!'
@@ -88834,6 +88837,9 @@ var _default = exports.default = {
88834
88837
realTime: 'real-time',
88835
88838
errorCoordinate: 'invalid coordinate'
88836
88839
},
88840
+ baseLayerSwitcher: {
88841
+ title: 'Base Map Switch'
88842
+ },
88837
88843
// layer
88838
88844
dataFlow: {
88839
88845
dataSubscriptionFailed: 'Data subscription failed!'
@@ -128569,6 +128575,8 @@ var iPortalDataService = exports.default = /*#__PURE__*/function (_Events) {
128569
128575
featureResults = data.features;
128570
128576
128571
128577
if (data.numberMatched < maxFeatures) {
128578
+ featureResults = _this4._transformContentFeatures(featureResults);
128579
+
128572
128580
_this4.iserverService._getFeaturesSucceed({
128573
128581
result: {
128574
128582
features: {
@@ -128592,6 +128600,7 @@ var iPortalDataService = exports.default = /*#__PURE__*/function (_Events) {
128592
128600
results.forEach(function (result) {
128593
128601
featureResults = featureResults.concat(result.features);
128594
128602
});
128603
+ featureResults = _this4._transformContentFeatures(featureResults);
128595
128604
128596
128605
_this4.iserverService._getFeaturesSucceed({
128597
128606
result: {
@@ -134192,10 +134201,15 @@ var longlat_names = ['longlat', 'identity'];
134192
134201
// CONCATENATED MODULE: ./node_modules/proj4/lib/projections.js
134193
134202
134194
134203
134204
+ /** @type {Array<Partial<import('./Proj').default>>} */
134195
134205
var projs = [merc, longlat];
134196
134206
var projections_names = {};
134197
134207
var projStore = [];
134198
134208
134209
+ /**
134210
+ * @param {import('./Proj').default} proj
134211
+ * @param {number} i
134212
+ */
134199
134213
function add(proj, i) {
134200
134214
var len = projStore.length;
134201
134215
if (!proj.names) {
@@ -134209,12 +134223,15 @@ function add(proj, i) {
134209
134223
return this;
134210
134224
}
134211
134225
134212
-
134213
-
134214
134226
function getNormalizedProjName(n) {
134215
134227
return n.replace(/[-\(\)\s]+/g, ' ').trim().replace(/ /g, '_');
134216
134228
}
134217
134229
134230
+ /**
134231
+ * Get a projection by name.
134232
+ * @param {string} name
134233
+ * @returns {import('./Proj').default|false}
134234
+ */
134218
134235
function get(name) {
134219
134236
if (!name) {
134220
134237
return false;
@@ -135884,6 +135901,22 @@ function datum_datum(datumCode, datum_params, a, b, es, ep2, nadgrids) {
135884
135901
135885
135902
/** @typedef {{header: NadgridHeader, subgrids: Array<Subgrid>}} NADGrid */
135886
135903
135904
+ /**
135905
+ * @typedef {Object} GeoTIFF
135906
+ * @property {() => Promise<number>} getImageCount - Returns the number of images in the GeoTIFF.
135907
+ * @property {(index: number) => Promise<GeoTIFFImage>} getImage - Returns a GeoTIFFImage for the given index.
135908
+ */
135909
+
135910
+ /**
135911
+ * @typedef {Object} GeoTIFFImage
135912
+ * @property {() => number} getWidth - Returns the width of the image.
135913
+ * @property {() => number} getHeight - Returns the height of the image.
135914
+ * @property {() => number[]} getBoundingBox - Returns the bounding box as [minX, minY, maxX, maxY] in degrees.
135915
+ * @property {() => Promise<ArrayLike<ArrayLike<number>>>} readRasters - Returns the raster data as an array of bands.
135916
+ * @property {Object} fileDirectory - The file directory object containing metadata.
135917
+ * @property {Object} fileDirectory.ModelPixelScale - The pixel scale array [scaleX, scaleY, scaleZ] in degrees.
135918
+ */
135919
+
135887
135920
var loadedNadgrids = {};
135888
135921
135889
135922
/**
@@ -135896,14 +135929,14 @@ var loadedNadgrids = {};
135896
135929
/**
135897
135930
* @overload
135898
135931
* @param {string} key - The key to associate with the loaded grid.
135899
- * @param {import('geotiff'). GeoTIFF} data - The GeoTIFF instance to read the grid from.
135932
+ * @param {GeoTIFF} data - The GeoTIFF instance to read the grid from.
135900
135933
* @returns {{ready: Promise<NADGrid>}} - A promise that resolves to the loaded grid information.
135901
135934
*/
135902
135935
/**
135903
135936
* Load either a NTv2 file (.gsb) or a Geotiff (.tif) to a key that can be used in a proj string like +nadgrids=<key>. Pass the NTv2 file
135904
135937
* as an ArrayBuffer. Pass Geotiff as a GeoTIFF instance from the geotiff.js library.
135905
135938
* @param {string} key - The key to associate with the loaded grid.
135906
- * @param {ArrayBuffer|import('geotiff'). GeoTIFF} data The data to load, either an ArrayBuffer for NTv2 or a GeoTIFF instance.
135939
+ * @param {ArrayBuffer|GeoTIFF} data The data to load, either an ArrayBuffer for NTv2 or a GeoTIFF instance.
135907
135940
* @param {NTV2GridOptions} [options] Optional parameters.
135908
135941
* @returns {{ready: Promise<NADGrid>}|NADGrid} - A promise that resolves to the loaded grid information.
135909
135942
*/
@@ -135936,7 +135969,7 @@ function readNTV2Grid(key, data, options) {
135936
135969
135937
135970
/**
135938
135971
* @param {string} key The key to associate with the loaded grid.
135939
- * @param {import('geotiff'). GeoTIFF} tiff The GeoTIFF instance to read the grid from.
135972
+ * @param {GeoTIFF} tiff The GeoTIFF instance to read the grid from.
135940
135973
* @returns {Promise<NADGrid>} A promise that resolves to the loaded NAD grid information.
135941
135974
*/
135942
135975
async function readGeotiffGrid(key, tiff) {
@@ -136166,8 +136199,12 @@ function Projection(srsCode, callback) {
136166
136199
this.forward = null;
136167
136200
/** @type {<T extends import('./core').TemplateCoordinates>(coordinates: T, enforceAxis?: boolean) => T} */
136168
136201
this.inverse = null;
136202
+ /** @type {function(): void} */
136203
+ this.init = null;
136169
136204
/** @type {string} */
136170
136205
this.name;
136206
+ /** @type {Array<string>} */
136207
+ this.names = null;
136171
136208
/** @type {string} */
136172
136209
this.title;
136173
136210
callback = callback || function (error) {
@@ -142871,6 +142908,14 @@ var bonne_names = ['bonne', 'Bonne (Werner lat_1=90)'];
142871
142908
* @property {(mgrsString: string) => [number, number]} toPoint
142872
142909
*/
142873
142910
142911
+ /**
142912
+ * @typedef {import('./defs').ProjectionDefinition} ProjectionDefinition
142913
+ * @typedef {import('./core').TemplateCoordinates} TemplateCoordinates
142914
+ * @typedef {import('./core').InterfaceCoordinates} InterfaceCoordinates
142915
+ * @typedef {import('./core').Converter} Converter
142916
+ * @typedef {import('./Proj').DatumDefinition} DatumDefinition
142917
+ */
142918
+
142874
142919
/**
142875
142920
* @template {import('./core').TemplateCoordinates} T
142876
142921
* @type {core<T> & {defaultDatum: string, Proj: typeof Proj, WGS84: Proj, Point: typeof Point, toPoint: typeof common, defs: typeof defs, nadgrid: typeof nadgrid, transform: typeof transform, mgrs: Mgrs, version: string}}
@@ -164898,6 +164943,7 @@ exports.getProjection = getProjection;
164898
164943
exports.registerProjection = registerProjection;
164899
164944
exports.toEpsgCode = toEpsgCode;
164900
164945
exports.transformCoodinates = transformCoodinates;
164946
+ exports.transformCoordinate = transformCoordinate;
164901
164947
164902
164948
var _util = __webpack_require__("e7LN");
164903
164949
@@ -164977,6 +165023,31 @@ function transformCoodinates(_ref) {
164977
165023
}
164978
165024
}
164979
165025
165026
+ function transformCoordinate(fromProjection, toProjection, coordinates) {
165027
+ if (fromProjection === toProjection) return coordinates;
165028
+
165029
+ if (fromProjection === 'EPSG:4490' && toProjection === 'EPSG:4326' || fromProjection === 'EPSG:4326' && toProjection === 'EPSG:4490') {
165030
+ return coordinates;
165031
+ } // proj4缺陷,EPSG:4214的坐标x为180,转换后变成-179.
165032
+
165033
+
165034
+ if (fromProjection === 'EPSG:4214' && toProjection === 'EPSG:4326' && coordinates[0] === 180) {
165035
+ var newCoordinate = transformCoodinates({
165036
+ coordinates: coordinates,
165037
+ sourceProjection: fromProjection,
165038
+ destProjection: toProjection
165039
+ });
165040
+ newCoordinate[0] = 180;
165041
+ return newCoordinate;
165042
+ }
165043
+
165044
+ return transformCoodinates({
165045
+ coordinates: coordinates,
165046
+ sourceProjection: fromProjection,
165047
+ destProjection: toProjection
165048
+ });
165049
+ }
165050
+
164980
165051
/***/ }),
164981
165052
164982
165053
/***/ "ymVN":
0 commit comments