youtube_video_player_original

Creator: coderz1093

Last updated:

0 purchases

youtube_video_player_original Image
youtube_video_player_original Images
Add to Cart

Description:

youtube video player original

Flutter YouTube Player #
A Flutter package for embedding a YouTube player with customizable controls and features.

Installation #
Add the following line to your pubspec.yaml file:
dependencies:
flutter_youtube_player: ^1.0.0
copied to clipboard
Then run:
flutter pub get
copied to clipboard
Usage #
Import the package in your Dart code:
import 'package:flutter_youtube_player/flutter_youtube_player.dart';
copied to clipboard
Use the PotraitPlayer widget to embed a YouTube player in your app:
PotraitPlayer(
link: 'YOUR_YOUTUBE_VIDEO_URL',
aspectRatio: 16 / 9, // Adjust the aspect ratio as needed
kColorWhite: Colors.white, // Optional: Customize color themes
kColorPrimary: Colors.orange,
kColorBlack: Colors.black,
);
copied to clipboard
Parameters #

link: The YouTube video URL.
aspectRatio: The aspect ratio of the player.
kColorWhite: (Optional) Color for elements with a white background.
kColorPrimary: (Optional) Primary color for buttons and progress bars.
kColorBlack: (Optional) Color for elements with a black background.

Features #

Play/Pause Controls: Tap on the video to toggle play/pause. Additional play/pause button available.
Brightness Control: Swipe vertically on the left side of the video to adjust brightness.
Volume Control: Swipe vertically on the right side of the video to adjust volume.
Seek Controls: Seek forward and backward by tapping on the respective buttons.
Fullscreen: Tap on the fullscreen button to switch to landscape mode.
Settings Popup: Tap on the settings button to access additional settings.

Example #
import 'package:flutter/material.dart';
import 'package:flutter_youtube_player/flutter_youtube_player.dart';

void main() {
runApp(MyApp());
}

class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
appBar: AppBar(
title: Text('YouTube Player Example'),
),
body: PotraitPlayer(
link: 'YOUR_YOUTUBE_VIDEO_URL',
aspectRatio: 16 / 9,
),
),
);
}
}
copied to clipboard
License #
This project is licensed under the MIT License - see the LICENSE file for details.

Replace YOUR_YOUTUBE_VIDEO_URL with the actual YouTube video URL you want to play. Additionally, consider adding more sections to the README, such as "Contributing," "Issues," and "Changelog," based on your project's needs.

License

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.