{"id":16434134,"url":"https://github.com/wangweianger/zane-data-time-calendar","last_synced_at":"2025-03-16T17:36:08.321Z","repository":{"id":57405175,"uuid":"104207525","full_name":"wangweianger/zane-data-time-calendar","owner":"wangweianger","description":"A simple and complete time calendar plug-in","archived":false,"fork":false,"pushed_at":"2019-04-01T03:03:44.000Z","size":987,"stargazers_count":69,"open_issues_count":14,"forks_count":31,"subscribers_count":11,"default_branch":"master","last_synced_at":"2024-10-12T08:48:15.113Z","etag":null,"topics":["es6","javascript","sass"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wangweianger.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-09-20T11:35:48.000Z","updated_at":"2024-03-25T08:15:35.000Z","dependencies_parsed_at":"2022-09-16T18:41:17.470Z","dependency_job_id":null,"html_url":"https://github.com/wangweianger/zane-data-time-calendar","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wangweianger%2Fzane-data-time-calendar","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wangweianger%2Fzane-data-time-calendar/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wangweianger%2Fzane-data-time-calendar/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wangweianger%2Fzane-data-time-calendar/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wangweianger","download_url":"https://codeload.github.com/wangweianger/zane-data-time-calendar/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":221666419,"owners_count":16860415,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["es6","javascript","sass"],"created_at":"2024-10-11T08:48:16.905Z","updated_at":"2024-10-27T11:01:38.333Z","avatar_url":"https://github.com/wangweianger.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# zane-data-time-calendar\nPC端时间日历插件\n\n### 说明：\n此插件不依赖任何第三方插件，因此可以在任何地方单独使用\n\n### images \n![输入图片说明](https://github.com/wangweianger/zane-data-time-calendar/blob/master/demo/01.png \"在这里输入图片标题\")\n![输入图片说明](https://github.com/wangweianger/zane-data-time-calendar/blob/master/demo/02.png \"在这里输入图片标题\")\n![输入图片说明](https://github.com/wangweianger/zane-data-time-calendar/blob/master/demo/03.png \"在这里输入图片标题\")\n![输入图片说明](https://github.com/wangweianger/zane-data-time-calendar/blob/master/demo/04.png \"在这里输入图片标题\")\n![输入图片说明](https://github.com/wangweianger/zane-data-time-calendar/blob/master/demo/05.png \"在这里输入图片标题\")\n![输入图片说明](https://github.com/wangweianger/zane-data-time-calendar/blob/master/demo/06.png \"在这里输入图片标题\")\n![输入图片说明](https://github.com/wangweianger/zane-data-time-calendar/blob/master/demo/07.png \"在这里输入图片标题\")\n![输入图片说明](https://github.com/wangweianger/zane-data-time-calendar/blob/master/demo/08.png \"在这里输入图片标题\")\n\n### API文档及DEMO地址  ：http://www.seosiwei.com/zaneDate/index.html  \n\n### npm地址：https://www.npmjs.com/package/zane-calendar \n\n### vue组件npm地址 支持vue1.0,vue2.0: https://www.npmjs.com/package/vue-date-calendar\n\n### 使用方式  \n\n\n### 浏览器端使用 \n```js\n\u003clink href=\"./dist/zane-calendar.min.css\"\u003e\n\u003cscript src=\"./dist/zane-calendar.min.js\"\u003e\u003c/script\u003e\n\n\u003c!-- Input boxes for plug-ins requiring extra time. --\u003e\n\u003cinput type=\"\" name=\"\" id=\"zane-calendar\"\u003e\n\nInitialization.\nzaneDate({\n\telem:'#zane-calendar',\n})\n```\n\n\n### Webpack 使用\n\n```js\n\nnpm install zane-calendar --save   |  yarn add zane-calendar\n\n\nconst zaneDate = require('zane-calendar') 或\nimport zaneDate from 'zane-calendar'\n\n\n\u003c!-- Input boxes for plug-ins requiring extra time. --\u003e\n\u003cinput type=\"\" name=\"\" id=\"zane-calendar\"\u003e\n\n\nInitialization. \nzaneDate({\n\telem:'#zane-calendar',\n})\n\n```\n\n### 参数说明\n\n参数配置(参数可灵活配置)\n```js\n{\n\t\n\telem:'#zane-calendar',  控件的原生dom 注意：仅限制于id选择器\n\ttype:'day',   \t\t\t可选类型 day year month time doubleday doubleyear doublemonth doubletime\n\tlang:'cn',   \t\t\t可选择语言类型 cn , en \n\twidth:250,  \t\t\t插件宽度配置   220 \u003c= X \u003c= 500\n\theight:280, \t\t\t插件高度配置   240 \u003c= X \u003c= 350\n\tbehindTop:10,   \t\t插件与输入框的高度 \n\tformat:'yyyy-MM-dd HH:mm:ss',  时间格式化\n\tbegintime:'',  \t\t\t开始时间  （单选择可选项）\n\tendtime:'',             结束时间  （double选择器可选项）\n\tmin:'',  \t\t\t\t可选取时间最小范围 1900-10-01\n\tmax: '',  \t\t\t\t可选取时间最大范围 2099-12-31\n\tposition:'fixed',  \t\t定位方式，暂时只支持 fixed\n\tevent:'click',   \t\t事件方式，暂时只支持 click \n\tzindex:100,   \t\t\tz-index值\n\tshowtime:true,  \t\t是否显示选择时间\n\tshowclean:true,  \t\t是否显示清除按钮\n\tshownow:true,  \t\t\t是否显示当前按钮\n\tshowsubmit:true, \t\t是否显示提交按钮\n\thaveBotBtns:true, \t\t是否有底部按钮列表\n\tshowsecond:true,        type='time|doubletime'时是否支持选择秒单位\n\tcalendarName:'', \t\t此参数勿动 表示当前时间插件实例化对象\n\tmounted:()=\u003e{}, \t\t插件加载完成之后调用\n\tchange:(fulltime,begintime,endtime)=\u003e{}, 时间变更之后调用\n\tdone:(fulltime,begintime,endtime)=\u003e{}, 选择完成之后调用\n}\t\n\n\n```\n### 案例调用方式\n\n```js\n\t默认完整选项\n\tzaneDate({\n\t\telem:'#zane-calendar',\n\t})\n\n\t只选择年月日\n\tzaneDate({\n\t\telem:'#zane-calendar',\n\t\tshowtime:false,\n\t})\n\n\t使用英文\n\tzaneDate({\n\t\telem:'#zane-calendar',\n\t\tlang:'en',\n\t})\n\n\t只选择年\n\tzaneDate({\n\t\telem:'#zane-calendar',\n\t\ttype:'year',\n\t})\n\n\t只选择月\n\tzaneDate({\n\t\telem:'#zane-calendar',\n\t\ttype:'month',\n\t})\n\n\t只选择时间\n\tzaneDate({\n\t\telem:'#zane-calendar',\n\t\ttype:'time',\n\t})\n\n\t格式化方式\n\tzaneDate({\n\t\telem:'#zane-calendar',\n\t\tformat:'yyyy年MM月dd日 HH时mm分ss秒',\n\t})\n\n\t限定能选择的最小最大区间\n\tzaneDate({\n\t\telem:'#zane-calendar',\n\t\tmin:'2017-08-01',\n\t\tmax:'2017-08-20',\n\t})\n\n\t......\n\n\t具体的请查看demo\n\n```\n\n### 1.1.0 版本新增 double选择器 \n\n```js\nconfig.type  新增double类型  可选类型如下：day year month time doubleday doubleyear doublemonth doubletime\n\n双日期范围选择\nzaneDate({\n\telem:'#demo21',\n\ttype:'doubleday'\n})\n\n双年范围选择\nzaneDate({\n\telem:'#demo22',\n\ttype:'doubleyear',\n})\n\n双月范围选择\nzaneDate({\n\telem:'#demo23',\n\ttype:'doublemonth',\n})\n\n双时间选择\nzaneDate({\n\telem:'#demo24',\n\ttype:'doubletime', \n})\n\n\n```\n\n### 1.2.0 版本\n### 1.doubleday类型新增选择时间，支持时分秒选择\n### 2.double类型检测距离右边window边线的距离，若不足，自动排列为上下两个日期\n\n```js\nconfig.type doubleday支持选择时间范围\n\n双日期范围选择\nzaneDate({\n\telem:'#demo25',\n\tformat:'yyyy-MM-dd HH:mm:ss',\n\ttype:'doubleday',\n\tshowtime:true\n})\n\n```\n\n### 1.2.1 版本  新增z-index 参数\n```js\nzaneDate({\n\telem:'#zane-calendar',\n\tzindex:500,\n})\n\n```\n\n### 1.2.2 版本 完善日历插件文档\n\n### 2.0.9 版本 修复单页面BUG，修复safair苹果信息 相关BUG\n\n### 2.1.0 版本 修复双选择器有默认值的bug，更新demo图片\n\n### 2.2.0 版本 修复上一月下一月跳月问题\n\n### 2.2.3 版本 修复点击多次重复生成日历问题\n\n### 2.2.4 版本 增加结束时间大于开始时间的判断\n\n### 2.2.5 版本 增加双选择器区间选中样式效果\n\n### 2.2.6 版本 修复双选择器默认选中颜色相关bug\n\n### 2.2.7 版本 type='time|doubletime'时是否支持选择秒单位\n```js\nzaneDate({\n\telem:'#demo25',\n\ttype:'time',\n\tshowsecond:false\n})\n\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwangweianger%2Fzane-data-time-calendar","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwangweianger%2Fzane-data-time-calendar","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwangweianger%2Fzane-data-time-calendar/lists"}