Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
najiu-admin-template
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
najiu-frontend
najiu-admin-template
Commits
3a132f3f
Commit
3a132f3f
authored
Nov 23, 2020
by
陈小婷
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: add card-list page
parent
737b1b19
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
148 additions
and
0 deletions
+148
-0
page.ts
src/router/menus/modules/demo/page.ts
+13
-0
page.ts
src/router/routes/modules/demo/page.ts
+20
-0
Application.vue
src/views/demo/page/account/center/Application.vue
+1
-0
data.tsx
src/views/demo/page/list/card/data.tsx
+14
-0
index.vue
src/views/demo/page/list/card/index.vue
+100
-0
No files found.
src/router/menus/modules/demo/page.ts
View file @
3a132f3f
...
@@ -106,6 +106,19 @@ const menu: MenuModule = {
...
@@ -106,6 +106,19 @@ const menu: MenuModule = {
},
},
],
],
},
},
{
path
:
'
list
'
,
name
:
'
列表页
'
,
tag
:
{
content
:
'
new
'
,
},
children
:
[
{
path
:
'
card
'
,
name
:
'
卡片列表
'
,
},
],
},
],
],
},
},
};
};
...
...
src/router/routes/modules/demo/page.ts
View file @
3a132f3f
...
@@ -209,6 +209,26 @@ const page: AppRouteModule = {
...
@@ -209,6 +209,26 @@ const page: AppRouteModule = {
],
],
},
},
// =============================exception end=============================
// =============================exception end=============================
// =============================list start=============================
{
path
:
'
/list
'
,
name
:
'
ListPage
'
,
redirect
:
'
/page-demo/list/card
'
,
meta
:
{
title
:
'
列表页
'
,
},
children
:
[
{
path
:
'
card
'
,
name
:
'
ListCardPage
'
,
component
:
()
=>
import
(
'
/@/views/demo/page/list/card/index.vue
'
),
meta
:
{
title
:
'
卡片列表
'
,
},
},
],
},
// =============================list end=============================
],
],
};
};
...
...
src/views/demo/page/account/center/Application.vue
View file @
3a132f3f
...
@@ -52,6 +52,7 @@
...
@@ -52,6 +52,7 @@
.account-center-application {
.account-center-application {
&__card {
&__card {
width: 100%;
width: 100%;
margin-bottom: -12px;
.ant-card-body {
.ant-card-body {
padding: 16px;
padding: 16px;
...
...
src/views/demo/page/list/card/data.tsx
0 → 100644
View file @
3a132f3f
export
const
cardList
=
(()
=>
{
const
result
:
any
[]
=
[];
for
(
let
i
=
0
;
i
<
12
;
i
++
)
{
result
.
push
({
title
:
'
Vben Admin
'
,
icon
:
'
logos:ant-design
'
,
color
:
'
#1890ff
'
,
active
:
'
100
'
,
new
:
'
1,799
'
,
download
:
'
bx:bx-download
'
,
});
}
return
result
;
})();
src/views/demo/page/list/card/index.vue
0 → 100644
View file @
3a132f3f
<
template
>
<div
:class=
"prefixCls"
>
<a-page-header
title=
"卡片列表"
:ghost=
"false"
>
基于Vue Next, TypeScript, Ant Design实现的一套完整的企业级后台管理系统。
<div
:class=
"`$
{prefixCls}__link`">
<a><Icon
icon=
"bx:bx-paper-plane"
color=
"#1890ff"
/><span>
开始
</span></a>
<a><Icon
icon=
"carbon:warning"
color=
"#1890ff"
/><span>
简介
</span></a>
<a><Icon
icon=
"gg:loadbar-doc"
color=
"#1890ff"
/><span>
文档
</span></a>
</div>
</a-page-header>
<div
:class=
"`$
{prefixCls}__content`">
<List>
<a-row
:gutter=
"16"
>
<template
v-for=
"(item, index) in list"
:key=
"index"
>
<a-col
:span=
"6"
>
<ListItem>
<Card
:hoverable=
"true"
:class=
"`$
{prefixCls}__card`">
<div
:class=
"`$
{prefixCls}__card-title`">
<Icon
class=
"icon"
v-if=
"item.icon"
:icon=
"item.icon"
:color=
"item.color"
/>
{{
item
.
title
}}
</div>
<div
:class=
"`$
{prefixCls}__card-detail`">
基于Vue Next, TypeScript, Ant Design实现的一套完整的企业级后台管理系统
</div>
</Card>
</ListItem>
</a-col>
</
template
>
</a-row>
</List>
</div>
</div>
</template>
<
script
lang=
"ts"
>
import
{
defineComponent
}
from
'
vue
'
;
import
{
List
,
Card
}
from
'
ant-design-vue
'
;
import
Icon
from
'
/@/components/Icon/index
'
;
import
{
cardList
}
from
'
./data
'
;
export
default
defineComponent
({
components
:
{
Icon
,
List
,
ListItem
:
List
.
Item
,
Card
},
setup
()
{
return
{
prefixCls
:
'
list-card
'
,
list
:
cardList
,
};
},
});
</
script
>
<
style
lang=
"less"
scoped
>
.list-card {
&__link {
margin-top: 10px;
font-size: 14px;
a {
margin-right: 30px;
}
span {
margin-left: 5px;
}
}
&__content {
padding: 12px 24px;
// background: #fff;
}
&__card {
width: 100%;
margin-bottom: -8px;
.ant-card-body {
padding: 16px;
}
&-title {
margin-bottom: 5px;
font-size: 16px;
font-weight: 500;
color: rgba(0, 0, 0, 0.85);
.icon {
margin-top: -5px;
margin-right: 10px;
font-size: 38px !important;
}
}
&-detail {
padding-top: 10px;
padding-left: 30px;
font-size: 14px;
color: rgba(0, 0, 0, 0.5);
}
}
}
</
style
>
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