-
Notifications
You must be signed in to change notification settings - Fork 19
/
manifest.config.ts
72 lines (70 loc) · 1.78 KB
/
manifest.config.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
import { defineManifest } from '@crxjs/vite-plugin'
import packageJson from './package.json'
const { version } = packageJson
const [major, minor, patch, label = '0'] = version
.replace(/[^\d.-]+/g, '')
.split(/[.-]/)
export default defineManifest(async (env) => ({
name:
env.mode === 'staging'
? '[INTERNAL] Syncia'
: 'Syncia - Power of ChatGPT on any website',
description:
"Syncia is a browser extension that allows you to use Open AI's GPT in any website.",
version: `${major}.${minor}.${patch}.${label}`,
version_name: version,
action: {
default_title: 'Syncia - Open Sidebar',
},
commands: {
'open-sidebar': {
suggested_key: {
default: 'Ctrl+Shift+X',
mac: 'Command+Shift+X',
},
description: 'Open the sidebar',
},
},
externally_connectable: { ids: ['*'] },
manifest_version: 3,
icons: {
'16': 'images/icon-16.png',
'32': 'images/icon-32.png',
'48': 'images/icon-48.png',
'128': 'images/icon-128.png',
},
permissions: [
'storage',
'unlimitedStorage',
'contextMenus',
'tabs',
'activeTab',
],
background: {
service_worker: 'src/pages/background/index.ts',
},
content_scripts: [
{
matches: ['http://*/*', 'https://*/*', '<all_urls>'],
js: ['src/pages/content/sidebar.tsx'],
},
{
matches: ['http://*/*', 'https://*/*', '<all_urls>'],
js: [
'src/pages/content/quick-menu/initQuickMenu.tsx',
'src/pages/content/quick-menu/listenContextMenu.tsx',
],
all_frames: true,
},
],
web_accessible_resources: [
{
resources: [
'src/pages/sidebar/index.html',
'images/robot.png',
'src/pages/settings/index.html',
],
matches: ['http://*/*', 'https://*/*'],
},
],
}))