File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
packages/tailwindcss-language-service/src Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -499,8 +499,8 @@ async function provideCustomClassNameCompletions(
499499 const positionOffset = document . offsetAt ( position )
500500
501501 const searchRange : Range = {
502- start : document . positionAt ( Math . max ( 0 , positionOffset - 1000 ) ) ,
503- end : document . positionAt ( positionOffset + 1000 ) ,
502+ start : document . positionAt ( 0 ) ,
503+ end : document . positionAt ( positionOffset + 2000 ) ,
504504 }
505505
506506 let str = document . getText ( searchRange )
Original file line number Diff line number Diff line change @@ -135,7 +135,7 @@ async function findCustomClassLists(
135135
136136 if ( ! Array . isArray ( regexes ) || regexes . length === 0 ) return [ ]
137137
138- const text = doc . getText ( range )
138+ const text = doc . getText ( range ? { ... range , start : doc . positionAt ( 0 ) } : undefined )
139139 const result : DocumentClassList [ ] = [ ]
140140
141141 for ( let i = 0 ; i < regexes . length ; i ++ ) {
You can’t perform that action at this time.
0 commit comments