Add PostCSS text align utilities
This commit is contained in:
parent
4251aa60de
commit
1d9c36816f
5 changed files with 93 additions and 7 deletions
|
|
@ -3,12 +3,6 @@
|
|||
|
||||
.define-text-hover-colors(@text-colors; @screens);
|
||||
|
||||
// Horizontal alignment
|
||||
.text-center { text-align: center; }
|
||||
.text-left { text-align: left; }
|
||||
.text-right { text-align: right; }
|
||||
.text-justify { text-align: justify; }
|
||||
|
||||
// Vertical alignment
|
||||
.align-baseline { vertical-align: baseline; }
|
||||
.align-top { vertical-align: top; }
|
||||
|
|
|
|||
10
src/generators/textAlign.js
Normal file
10
src/generators/textAlign.js
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
import defineClasses from '../util/defineClasses'
|
||||
|
||||
export default function() {
|
||||
return defineClasses({
|
||||
'text-left': { 'text-align': 'left' },
|
||||
'text-center': { 'text-align': 'center' },
|
||||
'text-right': { 'text-align': 'right' },
|
||||
'text-justify': { 'text-align': 'justify' },
|
||||
})
|
||||
}
|
||||
|
|
@ -6,6 +6,7 @@ import textFonts from '../generators/textFonts'
|
|||
import textColors from '../generators/textColors'
|
||||
import textLeading from '../generators/textLeading'
|
||||
import textTracking from '../generators/textTracking'
|
||||
import textAlign from '../generators/textAlign'
|
||||
import backgroundColors from '../generators/backgroundColors'
|
||||
import backgroundSize from '../generators/backgroundSize'
|
||||
import borderWidths from '../generators/borderWidths'
|
||||
|
|
@ -30,6 +31,7 @@ export default function(options) {
|
|||
textColors(options),
|
||||
textLeading(options),
|
||||
textTracking(options),
|
||||
textAlign(options),
|
||||
backgroundColors(options),
|
||||
backgroundSize(options),
|
||||
borderWidths(options),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue