-
Notifications
You must be signed in to change notification settings - Fork 107
Open
Labels
Description
Please provide details about:
- What you're trying to do
- I'm trying to use a custom CSS file to fine-tune the default ones used for the preview.
- For convenience I use the setting
asciidoc.preview.stylein.vscode/settings.json.
- What happened
- With a configured custom preview style the default styles are omitted, so my custom preview style cannot fine-tune as the settings I'd like to change are not loaded anymore AND it breaks basic formatting e.g alignment in table cells (maybe it would be an idea to extract core formatting into a dedicated style-sheet).
- I'd need to copy the default one and add my settings at the end...
- What you expected to happen
- I'd prefer the custom styles to be not omitted from the preview
- or this could be an optional setting (which could be set in a way to be backwards compatible) if one wants to use the custom preview style exclusively.
Vscode Version: 1.106.0 (Universal)
Commit: ac4cbdf48759c7d8c3eb91ffe6bb04316e263c57
Date: 2025-11-11T16:02:25.943Z
Electron: 37.7.0
ElectronBuildId: 12597478
Chromium: 138.0.7204.251
Node.js: 22.20.0
V8: 13.8.258.32-electron.0
OS: Darwin arm64 25.1.0
asciidoctor.ascidoctor-vscode: v3.4.5
The reason seems to be here:
asciidoctor-vscode/src/asciidoctorWebViewConverter.ts
Lines 597 to 604 in 5179080
| if (config.previewStyle === '') { | |
| const builtinStylesheet = config.useEditorStylesheet | |
| ? 'asciidoctor-editor.css' | |
| : 'asciidoctor-default.css' | |
| baseStyles.push( | |
| `<link rel="stylesheet" type="text/css" href="${webviewResourceProvider.asMediaWebViewSrc('media', builtinStylesheet)}">`, | |
| ) | |
| } |
Reactions are currently unavailable