Skip to content

Commit bb73d4f

Browse files
committed
feat: modify downloads page for JDBC
- Add new downloads page (/downloads-page) with IvorySQL software and JDBC driver links - Update navbar to point Downloads to new internal page instead of direct GitHub link
1 parent 2401657 commit bb73d4f

3 files changed

Lines changed: 259 additions & 1 deletion

File tree

CLAUDE.md

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
# CLAUDE.md
2+
3+
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
4+
5+
## Project Overview
6+
7+
This is the IvorySQL website (IvorySQL.org), a Docusaurus 2-based documentation site for the IvorySQL project - an open-source Oracle-compatible PostgreSQL database.
8+
9+
## Common Commands
10+
11+
```bash
12+
yarn # Install dependencies
13+
yarn start # Start local dev server (http://localhost:3000)
14+
yarn build # Build production static site
15+
yarn serve # Serve the built site locally
16+
yarn clear # Clear Docusaurus cache
17+
yarn deploy # Deploy to Netlify (auto-deployed on main branch push)
18+
```
19+
20+
## Architecture
21+
22+
- **Framework**: Docusaurus 2 with preset-classic
23+
- **Localization**: English (default) and Chinese (zh-CN) via i18n
24+
- **Search**: @easyops-cn/docusaurus-search-local (indexes docs and blog, excludes certain pages)
25+
- **Deployment**: Auto-deploys to Netlify on push to main branch
26+
- **Custom CSS**: src/css/custom.css
27+
- **Custom Components**: src/components/
28+
- **Custom Pages**: src/pages/ (home page, release pages, partners, events, etc.)
29+
- **Blog**: blog/ directory with dated subdirectories for posts
30+
- **Docs**: docs/ directory with auto-generated sidebar from filesystem structure
31+
32+
## Site Configuration
33+
34+
- `docusaurus.config.js` - Main configuration including navbar, footer, i18n, and search plugin settings
35+
- `sidebars.js` - Sidebar configuration (currently auto-generated from docs directory)
36+
- `src/clientModules/lang-redirect.js` - Language detection/redirect logic
37+
38+
## Translation Workflow
39+
40+
Translations are managed through Docusaurus i18n system:
41+
- Source files: docs/, blog/
42+
- Translation files: i18n/zh-CN/docusaurus-plugin-content-docs/current/
43+
- Run `yarn write-translations --locale zh-CN` to generate translation templates
44+
45+
## Environment Variables
46+
47+
The site uses docusaurus-plugin-dotenv with `.env` file support. Custom fields `BOT_ID` and `TOKEN` are exposed via `customFields` in docusaurus.config.js.
48+
49+
## Key Files
50+
51+
- `src/pages/index.js` - Homepage with sliders and components
52+
- `blog/authors.yml` - Blog author definitions
53+
- `static/img/` - Static images
54+
- `static/pdf/` - Static PDF files

docusaurus.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ const config = {
129129
items: [
130130
{
131131
label: 'Downloads',
132-
href: 'https://github.com/IvorySQL/IvorySQL/releases',
132+
to: '/downloads-page',
133133
},
134134
{
135135
label: 'Installation',

src/pages/downloads-page.mdx

Lines changed: 204 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,204 @@
1+
---
2+
title: Downloads
3+
hide_table_of_contents: true
4+
---
5+
6+
import useBaseUrl from '@docusaurus/useBaseUrl';
7+
8+
<style>{`
9+
.downloads-banner {
10+
background: linear-gradient(135deg, #7D52F4 0%, #A38CF9 100%);
11+
border-radius: 16px;
12+
padding: 60px 40px;
13+
text-align: center;
14+
margin: 20px 0 50px;
15+
position: relative;
16+
overflow: hidden;
17+
}
18+
.downloads-banner::before {
19+
content: '';
20+
position: absolute;
21+
top: 0;
22+
left: 0;
23+
right: 0;
24+
bottom: 0;
25+
background: url('/img/downloads/download-banner-bg.png') center/cover no-repeat;
26+
opacity: 0.15;
27+
}
28+
.downloads-banner h1 {
29+
color: white !important;
30+
font-size: 2.8rem;
31+
font-weight: bold;
32+
margin: 0 0 15px 0;
33+
position: relative;
34+
z-index: 1;
35+
}
36+
.downloads-banner p {
37+
color: rgba(255,255,255,0.9);
38+
font-size: 1.2rem;
39+
margin: 0;
40+
position: relative;
41+
z-index: 1;
42+
}
43+
44+
.downloads-container {
45+
max-width: 1200px;
46+
margin: 0 auto;
47+
padding: 0 20px 80px;
48+
}
49+
50+
.download-grid {
51+
display: grid;
52+
grid-template-columns: repeat(2, 1fr);
53+
gap: 30px;
54+
margin-top: 30px;
55+
}
56+
57+
.download-card {
58+
background: #fff;
59+
border: 1px solid #f0f0f0;
60+
border-radius: 16px;
61+
padding: 40px;
62+
transition: all 0.3s ease;
63+
display: flex;
64+
flex-direction: column;
65+
align-items: center;
66+
text-align: center;
67+
}
68+
.download-card:hover {
69+
transform: translateY(-5px);
70+
box-shadow: 0 15px 40px rgba(125, 82, 244, 0.15);
71+
border-color: #7D52F4;
72+
}
73+
74+
.download-icon {
75+
width: 80px;
76+
height: 80px;
77+
border-radius: 50%;
78+
background: linear-gradient(135deg, #7D52F4 0%, #A38CF9 100%);
79+
display: flex;
80+
align-items: center;
81+
justify-content: center;
82+
margin-bottom: 25px;
83+
}
84+
.download-icon svg {
85+
width: 40px;
86+
height: 40px;
87+
fill: white;
88+
}
89+
90+
.download-card h2 {
91+
font-size: 1.5rem;
92+
color: #333;
93+
margin: 0 0 15px 0;
94+
}
95+
96+
.download-card p {
97+
color: #666;
98+
font-size: 0.95rem;
99+
line-height: 1.6;
100+
margin: 0 0 25px 0;
101+
flex-grow: 1;
102+
}
103+
104+
.download-btn {
105+
display: inline-flex;
106+
align-items: center;
107+
gap: 8px;
108+
background: linear-gradient(135deg, #7D52F4 0%, #A38CF9 100%);
109+
color: white;
110+
padding: 12px 30px;
111+
border-radius: 30px;
112+
text-decoration: none;
113+
font-weight: 600;
114+
transition: all 0.3s ease;
115+
}
116+
.download-btn:hover {
117+
transform: scale(1.05);
118+
box-shadow: 0 8px 25px rgba(125, 82, 244, 0.35);
119+
color: white;
120+
}
121+
.download-btn svg {
122+
width: 18px;
123+
height: 18px;
124+
fill: currentColor;
125+
}
126+
127+
.download-info {
128+
margin-top: 40px;
129+
background: #F9F7FF;
130+
border-radius: 16px;
131+
padding: 30px;
132+
text-align: center;
133+
}
134+
.download-info h3 {
135+
color: #7D52F4;
136+
margin: 0 0 15px 0;
137+
}
138+
.download-info p {
139+
color: #666;
140+
margin: 0;
141+
line-height: 1.8;
142+
}
143+
144+
@media (max-width: 996px) {
145+
.downloads-banner {
146+
padding: 40px 20px;
147+
}
148+
.downloads-banner h1 {
149+
font-size: 2rem;
150+
}
151+
.download-grid {
152+
grid-template-columns: 1fr;
153+
}
154+
.download-card {
155+
padding: 30px 20px;
156+
}
157+
}
158+
`}</style>
159+
160+
<div className="downloads-banner">
161+
<h1>Downloads</h1>
162+
<p>Get the latest IvorySQL software and drivers</p>
163+
</div>
164+
165+
<div className="downloads-container">
166+
<div className="download-grid">
167+
<div className="download-card">
168+
<div className="download-icon">
169+
<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
170+
<path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-1 17.93c-3.95-.49-7-3.85-7-7.93 0-.62.08-1.21.21-1.79L9 15v1c0 1.1.9 2 2 2v1.93zm6.9-2.54c-.26-.81-1-1.39-1.9-1.39h-1v-3c0-.55-.45-1-1-1H8v-2h2c.55 0 1-.45 1-1V7h2c1.1 0 2-.9 2-2v-.41c2.93 1.19 5 4.06 5 7.41 0 2.08-.8 3.97-2.1 5.39z"/>
171+
</svg>
172+
</div>
173+
<h2>IvorySQL Software</h2>
174+
<p>Download the latest IvorySQL database release. IvorySQL is an open-source Oracle-compatible PostgreSQL database.</p>
175+
<a href="https://github.com/IvorySQL/IvorySQL/releases" target="_blank" rel="noopener noreferrer" className="download-btn">
176+
<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
177+
<path d="M19 9h-4V3H9v6H5l7 7 7-7zM5 18v2h14v-2H5z"/>
178+
</svg>
179+
Download Now
180+
</a>
181+
</div>
182+
183+
<div className="download-card">
184+
<div className="download-icon">
185+
<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
186+
<path d="M20 6h-8l-2-2H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-1 8h-3v2h3v2h-3v4h-2v-4H9v-2h3v-2h2v2z"/>
187+
</svg>
188+
</div>
189+
<h2>JDBC Driver</h2>
190+
<p>Download the official IvorySQL JDBC driver for Java applications to connect to IvorySQL databases.</p>
191+
<a href="https://github.com/IvorySQL/IvorySQL/releases" target="_blank" rel="noopener noreferrer" className="download-btn">
192+
<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
193+
<path d="M19 9h-4V3H9v6H5l7 7 7-7zM5 18v2h14v-2H5z"/>
194+
</svg>
195+
Download Now
196+
</a>
197+
</div>
198+
</div>
199+
200+
<div className="download-info">
201+
<h3>All Downloads Available on GitHub</h3>
202+
<p>Visit our GitHub releases page to find all IvorySQL versions, including previous releases, source code, and additional components.</p>
203+
</div>
204+
</div>

0 commit comments

Comments
 (0)