Skip to content

Commit ef93cb2

Browse files
Initial commit
0 parents  commit ef93cb2

File tree

60 files changed

+467
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+467
-0
lines changed

.gitignore

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#OS junk files
2+
[Tt]humbs.db
3+
*.DS_Store

LICENSE.md

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
Copyright © 2017 Alex Clapperton
2+
3+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4+
5+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
6+
7+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

README.md

+96
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,96 @@
1+
# CSS Grid Layout Snippets
2+
3+
[![apm](https://img.shields.io/apm/v/css-grid-snippets.svg?style=flat-square)](https://atom.io/packages/css-grid-snippets)
4+
[![apm](https://img.shields.io/apm/dm/css-grid-snippets.svg?style=flat-square)](https://atom.io/packages/css-grid-snippets)
5+
[![apm](https://img.shields.io/apm/l/css-grid-snippets.svg?style=flat-square)](https://atom.io/packages/css-grid-snippets)
6+
7+
###### An Atom Package - [Atom.io](https://atom.io/packages/css-grid-snippets) : [GitHub](https://github.com/pushedskydiver/atom-css-grid-snippets)
8+
9+
Shorthand [snippets](https://atom.io/packages/snippets) for CSS, SCSS, Sass, and Less.
10+
11+
## Preview
12+
![CSS grid snippets in atom](https://s10.postimg.org/lp7ivhwop/css_grid_snippets.gif)
13+
14+
## What is CSS Grid Layout?
15+
To put it simply CSS Grid Layout (aka "Grid"), is a two-dimensional grid-based layout system that aims to do nothing less than completely change the way we design grid-based user interfaces. It hasn't been added yet to modern browsers but is expected to be added within the coming months.
16+
17+
### What's Included?
18+
You can see the list of the CSS grid snippets in the tables below. I have organized the tables into grid container and grid item snippets. Alternatively, once you install the package you can view the snippets in the Settings View. Basically, it's snippets like `dg` for ```display: grid;``` and `gg` for ```grid-gap: 20px;```.
19+
20+
### Grid Container Snippets
21+
22+
| Property | Snippet |
23+
| :-------------------------------- | :------------ |
24+
| align-content | ac |
25+
| align-content: center; | acc |
26+
| align-content: end; | ace |
27+
| align-content: start; | acs |
28+
| align-content: space-around; | acsa |
29+
| align-content: space-between; | acsb |
30+
| align-content: space-evenly; | acse |
31+
| align-items | ai |
32+
| align-items: center; | aic |
33+
| align-items: end; | aie |
34+
| align-items: start; | ais |
35+
| align-items: stretch; | aistr |
36+
| display: inline-grid; | disig |
37+
| display: grid; | disg |
38+
| display: subgrid; | dissg |
39+
| grid-auto-columns | gac |
40+
| grid-auto-rows | gar |
41+
| grid-auto-flow | gaf |
42+
| grid-auto-flow: column; | gafc |
43+
| grid-auto-flow: dense; | gafd |
44+
| grid-auto-flow: row; | gafr |
45+
| grid-column-gap | gcg |
46+
| grid-gap | gg |
47+
| grid-row-gap | grg |
48+
| grid-template-areas | gta |
49+
| grid-template-columns | gtc |
50+
| grid-template-rows | gtr |
51+
| justify-content | jc |
52+
| justify-content: center; | jcc |
53+
| justify-content: end; | jce |
54+
| justify-content: start; | jcs |
55+
| justify-content: space-around; | jcsa |
56+
| justify-content: space-between; | jcsb |
57+
| justify-items | ji |
58+
| justify-items: center; | jic |
59+
| justify-items: end; | jie |
60+
| justify-items: start; | jis |
61+
| justify-items: stretch; | jistr |
62+
63+
### Grid Item Snippets
64+
65+
| Property | Snippet |
66+
| --------------------------------- | ------------- |
67+
| align-self | als |
68+
| align-self: center; | alsc |
69+
| align-self: end; | alse |
70+
| align-self: start; | alss |
71+
| align-self: stretch; | alsstr |
72+
| grid-area | gra |
73+
| grid-column | gc |
74+
| grid-column-end | gce |
75+
| grid-column-start | gcs |
76+
| grid-row | gr |
77+
| grid-row-start | grs |
78+
| grid-row-end | gre |
79+
| justify-self | js |
80+
| justify-self: center; | jsc |
81+
| justify-self: end; | jse |
82+
| justify-self: start; | jss |
83+
| justify-self: stretch; | jsstr |
84+
85+
### Want To Learn CSS Grid?
86+
If you are new or have never heard of CSS Grid before, then now is the time to learn, with browsers ready to start shipping it very soon.
87+
88+
For more information about grid and how to learn it, checkout out [gridbyexample.com](http://gridbyexample.com "Grid By Example homepage"), created by [Rachel Andrew](https://rachelandrew.co.uk "Rachel Andrew's website") who has been at the forefront of grid layout research.
89+
90+
### Grid Layout Learning Resources
91+
* [gridbyexample.com](http://gridbyexample.com "Grid By Example homepage")
92+
* [css-tricks.com](https://css-tricks.com/snippets/css/complete-guide-grid/ "A Complete Guide to Grid")
93+
* [sitepoint.com](https://www.sitepoint.com/introducing-the-css-grid-layout/ "Introducing the CSS Grid Layout")
94+
95+
### Notes
96+
Issues and Pull Requests are welcome.

package.json

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"name": "css-grid-snippets",
3+
"version": "1.0.0",
4+
"description": "CSS Grid Layout Snippets",
5+
"keywords": [
6+
"snippets",
7+
"css",
8+
"css grid",
9+
"scss",
10+
"grid"
11+
],
12+
"dependencies": {},
13+
"repository": {
14+
"type": "git",
15+
"url": "https://github.com/Pushedskydiver/sublime-text-css-grid-snippets"
16+
},
17+
"bugs": {
18+
"url": "https://github.com/Pushedskydiver/sublime-text-css-grid-snippets/issues"
19+
},
20+
"homepage": "https://github.com/Pushedskydiver/sublime-text-css-grid-snippets",
21+
"license": "MIT"
22+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-cotntent: center;]]></content>
3+
<tabTrigger>acc</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align content center property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-cotntent: end;]]></content>
3+
<tabTrigger>ace</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align content end property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-cotntent: space-around;]]></content>
3+
<tabTrigger>acsa</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align content space around property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-cotntent: space-between;]]></content>
3+
<tabTrigger>acsb</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align content space between property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-cotntent: space-evenly;]]></content>
3+
<tabTrigger>acse</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align content space evenly property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-cotntent: start;]]></content>
3+
<tabTrigger>acs</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align content start property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-cotntent: stretch;]]></content>
3+
<tabTrigger>acstr</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align content stretch property</description>
6+
</snippet>
+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-cotntent: ${1:center};]]></content>
3+
<tabTrigger>ac</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align content property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-items: center;]]></content>
3+
<tabTrigger>aic</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align items property</description>
6+
</snippet>
+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-items: end;]]></content>
3+
<tabTrigger>aie</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align items end property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-items: start;]]></content>
3+
<tabTrigger>ais</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align items start property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-items: stretch;]]></content>
3+
<tabTrigger>aistr</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align items stretch property</description>
6+
</snippet>

snippets/align-items.sublime-snippet

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-items: ${1:center};]]></content>
3+
<tabTrigger>ai</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align items property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-self: center;]]></content>
3+
<tabTrigger>alsc</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align self center property</description>
6+
</snippet>
+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-self: end;]]></content>
3+
<tabTrigger>alse</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align self end property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-self: start;]]></content>
3+
<tabTrigger>alss</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align self start property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-self: stretch;]]></content>
3+
<tabTrigger>alsstr</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align self stretch property</description>
6+
</snippet>

snippets/align-self.sublime-snippet

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[align-self: ${1:center};]]></content>
3+
<tabTrigger>als</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>align self property</description>
6+
</snippet>

snippets/display-grid.sublime-snippet

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[display: grid;]]></content>
3+
<tabTrigger>disg</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>display grid property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[display: inline-grid;]]></content>
3+
<tabTrigger>disig</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>display inline-grid property</description>
6+
</snippet>
+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[display: subgrid;]]></content>
3+
<tabTrigger>dissg</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>display subgrid property</description>
6+
</snippet>

snippets/grid-area.sublime-snippet

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[grid-area: ${1:<name>};]]></content>
3+
<tabTrigger>gra</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>grid area property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[grid-auto-columns: ${1:50px};]]></content>
3+
<tabTrigger>gac</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>grid auto columns property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[grid-auto-flow: column;]]></content>
3+
<tabTrigger>gafc</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>grid auto flow column property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[grid-auto-flow: dense;]]></content>
3+
<tabTrigger>gafd</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>grid auto flow dense property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[grid-auto-flow: row;]]></content>
3+
<tabTrigger>gafr</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>grid auto flow row property</description>
6+
</snippet>
+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[grid-auto-flow: ${1:dense};]]></content>
3+
<tabTrigger>gaf</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>grid auto flow property</description>
6+
</snippet>
+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[grid-auto-rows: ${1:50px};]]></content>
3+
<tabTrigger>gar</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>grid auto rows property</description>
6+
</snippet>
+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[grid-column-end: ${1:2}};]]></content>
3+
<tabTrigger>gce</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>grid column end property</description>
6+
</snippet>
+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[grid-column-gap: ${1:20px};]]></content>
3+
<tabTrigger>gcg</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>grid column gap property</description>
6+
</snippet>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[grid-column-start: ${1:1}};]]></content>
3+
<tabTrigger>gcs</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>grid column start property</description>
6+
</snippet>

snippets/grid-column.sublime-snippet

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[grid-column: ${1:1} / ${1:2};]]></content>
3+
<tabTrigger>gc</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>grid column start and end property</description>
6+
</snippet>

snippets/grid-gap.sublime-snippet

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<snippet>
2+
<content><![CDATA[grid-gap: ${1:20px};]]></content>
3+
<tabTrigger>gg</tabTrigger>
4+
<scope>source.css, source.sass, source.scss, source.less</scope>
5+
<description>grid gap property</description>
6+
</snippet>

0 commit comments

Comments
 (0)