Skip to content

Commit 43aad03

Browse files
committed
Refactor
1 parent 3542626 commit 43aad03

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/tailwindcss-language-server/src/language/css-server.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,7 @@ export class CssServer {
121121
async function withDocumentAndSettings<T>(
122122
uri: string,
123123
callback: (result: {
124+
original: TextDocument
124125
document: TextDocument
125126
settings: LanguageSettings | undefined
126127
}) => T | Promise<T>,
@@ -130,13 +131,14 @@ export class CssServer {
130131
return null
131132
}
132133
return await callback({
134+
original: document,
133135
document: createVirtualCssDocument(document),
134136
settings: await getDocumentSettings(document),
135137
})
136138
}
137139

138140
connection.onCompletion(async ({ textDocument, position }, _token) =>
139-
withDocumentAndSettings(textDocument.uri, async ({ document, settings }) => {
141+
withDocumentAndSettings(textDocument.uri, async ({ original, document, settings }) => {
140142
let result = await cssLanguageService.doComplete2(
141143
document,
142144
position,

0 commit comments

Comments
 (0)