@eluan/core 0.3.0 → 0.4.1

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.
Files changed (165) hide show
  1. package/README.md +23 -1
  2. package/dist/{action-popover-Bpf4SQLh.cjs → action-popover-CCRZyXVl.cjs} +1 -1
  3. package/dist/{action-popover-C8URIySO.js → action-popover-DUJjIthU.js} +2 -2
  4. package/dist/action-popover.cjs +1 -1
  5. package/dist/action-popover.js +1 -1
  6. package/dist/{avatar-BGtpKaIp.js → avatar-CS5f1irF.js} +1 -1
  7. package/dist/{avatar-h_saVZqK.cjs → avatar-Co-k8KqV.cjs} +1 -1
  8. package/dist/avatar.cjs +1 -1
  9. package/dist/avatar.js +1 -1
  10. package/dist/{badge-NIOPu08c.js → badge-D9NYZFWH.js} +0 -1
  11. package/dist/badge-DXKWztL-.cjs +1 -0
  12. package/dist/badge.cjs +1 -1
  13. package/dist/badge.js +1 -1
  14. package/dist/{breadcrumb-BvEmqspe.js → breadcrumb-Czu2XwgU.js} +2 -2
  15. package/dist/{breadcrumb-BndfpXpd.cjs → breadcrumb-D6_IoicI.cjs} +1 -1
  16. package/dist/breadcrumb.cjs +1 -1
  17. package/dist/breadcrumb.js +1 -1
  18. package/dist/{button-DnbBpYRD.js → button-ANAPDrvs.js} +10 -17
  19. package/dist/button-Ny6OF8Un.cjs +1 -0
  20. package/dist/button.cjs +1 -1
  21. package/dist/button.js +1 -1
  22. package/dist/{calendar-onOz6xAu.js → calendar-BUPsr0be.js} +2 -2
  23. package/dist/{calendar-BksOnK5M.cjs → calendar-Dd-Ud2zz.cjs} +1 -1
  24. package/dist/calendar.cjs +1 -1
  25. package/dist/calendar.js +1 -1
  26. package/dist/{carousel-Bt6UvkQ8.cjs → carousel-BfL7oy_q.cjs} +1 -1
  27. package/dist/{carousel-BXVJVj9A.js → carousel-DuP0hvF-.js} +1 -1
  28. package/dist/carousel.cjs +1 -1
  29. package/dist/carousel.js +1 -1
  30. package/dist/checkbox-Bi0Kmuut.js +10 -0
  31. package/dist/checkbox-M8DmWKiC.cjs +1 -0
  32. package/dist/{checkbox-group-B5UAuO0J.js → checkbox-group-CQMEJnhD.js} +1 -1
  33. package/dist/{checkbox-group-Dc1RAF3a.cjs → checkbox-group-KBwPhjmW.cjs} +1 -1
  34. package/dist/checkbox-group.cjs +1 -1
  35. package/dist/checkbox-group.js +1 -1
  36. package/dist/checkbox.cjs +1 -1
  37. package/dist/checkbox.js +1 -1
  38. package/dist/{code-block-3DZZzUKL.js → code-block-C9u140Ob.js} +354 -340
  39. package/dist/code-block-_dFw7Su1.cjs +2 -0
  40. package/dist/code-block.cjs +1 -1
  41. package/dist/code-block.js +1 -1
  42. package/dist/components/typography.d.ts +37 -0
  43. package/dist/{credit-card-input-C9XQgOxy.cjs → credit-card-input-CUqA9CX3.cjs} +1 -1
  44. package/dist/{credit-card-input-Cb6AsLGQ.js → credit-card-input-DN-8vaFj.js} +1 -1
  45. package/dist/credit-card-input.cjs +1 -1
  46. package/dist/credit-card-input.js +1 -1
  47. package/dist/{date-picker-Djsjwm-u.js → date-picker-CISIHHyU.js} +2 -2
  48. package/dist/{date-picker-BVv2YLs_.cjs → date-picker-K5GcZ_Li.cjs} +1 -1
  49. package/dist/date-picker.cjs +1 -1
  50. package/dist/date-picker.js +1 -1
  51. package/dist/{datetime-picker-y1NZjhHU.cjs → datetime-picker-CP_fhCA-.cjs} +1 -1
  52. package/dist/{datetime-picker-C61J5xlq.js → datetime-picker-zTrUj815.js} +3 -3
  53. package/dist/datetime-picker.cjs +1 -1
  54. package/dist/datetime-picker.js +1 -1
  55. package/dist/dropdown-menu-BtU3Yhar.cjs +1 -0
  56. package/dist/{dropdown-menu-Bt3ofX5-.js → dropdown-menu-CA2MpoMo.js} +32 -32
  57. package/dist/dropdown-menu.cjs +1 -1
  58. package/dist/dropdown-menu.js +1 -1
  59. package/dist/{email-input-BdHelX2L.cjs → email-input-DFI4h_KN.cjs} +1 -1
  60. package/dist/{email-input-2NVWxyYE.js → email-input-pX0hlYV3.js} +1 -1
  61. package/dist/email-input.cjs +1 -1
  62. package/dist/email-input.js +1 -1
  63. package/dist/{footer-BwnrDB4b.js → footer-B3KUIwXW.js} +1 -1
  64. package/dist/{footer-BRFOcyZi.cjs → footer-DB0_-IwN.cjs} +1 -1
  65. package/dist/footer.cjs +1 -1
  66. package/dist/footer.js +1 -1
  67. package/dist/{header-DaxcTBn2.js → header-BqNWcy93.js} +1 -1
  68. package/dist/{header-BuYMVFXu.cjs → header-Dg6y6pKR.cjs} +1 -1
  69. package/dist/header.cjs +1 -1
  70. package/dist/header.js +1 -1
  71. package/dist/index.cjs +5 -5
  72. package/dist/index.d.ts +2 -1
  73. package/dist/index.js +699 -449
  74. package/dist/input-BrGJn-D9.cjs +1 -0
  75. package/dist/{input-BB26lFHB.js → input-Cccufiqn.js} +0 -1
  76. package/dist/input.cjs +1 -1
  77. package/dist/input.js +1 -1
  78. package/dist/{multi-select-BbCvy9F4.js → multi-select-BM4Zxa3I.js} +1 -1
  79. package/dist/{multi-select-CGe9JXis.cjs → multi-select-FXNBRmwx.cjs} +1 -1
  80. package/dist/multi-select.cjs +1 -1
  81. package/dist/multi-select.js +1 -1
  82. package/dist/{navigation-drawer-BVyE88EB.js → navigation-drawer-C99JVOby.js} +1 -1
  83. package/dist/{navigation-drawer-CTUgzXW_.cjs → navigation-drawer-CVxS6X5J.cjs} +1 -1
  84. package/dist/navigation-drawer.cjs +1 -1
  85. package/dist/navigation-drawer.js +1 -1
  86. package/dist/{number-input-CSe8MPy0.cjs → number-input-Bc7jUsu-.cjs} +1 -1
  87. package/dist/{number-input-CdWJfr6M.js → number-input-vICbRc2y.js} +1 -1
  88. package/dist/number-input.cjs +1 -1
  89. package/dist/number-input.js +1 -1
  90. package/dist/{pagination-8tmdKm4b.cjs → pagination-CVZk8eCM.cjs} +1 -1
  91. package/dist/{pagination-BSIae9Rc.js → pagination-DhGezNeG.js} +2 -2
  92. package/dist/pagination.cjs +1 -1
  93. package/dist/pagination.js +1 -1
  94. package/dist/{password-input-Btz0Bnt-.js → password-input-B9V45d3Q.js} +1 -1
  95. package/dist/{password-input-Cp0hQd_Z.cjs → password-input-BwnlHPbX.cjs} +1 -1
  96. package/dist/password-input.cjs +1 -1
  97. package/dist/password-input.js +1 -1
  98. package/dist/{phone-input-CQ-VONKC.js → phone-input-COi21JIl.js} +2 -2
  99. package/dist/{phone-input-DTAr8VTY.cjs → phone-input-DXkhw_4A.cjs} +1 -1
  100. package/dist/phone-input.cjs +1 -1
  101. package/dist/phone-input.js +1 -1
  102. package/dist/providers/eluan-provider.d.ts +16 -2
  103. package/dist/{radio-group-DqrwDPd6.cjs → radio-group-C--1neiq.cjs} +1 -1
  104. package/dist/radio-group-CNMPZx_2.js +12 -0
  105. package/dist/radio-group.cjs +1 -1
  106. package/dist/radio-group.js +1 -1
  107. package/dist/{rich-text-CY0lbdka.js → rich-text-CuJJFeUV.js} +1 -1
  108. package/dist/{rich-text-VsCx-RMe.cjs → rich-text-uAtn5CZk.cjs} +1 -1
  109. package/dist/rich-text.cjs +1 -1
  110. package/dist/rich-text.js +1 -1
  111. package/dist/{search-input-C2F_NayM.cjs → search-input-BRf6r110.cjs} +1 -1
  112. package/dist/{search-input-DOcH68qN.js → search-input-DrO3-p4h.js} +1 -1
  113. package/dist/search-input.cjs +1 -1
  114. package/dist/search-input.js +1 -1
  115. package/dist/{select-DY67JirM.js → select-3GU6G3YF.js} +19 -19
  116. package/dist/select-CGLm4HTg.cjs +1 -0
  117. package/dist/select.cjs +1 -1
  118. package/dist/select.js +1 -1
  119. package/dist/slider-CZQBAXup.js +16 -0
  120. package/dist/slider-DdEOapYP.cjs +1 -0
  121. package/dist/slider.cjs +1 -1
  122. package/dist/slider.js +1 -1
  123. package/dist/styles.css +145 -129
  124. package/dist/switch-C7EBLT5H.js +9 -0
  125. package/dist/{switch-rRktfpbm.cjs → switch-KzBijHMJ.cjs} +1 -1
  126. package/dist/switch.cjs +1 -1
  127. package/dist/switch.js +1 -1
  128. package/dist/tabs-Bpm29QTI.cjs +1 -0
  129. package/dist/{tabs-fIOp55Me.js → tabs-DNkc9RO6.js} +9 -9
  130. package/dist/tabs.cjs +1 -1
  131. package/dist/tabs.js +1 -1
  132. package/dist/textarea-DXUk1b_-.js +8 -0
  133. package/dist/textarea-Dl-daLHR.cjs +1 -0
  134. package/dist/textarea.cjs +1 -1
  135. package/dist/textarea.js +1 -1
  136. package/dist/{time-input-eF_X9to1.js → time-input-BPoFvoeM.js} +1 -1
  137. package/dist/{time-input-CIDRBxQk.cjs → time-input-DR2snTgB.cjs} +1 -1
  138. package/dist/time-input.cjs +1 -1
  139. package/dist/time-input.js +1 -1
  140. package/dist/toggle-Bvh1v32T.cjs +1 -0
  141. package/dist/{toggle-f7Ym7n7Z.js → toggle-Dv1VZ5Le.js} +4 -6
  142. package/dist/{toggle-group-CAsy1xnG.js → toggle-group-DE8BPZih.js} +5 -7
  143. package/dist/toggle-group-SyHMwO90.cjs +1 -0
  144. package/dist/toggle-group.cjs +1 -1
  145. package/dist/toggle-group.js +1 -1
  146. package/dist/toggle.cjs +1 -1
  147. package/dist/toggle.js +1 -1
  148. package/package.json +7 -7
  149. package/dist/badge-BMgIAfSC.cjs +0 -1
  150. package/dist/button-CzuCIuTx.cjs +0 -1
  151. package/dist/checkbox--uuKohr3.js +0 -10
  152. package/dist/checkbox-C7YMv2nW.cjs +0 -1
  153. package/dist/code-block-DsJwW6oD.cjs +0 -2
  154. package/dist/dropdown-menu-CaLsHigj.cjs +0 -1
  155. package/dist/input-BT3Z4cef.cjs +0 -1
  156. package/dist/radio-group-DIPxpnMD.js +0 -12
  157. package/dist/select-DKjwZjvo.cjs +0 -1
  158. package/dist/slider-CXYJmfQw.cjs +0 -1
  159. package/dist/slider-Dlxdjxxz.js +0 -16
  160. package/dist/switch-D1UO68fj.js +0 -9
  161. package/dist/tabs-BlohGs-G.cjs +0 -1
  162. package/dist/textarea-C5AVV2Wr.cjs +0 -1
  163. package/dist/textarea-DZmGU7QE.js +0 -8
  164. package/dist/toggle-CSlk0ql9.cjs +0 -1
  165. package/dist/toggle-group-CrAyoUON.cjs +0 -1
@@ -1,9 +1,9 @@
1
1
  "use client";
2
- import { jsxs as I, jsx as f, Fragment as N } from "react/jsx-runtime";
2
+ import { jsxs as R, jsx as f, Fragment as N } from "react/jsx-runtime";
3
3
  import * as T from "react";
4
- import * as k from "@stylexjs/stylex";
4
+ import * as U from "@stylexjs/stylex";
5
5
  import y from "prismjs";
6
- import { Check as F, Copy as L } from "lucide-react";
6
+ import { Check as P, Copy as M } from "lucide-react";
7
7
  Prism.languages.javascript = Prism.languages.extend("clike", {
8
8
  "class-name": [
9
9
  Prism.languages.clike["class-name"],
@@ -141,51 +141,55 @@ Prism.languages.markup && (Prism.languages.markup.tag.addInlined("script", "java
141
141
  "javascript"
142
142
  ));
143
143
  Prism.languages.js = Prism.languages.javascript;
144
- (function(e) {
145
- e.languages.typescript = e.languages.extend("javascript", {
146
- "class-name": {
147
- pattern: /(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,
148
- lookbehind: !0,
149
- greedy: !0,
150
- inside: null
151
- // see below
152
- },
153
- builtin: /\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/
154
- }), e.languages.typescript.keyword.push(
155
- /\b(?:abstract|declare|is|keyof|readonly|require)\b/,
156
- // keywords that have to be followed by an identifier
157
- /\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,
158
- // This is for `import type *, {}`
159
- /\btype\b(?=\s*(?:[\{*]|$))/
160
- ), delete e.languages.typescript.parameter, delete e.languages.typescript["literal-property"];
161
- var n = e.languages.extend("typescript", {});
162
- delete n["class-name"], e.languages.typescript["class-name"].inside = n, e.languages.insertBefore("typescript", "function", {
163
- decorator: {
164
- pattern: /@[$\w\xA0-\uFFFF]+/,
165
- inside: {
166
- at: {
167
- pattern: /^@/,
168
- alias: "operator"
169
- },
170
- function: /^[\s\S]+/
171
- }
172
- },
173
- "generic-function": {
174
- // e.g. foo<T extends "bar" | "baz">( ...
175
- pattern: /#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,
176
- greedy: !0,
177
- inside: {
178
- function: /^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,
179
- generic: {
180
- pattern: /<[\s\S]+/,
181
- // everything after the first <
182
- alias: "class-name",
183
- inside: n
144
+ var O = {}, w;
145
+ function B() {
146
+ return w || (w = 1, (function(e) {
147
+ e.languages.typescript = e.languages.extend("javascript", {
148
+ "class-name": {
149
+ pattern: /(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,
150
+ lookbehind: !0,
151
+ greedy: !0,
152
+ inside: null
153
+ // see below
154
+ },
155
+ builtin: /\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/
156
+ }), e.languages.typescript.keyword.push(
157
+ /\b(?:abstract|declare|is|keyof|readonly|require)\b/,
158
+ // keywords that have to be followed by an identifier
159
+ /\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,
160
+ // This is for `import type *, {}`
161
+ /\btype\b(?=\s*(?:[\{*]|$))/
162
+ ), delete e.languages.typescript.parameter, delete e.languages.typescript["literal-property"];
163
+ var n = e.languages.extend("typescript", {});
164
+ delete n["class-name"], e.languages.typescript["class-name"].inside = n, e.languages.insertBefore("typescript", "function", {
165
+ decorator: {
166
+ pattern: /@[$\w\xA0-\uFFFF]+/,
167
+ inside: {
168
+ at: {
169
+ pattern: /^@/,
170
+ alias: "operator"
171
+ },
172
+ function: /^[\s\S]+/
173
+ }
174
+ },
175
+ "generic-function": {
176
+ // e.g. foo<T extends "bar" | "baz">( ...
177
+ pattern: /#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,
178
+ greedy: !0,
179
+ inside: {
180
+ function: /^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,
181
+ generic: {
182
+ pattern: /<[\s\S]+/,
183
+ // everything after the first <
184
+ alias: "class-name",
185
+ inside: n
186
+ }
184
187
  }
185
188
  }
186
- }
187
- }), e.languages.ts = e.languages.typescript;
188
- })(Prism);
189
+ }), e.languages.ts = e.languages.typescript;
190
+ })(Prism)), O;
191
+ }
192
+ B();
189
193
  (function(e) {
190
194
  var n = e.util.clone(e.languages.javascript), s = /(?:\s|\/\/.*(?!.)|\/\*(?:[^*]|\*(?!\/))\*\/)/.source, o = /(?:\{(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])*\})/.source, p = /(?:\{<S>*\.{3}(?:[^{}]|<BRACES>)*\})/.source;
191
195
  function E(r, u) {
@@ -220,7 +224,7 @@ Prism.languages.js = Prism.languages.javascript;
220
224
  }, e.languages.jsx.tag);
221
225
  var i = function(r) {
222
226
  return r ? typeof r == "string" ? r : typeof r.content == "string" ? r.content : r.content.map(i).join("") : "";
223
- }, A = function(r) {
227
+ }, h = function(r) {
224
228
  for (var u = [], a = 0; a < r.length; a++) {
225
229
  var t = r[a], d = !1;
226
230
  if (typeof t != "string" && (t.type === "tag" && t.content[0] && t.content[0].type === "tag" ? t.content[0].content[0].content === "</" ? u.length > 0 && u[u.length - 1].tagName === i(t.content[0].content[1]) && u.pop() : t.content[t.content.length - 1].content === "/>" || u.push({
@@ -230,11 +234,11 @@ Prism.languages.js = Prism.languages.javascript;
230
234
  var l = i(t);
231
235
  a < r.length - 1 && (typeof r[a + 1] == "string" || r[a + 1].type === "plain-text") && (l += i(r[a + 1]), r.splice(a + 1, 1)), a > 0 && (typeof r[a - 1] == "string" || r[a - 1].type === "plain-text") && (l = i(r[a - 1]) + l, r.splice(a - 1, 1), a--), r[a] = new e.Token("plain-text", l, null, l);
232
236
  }
233
- t.content && typeof t.content != "string" && A(t.content);
237
+ t.content && typeof t.content != "string" && h(t.content);
234
238
  }
235
239
  };
236
240
  e.hooks.add("after-tokenize", function(r) {
237
- r.language !== "jsx" && r.language !== "tsx" || A(r.tokens);
241
+ r.language !== "jsx" && r.language !== "tsx" || h(r.tokens);
238
242
  });
239
243
  })(Prism);
240
244
  (function(e) {
@@ -542,183 +546,189 @@ Prism.languages.webmanifest = Prism.languages.json;
542
546
  E[p[i]] = e.languages.bash[p[i]];
543
547
  e.languages.sh = e.languages.bash, e.languages.shell = e.languages.bash;
544
548
  })(Prism);
545
- Prism.languages.python = {
546
- comment: {
547
- pattern: /(^|[^\\])#.*/,
548
- lookbehind: !0,
549
- greedy: !0
550
- },
551
- "string-interpolation": {
552
- pattern: /(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,
553
- greedy: !0,
554
- inside: {
555
- interpolation: {
556
- // "{" <expression> <optional "!s", "!r", or "!a"> <optional ":" format specifier> "}"
557
- pattern: /((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,
558
- lookbehind: !0,
559
- inside: {
560
- "format-spec": {
561
- pattern: /(:)[^:(){}]+(?=\}$)/,
562
- lookbehind: !0
563
- },
564
- "conversion-option": {
565
- pattern: /![sra](?=[:}]$)/,
566
- alias: "punctuation"
567
- },
568
- rest: null
569
- }
570
- },
571
- string: /[\s\S]+/
572
- }
573
- },
574
- "triple-quoted-string": {
575
- pattern: /(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,
576
- greedy: !0,
577
- alias: "string"
578
- },
579
- string: {
580
- pattern: /(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,
581
- greedy: !0
582
- },
583
- function: {
584
- pattern: /((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,
585
- lookbehind: !0
586
- },
587
- "class-name": {
588
- pattern: /(\bclass\s+)\w+/i,
589
- lookbehind: !0
590
- },
591
- decorator: {
592
- pattern: /(^[\t ]*)@\w+(?:\.\w+)*/m,
593
- lookbehind: !0,
594
- alias: ["annotation", "punctuation"],
595
- inside: {
596
- punctuation: /\./
597
- }
598
- },
599
- keyword: /\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,
600
- builtin: /\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,
601
- boolean: /\b(?:False|None|True)\b/,
602
- number: /\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,
603
- operator: /[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,
604
- punctuation: /[{}[\];(),.:]/
605
- };
606
- Prism.languages.python["string-interpolation"].inside.interpolation.inside.rest = Prism.languages.python;
607
- Prism.languages.py = Prism.languages.python;
608
- (function(e) {
609
- var n = /\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record(?!\s*[(){}[\]<>=%~.:,;?+\-*/&|^])|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/, s = /(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source, o = {
610
- pattern: RegExp(/(^|[^\w.])/.source + s + /[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),
611
- lookbehind: !0,
612
- inside: {
613
- namespace: {
614
- pattern: /^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,
615
- inside: {
616
- punctuation: /\./
617
- }
618
- },
619
- punctuation: /\./
620
- }
621
- };
622
- e.languages.java = e.languages.extend("clike", {
623
- string: {
624
- pattern: /(^|[^\\])"(?:\\.|[^"\\\r\n])*"/,
549
+ var k = {}, F;
550
+ function G() {
551
+ return F || (F = 1, Prism.languages.python = {
552
+ comment: {
553
+ pattern: /(^|[^\\])#.*/,
625
554
  lookbehind: !0,
626
555
  greedy: !0
627
556
  },
628
- "class-name": [
629
- o,
630
- {
631
- // variables, parameters, and constructor references
632
- // this to support class names (or generic parameters) which do not contain a lower case letter (also works for methods)
633
- pattern: RegExp(/(^|[^\w.])/.source + s + /[A-Z]\w*(?=\s+\w+\s*[;,=()]|\s*(?:\[[\s,]*\]\s*)?::\s*new\b)/.source),
634
- lookbehind: !0,
635
- inside: o.inside
636
- },
637
- {
638
- // class names based on keyword
639
- // this to support class names (or generic parameters) which do not contain a lower case letter (also works for methods)
640
- pattern: RegExp(/(\b(?:class|enum|extends|implements|instanceof|interface|new|record|throws)\s+)/.source + s + /[A-Z]\w*\b/.source),
641
- lookbehind: !0,
642
- inside: o.inside
643
- }
644
- ],
645
- keyword: n,
646
- function: [
647
- e.languages.clike.function,
648
- {
649
- pattern: /(::\s*)[a-z_]\w*/,
650
- lookbehind: !0
557
+ "string-interpolation": {
558
+ pattern: /(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,
559
+ greedy: !0,
560
+ inside: {
561
+ interpolation: {
562
+ // "{" <expression> <optional "!s", "!r", or "!a"> <optional ":" format specifier> "}"
563
+ pattern: /((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,
564
+ lookbehind: !0,
565
+ inside: {
566
+ "format-spec": {
567
+ pattern: /(:)[^:(){}]+(?=\}$)/,
568
+ lookbehind: !0
569
+ },
570
+ "conversion-option": {
571
+ pattern: /![sra](?=[:}]$)/,
572
+ alias: "punctuation"
573
+ },
574
+ rest: null
575
+ }
576
+ },
577
+ string: /[\s\S]+/
651
578
  }
652
- ],
653
- number: /\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i,
654
- operator: {
655
- pattern: /(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m,
656
- lookbehind: !0
657
579
  },
658
- constant: /\b[A-Z][A-Z_\d]+\b/
659
- }), e.languages.insertBefore("java", "string", {
660
580
  "triple-quoted-string": {
661
- // http://openjdk.java.net/jeps/355#Description
662
- pattern: /"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/,
581
+ pattern: /(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,
663
582
  greedy: !0,
664
583
  alias: "string"
665
584
  },
666
- char: {
667
- pattern: /'(?:\\.|[^'\\\r\n]){1,6}'/,
585
+ string: {
586
+ pattern: /(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,
668
587
  greedy: !0
669
- }
670
- }), e.languages.insertBefore("java", "class-name", {
671
- annotation: {
672
- pattern: /(^|[^.])@\w+(?:\s*\.\s*\w+)*/,
673
- lookbehind: !0,
674
- alias: "punctuation"
675
588
  },
676
- generics: {
677
- pattern: /<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/,
589
+ function: {
590
+ pattern: /((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,
591
+ lookbehind: !0
592
+ },
593
+ "class-name": {
594
+ pattern: /(\bclass\s+)\w+/i,
595
+ lookbehind: !0
596
+ },
597
+ decorator: {
598
+ pattern: /(^[\t ]*)@\w+(?:\.\w+)*/m,
599
+ lookbehind: !0,
600
+ alias: ["annotation", "punctuation"],
678
601
  inside: {
679
- "class-name": o,
680
- keyword: n,
681
- punctuation: /[<>(),.:]/,
682
- operator: /[?&|]/
602
+ punctuation: /\./
683
603
  }
684
604
  },
685
- import: [
686
- {
687
- pattern: RegExp(/(\bimport\s+)/.source + s + /(?:[A-Z]\w*|\*)(?=\s*;)/.source),
605
+ keyword: /\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,
606
+ builtin: /\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,
607
+ boolean: /\b(?:False|None|True)\b/,
608
+ number: /\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,
609
+ operator: /[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,
610
+ punctuation: /[{}[\];(),.:]/
611
+ }, Prism.languages.python["string-interpolation"].inside.interpolation.inside.rest = Prism.languages.python, Prism.languages.py = Prism.languages.python), k;
612
+ }
613
+ G();
614
+ var L = {}, _;
615
+ function H() {
616
+ return _ || (_ = 1, (function(e) {
617
+ var n = /\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record(?!\s*[(){}[\]<>=%~.:,;?+\-*/&|^])|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/, s = /(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source, o = {
618
+ pattern: RegExp(/(^|[^\w.])/.source + s + /[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),
619
+ lookbehind: !0,
620
+ inside: {
621
+ namespace: {
622
+ pattern: /^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,
623
+ inside: {
624
+ punctuation: /\./
625
+ }
626
+ },
627
+ punctuation: /\./
628
+ }
629
+ };
630
+ e.languages.java = e.languages.extend("clike", {
631
+ string: {
632
+ pattern: /(^|[^\\])"(?:\\.|[^"\\\r\n])*"/,
633
+ lookbehind: !0,
634
+ greedy: !0
635
+ },
636
+ "class-name": [
637
+ o,
638
+ {
639
+ // variables, parameters, and constructor references
640
+ // this to support class names (or generic parameters) which do not contain a lower case letter (also works for methods)
641
+ pattern: RegExp(/(^|[^\w.])/.source + s + /[A-Z]\w*(?=\s+\w+\s*[;,=()]|\s*(?:\[[\s,]*\]\s*)?::\s*new\b)/.source),
642
+ lookbehind: !0,
643
+ inside: o.inside
644
+ },
645
+ {
646
+ // class names based on keyword
647
+ // this to support class names (or generic parameters) which do not contain a lower case letter (also works for methods)
648
+ pattern: RegExp(/(\b(?:class|enum|extends|implements|instanceof|interface|new|record|throws)\s+)/.source + s + /[A-Z]\w*\b/.source),
649
+ lookbehind: !0,
650
+ inside: o.inside
651
+ }
652
+ ],
653
+ keyword: n,
654
+ function: [
655
+ e.languages.clike.function,
656
+ {
657
+ pattern: /(::\s*)[a-z_]\w*/,
658
+ lookbehind: !0
659
+ }
660
+ ],
661
+ number: /\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i,
662
+ operator: {
663
+ pattern: /(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m,
664
+ lookbehind: !0
665
+ },
666
+ constant: /\b[A-Z][A-Z_\d]+\b/
667
+ }), e.languages.insertBefore("java", "string", {
668
+ "triple-quoted-string": {
669
+ // http://openjdk.java.net/jeps/355#Description
670
+ pattern: /"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/,
671
+ greedy: !0,
672
+ alias: "string"
673
+ },
674
+ char: {
675
+ pattern: /'(?:\\.|[^'\\\r\n]){1,6}'/,
676
+ greedy: !0
677
+ }
678
+ }), e.languages.insertBefore("java", "class-name", {
679
+ annotation: {
680
+ pattern: /(^|[^.])@\w+(?:\s*\.\s*\w+)*/,
688
681
  lookbehind: !0,
682
+ alias: "punctuation"
683
+ },
684
+ generics: {
685
+ pattern: /<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/,
689
686
  inside: {
690
- namespace: o.inside.namespace,
691
- punctuation: /\./,
692
- operator: /\*/,
693
- "class-name": /\w+/
687
+ "class-name": o,
688
+ keyword: n,
689
+ punctuation: /[<>(),.:]/,
690
+ operator: /[?&|]/
694
691
  }
695
692
  },
696
- {
697
- pattern: RegExp(/(\bimport\s+static\s+)/.source + s + /(?:\w+|\*)(?=\s*;)/.source),
693
+ import: [
694
+ {
695
+ pattern: RegExp(/(\bimport\s+)/.source + s + /(?:[A-Z]\w*|\*)(?=\s*;)/.source),
696
+ lookbehind: !0,
697
+ inside: {
698
+ namespace: o.inside.namespace,
699
+ punctuation: /\./,
700
+ operator: /\*/,
701
+ "class-name": /\w+/
702
+ }
703
+ },
704
+ {
705
+ pattern: RegExp(/(\bimport\s+static\s+)/.source + s + /(?:\w+|\*)(?=\s*;)/.source),
706
+ lookbehind: !0,
707
+ alias: "static",
708
+ inside: {
709
+ namespace: o.inside.namespace,
710
+ static: /\b\w+$/,
711
+ punctuation: /\./,
712
+ operator: /\*/,
713
+ "class-name": /\w+/
714
+ }
715
+ }
716
+ ],
717
+ namespace: {
718
+ pattern: RegExp(
719
+ /(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g, function() {
720
+ return n.source;
721
+ })
722
+ ),
698
723
  lookbehind: !0,
699
- alias: "static",
700
724
  inside: {
701
- namespace: o.inside.namespace,
702
- static: /\b\w+$/,
703
- punctuation: /\./,
704
- operator: /\*/,
705
- "class-name": /\w+/
725
+ punctuation: /\./
706
726
  }
707
727
  }
708
- ],
709
- namespace: {
710
- pattern: RegExp(
711
- /(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g, function() {
712
- return n.source;
713
- })
714
- ),
715
- lookbehind: !0,
716
- inside: {
717
- punctuation: /\./
718
- }
719
- }
720
- });
721
- })(Prism);
728
+ });
729
+ })(Prism)), L;
730
+ }
731
+ H();
722
732
  Prism.languages.go = Prism.languages.extend("clike", {
723
733
  string: {
724
734
  pattern: /(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,
@@ -745,122 +755,126 @@ Prism.languages.insertBefore("go", "string", {
745
755
  }
746
756
  });
747
757
  delete Prism.languages.go["class-name"];
748
- (function(e) {
749
- for (var n = /\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|<self>)*\*\//.source, s = 0; s < 2; s++)
758
+ var v = {}, C;
759
+ function z() {
760
+ return C || (C = 1, (function(e) {
761
+ for (var n = /\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|<self>)*\*\//.source, s = 0; s < 2; s++)
762
+ n = n.replace(/<self>/g, function() {
763
+ return n;
764
+ });
750
765
  n = n.replace(/<self>/g, function() {
751
- return n;
752
- });
753
- n = n.replace(/<self>/g, function() {
754
- return /[^\s\S]/.source;
755
- }), e.languages.rust = {
756
- comment: [
757
- {
758
- pattern: RegExp(/(^|[^\\])/.source + n),
759
- lookbehind: !0,
766
+ return /[^\s\S]/.source;
767
+ }), e.languages.rust = {
768
+ comment: [
769
+ {
770
+ pattern: RegExp(/(^|[^\\])/.source + n),
771
+ lookbehind: !0,
772
+ greedy: !0
773
+ },
774
+ {
775
+ pattern: /(^|[^\\:])\/\/.*/,
776
+ lookbehind: !0,
777
+ greedy: !0
778
+ }
779
+ ],
780
+ string: {
781
+ pattern: /b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,
760
782
  greedy: !0
761
783
  },
762
- {
763
- pattern: /(^|[^\\:])\/\/.*/,
764
- lookbehind: !0,
784
+ char: {
785
+ pattern: /b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,
765
786
  greedy: !0
766
- }
767
- ],
768
- string: {
769
- pattern: /b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,
770
- greedy: !0
771
- },
772
- char: {
773
- pattern: /b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,
774
- greedy: !0
775
- },
776
- attribute: {
777
- pattern: /#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,
778
- greedy: !0,
779
- alias: "attr-name",
780
- inside: {
781
- string: null
782
- // see below
783
- }
784
- },
785
- // Closure params should not be confused with bitwise OR |
786
- "closure-params": {
787
- pattern: /([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,
788
- lookbehind: !0,
789
- greedy: !0,
790
- inside: {
791
- "closure-punctuation": {
792
- pattern: /^\||\|$/,
793
- alias: "punctuation"
794
- },
795
- rest: null
796
- // see below
797
- }
798
- },
799
- "lifetime-annotation": {
800
- pattern: /'\w+/,
801
- alias: "symbol"
802
- },
803
- "fragment-specifier": {
804
- pattern: /(\$\w+:)[a-z]+/,
805
- lookbehind: !0,
806
- alias: "punctuation"
807
- },
808
- variable: /\$\w+/,
809
- "function-definition": {
810
- pattern: /(\bfn\s+)\w+/,
811
- lookbehind: !0,
812
- alias: "function"
813
- },
814
- "type-definition": {
815
- pattern: /(\b(?:enum|struct|trait|type|union)\s+)\w+/,
816
- lookbehind: !0,
817
- alias: "class-name"
818
- },
819
- "module-declaration": [
820
- {
821
- pattern: /(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,
787
+ },
788
+ attribute: {
789
+ pattern: /#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,
790
+ greedy: !0,
791
+ alias: "attr-name",
792
+ inside: {
793
+ string: null
794
+ // see below
795
+ }
796
+ },
797
+ // Closure params should not be confused with bitwise OR |
798
+ "closure-params": {
799
+ pattern: /([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,
800
+ lookbehind: !0,
801
+ greedy: !0,
802
+ inside: {
803
+ "closure-punctuation": {
804
+ pattern: /^\||\|$/,
805
+ alias: "punctuation"
806
+ },
807
+ rest: null
808
+ // see below
809
+ }
810
+ },
811
+ "lifetime-annotation": {
812
+ pattern: /'\w+/,
813
+ alias: "symbol"
814
+ },
815
+ "fragment-specifier": {
816
+ pattern: /(\$\w+:)[a-z]+/,
822
817
  lookbehind: !0,
823
- alias: "namespace"
818
+ alias: "punctuation"
824
819
  },
825
- {
826
- pattern: /(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,
820
+ variable: /\$\w+/,
821
+ "function-definition": {
822
+ pattern: /(\bfn\s+)\w+/,
827
823
  lookbehind: !0,
828
- alias: "namespace",
824
+ alias: "function"
825
+ },
826
+ "type-definition": {
827
+ pattern: /(\b(?:enum|struct|trait|type|union)\s+)\w+/,
828
+ lookbehind: !0,
829
+ alias: "class-name"
830
+ },
831
+ "module-declaration": [
832
+ {
833
+ pattern: /(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,
834
+ lookbehind: !0,
835
+ alias: "namespace"
836
+ },
837
+ {
838
+ pattern: /(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,
839
+ lookbehind: !0,
840
+ alias: "namespace",
841
+ inside: {
842
+ punctuation: /::/
843
+ }
844
+ }
845
+ ],
846
+ keyword: [
847
+ // https://github.com/rust-lang/reference/blob/master/src/keywords.md
848
+ /\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,
849
+ // primitives and str
850
+ // https://doc.rust-lang.org/stable/rust-by-example/primitives.html
851
+ /\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/
852
+ ],
853
+ // functions can technically start with an upper-case letter, but this will introduce a lot of false positives
854
+ // and Rust's naming conventions recommend snake_case anyway.
855
+ // https://doc.rust-lang.org/1.0.0/style/style/naming/README.html
856
+ function: /\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,
857
+ macro: {
858
+ pattern: /\b\w+!/,
859
+ alias: "property"
860
+ },
861
+ constant: /\b[A-Z_][A-Z_\d]+\b/,
862
+ "class-name": /\b[A-Z]\w*\b/,
863
+ namespace: {
864
+ pattern: /(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,
829
865
  inside: {
830
866
  punctuation: /::/
831
867
  }
832
- }
833
- ],
834
- keyword: [
835
- // https://github.com/rust-lang/reference/blob/master/src/keywords.md
836
- /\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,
837
- // primitives and str
838
- // https://doc.rust-lang.org/stable/rust-by-example/primitives.html
839
- /\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/
840
- ],
841
- // functions can technically start with an upper-case letter, but this will introduce a lot of false positives
842
- // and Rust's naming conventions recommend snake_case anyway.
843
- // https://doc.rust-lang.org/1.0.0/style/style/naming/README.html
844
- function: /\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,
845
- macro: {
846
- pattern: /\b\w+!/,
847
- alias: "property"
848
- },
849
- constant: /\b[A-Z_][A-Z_\d]+\b/,
850
- "class-name": /\b[A-Z]\w*\b/,
851
- namespace: {
852
- pattern: /(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,
853
- inside: {
854
- punctuation: /::/
855
- }
856
- },
857
- // Hex, oct, bin, dec numbers with visual separators and type suffix
858
- number: /\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,
859
- boolean: /\b(?:false|true)\b/,
860
- punctuation: /->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,
861
- operator: /[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?=?|[@?]/
862
- }, e.languages.rust["closure-params"].inside.rest = e.languages.rust, e.languages.rust.attribute.inside.string = e.languages.rust.string;
863
- })(Prism);
868
+ },
869
+ // Hex, oct, bin, dec numbers with visual separators and type suffix
870
+ number: /\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,
871
+ boolean: /\b(?:false|true)\b/,
872
+ punctuation: /->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,
873
+ operator: /[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?=?|[@?]/
874
+ }, e.languages.rust["closure-params"].inside.rest = e.languages.rust, e.languages.rust.attribute.inside.string = e.languages.rust.string;
875
+ })(Prism)), v;
876
+ }
877
+ z();
864
878
  Prism.languages.sql = {
865
879
  comment: {
866
880
  pattern: /(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,
@@ -1147,8 +1161,8 @@ Prism.languages.sql = {
1147
1161
  if (b && c && b.type === "code-language" && c.type === "code-block" && typeof b.content == "string") {
1148
1162
  var S = b.content.replace(/\b#/g, "sharp").replace(/\b\+\+/g, "pp");
1149
1163
  S = (/[a-z][\w-]*/i.exec(S) || [""])[0].toLowerCase();
1150
- var R = "language-" + S;
1151
- c.alias ? typeof c.alias == "string" ? c.alias = [c.alias, R] : c.alias.push(R) : c.alias = [R];
1164
+ var I = "language-" + S;
1165
+ c.alias ? typeof c.alias == "string" ? c.alias = [c.alias, I] : c.alias.push(I) : c.alias = [I];
1152
1166
  }
1153
1167
  }
1154
1168
  }
@@ -1174,7 +1188,7 @@ Prism.languages.sql = {
1174
1188
  }
1175
1189
  }
1176
1190
  });
1177
- var i = RegExp(e.languages.markup.tag.pattern.source, "gi"), A = {
1191
+ var i = RegExp(e.languages.markup.tag.pattern.source, "gi"), h = {
1178
1192
  amp: "&",
1179
1193
  lt: "<",
1180
1194
  gt: ">",
@@ -1187,7 +1201,7 @@ Prism.languages.sql = {
1187
1201
  var m;
1188
1202
  return l[1] === "x" ? m = parseInt(l.slice(2), 16) : m = Number(l.slice(1)), r(m);
1189
1203
  } else {
1190
- var g = A[l];
1204
+ var g = h[l];
1191
1205
  return g || d;
1192
1206
  }
1193
1207
  }), t;
@@ -1198,12 +1212,12 @@ Prism.languages.sql = {
1198
1212
  var n = /[*&][^\s[\]{},]+/, s = /!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/, o = "(?:" + s.source + "(?:[ ]+" + n.source + ")?|" + n.source + "(?:[ ]+" + s.source + ")?)", p = /(?:[^\s\x00-\x08\x0e-\x1f!"#%&'*,\-:>?@[\]`{|}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]|[?:-]<PLAIN>)(?:[ \t]*(?:(?![#:])<PLAIN>|:<PLAIN>))*/.source.replace(/<PLAIN>/g, function() {
1199
1213
  return /[^\s\x00-\x08\x0e-\x1f,[\]{}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]/.source;
1200
1214
  }), E = /"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/.source;
1201
- function i(A, r) {
1215
+ function i(h, r) {
1202
1216
  r = (r || "").replace(/m/g, "") + "m";
1203
1217
  var u = /([:\-,[{]\s*(?:\s<<prop>>[ \t]+)?)(?:<<value>>)(?=[ \t]*(?:$|,|\]|\}|(?:[\r\n]\s*)?#))/.source.replace(/<<prop>>/g, function() {
1204
1218
  return o;
1205
1219
  }).replace(/<<value>>/g, function() {
1206
- return A;
1220
+ return h;
1207
1221
  });
1208
1222
  return RegExp(u, r);
1209
1223
  }
@@ -1260,7 +1274,7 @@ Prism.languages.sql = {
1260
1274
  punctuation: /---|[:[\]{}\-,|>?]|\.\.\./
1261
1275
  }, e.languages.yml = e.languages.yaml;
1262
1276
  })(Prism);
1263
- const _ = T.forwardRef(({
1277
+ const j = T.forwardRef(({
1264
1278
  code: e,
1265
1279
  language: n = "text",
1266
1280
  showLineNumbers: s = !1,
@@ -1268,7 +1282,7 @@ const _ = T.forwardRef(({
1268
1282
  filename: p,
1269
1283
  highlightLines: E = [],
1270
1284
  languages: i,
1271
- ...A
1285
+ ...h
1272
1286
  }, r) => {
1273
1287
  const [u, a] = T.useState(!1), [t, d] = T.useState(""), [l, m] = T.useState(0), g = T.useRef(null);
1274
1288
  T.useEffect(() => () => {
@@ -1277,37 +1291,37 @@ const _ = T.forwardRef(({
1277
1291
  const b = i ? i[l].code : e, c = i ? i[l].language : n;
1278
1292
  T.useEffect(() => {
1279
1293
  if (c !== "text") {
1280
- const h = y.languages[c];
1281
- d(h ? y.highlight(b, h, c) : O(b));
1294
+ const A = y.languages[c];
1295
+ d(A ? y.highlight(b, A, c) : D(b));
1282
1296
  } else
1283
- d(O(b));
1297
+ d(D(b));
1284
1298
  }, [b, c]);
1285
1299
  const S = async () => {
1286
1300
  await navigator.clipboard.writeText(b), a(!0), g.current && clearTimeout(g.current), g.current = setTimeout(() => a(!1), 2e3);
1287
- }, R = t.split(`
1288
- `), w = p || o || i && i.length > 1;
1289
- return /* @__PURE__ */ I("div", { ref: r, ...A, className: "x1cqd74s xsdfdjn x9nsp9x x1y0btm7 xmkeg23 xa18zv3 x1eqnyfr x1n2onr6", children: [
1290
- w && /* @__PURE__ */ I("div", { className: "x6s0dn4 x1dyd9yc x1q0q8m5 xso031l x78zum5 xpfqfdi x1qughib xrtip4p x16pzmsl", children: [
1291
- /* @__PURE__ */ I("div", { className: "x6s0dn4 x78zum5 xpfqfdi xw2csxc", children: [
1301
+ }, I = t.split(`
1302
+ `), $ = p || o || i && i.length > 1;
1303
+ return /* @__PURE__ */ R("div", { ref: r, ...h, className: "x1cqd74s xsdfdjn x9nsp9x x1y0btm7 xmkeg23 xa18zv3 x1eqnyfr x1n2onr6", children: [
1304
+ $ && /* @__PURE__ */ R("div", { className: "x6s0dn4 x1dyd9yc x1q0q8m5 xso031l x78zum5 xpfqfdi x1qughib xrtip4p x16pzmsl", children: [
1305
+ /* @__PURE__ */ R("div", { className: "x6s0dn4 x78zum5 xpfqfdi xw2csxc", children: [
1292
1306
  p && /* @__PURE__ */ f("span", { className: "xwa5xuj x2lah0s x51wmvv", children: p }),
1293
- i && i.length > 1 && /* @__PURE__ */ f("div", { className: "x6s0dn4 xtpsrvy x1brvnfc x78zum5 x1o29ju6 x2k5h2x", children: i.map((h, x) => /* @__PURE__ */ f("button", { type: "button", onClick: () => m(x), ...{
1307
+ i && i.length > 1 && /* @__PURE__ */ f("div", { className: "x6s0dn4 xtpsrvy x1brvnfc x78zum5 x1o29ju6 x2k5h2x", children: i.map((A, x) => /* @__PURE__ */ f("button", { type: "button", onClick: () => m(x), ...{
1294
1308
  0: {
1295
1309
  className: "xc342km x1kcekj6 x1ypdohk x51wmvv xk50ysn x14aypoh x1wu0y3b xx6bhzk x1yyhn7k xwji4o3 xjbqb8w x1uuraw0 x1leyzdx"
1296
1310
  },
1297
1311
  1: {
1298
1312
  className: "xc342km x1kcekj6 x1ypdohk x51wmvv xk50ysn x14aypoh x1wu0y3b xx6bhzk x1yyhn7k xwji4o3 x11tn5dx xv186zg x1vmo3ik"
1299
1313
  }
1300
- }[(x === l) << 0], children: h.label ?? h.language }, h.language + x)) })
1314
+ }[(x === l) << 0], children: A.label ?? A.language }, A.language + x)) })
1301
1315
  ] }),
1302
- o && /* @__PURE__ */ f("button", { type: "button", onClick: S, className: "x6s0dn4 xjbqb8w x1kcekj6 xc342km x1uuraw0 x1ypdohk x78zum5 x2lah0s x51wmvv x1o29ju6 x8x9d4c x136oad8 x1wu0y3b x3wwfir x1leyzdx", children: u ? /* @__PURE__ */ I(N, { children: [
1303
- /* @__PURE__ */ f(F, { "aria-hidden": "true", className: "x1kpxq89 xsmyaan" }),
1316
+ o && /* @__PURE__ */ f("button", { type: "button", onClick: S, className: "x6s0dn4 xjbqb8w x1kcekj6 xc342km x1uuraw0 x1ypdohk x78zum5 x2lah0s x51wmvv x1o29ju6 x8x9d4c x136oad8 x1wu0y3b x3wwfir x1leyzdx", children: u ? /* @__PURE__ */ R(N, { children: [
1317
+ /* @__PURE__ */ f(P, { "aria-hidden": "true", className: "x1kpxq89 xsmyaan" }),
1304
1318
  "Copied"
1305
- ] }) : /* @__PURE__ */ I(N, { children: [
1306
- /* @__PURE__ */ f(L, { "aria-hidden": "true", className: "x1kpxq89 xsmyaan" }),
1319
+ ] }) : /* @__PURE__ */ R(N, { children: [
1320
+ /* @__PURE__ */ f(M, { "aria-hidden": "true", className: "x1kpxq89 xsmyaan" }),
1307
1321
  "Copy"
1308
1322
  ] }) })
1309
1323
  ] }),
1310
- /* @__PURE__ */ f("div", { className: "xw2csxc x11omchh", children: /* @__PURE__ */ f("pre", { className: `${v(C.pre)} language-${c}`, children: /* @__PURE__ */ f("code", { className: `language-${c}`, children: R.map((h, x) => /* @__PURE__ */ I("div", { ...{
1324
+ /* @__PURE__ */ f("div", { className: "xw2csxc x11omchh", children: /* @__PURE__ */ f("pre", { className: `${Y(q.pre)} language-${c}`, children: /* @__PURE__ */ f("code", { className: `language-${c}`, children: I.map((A, x) => /* @__PURE__ */ R("div", { ...{
1311
1325
  0: {
1312
1326
  className: "x17mssa0"
1313
1327
  },
@@ -1317,19 +1331,19 @@ const _ = T.forwardRef(({
1317
1331
  }[!!E.includes(x + 1) << 0], children: [
1318
1332
  s && /* @__PURE__ */ f("span", { className: "xwa5xuj x1rg5ohu xdmqks8 x1hr2gdg x87ps6o xooyq8t", children: x + 1 }),
1319
1333
  /* @__PURE__ */ f("span", { dangerouslySetInnerHTML: {
1320
- __html: h || " "
1334
+ __html: A || " "
1321
1335
  } })
1322
1336
  ] }, x)) }) }) })
1323
1337
  ] });
1324
1338
  });
1325
- _.displayName = "CodeBlock";
1326
- function v(...e) {
1327
- return k.props(...e).className ?? "";
1339
+ j.displayName = "CodeBlock";
1340
+ function Y(...e) {
1341
+ return U.props(...e).className ?? "";
1328
1342
  }
1329
- function O(e) {
1343
+ function D(e) {
1330
1344
  return e.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#39;");
1331
1345
  }
1332
- const C = {
1346
+ const q = {
1333
1347
  pre: {
1334
1348
  kMv6JI: "xpw0y0u",
1335
1349
  kGuDYH: "x1eqnyfr",
@@ -1338,5 +1352,5 @@ const C = {
1338
1352
  }
1339
1353
  };
1340
1354
  export {
1341
- _ as C
1355
+ j as C
1342
1356
  };