UNPKG

1.57 kBTypeScriptView Raw
1import * as React from "react";
2import { AbstractPureComponent2 } from "../../common";
3import { IntentProps, Props } from "../../common/props";
4export declare type FormGroupProps = IFormGroupProps;
5/** @deprecated use FormGroupProps */
6export interface IFormGroupProps extends IntentProps, Props {
7 /**
8 * A space-delimited list of class names to pass along to the
9 * `Classes.FORM_CONTENT` element that contains `children`.
10 */
11 contentClassName?: string;
12 /**
13 * Whether form group should appear as non-interactive.
14 * Remember that `input` elements must be disabled separately.
15 */
16 disabled?: boolean;
17 /**
18 * Optional helper text. The given content will be wrapped in
19 * `Classes.FORM_HELPER_TEXT` and displayed beneath `children`.
20 * Helper text color is determined by the `intent`.
21 */
22 helperText?: React.ReactNode;
23 /** Whether to render the label and children on a single line. */
24 inline?: boolean;
25 /** Label of this form group. */
26 label?: React.ReactNode;
27 /**
28 * `id` attribute of the labelable form element that this `FormGroup` controls,
29 * used as `<label for>` attribute.
30 */
31 labelFor?: string;
32 /**
33 * Optional secondary text that appears after the label.
34 */
35 labelInfo?: React.ReactNode;
36 /** CSS properties to apply to the root element. */
37 style?: React.CSSProperties;
38}
39export declare class FormGroup extends AbstractPureComponent2<FormGroupProps> {
40 static displayName: string;
41 render(): JSX.Element;
42 private getClassName;
43}