pdflinux 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +165 -0
- package/bin/pdflinux +31 -0
- package/index.html +13 -0
- package/install.sh +254 -0
- package/package.json +57 -0
- package/public/favicon.svg +1 -0
- package/public/icons.svg +24 -0
- package/src/App.tsx +68 -0
- package/src/assets/hero.png +0 -0
- package/src/assets/react.svg +1 -0
- package/src/assets/vite.svg +1 -0
- package/src/components/Dropzone.tsx +90 -0
- package/src/components/FileItem.tsx +27 -0
- package/src/components/ProgressBar.tsx +18 -0
- package/src/components/Sidebar.tsx +92 -0
- package/src/hooks/useTheme.ts +23 -0
- package/src/index.css +675 -0
- package/src/main.tsx +10 -0
- package/src/pages/Dashboard.tsx +71 -0
- package/src/pages/ImageToPdf.tsx +100 -0
- package/src/pages/PdfCompress.tsx +175 -0
- package/src/pages/PdfCrop.tsx +112 -0
- package/src/pages/PdfDeletePages.tsx +151 -0
- package/src/pages/PdfGrayscale.tsx +100 -0
- package/src/pages/PdfInfo.tsx +71 -0
- package/src/pages/PdfMerge.tsx +135 -0
- package/src/pages/PdfOcr.tsx +136 -0
- package/src/pages/PdfPageNumbers.tsx +155 -0
- package/src/pages/PdfProtect.tsx +171 -0
- package/src/pages/PdfReorder.tsx +145 -0
- package/src/pages/PdfRotate.tsx +89 -0
- package/src/pages/PdfSplit.tsx +147 -0
- package/src/pages/PdfToImage.tsx +134 -0
- package/src/pages/PdfToText.tsx +107 -0
- package/src/pages/PdfUnlock.tsx +79 -0
- package/src/pages/PdfWatermark.tsx +77 -0
- package/src-tauri/Cargo.lock +5347 -0
- package/src-tauri/Cargo.toml +32 -0
- package/src-tauri/build.rs +3 -0
- package/src-tauri/capabilities/default.json +14 -0
- package/src-tauri/icons/128x128.png +0 -0
- package/src-tauri/icons/128x128@2x.png +0 -0
- package/src-tauri/icons/32x32.png +0 -0
- package/src-tauri/icons/Square107x107Logo.png +0 -0
- package/src-tauri/icons/Square142x142Logo.png +0 -0
- package/src-tauri/icons/Square150x150Logo.png +0 -0
- package/src-tauri/icons/Square284x284Logo.png +0 -0
- package/src-tauri/icons/Square30x30Logo.png +0 -0
- package/src-tauri/icons/Square310x310Logo.png +0 -0
- package/src-tauri/icons/Square44x44Logo.png +0 -0
- package/src-tauri/icons/Square71x71Logo.png +0 -0
- package/src-tauri/icons/Square89x89Logo.png +0 -0
- package/src-tauri/icons/StoreLogo.png +0 -0
- package/src-tauri/icons/icon.icns +0 -0
- package/src-tauri/icons/icon.ico +0 -0
- package/src-tauri/icons/icon.png +0 -0
- package/src-tauri/src/lib.rs +48 -0
- package/src-tauri/src/main.rs +6 -0
- package/src-tauri/src/pdf_engine.rs +1022 -0
- package/src-tauri/tauri.conf.json +48 -0
- package/tsconfig.app.json +28 -0
- package/tsconfig.json +7 -0
- package/tsconfig.node.json +26 -0
- package/uninstall.sh +65 -0
- package/vite.config.ts +7 -0
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "../node_modules/@tauri-apps/cli/config.schema.json",
|
|
3
|
+
"productName": "PDFLinux",
|
|
4
|
+
"version": "0.1.0",
|
|
5
|
+
"identifier": "io.github.saaandbite.pdflinux",
|
|
6
|
+
"build": {
|
|
7
|
+
"frontendDist": "../dist",
|
|
8
|
+
"devUrl": "http://localhost:5173",
|
|
9
|
+
"beforeDevCommand": "npm run dev",
|
|
10
|
+
"beforeBuildCommand": "npm run build"
|
|
11
|
+
},
|
|
12
|
+
"app": {
|
|
13
|
+
"windows": [
|
|
14
|
+
{
|
|
15
|
+
"title": "PDFLinux",
|
|
16
|
+
"width": 1000,
|
|
17
|
+
"height": 680,
|
|
18
|
+
"minWidth": 800,
|
|
19
|
+
"minHeight": 560,
|
|
20
|
+
"resizable": true,
|
|
21
|
+
"fullscreen": false
|
|
22
|
+
}
|
|
23
|
+
],
|
|
24
|
+
"security": {
|
|
25
|
+
"csp": null
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"bundle": {
|
|
29
|
+
"active": true,
|
|
30
|
+
"targets": ["deb", "rpm", "appimage"],
|
|
31
|
+
"icon": [
|
|
32
|
+
"icons/32x32.png",
|
|
33
|
+
"icons/128x128.png",
|
|
34
|
+
"icons/128x128@2x.png",
|
|
35
|
+
"icons/icon.icns",
|
|
36
|
+
"icons/icon.ico"
|
|
37
|
+
],
|
|
38
|
+
"linux": {
|
|
39
|
+
"desktopFile": {
|
|
40
|
+
"Comment": "Privacy-first PDF tools untuk Linux — berjalan 100% offline",
|
|
41
|
+
"Categories": "Office;Utility;"
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
"category": "Utility",
|
|
45
|
+
"shortDescription": "Privacy-first PDF tools untuk Linux",
|
|
46
|
+
"longDescription": "A fast, privacy-first desktop application for all your everyday PDF tasks. Runs 100% offline — no files are uploaded anywhere."
|
|
47
|
+
}
|
|
48
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo",
|
|
4
|
+
"target": "ES2023",
|
|
5
|
+
"useDefineForClassFields": true,
|
|
6
|
+
"lib": ["ES2023", "DOM", "DOM.Iterable"],
|
|
7
|
+
"module": "ESNext",
|
|
8
|
+
"types": ["vite/client"],
|
|
9
|
+
"skipLibCheck": true,
|
|
10
|
+
|
|
11
|
+
/* Bundler mode */
|
|
12
|
+
"moduleResolution": "bundler",
|
|
13
|
+
"allowImportingTsExtensions": true,
|
|
14
|
+
"verbatimModuleSyntax": true,
|
|
15
|
+
"moduleDetection": "force",
|
|
16
|
+
"noEmit": true,
|
|
17
|
+
"jsx": "react-jsx",
|
|
18
|
+
|
|
19
|
+
/* Linting */
|
|
20
|
+
"strict": true,
|
|
21
|
+
"noUnusedLocals": true,
|
|
22
|
+
"noUnusedParameters": true,
|
|
23
|
+
"erasableSyntaxOnly": true,
|
|
24
|
+
"noFallthroughCasesInSwitch": true,
|
|
25
|
+
"noUncheckedSideEffectImports": true
|
|
26
|
+
},
|
|
27
|
+
"include": ["src"]
|
|
28
|
+
}
|
package/tsconfig.json
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo",
|
|
4
|
+
"target": "ES2023",
|
|
5
|
+
"lib": ["ES2023"],
|
|
6
|
+
"module": "ESNext",
|
|
7
|
+
"types": ["node"],
|
|
8
|
+
"skipLibCheck": true,
|
|
9
|
+
|
|
10
|
+
/* Bundler mode */
|
|
11
|
+
"moduleResolution": "bundler",
|
|
12
|
+
"allowImportingTsExtensions": true,
|
|
13
|
+
"verbatimModuleSyntax": true,
|
|
14
|
+
"moduleDetection": "force",
|
|
15
|
+
"noEmit": true,
|
|
16
|
+
|
|
17
|
+
/* Linting */
|
|
18
|
+
"strict": true,
|
|
19
|
+
"noUnusedLocals": true,
|
|
20
|
+
"noUnusedParameters": true,
|
|
21
|
+
"erasableSyntaxOnly": true,
|
|
22
|
+
"noFallthroughCasesInSwitch": true,
|
|
23
|
+
"noUncheckedSideEffectImports": true
|
|
24
|
+
},
|
|
25
|
+
"include": ["vite.config.ts"]
|
|
26
|
+
}
|
package/uninstall.sh
ADDED
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
set -euo pipefail
|
|
3
|
+
|
|
4
|
+
APP_NAME="pdflinux"
|
|
5
|
+
DISPLAY_NAME="PDFLinux"
|
|
6
|
+
|
|
7
|
+
RED='\033[0;31m'
|
|
8
|
+
GREEN='\033[0;32m'
|
|
9
|
+
BLUE='\033[0;34m'
|
|
10
|
+
NC='\033[0m'
|
|
11
|
+
|
|
12
|
+
info() { echo -e "${BLUE}[*]${NC} $*"; }
|
|
13
|
+
success() { echo -e "${GREEN}[✓]${NC} $*"; }
|
|
14
|
+
error() { echo -e "${RED}[✗]${NC} $*"; exit 1; }
|
|
15
|
+
|
|
16
|
+
detect_pkg_manager() {
|
|
17
|
+
if command -v apt &>/dev/null; then echo "apt"
|
|
18
|
+
elif command -v dnf &>/dev/null; then echo "dnf"
|
|
19
|
+
elif command -v yum &>/dev/null; then echo "yum"
|
|
20
|
+
elif command -v pacman &>/dev/null; then echo "pacman"
|
|
21
|
+
else echo "unknown"
|
|
22
|
+
fi
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
PM=$(detect_pkg_manager)
|
|
26
|
+
|
|
27
|
+
echo ""
|
|
28
|
+
echo -e "${RED}╔══════════════════════════════════╗${NC}"
|
|
29
|
+
echo -e "${RED}║ PDFLinux — Uninstall ║${NC}"
|
|
30
|
+
echo -e "${RED}╚══════════════════════════════════╝${NC}"
|
|
31
|
+
echo ""
|
|
32
|
+
|
|
33
|
+
# Hapus paket yang diinstal via package manager
|
|
34
|
+
case "$PM" in
|
|
35
|
+
apt)
|
|
36
|
+
if dpkg -l "pdf-tools" &>/dev/null 2>&1; then
|
|
37
|
+
info "Menghapus paket .deb..."
|
|
38
|
+
sudo apt-get remove -y pdf-tools || true
|
|
39
|
+
fi
|
|
40
|
+
;;
|
|
41
|
+
dnf|yum)
|
|
42
|
+
if rpm -q "pdf-tools" &>/dev/null 2>&1; then
|
|
43
|
+
info "Menghapus paket .rpm..."
|
|
44
|
+
sudo "$PM" remove -y pdf-tools || true
|
|
45
|
+
fi
|
|
46
|
+
;;
|
|
47
|
+
esac
|
|
48
|
+
|
|
49
|
+
# Hapus AppImage
|
|
50
|
+
if [ -f "$HOME/.local/bin/$APP_NAME" ]; then
|
|
51
|
+
info "Menghapus AppImage..."
|
|
52
|
+
rm -f "$HOME/.local/bin/$APP_NAME"
|
|
53
|
+
fi
|
|
54
|
+
|
|
55
|
+
# Hapus .desktop file dan ikon
|
|
56
|
+
info "Menghapus shortcut menu aplikasi..."
|
|
57
|
+
rm -f "$HOME/.local/share/applications/$APP_NAME.desktop"
|
|
58
|
+
rm -f "$HOME/.local/share/icons/hicolor/128x128/apps/$APP_NAME.png"
|
|
59
|
+
|
|
60
|
+
if command -v update-desktop-database &>/dev/null; then
|
|
61
|
+
update-desktop-database "$HOME/.local/share/applications" &>/dev/null || true
|
|
62
|
+
fi
|
|
63
|
+
|
|
64
|
+
success "$DISPLAY_NAME berhasil dihapus."
|
|
65
|
+
echo ""
|