Skip to content

Commit 608a32c

Browse files
committed
initial commit
0 parents  commit 608a32c

30 files changed

Lines changed: 6356 additions & 0 deletions

.github/workflows/build.yml

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
name: Build
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
branches:
9+
- main
10+
11+
jobs:
12+
build:
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- name: Checkout code
17+
uses: actions/checkout@v4
18+
19+
- name: Setup Node.js
20+
uses: actions/setup-node@v4
21+
with:
22+
node-version: '20'
23+
24+
- name: Setup pnpm
25+
uses: pnpm/action-setup@v3
26+
with:
27+
version: 8
28+
29+
- name: Get pnpm store directory
30+
shell: bash
31+
run: |
32+
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
33+
34+
- name: Setup pnpm cache
35+
uses: actions/cache@v4
36+
with:
37+
path: ${{ env.STORE_PATH }}
38+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
39+
restore-keys: |
40+
${{ runner.os }}-pnpm-store-
41+
42+
- name: Install dependencies
43+
run: pnpm install --frozen-lockfile
44+
45+
- name: Type check
46+
run: pnpm type-check
47+
48+
- name: Build extension
49+
run: pnpm build
50+
51+
- name: Upload build artifact
52+
uses: actions/upload-artifact@v4
53+
with:
54+
name: extension-build
55+
path: dist/
56+
retention-days: 7

.github/workflows/release.yml

Lines changed: 109 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,109 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
8+
permissions:
9+
contents: write
10+
11+
jobs:
12+
build-and-release:
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- name: Checkout code
17+
uses: actions/checkout@v4
18+
19+
- name: Setup Node.js
20+
uses: actions/setup-node@v4
21+
with:
22+
node-version: '20'
23+
24+
- name: Setup pnpm
25+
uses: pnpm/action-setup@v3
26+
with:
27+
version: 8
28+
29+
- name: Get pnpm store directory
30+
shell: bash
31+
run: |
32+
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
33+
34+
- name: Setup pnpm cache
35+
uses: actions/cache@v4
36+
with:
37+
path: ${{ env.STORE_PATH }}
38+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
39+
restore-keys: |
40+
${{ runner.os }}-pnpm-store-
41+
42+
- name: Install dependencies
43+
run: pnpm install --frozen-lockfile
44+
45+
- name: Lint code
46+
run: pnpm lint
47+
48+
- name: Type check
49+
run: pnpm type-check
50+
51+
- name: Build extension
52+
run: pnpm build
53+
54+
- name: Create release archive
55+
run: |
56+
cd dist
57+
zip -r ../isekai-chrome-extension.zip .
58+
cd ..
59+
60+
- name: Extract version from tag
61+
id: get_version
62+
run: echo "VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_OUTPUT
63+
64+
- name: Verify manifest version matches tag
65+
run: |
66+
MANIFEST_VERSION=$(node -p "require('./src/manifest.json').version")
67+
TAG_VERSION="${{ steps.get_version.outputs.VERSION }}"
68+
echo "Manifest version: $MANIFEST_VERSION"
69+
echo "Tag version: $TAG_VERSION"
70+
if [ "$MANIFEST_VERSION" != "$TAG_VERSION" ]; then
71+
echo "Error: manifest.json version ($MANIFEST_VERSION) does not match tag version ($TAG_VERSION)"
72+
exit 1
73+
fi
74+
echo "Version check passed!"
75+
76+
- name: Create GitHub Release
77+
uses: softprops/action-gh-release@v1
78+
with:
79+
files: isekai-chrome-extension.zip
80+
generate_release_notes: true
81+
draft: false
82+
prerelease: false
83+
name: Release v${{ steps.get_version.outputs.VERSION }}
84+
body: |
85+
## Isekai Chrome Extension v${{ steps.get_version.outputs.VERSION }}
86+
87+
Browser extension to help artists manage DeviantArt exclusive sales efficiently.
88+
89+
### Installation
90+
91+
1. Download `isekai-chrome-extension.zip` below
92+
2. Extract to a permanent location on your computer
93+
3. Open `chrome://extensions/` in your browser
94+
4. Enable "Developer mode" (top-right toggle)
95+
5. Click "Load unpacked" and select the extracted folder
96+
6. Configure your API URL and API key
97+
98+
For detailed instructions, see the [Installation Guide](https://isekai.sh/chrome-extension/installation).
99+
100+
### Documentation
101+
102+
- [Installation](https://isekai.sh/chrome-extension/installation)
103+
- [Configuration](https://isekai.sh/chrome-extension/configuration)
104+
- [Usage Guide](https://isekai.sh/chrome-extension/usage)
105+
- [Troubleshooting](https://isekai.sh/chrome-extension/troubleshooting)
106+
107+
### What's Changed
108+
env:
109+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
node_modules/
2+
dist/
3+
.DS_Store
4+
*.log
5+
.vscode/
6+
.idea/

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2025 Isekai
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
# Isekai Chrome Extension
2+
3+
[![Release](https://img.shields.io/github/v/release/isekai-sh/isekai-chrome-extension?style=flat-square)](https://github.com/isekai-sh/isekai-chrome-extension/releases/latest)
4+
[![License](https://img.shields.io/github/license/isekai-sh/isekai-chrome-extension?style=flat-square)](https://github.com/isekai-sh/isekai-chrome-extension/blob/main/LICENSE)
5+
[![Build](https://img.shields.io/github/actions/workflow/status/isekai-sh/isekai-chrome-extension/release.yml?style=flat-square)](https://github.com/isekai-sh/isekai-chrome-extension/actions)
6+
[![Documentation](https://img.shields.io/badge/docs-isekai.sh-blue?style=flat-square)](https://isekai.sh/chrome-extension)
7+
8+
Browser extension to help artists manage DeviantArt exclusive sales efficiently. Works seamlessly with your [Isekai](https://isekai.sh) deployment.
9+
10+
## Purpose
11+
12+
DeviantArt's official API does not provide programmatic access to exclusive sales management. This extension bridges that gap for professional artists managing large portfolios. It operates respectfully - opening each page once, processing the form, and closing immediately, ensuring no unnecessary load on DeviantArt's servers.
13+
14+
## Features
15+
16+
- **Sales Management Assistant**: Helps you process exclusive sales from your organized queue
17+
- **Your Account**: Uses your actual DeviantArt login - you remain in control at all times
18+
- **Non-Intrusive**: Handles form filling in background tabs while you continue your work
19+
- **Activity Logs**: Detailed logging of all sales operations for business record-keeping
20+
- **Lightweight**: Just ~500KB browser extension, no additional software needed
21+
- **Secure**: Operates entirely in your browser using API key authentication
22+
23+
## Documentation
24+
25+
Complete documentation is available at [isekai.sh/chrome-extension](https://isekai.sh/chrome-extension):
26+
27+
- [Installation Guide](https://isekai.sh/chrome-extension/installation) - Install on Windows, macOS, or Linux
28+
- [Configuration](https://isekai.sh/chrome-extension/configuration) - Set up API URL and API key
29+
- [Usage Guide](https://isekai.sh/chrome-extension/usage) - Learn how to use the popup and console
30+
- [Troubleshooting](https://isekai.sh/chrome-extension/troubleshooting) - Common issues and solutions
31+
32+
## Quick Start
33+
34+
1. Download the latest release from [GitHub Releases](https://github.com/isekai-sh/isekai-chrome-extension/releases/latest)
35+
2. Extract the ZIP file to a permanent location
36+
3. Open `chrome://extensions/` in your browser
37+
4. Enable "Developer mode" (top-right toggle)
38+
5. Click "Load unpacked" and select the extracted folder
39+
6. Configure your API URL and API key in the extension settings
40+
7. Click Start to begin processing jobs
41+
42+
For detailed instructions, see the [Installation Guide](https://isekai.sh/chrome-extension/installation).
43+
44+
## Requirements
45+
46+
- Chrome, Edge, Brave, or any Chromium-based browser
47+
- Running [Isekai Core](https://github.com/isekai-sh/isekai-core) deployment
48+
- DeviantArt account (must be logged in)
49+
- API key from your Isekai instance
50+
51+
## Development
52+
53+
```bash
54+
# Install dependencies
55+
pnpm install
56+
57+
# Development mode with hot reload
58+
pnpm dev
59+
60+
# Build for production
61+
pnpm build
62+
63+
# Type check
64+
pnpm type-check
65+
```
66+
67+
## Architecture
68+
69+
- **Service Worker**: Background script that polls the backend API for pending jobs
70+
- **Content Script**: Injects into DeviantArt pages to perform DOM automation
71+
- **Popup**: Compact toolbar widget for quick status and controls
72+
- **Console**: Full-featured terminal interface for logs and job history
73+
74+
Built with TypeScript, Vite, and Chrome Extension Manifest V3.
75+
76+
## Support
77+
78+
- Documentation: [isekai.sh/chrome-extension](https://isekai.sh/chrome-extension)
79+
- Report Issues: [GitHub Issues](https://github.com/isekai-sh/isekai-chrome-extension/issues)
80+
- Main Project: [Isekai Core](https://github.com/isekai-sh/isekai-core)
81+
82+
## License
83+
84+
MIT - See [LICENSE](./LICENSE) file for details.

eslint.config.js

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
import tseslint from '@typescript-eslint/eslint-plugin';
2+
import tsparser from '@typescript-eslint/parser';
3+
4+
export default [
5+
{
6+
files: ['**/*.ts'],
7+
languageOptions: {
8+
parser: tsparser,
9+
parserOptions: {
10+
ecmaVersion: 'latest',
11+
sourceType: 'module',
12+
},
13+
},
14+
plugins: {
15+
'@typescript-eslint': tseslint,
16+
},
17+
rules: {
18+
'@typescript-eslint/no-unused-vars': ['error', {
19+
argsIgnorePattern: '^_',
20+
varsIgnorePattern: '^_',
21+
caughtErrorsIgnorePattern: '^_'
22+
}],
23+
'@typescript-eslint/no-explicit-any': 'off',
24+
'no-console': 'off',
25+
'no-debugger': 'error',
26+
},
27+
},
28+
{
29+
ignores: ['dist/', 'node_modules/', '*.config.js'],
30+
},
31+
];

package.json

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
{
2+
"name": "isekai-chrome-extension",
3+
"version": "1.0.0",
4+
"description": "Browser extension to help artists manage DeviantArt exclusive sales",
5+
"type": "module",
6+
"scripts": {
7+
"dev": "vite",
8+
"build": "vite build",
9+
"preview": "vite preview",
10+
"type-check": "tsc --noEmit",
11+
"lint": "eslint src/**/*.ts",
12+
"lint:fix": "eslint src/**/*.ts --fix"
13+
},
14+
"dependencies": {
15+
"lucide": "^0.562.0"
16+
},
17+
"devDependencies": {
18+
"@crxjs/vite-plugin": "^2.0.0-beta.25",
19+
"@types/chrome": "^0.0.268",
20+
"@types/node": "^20.11.5",
21+
"@typescript-eslint/eslint-plugin": "^8.50.1",
22+
"@typescript-eslint/parser": "^8.50.1",
23+
"eslint": "^9.39.2",
24+
"typescript": "^5.3.3",
25+
"vite": "^5.0.12"
26+
},
27+
"keywords": [
28+
"chrome-extension",
29+
"deviantart",
30+
"automation"
31+
],
32+
"author": "Isekai",
33+
"license": "MIT"
34+
}

0 commit comments

Comments
 (0)