Skip to content

Commit

Permalink
fix: clear btn functionality ffix
Browse files Browse the repository at this point in the history
  • Loading branch information
shubhadip committed Feb 11, 2023
1 parent 4d2fb5c commit 4ca56cb
Show file tree
Hide file tree
Showing 7 changed files with 1,714 additions and 16,011 deletions.
1 change: 0 additions & 1 deletion .eslintcache

This file was deleted.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vuejs3-datepicker",
"version": "1.0.11",
"version": "1.0.14",
"description": "Vue 3 datepicker",
"files": [
"dist/*",
Expand Down
17,709 changes: 1,705 additions & 16,004 deletions serve/datepicker.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions src/components/datepicker/DateInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,7 @@ export default defineComponent({
parseTypedDate,
inputBlurred,
inputRef,
clearDate,
};
},
});
Expand Down
4 changes: 3 additions & 1 deletion src/components/datepicker/datepicker.css
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
margin-left: 10px;
font-size: 15px;
}

&__typeablecalendar{
position: absolute;
top: 10px;
Expand Down Expand Up @@ -187,6 +186,9 @@
&__clear-button, &__calendar-button{
cursor: pointer;
font-style: normal;
position: absolute;
top: 12px;
right:12px;
&.disabled {
color: #999;
cursor: default;
Expand Down
4 changes: 2 additions & 2 deletions src/components/datepicker/locale/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -488,8 +488,8 @@ export const vn = (): ILocale => {
'Tháng 11',
'Tháng 12',
];
const days = ['CN', 'H', 'B', 'T', 'N', 'S', 'B']
const daysNames = ['CN', 'Thứ Hai', 'Thứ Ba', 'Thứ Tư', 'Thứ Năm', 'Thứ Sáu', 'Thứ Bảy']
const days = ['CN', 'H', 'B', 'T', 'N', 'S', 'B'];
const daysNames = ['CN', 'Thứ Hai', 'Thứ Ba', 'Thứ Tư', 'Thứ Năm', 'Thứ Sáu', 'Thứ Bảy'];
const rtl = false;
const ymd = false;
const yearSuffix = '';
Expand Down
4 changes: 2 additions & 2 deletions src/components/examples/VModel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
</template>
<template v-slot:content>
<div class="flex-block">
<appdate-picker v-model="dateinput" @update:modelValue="dateSelected" />
<appdate-picker v-model="dateinput" @update:modelValue="dateSelected" :clearButton="true" />
<div class="change-btn">
<button @click="changeValue">Change Value</button>
<p>UpdateValue : {{ dateinput }}</p>
Expand All @@ -29,7 +29,7 @@ export default defineComponent({
setup() {
const dateinput = ref(new Date());
const template = `<appdate-picker
v-model="dateinput"
v-model="dateinput"
@update:modelValue="dateSelected"
/>`;
Expand Down

0 comments on commit 4ca56cb

Please sign in to comment.