praveenpuglia / vuetify-daterange-picker

The missing date range picker for Vuetify JS you have been looking for.
https://vuetify-daterange-picker.gitbook.io/docs
MIT License
197 stars 59 forks source link

Internalization name of presets #42

Closed magvan closed 5 years ago

magvan commented 5 years ago

I make internalization. image labels translated success. dataRangeLabels image But presets not translated. image image

I tried to transfer as computed property, dont works.

Solution to the problem: property "presets" make as props.

praveenpuglia commented 5 years ago

This does not seem like an issue with the date range picker. Because the value for each preset's label would be evaluated and then be passed on to the date range component. ( Unless I am wrong about that. )

Can you put an example, somewhere like codesandbox so I can try it out and debug?

magvan commented 5 years ago

Thank. https://codesandbox.io/s/m5z0pmyym8 The name of the month has been translated. DateStart and DateEnd has been translated. Name presets not is not translated.

Step 1. image

Step 2. image

praveenpuglia commented 5 years ago

Thanks for the codesandbox setup. I'll try this out and see if I can fix things :)

magvan commented 5 years ago

Make presets as prop <v-daterange :options="dateRangeOptions" :presets="dataRangePresets"></v-daterange> then we can pass the computed property. this will work

praveenpuglia commented 5 years ago

Making presets as a prop will break code for everyone else who is already using the component. That is why I am thinking of a diff way. I may as well do that but release it as a separate version.

praveenpuglia commented 5 years ago

Hi!

I built a new version from ground up keeping simplicity of use in mind. Can you please try it out and let me know if that works for you?

P.S - I still need to add the option to pass in presets.

https://vuetify-daterange-picker.gitbook.io/docs/

praveenpuglia commented 5 years ago

Version 3.1.1 should fix this issue. Hence closing.