1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
| <template>
| <div class="sheet-container w-full h-full">
| <el-scrollbar>
| <el-collapse v-model="activeNames" @change="handleChange">
| <template v-for="item in sheetList">
| <el-collapse-item :title="item.title" :name="item.type">
| <div class="sheet-list grid grid-cols-5 gap-4 justify-items-center">
| <div class="sheet-item cursor-pointer flex justify-center items-center" v-for="index in item.total" @click="">
| {{ index }}
| </div>
| </div>
| </el-collapse-item>
| </template>
| </el-collapse>
| </el-scrollbar>
| </div>
| </template>
|
| <script setup>
| import { ref } from 'vue';
|
| const categroy = ref(0);
| const sheetIndex = ref(0);
|
|
| const sheetList = ref([
| {
| title: '单选题',
| type: 1,
| total: 20,
| },
| {
| title: '多选题',
| type: 2,
| total: 20,
| },
| {
| title: '判断题',
| type: 3,
| total: 20,
| },
| ]);
|
| const activeNames = ref(sheetList.value.map(item => item.type));
|
|
| const handleChange = () => {
|
| };
| </script>
|
| <style lang="scss" scoped>
| .sheet-list {
| width: 97%;
| }
| .sheet-item {
| width: 35px;
| height: 35px;
| border: 1px solid #DCDFE6;
| background-color: #fff;
| color: #374151;
| }
| </style>
|
|