GithubHelp home page GithubHelp logo

nysamnang / react-native-24h-timepicker Goto Github PK

View Code? Open in Web Editor NEW
30.0 0.0 30.0 7 KB

React Native 24 hours format TimePicker for iOS

License: MIT License

JavaScript 100.00%
react-native 24-hour-format twenty-four-hour-format time-picker-ios number-picker-ios

react-native-24h-timepicker's Introduction

Hi there ๐Ÿ‘‹

react-native-24h-timepicker's People

Contributors

nysamnang avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

react-native-24h-timepicker's Issues

Warning: componentWillReceiveProps has been renamed

Please, update package to eliminate debug warning message:

Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://fb.me/react-async-component-lifecycle-hooks for details.

* Move data fetching code or side effects to componentDidUpdate.
* If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state
* Rename componentWillReceiveProps to UNSAFE_componentWillReceiveProps to suppress this warning in non-strict mode. In React 17.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run `npx react-codemod rename-unsafe-lifecycles` in your project source folder.

Please update the following components: TimePicker

Components state is lost if screen rerenders in background

Hi!

My screen is rerendering in the background as there's progressbars etc which are updating. On every update (once per second) my input into the timepicker is lost (has I haven't been able to press "DONE".

Is there a way to att an "onChange" method to the component?

Or how can this be solved?

Thanks,
D

Picker has been removed from React Native. It can now be installed and imported from '@react-native-picker/picker' instead of 'react-native'

Hi! ๐Ÿ‘‹

Picker has been removed from React Native. It can now be installed and imported from '@react-native-picker/picker' instead of 'react-native' ,
After upgrading react native to the latest version it stopped using Picker which is called in the react-native-24h-timepicker package

Here is the diff that solved my problem:

diff --git a/node_modules/react-native-24h-timepicker/src/index.js b/node_modules/react-native-24h-timepicker/src/index.js
index 14e68e6..9e13701 100644
--- a/node_modules/react-native-24h-timepicker/src/index.js
+++ b/node_modules/react-native-24h-timepicker/src/index.js
@@ -1,6 +1,7 @@
 import React, { Component } from "react";
 import PropTypes from "prop-types";
-import { View, TouchableOpacity, Text, Picker } from "react-native";
+import { View, TouchableOpacity, Text } from "react-native";
+import {Picker} from '@react-native-picker/picker';
 import RBSheet from "react-native-raw-bottom-sheet";
 import styles from "./styles";
 

This issue body was partially generated by patch-package.

No period of time like: AM and PM

I'm using this library but I can't use the 12hour maixmumHour because it don't have the period of time. So I stay in 24 hours so that I can determine if it's PM or AM.

I hope you can work on the time period.

Warning: componentWillReceiveProps

Hi,

Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://fb.me/react-async-component-lifecycle-hooks for details.

  • Move data fetching code or side effects to componentDidUpdate.
  • If you're updating state whenever props change, refactor your code to use memoization techniques or move it to static getDerivedStateFromProps. Learn more at: https://fb.me/react-derived-state
  • Rename componentWillReceiveProps to UNSAFE_componentWillReceiveProps to suppress this warning in non-strict mode. In React 17.x, only the UNSAFE_ name will work. To rename all deprecated lifecycles to their new names, you can run npx react-codemod rename-unsafe-lifecycles in your project source folder.

Please update the following components: TimePicker

Setting minutes after setting hour reset both at 0

Everything is in the title. I have copied and pasted the exemple code but still have this issue.
When I only set hour sand hit confirm, it works.
When I only set minutes and hit confirm, it works.
When I set both, it goes back to 0:00 before I can hit the confirm button.

Tested on iPhone 11 Pro Max IOS 14.0

Minimum Hour

A feature request for being able to set the Minimum Hour.

Warning RN V0.63

React Native 0.63
Xcode 12.1

Warning: componentWillReceiveProps has been renamed, and is not recommended for use. See https://fb.me/react-unsafe-component-lifecycles for details.

Animated: useNativeDriverwas not specified. This is a required option and must be explicitly set totrueorfalse``

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.