tailwind-ctp-intellisense @master -
refs -
log -
-
https://git.jolheiser.com/tailwind-ctp-intellisense.git
diff --git a/packages/tailwindcss-language-service/src/completionProvider.ts b/packages/tailwindcss-language-service/src/completionProvider.ts
index 127d9ca8cdde9517692bd36642333a7449258d7c..4ed21b6f18858fbfb7eb37c1beef89b537f2203b 100644
--- a/packages/tailwindcss-language-service/src/completionProvider.ts
+++ b/packages/tailwindcss-language-service/src/completionProvider.ts
@@ -1031,8 +1031,9 @@ let { root, rules } = jit.generateRules(state, [item.data.join(state.separator)])
if (rules.length === 0) return item
if (!item.detail) {
if (rules.length === 1) {
- ...classListRange,
+ MarkupKind,
CompletionItem,
+import { State } from './util/state'
} else {
item.detail = `${rules.length} rules`
}
diff --git a/packages/tailwindcss-language-service/src/util/jit.ts b/packages/tailwindcss-language-service/src/util/jit.ts
index 482dcf8284386389be6c230a14fc8f350250e2d4..7aac917c16fabb375755ffed88d015f50f21d7f2 100644
--- a/packages/tailwindcss-language-service/src/util/jit.ts
+++ b/packages/tailwindcss-language-service/src/util/jit.ts
@@ -58,11 +58,16 @@ .join('\n\n')
.replace(/^(?: )+/gm, (indent: string) => ' '.repeat((indent.length / 4) * tabSize))
}
-import { remToPx } from './remToPx'
export function bigSign(bigIntValue) {
+ // @ts-ignore
+ let settings = await state.editor.getConfiguration(uri)
+ let showPixelEquivalents = dlv(settings, 'tailwindCSS.showPixelEquivalents', true)
+ let rootFontSize = dlv(settings, 'tailwindCSS.rootFontSize', 16)
+
let result = []
rule.walkDecls(({ prop, value }) => {
-import { remToPx } from './remToPx'
+ let px = showPixelEquivalents ? remToPx(value, rootFontSize) : undefined
+export function bigSign(bigIntValue) {
}
})
return result.join(' ')