es-grid-template 0.0.5 → 0.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/LICENSE +19 -0
- package/README.md +1 -6
- package/{dist/components/GridTable → es}/CheckboxFilter.d.ts +1 -1
- package/es/CheckboxFilter.js +249 -0
- package/{dist/components/GridTable → es}/ColumnsChoose.d.ts +3 -2
- package/es/ColumnsChoose.js +213 -0
- package/{dist/components/GridTable → es}/ContextMenu.d.ts +1 -1
- package/es/ContextMenu.js +126 -0
- package/{dist/components/GridTable → es}/FilterSearch.d.ts +3 -3
- package/es/FilterSearch.js +33 -0
- package/es/GridTable.d.ts +7 -0
- package/es/GridTable.js +927 -0
- package/es/hooks/constant.js +214 -0
- package/es/hooks/index.js +5 -0
- package/{dist → es}/hooks/useColumns/index.d.ts +1 -1
- package/es/hooks/useColumns/index.js +25 -0
- package/{dist → es}/hooks/useIsOverflow.d.ts +1 -1
- package/es/hooks/useIsOverflow.js +17 -0
- package/es/hooks/useOnClickOutside.js +28 -0
- package/{dist → es}/hooks/utils.d.ts +6 -6
- package/es/hooks/utils.js +192 -0
- package/es/index.d.ts +2 -0
- package/es/index.js +2 -0
- package/es/styles.scss +30 -0
- package/es/type.d.ts +88 -0
- package/es/type.js +1 -0
- package/lib/CheckboxFilter.d.ts +19 -0
- package/lib/CheckboxFilter.js +257 -0
- package/lib/ColumnsChoose.d.ts +10 -0
- package/lib/ColumnsChoose.js +223 -0
- package/lib/ContextMenu.d.ts +20 -0
- package/lib/ContextMenu.js +135 -0
- package/lib/FilterSearch.d.ts +12 -0
- package/lib/FilterSearch.js +42 -0
- package/lib/GridTable.d.ts +7 -0
- package/lib/GridTable.js +936 -0
- package/lib/hooks/constant.d.ts +48 -0
- package/lib/hooks/constant.js +221 -0
- package/lib/hooks/index.d.ts +4 -0
- package/lib/hooks/index.js +49 -0
- package/lib/hooks/useColumns/index.d.ts +2 -0
- package/lib/hooks/useColumns/index.js +31 -0
- package/lib/hooks/useIsOverflow.d.ts +1 -0
- package/lib/hooks/useIsOverflow.js +26 -0
- package/lib/hooks/useOnClickOutside.d.ts +1 -0
- package/lib/hooks/useOnClickOutside.js +36 -0
- package/lib/hooks/utils.d.ts +18 -0
- package/lib/hooks/utils.js +215 -0
- package/lib/index.d.ts +2 -0
- package/lib/index.js +9 -0
- package/lib/styles.scss +30 -0
- package/lib/type.d.ts +88 -0
- package/lib/type.js +5 -0
- package/package.json +75 -94
- package/dist/components/GridTable/GridTable.d.ts +0 -6
- package/dist/components/GridTable/index.d.ts +0 -1
- package/dist/components/index.d.ts +0 -1
- package/dist/index.d.ts +0 -2
- package/dist/index.js +0 -53
- package/dist/type.d.ts +0 -44
- /package/{dist → es}/hooks/constant.d.ts +0 -0
- /package/{dist → es}/hooks/index.d.ts +0 -0
- /package/{dist → es}/hooks/useOnClickOutside.d.ts +0 -0
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.default = void 0;
|
|
8
|
+
var React = _interopRequireWildcard(require("react"));
|
|
9
|
+
var _SearchOutlined = _interopRequireDefault(require("@ant-design/icons/SearchOutlined"));
|
|
10
|
+
var _uiRc = require("ui-rc");
|
|
11
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
12
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
13
|
+
const FilterSearch = props => {
|
|
14
|
+
const {
|
|
15
|
+
value,
|
|
16
|
+
filterSearch,
|
|
17
|
+
tablePrefixCls,
|
|
18
|
+
locale,
|
|
19
|
+
onChange
|
|
20
|
+
} = props;
|
|
21
|
+
if (!filterSearch) {
|
|
22
|
+
return null;
|
|
23
|
+
}
|
|
24
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
25
|
+
className: `${tablePrefixCls}-filter-dropdown-search`,
|
|
26
|
+
style: {
|
|
27
|
+
paddingLeft: 0,
|
|
28
|
+
paddingRight: 0
|
|
29
|
+
}
|
|
30
|
+
}, /*#__PURE__*/React.createElement(_uiRc.Input, {
|
|
31
|
+
prefix: /*#__PURE__*/React.createElement(_SearchOutlined.default, null),
|
|
32
|
+
placeholder: locale.filterSearchPlaceholder,
|
|
33
|
+
onChange: onChange,
|
|
34
|
+
value: value,
|
|
35
|
+
autoFocus: true
|
|
36
|
+
// for skip min-width of input
|
|
37
|
+
,
|
|
38
|
+
htmlSize: 1,
|
|
39
|
+
className: `${tablePrefixCls}-filter-dropdown-search-input`
|
|
40
|
+
}));
|
|
41
|
+
};
|
|
42
|
+
var _default = exports.default = FilterSearch;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import 'dayjs/locale/es';
|
|
3
|
+
import 'dayjs/locale/vi';
|
|
4
|
+
import './styles.scss';
|
|
5
|
+
import type { GridTableProps } from "./type";
|
|
6
|
+
declare const GridTable: <RecordType extends object>(props: GridTableProps<RecordType>) => React.JSX.Element;
|
|
7
|
+
export default GridTable;
|