Skip to content

Highlight SCSS filters in native Slim - #11

Merged
devin-ai-integration[bot] merged 3 commits into
masterfrom
devin/1796211600-slim-scss-filter
Dec 2, 2026
Merged

devin-ai-integration[bot] merged 3 commits into
masterfrom
devin/1796211600-slim-scss-filter

Conversation

@tiensonqin

@tiensonqin tiensonqin commented Dec 2, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Highlight Slim scss: filters with the existing SCSS grammar. Use the first content line's indentation as the filter margin, preserve source offsets, and resume Slim parsing on dedent.
  • Keep SCSS comment delimiters inside the filter. Leave out the standalone brace auto-indent hook so it cannot move a closing brace outside the filter.
  • Cover highlighting, brace input, and block comments within the filter in the native catalog suite.

Verification

  • dune build @all, dune runtest, dune build @melange-tests, and native catalog @all @runtest passed.
  • The signed macOS SDL3/Metal smoke passed at 331925c on the same Logseq host source as the baseline (f30d1c6ef). Dedent restored Slim tag styling, and Copy preserved all 106 fixture bytes. Brace auto-indent and block comments are covered at the editor-state boundary.
  • In the local Web/master CodeMirror 5.65.18 harness, #c00 is pink. The native catalog recognizes it as a color token, but the host draws it in body ink. Standalone SCSS reproduced that palette gap on both signed builds.
  • A selection spanning SCSS and Slim can still place the comment closer outside the filter. The shared command also behaves this way in existing CSS filters. Review discussion

Slim scss filter before
Slim scss filter on the final signed candidate

Link to Devin session: https://app.devin.ai/sessions/97b992ac6a93453796bebbf311e43f75
Open in Devin Desktop: https://app.devin.ai/desktop/session/97b992ac6a93453796bebbf311e43f75?variant=devin
Requested by: @tiensonqin


🟢 Devin Review found nothing to fix · View findings · Follow Devin's work

Devin Review

@devin-ai-integration

Copy link
Copy Markdown

I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".

  • Disable automatic comment, CI, and merge conflict monitoring

@devin-ai-integration devin-ai-integration Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note

Newer findings are available below. Devin Review posted a newer report on this PR, in addition to the findings presented here.

Devin Review found 3 findings. Devin fixed 2 findings; 1 finding is left for you to triage below.

Fixed by Devin (2)
  • Block comment shortcut ignores SCSS selections — Selecting color: red; inside a Slim SCSS rule reproduced the no-op. The mounted language now provides SCSS comment delimiters and leaves the standalone indent-on-input hook disabled. Both editor-state regressions pass.
  • Auto-indent breaks Slim SCSS filters — A typing transaction before a selector’s opening { reproduced the unwanted dedent. Mounting the bare SCSS grammar preserves highlighting and prevents the standalone indent-on-input hook from changing Slim indentation. The catalog regression checks the exact resulting document.

View findings in Devin Review · Follow Devin's work

Devin Review

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Devin Review

@devin-ai-integration
devin-ai-integration Bot merged commit 39e3b1e into master Dec 2, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant