damienroche / vue-mj-daterangepicker Goto Github PK
View Code? Open in Web Editor NEW๐Vue.js date range picker with multiples ranges and presets (vue 2.x)
Home Page: https://damienroche.github.io/vue-mj-daterangepicker/
๐Vue.js date range picker with multiples ranges and presets (vue 2.x)
Home Page: https://damienroche.github.io/vue-mj-daterangepicker/
The first day of the week is not always Monday in some of the countries, is the picker aware of that?
If not, how can I set the first day of the week as a prop? (Here is an example: https://element.eleme.io/#/en-US/component/datetime-picker#picker-options)
Currently, 'custom'
is hardcoded to be the default selected presets.
can we add an api to pass default preset selection? for example I may want 'next7days'
to be the default selected presets.
thank you.I can open the pr if you want me to
Is this library support to select the month range?
The ability to select a date range not from today but from an arbitrary date of 3 months? or year? it would be nice to present
There's no .d.ts available for this, so can't just use when you develop in TypeScript.
https://definitelytyped.org/
I save dateFrom and dateTo in localstorage or cookie to set up it after page reload. If I set lastDay preset i need remember it.
You know that I meen?
Hello, it's very common now a days to use webpack to filter-out unused classes from css files. Adding a namespace so that all styles related to this component, specially since the DOM isn't present on html files which is what webpack looks over. having a consistent namespace for classes would make it very easy to whistlist classes
First of all thanks to the wonderful plugin. The design looks very neat and superb.
The picker does not even show up in the component I have used.
I have used the same code as described in the example.
There are no errors in the console though.
<date-range-picker begin="2016-02-19T00:00:00.000+01:00" :from="from" :to="to" :panel="panel" :theme="theme"/>
<script>
export default {
name: "SampleComponent",
data: () => ({
to: '2019-04-23T10:26:00.996Z',
from: '2018-04-23T10:26:00.996Z',
panel: 'range',
theme: {
primary: '#46C3A3',
secondary: '#2D3E50',
ternary: '#93A0BD',
light: '#ffffff',
border: '#e6e6e6',
dark: '#000000',
hovers: {
day: '#CCC',
range: '#e6e6e6'
}
}
}),
methods: {
update(values) {
this.$router.push({
query: Object.assign({}, this.$route.query, {
to: values.to,
from: values.from,
panel: values.panel
})
});
}
}
};
</script>
The initialisation is done in the application.js
import Vue from "vue";
import DateRangePicker from 'vue-mj-daterangepicker'
import 'vue-mj-daterangepicker/dist/vue-mj-daterangepicker.css'
Vue.use(DateRangePicker)
Hi, Damien!
You made a great date range picker!
I have a question about start and finish range date begin.
What's the point?
Today is 09 March. I set the date range from 15 March to 05 April and save it.
Then I refresh the page, after page is loaded I see that current month setted as April (because the end range is next month and i do not see March), it would be better if calendar could begin from Start range - March!
What I see when page is loaded: (End of the range)
What i expected to see: (Start of the range)
I try to use begin param with a start date, but it does not help.
<date-range-picker
ref="rangepicker"
:begin="'{{ $item->start }}'"
:from="'{{ $item->start }}'"
:to="'{{ $item->finish }}'"
:past="false"
/>
Btw, it would be useful to add a Home icon (or a method to quickly back to the current day, but without it selected)
Is possible to add other locales like 'es'?
Thanks
<div v-for="(Device,key) in Devices" :key="key">
<date-range-picker :ref="Device.Id" @update="update" :theme="dateRangeTheme" :from="Device.startDate" :to="Device.endDate" :presets='presets' :panels="['range', 'week', 'month']"/>
</div>
Only the first iteration of the date-range-picker component allows me to change the presets. The others don't respond when I click the input button. Although the Submit and Reset ranges buttons work still. I'm not receiving any errors in my console.
I have used the same code as described in the example. (in laravel-vue working project). After istalation i saw this errors in browser console:[Vue warn]: $attrs is readonly and [Vue warn]: $attrs is readonly and [Vue warn]: $listeners is readonly.
Before this error wasnt exists((( Is this problem from datepicker or this depends on some special config of my app? Thanks
By default i want month and week panel to be available but when you click a certain button i have written code to update the 'panel' prop. But the calander is not updated and when i look what is stored in the 'currentPanel' data variable it is still month and week. Is it possible to update this?
Is it possible to provide a list of dates which can be highlighted as holidays? or maybe a pill type hover to say which holiday it is?
Is it possible that if user open week panel and if he wants to change the year or month of opened calendar then on click on month it will open month panel from which they can select month and the functionality of selecting week for that panel remain same.
Year panel selection with future false causes browser to toss the long script warning. even if I set the yearsCount to 0. It should simply not show the future years but the right count of years in the past.
I'd like to add a new language, but I currently have no clue on how to do that.
Can I add a language without having to change the source code?
Nobody wants node-sass in its project dependencies.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.