UNPKG

@progress/kendo-vue-data-tools

Version:
74 lines (73 loc) 1.84 kB
/** * @license *------------------------------------------------------------------------------------------- * Copyright © 2025 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the package root for more information *------------------------------------------------------------------------------------------- */ import { defineComponent as d, inject as n, createVNode as s } from "vue"; import { noop as l, getDefaultSlots as c } from "@progress/kendo-vue-common"; import { KEYBOARD_NAV_DATA_LEVEL as m, KEYBOARD_NAV_DATA_ID as u } from "../navigation/constants.mjs"; const A = /* @__PURE__ */ d({ name: "KendoHeaderTdElement", emits: { keydown: null }, props: { ariaColumnIndex: Number, role: String, columnId: String, navigatable: Boolean }, computed: { tdClass() { const { className: e } = this.$props; return { "k-table-td": !0, [e]: e }; } }, inject: { getKeyboardNavigationAttributes: { default: l } }, setup() { const e = n("kendoIntlService", {}), t = n("kendoLocalizationService", {}); return { kendoIntlService: e, kendoLocalizationService: t }; }, render() { const { columnId: e, navigatable: t, ariaColumnIndex: a, role: r } = this.$props, o = this.getKeyboardNavigationAttributes(e, t), i = c(this); return s("td", { style: { top: "0px" }, "aria-colindex": a, class: this.tdClass, onKeydown: this.onKeyDown, role: r, tabindex: o.tabIndex, "data-keyboardnavlevel": o[m], "data-keyboardnavid": o[u] }, [i]); }, methods: { onKeyDown(e) { this.$emit("keydown", e); } } }); export { A as HeaderTdElement };