import { BREADCRUMB_ITEM_SELECTED_MODIFIER as l } from "./breadcrumbs-constants.js";
import { removeClassStyleAttrs as i, addClassStyleAttrs as s } from "../../common/utils/index.js";
import { resolveComponent as o, openBlock as m, createElementBlock as c, mergeProps as a, createVNode as u, withCtx as f, renderSlot as _, createTextVNode as p, toDisplayString as E } from "vue";
import { _ as C } from "../../_plugin-vue_export-helper-CHgC5LLL.js";
import k from "../link/link.js";
import { MUTED as D } from "../link/link-constants.js";
const b = {
  name: "DtBreadcrumbItem",
  components: {
    DtLink: k
  },
  inheritAttrs: !1,
  props: {
    /**
     * Passed through to link. If true, applies inverted styles to the link.
     */
    inverted: {
      type: Boolean,
      default: !1
    },
    /**
     * Applies selected styles to the breadcrumb
     */
    selected: {
      type: Boolean,
      default: !1
    },
    /**
     * Describes the breadcrumb. Overridden by default slot
     */
    label: {
      type: String,
      default: ""
    }
  },
  data() {
    return {
      BREADCRUMB_ITEM_SELECTED_MODIFIER: l
    };
  },
  computed: {
    linkKind() {
      return this.inverted ? "" : D;
    },
    linkInverted() {
      return !!this.inverted;
    },
    ariaCurrent() {
      return this.selected ? "location" : void 0;
    }
  },
  methods: {
    removeClassStyleAttrs: i,
    addClassStyleAttrs: s
  }
};
function v(t, B, r, I, n, e) {
  const d = o("dt-link");
  return m(), c("li", a({
    "data-qa": "dt-breadcrumb-item",
    class: [
      "d-breadcrumbs__item",
      { [n.BREADCRUMB_ITEM_SELECTED_MODIFIER]: r.selected }
    ]
  }, e.addClassStyleAttrs(t.$attrs)), [
    u(d, a({
      kind: e.linkKind,
      inverted: e.linkInverted,
      "aria-current": e.ariaCurrent,
      "data-qa": "breadcrumb-item"
    }, e.removeClassStyleAttrs(t.$attrs)), {
      default: f(() => [
        _(t.$slots, "default", {}, () => [
          p(E(r.label), 1)
        ])
      ]),
      _: 3
    }, 16, ["kind", "inverted", "aria-current"])
  ], 16);
}
const T = /* @__PURE__ */ C(b, [["render", v]]);
export {
  T as default
};
//# sourceMappingURL=breadcrumb-item.js.map
