@pisell/private-materials 6.0.5 → 6.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/es/components/workSpaceList/components/SearchBar/index.js +0 -1
- package/es/components/workSpaceList/components/SearchWorkspaceAndBase/index.js +7 -5
- package/lib/components/workSpaceList/components/SearchBar/index.js +0 -5
- package/lib/components/workSpaceList/components/SearchWorkspaceAndBase/index.js +5 -4
- package/package.json +4 -4
@@ -75,7 +75,6 @@ var SearchBar = function SearchBar(props) {
|
|
75
75
|
var handleGoBack = function handleGoBack() {
|
76
76
|
window.history.back();
|
77
77
|
};
|
78
|
-
console.log('%c [ onDelete ]-80', 'font-size:13px; background:pink; color:#bf2c9f;', onDelete);
|
79
78
|
var onDropdownClick = /*#__PURE__*/function () {
|
80
79
|
var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(_ref) {
|
81
80
|
var key;
|
@@ -65,8 +65,9 @@ var Search = function Search() {
|
|
65
65
|
manual: true,
|
66
66
|
debounceWait: 300
|
67
67
|
}),
|
68
|
-
|
69
|
-
data = _useRequest.data
|
68
|
+
runAsync = _useRequest.runAsync,
|
69
|
+
_useRequest$data = _useRequest.data,
|
70
|
+
data = _useRequest$data === void 0 ? {} : _useRequest$data;
|
70
71
|
var handleSearch = /*#__PURE__*/function () {
|
71
72
|
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(searchText) {
|
72
73
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
@@ -79,7 +80,7 @@ var Search = function Search() {
|
|
79
80
|
return _context.abrupt("return");
|
80
81
|
case 2:
|
81
82
|
_context.next = 4;
|
82
|
-
return
|
83
|
+
return runAsync({
|
83
84
|
tenant_id: '0',
|
84
85
|
search: searchText
|
85
86
|
});
|
@@ -94,7 +95,7 @@ var Search = function Search() {
|
|
94
95
|
};
|
95
96
|
}();
|
96
97
|
useEffect(function () {
|
97
|
-
var _ref2 = data || {},
|
98
|
+
var _ref2 = (data === null || data === void 0 ? void 0 : data.data) || {},
|
98
99
|
workspace = _ref2.workspace,
|
99
100
|
base = _ref2.base;
|
100
101
|
if (workspace !== null && workspace !== void 0 && workspace.length || base !== null && base !== void 0 && base.length) {
|
@@ -131,7 +132,8 @@ var Search = function Search() {
|
|
131
132
|
prefix: /*#__PURE__*/React.createElement(SearchLg, {
|
132
133
|
className: 'search-icon'
|
133
134
|
}),
|
134
|
-
placeholder: "search"
|
135
|
+
placeholder: "search",
|
136
|
+
size: "large"
|
135
137
|
}));
|
136
138
|
};
|
137
139
|
export default Search;
|
@@ -95,11 +95,6 @@ var SearchBar = (props) => {
|
|
95
95
|
const handleGoBack = () => {
|
96
96
|
window.history.back();
|
97
97
|
};
|
98
|
-
console.log(
|
99
|
-
"%c [ onDelete ]-80",
|
100
|
-
"font-size:13px; background:pink; color:#bf2c9f;",
|
101
|
-
onDelete
|
102
|
-
);
|
103
98
|
const onDropdownClick = async ({ key }) => {
|
104
99
|
if (key === "rename") {
|
105
100
|
setEditingTitle(true);
|
@@ -67,20 +67,20 @@ var Search = () => {
|
|
67
67
|
import_utils.request.setRequest(context.appHelper.utils.request);
|
68
68
|
const [options, setOptions] = (0, import_react2.useState)([]);
|
69
69
|
const searchParams = new URLSearchParams(window.location.search);
|
70
|
-
const {
|
70
|
+
const { runAsync, data = {} } = (0, import_ahooks.useRequest)(import_server.searchWorkspace, {
|
71
71
|
manual: true,
|
72
72
|
debounceWait: 300
|
73
73
|
});
|
74
74
|
const handleSearch = async (searchText) => {
|
75
75
|
if (!searchText)
|
76
76
|
return;
|
77
|
-
await
|
77
|
+
await runAsync({
|
78
78
|
tenant_id: "0",
|
79
79
|
search: searchText
|
80
80
|
});
|
81
81
|
};
|
82
82
|
(0, import_react2.useEffect)(() => {
|
83
|
-
const { workspace, base } = data || {};
|
83
|
+
const { workspace, base } = (data == null ? void 0 : data.data) || {};
|
84
84
|
if ((workspace == null ? void 0 : workspace.length) || (base == null ? void 0 : base.length)) {
|
85
85
|
const newOptions = [
|
86
86
|
{
|
@@ -117,7 +117,8 @@ var Search = () => {
|
|
117
117
|
import_materials.Input,
|
118
118
|
{
|
119
119
|
prefix: /* @__PURE__ */ import_react.default.createElement(import_icon.SearchLg, { className: "search-icon" }),
|
120
|
-
placeholder: "search"
|
120
|
+
placeholder: "search",
|
121
|
+
size: "large"
|
121
122
|
}
|
122
123
|
)
|
123
124
|
);
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@pisell/private-materials",
|
3
|
-
"version": "6.0.
|
3
|
+
"version": "6.0.7",
|
4
4
|
"main": "./lib/index.js",
|
5
5
|
"module": "./es/index.js",
|
6
6
|
"types": "./lib/index.d.ts",
|
@@ -60,9 +60,9 @@
|
|
60
60
|
"rc-virtual-list": "^3.11.3",
|
61
61
|
"decimal.js": "^10.4.3",
|
62
62
|
"@pisell/icon": "0.0.11",
|
63
|
-
"@pisell/
|
64
|
-
"@pisell/materials": "6.0.
|
65
|
-
"@pisell/
|
63
|
+
"@pisell/date-picker": "1.0.100",
|
64
|
+
"@pisell/materials": "6.0.5",
|
65
|
+
"@pisell/utils": "1.0.42"
|
66
66
|
},
|
67
67
|
"peerDependencies": {
|
68
68
|
"react": "^18.0.0",
|