Skip to content

Commit c74adb4

Browse files
committed
fixed few rendering issues with the checkbox demo's
1 parent b6bcf78 commit c74adb4

File tree

3 files changed

+25
-15
lines changed

3 files changed

+25
-15
lines changed

packages/documentation/components/checkbox-group/widgets.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ function Widgets() {
2626
language="jsx"
2727
componentName="CheckBoxGroup"
2828
>
29-
<DemoWidget name="CheckBoxGroup" width={100}>
29+
<DemoWidget name="CheckBoxGroup" width={300}>
3030
{Default}
3131
</DemoWidget>
3232
</HeaderCodeToggle.Content>
@@ -45,7 +45,7 @@ function Widgets() {
4545
language="jsx"
4646
componentName="CheckBoxGroup"
4747
>
48-
<DemoWidget name="CheckBoxGroup" width={200}>
48+
<DemoWidget name="CheckBoxGroup" width={350}>
4949
{PreSelected}
5050
</DemoWidget>
5151
</HeaderCodeToggle.Content>
@@ -64,7 +64,7 @@ function Widgets() {
6464
language="jsx"
6565
componentName="CheckBoxGroup"
6666
>
67-
<DemoWidget name="CheckBoxGroup" width={200}>
67+
<DemoWidget name="CheckBoxGroup" width={400}>
6868
{Disabled}
6969
</DemoWidget>
7070
</HeaderCodeToggle.Content>
@@ -83,7 +83,7 @@ function Widgets() {
8383
language="jsx"
8484
componentName="CheckBoxGroup"
8585
>
86-
<DemoWidget name="CheckBoxGroup" width={150}>
86+
<DemoWidget name="CheckBoxGroup" width={300}>
8787
{CustomStyle}
8888
</DemoWidget>
8989
</HeaderCodeToggle.Content>
@@ -103,7 +103,7 @@ function Widgets() {
103103
language="jsx"
104104
componentName="CheckBoxGroup"
105105
>
106-
<DemoWidget name="CheckBoxGroup" width={150}>
106+
<DemoWidget name="CheckBoxGroup" width={300}>
107107
{RTL}
108108
</DemoWidget>
109109
</HeaderCodeToggle.Content>

packages/documentation/components/checkbox/widgets.tsx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ function widgets() {
2727
language="jsx"
2828
componentName="CheckBox"
2929
>
30-
<DemoWidget name="CheckBox" width={220}>
30+
<DemoWidget name="CheckBox" width={300}>
3131
{Default}
3232
</DemoWidget>
3333
</HeaderCodeToggle.Content>
@@ -49,7 +49,7 @@ function widgets() {
4949
language="jsx"
5050
componentName="CheckBox"
5151
>
52-
<DemoWidget name="CheckBox" width={200}>
52+
<DemoWidget name="CheckBox" width={300}>
5353
{Disabled}
5454
</DemoWidget>
5555
</HeaderCodeToggle.Content>
@@ -72,7 +72,7 @@ function widgets() {
7272
language="jsx"
7373
componentName="CheckBox"
7474
>
75-
<DemoWidget name="CheckBox" width={200}>
75+
<DemoWidget name="CheckBox" width={300}>
7676
{Large}
7777
</DemoWidget>
7878
</HeaderCodeToggle.Content>
@@ -95,7 +95,7 @@ function widgets() {
9595
language="jsx"
9696
componentName="CheckBox"
9797
>
98-
<DemoWidget name="CheckBox" width={150}>
98+
<DemoWidget name="CheckBox" width={300}>
9999
{CustomStyle}
100100
</DemoWidget>
101101
</HeaderCodeToggle.Content>
@@ -114,13 +114,13 @@ function widgets() {
114114
language="jsx"
115115
componentName="CheckBox"
116116
>
117-
<DemoWidget name="CheckBox" width={200}>
117+
<DemoWidget name="CheckBox" width={300}>
118118
{CustomStyle}
119119
</DemoWidget>
120-
<DemoWidget name="CheckBox" width={200}>
120+
<DemoWidget name="CheckBox" width={300}>
121121
{Medium}
122122
</DemoWidget>
123-
<DemoWidget name="CheckBox" width={200}>
123+
<DemoWidget name="CheckBox" width={300}>
124124
{LargeRounded}
125125
</DemoWidget>
126126
</HeaderCodeToggle.Content>

packages/lib/components/checkbox/checkbox.module.scss

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,14 @@ $heights: (
5555

5656
// Border styles
5757
@mixin borderStyles {
58+
border-radius: hybrid.$radius-xs;
59+
5860
&:not(.dark) {
59-
@extend %border;
61+
border: 1px solid rgba(theme.$secondary-rgb, 0.75);
62+
}
63+
64+
&.dark {
65+
border: 1px solid rgba(theme.$dark-control-border-rgb, 1);
6066
}
6167
}
6268

@@ -66,7 +72,7 @@ $heights: (
6672

6773
// Hover styles with interactive feedback
6874
@mixin hoverStyles {
69-
@extend %border-radius;
75+
border-radius: hybrid.$radius-xs;
7076

7177
@include hybrid.hover-feedback() {
7278
&.dark {
@@ -116,7 +122,11 @@ $heights: (
116122
}
117123

118124
&.round {
119-
border-radius: hybrid.$radius-sm;
125+
border-radius: hybrid.$radius-xs;
126+
}
127+
128+
&.square {
129+
border-radius: hybrid.$radius-xs;
120130
}
121131

122132
svg {

0 commit comments

Comments
 (0)