Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions example/.java-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1.8
2 changes: 1 addition & 1 deletion example/ios/Podfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
platform :ios, '9.0'
platform :ios, '10.0'
require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'

target 'example' do
Expand Down
16 changes: 14 additions & 2 deletions example/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,10 @@ PODS:
- React-cxxreact (= 0.61.5)
- React-jsi (= 0.61.5)
- ReactCommon/jscallinvoker (= 0.61.5)
- RNCPicker (1.14.0):
- React-Core
- RNDateTimePicker (3.4.3):
- React-Core
- Yoga (1.14.0)

DEPENDENCIES:
Expand Down Expand Up @@ -247,6 +251,8 @@ DEPENDENCIES:
- React-RCTVibration (from `../node_modules/react-native/Libraries/Vibration`)
- ReactCommon/jscallinvoker (from `../node_modules/react-native/ReactCommon`)
- ReactCommon/turbomodule/core (from `../node_modules/react-native/ReactCommon`)
- "RNCPicker (from `../node_modules/@react-native-picker/picker`)"
- "RNDateTimePicker (from `../node_modules/@react-native-community/datetimepicker`)"
- Yoga (from `../node_modules/react-native/ReactCommon/yoga`)

SPEC REPOS:
Expand Down Expand Up @@ -302,6 +308,10 @@ EXTERNAL SOURCES:
:path: "../node_modules/react-native/Libraries/Vibration"
ReactCommon:
:path: "../node_modules/react-native/ReactCommon"
RNCPicker:
:path: "../node_modules/@react-native-picker/picker"
RNDateTimePicker:
:path: "../node_modules/@react-native-community/datetimepicker"
Yoga:
:path: "../node_modules/react-native/ReactCommon/yoga"

Expand Down Expand Up @@ -331,8 +341,10 @@ SPEC CHECKSUMS:
React-RCTText: 9ccc88273e9a3aacff5094d2175a605efa854dbe
React-RCTVibration: a49a1f42bf8f5acf1c3e297097517c6b3af377ad
ReactCommon: 198c7c8d3591f975e5431bec1b0b3b581aa1c5dd
RNCPicker: 1a266981fc99330c252f5f98b3f09a377a35d88c
RNDateTimePicker: d943800c936fb01c352fcfb70439550d2cb57092
Yoga: f2a7cd4280bfe2cca5a7aed98ba0eb3d1310f18b

PODFILE CHECKSUM: 79310af6b976c356911a8a833e9b99c3399fdda3
PODFILE CHECKSUM: 458533d98e56668b204d6c159e3a7c75610075a3

COCOAPODS: 1.8.4
COCOAPODS: 1.10.0
3 changes: 2 additions & 1 deletion example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
"moment": "^2.24.0",
"react": "16.9.0",
"react-native": "0.61.5",
"@react-native-community/picker": "^1.8.0",
"@react-native-picker/picker": "^1.14.0",
"@react-native-community/datetimepicker" : "^3.4.3",
"react-native-wheel-picker-android": "../"
},
"devDependencies": {
Expand Down
20 changes: 17 additions & 3 deletions example/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -944,6 +944,13 @@
wcwidth "^1.0.1"
ws "^1.1.0"

"@react-native-community/datetimepicker@^3.4.3":
version "3.4.3"
resolved "https://registry.yarnpkg.com/@react-native-community/datetimepicker/-/datetimepicker-3.4.3.tgz#e57cc254a53ea7c4229ad7c4cfc3368c109c1db3"
integrity sha512-FaryfNYxWvgL2YH+CPhbKl2viLwsYFSq+vrhQT8IHB+uOTPhRtRZ0sWSU1N3eWy8HFwqmTw2Ao5uVgn8cvsUew==
dependencies:
invariant "^2.2.4"

"@react-native-community/eslint-config@^0.0.5":
version "0.0.5"
resolved "https://registry.yarnpkg.com/@react-native-community/eslint-config/-/eslint-config-0.0.5.tgz#584f6493258202a57efc22e7be66966e43832795"
Expand All @@ -961,6 +968,11 @@
eslint-plugin-react-native "3.6.0"
prettier "1.16.4"

"@react-native-picker/picker@^1.14.0":
version "1.14.0"
resolved "https://registry.yarnpkg.com/@react-native-picker/picker/-/picker-1.14.0.tgz#9c3ce0be162239a7a05b994f2bdcf5660b5466b9"
integrity sha512-KN/nOSxO64LxYms/8RpdjdIqemqDlxM8glDi4upg40/3JqalmXoHHBQxA0XYdAoL+padSVHAoAS6Ie5zAn8gTw==

"@types/babel__core@^7.1.0":
version "7.1.6"
resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.1.6.tgz#16ff42a5ae203c9af1c6e190ed1f30f83207b610"
Expand Down Expand Up @@ -4421,7 +4433,7 @@ mkdirp@^0.5.1:
dependencies:
minimist "0.0.8"

moment@^2.22.0, moment@^2.24.0:
moment@^2.24.0:
version "2.24.0"
resolved "https://registry.yarnpkg.com/moment/-/moment-2.24.0.tgz#0d055d53f5052aa653c9f6eb68bb5d12bf5c2b5b"
integrity sha512-bV7f+6l2QigeBBZSM/6yTNq4P2fNpSWj/0e7jQcy87A8e7o2nAfP/34/2ky5Vw4B9S446EtIhodAzkFCcR4dQg==
Expand Down Expand Up @@ -5073,9 +5085,11 @@ react-is@^16.12.0, react-is@^16.8.1, react-is@^16.8.4, react-is@^16.9.0:
integrity sha512-GFMtL0vHkiBv9HluwNZTggSn/sCyEt9n02aM0dSAjGGyqyNlAyftYm4phPxdvCigG15JreC5biwxCgTAJZ7yAA==

react-native-wheel-picker-android@../:
version "2.0.7"
version "3.0.0"
dependencies:
moment "^2.22.0"
"@react-native-community/datetimepicker" "^3.4.3"
"@react-native-picker/picker" "^1.14.0"
moment "^2.24.0"

[email protected]:
version "0.61.5"
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@
},
"homepage": "https://github.com/kalontech/ReactNativeWheelPicker",
"dependencies": {
"@react-native-community/picker": "^1.8.0",
"@react-native-picker/picker": "^1.14.0",
"@react-native-community/datetimepicker" : "^3.4.3",
"moment": "^2.24.0"
}
}
11 changes: 6 additions & 5 deletions src/DatePicker.ios.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import React, { useState } from "react";
import { DatePickerIOS, View } from "react-native";
import { View } from "react-native";
import RNDateTimePicker from "@react-native-community/datetimepicker"

interface Props {
initDate: Date;
Expand All @@ -12,13 +13,13 @@ const DatePicker: React.FC<Props> = props => {
const [date, setDate] = useState(initDate || new Date())
return (
<View pointerEvents={disabled ? "none" : "auto"}>
<DatePickerIOS
date={date}
onDateChange={(date) => {
<RNDateTimePicker
value={date}
onChange={(event, date) => {
if (onDateSelected) onDateSelected(date)
setDate(date)
}}
mode={'date'}
mode="date"
{...props}
/>
</View>
Expand Down
2 changes: 1 addition & 1 deletion src/WheelPicker.ios.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, { useState } from "react";
import { View } from "react-native";
import { Picker } from "@react-native-community/picker";
import { Picker } from "@react-native-picker/picker";

interface Props {
data: Array<string>;
Expand Down