From f9bcfe2e9238e5982dd8d05d3faa18cde2b4ebd1 Mon Sep 17 00:00:00 2001 From: Koen Lageveen Date: Wed, 2 Jun 2021 16:03:21 +0200 Subject: [PATCH] fix #80 property-names with a trailing space --- Syntaxes/Sass.sublime-syntax | 2 +- Tests/syntax_test_sass.sass | 2 ++ Tests/syntax_test_scss.scss | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/Syntaxes/Sass.sublime-syntax b/Syntaxes/Sass.sublime-syntax index 74645952..5d104823 100644 --- a/Syntaxes/Sass.sublime-syntax +++ b/Syntaxes/Sass.sublime-syntax @@ -380,7 +380,7 @@ contexts: - meta_scope: meta.selector.css - include: selector-parts # custom elements - - match: '\s*({{custom_elements}})(?![-:])' + - match: '\s*({{custom_elements}})(?!-|\s*:)' captures: 1: entity.name.tag.custom.css push: diff --git a/Tests/syntax_test_sass.sass b/Tests/syntax_test_sass.sass index bde37022..ad513859 100644 --- a/Tests/syntax_test_sass.sass +++ b/Tests/syntax_test_sass.sass @@ -101,6 +101,8 @@ input:not([type="radio"]):not(h1):not(custom-element):not(%placeholder), select, // ^ support.constant.property-value.css // ^ support.constant.property-value.css // ^ support.constant.property-value.css + align-self : baseline +// ^ support.type.property-name.css object-fit: scale-down // ^^^^^^^^^ support.type.property-name.css // ^ - meta.selector diff --git a/Tests/syntax_test_scss.scss b/Tests/syntax_test_scss.scss index fdae0d91..d4afbbdf 100644 --- a/Tests/syntax_test_scss.scss +++ b/Tests/syntax_test_scss.scss @@ -113,6 +113,8 @@ selector-ish::before[data-type="text"]:not(:first-child), // ^ punctuation.section.property-list.begin color: #00ff00; height: 97%; + align-self : baseline; +// ^ support.type.property-name.css object-fit: scale-down; // ^ support.type.property-name.css // ^ - meta.selector