aboutsummaryrefslogtreecommitdiffstats
path: root/runtime/queries/phpdoc/highlights.scm
blob: 3ebe4a66e28ba729c3e1ca42c1eddc3eb0f49699 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
(tag_name) @attribute @nospell

(tag
  (tag_name) @_tag
  (#eq? @_tag "@param")
  (variable_name) @variable.parameter)

(tag
  (tag_name) @_tag
  (#eq? @_tag "@property")
  (variable_name) @variable.member)

(tag
  (tag_name) @_tag
  (#eq? @_tag "@var")
  (variable_name) @variable)

(tag
  (tag_name) @_tag
  (#eq? @_tag "@function.method")
  (name) @function.method)

(parameter
  (variable_name) @variable.parameter)

[
  (array_type)
  (primitive_type)
  (named_type)
  (optional_type)
] @type

(union_type
  [
    (array_type)
    (primitive_type)
    (named_type)
    (optional_type)
  ] @type)

(union_type) @nospell

(variable_name) @nospell

(tag
  (description
    (text) @none @spell))

(tag
  [
    (author_name)
    (version)
  ] @none)

(tag
  (email_address) @string.special.url)

(union_type
  "|" @keyword)

(variable_name
  "$" @keyword)

(tag
  (tag_name) @_tag_name
  [
    "<"
    ">"
  ] @keyword
  (#eq? @_tag_name "@author"))

(text) @spell