Skip to content

Commit 86eac43

Browse files
committed
Add checkbox for testing
1 parent d0e1d09 commit 86eac43

File tree

2 files changed

+13
-3
lines changed

2 files changed

+13
-3
lines changed

src/components/card2/CardCheckbox.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import * as React from 'react';
22
import cx from 'classnames';
3+
import Checkbox from '../form-elements/checkbox/Checkbox';
34

45
export interface CardCheckboxPropsType {
56
/**
@@ -27,12 +28,13 @@ const CardCheckbox = ({
2728
};
2829

2930
return (
30-
<div
31+
<label
3132
className={cx('sg-card-radio', className)}
3233
style={{...style, ...cssVariables}}
3334
>
35+
<Checkbox />
3436
{children}
35-
</div>
37+
</label>
3638
);
3739
};
3840

src/components/card2/card.scss

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,18 @@
11
.sg-card-button,
2-
.sg-card-radio {
2+
.sg-card-radio,
3+
.sg-card-checkbox {
4+
display: block;
35
width: var(--card-width, auto);
46
height: var(--card-height, auto);
57
border-radius: 8px;
68
border: 2px solid #e1eaf1;
79

10+
transition: transform $durationModerate2 $easingRegular;
11+
12+
&:active:not([disabled]) {
13+
transform: scale(0.98);
14+
}
15+
816
&:hover {
917
border-color: #46535f;
1018
}

0 commit comments

Comments
 (0)