@mapvx/web-components 0.0.21 → 0.0.22

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,15 +1,15 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./consume-BqcKIzaR.cjs"),e=require("./lazy-load-jYim30I-.cjs"),t=require("./class-map-DsgSsfJZ.cjs");var r=Object.defineProperty,n=Object.getOwnPropertyDescriptor,i=(o,e,t,i)=>{for(var a,s=i>1?void 0:i?n(e,t):e,l=o.length-1;l>=0;l--)(a=o[l])&&(s=(i?a(e,t,s):a(s))||s);return i&&s&&r(e,t,s),s};exports.FloorSelector=class extends e.i{_selectFloor(o){this.dispatchEvent(new CustomEvent("floorChange",{detail:o,bubbles:!0,composed:!0}))}render(){if(!this.sdkData)return e.x`<div>No data</div>`;const{currentFloor:o,parentPlace:r,enabledFloors:n}=this.sdkData;let i=r?.innerFloors||[];const a=this.sdkData?.generalConfig?.enabledFloors||[];return a.length>0&&(i=i.filter((o=>a.includes(o.key)))),e.x`
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./lazy-load-DWZU-puG.cjs"),e=require("./class-map-BGLcy4Zq.cjs"),t=require("./base-floor-selector-DHIQdC2s.cjs");var r=Object.getOwnPropertyDescriptor;exports.FloorSelector=class extends t.BaseFloorSelector{render(){if(!this.sdkData)return o.x`<div>No data</div>`;const t=this.getFloors();return o.x`
2
2
  <div class="floor-selector-container">
3
- ${i.map((r=>{const i=r.key===o?.key,a=n?.some((o=>o.key===r.key))||!1;return e.x`
3
+ ${t.map((t=>{const r=this.isFloorActive(t),n=this.isFloorEnabled(t);return o.x`
4
4
  <div class="floor-btn-container">
5
5
  <button
6
- class=${t.e({"floor-btn":!0,active:i,disabled:!i&&!a})}
7
- @click=${()=>a?this._selectFloor(r.key):null}
6
+ class=${e.e({"floor-btn":!0,active:r,disabled:!r&&!n})}
7
+ @click=${()=>n?this.selectFloor(t.key):null}
8
8
  >
9
- <span>${r.name}</span>
9
+ <span>${this.getFloorDisplayName(t)}</span>
10
10
  </button>
11
11
  </div>
12
12
  `}))}
13
13
  </div>
14
- `}},exports.FloorSelector.styles=[e.r(':host{position:absolute;top:0;right:10px}.floor-selector-container{display:flex;flex-direction:row;background:#fff;border-radius:0 0 30px 30px;box-shadow:0 0 15px #00000026;padding:0 6px;gap:8px;height:65px}.btn-floor{height:auto;width:100px;vertical-align:middle;font-size:small!important;word-wrap:break-word!important;font-family:Poppins;font-weight:600;font-size:16pt;border-radius:10px;border:0;box-shadow:0 0 15px #00000026}@media only screen and (max-width: 576px){.btn-floor{padding:6px;width:70px;height:auto;font-size:small!important}}.floor-btn-container:hover .floor-btn:not(.active):not(.disabled){border-radius:0 0 999px 999px;background:#000;color:#fff}.floor-btn{transition:background .2s ease,color .2s ease,transform .2s ease,opacity .2s ease;position:relative;background:transparent;border:none;outline:none;font-family:Poppins,sans-serif;font-weight:600;font-size:13px;border-radius:0 0 30px 30px;cursor:pointer;transition:all .2s ease;height:100%;min-width:65px;display:flex;align-items:center;justify-content:center;color:#000;z-index:1;span{min-width:50px}}.floor-btn.disabled{color:#c5c3c3;background:transparent;pointer-events:none;-webkit-tap-highlight-color:transparent;user-select:none}.floor-btn.active{color:#fff;background:transparent;z-index:2}.floor-btn.active:after{content:"";position:absolute;inset:0 2px;border-radius:0 0 999px 999px;background:#000;color:#fff;z-index:1}.floor-btn.active:before{content:"";position:absolute;inset:0 -3px -3px;border-radius:0 0 999px 999px;background:linear-gradient(45.8deg,#f5a 10.03%,#b850c9 25.23%,#6572d6 48.67%,#4eaeb8 72.74%);z-index:0}.floor-btn.active span{z-index:10}@media (max-width: 1100px){.floor-btn-container:hover .floor-btn:not(.active):not(.disabled){border-radius:999px 0 0 999px;background:#000;color:#fff}.floor-selector-container{right:0;position:fixed;top:50%;transform:translateY(-50%);display:flex;flex-direction:column-reverse;border-radius:30px 0 0 30px;min-width:87px;max-height:100%;height:auto;padding:0;gap:0}.floor-btn-container{padding:0;width:100%}.floor-btn{width:100%;padding:20px;border-radius:999px 0 0 999px}.floor-btn.active:after{position:absolute;inset:2px 0 2px 2px;border-radius:999px 0 0 999px}.floor-btn.active:before{inset:-3px 0 -3px -3px;border-radius:999px 0 0 999px}}')],i([o.c({context:e.sdkContext,subscribe:!0})],exports.FloorSelector.prototype,"sdkData",2),exports.FloorSelector=i([e.t("floor-selector")],exports.FloorSelector);
15
- //# sourceMappingURL=floor-selector-Bs-_2vdJ.cjs.map
14
+ `}},exports.FloorSelector.styles=[o.r(':host{position:absolute;top:0;right:10px}.floor-selector-container{display:flex;flex-direction:row;background:#fff;border-radius:0 0 30px 30px;box-shadow:0 0 15px #00000026;padding:0 6px;gap:8px;height:65px}.btn-floor{height:auto;width:100px;vertical-align:middle;font-size:small!important;word-wrap:break-word!important;font-family:Poppins;font-weight:600;font-size:16pt;border-radius:10px;border:0;box-shadow:0 0 15px #00000026}@media only screen and (max-width: 576px){.btn-floor{padding:6px;width:70px;height:auto;font-size:small!important}}.floor-btn-container:hover .floor-btn:not(.active):not(.disabled){border-radius:0 0 999px 999px;background:#000;color:#fff}.floor-btn{transition:background .2s ease,color .2s ease,transform .2s ease,opacity .2s ease;position:relative;background:transparent;border:none;outline:none;font-family:Poppins,sans-serif;font-weight:600;font-size:13px;border-radius:0 0 30px 30px;cursor:pointer;transition:all .2s ease;height:100%;min-width:65px;display:flex;align-items:center;justify-content:center;color:#000;z-index:1;span{min-width:50px}}.floor-btn.disabled{color:#c5c3c3;background:transparent;pointer-events:none;-webkit-tap-highlight-color:transparent;user-select:none}.floor-btn.active{color:#fff;background:transparent;z-index:2}.floor-btn.active:after{content:"";position:absolute;inset:0 2px;border-radius:0 0 999px 999px;background:#000;color:#fff;z-index:1}.floor-btn.active:before{content:"";position:absolute;inset:0 -3px -3px;border-radius:0 0 999px 999px;background:linear-gradient(45.8deg,#f5a 10.03%,#b850c9 25.23%,#6572d6 48.67%,#4eaeb8 72.74%);z-index:0}.floor-btn.active span{z-index:10}@media (max-width: 1100px){.floor-btn-container:hover .floor-btn:not(.active):not(.disabled){border-radius:999px 0 0 999px;background:#000;color:#fff}.floor-selector-container{right:0;position:fixed;top:50%;transform:translateY(-50%);display:flex;flex-direction:column-reverse;border-radius:30px 0 0 30px;min-width:87px;max-height:100%;height:auto;padding:0;gap:0}.floor-btn-container{padding:0;width:100%}.floor-btn{width:100%;padding:20px;border-radius:999px 0 0 999px}.floor-btn.active:after{position:absolute;inset:2px 0 2px 2px;border-radius:999px 0 0 999px}.floor-btn.active:before{inset:-3px 0 -3px -3px;border-radius:999px 0 0 999px}}')],exports.FloorSelector=((o,e,t,n)=>{for(var i,a=n>1?void 0:n?r(e,t):e,s=o.length-1;s>=0;s--)(i=o[s])&&(a=i(a)||a);return a})([o.t("floor-selector")],exports.FloorSelector);
15
+ //# sourceMappingURL=floor-selector-Bp_umxgG.cjs.map