Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
8 changes: 0 additions & 8 deletions packages/core/src/main/ts/block/Block.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,3 @@ export const Block: FC<BlockProps> = ({
)

Block.displayName = 'Block'

Block.defaultProps = {
active: false,
focus: false,
hover: false,
accent: false,
bg: '#fff',
}
6 changes: 0 additions & 6 deletions packages/core/src/main/ts/cross-burger/CrossBurger.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,3 @@ export const CrossBurger: FC<CrossBurgerProps> = ({
)

CrossBurger.displayName = 'CrossBurger'

CrossBurger.defaultProps = {
size: 6,
color: '#000',
active: false,
}
5 changes: 0 additions & 5 deletions packages/core/src/main/ts/flag/Flag.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -247,8 +247,3 @@ export const Flag: FC<FlagProps> = ({
)

Flag.displayName = 'Flag'

Flag.defaultProps = {
width: 6,
height: 4,
}
5 changes: 0 additions & 5 deletions packages/core/src/main/ts/grid/Grid.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,3 @@ export const Grid: FC<GridProps> = ({
}

Grid.displayName = 'Grid'

Grid.defaultProps = {
gutter: 20,
columns: 12,
}
5 changes: 0 additions & 5 deletions packages/core/src/main/ts/icon/CircleBellIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,3 @@ export const CircleBellIcon: FC<CircleBellIconProps> = ({ size = 6, color = '#00
)

CircleBellIcon.displayName = 'CircleBellIcon'

CircleBellIcon.defaultProps = {
size: 6,
color: '#000',
}
6 changes: 0 additions & 6 deletions packages/core/src/main/ts/icon/FeedIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,3 @@ export const FeedIcon: FC<FeedIconProps> = ({
)

FeedIcon.displayName = 'FeedIcon'

FeedIcon.defaultProps = {
size: 6,
color: '#000',
active: false,
}
6 changes: 0 additions & 6 deletions packages/core/src/main/ts/icon/FilterIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,3 @@ export const FilterIcon: FC<FilterIconProps> = ({
)

FilterIcon.displayName = 'FilterIcon'

FilterIcon.defaultProps = {
size: 6,
color: '#000',
active: false,
}
5 changes: 0 additions & 5 deletions packages/core/src/main/ts/icon/Icon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -310,8 +310,3 @@ export const Icon: FC<IconProps> = ({
)

Icon.displayName = 'Icon'

Icon.defaultProps = {
size: 6,
color: '#000',
}
6 changes: 1 addition & 5 deletions packages/core/src/main/ts/icon/QuestionIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export interface QuestionIconProps {
size?: number
}

export const QuestionIcon: FC<QuestionIconProps> = ({ size, ...rest }) => (
export const QuestionIcon: FC<QuestionIconProps> = ({ size = 6, ...rest }) => (
<Svg
{...getDataProps(rest)}
width={size}
Expand All @@ -29,7 +29,3 @@ export const QuestionIcon: FC<QuestionIconProps> = ({ size, ...rest }) => (
)

QuestionIcon.displayName = 'QuestionIcon'

QuestionIcon.defaultProps = {
size: 6,
}
4 changes: 0 additions & 4 deletions packages/core/src/main/ts/image/Image.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,3 @@ export const Image: FC<ImageProps> = ({
)

Image.displayName = 'Image'

Image.defaultProps = {
stub: true,
}
11 changes: 6 additions & 5 deletions packages/core/src/main/ts/input/BasicInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,12 @@ export interface BasicInputProps {
}

export const BasicInput = forwardRef<HTMLInputElement, BasicInputProps>(
(props, ref) => {
({
tabIndex = 0,
...props
},
ref
) => {
const theme = useTheme()

const common = {
Expand Down Expand Up @@ -119,7 +124,3 @@ export const BasicInput = forwardRef<HTMLInputElement, BasicInputProps>(
)

BasicInput.displayName = 'BasicInput'

BasicInput.defaultProps = {
tabIndex: 0,
}
6 changes: 1 addition & 5 deletions packages/core/src/main/ts/input/ContentInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export interface ContentInputProps {
}

export const ContentInput = forwardRef<HTMLInputElement, ContentInputProps>(
(props, ref) => {
({ tabIndex = 0, ...props }, ref) => {
const common = {
width: 1,
height: 12,
Expand Down Expand Up @@ -113,7 +113,3 @@ export const ContentInput = forwardRef<HTMLInputElement, ContentInputProps>(
)

ContentInput.displayName = 'ContentInput'

ContentInput.defaultProps = {
tabIndex: 0,
}
6 changes: 1 addition & 5 deletions packages/core/src/main/ts/input/SelectInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export interface SelectInputProps {
}

export const SelectInput = forwardRef<HTMLInputElement, SelectInputProps>(
(props, ref) => {
({ tabIndex = 0, ...props }, ref) => {
const common = {
ref,
width: 1,
Expand Down Expand Up @@ -75,7 +75,3 @@ export const SelectInput = forwardRef<HTMLInputElement, SelectInputProps>(
)

SelectInput.displayName = 'SelectInput'

SelectInput.defaultProps = {
tabIndex: 0,
}
7 changes: 2 additions & 5 deletions packages/core/src/main/ts/primitive/Box.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,11 @@ export const BoxOptions: StyledOptions<BoxProps> = {
}

export const BoxStyles: Interpolation<BoxProps & { theme: Theme }> = ({
display = 'block',
theme,
...props
}) => ({
display: props.display,
display,
margin: cssValue(props.m, theme.scale, false),
marginTop: cssValue(props.mt || props.my, theme.scale, false),
marginRight: cssValue(props.mr || props.mx, theme.scale, false),
Expand Down Expand Up @@ -123,7 +124,3 @@ export const BoxStyles: Interpolation<BoxProps & { theme: Theme }> = ({
export const Box = styled('div', BoxOptions)<BoxProps>(BoxStyles)

Box.displayName = 'Box'

Box.defaultProps = {
display: 'block',
}
13 changes: 8 additions & 5 deletions packages/core/src/main/ts/primitive/Flex.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,18 @@ export const FlexOptions: StyledOptions<FlexProps> = {
export const Flex = styled(
Box,
FlexOptions,
)<FlexProps>(({ wrap, direction, align, justify }) => ({
)<FlexProps>(({
display = 'flex',
wrap,
direction,
align,
justify
}) => ({
display,
flexWrap: wrap,
flexDirection: direction,
alignItems: align,
justifyContent: justify,
}))

Flex.displayName = 'Flex'

Flex.defaultProps = {
display: 'flex',
}
11 changes: 5 additions & 6 deletions packages/core/src/main/ts/recaptcha-field/ReCaptchaField.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,16 @@ export interface ReCaptchaFieldProps extends ReCaptchaProps {
help?: ReactNode
}

export const ReCaptchaField: FC<ReCaptchaFieldProps> = (props) => (
export const ReCaptchaField: FC<ReCaptchaFieldProps> = ({
tabIndex = 0,
...props
}) => (
<SimpleField
{...getDataProps(props)}
input={
<ReCaptcha
siteKey={props.siteKey}
tabIndex={props.tabIndex}
tabIndex={tabIndex}
value={props.value}
onChange={props.onChange}
onErrored={props.onErrored}
Expand All @@ -30,7 +33,3 @@ export const ReCaptchaField: FC<ReCaptchaFieldProps> = (props) => (
)

ReCaptchaField.displayName = 'ReCaptchaField'

ReCaptchaField.defaultProps = {
tabIndex: 0,
}
4 changes: 0 additions & 4 deletions packages/core/src/main/ts/spacer/Spacer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,3 @@ export const Spacer: FC<SpacerProps> = ({ size = 'm', children }) => {
}

Spacer.displayName = 'Spacer'

Spacer.defaultProps = {
size: 'm',
}
11 changes: 5 additions & 6 deletions packages/core/src/main/ts/stub/Stub.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,10 @@ export interface StubProps {
r?: Value
}

export const Stub: FC<StubProps> = (props) => (
export const Stub: FC<StubProps> = ({
r = 4,
...props
}) => (
<Box
{...getDataProps(props)}
as="span"
Expand All @@ -43,7 +46,7 @@ export const Stub: FC<StubProps> = (props) => (
<CardPos
as="span"
type="relative"
r={props.r}
r={r}
overflow="hidden"
bg={props.inverse ? 'rgba(255, 255, 255, 0.14)' : '#E6E6E6'}
width={1}
Expand Down Expand Up @@ -73,7 +76,3 @@ export const Stub: FC<StubProps> = (props) => (
)

Stub.displayName = 'Stub'

Stub.defaultProps = {
r: 4,
}
11 changes: 6 additions & 5 deletions packages/core/src/main/ts/text-area/BasicTextArea.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,12 @@ export interface BasicTextAreaProps {
export const BasicTextArea = forwardRef<
HTMLTextAreaElement,
BasicTextAreaProps
>((props, ref) => (
>(({
tabIndex = 0,
...props
},
ref
) => (
<TextArea
{...getDataProps(props)}
ref={ref}
Expand Down Expand Up @@ -88,7 +93,3 @@ export const BasicTextArea = forwardRef<
))

BasicTextArea.displayName = 'BasicTextArea'

BasicTextArea.defaultProps = {
tabIndex: 0,
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@ exports[`DatePicker renders correctly 1`] = `
className="css-1bx5ylf"
>
<div
className="css-70qvj9"
className="css-1qsie2a"
>
<input
autoComplete="off"
className="css-1haa77m"
className="css-1fb1yqj"
defaultValue=""
disabled={false}
onBlur={[Function]}
Expand Down Expand Up @@ -58,7 +58,7 @@ exports[`DatePicker renders correctly 1`] = `
</div>
</div>
<div
className="css-1abbrc"
className="css-hnykp"
/>
</div>
<div
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,11 @@ exports[`DateRangePicker renders correctly 1`] = `
className="css-1bx5ylf"
>
<div
className="css-70qvj9"
className="css-1qsie2a"
>
<input
autoComplete="off"
className="css-1haa77m"
className="css-1fb1yqj"
disabled={false}
onBlur={[Function]}
onChange={[Function]}
Expand Down Expand Up @@ -66,7 +66,7 @@ exports[`DateRangePicker renders correctly 1`] = `
</div>
</div>
<div
className="css-1abbrc"
className="css-hnykp"
>
<div
className="css-13ulrxv"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

exports[`Icon renders correctly 1`] = `
<div
className="css-1n0zz00"
className="css-12rtanj"
>
<div
className="css-1rfmcj9"
Expand Down Expand Up @@ -42,7 +42,7 @@ exports[`Icon renders correctly 1`] = `

exports[`Icon renders correctly 2`] = `
<div
className="css-1n0zz00"
className="css-12rtanj"
>
<div
className="css-1rfmcj9"
Expand Down
Loading
Loading