Prototyping Markdown Preview Synchronization With Editors (#18762)

* Adds command to post a message to an html preview

**Bug**
There is currently no easy way to communicate with an html preview document after the preview has been created.

**Fix**
Adds a command called `vscode.htmlPreview.postMessage` to post a message to a visible html preview. This message will only be posted if the target preview is visible.

Inside the preview, the event is recieved using the standard dom event:

* Remove logging

* proto

Continue proto

* clean up rendering

* Gate prototype

* Fix gating

* Remove public command

* Change setting name

* Added current position indicator

* Reveal center
This commit is contained in:
Matt Bierner
2017-01-18 17:58:45 -08:00
committed by GitHub
parent 5dc2fb8c30
commit b29ef9b4e8
9 changed files with 244 additions and 52 deletions

View File

@@ -15,6 +15,20 @@ body.scrollBeyondLastLine {
margin-bottom: calc(100vh - 22px);
}
.code-active-line {
position: relative;
}
.code-active-line:before {
content: "";
display: block;
position: absolute;
top: 0;
left: -12px;
height: 100%;
border-left: 3px solid #4080D0;
}
img {
max-width: 100%;
max-height: 100%;