import * as t from 'io-ts' ; import { NonEmptyString } from '@kbn/securitysolution-io-ts-types' ; import { id } from '../id' ; export const updateComment = t . intersection ( [ t . exact ( t . type ( { comment : NonEmptyString , } ) ) , t . exact ( t . partial ( { id , } ) ) , ] ) ; export type UpdateComment = t . TypeOf < typeof updateComment > ; export const updateCommentsArray = t . array ( updateComment ) ; export type UpdateCommentsArray = t . TypeOf < typeof updateCommentsArray > ; export const updateCommentsArrayOrUndefined = t . union ( [ updateCommentsArray , t . undefined ] ) ; export type UpdateCommentsArrayOrUndefined = t . TypeOf < typeof updateCommentsArrayOrUndefined > ;