You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Toggle line comment, comment as block in scss files #15013
I expect to be comment as a line with //, but it get surrounded by /* */ instead.
If I have a line commented with // it just surround again the line with /* */.
If I have the line surrounded with /* */ it toggle.
Yep. I think it is. I would edit that an say that it does not matter where you try to toggle, it will use CSS style to comment instead of the SASS ones, cause if you invoke that from the command pallete it will have the same behavior.
alexandrudima, If I fully understand your code, this should help:
functiontoModeTransitions(topLevelModeId: string,modeTransitions: ModeTransition[],tokens: Token[]): ModeTransition[]{if(!modeTransitions||modeTransitions.length===0){returnnull;}elseif(modeTransitions.length===1&&modeTransitions[0].startIndex===0&&modeTransitions[0].modeId===topLevelModeId){returnnull;}// If tokens has embedded scopes, then return the transition modesfor(leti=0;i<tokens.length;i++){if(tokens[i].type.indexOf('embedded')!==-1){returnmodeTransitions;}}returnnull;}
Activity
rebornix commentedon Nov 4, 2016
This one might be related to #14661 as well.
michaeljota commentedon Nov 4, 2016
Yep. I think it is. I would edit that an say that it does not matter where you try to toggle, it will use CSS style to comment instead of the SASS ones, cause if you invoke that from the command pallete it will have the same behavior.
mrmlnc commentedon Nov 4, 2016
Michael De Abreu (@michaeljota), Peng Lyu (@rebornix),
Yes, this is fully related to #14661. VS Code 1.7.0/1.7.1 has incorrect behaviour with finding scopes at the cursor position. See Martin Aeschlimann (@aeschli) comment: #14661 (comment)
mrmlnc commentedon Nov 4, 2016
alexandrudima, If I fully understand your code, this should help:
Works fine for all issues.
alexdima commentedon Nov 8, 2016
Duplicate of #14661