# react-cal-af

> React Native component that renders selectable monthly calendar or week stripe with agenda for selected date

Latest version **0.4.11** (published 2023-01-03) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-cal-af
pnpm add react-cal-af
yarn add react-cal-af
bun add react-cal-af
```

## 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.4.11 |
| Published | 2023-01-03 |
| First published | 2022-11-11 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 28.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | ger_eXciTer |
| Maintainers | nataliemcmullen |
| Keywords | react, react-native, calendar, agenda, stripe, datepicker |

## Links

- npm: https://www.npmjs.com/package/react-cal-af
- Repository: https://github.com/0xnatalie/react-native-inline-calendar
- Homepage: https://github.com/0xnatalie/react-native-inline-calendar#readme
- Issues: https://github.com/0xnatalie/react-native-inline-calendar/issues
- npm.io page: https://npm.io/package/react-cal-af

## Dependencies (1)

- [date-fns](https://npm.io/package/date-fns.md) ^1.29.0

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 0.4.11 (latest) — 2023-01-03
- 0.4.10 — 2022-12-21
- 0.4.9 — 2022-12-04
- 0.4.8 — 2022-11-15
- 0.4.7 — 2022-11-11
- 0.4.6 — 2022-11-11

## README

# react-native-inline-calendar
React Native component that renders selectable monthly calendar or week stripe with agenda for selected date

# Installation
Run in your terminal:
```javascript
yarn add react-native-inline-calendar
```
or
```javascript
npm install react-native-inline-calendar --save
```

Then add to your application as
```javascript
import { Calendar } from react-native-inline-calendar
```

# Usage

You can see usage example in this [Expo demo](https://snack.expo.io/@ger_exciter/react-native-inline-calendar)

# Params

| Param name    | Type        | Default value | Description |
| ------------- | ----------- | ------------- | ----------- |
| weekMode  | boolean         | false | enable week stripe mode |
| disableWeekToggle | boolean | false | disable toggle from week stripe to month view |
| scrollable  | boolean       | false | scrollable or not |
| weekStartsOn  | number      | 0 | Index of the first week day, i.e. 0 - Sunday, 1 - Monday, etc. |
| showAgenda  | boolean       | true | show agenda list under the calendar (_items_ property) |
| scrollByOne | boolean       | true | scroll by one page or with momentum |
| animatedScrollTo  | boolean | true | animate initial scroll |
| hideHeader  | boolean       | false | Hide/show month header |
| hideWeekDays  | boolean     | false | Hide/show week days names |
| showArrows  | boolean       | true  | Hide/show navigation arrows |
| minMonthsToScroll | number  | 0 | number of months in the past available for scroll |
| maxMonthsToScroll | number  | 1 | number of months in the future available for scroll |
| initialDate | date          | new Date | initial date |
| minDate | date              | new Date | if set, all dates earlier than that will be disabled |
| headerDateFormat            | string  | Date format for header |
| selectedDate  | date        | initialDate or now | date, initially selected |
| currentDate | date          | initialDate or now | current date |
| items | object              | null | agenda items in map format (see below) |
| dataUpdated | timestamp     | null | timestamp of last data refresh to update calendar cache. Required for dinamic data updates |
| emptyListRenderer | function | defaultEmptyListRenderer | what should be rendered if agenda is empty for selected date |
| itemRenderer | function     | defaultItemRenderer | agenda item renderer |
| itemClickHandler | function | void | agenda item click handler |
| onDateSelect | function     | void | date select handler, doesn't prevent rendering date's agenda, runs after selected date state is updated |
| styles | object             | defaultStyles | custom styles that can be applied to the component. Import defaultStyles for the reference |

Agenda items data format:
```javascript
{
  'YYYY-MM-DD': {
    style: object,
    items: [ object ] 
  } 
} 
```

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