@datagouv/components-next 1.4.1-dev.1355.g54710cb7 → 1.4.1-dev.1358.g6d93ccfb
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/assets/json/vector.json +1336 -523
- package/dist/{MapContainer.client-UC7wQOBj.js → MapContainer.client-ZoJqauC6.js} +1 -1
- package/dist/Pmtiles.client-DBaMKSO-.js +41347 -0
- package/dist/assets/maplibre-gl-worker-C24SsKwV.js +10 -0
- package/dist/components-next.css +1 -1
- package/dist/components-next.js +9025 -8715
- package/dist/{france-Ub9ufuh4.js → france-DxksUv5K.js} +4 -4
- package/dist/{purify.es-CeeOHdER.js → purify.es-D6pPunDo.js} +250 -189
- package/dist/{src-C0XyM3eg.js → src-D_UE0st7.js} +33 -29
- package/package.json +4 -4
- package/src/components/ResourceAccordion/Pmtiles.client.vue +6 -2
- package/dist/Pmtiles.client-CTXTfoSy.js +0 -38397
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as __toCommonJS, i as __require, n as __esmMin, o as __toESM, r as __exportAll, t as __commonJSMin } from "./rolldown-runtime-CEFd7nDs.js";
|
|
2
|
-
import { t as
|
|
2
|
+
import { t as purify_default } from "./purify.es-D6pPunDo.js";
|
|
3
3
|
import { a as CLASS_SELECTABLE, n as CLASS_COLLAPSED, o as CLASS_UNSELECTABLE, r as CLASS_CONTROL, s as CLASS_UNSUPPORTED, t as Control, u as MapEventType_default } from "./Control-CeBb5PEu.js";
|
|
4
4
|
import { $ as buffer, $t as equals$1, A as angleBetween, B as clamp$1, Bt as getUid, C as getArea, Ct as getHeight, D as Projection$1, E as get$3, Et as getTopLeft, Ft as wrapAndSliceX, Gt as FALSE, H as lerp, Ht as unByKey, I as squaredDistance$1, It as wrapX$1, J as toFixed, Jt as memoizeOne, K as squaredDistance, Kt as TRUE, L as squaredDistanceToSegment, Lt as Relationship_default, M as distance, N as equals$2, Nt as scaleFromCenter, O as METERS_PER_UNIT, Ot as getWidth, Pt as subtractExtents, Q as boundingExtent, Qt as descending, R as wrapX, Rt as BaseObject, S as transformExtent, St as getForViewAndSize, U as modulo, V as floor, W as round, Wt as BaseEvent, Xt as ascending, Y as toRadians, Yt as toPromise, Z as applyTransform, Zt as binarySearch$1, _ as identityTransform, an as EventType_default, at as coordinateRelationship, b as toUserResolution, c as fromLonLat, cn as unlistenByKey, ct as createOrUpdateEmpty, d as fromUserResolution, dn as ObjectEventType_default, dt as equals, en as extend$1, et as clone$1, f as get$2, ft as extend$2, g as getUserProjection, h as getTransformFromProjections, ht as forEachCorner, it as containsXY, j as closestOnSegment, jt as isEmpty$1, kt as intersects, l as fromUserCoordinate, lt as createOrUpdateFromCoordinate, m as getTransform, n as addEquivalentProjections, nn as linearFindNearest, nt as containsCoordinate, on as listen, ot as createEmpty, pt as extendCoordinate, qt as VOID, r as addProjection, rn as reverseSubArray, rt as containsExtent, s as equivalent, sn as listenOnce, st as createOrUpdate, t as addCoordinateTransforms, tt as closestSquaredDistanceXY, u as fromUserExtent, un as isEmpty, ut as createOrUpdateFromFlatCoordinates, v as toUserCoordinate, vt as getBottomRight, w as getDistance, wt as getIntersection, x as transform$1, xt as getDifference, y as toUserExtent, yt as getCenter, z as ceil, zt as abstract } from "./proj-DM6GW1n3.js";
|
|
5
5
|
import { _ as removeChildren, a as ImageState_default, c as toSize, g as releaseCanvas, h as outerWidth, l as TileState_default, m as outerHeight, n as decode$1, t as ImageWrapper, u as createCanvasContext2D, w as WORKER_OFFSCREEN_CANVAS, y as replaceNode } from "./Image-CBQwYbQB.js";
|
|
@@ -16634,7 +16634,7 @@ function getGeometryType(Y, ee) {
|
|
|
16634
16634
|
return Y === 1 ? te = ee === 1 ? "Point" : "MultiPoint" : Y === 2 ? te = ee === 1 ? "LineString" : "MultiLineString" : Y === 3 && (te = "Polygon"), te;
|
|
16635
16635
|
}
|
|
16636
16636
|
//#endregion
|
|
16637
|
-
//#region ../node_modules
|
|
16637
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/reference/v8.mjs
|
|
16638
16638
|
var v8_default = {
|
|
16639
16639
|
$version: 8,
|
|
16640
16640
|
$root: {
|
|
@@ -19307,7 +19307,7 @@ var v8_default = {
|
|
|
19307
19307
|
"layout"
|
|
19308
19308
|
];
|
|
19309
19309
|
//#endregion
|
|
19310
|
-
//#region ../node_modules
|
|
19310
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/deref.mjs
|
|
19311
19311
|
function deref(Y, ee) {
|
|
19312
19312
|
let te = {};
|
|
19313
19313
|
for (let ee in Y) ee !== "ref" && (te[ee] = Y[ee]);
|
|
@@ -19323,7 +19323,7 @@ function derefLayers(Y) {
|
|
|
19323
19323
|
return Y;
|
|
19324
19324
|
}
|
|
19325
19325
|
//#endregion
|
|
19326
|
-
//#region ../node_modules
|
|
19326
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/types.mjs
|
|
19327
19327
|
var NullType = { kind: "null" }, NumberType = { kind: "number" }, StringType = { kind: "string" }, BooleanType = { kind: "boolean" }, ColorType = { kind: "color" }, ProjectionDefinitionType = { kind: "projectionDefinition" }, ObjectType = { kind: "object" }, ValueType = { kind: "value" }, ErrorType = { kind: "error" }, CollatorType = { kind: "collator" }, FormattedType = { kind: "formatted" }, PaddingType = { kind: "padding" }, ColorArrayType = { kind: "colorArray" }, NumberArrayType = { kind: "numberArray" }, ResolvedImageType = { kind: "resolvedImage" }, VariableAnchorOffsetCollectionType = { kind: "variableAnchorOffsetCollection" };
|
|
19328
19328
|
function array(Y, ee) {
|
|
19329
19329
|
return {
|
|
@@ -19375,7 +19375,7 @@ function verifyType(Y, ee) {
|
|
|
19375
19375
|
return Y.kind === "array" && ee.kind === "array" ? Y.itemType.kind === ee.itemType.kind && typeof Y.N == "number" : Y.kind === ee.kind;
|
|
19376
19376
|
}
|
|
19377
19377
|
//#endregion
|
|
19378
|
-
//#region ../node_modules
|
|
19378
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/types/color_spaces.mjs
|
|
19379
19379
|
var Xn = .96422, Yn = 1, Zn = .82521, t0 = 4 / 29, t1 = 6 / 29, t2 = 3 * t1 * t1, t3 = t1 * t1 * t1, deg2rad$1 = Math.PI / 180, rad2deg = 180 / Math.PI;
|
|
19380
19380
|
function constrainAngle(Y) {
|
|
19381
19381
|
return Y %= 360, Y < 0 && (Y += 360), Y;
|
|
@@ -19444,7 +19444,7 @@ function hslToRgb([Y, ee, te, ne]) {
|
|
|
19444
19444
|
];
|
|
19445
19445
|
}
|
|
19446
19446
|
//#endregion
|
|
19447
|
-
//#region ../node_modules
|
|
19447
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/util/get_own.mjs
|
|
19448
19448
|
var hasOwnProperty = Object.hasOwn || function(Y, ee) {
|
|
19449
19449
|
return Object.prototype.hasOwnProperty.call(Y, ee);
|
|
19450
19450
|
};
|
|
@@ -19452,7 +19452,7 @@ function getOwn(Y, ee) {
|
|
|
19452
19452
|
return hasOwnProperty(Y, ee) ? Y[ee] : void 0;
|
|
19453
19453
|
}
|
|
19454
19454
|
//#endregion
|
|
19455
|
-
//#region ../node_modules
|
|
19455
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/types/parse_css_color.mjs
|
|
19456
19456
|
function parseCssColor(Y) {
|
|
19457
19457
|
if (Y = Y.toLowerCase().trim(), Y === "transparent") return [
|
|
19458
19458
|
0,
|
|
@@ -20279,7 +20279,7 @@ var namedColors = {
|
|
|
20279
20279
|
]
|
|
20280
20280
|
};
|
|
20281
20281
|
//#endregion
|
|
20282
|
-
//#region ../node_modules
|
|
20282
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/util/interpolate-primitives.mjs
|
|
20283
20283
|
function interpolateNumber(Y, ee, te) {
|
|
20284
20284
|
return Y + te * (ee - Y);
|
|
20285
20285
|
}
|
|
@@ -20287,7 +20287,7 @@ function interpolateArray(Y, ee, te) {
|
|
|
20287
20287
|
return Y.map((Y, ne) => interpolateNumber(Y, ee[ne], te));
|
|
20288
20288
|
}
|
|
20289
20289
|
//#endregion
|
|
20290
|
-
//#region ../node_modules
|
|
20290
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/types/color.mjs
|
|
20291
20291
|
var Color = class Y {
|
|
20292
20292
|
constructor(Y, ee, te, ne = 1, xe = !0) {
|
|
20293
20293
|
this.r = Y, this.g = ee, this.b = te, this.a = ne, xe || (this.r *= ne, this.g *= ne, this.b *= ne, ne || this.overwriteGetter("rgb", [
|
|
@@ -20579,7 +20579,7 @@ var Color = class Y {
|
|
|
20579
20579
|
}
|
|
20580
20580
|
};
|
|
20581
20581
|
//#endregion
|
|
20582
|
-
//#region ../node_modules
|
|
20582
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/values.mjs
|
|
20583
20583
|
function validateRGBA(Y, ee, te, ne) {
|
|
20584
20584
|
return typeof Y == "number" && Y >= 0 && Y <= 255 && typeof ee == "number" && ee >= 0 && ee <= 255 && typeof te == "number" && te >= 0 && te <= 255 ? ne === void 0 || typeof ne == "number" && ne >= 0 && ne <= 1 ? null : `Invalid rgba value [${[
|
|
20585
20585
|
Y,
|
|
@@ -20643,7 +20643,7 @@ function valueToString(Y) {
|
|
|
20643
20643
|
return Y === null ? "" : ee === "string" || ee === "number" || ee === "boolean" ? String(Y) : Y instanceof Color || Y instanceof ProjectionDefinition || Y instanceof Formatted || Y instanceof Padding || Y instanceof NumberArray || Y instanceof ColorArray || Y instanceof VariableAnchorOffsetCollection || Y instanceof ResolvedImage ? Y.toString() : JSON.stringify(Y);
|
|
20644
20644
|
}
|
|
20645
20645
|
//#endregion
|
|
20646
|
-
//#region ../node_modules
|
|
20646
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/definitions/literal.mjs
|
|
20647
20647
|
var Literal = class Y {
|
|
20648
20648
|
constructor(Y, ee) {
|
|
20649
20649
|
this.type = Y, this.value = ee;
|
|
@@ -20691,7 +20691,7 @@ var Literal = class Y {
|
|
|
20691
20691
|
}
|
|
20692
20692
|
};
|
|
20693
20693
|
//#endregion
|
|
20694
|
-
//#region ../node_modules
|
|
20694
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/stops.mjs
|
|
20695
20695
|
function findStopLessThanOrEqualTo(Y, ee, te) {
|
|
20696
20696
|
let ne = Y.length - 1, xe = 0, Le = ne, et = 0, tt, nt;
|
|
20697
20697
|
for (; xe <= Le;) if (et = Math.floor((xe + Le) / 2), tt = Y[et], nt = Y[et + 1], tt <= ee) {
|
|
@@ -20702,7 +20702,7 @@ function findStopLessThanOrEqualTo(Y, ee, te) {
|
|
|
20702
20702
|
return 0;
|
|
20703
20703
|
}
|
|
20704
20704
|
//#endregion
|
|
20705
|
-
//#region ../node_modules
|
|
20705
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/definitions/step.mjs
|
|
20706
20706
|
var Step = class Y {
|
|
20707
20707
|
constructor(Y, ee, te, ne) {
|
|
20708
20708
|
this.type = Y, this.input = ee, this.key = ne, this.labels = [], this.outputs = [];
|
|
@@ -20742,7 +20742,7 @@ var Step = class Y {
|
|
|
20742
20742
|
}
|
|
20743
20743
|
};
|
|
20744
20744
|
//#endregion
|
|
20745
|
-
//#region ../node_modules
|
|
20745
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/node_modules/@mapbox/unitbezier/index.mjs
|
|
20746
20746
|
function unitBezier(Y, ee, te, ne) {
|
|
20747
20747
|
let xe = 3 * Y, Le = 3 * (te - Y) - xe, et = 1 - xe - Le, tt = 3 * ee, nt = 3 * (ne - ee) - tt, rt = 1 - tt - nt;
|
|
20748
20748
|
return function(Y, ee = 1e-6) {
|
|
@@ -20767,7 +20767,7 @@ function unitBezier(Y, ee, te, ne) {
|
|
|
20767
20767
|
};
|
|
20768
20768
|
}
|
|
20769
20769
|
//#endregion
|
|
20770
|
-
//#region ../node_modules
|
|
20770
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/definitions/interpolate.mjs
|
|
20771
20771
|
var Interpolate = class Y {
|
|
20772
20772
|
constructor(Y, ee, te, ne, xe, Le) {
|
|
20773
20773
|
this.type = Y, this.operator = ee, this.interpolation = te, this.input = ne, this.key = Le, this.labels = [], this.outputs = [];
|
|
@@ -20922,7 +20922,7 @@ var interpolateFactory = {
|
|
|
20922
20922
|
}
|
|
20923
20923
|
};
|
|
20924
20924
|
//#endregion
|
|
20925
|
-
//#region ../node_modules
|
|
20925
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/node_modules/quickselect/index.mjs
|
|
20926
20926
|
function quickselect(Y, ee, te = 0, ne = Y.length - 1, xe = defaultCompare) {
|
|
20927
20927
|
for (; ne > te;) {
|
|
20928
20928
|
if (ne - te > 600) {
|
|
@@ -20945,7 +20945,7 @@ function defaultCompare(Y, ee) {
|
|
|
20945
20945
|
return Y < ee ? -1 : +(Y > ee);
|
|
20946
20946
|
}
|
|
20947
20947
|
//#endregion
|
|
20948
|
-
//#region ../node_modules
|
|
20948
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/util/classify_rings.mjs
|
|
20949
20949
|
function classifyRings(Y, ee) {
|
|
20950
20950
|
if (Y.length <= 1) return [Y];
|
|
20951
20951
|
let te = [], ne, xe;
|
|
@@ -20965,7 +20965,7 @@ function calculateSignedArea(Y) {
|
|
|
20965
20965
|
return ee;
|
|
20966
20966
|
}
|
|
20967
20967
|
//#endregion
|
|
20968
|
-
//#region ../node_modules
|
|
20968
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/definitions/assertion.mjs
|
|
20969
20969
|
var types$2 = {
|
|
20970
20970
|
string: StringType,
|
|
20971
20971
|
number: NumberType,
|
|
@@ -21395,7 +21395,7 @@ var types$2 = {
|
|
|
21395
21395
|
}
|
|
21396
21396
|
};
|
|
21397
21397
|
//#endregion
|
|
21398
|
-
//#region ../node_modules
|
|
21398
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/definitions/comparison.mjs
|
|
21399
21399
|
function isComparableType(Y, ee) {
|
|
21400
21400
|
return Y === "==" || Y === "!=" ? ee.kind === "boolean" || ee.kind === "string" || ee.kind === "number" || ee.kind === "null" || ee.kind === "value" : ee.kind === "string" || ee.kind === "number" || ee.kind === "value";
|
|
21401
21401
|
}
|
|
@@ -21650,7 +21650,7 @@ function twoSided(Y, ee, te, ne) {
|
|
|
21650
21650
|
return it > 0 && at < 0 || it < 0 && at > 0;
|
|
21651
21651
|
}
|
|
21652
21652
|
//#endregion
|
|
21653
|
-
//#region ../node_modules
|
|
21653
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/definitions/within.mjs
|
|
21654
21654
|
function getTilePolygon(Y, ee, te) {
|
|
21655
21655
|
let ne = [];
|
|
21656
21656
|
for (let xe = 0; xe < Y.length; xe++) {
|
|
@@ -22852,7 +22852,7 @@ function isGlobalPropertyConstant(Y, ee) {
|
|
|
22852
22852
|
}), te;
|
|
22853
22853
|
}
|
|
22854
22854
|
//#endregion
|
|
22855
|
-
//#region ../node_modules
|
|
22855
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/util/properties.mjs
|
|
22856
22856
|
function supportsPropertyExpression(Y) {
|
|
22857
22857
|
return Y["property-type"] === "data-driven" || Y["property-type"] === "cross-faded-data-driven";
|
|
22858
22858
|
}
|
|
@@ -22863,12 +22863,12 @@ function supportsInterpolation(Y) {
|
|
|
22863
22863
|
return !!Y.expression && Y.expression.interpolated;
|
|
22864
22864
|
}
|
|
22865
22865
|
//#endregion
|
|
22866
|
-
//#region ../node_modules
|
|
22866
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/function/index.mjs
|
|
22867
22867
|
function isFunction(Y) {
|
|
22868
22868
|
return typeof Y == "object" && !!Y && !Array.isArray(Y) && typeOf(Y) === ObjectType;
|
|
22869
22869
|
}
|
|
22870
22870
|
//#endregion
|
|
22871
|
-
//#region ../node_modules
|
|
22871
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/util/result.mjs
|
|
22872
22872
|
function success(Y) {
|
|
22873
22873
|
return {
|
|
22874
22874
|
result: "success",
|
|
@@ -22882,7 +22882,7 @@ function error(Y) {
|
|
|
22882
22882
|
};
|
|
22883
22883
|
}
|
|
22884
22884
|
//#endregion
|
|
22885
|
-
//#region ../node_modules
|
|
22885
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/expression/index.mjs
|
|
22886
22886
|
var StyleExpression = class {
|
|
22887
22887
|
constructor(Y, ee, te, ne) {
|
|
22888
22888
|
this.expression = Y, this._warningHistory = {}, this._evaluator = new EvaluationContext(), this._defaultValue = te ? getDefaultValue(te) : null, this._enumValues = te && te.type === "enum" ? te.values : null, this._globalState = ne, this._rootKey = ee;
|
|
@@ -23014,7 +23014,7 @@ function addGlobalState(Y, ee) {
|
|
|
23014
23014
|
};
|
|
23015
23015
|
}
|
|
23016
23016
|
//#endregion
|
|
23017
|
-
//#region ../node_modules
|
|
23017
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/feature_filter/index.mjs
|
|
23018
23018
|
function classifyChildren(Y) {
|
|
23019
23019
|
let ee = !1;
|
|
23020
23020
|
for (let te of Y) {
|
|
@@ -23202,7 +23202,7 @@ function convertNegation(Y) {
|
|
|
23202
23202
|
return ["!", Y];
|
|
23203
23203
|
}
|
|
23204
23204
|
//#endregion
|
|
23205
|
-
//#region ../node_modules
|
|
23205
|
+
//#region ../node_modules/@maplibre/maplibre-gl-style-spec/dist/function/convert.mjs
|
|
23206
23206
|
function convertLiteral(Y) {
|
|
23207
23207
|
return typeof Y == "object" ? ["literal", Y] : Y;
|
|
23208
23208
|
}
|
|
@@ -25995,13 +25995,13 @@ var DEFAULT_CONFIG = {
|
|
|
25995
25995
|
};
|
|
25996
25996
|
function sanitizeHtml(Y, ee = {}) {
|
|
25997
25997
|
if (typeof Y != "string") return Y;
|
|
25998
|
-
let { strict: te = !1, config: ne = {}, purify: xe =
|
|
25998
|
+
let { strict: te = !1, config: ne = {}, purify: xe = purify_default } = ee, Le = {
|
|
25999
25999
|
...te ? STRICT_CONFIG : DEFAULT_CONFIG,
|
|
26000
26000
|
...ne
|
|
26001
26001
|
};
|
|
26002
26002
|
return xe.sanitize(Y, Le);
|
|
26003
26003
|
}
|
|
26004
|
-
|
|
26004
|
+
purify_default.addHook("afterSanitizeAttributes", (Y) => {
|
|
26005
26005
|
if (Y.tagName === "A") {
|
|
26006
26006
|
let ee = Y.getAttribute("href") || "";
|
|
26007
26007
|
/^\s*(javascript|data|vbscript):/i.test(ee) && Y.removeAttribute("href"), ee.startsWith("http") && (Y.setAttribute("target", "_blank"), Y.setAttribute("rel", "noopener noreferrer"));
|
|
@@ -62025,7 +62025,11 @@ var require_code$3 = /* @__PURE__ */ __commonJSMin(((Y) => {
|
|
|
62025
62025
|
}
|
|
62026
62026
|
xe.reference = xe.scheme === void 0 && xe.userinfo === void 0 && xe.host === void 0 && xe.port === void 0 && xe.query === void 0 && !xe.path ? "same-document" : xe.scheme === void 0 ? "relative" : xe.fragment === void 0 ? "absolute" : "uri", ne.reference && ne.reference !== "suffix" && ne.reference !== xe.reference && (xe.error = xe.error || "URI is not a " + ne.reference + " reference.");
|
|
62027
62027
|
let _t = ut(ne.scheme || xe.scheme);
|
|
62028
|
-
pt || (st = Dt(xe, ne, _t, ht)),
|
|
62028
|
+
if (pt || (st = Dt(xe, ne, _t, ht)), Y.indexOf("%") !== -1 && xe.host !== void 0 && !pt) {
|
|
62029
|
+
let Y = ht ? xe.host : Le(xe.host, !0);
|
|
62030
|
+
ht || (Y = Le(Y.toLowerCase())), xe.host = at(Y, ht);
|
|
62031
|
+
}
|
|
62032
|
+
(!_t || _t && !_t.skipNormalize) && (xe.path &&= et(xe.path), xe.query &&= nt(xe.query), xe.fragment &&= nt(xe.fragment)), _t && _t.parse && (_t.parse(xe, ne), _t === ct.urn && xe.nid === void 0 && (it = !0));
|
|
62029
62033
|
} else xe.error = xe.error || "URI can not be parsed.";
|
|
62030
62034
|
return {
|
|
62031
62035
|
parsed: xe,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@datagouv/components-next",
|
|
3
|
-
"version": "1.4.1-dev.
|
|
3
|
+
"version": "1.4.1-dev.1358.g6d93ccfb",
|
|
4
4
|
"private": false,
|
|
5
5
|
"type": "module",
|
|
6
6
|
"engines": {
|
|
@@ -32,11 +32,11 @@
|
|
|
32
32
|
"@vueuse/core": "^14.4.0",
|
|
33
33
|
"@vueuse/router": "^14.4.0",
|
|
34
34
|
"chart.js": "^4.5.1",
|
|
35
|
-
"dompurify": "^3.4.
|
|
35
|
+
"dompurify": "^3.4.16",
|
|
36
36
|
"echarts": "^6.1.0",
|
|
37
37
|
"geopf-extensions-openlayers": "1.0.0-beta.15",
|
|
38
38
|
"leaflet": "^1.9.4",
|
|
39
|
-
"maplibre-gl": "^
|
|
39
|
+
"maplibre-gl": "^6.13.0",
|
|
40
40
|
"ofetch": "^1.5.1",
|
|
41
41
|
"ol": "^10.10.0",
|
|
42
42
|
"pdfjs-dist": "^4.10.38",
|
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
"vite-plugin-vue-devtools": "^8.2.1",
|
|
88
88
|
"vue": "^3.5.42",
|
|
89
89
|
"vue-router": "^5.3.1",
|
|
90
|
-
"vue-tsc": "
|
|
90
|
+
"vue-tsc": "3.3.11"
|
|
91
91
|
},
|
|
92
92
|
"peerDependencies": {
|
|
93
93
|
"echarts": "^6.0.0",
|
|
@@ -55,7 +55,8 @@
|
|
|
55
55
|
import { computed, onMounted, ref, useTemplateRef } from 'vue'
|
|
56
56
|
import { RiExternalLinkFill } from '@remixicon/vue'
|
|
57
57
|
import { Protocol, PMTiles } from 'pmtiles'
|
|
58
|
-
import maplibregl from 'maplibre-gl'
|
|
58
|
+
import * as maplibregl from 'maplibre-gl'
|
|
59
|
+
import maplibreWorkerUrl from 'maplibre-gl/dist/maplibre-gl-worker.mjs?worker&url'
|
|
59
60
|
import DOMPurify from 'dompurify'
|
|
60
61
|
import { useComponentsConfig } from '../../config'
|
|
61
62
|
import { useFormatDate } from '../../functions/dates'
|
|
@@ -94,6 +95,9 @@ const lastUpdate = computed(() => {
|
|
|
94
95
|
|
|
95
96
|
const container = useTemplateRef('containerRef')
|
|
96
97
|
|
|
98
|
+
// v6 with a bundler cannot resolve the worker from import.meta.url; point it at the chunk Vite emits.
|
|
99
|
+
maplibregl.setWorkerUrl(maplibreWorkerUrl)
|
|
100
|
+
|
|
97
101
|
const attributions = computed(() => getMapAttribution(props.dataset))
|
|
98
102
|
|
|
99
103
|
async function displayMap() {
|
|
@@ -183,7 +187,7 @@ async function displayMap() {
|
|
|
183
187
|
'type': typeLayer.value as 'fill' | 'circle' | 'line',
|
|
184
188
|
'paint': {
|
|
185
189
|
[`${typeLayer.value}-color`]: 'steelblue',
|
|
186
|
-
[`${typeLayer.value}-opacity`]:
|
|
190
|
+
[`${typeLayer.value}-opacity`]: ['interpolate', ['linear'], ['zoom'], 0, 0.9, 10, 0.6],
|
|
187
191
|
},
|
|
188
192
|
} as maplibregl.AddLayerObject)
|
|
189
193
|
map.on('click', layer.layer, showMapPopup)
|