@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.
- package/dist/{GoogleMapsMap-C5n6Bgtp.mjs → GoogleMapsMap-Dkn60-_e.mjs} +2 -2
- package/dist/{MapboxMap-UCqzt1AC.mjs → MapboxMap-B1oo7IUm.mjs} +2 -2
- package/dist/_commonjsHelpers-B85MJLTf.js +5 -0
- package/dist/app-globals-DQuL1Twl.js +3 -0
- package/dist/combo-box-item.entry.js +8 -10
- package/dist/icon-DT_sDkmK.js +11 -0
- package/dist/index-BZQHyS7V.js +1701 -0
- package/dist/loader.js +7 -14
- package/dist/mapsindoors-react.es.js +1 -1
- package/dist/mapsindoors-react.umd.js +175 -175
- package/dist/mapsindoors-webcomponent.es.js +2916 -2904
- package/dist/mi-card_2.entry.js +23 -18
- package/dist/mi-chip.entry.js +25 -16
- package/dist/mi-column.entry.js +47 -23
- package/dist/mi-combo-box.entry.js +412 -379
- package/dist/mi-components.js +15 -12
- package/dist/mi-data-table.entry.js +298 -278
- package/dist/mi-distance_2.entry.js +58 -56
- package/dist/mi-dropdown-item.entry.js +8 -10
- package/dist/mi-dropdown.entry.js +525 -481
- package/dist/mi-floor-selector.entry.js +183 -180
- package/dist/mi-keyboard.entry.js +207 -186
- package/dist/mi-list-item-category.entry.js +44 -41
- package/dist/mi-list-item-location.entry.js +168 -162
- package/dist/mi-list.entry.js +56 -48
- package/dist/mi-location-booking.entry.js +320 -295
- package/dist/mi-location-info.entry.js +61 -53
- package/dist/mi-map-googlemaps.entry.js +369 -324
- package/dist/mi-map-mapbox.entry.js +502 -439
- package/dist/mi-metric-card.entry.js +50 -37
- package/dist/mi-my-position.entry.js +2341 -874
- package/dist/mi-notification.entry.js +112 -102
- package/dist/mi-route-instructions-heading.entry.js +70 -65
- package/dist/mi-route-instructions-maneuver-legacy.entry.js +80 -76
- package/dist/mi-route-instructions-maneuver.entry.js +80 -76
- package/dist/mi-route-instructions-step-legacy.entry.js +296 -282
- package/dist/mi-route-instructions-step.entry.js +313 -292
- package/dist/mi-route-instructions.entry.js +167 -150
- package/dist/mi-scroll-buttons.entry.js +104 -98
- package/dist/mi-search.entry.js +366 -325
- package/dist/mi-share-sms.entry.js +82 -70
- package/dist/mi-step-switcher.entry.js +34 -25
- package/dist/mi-tab-panel.entry.js +18 -18
- package/dist/mi-tab.entry.js +5 -7
- package/dist/mi-tabs.entry.js +42 -40
- package/dist/mi-time.entry.js +49 -49
- package/dist/mi-variables-CDNvnTkH.js +5 -0
- package/dist/{reactcomponent-DQsjxRIN.mjs → reactcomponent-2Oa1vSiK.mjs} +8996 -8660
- package/dist/route-travel-mode.enum-BvqP1fpw.js +9 -0
- package/dist/sort-order.enum-jsLAbYWg.js +566 -0
- package/dist/{unit-system.enum-eaefb53e.js → unit-system.enum-BwPgAWqL.js} +2 -2
- package/dist/utils-DNHzysQ6.js +61 -0
- package/package.json +1 -1
- package/dist/_commonjsHelpers-ba3f0406.js +0 -21
- package/dist/icon-b8d01d6f.js +0 -24
- package/dist/index-7e9696f3.js +0 -1678
- package/dist/mi-variables-9a6c8d4d.js +0 -6
- package/dist/polyfills/core-js.js +0 -11
- package/dist/polyfills/css-shim.js +0 -1
- package/dist/polyfills/dom.js +0 -79
- package/dist/polyfills/es5-html-element.js +0 -1
- package/dist/polyfills/index.js +0 -34
- package/dist/polyfills/system.js +0 -6
- package/dist/route-travel-mode.enum-7f4ce9c7.js +0 -9
- package/dist/sort-order.enum-64ce8998.js +0 -552
- package/dist/utils-ae714467.js +0 -61
|
@@ -1,48 +1,61 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host } from './index-
|
|
2
|
-
import {
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-BZQHyS7V.js';
|
|
2
|
+
import { f as formatNumber, a as isNumber } from './utils-DNHzysQ6.js';
|
|
3
3
|
|
|
4
|
-
const metricCardCss =
|
|
4
|
+
const metricCardCss = () => `:host{font-family:Figtree, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";flex-shrink:0;flex-grow:1}:host mi-card{position:relative;overflow:hidden;min-width:312px}:host mi-card .content h1{display:inline-flex;cursor:default;align-items:center;text-transform:uppercase;white-space:nowrap;margin:0;font-size:1rem;font-weight:600;color:#6b7280;margin-bottom:8px}:host mi-card .content h1 svg{fill:#9ca3af;width:16px;height:16px;margin-left:8px}:host mi-card .content section{position:relative}:host mi-card .content section p{margin:0;font-size:3rem;line-height:3rem;font-weight:500;color:#1c1917}:host mi-card .content section p.error{font-size:1rem;font-weight:500;color:#6b7280}:host mi-card .content section p.hidden{visibility:hidden}:host mi-card .content section p.tool-tip{box-sizing:border-box;visibility:hidden;overflow:hidden;position:absolute;top:0px;right:0px;bottom:0px;left:0px;opacity:0;transition:all 100ms;z-index:700;background-color:#ffffff;font-size:0.875rem;font-weight:400;line-height:1rem;margin:0}:host mi-card .content section p.tool-tip.visible{opacity:1;visibility:visible}:host mi-card .content section mi-spinner{display:inline-block;vertical-align:middle;width:100%}`;
|
|
5
5
|
|
|
6
6
|
const MetricCard = class {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
7
|
+
constructor(hostRef) {
|
|
8
|
+
registerInstance(this, hostRef);
|
|
9
|
+
this.showToolTip = false;
|
|
10
|
+
/**
|
|
11
|
+
* This is the metric title.
|
|
12
|
+
* @type {string}
|
|
13
|
+
* @memberof MetricCard
|
|
14
|
+
*/
|
|
15
|
+
this.label = '';
|
|
16
|
+
/**
|
|
17
|
+
* This is the metric value.
|
|
18
|
+
* @type {string}
|
|
19
|
+
* @memberof MetricCard
|
|
20
|
+
*/
|
|
21
|
+
this.value = '';
|
|
22
|
+
/**
|
|
23
|
+
* When present a loading spinner will be displayed until the value or error attribute is set or the spinner attribute is removed
|
|
24
|
+
* @type {boolean}
|
|
25
|
+
* @memberof MetricCard
|
|
26
|
+
*/
|
|
27
|
+
this.spinner = false;
|
|
22
28
|
}
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
if (this.tip > '') {
|
|
26
|
-
return h("svg", { xmlns: "http://www.w3.org/2000/svg", height: "24", viewBox: "0 0 24 24", width: "24" }, h("path", { d: "M0 0h24v24H0V0z", fill: "none" }), h("path", { d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 17h-2v-2h2v2zm2.07-7.75l-.9.92c-.5.51-.86.97-1.04 1.69-.08.32-.13.68-.13 1.14h-2v-.5c0-.46.08-.9.22-1.31.2-.58.53-1.1.95-1.52l1.24-1.26c.46-.44.68-1.1.55-1.8-.13-.72-.69-1.33-1.39-1.53-1.11-.31-2.14.32-2.47 1.27-.12.37-.43.65-.82.65h-.3C8.4 9 8 8.44 8.16 7.88c.43-1.47 1.68-2.59 3.23-2.83 1.52-.24 2.97.55 3.87 1.8 1.18 1.63.83 3.38-.19 4.4z" }));
|
|
29
|
+
render() {
|
|
30
|
+
return (h(Host, { key: '866f6311805722aa74911b0f2360860ab22d0fff' }, h("mi-card", { key: '6fad0cdf8ee8a281497dc7041188bd2d28615345' }, this.renderContent())));
|
|
27
31
|
}
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
value = isNumber(this.value) ? formatNumber(this.value) : this.value;
|
|
32
|
+
renderToolTip() {
|
|
33
|
+
if (this.tip > '') {
|
|
34
|
+
return h("p", { class: { 'tool-tip': true, 'visible': this.tip && this.showToolTip } }, this.tip);
|
|
35
|
+
}
|
|
33
36
|
}
|
|
34
|
-
|
|
35
|
-
|
|
37
|
+
getInfoIcon() {
|
|
38
|
+
if (this.tip > '') {
|
|
39
|
+
return h("svg", { xmlns: "http://www.w3.org/2000/svg", height: "24", viewBox: "0 0 24 24", width: "24" }, h("path", { d: "M0 0h24v24H0V0z", fill: "none" }), h("path", { d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 17h-2v-2h2v2zm2.07-7.75l-.9.92c-.5.51-.86.97-1.04 1.69-.08.32-.13.68-.13 1.14h-2v-.5c0-.46.08-.9.22-1.31.2-.58.53-1.1.95-1.52l1.24-1.26c.46-.44.68-1.1.55-1.8-.13-.72-.69-1.33-1.39-1.53-1.11-.31-2.14.32-2.47 1.27-.12.37-.43.65-.82.65h-.3C8.4 9 8 8.44 8.16 7.88c.43-1.47 1.68-2.59 3.23-2.83 1.52-.24 2.97.55 3.87 1.8 1.18 1.63.83 3.38-.19 4.4z" }));
|
|
40
|
+
}
|
|
36
41
|
}
|
|
37
|
-
|
|
38
|
-
|
|
42
|
+
renderContent() {
|
|
43
|
+
let value;
|
|
44
|
+
if (this.value) {
|
|
45
|
+
value = isNumber(this.value) ? formatNumber(this.value) : this.value;
|
|
46
|
+
}
|
|
47
|
+
else if (this.error) {
|
|
48
|
+
value = this.error;
|
|
49
|
+
}
|
|
50
|
+
else if (this.spinner) {
|
|
51
|
+
value = h("mi-spinner", null);
|
|
52
|
+
}
|
|
53
|
+
else {
|
|
54
|
+
value = ' ';
|
|
55
|
+
}
|
|
56
|
+
return h("div", { class: "content" }, h("h1", { onMouseOver: () => this.showToolTip = true, onMouseOut: () => this.showToolTip = false }, this.label, " ", this.getInfoIcon()), h("section", null, this.renderToolTip(), h("p", { class: { 'error': !!this.error, 'hidden': this.tip && this.showToolTip } }, value)));
|
|
39
57
|
}
|
|
40
|
-
else {
|
|
41
|
-
value = ' ';
|
|
42
|
-
}
|
|
43
|
-
return h("div", { class: "content" }, h("h1", { onMouseOver: () => this.showToolTip = true, onMouseOut: () => this.showToolTip = false }, this.label, " ", this.getInfoIcon()), h("section", null, this.renderToolTip(), h("p", { class: { 'error': !!this.error, 'hidden': this.tip && this.showToolTip } }, value)));
|
|
44
|
-
}
|
|
45
58
|
};
|
|
46
|
-
MetricCard.style = metricCardCss;
|
|
59
|
+
MetricCard.style = metricCardCss();
|
|
47
60
|
|
|
48
61
|
export { MetricCard as mi_metric_card };
|