@nextcloud/vue
Version:
Nextcloud vue components
24 lines (23 loc) • 1.46 kB
JavaScript
import "../assets/NcAppNavigationToggle.css";
import n from "../Components/NcButton.mjs";
import "../Directives/Tooltip.mjs";
import { t as e } from "./l10n-9a5a6afc.mjs";
import a from "vue-material-design-icons/Menu.vue";
import i from "vue-material-design-icons/MenuOpen.vue";
import { n as r } from "./_plugin-vue2_normalizer-5b4c43a4.mjs";
import { VTooltip as p } from "floating-vue";
const l = { name: "NcAppNavigationToggle", directives: { tooltip: p }, components: { NcButton: n, MenuIcon: a, MenuOpenIcon: i }, props: { open: { type: Boolean, required: !0 } }, emits: ["update:open"], computed: { label() {
return this.open ? e("Close navigation") : e("Open navigation");
} }, methods: { toggleNavigation() {
this.$emit("update:open", !this.open);
} } };
var s = function() {
var o = this, t = o._self._c;
return t("NcButton", { directives: [{ name: "tooltip", rawName: "v-tooltip.auto", value: o.label, expression: "label", modifiers: { auto: !0 } }], staticClass: "app-navigation-toggle", attrs: { type: "tertiary", "aria-expanded": o.open ? "true" : "false", "aria-label": o.label, "aria-controls": "app-navigation-vue" }, on: { click: o.toggleNavigation }, scopedSlots: o._u([{ key: "icon", fn: function() {
return [o.open ? t("MenuOpenIcon", { attrs: { size: 20 } }) : t("MenuIcon", { attrs: { size: 20 } })];
}, proxy: !0 }]) });
}, u = [], m = r(l, s, u, !1, null, "83ed51ad", null, null);
const x = m.exports;
export {
x as N
};