import * as t from 'io-ts' ; import { NonEmptyString } from '@kbn/securitysolution-io-ts-types' ; import { created_at } from '../created_at' ; import { created_by } from '../created_by' ; import { id } from '../id' ; import { updated_at } from '../updated_at' ; import { updated_by } from '../updated_by' ; export const comment = t . intersection ( [ t . exact ( t . type ( { comment : NonEmptyString , created_at , created_by , id , } ) ) , t . exact ( t . partial ( { updated_at , updated_by , } ) ) , ] ) ; export const commentsArray = t . array ( comment ) ; export type CommentsArray = t . TypeOf < typeof commentsArray > ; export type Comment = t . TypeOf < typeof comment > ; export const commentsArrayOrUndefined = t . union ( [ commentsArray , t . undefined ] ) ; export type CommentsArrayOrUndefined = t . TypeOf < typeof commentsArrayOrUndefined > ;