@mapsindoors/map-template 1.95.1 → 1.95.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.
Files changed (66) hide show
  1. package/dist/{GoogleMapsMap-C5n6Bgtp.mjs → GoogleMapsMap-Dkn60-_e.mjs} +2 -2
  2. package/dist/{MapboxMap-UCqzt1AC.mjs → MapboxMap-B1oo7IUm.mjs} +2 -2
  3. package/dist/_commonjsHelpers-B85MJLTf.js +5 -0
  4. package/dist/app-globals-DQuL1Twl.js +3 -0
  5. package/dist/combo-box-item.entry.js +8 -10
  6. package/dist/icon-DT_sDkmK.js +11 -0
  7. package/dist/index-BZQHyS7V.js +1701 -0
  8. package/dist/loader.js +7 -14
  9. package/dist/mapsindoors-react.es.js +1 -1
  10. package/dist/mapsindoors-react.umd.js +175 -175
  11. package/dist/mapsindoors-webcomponent.es.js +2916 -2904
  12. package/dist/mi-card_2.entry.js +23 -18
  13. package/dist/mi-chip.entry.js +25 -16
  14. package/dist/mi-column.entry.js +47 -23
  15. package/dist/mi-combo-box.entry.js +412 -379
  16. package/dist/mi-components.js +15 -12
  17. package/dist/mi-data-table.entry.js +298 -278
  18. package/dist/mi-distance_2.entry.js +58 -56
  19. package/dist/mi-dropdown-item.entry.js +8 -10
  20. package/dist/mi-dropdown.entry.js +525 -481
  21. package/dist/mi-floor-selector.entry.js +183 -180
  22. package/dist/mi-keyboard.entry.js +207 -186
  23. package/dist/mi-list-item-category.entry.js +44 -41
  24. package/dist/mi-list-item-location.entry.js +168 -162
  25. package/dist/mi-list.entry.js +56 -48
  26. package/dist/mi-location-booking.entry.js +320 -295
  27. package/dist/mi-location-info.entry.js +61 -53
  28. package/dist/mi-map-googlemaps.entry.js +369 -324
  29. package/dist/mi-map-mapbox.entry.js +502 -439
  30. package/dist/mi-metric-card.entry.js +50 -37
  31. package/dist/mi-my-position.entry.js +2341 -874
  32. package/dist/mi-notification.entry.js +112 -102
  33. package/dist/mi-route-instructions-heading.entry.js +70 -65
  34. package/dist/mi-route-instructions-maneuver-legacy.entry.js +80 -76
  35. package/dist/mi-route-instructions-maneuver.entry.js +80 -76
  36. package/dist/mi-route-instructions-step-legacy.entry.js +296 -282
  37. package/dist/mi-route-instructions-step.entry.js +313 -292
  38. package/dist/mi-route-instructions.entry.js +167 -150
  39. package/dist/mi-scroll-buttons.entry.js +104 -98
  40. package/dist/mi-search.entry.js +366 -325
  41. package/dist/mi-share-sms.entry.js +82 -70
  42. package/dist/mi-step-switcher.entry.js +34 -25
  43. package/dist/mi-tab-panel.entry.js +18 -18
  44. package/dist/mi-tab.entry.js +5 -7
  45. package/dist/mi-tabs.entry.js +42 -40
  46. package/dist/mi-time.entry.js +49 -49
  47. package/dist/mi-variables-CDNvnTkH.js +5 -0
  48. package/dist/{reactcomponent-DQsjxRIN.mjs → reactcomponent-2Oa1vSiK.mjs} +8996 -8660
  49. package/dist/route-travel-mode.enum-BvqP1fpw.js +9 -0
  50. package/dist/sort-order.enum-jsLAbYWg.js +566 -0
  51. package/dist/{unit-system.enum-eaefb53e.js → unit-system.enum-BwPgAWqL.js} +2 -2
  52. package/dist/utils-DNHzysQ6.js +61 -0
  53. package/package.json +1 -1
  54. package/dist/_commonjsHelpers-ba3f0406.js +0 -21
  55. package/dist/icon-b8d01d6f.js +0 -24
  56. package/dist/index-7e9696f3.js +0 -1678
  57. package/dist/mi-variables-9a6c8d4d.js +0 -6
  58. package/dist/polyfills/core-js.js +0 -11
  59. package/dist/polyfills/css-shim.js +0 -1
  60. package/dist/polyfills/dom.js +0 -79
  61. package/dist/polyfills/es5-html-element.js +0 -1
  62. package/dist/polyfills/index.js +0 -34
  63. package/dist/polyfills/system.js +0 -6
  64. package/dist/route-travel-mode.enum-7f4ce9c7.js +0 -9
  65. package/dist/sort-order.enum-64ce8998.js +0 -552
  66. package/dist/utils-ae714467.js +0 -61
@@ -1,82 +1,86 @@
1
- import { r as registerInstance, h, H as Host } from './index-7e9696f3.js';
2
- import { U as UnitSystem } from './unit-system.enum-eaefb53e.js';
1
+ import { r as registerInstance, h, H as Host } from './index-BZQHyS7V.js';
2
+ import { U as UnitSystem } from './unit-system.enum-BwPgAWqL.js';
3
3
 
4
- const routeInstructionsManeuverCss = ":host{display:grid;gap:24px;grid-auto-flow:column;align-items:center;grid-template-columns:24px 1fr;border-top:1px solid #e5e7eb;padding:16px}.icon{width:24px;height:24px}.description{font-size:16px;display:grid;gap:8px;height:-moz-fit-content;height:fit-content}.description__text{margin:0;font-size:16px;word-break:break-all}.description mi-distance{font-size:12px;color:#6b7280}";
4
+ const routeInstructionsManeuverCss = () => `:host{display:grid;gap:24px;grid-auto-flow:column;align-items:center;grid-template-columns:24px 1fr;border-top:1px solid #e5e7eb;padding:16px}.icon{width:24px;height:24px}.description{font-size:16px;display:grid;gap:8px;height:-moz-fit-content;height:fit-content}.description__text{margin:0;font-size:16px;word-break:break-all}.description mi-distance{font-size:12px;color:#6b7280}`;
5
5
 
6
6
  const RouteInstructionsManeuver = class {
7
- constructor(hostRef) {
8
- registerInstance(this, hostRef);
9
- this.maneuver = undefined;
10
- this.maneuverData = undefined;
11
- this.translations = undefined;
12
- this.translationsData = undefined;
13
- this.unit = UnitSystem.Metric;
14
- }
15
- parseManeuverProp() {
16
- this.maneuverData = JSON.parse(this.maneuver);
17
- }
18
- parseTranslationsProp() {
19
- this.translationsData = JSON.parse(this.translations);
20
- }
21
- componentWillLoad() {
22
- this.parseManeuverProp();
23
- this.parseTranslationsProp();
24
- }
25
- /**
26
- * Get maneuver name.
27
- *
28
- * @returns {string}
29
- */
30
- getManeuverName(maneuver) {
31
- if (maneuver.includes('straight'))
32
- return 'straight';
33
- if (maneuver.includes('sharp right'))
34
- return 'sharp-right';
35
- if (maneuver.includes('sharp left'))
36
- return 'sharp-left';
37
- if (maneuver.includes('slight right'))
38
- return 'slight-right';
39
- if (maneuver.includes('slight left'))
40
- return 'slight-left';
41
- if (maneuver.includes('right'))
42
- return 'right';
43
- if (maneuver.includes('left'))
44
- return 'left';
45
- if (maneuver.includes('uturn'))
46
- return 'u-turn';
47
- if (maneuver.includes('depart'))
48
- return 'straight';
49
- }
50
- render() {
51
- return (this.maneuverData && this.translationsData ? this.renderManeuver() : null);
52
- }
53
- /**
54
- * Render step.
55
- *
56
- * @returns {JSX.Element}
57
- */
58
- renderManeuver() {
59
- const maneuverStrings = {
60
- 'straight': this.translationsData.continueStraightAhead,
61
- 'left': `${this.translationsData.goLeft} ${this.translationsData.andContinue}`,
62
- 'sharp-left': `${this.translationsData.goSharpLeft} ${this.translationsData.andContinue}`,
63
- 'slight-left': `${this.translationsData.goSlightLeft} ${this.translationsData.andContinue}`,
64
- 'right': `${this.translationsData.goRight} ${this.translationsData.andContinue}`,
65
- 'sharp-right': `${this.translationsData.goSharpRight} ${this.translationsData.andContinue}`,
66
- 'slight-right': `${this.translationsData.goSlightRight} ${this.translationsData.andContinue}`,
67
- 'u-turn': `${this.translationsData.turnAround} ${this.translationsData.andContinue}`, // 'Turn around and continue'
68
- };
69
- const maneuver = this.getManeuverName(this.maneuverData.maneuver.toLowerCase());
70
- const iconName = `arrow-${maneuver}`;
71
- // Check if the instructions property has a value otherwise fallback to maneuver property
72
- const translatedManeuver = this.maneuverData.instructions ? this.maneuverData.instructions : maneuverStrings[maneuver];
73
- return (h(Host, null, h("div", { class: "icon" }, maneuver ? h("mi-icon", { part: "maneuver-icon", "icon-name": iconName }) : null), h("div", { class: "description" }, h("div", { class: "description__text" }, translatedManeuver), h("mi-distance", { part: "maneuver-description-distance", meters: this.maneuverData.distance.value, unit: this.unit }))));
74
- }
75
- static get watchers() { return {
76
- "maneuver": ["parseManeuverProp"],
77
- "translations": ["parseTranslationsProp"]
78
- }; }
7
+ constructor(hostRef) {
8
+ registerInstance(this, hostRef);
9
+ /**
10
+ * Set imperial or metric as default unit system.
11
+ * @type {UnitSystem} 'imperial' or 'metric'
12
+ */
13
+ this.unit = UnitSystem.Metric;
14
+ }
15
+ parseManeuverProp() {
16
+ this.maneuverData = JSON.parse(this.maneuver);
17
+ }
18
+ parseTranslationsProp() {
19
+ this.translationsData = JSON.parse(this.translations);
20
+ }
21
+ componentWillLoad() {
22
+ this.parseManeuverProp();
23
+ this.parseTranslationsProp();
24
+ }
25
+ /**
26
+ * Get maneuver name.
27
+ *
28
+ * @returns {string}
29
+ */
30
+ getManeuverName(maneuver) {
31
+ if (maneuver.includes('straight'))
32
+ return 'straight';
33
+ if (maneuver.includes('sharp right'))
34
+ return 'sharp-right';
35
+ if (maneuver.includes('sharp left'))
36
+ return 'sharp-left';
37
+ if (maneuver.includes('slight right'))
38
+ return 'slight-right';
39
+ if (maneuver.includes('slight left'))
40
+ return 'slight-left';
41
+ if (maneuver.includes('right'))
42
+ return 'right';
43
+ if (maneuver.includes('left'))
44
+ return 'left';
45
+ if (maneuver.includes('uturn'))
46
+ return 'u-turn';
47
+ if (maneuver.includes('depart'))
48
+ return 'straight';
49
+ }
50
+ render() {
51
+ return (this.maneuverData && this.translationsData ? this.renderManeuver() : null);
52
+ }
53
+ /**
54
+ * Render step.
55
+ *
56
+ * @returns {JSX.Element}
57
+ */
58
+ renderManeuver() {
59
+ const maneuverStrings = {
60
+ 'straight': this.translationsData.continueStraightAhead, // 'Continue straight ahead',
61
+ 'left': `${this.translationsData.goLeft} ${this.translationsData.andContinue}`, // 'Go left and continue',
62
+ 'sharp-left': `${this.translationsData.goSharpLeft} ${this.translationsData.andContinue}`, // 'Go sharp left and continue',
63
+ 'slight-left': `${this.translationsData.goSlightLeft} ${this.translationsData.andContinue}`, // 'Go slight left and continue',
64
+ 'right': `${this.translationsData.goRight} ${this.translationsData.andContinue}`, // 'Go right and continue',
65
+ 'sharp-right': `${this.translationsData.goSharpRight} ${this.translationsData.andContinue}`, // 'Go sharp right and continue',
66
+ 'slight-right': `${this.translationsData.goSlightRight} ${this.translationsData.andContinue}`, // 'Go slight right and continue',
67
+ 'u-turn': `${this.translationsData.turnAround} ${this.translationsData.andContinue}`, // 'Turn around and continue'
68
+ };
69
+ const maneuver = this.getManeuverName(this.maneuverData.maneuver.toLowerCase());
70
+ const iconName = `arrow-${maneuver}`;
71
+ // Check if the instructions property has a value otherwise fallback to maneuver property
72
+ const translatedManeuver = this.maneuverData.instructions ? this.maneuverData.instructions : maneuverStrings[maneuver];
73
+ return (h(Host, null, h("div", { class: "icon" }, maneuver ? h("mi-icon", { part: "maneuver-icon", "icon-name": iconName }) : null), h("div", { class: "description" }, h("div", { class: "description__text" }, translatedManeuver), h("mi-distance", { part: "maneuver-description-distance", meters: this.maneuverData.distance.value, unit: this.unit }))));
74
+ }
75
+ static get watchers() { return {
76
+ "maneuver": [{
77
+ "parseManeuverProp": 0
78
+ }],
79
+ "translations": [{
80
+ "parseTranslationsProp": 0
81
+ }]
82
+ }; }
79
83
  };
80
- RouteInstructionsManeuver.style = routeInstructionsManeuverCss;
84
+ RouteInstructionsManeuver.style = routeInstructionsManeuverCss();
81
85
 
82
86
  export { RouteInstructionsManeuver as mi_route_instructions_maneuver };