aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--grammar.js4
-rw-r--r--src/grammar.json4
2 files changed, 4 insertions, 4 deletions
diff --git a/grammar.js b/grammar.js
index e2cdbce..6d309b2 100644
--- a/grammar.js
+++ b/grammar.js
@@ -43,8 +43,8 @@ module.exports = grammar({
),
),
- class_shorthand: $ => /\.[^\p{White_Space}]+/u,
- id_shorthand: $ => /#[^\p{White_Space}]+/u,
+ class_shorthand: $ => /\.\P{White_Space}+/u,
+ id_shorthand: $ => /#\P{White_Space}+/u,
attribute_name: $ => /[a-zA-Z0-9_-]+/,
attribute_value: $ => /"(\\.|[^"\\])*"/,
diff --git a/src/grammar.json b/src/grammar.json
index 960f0dd..e3e1f0a 100644
--- a/src/grammar.json
+++ b/src/grammar.json
@@ -180,11 +180,11 @@
},
"class_shorthand": {
"type": "PATTERN",
- "value": "\\.[^\\p{White_Space}]+"
+ "value": "\\.\\P{White_Space}+"
},
"id_shorthand": {
"type": "PATTERN",
- "value": "#[^\\p{White_Space}]+"
+ "value": "#\\P{White_Space}+"
},
"attribute_name": {
"type": "PATTERN",