pre-installations and preparations
This commit is contained in:
1 parent
3e5a0329cb
commit
201d621ac3
6977 files changed
+742826
No files matched your search
+23
@@ -0,0 +1,23 @@
|
||||
// @flow
|
||||
import css from './css'
|
||||
|
||||
type Keyframes = {|
|
||||
name: string,
|
||||
styles: string,
|
||||
anim: 1,
|
||||
toString: () => string
|
||||
|} & string
|
||||
|
||||
export const keyframes = (...args: *): Keyframes => {
|
||||
let insertable = css(...args)
|
||||
const name = `animation-${insertable.name}`
|
||||
// $FlowFixMe
|
||||
return {
|
||||
name,
|
||||
styles: `@keyframes ${name}{${insertable.styles}}`,
|
||||
anim: 1,
|
||||
toString() {
|
||||
return `_EMO_${this.name}_${this.styles}_EMO_`
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user