Skip to content

Commit

Permalink
chore: minor changes after last iteration of review
Browse files Browse the repository at this point in the history
  • Loading branch information
kirillzyusko committed Dec 13, 2023
1 parent 97b0ae0 commit cb30df2
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 8 deletions.
2 changes: 1 addition & 1 deletion FabricExample/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1437,4 +1437,4 @@ SPEC CHECKSUMS:

PODFILE CHECKSUM: af32ece02671a96e2bafdfe72ad520e4015c2fe4

COCOAPODS: 1.11.3
COCOAPODS: 1.14.3
Original file line number Diff line number Diff line change
Expand Up @@ -113,10 +113,8 @@ const KeyboardAwareScrollView: FC<KeyboardAwareScrollViewProps> = ({
if (absoluteY < 0) {
const positionOnScreen = visibleRect - inputHeight - bottomOffset;
const topOfScreen = scrollPosition.value + absoluteY;
scrollTo(scrollViewAnimatedRef, 0, topOfScreen - positionOnScreen, animated);

// TODO: return correct value
return -1;
scrollTo(scrollViewAnimatedRef, 0, topOfScreen - positionOnScreen, animated);
}

return 0;
Expand Down
2 changes: 1 addition & 1 deletion example/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -759,4 +759,4 @@ SPEC CHECKSUMS:

PODFILE CHECKSUM: 45614159967e4f036f83a709a2537d9ed3694b03

COCOAPODS: 1.11.3
COCOAPODS: 1.14.3
Original file line number Diff line number Diff line change
Expand Up @@ -113,10 +113,8 @@ const KeyboardAwareScrollView: FC<KeyboardAwareScrollViewProps> = ({
if (absoluteY < 0) {
const positionOnScreen = visibleRect - inputHeight - bottomOffset;
const topOfScreen = scrollPosition.value + absoluteY;
scrollTo(scrollViewAnimatedRef, 0, topOfScreen - positionOnScreen, animated);

// TODO: return correct value
return -1;
scrollTo(scrollViewAnimatedRef, 0, topOfScreen - positionOnScreen, animated);
}

return 0;
Expand Down
2 changes: 2 additions & 0 deletions ios/views/KeyboardControllerView.mm
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,8 @@ - (instancetype)initWithFrame:(CGRect)frame
facebook::react::KeyboardControllerViewEventEmitter::OnFocusedInputTextChanged{
.text = std::string([text UTF8String])});

// TODO: use built-in _eventEmitter once NativeAnimated module will use
// ModernEventemitter
RCTBridge *bridge = [RCTBridge currentBridge];
if (bridge && [bridge valueForKey:@"_jsThread"]) {
FocusedInputTextChangedEvent *textChangedEvent =
Expand Down

0 comments on commit cb30df2

Please sign in to comment.