* Generates hint for inputhints * @param {HintModification} hints Hint modification object
(hints)
| 25 | * @param {HintModification} hints Hint modification object |
| 26 | */ |
| 27 | async function generateHints(hints) { |
| 28 | hintsModification = hints; |
| 29 | const list = []; |
| 30 | |
| 31 | editorManager.files.forEach((file) => { |
| 32 | const { uri, name } = file; |
| 33 | let { location = "" } = file; |
| 34 | |
| 35 | if (location) { |
| 36 | location = helpers.getVirtualPath(location); |
| 37 | } |
| 38 | |
| 39 | list.push(hintItem(name, location, uri)); |
| 40 | }); |
| 41 | |
| 42 | list.push(...files(hintItem)); |
| 43 | return list; |
| 44 | } |
| 45 | |
| 46 | function onselect(value) { |
| 47 | if (!value) return; |