According to its documentation, you have to customize your own css class to achieve the style you want via modal's prop dialogClassName.

So we might have my.jsx code below:

<Modal dialogClassName="my-modal">
</Modal>

With my.css below:

.my-modal {
    width: 90vw    /* Occupy the 90% of the screen width */
    max-width: 90vw;
} 

Then you will have your custmized modal!

Answer from Qi W. on Stack Overflow
🌐
React Bootstrap
react-bootstrap.netlify.app › modals
Modals | React Bootstrap
You can specify a Bootstrap large or small modal by using the size prop.
🌐
MDBootstrap
mdbootstrap.com › standard › modal size
React Bootstrap 5 Modal Size - free examples & tutorial
import React, { useState } from 'react'; import { MDBBtn, MDBModal, MDBModalDialog, MDBModalContent, MDBModalHeader, MDBModalTitle, MDBModalBody, MDBModalFooter, } from 'mdb-react-ui-kit'; export default function App() { const [fullscreenXlModal, setFullscreenXlModal] = useState(false); const toggleShow = () => setFullscreenXlModal(!fullscreenXlModal); return ( <> <MDBBtn onClick={toggleShow}>Full screen below xl</MDBBtn> <MDBModal tabIndex='-1' show={fullscreenXlModal} setShow={setFullscreenXlModal}> <MDBModalDialog size='fullscreen-xl-down'> <MDBModalContent> <MDBModalHeader> <MDBModalTitle>
🌐
GitHub
github.com › react-bootstrap › react-bootstrap › issues › 3794
How to set the width of Modal · Issue #3794 · react-bootstrap/react-bootstrap
February 8, 2019 - Hello, I can't change the width of my Modal. I already read all the issues about this problem but nothing worked. I followed this link : React Bootstrap. I use dialogClassName in my react compo...
Published   May 15, 2019
Author   mathiz11
🌐
Trimble
modus-react-bootstrap.trimble.com › components › modals
Modals | Trimble Modus React Bootstrap Developer Guide
You can specify a bootstrap large or small modal by using the "size" prop.These sizes kick in at certain breakpoints to avoid horizontal scrollbars on narrower viewports. import Modal from `@trimbleinc/modus-react-bootstrap/Modal`
🌐
GitHub
github.com › react-bootstrap › react-bootstrap › issues › 1643
Set Modal custom size? · Issue #1643 · react-bootstrap/react-bootstrap
September 3, 2015 - I need to create a bootstrap modal, but with a custom size, for instance "xl". How can I do it??? Thanks
Author   rulyotano
🌐
DEV Community
dev.to › itz_giddy › the-right-way-to-resize-reactstrap-s-modal-component-302o
The right way to resize Reactstrap's Modal component. - DEV Community
February 12, 2020 - In this case you may give preference to your css item by adding !important in your css item as below: .custom-modal-style { width: 600px !important; height: 802px !important; } ... HY! thanks for this amazing editorial.
🌐
Web Developer
webdeveloper.com › bounties › how-to-set-the-size-of-a-modal-in-react
how to set the size of a modal in react
However, the general idea is to define the width and height of the modal element using CSS. For example, if you are using the React Bootstrap package for your modal, you can set the size by passing the size prop to the Modal component.
🌐
Bootstrap
getbootstrap.com › docs › 5.0 › components › modal
Modal · Bootstrap v5.0
Embedding YouTube videos in modals requires additional JavaScript not in Bootstrap to automatically stop playback and more. See this helpful Stack Overflow post for more information. Modals have three optional sizes, available via modifier classes to be placed on a .modal-dialog.
Find elsewhere
🌐
Netlify
react-bootstrap-v3.netlify.app › components › modal
Netlify
You can specify a bootstrap large or small modal by using the "bsSize" prop. ... class MySmallModal extends React.Component { render() { return ( <Modal {...this.props} bsSize="small" aria-labelledby="contained-modal-title-sm" > <Modal.Header closeButton> <Modal.Title id="contained-modal-t...
🌐
X
smartdevpreneur.com › the-complete-guide-to-react-bootstrap-modal-width-and-height
The Complete Guide to React-Bootstrap Modal Width and ...
JavaScript is not available · We’ve detected that JavaScript is disabled in this browser. Please enable JavaScript or switch to a supported browser to continue using x.com. You can see a list of supported browsers in our Help Center · Help Center · Terms of Service Privacy Policy Cookie ...
🌐
GitHub
github.com › react-bootstrap › react-bootstrap › issues › 2285
How to set the width of the element : Modal · Issue #2285 · react-bootstrap/react-bootstrap
August 27, 2016 - react-bootstrap / react-bootstrap Public · Notifications · You must be signed in to change notification settings · Fork 3.6k · Star 22.6k · New issueCopy link · New issueCopy link · Closed · Closed · How to set the width of the element : Modal#2285 ·
Author   captainwooder
🌐
Pluralsight
pluralsight.com › blog › guides
Working with Bootstrap's Modals in React | Online Courses, Learning Paths, and Certifications - Pluralsight
Modals are very common in front-end applications. React-bootstrap has rebuilt the jQuery-based modal with React components that provide the same functionality as the jQuery counter-parts. In this guide I will show you how to install react-bootstrap, show and hide a modal, work with different ...
🌐
MDBootstrap
mdbootstrap.com › standard › modal
React Modal with Bootstrap - free examples & tutorial
Embedding YouTube videos in modals requires additional JavaScript not in Bootstrap to automatically stop playback and more. See this helpful Stack Overflow post for more information. Modals have three optional sizes, available via modifier props to be placed on a MDBModalDialog. These sizes kick in at certain breakpoints to avoid horizontal scrollbars on narrower viewports. ... import React, { useState } from 'react'; import { MDBBtn, MDBModal, MDBModalDialog, MDBModalContent, MDBModalHeader, MDBModalTitle, MDBModalBody } from 'mdb-react-ui-kit'; export default function App() { const [optSmMod
🌐
GeeksforGeeks
geeksforgeeks.org › reactjs › react-suite-modal-size
React Suite Modal Size - GeeksforGeeks
June 27, 2022 - ... import "rsuite/dist/rsuite... <h4 style={{ color: "green" }}>React Suite Modal Sizes</h4> <div style={{ marginTop: 20, width: 340 }}> <Button onClick={handleOpen}>Open</Button> <Modal open={open} onClose={handleClose} size="xs" ...
🌐
GitHub
github.com › mdbootstrap › react-modal-size
GitHub - mdbootstrap/react-modal-size: Responsive React popup window sizing with Bootstrap 5. Modal width, modal height, fullscreen modal, large modal with lg & xl modal classes and more. https://mdbootstrap.com/docs/react/extended/modal-size
Responsive React popup window sizing with Bootstrap 5. Modal width, modal height, fullscreen modal, large modal with lg & xl modal classes and more. Check out React Modal Size Documentation for detailed instructions & even more examples.
Author   mdbootstrap
Top answer
1 of 5
7

Yes, it's documented on their website but you can only change the base class the subcomponent such as Modal.header, Modal.footer doesn't add custom classes so you may have to face some difficulties to do it with CSS code, here is my modal code,

     <Modal
      {...this.props}
      show={this.state.show}
      onHide={this.hideModal}
      dialogClassName="custom-modal"
      bsClass="my-modal"
    >

With below CSS code I was able to make the bootstrap code full screen

@media (min-width: 992px)
.my-modal-lg {
    width: auto;
}

@media (min-width: 768px)
.my-modal-dialog {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
 }

@media (min-width: 768px)
.my-modal-content {
    box-shadow: 0 5px 15px rgba(0,0,0,.5);
    height: auto;
    min-height: 100%;
    border-radius: 0;
}

To get more control of your modal data, form, text i would suggest to have a look at the following GitHub react-bootstrap-modal repo

https://github.com/jquense/react-bootstrap-modal

and if you want to try anything except bootstrap modal, then you can also have a look at the react-modal by visiting below url,

https://github.com/reactjs/react-modal

2 of 5
3

EDIT: Thanks to Aravind Reddy for pointing out that the fullscreen prop is only available in v5.

According to this documentation https://react-bootstrap.github.io/components/modal/ you can include a size of 'sm' | 'lg' | 'xl' as a prop for Modal. There is also a fullscreen property that accepts 'true' |'sm-down' | 'md-down' | 'lg-down' | 'xl-down' | 'xxl-down'.

Example of using size

  const [smShow, setSmShow] = useState(false);
  const [lgShow, setLgShow] = useState(false);

  return (
    <>
      <Button onClick={() => setSmShow(true)}>Small modal</Button>{' '}
      <Button onClick={() => setLgShow(true)}>Large modal</Button>
      <Modal
        size="sm"
        show={smShow}
        onHide={() => setSmShow(false)}
        aria-labelledby="example-modal-sizes-title-sm"
      >
        <Modal.Header closeButton>
          <Modal.Title id="example-modal-sizes-title-sm">
            Small Modal
          </Modal.Title>
        </Modal.Header>
        <Modal.Body>...</Modal.Body>
      </Modal>
      <Modal
        size="lg"
        show={lgShow}
        onHide={() => setLgShow(false)}
        aria-labelledby="example-modal-sizes-title-lg"
      >
        <Modal.Header closeButton>
          <Modal.Title id="example-modal-sizes-title-lg">
            Large Modal
          </Modal.Title>
        </Modal.Header>
        <Modal.Body>...</Modal.Body>
      </Modal>
    </>
  );
}

render(<Example />);

And the example of fullscreen

  const values = [true, 'sm-down', 'md-down', 'lg-down', 'xl-down', 'xxl-down'];
  const [fullscreen, setFullscreen] = useState(true);
  const [show, setShow] = useState(false);

  function handleShow(breakpoint) {
    setFullscreen(breakpoint);
    setShow(true);
  }

  return (
    <>
      {values.map((v, idx) => (
        <Button key={idx} className="me-2" onClick={() => handleShow(v)}>
          Full screen
          {typeof v === 'string' && `below ${v.split('-')[0]}`}
        </Button>
      ))}
      <Modal show={show} fullscreen={fullscreen} onHide={() => setShow(false)}>
        <Modal.Header closeButton>
          <Modal.Title>Modal</Modal.Title>
        </Modal.Header>
        <Modal.Body>Modal body content</Modal.Body>
      </Modal>
    </>
  );
}

render(<Example />);
🌐
GeeksforGeeks
geeksforgeeks.org › reactjs › react-bootstrap-modal-component
React-Bootstrap Modal Component - GeeksforGeeks
March 7, 2024 - import React from 'react'; import 'bootstrap/dist/css/bootstrap.css'; import Modal from 'react-bootstrap/Modal'; import Button from 'react-bootstrap/Button'; export default function App() { return ( <div style={{ display: 'block', width: 700, ...