@@ -108,7 +108,6 @@ namespace ts.server {
108108 /* @internal */
109109 export const CompletionsFull : protocol . CommandTypes . CompletionsFull = "completions-full" ;
110110 export const CompletionDetails : protocol . CommandTypes . CompletionDetails = "completionEntryDetails" ;
111- export const CommitCompletionWithCodeAction : protocol . CommandTypes . CommitCompletionWithCodeAction = "commitCompletionWithCodeAction" ;
112111 export const CompileOnSaveAffectedFileList : protocol . CommandTypes . CompileOnSaveAffectedFileList = "compileOnSaveAffectedFileList" ;
113112 export const CompileOnSaveEmitFile : protocol . CommandTypes . CompileOnSaveEmitFile = "compileOnSaveEmitFile" ;
114113 export const Configure : protocol . CommandTypes . Configure = "configure" ;
@@ -1168,8 +1167,11 @@ namespace ts.server {
11681167
11691168 return args . entryNames . reduce ( ( accum : protocol . CompletionEntryDetails [ ] , entryName : string ) => {
11701169 const details = project . getLanguageService ( ) . getCompletionEntryDetails ( file , position , entryName ) ;
1170+ const mappedCodeActions = map ( details . codeActions , action => this . mapCodeAction ( action , scriptInfo ) ) ;
1171+ const mappedDetails = details as ( CompletionEntryDetails | protocol . CompletionEntryDetails ) ;
1172+ mappedDetails . codeActions = mappedCodeActions ;
11711173 if ( details ) {
1172- accum . push ( details ) ;
1174+ accum . push ( < protocol . CompletionEntryDetails > mappedDetails ) ;
11731175 }
11741176 return accum ;
11751177 } , [ ] ) ;
@@ -1197,11 +1199,6 @@ namespace ts.server {
11971199 return result ;
11981200 }
11991201
1200- private getCodeActionAfterCommittingCompletion ( args : protocol . CommitCompletionWithCodeActionRequestArgs ) {
1201- const { itemName, sourceFileName } = args ;
1202- const { file, project } = this . getFileAndProject ( args ) ;
1203- }
1204-
12051202 private emitFile ( args : protocol . CompileOnSaveEmitFileRequestArgs ) {
12061203 const { file, project } = this . getFileAndProject ( args ) ;
12071204 if ( ! project ) {
@@ -1686,9 +1683,6 @@ namespace ts.server {
16861683 [ CommandNames . CompileOnSaveEmitFile ] : ( request : protocol . CompileOnSaveEmitFileRequest ) => {
16871684 return this . requiredResponse ( this . emitFile ( request . arguments ) ) ;
16881685 } ,
1689- [ CommandNames . CommitCompletionWithCodeAction ] : ( request : protocol . CommitCompletionWithCodeActionRequest ) => {
1690- return this . requiredResponse ( this . getCodeActionAfterCommittingCompletion ( request . arguments ) ) ;
1691- } ,
16921686 [ CommandNames . SignatureHelp ] : ( request : protocol . SignatureHelpRequest ) => {
16931687 return this . requiredResponse ( this . getSignatureHelpItems ( request . arguments , /*simplifiedResult*/ true ) ) ;
16941688 } ,
0 commit comments