Skip to content

Commit

Permalink
refactor(react-native-github): move ProgressViewIOS to internal (#35277)
Browse files Browse the repository at this point in the history
Summary:
Pull Request resolved: #35277

# Changelog:
[JS][Removed] - removed ProgressViewIOS module
[iOS][Removed] - removed native iOS sources of ProgressViewIOS

Reviewed By: lunaleaps

Differential Revision: D40937475

fbshipit-source-id: 9060adf3c99727af4eeffc767ccfd0a70574859d
  • Loading branch information
hoxyq authored and facebook-github-bot committed Nov 10, 2022
1 parent ff4a3c2 commit 1453ef1
Show file tree
Hide file tree
Showing 13 changed files with 63 additions and 404 deletions.
45 changes: 0 additions & 45 deletions Libraries/Components/ProgressViewIOS/ProgressViewIOS.android.js

This file was deleted.

62 changes: 0 additions & 62 deletions Libraries/Components/ProgressViewIOS/ProgressViewIOS.d.ts

This file was deleted.

75 changes: 0 additions & 75 deletions Libraries/Components/ProgressViewIOS/ProgressViewIOS.ios.js

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

12 changes: 0 additions & 12 deletions React/Views/RCTProgressViewManager.h

This file was deleted.

45 changes: 0 additions & 45 deletions React/Views/RCTProgressViewManager.m

This file was deleted.

26 changes: 15 additions & 11 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import typeof KeyboardAvoidingView from './Libraries/Components/Keyboard/Keyboar
import typeof Modal from './Libraries/Modal/Modal';
import typeof Pressable from './Libraries/Components/Pressable/Pressable';
import typeof ProgressBarAndroid from './Libraries/Components/ProgressBarAndroid/ProgressBarAndroid';
import typeof ProgressViewIOS from './Libraries/Components/ProgressViewIOS/ProgressViewIOS';
import typeof RefreshControl from './Libraries/Components/RefreshControl/RefreshControl';
import typeof SafeAreaView from './Libraries/Components/SafeAreaView/SafeAreaView';
import typeof ScrollView from './Libraries/Components/ScrollView/ScrollView';
Expand Down Expand Up @@ -160,16 +159,6 @@ module.exports = {
);
return require('./Libraries/Components/ProgressBarAndroid/ProgressBarAndroid');
},
// $FlowFixMe[value-as-type]
get ProgressViewIOS(): ProgressViewIOS {
warnOnce(
'progress-view-ios-moved',
'ProgressViewIOS has been extracted from react-native core and will be removed in a future release. ' +
"It can now be installed and imported from '@react-native-community/progress-view' instead of 'react-native'. " +
'See https://github.com/react-native-progress-view/progress-view',
);
return require('./Libraries/Components/ProgressViewIOS/ProgressViewIOS');
},
get RefreshControl(): RefreshControl {
return require('./Libraries/Components/RefreshControl/RefreshControl');
},
Expand Down Expand Up @@ -770,4 +759,19 @@ if (__DEV__) {
);
},
});
/* $FlowFixMe[prop-missing] This is intentional: Flow will error when
* attempting to access ProgressViewIOS. */
/* $FlowFixMe[invalid-export] This is intentional: Flow will error when
* attempting to access ProgressViewIOS. */
Object.defineProperty(module.exports, 'ProgressViewIOS', {
configurable: true,
get() {
invariant(
false,
'ProgressViewIOS has been removed from react-native core. ' +
"It can now be installed and imported from '@react-native-community/progress-view' instead of 'react-native'. " +
'See https://github.com/react-native-progress-view/progress-view',
);
},
});
}

0 comments on commit 1453ef1

Please sign in to comment.