diff --git a/README.md b/README.md index bf115e98..56704a8c 100644 --- a/README.md +++ b/README.md @@ -77,7 +77,8 @@ export default { |**priceDecimals**|`Number`|`0`|The price decimals for weekly periods (see `periodDates`). |**priceSymbol**|`String`|`''`|The price symbol added before the price when `showPrice` is true and a `price` has been set in one of the `periodDates` array items (period). |**showPrice**|`Boolean`|`false`|If set to true, displays a price contains on your `periodDates`. -|**showSingleMonth**|`Boolean`|`false`|If set to true, display one month only +|**showSingleMonth**|`Boolean`|`false`|If set to true, display one month only. +|**showWeekNumbers**|`Boolean`|`false`|If set to true, displays the week numbers. |**showYear**|`Boolean`|`true`|Shows the year next to the month. |**singleDaySelection**|`Boolean`|`false`|When true only one day can be selected instead of a range. |**startDate**|`[Date, String]`|`new Date()`|The start view date. All the dates before this date will be disabled. diff --git a/package.json b/package.json index dc95b4b3..e079ed03 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vue-hotel-datepicker", - "version": "4.5.1", + "version": "4.6.0", "description": "A responsive date range picker for Vue.js that displays the number of nights selected and allow several useful options like custom check-in/check-out rules, localization support and more", "author": "krystalcampioni ", "main": "dist/vueHotelDatepicker.common.js", diff --git a/src/App.vue b/src/App.vue index a7dd10cf..b57dc036 100644 --- a/src/App.vue +++ b/src/App.vue @@ -64,6 +64,7 @@ singleDaySelection
showYear
yearBeforeMonth
+ showWeekNumbers
startingDateValue: @@ -90,6 +91,7 @@ :showSingleMonth="showSingleMonth" :showYear="showYear" :showPrice="showPrice" + :showWeekNumbers="showWeekNumbers" :priceSymbol="priceSymbol" :yearBeforeMonth="yearBeforeMonth" :positionRight="positionRight" @@ -403,6 +405,7 @@ export default { showLastDateAvailable: false, showPeriodDates: false, showStartingDate: false, + showWeekNumbers: false, startingDate: `${today.getFullYear()}-${month}-${today.getDate()}`, showEndingDate: false, endingDate: `${today.getFullYear()}-${month}-${today.getDate()}`, diff --git a/src/DatePicker/HotelDatePicker.vue b/src/DatePicker/HotelDatePicker.vue index 3565244d..b00abcd4 100644 --- a/src/DatePicker/HotelDatePicker.vue +++ b/src/DatePicker/HotelDatePicker.vue @@ -135,6 +135,7 @@ :screenSize="screenSize" :showCustomTooltip="showCustomTooltip" :showPrice="showPrice" + :showWeekNumbers="showWeekNumbers" :disabledDates="disabledDates" :periodDates="periodDates" :sortedDisabledDates="sortedDisabledDates" @@ -335,6 +336,10 @@ export default { type: Boolean, default: true, }, + showWeekNumbers: { + type: Boolean, + default: false, + }, singleDaySelection: { type: Boolean, default: false, diff --git a/src/DatePicker/components/Month.vue b/src/DatePicker/components/Month.vue index 6dedfbab..cbdc3161 100644 --- a/src/DatePicker/components/Month.vue +++ b/src/DatePicker/components/Month.vue @@ -1,9 +1,23 @@