Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
wangjin-front-end
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
张媛
wangjin-front-end
Commits
70ed8733
Commit
70ed8733
authored
Jul 19, 2021
by
张媛
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
组件概览数据提出来
parent
da6348b3
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
34 additions
and
31 deletions
+34
-31
comData.ts
src/docs/data/comData.ts
+29
-0
totalCom.tsx
src/docs/totalCom.tsx
+5
-31
No files found.
src/docs/data/comData.ts
0 → 100644
View file @
70ed8733
export
const
canvasData
=
[
{
name
:
"金币动效"
,
imgUrl
:
"/resource/金币动效.gif"
,
href
:
"金币动效"
},
{
name
:
"轮播组件"
,
imgUrl
:
"/resource/轮播.gif"
,
href
:
"轮播组件"
},
{
name
:
"多边形坐标系统"
,
imgUrl
:
"/resource/多边形坐标系统.gif"
,
href
:
"多边形坐标系统"
},
{
name
:
"丰富文本"
,
imgUrl
:
"/resource/丰富文本.gif"
,
href
:
"丰富文本"
}
]
export
const
reactData
=
[
{
name
:
"弹幕"
,
imgUrl
:
"/resource/reactDanmu.gif"
,
href
:
"弹幕"
}
]
\ No newline at end of file
src/docs/totalCom.tsx
View file @
70ed8733
...
...
@@ -4,41 +4,15 @@ import { useEffect } from 'react';
import
{
navigate
,
LinkTo
,
linkTo
,
hrefTo
}
from
'@storybook/addon-links'
;
import
"./totalCom.less"
import
{
canvasData
,
reactData
}
from
"./data/comData"
const
canvasClickFun
=
(
name
)
=>
{
linkTo
(
'Canvas组件/'
+
name
)();
}
const
reactClickFun
=
(
name
)
=>
{
linkTo
(
'React组件/'
+
name
)();
}
const
comArrData
=
[
{
name
:
"金币动效"
,
imgUrl
:
"/resource/金币动效.gif"
,
href
:
"金币动效"
},
{
name
:
"轮播组件"
,
imgUrl
:
"/resource/轮播.gif"
,
href
:
"轮播组件"
},
{
name
:
"多边形坐标系统"
,
imgUrl
:
"/resource/多边形坐标系统.gif"
,
href
:
"多边形坐标系统"
},
{
name
:
"丰富文本"
,
imgUrl
:
"/resource/丰富文本.gif"
,
href
:
"丰富文本"
}
]
const
reactArrData
=
[
{
name
:
"弹幕"
,
imgUrl
:
"/resource/reactDanmu.gif"
,
href
:
"弹幕"
}
]
export
const
TotalCom
=
()
=>
{
clearStage
();
return
(
...
...
@@ -46,7 +20,7 @@ export const TotalCom = ()=>{
<
h2
>
canvas组件概览
</
h2
>
<
div
className
="
container
-
div
"
>
{
c
omArr
Data
.
map
((
el
,
index
)
=>
{
c
anvas
Data
.
map
((
el
,
index
)
=>
{
return
(
<
div
key=
{
index
}
className=
"itemCom"
>
<
img
src=
{
el
.
imgUrl
}
width
=
"200"
height
=
"150"
/>
...
...
@@ -59,7 +33,7 @@ export const TotalCom = ()=>{
<
h2
>
React组件概览
</
h2
>
<
div
className
="
container
-
div
"
>
{
react
Arr
Data
.
map
((
el
,
index
)
=>
{
reactData
.
map
((
el
,
index
)
=>
{
return
(
<
div
key=
{
index
}
className=
"itemCom"
>
<
img
src=
{
el
.
imgUrl
}
width
=
"200"
height
=
"150"
/>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment