import { unsafeCSS, html } from "lit";
import { property } from "lit/decorators.js";
import { customElement } from "../../decorator.js";
import { ObcAbstractPoiObject } from "../building-blocks/poi-object/abstract-poi-object.js";
import { ObcPoiObjectType } from "../building-blocks/poi-object/poi-object.js";
import componentStyle from "./poi-object-vessel.css.js";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __decorateClass = (decorators, target, key, kind) => {
  var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc(target, key) : target;
  for (var i = decorators.length - 1, decorator; i >= 0; i--)
    if (decorator = decorators[i])
      result = (kind ? decorator(target, key, result) : decorator(result)) || result;
  if (kind && result) __defProp(target, key, result);
  return result;
};
var ObcPoiObjectVesselType = /* @__PURE__ */ ((ObcPoiObjectVesselType2) => {
  ObcPoiObjectVesselType2["Indicator"] = "indicator";
  ObcPoiObjectVesselType2["Regular"] = "regular";
  ObcPoiObjectVesselType2["Large"] = "large";
  ObcPoiObjectVesselType2["SpeedRot"] = "speed-rot";
  ObcPoiObjectVesselType2["NUp"] = "n-up";
  ObcPoiObjectVesselType2["NUpLarge"] = "n-up-large";
  return ObcPoiObjectVesselType2;
})(ObcPoiObjectVesselType || {});
var ObcPoiObjectVesselStyle = /* @__PURE__ */ ((ObcPoiObjectVesselStyle2) => {
  ObcPoiObjectVesselStyle2["Regular"] = "regular";
  ObcPoiObjectVesselStyle2["Categorical"] = "categorical";
  ObcPoiObjectVesselStyle2["Enhanced"] = "enhanced";
  return ObcPoiObjectVesselStyle2;
})(ObcPoiObjectVesselStyle || {});
var ObcPoiObjectVesselState = /* @__PURE__ */ ((ObcPoiObjectVesselState2) => {
  ObcPoiObjectVesselState2["Unchecked"] = "unchecked";
  ObcPoiObjectVesselState2["Checked"] = "checked";
  ObcPoiObjectVesselState2["StaticUnchecked"] = "static-unchecked";
  ObcPoiObjectVesselState2["StaticChecked"] = "static-checked";
  ObcPoiObjectVesselState2["Activated"] = "activated";
  ObcPoiObjectVesselState2["Overlapped"] = "overlapped";
  ObcPoiObjectVesselState2["Caution"] = "caution";
  ObcPoiObjectVesselState2["Warning"] = "warning";
  ObcPoiObjectVesselState2["Alarm"] = "alarm";
  return ObcPoiObjectVesselState2;
})(ObcPoiObjectVesselState || {});
let ObcPoiObjectVessel = class extends ObcAbstractPoiObject {
  constructor() {
    super(...arguments);
    this.type = "regular";
  }
  get isSpeedRot() {
    return this.type === "speed-rot";
  }
  get baseType() {
    switch (this.type) {
      case "indicator":
        return ObcPoiObjectType.Indicator;
      case "regular":
        return ObcPoiObjectType.Regular;
      case "large":
      case "speed-rot":
        return ObcPoiObjectType.Large;
      case "n-up":
        return ObcPoiObjectType.NUp;
      case "n-up-large":
        return ObcPoiObjectType.NUpLarge;
      default:
        return ObcPoiObjectType.Regular;
    }
  }
  get icon() {
    if (this.isSpeedRot) {
      return html`
        <div class="speed-rot-wrapper">
          <div class="turn-indicator">
            <slot name="turn-indicator"></slot>
          </div>
          <div class="vessel-icon">
            <slot></slot>
          </div>
          <div class="speed-indicator">
            <slot name="speed-indicator"></slot>
          </div>
        </div>
      `;
    }
    return html`<slot></slot>`;
  }
};
ObcPoiObjectVessel.styles = [
  ...ObcAbstractPoiObject.styles,
  unsafeCSS(componentStyle)
];
__decorateClass([
  property({ type: String })
], ObcPoiObjectVessel.prototype, "type", 2);
ObcPoiObjectVessel = __decorateClass([
  customElement("obc-poi-object-vessel")
], ObcPoiObjectVessel);
export {
  ObcPoiObjectVessel,
  ObcPoiObjectVesselState,
  ObcPoiObjectVesselStyle,
  ObcPoiObjectVesselType
};
//# sourceMappingURL=poi-object-vessel.js.map
