1- # tailwindcss-bg-patterns (IN-DEVELOPMENT)
1+ # @ yet3/ tailwindcss-bg-patterns
22
33![ GitHub license] ( https://img.shields.io/github/license/yet3/tailwindcss-bg-patterns?style=flat )
44<a href =' https://www.npmjs.com/package/@yet3/tailwindcss-bg-patterns ' >
@@ -15,12 +15,20 @@ See a [live demo](https://yet3.github.io/tailwindcss-bg-patterns/)
1515
1616- [ Installation] ( #installation )
1717- [ Config] ( #config )
18- - [ Usage] ( #usage )
18+ - [ Example usage] ( #grid )
19+ - [ Patterns] ( #patterns )
20+ - [ Grid] ( #grid )
21+ - [ Hatching] ( #hatching )
22+ - [ Cross-Hatching] ( #cross-hatching )
23+ - [ Polka dot] ( #polka-dot )
24+ - [ Hexagonal Polka dot] ( #hexagonal-polka-dot )
25+ - [ Todo] ( #support )
26+ - [ Support] ( #support )
1927
2028## Installation
2129
2230``` sh
23- npm install -D @yet3/tailwindcss-bg-patterns
31+ npm install --save-dev @yet3/tailwindcss-bg-patterns
2432```
2533
2634``` sh
@@ -57,30 +65,84 @@ export default {
5765};
5866```
5967
60- ## Usage
68+ ## Example usage
6169
70+ ``` html
71+ <div
72+ class =" bg-blue-500 bg-pattern-grid bg-pattern-line-0.5 bg-pattern-spacing-32"
73+ />
6274```
63- bg-pattern-grid
6475
65- bg-pattern-hatching
66- bg-pattern-hatching-left-to-right
67- bg- pattern-hatching-right-to-left
76+ this code will result in:
77+
78+ < img src = " ./public/grid.png " alt = " Grid pattern" height = " 200 " />
6879
69- bg-pattern-cross-hatching
80+ ## Patterns
7081
71- bg-pattern-line-2 // line width
72- bg-pattern-line-[8] // custom line width
73- bg-pattern-line-red-500 // line color
74- bg-pattern-line-[#a2a2a2] // custom line color
82+ ### Grid
83+ See it live [ here] ( https://yet3.github.io/tailwindcss-bg-patterns#grid )
7584
76- bg-pattern-spacing-24 // space between pattern lines
77- bg-pattern-spacing-[321] // custom space between pattern lines
85+ ``` html
86+ <div
87+ class =" bg-blue-500 bg-pattern-grid bg-pattern-line-0.5 bg-pattern-spacing-32"
88+ />
7889```
7990
8091<img src =" ./public/grid.png " alt =" Grid pattern " height =" 200 " />
8192
93+ ### Hatching
94+ See it live [ here] ( https://yet3.github.io/tailwindcss-bg-patterns#hatching )
95+
8296``` html
8397<div
84- class =" bg-blue-500 bg-pattern-grid bg-pattern-line-2 bg-pattern-line-white bg-pattern-spacing-32 "
98+ class =" bg-blue-500 bg-pattern-hatching bg-pattern-line-0.5 bg-pattern-spacing-16 bg-pattern-hatching-left-to-right "
8599/>
86100```
101+
102+ <img src =" ./public/hatching.png " alt =" Hatching pattern " height =" 200 " />
103+
104+ ### Cross-Hatching
105+ See it live [ here] ( https://yet3.github.io/tailwindcss-bg-patterns#cross-hatching )
106+
107+ ``` html
108+ <div
109+ class =" bg-blue-500 bg-pattern-cross-hatching bg-pattern-line-0.5 bg-pattern-spacing-16"
110+ />
111+ ```
112+
113+ <img src =" ./public/cross-hatching.png " alt =" Cross-Hatching pattern " height =" 200 " />
114+
115+ ### Polka dot
116+ See it live [ here] ( https://yet3.github.io/tailwindcss-bg-patterns#polka-dot )
117+
118+ ``` html
119+ <div
120+ class =" bg-blue-500 bg-pattern-polka-dot bg-pattern-dot-white bg-pattern-dot-8 bg-pattern-spacing-16"
121+ />
122+ ```
123+
124+ <img src =" ./public/polka-dot.png " alt =" Polka dot pattern " height =" 200 " />
125+
126+ ### Hexagonal polka dot
127+ See it live [ here] ( https://yet3.github.io/tailwindcss-bg-patterns#hexagonal-polka-dot )
128+
129+ ``` html
130+ <div
131+ class =" bg-blue-500 bg-pattern-hex-polka-dot bg-pattern-dot-white bg-pattern-dot-8 bg-pattern-spacing-16"
132+ />
133+ ```
134+
135+ <img src =" ./public/hex-polka-dot.png " alt =" Polka dot pattern " height =" 200 " />
136+
137+ ## Todo
138+
139+ - [ ] Add utility to adjust pattern opacity
140+ - [ ] Add pattern: horizontal-lines (x-lines?)
141+ - [ ] Add pattern: vertical-lines (y-lines?)
142+ - [ ] Add pattern: checkers
143+ - [ ] Add pattern: honeycomb
144+ - [ ] Add pattern: bricks
145+
146+ ## Support
147+
148+ [ ![ ko-fi] ( https://ko-fi.com/img/githubbutton_sm.svg )] ( https://ko-fi.com/W7W618YWH4 )
0 commit comments