Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(410)

Side by Side Diff: polymer_0.4.0/bower_components/google-code-prettify/src/lang-yaml.js

Issue 786953007: npm_modules: Fork bower_components into Polymer 0.4.0 and 0.5.0 versions (Closed) Base URL: https://chromium.googlesource.com/infra/third_party/npm_modules.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Contributed by ribrdb @ code.google.com 1 // Contributed by ribrdb @ code.google.com
2 2
3 /** 3 /**
4 * @fileoverview 4 * @fileoverview
5 * Registers a language handler for YAML. 5 * Registers a language handler for YAML.
6 * 6 *
7 * @author ribrdb 7 * @author ribrdb
8 */ 8 */
9 9
10 PR['registerLangHandler']( 10 PR['registerLangHandler'](
11 PR['createSimpleLexer']( 11 PR['createSimpleLexer'](
12 [ 12 [
13 [PR['PR_PUNCTUATION'], /^[:|>?]+/, null, ':|>?'], 13 [PR['PR_PUNCTUATION'], /^[:|>?]+/, null, ':|>?'],
14 [PR['PR_DECLARATION'], /^%(?:YAML|TAG)[^#\r\n]+/, null, '%'], 14 [PR['PR_DECLARATION'], /^%(?:YAML|TAG)[^#\r\n]+/, null, '%'],
15 [PR['PR_TYPE'], /^[&]\S+/, null, '&'], 15 [PR['PR_TYPE'], /^[&]\S+/, null, '&'],
16 [PR['PR_TYPE'], /^!\S*/, null, '!'], 16 [PR['PR_TYPE'], /^!\S*/, null, '!'],
17 [PR['PR_STRING'], /^"(?:[^\\"]|\\.)*(?:"|$)/, null, '"'], 17 [PR['PR_STRING'], /^"(?:[^\\"]|\\.)*(?:"|$)/, null, '"'],
18 [PR['PR_STRING'], /^'(?:[^']|'')*(?:'|$)/, null, "'"], 18 [PR['PR_STRING'], /^'(?:[^']|'')*(?:'|$)/, null, "'"],
19 [PR['PR_COMMENT'], /^#[^\r\n]*/, null, '#'], 19 [PR['PR_COMMENT'], /^#[^\r\n]*/, null, '#'],
20 [PR['PR_PLAIN'], /^\s+/, null, ' \t\r\n'] 20 [PR['PR_PLAIN'], /^\s+/, null, ' \t\r\n']
21 ], 21 ],
22 [ 22 [
23 [PR['PR_DECLARATION'], /^(?:---|\.\.\.)(?:[\r\n]|$)/], 23 [PR['PR_DECLARATION'], /^(?:---|\.\.\.)(?:[\r\n]|$)/],
24 [PR['PR_PUNCTUATION'], /^-/], 24 [PR['PR_PUNCTUATION'], /^-/],
25 [PR['PR_KEYWORD'], /^\w+:[ \r\n]/], 25 [PR['PR_KEYWORD'], /^\w+:[ \r\n]/],
26 [PR['PR_PLAIN'], /^\w+/] 26 [PR['PR_PLAIN'], /^\w+/]
27 ]), ['yaml', 'yml']); 27 ]), ['yaml', 'yml']);
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698