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
  • !22376

Simplify grid column styles

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Mark Otto requested to merge simpler-grid into v4-dev Apr 07, 2017
  • Overview 0
  • Commits 2
  • Pipelines 0
  • Changes 1

This PR removes the flex shorthand and max-width on the make-col mixin, reducing it back down to the width alone. This mixins is used to generate our .col classes, so we're removing those styles from all those classes, too. When using the flex shorthand—in particular the flex-basis part—to set the width, we needed to account for IE10+ and Firefox not sizing things properly with duplicate CSS.

Removing these properties for width also gives us the benefit of implicit responsive width utilities. Have something you want 25% wide? Use .col-3. Want that 50% wide at medium and up? Use .col-md-6. This should effectively close #22374.

After this PR ships, we can go back and remove the width and height utility classes as they'll be duplicate.


  • Original PR where max-width was added: #17756.
  • Example of new changes in action: https://output.jsbin.com/wumubid.

/cc @zalog

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: simpler-grid