This is an automated email from the ASF dual-hosted git repository.

jark pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/fluss.git


The following commit(s) were added to refs/heads/main by this push:
     new 1178d39a6 [website] Update code styling and add light theme for syntax 
highlighting (#2742)
1178d39a6 is described below

commit 1178d39a61a55c1b9a7ce19a757bcc29fbd32f7c
Author: Jark Wu <[email protected]>
AuthorDate: Fri Feb 27 23:34:50 2026 +0800

    [website] Update code styling and add light theme for syntax highlighting 
(#2742)
---
 website/docs/quickstart/flink.md |  2 +-
 website/docusaurus.config.ts     |  3 +-
 website/src/css/custom.css       |  7 ++--
 website/src/utils/prismLight.ts  | 69 ++++++++++++++++++++++++++++++++++++++++
 4 files changed, 75 insertions(+), 6 deletions(-)

diff --git a/website/docs/quickstart/flink.md b/website/docs/quickstart/flink.md
index f94161f56..472a864eb 100644
--- a/website/docs/quickstart/flink.md
+++ b/website/docs/quickstart/flink.md
@@ -423,7 +423,7 @@ If you are interested in a specific customer, you can 
retrieve their details by
 SELECT * FROM fluss_customer WHERE `cust_key` = 1;
 ```
 **Sample Output**
-```shell
+```
 +----------+---------------+--------------+------------+---------+------------+
 | cust_key |          name |        phone | nation_key | acctbal | mktsegment |
 +----------+---------------+--------------+------------+---------+------------+
diff --git a/website/docusaurus.config.ts b/website/docusaurus.config.ts
index 6cad47dfd..3df9308a3 100644
--- a/website/docusaurus.config.ts
+++ b/website/docusaurus.config.ts
@@ -18,6 +18,7 @@
 import {themes as prismThemes} from 'prism-react-renderer';
 import type {Config} from '@docusaurus/types';
 import type * as Preset from '@docusaurus/preset-classic';
+import lightTheme from './src/utils/prismLight';
 import versionReplace from './src/plugins/remark-version-replace/index';
 import { loadVersionData } from './src/utils/versionData';
 const { versionsMap, latestVersion } = loadVersionData();
@@ -226,7 +227,7 @@ const config: Config = {
                   <p>Apache, the names of Apache projects, and the feather 
logo are either registered trademarks or trademarks of the Apache Software 
Foundation in the United States and/or other countries. All other marks 
mentioned may be trademarks or registered trademarks of their respective 
owners.</p>`,
     },
     prism: {
-      theme: prismThemes.vsDark,
+      theme: lightTheme,
       darkTheme: prismThemes.dracula,
       additionalLanguages: ['java', 'bash', 'scala']
     },
diff --git a/website/src/css/custom.css b/website/src/css/custom.css
index dd5af2401..a643aa173 100644
--- a/website/src/css/custom.css
+++ b/website/src/css/custom.css
@@ -144,13 +144,12 @@
         color: #4c576c;
     }
 
-/*    pre {
+    pre {
         code {
             padding: 0.725rem 1.25rem;
-            background-color: #262a37;
-            line-height: 1.875;
+            background-color: #f5f5f5;
         }
-    }*/
+    }
 
     table thead tr {
         background-color: #f7f9fe;
diff --git a/website/src/utils/prismLight.ts b/website/src/utils/prismLight.ts
new file mode 100644
index 000000000..40d055526
--- /dev/null
+++ b/website/src/utils/prismLight.ts
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import type {PrismTheme} from 'prism-react-renderer';
+
+const lightTheme: PrismTheme = {
+  plain: {
+    color: '#36464e',
+    backgroundColor: '#f5f5f5',
+  },
+  styles: [
+    {
+      types: ['comment', 'prolog', 'doctype', 'cdata'],
+      style: { color: '#8e908c', fontStyle: 'italic' },
+    },
+    {
+      types: ['namespace'],
+      style: { opacity: 0.7 },
+    },
+    {
+      types: ['string', 'attr-value', 'char', 'inserted'],
+      style: { color: '#1c7d4d' },
+    },
+    {
+      types: ['number', 'boolean'],
+      style: { color: '#d52a2a' },
+    },
+    {
+      types: ['keyword', 'atrule', 'selector'],
+      style: { color: '#3f6ec6' },
+    },
+    {
+      types: ['function', 'class-name', 'tag'],
+      style: { color: '#a846b9' },
+    },
+    {
+      types: ['builtin', 'constant', 'variable', 'property'],
+      style: { color: '#6e59d9' },
+    },
+    {
+      types: ['operator', 'punctuation'],
+      style: { color: 'rgba(0, 0, 0, 0.54)' },
+    },
+    {
+      types: ['regex', 'important', 'deleted'],
+      style: { color: '#db1457' },
+    },
+    {
+      types: ['attr-name'],
+      style: { color: '#3f6ec6' },
+    },
+  ],
+};
+
+export default lightTheme;

Reply via email to