Skip to content

Commit

Permalink
Merge pull request #974 from primer/cb/ts-branch-name
Browse files Browse the repository at this point in the history
Migrate BranchName to TypeScript
  • Loading branch information
colebemis authored Jan 21, 2021
2 parents db46b0e + efa3599 commit 9f76c5d
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 3 deletions.
5 changes: 5 additions & 0 deletions .changeset/sharp-pugs-tap.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@primer/components": patch
---

Migrate `BranchName` to TypeScript
7 changes: 4 additions & 3 deletions src/BranchName.js → src/BranchName.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import PropTypes from 'prop-types'
import styled from 'styled-components'
import sx from './sx'
import sx, {SxProp} from './sx'
import theme from './theme'
import {COMMON, get} from './constants'
import {COMMON, get, SystemCommonProps} from './constants'

const BranchName = styled.a`
const BranchName = styled.a<SystemCommonProps & SxProp>`
display: inline-block;
padding: 2px 6px;
font-size: ${get('fontSizes.0')};
Expand All @@ -27,4 +27,5 @@ BranchName.propTypes = {
theme: PropTypes.object
}

export type BranchNameProps = React.ComponentProps<typeof BranchName>
export default BranchName
File renamed without changes.

1 comment on commit 9f76c5d

@vercel
Copy link

@vercel vercel bot commented on 9f76c5d Jan 21, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.