@banyan_cloud/roots 1.0.109 → 1.0.111

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -20674,134 +20674,126 @@ function c(Prism) {
20674
20674
  delete Prism.languages.c['boolean'];
20675
20675
  }
20676
20676
 
20677
- var cpp_1;
20678
- var hasRequiredCpp;
20679
-
20680
- function requireCpp () {
20681
- if (hasRequiredCpp) return cpp_1;
20682
- hasRequiredCpp = 1;
20683
- var refractorC = c_1;
20684
- cpp_1 = cpp;
20685
- cpp.displayName = 'cpp';
20686
- cpp.aliases = [];
20687
- function cpp(Prism) {
20688
- Prism.register(refractorC)
20689
- ;(function (Prism) {
20690
- var keyword =
20691
- /\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/;
20692
- var modName = /\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(
20693
- /<keyword>/g,
20694
- function () {
20695
- return keyword.source
20696
- }
20697
- );
20698
- Prism.languages.cpp = Prism.languages.extend('c', {
20699
- 'class-name': [
20700
- {
20701
- pattern: RegExp(
20702
- /(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(
20703
- /<keyword>/g,
20704
- function () {
20705
- return keyword.source
20706
- }
20707
- )
20708
- ),
20709
- lookbehind: true
20710
- }, // This is intended to capture the class name of method implementations like:
20711
- // void foo::bar() const {}
20712
- // However! The `foo` in the above example could also be a namespace, so we only capture the class name if
20713
- // it starts with an uppercase letter. This approximation should give decent results.
20714
- /\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/, // This will capture the class name before destructors like:
20715
- // Foo::~Foo() {}
20716
- /\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i, // This also intends to capture the class name of method implementations but here the class has template
20717
- // parameters, so it can't be a namespace (until C++ adds generic namespaces).
20718
- /\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/
20719
- ],
20720
- keyword: keyword,
20721
- number: {
20722
- pattern:
20723
- /(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,
20724
- greedy: true
20725
- },
20726
- operator:
20727
- />>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,
20728
- boolean: /\b(?:false|true)\b/
20729
- });
20730
- Prism.languages.insertBefore('cpp', 'string', {
20731
- module: {
20732
- // https://en.cppreference.com/w/cpp/language/modules
20733
- pattern: RegExp(
20734
- /(\b(?:import|module)\s+)/.source +
20735
- '(?:' + // header-name
20736
- /"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source +
20737
- '|' + // module name or partition or both
20738
- /<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(
20739
- /<mod-name>/g,
20740
- function () {
20741
- return modName
20742
- }
20743
- ) +
20744
- ')'
20745
- ),
20746
- lookbehind: true,
20747
- greedy: true,
20748
- inside: {
20749
- string: /^[<"][\s\S]+/,
20750
- operator: /:/,
20751
- punctuation: /\./
20752
- }
20753
- },
20754
- 'raw-string': {
20755
- pattern: /R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,
20756
- alias: 'string',
20757
- greedy: true
20758
- }
20759
- });
20760
- Prism.languages.insertBefore('cpp', 'keyword', {
20761
- 'generic-function': {
20762
- pattern: /\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,
20763
- inside: {
20764
- function: /^\w+/,
20765
- generic: {
20766
- pattern: /<[\s\S]+/,
20767
- alias: 'class-name',
20768
- inside: Prism.languages.cpp
20769
- }
20770
- }
20771
- }
20772
- });
20773
- Prism.languages.insertBefore('cpp', 'operator', {
20774
- 'double-colon': {
20775
- pattern: /::/,
20776
- alias: 'punctuation'
20777
- }
20778
- });
20779
- Prism.languages.insertBefore('cpp', 'class-name', {
20780
- // the base clause is an optional list of parent classes
20781
- // https://en.cppreference.com/w/cpp/language/class
20782
- 'base-clause': {
20783
- pattern:
20784
- /(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,
20785
- lookbehind: true,
20786
- greedy: true,
20787
- inside: Prism.languages.extend('cpp', {})
20788
- }
20789
- });
20790
- Prism.languages.insertBefore(
20791
- 'inside',
20792
- 'double-colon',
20793
- {
20794
- // All untokenized words that are not namespaces should be class names
20795
- 'class-name': /\b[a-z_]\w*\b(?!\s*::)/i
20796
- },
20797
- Prism.languages.cpp['base-clause']
20798
- );
20799
- })(Prism);
20800
- }
20801
- return cpp_1;
20677
+ var refractorC$1 = c_1;
20678
+ var cpp_1 = cpp;
20679
+ cpp.displayName = 'cpp';
20680
+ cpp.aliases = [];
20681
+ function cpp(Prism) {
20682
+ Prism.register(refractorC$1)
20683
+ ;(function (Prism) {
20684
+ var keyword =
20685
+ /\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/;
20686
+ var modName = /\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(
20687
+ /<keyword>/g,
20688
+ function () {
20689
+ return keyword.source
20690
+ }
20691
+ );
20692
+ Prism.languages.cpp = Prism.languages.extend('c', {
20693
+ 'class-name': [
20694
+ {
20695
+ pattern: RegExp(
20696
+ /(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(
20697
+ /<keyword>/g,
20698
+ function () {
20699
+ return keyword.source
20700
+ }
20701
+ )
20702
+ ),
20703
+ lookbehind: true
20704
+ }, // This is intended to capture the class name of method implementations like:
20705
+ // void foo::bar() const {}
20706
+ // However! The `foo` in the above example could also be a namespace, so we only capture the class name if
20707
+ // it starts with an uppercase letter. This approximation should give decent results.
20708
+ /\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/, // This will capture the class name before destructors like:
20709
+ // Foo::~Foo() {}
20710
+ /\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i, // This also intends to capture the class name of method implementations but here the class has template
20711
+ // parameters, so it can't be a namespace (until C++ adds generic namespaces).
20712
+ /\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/
20713
+ ],
20714
+ keyword: keyword,
20715
+ number: {
20716
+ pattern:
20717
+ /(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,
20718
+ greedy: true
20719
+ },
20720
+ operator:
20721
+ />>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,
20722
+ boolean: /\b(?:false|true)\b/
20723
+ });
20724
+ Prism.languages.insertBefore('cpp', 'string', {
20725
+ module: {
20726
+ // https://en.cppreference.com/w/cpp/language/modules
20727
+ pattern: RegExp(
20728
+ /(\b(?:import|module)\s+)/.source +
20729
+ '(?:' + // header-name
20730
+ /"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source +
20731
+ '|' + // module name or partition or both
20732
+ /<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(
20733
+ /<mod-name>/g,
20734
+ function () {
20735
+ return modName
20736
+ }
20737
+ ) +
20738
+ ')'
20739
+ ),
20740
+ lookbehind: true,
20741
+ greedy: true,
20742
+ inside: {
20743
+ string: /^[<"][\s\S]+/,
20744
+ operator: /:/,
20745
+ punctuation: /\./
20746
+ }
20747
+ },
20748
+ 'raw-string': {
20749
+ pattern: /R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,
20750
+ alias: 'string',
20751
+ greedy: true
20752
+ }
20753
+ });
20754
+ Prism.languages.insertBefore('cpp', 'keyword', {
20755
+ 'generic-function': {
20756
+ pattern: /\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,
20757
+ inside: {
20758
+ function: /^\w+/,
20759
+ generic: {
20760
+ pattern: /<[\s\S]+/,
20761
+ alias: 'class-name',
20762
+ inside: Prism.languages.cpp
20763
+ }
20764
+ }
20765
+ }
20766
+ });
20767
+ Prism.languages.insertBefore('cpp', 'operator', {
20768
+ 'double-colon': {
20769
+ pattern: /::/,
20770
+ alias: 'punctuation'
20771
+ }
20772
+ });
20773
+ Prism.languages.insertBefore('cpp', 'class-name', {
20774
+ // the base clause is an optional list of parent classes
20775
+ // https://en.cppreference.com/w/cpp/language/class
20776
+ 'base-clause': {
20777
+ pattern:
20778
+ /(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,
20779
+ lookbehind: true,
20780
+ greedy: true,
20781
+ inside: Prism.languages.extend('cpp', {})
20782
+ }
20783
+ });
20784
+ Prism.languages.insertBefore(
20785
+ 'inside',
20786
+ 'double-colon',
20787
+ {
20788
+ // All untokenized words that are not namespaces should be class names
20789
+ 'class-name': /\b[a-z_]\w*\b(?!\s*::)/i
20790
+ },
20791
+ Prism.languages.cpp['base-clause']
20792
+ );
20793
+ })(Prism);
20802
20794
  }
20803
20795
 
20804
- var refractorCpp$1 = requireCpp();
20796
+ var refractorCpp$1 = cpp_1;
20805
20797
  var arduino_1 = arduino;
20806
20798
  arduino.displayName = 'arduino';
20807
20799
  arduino.aliases = ['ino'];
@@ -21145,484 +21137,475 @@ function asmatmel(Prism) {
21145
21137
  };
21146
21138
  }
21147
21139
 
21148
- var csharp_1;
21149
- var hasRequiredCsharp;
21150
-
21151
- function requireCsharp () {
21152
- if (hasRequiredCsharp) return csharp_1;
21153
- hasRequiredCsharp = 1;
21154
-
21155
- csharp_1 = csharp;
21156
- csharp.displayName = 'csharp';
21157
- csharp.aliases = ['dotnet', 'cs'];
21158
- function csharp(Prism) {
21140
+ var csharp_1 = csharp;
21141
+ csharp.displayName = 'csharp';
21142
+ csharp.aliases = ['dotnet', 'cs'];
21143
+ function csharp(Prism) {
21159
21144
  (function (Prism) {
21160
- /**
21161
- * Replaces all placeholders "<<n>>" of given pattern with the n-th replacement (zero based).
21162
- *
21163
- * Note: This is a simple text based replacement. Be careful when using backreferences!
21164
- *
21165
- * @param {string} pattern the given pattern.
21166
- * @param {string[]} replacements a list of replacement which can be inserted into the given pattern.
21167
- * @returns {string} the pattern with all placeholders replaced with their corresponding replacements.
21168
- * @example replace(/a<<0>>a/.source, [/b+/.source]) === /a(?:b+)a/.source
21169
- */
21170
- function replace(pattern, replacements) {
21171
- return pattern.replace(/<<(\d+)>>/g, function (m, index) {
21172
- return '(?:' + replacements[+index] + ')'
21173
- })
21174
- }
21175
- /**
21176
- * @param {string} pattern
21177
- * @param {string[]} replacements
21178
- * @param {string} [flags]
21179
- * @returns {RegExp}
21180
- */
21181
- function re(pattern, replacements, flags) {
21182
- return RegExp(replace(pattern, replacements), flags || '')
21183
- }
21184
- /**
21185
- * Creates a nested pattern where all occurrences of the string `<<self>>` are replaced with the pattern itself.
21186
- *
21187
- * @param {string} pattern
21188
- * @param {number} depthLog2
21189
- * @returns {string}
21190
- */
21191
- function nested(pattern, depthLog2) {
21192
- for (var i = 0; i < depthLog2; i++) {
21193
- pattern = pattern.replace(/<<self>>/g, function () {
21194
- return '(?:' + pattern + ')'
21195
- });
21196
- }
21197
- return pattern.replace(/<<self>>/g, '[^\\s\\S]')
21198
- } // https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/keywords/
21199
- var keywordKinds = {
21200
- // keywords which represent a return or variable type
21201
- type: 'bool byte char decimal double dynamic float int long object sbyte short string uint ulong ushort var void',
21202
- // keywords which are used to declare a type
21203
- typeDeclaration: 'class enum interface record struct',
21204
- // contextual keywords
21205
- // ("var" and "dynamic" are missing because they are used like types)
21206
- contextual:
21207
- 'add alias and ascending async await by descending from(?=\\s*(?:\\w|$)) get global group into init(?=\\s*;) join let nameof not notnull on or orderby partial remove select set unmanaged value when where with(?=\\s*{)',
21208
- // all other keywords
21209
- other:
21210
- 'abstract as base break case catch checked const continue default delegate do else event explicit extern finally fixed for foreach goto if implicit in internal is lock namespace new null operator out override params private protected public readonly ref return sealed sizeof stackalloc static switch this throw try typeof unchecked unsafe using virtual volatile while yield'
21211
- }; // keywords
21212
- function keywordsToPattern(words) {
21213
- return '\\b(?:' + words.trim().replace(/ /g, '|') + ')\\b'
21214
- }
21215
- var typeDeclarationKeywords = keywordsToPattern(
21216
- keywordKinds.typeDeclaration
21217
- );
21218
- var keywords = RegExp(
21219
- keywordsToPattern(
21220
- keywordKinds.type +
21221
- ' ' +
21222
- keywordKinds.typeDeclaration +
21223
- ' ' +
21224
- keywordKinds.contextual +
21225
- ' ' +
21226
- keywordKinds.other
21227
- )
21228
- );
21229
- var nonTypeKeywords = keywordsToPattern(
21230
- keywordKinds.typeDeclaration +
21231
- ' ' +
21232
- keywordKinds.contextual +
21233
- ' ' +
21234
- keywordKinds.other
21235
- );
21236
- var nonContextualKeywords = keywordsToPattern(
21237
- keywordKinds.type +
21238
- ' ' +
21239
- keywordKinds.typeDeclaration +
21240
- ' ' +
21241
- keywordKinds.other
21242
- ); // types
21243
- var generic = nested(/<(?:[^<>;=+\-*/%&|^]|<<self>>)*>/.source, 2); // the idea behind the other forbidden characters is to prevent false positives. Same for tupleElement.
21244
- var nestedRound = nested(/\((?:[^()]|<<self>>)*\)/.source, 2);
21245
- var name = /@?\b[A-Za-z_]\w*\b/.source;
21246
- var genericName = replace(/<<0>>(?:\s*<<1>>)?/.source, [name, generic]);
21247
- var identifier = replace(/(?!<<0>>)<<1>>(?:\s*\.\s*<<1>>)*/.source, [
21248
- nonTypeKeywords,
21249
- genericName
21250
- ]);
21251
- var array = /\[\s*(?:,\s*)*\]/.source;
21252
- var typeExpressionWithoutTuple = replace(
21253
- /<<0>>(?:\s*(?:\?\s*)?<<1>>)*(?:\s*\?)?/.source,
21254
- [identifier, array]
21255
- );
21256
- var tupleElement = replace(
21257
- /[^,()<>[\];=+\-*/%&|^]|<<0>>|<<1>>|<<2>>/.source,
21258
- [generic, nestedRound, array]
21259
- );
21260
- var tuple = replace(/\(<<0>>+(?:,<<0>>+)+\)/.source, [tupleElement]);
21261
- var typeExpression = replace(
21262
- /(?:<<0>>|<<1>>)(?:\s*(?:\?\s*)?<<2>>)*(?:\s*\?)?/.source,
21263
- [tuple, identifier, array]
21264
- );
21265
- var typeInside = {
21266
- keyword: keywords,
21267
- punctuation: /[<>()?,.:[\]]/
21268
- }; // strings & characters
21269
- // https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/language-specification/lexical-structure#character-literals
21270
- // https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/language-specification/lexical-structure#string-literals
21271
- var character = /'(?:[^\r\n'\\]|\\.|\\[Uux][\da-fA-F]{1,8})'/.source; // simplified pattern
21272
- var regularString = /"(?:\\.|[^\\"\r\n])*"/.source;
21273
- var verbatimString = /@"(?:""|\\[\s\S]|[^\\"])*"(?!")/.source;
21274
- Prism.languages.csharp = Prism.languages.extend('clike', {
21275
- string: [
21276
- {
21277
- pattern: re(/(^|[^$\\])<<0>>/.source, [verbatimString]),
21278
- lookbehind: true,
21279
- greedy: true
21280
- },
21281
- {
21282
- pattern: re(/(^|[^@$\\])<<0>>/.source, [regularString]),
21283
- lookbehind: true,
21284
- greedy: true
21285
- }
21286
- ],
21287
- 'class-name': [
21288
- {
21289
- // Using static
21290
- // using static System.Math;
21291
- pattern: re(/(\busing\s+static\s+)<<0>>(?=\s*;)/.source, [
21292
- identifier
21293
- ]),
21294
- lookbehind: true,
21295
- inside: typeInside
21296
- },
21297
- {
21298
- // Using alias (type)
21299
- // using Project = PC.MyCompany.Project;
21300
- pattern: re(/(\busing\s+<<0>>\s*=\s*)<<1>>(?=\s*;)/.source, [
21301
- name,
21302
- typeExpression
21303
- ]),
21304
- lookbehind: true,
21305
- inside: typeInside
21306
- },
21307
- {
21308
- // Using alias (alias)
21309
- // using Project = PC.MyCompany.Project;
21310
- pattern: re(/(\busing\s+)<<0>>(?=\s*=)/.source, [name]),
21311
- lookbehind: true
21312
- },
21313
- {
21314
- // Type declarations
21315
- // class Foo<A, B>
21316
- // interface Foo<out A, B>
21317
- pattern: re(/(\b<<0>>\s+)<<1>>/.source, [
21318
- typeDeclarationKeywords,
21319
- genericName
21320
- ]),
21321
- lookbehind: true,
21322
- inside: typeInside
21323
- },
21324
- {
21325
- // Single catch exception declaration
21326
- // catch(Foo)
21327
- // (things like catch(Foo e) is covered by variable declaration)
21328
- pattern: re(/(\bcatch\s*\(\s*)<<0>>/.source, [identifier]),
21329
- lookbehind: true,
21330
- inside: typeInside
21331
- },
21332
- {
21333
- // Name of the type parameter of generic constraints
21334
- // where Foo : class
21335
- pattern: re(/(\bwhere\s+)<<0>>/.source, [name]),
21336
- lookbehind: true
21337
- },
21338
- {
21339
- // Casts and checks via as and is.
21340
- // as Foo<A>, is Bar<B>
21341
- // (things like if(a is Foo b) is covered by variable declaration)
21342
- pattern: re(/(\b(?:is(?:\s+not)?|as)\s+)<<0>>/.source, [
21343
- typeExpressionWithoutTuple
21344
- ]),
21345
- lookbehind: true,
21346
- inside: typeInside
21347
- },
21348
- {
21349
- // Variable, field and parameter declaration
21350
- // (Foo bar, Bar baz, Foo[,,] bay, Foo<Bar, FooBar<Bar>> bax)
21351
- pattern: re(
21352
- /\b<<0>>(?=\s+(?!<<1>>|with\s*\{)<<2>>(?:\s*[=,;:{)\]]|\s+(?:in|when)\b))/
21353
- .source,
21354
- [typeExpression, nonContextualKeywords, name]
21355
- ),
21356
- inside: typeInside
21357
- }
21358
- ],
21359
- keyword: keywords,
21360
- // https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/language-specification/lexical-structure#literals
21361
- number:
21362
- /(?:\b0(?:x[\da-f_]*[\da-f]|b[01_]*[01])|(?:\B\.\d+(?:_+\d+)*|\b\d+(?:_+\d+)*(?:\.\d+(?:_+\d+)*)?)(?:e[-+]?\d+(?:_+\d+)*)?)(?:[dflmu]|lu|ul)?\b/i,
21363
- operator: />>=?|<<=?|[-=]>|([-+&|])\1|~|\?\?=?|[-+*/%&|^!=<>]=?/,
21364
- punctuation: /\?\.?|::|[{}[\];(),.:]/
21365
- });
21366
- Prism.languages.insertBefore('csharp', 'number', {
21367
- range: {
21368
- pattern: /\.\./,
21369
- alias: 'operator'
21370
- }
21371
- });
21372
- Prism.languages.insertBefore('csharp', 'punctuation', {
21373
- 'named-parameter': {
21374
- pattern: re(/([(,]\s*)<<0>>(?=\s*:)/.source, [name]),
21375
- lookbehind: true,
21376
- alias: 'punctuation'
21377
- }
21378
- });
21379
- Prism.languages.insertBefore('csharp', 'class-name', {
21380
- namespace: {
21381
- // namespace Foo.Bar {}
21382
- // using Foo.Bar;
21383
- pattern: re(
21384
- /(\b(?:namespace|using)\s+)<<0>>(?:\s*\.\s*<<0>>)*(?=\s*[;{])/.source,
21385
- [name]
21386
- ),
21387
- lookbehind: true,
21388
- inside: {
21389
- punctuation: /\./
21390
- }
21391
- },
21392
- 'type-expression': {
21393
- // default(Foo), typeof(Foo<Bar>), sizeof(int)
21394
- pattern: re(
21395
- /(\b(?:default|sizeof|typeof)\s*\(\s*(?!\s))(?:[^()\s]|\s(?!\s)|<<0>>)*(?=\s*\))/
21396
- .source,
21397
- [nestedRound]
21398
- ),
21399
- lookbehind: true,
21400
- alias: 'class-name',
21401
- inside: typeInside
21402
- },
21403
- 'return-type': {
21404
- // Foo<Bar> ForBar(); Foo IFoo.Bar() => 0
21405
- // int this[int index] => 0; T IReadOnlyList<T>.this[int index] => this[index];
21406
- // int Foo => 0; int Foo { get; set } = 0;
21407
- pattern: re(
21408
- /<<0>>(?=\s+(?:<<1>>\s*(?:=>|[({]|\.\s*this\s*\[)|this\s*\[))/.source,
21409
- [typeExpression, identifier]
21410
- ),
21411
- inside: typeInside,
21412
- alias: 'class-name'
21413
- },
21414
- 'constructor-invocation': {
21415
- // new List<Foo<Bar[]>> { }
21416
- pattern: re(/(\bnew\s+)<<0>>(?=\s*[[({])/.source, [typeExpression]),
21417
- lookbehind: true,
21418
- inside: typeInside,
21419
- alias: 'class-name'
21420
- },
21421
- /*'explicit-implementation': {
21422
- // int IFoo<Foo>.Bar => 0; void IFoo<Foo<Foo>>.Foo<T>();
21423
- pattern: replace(/\b<<0>>(?=\.<<1>>)/, className, methodOrPropertyDeclaration),
21424
- inside: classNameInside,
21425
- alias: 'class-name'
21426
- },*/
21427
- 'generic-method': {
21428
- // foo<Bar>()
21429
- pattern: re(/<<0>>\s*<<1>>(?=\s*\()/.source, [name, generic]),
21430
- inside: {
21431
- function: re(/^<<0>>/.source, [name]),
21432
- generic: {
21433
- pattern: RegExp(generic),
21434
- alias: 'class-name',
21435
- inside: typeInside
21436
- }
21437
- }
21438
- },
21439
- 'type-list': {
21440
- // The list of types inherited or of generic constraints
21441
- // class Foo<F> : Bar, IList<FooBar>
21442
- // where F : Bar, IList<int>
21443
- pattern: re(
21444
- /\b((?:<<0>>\s+<<1>>|record\s+<<1>>\s*<<5>>|where\s+<<2>>)\s*:\s*)(?:<<3>>|<<4>>|<<1>>\s*<<5>>|<<6>>)(?:\s*,\s*(?:<<3>>|<<4>>|<<6>>))*(?=\s*(?:where|[{;]|=>|$))/
21445
- .source,
21446
- [
21447
- typeDeclarationKeywords,
21448
- genericName,
21449
- name,
21450
- typeExpression,
21451
- keywords.source,
21452
- nestedRound,
21453
- /\bnew\s*\(\s*\)/.source
21454
- ]
21455
- ),
21456
- lookbehind: true,
21457
- inside: {
21458
- 'record-arguments': {
21459
- pattern: re(/(^(?!new\s*\()<<0>>\s*)<<1>>/.source, [
21460
- genericName,
21461
- nestedRound
21462
- ]),
21463
- lookbehind: true,
21464
- greedy: true,
21465
- inside: Prism.languages.csharp
21466
- },
21467
- keyword: keywords,
21468
- 'class-name': {
21469
- pattern: RegExp(typeExpression),
21470
- greedy: true,
21471
- inside: typeInside
21472
- },
21473
- punctuation: /[,()]/
21474
- }
21475
- },
21476
- preprocessor: {
21477
- pattern: /(^[\t ]*)#.*/m,
21478
- lookbehind: true,
21479
- alias: 'property',
21480
- inside: {
21481
- // highlight preprocessor directives as keywords
21482
- directive: {
21483
- pattern:
21484
- /(#)\b(?:define|elif|else|endif|endregion|error|if|line|nullable|pragma|region|undef|warning)\b/,
21485
- lookbehind: true,
21486
- alias: 'keyword'
21487
- }
21488
- }
21489
- }
21490
- }); // attributes
21491
- var regularStringOrCharacter = regularString + '|' + character;
21492
- var regularStringCharacterOrComment = replace(
21493
- /\/(?![*/])|\/\/[^\r\n]*[\r\n]|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>/.source,
21494
- [regularStringOrCharacter]
21495
- );
21496
- var roundExpression = nested(
21497
- replace(/[^"'/()]|<<0>>|\(<<self>>*\)/.source, [
21498
- regularStringCharacterOrComment
21499
- ]),
21500
- 2
21501
- ); // https://docs.microsoft.com/en-us/dotnet/csharp/programming-guide/concepts/attributes/#attribute-targets
21502
- var attrTarget =
21503
- /\b(?:assembly|event|field|method|module|param|property|return|type)\b/
21504
- .source;
21505
- var attr = replace(/<<0>>(?:\s*\(<<1>>*\))?/.source, [
21506
- identifier,
21507
- roundExpression
21508
- ]);
21509
- Prism.languages.insertBefore('csharp', 'class-name', {
21510
- attribute: {
21511
- // Attributes
21512
- // [Foo], [Foo(1), Bar(2, Prop = "foo")], [return: Foo(1), Bar(2)], [assembly: Foo(Bar)]
21513
- pattern: re(
21514
- /((?:^|[^\s\w>)?])\s*\[\s*)(?:<<0>>\s*:\s*)?<<1>>(?:\s*,\s*<<1>>)*(?=\s*\])/
21515
- .source,
21516
- [attrTarget, attr]
21517
- ),
21518
- lookbehind: true,
21519
- greedy: true,
21520
- inside: {
21521
- target: {
21522
- pattern: re(/^<<0>>(?=\s*:)/.source, [attrTarget]),
21523
- alias: 'keyword'
21524
- },
21525
- 'attribute-arguments': {
21526
- pattern: re(/\(<<0>>*\)/.source, [roundExpression]),
21527
- inside: Prism.languages.csharp
21528
- },
21529
- 'class-name': {
21530
- pattern: RegExp(identifier),
21531
- inside: {
21532
- punctuation: /\./
21533
- }
21534
- },
21535
- punctuation: /[:,]/
21536
- }
21537
- }
21538
- }); // string interpolation
21539
- var formatString = /:[^}\r\n]+/.source; // multi line
21540
- var mInterpolationRound = nested(
21541
- replace(/[^"'/()]|<<0>>|\(<<self>>*\)/.source, [
21542
- regularStringCharacterOrComment
21543
- ]),
21544
- 2
21545
- );
21546
- var mInterpolation = replace(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source, [
21547
- mInterpolationRound,
21548
- formatString
21549
- ]); // single line
21550
- var sInterpolationRound = nested(
21551
- replace(
21552
- /[^"'/()]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>|\(<<self>>*\)/
21553
- .source,
21554
- [regularStringOrCharacter]
21555
- ),
21556
- 2
21557
- );
21558
- var sInterpolation = replace(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source, [
21559
- sInterpolationRound,
21560
- formatString
21561
- ]);
21562
- function createInterpolationInside(interpolation, interpolationRound) {
21563
- return {
21564
- interpolation: {
21565
- pattern: re(/((?:^|[^{])(?:\{\{)*)<<0>>/.source, [interpolation]),
21566
- lookbehind: true,
21567
- inside: {
21568
- 'format-string': {
21569
- pattern: re(/(^\{(?:(?![}:])<<0>>)*)<<1>>(?=\}$)/.source, [
21570
- interpolationRound,
21571
- formatString
21572
- ]),
21573
- lookbehind: true,
21574
- inside: {
21575
- punctuation: /^:/
21576
- }
21577
- },
21578
- punctuation: /^\{|\}$/,
21579
- expression: {
21580
- pattern: /[\s\S]+/,
21581
- alias: 'language-csharp',
21582
- inside: Prism.languages.csharp
21583
- }
21584
- }
21585
- },
21586
- string: /[\s\S]+/
21587
- }
21588
- }
21589
- Prism.languages.insertBefore('csharp', 'string', {
21590
- 'interpolation-string': [
21591
- {
21592
- pattern: re(
21593
- /(^|[^\\])(?:\$@|@\$)"(?:""|\\[\s\S]|\{\{|<<0>>|[^\\{"])*"/.source,
21594
- [mInterpolation]
21595
- ),
21596
- lookbehind: true,
21597
- greedy: true,
21598
- inside: createInterpolationInside(mInterpolation, mInterpolationRound)
21599
- },
21600
- {
21601
- pattern: re(/(^|[^@\\])\$"(?:\\.|\{\{|<<0>>|[^\\"{])*"/.source, [
21602
- sInterpolation
21603
- ]),
21604
- lookbehind: true,
21605
- greedy: true,
21606
- inside: createInterpolationInside(sInterpolation, sInterpolationRound)
21607
- }
21608
- ],
21609
- char: {
21610
- pattern: RegExp(character),
21611
- greedy: true
21612
- }
21613
- });
21614
- Prism.languages.dotnet = Prism.languages.cs = Prism.languages.csharp;
21615
- })(Prism);
21616
- }
21617
- return csharp_1;
21145
+ /**
21146
+ * Replaces all placeholders "<<n>>" of given pattern with the n-th replacement (zero based).
21147
+ *
21148
+ * Note: This is a simple text based replacement. Be careful when using backreferences!
21149
+ *
21150
+ * @param {string} pattern the given pattern.
21151
+ * @param {string[]} replacements a list of replacement which can be inserted into the given pattern.
21152
+ * @returns {string} the pattern with all placeholders replaced with their corresponding replacements.
21153
+ * @example replace(/a<<0>>a/.source, [/b+/.source]) === /a(?:b+)a/.source
21154
+ */
21155
+ function replace(pattern, replacements) {
21156
+ return pattern.replace(/<<(\d+)>>/g, function (m, index) {
21157
+ return '(?:' + replacements[+index] + ')'
21158
+ })
21159
+ }
21160
+ /**
21161
+ * @param {string} pattern
21162
+ * @param {string[]} replacements
21163
+ * @param {string} [flags]
21164
+ * @returns {RegExp}
21165
+ */
21166
+ function re(pattern, replacements, flags) {
21167
+ return RegExp(replace(pattern, replacements), flags || '')
21168
+ }
21169
+ /**
21170
+ * Creates a nested pattern where all occurrences of the string `<<self>>` are replaced with the pattern itself.
21171
+ *
21172
+ * @param {string} pattern
21173
+ * @param {number} depthLog2
21174
+ * @returns {string}
21175
+ */
21176
+ function nested(pattern, depthLog2) {
21177
+ for (var i = 0; i < depthLog2; i++) {
21178
+ pattern = pattern.replace(/<<self>>/g, function () {
21179
+ return '(?:' + pattern + ')'
21180
+ });
21181
+ }
21182
+ return pattern.replace(/<<self>>/g, '[^\\s\\S]')
21183
+ } // https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/keywords/
21184
+ var keywordKinds = {
21185
+ // keywords which represent a return or variable type
21186
+ type: 'bool byte char decimal double dynamic float int long object sbyte short string uint ulong ushort var void',
21187
+ // keywords which are used to declare a type
21188
+ typeDeclaration: 'class enum interface record struct',
21189
+ // contextual keywords
21190
+ // ("var" and "dynamic" are missing because they are used like types)
21191
+ contextual:
21192
+ 'add alias and ascending async await by descending from(?=\\s*(?:\\w|$)) get global group into init(?=\\s*;) join let nameof not notnull on or orderby partial remove select set unmanaged value when where with(?=\\s*{)',
21193
+ // all other keywords
21194
+ other:
21195
+ 'abstract as base break case catch checked const continue default delegate do else event explicit extern finally fixed for foreach goto if implicit in internal is lock namespace new null operator out override params private protected public readonly ref return sealed sizeof stackalloc static switch this throw try typeof unchecked unsafe using virtual volatile while yield'
21196
+ }; // keywords
21197
+ function keywordsToPattern(words) {
21198
+ return '\\b(?:' + words.trim().replace(/ /g, '|') + ')\\b'
21199
+ }
21200
+ var typeDeclarationKeywords = keywordsToPattern(
21201
+ keywordKinds.typeDeclaration
21202
+ );
21203
+ var keywords = RegExp(
21204
+ keywordsToPattern(
21205
+ keywordKinds.type +
21206
+ ' ' +
21207
+ keywordKinds.typeDeclaration +
21208
+ ' ' +
21209
+ keywordKinds.contextual +
21210
+ ' ' +
21211
+ keywordKinds.other
21212
+ )
21213
+ );
21214
+ var nonTypeKeywords = keywordsToPattern(
21215
+ keywordKinds.typeDeclaration +
21216
+ ' ' +
21217
+ keywordKinds.contextual +
21218
+ ' ' +
21219
+ keywordKinds.other
21220
+ );
21221
+ var nonContextualKeywords = keywordsToPattern(
21222
+ keywordKinds.type +
21223
+ ' ' +
21224
+ keywordKinds.typeDeclaration +
21225
+ ' ' +
21226
+ keywordKinds.other
21227
+ ); // types
21228
+ var generic = nested(/<(?:[^<>;=+\-*/%&|^]|<<self>>)*>/.source, 2); // the idea behind the other forbidden characters is to prevent false positives. Same for tupleElement.
21229
+ var nestedRound = nested(/\((?:[^()]|<<self>>)*\)/.source, 2);
21230
+ var name = /@?\b[A-Za-z_]\w*\b/.source;
21231
+ var genericName = replace(/<<0>>(?:\s*<<1>>)?/.source, [name, generic]);
21232
+ var identifier = replace(/(?!<<0>>)<<1>>(?:\s*\.\s*<<1>>)*/.source, [
21233
+ nonTypeKeywords,
21234
+ genericName
21235
+ ]);
21236
+ var array = /\[\s*(?:,\s*)*\]/.source;
21237
+ var typeExpressionWithoutTuple = replace(
21238
+ /<<0>>(?:\s*(?:\?\s*)?<<1>>)*(?:\s*\?)?/.source,
21239
+ [identifier, array]
21240
+ );
21241
+ var tupleElement = replace(
21242
+ /[^,()<>[\];=+\-*/%&|^]|<<0>>|<<1>>|<<2>>/.source,
21243
+ [generic, nestedRound, array]
21244
+ );
21245
+ var tuple = replace(/\(<<0>>+(?:,<<0>>+)+\)/.source, [tupleElement]);
21246
+ var typeExpression = replace(
21247
+ /(?:<<0>>|<<1>>)(?:\s*(?:\?\s*)?<<2>>)*(?:\s*\?)?/.source,
21248
+ [tuple, identifier, array]
21249
+ );
21250
+ var typeInside = {
21251
+ keyword: keywords,
21252
+ punctuation: /[<>()?,.:[\]]/
21253
+ }; // strings & characters
21254
+ // https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/language-specification/lexical-structure#character-literals
21255
+ // https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/language-specification/lexical-structure#string-literals
21256
+ var character = /'(?:[^\r\n'\\]|\\.|\\[Uux][\da-fA-F]{1,8})'/.source; // simplified pattern
21257
+ var regularString = /"(?:\\.|[^\\"\r\n])*"/.source;
21258
+ var verbatimString = /@"(?:""|\\[\s\S]|[^\\"])*"(?!")/.source;
21259
+ Prism.languages.csharp = Prism.languages.extend('clike', {
21260
+ string: [
21261
+ {
21262
+ pattern: re(/(^|[^$\\])<<0>>/.source, [verbatimString]),
21263
+ lookbehind: true,
21264
+ greedy: true
21265
+ },
21266
+ {
21267
+ pattern: re(/(^|[^@$\\])<<0>>/.source, [regularString]),
21268
+ lookbehind: true,
21269
+ greedy: true
21270
+ }
21271
+ ],
21272
+ 'class-name': [
21273
+ {
21274
+ // Using static
21275
+ // using static System.Math;
21276
+ pattern: re(/(\busing\s+static\s+)<<0>>(?=\s*;)/.source, [
21277
+ identifier
21278
+ ]),
21279
+ lookbehind: true,
21280
+ inside: typeInside
21281
+ },
21282
+ {
21283
+ // Using alias (type)
21284
+ // using Project = PC.MyCompany.Project;
21285
+ pattern: re(/(\busing\s+<<0>>\s*=\s*)<<1>>(?=\s*;)/.source, [
21286
+ name,
21287
+ typeExpression
21288
+ ]),
21289
+ lookbehind: true,
21290
+ inside: typeInside
21291
+ },
21292
+ {
21293
+ // Using alias (alias)
21294
+ // using Project = PC.MyCompany.Project;
21295
+ pattern: re(/(\busing\s+)<<0>>(?=\s*=)/.source, [name]),
21296
+ lookbehind: true
21297
+ },
21298
+ {
21299
+ // Type declarations
21300
+ // class Foo<A, B>
21301
+ // interface Foo<out A, B>
21302
+ pattern: re(/(\b<<0>>\s+)<<1>>/.source, [
21303
+ typeDeclarationKeywords,
21304
+ genericName
21305
+ ]),
21306
+ lookbehind: true,
21307
+ inside: typeInside
21308
+ },
21309
+ {
21310
+ // Single catch exception declaration
21311
+ // catch(Foo)
21312
+ // (things like catch(Foo e) is covered by variable declaration)
21313
+ pattern: re(/(\bcatch\s*\(\s*)<<0>>/.source, [identifier]),
21314
+ lookbehind: true,
21315
+ inside: typeInside
21316
+ },
21317
+ {
21318
+ // Name of the type parameter of generic constraints
21319
+ // where Foo : class
21320
+ pattern: re(/(\bwhere\s+)<<0>>/.source, [name]),
21321
+ lookbehind: true
21322
+ },
21323
+ {
21324
+ // Casts and checks via as and is.
21325
+ // as Foo<A>, is Bar<B>
21326
+ // (things like if(a is Foo b) is covered by variable declaration)
21327
+ pattern: re(/(\b(?:is(?:\s+not)?|as)\s+)<<0>>/.source, [
21328
+ typeExpressionWithoutTuple
21329
+ ]),
21330
+ lookbehind: true,
21331
+ inside: typeInside
21332
+ },
21333
+ {
21334
+ // Variable, field and parameter declaration
21335
+ // (Foo bar, Bar baz, Foo[,,] bay, Foo<Bar, FooBar<Bar>> bax)
21336
+ pattern: re(
21337
+ /\b<<0>>(?=\s+(?!<<1>>|with\s*\{)<<2>>(?:\s*[=,;:{)\]]|\s+(?:in|when)\b))/
21338
+ .source,
21339
+ [typeExpression, nonContextualKeywords, name]
21340
+ ),
21341
+ inside: typeInside
21342
+ }
21343
+ ],
21344
+ keyword: keywords,
21345
+ // https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/language-specification/lexical-structure#literals
21346
+ number:
21347
+ /(?:\b0(?:x[\da-f_]*[\da-f]|b[01_]*[01])|(?:\B\.\d+(?:_+\d+)*|\b\d+(?:_+\d+)*(?:\.\d+(?:_+\d+)*)?)(?:e[-+]?\d+(?:_+\d+)*)?)(?:[dflmu]|lu|ul)?\b/i,
21348
+ operator: />>=?|<<=?|[-=]>|([-+&|])\1|~|\?\?=?|[-+*/%&|^!=<>]=?/,
21349
+ punctuation: /\?\.?|::|[{}[\];(),.:]/
21350
+ });
21351
+ Prism.languages.insertBefore('csharp', 'number', {
21352
+ range: {
21353
+ pattern: /\.\./,
21354
+ alias: 'operator'
21355
+ }
21356
+ });
21357
+ Prism.languages.insertBefore('csharp', 'punctuation', {
21358
+ 'named-parameter': {
21359
+ pattern: re(/([(,]\s*)<<0>>(?=\s*:)/.source, [name]),
21360
+ lookbehind: true,
21361
+ alias: 'punctuation'
21362
+ }
21363
+ });
21364
+ Prism.languages.insertBefore('csharp', 'class-name', {
21365
+ namespace: {
21366
+ // namespace Foo.Bar {}
21367
+ // using Foo.Bar;
21368
+ pattern: re(
21369
+ /(\b(?:namespace|using)\s+)<<0>>(?:\s*\.\s*<<0>>)*(?=\s*[;{])/.source,
21370
+ [name]
21371
+ ),
21372
+ lookbehind: true,
21373
+ inside: {
21374
+ punctuation: /\./
21375
+ }
21376
+ },
21377
+ 'type-expression': {
21378
+ // default(Foo), typeof(Foo<Bar>), sizeof(int)
21379
+ pattern: re(
21380
+ /(\b(?:default|sizeof|typeof)\s*\(\s*(?!\s))(?:[^()\s]|\s(?!\s)|<<0>>)*(?=\s*\))/
21381
+ .source,
21382
+ [nestedRound]
21383
+ ),
21384
+ lookbehind: true,
21385
+ alias: 'class-name',
21386
+ inside: typeInside
21387
+ },
21388
+ 'return-type': {
21389
+ // Foo<Bar> ForBar(); Foo IFoo.Bar() => 0
21390
+ // int this[int index] => 0; T IReadOnlyList<T>.this[int index] => this[index];
21391
+ // int Foo => 0; int Foo { get; set } = 0;
21392
+ pattern: re(
21393
+ /<<0>>(?=\s+(?:<<1>>\s*(?:=>|[({]|\.\s*this\s*\[)|this\s*\[))/.source,
21394
+ [typeExpression, identifier]
21395
+ ),
21396
+ inside: typeInside,
21397
+ alias: 'class-name'
21398
+ },
21399
+ 'constructor-invocation': {
21400
+ // new List<Foo<Bar[]>> { }
21401
+ pattern: re(/(\bnew\s+)<<0>>(?=\s*[[({])/.source, [typeExpression]),
21402
+ lookbehind: true,
21403
+ inside: typeInside,
21404
+ alias: 'class-name'
21405
+ },
21406
+ /*'explicit-implementation': {
21407
+ // int IFoo<Foo>.Bar => 0; void IFoo<Foo<Foo>>.Foo<T>();
21408
+ pattern: replace(/\b<<0>>(?=\.<<1>>)/, className, methodOrPropertyDeclaration),
21409
+ inside: classNameInside,
21410
+ alias: 'class-name'
21411
+ },*/
21412
+ 'generic-method': {
21413
+ // foo<Bar>()
21414
+ pattern: re(/<<0>>\s*<<1>>(?=\s*\()/.source, [name, generic]),
21415
+ inside: {
21416
+ function: re(/^<<0>>/.source, [name]),
21417
+ generic: {
21418
+ pattern: RegExp(generic),
21419
+ alias: 'class-name',
21420
+ inside: typeInside
21421
+ }
21422
+ }
21423
+ },
21424
+ 'type-list': {
21425
+ // The list of types inherited or of generic constraints
21426
+ // class Foo<F> : Bar, IList<FooBar>
21427
+ // where F : Bar, IList<int>
21428
+ pattern: re(
21429
+ /\b((?:<<0>>\s+<<1>>|record\s+<<1>>\s*<<5>>|where\s+<<2>>)\s*:\s*)(?:<<3>>|<<4>>|<<1>>\s*<<5>>|<<6>>)(?:\s*,\s*(?:<<3>>|<<4>>|<<6>>))*(?=\s*(?:where|[{;]|=>|$))/
21430
+ .source,
21431
+ [
21432
+ typeDeclarationKeywords,
21433
+ genericName,
21434
+ name,
21435
+ typeExpression,
21436
+ keywords.source,
21437
+ nestedRound,
21438
+ /\bnew\s*\(\s*\)/.source
21439
+ ]
21440
+ ),
21441
+ lookbehind: true,
21442
+ inside: {
21443
+ 'record-arguments': {
21444
+ pattern: re(/(^(?!new\s*\()<<0>>\s*)<<1>>/.source, [
21445
+ genericName,
21446
+ nestedRound
21447
+ ]),
21448
+ lookbehind: true,
21449
+ greedy: true,
21450
+ inside: Prism.languages.csharp
21451
+ },
21452
+ keyword: keywords,
21453
+ 'class-name': {
21454
+ pattern: RegExp(typeExpression),
21455
+ greedy: true,
21456
+ inside: typeInside
21457
+ },
21458
+ punctuation: /[,()]/
21459
+ }
21460
+ },
21461
+ preprocessor: {
21462
+ pattern: /(^[\t ]*)#.*/m,
21463
+ lookbehind: true,
21464
+ alias: 'property',
21465
+ inside: {
21466
+ // highlight preprocessor directives as keywords
21467
+ directive: {
21468
+ pattern:
21469
+ /(#)\b(?:define|elif|else|endif|endregion|error|if|line|nullable|pragma|region|undef|warning)\b/,
21470
+ lookbehind: true,
21471
+ alias: 'keyword'
21472
+ }
21473
+ }
21474
+ }
21475
+ }); // attributes
21476
+ var regularStringOrCharacter = regularString + '|' + character;
21477
+ var regularStringCharacterOrComment = replace(
21478
+ /\/(?![*/])|\/\/[^\r\n]*[\r\n]|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>/.source,
21479
+ [regularStringOrCharacter]
21480
+ );
21481
+ var roundExpression = nested(
21482
+ replace(/[^"'/()]|<<0>>|\(<<self>>*\)/.source, [
21483
+ regularStringCharacterOrComment
21484
+ ]),
21485
+ 2
21486
+ ); // https://docs.microsoft.com/en-us/dotnet/csharp/programming-guide/concepts/attributes/#attribute-targets
21487
+ var attrTarget =
21488
+ /\b(?:assembly|event|field|method|module|param|property|return|type)\b/
21489
+ .source;
21490
+ var attr = replace(/<<0>>(?:\s*\(<<1>>*\))?/.source, [
21491
+ identifier,
21492
+ roundExpression
21493
+ ]);
21494
+ Prism.languages.insertBefore('csharp', 'class-name', {
21495
+ attribute: {
21496
+ // Attributes
21497
+ // [Foo], [Foo(1), Bar(2, Prop = "foo")], [return: Foo(1), Bar(2)], [assembly: Foo(Bar)]
21498
+ pattern: re(
21499
+ /((?:^|[^\s\w>)?])\s*\[\s*)(?:<<0>>\s*:\s*)?<<1>>(?:\s*,\s*<<1>>)*(?=\s*\])/
21500
+ .source,
21501
+ [attrTarget, attr]
21502
+ ),
21503
+ lookbehind: true,
21504
+ greedy: true,
21505
+ inside: {
21506
+ target: {
21507
+ pattern: re(/^<<0>>(?=\s*:)/.source, [attrTarget]),
21508
+ alias: 'keyword'
21509
+ },
21510
+ 'attribute-arguments': {
21511
+ pattern: re(/\(<<0>>*\)/.source, [roundExpression]),
21512
+ inside: Prism.languages.csharp
21513
+ },
21514
+ 'class-name': {
21515
+ pattern: RegExp(identifier),
21516
+ inside: {
21517
+ punctuation: /\./
21518
+ }
21519
+ },
21520
+ punctuation: /[:,]/
21521
+ }
21522
+ }
21523
+ }); // string interpolation
21524
+ var formatString = /:[^}\r\n]+/.source; // multi line
21525
+ var mInterpolationRound = nested(
21526
+ replace(/[^"'/()]|<<0>>|\(<<self>>*\)/.source, [
21527
+ regularStringCharacterOrComment
21528
+ ]),
21529
+ 2
21530
+ );
21531
+ var mInterpolation = replace(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source, [
21532
+ mInterpolationRound,
21533
+ formatString
21534
+ ]); // single line
21535
+ var sInterpolationRound = nested(
21536
+ replace(
21537
+ /[^"'/()]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>|\(<<self>>*\)/
21538
+ .source,
21539
+ [regularStringOrCharacter]
21540
+ ),
21541
+ 2
21542
+ );
21543
+ var sInterpolation = replace(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source, [
21544
+ sInterpolationRound,
21545
+ formatString
21546
+ ]);
21547
+ function createInterpolationInside(interpolation, interpolationRound) {
21548
+ return {
21549
+ interpolation: {
21550
+ pattern: re(/((?:^|[^{])(?:\{\{)*)<<0>>/.source, [interpolation]),
21551
+ lookbehind: true,
21552
+ inside: {
21553
+ 'format-string': {
21554
+ pattern: re(/(^\{(?:(?![}:])<<0>>)*)<<1>>(?=\}$)/.source, [
21555
+ interpolationRound,
21556
+ formatString
21557
+ ]),
21558
+ lookbehind: true,
21559
+ inside: {
21560
+ punctuation: /^:/
21561
+ }
21562
+ },
21563
+ punctuation: /^\{|\}$/,
21564
+ expression: {
21565
+ pattern: /[\s\S]+/,
21566
+ alias: 'language-csharp',
21567
+ inside: Prism.languages.csharp
21568
+ }
21569
+ }
21570
+ },
21571
+ string: /[\s\S]+/
21572
+ }
21573
+ }
21574
+ Prism.languages.insertBefore('csharp', 'string', {
21575
+ 'interpolation-string': [
21576
+ {
21577
+ pattern: re(
21578
+ /(^|[^\\])(?:\$@|@\$)"(?:""|\\[\s\S]|\{\{|<<0>>|[^\\{"])*"/.source,
21579
+ [mInterpolation]
21580
+ ),
21581
+ lookbehind: true,
21582
+ greedy: true,
21583
+ inside: createInterpolationInside(mInterpolation, mInterpolationRound)
21584
+ },
21585
+ {
21586
+ pattern: re(/(^|[^@\\])\$"(?:\\.|\{\{|<<0>>|[^\\"{])*"/.source, [
21587
+ sInterpolation
21588
+ ]),
21589
+ lookbehind: true,
21590
+ greedy: true,
21591
+ inside: createInterpolationInside(sInterpolation, sInterpolationRound)
21592
+ }
21593
+ ],
21594
+ char: {
21595
+ pattern: RegExp(character),
21596
+ greedy: true
21597
+ }
21598
+ });
21599
+ Prism.languages.dotnet = Prism.languages.cs = Prism.languages.csharp;
21600
+ })(Prism);
21618
21601
  }
21619
21602
 
21620
- var refractorCsharp = requireCsharp();
21603
+ var refractorCsharp$1 = csharp_1;
21621
21604
  var aspnet_1 = aspnet;
21622
21605
  aspnet.displayName = 'aspnet';
21623
21606
  aspnet.aliases = [];
21624
21607
  function aspnet(Prism) {
21625
- Prism.register(refractorCsharp);
21608
+ Prism.register(refractorCsharp$1);
21626
21609
  Prism.languages.aspnet = Prism.languages.extend('markup', {
21627
21610
  'page-directive': {
21628
21611
  pattern: /<%\s*@.*%>/,
@@ -22811,7 +22794,7 @@ function cfscript(Prism) {
22811
22794
  Prism.languages.cfc = Prism.languages['cfscript'];
22812
22795
  }
22813
22796
 
22814
- var refractorCpp = requireCpp();
22797
+ var refractorCpp = cpp_1;
22815
22798
  var chaiscript_1 = chaiscript;
22816
22799
  chaiscript.displayName = 'chaiscript';
22817
22800
  chaiscript.aliases = [];
@@ -22944,54 +22927,45 @@ function clojure(Prism) {
22944
22927
  };
22945
22928
  }
22946
22929
 
22947
- var cmake_1;
22948
- var hasRequiredCmake;
22949
-
22950
- function requireCmake () {
22951
- if (hasRequiredCmake) return cmake_1;
22952
- hasRequiredCmake = 1;
22953
-
22954
- cmake_1 = cmake;
22955
- cmake.displayName = 'cmake';
22956
- cmake.aliases = [];
22957
- function cmake(Prism) {
22958
- Prism.languages.cmake = {
22959
- comment: /#.*/,
22960
- string: {
22961
- pattern: /"(?:[^\\"]|\\.)*"/,
22962
- greedy: true,
22963
- inside: {
22964
- interpolation: {
22965
- pattern: /\$\{(?:[^{}$]|\$\{[^{}$]*\})*\}/,
22966
- inside: {
22967
- punctuation: /\$\{|\}/,
22968
- variable: /\w+/
22969
- }
22970
- }
22971
- }
22972
- },
22973
- variable:
22974
- /\b(?:CMAKE_\w+|\w+_(?:(?:BINARY|SOURCE)_DIR|DESCRIPTION|HOMEPAGE_URL|ROOT|VERSION(?:_MAJOR|_MINOR|_PATCH|_TWEAK)?)|(?:ANDROID|APPLE|BORLAND|BUILD_SHARED_LIBS|CACHE|CPACK_(?:ABSOLUTE_DESTINATION_FILES|COMPONENT_INCLUDE_TOPLEVEL_DIRECTORY|ERROR_ON_ABSOLUTE_INSTALL_DESTINATION|INCLUDE_TOPLEVEL_DIRECTORY|INSTALL_DEFAULT_DIRECTORY_PERMISSIONS|INSTALL_SCRIPT|PACKAGING_INSTALL_PREFIX|SET_DESTDIR|WARN_ON_ABSOLUTE_INSTALL_DESTINATION)|CTEST_(?:BINARY_DIRECTORY|BUILD_COMMAND|BUILD_NAME|BZR_COMMAND|BZR_UPDATE_OPTIONS|CHANGE_ID|CHECKOUT_COMMAND|CONFIGURATION_TYPE|CONFIGURE_COMMAND|COVERAGE_COMMAND|COVERAGE_EXTRA_FLAGS|CURL_OPTIONS|CUSTOM_(?:COVERAGE_EXCLUDE|ERROR_EXCEPTION|ERROR_MATCH|ERROR_POST_CONTEXT|ERROR_PRE_CONTEXT|MAXIMUM_FAILED_TEST_OUTPUT_SIZE|MAXIMUM_NUMBER_OF_(?:ERRORS|WARNINGS)|MAXIMUM_PASSED_TEST_OUTPUT_SIZE|MEMCHECK_IGNORE|POST_MEMCHECK|POST_TEST|PRE_MEMCHECK|PRE_TEST|TESTS_IGNORE|WARNING_EXCEPTION|WARNING_MATCH)|CVS_CHECKOUT|CVS_COMMAND|CVS_UPDATE_OPTIONS|DROP_LOCATION|DROP_METHOD|DROP_SITE|DROP_SITE_CDASH|DROP_SITE_PASSWORD|DROP_SITE_USER|EXTRA_COVERAGE_GLOB|GIT_COMMAND|GIT_INIT_SUBMODULES|GIT_UPDATE_CUSTOM|GIT_UPDATE_OPTIONS|HG_COMMAND|HG_UPDATE_OPTIONS|LABELS_FOR_SUBPROJECTS|MEMORYCHECK_(?:COMMAND|COMMAND_OPTIONS|SANITIZER_OPTIONS|SUPPRESSIONS_FILE|TYPE)|NIGHTLY_START_TIME|P4_CLIENT|P4_COMMAND|P4_OPTIONS|P4_UPDATE_OPTIONS|RUN_CURRENT_SCRIPT|SCP_COMMAND|SITE|SOURCE_DIRECTORY|SUBMIT_URL|SVN_COMMAND|SVN_OPTIONS|SVN_UPDATE_OPTIONS|TEST_LOAD|TEST_TIMEOUT|TRIGGER_SITE|UPDATE_COMMAND|UPDATE_OPTIONS|UPDATE_VERSION_ONLY|USE_LAUNCHERS)|CYGWIN|ENV|EXECUTABLE_OUTPUT_PATH|GHS-MULTI|IOS|LIBRARY_OUTPUT_PATH|MINGW|MSVC(?:10|11|12|14|60|70|71|80|90|_IDE|_TOOLSET_VERSION|_VERSION)?|MSYS|PROJECT_(?:BINARY_DIR|DESCRIPTION|HOMEPAGE_URL|NAME|SOURCE_DIR|VERSION|VERSION_(?:MAJOR|MINOR|PATCH|TWEAK))|UNIX|WIN32|WINCE|WINDOWS_PHONE|WINDOWS_STORE|XCODE|XCODE_VERSION))\b/,
22975
- property:
22976
- /\b(?:cxx_\w+|(?:ARCHIVE_OUTPUT_(?:DIRECTORY|NAME)|COMPILE_DEFINITIONS|COMPILE_PDB_NAME|COMPILE_PDB_OUTPUT_DIRECTORY|EXCLUDE_FROM_DEFAULT_BUILD|IMPORTED_(?:IMPLIB|LIBNAME|LINK_DEPENDENT_LIBRARIES|LINK_INTERFACE_LANGUAGES|LINK_INTERFACE_LIBRARIES|LINK_INTERFACE_MULTIPLICITY|LOCATION|NO_SONAME|OBJECTS|SONAME)|INTERPROCEDURAL_OPTIMIZATION|LIBRARY_OUTPUT_DIRECTORY|LIBRARY_OUTPUT_NAME|LINK_FLAGS|LINK_INTERFACE_LIBRARIES|LINK_INTERFACE_MULTIPLICITY|LOCATION|MAP_IMPORTED_CONFIG|OSX_ARCHITECTURES|OUTPUT_NAME|PDB_NAME|PDB_OUTPUT_DIRECTORY|RUNTIME_OUTPUT_DIRECTORY|RUNTIME_OUTPUT_NAME|STATIC_LIBRARY_FLAGS|VS_CSHARP|VS_DOTNET_REFERENCEPROP|VS_DOTNET_REFERENCE|VS_GLOBAL_SECTION_POST|VS_GLOBAL_SECTION_PRE|VS_GLOBAL|XCODE_ATTRIBUTE)_\w+|\w+_(?:CLANG_TIDY|COMPILER_LAUNCHER|CPPCHECK|CPPLINT|INCLUDE_WHAT_YOU_USE|OUTPUT_NAME|POSTFIX|VISIBILITY_PRESET)|ABSTRACT|ADDITIONAL_MAKE_CLEAN_FILES|ADVANCED|ALIASED_TARGET|ALLOW_DUPLICATE_CUSTOM_TARGETS|ANDROID_(?:ANT_ADDITIONAL_OPTIONS|API|API_MIN|ARCH|ASSETS_DIRECTORIES|GUI|JAR_DEPENDENCIES|NATIVE_LIB_DEPENDENCIES|NATIVE_LIB_DIRECTORIES|PROCESS_MAX|PROGUARD|PROGUARD_CONFIG_PATH|SECURE_PROPS_PATH|SKIP_ANT_STEP|STL_TYPE)|ARCHIVE_OUTPUT_DIRECTORY|ATTACHED_FILES|ATTACHED_FILES_ON_FAIL|AUTOGEN_(?:BUILD_DIR|ORIGIN_DEPENDS|PARALLEL|SOURCE_GROUP|TARGETS_FOLDER|TARGET_DEPENDS)|AUTOMOC|AUTOMOC_(?:COMPILER_PREDEFINES|DEPEND_FILTERS|EXECUTABLE|MACRO_NAMES|MOC_OPTIONS|SOURCE_GROUP|TARGETS_FOLDER)|AUTORCC|AUTORCC_EXECUTABLE|AUTORCC_OPTIONS|AUTORCC_SOURCE_GROUP|AUTOUIC|AUTOUIC_EXECUTABLE|AUTOUIC_OPTIONS|AUTOUIC_SEARCH_PATHS|BINARY_DIR|BUILDSYSTEM_TARGETS|BUILD_RPATH|BUILD_RPATH_USE_ORIGIN|BUILD_WITH_INSTALL_NAME_DIR|BUILD_WITH_INSTALL_RPATH|BUNDLE|BUNDLE_EXTENSION|CACHE_VARIABLES|CLEAN_NO_CUSTOM|COMMON_LANGUAGE_RUNTIME|COMPATIBLE_INTERFACE_(?:BOOL|NUMBER_MAX|NUMBER_MIN|STRING)|COMPILE_(?:DEFINITIONS|FEATURES|FLAGS|OPTIONS|PDB_NAME|PDB_OUTPUT_DIRECTORY)|COST|CPACK_DESKTOP_SHORTCUTS|CPACK_NEVER_OVERWRITE|CPACK_PERMANENT|CPACK_STARTUP_SHORTCUTS|CPACK_START_MENU_SHORTCUTS|CPACK_WIX_ACL|CROSSCOMPILING_EMULATOR|CUDA_EXTENSIONS|CUDA_PTX_COMPILATION|CUDA_RESOLVE_DEVICE_SYMBOLS|CUDA_SEPARABLE_COMPILATION|CUDA_STANDARD|CUDA_STANDARD_REQUIRED|CXX_EXTENSIONS|CXX_STANDARD|CXX_STANDARD_REQUIRED|C_EXTENSIONS|C_STANDARD|C_STANDARD_REQUIRED|DEBUG_CONFIGURATIONS|DEFINE_SYMBOL|DEFINITIONS|DEPENDS|DEPLOYMENT_ADDITIONAL_FILES|DEPLOYMENT_REMOTE_DIRECTORY|DISABLED|DISABLED_FEATURES|ECLIPSE_EXTRA_CPROJECT_CONTENTS|ECLIPSE_EXTRA_NATURES|ENABLED_FEATURES|ENABLED_LANGUAGES|ENABLE_EXPORTS|ENVIRONMENT|EXCLUDE_FROM_ALL|EXCLUDE_FROM_DEFAULT_BUILD|EXPORT_NAME|EXPORT_PROPERTIES|EXTERNAL_OBJECT|EchoString|FAIL_REGULAR_EXPRESSION|FIND_LIBRARY_USE_LIB32_PATHS|FIND_LIBRARY_USE_LIB64_PATHS|FIND_LIBRARY_USE_LIBX32_PATHS|FIND_LIBRARY_USE_OPENBSD_VERSIONING|FIXTURES_CLEANUP|FIXTURES_REQUIRED|FIXTURES_SETUP|FOLDER|FRAMEWORK|Fortran_FORMAT|Fortran_MODULE_DIRECTORY|GENERATED|GENERATOR_FILE_NAME|GENERATOR_IS_MULTI_CONFIG|GHS_INTEGRITY_APP|GHS_NO_SOURCE_GROUP_FILE|GLOBAL_DEPENDS_DEBUG_MODE|GLOBAL_DEPENDS_NO_CYCLES|GNUtoMS|HAS_CXX|HEADER_FILE_ONLY|HELPSTRING|IMPLICIT_DEPENDS_INCLUDE_TRANSFORM|IMPORTED|IMPORTED_(?:COMMON_LANGUAGE_RUNTIME|CONFIGURATIONS|GLOBAL|IMPLIB|LIBNAME|LINK_DEPENDENT_LIBRARIES|LINK_INTERFACE_(?:LANGUAGES|LIBRARIES|MULTIPLICITY)|LOCATION|NO_SONAME|OBJECTS|SONAME)|IMPORT_PREFIX|IMPORT_SUFFIX|INCLUDE_DIRECTORIES|INCLUDE_REGULAR_EXPRESSION|INSTALL_NAME_DIR|INSTALL_RPATH|INSTALL_RPATH_USE_LINK_PATH|INTERFACE_(?:AUTOUIC_OPTIONS|COMPILE_DEFINITIONS|COMPILE_FEATURES|COMPILE_OPTIONS|INCLUDE_DIRECTORIES|LINK_DEPENDS|LINK_DIRECTORIES|LINK_LIBRARIES|LINK_OPTIONS|POSITION_INDEPENDENT_CODE|SOURCES|SYSTEM_INCLUDE_DIRECTORIES)|INTERPROCEDURAL_OPTIMIZATION|IN_TRY_COMPILE|IOS_INSTALL_COMBINED|JOB_POOLS|JOB_POOL_COMPILE|JOB_POOL_LINK|KEEP_EXTENSION|LABELS|LANGUAGE|LIBRARY_OUTPUT_DIRECTORY|LINKER_LANGUAGE|LINK_(?:DEPENDS|DEPENDS_NO_SHARED|DIRECTORIES|FLAGS|INTERFACE_LIBRARIES|INTERFACE_MULTIPLICITY|LIBRARIES|OPTIONS|SEARCH_END_STATIC|SEARCH_START_STATIC|WHAT_YOU_USE)|LISTFILE_STACK|LOCATION|MACOSX_BUNDLE|MACOSX_BUNDLE_INFO_PLIST|MACOSX_FRAMEWORK_INFO_PLIST|MACOSX_PACKAGE_LOCATION|MACOSX_RPATH|MACROS|MANUALLY_ADDED_DEPENDENCIES|MEASUREMENT|MODIFIED|NAME|NO_SONAME|NO_SYSTEM_FROM_IMPORTED|OBJECT_DEPENDS|OBJECT_OUTPUTS|OSX_ARCHITECTURES|OUTPUT_NAME|PACKAGES_FOUND|PACKAGES_NOT_FOUND|PARENT_DIRECTORY|PASS_REGULAR_EXPRESSION|PDB_NAME|PDB_OUTPUT_DIRECTORY|POSITION_INDEPENDENT_CODE|POST_INSTALL_SCRIPT|PREDEFINED_TARGETS_FOLDER|PREFIX|PRE_INSTALL_SCRIPT|PRIVATE_HEADER|PROCESSORS|PROCESSOR_AFFINITY|PROJECT_LABEL|PUBLIC_HEADER|REPORT_UNDEFINED_PROPERTIES|REQUIRED_FILES|RESOURCE|RESOURCE_LOCK|RULE_LAUNCH_COMPILE|RULE_LAUNCH_CUSTOM|RULE_LAUNCH_LINK|RULE_MESSAGES|RUNTIME_OUTPUT_DIRECTORY|RUN_SERIAL|SKIP_AUTOGEN|SKIP_AUTOMOC|SKIP_AUTORCC|SKIP_AUTOUIC|SKIP_BUILD_RPATH|SKIP_RETURN_CODE|SOURCES|SOURCE_DIR|SOVERSION|STATIC_LIBRARY_FLAGS|STATIC_LIBRARY_OPTIONS|STRINGS|SUBDIRECTORIES|SUFFIX|SYMBOLIC|TARGET_ARCHIVES_MAY_BE_SHARED_LIBS|TARGET_MESSAGES|TARGET_SUPPORTS_SHARED_LIBS|TESTS|TEST_INCLUDE_FILE|TEST_INCLUDE_FILES|TIMEOUT|TIMEOUT_AFTER_MATCH|TYPE|USE_FOLDERS|VALUE|VARIABLES|VERSION|VISIBILITY_INLINES_HIDDEN|VS_(?:CONFIGURATION_TYPE|COPY_TO_OUT_DIR|DEBUGGER_(?:COMMAND|COMMAND_ARGUMENTS|ENVIRONMENT|WORKING_DIRECTORY)|DEPLOYMENT_CONTENT|DEPLOYMENT_LOCATION|DOTNET_REFERENCES|DOTNET_REFERENCES_COPY_LOCAL|GLOBAL_KEYWORD|GLOBAL_PROJECT_TYPES|GLOBAL_ROOTNAMESPACE|INCLUDE_IN_VSIX|IOT_STARTUP_TASK|KEYWORD|RESOURCE_GENERATOR|SCC_AUXPATH|SCC_LOCALPATH|SCC_PROJECTNAME|SCC_PROVIDER|SDK_REFERENCES|SHADER_(?:DISABLE_OPTIMIZATIONS|ENABLE_DEBUG|ENTRYPOINT|FLAGS|MODEL|OBJECT_FILE_NAME|OUTPUT_HEADER_FILE|TYPE|VARIABLE_NAME)|STARTUP_PROJECT|TOOL_OVERRIDE|USER_PROPS|WINRT_COMPONENT|WINRT_EXTENSIONS|WINRT_REFERENCES|XAML_TYPE)|WILL_FAIL|WIN32_EXECUTABLE|WINDOWS_EXPORT_ALL_SYMBOLS|WORKING_DIRECTORY|WRAP_EXCLUDE|XCODE_(?:EMIT_EFFECTIVE_PLATFORM_NAME|EXPLICIT_FILE_TYPE|FILE_ATTRIBUTES|LAST_KNOWN_FILE_TYPE|PRODUCT_TYPE|SCHEME_(?:ADDRESS_SANITIZER|ADDRESS_SANITIZER_USE_AFTER_RETURN|ARGUMENTS|DISABLE_MAIN_THREAD_CHECKER|DYNAMIC_LIBRARY_LOADS|DYNAMIC_LINKER_API_USAGE|ENVIRONMENT|EXECUTABLE|GUARD_MALLOC|MAIN_THREAD_CHECKER_STOP|MALLOC_GUARD_EDGES|MALLOC_SCRIBBLE|MALLOC_STACK|THREAD_SANITIZER(?:_STOP)?|UNDEFINED_BEHAVIOUR_SANITIZER(?:_STOP)?|ZOMBIE_OBJECTS))|XCTEST)\b/,
22977
- keyword:
22978
- /\b(?:add_compile_definitions|add_compile_options|add_custom_command|add_custom_target|add_definitions|add_dependencies|add_executable|add_library|add_link_options|add_subdirectory|add_test|aux_source_directory|break|build_command|build_name|cmake_host_system_information|cmake_minimum_required|cmake_parse_arguments|cmake_policy|configure_file|continue|create_test_sourcelist|ctest_build|ctest_configure|ctest_coverage|ctest_empty_binary_directory|ctest_memcheck|ctest_read_custom_files|ctest_run_script|ctest_sleep|ctest_start|ctest_submit|ctest_test|ctest_update|ctest_upload|define_property|else|elseif|enable_language|enable_testing|endforeach|endfunction|endif|endmacro|endwhile|exec_program|execute_process|export|export_library_dependencies|file|find_file|find_library|find_package|find_path|find_program|fltk_wrap_ui|foreach|function|get_cmake_property|get_directory_property|get_filename_component|get_property|get_source_file_property|get_target_property|get_test_property|if|include|include_directories|include_external_msproject|include_guard|include_regular_expression|install|install_files|install_programs|install_targets|link_directories|link_libraries|list|load_cache|load_command|macro|make_directory|mark_as_advanced|math|message|option|output_required_files|project|qt_wrap_cpp|qt_wrap_ui|remove|remove_definitions|return|separate_arguments|set|set_directory_properties|set_property|set_source_files_properties|set_target_properties|set_tests_properties|site_name|source_group|string|subdir_depends|subdirs|target_compile_definitions|target_compile_features|target_compile_options|target_include_directories|target_link_directories|target_link_libraries|target_link_options|target_sources|try_compile|try_run|unset|use_mangled_mesa|utility_source|variable_requires|variable_watch|while|write_file)(?=\s*\()\b/,
22979
- boolean: /\b(?:FALSE|OFF|ON|TRUE)\b/,
22980
- namespace:
22981
- /\b(?:INTERFACE|PRIVATE|PROPERTIES|PUBLIC|SHARED|STATIC|TARGET_OBJECTS)\b/,
22982
- operator:
22983
- /\b(?:AND|DEFINED|EQUAL|GREATER|LESS|MATCHES|NOT|OR|STREQUAL|STRGREATER|STRLESS|VERSION_EQUAL|VERSION_GREATER|VERSION_LESS)\b/,
22984
- inserted: {
22985
- pattern: /\b\w+::\w+\b/,
22986
- alias: 'class-name'
22987
- },
22988
- number: /\b\d+(?:\.\d+)*\b/,
22989
- function: /\b[a-z_]\w*(?=\s*\()\b/i,
22990
- punctuation: /[()>}]|\$[<{]/
22991
- };
22992
- }
22993
- return cmake_1;
22994
- }
22930
+ var cmake_1 = cmake;
22931
+ cmake.displayName = 'cmake';
22932
+ cmake.aliases = [];
22933
+ function cmake(Prism) {
22934
+ Prism.languages.cmake = {
22935
+ comment: /#.*/,
22936
+ string: {
22937
+ pattern: /"(?:[^\\"]|\\.)*"/,
22938
+ greedy: true,
22939
+ inside: {
22940
+ interpolation: {
22941
+ pattern: /\$\{(?:[^{}$]|\$\{[^{}$]*\})*\}/,
22942
+ inside: {
22943
+ punctuation: /\$\{|\}/,
22944
+ variable: /\w+/
22945
+ }
22946
+ }
22947
+ }
22948
+ },
22949
+ variable:
22950
+ /\b(?:CMAKE_\w+|\w+_(?:(?:BINARY|SOURCE)_DIR|DESCRIPTION|HOMEPAGE_URL|ROOT|VERSION(?:_MAJOR|_MINOR|_PATCH|_TWEAK)?)|(?:ANDROID|APPLE|BORLAND|BUILD_SHARED_LIBS|CACHE|CPACK_(?:ABSOLUTE_DESTINATION_FILES|COMPONENT_INCLUDE_TOPLEVEL_DIRECTORY|ERROR_ON_ABSOLUTE_INSTALL_DESTINATION|INCLUDE_TOPLEVEL_DIRECTORY|INSTALL_DEFAULT_DIRECTORY_PERMISSIONS|INSTALL_SCRIPT|PACKAGING_INSTALL_PREFIX|SET_DESTDIR|WARN_ON_ABSOLUTE_INSTALL_DESTINATION)|CTEST_(?:BINARY_DIRECTORY|BUILD_COMMAND|BUILD_NAME|BZR_COMMAND|BZR_UPDATE_OPTIONS|CHANGE_ID|CHECKOUT_COMMAND|CONFIGURATION_TYPE|CONFIGURE_COMMAND|COVERAGE_COMMAND|COVERAGE_EXTRA_FLAGS|CURL_OPTIONS|CUSTOM_(?:COVERAGE_EXCLUDE|ERROR_EXCEPTION|ERROR_MATCH|ERROR_POST_CONTEXT|ERROR_PRE_CONTEXT|MAXIMUM_FAILED_TEST_OUTPUT_SIZE|MAXIMUM_NUMBER_OF_(?:ERRORS|WARNINGS)|MAXIMUM_PASSED_TEST_OUTPUT_SIZE|MEMCHECK_IGNORE|POST_MEMCHECK|POST_TEST|PRE_MEMCHECK|PRE_TEST|TESTS_IGNORE|WARNING_EXCEPTION|WARNING_MATCH)|CVS_CHECKOUT|CVS_COMMAND|CVS_UPDATE_OPTIONS|DROP_LOCATION|DROP_METHOD|DROP_SITE|DROP_SITE_CDASH|DROP_SITE_PASSWORD|DROP_SITE_USER|EXTRA_COVERAGE_GLOB|GIT_COMMAND|GIT_INIT_SUBMODULES|GIT_UPDATE_CUSTOM|GIT_UPDATE_OPTIONS|HG_COMMAND|HG_UPDATE_OPTIONS|LABELS_FOR_SUBPROJECTS|MEMORYCHECK_(?:COMMAND|COMMAND_OPTIONS|SANITIZER_OPTIONS|SUPPRESSIONS_FILE|TYPE)|NIGHTLY_START_TIME|P4_CLIENT|P4_COMMAND|P4_OPTIONS|P4_UPDATE_OPTIONS|RUN_CURRENT_SCRIPT|SCP_COMMAND|SITE|SOURCE_DIRECTORY|SUBMIT_URL|SVN_COMMAND|SVN_OPTIONS|SVN_UPDATE_OPTIONS|TEST_LOAD|TEST_TIMEOUT|TRIGGER_SITE|UPDATE_COMMAND|UPDATE_OPTIONS|UPDATE_VERSION_ONLY|USE_LAUNCHERS)|CYGWIN|ENV|EXECUTABLE_OUTPUT_PATH|GHS-MULTI|IOS|LIBRARY_OUTPUT_PATH|MINGW|MSVC(?:10|11|12|14|60|70|71|80|90|_IDE|_TOOLSET_VERSION|_VERSION)?|MSYS|PROJECT_(?:BINARY_DIR|DESCRIPTION|HOMEPAGE_URL|NAME|SOURCE_DIR|VERSION|VERSION_(?:MAJOR|MINOR|PATCH|TWEAK))|UNIX|WIN32|WINCE|WINDOWS_PHONE|WINDOWS_STORE|XCODE|XCODE_VERSION))\b/,
22951
+ property:
22952
+ /\b(?:cxx_\w+|(?:ARCHIVE_OUTPUT_(?:DIRECTORY|NAME)|COMPILE_DEFINITIONS|COMPILE_PDB_NAME|COMPILE_PDB_OUTPUT_DIRECTORY|EXCLUDE_FROM_DEFAULT_BUILD|IMPORTED_(?:IMPLIB|LIBNAME|LINK_DEPENDENT_LIBRARIES|LINK_INTERFACE_LANGUAGES|LINK_INTERFACE_LIBRARIES|LINK_INTERFACE_MULTIPLICITY|LOCATION|NO_SONAME|OBJECTS|SONAME)|INTERPROCEDURAL_OPTIMIZATION|LIBRARY_OUTPUT_DIRECTORY|LIBRARY_OUTPUT_NAME|LINK_FLAGS|LINK_INTERFACE_LIBRARIES|LINK_INTERFACE_MULTIPLICITY|LOCATION|MAP_IMPORTED_CONFIG|OSX_ARCHITECTURES|OUTPUT_NAME|PDB_NAME|PDB_OUTPUT_DIRECTORY|RUNTIME_OUTPUT_DIRECTORY|RUNTIME_OUTPUT_NAME|STATIC_LIBRARY_FLAGS|VS_CSHARP|VS_DOTNET_REFERENCEPROP|VS_DOTNET_REFERENCE|VS_GLOBAL_SECTION_POST|VS_GLOBAL_SECTION_PRE|VS_GLOBAL|XCODE_ATTRIBUTE)_\w+|\w+_(?:CLANG_TIDY|COMPILER_LAUNCHER|CPPCHECK|CPPLINT|INCLUDE_WHAT_YOU_USE|OUTPUT_NAME|POSTFIX|VISIBILITY_PRESET)|ABSTRACT|ADDITIONAL_MAKE_CLEAN_FILES|ADVANCED|ALIASED_TARGET|ALLOW_DUPLICATE_CUSTOM_TARGETS|ANDROID_(?:ANT_ADDITIONAL_OPTIONS|API|API_MIN|ARCH|ASSETS_DIRECTORIES|GUI|JAR_DEPENDENCIES|NATIVE_LIB_DEPENDENCIES|NATIVE_LIB_DIRECTORIES|PROCESS_MAX|PROGUARD|PROGUARD_CONFIG_PATH|SECURE_PROPS_PATH|SKIP_ANT_STEP|STL_TYPE)|ARCHIVE_OUTPUT_DIRECTORY|ATTACHED_FILES|ATTACHED_FILES_ON_FAIL|AUTOGEN_(?:BUILD_DIR|ORIGIN_DEPENDS|PARALLEL|SOURCE_GROUP|TARGETS_FOLDER|TARGET_DEPENDS)|AUTOMOC|AUTOMOC_(?:COMPILER_PREDEFINES|DEPEND_FILTERS|EXECUTABLE|MACRO_NAMES|MOC_OPTIONS|SOURCE_GROUP|TARGETS_FOLDER)|AUTORCC|AUTORCC_EXECUTABLE|AUTORCC_OPTIONS|AUTORCC_SOURCE_GROUP|AUTOUIC|AUTOUIC_EXECUTABLE|AUTOUIC_OPTIONS|AUTOUIC_SEARCH_PATHS|BINARY_DIR|BUILDSYSTEM_TARGETS|BUILD_RPATH|BUILD_RPATH_USE_ORIGIN|BUILD_WITH_INSTALL_NAME_DIR|BUILD_WITH_INSTALL_RPATH|BUNDLE|BUNDLE_EXTENSION|CACHE_VARIABLES|CLEAN_NO_CUSTOM|COMMON_LANGUAGE_RUNTIME|COMPATIBLE_INTERFACE_(?:BOOL|NUMBER_MAX|NUMBER_MIN|STRING)|COMPILE_(?:DEFINITIONS|FEATURES|FLAGS|OPTIONS|PDB_NAME|PDB_OUTPUT_DIRECTORY)|COST|CPACK_DESKTOP_SHORTCUTS|CPACK_NEVER_OVERWRITE|CPACK_PERMANENT|CPACK_STARTUP_SHORTCUTS|CPACK_START_MENU_SHORTCUTS|CPACK_WIX_ACL|CROSSCOMPILING_EMULATOR|CUDA_EXTENSIONS|CUDA_PTX_COMPILATION|CUDA_RESOLVE_DEVICE_SYMBOLS|CUDA_SEPARABLE_COMPILATION|CUDA_STANDARD|CUDA_STANDARD_REQUIRED|CXX_EXTENSIONS|CXX_STANDARD|CXX_STANDARD_REQUIRED|C_EXTENSIONS|C_STANDARD|C_STANDARD_REQUIRED|DEBUG_CONFIGURATIONS|DEFINE_SYMBOL|DEFINITIONS|DEPENDS|DEPLOYMENT_ADDITIONAL_FILES|DEPLOYMENT_REMOTE_DIRECTORY|DISABLED|DISABLED_FEATURES|ECLIPSE_EXTRA_CPROJECT_CONTENTS|ECLIPSE_EXTRA_NATURES|ENABLED_FEATURES|ENABLED_LANGUAGES|ENABLE_EXPORTS|ENVIRONMENT|EXCLUDE_FROM_ALL|EXCLUDE_FROM_DEFAULT_BUILD|EXPORT_NAME|EXPORT_PROPERTIES|EXTERNAL_OBJECT|EchoString|FAIL_REGULAR_EXPRESSION|FIND_LIBRARY_USE_LIB32_PATHS|FIND_LIBRARY_USE_LIB64_PATHS|FIND_LIBRARY_USE_LIBX32_PATHS|FIND_LIBRARY_USE_OPENBSD_VERSIONING|FIXTURES_CLEANUP|FIXTURES_REQUIRED|FIXTURES_SETUP|FOLDER|FRAMEWORK|Fortran_FORMAT|Fortran_MODULE_DIRECTORY|GENERATED|GENERATOR_FILE_NAME|GENERATOR_IS_MULTI_CONFIG|GHS_INTEGRITY_APP|GHS_NO_SOURCE_GROUP_FILE|GLOBAL_DEPENDS_DEBUG_MODE|GLOBAL_DEPENDS_NO_CYCLES|GNUtoMS|HAS_CXX|HEADER_FILE_ONLY|HELPSTRING|IMPLICIT_DEPENDS_INCLUDE_TRANSFORM|IMPORTED|IMPORTED_(?:COMMON_LANGUAGE_RUNTIME|CONFIGURATIONS|GLOBAL|IMPLIB|LIBNAME|LINK_DEPENDENT_LIBRARIES|LINK_INTERFACE_(?:LANGUAGES|LIBRARIES|MULTIPLICITY)|LOCATION|NO_SONAME|OBJECTS|SONAME)|IMPORT_PREFIX|IMPORT_SUFFIX|INCLUDE_DIRECTORIES|INCLUDE_REGULAR_EXPRESSION|INSTALL_NAME_DIR|INSTALL_RPATH|INSTALL_RPATH_USE_LINK_PATH|INTERFACE_(?:AUTOUIC_OPTIONS|COMPILE_DEFINITIONS|COMPILE_FEATURES|COMPILE_OPTIONS|INCLUDE_DIRECTORIES|LINK_DEPENDS|LINK_DIRECTORIES|LINK_LIBRARIES|LINK_OPTIONS|POSITION_INDEPENDENT_CODE|SOURCES|SYSTEM_INCLUDE_DIRECTORIES)|INTERPROCEDURAL_OPTIMIZATION|IN_TRY_COMPILE|IOS_INSTALL_COMBINED|JOB_POOLS|JOB_POOL_COMPILE|JOB_POOL_LINK|KEEP_EXTENSION|LABELS|LANGUAGE|LIBRARY_OUTPUT_DIRECTORY|LINKER_LANGUAGE|LINK_(?:DEPENDS|DEPENDS_NO_SHARED|DIRECTORIES|FLAGS|INTERFACE_LIBRARIES|INTERFACE_MULTIPLICITY|LIBRARIES|OPTIONS|SEARCH_END_STATIC|SEARCH_START_STATIC|WHAT_YOU_USE)|LISTFILE_STACK|LOCATION|MACOSX_BUNDLE|MACOSX_BUNDLE_INFO_PLIST|MACOSX_FRAMEWORK_INFO_PLIST|MACOSX_PACKAGE_LOCATION|MACOSX_RPATH|MACROS|MANUALLY_ADDED_DEPENDENCIES|MEASUREMENT|MODIFIED|NAME|NO_SONAME|NO_SYSTEM_FROM_IMPORTED|OBJECT_DEPENDS|OBJECT_OUTPUTS|OSX_ARCHITECTURES|OUTPUT_NAME|PACKAGES_FOUND|PACKAGES_NOT_FOUND|PARENT_DIRECTORY|PASS_REGULAR_EXPRESSION|PDB_NAME|PDB_OUTPUT_DIRECTORY|POSITION_INDEPENDENT_CODE|POST_INSTALL_SCRIPT|PREDEFINED_TARGETS_FOLDER|PREFIX|PRE_INSTALL_SCRIPT|PRIVATE_HEADER|PROCESSORS|PROCESSOR_AFFINITY|PROJECT_LABEL|PUBLIC_HEADER|REPORT_UNDEFINED_PROPERTIES|REQUIRED_FILES|RESOURCE|RESOURCE_LOCK|RULE_LAUNCH_COMPILE|RULE_LAUNCH_CUSTOM|RULE_LAUNCH_LINK|RULE_MESSAGES|RUNTIME_OUTPUT_DIRECTORY|RUN_SERIAL|SKIP_AUTOGEN|SKIP_AUTOMOC|SKIP_AUTORCC|SKIP_AUTOUIC|SKIP_BUILD_RPATH|SKIP_RETURN_CODE|SOURCES|SOURCE_DIR|SOVERSION|STATIC_LIBRARY_FLAGS|STATIC_LIBRARY_OPTIONS|STRINGS|SUBDIRECTORIES|SUFFIX|SYMBOLIC|TARGET_ARCHIVES_MAY_BE_SHARED_LIBS|TARGET_MESSAGES|TARGET_SUPPORTS_SHARED_LIBS|TESTS|TEST_INCLUDE_FILE|TEST_INCLUDE_FILES|TIMEOUT|TIMEOUT_AFTER_MATCH|TYPE|USE_FOLDERS|VALUE|VARIABLES|VERSION|VISIBILITY_INLINES_HIDDEN|VS_(?:CONFIGURATION_TYPE|COPY_TO_OUT_DIR|DEBUGGER_(?:COMMAND|COMMAND_ARGUMENTS|ENVIRONMENT|WORKING_DIRECTORY)|DEPLOYMENT_CONTENT|DEPLOYMENT_LOCATION|DOTNET_REFERENCES|DOTNET_REFERENCES_COPY_LOCAL|GLOBAL_KEYWORD|GLOBAL_PROJECT_TYPES|GLOBAL_ROOTNAMESPACE|INCLUDE_IN_VSIX|IOT_STARTUP_TASK|KEYWORD|RESOURCE_GENERATOR|SCC_AUXPATH|SCC_LOCALPATH|SCC_PROJECTNAME|SCC_PROVIDER|SDK_REFERENCES|SHADER_(?:DISABLE_OPTIMIZATIONS|ENABLE_DEBUG|ENTRYPOINT|FLAGS|MODEL|OBJECT_FILE_NAME|OUTPUT_HEADER_FILE|TYPE|VARIABLE_NAME)|STARTUP_PROJECT|TOOL_OVERRIDE|USER_PROPS|WINRT_COMPONENT|WINRT_EXTENSIONS|WINRT_REFERENCES|XAML_TYPE)|WILL_FAIL|WIN32_EXECUTABLE|WINDOWS_EXPORT_ALL_SYMBOLS|WORKING_DIRECTORY|WRAP_EXCLUDE|XCODE_(?:EMIT_EFFECTIVE_PLATFORM_NAME|EXPLICIT_FILE_TYPE|FILE_ATTRIBUTES|LAST_KNOWN_FILE_TYPE|PRODUCT_TYPE|SCHEME_(?:ADDRESS_SANITIZER|ADDRESS_SANITIZER_USE_AFTER_RETURN|ARGUMENTS|DISABLE_MAIN_THREAD_CHECKER|DYNAMIC_LIBRARY_LOADS|DYNAMIC_LINKER_API_USAGE|ENVIRONMENT|EXECUTABLE|GUARD_MALLOC|MAIN_THREAD_CHECKER_STOP|MALLOC_GUARD_EDGES|MALLOC_SCRIBBLE|MALLOC_STACK|THREAD_SANITIZER(?:_STOP)?|UNDEFINED_BEHAVIOUR_SANITIZER(?:_STOP)?|ZOMBIE_OBJECTS))|XCTEST)\b/,
22953
+ keyword:
22954
+ /\b(?:add_compile_definitions|add_compile_options|add_custom_command|add_custom_target|add_definitions|add_dependencies|add_executable|add_library|add_link_options|add_subdirectory|add_test|aux_source_directory|break|build_command|build_name|cmake_host_system_information|cmake_minimum_required|cmake_parse_arguments|cmake_policy|configure_file|continue|create_test_sourcelist|ctest_build|ctest_configure|ctest_coverage|ctest_empty_binary_directory|ctest_memcheck|ctest_read_custom_files|ctest_run_script|ctest_sleep|ctest_start|ctest_submit|ctest_test|ctest_update|ctest_upload|define_property|else|elseif|enable_language|enable_testing|endforeach|endfunction|endif|endmacro|endwhile|exec_program|execute_process|export|export_library_dependencies|file|find_file|find_library|find_package|find_path|find_program|fltk_wrap_ui|foreach|function|get_cmake_property|get_directory_property|get_filename_component|get_property|get_source_file_property|get_target_property|get_test_property|if|include|include_directories|include_external_msproject|include_guard|include_regular_expression|install|install_files|install_programs|install_targets|link_directories|link_libraries|list|load_cache|load_command|macro|make_directory|mark_as_advanced|math|message|option|output_required_files|project|qt_wrap_cpp|qt_wrap_ui|remove|remove_definitions|return|separate_arguments|set|set_directory_properties|set_property|set_source_files_properties|set_target_properties|set_tests_properties|site_name|source_group|string|subdir_depends|subdirs|target_compile_definitions|target_compile_features|target_compile_options|target_include_directories|target_link_directories|target_link_libraries|target_link_options|target_sources|try_compile|try_run|unset|use_mangled_mesa|utility_source|variable_requires|variable_watch|while|write_file)(?=\s*\()\b/,
22955
+ boolean: /\b(?:FALSE|OFF|ON|TRUE)\b/,
22956
+ namespace:
22957
+ /\b(?:INTERFACE|PRIVATE|PROPERTIES|PUBLIC|SHARED|STATIC|TARGET_OBJECTS)\b/,
22958
+ operator:
22959
+ /\b(?:AND|DEFINED|EQUAL|GREATER|LESS|MATCHES|NOT|OR|STREQUAL|STRGREATER|STRLESS|VERSION_EQUAL|VERSION_GREATER|VERSION_LESS)\b/,
22960
+ inserted: {
22961
+ pattern: /\b\w+::\w+\b/,
22962
+ alias: 'class-name'
22963
+ },
22964
+ number: /\b\d+(?:\.\d+)*\b/,
22965
+ function: /\b[a-z_]\w*(?=\s*\()\b/i,
22966
+ punctuation: /[()>}]|\$[<{]/
22967
+ };
22968
+ }
22995
22969
 
22996
22970
  var cobol_1 = cobol;
22997
22971
  cobol.displayName = 'cobol';
@@ -23051,1127 +23025,1030 @@ function cobol(Prism) {
23051
23025
  };
23052
23026
  }
23053
23027
 
23054
- var coffeescript_1;
23055
- var hasRequiredCoffeescript;
23056
-
23057
- function requireCoffeescript () {
23058
- if (hasRequiredCoffeescript) return coffeescript_1;
23059
- hasRequiredCoffeescript = 1;
23060
-
23061
- coffeescript_1 = coffeescript;
23062
- coffeescript.displayName = 'coffeescript';
23063
- coffeescript.aliases = ['coffee'];
23064
- function coffeescript(Prism) {
23028
+ var coffeescript_1 = coffeescript;
23029
+ coffeescript.displayName = 'coffeescript';
23030
+ coffeescript.aliases = ['coffee'];
23031
+ function coffeescript(Prism) {
23065
23032
  (function (Prism) {
23066
- // Ignore comments starting with { to privilege string interpolation highlighting
23067
- var comment = /#(?!\{).+/;
23068
- var interpolation = {
23069
- pattern: /#\{[^}]+\}/,
23070
- alias: 'variable'
23071
- };
23072
- Prism.languages.coffeescript = Prism.languages.extend('javascript', {
23073
- comment: comment,
23074
- string: [
23075
- // Strings are multiline
23076
- {
23077
- pattern: /'(?:\\[\s\S]|[^\\'])*'/,
23078
- greedy: true
23079
- },
23080
- {
23081
- // Strings are multiline
23082
- pattern: /"(?:\\[\s\S]|[^\\"])*"/,
23083
- greedy: true,
23084
- inside: {
23085
- interpolation: interpolation
23086
- }
23087
- }
23088
- ],
23089
- keyword:
23090
- /\b(?:and|break|by|catch|class|continue|debugger|delete|do|each|else|extend|extends|false|finally|for|if|in|instanceof|is|isnt|let|loop|namespace|new|no|not|null|of|off|on|or|own|return|super|switch|then|this|throw|true|try|typeof|undefined|unless|until|when|while|window|with|yes|yield)\b/,
23091
- 'class-member': {
23092
- pattern: /@(?!\d)\w+/,
23093
- alias: 'variable'
23094
- }
23095
- });
23096
- Prism.languages.insertBefore('coffeescript', 'comment', {
23097
- 'multiline-comment': {
23098
- pattern: /###[\s\S]+?###/,
23099
- alias: 'comment'
23100
- },
23101
- // Block regexp can contain comments and interpolation
23102
- 'block-regex': {
23103
- pattern: /\/{3}[\s\S]*?\/{3}/,
23104
- alias: 'regex',
23105
- inside: {
23106
- comment: comment,
23107
- interpolation: interpolation
23108
- }
23109
- }
23110
- });
23111
- Prism.languages.insertBefore('coffeescript', 'string', {
23112
- 'inline-javascript': {
23113
- pattern: /`(?:\\[\s\S]|[^\\`])*`/,
23114
- inside: {
23115
- delimiter: {
23116
- pattern: /^`|`$/,
23117
- alias: 'punctuation'
23118
- },
23119
- script: {
23120
- pattern: /[\s\S]+/,
23121
- alias: 'language-javascript',
23122
- inside: Prism.languages.javascript
23123
- }
23124
- }
23125
- },
23126
- // Block strings
23127
- 'multiline-string': [
23128
- {
23129
- pattern: /'''[\s\S]*?'''/,
23130
- greedy: true,
23131
- alias: 'string'
23132
- },
23133
- {
23134
- pattern: /"""[\s\S]*?"""/,
23135
- greedy: true,
23136
- alias: 'string',
23137
- inside: {
23138
- interpolation: interpolation
23139
- }
23140
- }
23141
- ]
23142
- });
23143
- Prism.languages.insertBefore('coffeescript', 'keyword', {
23144
- // Object property
23145
- property: /(?!\d)\w+(?=\s*:(?!:))/
23146
- });
23147
- delete Prism.languages.coffeescript['template-string'];
23148
- Prism.languages.coffee = Prism.languages.coffeescript;
23149
- })(Prism);
23150
- }
23151
- return coffeescript_1;
23033
+ // Ignore comments starting with { to privilege string interpolation highlighting
23034
+ var comment = /#(?!\{).+/;
23035
+ var interpolation = {
23036
+ pattern: /#\{[^}]+\}/,
23037
+ alias: 'variable'
23038
+ };
23039
+ Prism.languages.coffeescript = Prism.languages.extend('javascript', {
23040
+ comment: comment,
23041
+ string: [
23042
+ // Strings are multiline
23043
+ {
23044
+ pattern: /'(?:\\[\s\S]|[^\\'])*'/,
23045
+ greedy: true
23046
+ },
23047
+ {
23048
+ // Strings are multiline
23049
+ pattern: /"(?:\\[\s\S]|[^\\"])*"/,
23050
+ greedy: true,
23051
+ inside: {
23052
+ interpolation: interpolation
23053
+ }
23054
+ }
23055
+ ],
23056
+ keyword:
23057
+ /\b(?:and|break|by|catch|class|continue|debugger|delete|do|each|else|extend|extends|false|finally|for|if|in|instanceof|is|isnt|let|loop|namespace|new|no|not|null|of|off|on|or|own|return|super|switch|then|this|throw|true|try|typeof|undefined|unless|until|when|while|window|with|yes|yield)\b/,
23058
+ 'class-member': {
23059
+ pattern: /@(?!\d)\w+/,
23060
+ alias: 'variable'
23061
+ }
23062
+ });
23063
+ Prism.languages.insertBefore('coffeescript', 'comment', {
23064
+ 'multiline-comment': {
23065
+ pattern: /###[\s\S]+?###/,
23066
+ alias: 'comment'
23067
+ },
23068
+ // Block regexp can contain comments and interpolation
23069
+ 'block-regex': {
23070
+ pattern: /\/{3}[\s\S]*?\/{3}/,
23071
+ alias: 'regex',
23072
+ inside: {
23073
+ comment: comment,
23074
+ interpolation: interpolation
23075
+ }
23076
+ }
23077
+ });
23078
+ Prism.languages.insertBefore('coffeescript', 'string', {
23079
+ 'inline-javascript': {
23080
+ pattern: /`(?:\\[\s\S]|[^\\`])*`/,
23081
+ inside: {
23082
+ delimiter: {
23083
+ pattern: /^`|`$/,
23084
+ alias: 'punctuation'
23085
+ },
23086
+ script: {
23087
+ pattern: /[\s\S]+/,
23088
+ alias: 'language-javascript',
23089
+ inside: Prism.languages.javascript
23090
+ }
23091
+ }
23092
+ },
23093
+ // Block strings
23094
+ 'multiline-string': [
23095
+ {
23096
+ pattern: /'''[\s\S]*?'''/,
23097
+ greedy: true,
23098
+ alias: 'string'
23099
+ },
23100
+ {
23101
+ pattern: /"""[\s\S]*?"""/,
23102
+ greedy: true,
23103
+ alias: 'string',
23104
+ inside: {
23105
+ interpolation: interpolation
23106
+ }
23107
+ }
23108
+ ]
23109
+ });
23110
+ Prism.languages.insertBefore('coffeescript', 'keyword', {
23111
+ // Object property
23112
+ property: /(?!\d)\w+(?=\s*:(?!:))/
23113
+ });
23114
+ delete Prism.languages.coffeescript['template-string'];
23115
+ Prism.languages.coffee = Prism.languages.coffeescript;
23116
+ })(Prism);
23152
23117
  }
23153
23118
 
23154
- var concurnas_1;
23155
- var hasRequiredConcurnas;
23156
-
23157
- function requireConcurnas () {
23158
- if (hasRequiredConcurnas) return concurnas_1;
23159
- hasRequiredConcurnas = 1;
23160
-
23161
- concurnas_1 = concurnas;
23162
- concurnas.displayName = 'concurnas';
23163
- concurnas.aliases = ['conc'];
23164
- function concurnas(Prism) {
23165
- Prism.languages.concurnas = {
23166
- comment: {
23167
- pattern: /(^|[^\\])(?:\/\*[\s\S]*?(?:\*\/|$)|\/\/.*)/,
23168
- lookbehind: true,
23169
- greedy: true
23170
- },
23171
- langext: {
23172
- pattern: /\b\w+\s*\|\|[\s\S]+?\|\|/,
23173
- greedy: true,
23174
- inside: {
23175
- 'class-name': /^\w+/,
23176
- string: {
23177
- pattern: /(^\s*\|\|)[\s\S]+(?=\|\|$)/,
23178
- lookbehind: true
23179
- },
23180
- punctuation: /\|\|/
23181
- }
23182
- },
23183
- function: {
23184
- pattern: /((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/,
23185
- lookbehind: true
23186
- },
23187
- keyword:
23188
- /\b(?:abstract|actor|also|annotation|assert|async|await|bool|boolean|break|byte|case|catch|changed|char|class|closed|constant|continue|def|default|del|double|elif|else|enum|every|extends|false|finally|float|for|from|global|gpudef|gpukernel|if|import|in|init|inject|int|lambda|local|long|loop|match|new|nodefault|null|of|onchange|open|out|override|package|parfor|parforsync|post|pre|private|protected|provide|provider|public|return|shared|short|single|size_t|sizeof|super|sync|this|throw|trait|trans|transient|true|try|typedef|unchecked|using|val|var|void|while|with)\b/,
23189
- boolean: /\b(?:false|true)\b/,
23190
- number:
23191
- /\b0b[01][01_]*L?\b|\b0x(?:[\da-f_]*\.)?[\da-f_p+-]+\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfls]?/i,
23192
- punctuation: /[{}[\];(),.:]/,
23193
- operator:
23194
- /<==|>==|=>|->|<-|<>|&==|&<>|\?:?|\.\?|\+\+|--|[-+*/=<>]=?|[!^~]|\b(?:and|as|band|bor|bxor|comp|is|isnot|mod|or)\b=?/,
23195
- annotation: {
23196
- pattern: /@(?:\w+:)?(?:\w+|\[[^\]]+\])?/,
23197
- alias: 'builtin'
23198
- }
23199
- };
23200
- Prism.languages.insertBefore('concurnas', 'langext', {
23201
- 'regex-literal': {
23202
- pattern: /\br("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,
23203
- greedy: true,
23204
- inside: {
23205
- interpolation: {
23206
- pattern:
23207
- /((?:^|[^\\])(?:\\{2})*)\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,
23208
- lookbehind: true,
23209
- inside: Prism.languages.concurnas
23210
- },
23211
- regex: /[\s\S]+/
23212
- }
23213
- },
23214
- 'string-literal': {
23215
- pattern: /(?:\B|\bs)("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,
23216
- greedy: true,
23217
- inside: {
23218
- interpolation: {
23219
- pattern:
23220
- /((?:^|[^\\])(?:\\{2})*)\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,
23221
- lookbehind: true,
23222
- inside: Prism.languages.concurnas
23223
- },
23224
- string: /[\s\S]+/
23225
- }
23226
- }
23227
- });
23228
- Prism.languages.conc = Prism.languages.concurnas;
23229
- }
23230
- return concurnas_1;
23119
+ var concurnas_1 = concurnas;
23120
+ concurnas.displayName = 'concurnas';
23121
+ concurnas.aliases = ['conc'];
23122
+ function concurnas(Prism) {
23123
+ Prism.languages.concurnas = {
23124
+ comment: {
23125
+ pattern: /(^|[^\\])(?:\/\*[\s\S]*?(?:\*\/|$)|\/\/.*)/,
23126
+ lookbehind: true,
23127
+ greedy: true
23128
+ },
23129
+ langext: {
23130
+ pattern: /\b\w+\s*\|\|[\s\S]+?\|\|/,
23131
+ greedy: true,
23132
+ inside: {
23133
+ 'class-name': /^\w+/,
23134
+ string: {
23135
+ pattern: /(^\s*\|\|)[\s\S]+(?=\|\|$)/,
23136
+ lookbehind: true
23137
+ },
23138
+ punctuation: /\|\|/
23139
+ }
23140
+ },
23141
+ function: {
23142
+ pattern: /((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/,
23143
+ lookbehind: true
23144
+ },
23145
+ keyword:
23146
+ /\b(?:abstract|actor|also|annotation|assert|async|await|bool|boolean|break|byte|case|catch|changed|char|class|closed|constant|continue|def|default|del|double|elif|else|enum|every|extends|false|finally|float|for|from|global|gpudef|gpukernel|if|import|in|init|inject|int|lambda|local|long|loop|match|new|nodefault|null|of|onchange|open|out|override|package|parfor|parforsync|post|pre|private|protected|provide|provider|public|return|shared|short|single|size_t|sizeof|super|sync|this|throw|trait|trans|transient|true|try|typedef|unchecked|using|val|var|void|while|with)\b/,
23147
+ boolean: /\b(?:false|true)\b/,
23148
+ number:
23149
+ /\b0b[01][01_]*L?\b|\b0x(?:[\da-f_]*\.)?[\da-f_p+-]+\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfls]?/i,
23150
+ punctuation: /[{}[\];(),.:]/,
23151
+ operator:
23152
+ /<==|>==|=>|->|<-|<>|&==|&<>|\?:?|\.\?|\+\+|--|[-+*/=<>]=?|[!^~]|\b(?:and|as|band|bor|bxor|comp|is|isnot|mod|or)\b=?/,
23153
+ annotation: {
23154
+ pattern: /@(?:\w+:)?(?:\w+|\[[^\]]+\])?/,
23155
+ alias: 'builtin'
23156
+ }
23157
+ };
23158
+ Prism.languages.insertBefore('concurnas', 'langext', {
23159
+ 'regex-literal': {
23160
+ pattern: /\br("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,
23161
+ greedy: true,
23162
+ inside: {
23163
+ interpolation: {
23164
+ pattern:
23165
+ /((?:^|[^\\])(?:\\{2})*)\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,
23166
+ lookbehind: true,
23167
+ inside: Prism.languages.concurnas
23168
+ },
23169
+ regex: /[\s\S]+/
23170
+ }
23171
+ },
23172
+ 'string-literal': {
23173
+ pattern: /(?:\B|\bs)("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,
23174
+ greedy: true,
23175
+ inside: {
23176
+ interpolation: {
23177
+ pattern:
23178
+ /((?:^|[^\\])(?:\\{2})*)\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,
23179
+ lookbehind: true,
23180
+ inside: Prism.languages.concurnas
23181
+ },
23182
+ string: /[\s\S]+/
23183
+ }
23184
+ }
23185
+ });
23186
+ Prism.languages.conc = Prism.languages.concurnas;
23231
23187
  }
23232
23188
 
23233
- var coq_1;
23234
- var hasRequiredCoq;
23235
-
23236
- function requireCoq () {
23237
- if (hasRequiredCoq) return coq_1;
23238
- hasRequiredCoq = 1;
23239
-
23240
- coq_1 = coq;
23241
- coq.displayName = 'coq';
23242
- coq.aliases = [];
23243
- function coq(Prism) {
23189
+ var coq_1 = coq;
23190
+ coq.displayName = 'coq';
23191
+ coq.aliases = [];
23192
+ function coq(Prism) {
23244
23193
  (function (Prism) {
23245
- // https://github.com/coq/coq
23246
- var commentSource = /\(\*(?:[^(*]|\((?!\*)|\*(?!\))|<self>)*\*\)/.source;
23247
- for (var i = 0; i < 2; i++) {
23248
- commentSource = commentSource.replace(/<self>/g, function () {
23249
- return commentSource
23250
- });
23251
- }
23252
- commentSource = commentSource.replace(/<self>/g, '[]');
23253
- Prism.languages.coq = {
23254
- comment: RegExp(commentSource),
23255
- string: {
23256
- pattern: /"(?:[^"]|"")*"(?!")/,
23257
- greedy: true
23258
- },
23259
- attribute: [
23260
- {
23261
- pattern: RegExp(
23262
- /#\[(?:[^\[\]("]|"(?:[^"]|"")*"(?!")|\((?!\*)|<comment>)*\]/.source.replace(
23263
- /<comment>/g,
23264
- function () {
23265
- return commentSource
23266
- }
23267
- )
23268
- ),
23269
- greedy: true,
23270
- alias: 'attr-name',
23271
- inside: {
23272
- comment: RegExp(commentSource),
23273
- string: {
23274
- pattern: /"(?:[^"]|"")*"(?!")/,
23275
- greedy: true
23276
- },
23277
- operator: /=/,
23278
- punctuation: /^#\[|\]$|[,()]/
23279
- }
23280
- },
23281
- {
23282
- pattern:
23283
- /\b(?:Cumulative|Global|Local|Monomorphic|NonCumulative|Polymorphic|Private|Program)\b/,
23284
- alias: 'attr-name'
23285
- }
23286
- ],
23287
- keyword:
23288
- /\b(?:Abort|About|Add|Admit|Admitted|All|Arguments|As|Assumptions|Axiom|Axioms|Back|BackTo|Backtrace|BinOp|BinOpSpec|BinRel|Bind|Blacklist|Canonical|Case|Cd|Check|Class|Classes|Close|CoFixpoint|CoInductive|Coercion|Coercions|Collection|Combined|Compute|Conjecture|Conjectures|Constant|Constants|Constraint|Constructors|Context|Corollary|Create|CstOp|Custom|Cut|Debug|Declare|Defined|Definition|Delimit|Dependencies|Dependent|Derive|Diffs|Drop|Elimination|End|Entry|Equality|Eval|Example|Existential|Existentials|Existing|Export|Extern|Extraction|Fact|Fail|Field|File|Firstorder|Fixpoint|Flags|Focus|From|Funclass|Function|Functional|GC|Generalizable|Goal|Grab|Grammar|Graph|Guarded|Haskell|Heap|Hide|Hint|HintDb|Hints|Hypotheses|Hypothesis|IF|Identity|Immediate|Implicit|Implicits|Import|Include|Induction|Inductive|Infix|Info|Initial|InjTyp|Inline|Inspect|Instance|Instances|Intro|Intros|Inversion|Inversion_clear|JSON|Language|Left|Lemma|Let|Lia|Libraries|Library|Load|LoadPath|Locate|Ltac|Ltac2|ML|Match|Method|Minimality|Module|Modules|Morphism|Next|NoInline|Notation|Number|OCaml|Obligation|Obligations|Opaque|Open|Optimize|Parameter|Parameters|Parametric|Path|Paths|Prenex|Preterm|Primitive|Print|Profile|Projections|Proof|Prop|PropBinOp|PropOp|PropUOp|Property|Proposition|Pwd|Qed|Quit|Rec|Record|Recursive|Redirect|Reduction|Register|Relation|Remark|Remove|Require|Reserved|Reset|Resolve|Restart|Rewrite|Right|Ring|Rings|SProp|Saturate|Save|Scheme|Scope|Scopes|Search|SearchHead|SearchPattern|SearchRewrite|Section|Separate|Set|Setoid|Show|Signatures|Solve|Solver|Sort|Sortclass|Sorted|Spec|Step|Strategies|Strategy|String|Structure|SubClass|Subgraph|SuchThat|Tactic|Term|TestCompile|Theorem|Time|Timeout|To|Transparent|Type|Typeclasses|Types|Typing|UnOp|UnOpSpec|Undelimit|Undo|Unfocus|Unfocused|Unfold|Universe|Universes|Unshelve|Variable|Variables|Variant|Verbose|View|Visibility|Zify|_|apply|as|at|by|cofix|else|end|exists|exists2|fix|for|forall|fun|if|in|let|match|measure|move|removed|return|struct|then|using|wf|where|with)\b/,
23289
- number:
23290
- /\b(?:0x[a-f0-9][a-f0-9_]*(?:\.[a-f0-9_]+)?(?:p[+-]?\d[\d_]*)?|\d[\d_]*(?:\.[\d_]+)?(?:e[+-]?\d[\d_]*)?)\b/i,
23291
- punct: {
23292
- pattern: /@\{|\{\||\[=|:>/,
23293
- alias: 'punctuation'
23294
- },
23295
- operator:
23296
- /\/\\|\\\/|\.{2,3}|:{1,2}=|\*\*|[-=]>|<(?:->?|[+:=>]|<:)|>(?:=|->)|\|[-|]?|[-!%&*+/<=>?@^~']/,
23297
- punctuation: /\.\(|`\(|@\{|`\{|\{\||\[=|:>|[:.,;(){}\[\]]/
23298
- };
23299
- })(Prism);
23300
- }
23301
- return coq_1;
23194
+ // https://github.com/coq/coq
23195
+ var commentSource = /\(\*(?:[^(*]|\((?!\*)|\*(?!\))|<self>)*\*\)/.source;
23196
+ for (var i = 0; i < 2; i++) {
23197
+ commentSource = commentSource.replace(/<self>/g, function () {
23198
+ return commentSource
23199
+ });
23200
+ }
23201
+ commentSource = commentSource.replace(/<self>/g, '[]');
23202
+ Prism.languages.coq = {
23203
+ comment: RegExp(commentSource),
23204
+ string: {
23205
+ pattern: /"(?:[^"]|"")*"(?!")/,
23206
+ greedy: true
23207
+ },
23208
+ attribute: [
23209
+ {
23210
+ pattern: RegExp(
23211
+ /#\[(?:[^\[\]("]|"(?:[^"]|"")*"(?!")|\((?!\*)|<comment>)*\]/.source.replace(
23212
+ /<comment>/g,
23213
+ function () {
23214
+ return commentSource
23215
+ }
23216
+ )
23217
+ ),
23218
+ greedy: true,
23219
+ alias: 'attr-name',
23220
+ inside: {
23221
+ comment: RegExp(commentSource),
23222
+ string: {
23223
+ pattern: /"(?:[^"]|"")*"(?!")/,
23224
+ greedy: true
23225
+ },
23226
+ operator: /=/,
23227
+ punctuation: /^#\[|\]$|[,()]/
23228
+ }
23229
+ },
23230
+ {
23231
+ pattern:
23232
+ /\b(?:Cumulative|Global|Local|Monomorphic|NonCumulative|Polymorphic|Private|Program)\b/,
23233
+ alias: 'attr-name'
23234
+ }
23235
+ ],
23236
+ keyword:
23237
+ /\b(?:Abort|About|Add|Admit|Admitted|All|Arguments|As|Assumptions|Axiom|Axioms|Back|BackTo|Backtrace|BinOp|BinOpSpec|BinRel|Bind|Blacklist|Canonical|Case|Cd|Check|Class|Classes|Close|CoFixpoint|CoInductive|Coercion|Coercions|Collection|Combined|Compute|Conjecture|Conjectures|Constant|Constants|Constraint|Constructors|Context|Corollary|Create|CstOp|Custom|Cut|Debug|Declare|Defined|Definition|Delimit|Dependencies|Dependent|Derive|Diffs|Drop|Elimination|End|Entry|Equality|Eval|Example|Existential|Existentials|Existing|Export|Extern|Extraction|Fact|Fail|Field|File|Firstorder|Fixpoint|Flags|Focus|From|Funclass|Function|Functional|GC|Generalizable|Goal|Grab|Grammar|Graph|Guarded|Haskell|Heap|Hide|Hint|HintDb|Hints|Hypotheses|Hypothesis|IF|Identity|Immediate|Implicit|Implicits|Import|Include|Induction|Inductive|Infix|Info|Initial|InjTyp|Inline|Inspect|Instance|Instances|Intro|Intros|Inversion|Inversion_clear|JSON|Language|Left|Lemma|Let|Lia|Libraries|Library|Load|LoadPath|Locate|Ltac|Ltac2|ML|Match|Method|Minimality|Module|Modules|Morphism|Next|NoInline|Notation|Number|OCaml|Obligation|Obligations|Opaque|Open|Optimize|Parameter|Parameters|Parametric|Path|Paths|Prenex|Preterm|Primitive|Print|Profile|Projections|Proof|Prop|PropBinOp|PropOp|PropUOp|Property|Proposition|Pwd|Qed|Quit|Rec|Record|Recursive|Redirect|Reduction|Register|Relation|Remark|Remove|Require|Reserved|Reset|Resolve|Restart|Rewrite|Right|Ring|Rings|SProp|Saturate|Save|Scheme|Scope|Scopes|Search|SearchHead|SearchPattern|SearchRewrite|Section|Separate|Set|Setoid|Show|Signatures|Solve|Solver|Sort|Sortclass|Sorted|Spec|Step|Strategies|Strategy|String|Structure|SubClass|Subgraph|SuchThat|Tactic|Term|TestCompile|Theorem|Time|Timeout|To|Transparent|Type|Typeclasses|Types|Typing|UnOp|UnOpSpec|Undelimit|Undo|Unfocus|Unfocused|Unfold|Universe|Universes|Unshelve|Variable|Variables|Variant|Verbose|View|Visibility|Zify|_|apply|as|at|by|cofix|else|end|exists|exists2|fix|for|forall|fun|if|in|let|match|measure|move|removed|return|struct|then|using|wf|where|with)\b/,
23238
+ number:
23239
+ /\b(?:0x[a-f0-9][a-f0-9_]*(?:\.[a-f0-9_]+)?(?:p[+-]?\d[\d_]*)?|\d[\d_]*(?:\.[\d_]+)?(?:e[+-]?\d[\d_]*)?)\b/i,
23240
+ punct: {
23241
+ pattern: /@\{|\{\||\[=|:>/,
23242
+ alias: 'punctuation'
23243
+ },
23244
+ operator:
23245
+ /\/\\|\\\/|\.{2,3}|:{1,2}=|\*\*|[-=]>|<(?:->?|[+:=>]|<:)|>(?:=|->)|\|[-|]?|[-!%&*+/<=>?@^~']/,
23246
+ punctuation: /\.\(|`\(|@\{|`\{|\{\||\[=|:>|[:.,;(){}\[\]]/
23247
+ };
23248
+ })(Prism);
23302
23249
  }
23303
23250
 
23304
- var ruby_1;
23305
- var hasRequiredRuby;
23306
-
23307
- function requireRuby () {
23308
- if (hasRequiredRuby) return ruby_1;
23309
- hasRequiredRuby = 1;
23310
-
23311
- ruby_1 = ruby;
23312
- ruby.displayName = 'ruby';
23313
- ruby.aliases = ['rb'];
23314
- function ruby(Prism) {
23251
+ var ruby_1 = ruby;
23252
+ ruby.displayName = 'ruby';
23253
+ ruby.aliases = ['rb'];
23254
+ function ruby(Prism) {
23315
23255
  (function (Prism) {
23316
- Prism.languages.ruby = Prism.languages.extend('clike', {
23317
- comment: {
23318
- pattern: /#.*|^=begin\s[\s\S]*?^=end/m,
23319
- greedy: true
23320
- },
23321
- 'class-name': {
23322
- pattern:
23323
- /(\b(?:class|module)\s+|\bcatch\s+\()[\w.\\]+|\b[A-Z_]\w*(?=\s*\.\s*new\b)/,
23324
- lookbehind: true,
23325
- inside: {
23326
- punctuation: /[.\\]/
23327
- }
23328
- },
23329
- keyword:
23330
- /\b(?:BEGIN|END|alias|and|begin|break|case|class|def|define_method|defined|do|each|else|elsif|end|ensure|extend|for|if|in|include|module|new|next|nil|not|or|prepend|private|protected|public|raise|redo|require|rescue|retry|return|self|super|then|throw|undef|unless|until|when|while|yield)\b/,
23331
- operator:
23332
- /\.{2,3}|&\.|===|<?=>|[!=]?~|(?:&&|\|\||<<|>>|\*\*|[+\-*/%<>!^&|=])=?|[?:]/,
23333
- punctuation: /[(){}[\].,;]/
23334
- });
23335
- Prism.languages.insertBefore('ruby', 'operator', {
23336
- 'double-colon': {
23337
- pattern: /::/,
23338
- alias: 'punctuation'
23339
- }
23340
- });
23341
- var interpolation = {
23342
- pattern: /((?:^|[^\\])(?:\\{2})*)#\{(?:[^{}]|\{[^{}]*\})*\}/,
23343
- lookbehind: true,
23344
- inside: {
23345
- content: {
23346
- pattern: /^(#\{)[\s\S]+(?=\}$)/,
23347
- lookbehind: true,
23348
- inside: Prism.languages.ruby
23349
- },
23350
- delimiter: {
23351
- pattern: /^#\{|\}$/,
23352
- alias: 'punctuation'
23353
- }
23354
- }
23355
- };
23356
- delete Prism.languages.ruby.function;
23357
- var percentExpression =
23358
- '(?:' +
23359
- [
23360
- /([^a-zA-Z0-9\s{(\[<=])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,
23361
- /\((?:[^()\\]|\\[\s\S]|\((?:[^()\\]|\\[\s\S])*\))*\)/.source,
23362
- /\{(?:[^{}\\]|\\[\s\S]|\{(?:[^{}\\]|\\[\s\S])*\})*\}/.source,
23363
- /\[(?:[^\[\]\\]|\\[\s\S]|\[(?:[^\[\]\\]|\\[\s\S])*\])*\]/.source,
23364
- /<(?:[^<>\\]|\\[\s\S]|<(?:[^<>\\]|\\[\s\S])*>)*>/.source
23365
- ].join('|') +
23366
- ')';
23367
- var symbolName =
23368
- /(?:"(?:\\.|[^"\\\r\n])*"|(?:\b[a-zA-Z_]\w*|[^\s\0-\x7F]+)[?!]?|\$.)/
23369
- .source;
23370
- Prism.languages.insertBefore('ruby', 'keyword', {
23371
- 'regex-literal': [
23372
- {
23373
- pattern: RegExp(
23374
- /%r/.source + percentExpression + /[egimnosux]{0,6}/.source
23375
- ),
23376
- greedy: true,
23377
- inside: {
23378
- interpolation: interpolation,
23379
- regex: /[\s\S]+/
23380
- }
23381
- },
23382
- {
23383
- pattern:
23384
- /(^|[^/])\/(?!\/)(?:\[[^\r\n\]]+\]|\\.|[^[/\\\r\n])+\/[egimnosux]{0,6}(?=\s*(?:$|[\r\n,.;})#]))/,
23385
- lookbehind: true,
23386
- greedy: true,
23387
- inside: {
23388
- interpolation: interpolation,
23389
- regex: /[\s\S]+/
23390
- }
23391
- }
23392
- ],
23393
- variable: /[@$]+[a-zA-Z_]\w*(?:[?!]|\b)/,
23394
- symbol: [
23395
- {
23396
- pattern: RegExp(/(^|[^:]):/.source + symbolName),
23397
- lookbehind: true,
23398
- greedy: true
23399
- },
23400
- {
23401
- pattern: RegExp(
23402
- /([\r\n{(,][ \t]*)/.source + symbolName + /(?=:(?!:))/.source
23403
- ),
23404
- lookbehind: true,
23405
- greedy: true
23406
- }
23407
- ],
23408
- 'method-definition': {
23409
- pattern: /(\bdef\s+)\w+(?:\s*\.\s*\w+)?/,
23410
- lookbehind: true,
23411
- inside: {
23412
- function: /\b\w+$/,
23413
- keyword: /^self\b/,
23414
- 'class-name': /^\w+/,
23415
- punctuation: /\./
23416
- }
23417
- }
23418
- });
23419
- Prism.languages.insertBefore('ruby', 'string', {
23420
- 'string-literal': [
23421
- {
23422
- pattern: RegExp(/%[qQiIwWs]?/.source + percentExpression),
23423
- greedy: true,
23424
- inside: {
23425
- interpolation: interpolation,
23426
- string: /[\s\S]+/
23427
- }
23428
- },
23429
- {
23430
- pattern:
23431
- /("|')(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|(?!\1)[^\\#\r\n])*\1/,
23432
- greedy: true,
23433
- inside: {
23434
- interpolation: interpolation,
23435
- string: /[\s\S]+/
23436
- }
23437
- },
23438
- {
23439
- pattern: /<<[-~]?([a-z_]\w*)[\r\n](?:.*[\r\n])*?[\t ]*\1/i,
23440
- alias: 'heredoc-string',
23441
- greedy: true,
23442
- inside: {
23443
- delimiter: {
23444
- pattern: /^<<[-~]?[a-z_]\w*|\b[a-z_]\w*$/i,
23445
- inside: {
23446
- symbol: /\b\w+/,
23447
- punctuation: /^<<[-~]?/
23448
- }
23449
- },
23450
- interpolation: interpolation,
23451
- string: /[\s\S]+/
23452
- }
23453
- },
23454
- {
23455
- pattern: /<<[-~]?'([a-z_]\w*)'[\r\n](?:.*[\r\n])*?[\t ]*\1/i,
23456
- alias: 'heredoc-string',
23457
- greedy: true,
23458
- inside: {
23459
- delimiter: {
23460
- pattern: /^<<[-~]?'[a-z_]\w*'|\b[a-z_]\w*$/i,
23461
- inside: {
23462
- symbol: /\b\w+/,
23463
- punctuation: /^<<[-~]?'|'$/
23464
- }
23465
- },
23466
- string: /[\s\S]+/
23467
- }
23468
- }
23469
- ],
23470
- 'command-literal': [
23471
- {
23472
- pattern: RegExp(/%x/.source + percentExpression),
23473
- greedy: true,
23474
- inside: {
23475
- interpolation: interpolation,
23476
- command: {
23477
- pattern: /[\s\S]+/,
23478
- alias: 'string'
23479
- }
23480
- }
23481
- },
23482
- {
23483
- pattern: /`(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|[^\\`#\r\n])*`/,
23484
- greedy: true,
23485
- inside: {
23486
- interpolation: interpolation,
23487
- command: {
23488
- pattern: /[\s\S]+/,
23489
- alias: 'string'
23490
- }
23491
- }
23492
- }
23493
- ]
23494
- });
23495
- delete Prism.languages.ruby.string;
23496
- Prism.languages.insertBefore('ruby', 'number', {
23497
- builtin:
23498
- /\b(?:Array|Bignum|Binding|Class|Continuation|Dir|Exception|FalseClass|File|Fixnum|Float|Hash|IO|Integer|MatchData|Method|Module|NilClass|Numeric|Object|Proc|Range|Regexp|Stat|String|Struct|Symbol|TMS|Thread|ThreadGroup|Time|TrueClass)\b/,
23499
- constant: /\b[A-Z][A-Z0-9_]*(?:[?!]|\b)/
23500
- });
23501
- Prism.languages.rb = Prism.languages.ruby;
23502
- })(Prism);
23503
- }
23504
- return ruby_1;
23505
- }
23506
-
23507
- var crystal_1;
23508
- var hasRequiredCrystal;
23509
-
23510
- function requireCrystal () {
23511
- if (hasRequiredCrystal) return crystal_1;
23512
- hasRequiredCrystal = 1;
23513
- var refractorRuby = requireRuby();
23514
- crystal_1 = crystal;
23515
- crystal.displayName = 'crystal';
23516
- crystal.aliases = [];
23517
- function crystal(Prism) {
23518
- Prism.register(refractorRuby)
23519
- ;(function (Prism) {
23520
- Prism.languages.crystal = Prism.languages.extend('ruby', {
23521
- keyword: [
23522
- /\b(?:__DIR__|__END_LINE__|__FILE__|__LINE__|abstract|alias|annotation|as|asm|begin|break|case|class|def|do|else|elsif|end|ensure|enum|extend|for|fun|if|ifdef|include|instance_sizeof|lib|macro|module|next|of|out|pointerof|private|protected|ptr|require|rescue|return|select|self|sizeof|struct|super|then|type|typeof|undef|uninitialized|union|unless|until|when|while|with|yield)\b/,
23523
- {
23524
- pattern: /(\.\s*)(?:is_a|responds_to)\?/,
23525
- lookbehind: true
23526
- }
23527
- ],
23528
- number:
23529
- /\b(?:0b[01_]*[01]|0o[0-7_]*[0-7]|0x[\da-fA-F_]*[\da-fA-F]|(?:\d(?:[\d_]*\d)?)(?:\.[\d_]*\d)?(?:[eE][+-]?[\d_]*\d)?)(?:_(?:[uif](?:8|16|32|64))?)?\b/,
23530
- operator: [/->/, Prism.languages.ruby.operator],
23531
- punctuation: /[(){}[\].,;\\]/
23532
- });
23533
- Prism.languages.insertBefore('crystal', 'string-literal', {
23534
- attribute: {
23535
- pattern: /@\[.*?\]/,
23536
- inside: {
23537
- delimiter: {
23538
- pattern: /^@\[|\]$/,
23539
- alias: 'punctuation'
23540
- },
23541
- attribute: {
23542
- pattern: /^(\s*)\w+/,
23543
- lookbehind: true,
23544
- alias: 'class-name'
23545
- },
23546
- args: {
23547
- pattern: /\S(?:[\s\S]*\S)?/,
23548
- inside: Prism.languages.crystal
23549
- }
23550
- }
23551
- },
23552
- expansion: {
23553
- pattern: /\{(?:\{.*?\}|%.*?%)\}/,
23554
- inside: {
23555
- content: {
23556
- pattern: /^(\{.)[\s\S]+(?=.\}$)/,
23557
- lookbehind: true,
23558
- inside: Prism.languages.crystal
23559
- },
23560
- delimiter: {
23561
- pattern: /^\{[\{%]|[\}%]\}$/,
23562
- alias: 'operator'
23563
- }
23564
- }
23565
- },
23566
- char: {
23567
- pattern:
23568
- /'(?:[^\\\r\n]{1,2}|\\(?:.|u(?:[A-Fa-f0-9]{1,4}|\{[A-Fa-f0-9]{1,6}\})))'/,
23569
- greedy: true
23570
- }
23571
- });
23572
- })(Prism);
23573
- }
23574
- return crystal_1;
23575
- }
23576
-
23577
- var cshtml_1;
23578
- var hasRequiredCshtml;
23579
-
23580
- function requireCshtml () {
23581
- if (hasRequiredCshtml) return cshtml_1;
23582
- hasRequiredCshtml = 1;
23583
- var refractorCsharp = requireCsharp();
23584
- cshtml_1 = cshtml;
23585
- cshtml.displayName = 'cshtml';
23586
- cshtml.aliases = ['razor'];
23587
- function cshtml(Prism) {
23588
- Prism.register(refractorCsharp)
23589
- // Docs:
23590
- // https://docs.microsoft.com/en-us/aspnet/core/razor-pages/?view=aspnetcore-5.0&tabs=visual-studio
23591
- // https://docs.microsoft.com/en-us/aspnet/core/mvc/views/razor?view=aspnetcore-5.0
23592
- ;(function (Prism) {
23593
- var commentLike = /\/(?![/*])|\/\/.*[\r\n]|\/\*[^*]*(?:\*(?!\/)[^*]*)*\*\//
23594
- .source;
23595
- var stringLike =
23596
- /@(?!")|"(?:[^\r\n\\"]|\\.)*"|@"(?:[^\\"]|""|\\[\s\S])*"(?!")/.source +
23597
- '|' +
23598
- /'(?:(?:[^\r\n'\\]|\\.|\\[Uux][\da-fA-F]{1,8})'|(?=[^\\](?!')))/.source;
23599
- /**
23600
- * Creates a nested pattern where all occurrences of the string `<<self>>` are replaced with the pattern itself.
23601
- *
23602
- * @param {string} pattern
23603
- * @param {number} depthLog2
23604
- * @returns {string}
23605
- */
23606
- function nested(pattern, depthLog2) {
23607
- for (var i = 0; i < depthLog2; i++) {
23608
- pattern = pattern.replace(/<self>/g, function () {
23609
- return '(?:' + pattern + ')'
23610
- });
23611
- }
23612
- return pattern
23613
- .replace(/<self>/g, '[^\\s\\S]')
23614
- .replace(/<str>/g, '(?:' + stringLike + ')')
23615
- .replace(/<comment>/g, '(?:' + commentLike + ')')
23616
- }
23617
- var round = nested(/\((?:[^()'"@/]|<str>|<comment>|<self>)*\)/.source, 2);
23618
- var square = nested(/\[(?:[^\[\]'"@/]|<str>|<comment>|<self>)*\]/.source, 2);
23619
- var curly = nested(/\{(?:[^{}'"@/]|<str>|<comment>|<self>)*\}/.source, 2);
23620
- var angle = nested(/<(?:[^<>'"@/]|<str>|<comment>|<self>)*>/.source, 2); // Note about the above bracket patterns:
23621
- // They all ignore HTML expressions that might be in the C# code. This is a problem because HTML (like strings and
23622
- // comments) is parsed differently. This is a huge problem because HTML might contain brackets and quotes which
23623
- // messes up the bracket and string counting implemented by the above patterns.
23624
- //
23625
- // This problem is not fixable because 1) HTML expression are highly context sensitive and very difficult to detect
23626
- // and 2) they require one capturing group at every nested level. See the `tagRegion` pattern to admire the
23627
- // complexity of an HTML expression.
23628
- //
23629
- // To somewhat alleviate the problem a bit, the patterns for characters (e.g. 'a') is very permissive, it also
23630
- // allows invalid characters to support HTML expressions like this: <p>That's it!</p>.
23631
- var tagAttrs =
23632
- /(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?/
23633
- .source;
23634
- var tagContent = /(?!\d)[^\s>\/=$<%]+/.source + tagAttrs + /\s*\/?>/.source;
23635
- var tagRegion =
23636
- /\B@?/.source +
23637
- '(?:' +
23638
- /<([a-zA-Z][\w:]*)/.source +
23639
- tagAttrs +
23640
- /\s*>/.source +
23641
- '(?:' +
23642
- (/[^<]/.source +
23643
- '|' + // all tags that are not the start tag
23644
- // eslint-disable-next-line regexp/strict
23645
- /<\/?(?!\1\b)/.source +
23646
- tagContent +
23647
- '|' + // nested start tag
23648
- nested(
23649
- // eslint-disable-next-line regexp/strict
23650
- /<\1/.source +
23651
- tagAttrs +
23652
- /\s*>/.source +
23653
- '(?:' +
23654
- (/[^<]/.source +
23655
- '|' + // all tags that are not the start tag
23656
- // eslint-disable-next-line regexp/strict
23657
- /<\/?(?!\1\b)/.source +
23658
- tagContent +
23659
- '|' +
23660
- '<self>') +
23661
- ')*' + // eslint-disable-next-line regexp/strict
23662
- /<\/\1\s*>/.source,
23663
- 2
23664
- )) +
23665
- ')*' + // eslint-disable-next-line regexp/strict
23666
- /<\/\1\s*>/.source +
23667
- '|' +
23668
- /</.source +
23669
- tagContent +
23670
- ')'; // Now for the actual language definition(s):
23671
- //
23672
- // Razor as a language has 2 parts:
23673
- // 1) CSHTML: A markup-like language that has been extended with inline C# code expressions and blocks.
23674
- // 2) C#+HTML: A variant of C# that can contain CSHTML tags as expressions.
23675
- //
23676
- // In the below code, both CSHTML and C#+HTML will be create as separate language definitions that reference each
23677
- // other. However, only CSHTML will be exported via `Prism.languages`.
23678
- Prism.languages.cshtml = Prism.languages.extend('markup', {});
23679
- var csharpWithHtml = Prism.languages.insertBefore(
23680
- 'csharp',
23681
- 'string',
23682
- {
23683
- html: {
23684
- pattern: RegExp(tagRegion),
23685
- greedy: true,
23686
- inside: Prism.languages.cshtml
23687
- }
23688
- },
23689
- {
23690
- csharp: Prism.languages.extend('csharp', {})
23691
- }
23692
- );
23693
- var cs = {
23694
- pattern: /\S[\s\S]*/,
23695
- alias: 'language-csharp',
23696
- inside: csharpWithHtml
23697
- };
23698
- Prism.languages.insertBefore('cshtml', 'prolog', {
23699
- 'razor-comment': {
23700
- pattern: /@\*[\s\S]*?\*@/,
23701
- greedy: true,
23702
- alias: 'comment'
23703
- },
23704
- block: {
23705
- pattern: RegExp(
23706
- /(^|[^@])@/.source +
23707
- '(?:' +
23708
- [
23709
- // @{ ... }
23710
- curly, // @code{ ... }
23711
- /(?:code|functions)\s*/.source + curly, // @for (...) { ... }
23712
- /(?:for|foreach|lock|switch|using|while)\s*/.source +
23713
- round +
23714
- /\s*/.source +
23715
- curly, // @do { ... } while (...);
23716
- /do\s*/.source +
23717
- curly +
23718
- /\s*while\s*/.source +
23719
- round +
23720
- /(?:\s*;)?/.source, // @try { ... } catch (...) { ... } finally { ... }
23721
- /try\s*/.source +
23722
- curly +
23723
- /\s*catch\s*/.source +
23724
- round +
23725
- /\s*/.source +
23726
- curly +
23727
- /\s*finally\s*/.source +
23728
- curly, // @if (...) {...} else if (...) {...} else {...}
23729
- /if\s*/.source +
23730
- round +
23731
- /\s*/.source +
23732
- curly +
23733
- '(?:' +
23734
- /\s*else/.source +
23735
- '(?:' +
23736
- /\s+if\s*/.source +
23737
- round +
23738
- ')?' +
23739
- /\s*/.source +
23740
- curly +
23741
- ')*'
23742
- ].join('|') +
23743
- ')'
23744
- ),
23745
- lookbehind: true,
23746
- greedy: true,
23747
- inside: {
23748
- keyword: /^@\w*/,
23749
- csharp: cs
23750
- }
23751
- },
23752
- directive: {
23753
- pattern:
23754
- /^([ \t]*)@(?:addTagHelper|attribute|implements|inherits|inject|layout|model|namespace|page|preservewhitespace|removeTagHelper|section|tagHelperPrefix|using)(?=\s).*/m,
23755
- lookbehind: true,
23756
- greedy: true,
23757
- inside: {
23758
- keyword: /^@\w+/,
23759
- csharp: cs
23760
- }
23761
- },
23762
- value: {
23763
- pattern: RegExp(
23764
- /(^|[^@])@/.source +
23765
- /(?:await\b\s*)?/.source +
23766
- '(?:' +
23767
- /\w+\b/.source +
23768
- '|' +
23769
- round +
23770
- ')' +
23771
- '(?:' +
23772
- /[?!]?\.\w+\b/.source +
23773
- '|' +
23774
- round +
23775
- '|' +
23776
- square +
23777
- '|' +
23778
- angle +
23779
- round +
23780
- ')*'
23781
- ),
23782
- lookbehind: true,
23783
- greedy: true,
23784
- alias: 'variable',
23785
- inside: {
23786
- keyword: /^@/,
23787
- csharp: cs
23788
- }
23789
- },
23790
- 'delegate-operator': {
23791
- pattern: /(^|[^@])@(?=<)/,
23792
- lookbehind: true,
23793
- alias: 'operator'
23794
- }
23795
- });
23796
- Prism.languages.razor = Prism.languages.cshtml;
23797
- })(Prism);
23798
- }
23799
- return cshtml_1;
23256
+ Prism.languages.ruby = Prism.languages.extend('clike', {
23257
+ comment: {
23258
+ pattern: /#.*|^=begin\s[\s\S]*?^=end/m,
23259
+ greedy: true
23260
+ },
23261
+ 'class-name': {
23262
+ pattern:
23263
+ /(\b(?:class|module)\s+|\bcatch\s+\()[\w.\\]+|\b[A-Z_]\w*(?=\s*\.\s*new\b)/,
23264
+ lookbehind: true,
23265
+ inside: {
23266
+ punctuation: /[.\\]/
23267
+ }
23268
+ },
23269
+ keyword:
23270
+ /\b(?:BEGIN|END|alias|and|begin|break|case|class|def|define_method|defined|do|each|else|elsif|end|ensure|extend|for|if|in|include|module|new|next|nil|not|or|prepend|private|protected|public|raise|redo|require|rescue|retry|return|self|super|then|throw|undef|unless|until|when|while|yield)\b/,
23271
+ operator:
23272
+ /\.{2,3}|&\.|===|<?=>|[!=]?~|(?:&&|\|\||<<|>>|\*\*|[+\-*/%<>!^&|=])=?|[?:]/,
23273
+ punctuation: /[(){}[\].,;]/
23274
+ });
23275
+ Prism.languages.insertBefore('ruby', 'operator', {
23276
+ 'double-colon': {
23277
+ pattern: /::/,
23278
+ alias: 'punctuation'
23279
+ }
23280
+ });
23281
+ var interpolation = {
23282
+ pattern: /((?:^|[^\\])(?:\\{2})*)#\{(?:[^{}]|\{[^{}]*\})*\}/,
23283
+ lookbehind: true,
23284
+ inside: {
23285
+ content: {
23286
+ pattern: /^(#\{)[\s\S]+(?=\}$)/,
23287
+ lookbehind: true,
23288
+ inside: Prism.languages.ruby
23289
+ },
23290
+ delimiter: {
23291
+ pattern: /^#\{|\}$/,
23292
+ alias: 'punctuation'
23293
+ }
23294
+ }
23295
+ };
23296
+ delete Prism.languages.ruby.function;
23297
+ var percentExpression =
23298
+ '(?:' +
23299
+ [
23300
+ /([^a-zA-Z0-9\s{(\[<=])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,
23301
+ /\((?:[^()\\]|\\[\s\S]|\((?:[^()\\]|\\[\s\S])*\))*\)/.source,
23302
+ /\{(?:[^{}\\]|\\[\s\S]|\{(?:[^{}\\]|\\[\s\S])*\})*\}/.source,
23303
+ /\[(?:[^\[\]\\]|\\[\s\S]|\[(?:[^\[\]\\]|\\[\s\S])*\])*\]/.source,
23304
+ /<(?:[^<>\\]|\\[\s\S]|<(?:[^<>\\]|\\[\s\S])*>)*>/.source
23305
+ ].join('|') +
23306
+ ')';
23307
+ var symbolName =
23308
+ /(?:"(?:\\.|[^"\\\r\n])*"|(?:\b[a-zA-Z_]\w*|[^\s\0-\x7F]+)[?!]?|\$.)/
23309
+ .source;
23310
+ Prism.languages.insertBefore('ruby', 'keyword', {
23311
+ 'regex-literal': [
23312
+ {
23313
+ pattern: RegExp(
23314
+ /%r/.source + percentExpression + /[egimnosux]{0,6}/.source
23315
+ ),
23316
+ greedy: true,
23317
+ inside: {
23318
+ interpolation: interpolation,
23319
+ regex: /[\s\S]+/
23320
+ }
23321
+ },
23322
+ {
23323
+ pattern:
23324
+ /(^|[^/])\/(?!\/)(?:\[[^\r\n\]]+\]|\\.|[^[/\\\r\n])+\/[egimnosux]{0,6}(?=\s*(?:$|[\r\n,.;})#]))/,
23325
+ lookbehind: true,
23326
+ greedy: true,
23327
+ inside: {
23328
+ interpolation: interpolation,
23329
+ regex: /[\s\S]+/
23330
+ }
23331
+ }
23332
+ ],
23333
+ variable: /[@$]+[a-zA-Z_]\w*(?:[?!]|\b)/,
23334
+ symbol: [
23335
+ {
23336
+ pattern: RegExp(/(^|[^:]):/.source + symbolName),
23337
+ lookbehind: true,
23338
+ greedy: true
23339
+ },
23340
+ {
23341
+ pattern: RegExp(
23342
+ /([\r\n{(,][ \t]*)/.source + symbolName + /(?=:(?!:))/.source
23343
+ ),
23344
+ lookbehind: true,
23345
+ greedy: true
23346
+ }
23347
+ ],
23348
+ 'method-definition': {
23349
+ pattern: /(\bdef\s+)\w+(?:\s*\.\s*\w+)?/,
23350
+ lookbehind: true,
23351
+ inside: {
23352
+ function: /\b\w+$/,
23353
+ keyword: /^self\b/,
23354
+ 'class-name': /^\w+/,
23355
+ punctuation: /\./
23356
+ }
23357
+ }
23358
+ });
23359
+ Prism.languages.insertBefore('ruby', 'string', {
23360
+ 'string-literal': [
23361
+ {
23362
+ pattern: RegExp(/%[qQiIwWs]?/.source + percentExpression),
23363
+ greedy: true,
23364
+ inside: {
23365
+ interpolation: interpolation,
23366
+ string: /[\s\S]+/
23367
+ }
23368
+ },
23369
+ {
23370
+ pattern:
23371
+ /("|')(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|(?!\1)[^\\#\r\n])*\1/,
23372
+ greedy: true,
23373
+ inside: {
23374
+ interpolation: interpolation,
23375
+ string: /[\s\S]+/
23376
+ }
23377
+ },
23378
+ {
23379
+ pattern: /<<[-~]?([a-z_]\w*)[\r\n](?:.*[\r\n])*?[\t ]*\1/i,
23380
+ alias: 'heredoc-string',
23381
+ greedy: true,
23382
+ inside: {
23383
+ delimiter: {
23384
+ pattern: /^<<[-~]?[a-z_]\w*|\b[a-z_]\w*$/i,
23385
+ inside: {
23386
+ symbol: /\b\w+/,
23387
+ punctuation: /^<<[-~]?/
23388
+ }
23389
+ },
23390
+ interpolation: interpolation,
23391
+ string: /[\s\S]+/
23392
+ }
23393
+ },
23394
+ {
23395
+ pattern: /<<[-~]?'([a-z_]\w*)'[\r\n](?:.*[\r\n])*?[\t ]*\1/i,
23396
+ alias: 'heredoc-string',
23397
+ greedy: true,
23398
+ inside: {
23399
+ delimiter: {
23400
+ pattern: /^<<[-~]?'[a-z_]\w*'|\b[a-z_]\w*$/i,
23401
+ inside: {
23402
+ symbol: /\b\w+/,
23403
+ punctuation: /^<<[-~]?'|'$/
23404
+ }
23405
+ },
23406
+ string: /[\s\S]+/
23407
+ }
23408
+ }
23409
+ ],
23410
+ 'command-literal': [
23411
+ {
23412
+ pattern: RegExp(/%x/.source + percentExpression),
23413
+ greedy: true,
23414
+ inside: {
23415
+ interpolation: interpolation,
23416
+ command: {
23417
+ pattern: /[\s\S]+/,
23418
+ alias: 'string'
23419
+ }
23420
+ }
23421
+ },
23422
+ {
23423
+ pattern: /`(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|[^\\`#\r\n])*`/,
23424
+ greedy: true,
23425
+ inside: {
23426
+ interpolation: interpolation,
23427
+ command: {
23428
+ pattern: /[\s\S]+/,
23429
+ alias: 'string'
23430
+ }
23431
+ }
23432
+ }
23433
+ ]
23434
+ });
23435
+ delete Prism.languages.ruby.string;
23436
+ Prism.languages.insertBefore('ruby', 'number', {
23437
+ builtin:
23438
+ /\b(?:Array|Bignum|Binding|Class|Continuation|Dir|Exception|FalseClass|File|Fixnum|Float|Hash|IO|Integer|MatchData|Method|Module|NilClass|Numeric|Object|Proc|Range|Regexp|Stat|String|Struct|Symbol|TMS|Thread|ThreadGroup|Time|TrueClass)\b/,
23439
+ constant: /\b[A-Z][A-Z0-9_]*(?:[?!]|\b)/
23440
+ });
23441
+ Prism.languages.rb = Prism.languages.ruby;
23442
+ })(Prism);
23800
23443
  }
23801
23444
 
23802
- var csp_1;
23803
- var hasRequiredCsp;
23804
-
23805
- function requireCsp () {
23806
- if (hasRequiredCsp) return csp_1;
23807
- hasRequiredCsp = 1;
23808
-
23809
- csp_1 = csp;
23810
- csp.displayName = 'csp';
23811
- csp.aliases = [];
23812
- function csp(Prism) {
23813
- (function (Prism) {
23814
- /**
23815
- * @param {string} source
23816
- * @returns {RegExp}
23817
- */
23818
- function value(source) {
23819
- return RegExp(
23820
- /([ \t])/.source + '(?:' + source + ')' + /(?=[\s;]|$)/.source,
23821
- 'i'
23822
- )
23823
- }
23824
- Prism.languages.csp = {
23825
- directive: {
23826
- pattern:
23827
- /(^|[\s;])(?:base-uri|block-all-mixed-content|(?:child|connect|default|font|frame|img|manifest|media|object|prefetch|script|style|worker)-src|disown-opener|form-action|frame-(?:ancestors|options)|input-protection(?:-(?:clip|selectors))?|navigate-to|plugin-types|policy-uri|referrer|reflected-xss|report-(?:to|uri)|require-sri-for|sandbox|(?:script|style)-src-(?:attr|elem)|upgrade-insecure-requests)(?=[\s;]|$)/i,
23828
- lookbehind: true,
23829
- alias: 'property'
23830
- },
23831
- scheme: {
23832
- pattern: value(/[a-z][a-z0-9.+-]*:/.source),
23833
- lookbehind: true
23834
- },
23835
- none: {
23836
- pattern: value(/'none'/.source),
23837
- lookbehind: true,
23838
- alias: 'keyword'
23839
- },
23840
- nonce: {
23841
- pattern: value(/'nonce-[-+/\w=]+'/.source),
23842
- lookbehind: true,
23843
- alias: 'number'
23844
- },
23845
- hash: {
23846
- pattern: value(/'sha(?:256|384|512)-[-+/\w=]+'/.source),
23847
- lookbehind: true,
23848
- alias: 'number'
23849
- },
23850
- host: {
23851
- pattern: value(
23852
- /[a-z][a-z0-9.+-]*:\/\/[^\s;,']*/.source +
23853
- '|' +
23854
- /\*[^\s;,']*/.source +
23855
- '|' +
23856
- /[a-z0-9-]+(?:\.[a-z0-9-]+)+(?::[\d*]+)?(?:\/[^\s;,']*)?/.source
23857
- ),
23858
- lookbehind: true,
23859
- alias: 'url',
23860
- inside: {
23861
- important: /\*/
23862
- }
23863
- },
23864
- keyword: [
23865
- {
23866
- pattern: value(/'unsafe-[a-z-]+'/.source),
23867
- lookbehind: true,
23868
- alias: 'unsafe'
23869
- },
23870
- {
23871
- pattern: value(/'[a-z-]+'/.source),
23872
- lookbehind: true,
23873
- alias: 'safe'
23874
- }
23875
- ],
23876
- punctuation: /;/
23877
- };
23878
- })(Prism);
23879
- }
23880
- return csp_1;
23445
+ var refractorRuby = ruby_1;
23446
+ var crystal_1 = crystal;
23447
+ crystal.displayName = 'crystal';
23448
+ crystal.aliases = [];
23449
+ function crystal(Prism) {
23450
+ Prism.register(refractorRuby)
23451
+ ;(function (Prism) {
23452
+ Prism.languages.crystal = Prism.languages.extend('ruby', {
23453
+ keyword: [
23454
+ /\b(?:__DIR__|__END_LINE__|__FILE__|__LINE__|abstract|alias|annotation|as|asm|begin|break|case|class|def|do|else|elsif|end|ensure|enum|extend|for|fun|if|ifdef|include|instance_sizeof|lib|macro|module|next|of|out|pointerof|private|protected|ptr|require|rescue|return|select|self|sizeof|struct|super|then|type|typeof|undef|uninitialized|union|unless|until|when|while|with|yield)\b/,
23455
+ {
23456
+ pattern: /(\.\s*)(?:is_a|responds_to)\?/,
23457
+ lookbehind: true
23458
+ }
23459
+ ],
23460
+ number:
23461
+ /\b(?:0b[01_]*[01]|0o[0-7_]*[0-7]|0x[\da-fA-F_]*[\da-fA-F]|(?:\d(?:[\d_]*\d)?)(?:\.[\d_]*\d)?(?:[eE][+-]?[\d_]*\d)?)(?:_(?:[uif](?:8|16|32|64))?)?\b/,
23462
+ operator: [/->/, Prism.languages.ruby.operator],
23463
+ punctuation: /[(){}[\].,;\\]/
23464
+ });
23465
+ Prism.languages.insertBefore('crystal', 'string-literal', {
23466
+ attribute: {
23467
+ pattern: /@\[.*?\]/,
23468
+ inside: {
23469
+ delimiter: {
23470
+ pattern: /^@\[|\]$/,
23471
+ alias: 'punctuation'
23472
+ },
23473
+ attribute: {
23474
+ pattern: /^(\s*)\w+/,
23475
+ lookbehind: true,
23476
+ alias: 'class-name'
23477
+ },
23478
+ args: {
23479
+ pattern: /\S(?:[\s\S]*\S)?/,
23480
+ inside: Prism.languages.crystal
23481
+ }
23482
+ }
23483
+ },
23484
+ expansion: {
23485
+ pattern: /\{(?:\{.*?\}|%.*?%)\}/,
23486
+ inside: {
23487
+ content: {
23488
+ pattern: /^(\{.)[\s\S]+(?=.\}$)/,
23489
+ lookbehind: true,
23490
+ inside: Prism.languages.crystal
23491
+ },
23492
+ delimiter: {
23493
+ pattern: /^\{[\{%]|[\}%]\}$/,
23494
+ alias: 'operator'
23495
+ }
23496
+ }
23497
+ },
23498
+ char: {
23499
+ pattern:
23500
+ /'(?:[^\\\r\n]{1,2}|\\(?:.|u(?:[A-Fa-f0-9]{1,4}|\{[A-Fa-f0-9]{1,6}\})))'/,
23501
+ greedy: true
23502
+ }
23503
+ });
23504
+ })(Prism);
23881
23505
  }
23882
23506
 
23883
- var cssExtras_1;
23884
- var hasRequiredCssExtras;
23885
-
23886
- function requireCssExtras () {
23887
- if (hasRequiredCssExtras) return cssExtras_1;
23888
- hasRequiredCssExtras = 1;
23889
-
23890
- cssExtras_1 = cssExtras;
23891
- cssExtras.displayName = 'cssExtras';
23892
- cssExtras.aliases = [];
23893
- function cssExtras(Prism) {
23894
- (function (Prism) {
23895
- var string = /("|')(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/;
23896
- var selectorInside;
23897
- Prism.languages.css.selector = {
23898
- pattern: Prism.languages.css.selector.pattern,
23899
- lookbehind: true,
23900
- inside: (selectorInside = {
23901
- 'pseudo-element':
23902
- /:(?:after|before|first-letter|first-line|selection)|::[-\w]+/,
23903
- 'pseudo-class': /:[-\w]+/,
23904
- class: /\.[-\w]+/,
23905
- id: /#[-\w]+/,
23906
- attribute: {
23907
- pattern: RegExp('\\[(?:[^[\\]"\']|' + string.source + ')*\\]'),
23908
- greedy: true,
23909
- inside: {
23910
- punctuation: /^\[|\]$/,
23911
- 'case-sensitivity': {
23912
- pattern: /(\s)[si]$/i,
23913
- lookbehind: true,
23914
- alias: 'keyword'
23915
- },
23916
- namespace: {
23917
- pattern: /^(\s*)(?:(?!\s)[-*\w\xA0-\uFFFF])*\|(?!=)/,
23918
- lookbehind: true,
23919
- inside: {
23920
- punctuation: /\|$/
23921
- }
23922
- },
23923
- 'attr-name': {
23924
- pattern: /^(\s*)(?:(?!\s)[-\w\xA0-\uFFFF])+/,
23925
- lookbehind: true
23926
- },
23927
- 'attr-value': [
23928
- string,
23929
- {
23930
- pattern: /(=\s*)(?:(?!\s)[-\w\xA0-\uFFFF])+(?=\s*$)/,
23931
- lookbehind: true
23932
- }
23933
- ],
23934
- operator: /[|~*^$]?=/
23935
- }
23936
- },
23937
- 'n-th': [
23938
- {
23939
- pattern: /(\(\s*)[+-]?\d*[\dn](?:\s*[+-]\s*\d+)?(?=\s*\))/,
23940
- lookbehind: true,
23941
- inside: {
23942
- number: /[\dn]+/,
23943
- operator: /[+-]/
23944
- }
23945
- },
23946
- {
23947
- pattern: /(\(\s*)(?:even|odd)(?=\s*\))/i,
23948
- lookbehind: true
23949
- }
23950
- ],
23951
- combinator: />|\+|~|\|\|/,
23952
- // the `tag` token has been existed and removed.
23953
- // because we can't find a perfect tokenize to match it.
23954
- // if you want to add it, please read https://github.com/PrismJS/prism/pull/2373 first.
23955
- punctuation: /[(),]/
23956
- })
23957
- };
23958
- Prism.languages.css['atrule'].inside['selector-function-argument'].inside =
23959
- selectorInside;
23960
- Prism.languages.insertBefore('css', 'property', {
23961
- variable: {
23962
- pattern:
23963
- /(^|[^-\w\xA0-\uFFFF])--(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*/i,
23964
- lookbehind: true
23965
- }
23966
- });
23967
- var unit = {
23968
- pattern: /(\b\d+)(?:%|[a-z]+(?![\w-]))/,
23969
- lookbehind: true
23970
- }; // 123 -123 .123 -.123 12.3 -12.3
23971
- var number = {
23972
- pattern: /(^|[^\w.-])-?(?:\d+(?:\.\d+)?|\.\d+)/,
23973
- lookbehind: true
23974
- };
23975
- Prism.languages.insertBefore('css', 'function', {
23976
- operator: {
23977
- pattern: /(\s)[+\-*\/](?=\s)/,
23978
- lookbehind: true
23979
- },
23980
- // CAREFUL!
23981
- // Previewers and Inline color use hexcode and color.
23982
- hexcode: {
23983
- pattern: /\B#[\da-f]{3,8}\b/i,
23984
- alias: 'color'
23985
- },
23986
- color: [
23987
- {
23988
- pattern:
23989
- /(^|[^\w-])(?:AliceBlue|AntiqueWhite|Aqua|Aquamarine|Azure|Beige|Bisque|Black|BlanchedAlmond|Blue|BlueViolet|Brown|BurlyWood|CadetBlue|Chartreuse|Chocolate|Coral|CornflowerBlue|Cornsilk|Crimson|Cyan|DarkBlue|DarkCyan|DarkGoldenRod|DarkGr[ae]y|DarkGreen|DarkKhaki|DarkMagenta|DarkOliveGreen|DarkOrange|DarkOrchid|DarkRed|DarkSalmon|DarkSeaGreen|DarkSlateBlue|DarkSlateGr[ae]y|DarkTurquoise|DarkViolet|DeepPink|DeepSkyBlue|DimGr[ae]y|DodgerBlue|FireBrick|FloralWhite|ForestGreen|Fuchsia|Gainsboro|GhostWhite|Gold|GoldenRod|Gr[ae]y|Green|GreenYellow|HoneyDew|HotPink|IndianRed|Indigo|Ivory|Khaki|Lavender|LavenderBlush|LawnGreen|LemonChiffon|LightBlue|LightCoral|LightCyan|LightGoldenRodYellow|LightGr[ae]y|LightGreen|LightPink|LightSalmon|LightSeaGreen|LightSkyBlue|LightSlateGr[ae]y|LightSteelBlue|LightYellow|Lime|LimeGreen|Linen|Magenta|Maroon|MediumAquaMarine|MediumBlue|MediumOrchid|MediumPurple|MediumSeaGreen|MediumSlateBlue|MediumSpringGreen|MediumTurquoise|MediumVioletRed|MidnightBlue|MintCream|MistyRose|Moccasin|NavajoWhite|Navy|OldLace|Olive|OliveDrab|Orange|OrangeRed|Orchid|PaleGoldenRod|PaleGreen|PaleTurquoise|PaleVioletRed|PapayaWhip|PeachPuff|Peru|Pink|Plum|PowderBlue|Purple|Red|RosyBrown|RoyalBlue|SaddleBrown|Salmon|SandyBrown|SeaGreen|SeaShell|Sienna|Silver|SkyBlue|SlateBlue|SlateGr[ae]y|Snow|SpringGreen|SteelBlue|Tan|Teal|Thistle|Tomato|Transparent|Turquoise|Violet|Wheat|White|WhiteSmoke|Yellow|YellowGreen)(?![\w-])/i,
23990
- lookbehind: true
23991
- },
23992
- {
23993
- pattern:
23994
- /\b(?:hsl|rgb)\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*\)\B|\b(?:hsl|rgb)a\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*,\s*(?:0|0?\.\d+|1)\s*\)\B/i,
23995
- inside: {
23996
- unit: unit,
23997
- number: number,
23998
- function: /[\w-]+(?=\()/,
23999
- punctuation: /[(),]/
24000
- }
24001
- }
24002
- ],
24003
- // it's important that there is no boundary assertion after the hex digits
24004
- entity: /\\[\da-f]{1,8}/i,
24005
- unit: unit,
24006
- number: number
24007
- });
24008
- })(Prism);
24009
- }
24010
- return cssExtras_1;
23507
+ var refractorCsharp = csharp_1;
23508
+ var cshtml_1 = cshtml;
23509
+ cshtml.displayName = 'cshtml';
23510
+ cshtml.aliases = ['razor'];
23511
+ function cshtml(Prism) {
23512
+ Prism.register(refractorCsharp)
23513
+ // Docs:
23514
+ // https://docs.microsoft.com/en-us/aspnet/core/razor-pages/?view=aspnetcore-5.0&tabs=visual-studio
23515
+ // https://docs.microsoft.com/en-us/aspnet/core/mvc/views/razor?view=aspnetcore-5.0
23516
+ ;(function (Prism) {
23517
+ var commentLike = /\/(?![/*])|\/\/.*[\r\n]|\/\*[^*]*(?:\*(?!\/)[^*]*)*\*\//
23518
+ .source;
23519
+ var stringLike =
23520
+ /@(?!")|"(?:[^\r\n\\"]|\\.)*"|@"(?:[^\\"]|""|\\[\s\S])*"(?!")/.source +
23521
+ '|' +
23522
+ /'(?:(?:[^\r\n'\\]|\\.|\\[Uux][\da-fA-F]{1,8})'|(?=[^\\](?!')))/.source;
23523
+ /**
23524
+ * Creates a nested pattern where all occurrences of the string `<<self>>` are replaced with the pattern itself.
23525
+ *
23526
+ * @param {string} pattern
23527
+ * @param {number} depthLog2
23528
+ * @returns {string}
23529
+ */
23530
+ function nested(pattern, depthLog2) {
23531
+ for (var i = 0; i < depthLog2; i++) {
23532
+ pattern = pattern.replace(/<self>/g, function () {
23533
+ return '(?:' + pattern + ')'
23534
+ });
23535
+ }
23536
+ return pattern
23537
+ .replace(/<self>/g, '[^\\s\\S]')
23538
+ .replace(/<str>/g, '(?:' + stringLike + ')')
23539
+ .replace(/<comment>/g, '(?:' + commentLike + ')')
23540
+ }
23541
+ var round = nested(/\((?:[^()'"@/]|<str>|<comment>|<self>)*\)/.source, 2);
23542
+ var square = nested(/\[(?:[^\[\]'"@/]|<str>|<comment>|<self>)*\]/.source, 2);
23543
+ var curly = nested(/\{(?:[^{}'"@/]|<str>|<comment>|<self>)*\}/.source, 2);
23544
+ var angle = nested(/<(?:[^<>'"@/]|<str>|<comment>|<self>)*>/.source, 2); // Note about the above bracket patterns:
23545
+ // They all ignore HTML expressions that might be in the C# code. This is a problem because HTML (like strings and
23546
+ // comments) is parsed differently. This is a huge problem because HTML might contain brackets and quotes which
23547
+ // messes up the bracket and string counting implemented by the above patterns.
23548
+ //
23549
+ // This problem is not fixable because 1) HTML expression are highly context sensitive and very difficult to detect
23550
+ // and 2) they require one capturing group at every nested level. See the `tagRegion` pattern to admire the
23551
+ // complexity of an HTML expression.
23552
+ //
23553
+ // To somewhat alleviate the problem a bit, the patterns for characters (e.g. 'a') is very permissive, it also
23554
+ // allows invalid characters to support HTML expressions like this: <p>That's it!</p>.
23555
+ var tagAttrs =
23556
+ /(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?/
23557
+ .source;
23558
+ var tagContent = /(?!\d)[^\s>\/=$<%]+/.source + tagAttrs + /\s*\/?>/.source;
23559
+ var tagRegion =
23560
+ /\B@?/.source +
23561
+ '(?:' +
23562
+ /<([a-zA-Z][\w:]*)/.source +
23563
+ tagAttrs +
23564
+ /\s*>/.source +
23565
+ '(?:' +
23566
+ (/[^<]/.source +
23567
+ '|' + // all tags that are not the start tag
23568
+ // eslint-disable-next-line regexp/strict
23569
+ /<\/?(?!\1\b)/.source +
23570
+ tagContent +
23571
+ '|' + // nested start tag
23572
+ nested(
23573
+ // eslint-disable-next-line regexp/strict
23574
+ /<\1/.source +
23575
+ tagAttrs +
23576
+ /\s*>/.source +
23577
+ '(?:' +
23578
+ (/[^<]/.source +
23579
+ '|' + // all tags that are not the start tag
23580
+ // eslint-disable-next-line regexp/strict
23581
+ /<\/?(?!\1\b)/.source +
23582
+ tagContent +
23583
+ '|' +
23584
+ '<self>') +
23585
+ ')*' + // eslint-disable-next-line regexp/strict
23586
+ /<\/\1\s*>/.source,
23587
+ 2
23588
+ )) +
23589
+ ')*' + // eslint-disable-next-line regexp/strict
23590
+ /<\/\1\s*>/.source +
23591
+ '|' +
23592
+ /</.source +
23593
+ tagContent +
23594
+ ')'; // Now for the actual language definition(s):
23595
+ //
23596
+ // Razor as a language has 2 parts:
23597
+ // 1) CSHTML: A markup-like language that has been extended with inline C# code expressions and blocks.
23598
+ // 2) C#+HTML: A variant of C# that can contain CSHTML tags as expressions.
23599
+ //
23600
+ // In the below code, both CSHTML and C#+HTML will be create as separate language definitions that reference each
23601
+ // other. However, only CSHTML will be exported via `Prism.languages`.
23602
+ Prism.languages.cshtml = Prism.languages.extend('markup', {});
23603
+ var csharpWithHtml = Prism.languages.insertBefore(
23604
+ 'csharp',
23605
+ 'string',
23606
+ {
23607
+ html: {
23608
+ pattern: RegExp(tagRegion),
23609
+ greedy: true,
23610
+ inside: Prism.languages.cshtml
23611
+ }
23612
+ },
23613
+ {
23614
+ csharp: Prism.languages.extend('csharp', {})
23615
+ }
23616
+ );
23617
+ var cs = {
23618
+ pattern: /\S[\s\S]*/,
23619
+ alias: 'language-csharp',
23620
+ inside: csharpWithHtml
23621
+ };
23622
+ Prism.languages.insertBefore('cshtml', 'prolog', {
23623
+ 'razor-comment': {
23624
+ pattern: /@\*[\s\S]*?\*@/,
23625
+ greedy: true,
23626
+ alias: 'comment'
23627
+ },
23628
+ block: {
23629
+ pattern: RegExp(
23630
+ /(^|[^@])@/.source +
23631
+ '(?:' +
23632
+ [
23633
+ // @{ ... }
23634
+ curly, // @code{ ... }
23635
+ /(?:code|functions)\s*/.source + curly, // @for (...) { ... }
23636
+ /(?:for|foreach|lock|switch|using|while)\s*/.source +
23637
+ round +
23638
+ /\s*/.source +
23639
+ curly, // @do { ... } while (...);
23640
+ /do\s*/.source +
23641
+ curly +
23642
+ /\s*while\s*/.source +
23643
+ round +
23644
+ /(?:\s*;)?/.source, // @try { ... } catch (...) { ... } finally { ... }
23645
+ /try\s*/.source +
23646
+ curly +
23647
+ /\s*catch\s*/.source +
23648
+ round +
23649
+ /\s*/.source +
23650
+ curly +
23651
+ /\s*finally\s*/.source +
23652
+ curly, // @if (...) {...} else if (...) {...} else {...}
23653
+ /if\s*/.source +
23654
+ round +
23655
+ /\s*/.source +
23656
+ curly +
23657
+ '(?:' +
23658
+ /\s*else/.source +
23659
+ '(?:' +
23660
+ /\s+if\s*/.source +
23661
+ round +
23662
+ ')?' +
23663
+ /\s*/.source +
23664
+ curly +
23665
+ ')*'
23666
+ ].join('|') +
23667
+ ')'
23668
+ ),
23669
+ lookbehind: true,
23670
+ greedy: true,
23671
+ inside: {
23672
+ keyword: /^@\w*/,
23673
+ csharp: cs
23674
+ }
23675
+ },
23676
+ directive: {
23677
+ pattern:
23678
+ /^([ \t]*)@(?:addTagHelper|attribute|implements|inherits|inject|layout|model|namespace|page|preservewhitespace|removeTagHelper|section|tagHelperPrefix|using)(?=\s).*/m,
23679
+ lookbehind: true,
23680
+ greedy: true,
23681
+ inside: {
23682
+ keyword: /^@\w+/,
23683
+ csharp: cs
23684
+ }
23685
+ },
23686
+ value: {
23687
+ pattern: RegExp(
23688
+ /(^|[^@])@/.source +
23689
+ /(?:await\b\s*)?/.source +
23690
+ '(?:' +
23691
+ /\w+\b/.source +
23692
+ '|' +
23693
+ round +
23694
+ ')' +
23695
+ '(?:' +
23696
+ /[?!]?\.\w+\b/.source +
23697
+ '|' +
23698
+ round +
23699
+ '|' +
23700
+ square +
23701
+ '|' +
23702
+ angle +
23703
+ round +
23704
+ ')*'
23705
+ ),
23706
+ lookbehind: true,
23707
+ greedy: true,
23708
+ alias: 'variable',
23709
+ inside: {
23710
+ keyword: /^@/,
23711
+ csharp: cs
23712
+ }
23713
+ },
23714
+ 'delegate-operator': {
23715
+ pattern: /(^|[^@])@(?=<)/,
23716
+ lookbehind: true,
23717
+ alias: 'operator'
23718
+ }
23719
+ });
23720
+ Prism.languages.razor = Prism.languages.cshtml;
23721
+ })(Prism);
24011
23722
  }
24012
23723
 
24013
- var csv_1;
24014
- var hasRequiredCsv;
24015
-
24016
- function requireCsv () {
24017
- if (hasRequiredCsv) return csv_1;
24018
- hasRequiredCsv = 1;
24019
-
24020
- csv_1 = csv;
24021
- csv.displayName = 'csv';
24022
- csv.aliases = [];
24023
- function csv(Prism) {
24024
- // https://tools.ietf.org/html/rfc4180
24025
- Prism.languages.csv = {
24026
- value: /[^\r\n,"]+|"(?:[^"]|"")*"(?!")/,
24027
- punctuation: /,/
24028
- };
24029
- }
24030
- return csv_1;
23724
+ var csp_1 = csp;
23725
+ csp.displayName = 'csp';
23726
+ csp.aliases = [];
23727
+ function csp(Prism) {
23728
+ (function (Prism) {
23729
+ /**
23730
+ * @param {string} source
23731
+ * @returns {RegExp}
23732
+ */
23733
+ function value(source) {
23734
+ return RegExp(
23735
+ /([ \t])/.source + '(?:' + source + ')' + /(?=[\s;]|$)/.source,
23736
+ 'i'
23737
+ )
23738
+ }
23739
+ Prism.languages.csp = {
23740
+ directive: {
23741
+ pattern:
23742
+ /(^|[\s;])(?:base-uri|block-all-mixed-content|(?:child|connect|default|font|frame|img|manifest|media|object|prefetch|script|style|worker)-src|disown-opener|form-action|frame-(?:ancestors|options)|input-protection(?:-(?:clip|selectors))?|navigate-to|plugin-types|policy-uri|referrer|reflected-xss|report-(?:to|uri)|require-sri-for|sandbox|(?:script|style)-src-(?:attr|elem)|upgrade-insecure-requests)(?=[\s;]|$)/i,
23743
+ lookbehind: true,
23744
+ alias: 'property'
23745
+ },
23746
+ scheme: {
23747
+ pattern: value(/[a-z][a-z0-9.+-]*:/.source),
23748
+ lookbehind: true
23749
+ },
23750
+ none: {
23751
+ pattern: value(/'none'/.source),
23752
+ lookbehind: true,
23753
+ alias: 'keyword'
23754
+ },
23755
+ nonce: {
23756
+ pattern: value(/'nonce-[-+/\w=]+'/.source),
23757
+ lookbehind: true,
23758
+ alias: 'number'
23759
+ },
23760
+ hash: {
23761
+ pattern: value(/'sha(?:256|384|512)-[-+/\w=]+'/.source),
23762
+ lookbehind: true,
23763
+ alias: 'number'
23764
+ },
23765
+ host: {
23766
+ pattern: value(
23767
+ /[a-z][a-z0-9.+-]*:\/\/[^\s;,']*/.source +
23768
+ '|' +
23769
+ /\*[^\s;,']*/.source +
23770
+ '|' +
23771
+ /[a-z0-9-]+(?:\.[a-z0-9-]+)+(?::[\d*]+)?(?:\/[^\s;,']*)?/.source
23772
+ ),
23773
+ lookbehind: true,
23774
+ alias: 'url',
23775
+ inside: {
23776
+ important: /\*/
23777
+ }
23778
+ },
23779
+ keyword: [
23780
+ {
23781
+ pattern: value(/'unsafe-[a-z-]+'/.source),
23782
+ lookbehind: true,
23783
+ alias: 'unsafe'
23784
+ },
23785
+ {
23786
+ pattern: value(/'[a-z-]+'/.source),
23787
+ lookbehind: true,
23788
+ alias: 'safe'
23789
+ }
23790
+ ],
23791
+ punctuation: /;/
23792
+ };
23793
+ })(Prism);
24031
23794
  }
24032
23795
 
24033
- var cypher_1;
24034
- var hasRequiredCypher;
24035
-
24036
- function requireCypher () {
24037
- if (hasRequiredCypher) return cypher_1;
24038
- hasRequiredCypher = 1;
24039
-
24040
- cypher_1 = cypher;
24041
- cypher.displayName = 'cypher';
24042
- cypher.aliases = [];
24043
- function cypher(Prism) {
24044
- Prism.languages.cypher = {
24045
- // https://neo4j.com/docs/cypher-manual/current/syntax/comments/
24046
- comment: /\/\/.*/,
24047
- string: {
24048
- pattern: /"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/,
24049
- greedy: true
24050
- },
24051
- 'class-name': {
24052
- pattern: /(:\s*)(?:\w+|`(?:[^`\\\r\n])*`)(?=\s*[{):])/,
24053
- lookbehind: true,
24054
- greedy: true
24055
- },
24056
- relationship: {
24057
- pattern:
24058
- /(-\[\s*(?:\w+\s*|`(?:[^`\\\r\n])*`\s*)?:\s*|\|\s*:\s*)(?:\w+|`(?:[^`\\\r\n])*`)/,
24059
- lookbehind: true,
24060
- greedy: true,
24061
- alias: 'property'
24062
- },
24063
- identifier: {
24064
- pattern: /`(?:[^`\\\r\n])*`/,
24065
- greedy: true
24066
- },
24067
- variable: /\$\w+/,
24068
- // https://neo4j.com/docs/cypher-manual/current/syntax/reserved/
24069
- keyword:
24070
- /\b(?:ADD|ALL|AND|AS|ASC|ASCENDING|ASSERT|BY|CALL|CASE|COMMIT|CONSTRAINT|CONTAINS|CREATE|CSV|DELETE|DESC|DESCENDING|DETACH|DISTINCT|DO|DROP|ELSE|END|ENDS|EXISTS|FOR|FOREACH|IN|INDEX|IS|JOIN|KEY|LIMIT|LOAD|MANDATORY|MATCH|MERGE|NODE|NOT|OF|ON|OPTIONAL|OR|ORDER(?=\s+BY)|PERIODIC|REMOVE|REQUIRE|RETURN|SCALAR|SCAN|SET|SKIP|START|STARTS|THEN|UNION|UNIQUE|UNWIND|USING|WHEN|WHERE|WITH|XOR|YIELD)\b/i,
24071
- function: /\b\w+\b(?=\s*\()/,
24072
- boolean: /\b(?:false|null|true)\b/i,
24073
- number: /\b(?:0x[\da-fA-F]+|\d+(?:\.\d+)?(?:[eE][+-]?\d+)?)\b/,
24074
- // https://neo4j.com/docs/cypher-manual/current/syntax/operators/
24075
- operator: /:|<--?|--?>?|<>|=~?|[<>]=?|[+*/%^|]|\.\.\.?/,
24076
- punctuation: /[()[\]{},;.]/
24077
- };
24078
- }
24079
- return cypher_1;
23796
+ var cssExtras_1 = cssExtras;
23797
+ cssExtras.displayName = 'cssExtras';
23798
+ cssExtras.aliases = [];
23799
+ function cssExtras(Prism) {
23800
+ (function (Prism) {
23801
+ var string = /("|')(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/;
23802
+ var selectorInside;
23803
+ Prism.languages.css.selector = {
23804
+ pattern: Prism.languages.css.selector.pattern,
23805
+ lookbehind: true,
23806
+ inside: (selectorInside = {
23807
+ 'pseudo-element':
23808
+ /:(?:after|before|first-letter|first-line|selection)|::[-\w]+/,
23809
+ 'pseudo-class': /:[-\w]+/,
23810
+ class: /\.[-\w]+/,
23811
+ id: /#[-\w]+/,
23812
+ attribute: {
23813
+ pattern: RegExp('\\[(?:[^[\\]"\']|' + string.source + ')*\\]'),
23814
+ greedy: true,
23815
+ inside: {
23816
+ punctuation: /^\[|\]$/,
23817
+ 'case-sensitivity': {
23818
+ pattern: /(\s)[si]$/i,
23819
+ lookbehind: true,
23820
+ alias: 'keyword'
23821
+ },
23822
+ namespace: {
23823
+ pattern: /^(\s*)(?:(?!\s)[-*\w\xA0-\uFFFF])*\|(?!=)/,
23824
+ lookbehind: true,
23825
+ inside: {
23826
+ punctuation: /\|$/
23827
+ }
23828
+ },
23829
+ 'attr-name': {
23830
+ pattern: /^(\s*)(?:(?!\s)[-\w\xA0-\uFFFF])+/,
23831
+ lookbehind: true
23832
+ },
23833
+ 'attr-value': [
23834
+ string,
23835
+ {
23836
+ pattern: /(=\s*)(?:(?!\s)[-\w\xA0-\uFFFF])+(?=\s*$)/,
23837
+ lookbehind: true
23838
+ }
23839
+ ],
23840
+ operator: /[|~*^$]?=/
23841
+ }
23842
+ },
23843
+ 'n-th': [
23844
+ {
23845
+ pattern: /(\(\s*)[+-]?\d*[\dn](?:\s*[+-]\s*\d+)?(?=\s*\))/,
23846
+ lookbehind: true,
23847
+ inside: {
23848
+ number: /[\dn]+/,
23849
+ operator: /[+-]/
23850
+ }
23851
+ },
23852
+ {
23853
+ pattern: /(\(\s*)(?:even|odd)(?=\s*\))/i,
23854
+ lookbehind: true
23855
+ }
23856
+ ],
23857
+ combinator: />|\+|~|\|\|/,
23858
+ // the `tag` token has been existed and removed.
23859
+ // because we can't find a perfect tokenize to match it.
23860
+ // if you want to add it, please read https://github.com/PrismJS/prism/pull/2373 first.
23861
+ punctuation: /[(),]/
23862
+ })
23863
+ };
23864
+ Prism.languages.css['atrule'].inside['selector-function-argument'].inside =
23865
+ selectorInside;
23866
+ Prism.languages.insertBefore('css', 'property', {
23867
+ variable: {
23868
+ pattern:
23869
+ /(^|[^-\w\xA0-\uFFFF])--(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*/i,
23870
+ lookbehind: true
23871
+ }
23872
+ });
23873
+ var unit = {
23874
+ pattern: /(\b\d+)(?:%|[a-z]+(?![\w-]))/,
23875
+ lookbehind: true
23876
+ }; // 123 -123 .123 -.123 12.3 -12.3
23877
+ var number = {
23878
+ pattern: /(^|[^\w.-])-?(?:\d+(?:\.\d+)?|\.\d+)/,
23879
+ lookbehind: true
23880
+ };
23881
+ Prism.languages.insertBefore('css', 'function', {
23882
+ operator: {
23883
+ pattern: /(\s)[+\-*\/](?=\s)/,
23884
+ lookbehind: true
23885
+ },
23886
+ // CAREFUL!
23887
+ // Previewers and Inline color use hexcode and color.
23888
+ hexcode: {
23889
+ pattern: /\B#[\da-f]{3,8}\b/i,
23890
+ alias: 'color'
23891
+ },
23892
+ color: [
23893
+ {
23894
+ pattern:
23895
+ /(^|[^\w-])(?:AliceBlue|AntiqueWhite|Aqua|Aquamarine|Azure|Beige|Bisque|Black|BlanchedAlmond|Blue|BlueViolet|Brown|BurlyWood|CadetBlue|Chartreuse|Chocolate|Coral|CornflowerBlue|Cornsilk|Crimson|Cyan|DarkBlue|DarkCyan|DarkGoldenRod|DarkGr[ae]y|DarkGreen|DarkKhaki|DarkMagenta|DarkOliveGreen|DarkOrange|DarkOrchid|DarkRed|DarkSalmon|DarkSeaGreen|DarkSlateBlue|DarkSlateGr[ae]y|DarkTurquoise|DarkViolet|DeepPink|DeepSkyBlue|DimGr[ae]y|DodgerBlue|FireBrick|FloralWhite|ForestGreen|Fuchsia|Gainsboro|GhostWhite|Gold|GoldenRod|Gr[ae]y|Green|GreenYellow|HoneyDew|HotPink|IndianRed|Indigo|Ivory|Khaki|Lavender|LavenderBlush|LawnGreen|LemonChiffon|LightBlue|LightCoral|LightCyan|LightGoldenRodYellow|LightGr[ae]y|LightGreen|LightPink|LightSalmon|LightSeaGreen|LightSkyBlue|LightSlateGr[ae]y|LightSteelBlue|LightYellow|Lime|LimeGreen|Linen|Magenta|Maroon|MediumAquaMarine|MediumBlue|MediumOrchid|MediumPurple|MediumSeaGreen|MediumSlateBlue|MediumSpringGreen|MediumTurquoise|MediumVioletRed|MidnightBlue|MintCream|MistyRose|Moccasin|NavajoWhite|Navy|OldLace|Olive|OliveDrab|Orange|OrangeRed|Orchid|PaleGoldenRod|PaleGreen|PaleTurquoise|PaleVioletRed|PapayaWhip|PeachPuff|Peru|Pink|Plum|PowderBlue|Purple|Red|RosyBrown|RoyalBlue|SaddleBrown|Salmon|SandyBrown|SeaGreen|SeaShell|Sienna|Silver|SkyBlue|SlateBlue|SlateGr[ae]y|Snow|SpringGreen|SteelBlue|Tan|Teal|Thistle|Tomato|Transparent|Turquoise|Violet|Wheat|White|WhiteSmoke|Yellow|YellowGreen)(?![\w-])/i,
23896
+ lookbehind: true
23897
+ },
23898
+ {
23899
+ pattern:
23900
+ /\b(?:hsl|rgb)\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*\)\B|\b(?:hsl|rgb)a\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*,\s*(?:0|0?\.\d+|1)\s*\)\B/i,
23901
+ inside: {
23902
+ unit: unit,
23903
+ number: number,
23904
+ function: /[\w-]+(?=\()/,
23905
+ punctuation: /[(),]/
23906
+ }
23907
+ }
23908
+ ],
23909
+ // it's important that there is no boundary assertion after the hex digits
23910
+ entity: /\\[\da-f]{1,8}/i,
23911
+ unit: unit,
23912
+ number: number
23913
+ });
23914
+ })(Prism);
24080
23915
  }
24081
23916
 
24082
- var d_1;
24083
- var hasRequiredD;
23917
+ var csv_1 = csv;
23918
+ csv.displayName = 'csv';
23919
+ csv.aliases = [];
23920
+ function csv(Prism) {
23921
+ // https://tools.ietf.org/html/rfc4180
23922
+ Prism.languages.csv = {
23923
+ value: /[^\r\n,"]+|"(?:[^"]|"")*"(?!")/,
23924
+ punctuation: /,/
23925
+ };
23926
+ }
24084
23927
 
24085
- function requireD () {
24086
- if (hasRequiredD) return d_1;
24087
- hasRequiredD = 1;
23928
+ var cypher_1 = cypher;
23929
+ cypher.displayName = 'cypher';
23930
+ cypher.aliases = [];
23931
+ function cypher(Prism) {
23932
+ Prism.languages.cypher = {
23933
+ // https://neo4j.com/docs/cypher-manual/current/syntax/comments/
23934
+ comment: /\/\/.*/,
23935
+ string: {
23936
+ pattern: /"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/,
23937
+ greedy: true
23938
+ },
23939
+ 'class-name': {
23940
+ pattern: /(:\s*)(?:\w+|`(?:[^`\\\r\n])*`)(?=\s*[{):])/,
23941
+ lookbehind: true,
23942
+ greedy: true
23943
+ },
23944
+ relationship: {
23945
+ pattern:
23946
+ /(-\[\s*(?:\w+\s*|`(?:[^`\\\r\n])*`\s*)?:\s*|\|\s*:\s*)(?:\w+|`(?:[^`\\\r\n])*`)/,
23947
+ lookbehind: true,
23948
+ greedy: true,
23949
+ alias: 'property'
23950
+ },
23951
+ identifier: {
23952
+ pattern: /`(?:[^`\\\r\n])*`/,
23953
+ greedy: true
23954
+ },
23955
+ variable: /\$\w+/,
23956
+ // https://neo4j.com/docs/cypher-manual/current/syntax/reserved/
23957
+ keyword:
23958
+ /\b(?:ADD|ALL|AND|AS|ASC|ASCENDING|ASSERT|BY|CALL|CASE|COMMIT|CONSTRAINT|CONTAINS|CREATE|CSV|DELETE|DESC|DESCENDING|DETACH|DISTINCT|DO|DROP|ELSE|END|ENDS|EXISTS|FOR|FOREACH|IN|INDEX|IS|JOIN|KEY|LIMIT|LOAD|MANDATORY|MATCH|MERGE|NODE|NOT|OF|ON|OPTIONAL|OR|ORDER(?=\s+BY)|PERIODIC|REMOVE|REQUIRE|RETURN|SCALAR|SCAN|SET|SKIP|START|STARTS|THEN|UNION|UNIQUE|UNWIND|USING|WHEN|WHERE|WITH|XOR|YIELD)\b/i,
23959
+ function: /\b\w+\b(?=\s*\()/,
23960
+ boolean: /\b(?:false|null|true)\b/i,
23961
+ number: /\b(?:0x[\da-fA-F]+|\d+(?:\.\d+)?(?:[eE][+-]?\d+)?)\b/,
23962
+ // https://neo4j.com/docs/cypher-manual/current/syntax/operators/
23963
+ operator: /:|<--?|--?>?|<>|=~?|[<>]=?|[+*/%^|]|\.\.\.?/,
23964
+ punctuation: /[()[\]{},;.]/
23965
+ };
23966
+ }
24088
23967
 
24089
- d_1 = d;
24090
- d.displayName = 'd';
24091
- d.aliases = [];
24092
- function d(Prism) {
24093
- Prism.languages.d = Prism.languages.extend('clike', {
24094
- comment: [
24095
- {
24096
- // Shebang
24097
- pattern: /^\s*#!.+/,
24098
- greedy: true
24099
- },
24100
- {
24101
- pattern: RegExp(
24102
- /(^|[^\\])/.source +
24103
- '(?:' +
24104
- [
24105
- // /+ comment +/
24106
- // Allow one level of nesting
24107
- /\/\+(?:\/\+(?:[^+]|\+(?!\/))*\+\/|(?!\/\+)[\s\S])*?\+\//.source, // // comment
24108
- /\/\/.*/.source, // /* comment */
24109
- /\/\*[\s\S]*?\*\//.source
24110
- ].join('|') +
24111
- ')'
24112
- ),
24113
- lookbehind: true,
24114
- greedy: true
24115
- }
24116
- ],
24117
- string: [
24118
- {
24119
- pattern: RegExp(
24120
- [
24121
- // r"", x""
24122
- /\b[rx]"(?:\\[\s\S]|[^\\"])*"[cwd]?/.source, // q"[]", q"()", q"<>", q"{}"
24123
- /\bq"(?:\[[\s\S]*?\]|\([\s\S]*?\)|<[\s\S]*?>|\{[\s\S]*?\})"/.source, // q"IDENT
24124
- // ...
24125
- // IDENT"
24126
- /\bq"((?!\d)\w+)$[\s\S]*?^\1"/.source, // q"//", q"||", etc.
24127
- // eslint-disable-next-line regexp/strict
24128
- /\bq"(.)[\s\S]*?\2"/.source, // eslint-disable-next-line regexp/strict
24129
- /(["`])(?:\\[\s\S]|(?!\3)[^\\])*\3[cwd]?/.source
24130
- ].join('|'),
24131
- 'm'
24132
- ),
24133
- greedy: true
24134
- },
24135
- {
24136
- pattern: /\bq\{(?:\{[^{}]*\}|[^{}])*\}/,
24137
- greedy: true,
24138
- alias: 'token-string'
24139
- }
24140
- ],
24141
- // In order: $, keywords and special tokens, globally defined symbols
24142
- keyword:
24143
- /\$|\b(?:__(?:(?:DATE|EOF|FILE|FUNCTION|LINE|MODULE|PRETTY_FUNCTION|TIMESTAMP|TIME|VENDOR|VERSION)__|gshared|parameters|traits|vector)|abstract|alias|align|asm|assert|auto|body|bool|break|byte|case|cast|catch|cdouble|cent|cfloat|char|class|const|continue|creal|dchar|debug|default|delegate|delete|deprecated|do|double|dstring|else|enum|export|extern|false|final|finally|float|for|foreach|foreach_reverse|function|goto|idouble|if|ifloat|immutable|import|inout|int|interface|invariant|ireal|lazy|long|macro|mixin|module|new|nothrow|null|out|override|package|pragma|private|protected|ptrdiff_t|public|pure|real|ref|return|scope|shared|short|size_t|static|string|struct|super|switch|synchronized|template|this|throw|true|try|typedef|typeid|typeof|ubyte|ucent|uint|ulong|union|unittest|ushort|version|void|volatile|wchar|while|with|wstring)\b/,
24144
- number: [
24145
- // The lookbehind and the negative look-ahead try to prevent bad highlighting of the .. operator
24146
- // Hexadecimal numbers must be handled separately to avoid problems with exponent "e"
24147
- /\b0x\.?[a-f\d_]+(?:(?!\.\.)\.[a-f\d_]*)?(?:p[+-]?[a-f\d_]+)?[ulfi]{0,4}/i,
24148
- {
24149
- pattern:
24150
- /((?:\.\.)?)(?:\b0b\.?|\b|\.)\d[\d_]*(?:(?!\.\.)\.[\d_]*)?(?:e[+-]?\d[\d_]*)?[ulfi]{0,4}/i,
24151
- lookbehind: true
24152
- }
24153
- ],
24154
- operator:
24155
- /\|[|=]?|&[&=]?|\+[+=]?|-[-=]?|\.?\.\.|=[>=]?|!(?:i[ns]\b|<>?=?|>=?|=)?|\bi[ns]\b|(?:<[<>]?|>>?>?|\^\^|[*\/%^~])=?/
24156
- });
24157
- Prism.languages.insertBefore('d', 'string', {
24158
- // Characters
24159
- // 'a', '\\', '\n', '\xFF', '\377', '\uFFFF', '\U0010FFFF', '\quot'
24160
- char: /'(?:\\(?:\W|\w+)|[^\\])'/
24161
- });
24162
- Prism.languages.insertBefore('d', 'keyword', {
24163
- property: /\B@\w*/
24164
- });
24165
- Prism.languages.insertBefore('d', 'function', {
24166
- register: {
24167
- // Iasm registers
24168
- pattern:
24169
- /\b(?:[ABCD][LHX]|E?(?:BP|DI|SI|SP)|[BS]PL|[ECSDGF]S|CR[0234]|[DS]IL|DR[012367]|E[ABCD]X|X?MM[0-7]|R(?:1[0-5]|[89])[BWD]?|R[ABCD]X|R[BS]P|R[DS]I|TR[3-7]|XMM(?:1[0-5]|[89])|YMM(?:1[0-5]|\d))\b|\bST(?:\([0-7]\)|\b)/,
24170
- alias: 'variable'
24171
- }
24172
- });
24173
- }
24174
- return d_1;
23968
+ var d_1 = d;
23969
+ d.displayName = 'd';
23970
+ d.aliases = [];
23971
+ function d(Prism) {
23972
+ Prism.languages.d = Prism.languages.extend('clike', {
23973
+ comment: [
23974
+ {
23975
+ // Shebang
23976
+ pattern: /^\s*#!.+/,
23977
+ greedy: true
23978
+ },
23979
+ {
23980
+ pattern: RegExp(
23981
+ /(^|[^\\])/.source +
23982
+ '(?:' +
23983
+ [
23984
+ // /+ comment +/
23985
+ // Allow one level of nesting
23986
+ /\/\+(?:\/\+(?:[^+]|\+(?!\/))*\+\/|(?!\/\+)[\s\S])*?\+\//.source, // // comment
23987
+ /\/\/.*/.source, // /* comment */
23988
+ /\/\*[\s\S]*?\*\//.source
23989
+ ].join('|') +
23990
+ ')'
23991
+ ),
23992
+ lookbehind: true,
23993
+ greedy: true
23994
+ }
23995
+ ],
23996
+ string: [
23997
+ {
23998
+ pattern: RegExp(
23999
+ [
24000
+ // r"", x""
24001
+ /\b[rx]"(?:\\[\s\S]|[^\\"])*"[cwd]?/.source, // q"[]", q"()", q"<>", q"{}"
24002
+ /\bq"(?:\[[\s\S]*?\]|\([\s\S]*?\)|<[\s\S]*?>|\{[\s\S]*?\})"/.source, // q"IDENT
24003
+ // ...
24004
+ // IDENT"
24005
+ /\bq"((?!\d)\w+)$[\s\S]*?^\1"/.source, // q"//", q"||", etc.
24006
+ // eslint-disable-next-line regexp/strict
24007
+ /\bq"(.)[\s\S]*?\2"/.source, // eslint-disable-next-line regexp/strict
24008
+ /(["`])(?:\\[\s\S]|(?!\3)[^\\])*\3[cwd]?/.source
24009
+ ].join('|'),
24010
+ 'm'
24011
+ ),
24012
+ greedy: true
24013
+ },
24014
+ {
24015
+ pattern: /\bq\{(?:\{[^{}]*\}|[^{}])*\}/,
24016
+ greedy: true,
24017
+ alias: 'token-string'
24018
+ }
24019
+ ],
24020
+ // In order: $, keywords and special tokens, globally defined symbols
24021
+ keyword:
24022
+ /\$|\b(?:__(?:(?:DATE|EOF|FILE|FUNCTION|LINE|MODULE|PRETTY_FUNCTION|TIMESTAMP|TIME|VENDOR|VERSION)__|gshared|parameters|traits|vector)|abstract|alias|align|asm|assert|auto|body|bool|break|byte|case|cast|catch|cdouble|cent|cfloat|char|class|const|continue|creal|dchar|debug|default|delegate|delete|deprecated|do|double|dstring|else|enum|export|extern|false|final|finally|float|for|foreach|foreach_reverse|function|goto|idouble|if|ifloat|immutable|import|inout|int|interface|invariant|ireal|lazy|long|macro|mixin|module|new|nothrow|null|out|override|package|pragma|private|protected|ptrdiff_t|public|pure|real|ref|return|scope|shared|short|size_t|static|string|struct|super|switch|synchronized|template|this|throw|true|try|typedef|typeid|typeof|ubyte|ucent|uint|ulong|union|unittest|ushort|version|void|volatile|wchar|while|with|wstring)\b/,
24023
+ number: [
24024
+ // The lookbehind and the negative look-ahead try to prevent bad highlighting of the .. operator
24025
+ // Hexadecimal numbers must be handled separately to avoid problems with exponent "e"
24026
+ /\b0x\.?[a-f\d_]+(?:(?!\.\.)\.[a-f\d_]*)?(?:p[+-]?[a-f\d_]+)?[ulfi]{0,4}/i,
24027
+ {
24028
+ pattern:
24029
+ /((?:\.\.)?)(?:\b0b\.?|\b|\.)\d[\d_]*(?:(?!\.\.)\.[\d_]*)?(?:e[+-]?\d[\d_]*)?[ulfi]{0,4}/i,
24030
+ lookbehind: true
24031
+ }
24032
+ ],
24033
+ operator:
24034
+ /\|[|=]?|&[&=]?|\+[+=]?|-[-=]?|\.?\.\.|=[>=]?|!(?:i[ns]\b|<>?=?|>=?|=)?|\bi[ns]\b|(?:<[<>]?|>>?>?|\^\^|[*\/%^~])=?/
24035
+ });
24036
+ Prism.languages.insertBefore('d', 'string', {
24037
+ // Characters
24038
+ // 'a', '\\', '\n', '\xFF', '\377', '\uFFFF', '\U0010FFFF', '\quot'
24039
+ char: /'(?:\\(?:\W|\w+)|[^\\])'/
24040
+ });
24041
+ Prism.languages.insertBefore('d', 'keyword', {
24042
+ property: /\B@\w*/
24043
+ });
24044
+ Prism.languages.insertBefore('d', 'function', {
24045
+ register: {
24046
+ // Iasm registers
24047
+ pattern:
24048
+ /\b(?:[ABCD][LHX]|E?(?:BP|DI|SI|SP)|[BS]PL|[ECSDGF]S|CR[0234]|[DS]IL|DR[012367]|E[ABCD]X|X?MM[0-7]|R(?:1[0-5]|[89])[BWD]?|R[ABCD]X|R[BS]P|R[DS]I|TR[3-7]|XMM(?:1[0-5]|[89])|YMM(?:1[0-5]|\d))\b|\bST(?:\([0-7]\)|\b)/,
24049
+ alias: 'variable'
24050
+ }
24051
+ });
24175
24052
  }
24176
24053
 
24177
24054
  var dart_1;
@@ -25344,7 +25221,7 @@ var hasRequiredErb;
25344
25221
  function requireErb () {
25345
25222
  if (hasRequiredErb) return erb_1;
25346
25223
  hasRequiredErb = 1;
25347
- var refractorRuby = requireRuby();
25224
+ var refractorRuby = ruby_1;
25348
25225
  var refractorMarkupTemplating = requireMarkupTemplating();
25349
25226
  erb_1 = erb;
25350
25227
  erb.displayName = 'erb';
@@ -27826,7 +27703,7 @@ var hasRequiredHaml;
27826
27703
  function requireHaml () {
27827
27704
  if (hasRequiredHaml) return haml_1;
27828
27705
  hasRequiredHaml = 1;
27829
- var refractorRuby = requireRuby();
27706
+ var refractorRuby = ruby_1;
27830
27707
  haml_1 = haml;
27831
27708
  haml.displayName = 'haml';
27832
27709
  haml.aliases = [];
@@ -40262,7 +40139,7 @@ function requireT4Cs () {
40262
40139
  if (hasRequiredT4Cs) return t4Cs_1;
40263
40140
  hasRequiredT4Cs = 1;
40264
40141
  var refractorT4Templating = requireT4Templating();
40265
- var refractorCsharp = requireCsharp();
40142
+ var refractorCsharp = csharp_1;
40266
40143
  t4Cs_1 = t4Cs;
40267
40144
  t4Cs.displayName = 't4Cs';
40268
40145
  t4Cs.aliases = [];
@@ -43038,20 +42915,20 @@ refractor.register(cfscript_1);
43038
42915
  refractor.register(chaiscript_1);
43039
42916
  refractor.register(cil_1);
43040
42917
  refractor.register(clojure_1);
43041
- refractor.register(requireCmake());
42918
+ refractor.register(cmake_1);
43042
42919
  refractor.register(cobol_1);
43043
- refractor.register(requireCoffeescript());
43044
- refractor.register(requireConcurnas());
43045
- refractor.register(requireCoq());
43046
- refractor.register(requireCpp());
43047
- refractor.register(requireCrystal());
43048
- refractor.register(requireCsharp());
43049
- refractor.register(requireCshtml());
43050
- refractor.register(requireCsp());
43051
- refractor.register(requireCssExtras());
43052
- refractor.register(requireCsv());
43053
- refractor.register(requireCypher());
43054
- refractor.register(requireD());
42920
+ refractor.register(coffeescript_1);
42921
+ refractor.register(concurnas_1);
42922
+ refractor.register(coq_1);
42923
+ refractor.register(cpp_1);
42924
+ refractor.register(crystal_1);
42925
+ refractor.register(csharp_1);
42926
+ refractor.register(cshtml_1);
42927
+ refractor.register(csp_1);
42928
+ refractor.register(cssExtras_1);
42929
+ refractor.register(csv_1);
42930
+ refractor.register(cypher_1);
42931
+ refractor.register(d_1);
43055
42932
  refractor.register(requireDart());
43056
42933
  refractor.register(requireDataweave());
43057
42934
  refractor.register(requireDax());
@@ -43210,7 +43087,7 @@ refractor.register(requireRest());
43210
43087
  refractor.register(requireRip());
43211
43088
  refractor.register(requireRoboconf());
43212
43089
  refractor.register(requireRobotframework());
43213
- refractor.register(requireRuby());
43090
+ refractor.register(ruby_1);
43214
43091
  refractor.register(requireRust());
43215
43092
  refractor.register(requireSas());
43216
43093
  refractor.register(requireSass());
@@ -46031,7 +45908,7 @@ var Calender = function Calender(props) {
46031
45908
  }));
46032
45909
  setSelectedMonth({
46033
45910
  month: _selectedDayInfo3.month,
46034
- monthAsNumber: MONTHS[_selectedDayInfo3.month],
45911
+ monthAsNumber: _selectedDayInfo3.monthAsNumber,
46035
45912
  year: _selectedDayInfo3.year
46036
45913
  });
46037
45914
  }
@@ -47612,8 +47489,8 @@ TableCell.defaultProps = _objectSpread2(_objectSpread2({}, BaseCell.defaultProps
47612
47489
  onSort: function onSort() {}
47613
47490
  });
47614
47491
 
47615
- var css$x = ".TableRow_module_root__f4710f2d {\n display: flex;\n flex-direction: row;\n justify-content: flex-start;\n align-items: center;\n}\n.TableRow_module_root__f4710f2d.TableRow_module_headerRow__f4710f2d {\n background: var(--grey6);\n}\n.TableRow_module_root__f4710f2d.TableRow_module_headerRow__f4710f2d > [data-elem=base-cell].TableRow_module_expandableCell__f4710f2d {\n background: transparent;\n}\n.TableRow_module_root__f4710f2d.TableRow_module_headerRow__f4710f2d > [data-elem=base-cell].TableRow_module_expandableCell__f4710f2d > [data-elem=component2] {\n width: 3rem;\n visibility: hidden;\n}\n.TableRow_module_root__f4710f2d.TableRow_module_bodyRow__f4710f2d {\n background: var(--white);\n}\n.TableRow_module_root__f4710f2d.TableRow_module_bodyRow__f4710f2d:hover > [data-elem=base-cell] {\n background: var(--info-bg);\n}\n.TableRow_module_root__f4710f2d.TableRow_module_bodyRow__f4710f2d[data-active=true] > [data-elem=base-cell] {\n background: var(--background);\n}\n.TableRow_module_root__f4710f2d > [data-elem=base-cell]:first-child {\n padding-left: 1rem;\n}\n.TableRow_module_root__f4710f2d > [data-elem=base-cell]:last-child {\n padding-right: 1rem;\n}\n.TableRow_module_root__f4710f2d.TableRow_module_rowHeightMd__f4710f2d > td[data-elem=base-cell] {\n height: 3rem;\n}\n.TableRow_module_root__f4710f2d.TableRow_module_rowHeightLg__f4710f2d > td[data-elem=base-cell] {\n height: 4rem;\n}\n.TableRow_module_root__f4710f2d > [data-elem=base-cell].TableRow_module_expandableCell__f4710f2d {\n padding-left: 0.9rem;\n padding-right: 0.1rem;\n overflow: visible;\n}\n.TableRow_module_root__f4710f2d > [data-elem=base-cell].TableRow_module_expandableCell__f4710f2d > [data-elem=component2] {\n overflow: visible;\n}\n.TableRow_module_root__f4710f2d > [data-elem=base-cell].TableRow_module_expandableCell__f4710f2d > [data-elem=component2] > [data-elem=text] {\n overflow: visible;\n}\n.TableRow_module_root__f4710f2d button.TableRow_module_button__f4710f2d[data-elem=base-cell] .TableRow_module_icon__f4710f2d {\n width: 1.5rem;\n height: 1.5rem;\n}\n.TableRow_module_root__f4710f2d button.TableRow_module_button__f4710f2d[data-elem=base-cell]:disabled {\n cursor: default;\n}\n.TableRow_module_root__f4710f2d button.TableRow_module_button__f4710f2d[data-elem=base-cell]:disabled .TableRow_module_icon__f4710f2d {\n visibility: hidden;\n}\n.TableRow_module_root__f4710f2d .TableRow_module_expanded__f4710f2d .TableRow_module_button__f4710f2d .TableRow_module_icon__f4710f2d {\n transform: rotate(180deg);\n}";
47616
- var modules_f6618a87 = {"root":"TableRow_module_root__f4710f2d","header-row":"TableRow_module_headerRow__f4710f2d","expandable-cell":"TableRow_module_expandableCell__f4710f2d","body-row":"TableRow_module_bodyRow__f4710f2d","row-height-md":"TableRow_module_rowHeightMd__f4710f2d","row-height-lg":"TableRow_module_rowHeightLg__f4710f2d","button":"TableRow_module_button__f4710f2d","icon":"TableRow_module_icon__f4710f2d","expanded":"TableRow_module_expanded__f4710f2d"};
47492
+ var css$x = ".TableRow_module_root__56f50f2c {\n display: flex;\n flex-direction: row;\n justify-content: flex-start;\n align-items: center;\n}\n.TableRow_module_root__56f50f2c.TableRow_module_headerRow__56f50f2c {\n background: var(--grey6);\n}\n.TableRow_module_root__56f50f2c.TableRow_module_headerRow__56f50f2c > [data-elem=base-cell].TableRow_module_expandableCell__56f50f2c {\n background: transparent;\n}\n.TableRow_module_root__56f50f2c.TableRow_module_headerRow__56f50f2c > [data-elem=base-cell].TableRow_module_expandableCell__56f50f2c > [data-elem=component2] {\n width: 3rem;\n visibility: hidden;\n}\n.TableRow_module_root__56f50f2c.TableRow_module_bodyRow__56f50f2c {\n background: var(--white);\n}\n.TableRow_module_root__56f50f2c.TableRow_module_bodyRow__56f50f2c > [data-elem=base-cell] {\n background: var(--white);\n}\n.TableRow_module_root__56f50f2c.TableRow_module_bodyRow__56f50f2c:hover > [data-elem=base-cell] {\n background: var(--info-bg);\n}\n.TableRow_module_root__56f50f2c.TableRow_module_bodyRow__56f50f2c[data-active=true] > [data-elem=base-cell] {\n background: var(--background);\n}\n.TableRow_module_root__56f50f2c > [data-elem=base-cell]:first-child {\n padding-left: 1rem;\n}\n.TableRow_module_root__56f50f2c > [data-elem=base-cell]:last-child {\n padding-right: 1rem;\n}\n.TableRow_module_root__56f50f2c.TableRow_module_rowHeightMd__56f50f2c > td[data-elem=base-cell] {\n height: 3rem;\n}\n.TableRow_module_root__56f50f2c.TableRow_module_rowHeightLg__56f50f2c > td[data-elem=base-cell] {\n height: 4rem;\n}\n.TableRow_module_root__56f50f2c > [data-elem=base-cell].TableRow_module_expandableCell__56f50f2c {\n padding-left: 0.9rem;\n padding-right: 0.1rem;\n overflow: visible;\n}\n.TableRow_module_root__56f50f2c > [data-elem=base-cell].TableRow_module_expandableCell__56f50f2c > [data-elem=component2] {\n overflow: visible;\n}\n.TableRow_module_root__56f50f2c > [data-elem=base-cell].TableRow_module_expandableCell__56f50f2c > [data-elem=component2] > [data-elem=text] {\n overflow: visible;\n}\n.TableRow_module_root__56f50f2c button.TableRow_module_button__56f50f2c[data-elem=base-cell] .TableRow_module_icon__56f50f2c {\n width: 1.5rem;\n height: 1.5rem;\n}\n.TableRow_module_root__56f50f2c button.TableRow_module_button__56f50f2c[data-elem=base-cell]:disabled {\n cursor: default;\n}\n.TableRow_module_root__56f50f2c button.TableRow_module_button__56f50f2c[data-elem=base-cell]:disabled .TableRow_module_icon__56f50f2c {\n visibility: hidden;\n}\n.TableRow_module_root__56f50f2c .TableRow_module_expanded__56f50f2c .TableRow_module_button__56f50f2c .TableRow_module_icon__56f50f2c {\n transform: rotate(180deg);\n}";
47493
+ var modules_f6618a87 = {"root":"TableRow_module_root__56f50f2c","header-row":"TableRow_module_headerRow__56f50f2c","expandable-cell":"TableRow_module_expandableCell__56f50f2c","body-row":"TableRow_module_bodyRow__56f50f2c","row-height-md":"TableRow_module_rowHeightMd__56f50f2c","row-height-lg":"TableRow_module_rowHeightLg__56f50f2c","button":"TableRow_module_button__56f50f2c","icon":"TableRow_module_icon__56f50f2c","expanded":"TableRow_module_expanded__56f50f2c"};
47617
47494
  n(css$x,{});
47618
47495
 
47619
47496
  var TableRow = /*#__PURE__*/forwardRef(function BaseTable(props, ref) {
@@ -47632,6 +47509,19 @@ var TableRow = /*#__PURE__*/forwardRef(function BaseTable(props, ref) {
47632
47509
  _useState2 = _slicedToArray(_useState, 2),
47633
47510
  expanded = _useState2[0],
47634
47511
  setExpanded = _useState2[1];
47512
+ var expandableProps = Expandable ? {
47513
+ _expanded: expanded,
47514
+ _setExpanded: setExpanded,
47515
+ disabled: !Expandable({
47516
+ datum: datum,
47517
+ index: _index
47518
+ }),
47519
+ onClick: function onClick() {
47520
+ setExpanded(function (prev) {
47521
+ return !prev;
47522
+ });
47523
+ }
47524
+ } : {};
47635
47525
  var tableCells = headerData === null || headerData === void 0 ? void 0 : (_headerData$map = headerData.map) === null || _headerData$map === void 0 ? void 0 : _headerData$map.call(headerData, function (item) {
47636
47526
  var _getCustomCell;
47637
47527
  var cellContent = null;
@@ -47642,6 +47532,7 @@ var TableRow = /*#__PURE__*/forwardRef(function BaseTable(props, ref) {
47642
47532
  }
47643
47533
  var cellProps = _objectSpread2(_objectSpread2(_objectSpread2({}, props), item), {}, {
47644
47534
  _index: _index,
47535
+ expandableProps: expandableProps,
47645
47536
  setActiveId: setActiveId,
47646
47537
  key: item.id,
47647
47538
  datum: datum,
@@ -47664,38 +47555,12 @@ var TableRow = /*#__PURE__*/forwardRef(function BaseTable(props, ref) {
47664
47555
  );
47665
47556
  });
47666
47557
  return /*#__PURE__*/jsxs(Fragment, {
47667
- children: [/*#__PURE__*/jsxs("tr", {
47558
+ children: [/*#__PURE__*/jsx("tr", {
47668
47559
  ref: ref,
47669
47560
  tabIndex: -1,
47670
47561
  "data-elem": "table-row",
47671
- className: classes(className, modules_f6618a87.root, modules_f6618a87["".concat(type, "-row")], modules_f6618a87["row-height-".concat(rowHeight)], Expandable ? modules_f6618a87.expandable : ''),
47672
- children: [Expandable && type === 'header' && /*#__PURE__*/jsx(TableCell, {
47673
- className: classes(modules_f6618a87['expandable-cell'], expanded ? modules_f6618a87.expanded : ''),
47674
- size: "auto",
47675
- cellContent: null
47676
- }), Expandable && type === 'body' && /*#__PURE__*/jsx(TableCell, {
47677
- className: classes(modules_f6618a87['expandable-cell'], expanded ? modules_f6618a87.expanded : ''),
47678
- size: "auto",
47679
- cellContent: /*#__PURE__*/jsx(Button, {
47680
- className: modules_f6618a87.button,
47681
- size: "auto",
47682
- variant: "text",
47683
- disabled: !Expandable({
47684
- datum: datum,
47685
- index: _index
47686
- }),
47687
- onClick: function onClick() {
47688
- setExpanded(function (prev) {
47689
- return !prev;
47690
- });
47691
- },
47692
- leftComponent: function leftComponent() {
47693
- return /*#__PURE__*/jsx(Caret, {
47694
- className: modules_f6618a87.icon
47695
- });
47696
- }
47697
- })
47698
- }), tableCells]
47562
+ className: classes(className, modules_f6618a87.root, modules_f6618a87["".concat(type, "-row")], modules_f6618a87["row-height-".concat(rowHeight)]),
47563
+ children: tableCells
47699
47564
  }), Expandable && expanded && /*#__PURE__*/jsx("tr", {
47700
47565
  children: /*#__PURE__*/jsx(Expandable, {
47701
47566
  datum: datum,