zeba_academy_resource_library 1.0.0
zeba_academy_resource_library: ^1.0.0 copied to clipboard
A Flutter resource library package with PDFs, videos, links, code snippets, favorites and offline access.
zeba_academy_resource_library #
A powerful Flutter package for creating a complete learning resource library.
zeba_academy_resource_library helps developers build educational apps with support for PDFs, videos, links, code examples, favorites, and offline access.
✨ About Me #
✨ I’m Sufyan bin Uzayr, an open-source developer passionate about building and sharing meaningful projects.
Learn more about my work:
LinkedIn:
https://www.linkedin.com/in/sufyanism
🚀 Zeba Academy #
Your all-in-one learning hub!
Explore courses and resources in:
- Coding
- Technology
- Development
- Programming
Build practical skills through:
- Curated tutorials
- Real-world projects
- Hands-on learning
- Developer resources
Main Website:
Coding Resources:
YouTube:
https://www.youtube.com/@zeba.academy
Instagram:
https://www.instagram.com/zeba.academy/
📦 Installation #
Add dependency:
dependencies:
zeba_academy_resource_library:
git:
url: https://github.com/your_username/zeba_academy_resource_library.git
Run:
flutter pub get
✨ Features #
📄 PDF Resources #
Display PDF learning materials.
Example:
ResourceModel(
id: "pdf_01",
title: "Flutter Guide",
description: "Flutter learning PDF",
type: ResourceType.pdf,
url: "https://example.com/flutter.pdf",
);
🎬 Video Resources #
Support video lessons.
ResourceModel(
id:"video_01",
title:"Flutter Course",
description:"Complete Flutter Course",
type:ResourceType.video,
url:"https://example.com/video.mp4",
);
🔗 Link Resources #
Open external resources.
ResourceModel(
id:"link_01",
title:"Flutter Docs",
description:"Official documentation",
type:ResourceType.link,
url:"https://flutter.dev",
);
💻 Code Snippets #
Display programming examples.
ResourceModel(
id:"code_01",
title:"Dart Example",
description:"Sample code",
type:ResourceType.code,
url:"void main(){print('Hello');}",
);
⭐ Favorites #
Save favorite resources locally.
Add:
await FavoriteService()
.add("resource_id");
Get:
final favorites =
await FavoriteService()
.getFavorites();
Remove:
await FavoriteService()
.remove("resource_id");
📥 Offline Access #
Download resources for offline usage.
final offline =
OfflineService();
final path =
await offline.downloadFile(
"https://example.com/file.pdf",
"file.pdf"
);
Check file:
await offline.exists(path);
🧱 Resource Types #
Available:
enum ResourceType {
pdf,
video,
link,
code,
}
🎨 Resource Card #
Create reusable resource cards:
ResourceCard(
resource: resource,
onTap:(){
}
);
📖 Resource Viewer #
Open resources automatically:
Navigator.push(
context,
MaterialPageRoute(
builder:(_)=>
ResourceView(
resource:resource,
)
)
);
Automatically handles:
✅ PDF ✅ Video ✅ Link ✅ Code
🏗️ Project Structure #
lib/
├── models/
│ └── resource_model.dart
├── services/
│ ├── favorite_service.dart
│ └── offline_service.dart
├── widgets/
│ ├── resource_card.dart
│ └── code_view.dart
├── screens/
│ ├── resource_view.dart
│ └── pdf_view.dart
└── zeba_academy_resource_library.dart
🔧 Dependencies #
This package uses:
- syncfusion_flutter_pdfviewer
- video_player
- url_launcher
- shared_preferences
- dio
- path_provider
🧪 Testing #
Run tests:
flutter test
Analyze:
flutter analyze
🤝 Contributing #
Contributions are welcome.
Steps:
git checkout -b feature/new-feature
git commit -m "Add feature"
git push origin feature/new-feature
Create a Pull Request.
📜 License #
Licensed under:
GNU General Public License v3.0
You can:
✅ Use ✅ Modify ✅ Distribute ✅ Improve
Conditions:
- Keep source available
- Keep GPL license
- Preserve copyright
❤️ Support #
If this package helps you:
⭐ Star the repository
🐛 Report issues
💡 Suggest improvements
Built with ❤️ using Flutter.
© Sufyan bin Uzayr