From 23c0413a0706268ea7d900ddbc0429a040cc4271 Mon Sep 17 00:00:00 2001
From: wangxiang <1827945911@qq.com>
Date: Mon, 20 Mar 2023 19:22:34 +0800
Subject: [PATCH] =?UTF-8?q?feat:=20=E6=96=B0=E5=A2=9E=20CardList=20?=
=?UTF-8?q?=E7=BB=84=E4=BB=B6?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/components/CardList/index.ts | 4 +
src/components/CardList/src/CardList.vue | 175 +++++++++++++++++++++++
src/components/CardList/src/data.ts | 25 ++++
3 files changed, 204 insertions(+)
create mode 100644 src/components/CardList/index.ts
create mode 100644 src/components/CardList/src/CardList.vue
create mode 100644 src/components/CardList/src/data.ts
diff --git a/src/components/CardList/index.ts b/src/components/CardList/index.ts
new file mode 100644
index 0000000..b977c1b
--- /dev/null
+++ b/src/components/CardList/index.ts
@@ -0,0 +1,4 @@
+import { withInstall } from '/@/utils';
+import cardList from './src/CardList.vue';
+
+export const CardList = withInstall(cardList);
diff --git a/src/components/CardList/src/CardList.vue b/src/components/CardList/src/CardList.vue
new file mode 100644
index 0000000..064cc01
--- /dev/null
+++ b/src/components/CardList/src/CardList.vue
@@ -0,0 +1,175 @@
+
+
+
+
+
+
+
+
+
+
+
+ 每行显示数量
+
+
+
+ 刷新
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ item.time }}
+
+
+
+
+
+
+
+
+
diff --git a/src/components/CardList/src/data.ts b/src/components/CardList/src/data.ts
new file mode 100644
index 0000000..b7c4be7
--- /dev/null
+++ b/src/components/CardList/src/data.ts
@@ -0,0 +1,25 @@
+import { ref } from 'vue';
+// 每行个数
+export const grid = ref(12);
+// slider属性
+export const useSlider = (min = 6, max = 12) => {
+ // 每行显示个数滑动条
+ const getMarks = () => {
+ const l = {};
+ for (let i = min; i < max + 1; i++) {
+ l[i] = {
+ style: {
+ color: '#fff',
+ },
+ label: i,
+ };
+ }
+ return l;
+ };
+ return {
+ min,
+ max,
+ marks: getMarks(),
+ step: 1,
+ };
+};