import { defineComponent as C, computed as l, resolveComponent as p, resolveDirective as g, createElementBlock as S, openBlock as n, renderSlot as y, withDirectives as r, createCommentVNode as u, createVNode as A, createBlock as a, withCtx as B, normalizeClass as I } from "vue";
import { _ as O } from "./install-BuMO14Rb.js";
const R = { class: "wt-table-actions" }, U = /* @__PURE__ */ C({
  __name: "wt-table-actions",
  props: {
    icons: { default: () => [
      "refresh"
    ] },
    isSettingsActive: { type: Boolean, default: !1 },
    isSettingsBadge: { type: Boolean, default: !1 }
  },
  emits: ["input"],
  setup(d) {
    const i = d, m = l(() => i.icons.indexOf("import") !== -1), f = l(() => i.icons.indexOf("export") !== -1), v = l(
      () => i.icons.indexOf("filter-reset") !== -1
    ), $ = l(
      () => i.icons.indexOf("column-select") !== -1
    ), b = l(() => i.icons.indexOf("refresh") !== -1), k = l(() => i.icons.indexOf("settings") !== -1);
    return (e, t) => {
      const o = p("wt-icon-btn"), w = p("wt-badge"), s = g("tooltip");
      return n(), S("aside", R, [
        y(e.$slots, "default", {}, void 0, !0),
        m.value ? r((n(), a(o, {
          key: 0,
          icon: "download",
          onClick: t[0] || (t[0] = (c) => e.$emit("input", "import"))
        }, null, 512)), [
          [s, e.$t("reusable.import")]
        ]) : u("", !0),
        f.value ? r((n(), a(o, {
          key: 1,
          icon: "upload",
          onClick: t[1] || (t[1] = (c) => e.$emit("input", "export"))
        }, null, 512)), [
          [s, e.$t("reusable.export")]
        ]) : u("", !0),
        v.value ? r((n(), a(o, {
          key: 2,
          icon: "clear",
          onClick: t[2] || (t[2] = (c) => e.$emit("input", "filterReset"))
        }, null, 512)), [
          [s, e.$t("webitelUI.tableActions.filterReset")]
        ]) : u("", !0),
        $.value ? r((n(), a(o, {
          key: 3,
          icon: "column-select",
          onClick: t[3] || (t[3] = (c) => e.$emit("input", "columnSelect"))
        }, null, 512)), [
          [s, e.$t("webitelUI.tableActions.columnSelect")]
        ]) : u("", !0),
        b.value ? r((n(), a(o, {
          key: 4,
          icon: "refresh",
          onClick: t[4] || (t[4] = (c) => e.$emit("input", "refresh"))
        }, null, 512)), [
          [s, e.$t("webitelUI.tableActions.refreshTable")]
        ]) : u("", !0),
        A(w, {
          hidden: !d.isSettingsBadge
        }, {
          default: B(() => [
            k.value ? r((n(), a(o, {
              key: 0,
              class: I({ active: d.isSettingsActive }),
              icon: "filter",
              onClick: t[5] || (t[5] = (c) => e.$emit("input", "settings"))
            }, null, 8, ["class"])), [
              [s, e.$t("webitelUI.tableActions.expandFilters")]
            ]) : u("", !0)
          ], void 0, !0),
          _: 1
        }, 8, ["hidden"])
      ]);
    };
  }
}), E = /* @__PURE__ */ O(U, [["__scopeId", "data-v-73cf33d9"]]);
export {
  E as default
};
