UNPKG

@nextcloud/vue

Version:
24 lines (23 loc) 776 B
import { A as i } from "./actionGlobal-cda46023.mjs"; const o = function(n, t) { let e = n.$parent; for (; e; ) { if (e.$options.name === t) return e; e = e.$parent; } }, c = { mixins: [i], props: { icon: { type: String, default: "" }, name: { type: String, default: "" }, title: { type: String, default: "" }, closeAfterClick: { type: Boolean, default: !1 }, ariaLabel: { type: String, default: "" }, ariaHidden: { type: Boolean, default: null } }, emits: ["click"], computed: { isIconUrl() { try { return new URL(this.icon); } catch { return !1; } } }, methods: { onClick(n) { if (this.$emit("click", n), this.closeAfterClick) { const t = o(this, "NcActions"); t && t.closeMenu && t.closeMenu(!1); } } } }; export { c as A };