@hw-component/table 1.9.12 → 1.9.13
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/es/Table.d.ts +2 -1
- package/es/Table.js +4 -3
- package/es/modal.d.ts +1 -0
- package/lib/Table.d.ts +2 -1
- package/lib/Table.js +4 -3
- package/lib/modal.d.ts +1 -0
- package/package.json +1 -1
- package/src/components/Table.tsx +2 -1
- package/src/components/modal.ts +1 -0
package/es/Table.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
import type { HTableProps } from "./modal";
|
|
2
|
-
declare const _default: ({ request, configData, searchSpan, table, hideHeader, headerStyle, tableStyle, action, spaceSize, className, paginationStyle, rowKey, onFinish, manual, formInitValues, hideLabel, labelWidth, onReset, ...props }: HTableProps) => JSX.Element;
|
|
3
|
+
declare const _default: ({ request, configData, searchSpan, table, hideHeader, headerStyle, tableStyle, action, spaceSize, className, paginationStyle, rowKey, onFinish, manual, formInitValues, hideLabel, labelWidth, onReset, style, ...props }: HTableProps) => JSX.Element;
|
|
3
4
|
export default _default;
|
package/es/Table.js
CHANGED
|
@@ -23,7 +23,7 @@ import useDispatch from './hooks/useDispatch.js';
|
|
|
23
23
|
import { useState } from 'react';
|
|
24
24
|
import { useClassName } from './hooks/index.js';
|
|
25
25
|
|
|
26
|
-
var _excluded = ["request", "configData", "searchSpan", "table", "hideHeader", "headerStyle", "tableStyle", "action", "spaceSize", "className", "paginationStyle", "rowKey", "onFinish", "manual", "formInitValues", "hideLabel", "labelWidth", "onReset"];
|
|
26
|
+
var _excluded = ["request", "configData", "searchSpan", "table", "hideHeader", "headerStyle", "tableStyle", "action", "spaceSize", "className", "paginationStyle", "rowKey", "onFinish", "manual", "formInitValues", "hideLabel", "labelWidth", "onReset", "style"];
|
|
27
27
|
function ownKeys(e, r) { var t = _Object$keys(e); if (_Object$getOwnPropertySymbols) { var o = _Object$getOwnPropertySymbols(e); r && (o = _filterInstanceProperty(o).call(o, function (r) { return _Object$getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
28
28
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var _context2, _context3; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty(_context2 = ownKeys(Object(t), !0)).call(_context2, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors ? _Object$defineProperties(e, _Object$getOwnPropertyDescriptors(t)) : _forEachInstanceProperty(_context3 = ownKeys(Object(t))).call(_context3, function (r) { _Object$defineProperty(e, r, _Object$getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
29
29
|
var Table = (function (_ref) {
|
|
@@ -48,6 +48,7 @@ var Table = (function (_ref) {
|
|
|
48
48
|
hideLabel = _ref.hideLabel,
|
|
49
49
|
labelWidth = _ref.labelWidth,
|
|
50
50
|
onReset = _ref.onReset,
|
|
51
|
+
style = _ref.style,
|
|
51
52
|
props = _objectWithoutProperties(_ref, _excluded);
|
|
52
53
|
var _useReq = useReq({
|
|
53
54
|
request: request,
|
|
@@ -117,9 +118,9 @@ var Table = (function (_ref) {
|
|
|
117
118
|
children: jsxs(Space, {
|
|
118
119
|
direction: "vertical",
|
|
119
120
|
size: 0,
|
|
120
|
-
style: {
|
|
121
|
+
style: _objectSpread({
|
|
121
122
|
width: "100%"
|
|
122
|
-
},
|
|
123
|
+
}, style),
|
|
123
124
|
className: _concatInstanceProperty(_context = "".concat(contentClassName, " ")).call(_context, className),
|
|
124
125
|
children: [!hideHeader && jsx(Header, {
|
|
125
126
|
searchSpan: searchSpan,
|
package/es/modal.d.ts
CHANGED
|
@@ -59,6 +59,7 @@ export interface HTableProps extends Omit<ProTableProps<any, any>, "request" | "
|
|
|
59
59
|
action?: Record<string, actionFn>;
|
|
60
60
|
headerStyle?: React.CSSProperties;
|
|
61
61
|
tableStyle?: React.CSSProperties;
|
|
62
|
+
style?: React.CSSProperties;
|
|
62
63
|
spaceSize?: number;
|
|
63
64
|
className?: string;
|
|
64
65
|
error?: Error;
|
package/lib/Table.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
import type { HTableProps } from "./modal";
|
|
2
|
-
declare const _default: ({ request, configData, searchSpan, table, hideHeader, headerStyle, tableStyle, action, spaceSize, className, paginationStyle, rowKey, onFinish, manual, formInitValues, hideLabel, labelWidth, onReset, ...props }: HTableProps) => JSX.Element;
|
|
3
|
+
declare const _default: ({ request, configData, searchSpan, table, hideHeader, headerStyle, tableStyle, action, spaceSize, className, paginationStyle, rowKey, onFinish, manual, formInitValues, hideLabel, labelWidth, onReset, style, ...props }: HTableProps) => JSX.Element;
|
|
3
4
|
export default _default;
|
package/lib/Table.js
CHANGED
|
@@ -26,7 +26,7 @@ var useDispatch = require('./hooks/useDispatch.js');
|
|
|
26
26
|
var React = require('react');
|
|
27
27
|
var index = require('./hooks/index.js');
|
|
28
28
|
|
|
29
|
-
var _excluded = ["request", "configData", "searchSpan", "table", "hideHeader", "headerStyle", "tableStyle", "action", "spaceSize", "className", "paginationStyle", "rowKey", "onFinish", "manual", "formInitValues", "hideLabel", "labelWidth", "onReset"];
|
|
29
|
+
var _excluded = ["request", "configData", "searchSpan", "table", "hideHeader", "headerStyle", "tableStyle", "action", "spaceSize", "className", "paginationStyle", "rowKey", "onFinish", "manual", "formInitValues", "hideLabel", "labelWidth", "onReset", "style"];
|
|
30
30
|
function ownKeys(e, r) { var t = _Object$keys(e); if (_Object$getOwnPropertySymbols) { var o = _Object$getOwnPropertySymbols(e); r && (o = _filterInstanceProperty(o).call(o, function (r) { return _Object$getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
31
31
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var _context2, _context3; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty(_context2 = ownKeys(Object(t), !0)).call(_context2, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors ? _Object$defineProperties(e, _Object$getOwnPropertyDescriptors(t)) : _forEachInstanceProperty(_context3 = ownKeys(Object(t))).call(_context3, function (r) { _Object$defineProperty(e, r, _Object$getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
32
32
|
var Table = (function (_ref) {
|
|
@@ -51,6 +51,7 @@ var Table = (function (_ref) {
|
|
|
51
51
|
hideLabel = _ref.hideLabel,
|
|
52
52
|
labelWidth = _ref.labelWidth,
|
|
53
53
|
onReset = _ref.onReset,
|
|
54
|
+
style = _ref.style,
|
|
54
55
|
props = _objectWithoutProperties(_ref, _excluded);
|
|
55
56
|
var _useReq = useReq.default({
|
|
56
57
|
request: request,
|
|
@@ -120,9 +121,9 @@ var Table = (function (_ref) {
|
|
|
120
121
|
children: jsxRuntime.jsxs(antd.Space, {
|
|
121
122
|
direction: "vertical",
|
|
122
123
|
size: 0,
|
|
123
|
-
style: {
|
|
124
|
+
style: _objectSpread({
|
|
124
125
|
width: "100%"
|
|
125
|
-
},
|
|
126
|
+
}, style),
|
|
126
127
|
className: _concatInstanceProperty(_context = "".concat(contentClassName, " ")).call(_context, className),
|
|
127
128
|
children: [!hideHeader && jsxRuntime.jsx(index$1.default, {
|
|
128
129
|
searchSpan: searchSpan,
|
package/lib/modal.d.ts
CHANGED
|
@@ -59,6 +59,7 @@ export interface HTableProps extends Omit<ProTableProps<any, any>, "request" | "
|
|
|
59
59
|
action?: Record<string, actionFn>;
|
|
60
60
|
headerStyle?: React.CSSProperties;
|
|
61
61
|
tableStyle?: React.CSSProperties;
|
|
62
|
+
style?: React.CSSProperties;
|
|
62
63
|
spaceSize?: number;
|
|
63
64
|
className?: string;
|
|
64
65
|
error?: Error;
|
package/package.json
CHANGED
package/src/components/Table.tsx
CHANGED
|
@@ -28,6 +28,7 @@ export default ({
|
|
|
28
28
|
hideLabel,
|
|
29
29
|
labelWidth,
|
|
30
30
|
onReset,
|
|
31
|
+
style,
|
|
31
32
|
...props
|
|
32
33
|
}: HTableProps) => {
|
|
33
34
|
const { run, loading, data, error, saveParams } = useReq({
|
|
@@ -86,7 +87,7 @@ export default ({
|
|
|
86
87
|
<Space
|
|
87
88
|
direction={"vertical"}
|
|
88
89
|
size={0}
|
|
89
|
-
style={{ width: "100%" }}
|
|
90
|
+
style={{ width: "100%" ,...style}}
|
|
90
91
|
className={`${contentClassName} ${className}`}
|
|
91
92
|
>
|
|
92
93
|
{!hideHeader && (
|
package/src/components/modal.ts
CHANGED