diff --git a/demo/pages/lang/main.ts b/demo/pages/lang/main.ts index 0d7400f..0f77ee2 100644 --- a/demo/pages/lang/main.ts +++ b/demo/pages/lang/main.ts @@ -6,7 +6,7 @@ const options: Options = { type: 'multiple', selectionDatesMode: 'multiple-ranged', disableDatesGaps: true, - // disableDatesPast: true, + disableDatesPast: true, dateMin: '2021-02-01', dateMax: '2025-11-30', displayDatesOutside: false, @@ -65,12 +65,11 @@ const options: Options = { }; document.addEventListener('DOMContentLoaded', () => { - const calendar = new Calendar('#calendar', options); + const calendar = new Calendar('#calendar'); calendar.init(); - // const btnSetEl = document.querySelector('#set-options'); - // btnSetEl?.addEventListener('click', () => { - // calendar.set(options, { dates: false }); - // console.log(calendar); - // }); + const btnSetEl = document.querySelector('#set-options'); + btnSetEl?.addEventListener('click', () => { + calendar.set(options, { dates: false }); + }); });