@aivex/ui 1.1.0-dev.13 → 1.1.0-dev.14

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,21 +1,15 @@
1
- import { type VariantProps } from "class-variance-authority";
2
- import { type ButtonHTMLAttributes, type HTMLAttributes, type ReactNode, type Ref } from "react";
3
- declare const segmentedRootVariants: (props?: ({
4
- size?: "sm" | "md" | "lg" | null | undefined;
5
- } & import("class-variance-authority/types").ClassProp) | undefined) => string;
6
- export interface SegmentedRootProps extends Omit<HTMLAttributes<HTMLDivElement>, "onChange">, VariantProps<typeof segmentedRootVariants> {
7
- value?: string;
8
- defaultValue?: string;
9
- onChange?: (value: string) => void;
1
+ import type { ToggleGroupItemProps, ToggleGroupSingleProps } from "@radix-ui/react-toggle-group";
2
+ import { type ReactNode, type RefAttributes } from "react";
3
+ type SegmentedSize = "sm" | "md" | "lg";
4
+ export interface SegmentedRootProps extends Omit<ToggleGroupSingleProps, "onValueChange" | "type">, RefAttributes<HTMLDivElement> {
5
+ size?: SegmentedSize;
6
+ onValueChange?: (value: string) => void;
10
7
  iconOnly?: boolean;
11
8
  children?: ReactNode;
12
- ref?: Ref<HTMLDivElement>;
13
9
  }
14
- declare function SegmentedRoot({ className, size, value, defaultValue, onChange, iconOnly, children, ref, ...props }: SegmentedRootProps): import("react/jsx-runtime").JSX.Element;
15
- export interface SegmentedItemProps extends ButtonHTMLAttributes<HTMLButtonElement> {
16
- value: string;
10
+ declare function SegmentedRoot({ className, size, value, defaultValue, onValueChange, iconOnly, children, ref, ...props }: SegmentedRootProps): import("react/jsx-runtime").JSX.Element;
11
+ export interface SegmentedItemProps extends ToggleGroupItemProps, RefAttributes<HTMLButtonElement> {
17
12
  children?: ReactNode;
18
- ref?: Ref<HTMLButtonElement>;
19
13
  }
20
- declare function SegmentedItem({ className, value, children, onClick, ref, ...props }: SegmentedItemProps): import("react/jsx-runtime").JSX.Element;
14
+ declare function SegmentedItem({ className, children, ref, ...props }: SegmentedItemProps): import("react/jsx-runtime").JSX.Element;
21
15
  export { SegmentedItem, SegmentedRoot };
@@ -1,18 +1,19 @@
1
- import { type VariantProps } from "class-variance-authority";
2
- import { type ButtonHTMLAttributes, type HTMLAttributes, type Ref } from "react";
3
- export interface TabRootProps extends Omit<HTMLAttributes<HTMLDivElement>, "onChange"> {
4
- value?: string;
5
- defaultValue?: string;
6
- onChange?: (value: string) => void;
7
- ref?: Ref<HTMLDivElement>;
1
+ import * as TabsPrimitive from "@radix-ui/react-tabs";
2
+ import type { ComponentPropsWithoutRef, ComponentRef, Ref } from "react";
3
+ export interface TabRootProps extends ComponentPropsWithoutRef<typeof TabsPrimitive.Root> {
4
+ ref?: Ref<ComponentRef<typeof TabsPrimitive.Root>>;
8
5
  }
9
- declare function TabRoot({ className, value, defaultValue, onChange, children, ref, ...props }: TabRootProps): import("react/jsx-runtime").JSX.Element;
10
- declare const tabItemVariants: (props?: ({
11
- active?: boolean | null | undefined;
12
- } & import("class-variance-authority/types").ClassProp) | undefined) => string;
13
- export interface TabItemProps extends ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof tabItemVariants> {
14
- value: string;
15
- ref?: Ref<HTMLButtonElement>;
6
+ declare function TabRoot({ className, ref, ...props }: TabRootProps): import("react/jsx-runtime").JSX.Element;
7
+ export interface TabListProps extends ComponentPropsWithoutRef<typeof TabsPrimitive.List> {
8
+ ref?: Ref<ComponentRef<typeof TabsPrimitive.List>>;
16
9
  }
17
- declare function TabItem({ className, value, children, active: activeProp, ref, ...props }: TabItemProps): import("react/jsx-runtime").JSX.Element;
18
- export { TabItem, TabRoot, tabItemVariants };
10
+ declare function TabList({ className, ref, ...props }: TabListProps): import("react/jsx-runtime").JSX.Element;
11
+ export interface TabTriggerProps extends ComponentPropsWithoutRef<typeof TabsPrimitive.Trigger> {
12
+ ref?: Ref<ComponentRef<typeof TabsPrimitive.Trigger>>;
13
+ }
14
+ declare function TabTrigger({ className, ref, ...props }: TabTriggerProps): import("react/jsx-runtime").JSX.Element;
15
+ export interface TabContentProps extends ComponentPropsWithoutRef<typeof TabsPrimitive.Content> {
16
+ ref?: Ref<ComponentRef<typeof TabsPrimitive.Content>>;
17
+ }
18
+ declare function TabContent({ className, ref, ...props }: TabContentProps): import("react/jsx-runtime").JSX.Element;
19
+ export { TabContent, TabList, TabRoot, TabTrigger };
@@ -1,2 +1,2 @@
1
- export type { TabItemProps, TabRootProps } from "./Tab";
2
- export { TabItem, TabRoot, tabItemVariants } from "./Tab";
1
+ export type { TabContentProps, TabListProps, TabRootProps, TabTriggerProps, } from "./Tab";
2
+ export { TabContent, TabList, TabRoot, TabTrigger } from "./Tab";