yootd 0.2.42 → 0.2.44
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.
@@ -1,7 +1,7 @@
|
|
1
|
-
.yot-preview-phone {
|
2
|
-
width: 398px;
|
3
|
-
height: 829px;
|
4
|
-
background-size: 100% 100%;
|
5
|
-
padding: 96px 36px 20px 36px;
|
6
|
-
box-sizing: border-box;
|
7
|
-
}
|
1
|
+
.yot-preview-phone {
|
2
|
+
width: 398px;
|
3
|
+
height: 829px;
|
4
|
+
background-size: 100% 100%;
|
5
|
+
padding: 96px 36px 20px 36px;
|
6
|
+
box-sizing: border-box;
|
7
|
+
}
|
package/dist/table/index.d.ts
CHANGED
@@ -15,6 +15,8 @@ export interface TableProps<T = AnyObject> extends Omit<AntTableProps<T>, 'colum
|
|
15
15
|
headerTextColor?: string;
|
16
16
|
showSetting?: boolean;
|
17
17
|
persistKeys?: string;
|
18
|
+
striped?: boolean;
|
19
|
+
stripedColor?: string[];
|
18
20
|
}
|
19
21
|
export interface ColumnType<T = AnyObject> extends Omit<AntColumnType<T>, 'key'> {
|
20
22
|
key: React.Key;
|
package/dist/table/index.js
CHANGED
@@ -3,7 +3,7 @@ import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
3
3
|
import _typeof from "@babel/runtime/helpers/esm/typeof";
|
4
4
|
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
5
5
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
6
|
-
var _excluded = ["type", "showSetting", "columns", "components", "persistKeys", "headerBgColor", "headerTextColor"];
|
6
|
+
var _excluded = ["type", "showSetting", "columns", "components", "persistKeys", "headerBgColor", "headerTextColor", "striped", "stripedColor"];
|
7
7
|
import { Table as AntTable } from 'antd';
|
8
8
|
import React, { forwardRef, useEffect, useMemo, useState } from 'react';
|
9
9
|
import { PrimaryHeaderRow } from "./components/primary-header-row";
|
@@ -22,6 +22,10 @@ var InternalTable = function InternalTable(_ref, ref) {
|
|
22
22
|
persistKeys = _ref.persistKeys,
|
23
23
|
headerBgColor = _ref.headerBgColor,
|
24
24
|
headerTextColor = _ref.headerTextColor,
|
25
|
+
_ref$striped = _ref.striped,
|
26
|
+
striped = _ref$striped === void 0 ? false : _ref$striped,
|
27
|
+
_ref$stripedColor = _ref.stripedColor,
|
28
|
+
stripedColor = _ref$stripedColor === void 0 ? ['#F0F9FF', '#FFFFFF'] : _ref$stripedColor,
|
25
29
|
rest = _objectWithoutProperties(_ref, _excluded);
|
26
30
|
var _useState = useState([]),
|
27
31
|
_useState2 = _slicedToArray(_useState, 2),
|
@@ -154,7 +158,23 @@ var InternalTable = function InternalTable(_ref, ref) {
|
|
154
158
|
}, /*#__PURE__*/React.createElement(AntTable, _extends({}, rest, {
|
155
159
|
ref: ref,
|
156
160
|
columns: filterColumns(innerColumns, keys),
|
157
|
-
components: _components
|
161
|
+
components: _components,
|
162
|
+
onRow: function onRow(_, index) {
|
163
|
+
if (index == null || !striped) return {};
|
164
|
+
if (index % 2 === 0) {
|
165
|
+
return {
|
166
|
+
style: {
|
167
|
+
backgroundColor: stripedColor === null || stripedColor === void 0 ? void 0 : stripedColor[0]
|
168
|
+
}
|
169
|
+
};
|
170
|
+
} else {
|
171
|
+
return {
|
172
|
+
style: {
|
173
|
+
backgroundColor: stripedColor === null || stripedColor === void 0 ? void 0 : stripedColor[1]
|
174
|
+
}
|
175
|
+
};
|
176
|
+
}
|
177
|
+
}
|
158
178
|
})));
|
159
179
|
};
|
160
180
|
var Table = /*#__PURE__*/forwardRef(InternalTable);
|
package/dist/year-term/index.js
CHANGED
@@ -38,7 +38,7 @@ export var YearTerm = function YearTerm(_ref) {
|
|
38
38
|
var _useQuery = useQuery({
|
39
39
|
queryKey: ['yearData'],
|
40
40
|
queryFn: function queryFn() {
|
41
|
-
return request('/v1/education/
|
41
|
+
return request('/v1/education/addition/school/year/install/all');
|
42
42
|
},
|
43
43
|
enabled: type === 'year' || type === 'yearTerm'
|
44
44
|
}),
|
@@ -60,8 +60,8 @@ export var YearTerm = function YearTerm(_ref) {
|
|
60
60
|
var _yearData$content;
|
61
61
|
return yearData === null || yearData === void 0 || (_yearData$content = yearData.content) === null || _yearData$content === void 0 ? void 0 : _yearData$content.map(function (item) {
|
62
62
|
return {
|
63
|
-
label: item.
|
64
|
-
value: item.
|
63
|
+
label: item.schoolYear,
|
64
|
+
value: item.yearId
|
65
65
|
};
|
66
66
|
});
|
67
67
|
}, [yearData]);
|