Skip to content

Commit 4febd35

Browse files
committed
Add web app deployment to GitHub Pages
1 parent 29ac761 commit 4febd35

File tree

17 files changed

+815
-28
lines changed

17 files changed

+815
-28
lines changed

.github/workflows/gh-pages.yml

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ on:
66
- main
77
paths:
88
- 'docs-site/**'
9+
- 'src/**'
10+
- 'vite.config.web.ts'
11+
- 'package.json'
912
- '.github/workflows/gh-pages.yml'
1013
workflow_dispatch:
1114

@@ -30,16 +33,26 @@ jobs:
3033
with:
3134
node-version: '20'
3235
cache: 'npm'
33-
cache-dependency-path: docs-site/package-lock.json
3436

35-
- name: Install dependencies
37+
- name: Install root dependencies
38+
run: npm ci
39+
40+
- name: Build web app
41+
run: npm run build:web
42+
43+
- name: Install docs-site dependencies
3644
working-directory: ./docs-site
3745
run: npm ci
3846

39-
- name: Build
47+
- name: Build docs-site
4048
working-directory: ./docs-site
4149
run: npm run build
4250

51+
- name: Combine builds
52+
run: |
53+
mkdir -p ./docs-site/dist/webapp
54+
cp -r ./dist-web/* ./docs-site/dist/webapp/
55+
4356
- name: Upload artifact
4457
uses: actions/upload-pages-artifact@v3
4558
with:

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ lerna-debug.log*
1010
node_modules
1111
dist
1212
dist-ssr
13+
dist-web
14+
test-deploy
1315
*.local
1416

1517
# Editor directories and files

README.md

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -62,16 +62,21 @@ $ docker run -d --name EASYEDIT -p 3024:3024 ghcr.io/gcclinux/easyedit:main
6262

6363
## *Markdown Image URL Example*
6464

65-
## *Markdown Image URL Example*
66-
6765
[![GitHub Project](https://raw.githubusercontent.com/gcclinux/EasyEdit/refs/heads/main/public/easyedit128.png "EasyEdit Icon")](https://github.com/gcclinux/EasyEdit)
6866

6967
---
7068

69+
## *Links*
70+
71+
- [Home](https://gcclinux.github.io/EasyEdit/)
72+
- [Docs](https://gcclinux.github.io/EasyEdit/docs)
73+
- [Features](https://gcclinux.github.io/EasyEdit/features)
74+
- [Downloads](https://gcclinux.github.io/EasyEdit/download)
75+
- [Project](https://github.com/gcclinux/EasyEdit)
76+
- [Latest releases](https://github.com/gcclinux/EasyEdit/releases)
77+
7178
## *Support & Community*
7279

7380
[![Issues](https://img.shields.io/badge/🐛_Report_Issues-GitHub-red?style=for-the-badge)](https://github.com/gcclinux/EasyEdit/issues)
7481
[![Discussions](https://img.shields.io/badge/💬_Join_Discussions-GitHub-blue?style=for-the-badge)](https://github.com/gcclinux/EasyEdit/discussions)
75-
[![Buy Me A Coffee](https://img.shields.io/badge/☕_Buy_Me_A_Coffee-Support-yellow?style=for-the-badge)](https://www.buymeacoffee.com/gcclinux)
76-
77-
````
82+
[![Buy Me A Coffee](https://img.shields.io/badge/☕_Buy_Me_A_Coffee-Support-yellow?style=for-the-badge)](https://www.buymeacoffee.com/gcclinux)

docs-site/src/App.tsx

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
import { Routes, Route } from 'react-router-dom'
1+
import { Routes, Route, useLocation } from 'react-router-dom'
2+
import { useEffect } from 'react'
23
import Layout from './components/Layout'
34
import Home from './pages/Home'
45
import Features from './pages/Features'
@@ -8,8 +9,16 @@ import ProjectSummary from './pages/docs/ProjectSummary'
89
import UMLQuickStart from './pages/docs/UMLQuickStart'
910
import UMLExamples from './pages/docs/UMLExamples'
1011
import NomnomlGuide from './pages/docs/NomnomlGuide'
12+
import TemplatesGuide from './pages/docs/TemplatesGuide'
13+
import MermaidGuide from './pages/docs/MermaidGuide'
1114

1215
function App() {
16+
const location = useLocation()
17+
18+
useEffect(() => {
19+
window.scrollTo(0, 0)
20+
}, [location.pathname])
21+
1322
return (
1423
<Routes>
1524
<Route path="/" element={<Layout />}>
@@ -21,6 +30,8 @@ function App() {
2130
<Route path="docs/uml-quick-start" element={<UMLQuickStart />} />
2231
<Route path="docs/uml-examples" element={<UMLExamples />} />
2332
<Route path="docs/nomnoml-guide" element={<NomnomlGuide />} />
33+
<Route path="docs/templates-guide" element={<TemplatesGuide />} />
34+
<Route path="docs/mermaid-guide" element={<MermaidGuide />} />
2435
</Route>
2536
</Routes>
2637
)

docs-site/src/components/Header.css

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,21 @@
4747
text-decoration: none;
4848
}
4949

50+
.webapp-link {
51+
padding: 0.5rem 1rem;
52+
background: linear-gradient(135deg, var(--accent-color), var(--secondary-color));
53+
color: white !important;
54+
border-radius: 6px;
55+
transition: transform 0.3s ease, box-shadow 0.3s ease;
56+
font-weight: 600;
57+
}
58+
59+
.webapp-link:hover {
60+
transform: translateY(-2px);
61+
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
62+
text-decoration: none;
63+
}
64+
5065
.github-link {
5166
padding: 0.5rem 1rem;
5267
background-color: var(--primary-color);

docs-site/src/components/Header.tsx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,16 @@ export default function Header() {
1414
<li><Link to="/features">Features</Link></li>
1515
<li><Link to="/docs">Docs</Link></li>
1616
<li><Link to="/download">Download</Link></li>
17+
<li>
18+
<a
19+
href="/EasyEdit/webapp/"
20+
target="_blank"
21+
rel="noopener noreferrer"
22+
className="webapp-link"
23+
>
24+
🚀 Web App
25+
</a>
26+
</li>
1727
<li>
1828
<a
1929
href="https://github.com/gcclinux/EasyEdit"

docs-site/src/pages/Docs.css

Lines changed: 47 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -162,21 +162,65 @@ kbd {
162162
.try-it-section {
163163
margin-top: 4rem;
164164
padding: 3rem;
165-
background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
165+
background: white;
166166
border-radius: 12px;
167167
text-align: center;
168-
color: white;
168+
color: var(--text-color);
169+
box-shadow: var(--shadow);
169170
}
170171

171172
.try-it-section h2 {
172173
margin-bottom: 1rem;
173174
font-size: 2rem;
175+
color: var(--primary-color);
174176
}
175177

176178
.try-it-section p {
177179
margin-bottom: 2rem;
178180
font-size: 1.1rem;
179-
opacity: 0.95;
181+
color: var(--text-light);
182+
}
183+
184+
.try-it-section .btn {
185+
padding: 0.875rem 2rem;
186+
border-radius: 8px;
187+
font-weight: 600;
188+
text-decoration: none;
189+
transition: all 0.3s ease;
190+
display: inline-block;
191+
font-size: 1rem;
192+
border: 2px solid transparent;
193+
}
194+
195+
.try-it-section .btn-primary {
196+
background-color: var(--primary-color);
197+
color: white;
198+
border-color: var(--primary-color);
199+
}
200+
201+
.try-it-section .btn-primary:hover {
202+
transform: translateY(-2px);
203+
box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
204+
text-decoration: none;
205+
}
206+
207+
.try-it-section .btn-secondary {
208+
background-color: transparent;
209+
color: var(--primary-color);
210+
border-color: var(--primary-color);
211+
}
212+
213+
.try-it-section .btn-secondary:hover {
214+
background-color: var(--primary-color);
215+
color: white;
216+
text-decoration: none;
217+
}
218+
219+
.try-it-section .hero-buttons {
220+
display: flex;
221+
gap: 1rem;
222+
justify-content: center;
223+
flex-wrap: wrap;
180224
}
181225

182226
.cta-links {

docs-site/src/pages/Docs.tsx

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,24 @@ export default function Docs() {
3232
<p>Explore real-world UML diagram examples and use cases</p>
3333
</Link>
3434

35+
<Link to="/docs/templates-guide" className="doc-card">
36+
<div className="doc-icon">📝</div>
37+
<h3>Templates Guide</h3>
38+
<p>Learn how to use pre-built templates for quick document creation</p>
39+
</Link>
40+
41+
<Link to="/docs/mermaid-guide" className="doc-card">
42+
<div className="doc-icon">🧜‍♀️</div>
43+
<h3>Mermaid Guide</h3>
44+
<p>Create flowcharts, Gantt charts, and diagrams with Mermaid syntax</p>
45+
</Link>
46+
3547
<Link to="/docs/nomnoml-guide" className="doc-card">
3648
<div className="doc-icon">📖</div>
3749
<h3>Nomnoml Guide</h3>
3850
<p>Complete guide to Nomnoml syntax and features</p>
3951
</Link>
52+
4053
</div>
4154

4255
<div className="getting-started">
@@ -121,10 +134,10 @@ export default function Docs() {
121134
<div className="try-it-section">
122135
<h2>Try EasyEdit Online</h2>
123136
<p>Experience EasyEdit directly in your browser without downloading anything!</p>
124-
<div className="cta-links">
125-
<Link to="/EasyEdit/docs" className="cta-button secondary">📚 Docs</Link>
126-
<a href="https://easyedit-web.web.app/" target="_blank" rel="noopener noreferrer" className="cta-button primary">🚀 Try It</a>
127-
<Link to="/EasyEdit/download" className="cta-button secondary">⬇️ Download</Link>
137+
<div className="hero-buttons">
138+
<Link to="/docs" className="btn btn-secondary">📚 Documentation</Link>
139+
<a href="https://easyedit-web.web.app/" target="_blank" rel="noopener noreferrer" className="btn btn-primary">🚀 Try It Online</a>
140+
<Link to="/download" className="btn btn-secondary">⬇️ Download</Link>
128141
</div>
129142
</div>
130143
</div>

docs-site/src/pages/Download.tsx

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -356,11 +356,11 @@ export default function Download() {
356356
</div>
357357
<div className="checksum-item">
358358
<strong>EasyEdit-1.4.2-arm64.dmg</strong>
359-
<code>TODO_CHECKSUM_ARM64_DMG</code>
359+
<code>dfef38d31478c4ea919ce310f9781ca8078317249340cce54c1201a7ab079b84</code>
360360
</div>
361361
<div className="checksum-item">
362362
<strong>EasyEdit-1.4.2-arm64-mac.zip</strong>
363-
<code>TODO_CHECKSUM_ARM64_ZIP</code>
363+
<code>592f7b801436ab050f9e0095a0a027a21e6362fd270d76e6eb81510e31f6b151</code>
364364
</div>
365365
</div>
366366
<div className="verify-instructions">
@@ -465,6 +465,27 @@ export default function Download() {
465465
</ol>
466466
</div>
467467

468+
<div className="install-section">
469+
<h3> macOS - DMG</h3>
470+
<ol>
471+
<li>Download the <code>EasyEdit-1.4.2-arm64.dmg</code> file from the links above.</li>
472+
<li>Open the downloaded .dmg file to mount it (double-click the file).</li>
473+
<li>In the mounted window, drag the <strong>EasyEdit</strong> app icon into the <strong>Applications</strong> folder.</li>
474+
<li>Eject the mounted image and launch EasyEdit from the Applications folder.</li>
475+
<li>If macOS blocks the app, open System Settings → Privacy & Security and allow the app, or right-click the app and choose <em>Open</em> to bypass Gatekeeper.</li>
476+
</ol>
477+
</div>
478+
479+
<div className="install-section">
480+
<h3> macOS - ZIP</h3>
481+
<ol>
482+
<li>Download the <code>EasyEdit-1.4.2-arm64-mac.zip</code> file.</li>
483+
<li>Unzip the archive: <code>unzip EasyEdit-1.4.2-arm64-mac.zip</code></li>
484+
<li>Move the extracted <strong>EasyEdit.app</strong> to your <code>/Applications</code> folder or run it from the extracted folder.</li>
485+
<li>If macOS warns about an unverified developer, right-click the app and choose <em>Open</em> to allow it.</li>
486+
</ol>
487+
</div>
488+
468489
<div className="install-section">
469490
<h3>🔧 Build from Source</h3>
470491
<ol>

0 commit comments

Comments
 (0)