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

what is the MarkdownLivePreview.css for? #89

Closed
michapixel opened this issue May 24, 2019 · 5 comments
Closed

what is the MarkdownLivePreview.css for? #89

michapixel opened this issue May 24, 2019 · 5 comments

Comments

@michapixel
Copy link

doesn't it style the livePreview? Seems not. Would it be possible to do this?

@michapixel
Copy link
Author

i mean thr right side, the real (browser) preview :)

@math2001
Copy link
Owner

Yes it does :) But you have to be aware that it's rendered in Sublime Text's Phantom, which isn't quite the same as a regular web browser. The phantom's documentation is on the minihtml page.

Would you want to contribute and submit a PR explaining this in a bit more details in the markdown live preview's documentation?

@rafaelbeckel
Copy link

For me it doesn't work as well. I'm using Material theme, but I want a white background in the preview. Also, the preview overflows the container.

I have tried:

html, body {
    background-color: #fff !important;
    width: 100%;
    overflow: wrap;
}

and it doesn't affect the viewer, even when I restart Sublime.

@math2001
Copy link
Owner

@rafaelbeckel you have to keep in mind that we aren't rendering in a browser, but Sublime's very quirky and limited minihtml.

Just to keep everything super clear:

doesn't it style the livePreview?

It does, but you can only use very few CSS properties (see minihtml link).

@rafaelbeckel
Copy link

Thanks for the explanation! I’ve skimmed minihtml’s docs and it seems background-color property is included. Maybe I’m missing something.

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

No branches or pull requests

3 participants