chore: update lerna configuration formatting
chore: bump version in package.json to 6.0.0
fix: modify build scripts for improved readability and consistency
feat: enhance translation scripts with better error handling and progress tracking
chore: improve plugin creation script for better user experience
style: format svgo configuration for consistency
- Created a new documentation file for the danmuku plugin with code examples.
- Added comprehensive language settings documentation, including default languages, importing languages, adding new languages, and modifying existing languages.
- Updated the i18n setup examples to reflect the latest changes in language handling.
- Introduced a new dataset attribute `data-id` to DOM elements for unique identification of danmuku items.
- Updated validation to include an optional `id` field for danmuku objects.
- Changed the property `$id` to `$index` for better clarity on its purpose as an index rather than a unique identifier.
- Ensured the `data-id` attribute is set for visibility control during hover interactions.
Refactor utility functions for improved readability and consistency
- Updated compatibility.js to use consistent line endings and formatting.
- Refactored component.js for better readability and structure, including consistent use of arrow functions and binding.
- Simplified dom.js functions with consistent formatting and improved readability.
- Enhanced emitter.js with consistent formatting and arrow function usage.
- Streamlined error.js for improved readability and consistency.
- Refactored file.js to use consistent formatting and improved readability.
- Improved format.js functions for better readability and consistency.
- Updated index.js to maintain consistent export formatting.
- Refactored property.js for improved readability and consistency.
- Enhanced subtitle.js with consistent formatting and improved readability.
- Refactored time.js for better readability and consistent formatting.
fix: update lint script to target only source files for consistency
Revert "fix: restore export statements for various plugins and update type definitions for better clarity"
This reverts commit b5e969d81ec765cd8a34b06e6ef4f232ef25087f.
fix: restore export statements for various plugins and update type definitions for better clarity
Refactor type definitions to use interfaces instead of type aliases for better extensibility and clarity across i18n, icons, option, player, quality, setting, subtitle, template, and utils modules.
- Replaced direct usage of event.composedPath() with a new utility function getComposedPath in Control component.
- Updated includeFromEvent function to utilize getComposedPath for better compatibility.
- Implemented getComposedPath function to ensure consistent event path retrieval across different browsers.
- Created a new documentation file for the danmuku plugin, detailing its usage and providing code examples.
- Added a comprehensive guide for language settings (i18n), including instructions for importing languages, setting default languages, and modifying language options.
- Included code snippets for initializing the Artplayer with different languages and examples for adding new languages.
- Simplified version display in context menu and template by directly importing version from package.json.
- Removed static version and environment methods from Artplayer class, replacing them with dynamic imports.
- Eliminated placeholder injection logic from build and dev scripts, streamlining the build process.
- Cleaned up build and dev scripts for better readability and maintainability.
- Updated the context menu version function to dynamically append the application version to the link and include a ref parameter in the URL.
- Removed the build version log from the initialization logs in the Artplayer class.
- Cleaned up the version and environment getters to return unquoted strings.
- Modified the config method to accept an initialization flag, allowing for configuration during the initial setup without triggering unnecessary updates.
- Updated the call to config in the constructor to pass the new initialization flag.
- Implemented an event listener for 'video:volumechange' to adjust the gain node's value based on the current volume of the artplayer instance.
- This enhancement ensures that the audio processing reflects the user's volume adjustments in real-time.
- Implemented pcmToWav function to convert PCM audio data to WAV format.
- Updated onAudioChunk callback to receive both PCM and WAV buffers.
- Modified TypeScript definitions to reflect changes in onAudioChunk parameter and append method.
- Renamed `hideTimeout` to `autoHideTimeout` for clarity.
- Updated the default options destructuring for better readability.
- Removed unnecessary comments and cleaned up the audio processing logic.
- Ensured that the audio buffer is processed correctly before sending to the `onAudioChunk` callback.
Refactor artplayerPluginAsr: Enhance audio capture and processing
- Introduced gainNode for audio output management.
- Added mediaStream and mediaStreamSource for fallback audio capture.
- Refactored startCapture and stopCapture functions for better clarity and error handling.
- Improved audio source setup with a dedicated function for capturing audio from video.
- Ensured proper disconnection of audio nodes and cleanup of resources on destroy.
feat: enhance ASR plugin with improved subtitle handling and styling
fix: rename autoClearTimer to hideTimer for consistency in ASR plugin
Update asr.js
feat: refactor ASR plugin to improve audio chunk handling and WebSocket management
Update asr.js
fix: rename autoClearTimeout to cleanupTimeout for consistency
Update asr.js
feat: refactor ASR handling and improve WebSocket management
Update index.js
feat: add append and clear functions to enhance audio chunk handling
Update asr.js
Update asr.js
feat: release version 2.0.0 of artplayer-plugin-asr
- Implemented core functionality for audio recording using AudioWorklet.
- Added support for configurable audio capture interval and sample rate.
- Introduced WAV encoding for recorded audio chunks.
- Created a new plugin structure with proper TypeScript definitions.
- Added legacy support for older environments.
- Updated package.json with necessary metadata and export configurations.
- Included comprehensive inline documentation for better maintainability.
- Moved the 'video:progress' event listener to be consistent with the RAF and timeupdate events.
- Ensured 'setBar' for 'loaded' is emitted during both RAF and video:progress events.
- Cleaned up the structure for better readability and maintainability.