Socket
Socket
Sign inDemoInstall

rmc-date-picker

Package Overview
Dependencies
22
Maintainers
7
Versions
69
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    rmc-date-picker

React Mobile DatePicker Component for web and react-native


Version published
Weekly downloads
18K
decreased by-1.14%
Maintainers
7
Install size
3.28 MB
Created
Weekly downloads
 

Readme

Source

rmc-date-picker


React Mobile DatePicker Component (web and react-native)

NPM version react-native react build status Codecov gemnasium deps node version npm download

Screenshots

web

ios

android

Usage

see example

Development

npm i
npm start

Example

http://localhost:8000/examples/

online example: http://react-component.github.io/m-date-picker/

react-native

npm run rn-init
npm run watch-tsc
react-native start
react-native run-ios

install

rmc-date-picker

API

DatePicker props

namedescriptiontypedefault
className(web)additional css class of root dom nodeString''
prefixCls(web)prefix classString'rmc-date-picker'
pickerPrefixCls(web)picker prefix classString'rmc-picker'
defaultDatedefault selected date.Date
dateThe currently selected date.Date
modeThe date picker mode.String'date' enum('date', 'time', 'datetime', 'year', 'month')
minDatemin dateDatenew Date(2000, 1, 1, 0, 0, 0)
maxDatemax dateDatenew Date(2030, 1, 1, 23, 59, 59)
minHourmin Hour [0, 23]Number0
maxHourmax Hour [0, 23]Number23
minMinutemax Minute [0, 59]Number0
maxMinutemax Minute [0, 59]Number59
localethe locale of areaObjectimport from 'rmc-date-picker/lib/locale/en_US'
use12Hours12 hours display modeBooleanfalse
minuteStepThe amount of time, in minutes, between each minute item. Number1
onDateChangeDate change handler.Function(date: Date)''
onValueChangefire when picker change(vals: any, index: number) => void
formatMonthCustomize display value of months(month:number, current:Date) => React.Node
formatDayCustomize display value of days(day:number, current:Date) => React.Node

rmc-date-picker/lib/Popup props

namedescriptiontypedefault
className(web)additional css class of modal nodeString''
style(web)additional modal styleobject{}
popupTransitionName(web)String
maskTransitionName(web)String
prefixCls(web)popup's prefix classString'rmc-picker-popup'
styles(react-native)PopupPicker's stylesStyleSheet.create
datePickerDatePicker elementReact DatePicker element
dateThe currently selected date.Date
visiblewhether pop picker is visibleBooleanfalse
onChangeexec on okFunction(date: Date)
onVisibleChangecalled when pop picker visible changeFunction
onDismissexec on dismissfunction
okTextok button textstring/React.ReactElement'Ok'
dismissTextdismiss button textstring/React.ReactElement'Dismiss'
titlePopup titlestring/React.ReactElement''

Test Case

npm test
npm run chrome-test

Coverage

npm run coverage

open coverage/ dir

License

rmc-date-picker is released under the MIT license.

Keywords

FAQs

Last updated on 30 Jul 2019

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc