Skip to content

Commit 2b2a3ef

Browse files
committed
Hide a few language tags in code blocks
1 parent 011043a commit 2b2a3ef

File tree

4 files changed

+11
-4
lines changed

4 files changed

+11
-4
lines changed

site/lib/src/extensions/code_block_processor.dart

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,13 @@ final class CodeBlockProcessor implements PageExtension {
9292
content: processedContent,
9393
textToCopy: codeLines.copyContent,
9494
language: language,
95+
languagesToHide: {
96+
'plaintext',
97+
'text',
98+
'console',
99+
'ps',
100+
'diff',
101+
},
95102
title: title,
96103
highlightLines: _parseNumbersAndRanges(rawHighlightLines),
97104
tag: tag != null ? CodeBlockTag.parse(tag) : null,

src/_includes/docs/test/integration/windows-example.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
```powershell
1+
```ps
22
PS C:\path\to\counter_app> flutter test .\integration_test\app_test.dart
33
Resolving dependencies...
44
Downloading packages...

src/content/deployment/android.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ If not, create one using one of the following methods:
139139

140140
On Windows, use the following command in PowerShell:
141141

142-
```powershell
142+
```ps
143143
keytool -genkey -v -keystore $env:USERPROFILE\upload-keystore.jks `
144144
-storetype JKS -keyalg RSA -keysize 2048 -validity 10000 `
145145
-alias upload

src/content/testing/native-debugging.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -356,11 +356,11 @@ test Flutter app. This update adds native code to debug.
356356
```
357357
1. In Windows, run this command in the command prompt.
358358

359-
```powershell
359+
```ps
360360
Get-ChildItem C:\dev\example\ -Rescurse | Where-Object {$_.LastWriteTime -gt (Get-Date).AddDays(-1)}
361361
```
362362

363-
```powershell
363+
```ps
364364
C:\dev\example\ios\Flutter\
365365

366366

0 commit comments

Comments
 (0)