Back to all questions

How can I disable all inputs/inputs group inside form?

Last updated

To disable all inputs/inputs group inside form, you can use the Fieldset component. If disabled prop is set, all inputs inside Fieldset are disabled. By default, Fieldset has border and padding styles. If you want to use Fieldset only for disabled feature, set variant="unstyled":

import { Fieldset, TextInput, Button } from '@mantine/core';

function Demo() {
  return (
      <Fieldset disabled variant="unstyled">
        <TextInput label="Your name" placeholder="Your name" />
        <TextInput label="Your email" placeholder="Your email" mt="md" />
        <Button type="submit" mt="md">