Skip to content

Instantly share code, notes, and snippets.

@AndrewGardhouse
Created October 30, 2019 17:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AndrewGardhouse/08ec9e86169005b2f804de085874e214 to your computer and use it in GitHub Desktop.
Save AndrewGardhouse/08ec9e86169005b2f804de085874e214 to your computer and use it in GitHub Desktop.
CSS Grid Chrome to IE
.example {
    display: grid; 
    grid-template-rows: auto auto auto auto auto; 
    grid-template-columns: 3fr 2fr; 
    grid-template-areas: 
        "title notes_title" 
        "policy_information notes_editor" 
        "loss_info_form notes_editor" 
        "policy_search policy_search" 
        "policy_search_information policy_search_information"; 
    grid-gap: 1em 2em;
}

.search-title {
    grid-area: title;
}

.notes-title {
    grid-area: notes_title;
}


.notes-editor {
    grid-area: notes_editor;
}

.policy-info {
    grid-area: policy_information;
}

.loss-info-form {
    grid-area: loss_info_form;
}

.policy-search {
    grid-area: policy_search;
}

Converted to this:

.example {
    display: -ms-grid;
    display: grid; 
    -ms-grid-rows: auto 1em auto 1em auto 1em auto 1em auto; 
    grid-template-rows: auto auto auto auto auto; 
    -ms-grid-columns: 3fr 2em 2fr; 
    grid-template-columns: 3fr 2fr; 
    grid-template-areas: 
         "title notes_title" 
         "policy_information notes_editor" 
         "loss_info_form notes_editor" 
         "policy_search policy_search" 
         "policy_search_information policy_search_information"; 
    grid-gap: 1em 2em;
}

.search-title {
    -ms-grid-row: 1;
    -ms-grid-column: 1;
    grid-area: title;
}

.notes-title {
    -ms-grid-row: 1;
    -ms-grid-column: 3;
    grid-area: notes_title;
}


.notes-editor {
    -ms-grid-row: 3;
    -ms-grid-row-span: 3;
    -ms-grid-column: 3;
    grid-area: notes_editor;
}

.policy-info {
    -ms-grid-row: 3;
    -ms-grid-column: 1;
    grid-area: policy_information;
}

.loss-info-form {
    -ms-grid-row: 5;
    -ms-grid-column: 1;
    grid-area: loss_info_form;
}

.policy-search {
    -ms-grid-row: 7;
    -ms-grid-column: 1;
    -ms-grid-column-span: 3;
    grid-area: policy_search;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment