diff --git a/CHANGELOG.md b/CHANGELOG.md index fc66a99..9441385 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,7 +11,7 @@ Summary ## 0.8.8 [2023.10.08] -- feat: support side panel for chrome extension(vanilla \ preact \ solid \ stencil \ svelte \ lit \ inferno) +- feat: support side panel for chrome extension(vanilla \ preact \ svelte) ## 0.8.7 [2023.10.03] diff --git a/package.json b/package.json index c89f810..dbd87d6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "create-chrome-ext", - "version": "0.8.7", + "version": "0.8.8", "type": "module", "description": "Scaffolding your chrome extension, multiple boilerplates supported!", "author": "yalda", diff --git a/template-preact-js/src/manifest.js b/template-preact-js/src/manifest.js index 476d049..54ea3b2 100644 --- a/template-preact-js/src/manifest.js +++ b/template-preact-js/src/manifest.js @@ -35,7 +35,5 @@ export default defineManifest({ matches: [], }, ], - permissions: [ - "sidePanel", - ], + permissions: ['sidePanel'], }) diff --git a/template-preact-ts/src/manifest.ts b/template-preact-ts/src/manifest.ts index 7089f75..bc1eee2 100644 --- a/template-preact-ts/src/manifest.ts +++ b/template-preact-ts/src/manifest.ts @@ -35,7 +35,5 @@ export default defineManifest({ matches: [], }, ], - permissions: [ - "sidePanel", - ], + permissions: ['sidePanel'], }) diff --git a/template-svelte-js/sidepanel.html b/template-svelte-js/sidepanel.html new file mode 100644 index 0000000..ebc0600 --- /dev/null +++ b/template-svelte-js/sidepanel.html @@ -0,0 +1,13 @@ + + + + + + + Chrome Extension + Svelte + JS + Vite App - Sidepanel + + +
+ + + diff --git a/template-svelte-js/src/manifest.js b/template-svelte-js/src/manifest.js index e41ff31..54ea3b2 100644 --- a/template-svelte-js/src/manifest.js +++ b/template-svelte-js/src/manifest.js @@ -26,11 +26,14 @@ export default defineManifest({ js: ['src/content/index.js'], }, ], + side_panel: { + default_path: 'sidepanel.html', + }, web_accessible_resources: [ { resources: ['img/logo-16.png', 'img/logo-34.png', 'img/logo-48.png', 'img/logo-128.png'], matches: [], }, ], - permissions: [], + permissions: ['sidePanel'], }) diff --git a/template-svelte-js/src/sidepanel/Sidepanel.svelte b/template-svelte-js/src/sidepanel/Sidepanel.svelte new file mode 100644 index 0000000..cd014f4 --- /dev/null +++ b/template-svelte-js/src/sidepanel/Sidepanel.svelte @@ -0,0 +1,56 @@ + + +
+

Side Panel Page!

+ +
v 0.0.0
+ + Power by {crx} +
+ + diff --git a/template-svelte-js/src/sidepanel/index.js b/template-svelte-js/src/sidepanel/index.js new file mode 100644 index 0000000..f89c087 --- /dev/null +++ b/template-svelte-js/src/sidepanel/index.js @@ -0,0 +1,7 @@ +import App from './Sidepanel.svelte' + +const app = new App({ + target: document.getElementById('app'), +}) + +export default app diff --git a/template-svelte-ts/sidepanel.html b/template-svelte-ts/sidepanel.html new file mode 100644 index 0000000..bab9a31 --- /dev/null +++ b/template-svelte-ts/sidepanel.html @@ -0,0 +1,13 @@ + + + + + + + Chrome Extension + Svelte + TS + Vite App - Sidepanel + + +
+ + + diff --git a/template-svelte-ts/src/manifest.ts b/template-svelte-ts/src/manifest.ts index 6e50228..bc1eee2 100644 --- a/template-svelte-ts/src/manifest.ts +++ b/template-svelte-ts/src/manifest.ts @@ -26,11 +26,14 @@ export default defineManifest({ js: ['src/content/index.ts'], }, ], + side_panel: { + default_path: 'sidepanel.html', + }, web_accessible_resources: [ { resources: ['img/logo-16.png', 'img/logo-34.png', 'img/logo-48.png', 'img/logo-128.png'], matches: [], }, ], - permissions: [], + permissions: ['sidePanel'], }) diff --git a/template-svelte-ts/src/sidepanel/Sidepanel.svelte b/template-svelte-ts/src/sidepanel/Sidepanel.svelte new file mode 100644 index 0000000..75f1492 --- /dev/null +++ b/template-svelte-ts/src/sidepanel/Sidepanel.svelte @@ -0,0 +1,56 @@ + + +
+

Side Panel Page!

+ +
v 0.0.0
+ + Power by {crx} +
+ + diff --git a/template-svelte-ts/src/sidepanel/index.ts b/template-svelte-ts/src/sidepanel/index.ts new file mode 100644 index 0000000..f89c087 --- /dev/null +++ b/template-svelte-ts/src/sidepanel/index.ts @@ -0,0 +1,7 @@ +import App from './Sidepanel.svelte' + +const app = new App({ + target: document.getElementById('app'), +}) + +export default app diff --git a/template-vanilla-js/src/manifest.js b/template-vanilla-js/src/manifest.js index 476d049..54ea3b2 100644 --- a/template-vanilla-js/src/manifest.js +++ b/template-vanilla-js/src/manifest.js @@ -35,7 +35,5 @@ export default defineManifest({ matches: [], }, ], - permissions: [ - "sidePanel", - ], + permissions: ['sidePanel'], }) diff --git a/template-vanilla-ts/src/manifest.ts b/template-vanilla-ts/src/manifest.ts index 7089f75..bc1eee2 100644 --- a/template-vanilla-ts/src/manifest.ts +++ b/template-vanilla-ts/src/manifest.ts @@ -35,7 +35,5 @@ export default defineManifest({ matches: [], }, ], - permissions: [ - "sidePanel", - ], + permissions: ['sidePanel'], })