File tree Expand file tree Collapse file tree 2 files changed +40
-8
lines changed
packages/ui/components/common Expand file tree Collapse file tree 2 files changed +40
-8
lines changed Original file line number Diff line number Diff line change @@ -32,4 +32,5 @@ export const Error = Template.bind({})
32
32
Error . args = {
33
33
hasError : true ,
34
34
title : '印刷工程の都合上、ネームカードの編集期限後は編集できなくなります。当日会場にてネームカードをご希望の方は期限までに編集を完了させてください。' ,
35
+ content : 'ネームカード編集期限:\n2024年9月16日(月祝)24:00' ,
35
36
}
Original file line number Diff line number Diff line change 1
1
<script setup lang="ts">
2
+ import { useColor } from ' @vuejs-jp/composable'
2
3
import Icon from ' ../icon/Icon.vue'
3
4
4
5
interface StatusCardProps {
5
6
hasError: boolean
6
7
title: string
8
+ content? : string
7
9
}
8
10
9
11
const props = defineProps <StatusCardProps >()
12
+
13
+ const { color } = useColor ()
10
14
</script >
11
15
12
16
<template >
@@ -16,37 +20,64 @@ const props = defineProps<StatusCardProps>()
16
20
background: hasError ? '#FFDAD6' : '#E7EFF7',
17
21
}"
18
22
>
19
- <Icon v-if =" hasError" :style =" { width: '80px' }" color =" vue-blue" name =" alert" />
20
- <p
21
- class =" title"
23
+ <div class =" status-card-body" >
24
+ <Icon v-if =" hasError" :style =" { width: '80px' }" color =" vue-blue" name =" alert" />
25
+ <p
26
+ class =" title"
27
+ :style =" {
28
+ fontWeight: hasError ? 700 : 500,
29
+ }"
30
+ >
31
+ {{ title }}
32
+ </p >
33
+ </div >
34
+ <div
35
+ v-if =" content"
36
+ class =" status-card-content"
22
37
:style =" {
23
- fontWeight: hasError ? 700 : 500 ,
38
+ color: color('sangosyo/200') ,
24
39
}"
25
40
>
26
- {{ title }}
27
- </p >
41
+ {{ content }}
42
+ </div >
28
43
</div >
29
44
</template >
30
45
31
46
<style scoped>
32
47
.status-card {
33
- display : flex ;
34
- gap : calc (var (--unit ) * 1 );
48
+ display : grid ;
49
+ place-items : center ;
50
+ gap : calc (var (--unit ) * 1.5 );
35
51
padding : calc (var (--unit ) * 3 ) calc (var (--unit ) * 4 );
36
52
max-width : 760px ;
37
53
color : var (--color-vue-blue );
38
54
border-radius : 8px ;
39
55
}
40
56
57
+ .status-card-body {
58
+ display : flex ;
59
+ gap : calc (var (--unit ) * 1 );
60
+ }
61
+
41
62
.title {
42
63
padding : 0 ;
43
64
margin : 0 ;
44
65
font-size : 18px ;
45
66
}
46
67
68
+ .status-card-content {
69
+ font-size : 18px ;
70
+ font-weight : 700 ;
71
+ }
72
+
47
73
@media screen and (max-width : 768px ) {
48
74
.status-card {
49
75
width : 100% ;
50
76
}
77
+
78
+ .status-card-content {
79
+ text-align : center ;
80
+ white-space : pre-wrap ;
81
+ }
51
82
}
52
83
</style >
You can’t perform that action at this time.
0 commit comments