# tys-calendar

> ``` yarn add ty-calendar npm i ty-calendar ``` ## Example ```js import Calendar from 'ty-calendar'

Latest version **0.0.4** (published 2018-10-20) · MIT license · 0 weekly downloads

## Install

```sh
npm install tys-calendar
pnpm add tys-calendar
yarn add tys-calendar
bun add tys-calendar
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.4 |
| Published | 2018-10-20 |
| First published | 2018-10-20 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 591.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | zhukecheng |
| Maintainers | zhukecheng |

## Links

- npm: https://www.npmjs.com/package/tys-calendar
- npm.io page: https://npm.io/package/tys-calendar

## Recent versions

- 0.0.4 (latest) — 2018-10-20

## README

# ty-calendar

```
yarn add ty-calendar
npm i ty-calendar
```
## Example
```js
import Calendar from 'ty-calendar'

export default class Test extends Component {
  render() {
    return <div>
      <Calendar />
    </div>
  }
}
```
![avatar](./20181020-0.png)

```js
import Calendar from 'ty-calendar'

const color = {
  1: '#c23531',
  2: '#2f4554',
  3: '#61a0a8',
  4: '#d48265',
  5: '#91c7ae',
  6: '#749f83',
  7: '#ca8622',
  8: '#bda29a',
  9: '#6e7074',
  10: '#546570',
  11: '#c4ccd3',
} // key代表日期 后面代表颜色代码

export default class Test extends Component {
  render() {
    return <div style={{ height: 800, width: 900 }}>
      <Calendar dataMap={color} />
      <div style={{ height: 300, background: '#000' }}></div>
    </div>
  }
}

```
![avatar](./20181020-124438@2x.png)
## Notice
```css
.ty-calendar {
  min-height: 500px; /*default height*/
  min-width: 700px; /*default width*/
}
```
## Props
| 参数 | 说明 | 类型 | 默认值 |
| :------: | :------: | :------: |
| toggleDay | 日期切换回调函数 | Function (dateinfo) | -- |
| monthEndRender | 月份面板结尾渲染 | Fucntion (month) | -- |
| dataMap | 高亮日期对象  | Map  | {} |

---
_Source: https://npm.io/package/tys-calendar · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
