Skip to content
This repository was archived by the owner on Jul 18, 2024. It is now read-only.

Fix test errors and warnings #32

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion calendar/calendar.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</tr>
</thead>
<tbody class="calendar__body" @keydown.left="calendarNav('prev', $event)" @keydown.right="calendarNav('next', $event)" @keydown.up="calendarNav('up', $event)" @keydown.down="calendarNav('down', $event)">
<tr class="calendar__week" v-for="week in calendar.days" @click="select" :key="'week--' + week">
<tr class="calendar__week" v-for="(week, index) in calendar.days" @click="select" :key="'week--' + week + index">
<td :class="day.status ? `calendar__day--${day.status}` : 'calendar__day'" v-for="day in week" :key="day.string">
<!-- Make only "active" or "1" focusable -->
<button :tabindex="day.focusable ? 0 : -1" class="calendar__link" :data-day="day.day" :data-month="day.month" :data-year="day.year" :ref="'calendar'" :aria-label="day.string"><span class="calendar__date">{{ day.dayString }}</span></button>
Expand Down
4 changes: 3 additions & 1 deletion calendar/calendar.js
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,9 @@ export default {
return current.day === this.today.day && current.month === this.today.month && current.year === this.today.year;
},
navigate(dir, e) {
e.preventDefault();
if (e) {
e.preventDefault();
}

const move = {};
if (dir === 'next') {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"homepage": "https://github.com/IBM/vue-a11y-calendar#readme",
"devDependencies": {
"@nuxtjs/markdownit": "^1.1.2",
"@nuxtjs/pwa": "^0.2.1",
"@nuxtjs/pwa": "^2.6.0",
"ava": "^0.22.0",
"babel-eslint": "^8.0.0",
"babel-loader": "^7.1.2",
Expand Down