UNPKG

@yamada-ui/react

Version:

React UI components of the Yamada, by the Yamada, for the Yamada built with React and Emotion

74 lines (70 loc) 1.97 kB
"use client"; import { utils_exports } from "../../utils/index.js"; import { styled } from "../../core/system/factory.js"; import { Icon } from "../icon/icon.js"; import { initialProps, superProps, withContext } from "./loading.js"; import { jsx, jsxs } from "react/jsx-runtime"; //#region src/components/loading/puff.tsx /** * `Loading` is a component displayed during waiting times, such as when data is being loaded. * * @see https://yamada-ui.com/docs/components/feedback/loading */ const Puff = withContext(({ dur = "1.8s",...rest }) => { dur = (0, utils_exports.isString)(dur) ? parseFloat(dur) : dur; return /* @__PURE__ */ jsx(Icon, { stroke: "currentColor", viewBox: "0 0 44 44", ...rest, children: /* @__PURE__ */ jsxs("g", { fill: "none", fillRule: "evenodd", strokeWidth: "2", children: [/* @__PURE__ */ jsx(styled.circle, { animationDuration: `${dur}s`, animationIterationCount: "infinite", animationTimingFunction: "cubic-bezier(0.3, 0.61, 0.355, 1)", cx: "22px", cy: "22px", r: "1px", transformBox: "fill-box", transformOrigin: "center", vectorEffect: "non-scaling-stroke", _keyframes: { "0%": { strokeOpacity: 1, transform: "scale(1)" }, "100%": { strokeOpacity: 0, transform: "scale(20)" } } }), /* @__PURE__ */ jsx(styled.circle, { animationDelay: "-0.9s", animationDuration: `${dur}s`, animationIterationCount: "infinite", animationTimingFunction: "cubic-bezier(0.3, 0.61, 0.355, 1)", cx: "22px", cy: "22px", r: "1px", transformBox: "fill-box", transformOrigin: "center", vectorEffect: "non-scaling-stroke", _keyframes: { "0%": { strokeOpacity: 1, transform: "scale(1)" }, "100%": { strokeOpacity: 0, transform: "scale(20)" } } })] }) }); })(initialProps, superProps); //#endregion export { Puff }; //# sourceMappingURL=puff.js.map