From 94189a72c3427c5a98af4adbc988ac5b30c9038b Mon Sep 17 00:00:00 2001 From: Alessio Occhipinti Date: Thu, 3 May 2018 11:39:51 +0200 Subject: [PATCH] Refactor/linting - tslint-xo (#178) * refactor(deps): added tslint, cleanup, and activationEvents modified * refactor(lint): linting... * refactor(changelog): changelo method refactor (should be tested) * refactor(theme-icons): linting and small refactor * refactor(accents-setter): linting and small refactor * chore(travis): added travis file --- .gulp/consts/log.ts | 2 +- .gulp/interfaces/itheme-icons-accents.ts | 6 +- .gulp/interfaces/itheme-icons-item.ts | 2 +- .gulp/interfaces/itheme-icons-variants.ts | 28 +- .gulp/tasks/changelog-title.ts | 9 +- .gulp/tasks/icons-accents.ts | 60 +- .gulp/tasks/icons-variants.ts | 57 +- .gulp/tasks/icons.ts | 48 +- .gulp/tasks/themes.ts | 33 +- .gulp/tasks/watcher.ts | 10 +- .travis.yml | 6 + .vscode/settings.json | 1 + extensions/commands/accents-setter/index.ts | 103 +- extensions/commands/theme-icons/index.ts | 97 +- extensions/consts/files.ts | 3 +- extensions/consts/paths.ts | 2 +- extensions/helpers/changelog.ts | 84 +- extensions/helpers/fs.ts | 66 +- extensions/helpers/settings.ts | 31 +- extensions/helpers/vscode.ts | 27 +- .../interfaces/iaccent-custom-property.ts | 2 +- extensions/interfaces/idefaults.ts | 32 +- extensions/interfaces/igeneric-object.ts | 2 +- extensions/interfaces/ipackage.json.ts | 48 +- extensions/interfaces/ipaths.ts | 12 +- .../interfaces/itheme-custom-properties.ts | 2 +- extensions/interfaces/itheme-icons.ts | 1013 +++++++++-------- extensions/material.theme.config.ts | 9 +- gulpfile.babel.ts | 2 +- package.json | 11 +- tsconfig.json | 2 +- tslint.json | 7 + yarn.lock | 479 ++------ 33 files changed, 994 insertions(+), 1302 deletions(-) create mode 100644 .travis.yml create mode 100644 tslint.json diff --git a/.gulp/consts/log.ts b/.gulp/consts/log.ts index bc933ba..94dba4d 100644 --- a/.gulp/consts/log.ts +++ b/.gulp/consts/log.ts @@ -4,4 +4,4 @@ export const MESSAGE_BUMP_SUCCESS: string = ' Finished successfully\n'; export const MESSAGE_ICON_ERROR: string = 'There is an error with JSON generated for icons'; export const MESSAGE_ICON_ACCENTS_ERROR: string = 'Failed to create accents icon themes, please read the log file.'; export const MESSAGE_GENERATED: string = 'Generated'; -export const MESSAGE_THEME_VARIANT_PARSE_ERROR: string = 'Error when parsing json for theme variants'; \ No newline at end of file +export const MESSAGE_THEME_VARIANT_PARSE_ERROR: string = 'Error when parsing json for theme variants'; diff --git a/.gulp/interfaces/itheme-icons-accents.ts b/.gulp/interfaces/itheme-icons-accents.ts index e2a5324..8f60ca1 100644 --- a/.gulp/interfaces/itheme-icons-accents.ts +++ b/.gulp/interfaces/itheme-icons-accents.ts @@ -1,8 +1,8 @@ -import { IThemeIconsItem } from "./itheme-icons-item"; +import {IThemeIconsItem} from './itheme-icons-item'; export interface IThemeIconsAccents { iconDefinitions: { _folder_open: IThemeIconsItem; _folder_open_build: IThemeIconsItem; - } -} \ No newline at end of file + }; +} diff --git a/.gulp/interfaces/itheme-icons-item.ts b/.gulp/interfaces/itheme-icons-item.ts index 1a5c615..964462c 100644 --- a/.gulp/interfaces/itheme-icons-item.ts +++ b/.gulp/interfaces/itheme-icons-item.ts @@ -1,3 +1,3 @@ export interface IThemeIconsItem { iconPath: string; -} \ No newline at end of file +} diff --git a/.gulp/interfaces/itheme-icons-variants.ts b/.gulp/interfaces/itheme-icons-variants.ts index 15e91e7..93c2bfb 100644 --- a/.gulp/interfaces/itheme-icons-variants.ts +++ b/.gulp/interfaces/itheme-icons-variants.ts @@ -1,17 +1,17 @@ -import { IThemeIconsItem } from "./itheme-icons-item"; +import {IThemeIconsItem} from './itheme-icons-item'; export interface IThemeIconsVariants { iconDefinitions: { - "_folder_dark": IThemeIconsItem; - "_folder_dark_build": IThemeIconsItem; - "_folder_light": IThemeIconsItem; - "_folder_light_build": IThemeIconsItem; - "_folder_vscode": IThemeIconsItem; - "_folder_gulp": IThemeIconsItem; - "_folder_node": IThemeIconsItem; - "_folder_images": IThemeIconsItem; - "_folder_js": IThemeIconsItem; - "_folder_src": IThemeIconsItem; - "_folder_assets": IThemeIconsItem; - } -} \ No newline at end of file + _folder_dark: IThemeIconsItem; + _folder_dark_build: IThemeIconsItem; + _folder_light: IThemeIconsItem; + _folder_light_build: IThemeIconsItem; + _folder_vscode: IThemeIconsItem; + _folder_gulp: IThemeIconsItem; + _folder_node: IThemeIconsItem; + _folder_images: IThemeIconsItem; + _folder_js: IThemeIconsItem; + _folder_src: IThemeIconsItem; + _folder_assets: IThemeIconsItem; + }; +} diff --git a/.gulp/tasks/changelog-title.ts b/.gulp/tasks/changelog-title.ts index c892c40..e8da38a 100644 --- a/.gulp/tasks/changelog-title.ts +++ b/.gulp/tasks/changelog-title.ts @@ -1,11 +1,10 @@ -import * as gulp from "gulp"; import * as fs from 'fs'; -import { CHARSET } from "../../extensions/consts/files"; - +import * as gulp from 'gulp'; +import {CHARSET} from './../../extensions/consts/files'; export default gulp.task('changelog-title', () => { fs.writeFileSync( './CHANGELOG.md', fs.readFileSync('CHANGELOG.md', CHARSET).replace('# Change Log', '# Material Theme Changelog'), - { encoding: CHARSET }); -}); \ No newline at end of file + {encoding: CHARSET}); +}); diff --git a/.gulp/tasks/icons-accents.ts b/.gulp/tasks/icons-accents.ts index a643185..f0b6466 100644 --- a/.gulp/tasks/icons-accents.ts +++ b/.gulp/tasks/icons-accents.ts @@ -3,22 +3,19 @@ import * as gulp from 'gulp'; import * as gutil from 'gulp-util'; import * as path from 'path'; -import { MESSAGE_GENERATED, MESSAGE_ICON_ACCENTS_ERROR } from "../consts/log"; +import {MESSAGE_GENERATED, MESSAGE_ICON_ACCENTS_ERROR} from './../consts/log'; -import { CHARSET } from "../../extensions/consts/files"; -import { IDefaults } from "../../extensions/interfaces/idefaults"; -import { IThemeIconsAccents } from "../interfaces/itheme-icons-accents"; -import PATHS from '../../extensions/consts/paths' -import { IThemeIconsItem } from '../interfaces/itheme-icons-item'; -import { getAccentableIcons } from '../../extensions/helpers/fs'; +import {CHARSET} from './../../extensions/consts/files'; +import {IThemeIconsAccents} from './../interfaces/itheme-icons-accents'; +import PATHS from './../../extensions/consts/paths'; +import {IThemeIconsItem} from './../interfaces/itheme-icons-item'; +import {getAccentableIcons, getDefaultValues} from './../../extensions/helpers/fs'; const BASE_ICON_THEME_PATH: string = path.join(process.cwd(), PATHS.THEMES, './Material-Theme-Icons.json'); -const DEFAULTS: IDefaults = require('../../extensions/defaults.json'); +const DEFAULTS = getDefaultValues(); /** * Normalizes icon path - * @param {string} iconPath - * @returns {string} */ function normalizeIconPath(iconPath: string): string { return path.join(process.cwd(), PATHS.ICONS, iconPath); @@ -26,9 +23,6 @@ function normalizeIconPath(iconPath: string): string { /** * Replaces a file name with the accented filename - * @param {string} name - * @param {string} accentName - * @returns {string} */ function replaceNameWithAccent(name: string, accentName: string): string { return name.replace('.svg', `.accent.${ accentName }.svg`); @@ -36,24 +30,17 @@ function replaceNameWithAccent(name: string, accentName: string): string { /** * Replaces a SVG colour - * - * @param {string} filecontent - * @param {string} colour - * @returns {string} */ export function replaceSVGColour(filecontent: string, colour: string): string { return filecontent.replace(new RegExp('#(80CBC4)', 'i'), ($0, $1) => { - - colour = colour.replace('#', ''); - console.log(`Replacing colour ${ $1 } with ${ colour }`) - return $0.replace($1, colour); + const newColour = colour.replace('#', ''); + console.log(`Replacing colour ${ $1 } with ${ newColour }`); + return $0.replace($1, newColour); }); } /** * Replaces white spaces in accents' names - * @param {string} input - * @returns {string} */ function replaceWhiteSpaces(input: string): string { return input.replace(/\s+/g, '-'); @@ -61,18 +48,15 @@ function replaceWhiteSpaces(input: string): string { /** * Writes a new svg file - * @param {string} fromFile - * @param {string} toFile - * @param {string} accentColour */ function writeSVGIcon(fromFile: string, toFile: string, accent: string): void { - let fileContent: string = fs.readFileSync(normalizeIconPath(fromFile), CHARSET); - let content: string = replaceSVGColour(fileContent, DEFAULTS.accents[accent]); - toFile = normalizeIconPath(toFile); + const fileContent: string = fs.readFileSync(normalizeIconPath(fromFile), CHARSET); + const content: string = replaceSVGColour(fileContent, DEFAULTS.accents[accent]); + const pathToFile = normalizeIconPath(toFile); - gutil.log(gutil.colors.gray(`Accented icon ${toFile} created with colour ${ accent } (${ DEFAULTS.accents[accent] })`)); + gutil.log(gutil.colors.gray(`Accented icon ${pathToFile} created with colour ${ accent } (${ DEFAULTS.accents[accent] })`)); - fs.writeFileSync(toFile, content); + fs.writeFileSync(pathToFile, content); } // Exports task to index.ts @@ -83,21 +67,21 @@ export default gulp.task('build:icons.accents', cb => { basetheme = require(BASE_ICON_THEME_PATH); Object.keys(DEFAULTS.accents).forEach(key => { - let iconName = replaceWhiteSpaces(key); - let themecopy: IThemeIconsAccents = JSON.parse(JSON.stringify(basetheme)); - let themePath: string = path.join(PATHS.THEMES, `./Material-Theme-Icons-${ key }.json`); + const iconName = replaceWhiteSpaces(key); + const themecopy: IThemeIconsAccents = JSON.parse(JSON.stringify(basetheme)); + const themePath: string = path.join(PATHS.THEMES, `./Material-Theme-Icons-${ key }.json`); getAccentableIcons().forEach(accentableIconName => { gutil.log(gutil.colors.gray(`Preparing ${ accentableIconName } accented icon`)); - let iconOriginDefinition: IThemeIconsItem = (basetheme.iconDefinitions as any)[accentableIconName]; - let iconCopyDefinition: IThemeIconsItem = (themecopy.iconDefinitions as any)[accentableIconName]; + const iconOriginDefinition: IThemeIconsItem = (basetheme.iconDefinitions as any)[accentableIconName]; + const iconCopyDefinition: IThemeIconsItem = (themecopy.iconDefinitions as any)[accentableIconName]; if (iconOriginDefinition !== undefined && typeof iconOriginDefinition.iconPath === 'string' && iconCopyDefinition !== undefined && typeof iconCopyDefinition.iconPath === 'string') { iconCopyDefinition.iconPath = replaceNameWithAccent(iconOriginDefinition.iconPath, iconName); writeSVGIcon(iconOriginDefinition.iconPath, iconCopyDefinition.iconPath, key); } else { - gutil.log(gutil.colors.yellow(`Icon ${ accentableIconName } not found`)) + gutil.log(gutil.colors.yellow(`Icon ${ accentableIconName } not found`)); } }); @@ -124,4 +108,4 @@ export default gulp.task('build:icons.accents', cb => { } cb(); -}); \ No newline at end of file +}); diff --git a/.gulp/tasks/icons-variants.ts b/.gulp/tasks/icons-variants.ts index c95f049..6c0232c 100644 --- a/.gulp/tasks/icons-variants.ts +++ b/.gulp/tasks/icons-variants.ts @@ -1,44 +1,47 @@ -import {getVariantIcons} from '../../extensions/helpers/fs'; import * as gulp from 'gulp'; import * as path from 'path'; import * as fs from 'fs'; -import { CHARSET } from "../../extensions/consts/files"; -import { IPackageJSON } from "../../extensions/interfaces/ipackage.json"; -import { IThemeIconsVariants } from "../interfaces/itheme-icons-variants"; -import PATHS from '../../extensions/consts/paths' -import { getDefaultValues } from "../../extensions/helpers/fs"; -import { IDefaultsThemeVariantColours } from "../../extensions/interfaces/idefaults"; -import { IThemeIconsItem } from '../interfaces/itheme-icons-item'; +import {IThemeIconsVariants} from '../interfaces/itheme-icons-variants'; +import {CHARSET} from './../../extensions/consts/files'; +import PATHS from './../../extensions/consts/paths'; +import {getDefaultValues, getVariantIcons, getPackageJSON} from './../../extensions/helpers/fs'; +import {IDefaultsThemeVariant} from './../../extensions/interfaces/idefaults'; +import {IThemeIconsItem} from './../interfaces/itheme-icons-item'; -const PACKAGE_JSON: IPackageJSON = require(path.join(process.cwd(), './package.json')); +const PACKAGE_JSON = getPackageJSON(); -let variants: IDefaultsThemeVariantColours = getDefaultValues().themeVariantsColours; - -function writeIconVariant(filepath: string, destpath: string, colour: string): void { - let regexp = new RegExp('(#4a616c)', 'i') - filepath = path.join(process.cwd(), PATHS.ICONS, filepath); - destpath = path.join(process.cwd(), PATHS.ICONS, destpath); - fs.writeFileSync(destpath, fs.readFileSync(filepath, CHARSET).replace(regexp, ($0, $1) => $0.replace($1, colour)), { encoding: CHARSET }) ; -} +const variants: IDefaultsThemeVariant = getDefaultValues().themeVariantsColours; +const writeIconVariant = (filepath: string, destpath: string, colour: string): void => { + const regexp = new RegExp('(#4a616c)', 'i'); + const finalFilePath = path.join(process.cwd(), PATHS.ICONS, filepath); + const finalDestpath = path.join(process.cwd(), PATHS.ICONS, destpath); + fs.writeFileSync( + finalDestpath, + fs.readFileSync(finalFilePath, CHARSET) + .replace(regexp, ($0, $1) => $0.replace($1, colour)), {encoding: CHARSET} + ); +}; export default gulp.task('build:icons.variants', callback => { try { Object.keys(variants).forEach(variantName => { PACKAGE_JSON.contributes.iconThemes.forEach(contribute => { - let regexpCheck: RegExp = new RegExp(Object.keys(variants).join('|'), 'i'); + const regexpCheck: RegExp = new RegExp(Object.keys(variants).join('|'), 'i'); - if (regexpCheck.test(contribute.path) || regexpCheck.test(contribute.id)) return; + if (regexpCheck.test(contribute.path) || regexpCheck.test(contribute.id)) { + return; + } - let basepath: string = path.join(process.cwd(), contribute.path); - let basetheme: IThemeIconsVariants = require(basepath); - let theme: IThemeIconsVariants = JSON.parse(JSON.stringify(basetheme)); - let variant = variants[variantName]; + const basepath: string = path.join(process.cwd(), contribute.path); + const basetheme: IThemeIconsVariants = require(basepath); + const theme: IThemeIconsVariants = JSON.parse(JSON.stringify(basetheme)); + const variant = variants[variantName]; - getVariantIcons().forEach(_iconName => { - let basethemeIcon: IThemeIconsItem = (basetheme.iconDefinitions as any)[_iconName]; - let themeIcon: IThemeIconsItem = (theme.iconDefinitions as any)[_iconName]; + getVariantIcons().forEach(iconName => { + const basethemeIcon: IThemeIconsItem = (basetheme.iconDefinitions as any)[iconName]; + const themeIcon: IThemeIconsItem = (theme.iconDefinitions as any)[iconName]; if (themeIcon !== undefined) { themeIcon.iconPath = themeIcon.iconPath.replace('.svg', `${ variantName }.svg`); @@ -57,4 +60,4 @@ export default gulp.task('build:icons.variants', callback => { } callback(); -}); \ No newline at end of file +}); diff --git a/.gulp/tasks/icons.ts b/.gulp/tasks/icons.ts index da574b7..ae3d6e7 100644 --- a/.gulp/tasks/icons.ts +++ b/.gulp/tasks/icons.ts @@ -4,24 +4,22 @@ import * as gutil from 'gulp-util'; import * as mustache from 'mustache'; import * as path from 'path'; -import { HR, MESSAGE_GENERATED, MESSAGE_ICON_ERROR } from './../consts/log'; +import {HR, MESSAGE_GENERATED, MESSAGE_ICON_ERROR} from './../consts/log'; -import { CHARSET } from "../../extensions/consts/files"; -import { IGenericObject } from "../../extensions/interfaces/igeneric-object"; -import { IIcon } from './../interfaces/iicon'; -import paths from '../../extensions/consts/paths'; -import { ensureDir } from '../../extensions/helpers/fs'; +import {CHARSET} from './../../extensions/consts/files'; +import {IGenericObject} from './../../extensions/interfaces/igeneric-object'; +import {IIcon} from './../interfaces/iicon'; +import paths from './../../extensions/consts/paths'; +import {ensureDir} from './../../extensions/helpers/fs'; /** * Returns an object implementing the IIcon interface - * @param {string} fileName - * @returns {IIcon} */ -function iconFactory(fileName: string): IIcon { - gutil.log(gutil.colors.gray(`Processing icon ${ fileName }`)) +const iconFactory = (fileName: string): IIcon => { + gutil.log(gutil.colors.gray(`Processing icon ${ fileName }`)); let name: string = path.basename(fileName, path.extname(fileName)); - let filename: string = name; - let last: boolean = false; + const filename: string = name; + const last: boolean = false; // renaming icon for vscode // if the icon filename starts with a folder prefix, @@ -35,8 +33,8 @@ function iconFactory(fileName: string): IIcon { gutil.log(gutil.colors.gray(`VSCode icon name ${ name } with filename ${ filename }`)); - return { filename, name, last } as IIcon; -} + return {filename, name, last} as IIcon; +}; /** * > Build Icons @@ -44,24 +42,26 @@ function iconFactory(fileName: string): IIcon { */ export default gulp.task('build:icons', cb => { let contents: string; - let fileNames: string[] = fs.readdirSync(path.join(paths.SRC, `./icons/svgs`)); - let icons: IIcon[] = fileNames.map(fileName => iconFactory(fileName)); - let partials: string[] = fs.readdirSync(path.join(paths.SRC, `./icons/partials`)); - let partialsData: IGenericObject = {}; - let pathTemp: string = './themes/.material-theme-icons.tmp'; + const fileNames: string[] = fs.readdirSync(path.join(paths.SRC, './icons/svgs')); + const icons: IIcon[] = fileNames.map(fileName => iconFactory(fileName)); + const partials: string[] = fs.readdirSync(path.join(paths.SRC, './icons/partials')); + const partialsData: IGenericObject = {}; + const pathTemp: string = './themes/.material-theme-icons.tmp'; ensureDir(path.join(paths.THEMES)); icons[icons.length - 1].last = true; partials.forEach(partial => { - partialsData[path.basename(partial, path.extname(partial))] = fs.readFileSync(path.join(paths.SRC, `./icons/partials`, `./${partial}`), CHARSET); + partialsData[path.basename(partial, path.extname(partial))] = fs.readFileSync( + path.join(paths.SRC, './icons/partials', `./${partial}` + ), CHARSET); }); contents = mustache.render( - fs.readFileSync(path.join(paths.SRC, `./icons/icons-theme.json`), CHARSET) - , { icons } - , partialsData + fs.readFileSync(path.join(paths.SRC, './icons/icons-theme.json'), CHARSET), + {icons}, + partialsData ); try { @@ -72,7 +72,7 @@ export default gulp.task('build:icons', cb => { return; } - fs.writeFileSync(pathTemp, contents, { encoding: CHARSET }); + fs.writeFileSync(pathTemp, contents, {encoding: CHARSET}); gutil.log(gutil.colors.gray(HR)); gutil.log(MESSAGE_GENERATED, gutil.colors.green(pathTemp)); diff --git a/.gulp/tasks/themes.ts b/.gulp/tasks/themes.ts index 9dca1a8..693ef7c 100644 --- a/.gulp/tasks/themes.ts +++ b/.gulp/tasks/themes.ts @@ -4,25 +4,24 @@ import * as gulpUtil from 'gulp-util'; import * as mustache from 'mustache'; import * as path from 'path'; -import { HR, MESSAGE_GENERATED, MESSAGE_THEME_VARIANT_PARSE_ERROR } from './../consts/log'; +import {HR, MESSAGE_GENERATED, MESSAGE_THEME_VARIANT_PARSE_ERROR} from './../consts/log'; -import { CHARSET } from "../../extensions/consts/files"; -import { IDefaults } from "../../extensions/interfaces/idefaults"; -import { IThemeVariant } from './../interfaces/itheme-variant'; -import paths from '../../extensions/consts/paths'; -import { ensureDir } from '../../extensions/helpers/fs'; +import {CHARSET} from './../../extensions/consts/files'; +import {IThemeVariant} from './../interfaces/itheme-variant'; +import paths from './../../extensions/consts/paths'; +import {ensureDir, getDefaultValues} from './../../extensions/helpers/fs'; -let commons: IDefaults = require('../../extensions/defaults.json'); +const commons = getDefaultValues(); -let themeTemplateFileContent: string = fs.readFileSync(path.join(paths.SRC, `/themes/theme-template-color-theme.json`), CHARSET); -let themeVariants: IThemeVariant[] = []; +const themeTemplateFileContent: string = fs.readFileSync(path.join(paths.SRC, '/themes/theme-template-color-theme.json'), CHARSET); +const themeVariants: IThemeVariant[] = []; -let fileNames: string[] = fs.readdirSync(path.join(paths.SRC, `./themes/settings/specific`)); +const fileNames: string[] = fs.readdirSync(path.join(paths.SRC, './themes/settings/specific')); // build theme variants for later use in templating fileNames.forEach(fileName => { - let filePath: string = path.join(paths.SRC, `./themes/settings/specific`, `./${fileName}`); - let contents: string = fs.readFileSync(filePath, CHARSET); + const filePath: string = path.join(paths.SRC, './themes/settings/specific', `./${fileName}`); + const contents: string = fs.readFileSync(filePath, CHARSET); try { themeVariants.push(JSON.parse(contents)); @@ -42,12 +41,12 @@ export default gulp.task('build:themes', cb => { try { themeVariants.forEach(variant => { - let filePath = path.join(paths.THEMES, `./${variant.name}.json`); - let templateData = { commons, variant }; - let templateJSON: any = JSON.parse(mustache.render(themeTemplateFileContent, templateData)); - let templateJSONStringified: string = JSON.stringify(templateJSON, null, 2); + const filePath = path.join(paths.THEMES, `./${variant.name}.json`); + const templateData = {commons, variant}; + const templateJSON: any = JSON.parse(mustache.render(themeTemplateFileContent, templateData)); + const templateJSONStringified: string = JSON.stringify(templateJSON, null, 2); - fs.writeFileSync(filePath, templateJSONStringified, { encoding: CHARSET }); + fs.writeFileSync(filePath, templateJSONStringified, {encoding: CHARSET}); gulpUtil.log(MESSAGE_GENERATED, gulpUtil.colors.green(filePath)); }); diff --git a/.gulp/tasks/watcher.ts b/.gulp/tasks/watcher.ts index e0be4d1..cc2dddd 100644 --- a/.gulp/tasks/watcher.ts +++ b/.gulp/tasks/watcher.ts @@ -1,7 +1,7 @@ -import * as gulp from "gulp"; -import * as path from "path"; +import * as gulp from 'gulp'; +import * as path from 'path'; -import Paths from "../../extensions/consts/paths"; +import Paths from './../../extensions/consts/paths'; /* * > Watcher @@ -10,5 +10,5 @@ import Paths from "../../extensions/consts/paths"; export default gulp.task('watch', () => { // Commented due // gulp.watch(path.join(Paths.SRC, `./themes/**/*.json`), ['build:themes']); - gulp.watch(path.join(Paths.SRC, `./themes/**/*.json`)); -}); \ No newline at end of file + gulp.watch(path.join(Paths.SRC, './themes/**/*.json')); +}); diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..ba125ba --- /dev/null +++ b/.travis.yml @@ -0,0 +1,6 @@ +language: node_js +node_js: + - '8' + +script: + - yarn test diff --git a/.vscode/settings.json b/.vscode/settings.json index e3fc186..c8a043f 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,6 +1,7 @@ { "editor.tabSize": 2, "editor.insertSpaces": true, + "files.insertFinalNewline": true, "files.exclude": { "**/.git": true, ".git-crypt": true, diff --git a/extensions/commands/accents-setter/index.ts b/extensions/commands/accents-setter/index.ts index 3b042e6..e2a90d9 100644 --- a/extensions/commands/accents-setter/index.ts +++ b/extensions/commands/accents-setter/index.ts @@ -1,107 +1,102 @@ import * as vscode from 'vscode'; -import {IAccentCustomProperty} from '../../interfaces/iaccent-custom-property'; -import { IDefaults } from "../../interfaces/idefaults"; -import {IGenericObject} from '../../interfaces/igeneric-object'; -import { updateAccent, isMaterialTheme, isMaterialThemeIcons } from "../../helpers/settings"; -import { getCurrentThemeID, getCurrentThemeIconsID, reloadWindow } from "../../helpers/vscode"; -import { THEME_ICONS } from "../theme-icons/index"; +import {IAccentCustomProperty} from './../../interfaces/iaccent-custom-property'; +import {IGenericObject} from './../../interfaces/igeneric-object'; +import { + updateAccent, + isMaterialTheme, + isMaterialThemeIcons +} from './../../helpers/settings'; +import { + getCurrentThemeID, + getCurrentThemeIconsID, + reloadWindow +} from './../../helpers/vscode'; +import {getDefaultValues} from './../../helpers/fs'; +import {THEME_ICONS} from './../theme-icons/index'; const REGEXP_HEX: RegExp = /^#([0-9A-F]{6}|[0-9A-F]{8})$/i; -let themeConfigCommon: IDefaults = require('../../defaults.json'); -let accentsProperties: IGenericObject = { - "activityBarBadge.background": { +const accentsProperties: IGenericObject = { + 'activityBarBadge.background': { alpha: 100, value: undefined }, - "list.activeSelectionForeground": { + 'list.activeSelectionForeground': { alpha: 100, value: undefined }, - "list.inactiveSelectionForeground": { + 'list.inactiveSelectionForeground': { alpha: 100, value: undefined }, - "list.highlightForeground": { + 'list.highlightForeground': { alpha: 100, value: undefined }, - "scrollbarSlider.activeBackground": { + 'scrollbarSlider.activeBackground': { alpha: 50, value: undefined }, - "editorSuggestWidget.highlightForeground": { + 'editorSuggestWidget.highlightForeground': { alpha: 100, value: undefined }, - "textLink.foreground": { + 'textLink.foreground': { alpha: 100, value: undefined }, - "progressBar.background": { + 'progressBar.background': { alpha: 100, value: undefined }, - "pickerGroup.foreground": { + 'pickerGroup.foreground': { alpha: 100, value: undefined }, - "tab.activeBorder": { + 'tab.activeBorder': { alpha: 100, value: undefined }, - "notificationLink.foreground": { + 'notificationLink.foreground': { alpha: 100, value: undefined } -} +}; /** * Assigns colours - * @param {string} colour - * @param {*} config */ -function assignColorCustomizations(colour: string, config: any): void { - if (!isValidColour(colour)) { - colour = undefined; - } +const assignColorCustomizations = (colour: string, config: any): void => { + const newColour = isValidColour(colour) ? colour : undefined; Object.keys(accentsProperties).forEach(propertyName => { - let accent: IAccentCustomProperty = accentsProperties[propertyName]; - let _colour = colour; + const accent: IAccentCustomProperty = accentsProperties[propertyName]; + let colorProp = newColour; if (colour && accent.alpha < 100) { - _colour = `${ colour }${ accent.alpha > 10 ? accent.alpha : `0${ accent.alpha }` }`; + colorProp = `${ colour }${ accent.alpha > 10 ? accent.alpha : `0${ accent.alpha }` }`; } if (accent) { - config[propertyName] = _colour; + config[propertyName] = colorProp; } }); -} +}; /** * Determines if a string is a valid colour - * @param {(string | null | undefined)} colour - * @returns {boolean} */ -function isValidColour(colour: string | null | undefined): boolean { - if (typeof colour === 'string' && REGEXP_HEX.test(colour)) { - return true; - } - return false; -} +const isValidColour = (colour: string | null | undefined): boolean => + typeof colour === 'string' && REGEXP_HEX.test(colour); /** * Sets workbench options - * @param {string} accentSelected - * @param {*} config */ -function setWorkbenchOptions(accentSelected: string | undefined, config: any): void { +const setWorkbenchOptions = (accentSelected: string | undefined, config: any): void => { vscode.workspace.getConfiguration().update('workbench.colorCustomizations', config, true).then(() => { - let themeID = getCurrentThemeID() - let themeIconsID = getCurrentThemeIconsID() + const themeID = getCurrentThemeID(); + const themeIconsID = getCurrentThemeIconsID(); updateAccent(accentSelected).then(() => { if (isMaterialTheme(themeID) && isMaterialThemeIcons(themeIconsID)) { @@ -111,32 +106,34 @@ function setWorkbenchOptions(accentSelected: string | undefined, config: any): v }, reason => { vscode.window.showErrorMessage(reason); }); -} +}; /** * VSCode command */ export const THEME_ACCENTS_SETTER = () => { + const themeConfigCommon = getDefaultValues(); // shows the quick pick dropdown - let options: string[] = Object.keys(themeConfigCommon.accents); - let purgeColourKey: string = 'Remove accents'; + const options: string[] = Object.keys(themeConfigCommon.accents); + const purgeColourKey: string = 'Remove accents'; options.push(purgeColourKey); vscode.window.showQuickPick(options).then(accentSelected => { - if (accentSelected === null || accentSelected === undefined) return; + if (accentSelected === null || accentSelected === undefined) { + return; + } - let config: any = vscode.workspace.getConfiguration().get('workbench.colorCustomizations'); + const config: any = vscode.workspace.getConfiguration().get('workbench.colorCustomizations'); - switch(accentSelected) { + switch (accentSelected) { case purgeColourKey: assignColorCustomizations(undefined, config); setWorkbenchOptions(undefined, config); - break; + break; default: assignColorCustomizations(themeConfigCommon.accents[accentSelected], config); setWorkbenchOptions(accentSelected, config); - break; } }); -} \ No newline at end of file +}; diff --git a/extensions/commands/theme-icons/index.ts b/extensions/commands/theme-icons/index.ts index 93cf51c..11103b2 100644 --- a/extensions/commands/theme-icons/index.ts +++ b/extensions/commands/theme-icons/index.ts @@ -1,30 +1,35 @@ -import {getAccentableIcons} from '../../helpers/fs'; import * as fs from 'fs'; -import { getAbsolutePath, getDefaultValues, getThemeIconsByContributeID, getThemeIconsContribute, getVariantIcons } from "../../helpers/fs"; -import { getCurrentThemeIconsID, getCurrentThemeID } from "../../helpers/vscode"; -import { isAccent, isMaterialThemeIcons, getCustomSettings } from "../../helpers/settings"; +import { + getAccentableIcons, + getAbsolutePath, + getDefaultValues, + getThemeIconsByContributeID, + getThemeIconsContribute, + getVariantIcons +} from './../../helpers/fs'; +import { + isAccent, + isMaterialThemeIcons, + getCustomSettings +} from './../../helpers/settings'; +import {getCurrentThemeIconsID, getCurrentThemeID} from './../../helpers/vscode'; +import {CHARSET} from './../../consts/files'; +import {IPackageJSONThemeIcons} from './../../interfaces/ipackage.json'; +import {IThemeIconsIconPath, IThemeIcons} from './../../interfaces/itheme-icons'; -import { CHARSET } from "../../consts/files"; -import { IPackageJSONThemeIcons } from "../../interfaces/ipackage.json"; -import {IThemeIconsIconPath, IThemeIcons} from '../../interfaces/itheme-icons'; - - -function getIconDefinition(definitions: any, iconname: string): IThemeIconsIconPath { +const getIconDefinition = (definitions: any, iconname: string): IThemeIconsIconPath => { return (definitions as any)[iconname]; -} +}; /** * Replaces icon path with the accented one. - * @param {string} iconPath - * @param {string} accentName - * @returns {string} */ -function replaceIconPathWithAccent(iconPath: string, accentName: string): string { +const replaceIconPathWithAccent = (iconPath: string, accentName: string): string => { return iconPath.replace('.svg', `.accent.${ accentName }.svg`); -} +}; -function getVariantFromColor(color: string): string { +const getVariantFromColor = (color: string): string => { switch (color) { case undefined || 'Material Theme': return 'Default'; @@ -33,61 +38,61 @@ function getVariantFromColor(color: string): string { default: return color.replace(/Material Theme /gi, ''); } -} +}; export const THEME_ICONS = () => { - let deferred: any = {}; - let promise = new Promise((resolve, reject) => { + const deferred: any = {}; + const promise = new Promise((resolve, reject) => { deferred.resolve = resolve; deferred.reject = reject; }); - let themeIconsID: string = getCurrentThemeIconsID(); + const themeIconsID: string = getCurrentThemeIconsID(); if (isMaterialThemeIcons(themeIconsID)) { - let themeID = getCurrentThemeID(); - let customSettings = getCustomSettings(); - let defaults = getDefaultValues(); - let accentName = customSettings.accent; - let variantName: string = getVariantFromColor(themeID); + const themeID = getCurrentThemeID(); + const customSettings = getCustomSettings(); + const defaults = getDefaultValues(); + const accentName = customSettings.accent; + const variantName: string = getVariantFromColor(themeID); - let themeContribute: IPackageJSONThemeIcons = getThemeIconsContribute(themeIconsID); - let theme: IThemeIcons = getThemeIconsByContributeID(themeIconsID); - let themepath: string = getAbsolutePath(themeContribute.path); + const themeContribute: IPackageJSONThemeIcons = getThemeIconsContribute(themeIconsID); + const theme: IThemeIcons = getThemeIconsByContributeID(themeIconsID); + const themepath: string = getAbsolutePath(themeContribute.path); if (isAccent(accentName, defaults)) { - let _accentName = accentName.replace(/\s+/, '-'); - + const realAccentName = accentName.replace(/\s+/, '-'); getAccentableIcons().forEach(iconname => { - let distIcon = getIconDefinition(theme.iconDefinitions, iconname); - let outIcon = getIconDefinition(defaults.icons.theme.iconDefinitions, iconname); + const distIcon = getIconDefinition(theme.iconDefinitions, iconname); + const outIcon = getIconDefinition(defaults.icons.theme.iconDefinitions, iconname); if (typeof distIcon === 'object' && typeof outIcon === 'object') { - distIcon.iconPath = replaceIconPathWithAccent(outIcon.iconPath, _accentName) + distIcon.iconPath = replaceIconPathWithAccent(outIcon.iconPath, realAccentName); } - }) + }); } else { - getAccentableIcons().forEach(iconname => { - let distIcon = getIconDefinition(theme.iconDefinitions, iconname); - let outIcon = getIconDefinition(defaults.icons.theme.iconDefinitions, iconname); + const distIcon = getIconDefinition(theme.iconDefinitions, iconname); + const outIcon = getIconDefinition(defaults.icons.theme.iconDefinitions, iconname); distIcon.iconPath = outIcon.iconPath; }); } getVariantIcons().forEach(iconname => { - let distIcon = getIconDefinition(theme.iconDefinitions, iconname); - let outIcon = getIconDefinition(defaults.icons.theme.iconDefinitions, iconname); + const distIcon = getIconDefinition(theme.iconDefinitions, iconname); + const outIcon = getIconDefinition(defaults.icons.theme.iconDefinitions, iconname); - if (!!distIcon && !!outIcon) { + if (distIcon && outIcon) { distIcon.iconPath = outIcon.iconPath.replace('.svg', `${ variantName }.svg`); } - }) + }); - fs.writeFile(themepath, JSON.stringify(theme), { encoding: CHARSET }, (error) => { - if (error) { - deferred.reject(error); + fs.writeFile(themepath, JSON.stringify(theme), { + encoding: CHARSET + }, err => { + if (err) { + deferred.reject(err); return; } @@ -98,4 +103,4 @@ export const THEME_ICONS = () => { } return promise; -} \ No newline at end of file +}; diff --git a/extensions/consts/files.ts b/extensions/consts/files.ts index ccde74c..63a0935 100644 --- a/extensions/consts/files.ts +++ b/extensions/consts/files.ts @@ -1,5 +1,4 @@ /** * File charset - * @type {string} */ -export const CHARSET: string = 'utf-8'; \ No newline at end of file +export const CHARSET: string = 'utf-8'; diff --git a/extensions/consts/paths.ts b/extensions/consts/paths.ts index 4f673e9..03372f0 100644 --- a/extensions/consts/paths.ts +++ b/extensions/consts/paths.ts @@ -1,6 +1,6 @@ import * as path from 'path'; -import { IPaths } from '../interfaces/ipaths'; +import {IPaths} from '../interfaces/ipaths'; export const PATHS: IPaths = { DIST: './dist', diff --git a/extensions/helpers/changelog.ts b/extensions/helpers/changelog.ts index 4fd18b9..cdd8fe6 100644 --- a/extensions/helpers/changelog.ts +++ b/extensions/helpers/changelog.ts @@ -1,61 +1,61 @@ import * as path from 'path'; import * as vscode from 'vscode'; -import { getDefaultValues, getPackageJSON, writeFile } from "./fs"; -import { PATHS } from '../consts/paths'; +import {IDefaults} from './../interfaces/idefaults'; -function previewFile(): void { - let uri = vscode.Uri.file(path.join(PATHS.VSIX_DIR, './CHANGELOG.md')); +import {getDefaultValues, getPackageJSON, writeFile} from './fs'; +import {PATHS} from './../consts/paths'; +const previewFile = (): void => { + const uri = vscode.Uri.file(path.join(PATHS.VSIX_DIR, './CHANGELOG.md')); vscode.commands.executeCommand('markdown.showPreview', uri); +}; -} +const splitVersion = (input: string): {major: number; minor: number; patch: number} => { + const [major, minor, patch] = input.split('.').map(i => parseInt(i, 10)); + return {major, minor, patch}; +}; -function splitVersion(input: string): { major: number, minor: number, patch: number } { - let [ major, minor, patch ] = input.split('.').map(i => parseInt(i)); - return { major, minor, patch }; -} +const writeDefaults = (defaults: IDefaults) => + writeFile(path.join('./extensions/defaults.json'), JSON.stringify(defaults, null, 2)); -export function showChangelog(): void { - let extname: string = 'vscode.markdown'; - let md = vscode.extensions.getExtension(extname); +export const showChangelog = (): void => { + const extname: string = 'vscode.markdown'; + const md = vscode.extensions.getExtension(extname); if (md === undefined) { - console.warn(`Ext not found ${ extname }`) + console.warn(`Ext not found ${ extname }`); return; } if (md.isActive) { - previewFile(); - } else { - md.activate().then(() => { - previewFile(); - }, reason => { - console.warn(reason); - }); - } -} - -export function shouldShowChangelog(): boolean { - let defaults = getDefaultValues(); - let out: boolean; - let packageJSON = getPackageJSON(); - - if (defaults.changelog == undefined || (defaults.changelog !== undefined && typeof defaults.changelog.lastversion !== 'string')) { - defaults.changelog = { - lastversion: packageJSON.version - } - out = true; - } else { - let versionCurrent = splitVersion(packageJSON.version); - let versionOld = splitVersion(defaults.changelog.lastversion); - - out = versionCurrent.major > versionOld.major || versionCurrent.minor > versionOld.minor || versionCurrent.patch > versionOld.patch; - - defaults.changelog.lastversion = packageJSON.version; + return previewFile(); } - writeFile(path.join('./extensions/defaults.json'), JSON.stringify(defaults, null, 2)); + md.activate() + .then(() => previewFile(), + reason => console.warn(reason) + ); +}; + +export const shouldShowChangelog = (): boolean => { + const defaults = getDefaultValues(); + const packageJSON = getPackageJSON(); + + const defaultsNotPresent = defaults.changelog === undefined || + (defaults.changelog !== undefined && typeof defaults.changelog.lastversion !== 'string'); + + const versionCurrent = splitVersion(packageJSON.version); + const versionOld = defaultsNotPresent ? null : splitVersion(defaults.changelog.lastversion); + + const out = !versionOld || + versionCurrent.major > versionOld.major || + versionCurrent.minor > versionOld.minor || + versionCurrent.patch > versionOld.patch; + + const newChangelog = {...defaults.changelog, lastversion: packageJSON.version}; + const newDefaults = {...defaults, changelog: newChangelog}; + writeDefaults(newDefaults); return out; -} \ No newline at end of file +}; diff --git a/extensions/helpers/fs.ts b/extensions/helpers/fs.ts index de5e41f..986a847 100644 --- a/extensions/helpers/fs.ts +++ b/extensions/helpers/fs.ts @@ -1,30 +1,21 @@ -import * as fs from 'fs' -import * as path from 'path' +import * as fs from 'fs'; +import * as path from 'path'; -import { IPackageJSON, IPackageJSONThemeIcons } from "../interfaces/ipackage.json"; +import {IPackageJSON, IPackageJSONThemeIcons} from './../interfaces/ipackage.json'; -import { CHARSET } from "../consts/files"; -import { IDefaults } from "../interfaces/idefaults"; -import { IThemeIcons } from "../interfaces/itheme-icons"; -import { PATHS } from "../consts/paths"; +import {CHARSET} from './../consts/files'; +import {IDefaults} from '../interfaces/idefaults'; +import {IThemeIcons} from '../interfaces/itheme-icons'; +import {PATHS} from '../consts/paths'; -/** - * @export - * @param {string} dirname - */ export function ensureDir(dirname: string): void { if (!fs.existsSync(dirname)) { fs.mkdirSync(dirname); } } -/** - * Gets default value - * @export - * @returns {IDefaults} - */ export function getDefaultValues(): IDefaults { - let defaults: IDefaults = require(path.join(PATHS.VSIX_DIR, './extensions/defaults.json')); + const defaults: IDefaults = require(path.join(PATHS.VSIX_DIR, './extensions/defaults.json')); if (defaults === undefined || defaults === null) { throw new Error('Cannot find defaults params'); @@ -33,74 +24,45 @@ export function getDefaultValues(): IDefaults { return defaults; } -/** - * Gets an absolute path - * - * @export - * @param {string} input - * @returns {string} - */ export function getAbsolutePath(input: string): string { return path.join(PATHS.VSIX_DIR, input); } -/** - * @export - * @returns {string[]} - */ export function getAccentableIcons(): string[] { return getDefaultValues().accentableIcons; } -/** - * @export - * @returns {string[]} - */ export function getVariantIcons(): string[] { return getDefaultValues().variantsIcons; } /** * Gets a theme content by a given contribute ID - * - * @export - * @param {string} ID - * @returns {IThemeIcons} */ export function getThemeIconsByContributeID(ID: string): IThemeIcons | null { - let contribute: IPackageJSONThemeIcons = getThemeIconsContribute(ID) + const contribute: IPackageJSONThemeIcons = getThemeIconsContribute(ID); return contribute !== null ? require(path.join(PATHS.VSIX_DIR, contribute.path)) : null; } /** * Gets a theme by name - * @export - * @param {string} name - * @returns {IThemeIcons} */ export function getThemeIconsContribute(ID: string): IPackageJSONThemeIcons { - let contributes = getPackageJSON().contributes.iconThemes.filter(contribute => contribute.id === ID); + const contributes = getPackageJSON().contributes.iconThemes.filter(contribute => contribute.id === ID); return contributes[0] !== undefined ? contributes[0] : null; } /** * Gets package JSON - * @export - * @returns {*} */ export function getPackageJSON(): IPackageJSON { - let packageJSON: IPackageJSON = require(path.join(PATHS.VSIX_DIR, './package.json')); - return packageJSON; + return require(path.join(PATHS.VSIX_DIR, './package.json')); } /** * Writes a file inside the vsix directory - * @export - * @param {string} filename - * @param {string} filecontent */ export function writeFile(filename: string, filecontent: string): void { - filename = path.join(PATHS.VSIX_DIR, filename); - console.log(arguments) - fs.writeFileSync(filename, filecontent, { encoding: CHARSET }); -} \ No newline at end of file + const filePath = path.join(PATHS.VSIX_DIR, filename); + fs.writeFileSync(filePath, filecontent, {encoding: CHARSET}); +} diff --git a/extensions/helpers/settings.ts b/extensions/helpers/settings.ts index e4e569c..e5b5f48 100644 --- a/extensions/helpers/settings.ts +++ b/extensions/helpers/settings.ts @@ -1,13 +1,11 @@ import * as vscode from 'vscode'; -import { IDefaults } from "../interfaces/idefaults"; -import { IThemeCustomProperties } from "../interfaces/itheme-custom-properties"; +import {IDefaults} from './../interfaces/idefaults'; +import {IThemeCustomProperties} from './../interfaces/itheme-custom-properties'; import {getPackageJSON} from './fs'; /** * Gets saved accent - * @export - * @returns {(string | null)} */ export function getAccent(): string | undefined { return getCustomSettings().accent; @@ -15,8 +13,6 @@ export function getAccent(): string | undefined { /** * Gets custom settings - * @export - * @returns {*} */ export function getCustomSettings(): IThemeCustomProperties { return vscode.workspace.getConfiguration().get('materialTheme', {}); @@ -24,10 +20,6 @@ export function getCustomSettings(): IThemeCustomProperties { /** * Checks if a given string could be an accent - * - * @export - * @param {string} accentName - * @returns {boolean} */ export function isAccent(accentName: string, defaults: IDefaults): boolean { return Object.keys(defaults.accents).filter(name => name === accentName).length > 0; @@ -35,31 +27,22 @@ export function isAccent(accentName: string, defaults: IDefaults): boolean { /** * Determines if the passing theme label is a material theme - * @export - * @param {string} themeName - * @returns {boolean} */ export function isMaterialTheme(themeName: string): boolean { - let packageJSON = getPackageJSON(); + const packageJSON = getPackageJSON(); return packageJSON.contributes.themes.filter(contrib => contrib.label === themeName).length > 0; } /** * Determines if the passing icons theme is a material theme - * @export - * @param {string} themeIconsName - * @returns {boolean} */ export function isMaterialThemeIcons(themeIconsName: string): boolean { - let packageJSON = getPackageJSON(); + const packageJSON = getPackageJSON(); return packageJSON.contributes.iconThemes.filter(contribute => contribute.id === themeIconsName).length > 0; } /** * Sets a custom property in custom settings - * @export - * @param {string} settingName - * @param {*} value */ export function setCustomSetting(settingName: string, value: any): Thenable { return vscode.workspace.getConfiguration().update(`materialTheme.${settingName}`, value, true); @@ -67,11 +50,9 @@ export function setCustomSetting(settingName: string, value: any): Thenable { const prevAccent = getAccent(); return setCustomSetting('accentPrevious', prevAccent) - .then(() => setCustomSetting('accent', accentName)) -} \ No newline at end of file + .then(() => setCustomSetting('accent', accentName)); +} diff --git a/extensions/helpers/vscode.ts b/extensions/helpers/vscode.ts index 2f38245..911024d 100644 --- a/extensions/helpers/vscode.ts +++ b/extensions/helpers/vscode.ts @@ -1,24 +1,22 @@ -import * as vscode from 'vscode' - +import * as vscode from 'vscode'; export function askForWindowReload(): Thenable { const PROMPT_MESSAGE: string = 'Material Theme requires VS Code reload in order to display icons correctly.'; const PROMPT_MESSAGE_CONFIRM: string = 'Ok, reload'; const PROMPT_MESSAGE_CANCEL: string = 'I will do it later'; - return vscode.window.showInformationMessage(PROMPT_MESSAGE, PROMPT_MESSAGE_CONFIRM, PROMPT_MESSAGE_CANCEL).then((response) => { - if (response === PROMPT_MESSAGE_CONFIRM) { - reloadWindow(); - } - }, (error) => { - console.log(error); - }); + return vscode.window.showInformationMessage(PROMPT_MESSAGE, PROMPT_MESSAGE_CONFIRM, PROMPT_MESSAGE_CANCEL) + .then(response => { + if (response === PROMPT_MESSAGE_CONFIRM) { + reloadWindow(); + } + }, err => { + console.log(err); + }); } /** * Gets your current theme ID - * @export - * @returns {string} */ export function getCurrentThemeID(): string { return vscode.workspace.getConfiguration().get('workbench.colorTheme'); @@ -26,8 +24,6 @@ export function getCurrentThemeID(): string { /** * Gets your current icons theme ID - * @export - * @returns {string} */ export function getCurrentThemeIconsID(): string { return vscode.workspace.getConfiguration().get('workbench.iconTheme'); @@ -35,8 +31,6 @@ export function getCurrentThemeIconsID(): string { /** * Set a specific id for icons - * @export - * @returns {Thenable} */ export function setIconsID(id: string): Thenable { return vscode.workspace.getConfiguration().update('workbench.iconTheme', id, true); @@ -44,8 +38,7 @@ export function setIconsID(id: string): Thenable { /** * Reloads current vscode window. - * @export */ export function reloadWindow(): void { vscode.commands.executeCommand('workbench.action.reloadWindow'); -} \ No newline at end of file +} diff --git a/extensions/interfaces/iaccent-custom-property.ts b/extensions/interfaces/iaccent-custom-property.ts index 6b6b81d..3c2ca51 100644 --- a/extensions/interfaces/iaccent-custom-property.ts +++ b/extensions/interfaces/iaccent-custom-property.ts @@ -1,4 +1,4 @@ export interface IAccentCustomProperty { alpha: number; value: any; -} \ No newline at end of file +} diff --git a/extensions/interfaces/idefaults.ts b/extensions/interfaces/idefaults.ts index 4e4ee50..e989c20 100644 --- a/extensions/interfaces/idefaults.ts +++ b/extensions/interfaces/idefaults.ts @@ -4,9 +4,10 @@ export interface IDefaults { changelog: IChangelog; icons: IDefaultsThemeIcons; themeVariants: IDefaultsThemeVariant; - themeVariantsColours: IDefaultsThemeVariantColours; - themeVariantsUITheme: IDefaultsThemeVariantUITheme; + themeVariantsColours: IDefaultsThemeVariant; + themeVariantsUITheme: IDefaultsThemeVariant; variantsIcons: string[]; + [Symbol.iterator](): IterableIterator; } export interface IAccents { @@ -16,6 +17,7 @@ export interface IAccents { export interface IChangelog { lastversion: string; + [Symbol.iterator](): IterableIterator; } export interface IDefaultsThemeIcons { @@ -23,24 +25,24 @@ export interface IDefaultsThemeIcons { iconDefinitions: { _folder_open: { iconPath: string; - } + }; _folder_open_build: { iconPath: string; - } + }; _folder_dark: { iconPath: string; - } + }; _folder_dark_build: { iconPath: string; - } - "_folder_light_build": { + }; + _folder_light_build: { iconPath: string; - } + }; _folder_light: { iconPath: string; - } - } - } + }; + }; + }; } export interface IDefaultsThemeVariant { @@ -53,11 +55,3 @@ export interface IDefaultsThemeVariant { LightHighContrast: string; PalenightHighContrast: string; } - -export interface IDefaultsThemeVariantColours extends IDefaultsThemeVariant { - -} - -export interface IDefaultsThemeVariantUITheme extends IDefaultsThemeVariant { - -} \ No newline at end of file diff --git a/extensions/interfaces/igeneric-object.ts b/extensions/interfaces/igeneric-object.ts index 7631326..d0515f4 100644 --- a/extensions/interfaces/igeneric-object.ts +++ b/extensions/interfaces/igeneric-object.ts @@ -1,3 +1,3 @@ export interface IGenericObject { [index: string]: TValue; -} \ No newline at end of file +} diff --git a/extensions/interfaces/ipackage.json.ts b/extensions/interfaces/ipackage.json.ts index b52a9f7..edd732a 100644 --- a/extensions/interfaces/ipackage.json.ts +++ b/extensions/interfaces/ipackage.json.ts @@ -1,4 +1,4 @@ -import { IGenericObject } from '../../extensions/interfaces/igeneric-object'; +import {IGenericObject} from './../../extensions/interfaces/igeneric-object'; export interface IPackageJSONBadge { description: string; @@ -14,9 +14,7 @@ export interface IPackageJSONContributes { } export interface IPackageJSONConfiguration { - properties: { - - } + properties: {}; } export interface IPackageJSONCommand { @@ -38,24 +36,24 @@ export interface IPackageJSONThemeIcons { } export interface IPackageJSON { - "activationEvents": string[] - "badges": IPackageJSONBadge[]; - "contributes": IPackageJSONContributes; - "bugs": IGenericObject; - "categories": string[]; - "description": string; - "displayName": string; - "engines": IGenericObject; - "galleryBanner": IGenericObject; - "homepage": string; - "icon": string; - "license": string; - "main": string; - "name": string; - "preview": boolean; - "publisher": string; - "repository": IGenericObject; - "scripts": IGenericObject; - "version": string; - "devDependencies": IGenericObject; -} \ No newline at end of file + activationEvents: string[]; + badges: IPackageJSONBadge[]; + contributes: IPackageJSONContributes; + bugs: IGenericObject; + categories: string[]; + description: string; + displayName: string; + engines: IGenericObject; + galleryBanner: IGenericObject; + homepage: string; + icon: string; + license: string; + main: string; + name: string; + preview: boolean; + publisher: string; + repository: IGenericObject; + scripts: IGenericObject; + version: string; + devDependencies: IGenericObject; +} diff --git a/extensions/interfaces/ipaths.ts b/extensions/interfaces/ipaths.ts index ba3d072..1a22e32 100644 --- a/extensions/interfaces/ipaths.ts +++ b/extensions/interfaces/ipaths.ts @@ -1,32 +1,22 @@ export interface IPaths { /** * Dist dir - * @type {string} - * @memberof IPaths */ DIST: string; /** * Icons dir - * @type {string} - * @memberof IPaths */ ICONS: string; /** * Src dir - * @type {string} - * @memberof IPaths */ SRC: string; /** * Themes dir - * @type {string} - * @memberof IPaths */ THEMES: string; /** * Extension directory - * @type {string} - * @memberof IPaths */ VSIX_DIR: string; -} \ No newline at end of file +} diff --git a/extensions/interfaces/itheme-custom-properties.ts b/extensions/interfaces/itheme-custom-properties.ts index 3bd1bc2..4d7a858 100644 --- a/extensions/interfaces/itheme-custom-properties.ts +++ b/extensions/interfaces/itheme-custom-properties.ts @@ -1,4 +1,4 @@ export interface IThemeCustomProperties { accent?: string; accentPrevious?: string; -} \ No newline at end of file +} diff --git a/extensions/interfaces/itheme-icons.ts b/extensions/interfaces/itheme-icons.ts index 23e10f6..4d6cd8b 100644 --- a/extensions/interfaces/itheme-icons.ts +++ b/extensions/interfaces/itheme-icons.ts @@ -3,511 +3,514 @@ export interface IThemeIconsIconPath { } export interface IThemeIcons { - "iconDefinitions": - { - "_folder_dark": IThemeIconsIconPath; - "_file_folder": IThemeIconsIconPath; - "_folder_dark_build": IThemeIconsIconPath; - "_folder_light": IThemeIconsIconPath; - "_folder_light_build": IThemeIconsIconPath; - "_folder_open": IThemeIconsIconPath; - "_folder_open_build": IThemeIconsIconPath; - "_file_dark": IThemeIconsIconPath; - "_file_actionscript": IThemeIconsIconPath; - "_file_ai": IThemeIconsIconPath; - "_file_android": IThemeIconsIconPath; - "_file_angular": IThemeIconsIconPath; - "_file_applescript": IThemeIconsIconPath; - "_file_arduino": IThemeIconsIconPath; - "_file_assembly": IThemeIconsIconPath; - "_file_autohotkey": IThemeIconsIconPath; - "_file_bower": IThemeIconsIconPath; - "_file_c": IThemeIconsIconPath; - "_file_certificate": IThemeIconsIconPath; - "_file_changelog": IThemeIconsIconPath; - "_file_clojure": IThemeIconsIconPath; - "_file_cmake": IThemeIconsIconPath; - "_file_cmd": IThemeIconsIconPath; - "_file_coffee": IThemeIconsIconPath; - "_file_console": IThemeIconsIconPath; - "_file_contributing": IThemeIconsIconPath; - "_file_cpp": IThemeIconsIconPath; - "_file_credits": IThemeIconsIconPath; - "_file_csharp": IThemeIconsIconPath; - "_file_css-map": IThemeIconsIconPath; - "_file_css": IThemeIconsIconPath; - "_file_dart": IThemeIconsIconPath; - "_file_database": IThemeIconsIconPath; - "_file_dlang": IThemeIconsIconPath; - "_file_docker": IThemeIconsIconPath; - "_file_document": IThemeIconsIconPath; - "_file_email": IThemeIconsIconPath; - "_file_exe": IThemeIconsIconPath; - "_file_favicon": IThemeIconsIconPath; - "_file_file": IThemeIconsIconPath; - "_file_flash": IThemeIconsIconPath; - "_file_flow": IThemeIconsIconPath; - "_file_folder-build": IThemeIconsIconPath; - "_file_folder-light-build": IThemeIconsIconPath; - "_file_folder-light": IThemeIconsIconPath; - "_file_folder-outline-build": IThemeIconsIconPath; - "_file_folder-outline": IThemeIconsIconPath; - "_file_font": IThemeIconsIconPath; - "_file_fsharp": IThemeIconsIconPath; - "_file_git": IThemeIconsIconPath; - "_file_github": IThemeIconsIconPath; - "_file_go": IThemeIconsIconPath; - "_file_gopher": IThemeIconsIconPath; - "_file_gradle": IThemeIconsIconPath; - "_file_graphql": IThemeIconsIconPath; - "_file_groovy": IThemeIconsIconPath; - "_file_grunt": IThemeIconsIconPath; - "_file_gulp": IThemeIconsIconPath; - "_file_haml": IThemeIconsIconPath; - "_file_haskell": IThemeIconsIconPath; - "_file_html": IThemeIconsIconPath; - "_file_image": IThemeIconsIconPath; - "_file_ionic": IThemeIconsIconPath; - "_file_java": IThemeIconsIconPath; - "_file_javascript-map": IThemeIconsIconPath; - "_file_js": IThemeIconsIconPath; - "_file_json": IThemeIconsIconPath; - "_file_key": IThemeIconsIconPath; - "_file_kotlin": IThemeIconsIconPath; - "_file_less": IThemeIconsIconPath; - "_file_lib": IThemeIconsIconPath; - "_file_license": IThemeIconsIconPath; - "_file_lua": IThemeIconsIconPath; - "_file_markdown": IThemeIconsIconPath; - "_file_markup": IThemeIconsIconPath; - "_file_movie": IThemeIconsIconPath; - "_file_music": IThemeIconsIconPath; - "_file_mustache": IThemeIconsIconPath; - "_file_mxml": IThemeIconsIconPath; - "_file_nodejs": IThemeIconsIconPath; - "_file_npm": IThemeIconsIconPath; - "_file_ocaml": IThemeIconsIconPath; - "_file_pdf": IThemeIconsIconPath; - "_file_php": IThemeIconsIconPath; - "_file_polymer": IThemeIconsIconPath; - "_file_postcss": IThemeIconsIconPath; - "_file_powerpoint": IThemeIconsIconPath; - "_file_pp": IThemeIconsIconPath; - "_file_procfile": IThemeIconsIconPath; - "_file_pug": IThemeIconsIconPath; - "_file_python": IThemeIconsIconPath; - "_file_r": IThemeIconsIconPath; - "_file_rails": IThemeIconsIconPath; - "_file_raml": IThemeIconsIconPath; - "_file_react": IThemeIconsIconPath; - "_file_readme": IThemeIconsIconPath; - "_file_ruby": IThemeIconsIconPath; - "_file_rust": IThemeIconsIconPath; - "_file_sass": IThemeIconsIconPath; - "_file_settings": IThemeIconsIconPath; - "_file_sketch": IThemeIconsIconPath; - "_file_star": IThemeIconsIconPath; - "_file_stylus": IThemeIconsIconPath; - "_file_sublime": IThemeIconsIconPath; - "_file_svg": IThemeIconsIconPath; - "_file_swc": IThemeIconsIconPath; - "_file_swift": IThemeIconsIconPath; - "_file_swig": IThemeIconsIconPath; - "_file_table": IThemeIconsIconPath; - "_file_tex": IThemeIconsIconPath; - "_file_todo": IThemeIconsIconPath; - "_file_tune": IThemeIconsIconPath; - "_file_twig": IThemeIconsIconPath; - "_file_typescript": IThemeIconsIconPath; - "_file_typescript_def": IThemeIconsIconPath; - "_file_url": IThemeIconsIconPath; - "_file_virtual": IThemeIconsIconPath; - "_file_visualstudio": IThemeIconsIconPath; - "_file_vue": IThemeIconsIconPath; - "_file_webpack": IThemeIconsIconPath; - "_file_word": IThemeIconsIconPath; - "_file_xaml": IThemeIconsIconPath; - "_file_xml": IThemeIconsIconPath; - "_file_yaml": IThemeIconsIconPath; - "_file_yarn": IThemeIconsIconPath; - "_file_zip": IThemeIconsIconPath; + iconDefinitions: { + _folder_dark: IThemeIconsIconPath; + _file_folder: IThemeIconsIconPath; + _folder_dark_build: IThemeIconsIconPath; + _folder_light: IThemeIconsIconPath; + _folder_light_build: IThemeIconsIconPath; + _folder_open: IThemeIconsIconPath; + _folder_open_build: IThemeIconsIconPath; + _file_dark: IThemeIconsIconPath; + _file_actionscript: IThemeIconsIconPath; + _file_ai: IThemeIconsIconPath; + _file_android: IThemeIconsIconPath; + _file_angular: IThemeIconsIconPath; + _file_applescript: IThemeIconsIconPath; + _file_arduino: IThemeIconsIconPath; + _file_assembly: IThemeIconsIconPath; + _file_autohotkey: IThemeIconsIconPath; + _file_bower: IThemeIconsIconPath; + _file_c: IThemeIconsIconPath; + _file_certificate: IThemeIconsIconPath; + _file_changelog: IThemeIconsIconPath; + _file_clojure: IThemeIconsIconPath; + _file_cmake: IThemeIconsIconPath; + _file_cmd: IThemeIconsIconPath; + _file_coffee: IThemeIconsIconPath; + _file_console: IThemeIconsIconPath; + _file_contributing: IThemeIconsIconPath; + _file_cpp: IThemeIconsIconPath; + _file_credits: IThemeIconsIconPath; + _file_csharp: IThemeIconsIconPath; + '_file_css-map': IThemeIconsIconPath; + _file_css: IThemeIconsIconPath; + _file_dart: IThemeIconsIconPath; + _file_database: IThemeIconsIconPath; + _file_dlang: IThemeIconsIconPath; + _file_docker: IThemeIconsIconPath; + _file_document: IThemeIconsIconPath; + _file_email: IThemeIconsIconPath; + _file_exe: IThemeIconsIconPath; + _file_favicon: IThemeIconsIconPath; + _file_file: IThemeIconsIconPath; + _file_flash: IThemeIconsIconPath; + _file_flow: IThemeIconsIconPath; + '_file_folder-build': IThemeIconsIconPath; + '_file_folder-light-build': IThemeIconsIconPath; + '_file_folder-light': IThemeIconsIconPath; + '_file_folder-outline-build': IThemeIconsIconPath; + '_file_folder-outline': IThemeIconsIconPath; + _file_font: IThemeIconsIconPath; + _file_fsharp: IThemeIconsIconPath; + _file_git: IThemeIconsIconPath; + _file_github: IThemeIconsIconPath; + _file_go: IThemeIconsIconPath; + _file_gopher: IThemeIconsIconPath; + _file_gradle: IThemeIconsIconPath; + _file_graphql: IThemeIconsIconPath; + _file_groovy: IThemeIconsIconPath; + _file_grunt: IThemeIconsIconPath; + _file_gulp: IThemeIconsIconPath; + _file_haml: IThemeIconsIconPath; + _file_haskell: IThemeIconsIconPath; + _file_html: IThemeIconsIconPath; + _file_image: IThemeIconsIconPath; + _file_ionic: IThemeIconsIconPath; + _file_java: IThemeIconsIconPath; + '_file_javascript-map': IThemeIconsIconPath; + _file_js: IThemeIconsIconPath; + _file_json: IThemeIconsIconPath; + _file_key: IThemeIconsIconPath; + _file_kotlin: IThemeIconsIconPath; + _file_less: IThemeIconsIconPath; + _file_lib: IThemeIconsIconPath; + _file_license: IThemeIconsIconPath; + _file_lua: IThemeIconsIconPath; + _file_markdown: IThemeIconsIconPath; + _file_markup: IThemeIconsIconPath; + _file_movie: IThemeIconsIconPath; + _file_music: IThemeIconsIconPath; + _file_mustache: IThemeIconsIconPath; + _file_mxml: IThemeIconsIconPath; + _file_nodejs: IThemeIconsIconPath; + _file_npm: IThemeIconsIconPath; + _file_ocaml: IThemeIconsIconPath; + _file_pdf: IThemeIconsIconPath; + _file_php: IThemeIconsIconPath; + _file_polymer: IThemeIconsIconPath; + _file_postcss: IThemeIconsIconPath; + _file_powerpoint: IThemeIconsIconPath; + _file_pp: IThemeIconsIconPath; + _file_procfile: IThemeIconsIconPath; + _file_pug: IThemeIconsIconPath; + _file_python: IThemeIconsIconPath; + _file_r: IThemeIconsIconPath; + _file_rails: IThemeIconsIconPath; + _file_raml: IThemeIconsIconPath; + _file_react: IThemeIconsIconPath; + _file_readme: IThemeIconsIconPath; + _file_ruby: IThemeIconsIconPath; + _file_rust: IThemeIconsIconPath; + _file_sass: IThemeIconsIconPath; + _file_settings: IThemeIconsIconPath; + _file_sketch: IThemeIconsIconPath; + _file_star: IThemeIconsIconPath; + _file_stylus: IThemeIconsIconPath; + _file_sublime: IThemeIconsIconPath; + _file_svg: IThemeIconsIconPath; + _file_swc: IThemeIconsIconPath; + _file_swift: IThemeIconsIconPath; + _file_swig: IThemeIconsIconPath; + _file_table: IThemeIconsIconPath; + _file_tex: IThemeIconsIconPath; + _file_todo: IThemeIconsIconPath; + _file_tune: IThemeIconsIconPath; + _file_twig: IThemeIconsIconPath; + _file_typescript: IThemeIconsIconPath; + _file_typescript_def: IThemeIconsIconPath; + _file_url: IThemeIconsIconPath; + _file_virtual: IThemeIconsIconPath; + _file_visualstudio: IThemeIconsIconPath; + _file_vue: IThemeIconsIconPath; + _file_webpack: IThemeIconsIconPath; + _file_word: IThemeIconsIconPath; + _file_xaml: IThemeIconsIconPath; + _file_xml: IThemeIconsIconPath; + _file_yaml: IThemeIconsIconPath; + _file_yarn: IThemeIconsIconPath; + _file_zip: IThemeIconsIconPath; }; - "fileExtensions": - { - "cmd": string; - "mustache": string; - "rails": string; - "styl": string; - "twig": string; - "swig": string; - "sketch": string; - "do": string; - "sublime-settings": string; - "sublime-theme": string; - "sublime-commands": string; - "sublime-menu": string; - "html": string; - "jade": string; - "pug": string; - "md": string; - "md.rendered": string; - "markdown": string; - "markdown.rendered": string; - "css": string; - "postcss": string; - "scss": string; - "sass": string; - "less": string; - "json": string; - "yaml": string; - "YAML-tmLanguage": string; - "yml": string; - "xml": string; - "plist": string; - "xsd": string; - "dtd": string; - "xsl": string; - "xslt": string; - "resx": string; - "iml": string; - "xquery": string; - "tmLanguage": string; - "png": string; - "jpeg": string; - "jpg": string; - "gif": string; - "svg": string; - "eps": string; - "ai": string; - "ico": string; - "tif": string; - "tiff": string; - "psd": string; - "psb": string; - "ami": string; - "apx": string; - "bmp": string; - "bpg": string; - "brk": string; - "cur": string; - "dds": string; - "dng": string; - "exr": string; - "fpx": string; - "gbr": string; - "img": string; - "jbig2": string; - "jb2": string; - "jng": string; - "jxr": string; - "pbm": string; - "pgf": string; - "pic": string; - "raw": string; - "webp": string; - "php": string; - "js": string; - "ejs": string; - "jsx": string; - "ini": string; - "dlc": string; - "dll": string; - "config": string; - "conf": string; - "esx": string; - "ts": string; - "tsx": string; - "d.ts": string; - "pdf": string; - "xlsx": string; - "xls": string; - "csv": string; - "vscodeignore": string; - "vsixmanifest": string; - "suo": string; - "sln": string; - "pdb": string; - "cs": string; - "csx": string; - "csproj": string; - "zip": string; - "tar": string; - "gz": string; - "xz": string; - "bzip2": string; - "gzip": string; - "7z": string; - "7zip": string; - "pzip": string; - "wim": string; - "rar": string; - "tgz": string; - "exe": string; - "msi": string; - "java": string; - "jar": string; - "jsp": string; - "c": string; - "h": string; - "m": string; - "cc": string; - "cpp": string; - "c++": string; - "hpp": string; - "mm": string; - "cxx": string; - "go": string; - "py": string; - "url": string; - "sh": string; - "bat": string; - "ps1": string; - "fish": string; - "bash": string; - "gradle": string; - "doc": string; - "docx": string; - "rtf": string; - "properties": string; - "prop": string; - "settings": string; - "sql": string; - "accdb": string; - "mdb": string; - "cer": string; - "cert": string; - "crt": string; - "pub": string; - "key": string; - "pem": string; - "asc": string; - "woff": string; - "woff2": string; - "ttf": string; - "eot": string; - "suit": string; - "otf": string; - "bmap": string; - "fnt": string; - "odttf": string; - "ttc": string; - "font": string; - "fonts": string; - "sui": string; - "ntf": string; - "mrf": string; - "lib": string; - "rb": string; - "erb": string; - "fs": string; - "fsx": string; - "fsi": string; - "fsproj": string; - "manifest": string; - "swift": string; - "ino": string; - "dockerignore": string; - "tex": string; - "bib": string; - "pptx": string; - "ppt": string; - "pptm": string; - "potx": string; - "pot": string; - "potm": string; - "ppsx": string; - "ppsm": string; - "pps": string; - "ppam": string; - "ppa": string; - "webm": string; - "mkv": string; - "flv": string; - "vob": string; - "ogv": string; - "ogg": string; - "gifv": string; - "avi": string; - "mov": string; - "qt": string; - "wmv": string; - "yuv": string; - "rm": string; - "rmvb": string; - "mp4": string; - "m4v": string; - "mpg": string; - "mp2": string; - "mpeg": string; - "mpe": string; - "mpv": string; - "m2v": string; - "vdi": string; - "vbox": string; - "vbox-prev": string; - "ics": string; - "mp3": string; - "flac": string; - "m4a": string; - "wma": string; - "aiff": string; - "coffee": string; - "txt": string; - "sqlite": string; - "graphql": string; - "gql": string; - "props": string; - "toml": string; - "rs": string; - "raml": string; - "xaml": string; - "prefs": string; - "hs": string; - "kt": string; - "project": string; - "patch": string; - "dockerfile": string; - "vb": string; - "lua": string; - "clj": string; - "groovy": string; - "r": string; - "rst": string; - "dart": string; - "as": string; - "mxml": string; - "ahk": string; - "swf": string; - "swc": string; - "cmake": string; - "asm": string; - "a51": string; - "inc": string; - "nasm": string; - "s": string; - "ms": string; - "agc": string; - "ags": string; - "aea": string; - "argus": string; - "mitigus": string; - "binsource": string; - "vue": string; - "ml": string; - "mli": string; - "cmx": string; - "js.map": string; - "css.map": string; - "tmTheme": string; - "pp": string; - "applescript": string; - "haml": string }; - "fileNames": - { "gruntfile.js": string; - "bower.json": string; - ".bowerrc": string; - "webpack.js": string; - "webpack.config.js": string; - "webpack.dev.js": string; - "webpack.prod.js": string; - "webpack.common.js": string; - "webpackfile.js": string; - "ionic.config.json": string; - ".io-config.json": string; - "gulpfile.js": string; - "gulpfile.babel.js": string; - "package.json": string; - "gradle.properties": string; - "gradlew": string; - ".jscsrc": string; - ".jshintrc": string; - ".jshintignore": string; - ".npmignore": string; - "tsconfig.json": string; - "tslint.json": string; - "androidmanifest.xml": string; - "gradle-wrapper.properties": string; - ".editorconfig": string; - "procfile": string; - ".env": string; - "dockerfile": string; - "license": string; - "license.md": string; - "license.md.rendered": string; - "license.txt": string; - ".babelrc": string; - ".eslintrc": string; - ".buildignore": string; - ".htaccess": string; - "composer.lock": string; - ".gitignore": string; - ".gitconfig": string; - ".gitattributes": string; - ".gitmodules": string; - ".gitkeep": string; - "yarn.lock": string; - ".yarnclean": string; - ".yarn-integrity": string; - "yarn-error.log": string; - "contributing.md": string; - "contributing.md.rendered": string; - "readme.md": string; - "readme.md.rendered": string; - ".mailmap": string; - "makefile": string; - "changelog": string; - "changelog.md": string; - "changelog.md.rendered": string; - "CREDITS": string; - "credits.txt": string; - "credits.md": string; - "credits.md.rendered": string; - ".flowconfig": string; - ".jsbeautifyrc": string; - "git-history": string; - "angular-cli.json": string; - "app.module.ts": string; - "favicon.ico": string }; - "file": string; - "folder": string; - "folderExpanded": string; - "languageIds": - { "git": string }; - "light": - { - "folderExpanded": string; - "folder": string; - "folderNames": - { "node_modules": string; - ".git": string; - ".github": string; - ".gulp": string; - "bower_components": string; - "build": string; - "dist": string }; - "folderNamesExpanded": - { "node_modules": string; - ".git": string; - ".github": string; - ".gulp": string; - "bower_components": string; - "build": string; - "dist": string } + fileExtensions: { + cmd: string; + mustache: string; + rails: string; + styl: string; + twig: string; + swig: string; + sketch: string; + do: string; + 'sublime-settings': string; + 'sublime-theme': string; + 'sublime-commands': string; + 'sublime-menu': string; + html: string; + jade: string; + pug: string; + md: string; + 'md.rendered': string; + markdown: string; + 'markdown.rendered': string; + css: string; + postcss: string; + scss: string; + sass: string; + less: string; + json: string; + yaml: string; + 'YAML-tmLanguage': string; + yml: string; + xml: string; + plist: string; + xsd: string; + dtd: string; + xsl: string; + xslt: string; + resx: string; + iml: string; + xquery: string; + tmLanguage: string; + png: string; + jpeg: string; + jpg: string; + gif: string; + svg: string; + eps: string; + ai: string; + ico: string; + tif: string; + tiff: string; + psd: string; + psb: string; + ami: string; + apx: string; + bmp: string; + bpg: string; + brk: string; + cur: string; + dds: string; + dng: string; + exr: string; + fpx: string; + gbr: string; + img: string; + jbig2: string; + jb2: string; + jng: string; + jxr: string; + pbm: string; + pgf: string; + pic: string; + raw: string; + webp: string; + php: string; + js: string; + ejs: string; + jsx: string; + ini: string; + dlc: string; + dll: string; + config: string; + conf: string; + esx: string; + ts: string; + tsx: string; + 'd.ts': string; + pdf: string; + xlsx: string; + xls: string; + csv: string; + vscodeignore: string; + vsixmanifest: string; + suo: string; + sln: string; + pdb: string; + cs: string; + csx: string; + csproj: string; + zip: string; + tar: string; + gz: string; + xz: string; + bzip2: string; + gzip: string; + '7z': string; + '7zip': string; + pzip: string; + wim: string; + rar: string; + tgz: string; + exe: string; + msi: string; + java: string; + jar: string; + jsp: string; + c: string; + h: string; + m: string; + cc: string; + cpp: string; + 'c++': string; + hpp: string; + mm: string; + cxx: string; + go: string; + py: string; + url: string; + sh: string; + bat: string; + ps1: string; + fish: string; + bash: string; + gradle: string; + doc: string; + docx: string; + rtf: string; + properties: string; + prop: string; + settings: string; + sql: string; + accdb: string; + mdb: string; + cer: string; + cert: string; + crt: string; + pub: string; + key: string; + pem: string; + asc: string; + woff: string; + woff2: string; + ttf: string; + eot: string; + suit: string; + otf: string; + bmap: string; + fnt: string; + odttf: string; + ttc: string; + font: string; + fonts: string; + sui: string; + ntf: string; + mrf: string; + lib: string; + rb: string; + erb: string; + fs: string; + fsx: string; + fsi: string; + fsproj: string; + manifest: string; + swift: string; + ino: string; + dockerignore: string; + tex: string; + bib: string; + pptx: string; + ppt: string; + pptm: string; + potx: string; + pot: string; + potm: string; + ppsx: string; + ppsm: string; + pps: string; + ppam: string; + ppa: string; + webm: string; + mkv: string; + flv: string; + vob: string; + ogv: string; + ogg: string; + gifv: string; + avi: string; + mov: string; + qt: string; + wmv: string; + yuv: string; + rm: string; + rmvb: string; + mp4: string; + m4v: string; + mpg: string; + mp2: string; + mpeg: string; + mpe: string; + mpv: string; + m2v: string; + vdi: string; + vbox: string; + 'vbox-prev': string; + ics: string; + mp3: string; + flac: string; + m4a: string; + wma: string; + aiff: string; + coffee: string; + txt: string; + sqlite: string; + graphql: string; + gql: string; + props: string; + toml: string; + rs: string; + raml: string; + xaml: string; + prefs: string; + hs: string; + kt: string; + project: string; + patch: string; + dockerfile: string; + vb: string; + lua: string; + clj: string; + groovy: string; + r: string; + rst: string; + dart: string; + as: string; + mxml: string; + ahk: string; + swf: string; + swc: string; + cmake: string; + asm: string; + a51: string; + inc: string; + nasm: string; + s: string; + ms: string; + agc: string; + ags: string; + aea: string; + argus: string; + mitigus: string; + binsource: string; + vue: string; + ml: string; + mli: string; + cmx: string; + 'js.map': string; + 'css.map': string; + tmTheme: string; + pp: string; + applescript: string; + haml: string; + }; + fileNames: { + 'gruntfile.js': string; + 'bower.json': string; + '.bowerrc': string; + 'webpack.js': string; + 'webpack.config.js': string; + 'webpack.dev.js': string; + 'webpack.prod.js': string; + 'webpack.common.js': string; + 'webpackfile.js': string; + 'ionic.config.json': string; + '.io-config.json': string; + 'gulpfile.js': string; + 'gulpfile.babel.js': string; + 'package.json': string; + 'gradle.properties': string; + gradlew: string; + '.jscsrc': string; + '.jshintrc': string; + '.jshintignore': string; + '.npmignore': string; + 'tsconfig.json': string; + 'tslint.json': string; + 'androidmanifest.xml': string; + 'gradle-wrapper.properties': string; + '.editorconfig': string; + procfile: string; + '.env': string; + dockerfile: string; + license: string; + 'license.md': string; + 'license.md.rendered': string; + 'license.txt': string; + '.babelrc': string; + '.eslintrc': string; + '.buildignore': string; + '.htaccess': string; + 'composer.lock': string; + '.gitignore': string; + '.gitconfig': string; + '.gitattributes': string; + '.gitmodules': string; + '.gitkeep': string; + 'yarn.lock': string; + '.yarnclean': string; + '.yarn-integrity': string; + 'yarn-error.log': string; + 'contributing.md': string; + 'contributing.md.rendered': string; + 'readme.md': string; + 'readme.md.rendered': string; + '.mailmap': string; + makefile: string; + changelog: string; + 'changelog.md': string; + 'changelog.md.rendered': string; + CREDITS: string; + 'credits.txt': string; + 'credits.md': string; + 'credits.md.rendered': string; + '.flowconfig': string; + '.jsbeautifyrc': string; + 'git-history': string; + 'angular-cli.json': string; + 'app.module.ts': string; + 'favicon.ico': string; + }; + file: string; + folder: string; + folderExpanded: string; + languageIds: + { git: string }; + light: { + folderExpanded: string; + folder: string; + folderNames: { + node_modules: string; + '.git': string; + '.github': string; + '.gulp': string; + bower_components: string; + build: string; + dist: string; + }; + folderNamesExpanded: { + node_modules: string; + '.git': string; + '.github': string; + '.gulp': string; + bower_components: string; + build: string; + dist: string; + }; + }; + folderNames: { + node_modules: string; + '.git': string; + '.github': string; + '.gulp': string; + bower_components: string; + build: string; + dist: string; + }; + folderNamesExpanded: { + node_modules: string; + '.git': string; + '.github': string; + '.gulp': string; + bower_components: string; + build: string; + dist: string; }; - "folderNames": - { "node_modules": string; - ".git": string; - ".github": string; - ".gulp": string; - "bower_components": string; - "build": string; - "dist": string }; - "folderNamesExpanded": - { "node_modules": string; - ".git": string; - ".github": string; - ".gulp": string; - "bower_components": string; - "build": string; - "dist": string } } diff --git a/extensions/material.theme.config.ts b/extensions/material.theme.config.ts index 4382632..a1f5c40 100644 --- a/extensions/material.theme.config.ts +++ b/extensions/material.theme.config.ts @@ -3,10 +3,10 @@ import { commands as Commands } from 'vscode'; -import { THEME_ACCENTS_SETTER } from "./commands/accents-setter/index"; -import { THEME_ICONS } from "./commands/theme-icons/index"; -import { shouldShowChangelog, showChangelog } from './helpers/changelog'; -import { reloadWindow, getCurrentThemeID, setIconsID } from "./helpers/vscode"; +import {THEME_ACCENTS_SETTER} from './commands/accents-setter/index'; +import {THEME_ICONS} from './commands/theme-icons/index'; +import {shouldShowChangelog, showChangelog} from './helpers/changelog'; +import {reloadWindow, getCurrentThemeID, setIconsID} from './helpers/vscode'; const isMaterialTheme = (currentTheme: string): boolean => currentTheme.includes('Material Theme'); @@ -18,6 +18,7 @@ export function activate() { Workspace.onDidChangeConfiguration(event => { const isColorTheme = event.affectsConfiguration('workbench.colorTheme'); const currentTheme = getCurrentThemeID(); + // tslint:disable-next-line:early-exit if (isColorTheme && isMaterialTheme(currentTheme)) { setIconsID('eq-material-theme-icons') .then(() => THEME_ICONS().catch(error => console.trace(error))) diff --git a/gulpfile.babel.ts b/gulpfile.babel.ts index 40ab315..9cde7bd 100644 --- a/gulpfile.babel.ts +++ b/gulpfile.babel.ts @@ -6,4 +6,4 @@ import * as tasks from './.gulp'; GulpStats(Gulp); // set default task -Gulp.task('default', tasks.default as any); \ No newline at end of file +Gulp.task('default', tasks.default as any); diff --git a/package.json b/package.json index 12d91f4..a14a015 100644 --- a/package.json +++ b/package.json @@ -38,6 +38,7 @@ "build-icons-variants": "yarn gulp build:icons.variants", "build-themes": "yarn gulp build:themes", "build-ts": "tsc -p ./tsconfig.json", + "test": "tslint **.ts", "release": "standard-version", "postinstall": "node ./node_modules/vscode/bin/install && opencollective postinstall && tsc -p tsconfig.json" }, @@ -46,9 +47,7 @@ "Other" ], "activationEvents": [ - "onCommand:materialTheme.setAccent", - "onCommand:materialTheme.fixIcons", - "onCommand:materialTheme.showChangelog" + "*" ], "main": "./extensions/material.theme.config.js", "contributes": { @@ -164,8 +163,6 @@ "babel-preset-es2015": "6.24.1", "babel-root-import": "4.1.8", "cpx": "1.5.0", - "eslint": "4.17.0", - "eslint-plugin-standard": "3.0.1", "gulp": "3.9.1", "gulp-bump": "3.1.0", "gulp-conventional-changelog": "1.1.11", @@ -179,7 +176,9 @@ "run-sequence": "2.2.1", "standard-version": "4.3.0", "svgo": "1.0.4", - "typescript": "2.7.1", + "tslint": "5.9.1", + "tslint-xo": "0.7.2", + "typescript": "2.8.3", "vscode": "1.1.10", "yamljs": "0.3.0", "yargs": "11.0.0" diff --git a/tsconfig.json b/tsconfig.json index 7c6e2b7..26f66ad 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,7 +1,7 @@ { "compilerOptions": { "lib": [ - "es2015" + "es6" ], "module": "commonjs", "allowUnreachableCode": false, diff --git a/tslint.json b/tslint.json new file mode 100644 index 0000000..5cd744e --- /dev/null +++ b/tslint.json @@ -0,0 +1,7 @@ +{ + "extends": "tslint-xo", + "rules": { + "comment-format": false, + "indent": [true, "spaces"] + } +} diff --git a/yarn.lock b/yarn.lock index 615aef3..5078c18 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,6 +2,22 @@ # yarn lockfile v1 +"@fimbul/bifrost@^0.6.0": + version "0.6.0" + resolved "https://registry.yarnpkg.com/@fimbul/bifrost/-/bifrost-0.6.0.tgz#5150302b63e1bd37ff95f561c3605949cb7e3770" + dependencies: + "@fimbul/ymir" "^0.6.0" + get-caller-file "^1.0.2" + tslib "^1.8.1" + +"@fimbul/ymir@^0.6.0": + version "0.6.0" + resolved "https://registry.yarnpkg.com/@fimbul/ymir/-/ymir-0.6.0.tgz#537cb15d361b7c993fe953b48c898ecdf4f671b8" + dependencies: + inversify "^4.10.0" + reflect-metadata "^0.1.12" + tslib "^1.8.1" + "@types/chalk@2.2.0": version "2.2.0" resolved "https://registry.yarnpkg.com/@types/chalk/-/chalk-2.2.0.tgz#b7f6e446f4511029ee8e3f43075fb5b73fbaa0ba" @@ -127,29 +143,11 @@ abbrev@1: version "1.1.1" resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8" -acorn-jsx@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-3.0.1.tgz#afdf9488fb1ecefc8348f6fb22f464e32a58b36b" - dependencies: - acorn "^3.0.4" - -acorn@^3.0.4: - version "3.3.0" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-3.3.0.tgz#45e37fb39e8da3f25baee3ff5369e2bb5f22017a" - -acorn@^5.5.0: - version "5.5.3" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.5.3.tgz#f473dd47e0277a08e28e9bec5aeeb04751f0b8c9" - add-stream@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/add-stream/-/add-stream-1.0.0.tgz#6a7990437ca736d5e1288db92bd3266d5f5cb2aa" -ajv-keywords@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-3.1.0.tgz#ac2b27939c543e95d2c06e7f7f5c27be4aa543be" - -ajv@^5.1.0, ajv@^5.3.0: +ajv@^5.1.0: version "5.5.2" resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965" dependencies: @@ -158,15 +156,6 @@ ajv@^5.1.0, ajv@^5.3.0: fast-json-stable-stringify "^2.0.0" json-schema-traverse "^0.3.0" -ajv@^6.0.1: - version "6.4.0" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.4.0.tgz#d3aff78e9277549771daf0164cff48482b754fc6" - dependencies: - fast-deep-equal "^1.0.0" - fast-json-stable-stringify "^2.0.0" - json-schema-traverse "^0.3.0" - uri-js "^3.0.2" - align-text@^0.1.1, align-text@^0.1.3: version "0.1.4" resolved "https://registry.yarnpkg.com/align-text/-/align-text-0.1.4.tgz#0cd90a561093f35d0a99256c22b7069433fad117" @@ -195,10 +184,6 @@ ansi-escapes@^1.1.0: version "1.4.0" resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-1.4.0.tgz#d3a8a83b319aa67793662b13e761c7911422306e" -ansi-escapes@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.1.0.tgz#f73207bb81207d75fd6c83f125af26eea378ca30" - ansi-gray@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/ansi-gray/-/ansi-gray-0.1.1.tgz#2962cf54ec9792c48510a3deb524436861ef7251" @@ -912,7 +897,7 @@ buffer-from@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.0.0.tgz#4cb8832d23612589b0406e9e2956c17f06fdf531" -builtin-modules@^1.0.0: +builtin-modules@^1.0.0, builtin-modules@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/builtin-modules/-/builtin-modules-1.1.1.tgz#270f076c5a72c02f5b65a47df94c5fe3a278892f" @@ -937,16 +922,6 @@ cache-base@^1.0.1: union-value "^1.0.0" unset-value "^1.0.0" -caller-path@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/caller-path/-/caller-path-0.1.0.tgz#94085ef63581ecd3daa92444a8fe94e82577751f" - dependencies: - callsites "^0.2.0" - -callsites@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/callsites/-/callsites-0.2.0.tgz#afab96262910a7f33c19a5775825c69f34e350ca" - camelcase-keys@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/camelcase-keys/-/camelcase-keys-2.1.0.tgz#308beeaffdf28119051efa1d932213c91b8f92e7" @@ -989,7 +964,7 @@ center-align@^0.1.1: align-text "^0.1.3" lazy-cache "^1.0.3" -chalk@*, chalk@^2.0.0, chalk@^2.1.0, chalk@^2.2.0: +chalk@*, chalk@^2.2.0: version "2.4.0" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.0.tgz#a060a297a6b57e15b61ca63ce84995daa0fe6e52" dependencies: @@ -1017,6 +992,14 @@ chalk@^0.5.1: strip-ansi "^0.3.0" supports-color "^0.2.0" +chalk@^2.3.0: + version "2.4.1" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.1.tgz#18c49ab16a037b6eb0152cc83e3471338215b66e" + dependencies: + ansi-styles "^3.2.1" + escape-string-regexp "^1.0.5" + supports-color "^5.3.0" + chardet@^0.4.0: version "0.4.2" resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.4.2.tgz#b5473b33dc97c424e5d98dc87d55d4d8a29c8bf2" @@ -1040,10 +1023,6 @@ chownr@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/chownr/-/chownr-1.0.1.tgz#e2a75042a9551908bebd25b8523d5f9769d79181" -circular-json@^0.3.1: - version "0.3.3" - resolved "https://registry.yarnpkg.com/circular-json/-/circular-json-0.3.3.tgz#815c99ea84f6809529d2f45791bdf82711352d66" - class-utils@^0.3.5: version "0.3.6" resolved "https://registry.yarnpkg.com/class-utils/-/class-utils-0.3.6.tgz#f93369ae8b9a7ce02fd41faad0ca83033190c463" @@ -1168,7 +1147,7 @@ commander@2.11.0: version "2.11.0" resolved "https://registry.yarnpkg.com/commander/-/commander-2.11.0.tgz#157152fd1e7a6c8d98a5b715cf376df928004563" -commander@^2.9.0: +commander@^2.12.1, commander@^2.9.0: version "2.15.1" resolved "https://registry.yarnpkg.com/commander/-/commander-2.15.1.tgz#df46e867d0fc2aec66a34662b406a9ccafff5b0f" @@ -1187,7 +1166,7 @@ concat-map@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" -concat-stream@^1.4.10, concat-stream@^1.5.0, concat-stream@^1.6.0: +concat-stream@^1.4.10, concat-stream@^1.5.0: version "1.6.2" resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" dependencies: @@ -1372,7 +1351,7 @@ cpx@1.5.0: shell-quote "^1.6.1" subarg "^1.0.0" -cross-spawn@^5.0.1, cross-spawn@^5.1.0: +cross-spawn@^5.0.1: version "5.1.0" resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-5.1.0.tgz#e8bd0efee58fcff6f8f94510a0a554bbfa235449" dependencies: @@ -1466,7 +1445,7 @@ dateformat@^3.0.0: version "3.0.3" resolved "https://registry.yarnpkg.com/dateformat/-/dateformat-3.0.3.tgz#a6e37499a4d9a9cf85ef5872044d62901c9889ae" -debug@3.1.0, debug@^3.1.0: +debug@3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" dependencies: @@ -1503,10 +1482,6 @@ deep-extend@~0.4.0: version "0.4.2" resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.4.2.tgz#48b699c27e334bf89f10892be432f6e4c7d34a7f" -deep-is@~0.1.3: - version "0.1.3" - resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" - defaults@^1.0.0: version "1.0.3" resolved "https://registry.yarnpkg.com/defaults/-/defaults-1.0.3.tgz#c656051e9817d9ff08ed881477f3fe4019f3ef7d" @@ -1539,18 +1514,6 @@ define-property@^2.0.2: is-descriptor "^1.0.2" isobject "^3.0.1" -del@^2.0.2: - version "2.2.2" - resolved "https://registry.yarnpkg.com/del/-/del-2.2.2.tgz#c12c981d067846c84bcaf862cff930d907ffd1a8" - dependencies: - globby "^5.0.0" - is-path-cwd "^1.0.0" - is-path-in-cwd "^1.0.0" - object-assign "^4.0.1" - pify "^2.0.0" - pinkie-promise "^2.0.0" - rimraf "^2.2.8" - delayed-stream@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" @@ -1581,11 +1544,16 @@ diff@3.3.1: version "3.3.1" resolved "https://registry.yarnpkg.com/diff/-/diff-3.3.1.tgz#aa8567a6eed03c531fc89d3f711cd0e5259dec75" -doctrine@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.1.0.tgz#5cd01fc101621b42c4cd7f5d1a66243716d3f39d" +diff@^3.2.0: + version "3.5.0" + resolved "https://registry.yarnpkg.com/diff/-/diff-3.5.0.tgz#800c0dd1e0a8bfbc95835c202ad220fe317e5a12" + +doctrine@0.7.2: + version "0.7.2" + resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-0.7.2.tgz#7cb860359ba3be90e040b26b729ce4bfa654c523" dependencies: - esutils "^2.0.2" + esutils "^1.1.6" + isarray "0.0.1" dom-serializer@0: version "0.1.0" @@ -1697,89 +1665,13 @@ escape-string-regexp@1.0.5, escape-string-regexp@^1.0.0, escape-string-regexp@^1 version "1.0.5" resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" -eslint-plugin-standard@3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/eslint-plugin-standard/-/eslint-plugin-standard-3.0.1.tgz#34d0c915b45edc6f010393c7eef3823b08565cf2" - -eslint-scope@^3.7.1: - version "3.7.1" - resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-3.7.1.tgz#3d63c3edfda02e06e01a452ad88caacc7cdcb6e8" - dependencies: - esrecurse "^4.1.0" - estraverse "^4.1.1" - -eslint-visitor-keys@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" - -eslint@4.17.0: - version "4.17.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-4.17.0.tgz#dc24bb51ede48df629be7031c71d9dc0ee4f3ddf" - dependencies: - ajv "^5.3.0" - babel-code-frame "^6.22.0" - chalk "^2.1.0" - concat-stream "^1.6.0" - cross-spawn "^5.1.0" - debug "^3.1.0" - doctrine "^2.1.0" - eslint-scope "^3.7.1" - eslint-visitor-keys "^1.0.0" - espree "^3.5.2" - esquery "^1.0.0" - esutils "^2.0.2" - file-entry-cache "^2.0.0" - functional-red-black-tree "^1.0.1" - glob "^7.1.2" - globals "^11.0.1" - ignore "^3.3.3" - imurmurhash "^0.1.4" - inquirer "^3.0.6" - is-resolvable "^1.0.0" - js-yaml "^3.9.1" - json-stable-stringify-without-jsonify "^1.0.1" - levn "^0.3.0" - lodash "^4.17.4" - minimatch "^3.0.2" - mkdirp "^0.5.1" - natural-compare "^1.4.0" - optionator "^0.8.2" - path-is-inside "^1.0.2" - pluralize "^7.0.0" - progress "^2.0.0" - require-uncached "^1.0.3" - semver "^5.3.0" - strip-ansi "^4.0.0" - strip-json-comments "~2.0.1" - table "^4.0.1" - text-table "~0.2.0" - -espree@^3.5.2: - version "3.5.4" - resolved "https://registry.yarnpkg.com/espree/-/espree-3.5.4.tgz#b0f447187c8a8bed944b815a660bddf5deb5d1a7" - dependencies: - acorn "^5.5.0" - acorn-jsx "^3.0.0" - esprima@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.0.tgz#4499eddcd1110e0b218bacf2fa7f7f59f55ca804" -esquery@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708" - dependencies: - estraverse "^4.0.0" - -esrecurse@^4.1.0: - version "4.2.1" - resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.2.1.tgz#007a3b9fdbc2b3bb87e4879ea19c92fdbd3942cf" - dependencies: - estraverse "^4.1.0" - -estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1: - version "4.2.0" - resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.2.0.tgz#0dee3fed31fcd469618ce7342099fc1afa0bdb13" +esutils@^1.1.6: + version "1.1.6" + resolved "https://registry.yarnpkg.com/esutils/-/esutils-1.1.6.tgz#c01ccaa9ae4b897c6d0c3e210ae52f3c7a844375" esutils@^2.0.2: version "2.0.2" @@ -1862,7 +1754,7 @@ extend@^3.0.0, extend@~3.0.0, extend@~3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444" -external-editor@^2.0.1, external-editor@^2.0.4: +external-editor@^2.0.1: version "2.2.0" resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-2.2.0.tgz#045511cfd8d133f3846673d1047c154e214ad3d5" dependencies: @@ -1913,10 +1805,6 @@ fast-json-stable-stringify@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" -fast-levenshtein@~2.0.4: - version "2.0.6" - resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" - fd-slicer@~1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/fd-slicer/-/fd-slicer-1.0.1.tgz#8b5bcbd9ec327c5041bf9ab023fd6750f1177e65" @@ -1936,13 +1824,6 @@ figures@^2.0.0: dependencies: escape-string-regexp "^1.0.5" -file-entry-cache@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-2.0.0.tgz#c392990c3e684783d838b8c84a45d8a048458361" - dependencies: - flat-cache "^1.2.1" - object-assign "^4.0.1" - filename-regex@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/filename-regex/-/filename-regex-2.0.1.tgz#c1c4b9bee3e09725ddb106b75c1e301fe2f18b26" @@ -2010,15 +1891,6 @@ flagged-respawn@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/flagged-respawn/-/flagged-respawn-1.0.0.tgz#4e79ae9b2eb38bf86b3bb56bf3e0a56aa5fcabd7" -flat-cache@^1.2.1: - version "1.3.0" - resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-1.3.0.tgz#d3030b32b38154f4e3b7e9c709f490f7ef97c481" - dependencies: - circular-json "^0.3.1" - del "^2.0.2" - graceful-fs "^4.1.2" - write "^0.2.1" - for-in@^1.0.1, for-in@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" @@ -2109,10 +1981,6 @@ function-bind@^1.0.2, function-bind@^1.1.0, function-bind@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" -functional-red-black-tree@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" - gauge@~2.7.3: version "2.7.4" resolved "https://registry.yarnpkg.com/gauge/-/gauge-2.7.4.tgz#2c03405c7538c39d7eb37b317022e325fb018bf7" @@ -2142,7 +2010,7 @@ generate-object-property@^1.1.0: dependencies: is-property "^1.0.0" -get-caller-file@^1.0.1: +get-caller-file@^1.0.1, get-caller-file@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.2.tgz#f702e63127e7e231c160a80c1554acb70d5047e5" @@ -2260,7 +2128,7 @@ glob2base@^0.0.12: dependencies: find-index "^0.1.1" -glob@7.1.2, glob@^7.0.3, glob@^7.0.5, glob@^7.1.2: +glob@7.1.2, glob@^7.0.5, glob@^7.1.1, glob@^7.1.2: version "7.1.2" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15" dependencies: @@ -2316,25 +2184,10 @@ global-prefix@^1.0.1: is-windows "^1.0.1" which "^1.2.14" -globals@^11.0.1: - version "11.4.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-11.4.0.tgz#b85c793349561c16076a3c13549238a27945f1bc" - globals@^9.18.0: version "9.18.0" resolved "https://registry.yarnpkg.com/globals/-/globals-9.18.0.tgz#aa3896b3e69b487f17e31ed2143d69a8e30c2d8a" -globby@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/globby/-/globby-5.0.0.tgz#ebd84667ca0dbb330b99bcfc68eac2bc54370e0d" - dependencies: - array-union "^1.0.1" - arrify "^1.0.0" - glob "^7.0.3" - object-assign "^4.0.1" - pify "^2.0.0" - pinkie-promise "^2.0.0" - globule@~0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/globule/-/globule-0.1.0.tgz#d9c8edde1da79d125a151b79533b978676346ae5" @@ -2704,14 +2557,6 @@ ignore-walk@^3.0.1: dependencies: minimatch "^3.0.4" -ignore@^3.3.3: - version "3.3.7" - resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.7.tgz#612289bfb3c220e186a58118618d5be8c1bab021" - -imurmurhash@^0.1.4: - version "0.1.4" - resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" - indent-string@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-2.1.0.tgz#8e2d48348742121b4a8218b7a137e9a52049dc80" @@ -2759,25 +2604,6 @@ inquirer@3.0.6: strip-ansi "^3.0.0" through "^2.3.6" -inquirer@^3.0.6: - version "3.3.0" - resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-3.3.0.tgz#9dd2f2ad765dcab1ff0443b491442a20ba227dc9" - dependencies: - ansi-escapes "^3.0.0" - chalk "^2.0.0" - cli-cursor "^2.1.0" - cli-width "^2.0.0" - external-editor "^2.0.4" - figures "^2.0.0" - lodash "^4.3.0" - mute-stream "0.0.7" - run-async "^2.2.0" - rx-lite "^4.0.8" - rx-lite-aggregates "^4.0.8" - string-width "^2.1.0" - strip-ansi "^4.0.0" - through "^2.3.6" - interpret@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.1.0.tgz#7ed1b1410c6a0e0f78cf95d3b8440c63f78b8614" @@ -2788,6 +2614,10 @@ invariant@^2.2.2: dependencies: loose-envify "^1.0.0" +inversify@^4.10.0: + version "4.13.0" + resolved "https://registry.yarnpkg.com/inversify/-/inversify-4.13.0.tgz#0ab40570bfa4474b04d5b919bbab3a4f682a72f5" + invert-kv@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6" @@ -2963,22 +2793,6 @@ is-odd@^2.0.0: dependencies: is-number "^4.0.0" -is-path-cwd@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-path-cwd/-/is-path-cwd-1.0.0.tgz#d225ec23132e89edd38fda767472e62e65f1106d" - -is-path-in-cwd@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/is-path-in-cwd/-/is-path-in-cwd-1.0.1.tgz#5ac48b345ef675339bd6c7a48a912110b241cf52" - dependencies: - is-path-inside "^1.0.0" - -is-path-inside@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/is-path-inside/-/is-path-inside-1.0.1.tgz#8ef5b7de50437a3fdca6b4e865ef7aa55cb48036" - dependencies: - path-is-inside "^1.0.1" - is-plain-obj@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-plain-obj/-/is-plain-obj-1.1.0.tgz#71a50c8429dfca773c92a390a4a03b39fcd51d3e" @@ -3017,10 +2831,6 @@ is-relative@^1.0.0: dependencies: is-unc-path "^1.0.0" -is-resolvable@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.1.0.tgz#fb18f87ce1feb925169c9a407c19318a3206ed88" - is-stream@^1.0.1, is-stream@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" @@ -3095,7 +2905,7 @@ js-tokens@^3.0.0, js-tokens@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" -js-yaml@^3.9.1: +js-yaml@^3.7.0: version "3.11.0" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.11.0.tgz#597c1a8bd57152f26d622ce4117851a51f5ebaef" dependencies: @@ -3137,10 +2947,6 @@ json-schema@0.2.3: version "0.2.3" resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" -json-stable-stringify-without-jsonify@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" - json-stable-stringify@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz#9a759d39c5f2ff503fd5300646ed445f88c4f9af" @@ -3216,13 +3022,6 @@ lcid@^1.0.0: dependencies: invert-kv "^1.0.0" -levn@^0.3.0, levn@~0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee" - dependencies: - prelude-ls "~1.1.2" - type-check "~0.3.2" - liftoff@^2.1.0: version "2.5.0" resolved "https://registry.yarnpkg.com/liftoff/-/liftoff-2.5.0.tgz#2009291bb31cea861bbf10a7c15a28caf75c31ec" @@ -3665,10 +3464,6 @@ natives@^1.1.0: version "1.1.3" resolved "https://registry.yarnpkg.com/natives/-/natives-1.1.3.tgz#44a579be64507ea2d6ed1ca04a9415915cf75558" -natural-compare@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" - needle@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/needle/-/needle-2.2.0.tgz#f14efc69cee1024b72c8b21c7bdf94a731dc12fa" @@ -3885,17 +3680,6 @@ optimist@^0.6.1: minimist "~0.0.1" wordwrap "~0.0.2" -optionator@^0.8.2: - version "0.8.2" - resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.2.tgz#364c5e409d3f4d6301d6c0b4c05bba50180aeb64" - dependencies: - deep-is "~0.1.3" - fast-levenshtein "~2.0.4" - levn "~0.3.0" - prelude-ls "~1.1.2" - type-check "~0.3.2" - wordwrap "~1.0.0" - orchestrator@^0.3.0: version "0.3.8" resolved "https://registry.yarnpkg.com/orchestrator/-/orchestrator-0.3.8.tgz#14e7e9e2764f7315fbac184e506c7aa6df94ad7e" @@ -4018,10 +3802,6 @@ path-is-absolute@^1.0.0, path-is-absolute@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" -path-is-inside@^1.0.1, path-is-inside@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/path-is-inside/-/path-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53" - path-key@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40" @@ -4118,18 +3898,10 @@ plugin-log@^0.1.0: chalk "^1.1.1" dateformat "^1.0.11" -pluralize@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/pluralize/-/pluralize-7.0.0.tgz#298b89df8b93b0221dbf421ad2b1b1ea23fc6777" - posix-character-classes@^0.1.0: version "0.1.1" resolved "https://registry.yarnpkg.com/posix-character-classes/-/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab" -prelude-ls@~1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54" - preserve@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/preserve/-/preserve-0.2.0.tgz#815ed1f6ebc65926f865b310c0713bcb3315ce4b" @@ -4146,10 +3918,6 @@ process-nextick-args@^2.0.0, process-nextick-args@~2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.0.tgz#a37d732f4271b4ab1ad070d35508e8290788ffaa" -progress@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.0.tgz#8a1be366bf8fc23db2bd23f10c6fe920b4389d1f" - pseudomap@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" @@ -4158,10 +3926,6 @@ punycode@^1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" -punycode@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.0.tgz#5f863edc89b96db09074bad7947bf09056ca4e7d" - q@^1.1.2, q@^1.4.1, q@^1.5.1: version "1.5.1" resolved "https://registry.yarnpkg.com/q/-/q-1.5.1.tgz#7e32f75b41381291d04611f1bf14109ac00651d7" @@ -4314,6 +4078,10 @@ redent@^2.0.0: indent-string "^3.0.0" strip-indent "^2.0.0" +reflect-metadata@^0.1.12: + version "0.1.12" + resolved "https://registry.yarnpkg.com/reflect-metadata/-/reflect-metadata-0.1.12.tgz#311bf0c6b63cd782f228a81abe146a2bfa9c56f2" + regenerate@^1.2.1: version "1.3.3" resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.3.3.tgz#0c336d3980553d755c39b586ae3b20aa49c82b7f" @@ -4451,13 +4219,6 @@ require-main-filename@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-1.0.1.tgz#97f717b69d48784f5f526a6c5aa8ffdda055a4d1" -require-uncached@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/require-uncached/-/require-uncached-1.0.3.tgz#4e0d56d6c9662fd31e43011c4b95aa49955421d3" - dependencies: - caller-path "^0.1.0" - resolve-from "^1.0.0" - requires-port@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" @@ -4469,15 +4230,11 @@ resolve-dir@^1.0.0, resolve-dir@^1.0.1: expand-tilde "^2.0.0" global-modules "^1.0.0" -resolve-from@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-1.0.1.tgz#26cbfe935d1aeeeabb29bc3fe5aeb01e93d44226" - resolve-url@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" -resolve@^1.1.6, resolve@^1.1.7: +resolve@^1.1.6, resolve@^1.1.7, resolve@^1.3.2: version "1.7.1" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.7.1.tgz#aadd656374fd298aee895bc026b8297418677fd3" dependencies: @@ -4500,7 +4257,7 @@ right-align@^0.1.1: dependencies: align-text "^0.1.1" -rimraf@2, rimraf@2.6.2, rimraf@^2.2.8, rimraf@^2.6.1: +rimraf@2, rimraf@2.6.2, rimraf@^2.6.1: version "2.6.2" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.2.tgz#2ed8150d24a16ea8651e6d6ef0f47c4158ce7a36" dependencies: @@ -4520,16 +4277,6 @@ run-sequence@2.2.1: fancy-log "^1.3.2" plugin-error "^0.1.2" -rx-lite-aggregates@^4.0.8: - version "4.0.8" - resolved "https://registry.yarnpkg.com/rx-lite-aggregates/-/rx-lite-aggregates-4.0.8.tgz#753b87a89a11c95467c4ac1626c4efc4e05c67be" - dependencies: - rx-lite "*" - -rx-lite@*, rx-lite@^4.0.8: - version "4.0.8" - resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-4.0.8.tgz#0b1e11af8bc44836f04a6407e92da42467b79444" - rx@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/rx/-/rx-4.1.0.tgz#a5f13ff79ef3b740fe30aa803fb09f98805d4782" @@ -4621,12 +4368,6 @@ slash@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/slash/-/slash-1.0.0.tgz#c41f2f6c39fc16d1cd17ad4b5d896114ae470d55" -slice-ansi@1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-1.0.0.tgz#044f1a49d8842ff307aad6b505ed178bd950134d" - dependencies: - is-fullwidth-code-point "^2.0.0" - snapdragon-node@^2.0.1: version "2.1.1" resolved "https://registry.yarnpkg.com/snapdragon-node/-/snapdragon-node-2.1.1.tgz#6c175f86ff14bdb0724563e8f3c1b021a286853b" @@ -4834,7 +4575,7 @@ string-width@^1.0.1, string-width@^1.0.2: is-fullwidth-code-point "^1.0.0" strip-ansi "^3.0.0" -string-width@^2.0.0, string-width@^2.1.0, string-width@^2.1.1: +string-width@^2.0.0, string-width@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" dependencies: @@ -4960,17 +4701,6 @@ svgo@1.0.4: unquote "~1.1.1" util.promisify "~1.0.0" -table@^4.0.1: - version "4.0.3" - resolved "https://registry.yarnpkg.com/table/-/table-4.0.3.tgz#00b5e2b602f1794b9acaf9ca908a76386a7813bc" - dependencies: - ajv "^6.0.1" - ajv-keywords "^3.0.0" - chalk "^2.1.0" - lodash "^4.17.4" - slice-ansi "1.0.0" - string-width "^2.1.1" - tar@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/tar/-/tar-2.2.1.tgz#8e4d2a256c0e2185c6b18ad694aec968b83cb1d1" @@ -5004,7 +4734,7 @@ text-extensions@^1.0.0: version "1.7.0" resolved "https://registry.yarnpkg.com/text-extensions/-/text-extensions-1.7.0.tgz#faaaba2625ed746d568a23e4d0aacd9bf08a8b39" -text-table@^0.2.0, text-table@~0.2.0: +text-table@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" @@ -5103,6 +4833,69 @@ trim-right@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/trim-right/-/trim-right-1.0.1.tgz#cb2e1203067e0c8de1f614094b9fe45704ea6003" +tslib@1.9.0, tslib@^1.7.1, tslib@^1.8.0, tslib@^1.8.1: + version "1.9.0" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.9.0.tgz#e37a86fda8cbbaf23a057f473c9f4dc64e5fc2e8" + +tslint-consistent-codestyle@^1.11.0: + version "1.13.0" + resolved "https://registry.yarnpkg.com/tslint-consistent-codestyle/-/tslint-consistent-codestyle-1.13.0.tgz#82abf230bf39e01159b4e9af721d489dd5ae0e6c" + dependencies: + "@fimbul/bifrost" "^0.6.0" + tslib "^1.7.1" + tsutils "^2.24.0" + +tslint-eslint-rules@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/tslint-eslint-rules/-/tslint-eslint-rules-5.1.0.tgz#3232b318da55dbb5a83e3f5d657c1ddbb27b9ff2" + dependencies: + doctrine "0.7.2" + tslib "1.9.0" + tsutils "2.8.0" + +tslint-microsoft-contrib@^5.0.2: + version "5.0.3" + resolved "https://registry.yarnpkg.com/tslint-microsoft-contrib/-/tslint-microsoft-contrib-5.0.3.tgz#6fc3e238179cd72045c2b422e4d655f4183a8d5c" + dependencies: + tsutils "^2.12.1" + +tslint-xo@0.7.2: + version "0.7.2" + resolved "https://registry.yarnpkg.com/tslint-xo/-/tslint-xo-0.7.2.tgz#7523e9f2819e23c5ce66b501e4b76067c1e6f637" + dependencies: + tslint-consistent-codestyle "^1.11.0" + tslint-eslint-rules "^5.1.0" + tslint-microsoft-contrib "^5.0.2" + +tslint@5.9.1: + version "5.9.1" + resolved "https://registry.yarnpkg.com/tslint/-/tslint-5.9.1.tgz#1255f87a3ff57eb0b0e1f0e610a8b4748046c9ae" + dependencies: + babel-code-frame "^6.22.0" + builtin-modules "^1.1.1" + chalk "^2.3.0" + commander "^2.12.1" + diff "^3.2.0" + glob "^7.1.1" + js-yaml "^3.7.0" + minimatch "^3.0.4" + resolve "^1.3.2" + semver "^5.3.0" + tslib "^1.8.0" + tsutils "^2.12.1" + +tsutils@2.8.0: + version "2.8.0" + resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-2.8.0.tgz#0160173729b3bf138628dd14a1537e00851d814a" + dependencies: + tslib "^1.7.1" + +tsutils@^2.12.1, tsutils@^2.24.0: + version "2.26.2" + resolved "https://registry.yarnpkg.com/tsutils/-/tsutils-2.26.2.tgz#a9f9f63434a456a5e0c95a45d9a59181cb32d3bf" + dependencies: + tslib "^1.8.1" + tunnel-agent@^0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz#27a5dea06b36b04a0a9966774b290868f0fc40fd" @@ -5117,19 +4910,13 @@ tweetnacl@^0.14.3, tweetnacl@~0.14.0: version "0.14.5" resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" -type-check@~0.3.2: - version "0.3.2" - resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.3.2.tgz#5884cab512cf1d355e3fb784f30804b2b520db72" - dependencies: - prelude-ls "~1.1.2" - typedarray@^0.0.6: version "0.0.6" resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" -typescript@2.7.1: - version "2.7.1" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-2.7.1.tgz#bb3682c2c791ac90e7c6210b26478a8da085c359" +typescript@2.8.3: + version "2.8.3" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-2.8.3.tgz#5d817f9b6f31bb871835f4edf0089f21abe6c170" uglify-js@^2.6: version "2.8.29" @@ -5179,12 +4966,6 @@ unset-value@^1.0.0: has-value "^0.3.1" isobject "^3.0.0" -uri-js@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-3.0.2.tgz#f90b858507f81dea4dcfbb3c4c3dbfa2b557faaa" - dependencies: - punycode "^2.1.0" - urix@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/urix/-/urix-0.1.0.tgz#da937f7a62e21fec1fd18d49b35c2935067a6c72" @@ -5381,10 +5162,6 @@ wordwrap@~0.0.2: version "0.0.3" resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz#a3d5da6cd5c0bc0008d37234bbaf1bed63059107" -wordwrap@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" - wrap-ansi@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz#d8fc3d284dd05794fe84973caecdd1cf824fdd85" @@ -5396,12 +5173,6 @@ wrappy@1: version "1.0.2" resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" -write@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/write/-/write-0.2.1.tgz#5fc03828e264cea3fe91455476f7a3c566cb0757" - dependencies: - mkdirp "^0.5.1" - "xtend@>=4.0.0 <4.1.0-0", xtend@^4.0.0, xtend@^4.0.1, xtend@~4.0.0, xtend@~4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.1.tgz#a5c6d532be656e23db820efb943a1f04998d63af"