Skip to content

WordPress News App is a modern Flutter application designed to deliver news content from WordPress sites. It offers a seamless and engaging experience for reading and interacting with WordPress-based news content on mobile devices.

Notifications You must be signed in to change notification settings

Thiararapeter/wpnewsapp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

12 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

WordPress News App

A modern Flutter application that delivers news content from WordPress sites with an integrated in-app browser experience. This app provides a seamless, engaging experience for reading and interacting with WordPress-based news content without leaving the app ecosystem.

✨ Key Features

πŸ“– Content Reading Experience

  • Clean Article Display: Optimized typography and layout for comfortable reading
  • Featured Images: High-quality image display with caching and error handling
  • Text-to-Speech: Built-in TTS functionality with customizable voice settings
  • Reading Progress: Visual progress indicator and position saving
  • Social Media Embeds: Integrated display of Twitter, Instagram, and Facebook content

🌐 In-App Browser

  • WebView Integration: Browse external links without leaving the app
  • Smart Link Handling: User choice between in-app and external browser
  • Network Error Recovery: Intelligent error handling with retry mechanisms
  • Navigation Controls: Back, forward, refresh, and share functionality
  • Connectivity Monitoring: Real-time network status detection

πŸ“š Content Management

  • Bookmarks System: Save articles for later reading with persistent storage
  • Related Posts: AI-powered content recommendations based on categories and keywords
  • Article Sharing: Native sharing functionality across platforms
  • Custom Fields Support: Display additional WordPress ACF data

🎨 User Interface

  • Responsive Design: Optimized for various screen sizes and orientations
  • Modern Material Design: Clean, intuitive interface following Material Design principles
  • Loading States: Smooth loading animations and progress indicators
  • Error Handling: User-friendly error messages with recovery options

πŸ—οΈ Technical Architecture

Core Technologies

  • Flutter Framework: Cross-platform mobile development
  • Provider Pattern: State management and data flow
  • WordPress REST API: Content delivery and management
  • WebView Flutter: In-app browser functionality
  • Connectivity Plus: Network monitoring and detection

Key Components

  • Post Detail Screen: Enhanced article reading experience
  • WebView Screen: Full-featured in-app browser
  • Link Handler: Smart URL management and routing
  • Network Helper: Connectivity testing and error recovery
  • Bookmark System: Persistent article storage

πŸš€ Getting Started

Prerequisites

  • Flutter SDK (3.0+)
  • Dart SDK (3.0+)
  • Android Studio / VS Code
  • Git

Installation

  1. Clone the repository:

    git clone https://github.com/Thiararapeter/wpnewsapp.git
  2. Navigate to project directory:

    cd wpnewsapp
  3. Install dependencies:

    flutter pub get
  4. Run the app:

    flutter run

πŸ“ Project Structure

lib/
β”œβ”€β”€ config/
β”‚   └── app_settings.dart           # Theme and app configuration
β”œβ”€β”€ models/
β”‚   β”œβ”€β”€ post.dart                   # Article data model
β”‚   └── comment.dart                # Comment data model (removed)
β”œβ”€β”€ providers/
β”‚   β”œβ”€β”€ posts_provider.dart         # Article state management
β”‚   └── comments_provider.dart      # Comment provider (removed)
β”œβ”€β”€ screens/
β”‚   β”œβ”€β”€ post_detail_screen.dart     # Enhanced article reading
β”‚   β”œβ”€β”€ webview_screen.dart         # In-app browser
β”‚   └── home_screen.dart            # Main app screen
β”œβ”€β”€ services/
β”‚   └── wordpress_service.dart      # WordPress API integration
β”œβ”€β”€ utils/
β”‚   β”œβ”€β”€ link_handler.dart           # Smart URL management
β”‚   └── network_helper.dart         # Connectivity utilities
└── widgets/
    β”œβ”€β”€ bookmark_button.dart        # Bookmark functionality
    β”œβ”€β”€ social_media_embed.dart     # Social media integration
    └── tts_test_widget.dart        # Text-to-speech testing

πŸ› οΈ Dependencies

Core Packages

UI & Media

Utilities

πŸš€ Usage Guide

Reading Articles

  1. Browse Articles: Scroll through the main feed to discover content
  2. Open Article: Tap any article to open the detailed reading view
  3. Read Full Article: Use the "Read Full Article" button to view the complete content in the in-app browser
  4. Text-to-Speech: Long-press the TTS button to access voice settings, then tap to listen
  5. Bookmark: Tap the bookmark icon to save articles for later reading

In-App Browser Features

  • Smart Link Handling: When tapping links, choose between in-app or external browser
  • Navigation: Use back/forward buttons to navigate between pages
  • Share Content: Share interesting pages directly from the browser
  • Network Issues: Automatic retry and fallback options for connectivity problems

Customization

  • TTS Settings: Adjust volume, speed, and pitch for optimal listening experience
  • Reading Position: App automatically saves your reading progress
  • Bookmarks: Access saved articles from the bookmarks section

πŸ”§ Configuration

WordPress Integration

The app connects to WordPress sites via REST API. Configure your WordPress endpoint in:

// lib/services/wordpress_service.dart
static const String baseUrl = 'YOUR_WORDPRESS_SITE_URL';

Theme Customization

Modify app appearance in:

// lib/config/app_settings.dart
class AppSettings {
  static final theme = AppTheme(
    primaryColor: Colors.blue,
    // ... other theme properties
  );
}

πŸ› Troubleshooting

Network Issues

  • Connection Problems: App automatically detects and handles network issues
  • WebView Errors: Use "Try Again" button or "Open in Browser" option
  • Slow Loading: Check internet connection and try refreshing

Performance

  • Memory Usage: Images are cached automatically for better performance
  • Battery Life: TTS and WebView are optimized for minimal battery drain
  • Storage: Bookmarks and reading positions are stored locally

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

πŸ‘€ Author

Peter Thiarara

🀝 Contributing

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

πŸ™ Acknowledgments

  • Flutter Team for the amazing framework
  • WordPress REST API Documentation
  • WebView Flutter plugin contributors
  • All contributors who help improve this project

πŸ“ž Support

For issues, questions, or feature requests:

  • GitHub Issues: Create an issue
  • Documentation: Check the code comments and inline documentation
  • Community: Join discussions in the repository

Built with ❀️ using Flutter

About

WordPress News App is a modern Flutter application designed to deliver news content from WordPress sites. It offers a seamless and engaging experience for reading and interacting with WordPress-based news content on mobile devices.

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published