Skip to content

Commit

Permalink
fix: add @ and *
Browse files Browse the repository at this point in the history
  • Loading branch information
Yoonjae Choi authored and Yoonjae Choi committed Apr 30, 2024
1 parent afc3ddc commit 2e30b9e
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/languages/yaml.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@ export default function(hljs) {
const KEY = {
className: 'attr',
variants: [
// added brackets and other special characters support
{ begin: /\w[\w\s:/.\-()]*:(?=[ \t]|$)/ },
{ // double quoted keys - brackets and other special characters
begin: /"\w[\w\s:/.\-()]*":(?=[ \t]|$)/ },
{ // single quoted keys - brackets and other special characters
begin: /'\w[\w\s:/.\-()]*':(?=[ \t]|$)/ },
// added brackets support
{ begin: /\w[\w :()\./\-*@]*:(?=[ \t]|$)/ },
{ // double quoted keys - with brackets
begin: /"\w[\w :()\./\-*@]*":(?=[ \t]|$)/ },
{ // single quoted keys - with brackets
begin: /'\w[\w :()\./\-*@]*':(?=[ \t]|$)/ },
]
};

Expand Down

0 comments on commit 2e30b9e

Please sign in to comment.