Week selection can be configured by setting the select to 'preset-range'.
Control the parameters of the selection:
- Define the first day of the selection - Set it in the
firstSelectDayoption. It can be different than thefirstDayof the week set in localization - Define the number of days - The
selectSizeoption can be any number, where3means three days,7means a week and14means two weeks
Looking to select a range with custom start/end dates? See how start/end selection works →
Demo
First day of the selection
Number of weeks
<mbsc-datepicker
[controls]="['calendar']"
select="preset-range"
[firstSelectDay]="1 "
[selectSize]="7 ">
</mbsc-datepicker>
ComponentTemplate
import { CommonModule } from '@angular/common';
import { Component } from '@angular/core';
import { MbscModule, setOptions } from '@mobiscroll/angular';
setOptions({
locale: ,
theme: ' ',
themeVariant: ' '
});
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
standalone: true,
imports: [CommonModule, MbscModule],
})
export class AppComponent {}
<mbsc-datepicker [controls]="['calendar']" display="inline" select="preset-range" [firstSelectDay]="1" [selectSize]="14"></mbsc-datepicker>