mirror of
https://github.com/mattn/emmet-vim.git
synced 2025-12-06 10:44:24 +08:00
Compare commits
1 Commits
970ef6e705
...
styled
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
84a0388827 |
@@ -396,6 +396,8 @@ function! emmet#getFileType(...) abort
|
||||
let type = 'html'
|
||||
elseif type =~? '^jsx'
|
||||
let type = 'jsx'
|
||||
elseif type =~? '^jsTemplateString'
|
||||
let type = 'css-block'
|
||||
elseif (type =~? '^js\w' || type =~? '^javascript') && !(&filetype =~? 'jsx')
|
||||
let type = 'javascript'
|
||||
elseif type =~? '^tsx'
|
||||
|
||||
@@ -15,6 +15,7 @@ function! emmet#lang#type(type) abort
|
||||
let settings = emmet#getSettings()
|
||||
while base != ''
|
||||
for b in split(base, '\.')
|
||||
let b = substitute(b, '-.*', '', '')
|
||||
if emmet#lang#exists(b)
|
||||
return b
|
||||
endif
|
||||
|
||||
@@ -13,10 +13,11 @@ function! emmet#lang#css#parseIntoTree(abbr, type) abort
|
||||
let prefix = 0
|
||||
let value = ''
|
||||
|
||||
let indent = emmet#getIndentation(type)
|
||||
let aliases = emmet#getResource(type, 'aliases', {})
|
||||
let snippets = emmet#getResource(type, 'snippets', {})
|
||||
let use_pipe_for_cursor = emmet#getResource(type, 'use_pipe_for_cursor', 1)
|
||||
let ftype = substitute(type, '-.*', '', '')
|
||||
let indent = emmet#getIndentation(ftype)
|
||||
let aliases = emmet#getResource(ftype, 'aliases', {})
|
||||
let snippets = emmet#getResource(ftype, 'snippets', {})
|
||||
let use_pipe_for_cursor = emmet#getResource(ftype, 'use_pipe_for_cursor', 1)
|
||||
|
||||
let root = emmet#newNode()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user