@getodk/web-forms 0.19.0 → 0.20.0

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.
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as Wn, ref as Me, computed as yt, watch as Tt, createBlock as it, openBlock as te, Transition as qu, withCtx as We, createElementBlock as _e, createCommentVNode as Ee, createElementVNode as N, normalizeClass as On, withDirectives as Ws, vModelText as Vs, createVNode as he, unref as Q, shallowRef as lt, toDisplayString as St, Fragment as ih, renderList as Ju, inject as Qu, onMounted as ed, onUnmounted as td, nextTick as nd, createTextVNode as id } from "vue";
2
- import { i as sd, a as Nl, b as rd, I as Be, t as xa, _ as Li, s as sh, c as Gt, S as ve, g as od, M as ad, d as ld, e as cd, f as hd, h as ud, p as dd, Q as fd, j as gd } from "./index-MXyKxa9t.js";
2
+ import { i as sd, a as Nl, b as rd, I as Be, t as xa, _ as Li, s as sh, c as Gt, S as ve, g as od, M as ad, d as ld, e as cd, f as hd, h as ud, p as dd, Q as fd, j as gd } from "./index-DKdvMAPh.js";
3
3
  function rh(...i) {
4
4
  console.warn(...i);
5
5
  }
@@ -733,7 +733,7 @@ function Jd(i) {
733
733
  * @param {number} [stride] Stride.
734
734
  * @return {Array<number>} Output.
735
735
  */
736
- function(e, t, n, s) {
736
+ (function(e, t, n, s) {
737
737
  const r = e.length;
738
738
  n = n !== void 0 ? n : 2, s = s ?? n, t = t !== void 0 ? t : new Array(r);
739
739
  for (let o = 0; o < r; o += s) {
@@ -742,7 +742,7 @@ function Jd(i) {
742
742
  t[o + c] = c >= l ? e[o + c] : a[c];
743
743
  }
744
744
  return t;
745
- }
745
+ })
746
746
  );
747
747
  }
748
748
  function ls(i, e) {
@@ -1027,7 +1027,7 @@ const ef = {
1027
1027
  ]),
1028
1028
  N("button", {
1029
1029
  class: "zoom-fit-all",
1030
- title: "Zoom to fit all options",
1030
+ title: "Zoom to fit",
1031
1031
  disabled: i.disableFitAllFeatures,
1032
1032
  onClick: s[1] || (s[1] = (r) => t("fitAllFeatures"))
1033
1033
  }, [
@@ -1062,7 +1062,7 @@ const ef = {
1062
1062
  ])) : Ee("", !0)
1063
1063
  ], 2));
1064
1064
  }
1065
- }), wf = /* @__PURE__ */ Li(Rf, [["__scopeId", "data-v-1083013c"]]);
1065
+ }), wf = /* @__PURE__ */ Li(Rf, [["__scopeId", "data-v-b324b2c9"]]);
1066
1066
  function X() {
1067
1067
  throw new Error("Unimplemented abstract method.");
1068
1068
  }
@@ -4605,7 +4605,7 @@ const q = {
4605
4605
  LOADING: 1,
4606
4606
  LOADED: 2,
4607
4607
  ERROR: 3
4608
- }, $n = typeof navigator < "u" && typeof navigator.userAgent < "u" ? navigator.userAgent.toLowerCase() : "", ig = $n.includes("safari") && !$n.includes("chrom"), sg = ig && ($n.includes("version/15.4") || /cpu (os|iphone os) 15_4 like mac os x/.test($n)), rg = $n.includes("webkit") && !$n.includes("edge"), Nh = $n.includes("macintosh"), og = typeof devicePixelRatio < "u" ? devicePixelRatio : 1, ct = typeof WorkerGlobalScope < "u" && typeof OffscreenCanvas < "u" && self instanceof WorkerGlobalScope, kh = typeof Image < "u" && Image.prototype.decode, Gh = function() {
4608
+ }, $n = typeof navigator < "u" && typeof navigator.userAgent < "u" ? navigator.userAgent.toLowerCase() : "", ig = $n.includes("safari") && !$n.includes("chrom"), sg = ig && ($n.includes("version/15.4") || /cpu (os|iphone os) 15_4 like mac os x/.test($n)), rg = $n.includes("webkit") && !$n.includes("edge"), Nh = $n.includes("macintosh"), og = typeof devicePixelRatio < "u" ? devicePixelRatio : 1, ct = typeof WorkerGlobalScope < "u" && typeof OffscreenCanvas < "u" && self instanceof WorkerGlobalScope, kh = typeof Image < "u" && Image.prototype.decode, Gh = (function() {
4609
4609
  let i = !1;
4610
4610
  try {
4611
4611
  const e = Object.defineProperty({}, "passive", {
@@ -4617,7 +4617,7 @@ const q = {
4617
4617
  } catch {
4618
4618
  }
4619
4619
  return i;
4620
- }();
4620
+ })();
4621
4621
  function Pe(i, e, t, n) {
4622
4622
  let s;
4623
4623
  return t && t.length ? s = /** @type {HTMLCanvasElement} */
@@ -5209,7 +5209,7 @@ const oa = {}, Sg = /* @__PURE__ */ new Set([
5209
5209
  function Rg(i, e, t) {
5210
5210
  return `${i} ${e} 16px "${t}"`;
5211
5211
  }
5212
- const wg = /* @__PURE__ */ function() {
5212
+ const wg = /* @__PURE__ */ (function() {
5213
5213
  let e, t;
5214
5214
  async function n(r) {
5215
5215
  await t.ready;
@@ -5256,7 +5256,7 @@ const wg = /* @__PURE__ */ function() {
5256
5256
  }
5257
5257
  l && (clearTimeout(e), e = setTimeout(s, 100));
5258
5258
  };
5259
- }(), Pg = /* @__PURE__ */ function() {
5259
+ })(), Pg = /* @__PURE__ */ (function() {
5260
5260
  let i;
5261
5261
  return function(e) {
5262
5262
  let t = oa[e];
@@ -5270,7 +5270,7 @@ const wg = /* @__PURE__ */ function() {
5270
5270
  }
5271
5271
  return t;
5272
5272
  };
5273
- }();
5273
+ })();
5274
5274
  function Wh(i, e) {
5275
5275
  return $i || ($i = Pe(1, 1)), i != tc && ($i.font = i, tc = $i.font), $i.measureText(e);
5276
5276
  }
@@ -13987,15 +13987,12 @@ function V_(i, e) {
13987
13987
  const t = i.operator, n = i.args.length, s = new Array(n);
13988
13988
  for (let r = 0; r < n; ++r)
13989
13989
  s[r] = It(i.args[r]);
13990
- switch (t) {
13991
- case C.ToString:
13992
- return (r) => {
13993
- const o = s[0](r);
13994
- return i.args[0].type === ue ? Va(o) : o.toString();
13995
- };
13996
- default:
13997
- throw new Error(`Unsupported convert operator ${t}`);
13998
- }
13990
+ if (t === C.ToString)
13991
+ return (r) => {
13992
+ const o = s[0](r);
13993
+ return i.args[0].type === ue ? Va(o) : o.toString();
13994
+ };
13995
+ throw new Error(`Unsupported convert operator ${t}`);
13999
13996
  }
14000
13997
  function qi(i, e, t, n, s, r) {
14001
13998
  const o = s - t;
@@ -14598,7 +14595,7 @@ function Rc(i, e, t) {
14598
14595
  * @param {Array<number>} [centerShift] Shift between map center and viewport center.
14599
14596
  * @return {import("./coordinate.js").Coordinate|undefined} Center.
14600
14597
  */
14601
- function(n, s, r, o, a) {
14598
+ (function(n, s, r, o, a) {
14602
14599
  if (!n)
14603
14600
  return;
14604
14601
  if (!s && !e)
@@ -14612,7 +14609,7 @@ function Rc(i, e, t) {
14612
14609
  _ += -x * Math.log(1 + Math.max(0, d - n[0]) / x) + x * Math.log(1 + Math.max(0, n[0] - f) / x), p += -x * Math.log(1 + Math.max(0, g - n[1]) / x) + x * Math.log(1 + Math.max(0, n[1] - m) / x);
14613
14610
  }
14614
14611
  return [_, p];
14615
- }
14612
+ })
14616
14613
  );
14617
14614
  }
14618
14615
  function om(i) {
@@ -14647,7 +14644,7 @@ function cm(i, e, t, n) {
14647
14644
  * @param {boolean} [isMoving] True if an interaction or animation is in progress.
14648
14645
  * @return {number|undefined} Resolution.
14649
14646
  */
14650
- function(s, r, o, a) {
14647
+ (function(s, r, o, a) {
14651
14648
  if (s !== void 0) {
14652
14649
  const l = i[0], c = i[i.length - 1], h = t ? Ja(
14653
14650
  l,
@@ -14664,7 +14661,7 @@ function cm(i, e, t, n) {
14664
14661
  const u = Math.min(h, s), d = Math.floor(ba(i, u, r));
14665
14662
  return i[d] > h && d < i.length - 1 ? i[d + 1] : i[d];
14666
14663
  }
14667
- };
14664
+ });
14668
14665
  }
14669
14666
  function hm(i, e, t, n, s, r) {
14670
14667
  return n = n !== void 0 ? n : !0, t = t !== void 0 ? t : 0, /**
@@ -14674,7 +14671,7 @@ function hm(i, e, t, n, s, r) {
14674
14671
  * @param {boolean} [isMoving] True if an interaction or animation is in progress.
14675
14672
  * @return {number|undefined} Resolution.
14676
14673
  */
14677
- function(o, a, l, c) {
14674
+ (function(o, a, l, c) {
14678
14675
  if (o !== void 0) {
14679
14676
  const h = s ? Ja(
14680
14677
  e,
@@ -14695,7 +14692,7 @@ function hm(i, e, t, n, s, r) {
14695
14692
  ), _ = Math.max(d, m), p = e / Math.pow(i, _);
14696
14693
  return de(p, t, h);
14697
14694
  }
14698
- };
14695
+ });
14699
14696
  }
14700
14697
  function wc(i, e, t, n, s) {
14701
14698
  return t = t !== void 0 ? t : !0, /**
@@ -14705,7 +14702,7 @@ function wc(i, e, t, n, s) {
14705
14702
  * @param {boolean} [isMoving] True if an interaction or animation is in progress.
14706
14703
  * @return {number|undefined} Resolution.
14707
14704
  */
14708
- function(r, o, a, l) {
14705
+ (function(r, o, a, l) {
14709
14706
  if (r !== void 0) {
14710
14707
  const c = n ? Ja(
14711
14708
  i,
@@ -14719,7 +14716,7 @@ function wc(i, e, t, n, s) {
14719
14716
  e
14720
14717
  );
14721
14718
  }
14722
- };
14719
+ });
14723
14720
  }
14724
14721
  function el(i) {
14725
14722
  if (i !== void 0)
@@ -14737,12 +14734,12 @@ function um(i) {
14737
14734
  * @param {boolean} [isMoving] True if an interaction or animation is in progress.
14738
14735
  * @return {number|undefined} Rotation.
14739
14736
  */
14740
- function(t, n) {
14737
+ (function(t, n) {
14741
14738
  if (n)
14742
14739
  return t;
14743
14740
  if (t !== void 0)
14744
14741
  return t = Math.floor(t / e + 0.5) * e, t;
14745
- }
14742
+ })
14746
14743
  );
14747
14744
  }
14748
14745
  function dm(i) {
@@ -14753,9 +14750,9 @@ function dm(i) {
14753
14750
  * @param {boolean} [isMoving] True if an interaction or animation is in progress.
14754
14751
  * @return {number|undefined} Rotation.
14755
14752
  */
14756
- function(t, n) {
14753
+ (function(t, n) {
14757
14754
  return n || t === void 0 ? t : Math.abs(t) <= e ? 0 : t;
14758
- }
14755
+ })
14759
14756
  );
14760
14757
  }
14761
14758
  const fm = 42, tl = 256, So = 0;
@@ -15269,9 +15266,9 @@ class Nt extends Wt {
15269
15266
  * @param {number} value Value.
15270
15267
  * @return {number} Resolution.
15271
15268
  */
15272
- function(r) {
15269
+ (function(r) {
15273
15270
  return t / Math.pow(e, r * s);
15274
- }
15271
+ })
15275
15272
  );
15276
15273
  }
15277
15274
  /**
@@ -15299,9 +15296,9 @@ class Nt extends Wt {
15299
15296
  * @param {number} resolution Resolution.
15300
15297
  * @return {number} Value.
15301
15298
  */
15302
- function(o) {
15299
+ (function(o) {
15303
15300
  return Math.log(n / o) / t / r;
15304
- }
15301
+ })
15305
15302
  );
15306
15303
  }
15307
15304
  /**
@@ -17800,7 +17797,7 @@ class gu extends rl {
17800
17797
  function wm(i) {
17801
17798
  i = i || {};
17802
17799
  const e = new Ue();
17803
- return (i.zoom !== void 0 ? i.zoom : !0) && e.push(new gu(i.zoomOptions)), (i.rotate !== void 0 ? i.rotate : !0) && e.push(new Rm(i.rotateOptions)), (i.attribution !== void 0 ? i.attribution : !0) && e.push(new fu(i.attributionOptions)), e;
17800
+ return (i.zoom === void 0 || i.zoom) && e.push(new gu(i.zoomOptions)), (i.rotate === void 0 || i.rotate) && e.push(new Rm(i.rotateOptions)), (i.attribution === void 0 || i.attribution) && e.push(new fu(i.attributionOptions)), e;
17804
17801
  }
17805
17802
  const ua = {
17806
17803
  ACTIVE: "active"
@@ -18705,31 +18702,31 @@ class Ym extends Kn {
18705
18702
  function Eu(i) {
18706
18703
  i = i || {};
18707
18704
  const e = new Ue(), t = new Em(-5e-3, 0.05, 100);
18708
- return (i.altShiftDragRotate !== void 0 ? i.altShiftDragRotate : !0) && e.push(new km()), (i.doubleClickZoom !== void 0 ? i.doubleClickZoom : !0) && e.push(
18705
+ return (i.altShiftDragRotate === void 0 || i.altShiftDragRotate) && e.push(new km()), (i.doubleClickZoom === void 0 || i.doubleClickZoom) && e.push(
18709
18706
  new Im({
18710
18707
  delta: i.zoomDelta,
18711
18708
  duration: i.zoomDuration
18712
18709
  })
18713
- ), (i.dragPan !== void 0 ? i.dragPan : !0) && e.push(
18710
+ ), (i.dragPan === void 0 || i.dragPan) && e.push(
18714
18711
  new Nm({
18715
18712
  onFocusOnly: i.onFocusOnly,
18716
18713
  kinetic: t
18717
18714
  })
18718
- ), (i.pinchRotate !== void 0 ? i.pinchRotate : !0) && e.push(new jm()), (i.pinchZoom !== void 0 ? i.pinchZoom : !0) && e.push(
18715
+ ), (i.pinchRotate === void 0 || i.pinchRotate) && e.push(new jm()), (i.pinchZoom === void 0 || i.pinchZoom) && e.push(
18719
18716
  new Ym({
18720
18717
  duration: i.zoomDuration
18721
18718
  })
18722
- ), (i.keyboard !== void 0 ? i.keyboard : !0) && (e.push(new zm()), e.push(
18719
+ ), (i.keyboard === void 0 || i.keyboard) && (e.push(new zm()), e.push(
18723
18720
  new $m({
18724
18721
  delta: i.zoomDelta,
18725
18722
  duration: i.zoomDuration
18726
18723
  })
18727
- )), (i.mouseWheelZoom !== void 0 ? i.mouseWheelZoom : !0) && e.push(
18724
+ )), (i.mouseWheelZoom === void 0 || i.mouseWheelZoom) && e.push(
18728
18725
  new Xm({
18729
18726
  onFocusOnly: i.onFocusOnly,
18730
18727
  duration: i.zoomDuration
18731
18728
  })
18732
- ), (i.shiftDragZoom !== void 0 ? i.shiftDragZoom : !0) && e.push(
18729
+ ), (i.shiftDragZoom === void 0 || i.shiftDragZoom) && e.push(
18733
18730
  new Um({
18734
18731
  duration: i.zoomDuration
18735
18732
  })
@@ -29060,7 +29057,7 @@ function ky(i, e) {
29060
29057
  * @param {import("./proj/Projection.js").default} projection Projection.
29061
29058
  * @return {string|undefined} Tile URL.
29062
29059
  */
29063
- function(t, n, s) {
29060
+ (function(t, n, s) {
29064
29061
  if (!t)
29065
29062
  return;
29066
29063
  let r;
@@ -29070,7 +29067,7 @@ function ky(i, e) {
29070
29067
  a && (r = a.getHeight() - 1);
29071
29068
  }
29072
29069
  return Oy(i, o, t[1], t[2], r);
29073
- }
29070
+ })
29074
29071
  );
29075
29072
  }
29076
29073
  function Gy(i, e) {
@@ -29087,12 +29084,12 @@ function By(i) {
29087
29084
  * @param {import("./proj/Projection.js").default} projection Projection.
29088
29085
  * @return {string|undefined} Tile URL.
29089
29086
  */
29090
- function(e, t, n) {
29087
+ (function(e, t, n) {
29091
29088
  if (!e)
29092
29089
  return;
29093
29090
  const s = $0(e), r = kn(s, i.length);
29094
29091
  return i[r](e, t, n);
29095
- }
29092
+ })
29096
29093
  );
29097
29094
  }
29098
29095
  class Uy extends Qh {
@@ -30053,7 +30050,7 @@ const Yy = {
30053
30050
  })) : Ee("", !0)
30054
30051
  ], 2));
30055
30052
  }
30056
- }), sx = /* @__PURE__ */ Li(ix, [["__scopeId", "data-v-dfcf9572"]]), rx = { class: "dialog-field-container" }, ox = {
30053
+ }), sx = /* @__PURE__ */ Li(ix, [["__scopeId", "data-v-50941833"]]), rx = { class: "dialog-field-container" }, ox = {
30057
30054
  key: 0,
30058
30055
  class: "coords-error-message"
30059
30056
  }, ax = { class: "dialog-field-container" }, lx = {