Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CodeBlock loses syntax highlighting on update #640

Open
KeithALane opened this issue Nov 12, 2024 · 0 comments
Open

CodeBlock loses syntax highlighting on update #640

KeithALane opened this issue Nov 12, 2024 · 0 comments
Labels
bug 🐛 Something isn't working

Comments

@KeithALane
Copy link
Contributor

Describe the Bug

When you Update-PodeWebText a PodeWebCodeBlock it will lose the syntax highlighting

Steps To Reproduce

Update-PodeWebText -Id "UpdateBOMCommon" -Value "SELECT 'After', Name from master.sys.databases where database_id <=4 "
New-PodeWebCodeBlock -id "UpdateBOMCommon" -Value "SELECT 'Before', Name from master.sys.databases where database_id <=4" -Language "SQL"

Expected Behavior

Syntax highlighting/Language should be preserved

Screenshots

20241111 - Pode Web SyntaxHighlighting1
20241111 - Pode Web SyntaxHighlighting2

Platform

  • OS: [e.g. iOS, Windows]
  • Browser: [e.g. Chrome, Safari]
  • Versions:
    • Pode: v2.9.0
    • Pode.Web: v0.8.3
    • PowerShell: v7.4.5

Additional Context

The solution for this is going to be impacted by the changes you are planning for 1.0 vs 0.8
I think fixing it in 1.0 it might be as easy as adding the language parameter to
"/src/public/actions.ps1" - Update-PodeWebText but I haven't tested that yet.

@KeithALane KeithALane added the bug 🐛 Something isn't working label Nov 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something isn't working
Projects
Status: Backlog
Development

No branches or pull requests

1 participant