Skip to content

Commit 7cc70fd

Browse files
committed
Update code block styling
1 parent 0abb2cf commit 7cc70fd

File tree

4 files changed

+21
-7
lines changed

4 files changed

+21
-7
lines changed

.vscode/docker.code-snippets

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,16 @@
3939
],
4040
"description": "Insert a Hugo tabs block with two tabs and snippet stops for names and content",
4141
},
42+
"Insert Hugo code block (no title)": {
43+
"prefix": ["codeblock", "block"],
44+
"body": ["```${1:json}", "$2", "```", ""],
45+
"description": "Insert a Hugo code block with an optional title",
46+
},
47+
"Insert Hugo code block (with title)": {
48+
"prefix": ["codeblock", "codettl", "block"],
49+
"body": ["```${1:json} {title=\"$2\"}", "$3", "```", ""],
50+
"description": "Insert a Hugo code block with an optional title",
51+
},
4252
"Insert a Button": {
4353
"prefix": ["button"],
4454
"body": ["{{< button url=\"$1\" text=\"$2\" >}}"],

layouts/_default/_markup/render-codeblock.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<div data-pagefind-ignore class="scroll-mt-2" x-data x-ref="root">
22
{{ with .Attributes.title }}
33
<div
4-
class="mb-0 rounded-sm bg-gray-100 p-2 text-sm text-gray-900 dark:bg-gray-900 dark:text-gray-200"
4+
class="mb-0 rounded-sm border-1 border-b bg-gray-50 p-2 text-sm text-gray-900 dark:border-gray-600 dark:bg-gray-900 dark:text-gray-200"
55
>
66
{{ . }}
77
</div>

package-lock.json

Lines changed: 9 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@
2121
"@material-symbols/svg-400": "^0.23.0",
2222
"@tailwindcss/cli": "^4.1.6",
2323
"@tailwindcss/nesting": "^0.0.0-insiders.565cd3e",
24-
"@tailwindcss/typography": "^0.5.15",
2524
"alpinejs": "^3.14.3",
2625
"tailwindcss": "^4.1.6"
2726
},
2827
"devDependencies": {
28+
"@tailwindcss/typography": "^0.5.16",
2929
"markdownlint": "^0.35.0",
3030
"prettier": "^3.3.3",
3131
"prettier-plugin-go-template": "^0.0.15",

0 commit comments

Comments
 (0)