diff --git a/index.html b/index.html index 93fb6cc..2aebd40 100644 --- a/index.html +++ b/index.html @@ -112,15 +112,6 @@

最新思路

-
-
-
-

赛博朋克时代的前端架构思考

-

探索在快速变化的技术环境中,如何构建可维护的前端系统...

-

2023-05-15

- 继续阅读 -
-
@@ -130,6 +121,15 @@ 继续阅读
+
+
+
+

赛博朋克时代的前端架构思考

+

探索在快速变化的技术环境中,如何构建可维护的前端系统...

+

2023-05-15

+ 继续阅读 +
+
@@ -195,7 +195,7 @@

内存使用

-

4.2GB / 16GB

+

4.2GB / 8GB

@@ -216,7 +216,7 @@

网络速度

-

120MB/s

+

3MB/s

@@ -228,7 +228,7 @@

VS Code

集成开发环境

- 启动 + 启动
diff --git a/script.js b/script.js index 3cbf4d2..9795a77 100644 --- a/script.js +++ b/script.js @@ -53,6 +53,7 @@ window.addEventListener('load', function() { const jenkinsUrl = `${window.location.protocol}//${currentHost}:9095`; const chatUrl = `${window.location.protocol}//${currentHost}/baseTalk`; const cloudreveUrl = `${window.location.protocol}//${currentHost}:5212`; + const codeServerUrl = `${window.location.protocol}//${currentHost}:8443`; // 构建博客文章URL,指向8090端口 const blogBaseUrl = `${window.location.protocol}//${currentHost}:8090`; @@ -63,6 +64,7 @@ window.addEventListener('load', function() { const jenkinsLink = document.getElementById('jenkinsLink'); const chatLink = document.getElementById('chatLink'); const cloudreveLink = document.getElementById('cloudreveLink'); + const codeServerLink = document.getElementById('codeServerLink'); if (portainerLink) { portainerLink.href = portainerUrl; @@ -88,6 +90,10 @@ window.addEventListener('load', function() { cloudreveLink.href = cloudreveUrl; cloudreveLink.target = '_blank'; } + if (codeServerLink) { + codeServerLink.href = codeServerUrl; + codeServerLink.target = '_blank'; + } // 处理博客文章链接 const blogPosts = document.querySelectorAll('.thought-card'); @@ -102,6 +108,27 @@ window.addEventListener('load', function() { window.open(postUrl, '_blank'); }); }); + + // 快速启动项目按钮处理 + const templateButtons = document.querySelectorAll('.template-button'); + const projectTemplates = [ + { type: 'frontend', name: '前端项目', url: '/?folder=/config/workspace' }, + { type: 'backend', name: '后端服务', url: '/?folder=/config/workspace' }, + { type: 'fullstack', name: '全栈应用', url: '/?folder=/config/workspace' } + ]; + + templateButtons.forEach((button, index) => { + if (projectTemplates[index]) { + button.addEventListener('click', () => { + // 构建基于当前域名的URL + const baseUrl = `${window.location.protocol}//${currentHost}:8443`; + const targetUrl = `${baseUrl}${projectTemplates[index].url}`; + window.open(targetUrl, '_blank'); + }); + } + }); + + }); // 粒子背景效果