Skip to content
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
60228e1
remove sx support from CircleBadge.tsx
llastflowers Aug 26, 2025
89f3cff
remove sx from docs
llastflowers Aug 26, 2025
55df642
Update CircleBadge to remove sx support
llastflowers Aug 26, 2025
8c2577d
update tests to match updated component
llastflowers Aug 26, 2025
572f588
Merge branch 'main' into llastflowers/5780/no-sx-CircleBadge
llastflowers Sep 5, 2025
726baeb
tests fix for CI
llastflowers Sep 5, 2025
26c05eb
Merge branch 'main' into llastflowers/5780/no-sx-CircleBadge
llastflowers Sep 8, 2025
9909b83
Merge branch 'main' into llastflowers/5780/no-sx-CircleBadge
llastflowers Sep 10, 2025
b42adef
Merge branch 'main' into llastflowers/5780/no-sx-CircleBadge
llastflowers Sep 11, 2025
64c6e06
Merge branch 'main' into llastflowers/5780/no-sx-CircleBadge
llastflowers Sep 15, 2025
dd65b9e
pull in version updates from main and update exports for CircleBadge
llastflowers Sep 15, 2025
91667fb
Merge branch 'main' into llastflowers/5780/no-sx-CircleBadge
llastflowers Sep 17, 2025
b271d41
fix import order
llastflowers Sep 17, 2025
f728b30
Merge branch 'main' of github.com:primer/react into llastflowers/5780…
francinelucca Sep 23, 2025
1704e1a
convert to css modules
francinelucca Sep 23, 2025
09fa5ac
format
francinelucca Sep 23, 2025
e7d7d8c
remove console.log
francinelucca Sep 23, 2025
02da762
fix export
francinelucca Sep 23, 2025
fe993c4
Merge branch 'main' into llastflowers/5780/no-sx-CircleBadge
francinelucca Sep 23, 2025
c4ff809
Create lazy-elephants-shave.md
francinelucca Sep 23, 2025
7fa6fe0
fix props
francinelucca Sep 23, 2025
788f05a
Merge branch 'llastflowers/5780/no-sx-CircleBadge' of github.com:prim…
francinelucca Sep 23, 2025
4e61811
type fixes
francinelucca Sep 23, 2025
1e8c865
lint fix
francinelucca Sep 23, 2025
4894bcb
ignore error
francinelucca Sep 23, 2025
0a70abb
fix(CircleBadge): update snapshots, add className
francinelucca Sep 23, 2025
ce9144f
remove unused import
francinelucca Sep 23, 2025
fada74d
type fixes
francinelucca Sep 23, 2025
d00fba0
Merge branch 'main' into llastflowers/5780/no-sx-CircleBadge
francinelucca Sep 23, 2025
ed8b30b
Merge branch 'main' into llastflowers/5780/no-sx-CircleBadge
francinelucca Sep 23, 2025
9f01823
Merge branch 'main' of github.com:primer/react into llastflowers/5780…
francinelucca Sep 29, 2025
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
5 changes: 5 additions & 0 deletions .changeset/cool-apricots-sneeze.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@primer/react': major
---

Update CircleBadge component to no longer support sx
5 changes: 0 additions & 5 deletions packages/react/src/CircleBadge/CircleBadge.docs.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,6 @@
"name": "as",
"type": "React.ElementType",
"defaultValue": "\"div\""
},
{
"name": "sx",
"type": "SystemStyleObject",
"deprecated": true
}
],
"subcomponents": [
Expand Down
5 changes: 1 addition & 4 deletions packages/react/src/CircleBadge/CircleBadge.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
import styled from 'styled-components'
import {get} from '../constants'
import Octicon from '../Octicon'
import type {SxProp} from '../sx'
import sx from '../sx'
import isNumeric from '../utils/isNumeric'
import type {ComponentProps} from '../utils/types'

Expand All @@ -16,7 +14,7 @@ type StyledCircleBadgeProps = {
inline?: boolean
variant?: keyof typeof variantSizes
size?: number
} & SxProp
}

const sizeStyles = ({size, variant = 'medium'}: StyledCircleBadgeProps) => {
const calc = isNumeric(size) ? size : variantSizes[variant]
Expand All @@ -34,7 +32,6 @@ const CircleBadge = styled.div<StyledCircleBadgeProps>`
border-radius: 50%;
box-shadow: ${get('shadows.shadow.medium')};
${sizeStyles};
${sx};
`
const CircleBadgeIcon = styled(Octicon)`
height: auto;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,19 @@

exports[`CircleBadge > respects the inline prop 1`] = `
<div
class="sc-gEvEer lNPvJ"
class="sc-gEvEer ddpfio"
/>
`;

exports[`CircleBadge > respects the variant prop 1`] = `
<div
class="sc-gEvEer irZoQl"
class="sc-gEvEer cGlgmQ"
/>
`;

exports[`CircleBadge > uses the size prop to override the variant prop 1`] = `
<div
class="sc-gEvEer ceBMXF"
class="sc-gEvEer buHDOk"
size="20"
/>
`;
Loading