react-ai-renderer 0.1.6 → 0.1.7

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
@@ -5753,126 +5753,134 @@ function c(Prism) {
5753
5753
  delete Prism.languages.c['boolean'];
5754
5754
  }
5755
5755
 
5756
- var refractorC$1 = c_1;
5757
- var cpp_1 = cpp;
5758
- cpp.displayName = 'cpp';
5759
- cpp.aliases = [];
5760
- function cpp(Prism) {
5761
- Prism.register(refractorC$1)
5762
- ;(function (Prism) {
5763
- var keyword =
5764
- /\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/;
5765
- var modName = /\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(
5766
- /<keyword>/g,
5767
- function () {
5768
- return keyword.source
5769
- }
5770
- );
5771
- Prism.languages.cpp = Prism.languages.extend('c', {
5772
- 'class-name': [
5773
- {
5774
- pattern: RegExp(
5775
- /(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(
5776
- /<keyword>/g,
5777
- function () {
5778
- return keyword.source
5779
- }
5780
- )
5781
- ),
5782
- lookbehind: true
5783
- }, // This is intended to capture the class name of method implementations like:
5784
- // void foo::bar() const {}
5785
- // However! The `foo` in the above example could also be a namespace, so we only capture the class name if
5786
- // it starts with an uppercase letter. This approximation should give decent results.
5787
- /\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/, // This will capture the class name before destructors like:
5788
- // Foo::~Foo() {}
5789
- /\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
5790
- // parameters, so it can't be a namespace (until C++ adds generic namespaces).
5791
- /\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/
5792
- ],
5793
- keyword: keyword,
5794
- number: {
5795
- pattern:
5796
- /(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,
5797
- greedy: true
5798
- },
5799
- operator:
5800
- />>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,
5801
- boolean: /\b(?:false|true)\b/
5802
- });
5803
- Prism.languages.insertBefore('cpp', 'string', {
5804
- module: {
5805
- // https://en.cppreference.com/w/cpp/language/modules
5806
- pattern: RegExp(
5807
- /(\b(?:import|module)\s+)/.source +
5808
- '(?:' + // header-name
5809
- /"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source +
5810
- '|' + // module name or partition or both
5811
- /<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(
5812
- /<mod-name>/g,
5813
- function () {
5814
- return modName
5815
- }
5816
- ) +
5817
- ')'
5818
- ),
5819
- lookbehind: true,
5820
- greedy: true,
5821
- inside: {
5822
- string: /^[<"][\s\S]+/,
5823
- operator: /:/,
5824
- punctuation: /\./
5825
- }
5826
- },
5827
- 'raw-string': {
5828
- pattern: /R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,
5829
- alias: 'string',
5830
- greedy: true
5831
- }
5832
- });
5833
- Prism.languages.insertBefore('cpp', 'keyword', {
5834
- 'generic-function': {
5835
- pattern: /\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,
5836
- inside: {
5837
- function: /^\w+/,
5838
- generic: {
5839
- pattern: /<[\s\S]+/,
5840
- alias: 'class-name',
5841
- inside: Prism.languages.cpp
5842
- }
5843
- }
5844
- }
5845
- });
5846
- Prism.languages.insertBefore('cpp', 'operator', {
5847
- 'double-colon': {
5848
- pattern: /::/,
5849
- alias: 'punctuation'
5850
- }
5851
- });
5852
- Prism.languages.insertBefore('cpp', 'class-name', {
5853
- // the base clause is an optional list of parent classes
5854
- // https://en.cppreference.com/w/cpp/language/class
5855
- 'base-clause': {
5856
- pattern:
5857
- /(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,
5858
- lookbehind: true,
5859
- greedy: true,
5860
- inside: Prism.languages.extend('cpp', {})
5861
- }
5862
- });
5863
- Prism.languages.insertBefore(
5864
- 'inside',
5865
- 'double-colon',
5866
- {
5867
- // All untokenized words that are not namespaces should be class names
5868
- 'class-name': /\b[a-z_]\w*\b(?!\s*::)/i
5869
- },
5870
- Prism.languages.cpp['base-clause']
5871
- );
5872
- })(Prism);
5756
+ var cpp_1;
5757
+ var hasRequiredCpp;
5758
+
5759
+ function requireCpp () {
5760
+ if (hasRequiredCpp) return cpp_1;
5761
+ hasRequiredCpp = 1;
5762
+ var refractorC = c_1;
5763
+ cpp_1 = cpp;
5764
+ cpp.displayName = 'cpp';
5765
+ cpp.aliases = [];
5766
+ function cpp(Prism) {
5767
+ Prism.register(refractorC)
5768
+ ;(function (Prism) {
5769
+ var keyword =
5770
+ /\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/;
5771
+ var modName = /\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(
5772
+ /<keyword>/g,
5773
+ function () {
5774
+ return keyword.source
5775
+ }
5776
+ );
5777
+ Prism.languages.cpp = Prism.languages.extend('c', {
5778
+ 'class-name': [
5779
+ {
5780
+ pattern: RegExp(
5781
+ /(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(
5782
+ /<keyword>/g,
5783
+ function () {
5784
+ return keyword.source
5785
+ }
5786
+ )
5787
+ ),
5788
+ lookbehind: true
5789
+ }, // This is intended to capture the class name of method implementations like:
5790
+ // void foo::bar() const {}
5791
+ // However! The `foo` in the above example could also be a namespace, so we only capture the class name if
5792
+ // it starts with an uppercase letter. This approximation should give decent results.
5793
+ /\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/, // This will capture the class name before destructors like:
5794
+ // Foo::~Foo() {}
5795
+ /\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
5796
+ // parameters, so it can't be a namespace (until C++ adds generic namespaces).
5797
+ /\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/
5798
+ ],
5799
+ keyword: keyword,
5800
+ number: {
5801
+ pattern:
5802
+ /(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,
5803
+ greedy: true
5804
+ },
5805
+ operator:
5806
+ />>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,
5807
+ boolean: /\b(?:false|true)\b/
5808
+ });
5809
+ Prism.languages.insertBefore('cpp', 'string', {
5810
+ module: {
5811
+ // https://en.cppreference.com/w/cpp/language/modules
5812
+ pattern: RegExp(
5813
+ /(\b(?:import|module)\s+)/.source +
5814
+ '(?:' + // header-name
5815
+ /"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source +
5816
+ '|' + // module name or partition or both
5817
+ /<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(
5818
+ /<mod-name>/g,
5819
+ function () {
5820
+ return modName
5821
+ }
5822
+ ) +
5823
+ ')'
5824
+ ),
5825
+ lookbehind: true,
5826
+ greedy: true,
5827
+ inside: {
5828
+ string: /^[<"][\s\S]+/,
5829
+ operator: /:/,
5830
+ punctuation: /\./
5831
+ }
5832
+ },
5833
+ 'raw-string': {
5834
+ pattern: /R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,
5835
+ alias: 'string',
5836
+ greedy: true
5837
+ }
5838
+ });
5839
+ Prism.languages.insertBefore('cpp', 'keyword', {
5840
+ 'generic-function': {
5841
+ pattern: /\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,
5842
+ inside: {
5843
+ function: /^\w+/,
5844
+ generic: {
5845
+ pattern: /<[\s\S]+/,
5846
+ alias: 'class-name',
5847
+ inside: Prism.languages.cpp
5848
+ }
5849
+ }
5850
+ }
5851
+ });
5852
+ Prism.languages.insertBefore('cpp', 'operator', {
5853
+ 'double-colon': {
5854
+ pattern: /::/,
5855
+ alias: 'punctuation'
5856
+ }
5857
+ });
5858
+ Prism.languages.insertBefore('cpp', 'class-name', {
5859
+ // the base clause is an optional list of parent classes
5860
+ // https://en.cppreference.com/w/cpp/language/class
5861
+ 'base-clause': {
5862
+ pattern:
5863
+ /(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,
5864
+ lookbehind: true,
5865
+ greedy: true,
5866
+ inside: Prism.languages.extend('cpp', {})
5867
+ }
5868
+ });
5869
+ Prism.languages.insertBefore(
5870
+ 'inside',
5871
+ 'double-colon',
5872
+ {
5873
+ // All untokenized words that are not namespaces should be class names
5874
+ 'class-name': /\b[a-z_]\w*\b(?!\s*::)/i
5875
+ },
5876
+ Prism.languages.cpp['base-clause']
5877
+ );
5878
+ })(Prism);
5879
+ }
5880
+ return cpp_1;
5873
5881
  }
5874
5882
 
5875
- var refractorCpp$1 = cpp_1;
5883
+ var refractorCpp$1 = requireCpp();
5876
5884
  var arduino_1 = arduino;
5877
5885
  arduino.displayName = 'arduino';
5878
5886
  arduino.aliases = ['ino'];
@@ -7873,7 +7881,7 @@ function cfscript(Prism) {
7873
7881
  Prism.languages.cfc = Prism.languages['cfscript'];
7874
7882
  }
7875
7883
 
7876
- var refractorCpp = cpp_1;
7884
+ var refractorCpp = requireCpp();
7877
7885
  var chaiscript_1 = chaiscript;
7878
7886
  chaiscript.displayName = 'chaiscript';
7879
7887
  chaiscript.aliases = [];
@@ -8993,64 +9001,64 @@ function cssExtras(Prism) {
8993
9001
  })(Prism);
8994
9002
  }
8995
9003
 
8996
- var csv_1 = csv;
8997
- csv.displayName = 'csv';
8998
- csv.aliases = [];
8999
- function csv(Prism) {
9000
- // https://tools.ietf.org/html/rfc4180
9001
- Prism.languages.csv = {
9002
- value: /[^\r\n,"]+|"(?:[^"]|"")*"(?!")/,
9003
- punctuation: /,/
9004
- };
9005
- }
9004
+ var csv_1;
9005
+ var hasRequiredCsv;
9006
9006
 
9007
- var cypher_1;
9008
- var hasRequiredCypher;
9007
+ function requireCsv () {
9008
+ if (hasRequiredCsv) return csv_1;
9009
+ hasRequiredCsv = 1;
9009
9010
 
9010
- function requireCypher () {
9011
- if (hasRequiredCypher) return cypher_1;
9012
- hasRequiredCypher = 1;
9013
-
9014
- cypher_1 = cypher;
9015
- cypher.displayName = 'cypher';
9016
- cypher.aliases = [];
9017
- function cypher(Prism) {
9018
- Prism.languages.cypher = {
9019
- // https://neo4j.com/docs/cypher-manual/current/syntax/comments/
9020
- comment: /\/\/.*/,
9021
- string: {
9022
- pattern: /"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/,
9023
- greedy: true
9024
- },
9025
- 'class-name': {
9026
- pattern: /(:\s*)(?:\w+|`(?:[^`\\\r\n])*`)(?=\s*[{):])/,
9027
- lookbehind: true,
9028
- greedy: true
9029
- },
9030
- relationship: {
9031
- pattern:
9032
- /(-\[\s*(?:\w+\s*|`(?:[^`\\\r\n])*`\s*)?:\s*|\|\s*:\s*)(?:\w+|`(?:[^`\\\r\n])*`)/,
9033
- lookbehind: true,
9034
- greedy: true,
9035
- alias: 'property'
9036
- },
9037
- identifier: {
9038
- pattern: /`(?:[^`\\\r\n])*`/,
9039
- greedy: true
9040
- },
9041
- variable: /\$\w+/,
9042
- // https://neo4j.com/docs/cypher-manual/current/syntax/reserved/
9043
- keyword:
9044
- /\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,
9045
- function: /\b\w+\b(?=\s*\()/,
9046
- boolean: /\b(?:false|null|true)\b/i,
9047
- number: /\b(?:0x[\da-fA-F]+|\d+(?:\.\d+)?(?:[eE][+-]?\d+)?)\b/,
9048
- // https://neo4j.com/docs/cypher-manual/current/syntax/operators/
9049
- operator: /:|<--?|--?>?|<>|=~?|[<>]=?|[+*/%^|]|\.\.\.?/,
9050
- punctuation: /[()[\]{},;.]/
9011
+ csv_1 = csv;
9012
+ csv.displayName = 'csv';
9013
+ csv.aliases = [];
9014
+ function csv(Prism) {
9015
+ // https://tools.ietf.org/html/rfc4180
9016
+ Prism.languages.csv = {
9017
+ value: /[^\r\n,"]+|"(?:[^"]|"")*"(?!")/,
9018
+ punctuation: /,/
9051
9019
  };
9052
9020
  }
9053
- return cypher_1;
9021
+ return csv_1;
9022
+ }
9023
+
9024
+ var cypher_1 = cypher;
9025
+ cypher.displayName = 'cypher';
9026
+ cypher.aliases = [];
9027
+ function cypher(Prism) {
9028
+ Prism.languages.cypher = {
9029
+ // https://neo4j.com/docs/cypher-manual/current/syntax/comments/
9030
+ comment: /\/\/.*/,
9031
+ string: {
9032
+ pattern: /"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/,
9033
+ greedy: true
9034
+ },
9035
+ 'class-name': {
9036
+ pattern: /(:\s*)(?:\w+|`(?:[^`\\\r\n])*`)(?=\s*[{):])/,
9037
+ lookbehind: true,
9038
+ greedy: true
9039
+ },
9040
+ relationship: {
9041
+ pattern:
9042
+ /(-\[\s*(?:\w+\s*|`(?:[^`\\\r\n])*`\s*)?:\s*|\|\s*:\s*)(?:\w+|`(?:[^`\\\r\n])*`)/,
9043
+ lookbehind: true,
9044
+ greedy: true,
9045
+ alias: 'property'
9046
+ },
9047
+ identifier: {
9048
+ pattern: /`(?:[^`\\\r\n])*`/,
9049
+ greedy: true
9050
+ },
9051
+ variable: /\$\w+/,
9052
+ // https://neo4j.com/docs/cypher-manual/current/syntax/reserved/
9053
+ keyword:
9054
+ /\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,
9055
+ function: /\b\w+\b(?=\s*\()/,
9056
+ boolean: /\b(?:false|null|true)\b/i,
9057
+ number: /\b(?:0x[\da-fA-F]+|\d+(?:\.\d+)?(?:[eE][+-]?\d+)?)\b/,
9058
+ // https://neo4j.com/docs/cypher-manual/current/syntax/operators/
9059
+ operator: /:|<--?|--?>?|<>|=~?|[<>]=?|[+*/%^|]|\.\.\.?/,
9060
+ punctuation: /[()[\]{},;.]/
9061
+ };
9054
9062
  }
9055
9063
 
9056
9064
  var d_1 = d;
@@ -9139,97 +9147,88 @@ function d(Prism) {
9139
9147
  });
9140
9148
  }
9141
9149
 
9142
- var dart_1;
9143
- var hasRequiredDart;
9144
-
9145
- function requireDart () {
9146
- if (hasRequiredDart) return dart_1;
9147
- hasRequiredDart = 1;
9148
-
9149
- dart_1 = dart;
9150
- dart.displayName = 'dart';
9151
- dart.aliases = [];
9152
- function dart(Prism) {
9150
+ var dart_1 = dart;
9151
+ dart.displayName = 'dart';
9152
+ dart.aliases = [];
9153
+ function dart(Prism) {
9153
9154
  (function (Prism) {
9154
- var keywords = [
9155
- /\b(?:async|sync|yield)\*/,
9156
- /\b(?:abstract|assert|async|await|break|case|catch|class|const|continue|covariant|default|deferred|do|dynamic|else|enum|export|extends|extension|external|factory|final|finally|for|get|hide|if|implements|import|in|interface|library|mixin|new|null|on|operator|part|rethrow|return|set|show|static|super|switch|sync|this|throw|try|typedef|var|void|while|with|yield)\b/
9157
- ]; // Handles named imports, such as http.Client
9158
- var packagePrefix = /(^|[^\w.])(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/
9159
- .source; // based on the dart naming conventions
9160
- var className = {
9161
- pattern: RegExp(packagePrefix + /[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),
9162
- lookbehind: true,
9163
- inside: {
9164
- namespace: {
9165
- pattern: /^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,
9166
- inside: {
9167
- punctuation: /\./
9168
- }
9169
- }
9170
- }
9171
- };
9172
- Prism.languages.dart = Prism.languages.extend('clike', {
9173
- 'class-name': [
9174
- className,
9175
- {
9176
- // variables and parameters
9177
- // this to support class names (or generic parameters) which do not contain a lower case letter (also works for methods)
9178
- pattern: RegExp(
9179
- packagePrefix + /[A-Z]\w*(?=\s+\w+\s*[;,=()])/.source
9180
- ),
9181
- lookbehind: true,
9182
- inside: className.inside
9183
- }
9184
- ],
9185
- keyword: keywords,
9186
- operator:
9187
- /\bis!|\b(?:as|is)\b|\+\+|--|&&|\|\||<<=?|>>=?|~(?:\/=?)?|[+\-*\/%&^|=!<>]=?|\?/
9188
- });
9189
- Prism.languages.insertBefore('dart', 'string', {
9190
- 'string-literal': {
9191
- pattern:
9192
- /r?(?:("""|''')[\s\S]*?\1|(["'])(?:\\.|(?!\2)[^\\\r\n])*\2(?!\2))/,
9193
- greedy: true,
9194
- inside: {
9195
- interpolation: {
9196
- pattern:
9197
- /((?:^|[^\\])(?:\\{2})*)\$(?:\w+|\{(?:[^{}]|\{[^{}]*\})*\})/,
9198
- lookbehind: true,
9199
- inside: {
9200
- punctuation: /^\$\{?|\}$/,
9201
- expression: {
9202
- pattern: /[\s\S]+/,
9203
- inside: Prism.languages.dart
9204
- }
9205
- }
9206
- },
9207
- string: /[\s\S]+/
9208
- }
9209
- },
9210
- string: undefined
9211
- });
9212
- Prism.languages.insertBefore('dart', 'class-name', {
9213
- metadata: {
9214
- pattern: /@\w+/,
9215
- alias: 'function'
9216
- }
9217
- });
9218
- Prism.languages.insertBefore('dart', 'class-name', {
9219
- generics: {
9220
- pattern:
9221
- /<(?:[\w\s,.&?]|<(?:[\w\s,.&?]|<(?:[\w\s,.&?]|<[\w\s,.&?]*>)*>)*>)*>/,
9222
- inside: {
9223
- 'class-name': className,
9224
- keyword: keywords,
9225
- punctuation: /[<>(),.:]/,
9226
- operator: /[?&|]/
9227
- }
9228
- }
9229
- });
9230
- })(Prism);
9231
- }
9232
- return dart_1;
9155
+ var keywords = [
9156
+ /\b(?:async|sync|yield)\*/,
9157
+ /\b(?:abstract|assert|async|await|break|case|catch|class|const|continue|covariant|default|deferred|do|dynamic|else|enum|export|extends|extension|external|factory|final|finally|for|get|hide|if|implements|import|in|interface|library|mixin|new|null|on|operator|part|rethrow|return|set|show|static|super|switch|sync|this|throw|try|typedef|var|void|while|with|yield)\b/
9158
+ ]; // Handles named imports, such as http.Client
9159
+ var packagePrefix = /(^|[^\w.])(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/
9160
+ .source; // based on the dart naming conventions
9161
+ var className = {
9162
+ pattern: RegExp(packagePrefix + /[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),
9163
+ lookbehind: true,
9164
+ inside: {
9165
+ namespace: {
9166
+ pattern: /^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,
9167
+ inside: {
9168
+ punctuation: /\./
9169
+ }
9170
+ }
9171
+ }
9172
+ };
9173
+ Prism.languages.dart = Prism.languages.extend('clike', {
9174
+ 'class-name': [
9175
+ className,
9176
+ {
9177
+ // variables and parameters
9178
+ // this to support class names (or generic parameters) which do not contain a lower case letter (also works for methods)
9179
+ pattern: RegExp(
9180
+ packagePrefix + /[A-Z]\w*(?=\s+\w+\s*[;,=()])/.source
9181
+ ),
9182
+ lookbehind: true,
9183
+ inside: className.inside
9184
+ }
9185
+ ],
9186
+ keyword: keywords,
9187
+ operator:
9188
+ /\bis!|\b(?:as|is)\b|\+\+|--|&&|\|\||<<=?|>>=?|~(?:\/=?)?|[+\-*\/%&^|=!<>]=?|\?/
9189
+ });
9190
+ Prism.languages.insertBefore('dart', 'string', {
9191
+ 'string-literal': {
9192
+ pattern:
9193
+ /r?(?:("""|''')[\s\S]*?\1|(["'])(?:\\.|(?!\2)[^\\\r\n])*\2(?!\2))/,
9194
+ greedy: true,
9195
+ inside: {
9196
+ interpolation: {
9197
+ pattern:
9198
+ /((?:^|[^\\])(?:\\{2})*)\$(?:\w+|\{(?:[^{}]|\{[^{}]*\})*\})/,
9199
+ lookbehind: true,
9200
+ inside: {
9201
+ punctuation: /^\$\{?|\}$/,
9202
+ expression: {
9203
+ pattern: /[\s\S]+/,
9204
+ inside: Prism.languages.dart
9205
+ }
9206
+ }
9207
+ },
9208
+ string: /[\s\S]+/
9209
+ }
9210
+ },
9211
+ string: undefined
9212
+ });
9213
+ Prism.languages.insertBefore('dart', 'class-name', {
9214
+ metadata: {
9215
+ pattern: /@\w+/,
9216
+ alias: 'function'
9217
+ }
9218
+ });
9219
+ Prism.languages.insertBefore('dart', 'class-name', {
9220
+ generics: {
9221
+ pattern:
9222
+ /<(?:[\w\s,.&?]|<(?:[\w\s,.&?]|<(?:[\w\s,.&?]|<[\w\s,.&?]*>)*>)*>)*>/,
9223
+ inside: {
9224
+ 'class-name': className,
9225
+ keyword: keywords,
9226
+ punctuation: /[<>(),.:]/,
9227
+ operator: /[?&|]/
9228
+ }
9229
+ }
9230
+ });
9231
+ })(Prism);
9233
9232
  }
9234
9233
 
9235
9234
  var dataweave_1 = dataweave;
@@ -9316,80 +9315,89 @@ function dax(Prism) {
9316
9315
  };
9317
9316
  }
9318
9317
 
9319
- var dhall_1 = dhall;
9320
- dhall.displayName = 'dhall';
9321
- dhall.aliases = [];
9322
- function dhall(Prism) {
9323
- // ABNF grammar:
9324
- // https://github.com/dhall-lang/dhall-lang/blob/master/standard/dhall.abnf
9325
- Prism.languages.dhall = {
9326
- // Multi-line comments can be nested. E.g. {- foo {- bar -} -}
9327
- // The multi-line pattern is essentially this:
9328
- // \{-(?:[^-{]|-(?!\})|\{(?!-)|<SELF>)*-\}
9329
- comment:
9330
- /--.*|\{-(?:[^-{]|-(?!\})|\{(?!-)|\{-(?:[^-{]|-(?!\})|\{(?!-))*-\})*-\}/,
9331
- string: {
9332
- pattern: /"(?:[^"\\]|\\.)*"|''(?:[^']|'(?!')|'''|''\$\{)*''(?!'|\$)/,
9333
- greedy: true,
9334
- inside: {
9335
- interpolation: {
9336
- pattern: /\$\{[^{}]*\}/,
9337
- inside: {
9338
- expression: {
9339
- pattern: /(^\$\{)[\s\S]+(?=\}$)/,
9340
- lookbehind: true,
9341
- alias: 'language-dhall',
9342
- inside: null // see blow
9343
- },
9344
- punctuation: /\$\{|\}/
9345
- }
9346
- }
9347
- }
9348
- },
9349
- label: {
9350
- pattern: /`[^`]*`/,
9351
- greedy: true
9352
- },
9353
- url: {
9354
- // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L596
9355
- pattern:
9356
- /\bhttps?:\/\/[\w.:%!$&'*+;=@~-]+(?:\/[\w.:%!$&'*+;=@~-]*)*(?:\?[/?\w.:%!$&'*+;=@~-]*)?/,
9357
- greedy: true
9358
- },
9359
- env: {
9360
- // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L661
9361
- pattern: /\benv:(?:(?!\d)\w+|"(?:[^"\\=]|\\.)*")/,
9362
- greedy: true,
9363
- inside: {
9364
- function: /^env/,
9365
- operator: /^:/,
9366
- variable: /[\s\S]+/
9367
- }
9368
- },
9369
- hash: {
9370
- // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L725
9371
- pattern: /\bsha256:[\da-fA-F]{64}\b/,
9372
- inside: {
9373
- function: /sha256/,
9374
- operator: /:/,
9375
- number: /[\da-fA-F]{64}/
9376
- }
9377
- },
9378
- // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L359
9379
- keyword:
9380
- /\b(?:as|assert|else|forall|if|in|let|merge|missing|then|toMap|using|with)\b|\u2200/,
9381
- builtin: /\b(?:None|Some)\b/,
9382
- boolean: /\b(?:False|True)\b/,
9383
- number:
9384
- /\bNaN\b|-?\bInfinity\b|[+-]?\b(?:0x[\da-fA-F]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)\b/,
9385
- operator:
9386
- /\/\\|\/\/\\\\|&&|\|\||===|[!=]=|\/\/|->|\+\+|::|[+*#@=:?<>|\\\u2227\u2a53\u2261\u2afd\u03bb\u2192]/,
9387
- punctuation: /\.\.|[{}\[\](),./]/,
9388
- // we'll just assume that every capital word left is a type name
9389
- 'class-name': /\b[A-Z]\w*\b/
9390
- };
9391
- Prism.languages.dhall.string.inside.interpolation.inside.expression.inside =
9392
- Prism.languages.dhall;
9318
+ var dhall_1;
9319
+ var hasRequiredDhall;
9320
+
9321
+ function requireDhall () {
9322
+ if (hasRequiredDhall) return dhall_1;
9323
+ hasRequiredDhall = 1;
9324
+
9325
+ dhall_1 = dhall;
9326
+ dhall.displayName = 'dhall';
9327
+ dhall.aliases = [];
9328
+ function dhall(Prism) {
9329
+ // ABNF grammar:
9330
+ // https://github.com/dhall-lang/dhall-lang/blob/master/standard/dhall.abnf
9331
+ Prism.languages.dhall = {
9332
+ // Multi-line comments can be nested. E.g. {- foo {- bar -} -}
9333
+ // The multi-line pattern is essentially this:
9334
+ // \{-(?:[^-{]|-(?!\})|\{(?!-)|<SELF>)*-\}
9335
+ comment:
9336
+ /--.*|\{-(?:[^-{]|-(?!\})|\{(?!-)|\{-(?:[^-{]|-(?!\})|\{(?!-))*-\})*-\}/,
9337
+ string: {
9338
+ pattern: /"(?:[^"\\]|\\.)*"|''(?:[^']|'(?!')|'''|''\$\{)*''(?!'|\$)/,
9339
+ greedy: true,
9340
+ inside: {
9341
+ interpolation: {
9342
+ pattern: /\$\{[^{}]*\}/,
9343
+ inside: {
9344
+ expression: {
9345
+ pattern: /(^\$\{)[\s\S]+(?=\}$)/,
9346
+ lookbehind: true,
9347
+ alias: 'language-dhall',
9348
+ inside: null // see blow
9349
+ },
9350
+ punctuation: /\$\{|\}/
9351
+ }
9352
+ }
9353
+ }
9354
+ },
9355
+ label: {
9356
+ pattern: /`[^`]*`/,
9357
+ greedy: true
9358
+ },
9359
+ url: {
9360
+ // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L596
9361
+ pattern:
9362
+ /\bhttps?:\/\/[\w.:%!$&'*+;=@~-]+(?:\/[\w.:%!$&'*+;=@~-]*)*(?:\?[/?\w.:%!$&'*+;=@~-]*)?/,
9363
+ greedy: true
9364
+ },
9365
+ env: {
9366
+ // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L661
9367
+ pattern: /\benv:(?:(?!\d)\w+|"(?:[^"\\=]|\\.)*")/,
9368
+ greedy: true,
9369
+ inside: {
9370
+ function: /^env/,
9371
+ operator: /^:/,
9372
+ variable: /[\s\S]+/
9373
+ }
9374
+ },
9375
+ hash: {
9376
+ // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L725
9377
+ pattern: /\bsha256:[\da-fA-F]{64}\b/,
9378
+ inside: {
9379
+ function: /sha256/,
9380
+ operator: /:/,
9381
+ number: /[\da-fA-F]{64}/
9382
+ }
9383
+ },
9384
+ // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L359
9385
+ keyword:
9386
+ /\b(?:as|assert|else|forall|if|in|let|merge|missing|then|toMap|using|with)\b|\u2200/,
9387
+ builtin: /\b(?:None|Some)\b/,
9388
+ boolean: /\b(?:False|True)\b/,
9389
+ number:
9390
+ /\bNaN\b|-?\bInfinity\b|[+-]?\b(?:0x[\da-fA-F]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)\b/,
9391
+ operator:
9392
+ /\/\\|\/\/\\\\|&&|\|\||===|[!=]=|\/\/|->|\+\+|::|[+*#@=:?<>|\\\u2227\u2a53\u2261\u2afd\u03bb\u2192]/,
9393
+ punctuation: /\.\.|[{}\[\](),./]/,
9394
+ // we'll just assume that every capital word left is a type name
9395
+ 'class-name': /\b[A-Z]\w*\b/
9396
+ };
9397
+ Prism.languages.dhall.string.inside.interpolation.inside.expression.inside =
9398
+ Prism.languages.dhall;
9399
+ }
9400
+ return dhall_1;
9393
9401
  }
9394
9402
 
9395
9403
  var diff_1 = diff;
@@ -9582,73 +9590,65 @@ function requireMarkupTemplating () {
9582
9590
  return markupTemplating_1;
9583
9591
  }
9584
9592
 
9585
- var django_1;
9586
- var hasRequiredDjango;
9587
-
9588
- function requireDjango () {
9589
- if (hasRequiredDjango) return django_1;
9590
- hasRequiredDjango = 1;
9591
- var refractorMarkupTemplating = requireMarkupTemplating();
9592
- django_1 = django;
9593
- django.displayName = 'django';
9594
- django.aliases = ['jinja2'];
9595
- function django(Prism) {
9596
- Prism.register(refractorMarkupTemplating)
9597
- // Django/Jinja2 syntax definition for Prism.js <http://prismjs.com> syntax highlighter.
9598
- // Mostly it works OK but can paint code incorrectly on complex html/template tag combinations.
9599
- ;(function (Prism) {
9600
- Prism.languages.django = {
9601
- comment: /^\{#[\s\S]*?#\}$/,
9602
- tag: {
9603
- pattern: /(^\{%[+-]?\s*)\w+/,
9604
- lookbehind: true,
9605
- alias: 'keyword'
9606
- },
9607
- delimiter: {
9608
- pattern: /^\{[{%][+-]?|[+-]?[}%]\}$/,
9609
- alias: 'punctuation'
9610
- },
9611
- string: {
9612
- pattern: /("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,
9613
- greedy: true
9614
- },
9615
- filter: {
9616
- pattern: /(\|)\w+/,
9617
- lookbehind: true,
9618
- alias: 'function'
9619
- },
9620
- test: {
9621
- pattern: /(\bis\s+(?:not\s+)?)(?!not\b)\w+/,
9622
- lookbehind: true,
9623
- alias: 'function'
9624
- },
9625
- function: /\b[a-z_]\w+(?=\s*\()/i,
9626
- keyword:
9627
- /\b(?:and|as|by|else|for|if|import|in|is|loop|not|or|recursive|with|without)\b/,
9628
- operator: /[-+%=]=?|!=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,
9629
- number: /\b\d+(?:\.\d+)?\b/,
9630
- boolean: /[Ff]alse|[Nn]one|[Tt]rue/,
9631
- variable: /\b\w+\b/,
9632
- punctuation: /[{}[\](),.:;]/
9633
- };
9634
- var pattern = /\{\{[\s\S]*?\}\}|\{%[\s\S]*?%\}|\{#[\s\S]*?#\}/g;
9635
- var markupTemplating = Prism.languages['markup-templating'];
9636
- Prism.hooks.add('before-tokenize', function (env) {
9637
- markupTemplating.buildPlaceholders(env, 'django', pattern);
9638
- });
9639
- Prism.hooks.add('after-tokenize', function (env) {
9640
- markupTemplating.tokenizePlaceholders(env, 'django');
9641
- }); // Add an Jinja2 alias
9642
- Prism.languages.jinja2 = Prism.languages.django;
9643
- Prism.hooks.add('before-tokenize', function (env) {
9644
- markupTemplating.buildPlaceholders(env, 'jinja2', pattern);
9645
- });
9646
- Prism.hooks.add('after-tokenize', function (env) {
9647
- markupTemplating.tokenizePlaceholders(env, 'jinja2');
9648
- });
9649
- })(Prism);
9650
- }
9651
- return django_1;
9593
+ var refractorMarkupTemplating$1 = requireMarkupTemplating();
9594
+ var django_1 = django;
9595
+ django.displayName = 'django';
9596
+ django.aliases = ['jinja2'];
9597
+ function django(Prism) {
9598
+ Prism.register(refractorMarkupTemplating$1)
9599
+ // Django/Jinja2 syntax definition for Prism.js <http://prismjs.com> syntax highlighter.
9600
+ // Mostly it works OK but can paint code incorrectly on complex html/template tag combinations.
9601
+ ;(function (Prism) {
9602
+ Prism.languages.django = {
9603
+ comment: /^\{#[\s\S]*?#\}$/,
9604
+ tag: {
9605
+ pattern: /(^\{%[+-]?\s*)\w+/,
9606
+ lookbehind: true,
9607
+ alias: 'keyword'
9608
+ },
9609
+ delimiter: {
9610
+ pattern: /^\{[{%][+-]?|[+-]?[}%]\}$/,
9611
+ alias: 'punctuation'
9612
+ },
9613
+ string: {
9614
+ pattern: /("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,
9615
+ greedy: true
9616
+ },
9617
+ filter: {
9618
+ pattern: /(\|)\w+/,
9619
+ lookbehind: true,
9620
+ alias: 'function'
9621
+ },
9622
+ test: {
9623
+ pattern: /(\bis\s+(?:not\s+)?)(?!not\b)\w+/,
9624
+ lookbehind: true,
9625
+ alias: 'function'
9626
+ },
9627
+ function: /\b[a-z_]\w+(?=\s*\()/i,
9628
+ keyword:
9629
+ /\b(?:and|as|by|else|for|if|import|in|is|loop|not|or|recursive|with|without)\b/,
9630
+ operator: /[-+%=]=?|!=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,
9631
+ number: /\b\d+(?:\.\d+)?\b/,
9632
+ boolean: /[Ff]alse|[Nn]one|[Tt]rue/,
9633
+ variable: /\b\w+\b/,
9634
+ punctuation: /[{}[\](),.:;]/
9635
+ };
9636
+ var pattern = /\{\{[\s\S]*?\}\}|\{%[\s\S]*?%\}|\{#[\s\S]*?#\}/g;
9637
+ var markupTemplating = Prism.languages['markup-templating'];
9638
+ Prism.hooks.add('before-tokenize', function (env) {
9639
+ markupTemplating.buildPlaceholders(env, 'django', pattern);
9640
+ });
9641
+ Prism.hooks.add('after-tokenize', function (env) {
9642
+ markupTemplating.tokenizePlaceholders(env, 'django');
9643
+ }); // Add an Jinja2 alias
9644
+ Prism.languages.jinja2 = Prism.languages.django;
9645
+ Prism.hooks.add('before-tokenize', function (env) {
9646
+ markupTemplating.buildPlaceholders(env, 'jinja2', pattern);
9647
+ });
9648
+ Prism.hooks.add('after-tokenize', function (env) {
9649
+ markupTemplating.tokenizePlaceholders(env, 'jinja2');
9650
+ });
9651
+ })(Prism);
9652
9652
  }
9653
9653
 
9654
9654
  var dnsZoneFile_1 = dnsZoneFile;
@@ -9930,37 +9930,46 @@ function requireEbnf () {
9930
9930
  return ebnf_1;
9931
9931
  }
9932
9932
 
9933
- var editorconfig_1 = editorconfig;
9934
- editorconfig.displayName = 'editorconfig';
9935
- editorconfig.aliases = [];
9936
- function editorconfig(Prism) {
9937
- Prism.languages.editorconfig = {
9938
- // https://editorconfig-specification.readthedocs.io
9939
- comment: /[;#].*/,
9940
- section: {
9941
- pattern: /(^[ \t]*)\[.+\]/m,
9942
- lookbehind: true,
9943
- alias: 'selector',
9944
- inside: {
9945
- regex: /\\\\[\[\]{},!?.*]/,
9946
- // Escape special characters with '\\'
9947
- operator: /[!?]|\.\.|\*{1,2}/,
9948
- punctuation: /[\[\]{},]/
9949
- }
9950
- },
9951
- key: {
9952
- pattern: /(^[ \t]*)[^\s=]+(?=[ \t]*=)/m,
9953
- lookbehind: true,
9954
- alias: 'attr-name'
9955
- },
9956
- value: {
9957
- pattern: /=.*/,
9958
- alias: 'attr-value',
9959
- inside: {
9960
- punctuation: /^=/
9961
- }
9962
- }
9963
- };
9933
+ var editorconfig_1;
9934
+ var hasRequiredEditorconfig;
9935
+
9936
+ function requireEditorconfig () {
9937
+ if (hasRequiredEditorconfig) return editorconfig_1;
9938
+ hasRequiredEditorconfig = 1;
9939
+
9940
+ editorconfig_1 = editorconfig;
9941
+ editorconfig.displayName = 'editorconfig';
9942
+ editorconfig.aliases = [];
9943
+ function editorconfig(Prism) {
9944
+ Prism.languages.editorconfig = {
9945
+ // https://editorconfig-specification.readthedocs.io
9946
+ comment: /[;#].*/,
9947
+ section: {
9948
+ pattern: /(^[ \t]*)\[.+\]/m,
9949
+ lookbehind: true,
9950
+ alias: 'selector',
9951
+ inside: {
9952
+ regex: /\\\\[\[\]{},!?.*]/,
9953
+ // Escape special characters with '\\'
9954
+ operator: /[!?]|\.\.|\*{1,2}/,
9955
+ punctuation: /[\[\]{},]/
9956
+ }
9957
+ },
9958
+ key: {
9959
+ pattern: /(^[ \t]*)[^\s=]+(?=[ \t]*=)/m,
9960
+ lookbehind: true,
9961
+ alias: 'attr-name'
9962
+ },
9963
+ value: {
9964
+ pattern: /=.*/,
9965
+ alias: 'attr-value',
9966
+ inside: {
9967
+ punctuation: /^=/
9968
+ }
9969
+ }
9970
+ };
9971
+ }
9972
+ return editorconfig_1;
9964
9973
  }
9965
9974
 
9966
9975
  var eiffel_1;
@@ -10010,45 +10019,37 @@ function requireEiffel () {
10010
10019
  return eiffel_1;
10011
10020
  }
10012
10021
 
10013
- var ejs_1;
10014
- var hasRequiredEjs;
10015
-
10016
- function requireEjs () {
10017
- if (hasRequiredEjs) return ejs_1;
10018
- hasRequiredEjs = 1;
10019
- var refractorMarkupTemplating = requireMarkupTemplating();
10020
- ejs_1 = ejs;
10021
- ejs.displayName = 'ejs';
10022
- ejs.aliases = ['eta'];
10023
- function ejs(Prism) {
10024
- Prism.register(refractorMarkupTemplating)
10025
- ;(function (Prism) {
10026
- Prism.languages.ejs = {
10027
- delimiter: {
10028
- pattern: /^<%[-_=]?|[-_]?%>$/,
10029
- alias: 'punctuation'
10030
- },
10031
- comment: /^#[\s\S]*/,
10032
- 'language-javascript': {
10033
- pattern: /[\s\S]+/,
10034
- inside: Prism.languages.javascript
10035
- }
10036
- };
10037
- Prism.hooks.add('before-tokenize', function (env) {
10038
- var ejsPattern = /<%(?!%)[\s\S]+?%>/g;
10039
- Prism.languages['markup-templating'].buildPlaceholders(
10040
- env,
10041
- 'ejs',
10042
- ejsPattern
10043
- );
10044
- });
10045
- Prism.hooks.add('after-tokenize', function (env) {
10046
- Prism.languages['markup-templating'].tokenizePlaceholders(env, 'ejs');
10047
- });
10048
- Prism.languages.eta = Prism.languages.ejs;
10049
- })(Prism);
10050
- }
10051
- return ejs_1;
10022
+ var refractorMarkupTemplating = requireMarkupTemplating();
10023
+ var ejs_1 = ejs;
10024
+ ejs.displayName = 'ejs';
10025
+ ejs.aliases = ['eta'];
10026
+ function ejs(Prism) {
10027
+ Prism.register(refractorMarkupTemplating)
10028
+ ;(function (Prism) {
10029
+ Prism.languages.ejs = {
10030
+ delimiter: {
10031
+ pattern: /^<%[-_=]?|[-_]?%>$/,
10032
+ alias: 'punctuation'
10033
+ },
10034
+ comment: /^#[\s\S]*/,
10035
+ 'language-javascript': {
10036
+ pattern: /[\s\S]+/,
10037
+ inside: Prism.languages.javascript
10038
+ }
10039
+ };
10040
+ Prism.hooks.add('before-tokenize', function (env) {
10041
+ var ejsPattern = /<%(?!%)[\s\S]+?%>/g;
10042
+ Prism.languages['markup-templating'].buildPlaceholders(
10043
+ env,
10044
+ 'ejs',
10045
+ ejsPattern
10046
+ );
10047
+ });
10048
+ Prism.hooks.add('after-tokenize', function (env) {
10049
+ Prism.languages['markup-templating'].tokenizePlaceholders(env, 'ejs');
10050
+ });
10051
+ Prism.languages.eta = Prism.languages.ejs;
10052
+ })(Prism);
10052
10053
  }
10053
10054
 
10054
10055
  var elixir_1;
@@ -27936,28 +27937,28 @@ refractor.register(cobol_1);
27936
27937
  refractor.register(coffeescript_1);
27937
27938
  refractor.register(concurnas_1);
27938
27939
  refractor.register(coq_1);
27939
- refractor.register(cpp_1);
27940
+ refractor.register(requireCpp());
27940
27941
  refractor.register(crystal_1);
27941
27942
  refractor.register(csharp_1);
27942
27943
  refractor.register(cshtml_1);
27943
27944
  refractor.register(csp_1);
27944
27945
  refractor.register(cssExtras_1);
27945
- refractor.register(csv_1);
27946
- refractor.register(requireCypher());
27946
+ refractor.register(requireCsv());
27947
+ refractor.register(cypher_1);
27947
27948
  refractor.register(d_1);
27948
- refractor.register(requireDart());
27949
+ refractor.register(dart_1);
27949
27950
  refractor.register(dataweave_1);
27950
27951
  refractor.register(dax_1);
27951
- refractor.register(dhall_1);
27952
+ refractor.register(requireDhall());
27952
27953
  refractor.register(diff_1);
27953
- refractor.register(requireDjango());
27954
+ refractor.register(django_1);
27954
27955
  refractor.register(dnsZoneFile_1);
27955
27956
  refractor.register(docker_1);
27956
27957
  refractor.register(dot_1);
27957
27958
  refractor.register(requireEbnf());
27958
- refractor.register(editorconfig_1);
27959
+ refractor.register(requireEditorconfig());
27959
27960
  refractor.register(requireEiffel());
27960
- refractor.register(requireEjs());
27961
+ refractor.register(ejs_1);
27961
27962
  refractor.register(requireElixir());
27962
27963
  refractor.register(requireElm());
27963
27964
  refractor.register(requireErb());
@@ -38934,6 +38935,18 @@ function escapeContentForStream(content) {
38934
38935
  }
38935
38936
 
38936
38937
  var renderTimer = null;
38938
+ /**
38939
+ * 预处理 MDX 内容,转义可能被误认为 HTML 标签的内容
38940
+ * @param content MDX 内容
38941
+ * @returns 处理后的内容
38942
+ */
38943
+ function preprocessMdxContent(content) {
38944
+ // 匹配可能被误认为 HTML 标签的模式,如 <数字、<字母但不是真正的组件标签
38945
+ // 真正的 React 组件标签应该以大写字母开头,如 <Component>
38946
+ // HTML 标签以小写字母开头,如 <div>
38947
+ // 需要排除正常的闭合标签 </Component>
38948
+ return content.replace(/<(?!\/|[A-Z][a-zA-Z]*\b|[a-z][a-zA-Z0-9]*\b)/g, '&lt;');
38949
+ }
38937
38950
  // 辅助函数:格式化props
38938
38951
  function formatProps(props) {
38939
38952
  return Object.entries(props).map(function (_a) {
@@ -38953,7 +38966,7 @@ function formatProps(props) {
38953
38966
  }
38954
38967
  function renderMdx(mdxContent, scope, registeredComponents) {
38955
38968
  return __awaiter(this, void 0, void 0, function () {
38956
- var componentTagRegex, usedComponents, match, vf, XComponent;
38969
+ var componentTagRegex, usedComponents, match, processedContent, vf, XComponent, e_1;
38957
38970
  return __generator(this, function (_a) {
38958
38971
  switch (_a.label) {
38959
38972
  case 0:
@@ -38965,7 +38978,8 @@ function renderMdx(mdxContent, scope, registeredComponents) {
38965
38978
  while ((match = componentTagRegex.exec(mdxContent)) !== null) {
38966
38979
  usedComponents.add(match[1]);
38967
38980
  }
38968
- return [4 /*yield*/, compile(mdxContent, {
38981
+ processedContent = preprocessMdxContent(mdxContent);
38982
+ return [4 /*yield*/, compile(processedContent, {
38969
38983
  outputFormat: "function-body",
38970
38984
  remarkPlugins: [[RemarkMath, {
38971
38985
  strict: true
@@ -38988,7 +39002,8 @@ function renderMdx(mdxContent, scope, registeredComponents) {
38988
39002
  scope: scope
38989
39003
  })];
38990
39004
  case 3:
38991
- _a.sent();
39005
+ e_1 = _a.sent();
39006
+ console.log(e_1, 'e');
38992
39007
  return [2 /*return*/, new Promise(function (resolve) {
38993
39008
  renderTimer = setTimeout(function () {
38994
39009
  resolve(/*#__PURE__*/React.createElement('div', {