你现在正在访问的是萌娘百科用于保存和管理图片、音频等媒体文件的子项目萌娘共享,想要回到萌娘百科,请使用浏览器上的返回按钮、或点击这里
MediaWiki:Gadget-prism-language-coffeescript.js
注意:在保存之后,您可能需要清除浏览器缓存才能看到所作出的变更的影响。
- Firefox或Safari:按住Shift的同时单击刷新,或按Ctrl-F5或Ctrl-R(Mac为⌘-R)
- Google Chrome:按Ctrl-Shift-R(Mac为⌘-Shift-R)
- Internet Explorer:按住Ctrl的同时单击刷新,或按Ctrl-F5
- Opera:前往菜单 → 设置(Mac为Opera → Preferences),然后隐私和安全 → 清除浏览数据 → 缓存的图片和文件。
- /**
- * -------------------------------------------------------------------------
- * !!! DON'T MODIFY THIS PAGE MANUALLY, YOUR CHANGES WILL BE OVERWRITTEN !!!
- * -------------------------------------------------------------------------
- */
- var _addText = '{{GHIACode|page=GHIA:MoegirlPediaInterfaceCodes/blob/master/src/gadgets/prism-language-coffeescript/Gadget-prism-language-coffeescript.js|user=[[U:AnnAngela]]|co-authors=GH:github-actions[bot]|longId=103d1a563ea4ccc8ff29fb55c9bcd88329a56eb5|shortId=103d1a56|summary=feat: rename (#594)|body=<nowiki>Co-authored-by: github-actions[bot] <41898282+github-actions[bot]📧users.noreply.github.com></nowiki>}}';
- /* <pre> */
- "use strict";
- (function (Prism) {
- var comment = /#(?!\{).+/;
- var interpolation = {
- pattern: /#\{[^}]+\}/,
- alias: 'variable'
- };
- Prism.languages.coffeescript = Prism.languages.extend('javascript', {
- 'comment': comment,
- 'string': [
- {
- pattern: /'(?:\\[\s\S]|[^\\'])*'/,
- greedy: true
- },
- {
- pattern: /"(?:\\[\s\S]|[^\\"])*"/,
- greedy: true,
- inside: {
- 'interpolation': interpolation
- }
- }
- ],
- 'keyword': /\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/,
- 'class-member': {
- pattern: /@(?!\d)\w+/,
- alias: 'variable'
- }
- });
- Prism.languages.insertBefore('coffeescript', 'comment', {
- 'multiline-comment': {
- pattern: /###[\s\S]+?###/,
- alias: 'comment'
- },
- 'block-regex': {
- pattern: /\/{3}[\s\S]*?\/{3}/,
- alias: 'regex',
- inside: {
- 'comment': comment,
- 'interpolation': interpolation
- }
- }
- });
- Prism.languages.insertBefore('coffeescript', 'string', {
- 'inline-javascript': {
- pattern: /`(?:\\[\s\S]|[^\\`])*`/,
- inside: {
- 'delimiter': {
- pattern: /^`|`$/,
- alias: 'punctuation'
- },
- 'script': {
- pattern: /[\s\S]+/,
- alias: 'language-javascript',
- inside: Prism.languages.javascript
- }
- }
- },
- 'multiline-string': [
- {
- pattern: /'''[\s\S]*?'''/,
- greedy: true,
- alias: 'string'
- },
- {
- pattern: /"""[\s\S]*?"""/,
- greedy: true,
- alias: 'string',
- inside: {
- interpolation: interpolation
- }
- }
- ]
- });
- Prism.languages.insertBefore('coffeescript', 'keyword', {
- 'property': /(?!\d)\w+(?=\s*:(?!:))/
- });
- delete Prism.languages.coffeescript['template-string'];
- Prism.languages.coffee = Prism.languages.coffeescript;
- }(Prism));
- /* </pre> */