mirror of
https://github.com/stablyai/orca.git
synced 2026-10-01 08:01:56 +00:00
* Add browser import hint button to the browser toolbar - Adds a dismissible "Import" button in the browser address bar that opens a popover with browser detection and one-click cookie import - Persists the hint's dismissed state via `browserImportHintHidden` in `PersistedUIState` so the hint stays hidden after the user clicks "Hide Hint" - Extracts platform-aware import source labels into `browser-cookie-import-sources.ts` and hint visibility logic into `browser-import-hint-visibility.ts` for isolated testing * fix the onblur for the import popover
36 lines
872 B
TypeScript
36 lines
872 B
TypeScript
import { describe, expect, it } from 'vitest'
|
|
import { getBrowserCookieImportSourceLabels } from './browser-cookie-import-sources'
|
|
|
|
describe('getBrowserCookieImportSourceLabels', () => {
|
|
it('includes mac-only sources on darwin', () => {
|
|
expect(getBrowserCookieImportSourceLabels('darwin')).toEqual([
|
|
'Google Chrome',
|
|
'Microsoft Edge',
|
|
'Arc',
|
|
'Brave',
|
|
'Comet',
|
|
'Firefox',
|
|
'Safari'
|
|
])
|
|
})
|
|
|
|
it('omits mac-only sources on Windows', () => {
|
|
expect(getBrowserCookieImportSourceLabels('win32')).toEqual([
|
|
'Google Chrome',
|
|
'Microsoft Edge',
|
|
'Brave',
|
|
'Comet',
|
|
'Firefox'
|
|
])
|
|
})
|
|
|
|
it('omits mac-only and Comet on Linux', () => {
|
|
expect(getBrowserCookieImportSourceLabels('linux')).toEqual([
|
|
'Google Chrome',
|
|
'Microsoft Edge',
|
|
'Brave',
|
|
'Firefox'
|
|
])
|
|
})
|
|
})
|