import type { JSX, ValidComponent } from "@solidjs/web"; import { dynamic } from "@solidjs/web"; import { omit } from "solid-js"; import { composeRefs, userRef } from "../../internals/compose-refs"; import { mergeRootProps } from "../../internals/merge-root-props"; import type { NativeButtonProps } from "../../internals/types"; import { useButton } from "../../internals/use-button/use-button"; import { useCollapsible } from "../create-collapsible.tsx"; /** * Props for {@link CollapsibleTrigger}. * * Stage-01c rewire: this wrapper is now a structural adapter over * `useCollapsible()` (axes A + G + P). `render={}` is gone — use `as=` * to swap the underlying tag/component. */ export interface CollapsibleTriggerProps extends JSX.ButtonHTMLAttributes, NativeButtonProps { /** * Tag/component to render. Defaults to `"button"`. Replaces the * pre-spike `render` prop (axis G). */ as?: ValidComponent; /** * Whether the trigger is disabled. Falls back to the collapsible's own * disabled state when not specified. */ disabled?: boolean | undefined; } /** * A button that opens and closes the collapsible panel. Renders a `