(text: MarkDown)
| 243 | } |
| 244 | } |
| 245 | class DateInput extends TextInput { |
| 246 | dateValue: Date | null; |
| 247 | constructor( |
| 248 | label: string, |
| 249 | onSubmit: (str: string) => void, |
| 250 | owner: Options, |
| 251 | {initText = "" as string | Date} = {}, |
| 252 | ) { |
| 253 | let initDate: DateInput["dateValue"] = null; |
| 254 | if (initText instanceof Date) { |
| 255 | initDate = initText; |
| 256 | initText = ""; |
| 257 | } |
| 258 | super(label, onSubmit, owner, {initText}); |