* modify MediaApi to support custom fetch implementation, defaults to native fetch
added an optional `fetcher` parameter to allow usage of a custom fetch function in both `upload` and `fetcher` methods. Defaults to the standard `fetch` if none is provided.
* fix tests and improve api fetcher types
* added permissions support for media module
introduced `MediaPermissions` for fine-grained access control in the media module, updated routes to enforce these permissions, and adjusted permission registration logic.
* fix: handle token absence in getUploadHeaders and add tests for transport modes
ensure getUploadHeaders does not set Authorization header when token is missing. Add unit tests to validate behavior for different token_transport options.
* remove console.log on DropzoneContainer.tsx
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Removed various commented-out code and replaced direct `console.log` and `console.warn` usage across the codebase with `$console` from "core" for standardized logging. Also adjusted linting rules in biome.json to enable warnings for `console.log` usage.
* refactored adapters to run test suites
* fix bun version for tests
* added missing adapter tests and refactored examples to use `bknd.config.ts` where applicable
* reorganized storage adapter and added test suites for adapter and fields
* added build command in ci pipeline
* updated workflow to also run node tests
* updated workflow: try with separate tasks
* updated workflow: try with separate tasks
* updated workflow: added tsx as dev dependency
* updated workflow: try with find instead of glob
Reworked `ensureEntity` to replace entities while maintaining their configuration and allowing type adjustments. Updated tests to verify type persistence and synchronization of entity properties.
Redesigned entity and index management with methods to streamline schema updates and added a sync flag to signal required DB syncs post-build. Enhanced test coverage and functionality for schema modifications, including support for additional fields.
Updated the logic to ensure media files are deleted from the filesystem alongside database entries when exceeding the maximum allowed items and enabled overwrite. Replaced IDs with file paths for proper file deletion.
Introduce `Media.*` to modularize and customize file upload handling. Refactor media-related components to improve usability, add max item limits, overwrite support, and event callbacks.