Skip to content

Commit

Permalink
Use new naming convention
Browse files Browse the repository at this point in the history
  • Loading branch information
sarayourfriend committed Jun 30, 2021
1 parent d0c2946 commit 38131d7
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
8 changes: 4 additions & 4 deletions packages/components/src/spacer/component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ import {
contextConnect,
PolymorphicComponentProps,
} from '../ui/context';
import type { SpacerProps } from './types';
import { SpacerWrapper } from './styles';
import type { Props } from './types';
import { SpacerView } from './styles';

function Spacer( props: PolymorphicComponentProps< SpacerProps, 'div' > ) {
function Spacer( props: PolymorphicComponentProps< Props, 'div' > ) {
const contextProps = useContextSystem( props, 'Spacer' );

return <SpacerWrapper { ...contextProps } />;
return <SpacerView { ...contextProps } />;
}

/**
Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/spacer/index.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
export { default as Spacer } from './component';
export type { SpacerProps } from './types';
export type { Props as SpacerProps } from './types';
2 changes: 1 addition & 1 deletion packages/components/src/spacer/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ const renderProperty = (
);
};

export const SpacerWrapper = styled.div< InnerProps >`
export const SpacerView = styled.div< InnerProps >`
${ renderProperty( 'marginTop' ) }
${ renderProperty( 'marginBottom' ) }
${ renderProperty( 'marginLeft' ) }
Expand Down
2 changes: 1 addition & 1 deletion packages/components/src/spacer/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,6 @@ export interface InnerProps {
*/
paddingRight?: SpaceInput;
}
export interface SpacerProps extends InnerProps {
export interface Props extends InnerProps {
children?: ReactNode;
}

0 comments on commit 38131d7

Please sign in to comment.