Blame view

天文台pc/tianwentai-ui/node_modules/@mui/material/esm/Collapse/Collapse.d.ts 3.47 KB
bc518174   王天杨   提交两个项目文件
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
  import * as React from 'react';
  import { SxProps } from '@mui/system';
  import { TransitionStatus } from 'react-transition-group';
  import { Theme } from "../styles/index.js";
  import { InternalStandardProps as StandardProps } from "../internal/index.js";
  import { TransitionProps } from "../transitions/transition.js";
  import { CollapseClasses } from "./collapseClasses.js";
  import { CreateSlotsAndSlotProps, SlotProps } from "../utils/types.js";
  export interface CollapseSlots {
    /**
     * The component that renders the root.
     * @default 'div'
     */
    root?: React.ElementType;
    /**
     * The component that renders the wrapper.
     * @default 'div'
     */
    wrapper?: React.ElementType;
    /**
     * The component that renders the inner wrapper.
     * @default 'div'
     */
    wrapperInner?: React.ElementType;
  }
  export interface CollapseRootSlotPropsOverrides {}
  export interface CollapseWrapperSlotPropsOverrides {}
  export interface CollapseWrapperInnerSlotPropsOverrides {}
  export type CollapseSlotsAndSlotProps = CreateSlotsAndSlotProps<CollapseSlots, {
    root: SlotProps<'div', CollapseRootSlotPropsOverrides, CollapseOwnerState>;
    wrapper: SlotProps<'div', CollapseWrapperSlotPropsOverrides, CollapseOwnerState>;
    wrapperInner: SlotProps<'div', CollapseWrapperInnerSlotPropsOverrides, CollapseOwnerState>;
  }>;
  export interface CollapseProps extends StandardProps<TransitionProps, 'timeout'>, CollapseSlotsAndSlotProps {
    /**
     * The content node to be collapsed.
     */
    children?: React.ReactNode;
    className?: string;
    /**
     * Override or extend the styles applied to the component.
     */
    classes?: Partial<CollapseClasses>;
    /**
     * The width (horizontal) or height (vertical) of the container when collapsed.
     * @default '0px'
     */
    collapsedSize?: string | number;
    /**
     * The component used for the root node.
     * Either a string to use a HTML element or a component.
     */
    component?: React.ElementType<TransitionProps>;
    /**
     * The transition timing function.
     * You may specify a single easing or a object containing enter and exit values.
     */
    easing?: TransitionProps['easing'];
    /**
     * If `true`, the component will transition in.
     */
    in?: boolean;
    /**
     * The transition orientation.
     * @default 'vertical'
     */
    orientation?: 'horizontal' | 'vertical';
    /**
     * The duration for the transition, in milliseconds.
     * You may specify a single timeout for all transitions, or individually with an object.
     *
     * Set to 'auto' to automatically calculate transition time based on height.
     * @default duration.standard
     */
    timeout?: TransitionProps['timeout'] | 'auto';
    /**
     * The system prop that allows defining system overrides as well as additional CSS styles.
     */
    sx?: SxProps<Theme>;
  }
  export interface CollapseOwnerState extends CollapseProps {
    state: TransitionStatus;
  }
  
  /**
   * The Collapse transition is used by the
   * [Vertical Stepper](https://mui.com/material-ui/react-stepper/#vertical-stepper) StepContent component.
   * It uses [react-transition-group](https://github.com/reactjs/react-transition-group) internally.
   *
   * Demos:
   *
   * - [Card](https://mui.com/material-ui/react-card/)
   * - [Lists](https://mui.com/material-ui/react-list/)
   * - [Transitions](https://mui.com/material-ui/transitions/)
   *
   * API:
   *
   * - [Collapse API](https://mui.com/material-ui/api/collapse/)
   * - inherits [Transition API](https://reactcommunity.org/react-transition-group/transition/#Transition-props)
   */
  
  export default function Collapse(props: CollapseProps): React.JSX.Element;