@progress/kendo-vue-grid
Version:
96 lines (95 loc) • 2.66 kB
JavaScript
/**
* @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 b, createVNode as t, h as v } from "vue";
import { GridColumnMenuFilterCell as n } from "./GridColumnMenuFilterCell.mjs";
import { DropDownList as T } from "@progress/kendo-vue-dropdowns";
import { getTemplate as $ } from "@progress/kendo-vue-common";
const H = /* @__PURE__ */ b({
name: "KendoGridColumnMenuFilterUI",
inheritAttrs: !1,
props: {
firstFilterProps: Object,
secondFilterProps: Object,
logicValue: Object,
logicData: Array,
hideSecondFilter: Boolean,
operators: Array,
render: [String, Function, Object]
},
emits: {
change: null,
filteruifocus: null,
logicChange: null
},
methods: {
handleFocus(e) {
this.$emit("filteruifocus", e);
},
changeHandler(e, o) {
this.$emit("change", e, o);
},
logicChange(e) {
this.$emit("logicChange", e);
}
},
render() {
const {
firstFilterProps: e,
hideSecondFilter: o,
secondFilterProps: l,
logicData: a,
logicValue: s,
operators: i,
render: c
} = this.$props, d = e.field, u = e.value, h = e.operator, p = e.booleanValues, f = e.filterType, g = l.field, m = l.value, F = l.operator, C = l.booleanValues, V = l.filterType, y = t("div", {
style: this.$attrs.style,
class: this.$attrs.class
}, [t(n, {
field: d,
value: u,
operator: h,
booleanValues: p,
filterType: f,
onFiltercellfocus: this.handleFocus,
onChange: (r) => {
this.changeHandler(r, 0);
},
operators: i
}, null), !o && t("div", null, [t(T, {
onChange: this.logicChange,
class: "k-filter-and",
"data-items": a,
value: s,
textField: "text"
}, null), t(n, {
field: g,
value: m,
operator: F,
booleanValues: C,
filterType: V,
onFiltercellfocus: this.handleFocus,
onChange: (r) => {
this.changeHandler(r, 1);
},
operators: i
}, null)])]);
return $.call(this, {
h: v,
template: c,
defaultRendering: y,
additionalProps: this.$props,
additionalListeners: {
change: this.changeHandler,
logicchange: this.logicChange
}
});
}
});
export {
H as GridColumnMenuFilterUI
};