myetv-player 1.2.0 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/css/myetv-player.css +131 -0
  2. package/css/myetv-player.min.css +1 -1
  3. package/dist/myetv-player.js +547 -102
  4. package/dist/myetv-player.min.js +486 -93
  5. package/package.json +35 -17
  6. package/plugins/twitch/myetv-player-twitch-plugin.js +125 -11
  7. package/plugins/vimeo/myetv-player-vimeo.js +80 -49
  8. package/plugins/youtube/README.md +5 -2
  9. package/plugins/youtube/myetv-player-youtube-plugin.js +766 -6
  10. package/.github/workflows/codeql.yml +0 -100
  11. package/.github/workflows/npm-publish.yml +0 -30
  12. package/SECURITY.md +0 -50
  13. package/build.js +0 -195
  14. package/scss/README.md +0 -161
  15. package/scss/_audio-player.scss +0 -21
  16. package/scss/_base.scss +0 -116
  17. package/scss/_controls.scss +0 -204
  18. package/scss/_loading.scss +0 -111
  19. package/scss/_menus.scss +0 -432
  20. package/scss/_mixins.scss +0 -112
  21. package/scss/_poster.scss +0 -8
  22. package/scss/_progress-bar.scss +0 -319
  23. package/scss/_resolution.scss +0 -68
  24. package/scss/_responsive.scss +0 -1368
  25. package/scss/_themes.scss +0 -30
  26. package/scss/_title-overlay.scss +0 -60
  27. package/scss/_tooltips.scss +0 -7
  28. package/scss/_variables.scss +0 -49
  29. package/scss/_video.scss +0 -221
  30. package/scss/_volume.scss +0 -122
  31. package/scss/_watermark.scss +0 -128
  32. package/scss/myetv-player.scss +0 -51
  33. package/scss/package.json +0 -16
  34. package/src/README.md +0 -560
  35. package/src/chapters.js +0 -521
  36. package/src/controls.js +0 -1242
  37. package/src/core.js +0 -1922
  38. package/src/events.js +0 -537
  39. package/src/fullscreen.js +0 -82
  40. package/src/i18n.js +0 -374
  41. package/src/playlist.js +0 -177
  42. package/src/plugins.js +0 -384
  43. package/src/quality.js +0 -963
  44. package/src/streaming.js +0 -346
  45. package/src/subtitles.js +0 -524
  46. package/src/utils.js +0 -65
  47. package/src/watermark.js +0 -246
@@ -1,100 +0,0 @@
1
- # For most projects, this workflow file will not need changing; you simply need
2
- # to commit it to your repository.
3
- #
4
- # You may wish to alter this file to override the set of languages analyzed,
5
- # or to provide custom queries or build logic.
6
- #
7
- # ******** NOTE ********
8
- # We have attempted to detect the languages in your repository. Please check
9
- # the `language` matrix defined below to confirm you have the correct set of
10
- # supported CodeQL languages.
11
- #
12
- name: "CodeQL Advanced"
13
-
14
- on:
15
- push:
16
- branches: [ "main" ]
17
- pull_request:
18
- branches: [ "main" ]
19
- schedule:
20
- - cron: '29 21 * * 0'
21
-
22
- jobs:
23
- analyze:
24
- name: Analyze (${{ matrix.language }})
25
- # Runner size impacts CodeQL analysis time. To learn more, please see:
26
- # - https://gh.io/recommended-hardware-resources-for-running-codeql
27
- # - https://gh.io/supported-runners-and-hardware-resources
28
- # - https://gh.io/using-larger-runners (GitHub.com only)
29
- # Consider using larger runners or machines with greater resources for possible analysis time improvements.
30
- runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
31
- permissions:
32
- # required for all workflows
33
- security-events: write
34
-
35
- # required to fetch internal or private CodeQL packs
36
- packages: read
37
-
38
- # only required for workflows in private repositories
39
- actions: read
40
- contents: read
41
-
42
- strategy:
43
- fail-fast: false
44
- matrix:
45
- include:
46
- - language: actions
47
- build-mode: none
48
- - language: javascript-typescript
49
- build-mode: none
50
- # CodeQL supports the following values keywords for 'language': 'actions', 'c-cpp', 'csharp', 'go', 'java-kotlin', 'javascript-typescript', 'python', 'ruby', 'rust', 'swift'
51
- # Use `c-cpp` to analyze code written in C, C++ or both
52
- # Use 'java-kotlin' to analyze code written in Java, Kotlin or both
53
- # Use 'javascript-typescript' to analyze code written in JavaScript, TypeScript or both
54
- # To learn more about changing the languages that are analyzed or customizing the build mode for your analysis,
55
- # see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/customizing-your-advanced-setup-for-code-scanning.
56
- # If you are analyzing a compiled language, you can modify the 'build-mode' for that language to customize how
57
- # your codebase is analyzed, see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages
58
- steps:
59
- - name: Checkout repository
60
- uses: actions/checkout@v4
61
-
62
- # Add any setup steps before running the `github/codeql-action/init` action.
63
- # This includes steps like installing compilers or runtimes (`actions/setup-node`
64
- # or others). This is typically only required for manual builds.
65
- # - name: Setup runtime (example)
66
- # uses: actions/setup-example@v1
67
-
68
- # Initializes the CodeQL tools for scanning.
69
- - name: Initialize CodeQL
70
- uses: github/codeql-action/init@v3
71
- with:
72
- languages: ${{ matrix.language }}
73
- build-mode: ${{ matrix.build-mode }}
74
- # If you wish to specify custom queries, you can do so here or in a config file.
75
- # By default, queries listed here will override any specified in a config file.
76
- # Prefix the list here with "+" to use these queries and those in the config file.
77
-
78
- # For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
79
- # queries: security-extended,security-and-quality
80
-
81
- # If the analyze step fails for one of the languages you are analyzing with
82
- # "We were unable to automatically build your code", modify the matrix above
83
- # to set the build mode to "manual" for that language. Then modify this step
84
- # to build your code.
85
- # ℹ️ Command-line programs to run using the OS shell.
86
- # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
87
- - if: matrix.build-mode == 'manual'
88
- shell: bash
89
- run: |
90
- echo 'If you are using a "manual" build mode for one or more of the' \
91
- 'languages you are analyzing, replace this with the commands to build' \
92
- 'your code, for example:'
93
- echo ' make bootstrap'
94
- echo ' make release'
95
- exit 1
96
-
97
- - name: Perform CodeQL Analysis
98
- uses: github/codeql-action/analyze@v3
99
- with:
100
- category: "/language:${{matrix.language}}"
@@ -1,30 +0,0 @@
1
- name: Node.js Package
2
-
3
- on:
4
- release:
5
- types: [created]
6
-
7
- jobs:
8
- build:
9
- runs-on: ubuntu-latest
10
- steps:
11
- - uses: actions/checkout@v4
12
- - uses: actions/setup-node@v4
13
- with:
14
- node-version: 20
15
- - run: npm ci # 'npm ci or npm install'
16
- - run: npm test
17
-
18
- publish-npm:
19
- needs: build
20
- runs-on: ubuntu-latest
21
- steps:
22
- - uses: actions/checkout@v4
23
- - uses: actions/setup-node@v4
24
- with:
25
- node-version: 20
26
- registry-url: https://registry.npmjs.org/
27
- - run: npm ci # 'npm ci or npm install'
28
- - run: npm publish
29
- env:
30
- NODE_AUTH_TOKEN: ${{secrets.npm_token}}
package/SECURITY.md DELETED
@@ -1,50 +0,0 @@
1
- # Security Policy
2
-
3
- ## Supported Versions
4
-
5
- Use this section to tell people about which versions of your project are
6
- currently being supported with security updates.
7
-
8
- | Version | Supported |
9
- | ------- | ------------------ |
10
- | 1.x.x | :white_check_mark: |
11
-
12
- ## Reporting a Vulnerability
13
-
14
- We take the security of MYETV Video Player seriously. If you discover a security vulnerability, please report it responsibly.
15
-
16
- ### How to Report
17
-
18
- **Please do not report security vulnerabilities through public GitHub issues.**
19
-
20
- Instead, please report them via one of the following methods:
21
- - The best way is: open a ticket here: [https://support.myetv.tv](https://support.myetv.tv)
22
- - Use GitHub's private vulnerability reporting feature in the Security tab of this repository
23
- - Email: admin@myetv.tv (This method is susceptible to email provider security like spam or otherwise)
24
-
25
- ### What to Include
26
-
27
- To help us better understand and resolve the issue, please include:
28
- - A clear description of the vulnerability
29
- - Steps to reproduce the issue
30
- - Affected versions of MYETV Video Player
31
- - Potential impact and severity assessment
32
- - Any suggested fixes or patches (if available)
33
- - Your environment details (browser, OS, etc.)
34
-
35
- ### Response Timeline
36
-
37
- - **Acknowledgment:** We will confirm receipt of your report within **48 hours**
38
- - **Initial Assessment:** We will provide an initial evaluation within **7 days**
39
- - **Progress Updates:** We will keep you informed about the progress of resolving the issue
40
- - **Resolution:** Once a fix is developed, we will coordinate the release and disclosure timeline with you
41
-
42
- ### Disclosure Policy
43
-
44
- We follow responsible disclosure principles:
45
- - Please allow us reasonable time to investigate and fix the vulnerability before public disclosure
46
- - We will credit you in the security advisory (unless you prefer to remain anonymous)
47
- - Once the fix is released, we will publish a security advisory with details about the vulnerability
48
- - We appreciate your cooperation in keeping MYETV users safe
49
-
50
- Thank you for helping to keep MYETV Video Player secure!
package/build.js DELETED
@@ -1,195 +0,0 @@
1
- // Build script for MYETV Video Player
2
- const fs = require('fs');
3
- const path = require('path');
4
- const { exec } = require('child_process');
5
- const util = require('util');
6
- const execPromise = util.promisify(exec);
7
-
8
- const srcDir = './src';
9
- const outputFile = './dist/myetv-player.js';
10
- const scssDir = './scss';
11
- const cssOutputFile = './css/myetv-player.css';
12
- const cssMinOutputFile = './css/myetv-player.min.css';
13
- const scssMainFile = './scss/myetv-player.scss';
14
-
15
- // Module order for correct concatenation
16
- const moduleOrder = [
17
- 'core.js',
18
- 'events.js',
19
- 'controls.js',
20
- 'quality.js',
21
- 'subtitles.js',
22
- 'chapters.js',
23
- 'fullscreen.js',
24
- 'playlist.js',
25
- 'watermark.js',
26
- 'streaming.js',
27
- 'plugins.js',
28
- 'utils.js'
29
- ];
30
-
31
- // ===================================
32
- // SCSS BUILD FUNCTION
33
- // ===================================
34
- async function buildSCSS() {
35
- console.log('\n📦 Building SCSS files...');
36
- if (!fs.existsSync(scssDir)) {
37
- console.log('⚠️ SCSS directory not found, skipping CSS build');
38
- return;
39
- }
40
- if (!fs.existsSync(scssMainFile)) {
41
- console.log('⚠️ Main SCSS file not found, skipping CSS build');
42
- return;
43
- }
44
- const cssDir = path.dirname(cssOutputFile);
45
- if (!fs.existsSync(cssDir)) {
46
- fs.mkdirSync(cssDir, { recursive: true });
47
- console.log(`✓ Created directory: ${cssDir}`);
48
- }
49
- try {
50
- console.log('Compiling SCSS to CSS (expanded)...');
51
- await execPromise(`npx sass --style=expanded --no-source-map ${scssMainFile} ${cssOutputFile}`);
52
- const stats1 = fs.statSync(cssOutputFile);
53
- const fileSize1KB = (stats1.size / 1024).toFixed(2);
54
- console.log(`✓ CSS (expanded) created: ${cssOutputFile}`);
55
- console.log(` File size: ${fileSize1KB} KB`);
56
- console.log('Compiling SCSS to CSS (minified)...');
57
- await execPromise(`npx sass --style=compressed --no-source-map ${scssMainFile} ${cssMinOutputFile}`);
58
- const stats2 = fs.statSync(cssMinOutputFile);
59
- const fileSize2KB = (stats2.size / 1024).toFixed(2);
60
- const savings = ((1 - stats2.size / stats1.size) * 100).toFixed(1);
61
- console.log(`✓ CSS (minified) created: ${cssMinOutputFile}`);
62
- console.log(` File size: ${fileSize2KB} KB (${savings}% smaller)`);
63
- console.log('\n✓ SCSS build completed successfully!');
64
- } catch (error) {
65
- if (error.message.includes('sass: not found') || error.message.includes('command not found')) {
66
- console.log('\n⚠️ Sass compiler not found!');
67
- console.log('Install with: npm install -g sass');
68
- console.log('Or add to package.json: npm install --save-dev sass');
69
- console.log('\nSkipping CSS build for now...\n');
70
- } else {
71
- console.error('✗ SCSS build failed:', error.message);
72
- throw error;
73
- }
74
- }
75
- }
76
-
77
- // ===================================
78
- // JAVASCRIPT BUILD FUNCTION
79
- // ===================================
80
- function buildJavaScript() {
81
- console.log('\n📦 Building MYETV Video Player from modular source...');
82
- let output = '// MYETV Video Player - Javascript\n';
83
- output += '// Created by https://www.myetv.tv https://oskarcosimo.com\n\n';
84
- const i18nPath = path.join(srcDir, 'i18n.js');
85
- if (fs.existsSync(i18nPath)) {
86
- console.log('Processing i18n.js...');
87
- let i18nContent = fs.readFileSync(i18nPath, 'utf8');
88
- i18nContent = i18nContent.replace(/^\/\/ i18n Module for MYETV Video Player[\s\S]*?Created by.*?\n\n/m, '')
89
- .replace(/export default VideoPlayerI18n;\s*$/m, '').trim();
90
- output += i18nContent + '\n\n';
91
- }
92
- let pluginsGlobalCode = '';
93
- const pluginsPath = path.join(srcDir, 'plugins.js');
94
- if (fs.existsSync(pluginsPath)) {
95
- console.log('Extracting global plugin code...');
96
- const pluginsContent = fs.readFileSync(pluginsPath, 'utf8');
97
- const globalMatch = pluginsContent.match(/\/\* GLOBAL_START \*\/([\s\S]*?)\/\* GLOBAL_END \*\//);
98
- if (globalMatch) {
99
- pluginsGlobalCode = globalMatch[1].trim() + '\n\n';
100
- console.log('✓ Global plugin code extracted');
101
- }
102
- }
103
- if (pluginsGlobalCode) {
104
- output += '// Plugin System - Global Code\n';
105
- output += pluginsGlobalCode;
106
- }
107
- output += 'class MYETVvideoplayer {\n';
108
- moduleOrder.forEach((moduleFile, index) => {
109
- const filePath = path.join(srcDir, moduleFile);
110
- if (fs.existsSync(filePath)) {
111
- console.log(`Processing ${moduleFile}... (${index + 1}/${moduleOrder.length})`);
112
- let content = fs.readFileSync(filePath, 'utf8');
113
- content = content.replace(/^\/\/.*Module for MYETV Video Player[\s\S]*?Created by.*?\n\n/m, '')
114
- .replace(/\/\/ .*methods for main class[\s\S]*$/m, '').trim();
115
- if (moduleFile === 'plugins.js') {
116
- content = content.replace(/\/\* GLOBAL_START \*\/[\s\S]*?\/\* GLOBAL_END \*\//m, '').trim();
117
- }
118
- if (content.length > 0) {
119
- output += '\n' + content + '\n';
120
- }
121
- } else {
122
- console.warn(`Warning: ${moduleFile} not found, skipping...`);
123
- }
124
- });
125
- output += '\n}\n\n';
126
- output += '// Export for module systems\n';
127
- output += 'if (typeof module !== \"undefined\" && module.exports) {\n';
128
- output += ' module.exports = MYETVvideoplayer;\n';
129
- output += '}\n';
130
- output += 'if (typeof define === \"function\" && define.amd) {\n';
131
- output += ' define([], function() { return MYETVvideoplayer; });\n';
132
- output += '}\n';
133
- const distDir = path.dirname(outputFile);
134
- if (!fs.existsSync(distDir)) {
135
- fs.mkdirSync(distDir, { recursive: true });
136
- }
137
- fs.writeFileSync(outputFile, output);
138
- console.log('✓ JavaScript build completed successfully!');
139
- console.log(`✓ Output file: ${outputFile}`);
140
- console.log(`✓ File size: ${(output.length / 1024).toFixed(2)} KB`);
141
- console.log(`✓ Total lines: ${output.split('\\n').length.toLocaleString()}`);
142
- }
143
-
144
- // ===================================
145
- // NATIVE JS MINIFICATION FUNCTION
146
- // ===================================
147
- function minifyJSNative() {
148
- const jsFile = './dist/myetv-player.js';
149
- const minFile = './dist/myetv-player.min.js';
150
-
151
- try {
152
- let code = fs.readFileSync(jsFile, 'utf8');
153
-
154
- code = code.replace(/\/\*[\s\S]*?\*\//g, '');
155
- code = code.replace(/^\s*\/\/.*$/gm, '');
156
-
157
- code = code.replace(/\n\s*\n\s*\n/g, '\n\n');
158
-
159
- code = code.replace(/ +/g, ' ');
160
-
161
- fs.writeFileSync(minFile, code);
162
- console.log(`✓ JS (minified native) created: ${minFile}`);
163
- console.log(` File size: ${(code.length / 1024).toFixed(2)} KB`);
164
- } catch (err) {
165
- console.log('✗ Native JS minification failed:', err.message);
166
- }
167
- }
168
-
169
- // ===================================
170
- // MAIN BUILD PROCESS
171
- // ===================================
172
- async function build() {
173
- console.log('\\n========================================');
174
- console.log(' MYETV Video Player - Build Script');
175
- console.log('========================================\\n');
176
- try {
177
- buildJavaScript();
178
- minifyJSNative();
179
- await buildSCSS();
180
- console.log('\\n========================================');
181
- console.log(' ✨ Build completed successfully!');
182
- console.log('========================================');
183
- console.log('\\n📄 Generated files:');
184
- console.log(' JavaScript: dist/myetv-player.js');
185
- console.log(' JavaScript: dist/myetv-player.min.js');
186
- console.log(' CSS (dev): css/myetv-player.css');
187
- console.log(' CSS (prod): css/myetv-player.min.css\\n');
188
- } catch (error) {
189
- console.error('\\n✗ Build failed:', error.message);
190
- process.exit(1);
191
- }
192
- }
193
-
194
- // Run the build
195
- build();
package/scss/README.md DELETED
@@ -1,161 +0,0 @@
1
- # MYETV Video Player - SCSS Files
2
-
3
- ## 📁 File Structure
4
-
5
- ```
6
- myetv-player/
7
- ├── scss/
8
- │ ├── myetv-player.scss # Main file
9
- │ ├── _variables.scss # Variables (colors, sizes, etc.)
10
- │ ├── _mixins.scss # Reusable mixins
11
- │ ├── _base.scss # Base styles
12
- │ ├── _video.scss # Video element
13
- │ ├── _loading.scss # Loading overlay
14
- │ ├── _title-overlay.scss # Title overlay
15
- │ ├── _controls.scss # Player controls
16
- │ ├── _progress-bar.scss # Progress bar
17
- │ ├── _volume.scss # Volume controls
18
- │ ├── _menus.scss # Dropdown menus
19
- │ ├── _poster.scss # Video poster
20
- │ ├── _watermark.scss # Watermark
21
- │ ├── _tooltips.scss # Tooltip system
22
- │ ├── _audio-player.scss # Player for only audio files
23
- │ ├── _themes.scss # Alternative themes
24
- │ ├── _resolution.scss # Display modes
25
- │ └── _responsive.scss # Media queries
26
- ├── package.json
27
- └── README.md
28
- ```
29
-
30
- ## Installation
31
-
32
- ### 1. Install Node.js
33
- Download and install Node.js from [nodejs.org](https://nodejs.org)
34
-
35
- ### 2. Install Sass
36
- ```bash
37
- npm install
38
- ```
39
-
40
- Or install Sass globally:
41
- ```bash
42
- npm install -g sass
43
- ```
44
-
45
- ## Compilation
46
-
47
- ### Development (with watch mode)
48
- ```bash
49
- npm run scss:watch
50
- ```
51
- This command watches SCSS files and recompiles automatically when changed.
52
-
53
- ### Production (minified)
54
- ```bash
55
- npm run scss:prod
56
- ```
57
- Generates a minified CSS file for production.
58
-
59
- ### Single compilation
60
- ```bash
61
- npm run scss
62
- ```
63
-
64
- ### Manual compilation
65
- ```bash
66
- sass myetv-player.scss myetv-player.css
67
- ```
68
-
69
- ## How to Add Features
70
-
71
- ### 1. Modify Variables
72
- Open `_variables.scss` and modify the values:
73
- ```scss
74
- $player-primary-color: #4a90e2 !default; // Change primary color
75
- $player-icon-size: 24px !default; // Change icon size
76
- ```
77
-
78
- ### 2. Add New Components
79
- Create a new file `_component-name.scss` and import it into `myetv-player.scss`:
80
- ```scss
81
- @import 'component-name';
82
- ```
83
-
84
- ### 3. Create New Themes
85
- Open `_themes.scss` and add:
86
- ```scss
87
- .video-wrapper.theme-custom {
88
- --player-primary-color: #your-color;
89
- --player-primary-hover: #your-hover-color;
90
- }
91
- ```
92
-
93
- ### 4. Modify Responsive Breakpoints
94
- Open `_mixins.scss` and customize the breakpoints:
95
- ```scss
96
- @mixin tablet {
97
- @media (max-width: 768px) {
98
- @content;
99
- }
100
- }
101
- ```
102
-
103
- ## Best Practices
104
-
105
- 1. **Do not modify compiled CSS** - Always work on SCSS files
106
- 2. **Use variables** - For reusable values, create variables in `_variables.scss`
107
- 3. **Create mixins** - For repeated patterns, add mixins in `_mixins.scss`
108
- 4. **Keep files small** - Each file should handle a single component
109
- 5. **Test on multiple browsers** - Verify cross-browser compatibility
110
-
111
- ## Quick Customization
112
-
113
- ### Change Primary Color
114
- ```scss
115
- // In _variables.scss
116
- $player-primary-color: #e74c3c !default; // Red
117
- ```
118
-
119
- ### Add New Button
120
- ```scss
121
- // In _controls.scss
122
- .custom-button {
123
- @include button-hover;
124
- // Your styles
125
- }
126
- ```
127
-
128
- ### Create Custom Menu
129
- ```scss
130
- // In _menus.scss
131
- .custom-menu {
132
- @include menu-base;
133
- // Your additional styles
134
- }
135
- ```
136
-
137
- ## Output
138
-
139
- After compilation you will get:
140
- - `myetv-player.css` - Complete CSS file
141
- - `myetv-player.min.css` - Minified CSS file for production
142
- - `myetv-player.css.map` - Source map for debugging (with --source-map)
143
-
144
- ## Debug
145
-
146
- If you use watch mode with source map:
147
- ```bash
148
- npm run scss:dev
149
- ```
150
-
151
- You can see the original SCSS styles in the browser during debug.
152
-
153
- ## Support
154
-
155
- For questions or issues:
156
- - Website: [https://www.myetv.tv](https://www.myetv.tv)
157
- - Developer: [https://oskarcosimo.com](https://oskarcosimo.com)
158
-
159
- ---
160
-
161
- **Happy Coding!**
@@ -1,21 +0,0 @@
1
- .audio-player {
2
- width: 320px;
3
- height: 80px;
4
-
5
- video {
6
- display: none !important;
7
- }
8
-
9
- .controls-wrapper {
10
- height: 60px;
11
- }
12
-
13
- .audio-wave-canvas {
14
- display: block;
15
- width: 100%;
16
- height: 60px;
17
- background-color: #222;
18
- border-radius: 4px;
19
- margin-top: 5px;
20
- }
21
- }
package/scss/_base.scss DELETED
@@ -1,116 +0,0 @@
1
- // ===================================
2
- // BASE STYLES
3
- // ===================================
4
-
5
- :root {
6
- /* Main theme colors */
7
- --player-primary-color: goldenrod;
8
- --player-primary-hover: #daa520;
9
- --player-primary-dark: #b8860b;
10
- /* Control colors */
11
- --player-button-color: white;
12
- --player-button-hover: rgba(255, 255, 255, 0.1);
13
- --player-button-active: rgba(255, 255, 255, 0.2);
14
- /* Text colors */
15
- --player-text-color: white;
16
- --player-text-secondary: rgba(255, 255, 255, 0.8);
17
- /* Background and overlay */
18
- --player-bg-primary: #000;
19
- --player-bg-controls: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.8) 100%);
20
- --player-bg-title-overlay: linear-gradient(180deg, rgba(0, 0, 0, 0.8) 0%, transparent 100%);
21
- --player-bg-menu: rgba(20, 20, 20, 0.95);
22
- --player-bg-loading: rgba(0, 0, 0, 0.7);
23
- /* Dimensions */
24
- --player-border-radius: 12px;
25
- --player-controls-padding: 20px 15px 15px;
26
- --player-title-overlay-padding: 15px 20px 25px;
27
- --player-button-padding: 8px;
28
- --player-icon-size: 20px;
29
- /* Progress and Volume bars */
30
- --player-progress-height: 6px;
31
- --player-progress-bg: rgba(255, 255, 255, 0.2);
32
- --player-progress-buffer: rgba(255, 255, 255, 0.3);
33
- --player-progress-handle-size: 16px;
34
- --player-volume-height: 4px;
35
- --player-volume-bg: rgba(255, 255, 255, 0.2);
36
- --player-volume-handle-size: 14px;
37
- --player-volume-fill: 100%;
38
- /* Transitions */
39
- --player-transition-fast: 0.2s ease;
40
- --player-transition-normal: 0.3s ease;
41
- /* Shadows */
42
- --player-shadow-main: 0 8px 32px rgba(0, 0, 0, 0.3);
43
- --player-shadow-menu: 0 4px 16px rgba(0, 0, 0, 0.2);
44
- --player-shadow-tooltip: 0 3px 12px rgba(0, 0, 0, 0.4);
45
- }
46
-
47
-
48
- * {
49
- box-sizing: border-box;
50
- }
51
-
52
- body {
53
- margin: 0;
54
- padding: 20px;
55
- background: #1a1a1a;
56
- font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
57
- }
58
-
59
- .video-container {
60
- max-width: 1200px;
61
- margin: 0 auto;
62
- background: var(--player-bg-primary);
63
- border-radius: var(--player-border-radius);
64
- box-shadow: var(--player-shadow-main);
65
- position: relative;
66
- }
67
-
68
- .video-container:fullscreen,
69
- .video-container:-webkit-full-screen,
70
- .video-container:-moz-full-screen {
71
- width: 100vw;
72
- height: 100vh;
73
- border-radius: 0;
74
- }
75
-
76
- .video-wrapper {
77
- position: relative;
78
- width: 100%;
79
- background: var(--player-bg-primary);
80
- overflow: visible !important;
81
- }
82
-
83
- .video-wrapper.player-initialized .video-player {
84
- visibility: visible;
85
- opacity: 1;
86
- transition: opacity 0.3s ease;
87
- pointer-events: auto;
88
- }
89
-
90
- .video-wrapper.player-initialized .initial-loading {
91
- opacity: 0;
92
- visibility: hidden;
93
- transition: opacity 0.3s ease, visibility 0.3s ease;
94
- transition-delay: 0.2s;
95
- display: none;
96
- transition-delay: 0.5s;
97
- }
98
-
99
- .video-wrapper:not(.has-controls) .video-watermark.hide-on-autohide {
100
- visibility: hidden;
101
- opacity: 0;
102
- }
103
-
104
- .hidden {
105
- display: none !important;
106
- }
107
-
108
-
109
- /* DARK MODE THEME */
110
-
111
- .player-theme-dark {
112
- --player-bg-primary: #1a1a1a;
113
- --player-bg-controls: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.9) 100%);
114
- --player-bg-title-overlay: linear-gradient(180deg, rgba(30, 30, 30, 0.9) 0%, transparent 100%);
115
- --player-bg-menu: rgba(30, 30, 30, 0.95);
116
- }