amis.define("fa3a791",function(e,t){"use strict";function n(e,t){var n=h.getColorValue(e);if(n){var r=o(e,t);return{color:n,range:r}}return null}function r(e,t,n){if(0===t.getChildren().length)return null;var r=t.getChild(0);return a(e,r,n)}function a(e,t,n){var r=t.getText(),a=o(t,e);if(a.start.line===a.end.line&&a.start.character===a.end.character)return null;(g.startsWith(r,"'")||g.startsWith(r,'"'))&&(r=r.slice(1,-1));var u;return u=g.startsWith(r,"http://")||g.startsWith(r,"https://")?r:/^\w+:\/\//g.test(r)?r:"scss"===e.languageId?g.endsWith(r,".css")||g.startsWith(r,"http://")||g.startsWith(r,"https://")||t.parent&&t.parent.type===f.NodeType.URILiteral||1!==t.parent.getChildren().length?n.resolveReference(r,e.uri):i(n.resolveReference(r,e.uri)):n.resolveReference(r,e.uri),{range:a,target:u}}function i(e){return e.replace(/\/(\w+)(.scss)?$/gm,function(e,t){return"/_"+t+".scss"})}function o(e,t){return l.Range.create(t.positionAt(e.offset),t.positionAt(e.end))}function u(e){if(e.type===f.NodeType.Selector)return l.DocumentHighlightKind.Write;if(e instanceof f.Identifier&&e.parent&&e.parent instanceof f.Property&&e.isCustomProperty)return l.DocumentHighlightKind.Write;if(e.parent)switch(e.parent.type){case f.NodeType.FunctionDeclaration:case f.NodeType.MixinDeclaration:case f.NodeType.Keyframe:case f.NodeType.VariableDeclaration:case f.NodeType.FunctionParameter:return l.DocumentHighlightKind.Write}return l.DocumentHighlightKind.Read}function c(e){var t=e.toString(16);return 2!==t.length?"0"+t:t}Object.defineProperty(t,"__esModule",{value:!0});var s=e("11ed2ab"),l=e("bbb15f3"),p=s.__importStar(e("df29dc9")),f=s.__importStar(e("f5750f9")),d=e("36989ab"),h=e("60fb112"),g=e("8ee4125"),y=p.loadMessageBundle(),m=function(){function e(){}return e.prototype.findDefinition=function(e,t,n){var r=new d.Symbols(n),a=e.offsetAt(t),i=f.getNodeAtOffset(n,a);if(!i)return null;var u=r.findSymbolFromNode(i);return u?{uri:e.uri,range:o(u.node,e)}:null},e.prototype.findReferences=function(e,t,n){var r=this.findDocumentHighlights(e,t,n);return r.map(function(t){return{uri:e.uri,range:t.range}})},e.prototype.findDocumentHighlights=function(e,t,n){var r=[],a=e.offsetAt(t),i=f.getNodeAtOffset(n,a);if(!i||i.type===f.NodeType.Stylesheet||i.type===f.NodeType.Declarations)return r;i.type===f.NodeType.Identifier&&i.parent&&i.parent.type===f.NodeType.ClassSelector&&(i=i.parent);var c=new d.Symbols(n),s=c.findSymbolFromNode(i),l=i.getText();return n.accept(function(t){if(s){if(c.matchesSymbol(t,s))return r.push({kind:u(t),range:o(t,e)}),!1}else i.type===t.type&&i.length===t.length&&l===t.getText()&&r.push({kind:u(t),range:o(t,e)});return!0}),r},e.prototype.findDocumentLinks=function(e,t,n){var i=[];return t.accept(function(t){if(t.type===f.NodeType.URILiteral){var o=r(e,t,n);return o&&i.push(o),!1}if(t.parent&&t.parent.type===f.NodeType.Import){var u=t.getText();return(g.startsWith(u,"'")||g.startsWith(u,'"'))&&i.push(a(e,t,n)),!1}return!0}),i},e.prototype.findDocumentSymbols=function(e,t){var n=[];return t.accept(function(t){var r={name:null,kind:l.SymbolKind.Class,location:null},a=t;return t instanceof f.Selector?(r.name=t.getText(),a=t.findAParent(f.NodeType.Ruleset,f.NodeType.ExtendsReference),a&&(r.location=l.Location.create(e.uri,o(a,e)),n.push(r)),!1):(t instanceof f.VariableDeclaration?(r.name=t.getName(),r.kind=l.SymbolKind.Variable):t instanceof f.MixinDeclaration?(r.name=t.getName(),r.kind=l.SymbolKind.Method):t instanceof f.FunctionDeclaration?(r.name=t.getName(),r.kind=l.SymbolKind.Function):t instanceof f.Keyframe?r.name=y("literal.keyframes","@keyframes {0}",t.getName()):t instanceof f.FontFace&&(r.name=y("literal.fontface","@font-face")),r.name&&(r.location=l.Location.create(e.uri,o(a,e)),n.push(r)),!0)}),n},e.prototype.findDocumentColors=function(e,t){var r=[];return t.accept(function(t){var a=n(t,e);return a&&r.push(a),!0}),r},e.prototype.getColorPresentations=function(e,t,n,r){var a,i=[],o=Math.round(255*n.red),u=Math.round(255*n.green),s=Math.round(255*n.blue);a=1===n.alpha?"rgb("+o+", "+u+", "+s+")":"rgba("+o+", "+u+", "+s+", "+n.alpha+")",i.push({label:a,textEdit:l.TextEdit.replace(r,a)}),a=1===n.alpha?"#"+c(o)+c(u)+c(s):"#"+c(o)+c(u)+c(s)+c(Math.round(255*n.alpha)),i.push({label:a,textEdit:l.TextEdit.replace(r,a)});var p=h.hslFromColor(n);return a=1===p.a?"hsl("+p.h+", "+Math.round(100*p.s)+"%, "+Math.round(100*p.l)+"%)":"hsla("+p.h+", "+Math.round(100*p.s)+"%, "+Math.round(100*p.l)+"%, "+p.a+")",i.push({label:a,textEdit:l.TextEdit.replace(r,a)}),i},e.prototype.doRename=function(e,t,n,r){var a,i=this.findDocumentHighlights(e,t,r),o=i.map(function(e){return l.TextEdit.replace(e.range,n)});return{changes:(a={},a[e.uri]=o,a)}},e}();t.CSSNavigation=m});