File tree Expand file tree Collapse file tree 3 files changed +11
-4
lines changed
page/archiving/component/TimeBlock Expand file tree Collapse file tree 3 files changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,6 @@ export const blockStyle = {
4
4
display : 'flex' ,
5
5
6
6
height : '5.6rem' ,
7
- marginRight : 'auto' ,
8
7
padding : '0.5rem' ,
9
8
justifyContent : 'center' ,
10
9
alignItems : 'center' ,
@@ -21,6 +20,7 @@ export const blockStyle = {
21
20
22
21
export const spanStyle = {
23
22
padding : '2rem 0.8rem' ,
23
+ marginRight : 'auto' ,
24
24
25
25
overflow : 'hidden' ,
26
26
textOverflow : 'ellipsis' ,
Original file line number Diff line number Diff line change @@ -6,12 +6,13 @@ import Eclipse from '@/common/asset/svg/eclipse.svg?react';
6
6
7
7
interface TimeBlockProps {
8
8
children : ReactNode ;
9
+ width : number ;
9
10
}
10
11
11
- const TimeBlock = ( { children } : TimeBlockProps ) => {
12
+ const TimeBlock = ( { children, width } : TimeBlockProps ) => {
12
13
return (
13
14
< >
14
- < div css = { blockStyle } >
15
+ < div css = { [ blockStyle , { width : ` ${ width } rem` } ] } >
15
16
< Eclipse width = { 47 } height = { 47 } css = { { flexShrink : 0 } } />
16
17
< span css = { spanStyle } > { children } </ span >
17
18
</ div >
Original file line number Diff line number Diff line change @@ -8,14 +8,20 @@ const meta = {
8
8
layout : 'centered' ,
9
9
} ,
10
10
args : {
11
- children : [ '타임 블록fjlaeijfla' ] ,
11
+ children : [ '타임 블록' ] ,
12
+ width : 10 ,
12
13
} ,
13
14
argTypes : {
14
15
children : {
15
16
control : {
16
17
type : 'text' ,
17
18
} ,
18
19
} ,
20
+ width : {
21
+ control : {
22
+ type : 'number' ,
23
+ } ,
24
+ } ,
19
25
} ,
20
26
} satisfies Meta < typeof TimeBlock > ;
21
27
You can’t perform that action at this time.
0 commit comments