{"id":19345600,"url":"https://github.com/future-team/ph-calendar","last_synced_at":"2026-06-17T19:07:21.488Z","repository":{"id":57322737,"uuid":"85649703","full_name":"future-team/ph-calendar","owner":"future-team","description":"calendar component for phoenix-ui","archived":false,"fork":false,"pushed_at":"2017-12-04T13:48:06.000Z","size":345,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-08-23T06:27:44.151Z","etag":null,"topics":["calendar-component","ph-calendar","phoenix-ui"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/future-team.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-03-21T02:26:18.000Z","updated_at":"2017-03-22T15:31:46.000Z","dependencies_parsed_at":"2022-08-26T01:11:29.357Z","dependency_job_id":null,"html_url":"https://github.com/future-team/ph-calendar","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/future-team/ph-calendar","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/future-team%2Fph-calendar","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/future-team%2Fph-calendar/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/future-team%2Fph-calendar/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/future-team%2Fph-calendar/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/future-team","download_url":"https://codeload.github.com/future-team/ph-calendar/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/future-team%2Fph-calendar/sbom","scorecard":{"id":414724,"data":{"date":"2025-08-11","repo":{"name":"github.com/future-team/ph-calendar","commit":"59cb098af9bf1f6298351e4c40ea1af3f5ae3f4d"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3,"checks":[{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Code-Review","score":0,"reason":"Found 2/22 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"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"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"License","score":9,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Warn: project license file does not contain an FSF or OSI license."],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 10 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-18T23:32:34.645Z","repository_id":57322737,"created_at":"2025-08-18T23:32:34.645Z","updated_at":"2025-08-18T23:32:34.645Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34461714,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-17T02:00:05.408Z","response_time":127,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["calendar-component","ph-calendar","phoenix-ui"],"created_at":"2024-11-10T04:07:23.637Z","updated_at":"2026-06-17T19:07:21.469Z","avatar_url":"https://github.com/future-team.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ph-calendar\ncalendar component for phoenix-ui\n\n# Install\n```javascript\n$ npm install ph-calendar --save \n```\n# Usage\n\n```javascript\nimport React, {Component, PropTypes} from 'react'\nimport PhCalendar from 'ph-calendar'\n\nclass Demo extends Component {\n    constructor(props, context) {\n        super(props, context)\n            this.state = {\n                values: [new Date(2017, 1, 24), new Date(2017, 2, 10)],\n                disabled:[new Date(2017, 2, 14), new Date(2017, 2, 17)],// start end 包括\n                weekStart: 1,\n                monthCount: 5,\n                range: true,\n                monthStart: 'top', //['top', 'center', 'bottom']\n                //weekLabel: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],\n                events: [\n                    {\n                        date: new Date(2017, 1, 10),\n                        name: '家立减'\n                    },\n                    {\n                        date: new Date(2017, 1, 22),\n                        name: '团购'\n                    },\n                    {\n                        date: new Date(2017, 2, 10),\n                        name: '劳动节'\n                    },\n                    {\n                        date: new Date(2017, 2, 15),\n                        name: '哈哈哈'\n                    }\n                ]\n            }\n    }\n    chooseCallback(data){\n        console.log('选择后的日期', data)\n    }\n    render() {\n        const {values, disabled, weekStart, events, weekLabel, range, monthCount} = this.state\n        return (\n            \u003cdiv className=\"rcs-demo\"\u003e\n                \u003cPhCalendar \n                    values={values}\n                    dateChose={this.chooseCallback}\n                    disabled={disabled}\n                    events={events}\n                    monthCount={monthCount}\n                    weekStart={weekStart}\n                    weekLabel={weekLabel}\n                    range={range}\n                    monthStart={monthStart}/\u003e\n            \u003c/div\u003e\n        )\n    }\n}\n```\n\n# Options\n\n支持的属性配置：\n- `values` : 日期对象数组，设置日历的选中日期，默认为空数组。 eg: 时间范围：`[new Date(2017, 1, 24), new Date(2017, 2, 10)]`    \n- `disabled` ：日期对象数组，设置禁用的日期，默认为空数组。 如果设置的值恰好为 2 个，则表示禁用的是一段日期。传如一个或者三个以上，则表示为单个日期禁用    \n- `dateChose` ：日期选择回调函数，默认为空函数。单个日期模式下，选中一个日期则处罚；日期范围模式下，选中两个日期才触发     \n- `range`：布尔值，设置日历选择日期的模式，默认为 `true`。 `true` 表示范围选择，`false` 表示单选\n- `monthCount`：正整数，设置单页日历的个数，默认为 6。最小值为 3，最大值为 12\n- `weekStart`：非负整数，设置一周的开始时间，默认为 1。取值范围是 `new Date().getDay()` 值的集合，即为 0、 1、 2、 3、 4、 5、 6，分别表示周日、周一、周二、周三、周四、周五、周六\n- `weekLabel`：字符串数组，设置周的显示格式，默认为 ['日', '一', '二', '三', '四', '五', '六']\n- `format`：字符串，设置日期的显示格式，默认为 `yyyy-MM-dd`\n- `events`：对象数组，设置日历事件显示，默认为空数组。对象的格式为 `{'date': [Date Object], 'name': [String Object]}`,eg： `[{'date': new Date(2016, 4, 1), 'name': '劳动节'}]`\n- `monthStart`：字符串，设置日历的默认显示方式，默认为 `top`。可选值为`['top', 'center', 'bottom']`, `top` 表示日历按照选中日期递增方式显示，`top` 表示日历按照选中日期两端延伸方式显示，`bottom` 表示日历按照选中日期递减方式显示，\n\n# Example\n效果图如下：    \n\u003cimg src=\"./examples/snapshot.png\" width=\"200\"\u003e      \n在线效果请看 [ph-calendar](https://future-team.github.io/ph-calendar/examples/index.html)       \n详细请参见`examples` 目录下 demo，更改对应参数查看效果，具体步骤参见下面 `Command`     \n\n# Command\n```bash\n# clone 代码仓库\n$ git clone https://github.com/future-team/ph-calendar.git \u0026\u0026 cd ph-calendar\n# 安装依赖\n$ npm install \n# 查看demo\n$ npm run demo \n```\n# Repair\n- 0.1.0 第一版本发布","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffuture-team%2Fph-calendar","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffuture-team%2Fph-calendar","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffuture-team%2Fph-calendar/lists"}