Blame view

bower_components/prism/components/prism-python.js 830 Bytes
eb240478   Luigi Serra   public room cards...
1
  Prism.languages.python= {
f748e9cf   Luigi Serra   new controllet an...
2
3
4
5
  	'triple-quoted-string': {
  		pattern: /"""[\s\S]+?"""|'''[\s\S]+?'''/,
  		alias: 'string'
  	},
73bcce88   luigser   COMPONENTS
6
  	'comment': {
eb240478   Luigi Serra   public room cards...
7
  		pattern: /(^|[^\\])#.*/,
73bcce88   luigser   COMPONENTS
8
9
  		lookbehind: true
  	},
f748e9cf   Luigi Serra   new controllet an...
10
  	'string': /("|')(?:\\?.)*?\1/,
73bcce88   luigser   COMPONENTS
11
  	'function' : {
eb240478   Luigi Serra   public room cards...
12
  		pattern: /((?:^|\s)def[ \t]+)[a-zA-Z_][a-zA-Z0-9_]*(?=\()/g,
73bcce88   luigser   COMPONENTS
13
14
  		lookbehind: true
  	},
eb240478   Luigi Serra   public room cards...
15
16
17
18
19
20
21
22
  	'class-name': {
  		pattern: /(\bclass\s+)[a-z0-9_]+/i,
  		lookbehind: true
  	},
  	'keyword' : /\b(?:as|assert|async|await|break|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|pass|print|raise|return|try|while|with|yield)\b/,
  	'boolean' : /\b(?:True|False)\b/,
  	'number' : /\b-?(?:0[bo])?(?:(?:\d|0x[\da-f])[\da-f]*\.?\d*|\.\d+)(?:e[+-]?\d+)?j?\b/i,
  	'operator' : /[-+%=]=?|!=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]|\b(?:or|and|not)\b/,
73bcce88   luigser   COMPONENTS
23
  	'punctuation' : /[{}[\];(),.:]/
eb240478   Luigi Serra   public room cards...
24
  };