Skip to content
This repository has been archived by the owner on Jul 10, 2024. It is now read-only.

Commit

Permalink
fried chicken rice
Browse files Browse the repository at this point in the history
  • Loading branch information
technicat committed Aug 10, 2023
1 parent b41d4af commit afea5cf
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion assets/json/dish/ricedishes.json
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
]
},
"Pinyin": "zhà jī fàn",
"description": "{炸} is *deep-fried*, {雞} is *chicken*, and {飯} is *rice* (cooked), so is *fried chicken rice*."
"description": "{炸} is *deep-fried*, {雞} is *chicken*, and {飯} is *rice* (cooked), so 炸雞飯 is *fried chicken rice*."
},
"images": [
{
Expand Down
8 changes: 7 additions & 1 deletion hugo.scm
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@
(define (write-dish-tags dish out)
(let ((tags (tags dish)))
(if tags
(let ((qtags (map (lambda (tag) #"\"~tag\"") tags)))
(let ((qtags (map (lambda (tag) (tag-display tag)) tags)))
(write-string #"tags: [~(comma-list qtags)]" out)))
(newline out)))

Expand All @@ -124,6 +124,12 @@
(write-string #"categories: [~(comma-list qcats)]" out)
(newline out)))))

(define (tag-display tag)
(let ((word (hash-table-get words tag)))
(if word
#"\"~tag ~(english word)\""
#"\"tag\"")))

(define (write-dish-date dish out)
(write-string #"showDate: false" out)
(newline out))
Expand Down

0 comments on commit afea5cf

Please sign in to comment.