fix: restore image paste and image tool-result handling (#308)

This commit is contained in:
KRATOS
2026-04-04 11:40:26 +05:30
committed by GitHub
parent 365bd3102d
commit c52245fc0a
7 changed files with 228 additions and 11 deletions

View File

@@ -0,0 +1,22 @@
import { expect, test } from 'bun:test'
import { supportsClipboardImageFallback } from './usePasteHandler.ts'
test('supports clipboard image fallback on Windows', () => {
expect(supportsClipboardImageFallback('windows')).toBe(true)
})
test('supports clipboard image fallback on macOS', () => {
expect(supportsClipboardImageFallback('macos')).toBe(true)
})
test('supports clipboard image fallback on Linux', () => {
expect(supportsClipboardImageFallback('linux')).toBe(true)
})
test('does not support clipboard image fallback on WSL', () => {
expect(supportsClipboardImageFallback('wsl')).toBe(false)
})
test('does not support clipboard image fallback on unknown platforms', () => {
expect(supportsClipboardImageFallback('unknown')).toBe(false)
})