@yamada-ui/react
Version:
React UI components of the Yamada, by the Yamada, for the Yamada built with React and Emotion
68 lines (67 loc) • 1.88 kB
TypeScript
import { KeyframeIdent, ThemeProps } from "../../core/system/index.types.js";
import { Component } from "../../core/components/index.types.js";
import "../../core/index.js";
import { AiryStyle } from "./airy.style.js";
import { HTMLMotionProps } from "../motion/index.types.js";
import "../../index.js";
import * as react65 from "react";
import { ReactNode } from "react";
//#region src/components/airy/airy.d.ts
interface AiryProps extends Omit<HTMLMotionProps<"button">, "onChange">, ThemeProps<AiryStyle> {
/**
* Passing React elements to "from" is required.
*/
from: ReactNode;
/**
* Passing React elements to "to" is required.
*/
to: ReactNode;
/**
* You can set the initial state.
*
* @default 'from'
*/
defaultValue?: KeyframeIdent;
/**
* The animation delay.
*
* @default 0
*/
delay?: number;
/**
* If `true`, the component is disabled.
*
* @default false
*/
disabled?: boolean;
/**
* The animation duration.
*
* @default 0.2
*/
duration?: number;
/**
* If `true`, the component is readonly.
*
* @default false
*/
readOnly?: boolean;
/**
* Use this when you want to control the animation from outside the component.
*/
value?: KeyframeIdent;
/**
* This is a callback function that is called when the animation state changes.
*/
onChange?: (value: KeyframeIdent) => void;
}
declare const AiryPropsContext: react65.Context<Partial<AiryProps> | undefined>, useAiryPropsContext: () => Partial<AiryProps> | undefined;
/**
* `Airy` is a component that creates an airy animation, switching between two elements when one is clicked.
*
* @see https://yamada-ui.com/docs/components/airy
*/
declare const Airy: Component<"button", AiryProps>;
//#endregion
export { Airy, AiryProps, AiryPropsContext, useAiryPropsContext };
//# sourceMappingURL=airy.d.ts.map