diff options
author | Joffrey BION <joffrey.bion@gmail.com> | 2019-05-05 20:39:07 +0200 |
---|---|---|
committer | jbion <joffrey.bion@amadeus.com> | 2019-05-06 18:33:15 +0200 |
commit | 43c0a1a90e74074161e092a757882217406575af (patch) | |
tree | bf39fee4dce8b8b0b74cd3fbbe2dc4d545f45fe1 /frontend | |
parent | Migrate lobby components to TypeScript (diff) | |
download | seven-wonders-43c0a1a90e74074161e092a757882217406575af.tar.gz seven-wonders-43c0a1a90e74074161e092a757882217406575af.tar.bz2 seven-wonders-43c0a1a90e74074161e092a757882217406575af.zip |
Add custom types for reflexbox
Diffstat (limited to 'frontend')
-rw-r--r-- | frontend/src/@types/reflexbox.d.ts | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/frontend/src/@types/reflexbox.d.ts b/frontend/src/@types/reflexbox.d.ts new file mode 100644 index 00000000..802bc5f3 --- /dev/null +++ b/frontend/src/@types/reflexbox.d.ts @@ -0,0 +1,37 @@ +declare module 'reflexbox' { + + import { HTMLAttributes } from 'react'; + import * as React from 'react' + + export interface BoxProps { + w?: number | string, + h?: number | string, + + flex?: boolean, + wrap?: boolean, + column?: boolean, + auto?: boolean, + order?: number, + align?: "flex-start" | "flex-end" | "center" | "stretch" | "baseline", + justify?: "flex-start" | "flex-end" | "center" | "space-between" | "space-around" | "space-evenly", + + m?: number | string, + mx?: number | string, + my?: number | string, + mt?: number | string, + mb?: number | string, + ml?: number | string, + mr?: number | string, + + p?: number | string, + px?: number | string, + py?: number | string, + pt?: number | string, + pb?: number | string, + pl?: number | string, + pr?: number | string, + } + + export class Flex extends React.Component<HTMLAttributes & BoxProps> { } + export class Box extends React.Component<HTMLAttributes & BoxProps> { } +} |