📝 Improve the user guide Template snippet chapter code display (#15402)

https://github.com/siyuan-note/siyuan/pull/15345
This commit is contained in:
Jeffrey Chen 2025-08-02 09:43:08 +08:00 committed by GitHub
parent 9a89a0eb4c
commit 2b9a2df233
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 136 additions and 139 deletions

View file

@ -6,7 +6,7 @@
"id": "20201204184532-3qm9l8n", "id": "20201204184532-3qm9l8n",
"title": "Template snippet", "title": "Template snippet",
"type": "doc", "type": "doc",
"updated": "20250331163727" "updated": "20250801152837"
}, },
"Children": [ "Children": [
{ {
@ -57,7 +57,7 @@
"HeadingLevel": 2, "HeadingLevel": 2,
"Properties": { "Properties": {
"id": "20210104091444-jy56z0p", "id": "20210104091444-jy56z0p",
"updated": "20250331163727" "updated": "20250801152821"
}, },
"Children": [ "Children": [
{ {
@ -215,7 +215,7 @@
"ListData": {}, "ListData": {},
"Properties": { "Properties": {
"id": "20210104091444-mwbvc9m", "id": "20210104091444-mwbvc9m",
"updated": "20250331163727" "updated": "20250801152821"
}, },
"Children": [ "Children": [
{ {
@ -421,7 +421,7 @@
}, },
"Properties": { "Properties": {
"id": "20210121193829-wfzsf6m", "id": "20210121193829-wfzsf6m",
"updated": "20250331163727" "updated": "20250801152749"
}, },
"Children": [ "Children": [
{ {
@ -454,7 +454,7 @@
"Properties": { "Properties": {
"id": "20241213215602-dk7iion", "id": "20241213215602-dk7iion",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20250331163727" "updated": "20250801152749"
}, },
"Children": [ "Children": [
{ {
@ -462,11 +462,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{$today := now | date \"20060102150405\"}\n.action{$blocks := queryBlocks \"SELECT * FROM blocks WHERE content LIKE '?' AND updated \u003e '?' LIMIT ?\" \"%foo%\" $today \"3\"}\n" "Data": ".action{ $today := now | date \"20060102150405\" }\n.action{ $blocks := queryBlocks \"SELECT * FROM blocks WHERE content LIKE '?' AND updated \u003e '?' LIMIT ?\" \"%foo%\" $today \"3\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -485,7 +486,7 @@
}, },
"Properties": { "Properties": {
"id": "20250331163529-vixv1we", "id": "20250331163529-vixv1we",
"updated": "20250331163604" "updated": "20250801152801"
}, },
"Children": [ "Children": [
{ {
@ -517,7 +518,7 @@
"IsFencedCodeBlock": true, "IsFencedCodeBlock": true,
"Properties": { "Properties": {
"id": "20250331163550-2r69a54", "id": "20250331163550-2r69a54",
"updated": "20250331163604" "updated": "20250801152801"
}, },
"Children": [ "Children": [
{ {
@ -525,11 +526,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{getBlock \"20250331163529-vixv1we\"}\n" "Data": ".action{ getBlock \"20250331163529-vixv1we\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -548,7 +550,7 @@
}, },
"Properties": { "Properties": {
"id": "20210504093232-vukp34t", "id": "20210504093232-vukp34t",
"updated": "20241224162810" "updated": "20250801152807"
}, },
"Children": [ "Children": [
{ {
@ -581,7 +583,7 @@
"Properties": { "Properties": {
"id": "20241213215606-a1mq6zf", "id": "20241213215606-a1mq6zf",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20241224162810" "updated": "20250801152807"
}, },
"Children": [ "Children": [
{ {
@ -589,11 +591,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": " .action{querySpans \"SELECT * FROM spans LIMIT ?\" \"3\"}\n" "Data": ".action{ querySpans \"SELECT * FROM spans LIMIT ?\" \"3\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -612,7 +615,7 @@
}, },
"Properties": { "Properties": {
"id": "20241213214939-he4wmcd", "id": "20241213214939-he4wmcd",
"updated": "20241213214939" "updated": "20250801152813"
}, },
"Children": [ "Children": [
{ {
@ -645,7 +648,7 @@
"Properties": { "Properties": {
"id": "20241213215554-rox3jk7", "id": "20241213215554-rox3jk7",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20241213215554" "updated": "20250801152813"
}, },
"Children": [ "Children": [
{ {
@ -653,11 +656,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": " .action{querySQL \"SELECT * FROM refs LIMIT 3\"}\n" "Data": ".action{ querySQL \"SELECT * FROM refs LIMIT 3\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -676,7 +680,7 @@
}, },
"Properties": { "Properties": {
"id": "20241212102027-j293sei", "id": "20241212102027-j293sei",
"updated": "20241213215714" "updated": "20250801152821"
}, },
"Children": [ "Children": [
{ {
@ -709,7 +713,7 @@
"Properties": { "Properties": {
"id": "20241213215714-u0j3i4k", "id": "20241213215714-u0j3i4k",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20241213215714" "updated": "20250801152821"
}, },
"Children": [ "Children": [
{ {
@ -717,11 +721,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{ (statBlock .id).RuneCount} .action{ (statBlock .id).WordCount}\n" "Data": ".action{ (statBlock .id).RuneCount }\n.action{ (statBlock .id).WordCount }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -1411,7 +1416,8 @@
"Type": "NodeHeading", "Type": "NodeHeading",
"HeadingLevel": 2, "HeadingLevel": 2,
"Properties": { "Properties": {
"id": "20210104091444-xz57sof" "id": "20210104091444-xz57sof",
"updated": "20250801152837"
}, },
"Children": [ "Children": [
{ {
@ -1428,36 +1434,26 @@
"ID": "20210104091444-cclnk66", "ID": "20210104091444-cclnk66",
"Type": "NodeCodeBlock", "Type": "NodeCodeBlock",
"IsFencedCodeBlock": true, "IsFencedCodeBlock": true,
"CodeBlockFenceChar": 96,
"CodeBlockFenceLen": 3,
"CodeBlockOpenFence": "YGBg",
"CodeBlockInfo": "cGxhaW50ZXh0",
"CodeBlockCloseFence": "YGBg",
"Properties": { "Properties": {
"id": "20210104091444-cclnk66" "id": "20210104091444-cclnk66",
"updated": "20250801152837"
}, },
"Children": [ "Children": [
{ {
"Type": "NodeCodeBlockFenceOpenMarker", "Type": "NodeCodeBlockFenceOpenMarker",
"Data": "```", "Data": "```"
"CodeBlockFenceLen": 3
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker", "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "cGxhaW50ZXh0" "CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"ID": "20220307092214-3y1eex2",
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{$before := (div (now.Sub (toDate \"2006-01-02\" \"2020-02-19\")).Hours 24)}\n\n.action{$after := (div ((toDate \"2006-01-02\" \"2048-02-19\").Sub now).Hours 24)}\nToday is `.action{now | date \"2006-01-02\"}`.\n\n* `.action{$before}` days have passed since `2020-02-19`\n* There are `.action{$after}` days left from `2048-02-19`\n", "Data": ".action{ $before := (div (now.Sub (toDate \"2006-01-02\" \"2020-02-19\")).Hours 24) }\n.action{ $after := (div ((toDate \"2006-01-02\" \"2048-02-19\").Sub now).Hours 24) }\nToday is `.action{ now | date \"2006-01-02\" }`.\n\n* `.action{ $before }` days have passed since `2020-02-19`\n* There are `.action{ $after }` days left from `2048-02-19`\n"
"Properties": {
"id": "20220307092214-3y1eex2"
}
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
"Data": "```", "Data": "```"
"CodeBlockFenceLen": 3
} }
] ]
}, },

View file

@ -6,7 +6,7 @@
"id": "20201204181006-7bkppue", "id": "20201204181006-7bkppue",
"title": "模板片段", "title": "模板片段",
"type": "doc", "type": "doc",
"updated": "20250331163228" "updated": "20250801152724"
}, },
"Children": [ "Children": [
{ {
@ -69,7 +69,7 @@
"HeadingLevel": 2, "HeadingLevel": 2,
"Properties": { "Properties": {
"id": "20210104091309-fhb549c", "id": "20210104091309-fhb549c",
"updated": "20250331163228" "updated": "20250801152510"
}, },
"Children": [ "Children": [
{ {
@ -237,7 +237,7 @@
"ListData": {}, "ListData": {},
"Properties": { "Properties": {
"id": "20210104091309-gjkg3u5", "id": "20210104091309-gjkg3u5",
"updated": "20250331163228" "updated": "20250801152510"
}, },
"Children": [ "Children": [
{ {
@ -443,7 +443,7 @@
}, },
"Properties": { "Properties": {
"id": "20210121193601-uwo8s5h", "id": "20210121193601-uwo8s5h",
"updated": "20250331163052" "updated": "20250801152331"
}, },
"Children": [ "Children": [
{ {
@ -476,7 +476,7 @@
"Properties": { "Properties": {
"id": "20210604111446-p6vadfc", "id": "20210604111446-p6vadfc",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20250331163052" "updated": "20250801152331"
}, },
"Children": [ "Children": [
{ {
@ -484,11 +484,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{$today := now | date \"20060102150405\"}\n.action{$blocks := queryBlocks \"SELECT * FROM blocks WHERE content LIKE '?' AND updated \u003e '?' LIMIT ?\" \"%foo%\" $today \"3\"}\n" "Data": ".action{ $today := now | date \"20060102150405\" }\n.action{ $blocks := queryBlocks \"SELECT * FROM blocks WHERE content LIKE '?' AND updated \u003e '?' LIMIT ?\" \"%foo%\" $today \"3\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -507,7 +508,7 @@
}, },
"Properties": { "Properties": {
"id": "20250331162928-53comqi", "id": "20250331162928-53comqi",
"updated": "20250331163228" "updated": "20250801152339"
}, },
"Children": [ "Children": [
{ {
@ -539,7 +540,7 @@
"IsFencedCodeBlock": true, "IsFencedCodeBlock": true,
"Properties": { "Properties": {
"id": "20250331163038-6j2ttlc", "id": "20250331163038-6j2ttlc",
"updated": "20250331163228" "updated": "20250801152339"
}, },
"Children": [ "Children": [
{ {
@ -547,11 +548,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{getBlock \"20250331162928-53comqi\"}\n" "Data": ".action{ getBlock \"20250331162928-53comqi\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -570,7 +572,7 @@
}, },
"Properties": { "Properties": {
"id": "20210504093313-4aoyxd0", "id": "20210504093313-4aoyxd0",
"updated": "20241224162826" "updated": "20250801152509"
}, },
"Children": [ "Children": [
{ {
@ -603,7 +605,7 @@
"Properties": { "Properties": {
"id": "20241213215337-rhkoc8k", "id": "20241213215337-rhkoc8k",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20241224162826" "updated": "20250801152509"
}, },
"Children": [ "Children": [
{ {
@ -611,11 +613,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": " .action{querySpans \"SELECT * FROM spans LIMIT ?\" \"3\"}\n" "Data": ".action{ querySpans \"SELECT * FROM spans LIMIT ?\" \"3\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -634,7 +637,7 @@
}, },
"Properties": { "Properties": {
"id": "20241213214733-ro4xcjm", "id": "20241213214733-ro4xcjm",
"updated": "20241213215421" "updated": "20250801152510"
}, },
"Children": [ "Children": [
{ {
@ -667,7 +670,7 @@
"Properties": { "Properties": {
"id": "20241213215240-f33bsqs", "id": "20241213215240-f33bsqs",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20241213215421" "updated": "20250801152510"
}, },
"Children": [ "Children": [
{ {
@ -675,11 +678,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": " .action{querySQL \"SELECT * FROM refs LIMIT 3\"}\n" "Data": ".action{ querySQL \"SELECT * FROM refs LIMIT 3\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -698,7 +702,7 @@
}, },
"Properties": { "Properties": {
"id": "20241212101708-0euo6is", "id": "20241212101708-0euo6is",
"updated": "20241213215655" "updated": "20250801152415"
}, },
"Children": [ "Children": [
{ {
@ -731,7 +735,7 @@
"Properties": { "Properties": {
"id": "20241212101810-6ffociu", "id": "20241212101810-6ffociu",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20241213215655" "updated": "20250801152415"
}, },
"Children": [ "Children": [
{ {
@ -739,11 +743,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{ (statBlock .id).RuneCount} .action{ (statBlock .id).WordCount}\n" "Data": ".action{ (statBlock .id).RuneCount }\n.action{ (statBlock .id).WordCount }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -1433,7 +1438,8 @@
"Type": "NodeHeading", "Type": "NodeHeading",
"HeadingLevel": 2, "HeadingLevel": 2,
"Properties": { "Properties": {
"id": "20210104091309-2p68yju" "id": "20210104091309-2p68yju",
"updated": "20250801152724"
}, },
"Children": [ "Children": [
{ {
@ -1450,36 +1456,26 @@
"ID": "20210104091309-9ppkq6j", "ID": "20210104091309-9ppkq6j",
"Type": "NodeCodeBlock", "Type": "NodeCodeBlock",
"IsFencedCodeBlock": true, "IsFencedCodeBlock": true,
"CodeBlockFenceChar": 96,
"CodeBlockFenceLen": 3,
"CodeBlockOpenFence": "YGBg",
"CodeBlockInfo": "cGxhaW50ZXh0",
"CodeBlockCloseFence": "YGBg",
"Properties": { "Properties": {
"id": "20210104091309-9ppkq6j" "id": "20210104091309-9ppkq6j",
"updated": "20250801152724"
}, },
"Children": [ "Children": [
{ {
"Type": "NodeCodeBlockFenceOpenMarker", "Type": "NodeCodeBlockFenceOpenMarker",
"Data": "```", "Data": "```"
"CodeBlockFenceLen": 3
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker", "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "cGxhaW50ZXh0" "CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"ID": "20220307091943-k77h7sb",
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{$before := (div (now.Sub (toDate \"2006-01-02\" \"2020-02-19\")).Hours 24)}\n\n.action{$after := (div ((toDate \"2006-01-02\" \"2048-02-19\").Sub now).Hours 24)}\n今天是 `.action{now | date \"2006-01-02\"}`。\n\n* 距离 `2020-02-19` 已经过去 `.action{$before}` 天\n* 距离 `2048-02-19` 还剩 `.action{$after}` 天\n", "Data": ".action{ $before := (div (now.Sub (toDate \"2006-01-02\" \"2020-02-19\")).Hours 24) }\n.action{ $after := (div ((toDate \"2006-01-02\" \"2048-02-19\").Sub now).Hours 24) }\n今天是 `.action{ now | date \"2006-01-02\" }`。\n\n* 距离 `2020-02-19` 已经过去 `.action{ $before }` 天\n* 距离 `2048-02-19` 还剩 `.action{ $after }` 天\n"
"Properties": {
"id": "20220307091943-k77h7sb"
}
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
"Data": "```", "Data": "```"
"CodeBlockFenceLen": 3
} }
] ]
}, },

View file

@ -6,7 +6,7 @@
"id": "20211226123004-dplpw0o", "id": "20211226123004-dplpw0o",
"title": "範本片段", "title": "範本片段",
"type": "doc", "type": "doc",
"updated": "20250331163725" "updated": "20250801152721"
}, },
"Children": [ "Children": [
{ {
@ -53,7 +53,7 @@
"HeadingLevel": 2, "HeadingLevel": 2,
"Properties": { "Properties": {
"id": "20211226123024-eyagqur", "id": "20211226123024-eyagqur",
"updated": "20250331163725" "updated": "20250801152602"
}, },
"Children": [ "Children": [
{ {
@ -208,7 +208,7 @@
"ListData": {}, "ListData": {},
"Properties": { "Properties": {
"id": "20211226123024-pjvw31z", "id": "20211226123024-pjvw31z",
"updated": "20250331163725" "updated": "20250801152602"
}, },
"Children": [ "Children": [
{ {
@ -414,7 +414,7 @@
}, },
"Properties": { "Properties": {
"id": "20211226123024-e42d7xq", "id": "20211226123024-e42d7xq",
"updated": "20250331163725" "updated": "20250801152535"
}, },
"Children": [ "Children": [
{ {
@ -447,7 +447,7 @@
"Properties": { "Properties": {
"id": "20241213215519-mfgruqs", "id": "20241213215519-mfgruqs",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20250331163725" "updated": "20250801152535"
}, },
"Children": [ "Children": [
{ {
@ -455,11 +455,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{$today := now | date \"20060102150405\"}\n.action{$blocks := queryBlocks \"SELECT * FROM blocks WHERE content LIKE '?' AND updated \u003e '?' LIMIT ?\" \"%foo%\" $today \"3\"}\n" "Data": ".action{ $today := now | date \"20060102150405\" }\n.action{ $blocks := queryBlocks \"SELECT * FROM blocks WHERE content LIKE '?' AND updated \u003e '?' LIMIT ?\" \"%foo%\" $today \"3\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -478,7 +479,7 @@
}, },
"Properties": { "Properties": {
"id": "20250331163425-s5u08ng", "id": "20250331163425-s5u08ng",
"updated": "20250331163515" "updated": "20250801152542"
}, },
"Children": [ "Children": [
{ {
@ -510,7 +511,7 @@
"IsFencedCodeBlock": true, "IsFencedCodeBlock": true,
"Properties": { "Properties": {
"id": "20250331163435-irjmxt9", "id": "20250331163435-irjmxt9",
"updated": "20250331163452" "updated": "20250801152542"
}, },
"Children": [ "Children": [
{ {
@ -518,11 +519,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{getBlock \"20250331163425-s5u08ng\"}\n" "Data": ".action{ getBlock \"20250331163425-s5u08ng\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -541,7 +543,7 @@
}, },
"Properties": { "Properties": {
"id": "20211226123024-69kddle", "id": "20211226123024-69kddle",
"updated": "20241224162821" "updated": "20250801152548"
}, },
"Children": [ "Children": [
{ {
@ -574,7 +576,7 @@
"Properties": { "Properties": {
"id": "20241213215524-9an3khb", "id": "20241213215524-9an3khb",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20241224162821" "updated": "20250801152548"
}, },
"Children": [ "Children": [
{ {
@ -582,11 +584,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": " .action{querySpans \"SELECT * FROM spans LIMIT ?\" \"3\"}\n" "Data": ".action{ querySpans \"SELECT * FROM spans LIMIT ?\" \"3\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -605,7 +608,7 @@
}, },
"Properties": { "Properties": {
"id": "20241213214930-4votv1n", "id": "20241213214930-4votv1n",
"updated": "20241213214930" "updated": "20250801152554"
}, },
"Children": [ "Children": [
{ {
@ -638,7 +641,7 @@
"Properties": { "Properties": {
"id": "20241213215530-f2iwrjz", "id": "20241213215530-f2iwrjz",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20241213215530" "updated": "20250801152554"
}, },
"Children": [ "Children": [
{ {
@ -646,11 +649,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": " .action{querySQL \"SELECT * FROM refs LIMIT 3\"}\n" "Data": ".action{ querySQL \"SELECT * FROM refs LIMIT 3\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -669,7 +673,7 @@
}, },
"Properties": { "Properties": {
"id": "20241212102019-gassjqt", "id": "20241212102019-gassjqt",
"updated": "20241213215707" "updated": "20250801152602"
}, },
"Children": [ "Children": [
{ {
@ -702,7 +706,7 @@
"Properties": { "Properties": {
"id": "20241213215707-lxpmd6b", "id": "20241213215707-lxpmd6b",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20241213215707" "updated": "20250801152602"
}, },
"Children": [ "Children": [
{ {
@ -710,11 +714,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{ (statBlock .id).RuneCount} .action{ (statBlock .id).WordCount}\n" "Data": ".action{ (statBlock .id).RuneCount }\n.action{ (statBlock .id).WordCount }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -1401,7 +1406,7 @@
"HeadingLevel": 2, "HeadingLevel": 2,
"Properties": { "Properties": {
"id": "20211226123024-yrgnp4o", "id": "20211226123024-yrgnp4o",
"updated": "20211225221841" "updated": "20250801152721"
}, },
"Children": [ "Children": [
{ {
@ -1416,7 +1421,7 @@
"IsFencedCodeBlock": true, "IsFencedCodeBlock": true,
"Properties": { "Properties": {
"id": "20211226123024-s56q5uh", "id": "20211226123024-s56q5uh",
"updated": "20211225221841" "updated": "20250801152721"
}, },
"Children": [ "Children": [
{ {
@ -1425,15 +1430,11 @@
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker", "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "cGxhaW50ZXh0" "CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"ID": "20220307092237-cf60m2o",
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{$before := (div (now.Sub (toDate \"2006-01-02\" \"2020-02-19\")).Hours 24)}\n\n.action{$after := (div ((toDate \"2006-01-02\" \"2048-02-19\").Sub now).Hours 24)}\n今天是 `.action{now | date \"2006-01-02\"}`。\n\n* 距離 `2020-02-19` 已經過去 `.action{$before}` 天\n* 距離 `2048-02-19` 還剩 `.action{$after}` 天\n", "Data": ".action{ $before := (div (now.Sub (toDate \"2006-01-02\" \"2020-02-19\")).Hours 24) }\n.action{ $after := (div ((toDate \"2006-01-02\" \"2048-02-19\").Sub now).Hours 24) }\n今天是 `.action{ now | date \"2006-01-02\" }`。\n\n* 距離 `2020-02-19` 已經過去 `.action{ $before }` 天\n* 距離 `2048-02-19` 還剩 `.action{ $after }` 天\n"
"Properties": {
"id": "20220307092237-cf60m2o"
}
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",

View file

@ -7,7 +7,7 @@
"id": "20240530101000-6x9ivi7", "id": "20240530101000-6x9ivi7",
"title": "テンプレートスニペット", "title": "テンプレートスニペット",
"type": "doc", "type": "doc",
"updated": "20250331163729" "updated": "20250801152939"
}, },
"Children": [ "Children": [
{ {
@ -66,7 +66,7 @@
"Properties": { "Properties": {
"ID": "20240530101000-5nvn9ad", "ID": "20240530101000-5nvn9ad",
"id": "20240530101000-pi05yzt", "id": "20240530101000-pi05yzt",
"updated": "20250331163729" "updated": "20250801152922"
}, },
"Children": [ "Children": [
{ {
@ -226,7 +226,7 @@
"ListData": {}, "ListData": {},
"Properties": { "Properties": {
"id": "20240530101000-by5hqnb", "id": "20240530101000-by5hqnb",
"updated": "20250331163729" "updated": "20250801152922"
}, },
"Children": [ "Children": [
{ {
@ -432,7 +432,7 @@
}, },
"Properties": { "Properties": {
"id": "20240530101000-0y2zlji", "id": "20240530101000-0y2zlji",
"updated": "20250331163729" "updated": "20250801152859"
}, },
"Children": [ "Children": [
{ {
@ -465,7 +465,7 @@
"Properties": { "Properties": {
"id": "20241213215628-5gixpmp", "id": "20241213215628-5gixpmp",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20250331163729" "updated": "20250801152859"
}, },
"Children": [ "Children": [
{ {
@ -473,11 +473,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{$today := now | date \"20060102150405\"}\n.action{$blocks := queryBlocks \"SELECT * FROM blocks WHERE content LIKE '?' AND updated \u003e '?' LIMIT ?\" \"%foo%\" $today \"3\"}\n" "Data": ".action{ $today := now | date \"20060102150405\" }\n.action{ $blocks := queryBlocks \"SELECT * FROM blocks WHERE content LIKE '?' AND updated \u003e '?' LIMIT ?\" \"%foo%\" $today \"3\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -496,7 +497,7 @@
}, },
"Properties": { "Properties": {
"id": "20250331163610-n3e9zft", "id": "20250331163610-n3e9zft",
"updated": "20250331163642" "updated": "20250801152903"
}, },
"Children": [ "Children": [
{ {
@ -528,7 +529,7 @@
"IsFencedCodeBlock": true, "IsFencedCodeBlock": true,
"Properties": { "Properties": {
"id": "20250331163621-j4iofxv", "id": "20250331163621-j4iofxv",
"updated": "20250331163642" "updated": "20250801152903"
}, },
"Children": [ "Children": [
{ {
@ -536,11 +537,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{getBlock \"20250331163610-n3e9zft\"}\n" "Data": ".action{ getBlock \"20250331163610-n3e9zft\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -559,7 +561,7 @@
}, },
"Properties": { "Properties": {
"id": "20240530101000-238ctfi", "id": "20240530101000-238ctfi",
"updated": "20241224162728" "updated": "20250801152909"
}, },
"Children": [ "Children": [
{ {
@ -592,7 +594,7 @@
"Properties": { "Properties": {
"id": "20241213215619-gkqs282", "id": "20241213215619-gkqs282",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20241224162728" "updated": "20250801152909"
}, },
"Children": [ "Children": [
{ {
@ -600,11 +602,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": " .action{querySpans \"SELECT * FROM spans LIMIT ?\" \"3\"}\n" "Data": ".action{ querySpans \"SELECT * FROM spans LIMIT ?\" \"3\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -623,7 +626,7 @@
}, },
"Properties": { "Properties": {
"id": "20241213215009-qrtc56j", "id": "20241213215009-qrtc56j",
"updated": "20241213215009" "updated": "20250801152915"
}, },
"Children": [ "Children": [
{ {
@ -656,7 +659,7 @@
"Properties": { "Properties": {
"id": "20241213215633-69ltmv1", "id": "20241213215633-69ltmv1",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20241213215633" "updated": "20250801152915"
}, },
"Children": [ "Children": [
{ {
@ -664,11 +667,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": " .action{querySQL \"SELECT * FROM refs LIMIT 3\"}\n" "Data": ".action{ querySQL \"SELECT * FROM refs LIMIT 3\" }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -687,7 +691,7 @@
}, },
"Properties": { "Properties": {
"id": "20241212102033-rn9u6t8", "id": "20241212102033-rn9u6t8",
"updated": "20241213215720" "updated": "20250801152922"
}, },
"Children": [ "Children": [
{ {
@ -720,7 +724,7 @@
"Properties": { "Properties": {
"id": "20241213215720-ueqpsna", "id": "20241213215720-ueqpsna",
"style": "line-height: 22px;", "style": "line-height: 22px;",
"updated": "20241213215720" "updated": "20250801152922"
}, },
"Children": [ "Children": [
{ {
@ -728,11 +732,12 @@
"Data": "```" "Data": "```"
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker" "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{ (statBlock .id).RuneCount} .action{ (statBlock .id).WordCount}\n" "Data": ".action{ (statBlock .id).RuneCount }\n.action{ (statBlock .id).WordCount }\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",
@ -1422,7 +1427,7 @@
"Properties": { "Properties": {
"ID": "20240530101000-h8k78jq", "ID": "20240530101000-h8k78jq",
"id": "20240530101000-3jhyboz", "id": "20240530101000-3jhyboz",
"updated": "20240530101000" "updated": "20250801152939"
}, },
"Children": [ "Children": [
{ {
@ -1436,9 +1441,8 @@
"Type": "NodeCodeBlock", "Type": "NodeCodeBlock",
"IsFencedCodeBlock": true, "IsFencedCodeBlock": true,
"Properties": { "Properties": {
"ID": "20240530101000-3sja27a",
"id": "20240530101000-v44hxz6", "id": "20240530101000-v44hxz6",
"updated": "20240530101000" "updated": "20250801152939"
}, },
"Children": [ "Children": [
{ {
@ -1447,11 +1451,11 @@
}, },
{ {
"Type": "NodeCodeBlockFenceInfoMarker", "Type": "NodeCodeBlockFenceInfoMarker",
"CodeBlockInfo": "cGxhaW50ZXh0" "CodeBlockInfo": "dGVtcGxhdGU="
}, },
{ {
"Type": "NodeCodeBlockCode", "Type": "NodeCodeBlockCode",
"Data": ".action{$before := (div (now.Sub (toDate \"2006-01-02\" \"2020-02-19\")).Hours 24)}\n\n.action{$after := (div ((toDate \"2006-01-02\" \"2048-02-19\").Sub now).Hours 24)}\n今日は `.action{now | date \"2006-01-02\"}` 日です。\n\n* `2020-02-19` 日から `.action{$before}` 日経過しました\n* `2048-02-19` 日まであと `.action{$after}` 日です\n" "Data": ".action{ $before := (div (now.Sub (toDate \"2006-01-02\" \"2020-02-19\")).Hours 24) }\n.action{ $after := (div ((toDate \"2006-01-02\" \"2048-02-19\").Sub now).Hours 24) }\n今日は `.action{ now | date \"2006-01-02\" }` 日です。\n\n* `2020-02-19` 日から `.action{ $before }` 日経過しました\n* `2048-02-19` 日まであと `.action{ $after }` 日です\n"
}, },
{ {
"Type": "NodeCodeBlockFenceCloseMarker", "Type": "NodeCodeBlockFenceCloseMarker",