import { BoxrecDateEvent } from "../boxrec-pages/date/boxrec.date.event" ; import { BoxrecPageEvent } from "../boxrec-pages/event/boxrec.page.event" ; param classType constructor export function EventsBoutsGetter ( classType ) { return target => { Object . defineProperty ( target . prototype , "events" , { get < T > ( ) { const el = this . $ ( ".calendarTable:nth-child(1) thead:nth-child(2)" ) ; const headers = `<thead>${ el . html ( ) }</thead>` ; return this . parse ( headers ) . map ( ( event ) => new classType ( event ) ) ; } , } ) ; } ; } export interface EventsBoutsInterface { readonly events : BoxrecPageEvent [ ] | BoxrecDateEvent [ ] ; }