fix css context check

master
Brad Cornes 2020-05-17 16:50:41 +01:00
parent b5daeb43c3
commit e0093b7404
1 changed files with 2 additions and 2 deletions

View File

@ -1,5 +1,5 @@
import { TextDocument, Position } from 'vscode-languageserver'
import { isInsideTag, isVueDoc, isSvelteDoc } from './html'
import { isInsideTag, isVueDoc, isSvelteDoc, isHtmlDoc } from './html'
import { State } from './state'
export const CSS_LANGUAGES = [
@ -28,7 +28,7 @@ export function isCssContext(
return true
}
if (isVueDoc(doc) || isSvelteDoc(doc)) {
if (isHtmlDoc(state, doc) || isVueDoc(doc) || isSvelteDoc(doc)) {
let str = doc.getText({
start: { line: 0, character: 0 },
end: position,