mirror of
https://github.com/roleypoly/roleypoly-v1.git
synced 2025-06-17 02:29:10 +00:00
force rename all UI folders to it's alway lowercase
This commit is contained in:
parent
df2a27663b
commit
dc3a65cfc4
26 changed files with 0 additions and 0 deletions
32
ui/kit/media.js
Normal file
32
ui/kit/media.js
Normal file
|
@ -0,0 +1,32 @@
|
|||
// @flow
|
||||
export type MediaQuery = $Shape<{
|
||||
xs: string,
|
||||
sm: string,
|
||||
md: string,
|
||||
lg: string,
|
||||
xl: string
|
||||
}>
|
||||
|
||||
export const breakpoints = {
|
||||
xs: 0,
|
||||
sm: 544,
|
||||
md: 768,
|
||||
lg: 1012,
|
||||
xl: 1280
|
||||
}
|
||||
|
||||
export default (mq: MediaQuery) => {
|
||||
const out = []
|
||||
|
||||
for (const size in mq) {
|
||||
if (breakpoints[size] == null) {
|
||||
continue
|
||||
}
|
||||
|
||||
const inner = mq[size]
|
||||
|
||||
out.push(`@media screen and (min-width: ${breakpoints[size]}px) {\n${inner}\n};`)
|
||||
}
|
||||
|
||||
return out.join('\n')
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue