Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Slightly hacky support for android - Updated #18

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

adamrainsby
Copy link

My last pull request had a bug. This one should work.

#16

@gr4yscale
Copy link

Hi @adamrainsby, can you please explain what the thinking is behind these changes? I see you added the empty onLayout but not sure what the purpose is, is this still a work in progress or does it work with these changes?

@adamrainsby
Copy link
Author

@gr4yscale See this issue for the onLayout thing. facebook/react-native#3282

@adamrainsby
Copy link
Author

If you want to contribute and get it working with the animation again that would be great. At the moment it literally just shows and hides the content without any animation so it definitely can be improved.

@naoufal
Copy link
Owner

naoufal commented Feb 16, 2016

Hey guys, thanks for moving this forward.

I would opt for a solution that retains the animations. @gr4yscale Have you had any luck fixing this?

@adamrainsby
Copy link
Author

@naoufal Just to be clear, the animations still work on iOS but it just opens and closes on android. That is an improvement on it not working at all on android.

I think it should be merged in and then we can open an issue for animations on android?

@naoufal
Copy link
Owner

naoufal commented Apr 15, 2016

@adamrainsby you're right. Before merging, could you post a video of the example running on Android?

@adamrainsby adamrainsby force-pushed the master branch 2 times, most recently from 82aea03 to 9f89d89 Compare April 16, 2016 00:18
@adamrainsby
Copy link
Author

adamrainsby commented Apr 16, 2016

@naoufal I had to do a bit of work to get the example app running on android. I've updated my PR with those changes.

iOS specific components like NavigatorIOS were stripped out for the android version but they are still there when running on iOS. I also updated the version of react native to the latest version because there was a bug where the background would disappear after pressing the accordion.

Not sure the exact version this was fixed but for now we can say there is android support from 0.23?

accordion

@adamrainsby
Copy link
Author

@naoufal Is this ok?

@cfournel
Copy link

@naoufal if this is okay , could you please merge the code and do a release ? i can t use your great module at the moment since my app has to be android / ios compatible. Thanks you !

@GeoffreyPlitt
Copy link

+1

@naoufal
Copy link
Owner

naoufal commented Jun 22, 2016

@adamrainsby Sorry for being MIA all. @adamrainsby If you rebase this branch, I'll gladly merge it.

@cfournel
Copy link

cfournel commented Jun 22, 2016

@naoufal : Here is my test of @adamrainsby . Since i have copied directly @adamrainsby fork into my node_modules dir , i had to install react-tween-state and everything works fine ( except animations of course, but may that could be related to a tween effect or duration ? ) .. here is a screen cast :

@adamrainsby
Copy link
Author

@huitiemesens You can put "adamrainsby/react-native-accordion" instead of a version number in the package.json and npm install as usual instead of copy and pasting.

@cfournel
Copy link

@adamrainsby thanks for this tips, i m more a composer guy , i didn t know that could be done within a package file

@parveen-wizni
Copy link

hi,
I am facing some issue. I am using "react-native-accordion": "0.2.4" library for my project. This is working fine in IOS. when I run my app in android device in debugging mode. Then app is running fine. But if I used signed apk in same device then it is give this error. here I paste my application crash report log which are shown in android monitor. Error given below.

FATAL EXCEPTION: mqt_native_modules
Process: com.ampsmobile, PID: 2139
com.facebook.react.modules.core.JavascriptException: Requiring unknown module "react-native-accordion", stack:
t@2:387
i@2:177
@451:139
t@2:511
i@2:177
@449:139
t@2:511
i@2:177
@448:203
t@2:511
i@2:177
@447:212
t@2:511
t@2:240
i@2:177
component@44:489
u@44:130
o@44:48
createScene@44:1781
_renderScene@244:15724
@244:16158
render@244:16032
_renderValidatedComponentWithoutOwnerOrContext@152:5072
_renderValidatedComponent@152:5200
_updateRenderedComponent@152:4595
_performComponentUpdate@152:4395
updateComponent@152:3672
performUpdateIfNecessary@152:3193
performUpdateIfNecessary@132:667
r@130:571
perform@135:494
perform@135:494
perform@130:1539
P@130:1711
closeAll@135:1131
perform@135:581
batchedUpdates@129:456
s@130:761
a@149:69
enqueueSetState@149:917
setState@29:339
push@244:13537
onPressRow@429:2254
onPress@437:2706
touchableHandlePress@295:1171
_performSideEffectsForTransition@219:8188
_receiveSignal@219:6697
touchableHandleResponderRelease@219:4183
a@113:72
o@111:392
a@111:583
f@109:163
g@109:266
i@115:88
processEventQueue@109:1386
s@163:92
handleTopLevel@163:182
_receiveRootNodeIDEvent@162:617
receiveTouches@162:999
value@60:3582
@60:1801
k@60:436
value@60:1773

@cfournel
Copy link

In order to keep it clean @naoufal could you please merge this one ? Thanks

@adamrainsby
Copy link
Author

Apologies @huitiemesens, I still need to rebase. I'll try to do it soon.

@cfournel
Copy link

@adamrainsby don t worry i already switch for your fork in my package.json , since @naoufal seems afk for a while now ...

In order to fix a great bug ( avoiding to compile a signed android apk ) could you please take a look at https://github.com/naoufal/react-native-accordion/pull/33/commits ( its basically renaming index.ios.js to index.js ) ! Thanks you !

@adamrainsby
Copy link
Author

@huitiemesens I already did that in my fork. Are you still having issues with it?

@adamrainsby
Copy link
Author

@naoufal Rebased, could you merge?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants