UNPKG

@progress/kendo-vue-layout

Version:
76 lines (75 loc) 1.99 kB
/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2026 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- */ import { defineComponent as o, createVNode as i } from "vue"; import { focusFirstFocusableChild as r, getDefaultSlots as p, validatePackage as s, guid as d } from "@progress/kendo-vue-common"; import { packageMetadata as n } from "../package-metadata.mjs"; const f = /* @__PURE__ */ o({ name: "KendoAppBar", props: { id: String, themeColor: { type: String, default: "base", validator: function(t) { return ["base", "primary", "secondary", "tertiary", "inverse"].includes(t); } }, position: { type: String, default: "top", validator: function(t) { return ["top", "bottom"].includes(t); } }, positionMode: { type: String, default: "static", validator: function(t) { return ["static", "sticky", "fixed"].includes(t); } } }, created() { s(n), this.calculatedId = d(); }, computed: { wrapperClass() { const { position: t, positionMode: e, themeColor: a } = this.$props; return { "k-appbar": !0, "k-appbar-top": t === "top", "k-appbar-bottom": t === "bottom", "k-appbar-static": e === "static", "k-appbar-sticky": e === "sticky", "k-appbar-fixed": e === "fixed", [`k-appbar-${a}`]: !!a }; } }, render() { const t = p(this), { id: e } = this.$props; return i("div", { class: this.wrapperClass, id: e || this.calculatedId }, [t]); }, methods: { focus() { this.$el && r(this.$el); } } }); export { f as AppBar };