Skip to content

Commit 3b8cfb4

Browse files
committed
feat: H1.00 官网艺术化重设计 + 移动端 IDE 防挤压 + v3.66 归档
版本跃迁 H1.00: - 归档 v3.66 → old/v3.66/,更新历史索引 - 全量版本号对齐 (ide/android/windows 三端 hic.js/app.js/store.js + 入口页 + 离线打包脚本) 官网首页 index.html 艺术化: - 深色主题 + 琥珀色强调 (#c7a56b) 品牌系统 - Hero 代码墙 3D tilt hover 交互 - 滚动渐显动画 (data-reveal + stagger-box,已在视口内元素分步延迟触发) - 导航吸顶 + 当前段落自动高亮 - Stats 数字滚动递增脉动 (cubic-bezier easing) - FAQ 平滑展开 (grid-template-rows 0fr→1fr 过渡) - 背景光晕固定层 + 视差滚动 下载页 download/index.html: - 对齐首页 data-reveal 渐显动画系统 移动端 IDE (android/css/style.css) 防挤压: - 顶栏紧凑化 (ed-switch 按钮 24px、live/导出按钮更紧凑、brand name/ver/crumb 限宽) - 360px / 320px / 400px 三档 media query 精细断点 - flex 布局修:layout/workspace/pane 全部 min-height:0 overflow:hidden 防撑爆 - 底部面板 44vh → 34vh 梯度收缩 离线单文件: - 重新打包 HiCode-H1.00M/R/X-offline.html 三档
1 parent 745564c commit 3b8cfb4

97 files changed

Lines changed: 36702 additions & 278 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎android/css/style.css‎

Lines changed: 60 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -358,25 +358,34 @@ body { overflow: hidden; }
358358
code { font-size: .9em; }
359359

360360
/* ---- 顶栏:紧凑 + 汉堡按钮 ---- */
361-
.topbar { gap: 8px; padding: 8px 10px; }
361+
.topbar { gap: 6px; padding: 7px 10px; flex-wrap: nowrap; overflow: hidden; }
362362
.btn-tree {
363-
width: 38px; height: 38px; flex: 0 0 38px; border-radius: 10px; font-size: 19px; line-height: 1;
363+
width: 36px; height: 36px; flex: 0 0 36px; border-radius: 10px; font-size: 18px; line-height: 1;
364364
color: var(--muted); background: var(--glass); border: 1px solid var(--line); display: grid; place-items: center;
365365
}
366366
.btn-tree:hover { color: var(--accent); border-color: var(--accent); }
367-
.brand { gap: 7px; }
368-
.brand-name { font-size: 15px; }
369-
.brand .ver { font-size: 10px; padding: 2px 6px; }
370-
.actions { gap: 6px; }
371-
.actions .btn { padding: 8px 12px; font-size: 12.5px; }
372-
.crumb { font-size: 11px; }
367+
.brand { gap: 5px; min-width: 0; flex: 0 0 auto; }
368+
.brand-name { font-size: 15px; white-space: nowrap; }
369+
.brand .ver { font-size: 10px; padding: 1px 6px; flex: 0 0 auto; }
370+
.crumb { flex: 0 1 auto; min-width: 0; max-width: 90px; font-size: 11px; }
371+
.actions { gap: 5px; flex: 0 0 auto; display: flex; align-items: center; min-width: 0; }
372+
373+
/* ed-switch 紧凑化,三按钮防撑 */
374+
.ed-switch { gap: 1px; padding: 2px; }
375+
.ed-switch .ed-btn { min-width: 24px; padding: 4px 7px; font-size: 11.5px; letter-spacing: .3px; }
376+
377+
/* ✓ 实时转译:在极窄屏缩为纯图标模式 */
378+
.btn.live { padding: 7px 10px; font-size: 12px; white-space: nowrap; }
379+
380+
/* 导出按钮:减少文字(移 ▾),更紧凑 */
381+
#btnExport.btn.solid { padding: 7px 10px; font-size: 12px; }
373382

374383
/* 导出下拉:窄屏下铺满可读 */
375384
.menu { position: fixed; left: 12px; right: 12px; top: 54px; width: auto; min-width: 0; }
376385
.menu button { padding: 12px 12px; font-size: 14px; }
377386

378387
/* ---- 布局单列,侧栏改为左侧滑出抽屉 ---- */
379-
.layout { height: calc(100vh - 54px); }
388+
.layout { height: calc(100vh - 54px); display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
380389
.drawer-scrim { position: fixed; inset: 0; z-index: 55; background: rgba(40, 30, 15, .42); -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px); }
381390
body.drawer-open { overflow: hidden; }
382391
.tree {
@@ -391,18 +400,18 @@ body.drawer-open { overflow: hidden; }
391400
.tree-item .ops { display: flex; gap: 4px; }
392401
.tree-item .ops span { padding: 2px 6px; font-size: 15px; }
393402
.tree-empty { font-size: 13px; margin-top: 22px; }
394-
.workspace { width: 100%; min-width: 0; }
403+
.workspace { width: 100%; min-width: 0; min-height: 0; flex: 1; display: flex; flex-direction: column; overflow: hidden; }
395404

396405
/* ---- 顶部面板:代码 / 预览 / 画布 ---- */
397406
.tabs { padding: 8px 10px 0; gap: 2px; }
398407
.tab { flex: 1; text-align: center; padding: 10px 4px; font-size: 13px; white-space: nowrap; }
399-
.pane { padding: 10px; }
408+
.pane { padding: 10px; flex: 1; min-height: 0; overflow: hidden; }
400409
.editor-head { gap: 6px; }
401410
.shortcut { display: none !important; }
402411
.editor-snippets { gap: 6px; }
403-
.editor-snippets .snippet { padding: 7px 11px; font-size: 12px; }
412+
.editor-snippets .snippet { padding: 8px 12px; font-size: 12px; white-space: nowrap; touch-action: manipulation; }
404413
.codearea, .editor-highlight, .editor-gutter { font-size: 13px; line-height: 1.6; }
405-
.editor-wrap { --gutter: 40px; }
414+
.editor-wrap { --gutter: 40px; min-height: 0; }
406415
.editor-wrap textarea.codearea { padding-left: calc(40px + 11px); }
407416
.editor-highlight { padding-left: calc(40px + 11px); }
408417
.editor-mark { left: 40px; }
@@ -455,16 +464,47 @@ body.drawer-open { overflow: hidden; }
455464
.statusbar { margin: 8px 10px 10px; padding: 5px 10px; font-size: 11px; }
456465
.sb-right { font-size: 10.5px; }
457466

458-
/* ---- 窄屏(≤400px)进一步压缩,避免横向溢出 ---- */
459-
@media (max-width: 400px) {
467+
/* ---- 极窄屏(≤360px):隐藏次要文本,仅保留核心操作 ---- */
468+
@media (max-width: 360px) {
469+
.brand-name { font-size: 13px; }
470+
.brand .ver { font-size: 9px; padding: 1px 5px; }
471+
.crumb { max-width: 60px; }
472+
.btn.live { padding: 7px 8px; font-size: 11px; }
473+
.btn.live::before { content: ""; } /* 保持占位 */
474+
#btnExport.btn.solid { padding: 7px 8px; font-size: 11.5px; }
475+
.ed-switch .ed-btn { min-width: 22px; padding: 3px 6px; font-size: 11px; }
476+
.btn-tree { width: 32px; height: 32px; flex-basis: 32px; font-size: 17px; border-radius: 9px; }
477+
.topbar { padding: 6px 7px; gap: 5px; }
478+
.pane { padding: 8px 7px 10px; }
479+
.editor-snippets .snippet { padding: 6px 8px; font-size: 11px; }
480+
.bottom-panel { margin: 6px 7px 0; flex-basis: 38vh; }
481+
.statusbar { margin: 6px 7px 8px; }
482+
}
483+
484+
/* ---- 超窄屏(≤320px):再砍一刀 ---- */
485+
@media (max-width: 320px) {
486+
.brand-name { display: none; }
487+
.crumb { max-width: 0; overflow: hidden; }
488+
.brand { gap: 3px; }
489+
.brand .ver { font-size: 9px; padding: 1px 5px; }
490+
.btn.live { display: none; } /* 实时转译图标隐藏 */
491+
.ed-switch .ed-btn { min-width: 20px; padding: 3px 5px; font-size: 10.5px; }
492+
#btnExport.btn.solid { padding: 7px 9px; font-size: 11px; }
493+
.bottom-panel { flex-basis: 34vh; }
494+
.tabs { padding: 6px 6px 0; }
495+
.tab { padding: 8px 2px; font-size: 12px; }
496+
.home-card { padding: 24px 16px; }
497+
.home-card h1 { font-size: 21px; }
498+
}
499+
500+
/* ---- 窄屏(≤400px):过渡优化 ---- */
501+
@media (max-width: 400px) and (min-width: 321px) {
460502
.topbar { padding: 7px 8px; gap: 6px; }
461503
.btn-tree { width: 34px; height: 34px; flex-basis: 34px; }
462-
.brand { gap: 5px; min-width: 0; }
463-
.brand-name { font-size: 14px; white-space: nowrap; overflow: hidden; max-width: 72px; text-overflow: ellipsis; }
504+
.brand-name { font-size: 14px; }
464505
.brand .ver { font-size: 9.5px; padding: 1px 5px; }
465-
.crumb { max-width: 84px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
506+
.crumb { max-width: 80px; }
466507
.actions .btn { padding: 7px 10px; font-size: 12px; }
467-
.actions .btn:first-of-type { letter-spacing: 0; }
468508
.pane { padding: 8px 8px 10px; }
469509
.tabs { padding: 6px 8px 0; gap: 1px; }
470510
.tab { padding: 9px 3px; font-size: 12.5px; letter-spacing: -.2px; }
@@ -476,21 +516,11 @@ body.drawer-open { overflow: hidden; }
476516
.editor-wrap textarea.codearea { padding-left: calc(34px + 9px); }
477517
.editor-highlight { padding-left: calc(34px + 9px); }
478518
.editor-mark { left: 34px; }
479-
.bottom-panel { margin: 6px 8px 0; flex-basis: 42vh; }
519+
.bottom-panel { margin: 6px 8px 0; flex-basis: 40vh; }
480520
.btab { font-size: 12px; padding: 8px 10px; }
481521
.statusbar { margin: 6px 8px 8px; }
482522
.home-card { padding: 26px 18px; }
483523
.home-card h1 { font-size: 23px; }
484524
.menu { left: 8px; right: 8px; top: 50px; }
485525
.graph-canvas { min-height: 50vh; }
486-
}
487-
488-
/* ---- 极窄屏(≤340px):隐藏次要文本,仅保留核心操作 ---- */
489-
@media (max-width: 340px) {
490-
.brand-name { display: none; }
491-
.crumb { max-width: 40px; }
492-
.preview-bar .preview-fname { max-width: 90px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
493-
.graph-tools label { font-size: 12px; }
494-
.console-filter { display: none; }
495-
.home-actions .btn.big { padding: 13px 12px; font-size: 14px; }
496526
}

‎android/index.html‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<head>
44
<meta charset="UTF-8" />
55
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
6-
<title>HiCode · 手机开发环境 v3.66(安卓端)</title>
6+
<title>HiCode · 手机开发环境 H1.00(安卓端)</title>
77
<link rel="icon" href="/assets/favicon.svg" type="image/svg+xml" />
88
<link rel="icon" href="/assets/favicon-32.png" sizes="32x32" type="image/png" />
99
<link rel="icon" href="/assets/favicon-16.png" sizes="16x16" type="image/png" />
@@ -18,7 +18,7 @@
1818
<div class="brand" id="btnHome" title="返回首页">
1919
<span class="logo-dot"></span>
2020
<span class="brand-name">HiCode</span>
21-
<span class="ver" id="verTag">v3.66 · 手机端</span>
21+
<span class="ver" id="verTag">H1.00 · 手机端</span>
2222
</div>
2323
<div class="crumb" id="crumb" title="当前文件">—</div>
2424
<div class="actions">
@@ -153,7 +153,7 @@
153153
<div class="console-welcome">
154154
<span class="cw-logo">H</span>
155155
<div class="cw-text">
156-
<span class="cw-title">HiCode · HIC 手机开发环境 v3.66(安卓端)</span>
156+
<span class="cw-title">HiCode · HIC 手机开发环境 H1.00(安卓端)</span>
157157
<span class="cw-sub">HIC 引擎已就绪 · 正在加载编辑器…</span>
158158
</div>
159159
</div>

‎android/js/app.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@
129129
if (typeof HC !== "undefined" && HC.setEdition) HC.setEdition(ed);
130130
try { window.HIC_EDITION = ed; } catch (e) {}
131131
const VT = document.getElementById("verTag");
132-
if (VT) VT.textContent = "v3.66 · " + ED_NAME[ed];
132+
if (VT) VT.textContent = "H1.00 · " + ED_NAME[ed];
133133
if (el.edSwitch) Array.prototype.forEach.call(el.edSwitch.querySelectorAll(".ed-btn"), function (b) {
134134
b.classList.toggle("on", b.getAttribute("data-ed") === ed);
135135
});

‎android/js/hic.js‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,12 @@
1111
})(typeof self !== 'undefined' ? self : null, function () {
1212
"use strict";
1313

14-
const APP = { version: "v3.66", name: "HiCode", lang: "HIC" };
14+
const APP = { version: "H1.00", name: "HiCode", lang: "HIC" };
1515
// 当前发布形态:r=标准(+py) / m=轻量(仅hic) / x=全能(+py+cpp)。
1616
// 导出的 HTML 会在 head 写入 window.HIC_EDITION,由内建编译器宿主据此决定编译哪些语言。
1717
let EDITION = "x"; // 源码/网页在线版默认全能(X);离线单文件按 R/M/X 各自注入。可用 HC.setEdition() 覆盖。
1818
function setEdition(e) { EDITION = String(e || "").toLowerCase()[0] === "r" ? "r" : String(e || "").toLowerCase()[0] === "m" ? "m" : "x"; }
19-
// v3.66 三版发布:R(标准,+py) / M(轻量,仅hic) / X(全能,+py+cpp)。
19+
// H1.00 三版发布:R(标准,+py) / M(轻量,仅hic) / X(全能,+py+cpp)。
2020
// 引擎统一解析全部语言块,具体版本决定「哪些语言可被 HIC 编译进 HTML」以及打包形态。
2121
// 块语法:html:(…)end(原样 HTML)、py:(…)end(HIC 编译 Python→HTML)、cpp:(…)end(HIC 编译 C++→HTML)
2222
const BLOCK_LANG = { html: "html", py: "py", py3: "py", cpp: "cpp", cxx: "cpp" };

‎android/js/store.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
"use strict";
2424

2525
const KEY = "HICODE_DATA";
26-
const STORE_VERSION = "v3.66";
26+
const STORE_VERSION = "H1.00";
2727

2828
function uuid() {
2929
return "h" + Date.now().toString(36) + Math.random().toString(36).slice(2, 8);

0 commit comments

Comments
 (0)