Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • B bootstrap
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 263
    • Issues 263
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 114
    • Merge requests 114
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Bootstrap
  • bootstrap
  • Merge requests
  • !30380

Grid: switch to margin approach and CSS variables

  • Review changes

  • Download
  • Email patches
  • Plain diff
Closed Administrator requested to merge master-mc-grid-custom-properties-margins into main Mar 11, 2020
  • Overview 0
  • Commits 6
  • Pipelines 0
  • Changes 7

Created by: MartijnCuppens

In draft, do not review yet

  • Switch from paddings to left margin
    • This way the .container or .overflow-hidden are not needed as row wrappers anymore
    • Cards can be direct children of a .row
  • Remove the widths from columns:
    • seperation between columns and width utilities
  • Store gutter widths in variables
    • Works a little more flexible than the universal selector technique we had
  • Enabled vertical gutters by default

Examples:

  • Cards without wrapping divs: https://deploy-preview-30380--twbs-bootstrap.netlify.com//docs/4.3/components/card/#grid-cards
  • Grid without wrapping container: https://deploy-preview-30380--twbs-bootstrap.netlify.com//docs/4.3/layout/grid/
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: master-mc-grid-custom-properties-margins