Skip to content
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,10 @@ node_modules/
pagefind/
static/pagefind/

# Auto-generated docs (by scripts/sync-docs.py from docs/source_en & docs/source_zh)
content/docs/components/
content/docs/usage-guide/

# ============================================================================
# Operating System
# ============================================================================
Expand Down
75 changes: 75 additions & 0 deletions assets/css/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,40 @@ header,
color: var(--twinkle-primary) !important;
}

/* Force horizontal navbar at md breakpoint (768px) instead of lg (1024px) */
@media (min-width: 768px) {
/* Hide hamburger button */
label[for="nav-toggle"] {
display: none !important;
}
/* Show nav menu horizontally */
#nav-menu {
display: flex !important;
width: auto !important;
padding-bottom: 0 !important;
gap: 0.25rem;
}
.navbar-nav {
text-align: left;
}
.nav-link {
padding: 0.5rem 0.6rem;
font-size: 0.9rem;
}
}

/* Show docs sidebar at md breakpoint (768px) instead of lg (1024px) */
@media (min-width: 768px) and (max-width: 1023px) {
.hb-sidebar-container {
position: sticky !important;
top: 4rem !important;
transform: none !important;
width: 16rem !important;
flex-shrink: 0 !important;
align-self: flex-start !important;
}
}

/* ─────────────────────────────────────────────────────────────────────────────
Footer - Light
───────────────────────────────────────────────────────────────────────────── */
Expand Down Expand Up @@ -551,3 +585,44 @@ footer {
background: #0f172a !important;
border-color: #334155;
}

/* ─────────────────────────────────────────────────────────────────────────────
Cookbook (Showcase) - Two-Column Card Grid
───────────────────────────────────────────────────────────────────────────── */
.page-body .container.grid {
max-width: 72rem !important;
grid-template-columns: 1fr !important;
}

@media (min-width: 768px) {
.page-body .container.grid {
grid-template-columns: repeat(2, 1fr) !important;
}
}

/* Compact card image area */
.page-body .container.grid .aspect-\[16\/9\] {
aspect-ratio: 16/10 !important;
}

/* Reduce card padding for compactness */
.page-body .container.grid .p-8 {
padding: 1.25rem !important;
}

.page-body .container.grid .space-y-4 {
gap: 0.5rem !important;
}

/* ─────────────────────────────────────────────────────────────────────────────
Stats Block: force 2×2 grid instead of 4-column to prevent text truncation
───────────────────────────────────────────────────────────────────────────── */
.blox-stats .grid {
grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

.blox-stats .grid h3 {
font-size: clamp(1.5rem, 4vw, 2.5rem) !important;
white-space: nowrap;
}

6 changes: 3 additions & 3 deletions assets/jsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
"baseUrl": ".",
"paths": {
"*": [
"../../../../Library/Caches/hugo_cache/modules/filecache/modules/pkg/mod/github.com/!hugo!blox/kit/modules/blox@v0.0.0-20260124040029-77f7678f08ac/assets/*",
"../../../../Library/Caches/hugo_cache/modules/filecache/modules/pkg/mod/github.com/!hugo!blox/kit/modules/blox@v0.0.0-20260124040029-77f7678f08ac/blox/*",
"../../../../Library/Caches/hugo_cache/modules/filecache/modules/pkg/mod/github.com/!hugo!blox/kit/modules/blox@v0.0.0-20260124040029-77f7678f08ac/blox/shared/js/*"
"../../../../../../../root/.cache/hugo_cache/modules/filecache/modules/pkg/mod/github.com/!hugo!blox/kit/modules/blox@v0.0.0-20260124040029-77f7678f08ac/assets/*",
"../../../../../../../root/.cache/hugo_cache/modules/filecache/modules/pkg/mod/github.com/!hugo!blox/kit/modules/blox@v0.0.0-20260124040029-77f7678f08ac/blox/*",
"../../../../../../../root/.cache/hugo_cache/modules/filecache/modules/pkg/mod/github.com/!hugo!blox/kit/modules/blox@v0.0.0-20260124040029-77f7678f08ac/blox/shared/js/*"
]
}
}
Expand Down
2 changes: 1 addition & 1 deletion config/_default/hugo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ timeout: 600000
taxonomies:
tag: tags
category: categories
author: authors

markup:
_merge: deep
related:
Expand Down
10 changes: 9 additions & 1 deletion config/_default/menus.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,26 @@ main:
- name: Home
url: /
weight: 10
- name: Quick Start
url: docs/getting-started/
weight: 15
- name: Documentation
url: docs/
weight: 20
- name: Blog
url: blog/
weight: 30
- name: Showcase
- name: Cookbook
url: showcase/
weight: 40
- name: Community
url: community/
weight: 50
Comment thread
tastelikefeet marked this conversation as resolved.
- name: GitHub
url: https://github.com/modelscope/twinkle
weight: 60
params:
icon: github

sidebar:
- identifier: more
Expand Down
10 changes: 9 additions & 1 deletion config/_default/menus.zh.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,26 @@ main:
- name: 首页
url: /
weight: 10
- name: 快速上手
url: docs/getting-started/
weight: 15
- name: 文档
url: docs/
weight: 20
- name: 博客
url: blog/
weight: 30
- name: 案例展示
- name: Cookbook
url: showcase/
weight: 40
- name: 社区
url: community/
weight: 50
Comment thread
tastelikefeet marked this conversation as resolved.
- name: GitHub
url: https://github.com/modelscope/twinkle
weight: 60
params:
icon: github

sidebar:
- identifier: more
Expand Down
82 changes: 15 additions & 67 deletions config/_default/params.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -95,9 +95,9 @@ hugoblox:
language_switcher: true
# Call-to-action button
cta:
enable: true
text: "GitHub"
url: "https://github.com/modelscope/twinkle"
enable: false
text: ""
url: ""

# ────────────────────────────────────────────────────────────────────────────
# FOOTER
Expand All @@ -106,7 +106,7 @@ hugoblox:
footer:
# Footer style variant
style: minimal # minimal | columns | centered
language_switcher: true
language_switcher: false
# Custom footer text (HTML supported)
text: ""

Expand All @@ -129,7 +129,7 @@ hugoblox:
# ────────────────────────────────────────────────────────────────────────────
seo:
# Browser tab title override (defaults to identity.name if not set)
title: ""
title: "Twinkle – LLM Training Framework by ModelScope"
# For local_business identity type only
location:
address:
Expand Down Expand Up @@ -180,51 +180,20 @@ hugoblox:
quick_actions: []

# ────────────────────────────────────────────────────────────────────────────
# COMMENTS
# User comments system
# COMMENTS (disabled)
# ────────────────────────────────────────────────────────────────────────────
comments:
enable: false
provider: "" # giscus | disqus
giscus:
repo: ""
repo_id: ""
category: ""
category_id: ""
disqus:
shortname: ""

# ────────────────────────────────────────────────────────────────────────────
# ANALYTICS
# Traffic and behavior analytics
# ────────────────────────────────────────────────────────────────────────────
analytics:
google:
measurement_id: "" # Google Analytics 4: G-XXXXXXXXXX
google_tag_manager:
container_id: "" # GTM-XXXXXXX
plausible:
domain: ""
fathom:
site_id: ""
pirsch:
site_id: ""
clarity:
project_id: ""
baidu:
site_id: ""
# ANALYTICS (none configured)
# ────────────────────────────────────────────────────────────────────────────
analytics: {}

# ────────────────────────────────────────────────────────────────────────────
# VERIFICATION
# Search engine site verification codes
# VERIFICATION (none configured)
# ────────────────────────────────────────────────────────────────────────────
verification:
google: ""
bing: ""
baidu: ""
yandex: ""
pinterest: ""
naver: ""
verification: {}

# ────────────────────────────────────────────────────────────────────────────
# REPOSITORY
Expand All @@ -246,46 +215,25 @@ hugoblox:
address_format: en-us

# ────────────────────────────────────────────────────────────────────────────
# SECURITY
# Security headers and policies (requires Netlify integration)
# SECURITY (defaults)
# ────────────────────────────────────────────────────────────────────────────
security:
csp:
policy: ""
report_only: false
frame_options: allow # deny | sameorigin | allow - allow enables iframe embedding
permissions_policy: ""
frame_options: allow

# ────────────────────────────────────────────────────────────────────────────
# PRIVACY
# Privacy and compliance features
# PRIVACY (disabled)
# ────────────────────────────────────────────────────────────────────────────
privacy:
enable: false
anonymize_analytics: true

# ────────────────────────────────────────────────────────────────────────────
# DEBUG
# Development and debugging (hidden in production)
# DEBUG (disabled in production)
# ────────────────────────────────────────────────────────────────────────────
debug:
enable: false
hud:
position: bottom-left # top-left | top-right | bottom-left | bottom-right
opacity: 1.0
export_logs: true

# ────────────────────────────────────────────────────────────────────────────
# PREMIUM
# Premium features and creator program (affiliates)
# ────────────────────────────────────────────────────────────────────────────
pro:
# Hide "Powered by HugoBlox" attribution
# Requires: HugoBlox Premium to support HugoBlox via alternative means
# Note: Even with Premium, you can keep this false to support open source!
# Get Premium: https://hugoblox.com/premium
hide_attribution: false

# Affiliate referral code for rewards program
# Join affiliate program: https://hugoblox.com/affiliates
affiliate_code: ""
Loading
Loading