Skip to content

Commit 0324c77

Browse files
authored
Clarify CSS partial handling in CLAUDE.md
1 parent e4f01cb commit 0324c77

1 file changed

Lines changed: 16 additions & 14 deletions

File tree

CLAUDE.md

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# CLAUDE.md
22

3-
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
3+
This file provides guidance to Claude Code (claude. ai/code) when working with code in this repository.
44

55
## Project Overview
66

@@ -17,7 +17,7 @@ bundle exec rake build
1717
# Serve locally at http://localhost:4000/
1818
bundle exec rake serve
1919

20-
# Alternative: Jekyll direct serve with incremental builds
20+
# Alternative: Jekyll direct serve with incremental builds
2121
bundle exec jekyll serve --watch --future --incremental
2222
```
2323

@@ -37,17 +37,17 @@ bundle exec rake lint # Markdown linter
3737

3838
# Post-build validation (requires built site)
3939
bundle exec rake check:markup # Validate HTML markup
40-
bundle exec rake check:links # Check for broken links (needs local server running)
40+
bundle exec rake check: links # Check for broken links (needs local server running)
4141
```
4242

4343
### Creating News Posts
4444

4545
```bash
4646
# Create news post template for specific language
47-
bundle exec rake new_post:en # English
47+
bundle exec rake new_post: en # English
4848
bundle exec rake new_post:ja # Japanese
49-
bundle exec rake new_post:fr # French
50-
# ... etc for: bg, de, es, id, it, ko, pl, pt, ru, tr, vi, zh_cn, zh_tw
49+
bundle exec rake new_post: fr # French
50+
# ... etc for: bg, de, es, id, it, ja, ko, pl, pt, ru, tr, vi, zh_cn, zh_tw
5151
```
5252

5353
## Architecture & Structure
@@ -61,7 +61,7 @@ bundle exec rake new_post:fr # French
6161

6262
### Jekyll Configuration
6363

64-
- **Markdown**: Kramdown with Rouge syntax highlighting
64+
- **Markdown**: Kramdown with Rouge syntax highlighting
6565
- **Timezone**: UTC (critical for news posts)
6666
- **Permalinks**: Pretty URLs
6767
- **Build output**: `_site/` directory
@@ -71,10 +71,10 @@ bundle exec rake new_post:fr # French
7171
- `_layouts/`: Page templates (default, homepage, news_post, news_archive_month, etc.)
7272
- `_includes/`: Reusable components (header, footer, navigation, toc, sidebar)
7373
- `_plugins/`: Custom Jekyll plugins (news archive generator, posted_by, translation_status)
74-
- `_data/`: YAML data files (releases.yml, downloads.yml, branches.yml, locales/)
74+
- `_data/`: YAML data files (releases.yml, downloads. yml, branches.yml, locales/)
7575
- `lib/`: Ruby utilities (linter, markup checker, draft release)
7676
- `test/`: Test files for plugins and linter
77-
- `stylesheets/`: CSS source (includes partials in underscored directories like `_components/` and files starting with `_`)
77+
- `stylesheets/`: CSS source (includes partials that Jekyll excludes by default: directories prefixed with `_` and files starting with `_`)
7878
- `_javascripts_src/`: TypeScript source files
7979
- `javascripts/`: Compiled JavaScript output
8080

@@ -85,7 +85,9 @@ The site uses a custom Tailwind configuration with:
8585
- **Semantic color tokens** via CSS variables (defined in `stylesheets/semantic-colors.css`)
8686
- Accessible via `bg-semantic-*`, `text-semantic-*`, `border-semantic-*` classes
8787
- Automatically handles light/dark mode via `prefers-color-scheme`
88-
- **Incremental Build**: Uses `_plugins/postcss_incremental_fix.rb` to trigger PostCSS rebuilds when HTML, Markdown, or CSS partials (e.g., `_*.css` or files within `_*` directories) are modified during `jekyll serve --incremental`
88+
- **Incremental Build**: Uses `_plugins/postcss_incremental_fix.rb` to trigger PostCSS rebuilds during `jekyll serve --incremental` when CSS partials are modified
89+
- **CSS partials**: Files/directories that Jekyll normally excludes (underscore-prefixed like `_components/` or `_variables. css`) but are imported by main stylesheets
90+
- The plugin watches these excluded partials and forces a rebuild when they change, ensuring Tailwind processes updated styles
8991
- **Brand colors**: Ruby (red) and Gold palettes
9092
- **Typography plugin** for prose styling
9193
- **Custom breakpoints**: Container max-widths configured for content layouts
@@ -131,7 +133,7 @@ default.html (base)
131133
```yaml
132134
---
133135
layout: page
134-
title: "Page Title"
136+
title: "Page Title"
135137
lang: en
136138
---
137139
```
@@ -143,7 +145,7 @@ layout: news_post
143145
title: "Post Title"
144146
author: "Author Name"
145147
translator: "Translator Name" # Required for non-original language
146-
date: YYYY-MM-DD HH:MM:SS +0000 # Must be UTC
148+
date: YYYY-MM-DD HH:MM: SS +0000 # Must be UTC
147149
lang: en
148150
---
149151
```
@@ -176,8 +178,8 @@ lang: en
176178
2. **File naming**: News posts must be `YYYY-MM-DD-title.md` matching the date in front matter
177179
3. **Language codes**: Must match directory structure (e.g., `lang: en` for files in `/en/`)
178180
4. **Translator field**: Required for translated news posts, not for original posts
179-
5. **Line endings**: LF only, no CRLF
180-
6. **Release posts**: Must include valid SHA checksums if referencing downloads
181+
5. **Line endings**: LF only, no CRLF
182+
6. **Release posts**: Must include valid SHA checksums if referencing downloads
181183

182184
## CI/CD
183185

0 commit comments

Comments
 (0)