mirror of
https://github.com/hail2u/vim-css3-syntax.git
synced 2025-12-09 03:54:46 +08:00
Compare commits
13 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f8a7f80019 | ||
|
|
aed0768408 | ||
|
|
f52a441267 | ||
|
|
1ea88056c1 | ||
|
|
f622f42d14 | ||
|
|
f638e6c30b | ||
|
|
9f4e52e66a | ||
|
|
14394d15df | ||
|
|
1321f220ea | ||
|
|
7d50b906d8 | ||
|
|
99583cc304 | ||
|
|
af135857ec | ||
|
|
289619aa56 |
25
README.md
25
README.md
@@ -37,8 +37,8 @@ NOTES
|
|||||||
### Highlighting problems on: `vertical-align`, `box-shadow`, and others
|
### Highlighting problems on: `vertical-align`, `box-shadow`, and others
|
||||||
|
|
||||||
Some properties do not highlight correctly by default. This is a limitation of
|
Some properties do not highlight correctly by default. This is a limitation of
|
||||||
Vim’s highlight priority mechanism. To fix this problems, put following lines in
|
Vim’s highlight priority mechanism. To fix this problems, put following lines
|
||||||
your `~/.vim/after/css.vim`:
|
in your `~/.vim/after/css.vim`:
|
||||||
|
|
||||||
setlocal iskeyword+=-
|
setlocal iskeyword+=-
|
||||||
|
|
||||||
@@ -62,9 +62,9 @@ such as `-webkit-` or `-moz-`, etc. These are hard to maintain because they are:
|
|||||||
* Changed unexpectedly
|
* Changed unexpectedly
|
||||||
* Removed silently
|
* Removed silently
|
||||||
|
|
||||||
These must be supported by separate syntax plugins (Vim 7.4’s default CSS syntax
|
These must be supported by separate syntax plugins (Vim 7.4’s default CSS
|
||||||
file supports this). If you want to highlight prefixed properties or functions
|
syntax file supports this). If you want to highlight prefixed properties or
|
||||||
manually, `:highlight` and `:match` would help:
|
functions manually, `:highlight` and `:match` would help:
|
||||||
|
|
||||||
:highlight VendorPrefix guifg=#00ffff gui=bold
|
:highlight VendorPrefix guifg=#00ffff gui=bold
|
||||||
:match VendorPrefix /-\(moz\|webkit\|o\|ms\)-[a-zA-Z-]\+/
|
:match VendorPrefix /-\(moz\|webkit\|o\|ms\)-[a-zA-Z-]\+/
|
||||||
@@ -73,19 +73,12 @@ These commands highlight vendor prefixed properties and functions instantly with
|
|||||||
cyan and bold (on gVim).
|
cyan and bold (on gVim).
|
||||||
|
|
||||||
|
|
||||||
### CSS Preprocessors: [Sass][2], [LESS][3], and [Stylus][4]
|
|
||||||
|
|
||||||
`vim-css3-syntax` supports Sass’s SCSS syntax only. If you want to use this
|
|
||||||
plugin with LESS, install [VIM-LESS][5]. Sass’s indent syntax and Stylus are not
|
|
||||||
supported.
|
|
||||||
|
|
||||||
|
|
||||||
### Media Queries
|
### Media Queries
|
||||||
|
|
||||||
I drop Media Queries Level 3 support in v0.12.0. There is no easy way to support
|
I drop Media Queries Level 3 support in v0.12.0. There is no easy way to support
|
||||||
Media Queries properly with `after` syntax plugin like this one, sorry. If you
|
Media Queries properly with `after` syntax plugin like this one, sorry. If you
|
||||||
want to highlight Media Queries correctly, you must update Vim to 7.4+ or
|
want to highlight Media Queries correctly, you must update Vim to 7.4+ or
|
||||||
install [JulesWang/css.vim][6].
|
install [JulesWang/css.vim][2].
|
||||||
|
|
||||||
|
|
||||||
AUTHOR
|
AUTHOR
|
||||||
@@ -101,8 +94,4 @@ MIT: http://hail2u.mit-license.org/2011
|
|||||||
|
|
||||||
|
|
||||||
[1]: http://www.vim.org/
|
[1]: http://www.vim.org/
|
||||||
[2]: http://sass-lang.com/
|
[2]: https://github.com/JulesWang/css.vim
|
||||||
[3]: http://lesscss.org/
|
|
||||||
[4]: http://learnboost.github.io/stylus/
|
|
||||||
[5]: https://github.com/groenewege/vim-less
|
|
||||||
[6]: https://github.com/JulesWang/css.vim
|
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
" TODO: create cssAnimationsProp group and cssAnimationsAttr group
|
|
||||||
syn match cssFontProp contained "\<animation\(-\(name\|duration\|timing-function\|iteration-count\|direction\|play-state\|delay\|fill-mode\)\)\=\>"
|
syn match cssFontProp contained "\<animation\(-\(name\|duration\|timing-function\|iteration-count\|direction\|play-state\|delay\|fill-mode\)\)\=\>"
|
||||||
syn keyword cssFontAttr contained forwards backwards running paused
|
syn keyword cssFontAttr contained forwards backwards running paused
|
||||||
syn match cssFontAttr contained "\<alternate-reverse\>"
|
syn match cssFontAttr contained "\<alternate-reverse\>"
|
||||||
@@ -1,4 +1,3 @@
|
|||||||
" TODO: create cssBackgroundProp group and cssBackgroundAttr group
|
|
||||||
syn match cssFontProp contained "\<background-\(clip\|origin\|size\)\>"
|
syn match cssFontProp contained "\<background-\(clip\|origin\|size\)\>"
|
||||||
syn match cssFontProp contained "\<border-image\(-\(source\|slice\|width\|outset\|repeat\)\)\=\>"
|
syn match cssFontProp contained "\<border-image\(-\(source\|slice\|width\|outset\|repeat\)\)\=\>"
|
||||||
syn match cssFontProp contained "\<border-\(\(top-right\|bottom-right\|bottom-left\|top-left\)-\)\=radius\>"
|
syn match cssFontProp contained "\<border-\(\(top-right\|bottom-right\|bottom-left\|top-left\)-\)\=radius\>"
|
||||||
@@ -1,4 +1,3 @@
|
|||||||
" TODO: create cssTransformsProp group and cssTransformsAttr group
|
|
||||||
syn match cssFontProp contained "\<backface-visibility\>"
|
syn match cssFontProp contained "\<backface-visibility\>"
|
||||||
syn match cssFontProp contained "\<perspective\(-origin\)\=\>"
|
syn match cssFontProp contained "\<perspective\(-origin\)\=\>"
|
||||||
syn match cssFontProp contained "\<transform\(-\(origin\|style\)\)\=\>"
|
syn match cssFontProp contained "\<transform\(-\(origin\|style\)\)\=\>"
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
" TODO: create cssTransitionsProp group and cssTransitionsAttr group
|
|
||||||
syn match cssFontProp contained "\<transition\(-\(property\|duration\|timing-function\|delay\)\)\=\>"
|
syn match cssFontProp contained "\<transition\(-\(property\|duration\|timing-function\|delay\)\)\=\>"
|
||||||
syn keyword cssFontAttr contained linear
|
syn keyword cssFontAttr contained linear
|
||||||
syn match cssFontAttr contained "\<ease\(-\(in\|out\|in-out\)\)\=\>"
|
syn match cssFontAttr contained "\<ease\(-\(in\|out\|in-out\)\)\=\>"
|
||||||
@@ -1,8 +1,7 @@
|
|||||||
syn match cssFontProp contained "\<writing-mode\>"
|
syn match cssFontProp contained "\<writing-mode\>"
|
||||||
syn match cssFontProp contained "\<text-\(orientation\|combine-upright\)\>"
|
syn match cssFontProp contained "\<text-\(orientation\|combine-upright\)\>"
|
||||||
syn match cssFontProp contained "\<glyph-orientation-vertical\>"
|
syn match cssFontProp contained "\<glyph-orientation-vertical\>"
|
||||||
syn keyword cssFontAttr contained before after mixed upright plaintext
|
syn keyword cssFontAttr contained before after mixed upright plaintext sideways
|
||||||
syn match cssFontAttr contained "\<sideways\(-rl\|-lr\)\=\>"
|
|
||||||
syn match cssFontAttr contained "\<isolate\(-override\)\=\>"
|
syn match cssFontAttr contained "\<isolate\(-override\)\=\>"
|
||||||
syn match cssFontAttr contained "\<horizontal-tb\>"
|
syn match cssFontAttr contained "\<horizontal-tb\>"
|
||||||
syn match cssFontAttr contained "\<vertical-\(rl\|lr\)\>"
|
syn match cssFontAttr contained "\<vertical-\(rl\|lr\)\>"
|
||||||
|
|||||||
1
after/syntax/css/css-writing-modes-4.vim
Normal file
1
after/syntax/css/css-writing-modes-4.vim
Normal file
@@ -0,0 +1 @@
|
|||||||
|
syn match cssFontAttr contained "\<sideways-\(rl\|lr\)\>"
|
||||||
2
after/syntax/css/webvtt1.vim
Normal file
2
after/syntax/css/webvtt1.vim
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
syn match cssPseudoClassId contained "::\<cue\(-region\)\=\>"
|
||||||
|
syn region cssPseudoClassLang matchgroup=cssPseudoClassId start="::cue\(-region\)\=(" end=")" oneline
|
||||||
@@ -1,79 +0,0 @@
|
|||||||
syn include @htmlCss syntax/css/compositing-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-align-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-backgrounds-4.vim
|
|
||||||
syn include @htmlCss syntax/css/css-break-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-cascade-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-cascade-4.vim
|
|
||||||
syn include @htmlCss syntax/css/css-color-4.vim
|
|
||||||
syn include @htmlCss syntax/css/css-contain-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-content-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-counter-styles-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-device-adapt-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-display-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-flexbox-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-font-loading-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-fonts-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-fonts-4.vim
|
|
||||||
syn include @htmlCss syntax/css/css-gcpm-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-grid-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-images-4.vim
|
|
||||||
syn include @htmlCss syntax/css/css-inline-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-line-grid-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-lists-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-logical-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-masking-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-multicol-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-overflow-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-overflow-4.vim
|
|
||||||
syn include @htmlCss syntax/css/css-page-floats-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-paint-api-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-position-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-properties-values-api-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-pseudo-4.vim
|
|
||||||
syn include @htmlCss syntax/css/css-regions-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-rhythm-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-round-display-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-ruby-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-scoping-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-scroll-snap-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-shapes-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-sizing-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-style-attr.vim
|
|
||||||
syn include @htmlCss syntax/css/css-syntax-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-text-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-text-4.vim
|
|
||||||
syn include @htmlCss syntax/css/css-text-decor-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-timing-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-transforms-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-typed-om-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-ui-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-ui-4.vim
|
|
||||||
syn include @htmlCss syntax/css/css-values-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css-variables-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-will-change-1.vim
|
|
||||||
syn include @htmlCss syntax/css/css-writing-modes-3.vim
|
|
||||||
syn include @htmlCss syntax/css/css3-animations.vim
|
|
||||||
syn include @htmlCss syntax/css/css3-background.vim
|
|
||||||
syn include @htmlCss syntax/css/css3-box.vim
|
|
||||||
syn include @htmlCss syntax/css/css3-color.vim
|
|
||||||
syn include @htmlCss syntax/css/css3-conditional.vim
|
|
||||||
syn include @htmlCss syntax/css/css3-exclusions.vim
|
|
||||||
syn include @htmlCss syntax/css/css3-images.vim
|
|
||||||
syn include @htmlCss syntax/css/css3-namespace.vim
|
|
||||||
syn include @htmlCss syntax/css/css3-page.vim
|
|
||||||
syn include @htmlCss syntax/css/css3-speech.vim
|
|
||||||
syn include @htmlCss syntax/css/css3-transitions.vim
|
|
||||||
syn include @htmlCss syntax/css/cssom-1.vim
|
|
||||||
syn include @htmlCss syntax/css/cssom-view-1.vim
|
|
||||||
syn include @htmlCss syntax/css/fill-stroke-3.vim
|
|
||||||
syn include @htmlCss syntax/css/filter-effects-1.vim
|
|
||||||
syn include @htmlCss syntax/css/geometry-1.vim
|
|
||||||
syn include @htmlCss syntax/css/html5.vim
|
|
||||||
syn include @htmlCss syntax/css/motion-1.vim
|
|
||||||
syn include @htmlCss syntax/css/pointerevents.vim
|
|
||||||
syn include @htmlCss syntax/css/selectors-nonelement-1.vim
|
|
||||||
syn include @htmlCss syntax/css/selectors.vim
|
|
||||||
syn include @htmlCss syntax/css/selectors4.vim
|
|
||||||
syn include @htmlCss syntax/css/svg2.vim
|
|
||||||
syn include @htmlCss syntax/css/web-animations-1.vim
|
|
||||||
syn include @htmlCss syntax/css/worklets-1.vim
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
runtime! syntax/css/*.vim
|
|
||||||
@@ -28,7 +28,7 @@
|
|||||||
animation-timing-function: auto;
|
animation-timing-function: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.background {
|
.backgrounds-3 {
|
||||||
background-clip: space;
|
background-clip: space;
|
||||||
background-origin: round;
|
background-origin: round;
|
||||||
background-size: local;
|
background-size: local;
|
||||||
@@ -871,6 +871,13 @@
|
|||||||
display: auto;
|
display: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.webvtt1::cue,
|
||||||
|
.webvtt1::cue-region,
|
||||||
|
.webvtt1::cue(#cue1),
|
||||||
|
.webvtt1::cue-region(#scroll), {
|
||||||
|
display: auto;
|
||||||
|
}
|
||||||
|
|
||||||
.will-change-1 {
|
.will-change-1 {
|
||||||
will-change: scroll-position;
|
will-change: scroll-position;
|
||||||
}
|
}
|
||||||
@@ -882,8 +889,6 @@
|
|||||||
glyph-orientation-vertical: upright;
|
glyph-orientation-vertical: upright;
|
||||||
display: plaintext;
|
display: plaintext;
|
||||||
display: sideways;
|
display: sideways;
|
||||||
display: sideways-rl;
|
|
||||||
display: sideways-lr;
|
|
||||||
display: isolate;
|
display: isolate;
|
||||||
display: isolate-override;
|
display: isolate-override;
|
||||||
display: horizontal-tb;
|
display: horizontal-tb;
|
||||||
@@ -891,6 +896,11 @@
|
|||||||
display: vertical-lr;
|
display: vertical-lr;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.writing-modes-4 {
|
||||||
|
display: sideways-rl;
|
||||||
|
display: sideways-lr;
|
||||||
|
}
|
||||||
|
|
||||||
.html5,
|
.html5,
|
||||||
picture,
|
picture,
|
||||||
rb,
|
rb,
|
||||||
|
|||||||
1084
test/test.html
1084
test/test.html
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user