-
Notifications
You must be signed in to change notification settings - Fork 11
Refactor components and enhance BottomNavigation integration #311
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
base: dev
Are you sure you want to change the base?
Conversation
- Updated StatusBarComponent background color in multiple components for visual consistency. - Integrated BottomNavigation into HomeScreen, Bookmarks, ReaderScreen, and Settings for improved navigation. - Simplified BaniHeader component by removing unused props and imports. - Enhanced BottomNavigation functionality to dynamically handle navigation based on current state. - Added localization strings for new navigation items to support multiple languages.
- Updated the icon size in the BottomNavigation component to a fixed value of 24 for consistency, removing conditional logic based on active key.
…ponents - Removed hardcoded navigation items from Bookmarks component and updated BottomNavigation to directly use the navigation prop for improved flexibility. - Cleaned up imports and streamlined code in HomeScreen by removing the BottomNavigation component, enhancing overall maintainability.
- Implemented handleBookmarkPress function to navigate to the bookmarks screen when the bookmark button is pressed. - Updated ReaderScreen to utilize the new bookmark handler, enhancing user navigation experience.
- Added localization strings for navigation items in BottomNavigation, improving accessibility and user experience. - Updated the rendering of navigation item text to utilize localized strings instead of hardcoded values.
- Removed unused audio toggle functionality to streamline the component. - Adjusted audio playback speed validation to allow a range from 0.5 to 2.0 for better user control. - Updated the disabled state for speed adjustment buttons to reflect the new playback speed limits.
src/common/localization.js
Outdated
| DOWNLOADING: "ਡਾਊਨਲੋਡ ਹੋ ਰਹਿ ਰਹਾ ਹੈ", | ||
| NEXT: "ਅਗਲਾ", | ||
| HOME: "ਹੋਮ", | ||
| READ: "ਰੀਡ", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The translation of read is wrong here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
src/common/icons/ReadIcon.jsx
Outdated
| export default ReadIcon; | ||
|
|
||
| ReadIcon.propTypes = { | ||
| size: PropTypes.number.isRequired, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since we are adding default values, we can remove the isRequired from propTypes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
| <Pressable | ||
| onPress={() => handleSpeedChange(audioPlaybackSpeed - 0.1)} | ||
| disabled={audioPlaybackSpeed < 1.0} | ||
| disabled={audioPlaybackSpeed <= 0.5} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this either be audioPlaybackSpeed < 0.5, or add <= in the handleSpeedChange function.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the handleSpeedChange function, it returns when the value is < 0.5, but it should still accept 0.5. However, when the slider reaches 0.5, touch gets disabled.
- Translated localization strings for HOME, READ, and MUSIC to enhance user experience. - Updated ReadIcon component to set default props for size and color, improving flexibility and usability.
Uh oh!
There was an error while loading. Please reload this page.