Move Body type into shared flux types
parent
27d70504fc
commit
2489aacd99
|
@ -9,7 +9,7 @@ import BodyDelete from 'src/flux/components/BodyDelete'
|
||||||
import {funcNames} from 'src/flux/constants'
|
import {funcNames} from 'src/flux/constants'
|
||||||
|
|
||||||
import {Service} from 'src/types'
|
import {Service} from 'src/types'
|
||||||
import {FlatBody, Suggestion} from 'src/types/flux'
|
import {Body, Suggestion} from 'src/types/flux'
|
||||||
|
|
||||||
interface Props {
|
interface Props {
|
||||||
service: Service
|
service: Service
|
||||||
|
@ -20,10 +20,6 @@ interface Props {
|
||||||
onDeleteBody: (bodyID: string) => void
|
onDeleteBody: (bodyID: string) => void
|
||||||
}
|
}
|
||||||
|
|
||||||
interface Body extends FlatBody {
|
|
||||||
id: string
|
|
||||||
}
|
|
||||||
|
|
||||||
class BodyBuilder extends PureComponent<Props> {
|
class BodyBuilder extends PureComponent<Props> {
|
||||||
public render() {
|
public render() {
|
||||||
const {body, onDeleteBody} = this.props
|
const {body, onDeleteBody} = this.props
|
||||||
|
|
|
@ -106,6 +106,9 @@ export interface FlatBody {
|
||||||
funcs?: Func[]
|
funcs?: Func[]
|
||||||
declarations?: FlatDeclaration[]
|
declarations?: FlatDeclaration[]
|
||||||
}
|
}
|
||||||
|
export interface Body extends FlatBody {
|
||||||
|
id: string
|
||||||
|
}
|
||||||
|
|
||||||
export interface Func {
|
export interface Func {
|
||||||
type: string
|
type: string
|
||||||
|
|
Loading…
Reference in New Issue