@stokelp/ui 1.9.0 → 1.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,9 @@
1
- import { AccordionRecipe } from '@stokelp/styled-system/recipes';
2
- import { StyledComponent } from '@stokelp/styled-system/jsx';
3
- import { ComponentVariants } from '../../utils/slots';
4
1
  import { Accordion as ArkAccordion } from '@ark-ui/react';
5
- import { ForwardRefExoticComponent, RefAttributes, ComponentProps } from 'react';
2
+ import { ComponentProps, ForwardRefExoticComponent, RefAttributes } from 'react';
3
+ import { ComponentVariants } from '../../utils/slots';
4
+ import { StyledComponent } from '@stokelp/styled-system/jsx';
5
+ import { AccordionRecipe } from '@stokelp/styled-system/recipes';
6
+
6
7
  export declare const Accordion: ComponentVariants<StyledComponent<ForwardRefExoticComponent<ArkAccordion.RootProps & RefAttributes<HTMLDivElement>>, {}>, AccordionRecipe>;
7
8
  export declare const AccordionItem: StyledComponent<ForwardRefExoticComponent<ArkAccordion.ItemProps & RefAttributes<HTMLDivElement>>, {}>;
8
9
  export declare const AccordionItemContent: StyledComponent<ForwardRefExoticComponent<ArkAccordion.ItemContentProps & RefAttributes<HTMLDivElement>>, {}>;
@@ -1,8 +1,8 @@
1
- import { JSX } from 'react/jsx-runtime';
2
- import { type HTMLStyledProps } from '@stokelp/styled-system/types';
1
+ import { HTMLStyledProps } from '@stokelp/styled-system/types';
2
+
3
3
  type As = 'span' | 'div' | 'nav' | 'aside' | 'ul' | 'li' | 'main' | 'section' | 'header' | 'footer';
4
4
  export type BoxProps = {
5
5
  as?: As;
6
6
  } & HTMLStyledProps<As>;
7
- export declare const Box: (props: BoxProps) => JSX.Element;
7
+ export declare const Box: (props: BoxProps) => import("react/jsx-runtime").JSX.Element;
8
8
  export {};
@@ -1,6 +1,7 @@
1
- import { ButtonVariantProps } from '@stokelp/styled-system/recipes';
1
+ import { ComponentProps } from 'react';
2
2
  import { StyledComponent } from '@stokelp/styled-system/jsx';
3
- import type { ComponentProps } from 'react';
3
+ import { ButtonVariantProps } from '@stokelp/styled-system/recipes';
4
+
4
5
  export declare const Button: StyledComponent<"button", ButtonVariantProps>;
5
6
  export interface ButtonProps extends ComponentProps<typeof Button> {
6
7
  }
@@ -1,7 +1,8 @@
1
- import { type CheckboxRootProps } from '@ark-ui/react';
2
- import { ForwardRefExoticComponent, RefAttributes, type ReactNode } from 'react';
3
- import { type CheckboxVariantProps } from '@stokelp/styled-system/recipes';
4
- import type { Assign, JsxStyleProps } from '@stokelp/styled-system/types';
1
+ import { CheckboxRootProps } from '@ark-ui/react';
2
+ import { ReactNode, ForwardRefExoticComponent, RefAttributes } from 'react';
3
+ import { CheckboxVariantProps } from '@stokelp/styled-system/recipes';
4
+ import { Assign, JsxStyleProps } from '@stokelp/styled-system/types';
5
+
5
6
  export interface CheckboxProps extends Assign<JsxStyleProps, CheckboxRootProps>, CheckboxVariantProps {
6
7
  children?: ReactNode;
7
8
  }
@@ -1,7 +1,8 @@
1
- import { DatepickerRecipe } from '@stokelp/styled-system/recipes';
2
- import { ComponentVariants } from '../../utils/slots';
3
1
  import { DatePicker as ArkDatePicker } from '@ark-ui/react';
4
- import { ForwardRefExoticComponent, RefAttributes, ComponentProps, FC } from 'react';
2
+ import { ComponentProps, FC, ForwardRefExoticComponent, RefAttributes } from 'react';
3
+ import { ComponentVariants } from '../../utils/slots';
4
+ import { DatepickerRecipe } from '@stokelp/styled-system/recipes';
5
+
5
6
  declare const DatePickerRoot: ComponentVariants<ForwardRefExoticComponent<ArkDatePicker.RootProps & RefAttributes<HTMLDivElement>>, DatepickerRecipe>;
6
7
  interface DatePickerRootProps extends ComponentProps<typeof DatePickerRoot> {
7
8
  placeholder?: string;
@@ -1,27 +1,21 @@
1
- import { StyledComponent } from '@stokelp/styled-system/jsx';
2
- import { DrawerRecipe } from '@stokelp/styled-system/recipes';
3
- import { JSX } from 'react/jsx-runtime';
1
+ import { Dialog as ArkDrawer, PolymorphicProps } from '@ark-ui/react';
2
+ import { ComponentProps, ForwardRefExoticComponent, DetailedHTMLProps, HTMLAttributes, DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES, RefObject, RefAttributes } from 'react';
4
3
  import { ComponentVariants } from '../../utils/slots';
5
- import { Dialog as ArkDrawer } from '@ark-ui/react';
6
- import { ForwardRefExoticComponent, DetailedHTMLProps, HTMLAttributes, RefObject, RefAttributes, ComponentProps } from 'react';
7
- export declare const Drawer: ComponentVariants<(props: ArkDrawer.RootProps) => JSX.Element, DrawerRecipe>;
8
- export declare const DrawerBody: StyledComponent<ForwardRefExoticComponent<Omit<DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
9
- ref?: ((instance: HTMLElement | null) => void) | RefObject<HTMLElement> | null | undefined;
10
- } & {
11
- asChild?: boolean | undefined;
12
- }>, {}>;
4
+ import { DrawerRecipe } from '@stokelp/styled-system/recipes';
5
+ import { StyledComponent } from '@stokelp/styled-system/jsx';
6
+
7
+ export declare const Drawer: ComponentVariants<(props: ArkDrawer.RootProps) => import("react/jsx-runtime").JSX.Element, DrawerRecipe>;
8
+ export declare const DrawerBody: StyledComponent<ForwardRefExoticComponent<Omit< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
9
+ ref?: ((instance: HTMLElement | null) => void | DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | RefObject<HTMLElement> | null | undefined;
10
+ } & PolymorphicProps>, {}>;
13
11
  export declare const DrawerCloseTrigger: StyledComponent<ForwardRefExoticComponent<ArkDrawer.CloseTriggerProps & RefAttributes<HTMLButtonElement>>, {}>;
14
- export declare const DrawerFooter: StyledComponent<ForwardRefExoticComponent<Omit<DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
15
- ref?: ((instance: HTMLElement | null) => void) | RefObject<HTMLElement> | null | undefined;
16
- } & {
17
- asChild?: boolean | undefined;
18
- }>, {}>;
19
- export declare const DrawerHeader: ForwardRefExoticComponent<Omit<Omit<DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
20
- ref?: ((instance: HTMLElement | null) => void) | RefObject<HTMLElement> | null | undefined;
21
- } & {
22
- asChild?: boolean | undefined;
23
- }, "ref"> & {
24
- showCloseTrigger?: boolean | undefined;
12
+ export declare const DrawerFooter: StyledComponent<ForwardRefExoticComponent<Omit< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
13
+ ref?: ((instance: HTMLElement | null) => void | DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | RefObject<HTMLElement> | null | undefined;
14
+ } & PolymorphicProps>, {}>;
15
+ export declare const DrawerHeader: ForwardRefExoticComponent<Omit<Omit< DetailedHTMLProps<HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
16
+ ref?: ((instance: HTMLElement | null) => void | DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | RefObject<HTMLElement> | null | undefined;
17
+ } & PolymorphicProps, "ref"> & {
18
+ showCloseTrigger?: boolean;
25
19
  } & RefAttributes<HTMLElement>>;
26
20
  export declare const DrawerTitle: StyledComponent<ForwardRefExoticComponent<ArkDrawer.TitleProps & RefAttributes<HTMLHeadingElement>>, {}>;
27
21
  export declare const DrawerTrigger: StyledComponent<ForwardRefExoticComponent<ArkDrawer.TriggerProps & RefAttributes<HTMLButtonElement>>, {}>;
@@ -1,6 +1,7 @@
1
- import { FormControlVariantProps } from '@stokelp/styled-system/recipes';
1
+ import { ComponentProps, FC } from 'react';
2
2
  import { StyledComponent } from '@stokelp/styled-system/jsx';
3
- import type { ComponentProps, FC } from 'react';
3
+ import { FormControlVariantProps } from '@stokelp/styled-system/recipes';
4
+
4
5
  declare const StyledFormControl: StyledComponent<"div", FormControlVariantProps>;
5
6
  export interface FormControlProps extends ComponentProps<typeof StyledFormControl> {
6
7
  isInvalid?: boolean;
@@ -1,6 +1,7 @@
1
- import { FormHelperTextVariantProps } from '@stokelp/styled-system/recipes';
1
+ import { ComponentProps } from 'react';
2
2
  import { StyledComponent } from '@stokelp/styled-system/jsx';
3
- import type { ComponentProps } from 'react';
3
+ import { FormHelperTextVariantProps } from '@stokelp/styled-system/recipes';
4
+
4
5
  export declare const FormHelperText: StyledComponent<"p", FormHelperTextVariantProps>;
5
6
  export interface FormHelperTextProps extends ComponentProps<typeof FormHelperText> {
6
7
  }
@@ -1,6 +1,7 @@
1
- import { FormLabelVariantProps } from '@stokelp/styled-system/recipes';
1
+ import { ComponentProps, FC, ReactNode } from 'react';
2
2
  import { StyledComponent } from '@stokelp/styled-system/jsx';
3
- import type { ComponentProps, FC, ReactNode } from 'react';
3
+ import { FormLabelVariantProps } from '@stokelp/styled-system/recipes';
4
+
4
5
  declare const StyledFormLabel: StyledComponent<"label", FormLabelVariantProps>;
5
6
  export interface FormLabelProps extends ComponentProps<typeof StyledFormLabel> {
6
7
  addon?: ReactNode;
@@ -1,9 +1,9 @@
1
- import { JSX } from 'react/jsx-runtime';
2
- import { type HTMLStyledProps } from '@stokelp/styled-system/jsx';
3
- import { type HeadingVariantProps } from '@stokelp/styled-system/recipes';
1
+ import { HTMLStyledProps } from '@stokelp/styled-system/jsx';
2
+ import { HeadingVariantProps } from '@stokelp/styled-system/recipes';
3
+
4
4
  type As = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6';
5
5
  export type HeadingProps = {
6
6
  as?: As;
7
7
  } & HeadingVariantProps & HTMLStyledProps<As>;
8
- export declare const Heading: (props: HeadingProps) => JSX.Element;
8
+ export declare const Heading: (props: HeadingProps) => import("react/jsx-runtime").JSX.Element;
9
9
  export {};
@@ -1,6 +1,7 @@
1
- import { InputVariantProps } from '@stokelp/styled-system/recipes';
1
+ import { ComponentProps } from 'react';
2
2
  import { StyledComponent } from '@stokelp/styled-system/jsx';
3
- import type { ComponentProps } from 'react';
3
+ import { InputVariantProps } from '@stokelp/styled-system/recipes';
4
+
4
5
  export declare const Input: StyledComponent<"input", InputVariantProps>;
5
6
  export interface InputProps extends ComponentProps<typeof Input> {
6
7
  }
@@ -1,10 +1,10 @@
1
- import { InputAddonVariantProps } from '@stokelp/styled-system/recipes';
1
+ import { ComponentProps, ForwardRefExoticComponent, DetailedHTMLProps, HTMLAttributes, DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES, RefObject } from 'react';
2
2
  import { StyledComponent } from '@stokelp/styled-system/jsx';
3
- import { ForwardRefExoticComponent, DetailedHTMLProps, HTMLAttributes, RefObject, ComponentProps } from 'react';
4
- export declare const InputAddon: StyledComponent<ForwardRefExoticComponent<Omit<DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
5
- ref?: ((instance: HTMLDivElement | null) => void) | RefObject<HTMLDivElement> | null | undefined;
6
- } & {
7
- asChild?: boolean | undefined;
8
- }>, InputAddonVariantProps>;
3
+ import { PolymorphicProps } from '@ark-ui/react';
4
+ import { InputAddonVariantProps } from '@stokelp/styled-system/recipes';
5
+
6
+ export declare const InputAddon: StyledComponent<ForwardRefExoticComponent<Omit< DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
7
+ ref?: ((instance: HTMLDivElement | null) => void | DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | RefObject<HTMLDivElement> | null | undefined;
8
+ } & PolymorphicProps>, InputAddonVariantProps>;
9
9
  export interface InputAddonProps extends ComponentProps<typeof InputAddon> {
10
10
  }
@@ -1,6 +1,7 @@
1
- import { InputGroupVariantProps } from '@stokelp/styled-system/recipes';
1
+ import { ComponentProps } from 'react';
2
2
  import { StyledComponent } from '@stokelp/styled-system/jsx';
3
- import type { ComponentProps } from 'react';
3
+ import { InputGroupVariantProps } from '@stokelp/styled-system/recipes';
4
+
4
5
  export declare const InputGroup: StyledComponent<"div", InputGroupVariantProps>;
5
6
  export interface InputGroupProps extends ComponentProps<typeof InputGroup> {
6
7
  }
@@ -1,7 +1,8 @@
1
- import type { FC } from 'react';
2
- import { type SelectRootProps } from '@ark-ui/react';
1
+ import { FC } from 'react';
2
+ import { SelectRootProps } from '@ark-ui/react';
3
3
  import { select } from '@stokelp/styled-system/recipes';
4
4
  import { HTMLStyledProps, RecipeVariantProps } from '@stokelp/styled-system/types';
5
+
5
6
  export type SelectItem = {
6
7
  value: string;
7
8
  label: string;
@@ -1,7 +1,8 @@
1
- import { type SwitchRootProps } from '@ark-ui/react';
2
- import { type SwitchRecipeVariantProps } from '@stokelp/styled-system/recipes';
3
- import type { Assign, JsxStyleProps } from '@stokelp/styled-system/types';
4
- import { ForwardRefExoticComponent, RefAttributes, type ReactNode } from 'react';
1
+ import { SwitchRootProps } from '@ark-ui/react';
2
+ import { SwitchRecipeVariantProps } from '@stokelp/styled-system/recipes';
3
+ import { Assign, JsxStyleProps } from '@stokelp/styled-system/types';
4
+ import { ReactNode, ForwardRefExoticComponent, RefAttributes } from 'react';
5
+
5
6
  export interface SwitchProps extends Assign<JsxStyleProps, SwitchRootProps>, SwitchRecipeVariantProps {
6
7
  children?: ReactNode;
7
8
  }
@@ -1,8 +1,9 @@
1
- import { TabsRecipe } from '@stokelp/styled-system/recipes';
2
- import { StyledComponent } from '@stokelp/styled-system/jsx';
3
- import { ComponentVariants } from '../../utils/slots.tsx';
4
1
  import { Tabs as ArkTab } from '@ark-ui/react';
5
- import { ForwardRefExoticComponent, RefAttributes, ComponentProps } from 'react';
2
+ import { ComponentProps, ForwardRefExoticComponent, RefAttributes } from 'react';
3
+ import { ComponentVariants } from '../../utils/slots.tsx';
4
+ import { StyledComponent } from '@stokelp/styled-system/jsx';
5
+ import { TabsRecipe } from '@stokelp/styled-system/recipes';
6
+
6
7
  export declare const Tabs: ComponentVariants<StyledComponent<ForwardRefExoticComponent<ArkTab.RootProps & RefAttributes<HTMLDivElement>>, {}>, TabsRecipe>;
7
8
  export declare const TabsContent: StyledComponent<ForwardRefExoticComponent<ArkTab.ContentProps & RefAttributes<HTMLDivElement>>, {}>;
8
9
  export declare const TabsTrigger: StyledComponent<ForwardRefExoticComponent<ArkTab.TriggerProps & RefAttributes<HTMLButtonElement>>, {}>;
@@ -1,7 +1,8 @@
1
- import { type HTMLArkProps } from '@ark-ui/react';
2
- import { type TagVariantProps } from '@stokelp/styled-system/recipes';
1
+ import { HTMLArkProps } from '@ark-ui/react';
2
+ import { TagVariantProps } from '@stokelp/styled-system/recipes';
3
3
  import { Assign, JsxStyleProps } from '@stokelp/styled-system/types';
4
- import { ForwardRefExoticComponent, RefAttributes, type ReactNode } from 'react';
4
+ import { ReactNode, ForwardRefExoticComponent, RefAttributes } from 'react';
5
+
5
6
  export interface TagProps extends Assign<JsxStyleProps, HTMLArkProps<'div'>>, TagVariantProps {
6
7
  children: ReactNode;
7
8
  }
@@ -1,9 +1,9 @@
1
- import { JSX } from 'react/jsx-runtime';
2
- import { type TextVariantProps } from '@stokelp/styled-system/recipes';
3
- import { type HTMLStyledProps } from '@stokelp/styled-system/types';
1
+ import { TextVariantProps } from '@stokelp/styled-system/recipes';
2
+ import { HTMLStyledProps } from '@stokelp/styled-system/types';
3
+
4
4
  type As = 'p' | 'span' | 'div' | 'label' | 'pre';
5
5
  export type TextProps = {
6
6
  as?: As;
7
7
  } & TextVariantProps & HTMLStyledProps<As>;
8
- export declare const Text: (props: TextProps) => JSX.Element;
8
+ export declare const Text: (props: TextProps) => import("react/jsx-runtime").JSX.Element;
9
9
  export {};
@@ -1,10 +1,10 @@
1
- import { TextareaVariantProps } from '@stokelp/styled-system/recipes';
1
+ import { ComponentProps, ForwardRefExoticComponent, DetailedHTMLProps, TextareaHTMLAttributes, DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES, RefObject } from 'react';
2
2
  import { StyledComponent } from '@stokelp/styled-system/jsx';
3
- import { ForwardRefExoticComponent, DetailedHTMLProps, TextareaHTMLAttributes, RefObject, ComponentProps } from 'react';
4
- export declare const Textarea: StyledComponent<ForwardRefExoticComponent<Omit<DetailedHTMLProps<TextareaHTMLAttributes<HTMLTextAreaElement>, HTMLTextAreaElement>, "ref"> & {
5
- ref?: ((instance: HTMLTextAreaElement | null) => void) | RefObject<HTMLTextAreaElement> | null | undefined;
6
- } & {
7
- asChild?: boolean | undefined;
8
- }>, TextareaVariantProps>;
3
+ import { PolymorphicProps } from '@ark-ui/react';
4
+ import { TextareaVariantProps } from '@stokelp/styled-system/recipes';
5
+
6
+ export declare const Textarea: StyledComponent<ForwardRefExoticComponent<Omit< DetailedHTMLProps<TextareaHTMLAttributes<HTMLTextAreaElement>, HTMLTextAreaElement>, "ref"> & {
7
+ ref?: ((instance: HTMLTextAreaElement | null) => void | DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | RefObject<HTMLTextAreaElement> | null | undefined;
8
+ } & PolymorphicProps>, TextareaVariantProps>;
9
9
  export interface TextareaProps extends ComponentProps<typeof Textarea> {
10
10
  }
package/dist/index.d.ts CHANGED
@@ -1,2 +1,3 @@
1
+
1
2
  export * from './components';
2
3
  export { preset } from './preset';
@@ -1,4 +1,5 @@
1
- import type { FC, ReactNode } from 'react';
1
+ import { FC, ReactNode } from 'react';
2
+
2
3
  export interface ConditionalWrapperProps {
3
4
  readonly when: boolean;
4
5
  readonly children: ReactNode;