Skip to content
Open
Show file tree
Hide file tree
Changes from 6 commits
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
aebf926
chore(docs, styles): added size variant in form radio button stories
Dec 5, 2025
ee055d9
chore(docs, styles): added `size: 'null'` in args for stories, added โ€ฆ
Dec 5, 2025
d706405
added changeset
bucknatt Dec 5, 2025
2180e38
chore(docs, styles): fixed stylelint error
Dec 5, 2025
b82751a
chore(docs, styles): fixed stylelint error
Dec 5, 2025
12425ba
chore(docs, styles): fixed stylelint error-3
Dec 5, 2025
789dc7a
feat(styles): added grouped radio button gap in `fieldset` CSS class
bucknatt Dec 9, 2025
dd6efcc
feat(styles): added CSS class to align label with radio
bucknatt Dec 9, 2025
62900e7
feat(styles): fixed label alignment with radio button for group vertiโ€ฆ
bucknatt Dec 9, 2025
37d33c9
feat(styles): fixed gap to be like in figma for all radio group (horiโ€ฆ
bucknatt Dec 9, 2025
0a00949
feat(docs): added snapshot stories for radio group vertical and horizโ€ฆ
bucknatt Dec 10, 2025
6320d9a
feat(docs): fixed import on snapshot stories
bucknatt Dec 10, 2025
7c5feee
feat(docs): fixed group name for cypress e2e testing on snapshot stories
bucknatt Dec 10, 2025
a67c6f1
feat(docs): fixed group name for cypress e2e testing on snapshot stories
bucknatt Dec 10, 2025
0495c59
feat(docs): fixed e2e and added name attribute to render-function
bucknatt Dec 10, 2025
fe392d9
Merge branch 'refs/heads/main' into 6290-htmlcss-radio-button-small
bucknatt Dec 11, 2025
d42e7d3
feat(compo, styles): added font-size for small variant on divider
bucknatt Dec 11, 2025
8942ba7
feat(docs): fix e2e-1
bucknatt Dec 11, 2025
0bdbe63
feat(docs): fix e2e-2 provided with unique id
bucknatt Dec 11, 2025
0e273ee
feat(docs): fix e2e-3 removed unused vars and type any for linting
bucknatt Dec 11, 2025
fc8751e
feat(docs): fix pipeline fail by replacing math.random because of insโ€ฆ
bucknatt Dec 11, 2025
68aa346
feat(docs): updated font-size for small label
bucknatt Dec 16, 2025
2f3add2
feat(docs): added logic to generate unique id with fallback to simpleโ€ฆ
bucknatt Dec 23, 2025
caa8952
feat(docs, styles): moved form-check code to form-check scss file forโ€ฆ
bucknatt Feb 9, 2026
8117383
feat(docs, styles): added code in checkbox scss-file for group
bucknatt Feb 9, 2026
91b8c47
feat(docs, styles): updated form-check scss-file to working code for โ€ฆ
bucknatt Feb 11, 2026
8af14f1
Merge branch 'main' of https://github.com/swisspost/design-system intโ€ฆ
bucknatt Feb 13, 2026
d84ad6e
chore(doc, styles): formatted and fixed stylelint errors
Feb 17, 2026
47b60cc
chore(doc, styles): added smaller icon-size and icon-dot for small raโ€ฆ
Feb 17, 2026
2f254a3
chore(doc, styles): updated logic for default and smaller font-size fโ€ฆ
Feb 17, 2026
19b4cc9
Merge branch 'main' of https://github.com/swisspost/design-system intโ€ฆ
bucknatt Feb 19, 2026
5df5cbe
feat(docs, styles): refactoring code for checkbox group
bucknatt Feb 19, 2026
cc574ac
feat(docs, styles): added group vertical and inline for default and sโ€ฆ
bucknatt Feb 19, 2026
a93bbed
feat(docs, styles): refactoring and added vertical and horizontal group
bucknatt Feb 24, 2026
48fbee6
feat(docs, styles): removed duplicated code for checkbox
bucknatt Feb 24, 2026
61064e5
feat(docs, styles): removed padding-inline-start before label in radiโ€ฆ
bucknatt Feb 24, 2026
960cb5b
Merge branch 'main' into 6290-htmlcss-radio-button-small
bucknatt Feb 25, 2026
e775bd4
Merge branch 'main' into 6290-htmlcss-radio-button-small
bucknatt Feb 25, 2026
f1cf175
feat(docs, styles): updated changeset
bucknatt Mar 5, 2026
bc1c16c
feat(docs, styles): revert change on aria-describedby
bucknatt Mar 5, 2026
0dbe58a
feat(docs, styles): revert changes on render Radio Group to be same aโ€ฆ
bucknatt Mar 5, 2026
f8fc297
feat(docs, styles): add small Radiobutton Group examples for Grouped โ€ฆ
bucknatt Mar 5, 2026
6a5cfdf
feat(docs, styles): update markdown for group examples for small group
bucknatt Mar 5, 2026
8cbff76
feat(docs, styles): revert change and set anchor on link for radio-buโ€ฆ
bucknatt Mar 5, 2026
5aec70a
feat(docs, styles): revert changes on validation line
bucknatt Mar 5, 2026
5a225f1
feat(docs, styles): revert and remove snapshot counter to create id wโ€ฆ
bucknatt Mar 5, 2026
86e86a9
feat(docs, styles): remove unused name not in args in meta.render funโ€ฆ
bucknatt Mar 10, 2026
5bb4bb3
Merge branch 'main' into 6290-htmlcss-radio-button-small
bucknatt Mar 10, 2026
a7d0cfa
feat(docs, styles): remove already defined `display flex` and `align-โ€ฆ
bucknatt Mar 10, 2026
24a712c
feat(docs, styles): remove redundant single padding from fieldset
bucknatt Mar 11, 2026
c5ce189
feat(docs, styles): replace `padding-block-start` and `padding-block-โ€ฆ
bucknatt Mar 11, 2026
7459c67
feat(docs, styles): add titles to snapshot stories,
bucknatt Mar 11, 2026
23e335a
feat(docs, styles): fix lint errors
bucknatt Mar 11, 2026
0824894
feat(docs, styles): remove typo
bucknatt Mar 11, 2026
c4031fd
feat(docs, styles): revert change
bucknatt Mar 11, 2026
dceaaa1
feat(docs, styles): change title text
bucknatt Mar 11, 2026
3c48834
feat(docs, styles): add groupName to input-tag of radio
bucknatt Mar 11, 2026
f88176f
feat(docs, styles): remove hardcoded line height as it is not unnecesโ€ฆ
bucknatt Mar 12, 2026
b15b4e3
feat(docs, styles): remove vertica-align for label, as it is a flex cโ€ฆ
bucknatt Mar 12, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .changeset/funny-rabbits-think.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@swisspost/design-system-documentation": minor
"@swisspost/design-system-styles": minor
---

The CSS `.form-check-sm` class has been added to the Form Radio Button component and the variant size is added to the component's documunetation.
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ const meta: MetaComponent = {
disabled: false,
validation: 'null',
requiredOptional: 'null',
size: 'null',
},
argTypes: {
hiddenLegend: {
Expand Down Expand Up @@ -60,6 +61,21 @@ const meta: MetaComponent = {
category: 'General',
},
},
size: {
name: 'Size',
description: 'Defines the size of the component.',
control: {
type: 'radio',
labels: {
'null': 'Default',
'form-check-sm': 'Small',
},
},
options: ['null', 'form-check-sm'],
table: {
category: 'General',
},
},
checked: {
name: 'Checked',
description: 'When set to `true`, places the component in the checked state.',
Expand Down
22 changes: 22 additions & 0 deletions packages/styles/src/components/radio-button.scss
Original file line number Diff line number Diff line change
Expand Up @@ -123,3 +123,25 @@ tokens.$default-map: components.$post-radio-button;
}
}
}

.form-check-sm:not(.form-switch):has(input[type='radio']) {
> input[type='radio'] {
width: tokens.get('radio-button-small-icon-size');
height: tokens.get('radio-button-small-icon-size');

margin-inline: tokens.get('radio-button-small-icon-padding');
margin-block: calc(
tokens.get('radio-button-small-icon-padding') +
tokens.get('radio-button-small-icon-container-padding')
);

&::after {
width: tokens.get('radio-button-small-icon-dot');
height: tokens.get('radio-button-small-icon-dot');
}
}

> label {
padding-block: tokens.get('radio-button-small-label-padding-block');
}
}
Loading