Last
Some checks are pending
Deploy Volleyball CMS / deploy (push) Waiting to run

This commit is contained in:
2025-06-02 18:56:22 +02:00
parent 8f62885a45
commit 33181acf83
1443 changed files with 286102 additions and 12 deletions

View File

@@ -0,0 +1,23 @@
import { type ElementType, type Ref } from 'react';
import type { Props } from '../../types.js';
import { type HasDisplayName, type RefProp } from '../../utils/render.js';
declare let DEFAULT_TEXTAREA_TAG: "textarea";
type TextareaRenderPropArg = {
disabled: boolean;
hover: boolean;
focus: boolean;
autofocus: boolean;
invalid: boolean;
};
type TextareaPropsWeControl = 'aria-labelledby' | 'aria-describedby';
export type TextareaProps<TTag extends ElementType = typeof DEFAULT_TEXTAREA_TAG> = Props<TTag, TextareaRenderPropArg, TextareaPropsWeControl, {
disabled?: boolean;
invalid?: boolean;
autoFocus?: boolean;
}>;
declare function TextareaFn<TTag extends ElementType = typeof DEFAULT_TEXTAREA_TAG>(props: TextareaProps<TTag>, ref: Ref<HTMLElement>): import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>> | null;
export interface _internal_ComponentTextarea extends HasDisplayName {
<TTag extends ElementType = typeof DEFAULT_TEXTAREA_TAG>(props: TextareaProps<TTag> & RefProp<typeof TextareaFn>): React.JSX.Element;
}
export declare let Textarea: _internal_ComponentTextarea;
export {};

View File

@@ -0,0 +1 @@
"use client";import{useFocusRing as A}from"@react-aria/focus";import{useHover as c}from"@react-aria/interactions";import{useMemo as E}from"react";import{useId as P}from'../../hooks/use-id.js';import{useDisabled as R}from'../../internal/disabled.js';import{useProvidedId as g}from'../../internal/id.js';import{forwardRefWithAs as v,mergeProps as _,useRender as D}from'../../utils/render.js';import{useDescribedBy as F}from'../description/description.js';import{useLabelledBy as h}from'../label/label.js';let L="textarea";function H(s,l){let i=P(),d=g(),n=R(),{id:p=d||`headlessui-textarea-${i}`,disabled:e=n||!1,autoFocus:r=!1,invalid:a=!1,...T}=s,f=h(),m=F(),{isFocused:o,focusProps:u}=A({autoFocus:r}),{isHovered:t,hoverProps:b}=c({isDisabled:e}),y=_({ref:l,id:p,"aria-labelledby":f,"aria-describedby":m,"aria-invalid":a?"true":void 0,disabled:e||void 0,autoFocus:r},u,b),x=E(()=>({disabled:e,invalid:a,hover:t,focus:o,autofocus:r}),[e,a,t,o,r]);return D()({ourProps:y,theirProps:T,slot:x,defaultTag:L,name:"Textarea"})}let J=v(H);export{J as Textarea};