@yilianjituan/yilian_dgerm 0.0.1-alpha.17 → 0.0.1-alpha.19
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/README.md +5 -1
- package/dist/components/TabsMode/index.d.ts +4 -0
- package/dist/components/TabsMode/index.interface.d.ts +18 -0
- package/dist/components/TabsMode/index.interface.js +1 -0
- package/dist/components/TabsMode/index.js +30 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +2 -1
- package/package.json +2 -6
package/README.md
CHANGED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export interface ITabsProps {
|
|
2
|
+
/**
|
|
3
|
+
* @description 默认选中
|
|
4
|
+
*/
|
|
5
|
+
tabIndex: string;
|
|
6
|
+
/**
|
|
7
|
+
* @description {key: '', title: ''} 页面数据
|
|
8
|
+
*/
|
|
9
|
+
tabPaneArr: ITabPaneArr[];
|
|
10
|
+
/**
|
|
11
|
+
* @description 返回点击事件
|
|
12
|
+
*/
|
|
13
|
+
handleClickCallback: (value: string) => void;
|
|
14
|
+
}
|
|
15
|
+
export interface ITabPaneArr {
|
|
16
|
+
title: string;
|
|
17
|
+
key: string;
|
|
18
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* @Author: lxx
|
|
3
|
+
* @Date: 2024-10-11 16:26:07
|
|
4
|
+
* @Last Modified by: lxx
|
|
5
|
+
* @Last Modified time: 2024-10-24 11:38:02
|
|
6
|
+
* @Desc: 级联组件封装
|
|
7
|
+
*/
|
|
8
|
+
import React from 'react';
|
|
9
|
+
import { Tabs } from 'antd';
|
|
10
|
+
var Index = function Index(props) {
|
|
11
|
+
var _tabPaneArr$length;
|
|
12
|
+
var tabIndex = props.tabIndex,
|
|
13
|
+
tabPaneArr = props.tabPaneArr,
|
|
14
|
+
handleClickCallback = props.handleClickCallback;
|
|
15
|
+
console.log(tabPaneArr, tabIndex, 'tabPaneArr===');
|
|
16
|
+
return /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Tabs, {
|
|
17
|
+
activeKey: tabIndex,
|
|
18
|
+
onChange: function onChange(e) {
|
|
19
|
+
return handleClickCallback(e);
|
|
20
|
+
},
|
|
21
|
+
items: new Array((_tabPaneArr$length = tabPaneArr === null || tabPaneArr === void 0 ? void 0 : tabPaneArr.length) !== null && _tabPaneArr$length !== void 0 ? _tabPaneArr$length : 0).fill(null).map(function (_, i) {
|
|
22
|
+
var _tabPaneArr$i, _tabPaneArr$i2;
|
|
23
|
+
return {
|
|
24
|
+
label: (_tabPaneArr$i = tabPaneArr[i]) === null || _tabPaneArr$i === void 0 ? void 0 : _tabPaneArr$i.title,
|
|
25
|
+
key: (_tabPaneArr$i2 = tabPaneArr[i]) === null || _tabPaneArr$i2 === void 0 ? void 0 : _tabPaneArr$i2.key
|
|
26
|
+
};
|
|
27
|
+
})
|
|
28
|
+
}));
|
|
29
|
+
};
|
|
30
|
+
export default Index;
|
package/dist/index.d.ts
CHANGED
|
@@ -11,3 +11,4 @@ export { default as SuperCascader } from './components/SuperCascader';
|
|
|
11
11
|
export { default as BigImage } from './components/BigImage';
|
|
12
12
|
export { default as VideoProgressModal } from './components/VideoProgressModal';
|
|
13
13
|
export { default as NumberInput } from './components/NumberInput';
|
|
14
|
+
export { default as TabsMode } from './components/TabsMode';
|
package/dist/index.js
CHANGED
|
@@ -10,4 +10,5 @@ export { default as YLModal } from "./components/YLModal";
|
|
|
10
10
|
export { default as SuperCascader } from "./components/SuperCascader";
|
|
11
11
|
export { default as BigImage } from "./components/BigImage";
|
|
12
12
|
export { default as VideoProgressModal } from "./components/VideoProgressModal";
|
|
13
|
-
export { default as NumberInput } from "./components/NumberInput";
|
|
13
|
+
export { default as NumberInput } from "./components/NumberInput";
|
|
14
|
+
export { default as TabsMode } from "./components/TabsMode";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yilianjituan/yilian_dgerm",
|
|
3
|
-
"version": "0.0.1-alpha.
|
|
3
|
+
"version": "0.0.1-alpha.19",
|
|
4
4
|
"description": "A react library developed with dumi",
|
|
5
5
|
"module": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -105,9 +105,5 @@
|
|
|
105
105
|
"resolutions": {
|
|
106
106
|
"zod-validation-error": "^1.5.0"
|
|
107
107
|
},
|
|
108
|
-
"main": ".eslintrc.js"
|
|
109
|
-
"repository": {
|
|
110
|
-
"type": "git",
|
|
111
|
-
"url": "https://git.yljt.cn/web-module/yl_dgerm"
|
|
112
|
-
}
|
|
108
|
+
"main": ".eslintrc.js"
|
|
113
109
|
}
|