J4 Issue ?
avatar 911truthoutreach
911truthoutreach
29 Jan 2019

Is your feature request related to a problem? Please describe.

Describe the solution you'd like

Additional context

avatar 911truthoutreach 911truthoutreach - open - 29 Jan 2019
avatar joomla-cms-bot joomla-cms-bot - change - 29 Jan 2019
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 29 Jan 2019
avatar joomla-cms-bot joomla-cms-bot - change - 30 Jan 2019
Status New Closed
Closed_Date 0000-00-00 00:00:00 2019-01-30 00:00:43
Closed_By joomla-cms-bot
avatar joomla-cms-bot joomla-cms-bot - close - 30 Jan 2019
avatar Quy Quy - change - 30 Jan 2019
Closed_Date 2019-01-30 00:00:43 2019-01-30 00:00:45
Closed_By joomla-cms-bot Quy
avatar 911truthoutreach
911truthoutreach - comment - 30 Jan 2019

I have been experimenting with CSS Grids and have actually used CSS Grids in the old Joomla Protostar template, and I have to say, I love CSS Grids. I read an article by one to the Mozilla developers who says that we can just change the Bootstrap class attributes to CSS Grid attributes and after reading that, I think we should replace the Bootstrap CSS with CSS Grids equivalents, or make Joomla 4.0 CSS Grics first with a fall back to Bootstrap 4.0

I would like to see Joomla 4.0 wholeheartedly embrace CSS Grids as I don't want to have to make these same replacements for Bootstrap 4 classes.

I have talked to component develops, however, who say that rep[lacing Bootstrap with CSS Grids, even if done in a cleaver way, may introduce some issues.

I took the foillowing from Dan Browne at Mozilla who suggested that we can replace the Bootstrap classes with CSS Grids See: Replace Bootstrap Layouts with CSS Grid]

/**** Bootstrap ****/

.container-fluid {
  margin-left: auto;
  margin-right: auto;
  margin-top: -3px;
  padding-left: 0;
  padding-right: 0;
}

.row-fluid {
  width: 100%;
  *zoom: 1;
}
.row-fluid:before,
.row-fluid:after {
  display: table;
  content: "";
  line-height: 0;
}
.row-fluid:after {
  clear: both;
}
.row-fluid [class*="span"] {
  display: block;
  width: 100%;
  min-height: 28px;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  float: left;
  margin-left: 1.127659574%;
  *margin-left: 1.0744680846383%;
}

 .row-fluid .span12 {
    width: 99.99999999%;
    *width: 99.946808500638%;
  }
  .row-fluid .span11 {
    width: 91.489361693%;
    *width: 91.436170203638%;
  }
  .row-fluid .span10 {
    width: 82.978723396%;
    *width: 82.925531906638%;
  }
…

.row-fluid .offset12 {
  margin-left: 104.255319138%;
  *margin-left: 104.14893615928%;
}
.row-fluid .offset12:first-child {
  margin-left: 102.127659564%;
  *margin-left: 102.02127658528%;
}
.row-fluid .offset11 {
  margin-left: 95.744680841%;
  *margin-left: 95.638297862277%;
}
.row-fluid .offset11:first-child {
  margin-left: 93.617021267%;
  *margin-left: 93.510638288277%;
}
.row-fluid .offset10 {
  margin-left: 87.234042544%;
  *margin-left: 87.127659565277%;
}
.row-fluid .offset10:first-child {
  margin-left: 85.10638297%;
  *margin-left: 84.999999991277%;
}
…

/**** CSS Grids ****/

.container-fluid {
  margin-left: auto;
  margin-right: auto;
  margin-top: auto;
  padding-left: 0;
  padding-right: 0;
}

.row-fluid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-gap: 20px;
 }

.row-fluid:before,
.row-fluid:after {
  display: none;
}
.row-fluid:after {
  clear: none;
}
.row-fluid [class*="span"] {
  display: inline-flex;
  grid-column: span12;
  min-height: 28px;
  box-sizing: border-box;
}

.row-fluid .span12 {
  grid-column: span12;
}

.row-fluid .span11 {
  grid-column: span11;
}

.row-fluid .span10 {
  grid-column: span10;
}
…

.row-fluid .offset12 {
  grid-area: 1 / 12 / 1 / 12; /* This would place all content in the 12th column. */
}

.row-fluid .offset12:first-child {
  grid-area: 1 / 12 / 1 / 12; /* This would place all content in the 12th column. */
}

.row-fluid .offset11 {
  grid-area: 1 / 11 / 1 / 12; /* This would place all content in columns 11 - 12. */
}

.row-fluid .offset11:first-child {
  grid-area: 1 / 11 / 1 / 12; /* This would place all content in columns 11 - 12. */
}

.row-fluid .offset10 {
  grid-area: 1 / 10 / 1 / 12;  /* This would place all content in columns 10 - 12. */
}

.row-fluid .offset10:first-child {
  grid-area: 1 / 10 / 1 / 12; /* This would place all content in columns 10 - 12. */
}

Thanks, Tim Michel tmichel@webdevtim.com

avatar Quy Quy - change - 30 Jan 2019
Status Closed Pending
Closed_Date 2019-01-30 00:00:45
Closed_By Quy
avatar joomla-cms-bot joomla-cms-bot - change - 30 Jan 2019
Status Pending New
Closed_Date 0000-00-00 00:00:00
avatar joomla-cms-bot joomla-cms-bot - reopen - 30 Jan 2019
avatar joomla-cms-bot
joomla-cms-bot - comment - 30 Jan 2019

Set to "open" on behalf of @Quy by The JTracker Application at issues.joomla.org/joomla-cms/23715

avatar joomla-cms-bot joomla-cms-bot - edited - 3 Mar 2019
avatar franz-wohlkoenig franz-wohlkoenig - change - 3 Mar 2019
Title
Joomla 4.0 & CSS Grids
[4.0] & CSS Grids
Status New Discussion
avatar franz-wohlkoenig franz-wohlkoenig - change - 28 Mar 2019
Category Feature Request
avatar franz-wohlkoenig franz-wohlkoenig - change - 4 Apr 2019
Labels Added: J4 Issue
avatar franz-wohlkoenig franz-wohlkoenig - labeled - 4 Apr 2019
avatar jwaisner jwaisner - change - 24 Mar 2020
Priority Medium Low
Status Discussion New
Build master 4.0-dev
avatar Quy
Quy - comment - 27 Jan 2021

@wilsonge Move to Discussions?

avatar wilsonge wilsonge - close - 27 Jan 2021
avatar wilsonge
wilsonge - comment - 27 Jan 2021

No I’m just going to close this one. We’re using grid in several key places like the article blog layout and backend dashboard but we have no intention for now to expand that and replace bootstraps grid

avatar wilsonge wilsonge - change - 27 Jan 2021
Status New Closed
Closed_Date 0000-00-00 00:00:00 2021-01-27 00:30:04
Closed_By wilsonge

Add a Comment

Login with GitHub to post a comment