diff --git a/CHANGELOG.md b/CHANGELOG.md index f655779..fc8fea5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,11 @@ All notable changes to this project will be documented in this file. This project tries to adhere to [Semantic Versioning](http://semver.org/). +## 1.4.0 - 2017-08-25 +### Added +- Support for Vue Component Files using HTML mode (see [#98](https://github.com/Hirse/brackets-outline-list/issues/98)) + + ## 1.3.1 - 2017-08-25 ### Fixed - Support Python default parameter floats (see [#97](https://github.com/Hirse/brackets-outline-list/issues/97)) diff --git a/main.js b/main.js index 2958005..0910374 100644 --- a/main.js +++ b/main.js @@ -20,24 +20,25 @@ define(function (require, exports, module) { /* beautify preserve:start *//* eslint-disable key-spacing */ var languageMapping = { - JavaScript: "JavaScript", - JSX: "JavaScript", - Haxe: "Haxe", - CoffeeScript: "CoffeeScript", - CSS: "CSS", - SCSS: "CSS", - LESS: "CSS", - Stylus: "Stylus", - PHP: "PHP", - Ruby: "Ruby", - Python: "Python", - Markdown: "Markdown", - "Markdown (GitHub)": "Markdown", - XML: "XML", - HTML: "XML", - "Embedded Ruby": "XML", - SVG: "XML", - Jade: "Jade" + JavaScript: "JavaScript", + JSX: "JavaScript", + Haxe: "Haxe", + CoffeeScript: "CoffeeScript", + CSS: "CSS", + SCSS: "CSS", + LESS: "CSS", + Stylus: "Stylus", + PHP: "PHP", + Ruby: "Ruby", + Python: "Python", + Markdown: "Markdown", + "Markdown (GitHub)": "Markdown", + XML: "XML", + HTML: "XML", + "Embedded Ruby": "XML", + SVG: "XML", + "Vue component file": "XML", + Jade: "Jade" }; /* eslint-enable key-spacing *//* beautify preserve:end */ diff --git a/package.json b/package.json index d7e9c17..21e7d1e 100755 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "hirse.outline-list", - "version": "1.3.1", + "version": "1.4.0", "title": "Brackets Outline List", "description": "Displays a list of the functions or definitions in the currently opened document. Works with CSS, CoffeeScript, HTML, Haxe, Jade, JavaScript, JSX, LESS, Markdown, PHP, Python, Ruby, SCSS, SVG, Stylus, and XML.", "engines": { @@ -40,7 +40,7 @@ "pl" ], "package-i18n": { - "ar":{ + "ar": { "description": " CSS, CoffeeScript, HTML, Haxe, Jade, JavaScript, JSX, LESS, Markdown, PHP, Python, Ruby, SCSS, SVG, Stylus, and XML.يعرض قائم بالوظائف أو التعريفات في الوثيقة المفتوحة حاليا ، يعمل مع لغة" }, "de": { diff --git a/test/XMLSpec.js b/test/XMLSpec.js index d191bf7..80c41fb 100644 --- a/test/XMLSpec.js +++ b/test/XMLSpec.js @@ -149,5 +149,32 @@ define(function XMLSpec(require) { done(); }); }); + + + it("detects html in vue", function (done) { + var test = require("text!example/html/vue.vue"); + Parser.parse(test).then(function (result) { + expect(result).toEqual([ + { + name: "template", + namespace: "", + level: 0, + id: "", + class: [], + line: 1, + ch: 0 + }, { + name: "div", + namespace: "", + level: 1, + id: "", + class: [], + line: 2, + ch: 4 + } + ]); + done(); + }); + }); }); }); diff --git a/test/example/html/vue.vue b/test/example/html/vue.vue new file mode 100644 index 0000000..80a9cc2 --- /dev/null +++ b/test/example/html/vue.vue @@ -0,0 +1,4 @@ + +