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

Could not load 'markdown.styles': *.css #77290

Closed
SHenry07 opened this issue Jul 12, 2019 · 6 comments
Closed

Could not load 'markdown.styles': *.css #77290

SHenry07 opened this issue Jul 12, 2019 · 6 comments
Assignees
Labels
*as-designed Described behavior is as designed markdown Markdown support issues
Milestone

Comments

@SHenry07
Copy link

SHenry07 commented Jul 12, 2019

  • VSCode Version: 1.36.0
  • OS Version: Linux x64 4.15.0-54-generic

Steps to Reproduce:

  1. point markdown.styles to "my.css"

  2. make sure such a file exists in the workspace root

  3. try to preview a markdown document

  4. erro say “Could not load the 'markdown.styles' ”

Does this issue occur when all extensions are disabled?: Yes

@vscodebot vscodebot bot added the markdown Markdown support issues label Jul 12, 2019
@SHenry07
Copy link
Author

SHenry07 commented Jul 13, 2019

my extra css file

body {
	font-size: 15px;
	color: #333;
	background: #fff;
	font-family: Helvetica, Arial, "PingFang SC", "Microsoft YaHei", "WenQuanYi Micro Hei", "tohoma,sans-serif";
	margin: 0;
	padding: 10%;
}
h1 {
	font-size: 2.2em;
	font-weight: 700;
	line-height: 1.1;
	padding-top: 16px;
	margin-bottom: 4px;
}
h2, h3, h4, h5, h6 {
	line-height: 1.5em;
	margin-top: 2.2em;
	margin-bottom: 4px;
}
h2 {
	font-size: 1.4em;
	margin: 40px 10px 20px 0;
	padding-left: 9px;
	border-left: 6px solid #ff7e79;
	font-weight: 700;
	line-height: 1.4;
}
h3 {
	font-weight: 700;
	font-size: 1.2em;
	line-height: 1.4;
	margin: 10px 0 5px;
	padding-top: 10px;
}
h4 {
	font-weight: 700;
	text-transform: uppercase;
	font-size: 1.1em;
	line-height: 1.4;
	margin: 10px 0 5px;
	padding-top: 10px
}
h5, h6 {
	font-size: .9em;
}
h5 {
	font-weight: bold;
	text-transform: uppercase;
}
h6 {
	font-weight: normal;
	color: #AAA;
}
img {
	width: 100%;
	border-radius: 5px;
	display: block;
	margin-bottom: 15px;
	height: auto;
}
dl, ol, ul {
	margin-top: 12px;
	margin-bottom: 20px;
	padding-left: 5%;
	line-height: 1.8;
}
p {
	margin: 0 0 20px;
	padding: 0;
	line-height: 1.8;
}
a {
	color: #f22f27;
	text-decoration: none;
}
a:hover {
	color: #f55852;
	text-decoration: underline;
}
a:focus {
	outline-offset: -2px;
}
blockquote {
	font-size: 1em;
	font-style: normal;
	padding: 30px 38px;
	margin: 0 0 15px;
	position: relative;
	line-height: 1.8;
	text-indent: 0;
	border: none;
	color: #888;
}
blockquote:before {
	content: "“";
	left: 12px;
	top: 0;
	color: #E0E0E0;
	font-size: 4em;
	font-family: Arial, serif;
	line-height: 1em;
	font-weight: 700;
	position: absolute;
}
blockquote:after {
	content: "”";
	right: 12px;
	bottom: -26px;
	color: #E0E0E0;
	font-size: 4em;
	font-family: Arial, serif;
	line-height: 1em;
	font-weight: 700;
	position: absolute;
	bottom: -31px;
}
strong, dfn {
	font-weight: 700;
}
em, dfn {
	font-style: italic;
	font-weight: 400;
}
del {
	text-decoration: line-through;
}
/*code {font-size:90%;}*/

/*pre {text-align:left; overflow-x: scroll; color: #257fa0; background: #f6f6f6; padding: 10pt 15pt; border-radius: 3px; border: solid 1px #e2e2e2;}*/

pre {
	margin: 0 0 10px;
	font-size: 13px;
	line-height: 1.42857;
	word-break: break-all;
	word-wrap: break-word;
	border-radius: 4px;
	white-space: pre-wrap;
	display: block;
	background: #f8f8f8;
	padding: 10px 20px;
	border: none;
	margin-bottom: 25px;
	color: #666;
	font-family: Courier, sans-serif;
}
code {
	color: #c7254e;
	background-color: #f9f2f4;
	border-radius: 4px;
	font-family: Menlo, Monaco, Consolas, "Courier New", monospace;
	padding: 2px 4px;
	font-size: 90%;
}
p>code {
	color: #c7264e;
	background-color: #f9f2f4;
	font-size: .95em;
	border-radius: 3px;
	-moz-border-radius: 3px;
	-webkit-border-radius: 3px;
}
figure {
	margin: 1em 0;
}
figcaption {
	font-size: 0.75em;
	padding: 0.5em 2em;
	margin-bottom: 2em;
}
figure img {
	margin-bottom: 0px;
}
hr {
	margin-top: 20px;
	margin-bottom: 20px;
	border: 0;
	border-top: 1px solid #eee;
}
ol p, ul p {
	margin-bottom: 0px;
}
li {
	margin-bottom: 0.75em;
	margin-top: 0.75em;
}
ol#footnotes {
	font-size: 0.95em;
	padding-top: 1em;
	margin-top: 1em;
	margin-left: 0;
	border-top: 1px solid #eaeaea;
	counter-reset: footer-counter;
	list-style: none;
	color: #555;
	padding-left: 5%;
	margin: 20px 0;
}
ol#footnotes li {
	margin-bottom: 10px;
	margin-left: 16px;
	font-weight: 400;
	line-height: 2;
	list-style-type: none;
}
ol#footnotes li:before {
	content: counter(footer-counter) ". ";
	counter-increment: footer-counter;
	font-weight: 800;
	font-size: .95em;
}
@keyframes highfade {
	0% {
		background-color: none;
	}
	20% {
		background-color: yellow;
	}
	100% {
		background-color: none;
	}
}
@-webkit-keyframes highfade {
	0% {
		background-color: none;
	}
	20% {
		background-color: yellow;
	}
	100% {
		background-color: none;
	}
}
a:target, ol#footnotes li:target, sup a:target {
	animation-name: highfade;
	animation-duration: 2s;
	animation-iteration-count: 1;
	animation-timing-function: ease-in-out;
	-webkit-animation-name: highfade;
	-webkit-animation-duration: 2s;
	-webkit-animation-iteration-count: 1;
	-webkit-animation-timing-function: ease-in-out;
}
a:target {
	border: 0;
	outline: 0;
}
animation-iteration-count: 1;
-webkit-animation-timing-function: ease-in-out;
}
a:target {
	border: 0;
	outline: 0;
}
tion-iteration-count: 1;
-webkit-animation-timing-function: ease-in-out;
}
a:target {
	border: 0;
	outline: 0;
}

@Neonit
Copy link
Contributor

Neonit commented Jul 22, 2019

Confirming for

  • Version: 1.36.1 (user setup)
  • OS: Windows_NT x64 6.1.7601

Is this still the same bug from 1.33?

@rfresow
Copy link

rfresow commented Jul 22, 2019

Also in:
image

@mjbvz mjbvz added this to the July 2019 milestone Jul 22, 2019
@mjbvz mjbvz added the info-needed Issue requires more information from poster label Jul 25, 2019
@mjbvz
Copy link
Collaborator

mjbvz commented Jul 25, 2019

I can't repo this. @HengHughSun can you please share the setting value you are using and the general structure of your workspace (such as where the md file is and where the css file is)

@SHenry07
Copy link
Author

Let we do a simple test.

  1. open a new window
  2. create new files in current directory(test1)
  • test.md
  • test.css
  • .vscode/settings.json
  1. in the settings.json
{
    "markdown.styles":[ 
        "test.css"
    ]
}

Result: it is working. All is Ok!


Another try

  1. open a new window
  2. copy files from directory(test1) to directory(test2)
  • test.md
  • .vscode/settings.json
  1. In this test, we try to load the test.css in directory(test1)
{
    "markdown.styles":[ 
        "/home/heng/work/testmd/test1/test.css"
    ]
}

Result: it is not working.


directory structure

➜  testmd tree -a
.
├── test1
│   ├── test.css
│   ├── test.md
│   └── .vscode
│       └── settings.json
└── test2
    ├── test.css
    ├── test.md
    └── .vscode
        └── settings.json

4 directories, 6 files
➜  testmd pwd
/home/heng/work/testmd

Thank you for you reply.@mjbvz

@mjbvz
Copy link
Collaborator

mjbvz commented Jul 28, 2019

The stylesheet must be contained inside the current workspace.

Closing as by-design

@mjbvz mjbvz closed this as completed Jul 28, 2019
@mjbvz mjbvz added *as-designed Described behavior is as designed and removed info-needed Issue requires more information from poster labels Jul 28, 2019
@vscodebot vscodebot bot locked and limited conversation to collaborators Sep 11, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
*as-designed Described behavior is as designed markdown Markdown support issues
Projects
None yet
Development

No branches or pull requests

4 participants