const require_runtime = require("../../../_virtual/_rolldown/runtime.js");
const require_index = require("../../../locales/index.js");
const require_objectSpread2 = require("../../../_virtual/_@oxc-project_runtime@0.122.0/helpers/objectSpread2.js");
let react = require("react");
react = require_runtime.__toESM(react);
let antd = require("antd");
let _pisell_icon_es_FilterFunnel01 = require("@pisell/icon/es/FilterFunnel01");
_pisell_icon_es_FilterFunnel01 = require_runtime.__toESM(_pisell_icon_es_FilterFunnel01);
let _pisell_icon_es_FilterFunnel01Fill = require("@pisell/icon/es/FilterFunnel01Fill");
_pisell_icon_es_FilterFunnel01Fill = require_runtime.__toESM(_pisell_icon_es_FilterFunnel01Fill);
require("./index.less");
//#region src/components/table/TableFilter/numberFilter.tsx
const getColumnNumberProps = ({ dataIndex }) => ({
	filterDropdown: ({ setSelectedKeys, selectedKeys, confirm, clearFilters, close }) => {
		var _selectedKeys$, _selectedKeys$2;
		return /* @__PURE__ */ react.default.createElement("div", {
			onKeyDown: (e) => e.stopPropagation(),
			className: "pisell-table-filter-dropdown"
		}, /* @__PURE__ */ react.default.createElement(antd.Space, {
			split: "-",
			className: "pisell-table-filter-dropdown-top"
		}, /* @__PURE__ */ react.default.createElement(antd.InputNumber, {
			value: selectedKeys === null || selectedKeys === void 0 || (_selectedKeys$ = selectedKeys[0]) === null || _selectedKeys$ === void 0 ? void 0 : _selectedKeys$.min,
			onChange: (value) => {
				setSelectedKeys([require_objectSpread2._objectSpread2(require_objectSpread2._objectSpread2({}, (selectedKeys === null || selectedKeys === void 0 ? void 0 : selectedKeys[0]) || {}), {}, { min: value })]);
			},
			placeholder: require_index.getText("table-filter-min"),
			onPressEnter: () => confirm(),
			style: { width: 105 }
		}), /* @__PURE__ */ react.default.createElement(antd.InputNumber, {
			value: selectedKeys === null || selectedKeys === void 0 || (_selectedKeys$2 = selectedKeys[0]) === null || _selectedKeys$2 === void 0 ? void 0 : _selectedKeys$2.max,
			placeholder: require_index.getText("table-filter-max"),
			onChange: (value) => {
				setSelectedKeys([require_objectSpread2._objectSpread2(require_objectSpread2._objectSpread2({}, (selectedKeys === null || selectedKeys === void 0 ? void 0 : selectedKeys[0]) || {}), {}, { max: value })]);
			},
			onPressEnter: () => confirm(),
			style: { width: 105 }
		})), /* @__PURE__ */ react.default.createElement(antd.Space, {
			className: "pisell-table-filter-dropdown-bottom",
			styles: { item: { flex: 1 } }
		}, /* @__PURE__ */ react.default.createElement(antd.Button, {
			onClick: () => {
				clearFilters && clearFilters();
				confirm();
			},
			block: true
		}, require_index.getText("table-filter-clear")), /* @__PURE__ */ react.default.createElement(antd.Button, {
			type: "primary",
			onClick: () => confirm(),
			block: true
		}, require_index.getText("table-filter-filter"))));
	},
	filterIcon: (filtered) => filtered ? /* @__PURE__ */ react.default.createElement(_pisell_icon_es_FilterFunnel01Fill.default, { style: {
		color: "#7f56d9",
		fontSize: 14
	} }) : /* @__PURE__ */ react.default.createElement(_pisell_icon_es_FilterFunnel01.default, { style: {
		color: "#98A2B3",
		fontSize: 14
	} })
});
//#endregion
exports.default = getColumnNumberProps;
