Compare commits

..

1 Commits

Author SHA1 Message Date
Simon Pinfold
38458c518e feat(assets): include previews in bulk asset export (#12746)
## Summary

Set `include_previews: true` on bulk asset export so exported zips
include preview files, using the new option added to the cloud export
API.

## Changes

- **What**: Added `include_previews` to `AssetExportOptions` and pass
`true` from the bulk export path in `useMediaAssetActions`.

## Review Focus

Field name matches the updated cloud `AssetExportOptions` contract.
2026-06-10 03:03:00 +00:00
3 changed files with 5 additions and 2 deletions

View File

@@ -573,7 +573,8 @@ describe('useMediaAssetActions', () => {
expect(mockDownloadFile).not.toHaveBeenCalled()
expect(mockCreateAssetExport).toHaveBeenCalledWith({
job_ids: ['job1'],
naming_strategy: 'preserve'
naming_strategy: 'preserve',
include_previews: true
})
expect(mockTrackExport).toHaveBeenCalledWith('test-task-id')

View File

@@ -201,7 +201,8 @@ export function useMediaAssetActions() {
...(Object.keys(jobAssetNameFilters).length > 0
? { job_asset_name_filters: jobAssetNameFilters }
: {}),
naming_strategy: namingStrategy
naming_strategy: namingStrategy,
include_previews: true
})
assetExportStore.trackExport(result.task_id)

View File

@@ -50,6 +50,7 @@ interface AssetExportOptions {
| 'preserve'
| 'asset_id'
job_asset_name_filters?: Record<string, string[]>
include_previews?: boolean
}
/**