(doc document.ComposeDocument, mappingNode *ast.MappingNode, nodePath []ast.Node)
| 154 | } |
| 155 | |
| 156 | func configHover(doc document.ComposeDocument, mappingNode *ast.MappingNode, nodePath []ast.Node) *protocol.Hover { |
| 157 | if len(nodePath) == 4 && nodePath[0].GetToken().Value == "services" { |
| 158 | // array string |
| 159 | if nodePath[2].GetToken().Value == "configs" { |
| 160 | t := nodePath[3].GetToken() |
| 161 | return createDependencyHover(doc, mappingNode, t, "configs", t.Value) |
| 162 | } |
| 163 | } else if len(nodePath) == 5 && nodePath[0].GetToken().Value == "services" { |
| 164 | // array object |
| 165 | if nodePath[2].GetToken().Value == "configs" && nodePath[3].GetToken().Value == "source" { |
| 166 | t := nodePath[4].GetToken() |
| 167 | return createDependencyHover(doc, mappingNode, t, "configs", t.Value) |
| 168 | } |
| 169 | } |
| 170 | return nil |
| 171 | } |
| 172 | |
| 173 | func secretHover(doc document.ComposeDocument, mappingNode *ast.MappingNode, nodePath []ast.Node) *protocol.Hover { |
| 174 | if len(nodePath) >= 4 && nodePath[0].GetToken().Value == "services" { |
no test coverage detected