diff options
| author | Sadeep Madurange <sadeep@asciimx.com> | 2025-10-25 11:48:31 +0800 |
|---|---|---|
| committer | Sadeep Madurange <sadeep@asciimx.com> | 2025-10-25 11:48:31 +0800 |
| commit | 47fc631c289adb367cf25479c693b5aa8500a6be (patch) | |
| tree | 1965427fa7d00a902bae7c0b8c3973b093c26ec8 /projects.html | |
| parent | dd08a2afcd2b008186096e2f41f26102854372e5 (diff) | |
| download | www-47fc631c289adb367cf25479c693b5aa8500a6be.tar.gz | |
Use variable for project column length.
Diffstat (limited to 'projects.html')
| -rw-r--r-- | projects.html | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/projects.html b/projects.html index 5f06646..4f8ce8e 100644 --- a/projects.html +++ b/projects.html @@ -4,11 +4,12 @@ title: Projects --- <table> - {% assign rows = site.projects.size | divided_by: 2.0 | ceil %} + {% assign n = 2 %} + {% assign rows = site.projects.size | divided_by: n | ceil %} {% for i in (1..rows) %} <tr> - {% assign offset = forloop.index0 | times: 2 %} - {% for item in site.projects limit:2 offset:offset %} + {% assign offset = forloop.index0 | times: n %} + {% for item in site.projects limit:n offset:offset %} <td class="project-item"> {% assign parts = item.url | split: '/' %} <img src="{{ parts[2] }}/{{ item.thumbnail }}" alt="{{ item.title }}"> |
