Installations
npm install vue3-persian-datetime-picker
Releases
Unable to fetch releases
Developer
talkhabi
Developer Guide
Module System
CommonJS
Min. Node Version
Typescript Support
No
Node Version
14.17.5
NPM Version
8.3.0
Statistics
159 Stars
59 Commits
16 Forks
1 Watching
2 Branches
3 Contributors
Updated on 22 Nov 2024
Bundle Size
389.58 kB
Minified
99.29 kB
Minified + Gzipped
Languages
Vue (68.1%)
SCSS (16.72%)
JavaScript (14.5%)
HTML (0.54%)
Shell (0.14%)
Total Downloads
Cumulative downloads
Total Downloads
119,897
Last day
16.3%
427
Compared to previous day
Last week
14%
2,055
Compared to previous week
Last month
-2.3%
8,315
Compared to previous month
Last year
118.2%
73,521
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
vue3-persian-datetime-picker
A vue plugin to select jalali date and time
See documentation and demo at vue-persian-datetime-picker.
If you are using vuejs 2, please refer to this repository.
Installation
browser
1<script src="https://unpkg.com/vue@next"></script> 2<script src="https://cdn.jsdelivr.net/npm/moment"></script> 3<script src="https://cdn.jsdelivr.net/npm/moment-jalaali@0.9.4/build/moment-jalaali.js"></script> 4<script src="/dist/vue3-persian-datetime-picker.umd.min.js"></script> 5<div id="app"> 6 <date-picker v-model="date"></date-picker> 7</div> 8<script> 9 Vue.createApp({ 10 data: function() { 11 return { 12 date: '1400/01/01' 13 } 14 }, 15 components: { 16 DatePicker: Vue3PersianDatetimePicker 17 } 18 }).mount('#app') 19</script>
npm
1npm install vue3-persian-datetime-picker --save
Configuration for moment to ignore loading locales:
1// vue.config.js: 2module.exports = { 3 //.. 4 configureWebpack: { 5 plugins: [new webpack.IgnorePlugin(/^\.\/locale$/, /moment$/)] 6 }, 7 //... 8}
vitejs configuration:
1// vite.config.js 2// ... 3export default defineConfig({ 4 // ... 5 resolve: { 6 mainFields: [ 7 'browser', 8 'module', 9 'main', 10 'jsnext:main', 11 'jsnext' 12 ] 13 } 14})
Usage
1// main.js 2 3import { createApp } from 'vue' 4import Vue3PersianDatetimePicker from 'vue3-persian-datetime-picker' 5const app = createApp({}) 6app.component('DatePicker', Vue3PersianDatetimePicker) 7app.mount('#app')
Or in component
1<template> 2 <date-picker v-model="date"></date-picker> 3</template> 4 5<script> 6 import DatePicker from 'vue3-persian-datetime-picker' 7 export default { 8 data(){ 9 return { 10 date: '' 11 } 12 }, 13 components: { DatePicker } 14 } 15</script>
You can also set default values:
1// main.js 2 3import Vue3PersianDatetimePicker from 'vue3-persian-datetime-picker' 4const app = createApp({}) 5app.use(Vue3PersianDatetimePicker, { 6 name: 'CustomDatePicker', 7 props: { 8 format: 'YYYY-MM-DD HH:mm', 9 displayFormat: 'jYYYY-jMM-jDD', 10 editable: false, 11 inputClass: 'form-control my-custom-class-name', 12 placeholder: 'Please select a date', 13 altFormat: 'YYYY-MM-DD HH:mm', 14 color: '#00acc1', 15 autoSubmit: false, 16 //... 17 //... And whatever you want to set as default. 18 //... 19 } 20})
Then use in component
1<custom-date-picker v-model="date"></custom-date-picker>
Click to see full documentation and demo
Built With
- Vue.js - The Progressive JavaScript Framework.
- Moment.js - Parse, validate, manipulate, and display dates and times in JavaScript.
- moment-jalaali - A Jalaali (Jalali, Persian, Khorshidi, Shamsi) calendar system plugin for moment.js.
License
This project is licensed under the MIT License
Change log
1.2.2 (2022-02-10)
- Fixed: "value" is no longer needed.
1.2.1 (2022-02-09)
- Fixed: Moment jalali localeData is not a function
- Fixed: Watch model value
1.2.0 (2021-11-04)
- Feat: Added support for display format when using
custom-input
- Fixed: Using jumpMinute and roundMinute together
- Fixed: Typescript declaration
1.1.0 (2021-10-01)
- Feat: Added simple-mode
- Feat: Added
input-attrs
- Feat: Added
@next-month
and@prev-month
events - Feat: Added
@year-change
and@month-change
events - Fix: Mouse wheel in Firefox
- Fix: Prevent selected dates from being reset
1.0.0 (2021-08-14)
- Migrated to Vue3
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
Found 2/28 approved changesets -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
license file not detected
Details
- Warn: project does not have a license file
Reason
security policy file not detected
Details
- Warn: no security policy file detected
- Warn: no security file to analyze
- Warn: no security file to analyze
- Warn: no security file to analyze
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
branch protection not enabled on development/release branches
Details
- Warn: branch protection not enabled for branch 'master'
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
- Warn: 0 commits out of 4 are checked with a SAST tool
Reason
71 existing vulnerabilities detected
Details
- Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92
- Warn: Project is vulnerable to: GHSA-whgm-jr23-g3j9
- Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw
- Warn: Project is vulnerable to: GHSA-fwr7-v2mv-hh25
- Warn: Project is vulnerable to: GHSA-qwcr-r2fm-qrc7
- Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg
- Warn: Project is vulnerable to: GHSA-x9w5-v3q2-3rhw
- Warn: Project is vulnerable to: GHSA-pxg6-pf52-xh8x
- Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275
- Warn: Project is vulnerable to: GHSA-w573-4hg7-7wgq
- Warn: Project is vulnerable to: GHSA-phwq-j96m-2c2q
- Warn: Project is vulnerable to: GHSA-ghr5-ch3p-vcr6
- Warn: Project is vulnerable to: GHSA-434g-2637-qmqr
- Warn: Project is vulnerable to: GHSA-49q7-c7j4-3p7m
- Warn: Project is vulnerable to: GHSA-977x-g7h5-7qgw
- Warn: Project is vulnerable to: GHSA-f7q4-pwc6-w24p
- Warn: Project is vulnerable to: GHSA-fc9h-whq2-v747
- Warn: Project is vulnerable to: GHSA-6h5x-7c5m-7cr7
- Warn: Project is vulnerable to: GHSA-rv95-896h-c2vc
- Warn: Project is vulnerable to: GHSA-qw6h-vgh9-j6wx
- Warn: Project is vulnerable to: GHSA-74fj-2j2h-c42q
- Warn: Project is vulnerable to: GHSA-pw2r-vq6v-hr8c
- Warn: Project is vulnerable to: GHSA-jchw-25xp-jwwc
- Warn: Project is vulnerable to: GHSA-cxjh-pqwp-8mfp
- Warn: Project is vulnerable to: GHSA-pfq8-rq6v-vf5m
- Warn: Project is vulnerable to: GHSA-c7qv-q95q-8v27
- Warn: Project is vulnerable to: GHSA-78xj-cgh5-2h22
- Warn: Project is vulnerable to: GHSA-2p57-rm9w-gvfp
- Warn: Project is vulnerable to: GHSA-896r-f27r-55mw
- Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h
- Warn: Project is vulnerable to: GHSA-76p3-8jx3-jpfq
- Warn: Project is vulnerable to: GHSA-3rfm-jhwj-7488
- Warn: Project is vulnerable to: GHSA-hhq3-ff78-jv3g
- Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv
- Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3
- Warn: Project is vulnerable to: GHSA-xvch-5gv4-984h
- Warn: Project is vulnerable to: GHSA-8hfj-j24r-96c4
- Warn: Project is vulnerable to: GHSA-wc69-rhjr-hc9g
- Warn: Project is vulnerable to: GHSA-56x4-j7p9-fcf9
- Warn: Project is vulnerable to: GHSA-v78c-4p63-2j6c
- Warn: Project is vulnerable to: GHSA-qrpm-p2h7-hrv2
- Warn: Project is vulnerable to: GHSA-5rrq-pxf6-6jx5
- Warn: Project is vulnerable to: GHSA-8fr3-hfg3-gpgp
- Warn: Project is vulnerable to: GHSA-gf8q-jrpm-jvxq
- Warn: Project is vulnerable to: GHSA-2r2c-g63r-vccr
- Warn: Project is vulnerable to: GHSA-cfm4-qjh2-4765
- Warn: Project is vulnerable to: GHSA-x4jg-mjrx-434g
- Warn: Project is vulnerable to: GHSA-r8f7-9pfq-mjmv
- Warn: Project is vulnerable to: GHSA-rp65-9cf3-cjxr
- Warn: Project is vulnerable to: GHSA-9wv6-86v2-598j
- Warn: Project is vulnerable to: GHSA-7fh5-64p2-3v2j
- Warn: Project is vulnerable to: GHSA-hrpp-h998-j3pp
- Warn: Project is vulnerable to: GHSA-p8p7-x288-28g6
- Warn: Project is vulnerable to: GHSA-7mwh-4pqv-wmr8
- Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw
- Warn: Project is vulnerable to: GHSA-m6fv-jmcg-4jfg
- Warn: Project is vulnerable to: GHSA-cm22-4g7w-348p
- Warn: Project is vulnerable to: GHSA-g4rg-993r-mgx7
- Warn: Project is vulnerable to: GHSA-3jfq-g458-7qm9
- Warn: Project is vulnerable to: GHSA-5955-9wpr-37jh
- Warn: Project is vulnerable to: GHSA-f5x3-32g6-xq36
- Warn: Project is vulnerable to: GHSA-4wf5-vphf-c2xc
- Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3
- Warn: Project is vulnerable to: GHSA-7p7h-4mm5-852v
- Warn: Project is vulnerable to: GHSA-rqff-837h-mm52
- Warn: Project is vulnerable to: GHSA-8v38-pw62-9cw2
- Warn: Project is vulnerable to: GHSA-hgjh-723h-mx2j
- Warn: Project is vulnerable to: GHSA-jf5r-8hm2-f872
- Warn: Project is vulnerable to: GHSA-wr3j-pwj9-hqq6
- Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7
- Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q
Score
1.3
/10
Last Scanned on 2024-11-18
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn MoreOther packages similar to vue3-persian-datetime-picker
react-native-modal-datetime-picker
A react-native datetime-picker for Android and iOS
vue-persian-datetime-picker
A vue plugin to select jalali date and time
react-native-date-picker
A datetime picker for React Native. In-modal or inlined. Supports Android and iOS.
react-datetime-picker
A date range picker for your React app.