Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for Responsive Containers (Bootstrap 4.4) #4884

Closed
davidjb opened this issue Dec 10, 2019 · 2 comments
Closed

Support for Responsive Containers (Bootstrap 4.4) #4884

davidjb opened this issue Dec 10, 2019 · 2 comments

Comments

@davidjb
Copy link
Contributor

davidjb commented Dec 10, 2019

Is your feature request related to a problem? Please describe

Bootstrap 4.4 added responsive containers (https://getbootstrap.com/docs/4.4/layout/overview/#responsive), with the syntax .container-{breakpoint}.

Describe the solution you'd like

Add support for setting a breakpoint prop on Container components, which then sets the resultant className.

Describe alternatives you've considered

A workaround is to use <div className="container-lg"> and manually create the container.

Using <Container className="container-lg"> isn't suitable as a solution given how the classes operate (eg it has no effect)

Additional context

@davidjb davidjb changed the title Responsive Containers (Bootstrap 4.4) Support for Responsive Containers (Bootstrap 4.4) Dec 10, 2019
@taion
Copy link
Member

taion commented Dec 10, 2019

We'd be happy to take a PR for this!

taion added a commit that referenced this issue Jan 15, 2020
* Update Container.js

Add breakpoint prop, set accepted values for prop, add use of prop as suffix if fluid is false

* Add types and update test

Add types to Container.js and update ContainerSpec.js to include test

* Rename breakpoint prop to size, include fluid in size

Renam brkPoints to sizes, include fluid as valid input, rename breakpoint prop to size

update test to include fluid on size prop, rename breakpoint to size

* Update Container.js

Remove size prop and add the size settings to the fluid prop instead.

Updated types and code.

* Update ContainerSpec.js

Updated container test to reflect changes.

* Updated docs for <Container />

Added <Container /> with fluid settings to docs.

* Update src/Container.js

Co-Authored-By: Jimmy Jia <tesrin@gmail.com>

* Update src/Container.js

Co-Authored-By: Jimmy Jia <tesrin@gmail.com>

* Update Container.js

fix prettier error

Co-authored-by: Jimmy Jia <tesrin@gmail.com>
@kosmiq
Copy link
Collaborator

kosmiq commented Jan 20, 2020

@taion this can be closed since the PR has been merged.

@jquense jquense closed this as completed Jan 20, 2020
adamayres added a commit to lithiumtech/react-bootstrap that referenced this issue Feb 5, 2020
* master: (54 commits)
  docs: Add Glyphicon removal to "Migrating to v1" doc (react-bootstrap#4967)
  chore(deps): update all non-major dependencies (react-bootstrap#4964)
  docs: fixed typos (react-bootstrap#4957)
  refactor(OverlayTrigger): convert to function component (react-bootstrap#4938)
  Add missing horizontal in ListGroupProps (react-bootstrap#4864)
  chore(deps): update all non-major dependencies (react-bootstrap#4953)
  chore(deps): update dependency cross-env to v7 (react-bootstrap#4949)
  Label large dropdown as large in playground (react-bootstrap#4945)
  Fix typographical errors in Button docs (react-bootstrap#4943)
  docs: fix dropdown typos (react-bootstrap#4944)
  docs: Fix component spacing in examples (react-bootstrap#4914)
  chore(deps): update all non-major dependencies (react-bootstrap#4941)
  chore(deps): update dependency lint-staged to v10 (react-bootstrap#4942)
  react-bootstrap#4884 add responsive containers (react-bootstrap#4902)
  feat: add size prop for FormLabel component - Fixes react-bootstrap#4886 (react-bootstrap#4893)
  tests: added for Modal and OverlayTrigger (react-bootstrap#4931)
  test: increase test coverage with minor refactor (react-bootstrap#4922)
  chore(deps): update all non-major dependencies (react-bootstrap#4929)
  docs: fix element type used for Breadcrumb (react-bootstrap#4926)
  chore(deps): update dependency husky to v4 (react-bootstrap#4923)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants