1 | "use strict";
|
2 |
|
3 | Object.defineProperty(exports, "__esModule", {
|
4 | value: true
|
5 | });
|
6 | exports.default = void 0;
|
7 |
|
8 | var _vue = require("vue");
|
9 |
|
10 | var _CalendarOutlined = _interopRequireDefault(require("@ant-design/icons-vue/CalendarOutlined"));
|
11 |
|
12 | var _propsUtil = require("../_util/props-util");
|
13 |
|
14 | var _vnode = require("../_util/vnode");
|
15 |
|
16 | var _classNames2 = _interopRequireDefault(require("../_util/classNames"));
|
17 |
|
18 | function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
19 |
|
20 | function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
21 |
|
22 | function _isSlot(s) {
|
23 | return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !(0, _vue.isVNode)(s);
|
24 | }
|
25 |
|
26 | var InputIcon = function InputIcon(_, _ref) {
|
27 | var _classNames;
|
28 |
|
29 | var attrs = _ref.attrs;
|
30 |
|
31 | var _a, _b;
|
32 |
|
33 | var suffixIcon = attrs.suffixIcon,
|
34 | prefixCls = attrs.prefixCls;
|
35 | return (suffixIcon && (0, _propsUtil.isValidElement)(suffixIcon) ? (0, _vnode.cloneElement)(suffixIcon, {
|
36 | class: (0, _classNames2.default)((_classNames = {}, _defineProperty(_classNames, (_a = suffixIcon.props) === null || _a === void 0 ? void 0 : _a.class, (_b = suffixIcon.props) === null || _b === void 0 ? void 0 : _b.class), _defineProperty(_classNames, "".concat(prefixCls, "-picker-icon"), true), _classNames))
|
37 | }) : (0, _vue.createVNode)("span", {
|
38 | "class": "".concat(prefixCls, "-picker-icon")
|
39 | }, _isSlot(suffixIcon) ? suffixIcon : {
|
40 | default: function _default() {
|
41 | return [suffixIcon];
|
42 | }
|
43 | })) || (0, _vue.createVNode)(_CalendarOutlined.default, {
|
44 | "class": "".concat(prefixCls, "-picker-icon")
|
45 | }, null);
|
46 | };
|
47 |
|
48 | InputIcon.inheritAttrs = false;
|
49 | var _default2 = InputIcon;
|
50 | exports.default = _default2; |
\ | No newline at end of file |