mirror of
https://github.com/microsoft/monaco-editor.git
synced 2025-12-22 23:13:02 +01:00
Separate constructors and constants from keywords
This commit is contained in:
parent
985b1bdc11
commit
b261c99d53
2 changed files with 56 additions and 9 deletions
|
|
@ -39,11 +39,24 @@ export const language = <ILanguage>{
|
|||
"is", "let", "meta", "not",
|
||||
"otherwise", "or", "section",
|
||||
"shared", "then", "true",
|
||||
"try", "type", "#binary",
|
||||
"#date", "#datetime",
|
||||
"#datetimezone", "#duration",
|
||||
"#infinity", "#nan", "#sections",
|
||||
"#shared", "#table", "#time"
|
||||
"try", "type"
|
||||
],
|
||||
|
||||
constructors: [
|
||||
"#binary",
|
||||
"#date",
|
||||
"#datetime",
|
||||
"#datetimezone",
|
||||
"#duration",
|
||||
"#table",
|
||||
"#time"
|
||||
],
|
||||
|
||||
constants: [
|
||||
"#infinity",
|
||||
"#nan",
|
||||
"#sections",
|
||||
"#shared"
|
||||
],
|
||||
|
||||
typeKeywords: [
|
||||
|
|
@ -81,8 +94,10 @@ export const language = <ILanguage>{
|
|||
[/(#?[a-z]+)/,
|
||||
{
|
||||
cases: {
|
||||
"@typeKeywords": "keyword.type",
|
||||
"@typeKeywords": "type",
|
||||
"@keywords": "keyword",
|
||||
"@constants": "constant",
|
||||
"@constructors": "constructor",
|
||||
"@default": "identifier"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue