mirror of
https://github.com/Microsoft/vscode
synced 2024-09-13 21:55:38 +00:00
Remove the onEnter rules from html in php as they will never get applied in a php block #39142
This commit is contained in:
parent
7d45b64ca8
commit
6aa6f0d332
|
@ -13,8 +13,6 @@ import PHPHoverProvider from './features/hoverProvider';
|
|||
import PHPSignatureHelpProvider from './features/signatureHelpProvider';
|
||||
import PHPValidationProvider from './features/validationProvider';
|
||||
|
||||
const EMPTY_ELEMENTS: string[] = ['area', 'base', 'br', 'col', 'embed', 'hr', 'img', 'input', 'keygen', 'link', 'menuitem', 'meta', 'param', 'source', 'track', 'wbr'];
|
||||
|
||||
export function activate(context: vscode.ExtensionContext): any {
|
||||
|
||||
let validator = new PHPValidationProvider(context.workspaceState);
|
||||
|
@ -54,15 +52,6 @@ export function activate(context: vscode.ExtensionContext): any {
|
|||
// e.g. *-----*/|
|
||||
beforeText: /^(\t|(\ \ ))*\ \*[^/]*\*\/\s*$/,
|
||||
action: { indentAction: vscode.IndentAction.None, removeText: 1 }
|
||||
},
|
||||
{
|
||||
beforeText: new RegExp(`<(?!(?:${EMPTY_ELEMENTS.join('|')}))([_:\\w][_:\\w-.\\d]*)([^/>]*(?!/)>)[^<]*$`, 'i'),
|
||||
afterText: /^<\/([_:\w][_:\w-.\d]*)\s*>/i,
|
||||
action: { indentAction: vscode.IndentAction.IndentOutdent }
|
||||
},
|
||||
{
|
||||
beforeText: new RegExp(`<(?!(?:${EMPTY_ELEMENTS.join('|')}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`, 'i'),
|
||||
action: { indentAction: vscode.IndentAction.Indent }
|
||||
}
|
||||
]
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue