yootd 0.0.16 → 0.0.18

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.
@@ -19,6 +19,7 @@ import "./index.scss";
19
19
  export var School = function School(_ref) {
20
20
  var _ref$type = _ref.type,
21
21
  type = _ref$type === void 0 ? 'collegeMajor' : _ref$type,
22
+ multiple = _ref.multiple,
22
23
  style = _ref.style,
23
24
  _ref$showSearch = _ref.showSearch,
24
25
  showSearch = _ref$showSearch === void 0 ? true : _ref$showSearch,
@@ -287,10 +288,12 @@ export var School = function School(_ref) {
287
288
  height: style === null || style === void 0 ? void 0 : style.height
288
289
  },
289
290
  options: firstSelectOptions,
290
- onChange: changeFirstSelect
291
+ onChange: changeFirstSelect,
292
+ mode: type !== 'collegeMajor' && type !== 'gradeClass' ? multiple ? 'multiple' : undefined : undefined
291
293
  }), type === 'college' || type === 'grade' ? null : /*#__PURE__*/React.createElement(Select, {
292
294
  allowClear: allowClear,
293
295
  value: type === 'collegeMajor' || type === 'major' ? majorId : classId,
296
+ mode: type !== 'collegeMajor' && type !== 'gradeClass' ? multiple ? 'multiple' : undefined : undefined,
294
297
  showSearch: showSearch,
295
298
  optionFilterProp: "label",
296
299
  placeholder: secondSelectPlaceholder,
@@ -75,6 +75,7 @@ type SchoolProps = {
75
75
  | 'major'
76
76
  | 'grade'
77
77
  | 'class';
78
+ multiple?: boolean;
78
79
  style?: React.CSSProperties;
79
80
  showSearch?: boolean;
80
81
  value?: Record<string, number>;
@@ -43,7 +43,8 @@ export var TabsComponent = function TabsComponent(_ref) {
43
43
  _className = "".concat(mb.b('small'));
44
44
  break;
45
45
  default:
46
- _className = '';
46
+ // 默认为小尺寸
47
+ _className = "".concat(mb.b('large'));
47
48
  }
48
49
  // 给key设置默认值
49
50
  useEffect(function () {
@@ -1,4 +1,9 @@
1
1
  .yot-tabs {
2
+ // 覆盖 ant 默认样式
3
+ .ant-tabs-top > .ant-tabs-nav .ant-tabs-ink-bar,
4
+ .ant-tabs-top > div > .ant-tabs-nav .ant-tabs-ink-bar {
5
+ bottom: 1px;
6
+ }
2
7
  &-large {
3
8
  .ant-tabs-tab.ant-tabs-tab-active {
4
9
  color: var(--ant-color-primary);
@@ -11,7 +16,7 @@
11
16
  padding-left: 1.5rem;
12
17
  padding-right: 1.5rem;
13
18
  }
14
- .ant-tabs-nav::before{
19
+ .ant-tabs-nav::before {
15
20
  content: '';
16
21
  position: absolute;
17
22
  right: 1.5rem;
@@ -19,7 +24,7 @@
19
24
  z-index: 10;
20
25
  border-bottom-width: var(--ant-line-width);
21
26
  border-bottom-style: solid;
22
- border-bottom-color: #E5E5E5;
27
+ border-bottom-color: #e5e5e5;
23
28
  }
24
29
  }
25
30
  &-small {
@@ -34,7 +39,7 @@
34
39
  padding-left: 1.5rem;
35
40
  padding-right: 1.5rem;
36
41
  }
37
- .ant-tabs-nav::before{
42
+ .ant-tabs-nav::before {
38
43
  content: '';
39
44
  position: absolute;
40
45
  right: 1.5rem;
@@ -42,7 +47,7 @@
42
47
  z-index: 10;
43
48
  border-bottom-width: var(--ant-line-width);
44
49
  border-bottom-style: solid;
45
- border-bottom-color: #E5E5E5;
50
+ border-bottom-color: #e5e5e5;
46
51
  }
47
52
  }
48
53
  &-capsule {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "yootd",
3
- "version": "0.0.16",
3
+ "version": "0.0.18",
4
4
  "description": "A react library developed with dumi",
5
5
  "license": "MIT",
6
6
  "module": "dist/index.js",