Skip to content

Commit

Permalink
fix: expose StyleRecord type
Browse files Browse the repository at this point in the history
  • Loading branch information
LexSwed committed Oct 12, 2020
1 parent 70be457 commit ab82714
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/lib/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { StylesWithVariants } from './types/helpers';
import type { StylesWithVariants } from './types/helpers';

export { default as Box } from './Box';
export { default as Button } from './Button';
Expand Down
4 changes: 2 additions & 2 deletions src/lib/types/helpers.d.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import type { TCssWithBreakpoints } from '@stitches/react';
import type { TCssProperties, TCss } from '@stitches/core';
import { css, styled } from '../stitches.config';
import { css } from '../stitches.config';

type Config = GetConfig<typeof css>;
export type CssWithBreakpoints = TCssWithBreakpoints<Config>;
export type StylesObject = TCssProperties<Config>;
export type StylesWithVariants = Parameters<typeof styled>[1]['variants'];
export type StylesWithVariants = TCssProperties<Config>;

type GetConfig<S> = S extends TCss<infer T> ? T : never;

1 comment on commit ab82714

@vercel
Copy link

@vercel vercel bot commented on ab82714 Oct 12, 2020

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.