Skip to content

Commit

Permalink
fix(vscode): let linkedEditing work when tag name contains .
Browse files Browse the repository at this point in the history
  • Loading branch information
dyc3 committed Nov 7, 2024
1 parent 6180537 commit 7075ec5
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions packages/svelte-vscode/src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -286,10 +286,11 @@ export function activateSvelteLanguageServer(context: ExtensionContext) {
// - Is a number with an optional negative sign and optional full number
// with numbers following the decimal point. e.g `-1.1px`, `.5`, `-.42rem`, etc
// - Is a sequence of characters without spaces and not containing
// any of the following: `~!@$^&*()=+[{]}\|;:'",.<>/
// any of the following: `~!@$^&*()=+[{]}\|;:'",<>/
// `.` is intentionally included in the word pattern to support property access for Svelte components.
//
wordPattern:
/(-?\d*\.\d\w*)|([^\`\~\!\@\#\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,
/(-?\d*\.\d\w*)|([^\`\~\!\@\#\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\<\>\/\s]+)/g,
onEnterRules: [
{
// Matches an opening tag that:
Expand Down Expand Up @@ -531,8 +532,8 @@ function warnIfOldExtensionInstalled() {
if (extensions.getExtension('JamesBirtles.svelte-vscode')) {
window.showWarningMessage(
'It seems you have the old and deprecated extension named "Svelte" installed. Please remove it. ' +
'Through the UI: You can find it when searching for "@installed" in the extensions window (searching "Svelte" won\'t work). ' +
'Command line: "code --uninstall-extension JamesBirtles.svelte-vscode"'
'Through the UI: You can find it when searching for "@installed" in the extensions window (searching "Svelte" won\'t work). ' +
'Command line: "code --uninstall-extension JamesBirtles.svelte-vscode"'
);
}
}

0 comments on commit 7075ec5

Please sign in to comment.