diff --git a/addons/api/.eslintignore b/addons/api/.eslintignore index 72df37307..922165552 100644 --- a/addons/api/.eslintignore +++ b/addons/api/.eslintignore @@ -13,6 +13,7 @@ # misc /coverage/ !.* +.eslintcache # ember-try /.node_modules.ember-try/ diff --git a/addons/api/.eslintrc.js b/addons/api/.eslintrc.js index 928585995..49fb14100 100644 --- a/addons/api/.eslintrc.js +++ b/addons/api/.eslintrc.js @@ -7,48 +7,54 @@ module.exports = { ecmaVersion: 2018, sourceType: 'module', ecmaFeatures: { - legacyDecorators: true - } + legacyDecorators: true, + }, }, - plugins: [ - 'ember' - ], + plugins: ['ember'], extends: [ 'eslint:recommended', - 'plugin:ember/recommended' + 'plugin:ember/recommended', + 'plugin:prettier/recommended', ], env: { - browser: true + browser: true, + }, + rules: { + 'ember/no-get': 'off', + 'ember/no-get-with-default': 'off', + 'ember/no-computed-properties-in-native-classes': 'off', + 'ember/no-assignment-of-untracked-properties-used-in-tracking-contexts': + 'off', }, - rules: {}, overrides: [ // node files { files: [ '.eslintrc.js', + '.prettierrc.js', '.template-lintrc.js', 'ember-cli-build.js', 'index.js', 'testem.js', 'blueprints/*/index.js', 'config/**/*.js', - 'tests/dummy/config/**/*.js' + 'tests/dummy/config/**/*.js', ], excludedFiles: [ 'addon/**', 'addon-test-support/**', 'app/**', - 'tests/dummy/app/**' + 'tests/dummy/app/**', ], parserOptions: { - sourceType: 'script' + sourceType: 'script', }, env: { browser: false, - node: true + node: true, }, plugins: ['node'], - extends: ['plugin:node/recommended'] - } - ] + extends: ['plugin:node/recommended'], + }, + ], }; diff --git a/addons/api/.npmignore b/addons/api/.npmignore index bd09adff9..88818f2c8 100644 --- a/addons/api/.npmignore +++ b/addons/api/.npmignore @@ -10,6 +10,7 @@ /.editorconfig /.ember-cli /.env* +/.eslintcache /.eslintignore /.eslintrc.js /.git/ diff --git a/addons/core/.gitignore b/addons/api/.prettierignore similarity index 50% rename from addons/core/.gitignore rename to addons/api/.prettierignore index c40a1b2ab..922165552 100644 --- a/addons/core/.gitignore +++ b/addons/api/.prettierignore @@ -1,4 +1,6 @@ -# See https://help.github.com/ignore-files/ for more about ignoring files. +# unconventional js +/blueprints/*/files/ +/vendor/ # compiled output /dist/ @@ -9,15 +11,9 @@ /node_modules/ # misc -/.env* -/.pnp* -/.sass-cache -/connect.lock /coverage/ -/libpeerconnection.log -/npm-debug.log* -/testem.log -/yarn-error.log +!.* +.eslintcache # ember-try /.node_modules.ember-try/ diff --git a/addons/api/.prettierrc.js b/addons/api/.prettierrc.js new file mode 100644 index 000000000..534e6d35a --- /dev/null +++ b/addons/api/.prettierrc.js @@ -0,0 +1,5 @@ +'use strict'; + +module.exports = { + singleQuote: true, +}; diff --git a/addons/api/.template-lintrc.js b/addons/api/.template-lintrc.js index f38737001..3b0b9af95 100644 --- a/addons/api/.template-lintrc.js +++ b/addons/api/.template-lintrc.js @@ -1,5 +1,5 @@ 'use strict'; module.exports = { - extends: 'octane' + extends: 'octane', }; diff --git a/addons/api/addon/generated/models/role.js b/addons/api/addon/generated/models/role.js index 3632696a4..87bfa46f8 100644 --- a/addons/api/addon/generated/models/role.js +++ b/addons/api/addon/generated/models/role.js @@ -18,7 +18,8 @@ export default class GeneratedRoleModel extends BaseModel { description; @attr('string', { - description: 'The scope to which this role applies. Defaults to the role\'s scope.', + description: + "The scope to which this role applies. Defaults to the role's scope.", }) grant_scope_id; diff --git a/addons/api/addon/generated/models/session.js b/addons/api/addon/generated/models/session.js index a33426e4c..977fff71d 100644 --- a/addons/api/addon/generated/models/session.js +++ b/addons/api/addon/generated/models/session.js @@ -2,7 +2,6 @@ import BaseModel from '../../models/base'; import { attr } from '@ember-data/model'; export default class GeneratedSessionModel extends BaseModel { - // =attributes @attr('string') user_id; @@ -32,5 +31,4 @@ export default class GeneratedSessionModel extends BaseModel { description: 'Current version number of this resource.', }) version; - } diff --git a/addons/api/addon/generated/models/target.js b/addons/api/addon/generated/models/target.js index 55c83d18c..4bf84649f 100644 --- a/addons/api/addon/generated/models/target.js +++ b/addons/api/addon/generated/models/target.js @@ -24,13 +24,13 @@ export default class GeneratedTargetModel extends BaseModel { @attr('number', { description: '', - defaultValue: 28800 + defaultValue: 28800, }) session_max_seconds; @attr('number', { description: '', - defaultValue: 1 + defaultValue: 1, }) session_connection_limit; diff --git a/addons/api/addon/models/account.js b/addons/api/addon/models/account.js index a4e1359f3..90ad55c42 100644 --- a/addons/api/addon/models/account.js +++ b/addons/api/addon/models/account.js @@ -4,7 +4,6 @@ import { computed } from '@ember/object'; import { equal } from '@ember/object/computed'; export default class AccountModel extends GeneratedAccountModel { - // =attributes /** diff --git a/addons/api/addon/models/base.js b/addons/api/addon/models/base.js index 60ed2faea..70da1b8a6 100644 --- a/addons/api/addon/models/base.js +++ b/addons/api/addon/models/base.js @@ -25,7 +25,6 @@ import { computed } from '@ember/object'; * 2) Or as an ID: `record.scopeID`. */ export default class BaseModel extends Model { - // =relationships /** diff --git a/addons/api/addon/models/host-set.js b/addons/api/addon/models/host-set.js index 3c56d2879..66dd96d52 100644 --- a/addons/api/addon/models/host-set.js +++ b/addons/api/addon/models/host-set.js @@ -2,7 +2,6 @@ import GeneratedHostSetModel from '../generated/models/host-set'; import { fragmentArray } from 'ember-data-model-fragments/attributes'; export default class HostSetModel extends GeneratedHostSetModel { - // =attributes /** diff --git a/addons/api/addon/models/host.js b/addons/api/addon/models/host.js index a2e855084..7748e023b 100644 --- a/addons/api/addon/models/host.js +++ b/addons/api/addon/models/host.js @@ -2,11 +2,9 @@ import GeneratedHostModel from '../generated/models/host'; import { fragment } from 'ember-data-model-fragments/attributes'; export default class HostModel extends GeneratedHostModel { - /** * Attributes of this resource, if any, represented as a JSON fragment. * @type {FragmentHostAttributesModel} */ @fragment('fragment-host-attributes', { defaultValue: {} }) attributes; - } diff --git a/addons/api/addon/models/role.js b/addons/api/addon/models/role.js index be29c1c24..60edd5ac9 100644 --- a/addons/api/addon/models/role.js +++ b/addons/api/addon/models/role.js @@ -35,7 +35,7 @@ export default class RoleModel extends GeneratedRoleModel { return this.save({ adapterOptions: { method: 'set-grants', - grantStrings + grantStrings, }, }); } diff --git a/addons/api/addon/models/session.js b/addons/api/addon/models/session.js index dd27cd9c6..15fd0b4dd 100644 --- a/addons/api/addon/models/session.js +++ b/addons/api/addon/models/session.js @@ -4,7 +4,6 @@ import { equal } from '@ember/object/computed'; import { attr } from '@ember-data/model'; export default class SessionModel extends GeneratedSessionModel { - // =attributes @attr('string', { readOnly: true }) proxy_address; @@ -61,5 +60,4 @@ export default class SessionModel extends GeneratedSessionModel { }, }); } - } diff --git a/addons/api/addon/models/target.js b/addons/api/addon/models/target.js index 6c5e1cfe8..a00c3b182 100644 --- a/addons/api/addon/models/target.js +++ b/addons/api/addon/models/target.js @@ -41,8 +41,9 @@ export default class TargetModel extends GeneratedTargetModel { * @type {SessionModel[]} */ get sessions() { - return this.store.peekAll('session') - .filter(s => s && (s.target_id === this.id)); + return this.store + .peekAll('session') + .filter((s) => s && s.target_id === this.id); } /** @@ -58,8 +59,9 @@ export default class TargetModel extends GeneratedTargetModel { * @type {boolean} */ get isActive() { - const pendingOrActiveSessions = - this.sessions.filter(s => s.isActive || s.isPending); + const pendingOrActiveSessions = this.sessions.filter( + (s) => s.isActive || s.isPending + ); return Boolean(pendingOrActiveSessions.length); } diff --git a/addons/api/addon/models/user.js b/addons/api/addon/models/user.js index 567ebd81c..49fe64520 100644 --- a/addons/api/addon/models/user.js +++ b/addons/api/addon/models/user.js @@ -3,7 +3,6 @@ import { attr } from '@ember-data/model'; import { A } from '@ember/array'; export default class UserModel extends GeneratedUserModel { - // =attributes /** @@ -74,5 +73,4 @@ export default class UserModel extends GeneratedUserModel { removeAccount(accountID, options) { return this.removeAccounts([accountID], options); } - } diff --git a/addons/api/addon/serializers/account.js b/addons/api/addon/serializers/account.js index 5f5291dcd..dfbb7e580 100644 --- a/addons/api/addon/serializers/account.js +++ b/addons/api/addon/serializers/account.js @@ -1,7 +1,6 @@ import ApplicationSerializer from './application'; export default class AccountSerializer extends ApplicationSerializer { - // =properties /** diff --git a/addons/api/addon/serializers/application.js b/addons/api/addon/serializers/application.js index e4531c7fe..08b59eebc 100644 --- a/addons/api/addon/serializers/application.js +++ b/addons/api/addon/serializers/application.js @@ -7,7 +7,6 @@ import { copy } from 'ember-copy'; * Manages serialization/normalization of data to/from the API. */ export default class ApplicationSerializer extends RESTSerializer { - // =properties /** @@ -82,7 +81,7 @@ export default class ApplicationSerializer extends RESTSerializer { // Delete `scope` field delete serialized.scope; // And serialize `scope_id` - if(this.serializeScopeID) { + if (this.serializeScopeID) { const scope_id = snapshot?.attr('scope')?.attr('scope_id'); if (scope_id) serialized.scope_id = scope_id; } diff --git a/addons/api/addon/serializers/host-set.js b/addons/api/addon/serializers/host-set.js index ee38bd5eb..5bdb2d028 100644 --- a/addons/api/addon/serializers/host-set.js +++ b/addons/api/addon/serializers/host-set.js @@ -1,7 +1,6 @@ import ApplicationSerializer from './application'; export default class HostSetSerializer extends ApplicationSerializer { - // =properties /** diff --git a/addons/api/addon/serializers/host.js b/addons/api/addon/serializers/host.js index fad6f2ca7..0b25ce63b 100644 --- a/addons/api/addon/serializers/host.js +++ b/addons/api/addon/serializers/host.js @@ -1,12 +1,10 @@ import ApplicationSerializer from './application'; export default class HostSerializer extends ApplicationSerializer { - // =properties /** * @type {boolean} */ serializeScopeID = false; - } diff --git a/addons/api/addon/serializers/role.js b/addons/api/addon/serializers/role.js index 59271fe44..a1801ff63 100644 --- a/addons/api/addon/serializers/role.js +++ b/addons/api/addon/serializers/role.js @@ -17,8 +17,8 @@ export default class RoleSerializer extends ApplicationSerializer { serialize(snapshot) { const grantStrings = get(snapshot, 'adapterOptions.grantStrings'); let serialized = super.serialize(...arguments); - if (grantStrings) serialized = - this.serializeWithGrantStrings(snapshot, grantStrings); + if (grantStrings) + serialized = this.serializeWithGrantStrings(snapshot, grantStrings); const principalIDs = snapshot?.adapterOptions?.principalIDs; if (principalIDs) serialized = this.serializewithPrincipals(snapshot, principalIDs); @@ -34,7 +34,7 @@ export default class RoleSerializer extends ApplicationSerializer { serializeWithGrantStrings(snapshot, grantStrings) { return { version: snapshot.attr('version'), - grant_strings: grantStrings + grant_strings: grantStrings, }; } diff --git a/addons/api/addon/serializers/user.js b/addons/api/addon/serializers/user.js index 9c4a47194..c5c3b223c 100644 --- a/addons/api/addon/serializers/user.js +++ b/addons/api/addon/serializers/user.js @@ -13,8 +13,8 @@ export default class UserSerializer extends ApplicationSerializer { serialize(snapshot) { let serialized = super.serialize(...arguments); const accountIDs = snapshot?.adapterOptions?.accountIDs; - if (accountIDs) serialized = - this.serializewithAccounts(snapshot, accountIDs); + if (accountIDs) + serialized = this.serializewithAccounts(snapshot, accountIDs); return serialized; } diff --git a/addons/api/config/ember-try.js b/addons/api/config/ember-try.js index 2022058df..aa7ca9f14 100644 --- a/addons/api/config/ember-try.js +++ b/addons/api/config/ember-try.js @@ -25,9 +25,9 @@ module.exports = async function () { name: 'ember-lts-3.20', npm: { devDependencies: { - 'ember-source': '~3.20.5' - } - } + 'ember-source': '~3.20.5', + }, + }, }, { name: 'ember-release', @@ -62,9 +62,9 @@ module.exports = async function () { }, npm: { devDependencies: { - '@ember/jquery': '^1.1.0' - } - } + '@ember/jquery': '^1.1.0', + }, + }, }, { name: 'ember-classic', diff --git a/addons/api/mirage/config.js b/addons/api/mirage/config.js index 8f6503319..ad976e8e7 100644 --- a/addons/api/mirage/config.js +++ b/addons/api/mirage/config.js @@ -5,8 +5,7 @@ import { pickRandomStatusString } from './factories/session'; import { Response } from 'miragejs'; import initializeMockIPC from './scenarios/ipc'; -export default function() { - +export default function () { initializeMockIPC(this); // make this `http://localhost:8080`, for example, if your API is on a different server @@ -23,17 +22,20 @@ export default function() { // Scope resources - this.get('/scopes', ({ scopes }, { queryParams: { scope_id, recursive } }) => { - // Default parent scope is global - if (!scope_id) scope_id = 'global'; - if (recursive && scope_id === 'global') { - return scopes.all(); - } else { - return scopes.where(scope => { - return scope.scope ? scope.scope.id === scope_id : false - }); + this.get( + '/scopes', + ({ scopes }, { queryParams: { scope_id, recursive } }) => { + // Default parent scope is global + if (!scope_id) scope_id = 'global'; + if (recursive && scope_id === 'global') { + return scopes.all(); + } else { + return scopes.where((scope) => { + return scope.scope ? scope.scope.id === scope_id : false; + }); + } } - }); + ); this.post('/scopes', function ({ scopes }) { // Parent scope comes through the payload via `scope_id`, but this needs // to be expanded to a scope object `scope: {id:..., type:...}` before @@ -49,41 +51,50 @@ export default function() { // Auth & IAM resources - this.get('/auth-methods', ({ authMethods }, { queryParams: { scope_id: scopeId } }) => { - return authMethods.where({ scopeId }); - }); + this.get( + '/auth-methods', + ({ authMethods }, { queryParams: { scope_id: scopeId } }) => { + return authMethods.where({ scopeId }); + } + ); this.post('/auth-methods'); this.get('/auth-methods/:id'); this.patch('/auth-methods/:id'); this.del('/auth-methods/:id'); // Auth Method Accounts - this.get('/accounts', ({ accounts }, { queryParams: { auth_method_id: authMethodId } }) => { - return accounts.where({ authMethodId }); - }); + this.get( + '/accounts', + ({ accounts }, { queryParams: { auth_method_id: authMethodId } }) => { + return accounts.where({ authMethodId }); + } + ); this.post('/accounts'); this.get('/accounts/:id'); this.patch('/accounts/:id'); this.del('/accounts/:id'); - this.post('/accounts/:idMethod', function ({ accounts }, { params: { idMethod } }) { - const attrs = this.normalizedRequestAttrs(); - const id = idMethod.split(':')[0]; - const method = idMethod.split(':')[1]; - const account = accounts.find(id); - const updatedAttrs = { - version: attrs.version, - attributes: account.attributes - }; - // Set new password - if (method === 'set-password') { - updatedAttrs.attributes.password = attrs.password; + this.post( + '/accounts/:idMethod', + function ({ accounts }, { params: { idMethod } }) { + const attrs = this.normalizedRequestAttrs(); + const id = idMethod.split(':')[0]; + const method = idMethod.split(':')[1]; + const account = accounts.find(id); + const updatedAttrs = { + version: attrs.version, + attributes: account.attributes, + }; + // Set new password + if (method === 'set-password') { + updatedAttrs.attributes.password = attrs.password; + } + // Set new password + if (method === 'change-password') { + updatedAttrs.attributes.password = attrs.new_password; + } + return account.update(updatedAttrs); } - // Set new password - if (method === 'change-password') { - updatedAttrs.attributes.password = attrs.new_password; - } - return account.update(updatedAttrs); - }); + ); // Authenticate/deauthenticate routes this.post('/auth-methods/:id_method', authHandler); @@ -104,11 +115,11 @@ export default function() { const user = users.find(id); const updatedAttrs = { version: attrs.version, - accountIds: user.accountIds + accountIds: user.accountIds, }; // If adding accounts, push them into the array if (method === 'add-accounts') { - attrs.accountIds.forEach(id => { + attrs.accountIds.forEach((id) => { if (!updatedAttrs.accountIds.includes(id)) { updatedAttrs.accountIds.push(id); } @@ -116,7 +127,7 @@ export default function() { } // If deleting accounts, filter them out of the array if (method === 'remove-accounts') { - updatedAttrs.accountIds = updatedAttrs.accountIds.filter(id => { + updatedAttrs.accountIds = updatedAttrs.accountIds.filter((id) => { return !attrs.accountIds.includes(id); }); } @@ -131,31 +142,34 @@ export default function() { this.get('/groups/:id'); this.patch('/groups/:id'); this.del('/groups/:id'); - this.post('/groups/:idMethod', function ({ groups }, { params: { idMethod } }) { - const attrs = this.normalizedRequestAttrs(); - const id = idMethod.split(':')[0]; - const method = idMethod.split(':')[1]; - const group = groups.find(id); - const updatedAttrs = { - version: attrs.version, - memberIds: group.memberIds - }; - // If adding members, push them into the array - if (method === 'add-members') { - attrs.memberIds.forEach(id => { - if (!updatedAttrs.memberIds.includes(id)) { - updatedAttrs.memberIds.push(id); - } - }); + this.post( + '/groups/:idMethod', + function ({ groups }, { params: { idMethod } }) { + const attrs = this.normalizedRequestAttrs(); + const id = idMethod.split(':')[0]; + const method = idMethod.split(':')[1]; + const group = groups.find(id); + const updatedAttrs = { + version: attrs.version, + memberIds: group.memberIds, + }; + // If adding members, push them into the array + if (method === 'add-members') { + attrs.memberIds.forEach((id) => { + if (!updatedAttrs.memberIds.includes(id)) { + updatedAttrs.memberIds.push(id); + } + }); + } + // If deleting members, filter them out of the array + if (method === 'remove-members') { + updatedAttrs.memberIds = updatedAttrs.memberIds.filter((id) => { + return !attrs.memberIds.includes(id); + }); + } + return group.update(updatedAttrs); } - // If deleting members, filter them out of the array - if (method === 'remove-members') { - updatedAttrs.memberIds = updatedAttrs.memberIds.filter(id => { - return !attrs.memberIds.includes(id); - }); - } - return group.update(updatedAttrs); - }); + ); // IAM: Roles this.get('/roles', ({ roles }, { queryParams: { scope_id: scopeId } }) => { @@ -165,66 +179,72 @@ export default function() { this.get('/roles/:id'); this.patch('/roles/:id'); this.del('/roles/:id'); - this.post('/roles/:idMethod', function ({ roles, users, groups }, { params: { idMethod } }) { - const attrs = this.normalizedRequestAttrs(); - const id = idMethod.split(':')[0]; - const method = idMethod.split(':')[1]; - const role = roles.find(id); - let updatedAttrs = {}; + this.post( + '/roles/:idMethod', + function ({ roles, users, groups }, { params: { idMethod } }) { + const attrs = this.normalizedRequestAttrs(); + const id = idMethod.split(':')[0]; + const method = idMethod.split(':')[1]; + const role = roles.find(id); + let updatedAttrs = {}; - // Principals is a combined list of users and groups, but in Mirage we've - // internally modelled them as separate lists. Therefore we must check - // the type by looking up the user or group first, then determine which - // list to add the principal to. - if (method === 'add-principals') { - updatedAttrs = { - version: attrs.version, - userIds: role.userIds, - groupIds: role.groupIds - }; - attrs.principalIds.forEach(id => { - const isUser = users.find(id); - const isGroup = groups.find(id); - if (isUser && !updatedAttrs.userIds.includes(id)) { - updatedAttrs.userIds.push(id); - } - if (isGroup && !updatedAttrs.groupIds.includes(id)) { - updatedAttrs.groupIds.push(id); - } - }); - } - // If deleting principals, filter them out of both users and groups, - // and in this case don't care about the type - if (method === 'remove-principals') { - updatedAttrs = { - version: attrs.version, - userIds: role.userIds, - groupIds: role.groupIds - }; - updatedAttrs.userIds = updatedAttrs.userIds.filter(id => { - return !attrs.principalIds.includes(id); - }); - updatedAttrs.groupIds = updatedAttrs.groupIds.filter(id => { - return !attrs.principalIds.includes(id); - }); - } + // Principals is a combined list of users and groups, but in Mirage we've + // internally modelled them as separate lists. Therefore we must check + // the type by looking up the user or group first, then determine which + // list to add the principal to. + if (method === 'add-principals') { + updatedAttrs = { + version: attrs.version, + userIds: role.userIds, + groupIds: role.groupIds, + }; + attrs.principalIds.forEach((id) => { + const isUser = users.find(id); + const isGroup = groups.find(id); + if (isUser && !updatedAttrs.userIds.includes(id)) { + updatedAttrs.userIds.push(id); + } + if (isGroup && !updatedAttrs.groupIds.includes(id)) { + updatedAttrs.groupIds.push(id); + } + }); + } + // If deleting principals, filter them out of both users and groups, + // and in this case don't care about the type + if (method === 'remove-principals') { + updatedAttrs = { + version: attrs.version, + userIds: role.userIds, + groupIds: role.groupIds, + }; + updatedAttrs.userIds = updatedAttrs.userIds.filter((id) => { + return !attrs.principalIds.includes(id); + }); + updatedAttrs.groupIds = updatedAttrs.groupIds.filter((id) => { + return !attrs.principalIds.includes(id); + }); + } - if (method === 'set-grants') { - updatedAttrs = { - version: attrs.version, - grantStrings: attrs.grantStrings - }; - } + if (method === 'set-grants') { + updatedAttrs = { + version: attrs.version, + grantStrings: attrs.grantStrings, + }; + } - return role.update(updatedAttrs); - }); + return role.update(updatedAttrs); + } + ); // Other resources // host-catalog - this.get('/host-catalogs', ({ hostCatalogs }, { queryParams: { scope_id: scopeId } }) => { - return hostCatalogs.where({ scopeId }); - }); + this.get( + '/host-catalogs', + ({ hostCatalogs }, { queryParams: { scope_id: scopeId } }) => { + return hostCatalogs.where({ scopeId }); + } + ); this.post('/host-catalogs'); this.get('/host-catalogs/:id'); this.patch('/host-catalogs/:id'); @@ -232,9 +252,12 @@ export default function() { // host - this.get('/hosts', function ({ hosts }, { queryParams: { host_catalog_id: hostCatalogId } }) { - return hosts.where({ hostCatalogId }); - }); + this.get( + '/hosts', + function ({ hosts }, { queryParams: { host_catalog_id: hostCatalogId } }) { + return hosts.where({ hostCatalogId }); + } + ); this.post('/hosts', function ({ hostCatalogs, hosts }) { const attrs = this.normalizedRequestAttrs(); const hostCatalog = hostCatalogs.find(attrs.hostCatalogId); @@ -247,9 +270,15 @@ export default function() { // host-set - this.get('/host-sets', function ({ hostSets }, { queryParams: { host_catalog_id: hostCatalogId } }) { - return hostSets.where({ hostCatalogId }); - }); + this.get( + '/host-sets', + function ( + { hostSets }, + { queryParams: { host_catalog_id: hostCatalogId } } + ) { + return hostSets.where({ hostCatalogId }); + } + ); this.post('/host-sets', function ({ hostCatalogs, hostSets }) { const attrs = this.normalizedRequestAttrs(); const hostCatalog = hostCatalogs.find(attrs.hostCatalogId); @@ -259,49 +288,57 @@ export default function() { this.get('/host-sets/:id'); this.patch('/host-sets/:id'); this.del('/host-sets/:id'); - this.post('/host-sets/:idMethod', function ({ hostSets }, { params: { idMethod } }) { - const attrs = this.normalizedRequestAttrs(); - const id = idMethod.split(':')[0]; - const method = idMethod.split(':')[1]; - const hostSet = hostSets.find(id); - const updatedAttrs = { - version: attrs.version, - hostIds: hostSet.hostIds - } + this.post( + '/host-sets/:idMethod', + function ({ hostSets }, { params: { idMethod } }) { + const attrs = this.normalizedRequestAttrs(); + const id = idMethod.split(':')[0]; + const method = idMethod.split(':')[1]; + const hostSet = hostSets.find(id); + const updatedAttrs = { + version: attrs.version, + hostIds: hostSet.hostIds, + }; - // If adding hosts, push them into the array - if(method === 'add-hosts') { - attrs.hostIds.forEach(id => { - if(!updatedAttrs.hostIds.includes(id)) { - updatedAttrs.hostIds.push(id); - } - }) - } + // If adding hosts, push them into the array + if (method === 'add-hosts') { + attrs.hostIds.forEach((id) => { + if (!updatedAttrs.hostIds.includes(id)) { + updatedAttrs.hostIds.push(id); + } + }); + } - // If deleting hosts, filter them out of the array - if (method === 'remove-hosts') { - updatedAttrs.hostIds = updatedAttrs.hostIds.filter(id => { - return !attrs.hostIds.includes(id); - }); - } + // If deleting hosts, filter them out of the array + if (method === 'remove-hosts') { + updatedAttrs.hostIds = updatedAttrs.hostIds.filter((id) => { + return !attrs.hostIds.includes(id); + }); + } - return hostSet.update(updatedAttrs); - }); + return hostSet.update(updatedAttrs); + } + ); // target - this.get('/targets', function ({ targets }, { queryParams: { scope_id, recursive } }) { - if (recursive && scope_id === 'global') { - return targets.all(); - } else if (recursive) { - return targets.where(target => { - const targetModel = targets.find(target.id); - return (target.scopeId === scope_id) - || (targetModel?.scope?.scope?.id === scope_id) - }); + this.get( + '/targets', + function ({ targets }, { queryParams: { scope_id, recursive } }) { + if (recursive && scope_id === 'global') { + return targets.all(); + } else if (recursive) { + return targets.where((target) => { + const targetModel = targets.find(target.id); + return ( + target.scopeId === scope_id || + targetModel?.scope?.scope?.id === scope_id + ); + }); + } + return targets.where((target) => target.scopeId === scope_id); } - return targets.where(target => target.scopeId === scope_id); - }); + ); this.post('/targets', function ({ targets }) { const attrs = this.normalizedRequestAttrs(); return targets.create(attrs); @@ -309,83 +346,93 @@ export default function() { this.get('/targets/:id'); this.patch('/targets/:id'); this.del('/targets/:id'); - this.post('/targets/:idMethod', function ({ targets }, { params: { idMethod } }) { - const attrs = this.normalizedRequestAttrs(); - const id = idMethod.split(':')[0]; - const method = idMethod.split(':')[1]; - const target = targets.find(id); - const updatedAttrs = { - version: attrs.version, - hostSetIds: target.hostSetIds - }; - // If adding host sets, push them into the array - if (method === 'add-host-sets') { - attrs.hostSetIds.forEach(id => { - if (!updatedAttrs.hostSetIds.includes(id)) { - updatedAttrs.hostSetIds.push(id); - } - }); + this.post( + '/targets/:idMethod', + function ({ targets }, { params: { idMethod } }) { + const attrs = this.normalizedRequestAttrs(); + const id = idMethod.split(':')[0]; + const method = idMethod.split(':')[1]; + const target = targets.find(id); + const updatedAttrs = { + version: attrs.version, + hostSetIds: target.hostSetIds, + }; + // If adding host sets, push them into the array + if (method === 'add-host-sets') { + attrs.hostSetIds.forEach((id) => { + if (!updatedAttrs.hostSetIds.includes(id)) { + updatedAttrs.hostSetIds.push(id); + } + }); + } + // If deleting host sets, filter them out of the array + if (method === 'remove-host-sets') { + updatedAttrs.hostSetIds = updatedAttrs.hostSetIds.filter((id) => { + return !attrs.hostSetIds.includes(id); + }); + } + return target.update(updatedAttrs); } - // If deleting host sets, filter them out of the array - if (method === 'remove-host-sets') { - updatedAttrs.hostSetIds = updatedAttrs.hostSetIds.filter(id => { - return !attrs.hostSetIds.includes(id); - }); - } - return target.update(updatedAttrs); - }); + ); // session - this.get('/sessions', function ({ sessions }, { queryParams: { scope_id, recursive } }) { - // To simulate changes to `session.status` that may occur in the backend, - // we quietly randomize the value of the field on GET. - // To populate sessions for logged in user, - // update alternate sessions to auth user. - // But only if not in testing mode. - // In tests, we need deterministic statuses. - if (!Ember.testing) { - sessions.all() - .models - .forEach(session => { + this.get( + '/sessions', + function ({ sessions }, { queryParams: { scope_id, recursive } }) { + // To simulate changes to `session.status` that may occur in the backend, + // we quietly randomize the value of the field on GET. + // To populate sessions for logged in user, + // update alternate sessions to auth user. + // But only if not in testing mode. + // In tests, we need deterministic statuses. + if (!Ember.testing) { + sessions.all().models.forEach((session) => { session.update({ - status: pickRandomStatusString() - }); - if(session.id.split('-').pop() % 2) session.update({ - userId: 'authenticateduser' + status: pickRandomStatusString(), }); + if (session.id.split('-').pop() % 2) + session.update({ + userId: 'authenticateduser', + }); }); + } + if (recursive && scope_id === 'global') { + return sessions.all(); + } else if (recursive) { + return sessions.where((session) => { + const sessionModel = sessions.find(session.id); + return ( + session.scopeId === scope_id || + sessionModel?.scope?.scope?.id === scope_id + ); + }); + } + return sessions.where((session) => session.scopeId === scope_id); } - if (recursive && scope_id === 'global') { - return sessions.all(); - } else if (recursive) { - return sessions.where(session => { - const sessionModel = sessions.find(session.id); - return (session.scopeId === scope_id) - || (sessionModel?.scope?.scope?.id === scope_id) - }); - } - return sessions.where(session => session.scopeId === scope_id); - }); + ); this.get('/sessions/:id', function ({ sessions }, { params: { id } }) { const session = sessions.find(id); return session.update({ - status: pickRandomStatusString() + status: pickRandomStatusString(), }); }); - this.post('/sessions/:idMethod', function ({ sessions }, { params: { idMethod } }) { - const attrs = this.normalizedRequestAttrs(); - const id = idMethod.split(':')[0]; - const method = idMethod.split(':')[1]; - const session = sessions.find(id); - const updatedAttrs = { - version: attrs.version - }; - if (method === 'cancel') { - updatedAttrs.status = 'canceling'; + this.post( + '/sessions/:idMethod', + function ({ sessions }, { params: { idMethod } }) { + const attrs = this.normalizedRequestAttrs(); + const id = idMethod.split(':')[0]; + const method = idMethod.split(':')[1]; + const session = sessions.find(id); + const updatedAttrs = { + version: attrs.version, + }; + if (method === 'cancel') { + updatedAttrs.status = 'canceling'; + } + return session.update(updatedAttrs); } - return session.update(updatedAttrs); - }); + ); // auth-tokens diff --git a/addons/api/mirage/factories/auth-method.js b/addons/api/mirage/factories/auth-method.js index 61d29726b..b14366c19 100644 --- a/addons/api/mirage/factories/auth-method.js +++ b/addons/api/mirage/factories/auth-method.js @@ -10,11 +10,10 @@ export default factory.extend({ withAccountsAndUsers: trait({ afterCreate(authMethod, server) { const { scope } = authMethod; - server.createList('user', 5, { scope }).map(user => { + server.createList('user', 5, { scope }).map((user) => { const { id } = server.create('account', { scope, authMethod }); user.update({ accountIds: [id] }); }); - } - }) - + }, + }), }); diff --git a/addons/api/mirage/factories/group.js b/addons/api/mirage/factories/group.js index 9531de4f8..79b28cc2e 100644 --- a/addons/api/mirage/factories/group.js +++ b/addons/api/mirage/factories/group.js @@ -13,6 +13,6 @@ export default factory.extend({ const scope = group.scope; const members = server.createList('user', 2, { scope }); group.update({ members }); - } - }) + }, + }), }); diff --git a/addons/api/mirage/factories/host-catalog.js b/addons/api/mirage/factories/host-catalog.js index 1eaed0433..ffb849668 100644 --- a/addons/api/mirage/factories/host-catalog.js +++ b/addons/api/mirage/factories/host-catalog.js @@ -2,13 +2,11 @@ import factory from '../generated/factories/host-catalog'; import { trait } from 'ember-cli-mirage'; export default factory.extend({ - withChildren: trait({ afterCreate(hostCatalog, server) { const { scope } = hostCatalog; const hosts = server.createList('host', 10, { scope, hostCatalog }); server.createList('host-set', 3, { scope, hostCatalog, hosts }); - } - }) - + }, + }), }); diff --git a/addons/api/mirage/factories/host-set.js b/addons/api/mirage/factories/host-set.js index ad9ae1fa1..a3c053fda 100644 --- a/addons/api/mirage/factories/host-set.js +++ b/addons/api/mirage/factories/host-set.js @@ -1,5 +1,5 @@ import factory from '../generated/factories/host-set'; export default factory.extend({ - id: (i) => `host-set-id-${i}` + id: (i) => `host-set-id-${i}`, }); diff --git a/addons/api/mirage/factories/host.js b/addons/api/mirage/factories/host.js index f322cb4d4..c797e8a64 100644 --- a/addons/api/mirage/factories/host.js +++ b/addons/api/mirage/factories/host.js @@ -1,5 +1,5 @@ import factory from '../generated/factories/host'; export default factory.extend({ - id: (i) => `host-id-${i}` + id: (i) => `host-id-${i}`, }); diff --git a/addons/api/mirage/factories/role.js b/addons/api/mirage/factories/role.js index aa4356af7..103a3725b 100644 --- a/addons/api/mirage/factories/role.js +++ b/addons/api/mirage/factories/role.js @@ -2,11 +2,10 @@ import factory from '../generated/factories/role'; import { trait } from 'ember-cli-mirage'; export default factory.extend({ - // eslint-disable-next-line ember/avoid-leaking-state-in-ember-objects grant_strings: () => [ 'id=*;action=*', - 'id=*;type=host-catalog;actions=create,read' + 'id=*;type=host-catalog;actions=create,read', ], /** @@ -18,15 +17,16 @@ export default factory.extend({ const users = server.createList('user', 2, { scope }); const groups = server.createList('group', 2, { scope }); role.update({ users, groups }); - } + }, }), /** * Set the grant scope ID to match the scope ID. */ afterCreate(role) { - const { scope: { id } } = role; + const { + scope: { id }, + } = role; role.update({ grant_scope_id: id }); - } - + }, }); diff --git a/addons/api/mirage/factories/scope.js b/addons/api/mirage/factories/scope.js index a14dbc719..fe41f3866 100644 --- a/addons/api/mirage/factories/scope.js +++ b/addons/api/mirage/factories/scope.js @@ -2,7 +2,6 @@ import factory from '../generated/factories/scope'; import { trait } from 'ember-cli-mirage'; export default factory.extend({ - type: 'global', /** @@ -18,18 +17,22 @@ export default factory.extend({ withChildren: trait({ afterCreate(record, server) { if (record.type === 'global') { - server.createList('scope', 1, { - type: 'org', - scope: { id: record.id, type: record.type } - }, 'withChildren'); + server.createList( + 'scope', + 1, + { + type: 'org', + scope: { id: record.id, type: record.type }, + }, + 'withChildren' + ); } if (record.type === 'org') { server.createList('scope', 3, { type: 'project', - scope: { id: record.id, type: record.type } + scope: { id: record.id, type: record.type }, }); } - } - }) - + }, + }), }); diff --git a/addons/api/mirage/factories/session.js b/addons/api/mirage/factories/session.js index f30301c5c..a581fa9e4 100644 --- a/addons/api/mirage/factories/session.js +++ b/addons/api/mirage/factories/session.js @@ -2,17 +2,11 @@ import factory from '../generated/factories/session'; import { trait } from 'ember-cli-mirage'; import { random } from 'faker'; -const statusStrings = [ - 'pending', - 'active', - 'canceling', - 'terminated' -]; +const statusStrings = ['pending', 'active', 'canceling', 'terminated']; export const pickRandomStatusString = () => random.arrayElement(statusStrings); export default factory.extend({ - id: (i) => `session-id-${i}`, status: pickRandomStatusString, @@ -26,7 +20,8 @@ export default factory.extend({ const scopeId = record.scopeId; if (record.scope.type === 'project') { const orgScopeId = record.scope?.scope.id; - const user = server.schema.users.where({ scopeId: orgScopeId }).models[0]; + const user = server.schema.users.where({ scopeId: orgScopeId }) + .models[0]; if (user) record.update({ user }); } const target = server.schema.targets.where({ scopeId }).models[0]; @@ -39,7 +34,6 @@ export default factory.extend({ if (host) record.update({ host }); } } - } - }) - + }, + }), }); diff --git a/addons/api/mirage/factories/target.js b/addons/api/mirage/factories/target.js index 4f34cc459..2c00b6639 100644 --- a/addons/api/mirage/factories/target.js +++ b/addons/api/mirage/factories/target.js @@ -6,7 +6,6 @@ const randomBoolean = (chance = 0.5) => Math.random() < chance; const hostSetChance = 0.3; export default factory.extend({ - /** * -1 means "unlimited" and we want to generate these on occassion. */ @@ -19,8 +18,8 @@ export default factory.extend({ if (target.type === 'tcp') { target.update({ attributes: { - default_port: random.number() - } + default_port: random.number(), + }, }); } }, @@ -37,10 +36,9 @@ export default factory.extend({ // expect at this level of abstraction, but appears to be a serialized // representation of the model instance. It's very confusing since // the result set of `where` _is a collection of model instances_. - .where(hostSet => hostSet.scopeId === target.scope.id).models - .filter(() => randomBoolean(hostSetChance)); - target.update({hostSets: randomlySelectedHostSets}); - } - }) - + .where((hostSet) => hostSet.scopeId === target.scope.id) + .models.filter(() => randomBoolean(hostSetChance)); + target.update({ hostSets: randomlySelectedHostSets }); + }, + }), }); diff --git a/addons/api/mirage/factories/user.js b/addons/api/mirage/factories/user.js index 42bccd33d..39c5abf96 100644 --- a/addons/api/mirage/factories/user.js +++ b/addons/api/mirage/factories/user.js @@ -1,5 +1,5 @@ import factory from '../generated/factories/user'; export default factory.extend({ - id: (i) => `user-${i}` + id: (i) => `user-${i}`, }); diff --git a/addons/api/mirage/generated/factories/account.js b/addons/api/mirage/generated/factories/account.js index a66184e1f..c659af6a2 100644 --- a/addons/api/mirage/generated/factories/account.js +++ b/addons/api/mirage/generated/factories/account.js @@ -5,7 +5,6 @@ import { random, date } from 'faker'; * GeneratedAccountFactory */ export default Factory.extend({ - type: 'password', name: () => random.words(), description: () => random.words(), @@ -13,5 +12,4 @@ export default Factory.extend({ updated_time: () => date.recent(), version: () => random.number(), attributes: () => ({ login_name: random.words() }), - }); diff --git a/addons/api/mirage/generated/factories/auth-method.js b/addons/api/mirage/generated/factories/auth-method.js index d76245946..26af0cc7f 100644 --- a/addons/api/mirage/generated/factories/auth-method.js +++ b/addons/api/mirage/generated/factories/auth-method.js @@ -5,12 +5,10 @@ import { random, date } from 'faker'; * GeneratedAuthMethodModelFactory */ export default Factory.extend({ - type: 'password', name: () => random.words(), description: () => random.words(), created_time: () => date.recent(), updated_time: () => date.recent(), disabled: () => random.boolean(), - }); diff --git a/addons/api/mirage/generated/factories/group.js b/addons/api/mirage/generated/factories/group.js index 7c78ee7ec..1f0a07f7b 100644 --- a/addons/api/mirage/generated/factories/group.js +++ b/addons/api/mirage/generated/factories/group.js @@ -6,11 +6,9 @@ import { random, date } from 'faker'; * Group contains all fields related to a Group resource */ export default Factory.extend({ - name: () => random.words(), description: () => random.words(), created_time: () => date.recent(), updated_time: () => date.recent(), disabled: () => random.boolean(), - }); diff --git a/addons/api/mirage/generated/factories/host-catalog.js b/addons/api/mirage/generated/factories/host-catalog.js index daf2d356f..83cfe556e 100644 --- a/addons/api/mirage/generated/factories/host-catalog.js +++ b/addons/api/mirage/generated/factories/host-catalog.js @@ -5,12 +5,10 @@ import { random, date } from 'faker'; * GeneratedHostCatalogModelFactory */ export default Factory.extend({ - type: 'static', name: () => random.words(), description: () => random.words(), created_time: () => date.recent(), updated_time: () => date.recent(), disabled: () => random.boolean(), - }); diff --git a/addons/api/mirage/generated/factories/host-set.js b/addons/api/mirage/generated/factories/host-set.js index 95636bda0..9f69c7318 100644 --- a/addons/api/mirage/generated/factories/host-set.js +++ b/addons/api/mirage/generated/factories/host-set.js @@ -5,7 +5,6 @@ import { random, date } from 'faker'; * GeneratedHostSetModelFactory */ export default Factory.extend({ - type: 'static', name: () => random.words(), description: () => random.words(), @@ -13,5 +12,4 @@ export default Factory.extend({ updated_time: () => date.recent(), version: () => random.number(), size: () => random.number(), - }); diff --git a/addons/api/mirage/generated/factories/host.js b/addons/api/mirage/generated/factories/host.js index e6fccf602..adfb886be 100644 --- a/addons/api/mirage/generated/factories/host.js +++ b/addons/api/mirage/generated/factories/host.js @@ -5,13 +5,13 @@ import { random, date, internet } from 'faker'; * GeneratedHostModelFactory */ export default Factory.extend({ - type: 'static', name: () => random.words(), description: () => random.words(), created_time: () => date.recent(), updated_time: () => date.recent(), version: () => random.number(), - attributes: () => { return { address: internet.ipv6() } }, - + attributes: () => { + return { address: internet.ipv6() }; + }, }); diff --git a/addons/api/mirage/generated/factories/org.js b/addons/api/mirage/generated/factories/org.js index 81ee23629..cc1d6200b 100644 --- a/addons/api/mirage/generated/factories/org.js +++ b/addons/api/mirage/generated/factories/org.js @@ -6,10 +6,8 @@ import { random, date } from 'faker'; * */ export default Factory.extend({ - name: () => random.words(), description: () => random.words(), created_time: () => date.recent(), updated_time: () => date.recent(), - }); diff --git a/addons/api/mirage/generated/factories/project.js b/addons/api/mirage/generated/factories/project.js index 69054217d..3f2cca936 100644 --- a/addons/api/mirage/generated/factories/project.js +++ b/addons/api/mirage/generated/factories/project.js @@ -6,11 +6,9 @@ import { random, date } from 'faker'; * Project contains all fields related to a Project resource */ export default Factory.extend({ - name: () => random.words(), description: () => random.words(), created_time: () => date.recent(), updated_time: () => date.recent(), disabled: () => random.boolean(), - }); diff --git a/addons/api/mirage/generated/factories/role.js b/addons/api/mirage/generated/factories/role.js index 13e83aad3..fec661f1a 100644 --- a/addons/api/mirage/generated/factories/role.js +++ b/addons/api/mirage/generated/factories/role.js @@ -6,12 +6,10 @@ import { random, date } from 'faker'; * Role contains all field related to a Role resource */ export default Factory.extend({ - name: () => random.words(), description: () => random.words(), created_time: () => date.recent(), updated_time: () => date.recent(), disabled: () => random.boolean(), version: () => random.number(), - }); diff --git a/addons/api/mirage/generated/factories/scope.js b/addons/api/mirage/generated/factories/scope.js index cc574d3cd..b5c5ca10f 100644 --- a/addons/api/mirage/generated/factories/scope.js +++ b/addons/api/mirage/generated/factories/scope.js @@ -5,11 +5,9 @@ import { random, date } from 'faker'; * GeneratedScopeModelFactory */ export default Factory.extend({ - name: () => random.words(), description: () => random.words(), created_time: () => date.recent(), updated_time: () => date.recent(), disabled: () => random.boolean(), - }); diff --git a/addons/api/mirage/generated/factories/session.js b/addons/api/mirage/generated/factories/session.js index 25aca3759..638580868 100644 --- a/addons/api/mirage/generated/factories/session.js +++ b/addons/api/mirage/generated/factories/session.js @@ -5,10 +5,8 @@ import { random, date } from 'faker'; * GeneratedSessionModelFactory */ export default Factory.extend({ - type: 'tcp', created_time: () => date.recent(), updated_time: () => date.recent(), version: () => random.number(), - }); diff --git a/addons/api/mirage/generated/factories/target.js b/addons/api/mirage/generated/factories/target.js index 5ce21adeb..82eb8769c 100644 --- a/addons/api/mirage/generated/factories/target.js +++ b/addons/api/mirage/generated/factories/target.js @@ -5,7 +5,6 @@ import { random, date } from 'faker'; * GeneratedTargetModelFactory */ export default Factory.extend({ - type: 'tcp', name: () => random.words(), session_max_seconds: () => random.number(), @@ -15,5 +14,4 @@ export default Factory.extend({ updated_time: () => date.recent(), disabled: () => random.boolean(), version: () => random.number(), - }); diff --git a/addons/api/mirage/generated/factories/user.js b/addons/api/mirage/generated/factories/user.js index 3934bc7e9..bdf283e45 100644 --- a/addons/api/mirage/generated/factories/user.js +++ b/addons/api/mirage/generated/factories/user.js @@ -6,11 +6,9 @@ import { random, date } from 'faker'; * User contains all fields related to a User resource */ export default Factory.extend({ - name: () => random.words(), description: () => random.words(), created_time: () => date.recent(), updated_time: () => date.recent(), disabled: () => random.boolean(), - }); diff --git a/addons/api/mirage/models/account.js b/addons/api/mirage/models/account.js index e6d3e303c..8f39ad219 100644 --- a/addons/api/mirage/models/account.js +++ b/addons/api/mirage/models/account.js @@ -1,8 +1,6 @@ import { Model, belongsTo } from 'ember-cli-mirage'; export default Model.extend({ - scope: belongsTo(), - authMethod: belongsTo() - + authMethod: belongsTo(), }); diff --git a/addons/api/mirage/models/auth-method.js b/addons/api/mirage/models/auth-method.js index 08b1f5ad3..7faa2b5a2 100644 --- a/addons/api/mirage/models/auth-method.js +++ b/addons/api/mirage/models/auth-method.js @@ -1,7 +1,5 @@ import { Model, belongsTo } from 'ember-cli-mirage'; export default Model.extend({ - - scope: belongsTo() - + scope: belongsTo(), }); diff --git a/addons/api/mirage/models/group.js b/addons/api/mirage/models/group.js index 3d73f3d73..67446a6d6 100644 --- a/addons/api/mirage/models/group.js +++ b/addons/api/mirage/models/group.js @@ -1,8 +1,6 @@ import { Model, belongsTo, hasMany } from 'ember-cli-mirage'; export default Model.extend({ - scope: belongsTo(), - members: hasMany('user') - + members: hasMany('user'), }); diff --git a/addons/api/mirage/models/host-catalog.js b/addons/api/mirage/models/host-catalog.js index 8c2757e71..0f03cb6ef 100644 --- a/addons/api/mirage/models/host-catalog.js +++ b/addons/api/mirage/models/host-catalog.js @@ -1,8 +1,6 @@ import { Model, belongsTo, hasMany } from 'ember-cli-mirage'; export default Model.extend({ - scope: belongsTo(), - hostSets: hasMany() - + hostSets: hasMany(), }); diff --git a/addons/api/mirage/models/host-set.js b/addons/api/mirage/models/host-set.js index 5a579e119..645c144ff 100644 --- a/addons/api/mirage/models/host-set.js +++ b/addons/api/mirage/models/host-set.js @@ -1,10 +1,8 @@ import { Model, belongsTo, hasMany } from 'ember-cli-mirage'; export default Model.extend({ - scope: belongsTo(), target: belongsTo(), hostCatalog: belongsTo(), - hosts: hasMany() - + hosts: hasMany(), }); diff --git a/addons/api/mirage/models/host.js b/addons/api/mirage/models/host.js index b9a941a4f..88d9026e8 100644 --- a/addons/api/mirage/models/host.js +++ b/addons/api/mirage/models/host.js @@ -1,8 +1,6 @@ import { Model, belongsTo } from 'ember-cli-mirage'; export default Model.extend({ - scope: belongsTo(), - hostCatalog: belongsTo() - + hostCatalog: belongsTo(), }); diff --git a/addons/api/mirage/models/role.js b/addons/api/mirage/models/role.js index 744d1025a..c256df5fc 100644 --- a/addons/api/mirage/models/role.js +++ b/addons/api/mirage/models/role.js @@ -1,9 +1,7 @@ import { Model, belongsTo, hasMany } from 'ember-cli-mirage'; export default Model.extend({ - scope: belongsTo(), users: hasMany(), - groups: hasMany() - + groups: hasMany(), }); diff --git a/addons/api/mirage/models/session.js b/addons/api/mirage/models/session.js index 91a4da594..eb036d6b8 100644 --- a/addons/api/mirage/models/session.js +++ b/addons/api/mirage/models/session.js @@ -1,11 +1,9 @@ import { Model, belongsTo } from 'ember-cli-mirage'; export default Model.extend({ - scope: belongsTo(), user: belongsTo(), target: belongsTo(), host: belongsTo(), hostSet: belongsTo(), - }); diff --git a/addons/api/mirage/models/target.js b/addons/api/mirage/models/target.js index 8c2757e71..0f03cb6ef 100644 --- a/addons/api/mirage/models/target.js +++ b/addons/api/mirage/models/target.js @@ -1,8 +1,6 @@ import { Model, belongsTo, hasMany } from 'ember-cli-mirage'; export default Model.extend({ - scope: belongsTo(), - hostSets: hasMany() - + hostSets: hasMany(), }); diff --git a/addons/api/mirage/models/user.js b/addons/api/mirage/models/user.js index 45cf14952..d3eb79bed 100644 --- a/addons/api/mirage/models/user.js +++ b/addons/api/mirage/models/user.js @@ -1,8 +1,6 @@ import { Model, belongsTo, hasMany } from 'ember-cli-mirage'; export default Model.extend({ - scope: belongsTo(), - accounts: hasMany('account') - + accounts: hasMany('account'), }); diff --git a/addons/api/mirage/route-handlers/auth.js b/addons/api/mirage/route-handlers/auth.js index 5bac04839..1876cd128 100644 --- a/addons/api/mirage/route-handlers/auth.js +++ b/addons/api/mirage/route-handlers/auth.js @@ -31,20 +31,23 @@ export function authHandler({ scopes, authMethods }, request) { const id = request.params.id_method.split(':')[0]; const authMethod = authMethods.find(id); const scope = scopes.find(authMethod.scopeId); - const scopeAttrs = - this.serialize(scopes.find(scope.id)); - return new Response(200, {}, { - scope: scopeAttrs, - id: 'token123', - token: 'thetokenstring', - account_id: '1', - user_id: 'authenticateduser', - auth_method_id: 'authmethod123', - created_time: '', - updated_time: '', - last_used_time: '', - expiration_time: '' - }); + const scopeAttrs = this.serialize(scopes.find(scope.id)); + return new Response( + 200, + {}, + { + scope: scopeAttrs, + id: 'token123', + token: 'thetokenstring', + account_id: '1', + user_id: 'authenticateduser', + auth_method_id: 'authmethod123', + created_time: '', + updated_time: '', + last_used_time: '', + expiration_time: '', + } + ); } } diff --git a/addons/api/mirage/scenarios/default.js b/addons/api/mirage/scenarios/default.js index c1db90168..fe5297ea2 100644 --- a/addons/api/mirage/scenarios/default.js +++ b/addons/api/mirage/scenarios/default.js @@ -1,23 +1,37 @@ -export default function(server) { - +export default function (server) { // Scope resources // creates a global scope const globalScope = server.create('scope', { id: 'global', type: 'global', - name: 'Global' + name: 'Global', }); - const orgScope = server.createList('scope', 3, { - type: 'org', - scope: { id: globalScope.id, type: globalScope.type } - }, 'withChildren')[0]; + const orgScope = server.createList( + 'scope', + 3, + { + type: 'org', + scope: { id: globalScope.id, type: globalScope.type }, + }, + 'withChildren' + )[0]; server.create('user', { id: 'authenticateduser' }); // Auth - server.createList('auth-method', 1, { scope: globalScope }, 'withAccountsAndUsers'); - server.createList('auth-method', 3, { scope: orgScope }, 'withAccountsAndUsers'); + server.createList( + 'auth-method', + 1, + { scope: globalScope }, + 'withAccountsAndUsers' + ); + server.createList( + 'auth-method', + 3, + { scope: orgScope }, + 'withAccountsAndUsers' + ); // Groups and Users server.createList('group', 1, { scope: globalScope }, 'withMembers'); @@ -27,7 +41,7 @@ export default function(server) { server.createList('role', 5, { scope: orgScope }, 'withPrincipals'); // Other resources - server.schema.scopes.where({type: 'project'}).models.forEach(scope => { + server.schema.scopes.where({ type: 'project' }).models.forEach((scope) => { server.createList('host-catalog', 2, { scope }, 'withChildren'); server.createList('target', 2, { scope }, 'withRandomHostSets'); server.createList('session', 4, { scope }, 'withAssociations'); diff --git a/addons/api/mirage/scenarios/ipc.js b/addons/api/mirage/scenarios/ipc.js index f8b7e524a..bf6d1947c 100644 --- a/addons/api/mirage/scenarios/ipc.js +++ b/addons/api/mirage/scenarios/ipc.js @@ -2,7 +2,7 @@ import Ember from 'ember'; import config from 'ember-get-config'; import { random } from 'faker'; -export default function initializeMockIPC (server) { +export default function initializeMockIPC(server) { /** * We strive to make this application runnable in a regular web browser, since * it is a convenient environment for development and testing. But only an @@ -51,13 +51,13 @@ export default function initializeMockIPC (server) { target, userId: 'authenticateduser', type, - created_time: new Date().toISOString() + created_time: new Date().toISOString(), }); return { address: window.location.hostname, port: random.number(), protocol: type, - session_id: newSession.id + session_id: newSession.id, }; } } @@ -80,5 +80,4 @@ export default function initializeMockIPC (server) { } }); } - } diff --git a/addons/api/mirage/serializers/account.js b/addons/api/mirage/serializers/account.js index 85d38851b..3ceb16738 100644 --- a/addons/api/mirage/serializers/account.js +++ b/addons/api/mirage/serializers/account.js @@ -4,9 +4,12 @@ export default ApplicationSerializer.extend({ modelName: 'account', _hashForModel(model) { - const json = ApplicationSerializer.prototype._hashForModel.apply(this, arguments); + const json = ApplicationSerializer.prototype._hashForModel.apply( + this, + arguments + ); json.auth_method_id = model.authMethodId; delete json.attributes?.password; return json; - } + }, }); diff --git a/addons/api/mirage/serializers/application.js b/addons/api/mirage/serializers/application.js index 7bfbc7cd7..453e11e21 100644 --- a/addons/api/mirage/serializers/application.js +++ b/addons/api/mirage/serializers/application.js @@ -6,7 +6,6 @@ import { isArray } from '@ember/array'; * Manages serialization/normalization of data into and out of the mock API. */ export default RestSerializer.extend({ - // =attributes /** @@ -45,7 +44,7 @@ export default RestSerializer.extend({ serialize() { let json = RestSerializer.prototype.serialize.apply(this, arguments); // If array, root it under a standard `items` key - if (isArray(json)) json = {items: json}; + if (isArray(json)) json = { items: json }; return json; }, @@ -59,7 +58,7 @@ export default RestSerializer.extend({ if (model.scope) { json.scope = { id: model.scope.id, - type: model.scope.type + type: model.scope.type, }; } return json; @@ -79,6 +78,5 @@ export default RestSerializer.extend({ } const value = RestSerializer.prototype.normalize.apply(this, [newJSON]); return value; - } - + }, }); diff --git a/addons/api/mirage/serializers/auth-method.js b/addons/api/mirage/serializers/auth-method.js index cabe9ee7b..4bc89ef3b 100644 --- a/addons/api/mirage/serializers/auth-method.js +++ b/addons/api/mirage/serializers/auth-method.js @@ -1,5 +1,5 @@ import ApplicationSerializer from './application'; export default ApplicationSerializer.extend({ - modelName: 'auth-method' + modelName: 'auth-method', }); diff --git a/addons/api/mirage/serializers/group.js b/addons/api/mirage/serializers/group.js index 1ea1605f7..3e879dfdb 100644 --- a/addons/api/mirage/serializers/group.js +++ b/addons/api/mirage/serializers/group.js @@ -11,9 +11,11 @@ export default ApplicationSerializer.extend({ }, _hashForModel(model) { - const json = ApplicationSerializer.prototype._hashForModel.apply(this, arguments); + const json = ApplicationSerializer.prototype._hashForModel.apply( + this, + arguments + ); if (model.memberIds.length) json.member_ids = model.memberIds; return json; - } - + }, }); diff --git a/addons/api/mirage/serializers/host-set.js b/addons/api/mirage/serializers/host-set.js index 7acf251b3..77cd5aa40 100644 --- a/addons/api/mirage/serializers/host-set.js +++ b/addons/api/mirage/serializers/host-set.js @@ -11,12 +11,14 @@ export default ApplicationSerializer.extend({ }, _hashForModel(model) { - const json = ApplicationSerializer.prototype._hashForModel.apply(this, arguments); + const json = ApplicationSerializer.prototype._hashForModel.apply( + this, + arguments + ); json.host_catalog_id = model.hostCatalogId; if (model.hostIds?.length) { json.host_ids = model.hostIds; } return json; - } - + }, }); diff --git a/addons/api/mirage/serializers/host.js b/addons/api/mirage/serializers/host.js index ccd3994ca..829b4476b 100644 --- a/addons/api/mirage/serializers/host.js +++ b/addons/api/mirage/serializers/host.js @@ -1,5 +1,5 @@ import ApplicationSerializer from './application'; export default ApplicationSerializer.extend({ - modelName: 'host' + modelName: 'host', }); diff --git a/addons/api/mirage/serializers/role.js b/addons/api/mirage/serializers/role.js index 73dec3023..db04fe328 100644 --- a/addons/api/mirage/serializers/role.js +++ b/addons/api/mirage/serializers/role.js @@ -4,23 +4,26 @@ export default ApplicationSerializer.extend({ modelName: 'role', _hashForModel(model) { - const json = ApplicationSerializer.prototype._hashForModel.apply(this, arguments); - const serializedUsers = model.users.models.map(user => ({ + const json = ApplicationSerializer.prototype._hashForModel.apply( + this, + arguments + ); + const serializedUsers = model.users.models.map((user) => ({ scope_id: model.scope.id, id: user.id, - type: 'user' + type: 'user', })); - const serializedGroups = model.groups.models.map(group => ({ + const serializedGroups = model.groups.models.map((group) => ({ scope_id: model.scope.id, id: group.id, - type: 'group' + type: 'group', })); - json.principals = [ ...serializedUsers, ...serializedGroups ]; + json.principals = [...serializedUsers, ...serializedGroups]; if (!json.principals.length) delete json.principals; // default grant scope if (!json.grant_scope_id) json.grant_scope_id = json.scope.id; return json; - } + }, }); diff --git a/addons/api/mirage/serializers/scope.js b/addons/api/mirage/serializers/scope.js index bfb33f398..b6989ad9e 100644 --- a/addons/api/mirage/serializers/scope.js +++ b/addons/api/mirage/serializers/scope.js @@ -1,5 +1,5 @@ import ApplicationSerializer from './application'; export default ApplicationSerializer.extend({ - modelName: 'scope' + modelName: 'scope', }); diff --git a/addons/api/mirage/serializers/session.js b/addons/api/mirage/serializers/session.js index 3e14a23e6..347e713c2 100644 --- a/addons/api/mirage/serializers/session.js +++ b/addons/api/mirage/serializers/session.js @@ -11,12 +11,14 @@ export default ApplicationSerializer.extend({ }, _hashForModel(model) { - const json = ApplicationSerializer.prototype._hashForModel.apply(this, arguments); + const json = ApplicationSerializer.prototype._hashForModel.apply( + this, + arguments + ); json.user_id = model.userId; json.target_id = model.targetId; json.host_set_id = model.hostSetId; json.host_id = model.hostId; return json; - } - + }, }); diff --git a/addons/api/mirage/serializers/target.js b/addons/api/mirage/serializers/target.js index 2d2a0d974..006388773 100644 --- a/addons/api/mirage/serializers/target.js +++ b/addons/api/mirage/serializers/target.js @@ -11,16 +11,18 @@ export default ApplicationSerializer.extend({ }, _hashForModel(model) { - const json = ApplicationSerializer.prototype._hashForModel.apply(this, arguments); + const json = ApplicationSerializer.prototype._hashForModel.apply( + this, + arguments + ); const { hostSets } = this.schema; if (model.hostSetIds?.length) { - json.host_sets = model.hostSetIds.map(host_set_id => { + json.host_sets = model.hostSetIds.map((host_set_id) => { const hostSet = hostSets.find(host_set_id); const host_catalog_id = hostSet?.hostCatalog?.id; return { id: host_set_id, host_catalog_id }; }); } return json; - } - + }, }); diff --git a/addons/api/mirage/serializers/user.js b/addons/api/mirage/serializers/user.js index 0ef9298f5..fe4c8084f 100644 --- a/addons/api/mirage/serializers/user.js +++ b/addons/api/mirage/serializers/user.js @@ -11,8 +11,11 @@ export default ApplicationSerializer.extend({ }, _hashForModel(model) { - const json = ApplicationSerializer.prototype._hashForModel.apply(this, arguments); + const json = ApplicationSerializer.prototype._hashForModel.apply( + this, + arguments + ); if (model.accountIds.length) json.account_ids = model.accountIds; return json; - } + }, }); diff --git a/addons/api/package.json b/addons/api/package.json index ed6925b35..00f8962a4 100644 --- a/addons/api/package.json +++ b/addons/api/package.json @@ -10,56 +10,65 @@ "scripts": { "build:development": "ember build", "build": "ember build --environment=production", - "lint": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*", + "lint": "npm-run-all --aggregate-output --continue-on-error --parallel 'lint:!(fix)'", + "lint:fix": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*:fix", + "lint:hbs": "ember-template-lint .", + "lint:hbs:fix": "ember-template-lint . --fix", "lint:js": "eslint .", + "lint:js:fix": "eslint . --fix", "format": "npm run format:js", - "format:js": "prettier --write '{addon,app,config,stories,tests}/**/*.js' *.js", + "format:js": "prettier --write '{addon,app,config,stories,tests,mirage}/**/*.js' *.js", "start": "ember serve", "test": "ember test", "test:ember-compatibility": "ember try:each", "doc:toc": "doctoc README.md" }, "dependencies": { - "ember-cli-babel": "^7.21.0", - "ember-cli-htmlbars": "^5.2.0", + "ember-cli-babel": "^7.23.0", + "ember-cli-htmlbars": "^5.3.1", + "ember-cli-mirage": "^1.1.8", "ember-data": "^3.20.0", "ember-data-model-fragments": "5.0.0-beta.0", - "ember-fetch": "^8.0.1", - "ember-cli-mirage": "^1.1.8" + "ember-fetch": "^8.0.1" }, "devDependencies": { - "@ember/optional-features": "^1.3.0", - "@glimmer/component": "^1.0.1", - "@glimmer/tracking": "^1.0.0", + "@ember/optional-features": "^2.0.0", + "@ember/test-helpers": "^2.1.4", + "@glimmer/component": "^1.0.3", + "@glimmer/tracking": "^1.0.3", "babel-eslint": "^10.1.0", "broccoli-asset-rev": "^3.0.0", "doctoc": "^1.4.0", - "ember-auto-import": "^1.6.0", - "ember-cli": "~3.20.2", + "ember-auto-import": "^1.10.1", + "ember-cli": "~3.24.0", "ember-cli-dependency-checker": "^3.2.0", "ember-cli-inject-live-reload": "^2.0.2", "ember-cli-sri": "^2.1.1", - "ember-cli-uglify": "^3.0.0", + "ember-cli-terser": "^4.0.1", "ember-cli-update": "^0.54.6", "ember-copy": "^1.0.0", "ember-disable-prototype-extensions": "^1.1.3", "ember-export-application-global": "^2.0.1", "ember-get-config": "^0.3.0", - "ember-load-initializers": "^2.1.1", + "ember-load-initializers": "^2.1.2", "ember-maybe-import-regenerator": "^0.1.6", - "ember-qunit": "^4.6.0", - "ember-resolver": "^8.0.0", - "ember-source": "~3.20.2", - "ember-source-channel-url": "^2.0.1", - "ember-template-lint": "^2.9.1", + "ember-page-title": "^6.0.3", + "ember-qunit": "^5.1.1", + "ember-resolver": "^8.0.2", + "ember-source": "~3.24.0", + "ember-source-channel-url": "^3.0.0", + "ember-template-lint": "^2.15.0", "ember-try": "^1.4.0", - "eslint": "^7.5.0", - "eslint-plugin-ember": "^8.9.1", + "eslint": "^7.17.0", + "eslint-config-prettier": "^7.1.0", + "eslint-plugin-ember": "^10.1.1", "eslint-plugin-node": "^11.1.0", + "eslint-plugin-prettier": "^3.3.1", "loader.js": "^4.7.0", "npm-run-all": "^4.1.5", - "prettier": "^2.0.5", - "qunit-dom": "^1.2.0" + "prettier": "^2.2.1", + "qunit": "^2.13.0", + "qunit-dom": "^1.6.0" }, "engines": { "node": "10.* || >= 12" diff --git a/addons/api/tests/dummy/app/templates/application.hbs b/addons/api/tests/dummy/app/templates/application.hbs index f8bc38e7b..001b0153a 100644 --- a/addons/api/tests/dummy/app/templates/application.hbs +++ b/addons/api/tests/dummy/app/templates/application.hbs @@ -1,3 +1,5 @@ +{{page-title "Dummy"}} +

Welcome to Ember

{{outlet}} diff --git a/addons/api/tests/dummy/config/ember-cli-update.json b/addons/api/tests/dummy/config/ember-cli-update.json index 3c0c55fdb..ed4d5fc2d 100644 --- a/addons/api/tests/dummy/config/ember-cli-update.json +++ b/addons/api/tests/dummy/config/ember-cli-update.json @@ -3,7 +3,7 @@ "packages": [ { "name": "ember-cli", - "version": "3.20.2", + "version": "3.24.0", "blueprints": [ { "name": "addon", diff --git a/addons/api/tests/index.html b/addons/api/tests/index.html index 5209b8523..3eb848dbd 100644 --- a/addons/api/tests/index.html +++ b/addons/api/tests/index.html @@ -21,6 +21,13 @@ {{content-for "body"}} {{content-for "test-body"}} +
+
+
+
+
+
+ diff --git a/addons/api/tests/test-helper.js b/addons/api/tests/test-helper.js index 4eae06f81..4efd6e58a 100644 --- a/addons/api/tests/test-helper.js +++ b/addons/api/tests/test-helper.js @@ -1,8 +1,12 @@ import Application from 'dummy/app'; import config from 'dummy/config/environment'; +import * as QUnit from 'qunit'; import { setApplication } from '@ember/test-helpers'; +import { setup } from 'qunit-dom'; import { start } from 'ember-qunit'; setApplication(Application.create(config.APP)); +setup(QUnit.assert); + start(); diff --git a/addons/api/tests/unit/mixins/adapter-build-url-test.js b/addons/api/tests/unit/mixins/adapter-build-url-test.js index 49d49029a..796b6bed6 100644 --- a/addons/api/tests/unit/mixins/adapter-build-url-test.js +++ b/addons/api/tests/unit/mixins/adapter-build-url-test.js @@ -9,7 +9,7 @@ module('Unit | Mixin | build-url', function (hooks) { test('it does not interfere with basic URLs', function (assert) { assert.expect(1); - /* eslint-disable-next-line ember/no-new-mixins */ + /* eslint-disable-next-line ember/no-new-mixins, ember/no-classic-classes */ const Adapter = RESTAdapter.extend(AdapterBuildURLMixin); this.owner.register('adapter:adapter', Adapter); const adapter = this.owner.lookup('adapter:adapter'); @@ -19,7 +19,7 @@ module('Unit | Mixin | build-url', function (hooks) { test('it does not interfere with namespaced URLs', function (assert) { assert.expect(1); - /* eslint-disable-next-line ember/no-new-mixins */ + /* eslint-disable-next-line ember/no-new-mixins, ember/no-classic-classes */ const Adapter = RESTAdapter.extend(AdapterBuildURLMixin, { namespace: 'api/v1', }); @@ -31,7 +31,7 @@ module('Unit | Mixin | build-url', function (hooks) { test('it can prepend a prefix', function (assert) { assert.expect(1); - /* eslint-disable-next-line ember/no-new-mixins */ + /* eslint-disable-next-line ember/no-new-mixins, ember/no-classic-classes */ const Adapter = RESTAdapter.extend(AdapterBuildURLMixin, { urlPrefix() { return '/foo/bars'; @@ -45,7 +45,7 @@ module('Unit | Mixin | build-url', function (hooks) { test('it can append a suffix', function (assert) { assert.expect(1); - /* eslint-disable-next-line ember/no-new-mixins */ + /* eslint-disable-next-line ember/no-new-mixins, ember/no-classic-classes */ const Adapter = RESTAdapter.extend(AdapterBuildURLMixin, { urlSuffix() { return ':method'; diff --git a/addons/api/tests/unit/models/account-test.js b/addons/api/tests/unit/models/account-test.js index f937b3c26..33021e295 100644 --- a/addons/api/tests/unit/models/account-test.js +++ b/addons/api/tests/unit/models/account-test.js @@ -21,5 +21,4 @@ module('Unit | Model | account', function (hooks) { model.attributes.login_name = 'username'; assert.equal(model.username, 'username'); }); - }); diff --git a/addons/api/tests/unit/models/auth-token-test.js b/addons/api/tests/unit/models/auth-token-test.js index 1f0826b86..bf9809ee0 100644 --- a/addons/api/tests/unit/models/auth-token-test.js +++ b/addons/api/tests/unit/models/auth-token-test.js @@ -1,11 +1,11 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Model | auth token', function(hooks) { +module('Unit | Model | auth token', function (hooks) { setupTest(hooks); // Replace this with your real tests. - test('it exists', function(assert) { + test('it exists', function (assert) { let store = this.owner.lookup('service:store'); let model = store.createRecord('auth-token', {}); assert.ok(model); diff --git a/addons/api/tests/unit/models/host-set-test.js b/addons/api/tests/unit/models/host-set-test.js index c7228a81f..d3738fe5b 100644 --- a/addons/api/tests/unit/models/host-set-test.js +++ b/addons/api/tests/unit/models/host-set-test.js @@ -24,10 +24,7 @@ module('Unit | Model | host set', function (hooks) { attributes: { name: 'Host Set', description: 'Description', - host_ids: [ - {value: '1'}, - {value: '3'}, - ], + host_ids: [{ value: '1' }, { value: '3' }], version: 1, scope: { scope_id: 'o_1', @@ -58,10 +55,7 @@ module('Unit | Model | host set', function (hooks) { attributes: { name: 'Host Set', description: 'Description', - host_ids: [ - {value: '1'}, - {value: '3'}, - ], + host_ids: [{ value: '1' }, { value: '3' }], version: 1, scope: { scope_id: 'o_1', @@ -92,10 +86,7 @@ module('Unit | Model | host set', function (hooks) { attributes: { name: 'Host Set', description: 'Description', - host_ids: [ - {value: '1'}, - {value: '3'}, - ], + host_ids: [{ value: '1' }, { value: '3' }], version: 1, scope: { scope_id: 'o_1', @@ -126,10 +117,7 @@ module('Unit | Model | host set', function (hooks) { attributes: { name: 'Host Set', description: 'Description', - host_ids: [ - {value: '1'}, - {value: '3'}, - ], + host_ids: [{ value: '1' }, { value: '3' }], version: 1, scope: { scope_id: 'o_1', diff --git a/addons/api/tests/unit/models/session-test.js b/addons/api/tests/unit/models/session-test.js index 54c8b44cc..43cf7caf4 100644 --- a/addons/api/tests/unit/models/session-test.js +++ b/addons/api/tests/unit/models/session-test.js @@ -1,28 +1,28 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Model | session', function(hooks) { +module('Unit | Model | session', function (hooks) { setupTest(hooks); - test('it exists', function(assert) { + test('it exists', function (assert) { let store = this.owner.lookup('service:store'); let model = store.createRecord('session', {}); assert.ok(model); assert.notOk(model.isCancelable); }); - test('it allows cancellation of an active session', function(assert) { + test('it allows cancellation of an active session', function (assert) { let store = this.owner.lookup('service:store'); let model = store.createRecord('session', { - status: 'active' + status: 'active', }); assert.ok(model.isCancelable); }); - test('it allows cancellation of a pending session', function(assert) { + test('it allows cancellation of a pending session', function (assert) { let store = this.owner.lookup('service:store'); let model = store.createRecord('session', { - status: 'pending' + status: 'pending', }); assert.ok(model.isCancelable); }); @@ -31,7 +31,7 @@ module('Unit | Model | session', function(hooks) { assert.expect(2); let store = this.owner.lookup('service:store'); let model = store.createRecord('session', { - status: 'pending' + status: 'pending', }); assert.notOk(model.isActive); model.status = 'active'; @@ -42,7 +42,7 @@ module('Unit | Model | session', function(hooks) { assert.expect(2); let store = this.owner.lookup('service:store'); let model = store.createRecord('session', { - status: 'active' + status: 'active', }); assert.notOk(model.isPending); model.status = 'pending'; @@ -55,7 +55,7 @@ module('Unit | Model | session', function(hooks) { assert.equal(model.proxy, null); model.setProperties({ proxy_address: 'localhost', - proxy_port: '12345' + proxy_port: '12345', }); assert.equal(model.proxy, 'localhost:12345'); }); diff --git a/addons/api/tests/unit/models/target-test.js b/addons/api/tests/unit/models/target-test.js index bacab9b42..18be834bd 100644 --- a/addons/api/tests/unit/models/target-test.js +++ b/addons/api/tests/unit/models/target-test.js @@ -186,33 +186,37 @@ module('Unit | Model | target', function (hooks) { store.push({ data: { id: '123abc', - type: 'target' - } + type: 'target', + }, }); const target = store.peekRecord('target', '123abc'); - assert.equal( target.sessions.length, 0); + assert.equal(target.sessions.length, 0); store.push({ data: { id: '1', type: 'session', - attributes: { target_id: '123abc' } - } + attributes: { target_id: '123abc' }, + }, }); store.push({ data: { id: '2', type: 'session', - attributes: { target_id: '123abc' } - } + attributes: { target_id: '123abc' }, + }, }); store.push({ data: { id: '3', type: 'session', - attributes: { target_id: '456xyz' } - } + attributes: { target_id: '456xyz' }, + }, }); - assert.equal(store.peekAll('session').length, 3, 'There are 3 sessions loaded in the store'); + assert.equal( + store.peekAll('session').length, + 3, + 'There are 3 sessions loaded in the store' + ); assert.equal( target.sessions.length, 2, diff --git a/addons/api/tests/unit/serializers/application-test.js b/addons/api/tests/unit/serializers/application-test.js index 014d80377..a7040e876 100644 --- a/addons/api/tests/unit/serializers/application-test.js +++ b/addons/api/tests/unit/serializers/application-test.js @@ -66,7 +66,7 @@ module('Unit | Serializer | application', function (hooks) { const serializedRecord = serializer.serialize(snapshot); assert.deepEqual(serializedRecord, { name: 'User', - description: 'Description' + description: 'Description', }); }); @@ -172,7 +172,7 @@ module('Unit | Serializer | application', function (hooks) { attributes: { name: 'User 1', account_ids: [], - scope: { scope_id: 'o_123' } + scope: { scope_id: 'o_123' }, }, relationships: {}, }, diff --git a/addons/api/tests/unit/serializers/host-test.js b/addons/api/tests/unit/serializers/host-test.js index c31a5ce4e..86c17fdd0 100644 --- a/addons/api/tests/unit/serializers/host-test.js +++ b/addons/api/tests/unit/serializers/host-test.js @@ -1,18 +1,18 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Serializer | host', function(hooks) { +module('Unit | Serializer | host', function (hooks) { setupTest(hooks); // Replace this with your real tests. - test('it exists', function(assert) { + test('it exists', function (assert) { let store = this.owner.lookup('service:store'); let serializer = store.serializerFor('host'); assert.ok(serializer); }); - test('it serializes records', function(assert) { + test('it serializes records', function (assert) { let store = this.owner.lookup('service:store'); let record = store.createRecord('host', {}); diff --git a/addons/api/tests/unit/serializers/role-test.js b/addons/api/tests/unit/serializers/role-test.js index f0d14b17a..16336d035 100644 --- a/addons/api/tests/unit/serializers/role-test.js +++ b/addons/api/tests/unit/serializers/role-test.js @@ -21,7 +21,7 @@ module('Unit | Serializer | role', function (hooks) { name: 'User', description: 'Description', version: 1, - grant_scope_id: null + grant_scope_id: null, }); }); diff --git a/addons/api/tests/unit/serializers/session-test.js b/addons/api/tests/unit/serializers/session-test.js index fde7c215f..a5ae53586 100644 --- a/addons/api/tests/unit/serializers/session-test.js +++ b/addons/api/tests/unit/serializers/session-test.js @@ -1,11 +1,11 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Serializer | session', function(hooks) { +module('Unit | Serializer | session', function (hooks) { setupTest(hooks); // Replace this with your real tests. - test('it exists', function(assert) { + test('it exists', function (assert) { let store = this.owner.lookup('service:store'); let serializer = store.serializerFor('session'); diff --git a/addons/api/tests/unit/serializers/target-test.js b/addons/api/tests/unit/serializers/target-test.js index d8e4a58fb..255faa9ac 100644 --- a/addons/api/tests/unit/serializers/target-test.js +++ b/addons/api/tests/unit/serializers/target-test.js @@ -20,7 +20,7 @@ module('Unit | Serializer | target', function (hooks) { type: 'org', }, version: 1, - type: 'tcp' + type: 'tcp', }); const snapshot = record._createSnapshot(); snapshot.adapterOptions = {}; diff --git a/addons/api/tests/unit/serializers/user-test.js b/addons/api/tests/unit/serializers/user-test.js index c0d2bd061..4ca1800d6 100644 --- a/addons/api/tests/unit/serializers/user-test.js +++ b/addons/api/tests/unit/serializers/user-test.js @@ -55,11 +55,7 @@ module('Unit | Serializer | user', function (hooks) { name: 'user 1', scope: { id: 'o_123' }, }; - const normalized = serializer.normalizeSingleResponse( - store, - user, - payload - ); + const normalized = serializer.normalizeSingleResponse(store, user, payload); assert.deepEqual(normalized, { included: [], data: { diff --git a/addons/auth/.eslintignore b/addons/auth/.eslintignore index 72df37307..922165552 100644 --- a/addons/auth/.eslintignore +++ b/addons/auth/.eslintignore @@ -13,6 +13,7 @@ # misc /coverage/ !.* +.eslintcache # ember-try /.node_modules.ember-try/ diff --git a/addons/auth/.eslintrc.js b/addons/auth/.eslintrc.js index 928585995..49fb14100 100644 --- a/addons/auth/.eslintrc.js +++ b/addons/auth/.eslintrc.js @@ -7,48 +7,54 @@ module.exports = { ecmaVersion: 2018, sourceType: 'module', ecmaFeatures: { - legacyDecorators: true - } + legacyDecorators: true, + }, }, - plugins: [ - 'ember' - ], + plugins: ['ember'], extends: [ 'eslint:recommended', - 'plugin:ember/recommended' + 'plugin:ember/recommended', + 'plugin:prettier/recommended', ], env: { - browser: true + browser: true, + }, + rules: { + 'ember/no-get': 'off', + 'ember/no-get-with-default': 'off', + 'ember/no-computed-properties-in-native-classes': 'off', + 'ember/no-assignment-of-untracked-properties-used-in-tracking-contexts': + 'off', }, - rules: {}, overrides: [ // node files { files: [ '.eslintrc.js', + '.prettierrc.js', '.template-lintrc.js', 'ember-cli-build.js', 'index.js', 'testem.js', 'blueprints/*/index.js', 'config/**/*.js', - 'tests/dummy/config/**/*.js' + 'tests/dummy/config/**/*.js', ], excludedFiles: [ 'addon/**', 'addon-test-support/**', 'app/**', - 'tests/dummy/app/**' + 'tests/dummy/app/**', ], parserOptions: { - sourceType: 'script' + sourceType: 'script', }, env: { browser: false, - node: true + node: true, }, plugins: ['node'], - extends: ['plugin:node/recommended'] - } - ] + extends: ['plugin:node/recommended'], + }, + ], }; diff --git a/addons/auth/.npmignore b/addons/auth/.npmignore index bd09adff9..88818f2c8 100644 --- a/addons/auth/.npmignore +++ b/addons/auth/.npmignore @@ -10,6 +10,7 @@ /.editorconfig /.ember-cli /.env* +/.eslintcache /.eslintignore /.eslintrc.js /.git/ diff --git a/addons/auth/.prettierignore b/addons/auth/.prettierignore new file mode 100644 index 000000000..922165552 --- /dev/null +++ b/addons/auth/.prettierignore @@ -0,0 +1,21 @@ +# unconventional js +/blueprints/*/files/ +/vendor/ + +# compiled output +/dist/ +/tmp/ + +# dependencies +/bower_components/ +/node_modules/ + +# misc +/coverage/ +!.* +.eslintcache + +# ember-try +/.node_modules.ember-try/ +/bower.json.ember-try +/package.json.ember-try diff --git a/addons/auth/.prettierrc.js b/addons/auth/.prettierrc.js new file mode 100644 index 000000000..534e6d35a --- /dev/null +++ b/addons/auth/.prettierrc.js @@ -0,0 +1,5 @@ +'use strict'; + +module.exports = { + singleQuote: true, +}; diff --git a/addons/auth/.template-lintrc.js b/addons/auth/.template-lintrc.js index f38737001..3b0b9af95 100644 --- a/addons/auth/.template-lintrc.js +++ b/addons/auth/.template-lintrc.js @@ -1,5 +1,5 @@ 'use strict'; module.exports = { - extends: 'octane' + extends: 'octane', }; diff --git a/addons/auth/addon/authenticators/base.js b/addons/auth/addon/authenticators/base.js index d0b394d32..641142222 100644 --- a/addons/auth/addon/authenticators/base.js +++ b/addons/auth/addon/authenticators/base.js @@ -15,7 +15,7 @@ export default class BaseAuthenticator extends SimpleAuthBaseAuthenticator { * @param {string} scopeID * @return {string} */ - buildDeauthEndpointURL(/* { scope: { id: scopeID } } */) { } + buildDeauthEndpointURL(/* { scope: { id: scopeID } } */) {} /** * Generates an auth token validation URL used to check tokens on restoration. @@ -23,7 +23,7 @@ export default class BaseAuthenticator extends SimpleAuthBaseAuthenticator { * @param {string} tokenID * @return {string} */ - buildTokenValidationEndpointURL(/* tokenID */) { } + buildTokenValidationEndpointURL(/* tokenID */) {} // =methods @@ -34,7 +34,7 @@ export default class BaseAuthenticator extends SimpleAuthBaseAuthenticator { const tokenValidationURL = this.buildTokenValidationEndpointURL(tokenID); const response = await fetch(tokenValidationURL, { method: 'get', - headers: { 'Authorization': `Bearer ${token}` } + headers: { Authorization: `Bearer ${token}` }, }); // 401 and 404 responses mean the token is invalid, whereas other types of // error responses do not tell us about the validity of the token. @@ -51,8 +51,9 @@ export default class BaseAuthenticator extends SimpleAuthBaseAuthenticator { */ async restore(data) { if (!data) return reject(); - return this.validateToken(data.token, data.id) - .then(() => this.normalizeData(data)); + return this.validateToken(data.token, data.id).then(() => + this.normalizeData(data) + ); } /** @@ -65,8 +66,8 @@ export default class BaseAuthenticator extends SimpleAuthBaseAuthenticator { */ normalizeData(data, username) { // Add booleans indicated the scope type - data.isGlobal = (data?.scope?.type === 'global'); - data.isOrg = (data?.scope?.type === 'org'); + data.isGlobal = data?.scope?.type === 'global'; + data.isOrg = data?.scope?.type === 'org'; if (username) data.username = username; return data; } diff --git a/addons/auth/addon/authenticators/password.js b/addons/auth/addon/authenticators/password.js index 6f70946e8..e130a23ee 100644 --- a/addons/auth/addon/authenticators/password.js +++ b/addons/auth/addon/authenticators/password.js @@ -34,7 +34,6 @@ import fetch from 'fetch'; * */ export default class PasswordAuthenticator extends BaseAuthenticator { - // =unimplemented methods /** @@ -48,7 +47,7 @@ export default class PasswordAuthenticator extends BaseAuthenticator { buildAuthEndpointURL(/* { scope: { id: scopeID }, authMethod: { id: authMethodID }, - } */) { } + } */) {} // =methods diff --git a/addons/auth/addon/session-stores/cookie.js b/addons/auth/addon/session-stores/cookie.js index ea0501ad5..a9e0b5120 100644 --- a/addons/auth/addon/session-stores/cookie.js +++ b/addons/auth/addon/session-stores/cookie.js @@ -75,6 +75,9 @@ export default class CookieSessionStore extends BaseSessionStore { * present. If either one is missing, we want to cleanup to be sure they * are both absent. */ + // The base class is a classic Ember class, but the linter doesn't know that. + // That's why this rule is disabled here. + /* eslint-disable-next-line ember/classic-decorator-hooks */ init() { if (!this.sessionExists) this.clear(); } diff --git a/addons/auth/config/ember-try.js b/addons/auth/config/ember-try.js index 9190baee5..f14ac7f50 100644 --- a/addons/auth/config/ember-try.js +++ b/addons/auth/config/ember-try.js @@ -6,14 +6,6 @@ module.exports = async function () { return { useYarn: true, scenarios: [ - { - name: 'ember-lts-3.12', - npm: { - devDependencies: { - 'ember-source': '~3.12.0', - }, - }, - }, { name: 'ember-lts-3.16', npm: { @@ -26,9 +18,9 @@ module.exports = async function () { name: 'ember-lts-3.20', npm: { devDependencies: { - 'ember-source': '~3.20.5' - } - } + 'ember-source': '~3.20.5', + }, + }, }, { name: 'ember-release', @@ -63,9 +55,9 @@ module.exports = async function () { }, npm: { devDependencies: { - '@ember/jquery': '^1.1.0' - } - } + '@ember/jquery': '^1.1.0', + }, + }, }, { name: 'ember-classic', diff --git a/addons/auth/package.json b/addons/auth/package.json index 702815140..a1bdbc248 100644 --- a/addons/auth/package.json +++ b/addons/auth/package.json @@ -8,53 +8,61 @@ "ember-addon" ], "scripts": { - "lint": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*", + "lint": "npm-run-all --aggregate-output --continue-on-error --parallel 'lint:!(fix)'", + "lint:fix": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*:fix", + "lint:hbs:fix": "ember-template-lint . --fix", "lint:js": "eslint .", "format": "npm run format:js", "format:js": "prettier --write '{addon,app,config,stories,tests}/**/*.js' *.js", + "lint:js:fix": "eslint . --fix", "start": "ember serve", "test": "ember test", "test:ember-compatibility": "ember try:each", "doc:toc": "doctoc README.md" }, "dependencies": { - "ember-cli-babel": "^7.21.0", - "ember-cli-htmlbars": "^5.2.0", + "ember-cli-babel": "^7.23.0", + "ember-cli-htmlbars": "^5.3.1", "ember-simple-auth": "^3.0.1" }, "devDependencies": { - "core": "*", - "@ember/optional-features": "^1.3.0", - "@glimmer/component": "^1.0.1", - "@glimmer/tracking": "^1.0.0", + "@ember/optional-features": "^2.0.0", + "@ember/test-helpers": "^2.1.4", + "@glimmer/component": "^1.0.3", + "@glimmer/tracking": "^1.0.3", "babel-eslint": "^10.1.0", "broccoli-asset-rev": "^3.0.0", + "core": "*", "doctoc": "^1.4.0", - "ember-auto-import": "^1.6.0", - "ember-cli": "~3.20.2", + "ember-auto-import": "^1.10.1", + "ember-cli": "~3.24.0", "ember-cli-dependency-checker": "^3.2.0", "ember-cli-inject-live-reload": "^2.0.2", "ember-cli-sri": "^2.1.1", - "ember-cli-uglify": "^3.0.0", + "ember-cli-terser": "^4.0.1", "ember-cli-update": "^0.54.6", "ember-cookies": "^0.5.2", "ember-disable-prototype-extensions": "^1.1.3", "ember-export-application-global": "^2.0.1", - "ember-load-initializers": "^2.1.1", + "ember-load-initializers": "^2.1.2", "ember-maybe-import-regenerator": "^0.1.6", - "ember-qunit": "^4.6.0", - "ember-resolver": "^8.0.0", - "ember-source": "~3.20.2", - "ember-source-channel-url": "^2.0.1", - "ember-template-lint": "^2.9.1", + "ember-page-title": "^6.0.3", + "ember-qunit": "^5.1.1", + "ember-resolver": "^8.0.2", + "ember-source": "~3.24.0", + "ember-source-channel-url": "^3.0.0", + "ember-template-lint": "^2.15.0", "ember-try": "^1.4.0", - "eslint": "^7.5.0", - "eslint-plugin-ember": "^8.9.1", + "eslint": "^7.17.0", + "eslint-config-prettier": "^7.1.0", + "eslint-plugin-ember": "^10.1.1", "eslint-plugin-node": "^11.1.0", + "eslint-plugin-prettier": "^3.3.1", "loader.js": "^4.7.0", "npm-run-all": "^4.1.5", - "prettier": "^2.0.5", - "qunit-dom": "^1.2.0" + "prettier": "^2.2.1", + "qunit": "^2.13.0", + "qunit-dom": "^1.6.0" }, "engines": { "node": "10.* || >= 12" diff --git a/addons/auth/tests/dummy/app/templates/application.hbs b/addons/auth/tests/dummy/app/templates/application.hbs index 5230580f8..1001d149e 100644 --- a/addons/auth/tests/dummy/app/templates/application.hbs +++ b/addons/auth/tests/dummy/app/templates/application.hbs @@ -1,3 +1,5 @@ +{{page-title "Dummy"}} +

Welcome to Ember

{{outlet}} \ No newline at end of file diff --git a/addons/auth/tests/dummy/config/ember-cli-update.json b/addons/auth/tests/dummy/config/ember-cli-update.json index 3c0c55fdb..ed4d5fc2d 100644 --- a/addons/auth/tests/dummy/config/ember-cli-update.json +++ b/addons/auth/tests/dummy/config/ember-cli-update.json @@ -3,7 +3,7 @@ "packages": [ { "name": "ember-cli", - "version": "3.20.2", + "version": "3.24.0", "blueprints": [ { "name": "addon", diff --git a/addons/auth/tests/index.html b/addons/auth/tests/index.html index 5209b8523..3eb848dbd 100644 --- a/addons/auth/tests/index.html +++ b/addons/auth/tests/index.html @@ -21,6 +21,13 @@ {{content-for "body"}} {{content-for "test-body"}} +
+
+
+
+
+
+ diff --git a/addons/auth/tests/test-helper.js b/addons/auth/tests/test-helper.js index 4eae06f81..4efd6e58a 100644 --- a/addons/auth/tests/test-helper.js +++ b/addons/auth/tests/test-helper.js @@ -1,8 +1,12 @@ import Application from 'dummy/app'; import config from 'dummy/config/environment'; +import * as QUnit from 'qunit'; import { setApplication } from '@ember/test-helpers'; +import { setup } from 'qunit-dom'; import { start } from 'ember-qunit'; setApplication(Application.create(config.APP)); +setup(QUnit.assert); + start(); diff --git a/addons/auth/tests/unit/authenticators/base-test.js b/addons/auth/tests/unit/authenticators/base-test.js index 7cb7a3e4b..726e76162 100644 --- a/addons/auth/tests/unit/authenticators/base-test.js +++ b/addons/auth/tests/unit/authenticators/base-test.js @@ -34,10 +34,13 @@ module('Unit | Authenticator | base', function (hooks) { assert.expect(1); const mockData = { id: 'token_123' }; const authenticator = this.owner.lookup('authenticator:base'); - this.server.get(authenticator.buildTokenValidationEndpointURL(mockData.id), () => { - assert.ok(true, 'token validation was requested'); - return new Response(200); - }); + this.server.get( + authenticator.buildTokenValidationEndpointURL(mockData.id), + () => { + assert.ok(true, 'token validation was requested'); + return new Response(200); + } + ); await authenticator.restore(mockData); }); @@ -45,10 +48,13 @@ module('Unit | Authenticator | base', function (hooks) { assert.expect(2); const mockData = { id: 'token_123' }; const authenticator = this.owner.lookup('authenticator:base'); - this.server.get(authenticator.buildTokenValidationEndpointURL(mockData.id), () => { - assert.ok(true, 'token validation was requested'); - return new Response(401); - }); + this.server.get( + authenticator.buildTokenValidationEndpointURL(mockData.id), + () => { + assert.ok(true, 'token validation was requested'); + return new Response(401); + } + ); try { await authenticator.restore(mockData); } catch (e) { @@ -60,10 +66,13 @@ module('Unit | Authenticator | base', function (hooks) { assert.expect(2); const mockData = { id: 'token_123' }; const authenticator = this.owner.lookup('authenticator:base'); - this.server.get(authenticator.buildTokenValidationEndpointURL(mockData.id), () => { - assert.ok(true, 'token validation was requested'); - return new Response(404); - }); + this.server.get( + authenticator.buildTokenValidationEndpointURL(mockData.id), + () => { + assert.ok(true, 'token validation was requested'); + return new Response(404); + } + ); try { await authenticator.restore(mockData); } catch (e) { diff --git a/addons/core/.eslintignore b/addons/core/.eslintignore index 72df37307..922165552 100644 --- a/addons/core/.eslintignore +++ b/addons/core/.eslintignore @@ -13,6 +13,7 @@ # misc /coverage/ !.* +.eslintcache # ember-try /.node_modules.ember-try/ diff --git a/addons/core/.eslintrc.js b/addons/core/.eslintrc.js index 928585995..49fb14100 100644 --- a/addons/core/.eslintrc.js +++ b/addons/core/.eslintrc.js @@ -7,48 +7,54 @@ module.exports = { ecmaVersion: 2018, sourceType: 'module', ecmaFeatures: { - legacyDecorators: true - } + legacyDecorators: true, + }, }, - plugins: [ - 'ember' - ], + plugins: ['ember'], extends: [ 'eslint:recommended', - 'plugin:ember/recommended' + 'plugin:ember/recommended', + 'plugin:prettier/recommended', ], env: { - browser: true + browser: true, + }, + rules: { + 'ember/no-get': 'off', + 'ember/no-get-with-default': 'off', + 'ember/no-computed-properties-in-native-classes': 'off', + 'ember/no-assignment-of-untracked-properties-used-in-tracking-contexts': + 'off', }, - rules: {}, overrides: [ // node files { files: [ '.eslintrc.js', + '.prettierrc.js', '.template-lintrc.js', 'ember-cli-build.js', 'index.js', 'testem.js', 'blueprints/*/index.js', 'config/**/*.js', - 'tests/dummy/config/**/*.js' + 'tests/dummy/config/**/*.js', ], excludedFiles: [ 'addon/**', 'addon-test-support/**', 'app/**', - 'tests/dummy/app/**' + 'tests/dummy/app/**', ], parserOptions: { - sourceType: 'script' + sourceType: 'script', }, env: { browser: false, - node: true + node: true, }, plugins: ['node'], - extends: ['plugin:node/recommended'] - } - ] + extends: ['plugin:node/recommended'], + }, + ], }; diff --git a/addons/core/.npmignore b/addons/core/.npmignore index bd09adff9..88818f2c8 100644 --- a/addons/core/.npmignore +++ b/addons/core/.npmignore @@ -10,6 +10,7 @@ /.editorconfig /.ember-cli /.env* +/.eslintcache /.eslintignore /.eslintrc.js /.git/ diff --git a/addons/core/.prettierignore b/addons/core/.prettierignore new file mode 100644 index 000000000..922165552 --- /dev/null +++ b/addons/core/.prettierignore @@ -0,0 +1,21 @@ +# unconventional js +/blueprints/*/files/ +/vendor/ + +# compiled output +/dist/ +/tmp/ + +# dependencies +/bower_components/ +/node_modules/ + +# misc +/coverage/ +!.* +.eslintcache + +# ember-try +/.node_modules.ember-try/ +/bower.json.ember-try +/package.json.ember-try diff --git a/addons/core/.prettierrc.js b/addons/core/.prettierrc.js new file mode 100644 index 000000000..534e6d35a --- /dev/null +++ b/addons/core/.prettierrc.js @@ -0,0 +1,5 @@ +'use strict'; + +module.exports = { + singleQuote: true, +}; diff --git a/addons/core/.template-lintrc.js b/addons/core/.template-lintrc.js index f38737001..3b0b9af95 100644 --- a/addons/core/.template-lintrc.js +++ b/addons/core/.template-lintrc.js @@ -1,5 +1,5 @@ 'use strict'; module.exports = { - extends: 'octane' + extends: 'octane', }; diff --git a/addons/core/README.md b/addons/core/README.md index 3b913d4d3..ad29fbe9e 100644 --- a/addons/core/README.md +++ b/addons/core/README.md @@ -112,7 +112,7 @@ async myAction() { This addon exposes a service to hold all active scopes (org and project where available). -To make use of the service, import it and initialize it using service injection. +To make use of the service, import it and initialize it using service injection. ```js import { inject as service } from '@ember/service'; diff --git a/addons/core/addon/decorators/notify.js b/addons/core/addon/decorators/notify.js index 1ce13d91e..21c5b7f47 100644 --- a/addons/core/addon/decorators/notify.js +++ b/addons/core/addon/decorators/notify.js @@ -51,14 +51,14 @@ export function notifyError(notification, options = { catch: false }) { const owner = getOwner(this); const notifyService = owner.lookup('service:notify'); const intlService = owner.lookup('service:intl'); - + try { return await method.apply(this, arguments); } catch (error) { - - const candidateKey = (typeof notification === 'function') - ? notification.apply(this, [error]) - : notification; + const candidateKey = + typeof notification === 'function' + ? notification.apply(this, [error]) + : notification; const text = intlService.exists(candidateKey) ? intlService.t(candidateKey) diff --git a/addons/core/app/components/error/message.js b/addons/core/app/components/error/message.js index 055e64811..4cea9812f 100644 --- a/addons/core/app/components/error/message.js +++ b/addons/core/app/components/error/message.js @@ -1 +1 @@ -export { default } from 'core/components/error/message'; \ No newline at end of file +export { default } from 'core/components/error/message'; diff --git a/addons/core/app/components/form/authenticate.js b/addons/core/app/components/form/authenticate.js index f471115c1..85004b271 100644 --- a/addons/core/app/components/form/authenticate.js +++ b/addons/core/app/components/form/authenticate.js @@ -1 +1 @@ -export { default } from 'core/components/form/authenticate'; \ No newline at end of file +export { default } from 'core/components/form/authenticate'; diff --git a/addons/core/app/components/form/authenticate/password.js b/addons/core/app/components/form/authenticate/password.js index ec54f0464..f8be6bacb 100644 --- a/addons/core/app/components/form/authenticate/password.js +++ b/addons/core/app/components/form/authenticate/password.js @@ -1 +1 @@ -export { default } from 'core/components/form/authenticate/password'; \ No newline at end of file +export { default } from 'core/components/form/authenticate/password'; diff --git a/addons/core/app/components/pending-confirmations.js b/addons/core/app/components/pending-confirmations.js index 7e60dd82a..6652a5c5e 100644 --- a/addons/core/app/components/pending-confirmations.js +++ b/addons/core/app/components/pending-confirmations.js @@ -1 +1 @@ -export { default } from 'core/components/pending-confirmations'; \ No newline at end of file +export { default } from 'core/components/pending-confirmations'; diff --git a/addons/core/app/helpers/format-date-iso-human.js b/addons/core/app/helpers/format-date-iso-human.js index b4586dc3d..947f5e926 100644 --- a/addons/core/app/helpers/format-date-iso-human.js +++ b/addons/core/app/helpers/format-date-iso-human.js @@ -1 +1,4 @@ -export { default, formatDateIsoHuman } from 'core/helpers/format-date-iso-human'; +export { + default, + formatDateIsoHuman, +} from 'core/helpers/format-date-iso-human'; diff --git a/addons/core/config/ember-try.js b/addons/core/config/ember-try.js index bbdb66252..f14ac7f50 100644 --- a/addons/core/config/ember-try.js +++ b/addons/core/config/ember-try.js @@ -1,84 +1,76 @@ -"use strict"; +'use strict'; -const getChannelURL = require("ember-source-channel-url"); +const getChannelURL = require('ember-source-channel-url'); module.exports = async function () { return { useYarn: true, scenarios: [ { - name: "ember-lts-3.12", + name: 'ember-lts-3.16', npm: { devDependencies: { - "ember-source": "~3.12.0", + 'ember-source': '~3.16.0', }, }, }, { - name: "ember-lts-3.16", + name: 'ember-lts-3.20', npm: { devDependencies: { - "ember-source": "~3.16.0", + 'ember-source': '~3.20.5', }, }, }, { - name: "ember-lts-3.20", + name: 'ember-release', npm: { devDependencies: { - "ember-source": "~3.20.5", + 'ember-source': await getChannelURL('release'), }, }, }, { - name: "ember-release", + name: 'ember-beta', npm: { devDependencies: { - "ember-source": await getChannelURL("release"), + 'ember-source': await getChannelURL('beta'), }, }, }, { - name: "ember-beta", + name: 'ember-canary', npm: { devDependencies: { - "ember-source": await getChannelURL("beta"), + 'ember-source': await getChannelURL('canary'), }, }, }, { - name: "ember-canary", - npm: { - devDependencies: { - "ember-source": await getChannelURL("canary"), - }, - }, - }, - { - name: "ember-default-with-jquery", + name: 'ember-default-with-jquery', env: { EMBER_OPTIONAL_FEATURES: JSON.stringify({ - "jquery-integration": true, + 'jquery-integration': true, }), }, npm: { devDependencies: { - "@ember/jquery": "^1.1.0", + '@ember/jquery': '^1.1.0', }, }, }, { - name: "ember-classic", + name: 'ember-classic', env: { EMBER_OPTIONAL_FEATURES: JSON.stringify({ - "application-template-wrapper": true, - "default-async-observers": false, - "template-only-glimmer-components": false, + 'application-template-wrapper': true, + 'default-async-observers': false, + 'template-only-glimmer-components': false, }), }, npm: { ember: { - edition: "classic", + edition: 'classic', }, }, }, diff --git a/addons/core/config/environment.js b/addons/core/config/environment.js index b7238585e..331ab30df 100644 --- a/addons/core/config/environment.js +++ b/addons/core/config/environment.js @@ -1,4 +1,4 @@ -"use strict"; +'use strict'; module.exports = function (/* environment, appConfig */) { return {}; diff --git a/addons/core/ember-cli-build.js b/addons/core/ember-cli-build.js index b6a8f26a0..ba0649dc9 100644 --- a/addons/core/ember-cli-build.js +++ b/addons/core/ember-cli-build.js @@ -1,6 +1,6 @@ -"use strict"; +'use strict'; -const EmberAddon = require("ember-cli/lib/broccoli/ember-addon"); +const EmberAddon = require('ember-cli/lib/broccoli/ember-addon'); module.exports = function (defaults) { let app = new EmberAddon(defaults, { diff --git a/addons/core/index.js b/addons/core/index.js index 245249bda..fa6be2662 100644 --- a/addons/core/index.js +++ b/addons/core/index.js @@ -1,4 +1,4 @@ -"use strict"; +'use strict'; module.exports = { - name: require("./package").name, + name: require('./package').name, }; diff --git a/addons/core/package.json b/addons/core/package.json index d5e613ea4..63edf135d 100644 --- a/addons/core/package.json +++ b/addons/core/package.json @@ -15,10 +15,13 @@ "scripts": { "build:development": "ember build", "build": "ember build --environment=production", - "lint": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*", + "lint": "npm-run-all --aggregate-output --continue-on-error --parallel 'lint:!(fix)'", + "lint:fix": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*:fix", + "lint:hbs:fix": "ember-template-lint . --fix", "lint:js": "eslint .", "format": "npm run format:js", "format:js": "prettier --write '{addon,app,config,stories,tests}/**/*.js' *.js", + "lint:js:fix": "eslint . --fix", "start": "ember serve", "test": "ember test", "test:ember-compatibility": "ember try:each", @@ -27,8 +30,8 @@ "dependencies": { "api": "*", "auth": "*", - "ember-cli-babel": "^7.21.0", - "ember-cli-htmlbars": "^5.2.0", + "ember-cli-babel": "^7.23.0", + "ember-cli-htmlbars": "^5.3.1", "ember-get-config": "^0.3.0", "ember-intl": "^5.5.0", "ember-loading": "^0.4.0", @@ -37,38 +40,43 @@ "rose": "*" }, "devDependencies": { - "@ember/optional-features": "^1.3.0", - "@glimmer/component": "^1.0.1", - "@glimmer/tracking": "^1.0.0", + "@ember/optional-features": "^2.0.0", + "@ember/test-helpers": "^2.1.4", + "@glimmer/component": "^1.0.3", + "@glimmer/tracking": "^1.0.3", "babel-eslint": "^10.1.0", "broccoli-asset-rev": "^3.0.0", "doctoc": "^1.4.0", - "ember-auto-import": "^1.6.0", - "ember-cli": "~3.20.2", + "ember-auto-import": "^1.10.1", + "ember-cli": "~3.24.0", "ember-cli-dependency-checker": "^3.2.0", "ember-cli-inject-live-reload": "^2.0.2", "ember-cli-sri": "^2.1.1", - "ember-cli-uglify": "^3.0.0", + "ember-cli-terser": "^4.0.1", "ember-disable-prototype-extensions": "^1.1.3", "ember-export-application-global": "^2.0.1", "ember-inline-svg": "^1.0.0", "ember-intl": "^5.5.0", - "ember-load-initializers": "^2.1.1", + "ember-load-initializers": "^2.1.2", "ember-maybe-import-regenerator": "^0.1.6", - "ember-qunit": "^4.6.0", - "ember-resolver": "^8.0.0", - "ember-source": "~3.20.2", - "ember-source-channel-url": "^2.0.1", - "ember-template-lint": "^2.9.1", + "ember-page-title": "^6.0.3", + "ember-qunit": "^5.1.1", + "ember-resolver": "^8.0.2", + "ember-source": "~3.24.0", + "ember-source-channel-url": "^3.0.0", + "ember-template-lint": "^2.15.0", "ember-try": "^1.4.0", - "eslint": "^7.5.0", - "eslint-plugin-ember": "^8.9.1", + "eslint": "^7.17.0", + "eslint-config-prettier": "^7.1.0", + "eslint-plugin-ember": "^10.1.1", "eslint-plugin-node": "^11.1.0", + "eslint-plugin-prettier": "^3.3.1", "faker": "^5.1.0", "loader.js": "^4.7.0", "npm-run-all": "^4.1.5", - "prettier": "^2.1.2", - "qunit-dom": "^1.2.0" + "prettier": "^2.2.1", + "qunit": "^2.13.0", + "qunit-dom": "^1.6.0" }, "engines": { "node": "10.* || >= 12" diff --git a/addons/core/testem.js b/addons/core/testem.js index e3e8564ff..ed2f37124 100644 --- a/addons/core/testem.js +++ b/addons/core/testem.js @@ -1,22 +1,22 @@ -"use strict"; +'use strict'; module.exports = { - test_page: "tests/index.html?hidepassed", + test_page: 'tests/index.html?hidepassed', disable_watching: true, - launch_in_ci: ["Chrome"], - launch_in_dev: ["Chrome"], + launch_in_ci: ['Chrome'], + launch_in_dev: ['Chrome'], browser_start_timeout: 120, browser_args: { Chrome: { ci: [ // --no-sandbox is needed when running Chrome inside a container - process.env.CI ? "--no-sandbox" : null, - "--headless", - "--disable-dev-shm-usage", - "--disable-software-rasterizer", - "--mute-audio", - "--remote-debugging-port=0", - "--window-size=1440,900", + process.env.CI ? '--no-sandbox' : null, + '--headless', + '--disable-dev-shm-usage', + '--disable-software-rasterizer', + '--mute-audio', + '--remote-debugging-port=0', + '--window-size=1440,900', ].filter(Boolean), }, }, diff --git a/addons/core/tests/dummy/app/app.js b/addons/core/tests/dummy/app/app.js index 2ae212dbd..523bad60c 100644 --- a/addons/core/tests/dummy/app/app.js +++ b/addons/core/tests/dummy/app/app.js @@ -1,7 +1,7 @@ -import Application from "@ember/application"; -import Resolver from "ember-resolver"; -import loadInitializers from "ember-load-initializers"; -import config from "dummy/config/environment"; +import Application from '@ember/application'; +import Resolver from 'ember-resolver'; +import loadInitializers from 'ember-load-initializers'; +import config from 'dummy/config/environment'; export default class App extends Application { modulePrefix = config.modulePrefix; diff --git a/addons/core/tests/dummy/app/formats.js b/addons/core/tests/dummy/app/formats.js index 4a4add42f..f5d1f1502 100644 --- a/addons/core/tests/dummy/app/formats.js +++ b/addons/core/tests/dummy/app/formats.js @@ -1,29 +1,29 @@ export default { time: { hhmmss: { - hour: "numeric", - minute: "numeric", - second: "numeric", + hour: 'numeric', + minute: 'numeric', + second: 'numeric', }, }, date: { hhmmss: { - hour: "numeric", - minute: "numeric", - second: "numeric", + hour: 'numeric', + minute: 'numeric', + second: 'numeric', }, }, number: { - compact: { notation: "compact" }, + compact: { notation: 'compact' }, EUR: { - style: "currency", - currency: "EUR", + style: 'currency', + currency: 'EUR', minimumFractionDigits: 2, maximumFractionDigits: 2, }, USD: { - style: "currency", - currency: "USD", + style: 'currency', + currency: 'USD', minimumFractionDigits: 2, maximumFractionDigits: 2, }, diff --git a/addons/core/tests/dummy/app/router.js b/addons/core/tests/dummy/app/router.js index 018b4b1ca..64e543ab2 100644 --- a/addons/core/tests/dummy/app/router.js +++ b/addons/core/tests/dummy/app/router.js @@ -1,5 +1,5 @@ -import EmberRouter from "@ember/routing/router"; -import config from "dummy/config/environment"; +import EmberRouter from '@ember/routing/router'; +import config from 'dummy/config/environment'; export default class Router extends EmberRouter { location = config.locationType; diff --git a/addons/core/tests/dummy/config/ember-cli-update.json b/addons/core/tests/dummy/config/ember-cli-update.json index 7d2c3ace4..279e6dab9 100644 --- a/addons/core/tests/dummy/config/ember-cli-update.json +++ b/addons/core/tests/dummy/config/ember-cli-update.json @@ -3,7 +3,7 @@ "packages": [ { "name": "ember-cli", - "version": "3.20.2", + "version": "3.24.0", "blueprints": [ { "name": "addon", diff --git a/addons/core/tests/dummy/config/ember-intl.js b/addons/core/tests/dummy/config/ember-intl.js index a5a3a93d5..70719ccdc 100644 --- a/addons/core/tests/dummy/config/ember-intl.js +++ b/addons/core/tests/dummy/config/ember-intl.js @@ -25,7 +25,7 @@ module.exports = function (/* environment */) { * @type {String} * @default "'translations'" */ - inputPath: "../../translations", + inputPath: '../../translations', /** * Prevents the translations from being bundled with the application code. diff --git a/addons/core/tests/dummy/config/environment.js b/addons/core/tests/dummy/config/environment.js index 2a5061f98..dca0b66ac 100644 --- a/addons/core/tests/dummy/config/environment.js +++ b/addons/core/tests/dummy/config/environment.js @@ -1,11 +1,11 @@ -"use strict"; +'use strict'; module.exports = function (environment) { let ENV = { - modulePrefix: "dummy", + modulePrefix: 'dummy', environment, - rootURL: "/", - locationType: "auto", + rootURL: '/', + locationType: 'auto', EmberENV: { FEATURES: { // Here you can enable experimental features on an ember canary build @@ -29,7 +29,7 @@ module.exports = function (environment) { baseURL: 'https://boundaryproject.io/help/admin-ui', topics: { account: '/accounts', - } + }, }, api: { @@ -38,13 +38,13 @@ module.exports = function (environment) { }, 'ember-cli-mirage': { - directory: '../api/mirage' + directory: '../api/mirage', }, - enableConfirmService: false + enableConfirmService: false, }; - if (environment === "development") { + if (environment === 'development') { // ENV.APP.LOG_RESOLVER = true; // ENV.APP.LOG_ACTIVE_GENERATION = true; // ENV.APP.LOG_TRANSITIONS = true; @@ -52,19 +52,19 @@ module.exports = function (environment) { // ENV.APP.LOG_VIEW_LOOKUPS = true; } - if (environment === "test") { + if (environment === 'test') { // Testem prefers this... - ENV.locationType = "none"; + ENV.locationType = 'none'; // keep test console output quieter ENV.APP.LOG_ACTIVE_GENERATION = false; ENV.APP.LOG_VIEW_LOOKUPS = false; - ENV.APP.rootElement = "#ember-testing"; + ENV.APP.rootElement = '#ember-testing'; ENV.APP.autoboot = false; } - if (environment === "production") { + if (environment === 'production') { // here you can enable a production-specific feature } diff --git a/addons/core/tests/dummy/config/targets.js b/addons/core/tests/dummy/config/targets.js index 9a022efa9..4b33327e8 100644 --- a/addons/core/tests/dummy/config/targets.js +++ b/addons/core/tests/dummy/config/targets.js @@ -1,16 +1,16 @@ -"use strict"; +'use strict'; const browsers = [ - "last 1 Chrome versions", - "last 1 Firefox versions", - "last 1 Safari versions", + 'last 1 Chrome versions', + 'last 1 Firefox versions', + 'last 1 Safari versions', ]; const isCI = Boolean(process.env.CI); -const isProduction = process.env.EMBER_ENV === "production"; +const isProduction = process.env.EMBER_ENV === 'production'; if (isCI || isProduction) { - browsers.push("ie 11"); + browsers.push('ie 11'); } module.exports = { diff --git a/addons/core/tests/index.html b/addons/core/tests/index.html index 5209b8523..3eb848dbd 100644 --- a/addons/core/tests/index.html +++ b/addons/core/tests/index.html @@ -21,6 +21,13 @@ {{content-for "body"}} {{content-for "test-body"}} +
+
+
+
+
+
+ diff --git a/addons/core/tests/integration/components/error/message-test.js b/addons/core/tests/integration/components/error/message-test.js index 47651bd89..a28f3c618 100644 --- a/addons/core/tests/integration/components/error/message-test.js +++ b/addons/core/tests/integration/components/error/message-test.js @@ -60,7 +60,7 @@ module('Integration | Component | error/message', function (hooks) { ); assert.equal( find('.rose-message-description').textContent.trim(), - 'We\'re not sure what happened. Please contact your administrator or try again later.' + "We're not sure what happened. Please contact your administrator or try again later." ); }); }); diff --git a/addons/core/tests/integration/helpers/company-copyright-test.js b/addons/core/tests/integration/helpers/company-copyright-test.js index 3025f34a1..2965f90e0 100644 --- a/addons/core/tests/integration/helpers/company-copyright-test.js +++ b/addons/core/tests/integration/helpers/company-copyright-test.js @@ -10,6 +10,9 @@ module('Integration | Helper | company-copyright', function (hooks) { assert.expect(1); const currentYear = new Date().getFullYear(); await render(hbs`{{company-copyright}}`); - assert.equal(this.element.textContent.trim(), `© ${currentYear} Company Name`); + assert.equal( + this.element.textContent.trim(), + `© ${currentYear} Company Name` + ); }); }); diff --git a/addons/core/tests/test-helper.js b/addons/core/tests/test-helper.js index d71607e7e..4efd6e58a 100644 --- a/addons/core/tests/test-helper.js +++ b/addons/core/tests/test-helper.js @@ -1,8 +1,12 @@ -import Application from "dummy/app"; -import config from "dummy/config/environment"; -import { setApplication } from "@ember/test-helpers"; -import { start } from "ember-qunit"; +import Application from 'dummy/app'; +import config from 'dummy/config/environment'; +import * as QUnit from 'qunit'; +import { setApplication } from '@ember/test-helpers'; +import { setup } from 'qunit-dom'; +import { start } from 'ember-qunit'; setApplication(Application.create(config.APP)); +setup(QUnit.assert); + start(); diff --git a/addons/rose/.eslintignore b/addons/rose/.eslintignore index 702dec378..0e64ff566 100644 --- a/addons/rose/.eslintignore +++ b/addons/rose/.eslintignore @@ -15,6 +15,7 @@ main.js /coverage/ !.* +.eslintcache # ember-try /.node_modules.ember-try/ diff --git a/addons/rose/.eslintrc.js b/addons/rose/.eslintrc.js index 50aa56a4f..bdb867ae9 100644 --- a/addons/rose/.eslintrc.js +++ b/addons/rose/.eslintrc.js @@ -7,51 +7,56 @@ module.exports = { ecmaVersion: 2018, sourceType: 'module', ecmaFeatures: { - legacyDecorators: true - } + legacyDecorators: true, + }, }, - plugins: [ - 'ember' - ], + plugins: ['ember'], extends: [ 'eslint:recommended', - 'plugin:ember/recommended' + 'plugin:ember/recommended', + 'plugin:prettier/recommended', ], env: { - browser: true + browser: true, }, rules: { 'ember/no-jquery': 'error', - 'ember/no-new-mixins': 0 + 'ember/no-new-mixins': 0, + 'ember/no-get': 'off', + 'ember/no-get-with-default': 'off', + 'ember/no-computed-properties-in-native-classes': 'off', + 'ember/no-assignment-of-untracked-properties-used-in-tracking-contexts': + 'off', }, overrides: [ // node files { files: [ '.eslintrc.js', + '.prettierrc.js', '.template-lintrc.js', 'ember-cli-build.js', 'index.js', 'testem.js', 'blueprints/*/index.js', 'config/**/*.js', - 'tests/dummy/config/**/*.js' + 'tests/dummy/config/**/*.js', ], excludedFiles: [ 'addon/**', 'addon-test-support/**', 'app/**', - 'tests/dummy/app/**' + 'tests/dummy/app/**', ], parserOptions: { - sourceType: 'script' + sourceType: 'script', }, env: { browser: false, - node: true + node: true, }, plugins: ['node'], - extends: ['plugin:node/recommended'] - } - ] + extends: ['plugin:node/recommended'], + }, + ], }; diff --git a/addons/rose/.npmignore b/addons/rose/.npmignore index bd09adff9..88818f2c8 100644 --- a/addons/rose/.npmignore +++ b/addons/rose/.npmignore @@ -10,6 +10,7 @@ /.editorconfig /.ember-cli /.env* +/.eslintcache /.eslintignore /.eslintrc.js /.git/ diff --git a/addons/rose/.prettierignore b/addons/rose/.prettierignore new file mode 100644 index 000000000..922165552 --- /dev/null +++ b/addons/rose/.prettierignore @@ -0,0 +1,21 @@ +# unconventional js +/blueprints/*/files/ +/vendor/ + +# compiled output +/dist/ +/tmp/ + +# dependencies +/bower_components/ +/node_modules/ + +# misc +/coverage/ +!.* +.eslintcache + +# ember-try +/.node_modules.ember-try/ +/bower.json.ember-try +/package.json.ember-try diff --git a/addons/rose/.prettierrc.js b/addons/rose/.prettierrc.js new file mode 100644 index 000000000..534e6d35a --- /dev/null +++ b/addons/rose/.prettierrc.js @@ -0,0 +1,5 @@ +'use strict'; + +module.exports = { + singleQuote: true, +}; diff --git a/addons/rose/.template-lintrc.js b/addons/rose/.template-lintrc.js index f38737001..3b0b9af95 100644 --- a/addons/rose/.template-lintrc.js +++ b/addons/rose/.template-lintrc.js @@ -1,5 +1,5 @@ 'use strict'; module.exports = { - extends: 'octane' + extends: 'octane', }; diff --git a/addons/core/.travis.yml b/addons/rose/.travis.yml similarity index 77% rename from addons/core/.travis.yml rename to addons/rose/.travis.yml index 1211e146c..156fd25fa 100644 --- a/addons/core/.travis.yml +++ b/addons/rose/.travis.yml @@ -11,7 +11,8 @@ addons: chrome: stable cache: - yarn: true + directories: + - $HOME/.npm env: global: @@ -34,19 +35,18 @@ jobs: - stage: "Tests" name: "Tests" script: - - yarn lint - - yarn test:ember + - npm run lint + - npm run test:ember - stage: "Additional Tests" name: "Floating Dependencies" install: - - yarn install --no-lockfile --non-interactive + - npm install --no-package-lock script: - - yarn test:ember + - npm run test:ember # we recommend new addons test the current and previous LTS # as well as latest stable release (bonus points to beta/canary) - - env: EMBER_TRY_SCENARIO=ember-lts-3.12 - env: EMBER_TRY_SCENARIO=ember-lts-3.16 - env: EMBER_TRY_SCENARIO=ember-lts-3.20 - env: EMBER_TRY_SCENARIO=ember-release @@ -55,12 +55,5 @@ jobs: - env: EMBER_TRY_SCENARIO=ember-default-with-jquery - env: EMBER_TRY_SCENARIO=ember-classic -before_install: - - curl -o- -L https://yarnpkg.com/install.sh | bash - - export PATH=$HOME/.yarn/bin:$PATH - -install: - - yarn install --non-interactive - script: - node_modules/.bin/ember try:one $EMBER_TRY_SCENARIO diff --git a/addons/rose/addon/components/rose/dialog/index.js b/addons/rose/addon/components/rose/dialog/index.js index e152fcaf0..eaba66c8a 100644 --- a/addons/rose/addon/components/rose/dialog/index.js +++ b/addons/rose/addon/components/rose/dialog/index.js @@ -3,7 +3,6 @@ import { generateComponentID } from '../../../utilities/component-auto-id'; import { action } from '@ember/object'; export default class RoseDialogComponent extends Component { - // =attributes /** @@ -23,5 +22,4 @@ export default class RoseDialogComponent extends Component { dismiss(fn) { fn(); } - } diff --git a/addons/rose/addon/components/rose/dropdown/index.js b/addons/rose/addon/components/rose/dropdown/index.js index 916c50c3f..cac1a9963 100644 --- a/addons/rose/addon/components/rose/dropdown/index.js +++ b/addons/rose/addon/components/rose/dropdown/index.js @@ -2,7 +2,6 @@ import Component from '@glimmer/component'; import { computed, action } from '@ember/object'; export default class RoseDropdownComponent extends Component { - // =attributes /** diff --git a/addons/rose/addon/components/rose/dropdown/section/index.js b/addons/rose/addon/components/rose/dropdown/section/index.js index eb2727185..84b354d6c 100644 --- a/addons/rose/addon/components/rose/dropdown/section/index.js +++ b/addons/rose/addon/components/rose/dropdown/section/index.js @@ -3,12 +3,10 @@ import { generateComponentID } from '../../../../utilities/component-auto-id'; import { action } from '@ember/object'; export default class RoseDialogComponent extends Component { - // =attributes /** * @type {string} */ id = generateComponentID(); - } diff --git a/addons/rose/addon/components/rose/footer/copyright/index.js b/addons/rose/addon/components/rose/footer/copyright/index.js index a9068f750..49e6594d0 100644 --- a/addons/rose/addon/components/rose/footer/copyright/index.js +++ b/addons/rose/addon/components/rose/footer/copyright/index.js @@ -1,8 +1,6 @@ import Component from '@glimmer/component'; export default class RoseFooterCopyrightComponent extends Component { - // =attributes currentYear = new Date().getFullYear(); - } diff --git a/addons/rose/addon/components/rose/form/actions/index.js b/addons/rose/addon/components/rose/form/actions/index.js index f8d5bb76e..89e038e72 100644 --- a/addons/rose/addon/components/rose/form/actions/index.js +++ b/addons/rose/addon/components/rose/form/actions/index.js @@ -14,7 +14,6 @@ import { computed } from '@ember/object'; * @cancel=(fn @cancel) /> */ export default class RoseFormActionsComponent extends Component { - /** * @type {boolean} */ diff --git a/addons/rose/addon/components/rose/form/checkbox/index.js b/addons/rose/addon/components/rose/form/checkbox/index.js index b13f24e4f..e557dcd4a 100644 --- a/addons/rose/addon/components/rose/form/checkbox/index.js +++ b/addons/rose/addon/components/rose/form/checkbox/index.js @@ -2,9 +2,7 @@ import Component from '@glimmer/component'; import { generateComponentID } from '../../../../utilities/component-auto-id'; export default class RoseFormCheckboxComponent extends Component { - // =attributes id = generateComponentID(); - } diff --git a/addons/rose/addon/components/rose/form/index.js b/addons/rose/addon/components/rose/form/index.js index 2a9f102e3..a7102918f 100644 --- a/addons/rose/addon/components/rose/form/index.js +++ b/addons/rose/addon/components/rose/form/index.js @@ -3,7 +3,6 @@ import { tracked } from '@glimmer/tracking'; import { computed, action } from '@ember/object'; export default class RoseFormComponent extends Component { - // =attributes /** @@ -57,9 +56,7 @@ export default class RoseFormComponent extends Component { // Since submit is allowed to fail in this context and we don't want // unhandled rejection warnings, we have a no-op catch. if (submitResult?.then) { - submitResult - .then(() => this.isEditable = false) - .catch(() => {}); + submitResult.then(() => (this.isEditable = false)).catch(() => {}); } return false; } @@ -89,5 +86,4 @@ export default class RoseFormComponent extends Component { disableEdit() { this.isEditable = false; } - } diff --git a/addons/rose/addon/components/rose/form/input/index.js b/addons/rose/addon/components/rose/form/input/index.js index 4fbc071f4..de4e226b2 100644 --- a/addons/rose/addon/components/rose/form/input/index.js +++ b/addons/rose/addon/components/rose/form/input/index.js @@ -2,9 +2,7 @@ import Component from '@glimmer/component'; import { generateComponentID } from '../../../../utilities/component-auto-id'; export default class RoseFormInputComponent extends Component { - // =attributes id = generateComponentID(); - } diff --git a/addons/rose/addon/components/rose/form/radio/radio/index.js b/addons/rose/addon/components/rose/form/radio/radio/index.js index ac2c2a6ec..0487f6fe1 100644 --- a/addons/rose/addon/components/rose/form/radio/radio/index.js +++ b/addons/rose/addon/components/rose/form/radio/radio/index.js @@ -2,9 +2,7 @@ import Component from '@glimmer/component'; import { generateComponentID } from '../../../../../utilities/component-auto-id'; export default class RoseFormRadioRadioComponent extends Component { - // =attributes id = generateComponentID(); - } diff --git a/addons/rose/addon/components/rose/form/select/index.js b/addons/rose/addon/components/rose/form/select/index.js index 9690ea00f..fddc7dd2b 100644 --- a/addons/rose/addon/components/rose/form/select/index.js +++ b/addons/rose/addon/components/rose/form/select/index.js @@ -2,9 +2,7 @@ import Component from '@glimmer/component'; import { generateComponentID } from '../../../../utilities/component-auto-id'; export default class RoseFormSelectComponent extends Component { - // =attributes id = generateComponentID(); - } diff --git a/addons/rose/addon/components/rose/form/textarea/index.js b/addons/rose/addon/components/rose/form/textarea/index.js index bbe402965..ff8ed90d1 100644 --- a/addons/rose/addon/components/rose/form/textarea/index.js +++ b/addons/rose/addon/components/rose/form/textarea/index.js @@ -2,9 +2,7 @@ import Component from '@glimmer/component'; import { generateComponentID } from '../../../../utilities/component-auto-id'; export default class RoseFormTextareaComponent extends Component { - // =attributes id = generateComponentID(); - } diff --git a/addons/rose/addon/components/rose/list/key-value/item/index.js b/addons/rose/addon/components/rose/list/key-value/item/index.js index a166c7897..145cf4258 100644 --- a/addons/rose/addon/components/rose/list/key-value/item/index.js +++ b/addons/rose/addon/components/rose/list/key-value/item/index.js @@ -2,9 +2,7 @@ import Component from '@glimmer/component'; import { generateComponentID } from '../../../../../utilities/component-auto-id'; export default class RoseListKeyValueItemComponent extends Component { - // =attributes id = generateComponentID(); - } diff --git a/addons/rose/addon/components/rose/nav/sidebar/index.js b/addons/rose/addon/components/rose/nav/sidebar/index.js index 1d3b63115..18ec05ae9 100644 --- a/addons/rose/addon/components/rose/nav/sidebar/index.js +++ b/addons/rose/addon/components/rose/nav/sidebar/index.js @@ -2,9 +2,7 @@ import Component from '@glimmer/component'; import { generateComponentID } from '../../../../utilities/component-auto-id'; export default class RoseNavSidebarComponent extends Component { - // =attributes id = generateComponentID(); - } diff --git a/addons/rose/addon/components/rose/notification/index.js b/addons/rose/addon/components/rose/notification/index.js index c27d54f9b..881d11355 100644 --- a/addons/rose/addon/components/rose/notification/index.js +++ b/addons/rose/addon/components/rose/notification/index.js @@ -2,7 +2,6 @@ import Component from '@glimmer/component'; import { computed } from '@ember/object'; export default class RoseNotificationComponent extends Component { - /** * Returns an icon name based on the notification style. * @type {string} @@ -25,5 +24,4 @@ export default class RoseNotificationComponent extends Component { return icon; } - } diff --git a/addons/rose/addon/styles/rose/components/_dialog.scss b/addons/rose/addon/styles/rose/components/_dialog.scss index 1ff395f63..677af2bfc 100644 --- a/addons/rose/addon/styles/rose/components/_dialog.scss +++ b/addons/rose/addon/styles/rose/components/_dialog.scss @@ -140,7 +140,7 @@ $xxxxs: sizing.rems(xxxxs); // 1 } // overlay .rose-dialog-modal-overlay { - content: " "; + content: ' '; background-color: var(--black); width: 100vw; height: 100vh; diff --git a/addons/rose/addon/styles/rose/components/card/_link.scss b/addons/rose/addon/styles/rose/components/card/_link.scss index 8c102c151..c4530d3e8 100644 --- a/addons/rose/addon/styles/rose/components/card/_link.scss +++ b/addons/rose/addon/styles/rose/components/card/_link.scss @@ -6,12 +6,11 @@ $xxxs: sizing.rems(xxxs); // 2 .rose-card-link { - --background-color-light: transparent; --background-color-dark: var(--ui-gray-subtler-6); --background-color: var(--background-color-light); - + .ember-application.rose-theme-light & { --background-color: var(--background-color-light); } @@ -124,7 +123,7 @@ $xxxs: sizing.rems(xxxs); // 2 margin: 0; &::before { - content: "ID"; + content: 'ID'; color: var(--stark); padding-right: sizing.rems(xs); } diff --git a/addons/rose/addon/styles/rose/components/dropdown/_section.scss b/addons/rose/addon/styles/rose/components/dropdown/_section.scss index f23bbc0c1..32cbe6150 100644 --- a/addons/rose/addon/styles/rose/components/dropdown/_section.scss +++ b/addons/rose/addon/styles/rose/components/dropdown/_section.scss @@ -9,6 +9,6 @@ margin: 0; $line-height: 36 / 14; line-height: $line-height; - color: var(--ui-gray) + color: var(--ui-gray); } } diff --git a/addons/rose/addon/styles/rose/components/header/_index.scss b/addons/rose/addon/styles/rose/components/header/_index.scss index 1bc82b5e3..d9c969c60 100644 --- a/addons/rose/addon/styles/rose/components/header/_index.scss +++ b/addons/rose/addon/styles/rose/components/header/_index.scss @@ -9,7 +9,6 @@ @import 'dropdown'; .rose-header { - --box-shadow-light: none; --box-shadow-dark: inset 0 -#{sizing.rems(xxxxs)} 0 var(--ui-border-subtler-1); diff --git a/addons/rose/addon/styles/rose/components/table/_table.scss b/addons/rose/addon/styles/rose/components/table/_table.scss index 956ab5faa..0c581393e 100644 --- a/addons/rose/addon/styles/rose/components/table/_table.scss +++ b/addons/rose/addon/styles/rose/components/table/_table.scss @@ -35,7 +35,7 @@ } } - [class*="rose-button"] { + [class*='rose-button'] { margin-bottom: 0; } } diff --git a/addons/rose/addon/styles/rose/variables/_sizing.scss b/addons/rose/addon/styles/rose/variables/_sizing.scss index 81b9c94e9..6879d2da9 100644 --- a/addons/rose/addon/styles/rose/variables/_sizing.scss +++ b/addons/rose/addon/styles/rose/variables/_sizing.scss @@ -7,23 +7,23 @@ $size-coefficients: ( xxl: 3, // 48 - xl: 2.25, + xl: 2.25, // 36 - l: 1.5, + l: 1.5, // 24 - m: 1, + m: 1, // 16 - base - s: 0.75, + s: 0.75, // 12 - xs: 0.5, + xs: 0.5, // 8 - off-xs: 0.3125, + off-xs: 0.3125, // 5 - xxs: 0.25, + xxs: 0.25, // 4 - xxxs: 0.125, + xxxs: 0.125, // 2 - xxxxs: 0.0625, + xxxxs: 0.0625, // 1 ); diff --git a/addons/rose/addon/styles/rose/variables/_typography.scss b/addons/rose/addon/styles/rose/variables/_typography.scss index 067c74496..1bd4c5415 100644 --- a/addons/rose/addon/styles/rose/variables/_typography.scss +++ b/addons/rose/addon/styles/rose/variables/_typography.scss @@ -26,21 +26,21 @@ $base-font-size: 16; $font-sizes: ( xl: sizing.size(m) * 1.75, // 28 - l: sizing.size(m) * 1.25, + l: sizing.size(m) * 1.25, // 20 - m: sizing.size(m), + m: sizing.size(m), // 16 - s: sizing.size(m) * 0.875, + s: sizing.size(m) * 0.875, // 14 - xs: sizing.size(m) * 0.75, + xs: sizing.size(m) * 0.75, // 12 - h1: sizing.size(m) * 1.75, + h1: sizing.size(m) * 1.75, // 28 - h2: sizing.size(m) * 1.25, + h2: sizing.size(m) * 1.25, // 20 - h3: sizing.size(m), + h3: sizing.size(m), // 16 - button: sizing.size(m) * 0.8125, + button: sizing.size(m) * 0.8125, // 13 ); diff --git a/addons/rose/app/components/rose/dialog.js b/addons/rose/app/components/rose/dialog.js index 6d1f33374..e457a1ea4 100644 --- a/addons/rose/app/components/rose/dialog.js +++ b/addons/rose/app/components/rose/dialog.js @@ -1 +1 @@ -export { default } from 'rose/components/rose/dialog'; \ No newline at end of file +export { default } from 'rose/components/rose/dialog'; diff --git a/addons/rose/app/components/rose/dialog/body.js b/addons/rose/app/components/rose/dialog/body.js index 53ba1e1f2..6022217f2 100644 --- a/addons/rose/app/components/rose/dialog/body.js +++ b/addons/rose/app/components/rose/dialog/body.js @@ -1 +1 @@ -export { default } from 'rose/components/rose/dialog/body'; \ No newline at end of file +export { default } from 'rose/components/rose/dialog/body'; diff --git a/addons/rose/app/components/rose/dropdown/section.js b/addons/rose/app/components/rose/dropdown/section.js index 5b4572475..296cc4544 100644 --- a/addons/rose/app/components/rose/dropdown/section.js +++ b/addons/rose/app/components/rose/dropdown/section.js @@ -1 +1 @@ -export { default } from 'rose/components/rose/dropdown/section'; \ No newline at end of file +export { default } from 'rose/components/rose/dropdown/section'; diff --git a/addons/rose/app/components/rose/footer.js b/addons/rose/app/components/rose/footer.js index ccac33104..0e28e5c81 100644 --- a/addons/rose/app/components/rose/footer.js +++ b/addons/rose/app/components/rose/footer.js @@ -1 +1 @@ -export { default } from 'rose/components/rose/footer'; \ No newline at end of file +export { default } from 'rose/components/rose/footer'; diff --git a/addons/rose/app/components/rose/footer/brand.js b/addons/rose/app/components/rose/footer/brand.js index 995d715ba..0f7f60629 100644 --- a/addons/rose/app/components/rose/footer/brand.js +++ b/addons/rose/app/components/rose/footer/brand.js @@ -1 +1 @@ -export { default } from 'rose/components/rose/footer/brand'; \ No newline at end of file +export { default } from 'rose/components/rose/footer/brand'; diff --git a/addons/rose/app/components/rose/footer/copyright.js b/addons/rose/app/components/rose/footer/copyright.js index d46304fc7..a6153621d 100644 --- a/addons/rose/app/components/rose/footer/copyright.js +++ b/addons/rose/app/components/rose/footer/copyright.js @@ -1 +1 @@ -export { default } from 'rose/components/rose/footer/copyright'; \ No newline at end of file +export { default } from 'rose/components/rose/footer/copyright'; diff --git a/addons/rose/app/components/rose/footer/nav.js b/addons/rose/app/components/rose/footer/nav.js index 3ca032af2..81282d6ea 100644 --- a/addons/rose/app/components/rose/footer/nav.js +++ b/addons/rose/app/components/rose/footer/nav.js @@ -1 +1 @@ -export { default } from 'rose/components/rose/footer/nav'; \ No newline at end of file +export { default } from 'rose/components/rose/footer/nav'; diff --git a/addons/rose/app/components/rose/footer/nav/link.js b/addons/rose/app/components/rose/footer/nav/link.js index e38b27530..8b14eb2c0 100644 --- a/addons/rose/app/components/rose/footer/nav/link.js +++ b/addons/rose/app/components/rose/footer/nav/link.js @@ -1 +1 @@ -export { default } from 'rose/components/rose/footer/nav/link'; \ No newline at end of file +export { default } from 'rose/components/rose/footer/nav/link'; diff --git a/addons/rose/app/components/rose/footer/product.js b/addons/rose/app/components/rose/footer/product.js index 7193b5690..ea676f3cf 100644 --- a/addons/rose/app/components/rose/footer/product.js +++ b/addons/rose/app/components/rose/footer/product.js @@ -1 +1 @@ -export { default } from 'rose/components/rose/footer/product'; \ No newline at end of file +export { default } from 'rose/components/rose/footer/product'; diff --git a/addons/rose/app/components/rose/form/actions/edit-toggle.js b/addons/rose/app/components/rose/form/actions/edit-toggle.js index e0790458d..033503049 100644 --- a/addons/rose/app/components/rose/form/actions/edit-toggle.js +++ b/addons/rose/app/components/rose/form/actions/edit-toggle.js @@ -1 +1 @@ -export { default } from 'rose/components/rose/form/actions/edit-toggle'; \ No newline at end of file +export { default } from 'rose/components/rose/form/actions/edit-toggle'; diff --git a/addons/rose/config/ember-try.js b/addons/rose/config/ember-try.js index 9190baee5..f14ac7f50 100644 --- a/addons/rose/config/ember-try.js +++ b/addons/rose/config/ember-try.js @@ -6,14 +6,6 @@ module.exports = async function () { return { useYarn: true, scenarios: [ - { - name: 'ember-lts-3.12', - npm: { - devDependencies: { - 'ember-source': '~3.12.0', - }, - }, - }, { name: 'ember-lts-3.16', npm: { @@ -26,9 +18,9 @@ module.exports = async function () { name: 'ember-lts-3.20', npm: { devDependencies: { - 'ember-source': '~3.20.5' - } - } + 'ember-source': '~3.20.5', + }, + }, }, { name: 'ember-release', @@ -63,9 +55,9 @@ module.exports = async function () { }, npm: { devDependencies: { - '@ember/jquery': '^1.1.0' - } - } + '@ember/jquery': '^1.1.0', + }, + }, }, { name: 'ember-classic', diff --git a/addons/rose/package.json b/addons/rose/package.json index 331b9d557..3a4666505 100644 --- a/addons/rose/package.json +++ b/addons/rose/package.json @@ -10,13 +10,16 @@ "scripts": { "build:development": "ember build", "build": "ember build --environment=production", - "lint": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*", + "lint": "npm-run-all --aggregate-output --continue-on-error --parallel 'lint:!(fix)'", + "lint:fix": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*:fix", "lint:hbs": "ember-template-lint .", + "lint:hbs:fix": "ember-template-lint . --fix", "lint:js": "eslint .", "lint:sass": "sass-lint -v -q", "format": "npm run format:js && npm run format:sass", "format:js": "prettier --write '{addon,app,config,stories,tests}/**/*.js' *.js", "format:sass": "prettier --write addon/**/*.scss", + "lint:js:fix": "eslint . --fix", "start": "ember serve", "test": "ember test", "test:ember-compatibility": "ember try:each", @@ -27,17 +30,18 @@ }, "dependencies": { "babel-loader": "^8.1.0", - "ember-cli-babel": "^7.21.0", - "ember-cli-htmlbars": "^5.2.0", + "ember-cli-babel": "^7.23.0", + "ember-cli-htmlbars": "^5.3.1", + "ember-focus-trap": "^0.4.0", "ember-radio-button": "^2.0.1", "ember-uuid": "^2.1.0", - "emberx-select": "github:adopted-ember-addons/emberx-select#bc5f774", - "ember-focus-trap": "^0.4.0" + "emberx-select": "github:adopted-ember-addons/emberx-select#bc5f774" }, "devDependencies": { - "@ember/optional-features": "^1.3.0", - "@glimmer/component": "^1.0.1", - "@glimmer/tracking": "^1.0.0", + "@ember/optional-features": "^2.0.0", + "@ember/test-helpers": "^2.1.4", + "@glimmer/component": "^1.0.3", + "@glimmer/tracking": "^1.0.3", "@hashicorp/structure-icons": "^1.8.1", "@storybook/addon-actions": "^6.0.26", "@storybook/addon-docs": "^6.0.26", @@ -47,33 +51,37 @@ "babel-eslint": "^10.1.0", "broccoli-asset-rev": "^3.0.0", "doctoc": "^1.4.0", - "ember-auto-import": "^1.6.0", - "ember-cli": "~3.20.2", + "ember-auto-import": "^1.10.1", + "ember-cli": "~3.24.0", "ember-cli-dependency-checker": "^3.2.0", "ember-cli-inject-live-reload": "^2.0.2", "ember-cli-sass": "^10.0.1", "ember-cli-sri": "^2.1.1", - "ember-cli-uglify": "^3.0.0", + "ember-cli-terser": "^4.0.1", "ember-cli-update": "^0.54.6", "ember-disable-prototype-extensions": "^1.1.3", "ember-export-application-global": "^2.0.1", "ember-inline-svg": "^1.0.0", - "ember-load-initializers": "^2.1.1", + "ember-load-initializers": "^2.1.2", "ember-maybe-import-regenerator": "^0.1.6", "ember-modifier": "^1.0.3", - "ember-qunit": "^4.6.0", - "ember-resolver": "^8.0.0", - "ember-source": "~3.20.2", - "ember-source-channel-url": "^2.0.1", - "ember-template-lint": "^2.9.1", + "ember-page-title": "^6.0.3", + "ember-qunit": "^5.1.1", + "ember-resolver": "^8.0.2", + "ember-source": "~3.24.0", + "ember-source-channel-url": "^3.0.0", + "ember-template-lint": "^2.15.0", "ember-try": "^1.4.0", - "eslint": "^7.5.0", - "eslint-plugin-ember": "^8.9.1", + "eslint": "^7.17.0", + "eslint-config-prettier": "^7.1.0", + "eslint-plugin-ember": "^10.1.1", "eslint-plugin-node": "^11.1.0", + "eslint-plugin-prettier": "^3.3.1", "loader.js": "^4.7.0", "npm-run-all": "^4.1.5", - "prettier": "^2.0.5", - "qunit-dom": "^1.2.0", + "prettier": "^2.2.1", + "qunit": "^2.13.0", + "qunit-dom": "^1.6.0", "sass": "^1.26.5", "sass-lint": "^1.13.1" }, diff --git a/addons/rose/tests/dummy/config/ember-cli-update.json b/addons/rose/tests/dummy/config/ember-cli-update.json index 3c0c55fdb..ed4d5fc2d 100644 --- a/addons/rose/tests/dummy/config/ember-cli-update.json +++ b/addons/rose/tests/dummy/config/ember-cli-update.json @@ -3,7 +3,7 @@ "packages": [ { "name": "ember-cli", - "version": "3.20.2", + "version": "3.24.0", "blueprints": [ { "name": "addon", diff --git a/addons/rose/tests/index.html b/addons/rose/tests/index.html index 5209b8523..3eb848dbd 100644 --- a/addons/rose/tests/index.html +++ b/addons/rose/tests/index.html @@ -21,6 +21,13 @@ {{content-for "body"}} {{content-for "test-body"}} +
+
+
+
+
+
+ diff --git a/addons/rose/tests/integration/components/rose/card/link-test.js b/addons/rose/tests/integration/components/rose/card/link-test.js index 288679791..af9003ef3 100644 --- a/addons/rose/tests/integration/components/rose/card/link-test.js +++ b/addons/rose/tests/integration/components/rose/card/link-test.js @@ -41,7 +41,9 @@ module('Integration | Component | rose/card/link', function (hooks) { }); test('it renders with @icon', async function (assert) { - await render(hbs``); + await render( + hbs`` + ); assert.ok(find('.rose-icon')); }); diff --git a/addons/rose/tests/integration/components/rose/dialog-test.js b/addons/rose/tests/integration/components/rose/dialog-test.js index a3fe4c8d6..2207378f2 100644 --- a/addons/rose/tests/integration/components/rose/dialog-test.js +++ b/addons/rose/tests/integration/components/rose/dialog-test.js @@ -3,7 +3,7 @@ import { setupRenderingTest } from 'ember-qunit'; import { render, find, click } from '@ember/test-helpers'; import { hbs } from 'ember-cli-htmlbars'; -module('Integration | Component | rose/dialog', function(hooks) { +module('Integration | Component | rose/dialog', function (hooks) { setupRenderingTest(hooks); test('it renders and handles dismiss actions', async function (assert) { @@ -24,5 +24,4 @@ module('Integration | Component | rose/dialog', function(hooks) { assert.ok(find('.rose-dialog-footer')); await click('button'); }); - }); diff --git a/addons/rose/tests/integration/components/rose/dialog/body-test.js b/addons/rose/tests/integration/components/rose/dialog/body-test.js index 28376e933..252f745a3 100644 --- a/addons/rose/tests/integration/components/rose/dialog/body-test.js +++ b/addons/rose/tests/integration/components/rose/dialog/body-test.js @@ -3,10 +3,10 @@ import { setupRenderingTest } from 'ember-qunit'; import { render } from '@ember/test-helpers'; import { hbs } from 'ember-cli-htmlbars'; -module('Integration | Component | rose/dialog/body', function(hooks) { +module('Integration | Component | rose/dialog/body', function (hooks) { setupRenderingTest(hooks); - test('it renders', async function(assert) { + test('it renders', async function (assert) { // Set any properties with this.set('myProperty', 'value'); // Handle any actions with this.set('myAction', function(val) { ... }); diff --git a/addons/rose/tests/integration/components/rose/dropdown/section-test.js b/addons/rose/tests/integration/components/rose/dropdown/section-test.js index 1719ccd6a..201ba9c82 100644 --- a/addons/rose/tests/integration/components/rose/dropdown/section-test.js +++ b/addons/rose/tests/integration/components/rose/dropdown/section-test.js @@ -3,10 +3,10 @@ import { setupRenderingTest } from 'ember-qunit'; import { render, find } from '@ember/test-helpers'; import { hbs } from 'ember-cli-htmlbars'; -module('Integration | Component | rose/dropdown/section', function(hooks) { +module('Integration | Component | rose/dropdown/section', function (hooks) { setupRenderingTest(hooks); - test('it renders', async function(assert) { + test('it renders', async function (assert) { await render(hbs` template block text @@ -16,12 +16,15 @@ module('Integration | Component | rose/dropdown/section', function(hooks) { assert.equal(this.element.textContent.trim(), 'template block text'); }); - test('it renders with optional @title', async function(assert) { + test('it renders with optional @title', async function (assert) { await render(hbs` template block text `); - assert.equal(find('.rose-dropdown-section-title').textContent.trim(), 'Section Title'); + assert.equal( + find('.rose-dropdown-section-title').textContent.trim(), + 'Section Title' + ); }); }); diff --git a/addons/rose/tests/integration/components/rose/footer-test.js b/addons/rose/tests/integration/components/rose/footer-test.js index 4a43f0d4f..6da5ef4c8 100644 --- a/addons/rose/tests/integration/components/rose/footer-test.js +++ b/addons/rose/tests/integration/components/rose/footer-test.js @@ -3,9 +3,9 @@ import { setupRenderingTest } from 'ember-qunit'; import { render, find } from '@ember/test-helpers'; import { hbs } from 'ember-cli-htmlbars'; -module('Integration | Component | rose/footer', function(hooks) { +module('Integration | Component | rose/footer', function (hooks) { setupRenderingTest(hooks); - + test('it renders', async function (assert) { assert.expect(4); await render(hbs``); @@ -38,5 +38,4 @@ module('Integration | Component | rose/footer', function(hooks) { `); assert.ok(find('.rose-footer-text')); }); - }); diff --git a/addons/rose/tests/integration/components/rose/footer/nav-test.js b/addons/rose/tests/integration/components/rose/footer/nav-test.js index 782602f44..4c60c2de2 100644 --- a/addons/rose/tests/integration/components/rose/footer/nav-test.js +++ b/addons/rose/tests/integration/components/rose/footer/nav-test.js @@ -3,7 +3,7 @@ import { setupRenderingTest } from 'ember-qunit'; import { render, find, findAll } from '@ember/test-helpers'; import { hbs } from 'ember-cli-htmlbars'; -module('Integration | Component | rose/footer/nav', function(hooks) { +module('Integration | Component | rose/footer/nav', function (hooks) { setupRenderingTest(hooks); test('it renders', async function (assert) { @@ -20,5 +20,4 @@ module('Integration | Component | rose/footer/nav', function(hooks) { `); assert.equal(findAll('a').length, 2); }); - }); diff --git a/addons/rose/tests/integration/components/rose/footer/nav/link-test.js b/addons/rose/tests/integration/components/rose/footer/nav/link-test.js index d5405db01..caa744487 100644 --- a/addons/rose/tests/integration/components/rose/footer/nav/link-test.js +++ b/addons/rose/tests/integration/components/rose/footer/nav/link-test.js @@ -3,7 +3,7 @@ import { setupRenderingTest } from 'ember-qunit'; import { render, find } from '@ember/test-helpers'; import { hbs } from 'ember-cli-htmlbars'; -module('Integration | Component | rose/footer/nav/link', function(hooks) { +module('Integration | Component | rose/footer/nav/link', function (hooks) { setupRenderingTest(hooks); test('it renders with @href', async function (assert) { diff --git a/addons/rose/tests/integration/components/rose/footer/text-test.js b/addons/rose/tests/integration/components/rose/footer/text-test.js index d3cbfacff..fea89e0cd 100644 --- a/addons/rose/tests/integration/components/rose/footer/text-test.js +++ b/addons/rose/tests/integration/components/rose/footer/text-test.js @@ -3,7 +3,7 @@ import { setupRenderingTest } from 'ember-qunit'; import { render, find } from '@ember/test-helpers'; import { hbs } from 'ember-cli-htmlbars'; -module('Integration | Component | rose/footer/text', function(hooks) { +module('Integration | Component | rose/footer/text', function (hooks) { setupRenderingTest(hooks); test('it renders', async function (assert) { diff --git a/addons/rose/tests/integration/components/rose/form-test.js b/addons/rose/tests/integration/components/rose/form-test.js index a8103ca56..eae79f40e 100644 --- a/addons/rose/tests/integration/components/rose/form-test.js +++ b/addons/rose/tests/integration/components/rose/form-test.js @@ -69,7 +69,10 @@ module('Integration | Component | rose/form', function (hooks) { test('it supports an editability toggle when @showEditToggle is true', async function (assert) { assert.expect(12); this.cancel = () => { - assert.ok(true, 'cancel function may still be passed even for @showEditToggle'); + assert.ok( + true, + 'cancel function may still be passed even for @showEditToggle' + ); }; this.submit = () => {}; await render(hbs` @@ -96,7 +99,10 @@ module('Integration | Component | rose/form', function (hooks) { assert.equal(findAll('input[disabled]').length, 0); assert.equal(findAll('button').length, 2); assert.equal(find('[type="submit"]').textContent.trim(), 'Save'); - assert.equal(find('button:not([type="submit"])').textContent.trim(), 'Cancel'); + assert.equal( + find('button:not([type="submit"])').textContent.trim(), + 'Cancel' + ); // After canceling, fields are disabled again and the edit mode button is displayed await click('button:not([type="submit"])'); assert.equal(findAll('input[disabled]').length, 1); @@ -131,13 +137,19 @@ module('Integration | Component | rose/form', function (hooks) { assert.equal(findAll('input[disabled]').length, 0); assert.equal(findAll('button').length, 2); assert.equal(find('[type="submit"]').textContent.trim(), 'Save'); - assert.equal(find('button:not([type="submit"])').textContent.trim(), 'Cancel'); + assert.equal( + find('button:not([type="submit"])').textContent.trim(), + 'Cancel' + ); // After saving with failure, fields are enabled and save/cancel buttons are displayed this.submit = () => reject(); assert.equal(findAll('input[disabled]').length, 0); assert.equal(findAll('button').length, 2); assert.equal(find('[type="submit"]').textContent.trim(), 'Save'); - assert.equal(find('button:not([type="submit"])').textContent.trim(), 'Cancel'); + assert.equal( + find('button:not([type="submit"])').textContent.trim(), + 'Cancel' + ); // After saving with success, fields are disabled again and the edit mode button is displayed this.submit = () => resolve(); await click('button[type="submit"]'); diff --git a/addons/rose/tests/integration/components/rose/form/actions-test.js b/addons/rose/tests/integration/components/rose/form/actions-test.js index 0463d1247..21ea002b4 100644 --- a/addons/rose/tests/integration/components/rose/form/actions-test.js +++ b/addons/rose/tests/integration/components/rose/form/actions-test.js @@ -17,7 +17,9 @@ module('Integration | Component | rose/form/actions', function (hooks) { test('it can disable the buttons', async function (assert) { assert.expect(2); this.cancel = () => {}; - await render(hbs`{{rose/form/actions cancel=this.cancel submitDisabled=true cancelDisabled=true}}`); + await render( + hbs`{{rose/form/actions cancel=this.cancel submitDisabled=true cancelDisabled=true}}` + ); assert.ok(find('[type="submit"]:disabled')); assert.ok(find('button:not([type="submit"]):disabled')); }); diff --git a/addons/rose/tests/integration/components/rose/form/actions/edit-toggle-test.js b/addons/rose/tests/integration/components/rose/form/actions/edit-toggle-test.js index 436a14b03..fd31aa5a7 100644 --- a/addons/rose/tests/integration/components/rose/form/actions/edit-toggle-test.js +++ b/addons/rose/tests/integration/components/rose/form/actions/edit-toggle-test.js @@ -3,20 +3,27 @@ import { setupRenderingTest } from 'ember-qunit'; import { render, find, click } from '@ember/test-helpers'; import hbs from 'htmlbars-inline-precompile'; -module('Integration | Component | rose/form/actions/edit-toggle', function (hooks) { - setupRenderingTest(hooks); +module( + 'Integration | Component | rose/form/actions/edit-toggle', + function (hooks) { + setupRenderingTest(hooks); - test('it renders a regular button', async function (assert) { - assert.expect(1); - this.enableEdit = () => {}; - await render(hbs`{{rose/form/actions/edit-toggle enableEdit=this.enableEdit}}`); - assert.ok(find('button')); - }); + test('it renders a regular button', async function (assert) { + assert.expect(1); + this.enableEdit = () => {}; + await render( + hbs`{{rose/form/actions/edit-toggle enableEdit=this.enableEdit}}` + ); + assert.ok(find('button')); + }); - test('it executes a function on button click', async function (assert) { - assert.expect(1); - this.enableEdit = () => assert.ok(true, 'edit was clicked'); - await render(hbs`{{rose/form/actions/edit-toggle enableEdit=this.enableEdit}}`); - await click('button'); - }); -}); + test('it executes a function on button click', async function (assert) { + assert.expect(1); + this.enableEdit = () => assert.ok(true, 'edit was clicked'); + await render( + hbs`{{rose/form/actions/edit-toggle enableEdit=this.enableEdit}}` + ); + await click('button'); + }); + } +); diff --git a/addons/rose/tests/test-helper.js b/addons/rose/tests/test-helper.js index 4eae06f81..4efd6e58a 100644 --- a/addons/rose/tests/test-helper.js +++ b/addons/rose/tests/test-helper.js @@ -1,8 +1,12 @@ import Application from 'dummy/app'; import config from 'dummy/config/environment'; +import * as QUnit from 'qunit'; import { setApplication } from '@ember/test-helpers'; +import { setup } from 'qunit-dom'; import { start } from 'ember-qunit'; setApplication(Application.create(config.APP)); +setup(QUnit.assert); + start(); diff --git a/package.json b/package.json index 28f76d867..7e89f60bc 100644 --- a/package.json +++ b/package.json @@ -33,7 +33,7 @@ "compliance:audit": "bash ./scripts/yarn-audit.sh", "precommit": "yarn compliance:licenses && yarn compliance:audit && yarn lint && yarn test", "commit": "git-cz", - "compliance:licenses": "license-checker --onlyAllow 'Apache*;Apache License, Version 2.0;Apache-2.0;Apache 2.0;Artistic-2.0;BSD;BSD-3-Clause;CC-BY-3.0;CC-BY-4.0;CC0-1.0;ISC;MIT;MPL-2.0;Public Domain;Unicode-TOU;Unlicense;WTFPL' --excludePackages 'boundary-ui;admin@0.0.0;desktop@0.0.0;base64-js@0.0.2;cycle@1.0.3'", + "compliance:licenses": "license-checker --onlyAllow 'Apache*;Apache License, Version 2.0;Apache-2.0;Apache 2.0;Artistic-2.0;BSD;BSD-3-Clause;CC-BY-3.0;CC-BY-4.0;CC0-1.0;ISC;MIT;MPL-2.0;Public Domain;Python-2.0;Unicode-TOU;Unlicense;WTFPL' --excludePackages 'boundary-ui;admin@0.0.0;desktop@0.0.0;base64-js@0.0.2;cycle@1.0.3'", "doc:toc": "doctoc README.md" }, "devDependencies": { @@ -55,7 +55,8 @@ "caniuse-lite": "^1.0.30001157", "immer": "^8.0.1", "node-notifier": "^8.0.1", - "highlight.js": "^10.4.1" + "highlight.js": "^10.4.1", + "hoek": "~4.2.0" }, "config": { "commitizen": { diff --git a/ui/admin/.eslintignore b/ui/admin/.eslintignore index 72df37307..922165552 100644 --- a/ui/admin/.eslintignore +++ b/ui/admin/.eslintignore @@ -13,6 +13,7 @@ # misc /coverage/ !.* +.eslintcache # ember-try /.node_modules.ember-try/ diff --git a/ui/admin/.eslintrc.js b/ui/admin/.eslintrc.js index 26d707835..5062441ff 100644 --- a/ui/admin/.eslintrc.js +++ b/ui/admin/.eslintrc.js @@ -7,47 +7,53 @@ module.exports = { ecmaVersion: 2018, sourceType: 'module', ecmaFeatures: { - legacyDecorators: true - } + legacyDecorators: true, + }, }, - plugins: [ - 'ember' - ], + plugins: ['ember'], extends: [ 'eslint:recommended', - 'plugin:ember/recommended' + 'plugin:ember/recommended', + 'plugin:prettier/recommended', ], env: { - browser: true + browser: true, + }, + rules: { + 'ember/no-get': 'off', + 'ember/no-get-with-default': 'off', + 'ember/no-computed-properties-in-native-classes': 'off', + 'ember/no-assignment-of-untracked-properties-used-in-tracking-contexts': + 'off', }, - rules: {}, overrides: [ // node files { files: [ '.eslintrc.js', + '.prettierrc.js', '.template-lintrc.js', 'ember-cli-build.js', 'testem.js', 'blueprints/*/index.js', 'config/**/*.js', 'lib/*/index.js', - 'server/**/*.js' + 'server/**/*.js', ], parserOptions: { - sourceType: 'script' + sourceType: 'script', }, env: { browser: false, - node: true + node: true, }, plugins: ['node'], extends: ['plugin:node/recommended'], rules: { // this can be removed once the following is fixed // https://github.com/mysticatea/eslint-plugin-node/issues/77 - 'node/no-unpublished-require': 'off' - } - } - ] + 'node/no-unpublished-require': 'off', + }, + }, + ], }; diff --git a/ui/admin/.prettierignore b/ui/admin/.prettierignore new file mode 100644 index 000000000..922165552 --- /dev/null +++ b/ui/admin/.prettierignore @@ -0,0 +1,21 @@ +# unconventional js +/blueprints/*/files/ +/vendor/ + +# compiled output +/dist/ +/tmp/ + +# dependencies +/bower_components/ +/node_modules/ + +# misc +/coverage/ +!.* +.eslintcache + +# ember-try +/.node_modules.ember-try/ +/bower.json.ember-try +/package.json.ember-try diff --git a/ui/admin/.prettierrc.js b/ui/admin/.prettierrc.js new file mode 100644 index 000000000..534e6d35a --- /dev/null +++ b/ui/admin/.prettierrc.js @@ -0,0 +1,5 @@ +'use strict'; + +module.exports = { + singleQuote: true, +}; diff --git a/ui/admin/.template-lintrc.js b/ui/admin/.template-lintrc.js index b887df9af..be0764215 100644 --- a/ui/admin/.template-lintrc.js +++ b/ui/admin/.template-lintrc.js @@ -4,7 +4,17 @@ module.exports = { extends: 'octane', rules: { 'no-bare-strings': true, - 'no-curly-component-invocation': { allow: ['app-name', 'company-name', 'company-copyright'] }, - 'no-implicit-this': { allow: ['app-name', 'company-name', 'company-copyright', 'doc-url', 'is-loading'] } - } + 'no-curly-component-invocation': { + allow: ['app-name', 'company-name', 'company-copyright'], + }, + 'no-implicit-this': { + allow: [ + 'app-name', + 'company-name', + 'company-copyright', + 'doc-url', + 'is-loading', + ], + }, + }, }; diff --git a/ui/admin/app/components/copyable/index.hbs b/ui/admin/app/components/copyable/index.hbs index 618f3315b..ac3474940 100644 --- a/ui/admin/app/components/copyable/index.hbs +++ b/ui/admin/app/components/copyable/index.hbs @@ -2,7 +2,7 @@ id={{this.id}} class="copyable" {{did-insert this.register}} - {{will-destroy this.destroy}} + {{will-destroy this.tearDown}} > {{#if this.copied}} diff --git a/ui/admin/app/components/copyable/index.js b/ui/admin/app/components/copyable/index.js index 17652e911..09da77365 100644 --- a/ui/admin/app/components/copyable/index.js +++ b/ui/admin/app/components/copyable/index.js @@ -36,6 +36,7 @@ export default class CopyableComponent extends Component { this.copied = true; yield timeout(1000); this.copied = false; + /* eslint-disable-next-line prettier/prettier */ }).drop() confirmCopyTimer; /** @@ -53,7 +54,7 @@ export default class CopyableComponent extends Component { */ @action register() { - this.destroy(); + this.tearDown(); /* istanbul ignore next */ this.clipboard = new ClipboardJS(`#${this.copyableButtonId}`, { text: () => this.args.text, @@ -69,7 +70,7 @@ export default class CopyableComponent extends Component { * Destroy ClipboardJS library instance and cancel icon timer. */ @action - destroy() { + tearDown() { this.clipboard?.destroy(); this.clipboard = null; this.confirmCopyTimer.cancelAll(); diff --git a/ui/admin/app/routes/scopes/scope.js b/ui/admin/app/routes/scopes/scope.js index 52799df7c..196164793 100644 --- a/ui/admin/app/routes/scopes/scope.js +++ b/ui/admin/app/routes/scopes/scope.js @@ -70,6 +70,7 @@ export default class ScopesScopeRoute extends Route { // Update the controller (if exists), since setupController is only // called once the first time the route is activated. It is not called // again on route refreshes. + /* eslint-disable-next-line ember/no-controller-access-in-routes */ if (this.controller) this.setControllerProperties(this.scopes); } @@ -87,6 +88,7 @@ export default class ScopesScopeRoute extends Route { * @param {array} scopes */ setControllerProperties(scopes) { + /* eslint-disable-next-line ember/no-controller-access-in-routes */ this.controller.setProperties({ scopes }); } diff --git a/ui/admin/app/routes/scopes/scope/auth-methods/auth-method/accounts/account/set-password.js b/ui/admin/app/routes/scopes/scope/auth-methods/auth-method/accounts/account/set-password.js index 72d2c0609..66b8b2236 100644 --- a/ui/admin/app/routes/scopes/scope/auth-methods/auth-method/accounts/account/set-password.js +++ b/ui/admin/app/routes/scopes/scope/auth-methods/auth-method/accounts/account/set-password.js @@ -2,10 +2,7 @@ import Route from '@ember/routing/route'; import { action } from '@ember/object'; import { inject as service } from '@ember/service'; import loading from 'ember-loading/decorator'; -import { - notifySuccess, - notifyError, -} from 'core/decorators/notify'; +import { notifySuccess, notifyError } from 'core/decorators/notify'; export default class ScopesScopeAuthMethodsAuthMethodAccountsAccountSettingsRoute extends Route { // =services diff --git a/ui/admin/app/routes/scopes/scope/auth-methods/new.js b/ui/admin/app/routes/scopes/scope/auth-methods/new.js index 04ab0aacf..dee0dc759 100644 --- a/ui/admin/app/routes/scopes/scope/auth-methods/new.js +++ b/ui/admin/app/routes/scopes/scope/auth-methods/new.js @@ -5,8 +5,8 @@ export default class ScopesScopeAuthMethodsNewRoute extends Route { queryParams = { type: { - refreshModel: true - } + refreshModel: true, + }, }; // =methods diff --git a/ui/admin/app/routes/scopes/scope/authenticate/method.js b/ui/admin/app/routes/scopes/scope/authenticate/method.js index cfb2c5acf..1e4c9f46a 100644 --- a/ui/admin/app/routes/scopes/scope/authenticate/method.js +++ b/ui/admin/app/routes/scopes/scope/authenticate/method.js @@ -37,12 +37,10 @@ export default class ScopesScopeAuthenticateMethodRoute extends Route { const authMethod = this.modelFor('scopes.scope.authenticate.method'); const authenticatorName = `authenticator:${authMethod.type}`; const requestCookies = false; - await this.session.authenticate( - authenticatorName, - creds, - requestCookies, - { scope, authMethod } - ); + await this.session.authenticate(authenticatorName, creds, requestCookies, { + scope, + authMethod, + }); this.transitionTo('index'); } } diff --git a/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets/host-set/add-hosts.js b/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets/host-set/add-hosts.js index b92c16814..5232404f1 100644 --- a/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets/host-set/add-hosts.js +++ b/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets/host-set/add-hosts.js @@ -3,10 +3,7 @@ import { inject as service } from '@ember/service'; import { action } from '@ember/object'; import { hash } from 'rsvp'; import loading from 'ember-loading/decorator'; -import { - notifySuccess, - notifyError, -} from 'core/decorators/notify'; +import { notifySuccess, notifyError } from 'core/decorators/notify'; export default class ScopesScopeHostCatalogsHostCatalogHostSetsHostSetAddHostsRoute extends Route { // =services diff --git a/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets/host-set/create-and-add-host.js b/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets/host-set/create-and-add-host.js index 977fc45f4..dfb871e6a 100644 --- a/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets/host-set/create-and-add-host.js +++ b/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets/host-set/create-and-add-host.js @@ -2,10 +2,7 @@ import Route from '@ember/routing/route'; import { inject as service } from '@ember/service'; import { action } from '@ember/object'; import loading from 'ember-loading/decorator'; -import { - notifySuccess, - notifyError, -} from 'core/decorators/notify'; +import { notifySuccess, notifyError } from 'core/decorators/notify'; export default class ScopesScopeHostCatalogsHostCatalogHostSetsHostSetCreateAndAddHostRoute extends Route { // =services diff --git a/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets/host-set/hosts.js b/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets/host-set/hosts.js index 5c3fbae73..b3f1a1c23 100644 --- a/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets/host-set/hosts.js +++ b/ui/admin/app/routes/scopes/scope/host-catalogs/host-catalog/host-sets/host-set/hosts.js @@ -4,10 +4,7 @@ import { action } from '@ember/object'; import { inject as service } from '@ember/service'; import loading from 'ember-loading/decorator'; import { confirm } from 'core/decorators/confirm'; -import { - notifySuccess, - notifyError, -} from 'core/decorators/notify'; +import { notifySuccess, notifyError } from 'core/decorators/notify'; export default class ScopesScopeHostCatalogsHostCatalogHostSetsHostSetHostsRoute extends Route { // =services diff --git a/ui/admin/app/routes/scopes/scope/roles/role/index.js b/ui/admin/app/routes/scopes/scope/roles/role/index.js index 24dd3c658..1f9589be7 100644 --- a/ui/admin/app/routes/scopes/scope/roles/role/index.js +++ b/ui/admin/app/routes/scopes/scope/roles/role/index.js @@ -19,7 +19,7 @@ export default class ScopesScopeRolesRoleIndexRoute extends Route { subScopes, }, ]; - this.set('grantScopes', grantScopes); + this.grantScopes = grantScopes; } /** diff --git a/ui/admin/app/routes/scopes/scope/sessions.js b/ui/admin/app/routes/scopes/scope/sessions.js index 2bcb606c1..2df7c8b4b 100644 --- a/ui/admin/app/routes/scopes/scope/sessions.js +++ b/ui/admin/app/routes/scopes/scope/sessions.js @@ -34,6 +34,7 @@ export default class ScopesScopeSessionsRoute extends Route { yield timeout(POLL_TIMEOUT_SECONDS * 1000); yield this.refresh(); } + /* eslint-disable-next-line prettier/prettier */ }).drop() poller; // =methods diff --git a/ui/admin/config/ember-cli-update.json b/ui/admin/config/ember-cli-update.json index 4c2450a37..c408f46f0 100644 --- a/ui/admin/config/ember-cli-update.json +++ b/ui/admin/config/ember-cli-update.json @@ -3,7 +3,7 @@ "packages": [ { "name": "ember-cli", - "version": "3.20.2", + "version": "3.24.0", "blueprints": [ { "name": "app", diff --git a/ui/admin/config/environment.js b/ui/admin/config/environment.js index 7cd8efa3e..fd3f8da64 100644 --- a/ui/admin/config/environment.js +++ b/ui/admin/config/environment.js @@ -81,8 +81,8 @@ module.exports = function (environment) { }, 'ember-cli-mirage': { - directory: '../../addons/api/mirage' - } + directory: '../../addons/api/mirage', + }, }; // Unsafe policy is necessary in development and test environments, but should diff --git a/ui/admin/ember-cli-build.js b/ui/admin/ember-cli-build.js index e99e80679..68a02a237 100644 --- a/ui/admin/ember-cli-build.js +++ b/ui/admin/ember-cli-build.js @@ -5,7 +5,7 @@ const EmberApp = require('ember-cli/lib/broccoli/ember-app'); module.exports = function (defaults) { let app = new EmberApp(defaults, { 'ember-cli-babel': { - includeExternalHelpers: true + includeExternalHelpers: true, }, babel: { sourceMaps: 'inline', @@ -22,10 +22,8 @@ module.exports = function (defaults) { importCss: false, }, svg: { - paths: [ - '../../addons/core/public' - ] - } + paths: ['../../addons/core/public'], + }, }); // Only import when in development or test mode diff --git a/ui/admin/package.json b/ui/admin/package.json index 9df05a650..ad2580897 100644 --- a/ui/admin/package.json +++ b/ui/admin/package.json @@ -13,13 +13,16 @@ "doc:toc": "doctoc README.md", "build:development": "ember build", "build": "ember build --environment=production", - "lint": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*", + "lint": "npm-run-all --aggregate-output --continue-on-error --parallel 'lint:!(fix)'", + "lint:fix": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*:fix", "lint:hbs": "ember-template-lint .", + "lint:hbs:fix": "ember-template-lint . --fix", "lint:js": "eslint .", "lint:sass": "sass-lint -v -q", "format": "npm-run-all format:*", "format:js": "prettier --write '{app,config,stories,tests}/**/*.js' *.js", "format:sass": "prettier --write app/**/*.scss", + "lint:js:fix": "eslint . --fix", "start": "ember serve", "clean:coverage": "rm -rf coverage_*", "pretest": "yarn clean:coverage", @@ -29,10 +32,11 @@ }, "devDependencies": { "@babel/core": "^7.9.6", - "@ember/optional-features": "^1.3.0", + "@ember/optional-features": "^2.0.0", "@ember/render-modifiers": "^1.0.2", - "@glimmer/component": "^1.0.1", - "@glimmer/tracking": "^1.0.0", + "@ember/test-helpers": "^2.1.4", + "@glimmer/component": "^1.0.3", + "@glimmer/tracking": "^1.0.3", "babel-eslint": "^10.1.0", "babel-loader": "^8.1.0", "broccoli-asset-rev": "^3.0.0", @@ -40,41 +44,45 @@ "core": "*", "doctoc": "^1.4.0", "ember-a11y-testing": "^3.0.0", - "ember-auto-import": "^1.6.0", + "ember-auto-import": "^1.10.1", "ember-breadcrumbs": "^0.2.3", - "ember-cli": "~3.20.2", - "ember-cli-app-version": "^3.2.0", - "ember-cli-babel": "^7.21.0", + "ember-cli": "~3.24.0", + "ember-cli-app-version": "^4.0.0", + "ember-cli-babel": "^7.23.0", "ember-cli-code-coverage": "^1.0.2", "ember-cli-content-security-policy": "^1.1.1", "ember-cli-dependency-checker": "^3.2.0", - "ember-cli-htmlbars": "^5.2.0", + "ember-cli-htmlbars": "^5.3.1", "ember-cli-inject-live-reload": "^2.0.2", "ember-cli-sass": "^10.0.1", "ember-cli-sri": "^2.1.1", "ember-cli-template-lint": "^2.0.2", - "ember-cli-uglify": "^3.0.0", + "ember-cli-terser": "^4.0.1", "ember-cli-update": "^0.54.6", "ember-concurrency": "^1.3.0", "ember-exam": "^6.0.1", "ember-export-application-global": "^2.0.1", "ember-inline-svg": "^1.0.0", - "ember-load-initializers": "^2.1.1", + "ember-load-initializers": "^2.1.2", "ember-maybe-import-regenerator": "^0.1.6", "ember-modifier": "^2.1.1", "ember-notify": "^6.0.0", - "ember-qunit": "^4.6.0", - "ember-resolver": "^8.0.0", - "ember-source": "~3.20.2", - "ember-template-lint": "^2.14.0", - "eslint": "^7.5.0", - "eslint-plugin-ember": "^8.9.1", + "ember-page-title": "^6.0.3", + "ember-qunit": "^5.1.1", + "ember-resolver": "^8.0.2", + "ember-source": "~3.24.0", + "ember-template-lint": "^2.15.0", + "eslint": "^7.17.0", + "eslint-config-prettier": "^7.1.0", + "eslint-plugin-ember": "^10.1.1", "eslint-plugin-node": "^11.1.0", + "eslint-plugin-prettier": "^3.3.1", "faker": "^5.1.0", "loader.js": "^4.7.0", "npm-run-all": "^4.1.5", - "prettier": "^2.1.2", - "qunit-dom": "^1.2.0", + "prettier": "^2.2.1", + "qunit": "^2.13.0", + "qunit-dom": "^1.6.0", "rose": "*", "sass": "^1.29.0", "sass-lint": "^1.13.1", diff --git a/ui/admin/tests/acceptance/accounts-test.js b/ui/admin/tests/acceptance/accounts-test.js index c12cc02a0..5b16765f8 100644 --- a/ui/admin/tests/acceptance/accounts-test.js +++ b/ui/admin/tests/acceptance/accounts-test.js @@ -79,8 +79,8 @@ module('Acceptance | accounts', function (hooks) { test('can update an account and save changes', async function (assert) { assert.expect(1); await visit(urls.account); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'update name'); - await click('form [type="button"]'); await click('form [type="submit"]:not(:disabled)'); assert.equal(this.server.db.accounts[0].name, 'update name'); }); @@ -175,8 +175,8 @@ module('Acceptance | accounts', function (hooks) { ); }); await visit(urls.account); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'save account'); - await click('form [type="button"]'); await click('form [type="submit"]'); await a11yAudit(); assert.ok( diff --git a/ui/admin/tests/acceptance/auth-methods-test.js b/ui/admin/tests/acceptance/auth-methods-test.js index bdc509df2..67e73d624 100644 --- a/ui/admin/tests/acceptance/auth-methods-test.js +++ b/ui/admin/tests/acceptance/auth-methods-test.js @@ -161,8 +161,8 @@ module('Acceptance | auth methods', function (hooks) { ); }); await visit(urls.authMethod); + await click('form [type="button"]', 'Activate edit mode'); await fillIn('[name="name"]', 'save auth method'); - await click('form [type="button"]'); await click('form [type="submit"]'); await a11yAudit(); assert.ok( diff --git a/ui/admin/tests/index.html b/ui/admin/tests/index.html index 97040205c..5591db965 100644 --- a/ui/admin/tests/index.html +++ b/ui/admin/tests/index.html @@ -21,6 +21,13 @@ {{content-for "body"}} {{content-for "test-body"}} +
+
+
+
+
+
+ diff --git a/ui/admin/tests/test-helper.js b/ui/admin/tests/test-helper.js index bc88900fc..f4950f34d 100644 --- a/ui/admin/tests/test-helper.js +++ b/ui/admin/tests/test-helper.js @@ -1,9 +1,13 @@ -import Application from '../app'; -import config from '../config/environment'; +import Application from 'admin/app'; +import config from 'admin/config/environment'; +import * as QUnit from 'qunit'; import { setApplication } from '@ember/test-helpers'; +import { setup } from 'qunit-dom'; //import { start } from 'ember-qunit'; import start from 'ember-exam/test-support/start'; setApplication(Application.create(config.APP)); +setup(QUnit.assert); + start(); diff --git a/ui/admin/tests/unit/controllers/scopes/scope/auth-methods/auth-method-test.js b/ui/admin/tests/unit/controllers/scopes/scope/auth-methods/auth-method-test.js index f9fe31d0b..f1396eba0 100644 --- a/ui/admin/tests/unit/controllers/scopes/scope/auth-methods/auth-method-test.js +++ b/ui/admin/tests/unit/controllers/scopes/scope/auth-methods/auth-method-test.js @@ -1,16 +1,17 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Controller | scopes/scope/auth-methods/auth-method', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Controller | scopes/scope/auth-methods/auth-method', + function (hooks) { + setupTest(hooks); - // Replace this with your real tests. - test('it exists', function (assert) { - let controller = this.owner.lookup( - 'controller:scopes/scope/auth-methods/auth-method' - ); - assert.ok(controller); - }); -}); + // Replace this with your real tests. + test('it exists', function (assert) { + let controller = this.owner.lookup( + 'controller:scopes/scope/auth-methods/auth-method' + ); + assert.ok(controller); + }); + } +); diff --git a/ui/admin/tests/unit/controllers/scopes/scope/groups/group/add-members-test.js b/ui/admin/tests/unit/controllers/scopes/scope/groups/group/add-members-test.js index baffc2dda..263e690aa 100644 --- a/ui/admin/tests/unit/controllers/scopes/scope/groups/group/add-members-test.js +++ b/ui/admin/tests/unit/controllers/scopes/scope/groups/group/add-members-test.js @@ -1,16 +1,17 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Controller | scopes/scope/groups/group/add-members', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Controller | scopes/scope/groups/group/add-members', + function (hooks) { + setupTest(hooks); - // Replace this with your real tests. - test('it exists', function (assert) { - let controller = this.owner.lookup( - 'controller:scopes/scope/groups/group/add-members' - ); - assert.ok(controller); - }); -}); + // Replace this with your real tests. + test('it exists', function (assert) { + let controller = this.owner.lookup( + 'controller:scopes/scope/groups/group/add-members' + ); + assert.ok(controller); + }); + } +); diff --git a/ui/admin/tests/unit/controllers/scopes/scope/groups/group/members-test.js b/ui/admin/tests/unit/controllers/scopes/scope/groups/group/members-test.js index 46dbddf58..0d8b1c81a 100644 --- a/ui/admin/tests/unit/controllers/scopes/scope/groups/group/members-test.js +++ b/ui/admin/tests/unit/controllers/scopes/scope/groups/group/members-test.js @@ -1,16 +1,17 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Controller | scopes/scope/groups/group/members', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Controller | scopes/scope/groups/group/members', + function (hooks) { + setupTest(hooks); - // TODO: Replace this with your real tests. - test('it exists', function (assert) { - let controller = this.owner.lookup( - 'controller:scopes/scope/groups/group/members' - ); - assert.ok(controller); - }); -}); + // TODO: Replace this with your real tests. + test('it exists', function (assert) { + let controller = this.owner.lookup( + 'controller:scopes/scope/groups/group/members' + ); + assert.ok(controller); + }); + } +); diff --git a/ui/admin/tests/unit/controllers/scopes/scope/host-catalogs/host-catalog-test.js b/ui/admin/tests/unit/controllers/scopes/scope/host-catalogs/host-catalog-test.js index fa1b421b7..9782d1c12 100644 --- a/ui/admin/tests/unit/controllers/scopes/scope/host-catalogs/host-catalog-test.js +++ b/ui/admin/tests/unit/controllers/scopes/scope/host-catalogs/host-catalog-test.js @@ -1,16 +1,17 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Controller | scopes/scope/host-catalogs/host-catalog', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Controller | scopes/scope/host-catalogs/host-catalog', + function (hooks) { + setupTest(hooks); - // TODO: Replace this with your real tests. - test('it exists', function (assert) { - let controller = this.owner.lookup( - 'controller:scopes/scope/host-catalogs/host-catalog' - ); - assert.ok(controller); - }); -}); + // TODO: Replace this with your real tests. + test('it exists', function (assert) { + let controller = this.owner.lookup( + 'controller:scopes/scope/host-catalogs/host-catalog' + ); + assert.ok(controller); + }); + } +); diff --git a/ui/admin/tests/unit/controllers/scopes/scope/roles/role/add-principals-test.js b/ui/admin/tests/unit/controllers/scopes/scope/roles/role/add-principals-test.js index ed13dde40..7eb851443 100644 --- a/ui/admin/tests/unit/controllers/scopes/scope/roles/role/add-principals-test.js +++ b/ui/admin/tests/unit/controllers/scopes/scope/roles/role/add-principals-test.js @@ -1,16 +1,17 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Controller | scopes/scope/roles/role/add-principals', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Controller | scopes/scope/roles/role/add-principals', + function (hooks) { + setupTest(hooks); - // Replace this with your real tests. - test('it exists', function (assert) { - let controller = this.owner.lookup( - 'controller:scopes/scope/roles/role/add-principals' - ); - assert.ok(controller); - }); -}); + // Replace this with your real tests. + test('it exists', function (assert) { + let controller = this.owner.lookup( + 'controller:scopes/scope/roles/role/add-principals' + ); + assert.ok(controller); + }); + } +); diff --git a/ui/admin/tests/unit/controllers/scopes/scope/roles/role/principals-test.js b/ui/admin/tests/unit/controllers/scopes/scope/roles/role/principals-test.js index 14de1a906..d8ad32897 100644 --- a/ui/admin/tests/unit/controllers/scopes/scope/roles/role/principals-test.js +++ b/ui/admin/tests/unit/controllers/scopes/scope/roles/role/principals-test.js @@ -1,16 +1,17 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Controller | scopes/scope/roles/role/principals', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Controller | scopes/scope/roles/role/principals', + function (hooks) { + setupTest(hooks); - // TODO: Replace this with your real tests. - test('it exists', function (assert) { - let controller = this.owner.lookup( - 'controller:scopes/scope/roles/role/principals' - ); - assert.ok(controller); - }); -}); + // TODO: Replace this with your real tests. + test('it exists', function (assert) { + let controller = this.owner.lookup( + 'controller:scopes/scope/roles/role/principals' + ); + assert.ok(controller); + }); + } +); diff --git a/ui/admin/tests/unit/controllers/scopes/scope/targets/target/host-sets-test.js b/ui/admin/tests/unit/controllers/scopes/scope/targets/target/host-sets-test.js index 1cc1b3aa1..46ca085a6 100644 --- a/ui/admin/tests/unit/controllers/scopes/scope/targets/target/host-sets-test.js +++ b/ui/admin/tests/unit/controllers/scopes/scope/targets/target/host-sets-test.js @@ -1,16 +1,17 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Controller | scopes/scope/targets/target/host-sets', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Controller | scopes/scope/targets/target/host-sets', + function (hooks) { + setupTest(hooks); - // TODO: Replace this with your real tests. - test('it exists', function (assert) { - let controller = this.owner.lookup( - 'controller:scopes/scope/targets/target/host-sets' - ); - assert.ok(controller); - }); -}); + // TODO: Replace this with your real tests. + test('it exists', function (assert) { + let controller = this.owner.lookup( + 'controller:scopes/scope/targets/target/host-sets' + ); + assert.ok(controller); + }); + } +); diff --git a/ui/admin/tests/unit/controllers/scopes/scope/users/user/accounts-test.js b/ui/admin/tests/unit/controllers/scopes/scope/users/user/accounts-test.js index f11f78bce..214b1a0a5 100644 --- a/ui/admin/tests/unit/controllers/scopes/scope/users/user/accounts-test.js +++ b/ui/admin/tests/unit/controllers/scopes/scope/users/user/accounts-test.js @@ -1,16 +1,17 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Controller | scopes/scope/users/user/accounts', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Controller | scopes/scope/users/user/accounts', + function (hooks) { + setupTest(hooks); - // TODO: Replace this with your real tests. - test('it exists', function (assert) { - let controller = this.owner.lookup( - 'controller:scopes/scope/users/user/accounts' - ); - assert.ok(controller); - }); -}); + // TODO: Replace this with your real tests. + test('it exists', function (assert) { + let controller = this.owner.lookup( + 'controller:scopes/scope/users/user/accounts' + ); + assert.ok(controller); + }); + } +); diff --git a/ui/admin/tests/unit/controllers/scopes/scope/users/user/add-accounts-test.js b/ui/admin/tests/unit/controllers/scopes/scope/users/user/add-accounts-test.js index 451f97d18..7971e808f 100644 --- a/ui/admin/tests/unit/controllers/scopes/scope/users/user/add-accounts-test.js +++ b/ui/admin/tests/unit/controllers/scopes/scope/users/user/add-accounts-test.js @@ -1,16 +1,17 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Controller | scopes/scope/users/user/add-accounts', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Controller | scopes/scope/users/user/add-accounts', + function (hooks) { + setupTest(hooks); - // Replace this with your real tests. - test('it exists', function (assert) { - let controller = this.owner.lookup( - 'controller:scopes/scope/users/user/add-accounts' - ); - assert.ok(controller); - }); -}); + // Replace this with your real tests. + test('it exists', function (assert) { + let controller = this.owner.lookup( + 'controller:scopes/scope/users/user/add-accounts' + ); + assert.ok(controller); + }); + } +); diff --git a/ui/admin/tests/unit/routes/scopes/scope/auth-methods/auth-method-test.js b/ui/admin/tests/unit/routes/scopes/scope/auth-methods/auth-method-test.js index 147a0a52b..01be4e6b1 100644 --- a/ui/admin/tests/unit/routes/scopes/scope/auth-methods/auth-method-test.js +++ b/ui/admin/tests/unit/routes/scopes/scope/auth-methods/auth-method-test.js @@ -1,15 +1,16 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/auth-methods/auth-method', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Route | scopes/scope/auth-methods/auth-method', + function (hooks) { + setupTest(hooks); - test('it exists', function (assert) { - let route = this.owner.lookup( - 'route:scopes/scope/auth-methods/auth-method' - ); - assert.ok(route); - }); -}); + test('it exists', function (assert) { + let route = this.owner.lookup( + 'route:scopes/scope/auth-methods/auth-method' + ); + assert.ok(route); + }); + } +); diff --git a/ui/admin/tests/unit/routes/scopes/scope/auth-methods/auth-method/index-test.js b/ui/admin/tests/unit/routes/scopes/scope/auth-methods/auth-method/index-test.js index 1f9e281c9..84b88453f 100644 --- a/ui/admin/tests/unit/routes/scopes/scope/auth-methods/auth-method/index-test.js +++ b/ui/admin/tests/unit/routes/scopes/scope/auth-methods/auth-method/index-test.js @@ -1,15 +1,16 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/auth-methods/auth-method/index', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Route | scopes/scope/auth-methods/auth-method/index', + function (hooks) { + setupTest(hooks); - test('it exists', function (assert) { - let route = this.owner.lookup( - 'route:scopes/scope/auth-methods/auth-method/index' - ); - assert.ok(route); - }); -}); + test('it exists', function (assert) { + let route = this.owner.lookup( + 'route:scopes/scope/auth-methods/auth-method/index' + ); + assert.ok(route); + }); + } +); diff --git a/ui/admin/tests/unit/routes/scopes/scope/groups/group/add-members-test.js b/ui/admin/tests/unit/routes/scopes/scope/groups/group/add-members-test.js index 03d00b579..065b23e40 100644 --- a/ui/admin/tests/unit/routes/scopes/scope/groups/group/add-members-test.js +++ b/ui/admin/tests/unit/routes/scopes/scope/groups/group/add-members-test.js @@ -1,15 +1,16 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/groups/group/add-members', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Route | scopes/scope/groups/group/add-members', + function (hooks) { + setupTest(hooks); - test('it exists', function (assert) { - let route = this.owner.lookup( - 'route:scopes/scope/groups/group/add-members' - ); - assert.ok(route); - }); -}); + test('it exists', function (assert) { + let route = this.owner.lookup( + 'route:scopes/scope/groups/group/add-members' + ); + assert.ok(route); + }); + } +); diff --git a/ui/admin/tests/unit/routes/scopes/scope/host-catalogs/host-catalog-test.js b/ui/admin/tests/unit/routes/scopes/scope/host-catalogs/host-catalog-test.js index 7fc517187..8766e1ba1 100644 --- a/ui/admin/tests/unit/routes/scopes/scope/host-catalogs/host-catalog-test.js +++ b/ui/admin/tests/unit/routes/scopes/scope/host-catalogs/host-catalog-test.js @@ -1,15 +1,16 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/host-catalogs/host-catalog', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Route | scopes/scope/host-catalogs/host-catalog', + function (hooks) { + setupTest(hooks); - test('it exists', function (assert) { - let route = this.owner.lookup( - 'route:scopes/scope/host-catalogs/host-catalog' - ); - assert.ok(route); - }); -}); + test('it exists', function (assert) { + let route = this.owner.lookup( + 'route:scopes/scope/host-catalogs/host-catalog' + ); + assert.ok(route); + }); + } +); diff --git a/ui/admin/tests/unit/routes/scopes/scope/roles/role/add-principals-test.js b/ui/admin/tests/unit/routes/scopes/scope/roles/role/add-principals-test.js index d70535062..d8ac4fac7 100644 --- a/ui/admin/tests/unit/routes/scopes/scope/roles/role/add-principals-test.js +++ b/ui/admin/tests/unit/routes/scopes/scope/roles/role/add-principals-test.js @@ -1,15 +1,16 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/roles/role/add-principals', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Route | scopes/scope/roles/role/add-principals', + function (hooks) { + setupTest(hooks); - test('it exists', function (assert) { - let route = this.owner.lookup( - 'route:scopes/scope/roles/role/add-principals' - ); - assert.ok(route); - }); -}); + test('it exists', function (assert) { + let route = this.owner.lookup( + 'route:scopes/scope/roles/role/add-principals' + ); + assert.ok(route); + }); + } +); diff --git a/ui/admin/tests/unit/routes/scopes/scope/targets/target/add-host-sets-test.js b/ui/admin/tests/unit/routes/scopes/scope/targets/target/add-host-sets-test.js index cc7f6a011..e2a87487e 100644 --- a/ui/admin/tests/unit/routes/scopes/scope/targets/target/add-host-sets-test.js +++ b/ui/admin/tests/unit/routes/scopes/scope/targets/target/add-host-sets-test.js @@ -1,15 +1,16 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/targets/target/add-host-sets', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Route | scopes/scope/targets/target/add-host-sets', + function (hooks) { + setupTest(hooks); - test('it exists', function (assert) { - let route = this.owner.lookup( - 'route:scopes/scope/targets/target/add-host-sets' - ); - assert.ok(route); - }); -}); + test('it exists', function (assert) { + let route = this.owner.lookup( + 'route:scopes/scope/targets/target/add-host-sets' + ); + assert.ok(route); + }); + } +); diff --git a/ui/admin/tests/unit/routes/scopes/scope/targets/target/host-sets-test.js b/ui/admin/tests/unit/routes/scopes/scope/targets/target/host-sets-test.js index 77d9430d2..214bf28b3 100644 --- a/ui/admin/tests/unit/routes/scopes/scope/targets/target/host-sets-test.js +++ b/ui/admin/tests/unit/routes/scopes/scope/targets/target/host-sets-test.js @@ -1,15 +1,16 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/targets/target/host-sets', function ( - hooks -) { - setupTest(hooks); +module( + 'Unit | Route | scopes/scope/targets/target/host-sets', + function (hooks) { + setupTest(hooks); - test('it exists', function (assert) { - let route = this.owner.lookup( - 'route:scopes/scope/targets/target/host-sets' - ); - assert.ok(route); - }); -}); + test('it exists', function (assert) { + let route = this.owner.lookup( + 'route:scopes/scope/targets/target/host-sets' + ); + assert.ok(route); + }); + } +); diff --git a/ui/desktop/.eslintignore b/ui/desktop/.eslintignore index b22d5a994..c1a086935 100644 --- a/ui/desktop/.eslintignore +++ b/ui/desktop/.eslintignore @@ -13,6 +13,7 @@ # misc /coverage/ !.* +.eslintcache # ember-try /.node_modules.ember-try/ diff --git a/ui/desktop/.eslintrc.js b/ui/desktop/.eslintrc.js index 3f6869249..6d20176b1 100644 --- a/ui/desktop/.eslintrc.js +++ b/ui/desktop/.eslintrc.js @@ -7,25 +7,31 @@ module.exports = { ecmaVersion: 2018, sourceType: 'module', ecmaFeatures: { - legacyDecorators: true - } + legacyDecorators: true, + }, }, - plugins: [ - 'ember' - ], + plugins: ['ember'], extends: [ 'eslint:recommended', - 'plugin:ember/recommended' + 'plugin:ember/recommended', + 'plugin:prettier/recommended', ], env: { - browser: true + browser: true, + }, + rules: { + 'ember/no-get': 'off', + 'ember/no-get-with-default': 'off', + 'ember/no-computed-properties-in-native-classes': 'off', + 'ember/no-assignment-of-untracked-properties-used-in-tracking-contexts': + 'off', }, - rules: {}, overrides: [ // node files { files: [ '.eslintrc.js', + '.prettierrc.js', '.template-lintrc.js', 'ember-cli-build.js', 'testem.js', @@ -33,22 +39,22 @@ module.exports = { 'blueprints/*/index.js', 'config/**/*.js', 'lib/*/index.js', - 'server/**/*.js' + 'server/**/*.js', ], parserOptions: { - sourceType: 'script' + sourceType: 'script', }, env: { browser: false, - node: true + node: true, }, plugins: ['node'], extends: ['plugin:node/recommended'], rules: { // this can be removed once the following is fixed // https://github.com/mysticatea/eslint-plugin-node/issues/77 - 'node/no-unpublished-require': 'off' - } - } - ] + 'node/no-unpublished-require': 'off', + }, + }, + ], }; diff --git a/ui/desktop/.gitignore b/ui/desktop/.gitignore index c40a1b2ab..7e0f7ddce 100644 --- a/ui/desktop/.gitignore +++ b/ui/desktop/.gitignore @@ -12,6 +12,7 @@ /.env* /.pnp* /.sass-cache +/.eslintcache /connect.lock /coverage/ /libpeerconnection.log diff --git a/ui/desktop/.prettierignore b/ui/desktop/.prettierignore new file mode 100644 index 000000000..922165552 --- /dev/null +++ b/ui/desktop/.prettierignore @@ -0,0 +1,21 @@ +# unconventional js +/blueprints/*/files/ +/vendor/ + +# compiled output +/dist/ +/tmp/ + +# dependencies +/bower_components/ +/node_modules/ + +# misc +/coverage/ +!.* +.eslintcache + +# ember-try +/.node_modules.ember-try/ +/bower.json.ember-try +/package.json.ember-try diff --git a/ui/desktop/.prettierrc.js b/ui/desktop/.prettierrc.js new file mode 100644 index 000000000..534e6d35a --- /dev/null +++ b/ui/desktop/.prettierrc.js @@ -0,0 +1,5 @@ +'use strict'; + +module.exports = { + singleQuote: true, +}; diff --git a/ui/desktop/.template-lintrc.js b/ui/desktop/.template-lintrc.js index 68511a97a..c95107553 100644 --- a/ui/desktop/.template-lintrc.js +++ b/ui/desktop/.template-lintrc.js @@ -5,6 +5,6 @@ module.exports = { rules: { 'no-bare-strings': true, 'no-curly-component-invocation': { allow: ['app-name'] }, - 'no-implicit-this': { allow: ['app-name', 'is-loading'] } - } + 'no-implicit-this': { allow: ['app-name', 'is-loading'] }, + }, }; diff --git a/ui/desktop/.travis.yml b/ui/desktop/.travis.yml new file mode 100644 index 000000000..aa771282f --- /dev/null +++ b/ui/desktop/.travis.yml @@ -0,0 +1,28 @@ +--- +language: node_js +node_js: + - "10" + +dist: xenial + +addons: + chrome: stable + +cache: + yarn: true + +env: + global: + # See https://git.io/vdao3 for details. + - JOBS=1 + +branches: + only: + - master + +before_install: + - curl -o- -L https://yarnpkg.com/install.sh | bash + - export PATH=$HOME/.yarn/bin:$PATH + +script: + - yarn test diff --git a/ui/desktop/app/components/copyable/index.hbs b/ui/desktop/app/components/copyable/index.hbs index 618f3315b..ac3474940 100644 --- a/ui/desktop/app/components/copyable/index.hbs +++ b/ui/desktop/app/components/copyable/index.hbs @@ -2,7 +2,7 @@ id={{this.id}} class="copyable" {{did-insert this.register}} - {{will-destroy this.destroy}} + {{will-destroy this.tearDown}} > {{#if this.copied}} diff --git a/ui/desktop/app/components/copyable/index.js b/ui/desktop/app/components/copyable/index.js index 3de4687ff..a30ff3aca 100644 --- a/ui/desktop/app/components/copyable/index.js +++ b/ui/desktop/app/components/copyable/index.js @@ -37,6 +37,7 @@ export default class CopyableComponent extends Component { this.copied = true; yield timeout(1000); this.copied = false; + /* eslint-disable-next-line prettier/prettier */ }).drop() confirmCopyTimer; /** @@ -66,7 +67,7 @@ export default class CopyableComponent extends Component { */ @action register() { - this.destroy(); + this.tearDown(); /* istanbul ignore next */ this.clipboard = new ClipboardJS(`#${this.copyableButtonId}`, { text: () => this.args.text, @@ -89,7 +90,7 @@ export default class CopyableComponent extends Component { * Destroy ClipboardJS library instance and cancel icon timer. */ @action - destroy() { + tearDown() { this.clipboard?.destroy(); this.clipboard = null; this.confirmCopyTimer.cancelAll(); diff --git a/ui/desktop/app/controllers/scopes/scope/authenticate.js b/ui/desktop/app/controllers/scopes/scope/authenticate.js index 93bb9beda..46ce98c66 100644 --- a/ui/desktop/app/controllers/scopes/scope/authenticate.js +++ b/ui/desktop/app/controllers/scopes/scope/authenticate.js @@ -2,7 +2,6 @@ import Controller from '@ember/controller'; import { inject as service } from '@ember/service'; export default class ScopesScopeAuthenticateController extends Controller { - // =services @service origin; diff --git a/ui/desktop/app/controllers/scopes/scope/projects/sessions/index.js b/ui/desktop/app/controllers/scopes/scope/projects/sessions/index.js index bafa6a171..439dc78c7 100644 --- a/ui/desktop/app/controllers/scopes/scope/projects/sessions/index.js +++ b/ui/desktop/app/controllers/scopes/scope/projects/sessions/index.js @@ -1,7 +1,6 @@ import Controller from '@ember/controller'; export default class ScopesScopeProjectsSessionsIndexController extends Controller { - // =attributes /** @@ -13,7 +12,8 @@ export default class ScopesScopeProjectsSessionsIndexController extends Controll const sessions = this.model; const sortedSessions = sessions // sort by created time - .sortBy('session.created_time').reverse(); + .sortBy('session.created_time') + .reverse(); return [ // then move active sessions to the top ...sortedSessions.filter((session) => session.isCancelable), @@ -21,5 +21,4 @@ export default class ScopesScopeProjectsSessionsIndexController extends Controll ...sortedSessions.filter((session) => !session.isCancelable), ]; } - } diff --git a/ui/desktop/app/controllers/scopes/scope/projects/targets/target/sessions.js b/ui/desktop/app/controllers/scopes/scope/projects/targets/target/sessions.js index 9b10b7e0d..f9ea74a2c 100644 --- a/ui/desktop/app/controllers/scopes/scope/projects/targets/target/sessions.js +++ b/ui/desktop/app/controllers/scopes/scope/projects/targets/target/sessions.js @@ -24,11 +24,9 @@ export default class ScopesScopeProjectsTargetsTargetSessionsController extends get cancelableUserSessions() { const sessions = this.sessions; const userId = this.session.data.authenticated.user_id; - const filteredSessions = - sessions.filter(session => - session.isCancelable && - session.user_id === userId - ); + const filteredSessions = sessions.filter( + (session) => session.isCancelable && session.user_id === userId + ); // Sort sessions const sortedSessions = A(filteredSessions).sortBy('created_time').reverse(); diff --git a/ui/desktop/app/initializers/origin.js b/ui/desktop/app/initializers/origin.js index 0a3abfc39..fea7a43c3 100644 --- a/ui/desktop/app/initializers/origin.js +++ b/ui/desktop/app/initializers/origin.js @@ -1,7 +1,6 @@ import { getOwner } from '@ember/application'; export function initialize(registry) { - // Lookup the application route const ApplicationRoute = registry.resolveRegistration ? registry.resolveRegistration('route:application') @@ -13,7 +12,7 @@ export function initialize(registry) { const originalBeforeModel = this.beforeModel; // Override the beforeModel hook and initialize the origin - this.beforeModel = async function() { + this.beforeModel = async function () { const origin = getOwner(this).lookup('service:origin'); return origin.updateOrigin().then( () => originalBeforeModel.apply(this, arguments), @@ -26,5 +25,5 @@ export function initialize(registry) { export default { after: 'ember-simple-auth', - initialize + initialize, }; diff --git a/ui/desktop/app/router.js b/ui/desktop/app/router.js index 0af5b7e46..041868e34 100644 --- a/ui/desktop/app/router.js +++ b/ui/desktop/app/router.js @@ -14,12 +14,12 @@ Router.map(function () { }); this.route('projects', function () { this.route('targets', function () { - this.route('target', { path: ':target_id' }, function() { + this.route('target', { path: ':target_id' }, function () { this.route('hosts'); this.route('sessions'); }); }); - this.route('sessions', function() {}); + this.route('sessions', function () {}); }); }); }); diff --git a/ui/desktop/app/routes/scopes/scope/authenticate/method.js b/ui/desktop/app/routes/scopes/scope/authenticate/method.js index f1547b90b..33b7fd324 100644 --- a/ui/desktop/app/routes/scopes/scope/authenticate/method.js +++ b/ui/desktop/app/routes/scopes/scope/authenticate/method.js @@ -37,12 +37,10 @@ export default class ScopesScopeAuthenticateMethodRoute extends Route { const authMethod = this.modelFor('scopes.scope.authenticate.method'); const authenticatorName = `authenticator:${authMethod.type}`; const requestCookies = false; - await this.session.authenticate( - authenticatorName, - creds, - requestCookies, - { scope, authMethod } - ); + await this.session.authenticate(authenticatorName, creds, requestCookies, { + scope, + authMethod, + }); this.replaceWith('index'); } } diff --git a/ui/desktop/app/routes/scopes/scope/projects.js b/ui/desktop/app/routes/scopes/scope/projects.js index e579d7efb..1f4387f70 100644 --- a/ui/desktop/app/routes/scopes/scope/projects.js +++ b/ui/desktop/app/routes/scopes/scope/projects.js @@ -38,5 +38,4 @@ export default class ScopesScopeProjectsRoute extends Route { .query('scope', { recursive: true, scope_id: 'global' }) .filter(({ isProject }) => isProject); } - } diff --git a/ui/desktop/app/routes/scopes/scope/projects/sessions.js b/ui/desktop/app/routes/scopes/scope/projects/sessions.js index 466a42767..272cf0672 100644 --- a/ui/desktop/app/routes/scopes/scope/projects/sessions.js +++ b/ui/desktop/app/routes/scopes/scope/projects/sessions.js @@ -30,6 +30,7 @@ export default class ScopesScopeProjectsSessionsRoute extends Route { yield timeout(POLL_TIMEOUT_SECONDS * 1000); yield this.refresh(); } + /* eslint-disable-next-line prettier/prettier */ }).drop() poller; // =methods diff --git a/ui/desktop/app/routes/scopes/scope/projects/sessions/index.js b/ui/desktop/app/routes/scopes/scope/projects/sessions/index.js index 85b153379..704c762f5 100644 --- a/ui/desktop/app/routes/scopes/scope/projects/sessions/index.js +++ b/ui/desktop/app/routes/scopes/scope/projects/sessions/index.js @@ -1,4 +1,3 @@ import Route from '@ember/routing/route'; -export default class ScopesScopeProjectsSessionsIndexRoute extends Route { -} +export default class ScopesScopeProjectsSessionsIndexRoute extends Route {} diff --git a/ui/desktop/app/routes/scopes/scope/projects/targets.js b/ui/desktop/app/routes/scopes/scope/projects/targets.js index 63884e634..dca07f657 100644 --- a/ui/desktop/app/routes/scopes/scope/projects/targets.js +++ b/ui/desktop/app/routes/scopes/scope/projects/targets.js @@ -34,6 +34,7 @@ export default class ScopesScopeProjectsTargetsRoute extends Route { yield timeout(POLL_TIMEOUT_SECONDS * 1000); yield this.refresh(); } + /* eslint-disable-next-line prettier/prettier */ }).drop() poller; // =methods diff --git a/ui/desktop/app/routes/scopes/scope/projects/targets/target.js b/ui/desktop/app/routes/scopes/scope/projects/targets/target.js index 3cf2343fe..0a540c12c 100644 --- a/ui/desktop/app/routes/scopes/scope/projects/targets/target.js +++ b/ui/desktop/app/routes/scopes/scope/projects/targets/target.js @@ -1,7 +1,6 @@ import Route from '@ember/routing/route'; export default class ScopesScopeProjectsTargetsTargetRoute extends Route { - // =methods /** diff --git a/ui/desktop/app/routes/scopes/scope/projects/targets/target/hosts.js b/ui/desktop/app/routes/scopes/scope/projects/targets/target/hosts.js index ef2f5a8ab..f43e8bab4 100644 --- a/ui/desktop/app/routes/scopes/scope/projects/targets/target/hosts.js +++ b/ui/desktop/app/routes/scopes/scope/projects/targets/target/hosts.js @@ -27,11 +27,9 @@ export default class ScopesScopeProjectsTargetsTargetHostsRoute extends Route { ); // Extract host ids from all host sets - const hostIds = hostSets.map(({host_ids}) => - host_ids.content.map((hostId) => - hostId.value - ) - ) + const hostIds = hostSets.map(({ host_ids }) => + host_ids.content.map((hostId) => hostId.value) + ); // Load unique hosts const uniqueHostIds = new Set(hostIds.flat()); @@ -42,7 +40,7 @@ export default class ScopesScopeProjectsTargetsTargetHostsRoute extends Route { [...uniqueHostIds].map((hostId) => this.store.findRecord('host', hostId) ) - ) - }) + ), + }); } } diff --git a/ui/desktop/app/routes/scopes/scope/projects/targets/target/index.js b/ui/desktop/app/routes/scopes/scope/projects/targets/target/index.js index 0f92ba860..82513fa81 100644 --- a/ui/desktop/app/routes/scopes/scope/projects/targets/target/index.js +++ b/ui/desktop/app/routes/scopes/scope/projects/targets/target/index.js @@ -9,5 +9,4 @@ export default class ScopesScopeProjectsTargetsTargetIndexRoute extends Route { afterModel() { this.transitionTo('scopes.scope.projects.targets.target.sessions'); } - } diff --git a/ui/desktop/app/routes/scopes/scope/projects/targets/target/sessions.js b/ui/desktop/app/routes/scopes/scope/projects/targets/target/sessions.js index 9306118c7..4f0281e2f 100644 --- a/ui/desktop/app/routes/scopes/scope/projects/targets/target/sessions.js +++ b/ui/desktop/app/routes/scopes/scope/projects/targets/target/sessions.js @@ -3,7 +3,6 @@ import { action } from '@ember/object'; import { notifySuccess, notifyError } from 'core/decorators/notify'; export default class ScopesScopeProjectsTargetsTargetSessionsRoute extends Route { - // =actions /** @@ -16,5 +15,4 @@ export default class ScopesScopeProjectsTargetsTargetSessionsRoute extends Route async cancelSession(session) { await session.cancelSession(); } - } diff --git a/ui/desktop/app/services/origin.js b/ui/desktop/app/services/origin.js index e72a738f0..a5c1f3a0e 100644 --- a/ui/desktop/app/services/origin.js +++ b/ui/desktop/app/services/origin.js @@ -4,7 +4,6 @@ import { inject as service } from '@ember/service'; import { notifyError } from 'core/decorators/notify'; export default class OriginService extends Service { - // =services @service ipc; @@ -59,11 +58,14 @@ export default class OriginService extends Service { */ async setOrigin(origin) { const originalHost = this.adapter.host; - assert(`setOrigin expects a string, you passed ${origin}`, typeof origin === 'string'); + assert( + `setOrigin expects a string, you passed ${origin}`, + typeof origin === 'string' + ); try { this.adapter.host = origin; this.rendererOrigin = origin; - if (origin !== await this.mainOrigin) { + if (origin !== (await this.mainOrigin)) { await this.ipc.invoke('setOrigin', origin); } } catch (e) { @@ -81,5 +83,4 @@ export default class OriginService extends Service { this.rendererOrigin = null; await this.ipc.invoke('resetOrigin'); } - } diff --git a/ui/desktop/app/templates/application.hbs b/ui/desktop/app/templates/application.hbs index 3bca4c490..b3750e04b 100644 --- a/ui/desktop/app/templates/application.hbs +++ b/ui/desktop/app/templates/application.hbs @@ -44,7 +44,7 @@ - + {{/if}} diff --git a/ui/desktop/config/ember-cli-update.json b/ui/desktop/config/ember-cli-update.json index 7742d41a6..6a97c18fb 100644 --- a/ui/desktop/config/ember-cli-update.json +++ b/ui/desktop/config/ember-cli-update.json @@ -3,7 +3,7 @@ "packages": [ { "name": "ember-cli", - "version": "3.20.2", + "version": "3.24.0", "blueprints": [ { "name": "app", diff --git a/ui/desktop/config/environment.js b/ui/desktop/config/environment.js index cb8bcd5cd..8e854404a 100644 --- a/ui/desktop/config/environment.js +++ b/ui/desktop/config/environment.js @@ -31,7 +31,7 @@ module.exports = function (environment) { 'ember-cli-mirage': { //enabled: ENABLE_MIRAGE, - directory: '../../addons/api/mirage' + directory: '../../addons/api/mirage', }, api: { @@ -49,9 +49,9 @@ module.exports = function (environment) { baseURL: 'https://boundaryproject.io/help/desktop', topics: { targets: '/targets', - sessions: '/sessions' - } - } + sessions: '/sessions', + }, + }, }; if (process.env.ENABLE_MIRAGE) { @@ -89,7 +89,7 @@ module.exports = function (environment) { // Use in-memory storage ENV.storage = { - memory: true + memory: true, }; } diff --git a/ui/desktop/electron-app/src/boundary-cli.js b/ui/desktop/electron-app/src/boundary-cli.js index e42255ea4..453a959df 100644 --- a/ui/desktop/electron-app/src/boundary-cli.js +++ b/ui/desktop/electron-app/src/boundary-cli.js @@ -18,7 +18,6 @@ const escapeAndValidateBase62 = (str) => { }; module.exports = { - // Check boundary cli existence exists: () => Boolean(cliPath()), @@ -27,7 +26,7 @@ module.exports = { const addr = origin.origin; const sanitized = { target_id: escapeAndValidateBase62(target_id), - token: escapeAndValidateBase62(token) + token: escapeAndValidateBase62(token), }; if (host_id) sanitized.host_id = escapeAndValidateBase62(host_id); const command = [ @@ -35,16 +34,16 @@ module.exports = { `-target-id=${sanitized.target_id}`, `-token=${sanitized.token}`, `-addr=${addr}`, - '-format=json' + '-format=json', ]; - if (host_id) command.push(`-host-id=${sanitized.host_id}`) + if (host_id) command.push(`-host-id=${sanitized.host_id}`); return spawnAsyncJSONPromise(command); }, // Returns JSON-formatted version information from the CLI version: () => { - const command = [ '-v' ]; + const command = ['-v']; const rawOutput = spawnSync(command); let gitRevision = /Git Revision:\s*(?.*)\n/.exec(rawOutput); let versionNumber = /Version Number:\s*(?.*)\n/.exec(rawOutput); @@ -55,6 +54,5 @@ module.exports = { : `CLI Commit: ${gitRevision}`; return { gitRevision, versionNumber, formatted }; return rawOutput; - } - -} + }, +}; diff --git a/ui/desktop/electron-app/src/content-security-policy.js b/ui/desktop/electron-app/src/content-security-policy.js index 41bd1e148..6f5156bb6 100644 --- a/ui/desktop/electron-app/src/content-security-policy.js +++ b/ui/desktop/electron-app/src/content-security-policy.js @@ -20,8 +20,8 @@ const enableDevCSP = () => { csp['style-src'].push("'unsafe-inline'"); csp['script-src'].push("'unsafe-eval'"); csp['script-src'].push("'unsafe-inline'"); - csp['script-src'].push("http://localhost:7020"); - csp['connect-src'].push("ws://localhost:7020"); + csp['script-src'].push('http://localhost:7020'); + csp['connect-src'].push('ws://localhost:7020'); }; const generateCSPHeader = () => { @@ -33,14 +33,13 @@ const generateCSPHeader = () => { policy['connect-src'].push(origin.origin); } - return Object - .keys(policy) - .map(key => `${key} ${policy[key].join(' ')};`) + return Object.keys(policy) + .map((key) => `${key} ${policy[key].join(' ')};`) .join(' '); -} +}; if (isDev) enableDevCSP(); module.exports = { - generateCSPHeader: generateCSPHeader + generateCSPHeader: generateCSPHeader, }; diff --git a/ui/desktop/electron-app/src/index.js b/ui/desktop/electron-app/src/index.js index 3a9e42607..bbe22a1d8 100644 --- a/ui/desktop/electron-app/src/index.js +++ b/ui/desktop/electron-app/src/index.js @@ -4,7 +4,14 @@ const { default: installExtension, EMBER_INSPECTOR, } = require('electron-devtools-installer'); -const { session, app, protocol, BrowserWindow, ipcMain, Menu } = require('electron'); +const { + session, + app, + protocol, + BrowserWindow, + ipcMain, + Menu, +} = require('electron'); require('./handlers.js'); const origin = require('./origin.js'); @@ -63,7 +70,8 @@ app.on('ready', async () => { // Disallow all permissions requests originating outside of serve://boundary, // per Electronegativity PERMISSION_REQUEST_HANDLER_GLOBAL_CHECK ses.setPermissionRequestHandler((webContents, permission, callback) => { - if (webContents.getURL().startsWith('serve://boundary')) return callback(false); + if (webContents.getURL().startsWith('serve://boundary')) + return callback(false); return callback(true); }); @@ -72,8 +80,8 @@ app.on('ready', async () => { callback({ responseHeaders: { ...details.responseHeaders, - 'Content-Security-Policy': [generateCSPHeader()] - } + 'Content-Security-Policy': [generateCSPHeader()], + }, }); }); @@ -91,7 +99,7 @@ app.on('ready', async () => { } // Configure menu in prod env - if(!isDev) { + if (!isDev) { const menuTemplate = Menu.buildFromTemplate(menu.generateMenuTemplate()); Menu.setApplicationMenu(menuTemplate); } @@ -109,7 +117,7 @@ app.on('ready', async () => { enableRemoteModule: false, allowRunningInsecureContent: false, preload: preloadPath, - disableBlinkFeatures: 'Auxclick' + disableBlinkFeatures: 'Auxclick', }, }); diff --git a/ui/desktop/electron-app/src/ipc-handler.js b/ui/desktop/electron-app/src/ipc-handler.js index 84122de1d..82cf76e19 100644 --- a/ui/desktop/electron-app/src/ipc-handler.js +++ b/ui/desktop/electron-app/src/ipc-handler.js @@ -1,10 +1,9 @@ const { ipcMain } = require('electron'); const isDev = require('electron-is-dev'); -const log = (method, request='', response='', type='log') => { - const requestString = typeof request === 'object' - ? JSON.stringify(request) - : request; +const log = (method, request = '', response = '', type = 'log') => { + const requestString = + typeof request === 'object' ? JSON.stringify(request) : request; // only log in dev mode if (isDev) { console[type]( @@ -15,7 +14,7 @@ const log = (method, request='', response='', type='log') => { } }; -module.exports = function handle (command, handler) { +module.exports = function handle(command, handler) { ipcMain.handle(command, async function (event, request) { const requestPayload = request; let result; @@ -26,7 +25,7 @@ module.exports = function handle (command, handler) { // If e is an Error instance, we need to extract the message and wrap // it in a POJO before stringifying it. If not an Error, e is assumed to // be already a POJO. - const errorMessage = (e instanceof Error) ? { message: e.message } : e; + const errorMessage = e instanceof Error ? { message: e.message } : e; result = new Error(JSON.stringify(errorMessage)); log(command, requestPayload, e, 'error'); } diff --git a/ui/desktop/electron-app/src/menu.js b/ui/desktop/electron-app/src/menu.js index 1047bb8a6..4a863826f 100644 --- a/ui/desktop/electron-app/src/menu.js +++ b/ui/desktop/electron-app/src/menu.js @@ -1,4 +1,4 @@ -const { shell } = require('electron') +const { shell } = require('electron'); const generateMenuTemplate = () => { return [ @@ -14,15 +14,13 @@ const generateMenuTemplate = () => { { role: 'hideothers' }, { role: 'unhide' }, { type: 'separator' }, - { role: 'quit' } - ] + { role: 'quit' }, + ], }, // { role: 'fileMenu' } { label: 'File', - submenu: [ - { role: 'close' } - ] + submenu: [{ role: 'close' }], }, // { role: 'editMenu' } { @@ -40,12 +38,9 @@ const generateMenuTemplate = () => { { type: 'separator' }, { label: 'Speech', - submenu: [ - { role: 'startSpeaking' }, - { role: 'stopSpeaking' } - ] - } - ] + submenu: [{ role: 'startSpeaking' }, { role: 'stopSpeaking' }], + }, + ], }, // { role: 'viewMenu' } { @@ -57,8 +52,8 @@ const generateMenuTemplate = () => { { role: 'zoomIn' }, { role: 'zoomOut' }, { type: 'separator' }, - { role: 'togglefullscreen' } - ] + { role: 'togglefullscreen' }, + ], }, // { role: 'windowMenu' } { @@ -69,21 +64,21 @@ const generateMenuTemplate = () => { { type: 'separator' }, { role: 'front' }, { type: 'separator' }, - { role: 'window' } - ] + { role: 'window' }, + ], }, { role: 'help', submenu: [ { label: 'Documentation', - click: () => shell.openExternal('https://www.boundaryproject.io') - } - ] - } - ] -} + click: () => shell.openExternal('https://www.boundaryproject.io'), + }, + ], + }, + ]; +}; module.exports = { - generateMenuTemplate: generateMenuTemplate + generateMenuTemplate: generateMenuTemplate, }; diff --git a/ui/desktop/electron-app/src/origin.js b/ui/desktop/electron-app/src/origin.js index cdb640cd2..5cc150c32 100644 --- a/ui/desktop/electron-app/src/origin.js +++ b/ui/desktop/electron-app/src/origin.js @@ -1,27 +1,27 @@ -const { net } = require('electron') +const { net } = require('electron'); const requestTimeoutSeconds = 10; // Simple promise wrapper around Electron's net.request feature. // https://www.electronjs.org/docs/api/client-request -const netRequestPromise = url => new Promise((resolve, reject) => { - try { - const request = net.request(url); - // We don't worry about canceling the request timeout timer once a - // request ends because: request.abort() has no effect after a request - // ends and the promise will already have been completed, so a rejection - // has no effect either. - const requestTimeout = - setTimeout(() => { +const netRequestPromise = (url) => + new Promise((resolve, reject) => { + try { + const request = net.request(url); + // We don't worry about canceling the request timeout timer once a + // request ends because: request.abort() has no effect after a request + // ends and the promise will already have been completed, so a rejection + // has no effect either. + const requestTimeout = setTimeout(() => { request.abort(); reject(new Error('Request timeout')); }, requestTimeoutSeconds * 1000); - request.on('error', reject); - request.on('response', resolve); - request.end(); - } catch (e) { - reject(e); - } -}); + request.on('error', reject); + request.on('response', resolve); + request.end(); + } catch (e) { + reject(e); + } + }); // Provides a singleton class instance to enable a consistent view of // runtime settings across the application. @@ -30,7 +30,6 @@ const netRequestPromise = url => new Promise((resolve, reject) => { // set up at runtime. For example, the Boundary origin is a runtime setting. class RuntimeSettings { - // Internal private origin is exposed via getter/setter below. #origin = undefined; @@ -38,7 +37,9 @@ class RuntimeSettings { * The user-specified Boundary origin, which should be allowed by CSP. * @type {?string} */ - get origin() { return this.#origin; } + get origin() { + return this.#origin; + } set origin(origin) { if (this.#origin !== origin) { this.#origin = origin; @@ -79,7 +80,7 @@ class RuntimeSettings { } triggerOriginChanged() { - this.#originWatchers.forEach(fn => fn(this.#origin)); + this.#originWatchers.forEach((fn) => fn(this.#origin)); } } diff --git a/ui/desktop/electron-app/src/spawn-promise.js b/ui/desktop/electron-app/src/spawn-promise.js index 47afae96d..d73390f02 100644 --- a/ui/desktop/electron-app/src/spawn-promise.js +++ b/ui/desktop/electron-app/src/spawn-promise.js @@ -5,13 +5,13 @@ const boundaryPath = path.resolve(__dirname, '..', 'cli', 'boundary'); // Convert to json const jsonify = (data) => { - if(typeof data !== 'string') data = JSON.stringify(data); + if (typeof data !== 'string') data = JSON.stringify(data); try { return JSON.parse(data); } catch (e) { // Ignore parse errors } -} +}; // You can throw exceptions, or allow them to occur, and this is supported. // Exceptions thrown in this way will be returned to the UI as an @@ -28,7 +28,6 @@ const jsonify = (data) => { // helpful message for users, so it's recommended to craft nice // POJO representation and throw it or promise->reject it. module.exports = { - /** * Spawns an asynchronous child process that is expected to output JSON * data on either stdout or stderr. The process is allowed to continue @@ -67,6 +66,5 @@ module.exports = { const childProcess = spawnSync(boundaryPath, command); const rawOutput = childProcess.output.toString(); return rawOutput; - } - + }, }; diff --git a/ui/desktop/ember-cli-build.js b/ui/desktop/ember-cli-build.js index 7cd77f5c0..2bec26235 100644 --- a/ui/desktop/ember-cli-build.js +++ b/ui/desktop/ember-cli-build.js @@ -5,7 +5,7 @@ const EmberApp = require('ember-cli/lib/broccoli/ember-app'); module.exports = function (defaults) { let app = new EmberApp(defaults, { 'ember-cli-babel': { - includeExternalHelpers: true + includeExternalHelpers: true, }, babel: { sourceMaps: 'inline', diff --git a/ui/desktop/package.json b/ui/desktop/package.json index e63f6435a..21aa5f5e1 100644 --- a/ui/desktop/package.json +++ b/ui/desktop/package.json @@ -15,20 +15,23 @@ "build:development": "ember build", "prebuild:desktop": "cp -r dist/ electron-app/ember-dist/", "build:desktop": "cd electron-app && yarn make", - "lint": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*", + "lint": "npm-run-all --aggregate-output --continue-on-error --parallel 'lint:!(fix)'", + "lint:fix": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*:fix", "lint:hbs": "ember-template-lint .", + "lint:hbs:fix": "ember-template-lint . --fix", "lint:js": "eslint .", "lint:sass": "stylelint '**/*.scss'", "lint:electron": "electronegativity -r -i ./electron-app", "format": "npm-run-all format:*", "format:js": "prettier --write '{app,config,stories,tests,electron-app/src}/**/*.js' *.js", "format:sass": "prettier --write app/**/*.scss", + "lint:js:fix": "eslint . --fix", "start": "ember serve", "prestart:desktop": "cd electron-app && yarn build:cli", "start:desktop": "ember electron", "clean:coverage": "rm -rf coverage_*", "pretest": "yarn clean:coverage", - "test": "npm-run-all test:*", + "test": "npm-run-all lint test:*", "test:ember": "COVERAGE=true ember exam --random", "postinstall": "cd electron-app && yarn install", "posttest": "ember coverage-merge && yarn clean:coverage" @@ -36,50 +39,55 @@ "devDependencies": { "@doyensec/electronegativity": "^1.7.0", "@ember/jquery": "^1.1.0", - "@ember/optional-features": "^1.3.0", + "@ember/optional-features": "^2.0.0", "@ember/render-modifiers": "^1.0.2", - "@glimmer/component": "^1.0.1", - "@glimmer/tracking": "^1.0.0", + "@ember/test-helpers": "^2.1.4", + "@glimmer/component": "^1.0.3", + "@glimmer/tracking": "^1.0.3", "babel-eslint": "^10.1.0", "babel-loader": "^8.1.0", "broccoli-asset-rev": "^3.0.0", "clipboard": "^2.0.6", "core": "*", "doctoc": "^1.4.0", - "ember-auto-import": "^1.6.0", + "ember-auto-import": "^1.10.1", "ember-autofocus-modifier": "^1.1.0", - "ember-cli": "~3.20.2", - "ember-cli-app-version": "^3.2.0", - "ember-cli-babel": "^7.21.0", + "ember-cli": "~3.24.0", + "ember-cli-app-version": "^4.0.0", + "ember-cli-babel": "^7.23.0", "ember-cli-code-coverage": "^1.0.2", "ember-cli-dependency-checker": "^3.2.0", - "ember-cli-htmlbars": "^5.2.0", + "ember-cli-htmlbars": "^5.3.1", "ember-cli-inject-live-reload": "^2.0.2", "ember-cli-sass": "^10.0.1", "ember-cli-sri": "^2.1.1", "ember-cli-template-lint": "^2.0.2", - "ember-cli-uglify": "^3.0.0", + "ember-cli-terser": "^4.0.1", "ember-concurrency": "^1.3.0", "ember-electron": "https://github.com/adopted-ember-addons/ember-electron#v3.0.0-beta.4", "ember-exam": "^6.0.1", "ember-export-application-global": "^2.0.1", "ember-inline-svg": "^1.0.0", - "ember-load-initializers": "^2.1.1", + "ember-load-initializers": "^2.1.2", "ember-maybe-import-regenerator": "^0.1.6", "ember-modifier": "^2.1.1", "ember-notify": "^6.0.0", - "ember-qunit": "^4.6.0", - "ember-resolver": "^8.0.0", - "ember-source": "~3.20.2", - "ember-template-lint": "^2.14.0", - "eslint": "^7.5.0", - "eslint-plugin-ember": "^8.9.1", + "ember-page-title": "^6.0.3", + "ember-qunit": "^5.1.1", + "ember-resolver": "^8.0.2", + "ember-source": "~3.24.0", + "ember-template-lint": "^2.15.0", + "eslint": "^7.17.0", + "eslint-config-prettier": "^7.1.0", + "eslint-plugin-ember": "^10.1.1", "eslint-plugin-node": "^11.1.0", + "eslint-plugin-prettier": "^3.3.1", "faker": "^5.1.0", "loader.js": "^4.7.0", "npm-run-all": "^4.1.5", - "prettier": "^2.1.2", - "qunit-dom": "^1.2.0", + "prettier": "^2.2.1", + "qunit": "^2.13.0", + "qunit-dom": "^1.6.0", "rose": "*", "sass": "^1.29.0", "sinon": "^9.2.1", diff --git a/ui/desktop/tests/acceptance/authentication-test.js b/ui/desktop/tests/acceptance/authentication-test.js index d0f0e3fa6..a436b4b54 100644 --- a/ui/desktop/tests/acceptance/authentication-test.js +++ b/ui/desktop/tests/acceptance/authentication-test.js @@ -166,7 +166,7 @@ module('Acceptance | authentication', function (hooks) { authenticateSession({ scope: { id: instances.scopes.global.id, - type: instances.scopes.global.type + type: instances.scopes.global.type, }, }); later(async () => { diff --git a/ui/desktop/tests/index.html b/ui/desktop/tests/index.html index d6b5581a4..8653a5598 100644 --- a/ui/desktop/tests/index.html +++ b/ui/desktop/tests/index.html @@ -21,6 +21,13 @@ {{content-for "body"}} {{content-for "test-body"}} +
+
+
+
+
+
+ diff --git a/ui/desktop/tests/integration/components/branded-card-test.js b/ui/desktop/tests/integration/components/branded-card-test.js index 35e7cdaf5..019103ec5 100644 --- a/ui/desktop/tests/integration/components/branded-card-test.js +++ b/ui/desktop/tests/integration/components/branded-card-test.js @@ -3,10 +3,10 @@ import { setupRenderingTest } from 'ember-qunit'; import { render } from '@ember/test-helpers'; import { hbs } from 'ember-cli-htmlbars'; -module('Integration | Component | branded-card', function(hooks) { +module('Integration | Component | branded-card', function (hooks) { setupRenderingTest(hooks); - test('it renders', async function(assert) { + test('it renders', async function (assert) { // Set any properties with this.set('myProperty', 'value'); // Handle any actions with this.set('myAction', function(val) { ... }); diff --git a/ui/desktop/tests/test-helper.js b/ui/desktop/tests/test-helper.js index 0382a848d..e2d6cc5a0 100644 --- a/ui/desktop/tests/test-helper.js +++ b/ui/desktop/tests/test-helper.js @@ -1,8 +1,12 @@ -import Application from '../app'; -import config from '../config/environment'; +import Application from 'desktop/app'; +import config from 'desktop/config/environment'; +import * as QUnit from 'qunit'; import { setApplication } from '@ember/test-helpers'; +import { setup } from 'qunit-dom'; import { start } from 'ember-qunit'; setApplication(Application.create(config.APP)); +setup(QUnit.assert); + start(); diff --git a/ui/desktop/tests/unit/controllers/scopes/scope/projects/sessions/index-test.js b/ui/desktop/tests/unit/controllers/scopes/scope/projects/sessions/index-test.js index 1a9f45f78..d34ff4736 100644 --- a/ui/desktop/tests/unit/controllers/scopes/scope/projects/sessions/index-test.js +++ b/ui/desktop/tests/unit/controllers/scopes/scope/projects/sessions/index-test.js @@ -1,12 +1,17 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Controller | scopes/scope/projects/sessions/index', function(hooks) { - setupTest(hooks); +module( + 'Unit | Controller | scopes/scope/projects/sessions/index', + function (hooks) { + setupTest(hooks); - // TODO: Replace this with your real tests. - test('it exists', function(assert) { - let controller = this.owner.lookup('controller:scopes/scope/projects/sessions/index'); - assert.ok(controller); - }); -}); + // TODO: Replace this with your real tests. + test('it exists', function (assert) { + let controller = this.owner.lookup( + 'controller:scopes/scope/projects/sessions/index' + ); + assert.ok(controller); + }); + } +); diff --git a/ui/desktop/tests/unit/controllers/scopes/scope/projects/targets/target/sessions-test.js b/ui/desktop/tests/unit/controllers/scopes/scope/projects/targets/target/sessions-test.js index f869024f9..456cd78ae 100644 --- a/ui/desktop/tests/unit/controllers/scopes/scope/projects/targets/target/sessions-test.js +++ b/ui/desktop/tests/unit/controllers/scopes/scope/projects/targets/target/sessions-test.js @@ -1,12 +1,17 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Controller | scopes/scope/projects/targets/target/sessions', function(hooks) { - setupTest(hooks); +module( + 'Unit | Controller | scopes/scope/projects/targets/target/sessions', + function (hooks) { + setupTest(hooks); - // TODO: Replace this with your real tests. - test('it exists', function(assert) { - let controller = this.owner.lookup('controller:scopes/scope/projects/targets/target/sessions'); - assert.ok(controller); - }); -}); + // TODO: Replace this with your real tests. + test('it exists', function (assert) { + let controller = this.owner.lookup( + 'controller:scopes/scope/projects/targets/target/sessions' + ); + assert.ok(controller); + }); + } +); diff --git a/ui/desktop/tests/unit/routes/scopes/scope/projects/sessions-test.js b/ui/desktop/tests/unit/routes/scopes/scope/projects/sessions-test.js index 358be9959..51481a29d 100644 --- a/ui/desktop/tests/unit/routes/scopes/scope/projects/sessions-test.js +++ b/ui/desktop/tests/unit/routes/scopes/scope/projects/sessions-test.js @@ -1,10 +1,10 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/projects/sessions', function(hooks) { +module('Unit | Route | scopes/scope/projects/sessions', function (hooks) { setupTest(hooks); - test('it exists', function(assert) { + test('it exists', function (assert) { let route = this.owner.lookup('route:scopes/scope/projects/sessions'); assert.ok(route); }); diff --git a/ui/desktop/tests/unit/routes/scopes/scope/projects/sessions/index-test.js b/ui/desktop/tests/unit/routes/scopes/scope/projects/sessions/index-test.js index 5c63b65eb..72c1e5966 100644 --- a/ui/desktop/tests/unit/routes/scopes/scope/projects/sessions/index-test.js +++ b/ui/desktop/tests/unit/routes/scopes/scope/projects/sessions/index-test.js @@ -1,10 +1,10 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/projects/sessions/index', function(hooks) { +module('Unit | Route | scopes/scope/projects/sessions/index', function (hooks) { setupTest(hooks); - test('it exists', function(assert) { + test('it exists', function (assert) { let route = this.owner.lookup('route:scopes/scope/projects/sessions/index'); assert.ok(route); }); diff --git a/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target-test.js b/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target-test.js index 7794f4aa7..0a3e5d110 100644 --- a/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target-test.js +++ b/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target-test.js @@ -1,10 +1,10 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/projects/targets/target', function(hooks) { +module('Unit | Route | scopes/scope/projects/targets/target', function (hooks) { setupTest(hooks); - test('it exists', function(assert) { + test('it exists', function (assert) { let route = this.owner.lookup('route:scopes/scope/projects/targets/target'); assert.ok(route); }); diff --git a/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target/hosts-test.js b/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target/hosts-test.js index e28f35db7..906e8dd65 100644 --- a/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target/hosts-test.js +++ b/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target/hosts-test.js @@ -1,11 +1,16 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/projects/targets/target/hosts', function(hooks) { - setupTest(hooks); +module( + 'Unit | Route | scopes/scope/projects/targets/target/hosts', + function (hooks) { + setupTest(hooks); - test('it exists', function(assert) { - let route = this.owner.lookup('route:scopes/scope/projects/targets/target/hosts'); - assert.ok(route); - }); -}); + test('it exists', function (assert) { + let route = this.owner.lookup( + 'route:scopes/scope/projects/targets/target/hosts' + ); + assert.ok(route); + }); + } +); diff --git a/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target/index-test.js b/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target/index-test.js index d097986e4..a59d6163c 100644 --- a/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target/index-test.js +++ b/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target/index-test.js @@ -1,11 +1,16 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/projects/targets/target/index', function(hooks) { - setupTest(hooks); +module( + 'Unit | Route | scopes/scope/projects/targets/target/index', + function (hooks) { + setupTest(hooks); - test('it exists', function(assert) { - let route = this.owner.lookup('route:scopes/scope/projects/targets/target/index'); - assert.ok(route); - }); -}); + test('it exists', function (assert) { + let route = this.owner.lookup( + 'route:scopes/scope/projects/targets/target/index' + ); + assert.ok(route); + }); + } +); diff --git a/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target/sessions-test.js b/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target/sessions-test.js index 2208beec8..705c38be0 100644 --- a/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target/sessions-test.js +++ b/ui/desktop/tests/unit/routes/scopes/scope/projects/targets/target/sessions-test.js @@ -1,11 +1,16 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Route | scopes/scope/projects/targets/target/sessions', function(hooks) { - setupTest(hooks); +module( + 'Unit | Route | scopes/scope/projects/targets/target/sessions', + function (hooks) { + setupTest(hooks); - test('it exists', function(assert) { - let route = this.owner.lookup('route:scopes/scope/projects/targets/target/sessions'); - assert.ok(route); - }); -}); + test('it exists', function (assert) { + let route = this.owner.lookup( + 'route:scopes/scope/projects/targets/target/sessions' + ); + assert.ok(route); + }); + } +); diff --git a/ui/desktop/tests/unit/services/ipc-test.js b/ui/desktop/tests/unit/services/ipc-test.js index f9c262130..a892ccccc 100644 --- a/ui/desktop/tests/unit/services/ipc-test.js +++ b/ui/desktop/tests/unit/services/ipc-test.js @@ -58,13 +58,13 @@ module('Unit | Service | ipc', function (hooks) { assert.expect(1); const stringifiedPayload = JSON.stringify({ foo: 'bar', - test: 42 + test: 42, }); const myWindow = { postMessage(request, origin, [port]) { // Post back an error on the response port port.postMessage(new Error(stringifiedPayload)); - } + }, }; try { await new IPCRequest('hello', 'world', myWindow); diff --git a/ui/desktop/tests/unit/services/origin-test.js b/ui/desktop/tests/unit/services/origin-test.js index c133a53a5..1355719a2 100644 --- a/ui/desktop/tests/unit/services/origin-test.js +++ b/ui/desktop/tests/unit/services/origin-test.js @@ -1,11 +1,11 @@ import { module, test } from 'qunit'; import { setupTest } from 'ember-qunit'; -module('Unit | Service | origin', function(hooks) { +module('Unit | Service | origin', function (hooks) { setupTest(hooks); // TODO: Replace this with your real tests. - test('it exists', function(assert) { + test('it exists', function (assert) { let service = this.owner.lookup('service:origin'); assert.ok(service); }); diff --git a/yarn.lock b/yarn.lock index 6a5062c2b..472e735d2 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,6 +2,13 @@ # yarn lockfile v1 +"@babel/code-frame@7.12.11", "@babel/code-frame@^7.0.0", "@babel/code-frame@^7.10.4", "@babel/code-frame@^7.12.11", "@babel/code-frame@^7.5.5": + version "7.12.11" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.12.11.tgz#f4ad435aa263db935b8f10f2c552d23fb716a63f" + integrity sha512-Zt1yodBx1UcyiePMSkWnU4hPqhwq7hGi2nFL1LeA3EUl+q2LQx16MISgJ0+z7dnmgvP9QtIleuETGOiOH1RcIw== + dependencies: + "@babel/highlight" "^7.10.4" + "@babel/code-frame@7.8.3": version "7.8.3" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.8.3.tgz#33e25903d7481181534e12ec0a25f16b6fcf419e" @@ -9,18 +16,23 @@ dependencies: "@babel/highlight" "^7.8.3" -"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.10.4", "@babel/code-frame@^7.12.11", "@babel/code-frame@^7.5.5": - version "7.12.11" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.12.11.tgz#f4ad435aa263db935b8f10f2c552d23fb716a63f" - integrity sha512-Zt1yodBx1UcyiePMSkWnU4hPqhwq7hGi2nFL1LeA3EUl+q2LQx16MISgJ0+z7dnmgvP9QtIleuETGOiOH1RcIw== +"@babel/code-frame@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.12.13.tgz#dcfc826beef65e75c50e21d3837d7d95798dd658" + integrity sha512-HV1Cm0Q3ZrpCR93tkWOYiuYIgLxZXZFVG2VgK+MBWjUqZTundupbfx2aXarXuw5Ko5aMcjtJgbSs4vUGBS5v6g== dependencies: - "@babel/highlight" "^7.10.4" + "@babel/highlight" "^7.12.13" "@babel/compat-data@^7.12.5", "@babel/compat-data@^7.12.7": version "7.12.7" resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.12.7.tgz#9329b4782a7d6bbd7eef57e11addf91ee3ef1e41" integrity sha512-YaxPMGs/XIWtYqrdEOZOCPsVWfEoriXopnsz3/i7apYPXQ3698UFhS6dVT1KN5qOsWmVgw/FOrmQgpRaZayGsw== +"@babel/compat-data@^7.13.8": + version "7.13.8" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.13.8.tgz#5b783b9808f15cef71547f1b691f34f8ff6003a6" + integrity sha512-EaI33z19T4qN3xLXsGf48M2cDqa6ei9tPZlfLdb2HC+e/cFtREiRd8hdSqDbwdLB0/+gLwqJmCYASH0z2bUdog== + "@babel/core@7.12.9": version "7.12.9" resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.12.9.tgz#fd450c4ec10cdbb980e2928b7aa7a28484593fc8" @@ -64,6 +76,28 @@ semver "^5.4.1" source-map "^0.5.0" +"@babel/core@^7.12.9": + version "7.13.8" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.13.8.tgz#c191d9c5871788a591d69ea1dc03e5843a3680fb" + integrity sha512-oYapIySGw1zGhEFRd6lzWNLWFX2s5dA/jm+Pw/+59ZdXtjyIuwlXbrId22Md0rgZVop+aVoqow2riXhBLNyuQg== + dependencies: + "@babel/code-frame" "^7.12.13" + "@babel/generator" "^7.13.0" + "@babel/helper-compilation-targets" "^7.13.8" + "@babel/helper-module-transforms" "^7.13.0" + "@babel/helpers" "^7.13.0" + "@babel/parser" "^7.13.4" + "@babel/template" "^7.12.13" + "@babel/traverse" "^7.13.0" + "@babel/types" "^7.13.0" + convert-source-map "^1.7.0" + debug "^4.1.0" + gensync "^1.0.0-beta.2" + json5 "^2.1.2" + lodash "^4.17.19" + semver "^6.3.0" + source-map "^0.5.0" + "@babel/generator@^7.12.1", "@babel/generator@^7.12.10", "@babel/generator@^7.12.11", "@babel/generator@^7.12.5": version "7.12.11" resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.12.11.tgz#98a7df7b8c358c9a37ab07a24056853016aba3af" @@ -73,6 +107,15 @@ jsesc "^2.5.1" source-map "^0.5.0" +"@babel/generator@^7.13.0": + version "7.13.9" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.13.9.tgz#3a7aa96f9efb8e2be42d38d80e2ceb4c64d8de39" + integrity sha512-mHOOmY0Axl/JCTkxTU6Lf5sWOg/v8nUa+Xkt4zMTftX0wqmb6Sh7J8gvcehBw7q0AhrhAR+FDacKjCZ2X8K+Sw== + dependencies: + "@babel/types" "^7.13.0" + jsesc "^2.5.1" + source-map "^0.5.0" + "@babel/helper-annotate-as-pure@^7.10.4", "@babel/helper-annotate-as-pure@^7.12.10": version "7.12.10" resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.12.10.tgz#54ab9b000e60a93644ce17b3f37d313aaf1d115d" @@ -98,6 +141,16 @@ browserslist "^4.14.5" semver "^5.5.0" +"@babel/helper-compilation-targets@^7.13.8": + version "7.13.8" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.13.8.tgz#02bdb22783439afb11b2f009814bdd88384bd468" + integrity sha512-pBljUGC1y3xKLn1nrx2eAhurLMA8OqBtBP/JwG4U8skN7kf8/aqwwxpV1N6T0e7r6+7uNitIa/fUxPFagSXp3A== + dependencies: + "@babel/compat-data" "^7.13.8" + "@babel/helper-validator-option" "^7.12.17" + browserslist "^4.14.5" + semver "^6.3.0" + "@babel/helper-create-class-features-plugin@^7.12.1", "@babel/helper-create-class-features-plugin@^7.5.5", "@babel/helper-create-class-features-plugin@^7.8.3": version "7.12.1" resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.12.1.tgz#3c45998f431edd4a9214c5f1d3ad1448a6137f6e" @@ -142,6 +195,15 @@ "@babel/template" "^7.12.7" "@babel/types" "^7.12.11" +"@babel/helper-function-name@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.12.13.tgz#93ad656db3c3c2232559fd7b2c3dbdcbe0eb377a" + integrity sha512-TZvmPn0UOqmvi5G4vvw0qZTpVptGkB1GL61R6lKvrSdIxGm5Pky7Q3fpKiIkQCAtRCBUwB0PaThlx9vebCDSwA== + dependencies: + "@babel/helper-get-function-arity" "^7.12.13" + "@babel/template" "^7.12.13" + "@babel/types" "^7.12.13" + "@babel/helper-get-function-arity@^7.12.10": version "7.12.10" resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.12.10.tgz#b158817a3165b5faa2047825dfa61970ddcc16cf" @@ -149,6 +211,13 @@ dependencies: "@babel/types" "^7.12.10" +"@babel/helper-get-function-arity@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.12.13.tgz#bc63451d403a3b3082b97e1d8b3fe5bd4091e583" + integrity sha512-DjEVzQNz5LICkzN0REdpD5prGoidvbdYk1BVgRUOINaWJP2t6avB27X1guXK1kXNrX0WMfsrm1A/ZBthYuIMQg== + dependencies: + "@babel/types" "^7.12.13" + "@babel/helper-hoist-variables@^7.10.4": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.10.4.tgz#d49b001d1d5a68ca5e6604dda01a6297f7c9381e" @@ -163,6 +232,13 @@ dependencies: "@babel/types" "^7.12.7" +"@babel/helper-member-expression-to-functions@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.13.0.tgz#6aa4bb678e0f8c22f58cdb79451d30494461b091" + integrity sha512-yvRf8Ivk62JwisqV1rFRMxiSMDGnN6KH1/mDMmIrij4jztpQNRoHqqMG3U6apYbGRPJpgPalhva9Yd06HlUxJQ== + dependencies: + "@babel/types" "^7.13.0" + "@babel/helper-module-imports@^7.0.0", "@babel/helper-module-imports@^7.12.1", "@babel/helper-module-imports@^7.12.5", "@babel/helper-module-imports@^7.8.3": version "7.12.5" resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.12.5.tgz#1bfc0229f794988f76ed0a4d4e90860850b54dfb" @@ -170,6 +246,13 @@ dependencies: "@babel/types" "^7.12.5" +"@babel/helper-module-imports@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.12.13.tgz#ec67e4404f41750463e455cc3203f6a32e93fcb0" + integrity sha512-NGmfvRp9Rqxy0uHSSVP+SRIW1q31a7Ji10cLBcqSDUngGentY4FRiHOFZFE1CLU5eiL0oE8reH7Tg1y99TDM/g== + dependencies: + "@babel/types" "^7.12.13" + "@babel/helper-module-transforms@^7.12.1": version "7.12.1" resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.12.1.tgz#7954fec71f5b32c48e4b303b437c34453fd7247c" @@ -185,6 +268,21 @@ "@babel/types" "^7.12.1" lodash "^4.17.19" +"@babel/helper-module-transforms@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.13.0.tgz#42eb4bd8eea68bab46751212c357bfed8b40f6f1" + integrity sha512-Ls8/VBwH577+pw7Ku1QkUWIyRRNHpYlts7+qSqBBFCW3I8QteB9DxfcZ5YJpOwH6Ihe/wn8ch7fMGOP1OhEIvw== + dependencies: + "@babel/helper-module-imports" "^7.12.13" + "@babel/helper-replace-supers" "^7.13.0" + "@babel/helper-simple-access" "^7.12.13" + "@babel/helper-split-export-declaration" "^7.12.13" + "@babel/helper-validator-identifier" "^7.12.11" + "@babel/template" "^7.12.13" + "@babel/traverse" "^7.13.0" + "@babel/types" "^7.13.0" + lodash "^4.17.19" + "@babel/helper-optimise-call-expression@^7.10.4", "@babel/helper-optimise-call-expression@^7.12.10": version "7.12.10" resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.12.10.tgz#94ca4e306ee11a7dd6e9f42823e2ac6b49881e2d" @@ -192,6 +290,13 @@ dependencies: "@babel/types" "^7.12.10" +"@babel/helper-optimise-call-expression@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.12.13.tgz#5c02d171b4c8615b1e7163f888c1c81c30a2aaea" + integrity sha512-BdWQhoVJkp6nVjB7nkFWcn43dkprYauqtk++Py2eaf/GRDFm5BxRqEIZCiHlZUGAVmtwKcsVL1dC68WmzeFmiA== + dependencies: + "@babel/types" "^7.12.13" + "@babel/helper-plugin-utils@7.10.4", "@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.8.0", "@babel/helper-plugin-utils@^7.8.3": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.10.4.tgz#2f75a831269d4f677de49986dff59927533cf375" @@ -216,6 +321,16 @@ "@babel/traverse" "^7.12.10" "@babel/types" "^7.12.11" +"@babel/helper-replace-supers@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.13.0.tgz#6034b7b51943094cb41627848cb219cb02be1d24" + integrity sha512-Segd5me1+Pz+rmN/NFBOplMbZG3SqRJOBlY+mA0SxAv6rjj7zJqr1AVr3SfzUVTLCv7ZLU5FycOM/SBGuLPbZw== + dependencies: + "@babel/helper-member-expression-to-functions" "^7.13.0" + "@babel/helper-optimise-call-expression" "^7.12.13" + "@babel/traverse" "^7.13.0" + "@babel/types" "^7.13.0" + "@babel/helper-simple-access@^7.12.1": version "7.12.1" resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.12.1.tgz#32427e5aa61547d38eb1e6eaf5fd1426fdad9136" @@ -223,6 +338,13 @@ dependencies: "@babel/types" "^7.12.1" +"@babel/helper-simple-access@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.12.13.tgz#8478bcc5cacf6aa1672b251c1d2dde5ccd61a6c4" + integrity sha512-0ski5dyYIHEfwpWGx5GPWhH35j342JaflmCeQmsPWcrOQDtCN6C1zKAVRFVbK53lPW2c9TsuLLSUDf0tIGJ5hA== + dependencies: + "@babel/types" "^7.12.13" + "@babel/helper-skip-transparent-expression-wrappers@^7.12.1": version "7.12.1" resolved "https://registry.yarnpkg.com/@babel/helper-skip-transparent-expression-wrappers/-/helper-skip-transparent-expression-wrappers-7.12.1.tgz#462dc63a7e435ade8468385c63d2b84cce4b3cbf" @@ -237,6 +359,13 @@ dependencies: "@babel/types" "^7.12.11" +"@babel/helper-split-export-declaration@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.12.13.tgz#e9430be00baf3e88b0e13e6f9d4eaf2136372b05" + integrity sha512-tCJDltF83htUtXx5NLcaDqRmknv652ZWCHyoTETf1CXYJdPC7nohZohjUgieXhv0hTJdRf2FjDueFehdNucpzg== + dependencies: + "@babel/types" "^7.12.13" + "@babel/helper-validator-identifier@^7.10.4", "@babel/helper-validator-identifier@^7.12.11": version "7.12.11" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.12.11.tgz#c9a1f021917dcb5ccf0d4e453e399022981fc9ed" @@ -247,6 +376,11 @@ resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.12.11.tgz#d66cb8b7a3e7fe4c6962b32020a131ecf0847f4f" integrity sha512-TBFCyj939mFSdeX7U7DDj32WtzYY7fDcalgq8v3fBZMNOJQNn7nOYzMaUCiPxPYfCup69mtIpqlKgMZLvQ8Xhw== +"@babel/helper-validator-option@^7.12.17": + version "7.12.17" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.12.17.tgz#d1fbf012e1a79b7eebbfdc6d270baaf8d9eb9831" + integrity sha512-TopkMDmLzq8ngChwRlyjR6raKD6gMSae4JdYDB8bByKreQgG0RBTuKe9LRxW3wFtUnjxOPRKBDwEH6Mg5KeDfw== + "@babel/helper-wrap-function@^7.10.4": version "7.12.3" resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.12.3.tgz#3332339fc4d1fbbf1c27d7958c27d34708e990d9" @@ -266,6 +400,15 @@ "@babel/traverse" "^7.12.5" "@babel/types" "^7.12.5" +"@babel/helpers@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.13.0.tgz#7647ae57377b4f0408bf4f8a7af01c42e41badc0" + integrity sha512-aan1MeFPxFacZeSz6Ld7YZo5aPuqnKlD7+HZY75xQsueczFccP9A7V05+oe0XpLwHK3oLorPe9eaAUljL7WEaQ== + dependencies: + "@babel/template" "^7.12.13" + "@babel/traverse" "^7.13.0" + "@babel/types" "^7.13.0" + "@babel/highlight@^7.10.4", "@babel/highlight@^7.8.3": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.10.4.tgz#7d1bdfd65753538fabe6c38596cdb76d9ac60143" @@ -275,11 +418,25 @@ chalk "^2.0.0" js-tokens "^4.0.0" +"@babel/highlight@^7.12.13": + version "7.13.8" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.13.8.tgz#10b2dac78526424dfc1f47650d0e415dfd9dc481" + integrity sha512-4vrIhfJyfNf+lCtXC2ck1rKSzDwciqF7IWFhXXrSOUC2O5DrVp+w4c6ed4AllTxhTkUP5x2tYj41VaxdVMMRDw== + dependencies: + "@babel/helper-validator-identifier" "^7.12.11" + chalk "^2.0.0" + js-tokens "^4.0.0" + "@babel/parser@^7.1.2", "@babel/parser@^7.12.10", "@babel/parser@^7.12.11", "@babel/parser@^7.12.3", "@babel/parser@^7.12.7", "@babel/parser@^7.4.5", "@babel/parser@^7.7.0": version "7.12.11" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.12.11.tgz#9ce3595bcd74bc5c466905e86c535b8b25011e79" integrity sha512-N3UxG+uuF4CMYoNj8AhnbAcJF0PiuJ9KHuy1lQmkYsxTer/MAH9UBNHsBoAX/4s6NvlDD047No8mYVGGzLL4hg== +"@babel/parser@^7.12.13", "@babel/parser@^7.13.0", "@babel/parser@^7.13.4": + version "7.13.9" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.13.9.tgz#ca34cb95e1c2dd126863a84465ae8ef66114be99" + integrity sha512-nEUfRiARCcaVo3ny3ZQjURjHQZUo/JkEw7rLlSZy/psWGnvwXFtPcr6jb7Yb41DVW5LTe6KRq9LGleRNsg1Frw== + "@babel/plugin-proposal-async-generator-functions@^7.12.1": version "7.12.12" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.12.12.tgz#04b8f24fd4532008ab4e79f788468fd5a8476566" @@ -626,7 +783,7 @@ dependencies: "@babel/helper-plugin-utils" "^7.10.4" -"@babel/plugin-transform-modules-amd@^7.10.1", "@babel/plugin-transform-modules-amd@^7.10.4", "@babel/plugin-transform-modules-amd@^7.10.5", "@babel/plugin-transform-modules-amd@^7.12.1": +"@babel/plugin-transform-modules-amd@^7.10.1", "@babel/plugin-transform-modules-amd@^7.10.5", "@babel/plugin-transform-modules-amd@^7.12.1": version "7.12.1" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.12.1.tgz#3154300b026185666eebb0c0ed7f8415fefcf6f9" integrity sha512-tDW8hMkzad5oDtzsB70HIQQRBiTKrhfgwC/KkJeGsaNFTdWhKNt/BiE8c5yj19XiGyrxpbkOfH87qkNg1YGlOQ== @@ -987,6 +1144,15 @@ "@babel/parser" "^7.12.7" "@babel/types" "^7.12.7" +"@babel/template@^7.12.13": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.12.13.tgz#530265be8a2589dbb37523844c5bcb55947fb327" + integrity sha512-/7xxiGA57xMo/P2GVvdEumr8ONhFOhfgq2ihK3h1e6THqzTAkHbkXgB0xI9yeTfIUoH3+oAeHhqm/I43OTbbjA== + dependencies: + "@babel/code-frame" "^7.12.13" + "@babel/parser" "^7.12.13" + "@babel/types" "^7.12.13" + "@babel/traverse@^7.1.6", "@babel/traverse@^7.10.4", "@babel/traverse@^7.12.1", "@babel/traverse@^7.12.10", "@babel/traverse@^7.12.5", "@babel/traverse@^7.12.9", "@babel/traverse@^7.3.4", "@babel/traverse@^7.4.5", "@babel/traverse@^7.7.0": version "7.12.12" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.12.12.tgz#d0cd87892704edd8da002d674bc811ce64743376" @@ -1002,6 +1168,21 @@ globals "^11.1.0" lodash "^4.17.19" +"@babel/traverse@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.13.0.tgz#6d95752475f86ee7ded06536de309a65fc8966cc" + integrity sha512-xys5xi5JEhzC3RzEmSGrs/b3pJW/o87SypZ+G/PhaE7uqVQNv/jlmVIBXuoh5atqQ434LfXV+sf23Oxj0bchJQ== + dependencies: + "@babel/code-frame" "^7.12.13" + "@babel/generator" "^7.13.0" + "@babel/helper-function-name" "^7.12.13" + "@babel/helper-split-export-declaration" "^7.12.13" + "@babel/parser" "^7.13.0" + "@babel/types" "^7.13.0" + debug "^4.1.0" + globals "^11.1.0" + lodash "^4.17.19" + "@babel/types@^7.1.6", "@babel/types@^7.10.4", "@babel/types@^7.10.5", "@babel/types@^7.12.1", "@babel/types@^7.12.10", "@babel/types@^7.12.11", "@babel/types@^7.12.12", "@babel/types@^7.12.5", "@babel/types@^7.12.7", "@babel/types@^7.4.4", "@babel/types@^7.7.0", "@babel/types@^7.7.2": version "7.12.12" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.12.12.tgz#4608a6ec313abbd87afa55004d373ad04a96c299" @@ -1011,6 +1192,15 @@ lodash "^4.17.19" to-fast-properties "^2.0.0" +"@babel/types@^7.12.13", "@babel/types@^7.13.0": + version "7.13.0" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.13.0.tgz#74424d2816f0171b4100f0ab34e9a374efdf7f80" + integrity sha512-hE+HE8rnG1Z6Wzo+MhaKE5lM5eMx71T4EHJgku2E3xIfaULhDcxiiRxUYgwX8qwP1BBSlag+TdGOt6JAidIZTA== + dependencies: + "@babel/helper-validator-identifier" "^7.12.11" + lodash "^4.17.19" + to-fast-properties "^2.0.0" + "@base2/pretty-print-object@1.0.0": version "1.0.0" resolved "https://registry.yarnpkg.com/@base2/pretty-print-object/-/pretty-print-object-1.0.0.tgz#860ce718b0b73f4009e153541faff2cb6b85d047" @@ -1455,18 +1645,17 @@ jquery "^3.4.1" resolve "^1.11.1" -"@ember/optional-features@^1.3.0": - version "1.3.0" - resolved "https://registry.yarnpkg.com/@ember/optional-features/-/optional-features-1.3.0.tgz#d7da860417b85a56cec88419f30da5ee1dde2756" - integrity sha512-Lrfojy4xKwTX+J4EAylmxZY2TO6bQtP4Lg5C8/z2priVqiT0X5fVB1+4WQCJbRBetctO1lMDnqjmhWCVKB8bmQ== +"@ember/optional-features@^2.0.0": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@ember/optional-features/-/optional-features-2.0.0.tgz#c809abd5a27d5b0ef3c6de3941334ab6153313f0" + integrity sha512-4gkvuGRYfpAh1nwAz306cmMeC1mG7wxZnbsBZ09mMaMX/W7IyKOKc/38JwrDPUFUalmNEM7q7JEPcmew2M3Dog== dependencies: - chalk "^3.0.0" - ember-cli-version-checker "^3.1.3" + chalk "^4.1.0" + ember-cli-version-checker "^5.1.1" glob "^7.1.6" - inquirer "^7.0.1" - mkdirp "^0.5.1" + inquirer "^7.3.3" + mkdirp "^1.0.4" silent-error "^1.1.1" - util.promisify "^1.0.0" "@ember/ordered-set@^4.0.0": version "4.0.0" @@ -1491,7 +1680,7 @@ dependencies: ember-cli-babel "^7.4.0" -"@ember/test-helpers@^1.7.0", "@ember/test-helpers@^1.7.1": +"@ember/test-helpers@^1.7.0": version "1.7.2" resolved "https://registry.yarnpkg.com/@ember/test-helpers/-/test-helpers-1.7.2.tgz#5b128dc5f6524c3850abf52668e6bd4fda401194" integrity sha512-FEJBpbFNIaWAsCSnataiNwYFvmcpoymL/B7fXLruuJ/46BnJjzLaRPtpUIZ91w4GNTK6knxbHWXW76aVb3Aezg== @@ -1503,6 +1692,29 @@ ember-cli-htmlbars-inline-precompile "^2.1.0" ember-test-waiters "^1.1.1" +"@ember/test-helpers@^2.1.4": + version "2.2.3" + resolved "https://registry.yarnpkg.com/@ember/test-helpers/-/test-helpers-2.2.3.tgz#237c2de48a9e85492374b91e825cb142675858cc" + integrity sha512-qpLz0wwHrY49JzmS2qznpEjrfZUhrWemgSXu48xgJAZnjXBa52libZgl7mzwnHmmo4YtUBgQtJSRPUp/coYFNA== + dependencies: + "@ember/test-waiters" "^2.4.0" + broccoli-debug "^0.6.5" + broccoli-funnel "^3.0.3" + ember-cli-babel "^7.23.1" + ember-cli-htmlbars "^5.2.0" + ember-destroyable-polyfill "^2.0.3" + +"@ember/test-waiters@^2.4.0": + version "2.4.1" + resolved "https://registry.yarnpkg.com/@ember/test-waiters/-/test-waiters-2.4.1.tgz#e46bd7f1d28ff9a779c89acbbd2cc2df81235ca1" + integrity sha512-tad4/nKcQHrBZ50kPlZy9xkTpmPpQUaAKegb7lHBfxC+5GcHSGbc6wYM2I8bT9Vf96diWZgNT0a5jbpLSQwRRA== + dependencies: + calculate-cache-key-for-tree "^2.0.0" + ember-cli-babel "^7.21.0" + ember-cli-typescript "^3.1.4" + ember-cli-version-checker "^5.1.2" + semver "^7.3.2" + "@embroider/core@0.29.0": version "0.29.0" resolved "https://registry.yarnpkg.com/@embroider/core/-/core-0.29.0.tgz#51421fbb2bcee607dc6e162400e3502a121230d2" @@ -1709,10 +1921,10 @@ resolved "https://registry.yarnpkg.com/@emotion/weak-memoize/-/weak-memoize-0.2.5.tgz#8eed982e2ee6f7f4e44c253e12962980791efd46" integrity sha512-6U71C2Wp7r5XtFtQzYrW5iKFT67OixrSxjI4MptCHzdSVlgabczzqLe0ZSgnub/5Kp4hSbpDB1tMytZY9pwxxA== -"@eslint/eslintrc@^0.3.0": - version "0.3.0" - resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-0.3.0.tgz#d736d6963d7003b6514e6324bec9c602ac340318" - integrity sha512-1JTKgrOKAHVivSvOYw+sJOunkBjUOvjqWk1DPja7ZFhIS2mX/4EgTT8M7eTK9jrKhL/FvXXEbQwIs3pg1xp3dg== +"@eslint/eslintrc@^0.4.0": + version "0.4.0" + resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-0.4.0.tgz#99cc0a0584d72f1df38b900fb062ba995f395547" + integrity sha512-2ZPCc+uNbjV5ERJr+aKSPRwZgKd2z11x0EgLvb1PURmUrn9QNRXFqje0Ldq454PfAVyaJYyrDvvIKSFP4NnBog== dependencies: ajv "^6.12.4" debug "^4.1.1" @@ -1721,7 +1933,6 @@ ignore "^4.0.6" import-fresh "^3.2.1" js-yaml "^3.13.1" - lodash "^4.17.20" minimatch "^3.0.4" strip-json-comments "^3.1.1" @@ -1732,10 +1943,10 @@ dependencies: tslib "^2.0.1" -"@glimmer/component@^1.0.1": - version "1.0.3" - resolved "https://registry.yarnpkg.com/@glimmer/component/-/component-1.0.3.tgz#38c26fc4855fd7ad0e0816d18d80d32c578e5140" - integrity sha512-GD3gcN+Pr2flmxkt2lm5K86jwX+KRD9QQpNH+wiEQGjBXOzd46+XD5npH1sRByqLYml9rW4klflcrEfNb7dnQw== +"@glimmer/component@^1.0.3": + version "1.0.4" + resolved "https://registry.yarnpkg.com/@glimmer/component/-/component-1.0.4.tgz#1c85a5181615a6647f6acfaaed68e28ad7e9626e" + integrity sha512-sS4N8wtcKfYdUJ6O3m8nbTut6NjErdz94Ap8VB1ekcg4WSD+7sI7Nmv6kt2rdPoe363nUdjUbRBzHNWhLzraBw== dependencies: "@glimmer/di" "^0.1.9" "@glimmer/env" "^0.1.7" @@ -1854,10 +2065,10 @@ "@handlebars/parser" "^1.1.0" simple-html-tokenizer "^0.5.10" -"@glimmer/tracking@^1.0.0": - version "1.0.3" - resolved "https://registry.yarnpkg.com/@glimmer/tracking/-/tracking-1.0.3.tgz#8b9b42aff6c206edeaaea178a95acc1eff62e61e" - integrity sha512-21WR13vPdzt1IQ6JmPPAu4szjV9yKdmLHV3nD0MLDj6/EoYv1c2PqpFBBlp++6xW8OnyDa++cQ8OFoQDP+MRpA== +"@glimmer/tracking@^1.0.3": + version "1.0.4" + resolved "https://registry.yarnpkg.com/@glimmer/tracking/-/tracking-1.0.4.tgz#f1bc1412fe5e2236d0f8d502994a8f88af1bbb21" + integrity sha512-F+oT8I55ba2puSGIzInmVrv/8QA2PcK1VD+GWgFMhF6WC97D+uZX7BFg+a3s/2N4FVBq5KHE+QxZzgazM151Yw== dependencies: "@glimmer/env" "^0.1.7" "@glimmer/validator" "^0.44.0" @@ -3643,6 +3854,11 @@ argparse@^1.0.7, argparse@~1.0.2: dependencies: sprintf-js "~1.0.2" +argparse@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/argparse/-/argparse-2.0.1.tgz#246f50f3ca78a3240f6c997e8a9bd1eac49e4b38" + integrity sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q== + arr-diff@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-4.0.0.tgz#d6461074febfec71e7e15235761a329a5dc7c520" @@ -4240,6 +4456,13 @@ babel-plugin-ember-modules-api-polyfill@^3.2.1: dependencies: ember-rfc176-data "^0.3.16" +babel-plugin-ember-modules-api-polyfill@^3.4.0: + version "3.4.0" + resolved "https://registry.yarnpkg.com/babel-plugin-ember-modules-api-polyfill/-/babel-plugin-ember-modules-api-polyfill-3.4.0.tgz#3f5e0457e135f8a29b3a8b6910806bb5b524649e" + integrity sha512-nVu/LqbZBAup1zLij6xGvQwVLWVk4XYu2fl4vIOUR3S6ukdonMLhKAb0d4QXSzH30Pd7OczVTlPffWbiwahdJw== + dependencies: + ember-rfc176-data "^0.3.16" + babel-plugin-emotion@^10.0.20, babel-plugin-emotion@^10.0.27: version "10.0.33" resolved "https://registry.yarnpkg.com/babel-plugin-emotion/-/babel-plugin-emotion-10.0.33.tgz#ce1155dcd1783bbb9286051efee53f4e2be63e03" @@ -4286,6 +4509,13 @@ babel-plugin-htmlbars-inline-precompile@^4.2.0: resolved "https://registry.yarnpkg.com/babel-plugin-htmlbars-inline-precompile/-/babel-plugin-htmlbars-inline-precompile-4.2.1.tgz#9a367f8d7ecb9fb2c2e886edfe285caf7cb9766d" integrity sha512-MCJXk+1R0YjlF/F52eDbhJTpsnqRVYsPYVP9d0jEu7E46AcRPEWDL5tfSweiQWHLKG017BIedATb91KcIoT3zA== +babel-plugin-htmlbars-inline-precompile@^4.4.1: + version "4.4.4" + resolved "https://registry.yarnpkg.com/babel-plugin-htmlbars-inline-precompile/-/babel-plugin-htmlbars-inline-precompile-4.4.4.tgz#e62bc7f037a3efd7a0c0de88796aaf88e2a2506b" + integrity sha512-H2EqG91B1Vfzc5caPmMm2G6BioWR3c/0qOvai5NxjAHwhf/BK4N/nQUbUTRA1qeakO8afqOpkNonb2BMEgmmlw== + dependencies: + babel-plugin-ember-modules-api-polyfill "^3.4.0" + babel-plugin-istanbul@^6.0.0: version "6.0.0" resolved "https://registry.yarnpkg.com/babel-plugin-istanbul/-/babel-plugin-istanbul-6.0.0.tgz#e159ccdc9af95e0b570c75b4573b7c34d671d765" @@ -5218,7 +5448,7 @@ broccoli-babel-transpiler@^6.5.0: rsvp "^4.8.2" workerpool "^2.3.0" -broccoli-babel-transpiler@^7.5.0, broccoli-babel-transpiler@^7.6.0, broccoli-babel-transpiler@^7.8.0: +broccoli-babel-transpiler@^7.5.0, broccoli-babel-transpiler@^7.8.0: version "7.8.0" resolved "https://registry.yarnpkg.com/broccoli-babel-transpiler/-/broccoli-babel-transpiler-7.8.0.tgz#7e0f01fce5739f49bbadeee7f1e625ca51cad66e" integrity sha512-dv30Td5uL7dO3NzQUqQKQs+Iq7JGKnCNtvc6GBO76uVPqGnRlsQZcYqdBVr33JrctR+ZrpTUf7TjsFKeDRFA8Q== @@ -5757,27 +5987,26 @@ broccoli-templater@^2.0.1: rimraf "^2.6.2" walk-sync "^0.3.3" -broccoli-uglify-sourcemap@^3.1.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/broccoli-uglify-sourcemap/-/broccoli-uglify-sourcemap-3.2.0.tgz#d96f1d41f6c18e9a5d49af1a5ab9489cdcac1c6c" - integrity sha512-kkkn8v7kXdWwnZNekq+3ILuTAGkZoaoEMUYCKoER5/uokuoyTjtdYLHaE7UxHkuPEuLfjvJYv21sCCePZ74/2g== +broccoli-terser-sourcemap@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/broccoli-terser-sourcemap/-/broccoli-terser-sourcemap-4.1.0.tgz#5f37441b64a3b6bfb0c67e9af232259c9576f115" + integrity sha512-zkNnjsAbP+M5rG2aMM1EE4BmXPUSxFKmtLUkUs2D1DLTOJQoF1xlOjGWjjKYCFy5tw8t4+tgGJ+HVa2ucJZ8sw== dependencies: async-promise-queue "^1.0.5" - broccoli-plugin "^1.2.1" + broccoli-plugin "^4.0.3" debug "^4.1.0" lodash.defaultsdeep "^4.6.1" - matcher-collection "^2.0.0" - mkdirp "^0.5.0" + matcher-collection "^2.0.1" source-map-url "^0.4.0" - symlink-or-copy "^1.0.1" - terser "^4.3.9" - walk-sync "^1.1.3" - workerpool "^5.0.1" + symlink-or-copy "^1.3.1" + terser "^5.3.0" + walk-sync "^2.2.0" + workerpool "^6.0.0" -broccoli@^3.4.2: - version "3.5.0" - resolved "https://registry.yarnpkg.com/broccoli/-/broccoli-3.5.0.tgz#bdf96dc32980d1ad9f7ef5e68aaaa19e8d47b602" - integrity sha512-qGYirIs6W5NGzDPMTRtoOnveP3UQJKWFjAWdRRZJjCoAJYN872sXuO48cnNfnc/c1nd9fCR8et4knlTPgI+9yQ== +broccoli@^3.5.0: + version "3.5.1" + resolved "https://registry.yarnpkg.com/broccoli/-/broccoli-3.5.1.tgz#371bc63cabe700bae3a2b80cac3e978f94664418" + integrity sha512-2Rvl40E6JgALX1JQN5PjCgP1apFAP24vVol+coX5TpVVy0Lsqzl3Mabbe3fVQcu3lMRfPJ6DyBKqBlo52XPSRg== dependencies: "@types/chai" "^4.2.9" "@types/chai-as-promised" "^7.1.2" @@ -6188,7 +6417,7 @@ callsites@^2.0.0: resolved "https://registry.yarnpkg.com/callsites/-/callsites-2.0.0.tgz#06eb84f00eea413da86affefacbffb36093b3c50" integrity sha1-BuuE8A7qQT2oav/vrL/7Ngk7PFA= -callsites@^3.0.0: +callsites@^3.0.0, callsites@^3.1.0: version "3.1.0" resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ== @@ -6537,7 +6766,7 @@ clean-css@^4.2.3: dependencies: source-map "~0.6.0" -clean-stack@^2.0.0: +clean-stack@^2.0.0, clean-stack@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/clean-stack/-/clean-stack-2.2.0.tgz#ee8472dbb129e727b31e8a10a427dee9dfe4008b" integrity sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A== @@ -6866,7 +7095,7 @@ commitizen@^4.0.3: strip-bom "4.0.0" strip-json-comments "3.0.1" -common-tags@^1.4.0, common-tags@^1.8.0: +common-tags@^1.8.0: version "1.8.0" resolved "https://registry.yarnpkg.com/common-tags/-/common-tags-1.8.0.tgz#8e3153e542d4a39e9b10554434afaaf98956a937" integrity sha512-6P6g0uetGpW/sdyUy/iQQCbFF0kWVMSIVSyYz7Zgjcgh8mgw8PQzDNZeyZ5DQ2gM7LBoZPHmnjz8rUthkBG5tw== @@ -6993,7 +7222,7 @@ console-control-strings@^1.0.0, console-control-strings@^1.1.0, console-control- resolved "https://registry.yarnpkg.com/console-control-strings/-/console-control-strings-1.1.0.tgz#3d7cf4464db6446ea644bf4b39507f9851008e8e" integrity sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4= -console-ui@^3.0.4, console-ui@^3.1.1: +console-ui@^3.0.4, console-ui@^3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/console-ui/-/console-ui-3.1.2.tgz#51aef616ff02013c85ccee6a6d77ef7a94202e7a" integrity sha512-+5j3R4wZJcEYZeXk30whc4ZU/+fWW9JMTNntVuMYpjZJ9n26Cxr0tUBXco1NRjVZRpRVvZ4DDKKKIHNYeUG9Dw== @@ -7370,6 +7599,14 @@ css-tree@1.0.0-alpha.29: mdn-data "~1.1.0" source-map "^0.5.3" +css-tree@^1.0.0-alpha.39: + version "1.1.2" + resolved "https://registry.yarnpkg.com/css-tree/-/css-tree-1.1.2.tgz#9ae393b5dafd7dae8a622475caec78d3d8fbd7b5" + integrity sha512-wCoWush5Aeo48GLhfHPbmvZs59Z+M7k5+B1xDnXbdWNcEF423DoFdqSWE0PM5aNk5nI5cp1q7ms36zGApY/sKQ== + dependencies: + mdn-data "2.0.14" + source-map "^0.6.1" + css-url-regex@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/css-url-regex/-/css-url-regex-1.1.0.tgz#83834230cc9f74c457de59eebd1543feeb83b7ec" @@ -8163,7 +8400,7 @@ ember-assign-polyfill@^2.6.0: ember-cli-babel "^7.20.5" ember-cli-version-checker "^2.0.0" -ember-auto-import@^1.2.15, ember-auto-import@^1.2.19, ember-auto-import@^1.5.3, ember-auto-import@^1.6.0: +ember-auto-import@^1.10.1, ember-auto-import@^1.2.15, ember-auto-import@^1.2.19, ember-auto-import@^1.5.3: version "1.10.1" resolved "https://registry.yarnpkg.com/ember-auto-import/-/ember-auto-import-1.10.1.tgz#6c93a875e494aa0a58b759867d3f20adfd514ae3" integrity sha512-7bOWzPELlVwdWDOkB+phDIjg8BNW+/2RiLLQ+Xa/eIvCLT4ABYhHV5wqW5gs5BnXTDVLfE4ddKZdllnGuPGGDQ== @@ -8224,20 +8461,20 @@ ember-cli-addon-docs-yuidoc@^0.2.3: lodash "^4.17.5" yuidocjs "^0.10.2" -ember-cli-app-version@^3.2.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/ember-cli-app-version/-/ember-cli-app-version-3.2.0.tgz#7b9ad0e1b63ae0518648356ee24c703e922bc26e" - integrity sha512-fHWOJElSw8JL03FNCHrT0RdWhGpWEQ4VQ10unEwwhVZ+OANNcOLz8O2dA3D5iuB4bb0fMLwjEwYZGM62+TBs1Q== +ember-cli-app-version@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/ember-cli-app-version/-/ember-cli-app-version-4.0.0.tgz#033057ec5fe4d3ecdf5ac5380d442e2dc9f7526a" + integrity sha512-YRH1r4vjA9ZIgTVJ38zWxhtt4SCzIHb0ppEsO/z+JV0ZTQlS3+2dT5RhJWz7O3dyw5FWnlIng+gPRoQEz1umHA== dependencies: - ember-cli-babel "^6.12.0" - git-repo-version "^1.0.2" + ember-cli-babel "^7.22.1" + git-repo-info "^2.1.1" ember-cli-babel-plugin-helpers@^1.0.0, ember-cli-babel-plugin-helpers@^1.1.0, ember-cli-babel-plugin-helpers@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/ember-cli-babel-plugin-helpers/-/ember-cli-babel-plugin-helpers-1.1.1.tgz#5016b80cdef37036c4282eef2d863e1d73576879" integrity sha512-sKvOiPNHr5F/60NLd7SFzMpYPte/nnGkq/tMIfXejfKHIhaiIkYFqX8Z9UFTKWLLn+V7NOaby6niNPZUdvKCRw== -ember-cli-babel@7, ember-cli-babel@^7.0.0, ember-cli-babel@^7.1.0, ember-cli-babel@^7.1.2, ember-cli-babel@^7.10.0, ember-cli-babel@^7.11.0, ember-cli-babel@^7.11.1, ember-cli-babel@^7.12.0, ember-cli-babel@^7.13.0, ember-cli-babel@^7.18.0, ember-cli-babel@^7.19.0, ember-cli-babel@^7.20.5, ember-cli-babel@^7.21.0, ember-cli-babel@^7.22.1, ember-cli-babel@^7.23.0, ember-cli-babel@^7.4.0, ember-cli-babel@^7.5.0, ember-cli-babel@^7.7.3: +ember-cli-babel@7, ember-cli-babel@^7.0.0, ember-cli-babel@^7.1.0, ember-cli-babel@^7.1.2, ember-cli-babel@^7.10.0, ember-cli-babel@^7.11.0, ember-cli-babel@^7.11.1, ember-cli-babel@^7.13.0, ember-cli-babel@^7.13.2, ember-cli-babel@^7.18.0, ember-cli-babel@^7.19.0, ember-cli-babel@^7.20.5, ember-cli-babel@^7.21.0, ember-cli-babel@^7.22.1, ember-cli-babel@^7.23.0, ember-cli-babel@^7.23.1, ember-cli-babel@^7.4.0, ember-cli-babel@^7.5.0, ember-cli-babel@^7.7.3: version "7.23.1" resolved "https://registry.yarnpkg.com/ember-cli-babel/-/ember-cli-babel-7.23.1.tgz#d1517228ede08a5d4b045c78a7429728e956b30b" integrity sha512-qYggmt3hRs6QJ6cRkww3ahMpyP8IEV2KFrIRO/Z6hu9MkE/8Y28Xd5NjQl6fPV3oLoG0vwuHzhNe3Jr7Wec8zw== @@ -8301,7 +8538,7 @@ ember-cli-babel@7.21.0: rimraf "^3.0.1" semver "^5.5.0" -ember-cli-babel@^6.0.0-beta.4, ember-cli-babel@^6.12.0, ember-cli-babel@^6.16.0, ember-cli-babel@^6.3.0, ember-cli-babel@^6.6.0, ember-cli-babel@^6.8.1, ember-cli-babel@^6.8.2, ember-cli-babel@^6.9.2: +ember-cli-babel@^6.0.0-beta.4, ember-cli-babel@^6.16.0, ember-cli-babel@^6.3.0, ember-cli-babel@^6.6.0, ember-cli-babel@^6.8.1, ember-cli-babel@^6.8.2, ember-cli-babel@^6.9.2: version "6.18.0" resolved "https://registry.yarnpkg.com/ember-cli-babel/-/ember-cli-babel-6.18.0.tgz#3f6435fd275172edeff2b634ee7b29ce74318957" integrity sha512-7ceC8joNYxY2wES16iIBlbPSxwKDBhYwC8drU3ZEvuPDMwVv1KzxCNu1fvxyFEBWhwaRNTUxSCsEVoTd9nosGA== @@ -8432,6 +8669,27 @@ ember-cli-htmlbars@^5.2.0: strip-bom "^4.0.0" walk-sync "^2.2.0" +ember-cli-htmlbars@^5.3.1: + version "5.6.3" + resolved "https://registry.yarnpkg.com/ember-cli-htmlbars/-/ember-cli-htmlbars-5.6.3.tgz#4916d1ea2b6d69ea5e7252c0c59e56d7031ee310" + integrity sha512-pn2pW49KmsrjlG4PEMmd3ZrsbS2WHKn+1NLLCWUjxmc5g4/lHxHicB8IN5z95ANmgqDHAwp+rw1XTyWy9r0xyQ== + dependencies: + "@ember/edition-utils" "^1.2.0" + babel-plugin-htmlbars-inline-precompile "^4.4.1" + broccoli-debug "^0.6.5" + broccoli-persistent-filter "^3.1.2" + broccoli-plugin "^4.0.3" + common-tags "^1.8.0" + ember-cli-babel-plugin-helpers "^1.1.1" + fs-tree-diff "^2.0.1" + hash-for-dep "^1.5.1" + heimdalljs-logger "^0.1.10" + json-stable-stringify "^1.0.1" + semver "^7.3.4" + silent-error "^1.1.1" + strip-bom "^4.0.0" + walk-sync "^2.2.0" + ember-cli-inject-live-reload@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/ember-cli-inject-live-reload/-/ember-cli-inject-live-reload-2.0.2.tgz#95edb543b386239d35959e5ea9579f5382976ac7" @@ -8526,6 +8784,13 @@ ember-cli-template-lint@^2.0.2: strip-ansi "^6.0.0" walk-sync "^2.0.2" +ember-cli-terser@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/ember-cli-terser/-/ember-cli-terser-4.0.1.tgz#0da0b8f2b09989e8c992b207553ddec1bbb65915" + integrity sha512-vvp0uVl8reYeW9EZjSXRPR3Bq7y4u9CYlUdI7j/WzMPDj3/gUHU4Z7CHYOCrftrClQvFfqO2eXmHwDA6F7SLug== + dependencies: + broccoli-terser-sourcemap "^4.1.0" + ember-cli-test-info@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/ember-cli-test-info/-/ember-cli-test-info-1.0.0.tgz#ed4e960f249e97523cf891e4aed2072ce84577b4" @@ -8533,12 +8798,12 @@ ember-cli-test-info@^1.0.0: dependencies: ember-cli-string-utils "^1.0.0" -ember-cli-test-loader@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/ember-cli-test-loader/-/ember-cli-test-loader-2.2.0.tgz#3fb8d5d1357e4460d3f0a092f5375e71b6f7c243" - integrity sha512-mlSXX9SciIRwGkFTX6XGyJYp4ry6oCFZRxh5jJ7VH8UXLTNx2ZACtDTwaWtNhYrWXgKyiDUvmD8enD56aePWRA== +ember-cli-test-loader@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/ember-cli-test-loader/-/ember-cli-test-loader-3.0.0.tgz#1c036fc48de36155355fcda3266af63f977826f1" + integrity sha512-wfFRBrfO9gaKScYcdQxTfklx9yp1lWK6zv1rZRpkas9z2SHyJojF7NOQRWQgSB3ypm7vfpiF8VsFFVVr7VBzAQ== dependencies: - ember-cli-babel "^6.8.1" + ember-cli-babel "^7.13.2" ember-cli-typescript@3.0.0: version "3.0.0" @@ -8575,7 +8840,7 @@ ember-cli-typescript@^2.0.0-rc.2, ember-cli-typescript@^2.0.2: stagehand "^1.0.0" walk-sync "^1.0.0" -ember-cli-typescript@^3.1.3: +ember-cli-typescript@^3.1.3, ember-cli-typescript@^3.1.4: version "3.1.4" resolved "https://registry.yarnpkg.com/ember-cli-typescript/-/ember-cli-typescript-3.1.4.tgz#21d6ccd670d1f2e34c9cce68c6e32c442f46806b" integrity sha512-HJ73kL45OGRmIkPhBNFt31I1SGUvdZND+LCH21+qpq3pPlFpJG8GORyXpP+2ze8PbnITNLzwe5AwUrpyuRswdQ== @@ -8611,14 +8876,6 @@ ember-cli-typescript@^4.0.0: stagehand "^1.0.0" walk-sync "^2.2.0" -ember-cli-uglify@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/ember-cli-uglify/-/ember-cli-uglify-3.0.0.tgz#8819665b2cc5fe70e3ba9fe7a94645209bc42fd6" - integrity sha512-n3QxdBfAgBdb2Cnso82Kt/nxm3ppIjnYWM8uhOEhF1aYxNXfM7AJrc+yiqTCDUR61Db8aCpHfAMvChz3kyme7g== - dependencies: - broccoli-uglify-sourcemap "^3.1.0" - lodash.defaultsdeep "^4.6.0" - ember-cli-update@^0.54.6: version "0.54.6" resolved "https://registry.yarnpkg.com/ember-cli-update/-/ember-cli-update-0.54.6.tgz#e9f405b4737558e53874025731568ae7c005a48c" @@ -8677,7 +8934,7 @@ ember-cli-version-checker@^4.1.0: semver "^6.3.0" silent-error "^1.1.1" -ember-cli-version-checker@^5.0.1, ember-cli-version-checker@^5.1.1: +ember-cli-version-checker@^5.0.1, ember-cli-version-checker@^5.1.1, ember-cli-version-checker@^5.1.2: version "5.1.2" resolved "https://registry.yarnpkg.com/ember-cli-version-checker/-/ember-cli-version-checker-5.1.2.tgz#649c7b6404902e3b3d69c396e054cea964911ab0" integrity sha512-rk7GY+FmLn/2e22HsZs0Ycrz8HQ1W3Fv+2TFOuEFW9optnDXDgkntPBIl6gact/LHsfBM5RKbM3dHsIIeLgl0Q== @@ -8686,20 +8943,20 @@ ember-cli-version-checker@^5.0.1, ember-cli-version-checker@^5.1.1: semver "^7.3.4" silent-error "^1.1.1" -ember-cli@~3.20.2: - version "3.20.2" - resolved "https://registry.yarnpkg.com/ember-cli/-/ember-cli-3.20.2.tgz#4a5411afc32a91eb81e4fa1e6f4bc950e838c132" - integrity sha512-8ggRX+NXD9VkQt/9/GSMLcnswWNYTgE7Aw1uelexHdxGA1TqcjOjQ07ljVmgRwYVieknhDzhK3M0u3Xoa3x0HA== +ember-cli@~3.24.0: + version "3.24.0" + resolved "https://registry.yarnpkg.com/ember-cli/-/ember-cli-3.24.0.tgz#dbda4938e74fdafe4da1c42b49356f9d14c10697" + integrity sha512-dLurYpluRcE+XjCHy/JzUBcW4dBKhjmXH3zUjyof89gFjj+8EFjB0b2tqyS6buKqBasinVaX8lZZVIXYCdFtNA== dependencies: - "@babel/core" "^7.10.2" - "@babel/plugin-transform-modules-amd" "^7.10.4" + "@babel/core" "^7.12.9" + "@babel/plugin-transform-modules-amd" "^7.12.1" amd-name-resolver "^1.3.1" babel-plugin-module-resolver "^4.0.0" bower-config "^1.4.3" bower-endpoint-parser "0.2.2" - broccoli "^3.4.2" + broccoli "^3.5.0" broccoli-amd-funnel "^2.0.1" - broccoli-babel-transpiler "^7.6.0" + broccoli-babel-transpiler "^7.8.0" broccoli-builder "^0.18.14" broccoli-concat "^4.2.4" broccoli-config-loader "^1.0.1" @@ -8714,12 +8971,12 @@ ember-cli@~3.20.2: broccoli-stew "^3.0.0" calculate-cache-key-for-tree "^2.0.0" capture-exit "^2.0.0" - chalk "^4.0.0" + chalk "^4.1.0" ci-info "^2.0.0" clean-base-url "^1.0.0" compression "^1.7.4" configstore "^5.0.1" - console-ui "^3.1.1" + console-ui "^3.1.2" core-object "^3.1.5" dag-map "^2.0.2" diff "^4.0.2" @@ -8728,57 +8985,59 @@ ember-cli@~3.20.2: ember-cli-normalize-entity-name "^1.0.0" ember-cli-preprocess-registry "^3.3.0" ember-cli-string-utils "^1.1.0" - ember-source-channel-url "^2.0.1" + ember-source-channel-url "^3.0.0" ensure-posix-path "^1.1.1" - execa "^1.0.0" + execa "^4.1.0" exit "^0.1.2" express "^4.17.1" filesize "^6.1.0" - find-up "^4.1.0" - find-yarn-workspace-root "^1.2.1" + find-up "^5.0.0" + find-yarn-workspace-root "^2.0.0" fixturify-project "^2.1.0" - fs-extra "^9.0.0" + fs-extra "^9.0.1" fs-tree-diff "^2.0.1" get-caller-file "^2.0.5" git-repo-info "^2.1.1" glob "^7.1.6" heimdalljs "^0.2.6" - heimdalljs-fs-monitor "^0.2.3" + heimdalljs-fs-monitor "^1.1.0" heimdalljs-graph "^1.0.0" heimdalljs-logger "^0.1.10" http-proxy "^1.18.1" inflection "^1.12.0" is-git-url "^1.0.0" + is-language-code "^2.0.0" isbinaryfile "^4.0.6" - js-yaml "^3.13.1" + js-yaml "^3.14.0" json-stable-stringify "^1.0.1" leek "0.0.24" lodash.template "^4.5.0" - markdown-it "^11.0.0" + markdown-it "^12.0.2" markdown-it-terminal "0.2.1" minimatch "^3.0.4" morgan "^1.10.0" nopt "^3.0.6" - npm-package-arg "^8.0.1" + npm-package-arg "^8.1.0" p-defer "^3.0.0" - portfinder "^1.0.26" + portfinder "^1.0.28" promise-map-series "^0.3.0" - promise.hash.helper "^1.0.6" + promise.hash.helper "^1.0.7" quick-temp "^0.1.8" - resolve "^1.17.0" - resolve-package-path "^2.0.0" + resolve "^1.19.0" + resolve-package-path "^3.1.0" sane "^4.1.0" semver "^7.3.2" silent-error "^1.1.1" - sort-package-json "^1.44.0" + sort-package-json "^1.48.0" symlink-or-copy "^1.3.1" - temp "0.9.1" - testem "^3.1.0" - tiny-lr "^1.1.1" + temp "0.9.4" + testem "^3.2.0" + tiny-lr "^2.0.0" tree-sync "^2.1.0" - uuid "^8.1.0" + uuid "^8.3.1" walk-sync "^2.2.0" watch-detector "^1.0.0" + workerpool "^6.0.3" yam "^1.0.0" ember-compatibility-helpers@^1.1.1, ember-compatibility-helpers@^1.1.2, ember-compatibility-helpers@^1.2.0, ember-compatibility-helpers@^1.2.1: @@ -8868,7 +9127,7 @@ ember-decorators-polyfill@^1.1.5: ember-cli-version-checker "^3.1.3" ember-compatibility-helpers "^1.2.0" -ember-destroyable-polyfill@^2.0.2: +ember-destroyable-polyfill@^2.0.2, ember-destroyable-polyfill@^2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/ember-destroyable-polyfill/-/ember-destroyable-polyfill-2.0.3.tgz#1673ed66609a82268ef270a7d917ebd3647f11e1" integrity sha512-TovtNqCumzyAiW0/OisSkkVK93xnVF4NRU6+FN0ubpfwEOpRrmM2RqDwXI6YAChCgSHON1cz0DfQStpA1Gjuuw== @@ -9035,7 +9294,7 @@ ember-intl@^5.5.0: mkdirp "^1.0.4" silent-error "^1.1.1" -ember-load-initializers@^2.1.1: +ember-load-initializers@^2.1.2: version "2.1.2" resolved "https://registry.yarnpkg.com/ember-load-initializers/-/ember-load-initializers-2.1.2.tgz#8a47a656c1f64f9b10cecdb4e22a9d52ad9c7efa" integrity sha512-CYR+U/wRxLbrfYN3dh+0Tb6mFaxJKfdyz+wNql6cqTrA0BBi9k6J3AaKXj273TqvEpyyXegQFFkZEiuZdYtgJw== @@ -9112,18 +9371,20 @@ ember-page-title@^6.0.3: dependencies: ember-cli-babel "^7.22.1" -ember-qunit@^4.6.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/ember-qunit/-/ember-qunit-4.6.0.tgz#ad79fd3ff00073a8779400cc5a4b44829517590f" - integrity sha512-i5VOGn0RP8XH+5qkYDOZshbqAvO6lHgF65D0gz8vRx4DszCIvJMJO+bbftBTfYMxp6rqG85etAA6pfNxE0DqsQ== +ember-qunit@^5.1.1: + version "5.1.3" + resolved "https://registry.yarnpkg.com/ember-qunit/-/ember-qunit-5.1.3.tgz#73de924c6c698eaed4adaaab257793741f2d666f" + integrity sha512-vz56bX/ciBZPNXl1l3jDNo9O0YBdVXtt3kqXpmEurNAlggmhdAJyAFTVZaWLtZYIfLuSdlHEMPwOzYmjqhd7fQ== dependencies: - "@ember/test-helpers" "^1.7.1" - broccoli-funnel "^2.0.2" + broccoli-funnel "^3.0.3" broccoli-merge-trees "^3.0.2" - common-tags "^1.4.0" - ember-cli-babel "^7.12.0" - ember-cli-test-loader "^2.2.0" - qunit "^2.9.3" + common-tags "^1.8.0" + ember-auto-import "^1.10.1" + ember-cli-babel "^7.23.1" + ember-cli-test-loader "^3.0.0" + resolve-package-path "^3.1.0" + silent-error "^1.1.1" + validate-peer-dependencies "^1.1.0" ember-radio-button@^2.0.1: version "2.0.1" @@ -9133,7 +9394,7 @@ ember-radio-button@^2.0.1: ember-cli-babel "^6.9.2" ember-cli-htmlbars "^1.1.1" -ember-resolver@^8.0.0: +ember-resolver@^8.0.2: version "8.0.2" resolved "https://registry.yarnpkg.com/ember-resolver/-/ember-resolver-8.0.2.tgz#8a45a744aaf5391eb52b4cb393b3b06d2db1975c" integrity sha512-BmCoPT8nf5uv0g2QkhMsrG1Gmu6MtXd6igfhCVzCTMTwZ97SxhJKqoMY62EP/av5HVSWBC/Sa1uGU5cQvX1Aog== @@ -9188,17 +9449,17 @@ ember-source-channel-url@^1.0.1: dependencies: got "^8.0.1" -ember-source-channel-url@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/ember-source-channel-url/-/ember-source-channel-url-2.0.1.tgz#18b88f8a00b7746e7a456b3551abb3aea18729cc" - integrity sha512-YlLUHW9gNvxEaohIj5exykoTZb4xj9ZRTcR4J3svv9S8rjAHJUnHmqC5Fd9onCs+NGxHo7KwR/fDwsfadbDu5Q== +ember-source-channel-url@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/ember-source-channel-url/-/ember-source-channel-url-3.0.0.tgz#bcd5be72c63fa0b8c390b3121783b462063e2a1b" + integrity sha512-vF/8BraOc66ZxIDo3VuNP7iiDrnXEINclJgSJmqwAAEpg84Zb1DHPI22XTXSDA+E8fW5btPUxu65c3ZXi8AQFA== dependencies: - got "^8.0.1" + node-fetch "^2.6.0" -ember-source@~3.20.2: - version "3.20.6" - resolved "https://registry.yarnpkg.com/ember-source/-/ember-source-3.20.6.tgz#c2aa4cee386436214b4b3ed84a71becfe815fa12" - integrity sha512-THimwJmimckNdumSg0M5URQTRlXAArEhe2ricCIuYesMwyX9HwZSUMS+IbXALzktGZU8qfEqyWNXxpmQ8ThJLA== +ember-source@~3.24.0: + version "3.24.2" + resolved "https://registry.yarnpkg.com/ember-source/-/ember-source-3.24.2.tgz#64c593057020eb867935cf0735e758e96bb5f4cd" + integrity sha512-naFddoVtCI01nDbmPC4u2+8CpnjQdKlgftkE35Io9Ud6PZTsTB1uib9jf5+v8h+ie+cNbRSfikKrB1odcGm0Og== dependencies: "@babel/helper-module-imports" "^7.8.3" "@babel/plugin-transform-block-scoping" "^7.8.3" @@ -9211,7 +9472,7 @@ ember-source@~3.20.2: broccoli-funnel "^2.0.2" broccoli-merge-trees "^4.2.0" chalk "^4.0.0" - ember-cli-babel "^7.19.0" + ember-cli-babel "^7.23.0" ember-cli-get-component-path-option "^1.0.0" ember-cli-is-package-missing "^1.0.0" ember-cli-normalize-entity-name "^1.0.0" @@ -9225,7 +9486,7 @@ ember-source@~3.20.2: semver "^6.1.1" silent-error "^1.1.1" -ember-template-lint@^2.0.1, ember-template-lint@^2.14.0, ember-template-lint@^2.9.1: +ember-template-lint@^2.0.1: version "2.18.0" resolved "https://registry.yarnpkg.com/ember-template-lint/-/ember-template-lint-2.18.0.tgz#cba7665c2ff3c34734285768d7bf41cdd08ffb3f" integrity sha512-4J1Dk2ZaMo/nqtP4QJF+25yYnKNOewE8xopSRNGjgQpNwaUFZmZCtzJtoSJF6+SRLcMDljnewXRezugok4ljug== @@ -9241,6 +9502,23 @@ ember-template-lint@^2.0.1, ember-template-lint@^2.14.0, ember-template-lint@^2. v8-compile-cache "^2.2.0" yargs "^16.2.0" +ember-template-lint@^2.15.0: + version "2.21.0" + resolved "https://registry.yarnpkg.com/ember-template-lint/-/ember-template-lint-2.21.0.tgz#7e120abf309a8810eeed26c52377943faf15a95b" + integrity sha512-19QbEqJQdMfcRS7PsQsubflRowEtnkbD0tpYR4q/xq4lodmhU7hhOFvlTQgbxD/jwW5Ur+tkOwH4KFy9JwOyXA== + dependencies: + chalk "^4.0.0" + ember-template-recast "^5.0.1" + find-up "^5.0.0" + fuse.js "^6.4.6" + get-stdin "^8.0.0" + globby "^11.0.2" + is-glob "^4.0.1" + micromatch "^4.0.2" + resolve "^1.20.0" + v8-compile-cache "^2.2.0" + yargs "^16.2.0" + ember-template-recast@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/ember-template-recast/-/ember-template-recast-5.0.1.tgz#c5d9e7208bf629ee368a3792328f245f3c651003" @@ -9448,11 +9726,6 @@ entities@^2.0.0: resolved "https://registry.yarnpkg.com/entities/-/entities-2.2.0.tgz#098dc90ebb83d8dffa089d55256b351d34c4da55" integrity sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A== -entities@~2.0.0: - version "2.0.3" - resolved "https://registry.yarnpkg.com/entities/-/entities-2.0.3.tgz#5c487e5742ab93c15abb5da22759b8590ec03b7f" - integrity sha512-MyoZ0jgnLvB2X3Lg5HqpFmn1kybDiIfEQmKzTb5apr51Rb+T3KdmMiqa70T+bhGnyv7bQ6WMj2QMHpGMmlrUYQ== - entities@~2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/entities/-/entities-2.1.0.tgz#992d3129cf7df6870b96c57858c249a120f8b8b5" @@ -9710,13 +9983,20 @@ escope@^3.6.0: esrecurse "^4.1.0" estraverse "^4.1.1" -eslint-plugin-ember@^8.9.1: - version "8.14.0" - resolved "https://registry.yarnpkg.com/eslint-plugin-ember/-/eslint-plugin-ember-8.14.0.tgz#fc4c5119b5a1c87604a7bf920ca397783b96b7be" - integrity sha512-PQhR58omMAZzcJOB8GLWzL6l/vjRZ2Uo1eohxOmgPUyeBkHfZAMlvK+OSeneMLIr4azLQ4GISkklwv6lxb8qnw== +eslint-config-prettier@^7.1.0: + version "7.2.0" + resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-7.2.0.tgz#f4a4bd2832e810e8cc7c1411ec85b3e85c0c53f9" + integrity sha512-rV4Qu0C3nfJKPOAhFujFxB7RMP+URFyQqqOZW9DMRD7ZDTFyjaIlETU3xzHELt++4ugC0+Jm084HQYkkJe+Ivg== + +eslint-plugin-ember@^10.1.1: + version "10.2.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-ember/-/eslint-plugin-ember-10.2.0.tgz#449c3ce8e5421c61ab47e0cb6954e2f6f1cfbdc8" + integrity sha512-W5cPJa+bBcKJ5kmmu7o8r1hbbT45ZCy8eE5EyRjqJ02B7Jlg74mX+Hdz4RYNSvV1+G7YAOwEZLUkIdJ+44ySGA== dependencies: "@ember-data/rfc395-data" "^0.0.4" + css-tree "^1.0.0-alpha.39" ember-rfc176-data "^0.3.15" + eslint-utils "^2.1.0" lodash.kebabcase "^4.1.1" snake-case "^3.0.3" @@ -9740,6 +10020,13 @@ eslint-plugin-node@^11.1.0: resolve "^1.10.1" semver "^6.1.0" +eslint-plugin-prettier@^3.3.1: + version "3.3.1" + resolved "https://registry.yarnpkg.com/eslint-plugin-prettier/-/eslint-plugin-prettier-3.3.1.tgz#7079cfa2497078905011e6f82e8dd8453d1371b7" + integrity sha512-Rq3jkcFY8RYeQLgk2cCwuc0P7SEFwDravPhsJZOQ5N4YI4DSg50NyqJ/9gdZHzQlHf8MvafSesbNJCcP/FF6pQ== + dependencies: + prettier-linter-helpers "^1.0.0" + eslint-scope@^4.0.3: version "4.0.3" resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-4.0.3.tgz#ca03833310f6889a3264781aa82e63eb9cfe7848" @@ -9862,13 +10149,13 @@ eslint@^6.5.1: text-table "^0.2.0" v8-compile-cache "^2.0.3" -eslint@^7.5.0: - version "7.19.0" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-7.19.0.tgz#6719621b196b5fad72e43387981314e5d0dc3f41" - integrity sha512-CGlMgJY56JZ9ZSYhJuhow61lMPPjUzWmChFya71Z/jilVos7mR/jPgaEfVGgMBY5DshbKdG8Ezb8FDCHcoMEMg== +eslint@^7.17.0: + version "7.21.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-7.21.0.tgz#4ecd5b8c5b44f5dedc9b8a110b01bbfeb15d1c83" + integrity sha512-W2aJbXpMNofUp0ztQaF40fveSsJBjlSCSWpy//gzfTvwC+USs/nceBrKmlJOiM8r1bLwP2EuYkCqArn/6QTIgg== dependencies: - "@babel/code-frame" "^7.0.0" - "@eslint/eslintrc" "^0.3.0" + "@babel/code-frame" "7.12.11" + "@eslint/eslintrc" "^0.4.0" ajv "^6.10.0" chalk "^4.0.0" cross-spawn "^7.0.2" @@ -9879,9 +10166,9 @@ eslint@^7.5.0: eslint-utils "^2.1.0" eslint-visitor-keys "^2.0.0" espree "^7.3.1" - esquery "^1.2.0" + esquery "^1.4.0" esutils "^2.0.2" - file-entry-cache "^6.0.0" + file-entry-cache "^6.0.1" functional-red-black-tree "^1.0.1" glob-parent "^5.0.0" globals "^12.1.0" @@ -9946,13 +10233,20 @@ esprima@~3.0.0: resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.0.0.tgz#53cf247acda77313e551c3aa2e73342d3fb4f7d9" integrity sha1-U88kes2ncxPlUcOqLnM0LT+099k= -esquery@^1.0.1, esquery@^1.2.0: +esquery@^1.0.1: version "1.3.1" resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.3.1.tgz#b78b5828aa8e214e29fb74c4d5b752e1c033da57" integrity sha512-olpvt9QG0vniUBZspVRN6lwB7hOZoTRtT+jzR+tS4ffYx2mzbw+z0XCOk44aaLYKApNX5nMm+E+P6o25ip/DHQ== dependencies: estraverse "^5.1.0" +esquery@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.4.0.tgz#2148ffc38b82e8c7057dfed48425b3e61f0f24a5" + integrity sha512-cCDispWt5vHHtwMY2YrAQ4ibFkAL8RbH5YGBnZBc90MolvvfkkQcJro/aZiAQUlQ3qgrYS6D6v8Gc5G5CQsc9w== + dependencies: + estraverse "^5.1.0" + esrecurse@^4.1.0, esrecurse@^4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.3.0.tgz#7ad7964d679abb28bee72cec63758b1c5d2c9921" @@ -10083,7 +10377,7 @@ execa@^3.0.0, execa@^3.4.0: signal-exit "^3.0.2" strip-final-newline "^2.0.0" -execa@^4.0.0, execa@^4.0.3: +execa@^4.0.0, execa@^4.0.3, execa@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/execa/-/execa-4.1.0.tgz#4e5491ad1572f2f17a77d388c6c857135b22847a" integrity sha512-j5W0//W7f8UxAn8hXVnwG8tLwdiUy4FJLcSupCg6maBYZDpyBvTApK7KyuI4bKj8KOh1r2YH+6ucuYtJv1bTZA== @@ -10226,6 +10520,11 @@ extglob@^2.0.4: snapdragon "^0.8.1" to-regex "^3.0.1" +extract-stack@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/extract-stack/-/extract-stack-2.0.0.tgz#11367bc865bfcd9bc0db3123e5edb57786f11f9b" + integrity sha512-AEo4zm+TenK7zQorGK1f9mJ8L14hnTDi2ZQPR+Mub1NX8zimka1mXpV5LpH8x9HoUmFSHZCfLHqWvp0Y4FxxzQ== + extract-zip@^2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/extract-zip/-/extract-zip-2.0.1.tgz#663dca56fe46df890d5f131ef4a06d22bb8ba13a" @@ -10267,6 +10566,11 @@ fast-deep-equal@^3.1.1: resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== +fast-diff@^1.1.2: + version "1.2.0" + resolved "https://registry.yarnpkg.com/fast-diff/-/fast-diff-1.2.0.tgz#73ee11982d86caaf7959828d519cfe927fac5f03" + integrity sha512-xJuoT5+L99XlZ8twedaRf6Ax2TgQVxvgZOYoPKqZufmJib0tL2tegPBOZb1pVNgIhlqDlA0eO0c3wBvQcmzx4w== + fast-glob@^2.0.2, fast-glob@^2.2.6: version "2.2.7" resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-2.2.7.tgz#6953857c3afa475fff92ee6015d52da70a4cd39d" @@ -10360,10 +10664,10 @@ fault@^1.0.0, fault@^1.0.1: dependencies: format "^0.2.0" -faye-websocket@~0.10.0: - version "0.10.0" - resolved "https://registry.yarnpkg.com/faye-websocket/-/faye-websocket-0.10.0.tgz#4e492f8d04dfb6f89003507f6edbf2d501e7c6f4" - integrity sha1-TkkvjQTftviQA1B/btvy1QHnxvQ= +faye-websocket@^0.11.3: + version "0.11.3" + resolved "https://registry.yarnpkg.com/faye-websocket/-/faye-websocket-0.11.3.tgz#5c0e9a8968e8912c286639fde977a8b209f2508e" + integrity sha512-D2y4bovYpzziGgbHYtGCMjlJM36vAl/y+xUyn1C+FVx8szd1E+86KwVw6XvYSzOP8iMpm1X0I4xJD+QtUb36OA== dependencies: websocket-driver ">=0.5.1" @@ -10430,6 +10734,13 @@ file-entry-cache@^6.0.0: dependencies: flat-cache "^3.0.4" +file-entry-cache@^6.0.1: + version "6.0.1" + resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-6.0.1.tgz#211b2dd9659cb0394b073e7323ac3c933d522027" + integrity sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg== + dependencies: + flat-cache "^3.0.4" + file-loader@^6.0.0: version "6.2.0" resolved "https://registry.yarnpkg.com/file-loader/-/file-loader-6.2.0.tgz#baef7cf8e1840df325e4390b4484879480eebe4d" @@ -10610,7 +10921,7 @@ find-up@^3.0.0: dependencies: locate-path "^3.0.0" -find-yarn-workspace-root@^1.1.0, find-yarn-workspace-root@^1.2.1: +find-yarn-workspace-root@^1.1.0: version "1.2.1" resolved "https://registry.yarnpkg.com/find-yarn-workspace-root/-/find-yarn-workspace-root-1.2.1.tgz#40eb8e6e7c2502ddfaa2577c176f221422f860db" integrity sha512-dVtfb0WuQG+8Ag2uWkbG79hOUzEsRrhBzgfn86g2sJPkzmcpGdghbNTfUKGTxymFrY/tLIodDzLoW9nOJ4FY8Q== @@ -10618,6 +10929,13 @@ find-yarn-workspace-root@^1.1.0, find-yarn-workspace-root@^1.2.1: fs-extra "^4.0.3" micromatch "^3.1.4" +find-yarn-workspace-root@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/find-yarn-workspace-root/-/find-yarn-workspace-root-2.0.0.tgz#f47fb8d239c900eb78179aa81b66673eac88f7bd" + integrity sha512-1IMnbjt4KzsQfnhnzNd8wUEgXZ44IzZaZmnLYx7D5FZlaHt2gW20Cri8Q+E/t5tIj4+epTBub+2Zxu/vNILzqQ== + dependencies: + micromatch "^4.0.2" + findup-sync@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/findup-sync/-/findup-sync-3.0.0.tgz#17b108f9ee512dfb7a5c7f3c8b27ea9e1a9c08d1" @@ -10760,13 +11078,6 @@ follow-redirects@^1.0.0: resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.13.2.tgz#dd73c8effc12728ba5cf4259d760ea5fb83e3147" integrity sha512-6mPTgLxYm3r6Bkkg0vNM0HTjfGrOEtsfbhagQvbxDEsEkpNhw582upBaoRZylzen6krEmxXJgt9Ju6HiI4O7BA== -for-each@^0.3.3: - version "0.3.3" - resolved "https://registry.yarnpkg.com/for-each/-/for-each-0.3.3.tgz#69b447e88a0a5d32c3e7084f3f1710034b21376e" - integrity sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw== - dependencies: - is-callable "^1.1.3" - for-in@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" @@ -11082,6 +11393,11 @@ fuse.js@^3.6.1: resolved "https://registry.yarnpkg.com/fuse.js/-/fuse.js-3.6.1.tgz#7de85fdd6e1b3377c23ce010892656385fd9b10c" integrity sha512-hT9yh/tiinkmirKrlv4KWOjztdoZo1mx9Qh4KvWqC7isoXwdUY3PNWUxceF4/qO9R6riA2C29jdTOeQOIROjgw== +fuse.js@^6.4.6: + version "6.4.6" + resolved "https://registry.yarnpkg.com/fuse.js/-/fuse.js-6.4.6.tgz#62f216c110e5aa22486aff20be7896d19a059b79" + integrity sha512-/gYxR/0VpXmWSfZOIPS3rWwU8SHgsRTwWuXhyb2O6s7aRuVtHtxCkR33bNYu3wyLyNx/Wpv0vU7FZy8Vj53VNw== + galactus@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/galactus/-/galactus-0.2.1.tgz#cbed2d20a40c1f5679a35908e2b9415733e78db9" @@ -11124,7 +11440,7 @@ genfun@^5.0.0: resolved "https://registry.yarnpkg.com/genfun/-/genfun-5.0.0.tgz#9dd9710a06900a5c4a5bf57aca5da4e52fe76537" integrity sha512-KGDOARWVga7+rnB3z9Sd2Letx515owfk0hSxHGuqjANb1M+x2bGZGqHLiozPsYMdM2OubeMni/Hpwmjq6qIUhA== -gensync@^1.0.0-beta.1: +gensync@^1.0.0-beta.1, gensync@^1.0.0-beta.2: version "1.0.0-beta.2" resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.2.tgz#32a6ee76c3d7f52d46b2b1ae5d93fea8580a25e0" integrity sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg== @@ -11276,23 +11592,11 @@ git-read-pkt-line@0.0.8: bops "0.0.3" through "~2.2.7" -git-repo-info@^1.4.1: - version "1.4.1" - resolved "https://registry.yarnpkg.com/git-repo-info/-/git-repo-info-1.4.1.tgz#2a072823254aaf62fcf0766007d7b6651bd41943" - integrity sha1-KgcoIyVKr2L88HZgB9e2ZRvUGUM= - git-repo-info@^2.0.0, git-repo-info@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/git-repo-info/-/git-repo-info-2.1.1.tgz#220ffed8cbae74ef8a80e3052f2ccb5179aed058" integrity sha512-8aCohiDo4jwjOwma4FmYFd3i97urZulL8XL24nIPxuE+GZnfsAyy/g2Shqx6OjUiFKUXZM+Yy+KHnOmmA3FVcg== -git-repo-version@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/git-repo-version/-/git-repo-version-1.0.2.tgz#2c8e9bee5d970cafc0dd58480f9dc56d9afe8e4f" - integrity sha512-OPtwtHx9E8/rTMcWT+BU6GNj6Kq/O40bHJZaZAGy+pN2RXGmeKcfr0ix4M+SQuFY8vl5L/wfPSGOAtvUT/e3Qg== - dependencies: - git-repo-info "^1.4.1" - git-transport-protocol@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/git-transport-protocol/-/git-transport-protocol-0.1.0.tgz#99f4dd6389b9161eded74a9e617d6ba5ed0a6c2c" @@ -11953,11 +12257,14 @@ he@1.2.0, he@^1.2.0: resolved "https://registry.yarnpkg.com/he/-/he-1.2.0.tgz#84ae65fa7eafb165fddb61566ae14baf05664f0f" integrity sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw== -heimdalljs-fs-monitor@^0.2.3: - version "0.2.3" - resolved "https://registry.yarnpkg.com/heimdalljs-fs-monitor/-/heimdalljs-fs-monitor-0.2.3.tgz#1aedd4b1c61d86c51f6141fb75c5a3350dc41b15" - integrity sha512-fYAvqSP0CxeOjLrt61B4wux/jqZzdZnS2xfb2oc14NP6BTZ8gtgtR2op6gKFakOR8lm8GN9Xhz1K4A1ZvJ4RQw== +heimdalljs-fs-monitor@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/heimdalljs-fs-monitor/-/heimdalljs-fs-monitor-1.1.0.tgz#0ad5aa1dac0a30d5940a74edeea3d515e70225e4" + integrity sha512-OH1LgPeqRo5kOzN5XhU/I4lUbqDqj0jx4+6vn33RTKcZTFmp/63KWbVrDDlk9iDlQ5j6FxmOeuoWJ2cjLjvNcQ== dependencies: + callsites "^3.1.0" + clean-stack "^2.2.0" + extract-stack "^2.0.0" heimdalljs "^0.2.3" heimdalljs-logger "^0.1.7" @@ -12002,21 +12309,11 @@ hmac-drbg@^1.0.0: minimalistic-assert "^1.0.0" minimalistic-crypto-utils "^1.0.1" -hoek@2.x.x: - version "2.16.3" - resolved "https://registry.yarnpkg.com/hoek/-/hoek-2.16.3.tgz#20bb7403d3cea398e91dc4710a8ff1b8274a25ed" - integrity sha1-ILt0A9POo5jpHcRxCo/xuCdKJe0= - -hoek@4.x.x: +hoek@2.x.x, hoek@4.x.x, hoek@6.x.x, hoek@~4.2.0: version "4.2.1" resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.1.tgz#9634502aa12c445dd5a7c5734b572bb8738aacbb" integrity sha512-QLg82fGkfnJ/4iy1xZ81/9SIJiq1NGFUMGs6ParyjBZr6jW2Ufj/snDqTHixNlHdPNwN2RLVD0Pi3igeK9+JfA== -hoek@6.x.x: - version "6.1.3" - resolved "https://registry.yarnpkg.com/hoek/-/hoek-6.1.3.tgz#73b7d33952e01fe27a38b0457294b79dd8da242c" - integrity sha512-YXXAAhmF9zpQbC7LEcREFtXfGq5K1fmd+4PHkBq8NUqmzW3G+Dq10bI/i0KucLRwss3YYFQ0fSfoxBZYiGUqtQ== - hoist-non-react-statics@^3.3.0: version "3.3.2" resolved "https://registry.yarnpkg.com/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz#ece0acaf71d62c2969c2ec59feff42a4b1a85b45" @@ -12546,7 +12843,7 @@ inquirer@^0.12.0: strip-ansi "^3.0.0" through "^2.3.6" -inquirer@^7.0.0, inquirer@^7.0.1: +inquirer@^7.0.0, inquirer@^7.3.3: version "7.3.3" resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-7.3.3.tgz#04d176b2af04afc157a83fd7c100e98ee0aad003" integrity sha512-JG3eIAj5V9CwcGvuOmoo6LB9kbAYT8HXffUl6memuszlwDC/qvFAJw49XJ5NROSFNPxp3iQg1GqkFhaY/CR0IA== @@ -12709,7 +13006,7 @@ is-buffer@^2.0.0: resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-2.0.5.tgz#ebc252e400d22ff8d77fa09888821a24a658c191" integrity sha512-i2R6zNFDwgEHJyQUtJEk0XFi1i0dPFn/oqjK3/vPCcDeJvW5NQ83V8QbicfF1SupOaB0h8ntgBC2YiE7dfyctQ== -is-callable@^1.1.3, is-callable@^1.1.4, is-callable@^1.2.2: +is-callable@^1.1.4, is-callable@^1.2.2: version "1.2.2" resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.2.2.tgz#c7c6715cd22d4ddb48d3e19970223aceabb080d9" integrity sha512-dnMqspv5nU3LoewK2N/y7KLtxtakvTuaCsU9FU50/QDmdbHNy/4/JuRtMHqRU22o3q+W89YQndQEeCVwK+3qrA== @@ -12735,7 +13032,7 @@ is-cidr@^3.0.0: dependencies: cidr-regex "^2.0.10" -is-core-module@^2.1.0: +is-core-module@^2.1.0, is-core-module@^2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.2.0.tgz#97037ef3d52224d85163f5597b2b63d9afed981a" integrity sha512-XRAfAdyyY5F5cOXn7hYQDqh2Xmii+DEfIcQGxK/uNwMHhIkPWO0g8msXcbzLe+MpGoR951MlqM/2iIlU4vKDdQ== @@ -12908,6 +13205,11 @@ is-lambda@^1.0.1: resolved "https://registry.yarnpkg.com/is-lambda/-/is-lambda-1.0.1.tgz#3d9877899e6a53efc0160504cde15f82e6f061d5" integrity sha1-PZh3iZ5qU+/AFgUEzeFfgubwYdU= +is-language-code@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/is-language-code/-/is-language-code-2.0.0.tgz#6f4d59c551d73b98c45cf9f1d3ce65cee060e65b" + integrity sha512-6xKmRRcP2YdmMBZMVS3uiJRPQgcMYolkD6hFw2Y4KjqyIyaJlCGxUt56tuu0iIV8q9r8kMEo0Gjd/GFwKrgjbw== + is-map@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/is-map/-/is-map-2.0.2.tgz#00922db8c9bf73e81b7a335827bc2a43f2b91127" @@ -13925,10 +14227,10 @@ linkify-it@~1.2.0: dependencies: uc.micro "^1.0.1" -livereload-js@^2.3.0: - version "2.4.0" - resolved "https://registry.yarnpkg.com/livereload-js/-/livereload-js-2.4.0.tgz#447c31cf1ea9ab52fc20db615c5ddf678f78009c" - integrity sha512-XPQH8Z2GDP/Hwz2PCDrh2mth4yFejwA1OZ/81Ti3LgKyhDcEjsSsqFWZojHG0va/duGd+WyosY7eXLDoOyqcPw== +livereload-js@^3.3.1: + version "3.3.1" + resolved "https://registry.yarnpkg.com/livereload-js/-/livereload-js-3.3.1.tgz#61f887468086762e61fb2987412cf9d1dda99202" + integrity sha512-CBu1gTEfzVhlOK1WASKAAJ9Qx1fHECTq0SUB67sfxwQssopTyvzqTlgl+c0h9pZ6V+Fzd2rc510ppuNusg9teQ== load-json-file@^1.0.0: version "1.1.0" @@ -14183,7 +14485,7 @@ lodash.defaults@^4.2.0: resolved "https://registry.yarnpkg.com/lodash.defaults/-/lodash.defaults-4.2.0.tgz#d09178716ffea4dde9e5fb7b37f6f0802274580c" integrity sha1-0JF4cW/+pN3p5ft7N/bwgCJ0WAw= -lodash.defaultsdeep@^4.6.0, lodash.defaultsdeep@^4.6.1: +lodash.defaultsdeep@^4.6.1: version "4.6.1" resolved "https://registry.yarnpkg.com/lodash.defaultsdeep/-/lodash.defaultsdeep-4.6.1.tgz#512e9bd721d272d94e3d3a63653fa17516741ca6" integrity sha512-3j8wdDzYuWO3lM3Reg03MuQR957t287Rpcxp1njpEa8oDrikb+FwGdW3n+FELh/A6qib6yPit0j/pv9G/yeAqA== @@ -14610,13 +14912,13 @@ markdown-it-terminal@0.2.1: lodash.merge "^4.6.2" markdown-it "^8.3.1" -markdown-it@^11.0.0: - version "11.0.1" - resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-11.0.1.tgz#b54f15ec2a2193efa66dda1eb4173baea08993d6" - integrity sha512-aU1TzmBKcWNNYvH9pjq6u92BML+Hz3h5S/QpfTFwiQF852pLT+9qHsrhM9JYipkOXZxGn+sGH8oyJE9FD9WezQ== +markdown-it@^12.0.2: + version "12.0.4" + resolved "https://registry.yarnpkg.com/markdown-it/-/markdown-it-12.0.4.tgz#eec8247d296327eac3ba9746bdeec9cfcc751e33" + integrity sha512-34RwOXZT8kyuOJy25oJNJoulO8L0bTHYWXcdZBYZqFnjIy3NgjeoM3FmPXIOFQ26/lSHYMr8oc62B6adxXcb3Q== dependencies: - argparse "^1.0.7" - entities "~2.0.0" + argparse "^2.0.1" + entities "~2.1.0" linkify-it "^3.0.1" mdurl "^1.0.1" uc.micro "^1.0.5" @@ -14767,6 +15069,11 @@ mdast-util-to-string@^2.0.0: resolved "https://registry.yarnpkg.com/mdast-util-to-string/-/mdast-util-to-string-2.0.0.tgz#b8cfe6a713e1091cb5b728fc48885a4767f8b97b" integrity sha512-AW4DRS3QbBayY/jJmD8437V1Gombjf8RSOUCMFBuo5iHi58AGEgVCKQ+ezHkZZDpAQS75hcBMpLqjpJTjtUL7w== +mdn-data@2.0.14: + version "2.0.14" + resolved "https://registry.yarnpkg.com/mdn-data/-/mdn-data-2.0.14.tgz#7113fc4281917d63ce29b43446f701e68c25ba50" + integrity sha512-dn6wd0uw5GsdswPFfsgMp5NSB0/aDe6fK94YJV/AJDYXL6HVLWBsxeq7js7Ad+mU2K9LAlwpk6kN2D5mwCPVow== + mdn-data@~1.1.0: version "1.1.4" resolved "https://registry.yarnpkg.com/mdn-data/-/mdn-data-1.1.4.tgz#50b5d4ffc4575276573c4eedb8780812a8419f01" @@ -15737,7 +16044,7 @@ npm-package-arg@^7.0.0: semver "^5.6.0" validate-npm-package-name "^3.0.0" -npm-package-arg@^8.0.0, npm-package-arg@^8.0.1: +npm-package-arg@^8.0.0: version "8.1.0" resolved "https://registry.yarnpkg.com/npm-package-arg/-/npm-package-arg-8.1.0.tgz#b5f6319418c3246a1c38e1a8fbaa06231bc5308f" integrity sha512-/ep6QDxBkm9HvOhOg0heitSd7JHA1U7y1qhhlRlteYYAi9Pdb/ZV7FW5aHpkrpM8+P+4p/jjR8zCyKPBMBjSig== @@ -15746,6 +16053,15 @@ npm-package-arg@^8.0.0, npm-package-arg@^8.0.1: semver "^7.0.0" validate-npm-package-name "^3.0.0" +npm-package-arg@^8.1.0: + version "8.1.1" + resolved "https://registry.yarnpkg.com/npm-package-arg/-/npm-package-arg-8.1.1.tgz#00ebf16ac395c63318e67ce66780a06db6df1b04" + integrity sha512-CsP95FhWQDwNqiYS+Q0mZ7FAEDytDZAkNxQqea6IaAFJTAY9Lhhqyl0irU/6PMc7BGfUmnsbHcqxJD7XuVM/rg== + dependencies: + hosted-git-info "^3.0.6" + semver "^7.0.0" + validate-npm-package-name "^3.0.0" + npm-packlist@^1.1.12, npm-packlist@^1.1.6, npm-packlist@^1.4.6, npm-packlist@^1.4.8: version "1.4.8" resolved "https://registry.yarnpkg.com/npm-packlist/-/npm-packlist-1.4.8.tgz#56ee6cc135b9f98ad3d51c1c95da22bbb9b2ef3e" @@ -16099,7 +16415,7 @@ object.entries@^1.1.0: es-abstract "^1.18.0-next.1" has "^1.0.3" -object.getownpropertydescriptors@^2.0.3, object.getownpropertydescriptors@^2.1.0, object.getownpropertydescriptors@^2.1.1: +object.getownpropertydescriptors@^2.0.3, object.getownpropertydescriptors@^2.1.0: version "2.1.1" resolved "https://registry.yarnpkg.com/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.1.tgz#0dfda8d108074d9c563e80490c883b6661091544" integrity sha512-6DtXgZ/lIZ9hqx4GtZETobXLR/ZLaa0aqV0kzbn80Rf8Z2e/XFnhA0I7p07N2wH8bBBltr2xQPi6sbKWAY2Eng== @@ -16904,7 +17220,7 @@ polished@^3.4.4: dependencies: "@babel/runtime" "^7.9.2" -portfinder@^1.0.25, portfinder@^1.0.26: +portfinder@^1.0.25, portfinder@^1.0.28: version "1.0.28" resolved "https://registry.yarnpkg.com/portfinder/-/portfinder-1.0.28.tgz#67c4622852bd5374dd1dd900f779f53462fac778" integrity sha512-Se+2isanIcEqf2XMHjyUKskczxbPH7dQnlMjXX6+dybayyHvAf/TCgyMRlzf/B6QDhAEFOGes0pzRo3by4AbMA== @@ -17087,7 +17403,14 @@ pretender@^3.4.3: fake-xml-http-request "^2.1.1" route-recognizer "^0.3.3" -prettier@^2.0.5, prettier@^2.1.2: +prettier-linter-helpers@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/prettier-linter-helpers/-/prettier-linter-helpers-1.0.0.tgz#d23d41fe1375646de2d0104d3454a3008802cf7b" + integrity sha512-GbK2cP9nraSSUF9N2XwUwqfzlAFlMNYYl+ShE/V+H8a9uNl/oUqB1w2EL54Jh0OlyRSd8RfWYJ3coVS4TROP2w== + dependencies: + fast-diff "^1.1.2" + +prettier@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.2.1.tgz#795a1a78dd52f073da0cd42b21f9c91381923ff5" integrity sha512-PqyhM2yCjg/oKkFPtTGUojv7gnZAoG80ttl45O6x2Ug/rMJw4wcc9k6aaf2hibP7BGVCCM33gZoGjyvt9mm16Q== @@ -17229,7 +17552,7 @@ promise.allsettled@^1.0.0: get-intrinsic "^1.0.2" iterate-value "^1.0.2" -promise.hash.helper@^1.0.6: +promise.hash.helper@^1.0.7: version "1.0.7" resolved "https://registry.yarnpkg.com/promise.hash.helper/-/promise.hash.helper-1.0.7.tgz#2f39d8495df40dcdfbc1d5be9e9e56efeae7f180" integrity sha512-0qhWYyCV9TYDMSooYw1fShIb7R6hsWYja7JLqbeb1MvHqDTvP/uy/R1RsyVqDi6GCiHOI4G5p2Hpr3IA+/l/+Q== @@ -17428,7 +17751,7 @@ quick-temp@^0.1.2, quick-temp@^0.1.3, quick-temp@^0.1.5, quick-temp@^0.1.8: rimraf "^2.5.4" underscore.string "~3.3.4" -qunit-dom@^1.2.0: +qunit-dom@^1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/qunit-dom/-/qunit-dom-1.6.0.tgz#a4bea6a46329d221e4a317d712cb40709107b977" integrity sha512-YwSqcLjQcRI0fUFpaSWwU10KIJPFW5Qh+d3cT5DOgx81dypRuUSiPkKFmBY/CDs/R1KdHRadthkcXg2rqAon8Q== @@ -17438,7 +17761,7 @@ qunit-dom@^1.2.0: ember-cli-babel "^7.23.0" ember-cli-version-checker "^5.1.1" -qunit@^2.9.3: +qunit@^2.13.0: version "2.14.0" resolved "https://registry.yarnpkg.com/qunit/-/qunit-2.14.0.tgz#6f913903e71ebe24ef4a4dada2b796fb52285051" integrity sha512-CYfenbgdpmhl2Ql2rDrrj0felY4h8k6lYhtWwGBCLL4qQC33YOj0psV8MWo85L1i0SIOmEDRXkFopWnGCLmf7g== @@ -18485,6 +18808,14 @@ resolve@^1.1.6, resolve@^1.10.0, resolve@^1.10.1, resolve@^1.11.1, resolve@^1.12 is-core-module "^2.1.0" path-parse "^1.0.6" +resolve@^1.20.0: + version "1.20.0" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.20.0.tgz#629a013fb3f70755d6f0b7935cc1c2c5378b1975" + integrity sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A== + dependencies: + is-core-module "^2.2.0" + path-parse "^1.0.6" + responselike@1.0.2, responselike@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/responselike/-/responselike-1.0.2.tgz#918720ef3b631c5642be068f15ade5a46f4ba1e7" @@ -19252,10 +19583,10 @@ sort-object-keys@^1.1.3: resolved "https://registry.yarnpkg.com/sort-object-keys/-/sort-object-keys-1.1.3.tgz#bff833fe85cab147b34742e45863453c1e190b45" integrity sha512-855pvK+VkU7PaKYPc+Jjnmt4EzejQHyhhF33q31qG8x7maDzkeFhAAThdCYay11CISO+qAMwjOBP+fPZe0IPyg== -sort-package-json@^1.44.0: - version "1.48.1" - resolved "https://registry.yarnpkg.com/sort-package-json/-/sort-package-json-1.48.1.tgz#58629823da53a3ccccc049cb7e7300bc23072b33" - integrity sha512-YvDm1iBzhphfXtctTS0XIBlIW/2N1DZNHx3YMcZnptpZhchqH4zazUOuEWmjfNXndwamITMt9hFPliqwx1SHvQ== +sort-package-json@^1.48.0: + version "1.49.0" + resolved "https://registry.yarnpkg.com/sort-package-json/-/sort-package-json-1.49.0.tgz#82845ab598501bb35875f326e4768a5ab5f15335" + integrity sha512-3YuqFGThwc9X0TZLYohOUJJ/P6uJIVcTeuJOc6ZWw4f1fHpTHIfVysKer4qXtrZ2zvwwU2aEcb555Bo+2fwIgQ== dependencies: detect-indent "^6.0.0" detect-newline "3.1.0" @@ -19300,7 +19631,7 @@ source-map-support@^0.4.15: dependencies: source-map "^0.5.6" -source-map-support@^0.5.13, source-map-support@^0.5.16, source-map-support@~0.5.12: +source-map-support@^0.5.13, source-map-support@^0.5.16, source-map-support@~0.5.12, source-map-support@~0.5.19: version "0.5.19" resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.19.tgz#a98b62f86dcaf4f67399648c085291ab9e8fed61" integrity sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw== @@ -19335,7 +19666,7 @@ source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.0, source-map@~0.6.1: resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== -source-map@^0.7.3: +source-map@^0.7.3, source-map@~0.7.2: version "0.7.3" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.3.tgz#5302f8169031735226544092e64981f751750383" integrity sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ== @@ -20149,11 +20480,12 @@ temp-dir@^2.0.0: resolved "https://registry.yarnpkg.com/temp-dir/-/temp-dir-2.0.0.tgz#bde92b05bdfeb1516e804c9c00ad45177f31321e" integrity sha512-aoBAniQmmwtcKp/7BzsH8Cxzv8OL736p7v1ihGb5e9DJ9kTwGWHrQrVB5+lfVDzfGrdRzXch+ig7LHaY1JTOrg== -temp@0.9.1: - version "0.9.1" - resolved "https://registry.yarnpkg.com/temp/-/temp-0.9.1.tgz#2d666114fafa26966cd4065996d7ceedd4dd4697" - integrity sha512-WMuOgiua1xb5R56lE0eH6ivpVmg/lq2OHm4+LtT/xtEtPQ+sz6N3bBM6WZ5FvO1lO4IKIOb43qnhoc4qxP5OeA== +temp@0.9.4: + version "0.9.4" + resolved "https://registry.yarnpkg.com/temp/-/temp-0.9.4.tgz#cd20a8580cb63635d0e4e9d4bd989d44286e7620" + integrity sha512-yYrrsWnrXMcdsnu/7YMYAofM1ktpL5By7vZhf15CrXijWWrEYZks5AXBudalfSWJLlnen/QUJUB5aoB0kqZUGA== dependencies: + mkdirp "^0.5.1" rimraf "~2.6.2" term-size@^1.2.0: @@ -20198,7 +20530,7 @@ terser-webpack-plugin@^3.0.0: terser "^4.8.0" webpack-sources "^1.4.3" -terser@^4.1.2, terser@^4.3.9, terser@^4.6.3, terser@^4.8.0: +terser@^4.1.2, terser@^4.6.3, terser@^4.8.0: version "4.8.0" resolved "https://registry.yarnpkg.com/terser/-/terser-4.8.0.tgz#63056343d7c70bb29f3af665865a46fe03a0df17" integrity sha512-EAPipTNeWsb/3wLPeup1tVPaXfIaU68xMnVdPafIL1TV05OhASArYyIfFvnvJCNrR2NIOvDVNNTFRa+Re2MWyw== @@ -20207,6 +20539,15 @@ terser@^4.1.2, terser@^4.3.9, terser@^4.6.3, terser@^4.8.0: source-map "~0.6.1" source-map-support "~0.5.12" +terser@^5.3.0: + version "5.6.0" + resolved "https://registry.yarnpkg.com/terser/-/terser-5.6.0.tgz#138cdf21c5e3100b1b3ddfddf720962f88badcd2" + integrity sha512-vyqLMoqadC1uR0vywqOZzriDYzgEkNJFK4q9GeyOBHIbiECHiWLKcWfbQWAUaPfxkjDhapSlZB9f7fkMrvkVjA== + dependencies: + commander "^2.20.0" + source-map "~0.7.2" + source-map-support "~0.5.19" + test-exclude@^6.0.0: version "6.0.0" resolved "https://registry.yarnpkg.com/test-exclude/-/test-exclude-6.0.0.tgz#04a8698661d805ea6fa293b6cb9e63ac044ef15e" @@ -20216,7 +20557,7 @@ test-exclude@^6.0.0: glob "^7.1.4" minimatch "^3.0.4" -testem@^3.1.0: +testem@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/testem/-/testem-3.2.0.tgz#9924481f6a3b23e350fa77bb251c64d801c4c9a7" integrity sha512-FkFzNRCIzCxjbNSTxIQSC2tWn1Q2MTR/GTxusSw6uZA4byEQ7wc86TKutNnoCyZ5XIaD9wo4q+dmlK0GUEqFVA== @@ -20350,15 +20691,15 @@ tiny-glob@0.2.8: globalyzer "0.1.0" globrex "^0.1.2" -tiny-lr@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/tiny-lr/-/tiny-lr-1.1.1.tgz#9fa547412f238fedb068ee295af8b682c98b2aab" - integrity sha512-44yhA3tsaRoMOjQQ+5v5mVdqef+kH6Qze9jTpqtVufgYjYt08zyZAwNwwVBj3i1rJMnR52IxOW0LK0vBzgAkuA== +tiny-lr@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/tiny-lr/-/tiny-lr-2.0.0.tgz#863659d7ce1ed201a117d8197d7f8b9a27bdc085" + integrity sha512-f6nh0VMRvhGx4KCeK1lQ/jaL0Zdb5WdR+Jk8q9OSUQnaSDxAEGH1fgqLZ+cMl5EW3F2MGnCsalBO1IsnnogW1Q== dependencies: body "^5.1.0" debug "^3.1.0" - faye-websocket "~0.10.0" - livereload-js "^2.3.0" + faye-websocket "^0.11.3" + livereload-js "^3.3.1" object-assign "^4.1.0" qs "^6.4.0" @@ -21158,17 +21499,6 @@ util.promisify@1.0.0: define-properties "^1.1.2" object.getownpropertydescriptors "^2.0.3" -util.promisify@^1.0.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/util.promisify/-/util.promisify-1.1.1.tgz#77832f57ced2c9478174149cae9b96e9918cd54b" - integrity sha512-/s3UsZUrIfa6xDhr7zZhnE9SLQ5RIXyYfiVnMMyMDzOc8WhWN4Nbh36H842OyurKbCDAesZOJaVyvmSl6fhGQw== - dependencies: - call-bind "^1.0.0" - define-properties "^1.1.3" - for-each "^0.3.3" - has-symbols "^1.0.1" - object.getownpropertydescriptors "^2.1.1" - util.promisify@~1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/util.promisify/-/util.promisify-1.0.1.tgz#6baf7774b80eeb0f7520d8b81d07982a59abbaee" @@ -21215,7 +21545,7 @@ uuid@^3.1.0, uuid@^3.3.2, uuid@^3.3.3: resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.4.0.tgz#b23e4358afa8a202fe7a100af1f5f883f02007ee" integrity sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A== -uuid@^8.0.0, uuid@^8.1.0, uuid@^8.3.0: +uuid@^8.0.0, uuid@^8.3.0, uuid@^8.3.1: version "8.3.2" resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== @@ -21240,6 +21570,14 @@ validate-npm-package-name@^3.0.0, validate-npm-package-name@~3.0.0: dependencies: builtins "^1.0.3" +validate-peer-dependencies@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/validate-peer-dependencies/-/validate-peer-dependencies-1.1.0.tgz#8240a115df121ea35b0bb082255b38b5c591d7e1" + integrity sha512-eHHxI3fNMqu8bzWPRWWgV72kBJkWwRCeEua7yC7UI6dsqC55orhxKAC3uyQfCjjToOyAZ8mpNrbQH+NMoYBn1w== + dependencies: + resolve-package-path "^3.1.0" + semver "^7.3.2" + vary@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/vary/-/vary-1.1.2.tgz#2299f02c6ded30d4a5961b0b9f74524a18f634fc" @@ -21646,12 +21984,7 @@ workerpool@^3.1.1: object-assign "4.1.1" rsvp "^4.8.4" -workerpool@^5.0.1: - version "5.0.4" - resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-5.0.4.tgz#4f67cb70ff7550a27ab94de25b0b843cd92059a2" - integrity sha512-Sywova24Ow2NQ24JPB68bI89EdqMDjUXo4OpofK/QMD7C2ZVMloYBgQ5J3PChcBJHj2vspsmGx1/3nBKXtUkXQ== - -workerpool@^6.0.3: +workerpool@^6.0.0, workerpool@^6.0.3: version "6.1.0" resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-6.1.0.tgz#a8e038b4c94569596852de7a8ea4228eefdeb37b" integrity sha512-toV7q9rWNYha963Pl/qyeZ6wG+3nnsyvolaNUS8+R5Wtw6qJPTxIlOP1ZSvcGhEJw+l3HMMmtiNo9Gl61G4GVg==