-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ee61eec
commit d29554c
Showing
22 changed files
with
170 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1 @@ | ||
declare module '*.module.css' | ||
declare module '*.module.scss' |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import plugin from 'tailwindcss/plugin' | ||
|
||
import { spacings } from '../variables' | ||
|
||
export const directional = plugin(({ addUtilities }) => { | ||
const directions: Record<string, any> = {} | ||
Object.entries(spacings).forEach(([key, value]) => { | ||
const size = `${value}` | ||
directions[`.t-${key}`] = { top: size } | ||
directions[`.b-${key}`] = { bottom: size } | ||
directions[`.l-${key}`] = { left: size } | ||
directions[`.r-${key}`] = { right: size } | ||
directions[`.y-${key}`] = { top: size, bottom: size } | ||
directions[`.x-${key}`] = { left: size, right: size } | ||
}) | ||
addUtilities(directions) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import plugin from 'tailwindcss/plugin' | ||
|
||
import { fontSizes } from '../variables' | ||
|
||
export const fontSize = plugin(({ addUtilities }) => { | ||
const fs: Record<string, { fontSize: string }> = {} | ||
Object.entries(fontSizes).forEach(([key, value]) => { | ||
fs[`.fs-${key}`] = { fontSize: `${value}` } | ||
}) | ||
addUtilities(fs) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import plugin from 'tailwindcss/plugin' | ||
|
||
import { fontWeights } from '../variables' | ||
|
||
export const fontWeight = plugin(({ addUtilities }) => { | ||
const fw: Record<string, { fontWeight: string }> = {} | ||
Object.entries(fontWeights).forEach(([key, value]) => { | ||
fw[`.fs-${key}`] = { fontWeight: `${value}` } | ||
}) | ||
addUtilities(fw) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,13 @@ | ||
import plugin from 'tailwindcss/plugin' | ||
|
||
import { spacing } from '../variables' | ||
import { spacings } from '../variables' | ||
|
||
export const gap = plugin(({ addUtilities }) => { | ||
const gaps: Record<string, { gap: string }> = {} | ||
Object.entries(spacing).forEach(([key, value]) => { | ||
const gaps: Record<string, any> = {} | ||
Object.entries(spacings).forEach(([key, value]) => { | ||
gaps[`.g-${key}`] = { gap: `${value}` } | ||
gaps[`.gx-${key}`] = { columnGap: `${value}` } | ||
gaps[`.gy-${key}`] = { rowGap: `${value}` } | ||
}) | ||
addUtilities(gaps) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import plugin from 'tailwindcss/plugin' | ||
|
||
import { lineHeights } from '../variables' | ||
|
||
export const lineHeight = plugin(({ addUtilities }) => { | ||
const lh: Record<string, { lineHeight: string }> = {} | ||
Object.entries(lineHeights).forEach(([key, value]) => { | ||
lh[`.lh-${key}`] = { lineHeight: `${value}` } | ||
}) | ||
addUtilities(lh) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import plugin from 'tailwindcss/plugin' | ||
|
||
export const placeContent = plugin(({ addUtilities }) => { | ||
addUtilities({ | ||
'.pc-center': { placeContent: 'center' }, | ||
'.pc-start': { placeContent: 'start' }, | ||
'.pc-end': { placeContent: 'end' }, | ||
'.pc-between': { placeContent: 'space-between' }, | ||
'.pc-around': { placeContent: 'space-around' }, | ||
'.pc-evenly': { placeContent: 'space-evenly' }, | ||
'.pc-baseline': { placeContent: 'baseline' }, | ||
'.pc-stretch': { placeContent: 'stretch' } | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import plugin from 'tailwindcss/plugin' | ||
|
||
export const placeItems = plugin(({ addUtilities }) => { | ||
addUtilities({ | ||
'.pi-start': { placeItems: 'start' }, | ||
'.pi-end': { placeItems: 'end' }, | ||
'.pi-center': { placeItems: 'center' }, | ||
'.pi-baseline': { placeItems: 'baseline' }, | ||
'.pi-stretch': { placeItems: 'stretch' } | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import plugin from 'tailwindcss/plugin' | ||
|
||
export const placeSelf = plugin(({ addUtilities }) => { | ||
addUtilities({ | ||
'.ps-auto': { placeSelf: 'auto' }, | ||
'.ps-start': { placeSelf: 'start' }, | ||
'.ps-end': { placeSelf: 'end' }, | ||
'.ps-center': { placeSelf: 'center' }, | ||
'.ps-stretch': { placeSelf: 'stretch' } | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import plugin from 'tailwindcss/plugin' | ||
|
||
import { spacings } from '../variables' | ||
|
||
export const size = plugin(({ addUtilities }) => { | ||
const sizes: Record<string, any> = {} | ||
Object.entries(spacings).forEach(([key, value]) => { | ||
sizes[`.max-size-${key}`] = { maxWidth: `${value}`, maxHeight: `${value}` } | ||
sizes[`.min-size-${key}`] = { minWidth: `${value}`, minHeight: `${value}` } | ||
sizes[`.square-${key}`] = { | ||
minWidth: `${value}`, | ||
minHeight: `${value}`, | ||
width: `${value}`, | ||
height: `${value}` | ||
} | ||
}) | ||
addUtilities(sizes) | ||
}) |
2 changes: 1 addition & 1 deletion
2
src/theme/variables/boxShadow.ts → src/theme/variables/boxShadows.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/theme/variables/fontSize.ts → src/theme/variables/fontSizes.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
export const fontSize = { | ||
export const fontSizes = { | ||
12: '12px', | ||
14: '14px', | ||
16: '16px', | ||
|
2 changes: 1 addition & 1 deletion
2
src/theme/variables/fontWeight.ts → src/theme/variables/fontWeights.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
export const fontWeight = { | ||
export const fontWeights = { | ||
700: '700', | ||
600: '600', | ||
500: '500' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
export { colors } from './colors' | ||
export { screens } from './screens' | ||
export { spacing } from './spacing' | ||
export { spacings } from './spacings' | ||
export { borderRadius } from './borderRadius' | ||
export { zIndex } from './zIndex' | ||
export { fontWeight } from './fontWeight' | ||
export { boxShadow } from './boxShadow' | ||
export { fontSize } from './fontSize' | ||
export { fontWeights } from './fontWeights' | ||
export { boxShadows } from './boxShadows' | ||
export { fontSizes } from './fontSizes' | ||
export { keyframes } from './keyframes' | ||
export { lineHeights } from './lineHights' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
export const lineHeights = { | ||
100: '1', | ||
110: '1.1', | ||
120: '1.2', | ||
130: '1.3', | ||
140: '1.4', | ||
150: '1.5', | ||
160: '1.6', | ||
170: '1.7', | ||
180: '1.8', | ||
190: '1.9', | ||
200: '2' | ||
} |
2 changes: 1 addition & 1 deletion
2
src/theme/variables/spacing.ts → src/theme/variables/spacings.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
export const spacing = { | ||
export const spacings = { | ||
0: '0px', | ||
1: '1px', | ||
2: '2px', | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,50 +1,50 @@ | ||
import defaultTheme from 'tailwindcss/defaultTheme' | ||
import type { Config } from 'tailwindcss' | ||
|
||
import containerQueries from '@tailwindcss/container-queries' | ||
|
||
import { | ||
colors, | ||
zIndex, | ||
spacing, | ||
fontWeight, | ||
fontSize, | ||
boxShadow, | ||
spacings, | ||
fontWeights, | ||
fontSizes, | ||
boxShadows, | ||
borderRadius, | ||
screens, | ||
keyframes | ||
} from './src/theme/variables' | ||
import { utilities } from './src/theme/utilities' | ||
import { components } from './src/theme/components' | ||
|
||
export default { | ||
const config: Config = { | ||
content: [ | ||
'./src/app/**/*.{js,ts,jsx,tsx}', | ||
'./src/components/**/*.{js,ts,jsx,tsx}' | ||
], | ||
theme: { | ||
screens, | ||
colors, | ||
zIndex, | ||
borderRadius, | ||
fontWeight: fontWeights, | ||
fontSize: fontSizes, | ||
extend: { | ||
width: { ...defaultTheme.width, ...spacing }, | ||
height: { ...defaultTheme.height, ...spacing }, | ||
screens, | ||
spacing: { ...defaultTheme.spacing, ...spacing }, | ||
colors, | ||
borderRadius: { ...defaultTheme.borderRadius, ...borderRadius }, | ||
borderWidth: { ...defaultTheme.borderWidth, ...spacing }, | ||
zIndex: { ...defaultTheme.zIndex, ...zIndex }, | ||
fontWeight: { ...defaultTheme.fontWeight, ...fontWeight }, | ||
boxShadow: { ...defaultTheme.boxShadow, ...boxShadow }, | ||
fontSize, | ||
width: { ...defaultTheme.width, ...spacings }, | ||
height: { ...defaultTheme.height, ...spacings }, | ||
spacing: { ...defaultTheme.spacing, ...spacings }, | ||
borderWidth: { ...defaultTheme.borderWidth, ...spacings }, | ||
boxShadow: { ...defaultTheme.boxShadow, ...boxShadows }, | ||
keyframes: { ...defaultTheme.keyframes, ...keyframes }, | ||
fontFamily: { | ||
sans: 'var(--font-quicksand)' | ||
}, | ||
aspectRatio: { | ||
...defaultTheme.aspectRatio, | ||
'600/317': '600/317', | ||
'10/7': '10/7' | ||
}, | ||
keyframes: { ...defaultTheme.keyframes, ...keyframes } | ||
} | ||
} | ||
}, | ||
plugins: [containerQueries, ...components, ...utilities] | ||
} satisfies Config | ||
plugins: [...components, ...utilities] | ||
} | ||
|
||
export default config |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters