Skip to content

Commit

Permalink
chore: prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
knownasilya committed Oct 6, 2020
1 parent c832b5f commit 94098b8
Show file tree
Hide file tree
Showing 22 changed files with 369 additions and 170 deletions.
62 changes: 31 additions & 31 deletions config/ember-try.js
Expand Up @@ -2,85 +2,85 @@

const getChannelURL = require('ember-source-channel-url');

module.exports = async function() {
module.exports = async function () {
return {
useYarn: true,
scenarios: [
{
name: 'ember-lts-3.12',
npm: {
devDependencies: {
'ember-source': '~3.12.0'
}
}
'ember-source': '~3.12.0',
},
},
},
{
name: 'ember-lts-3.16',
npm: {
devDependencies: {
'ember-source': '~3.16.0'
}
}
'ember-source': '~3.16.0',
},
},
},
{
name: 'ember-lts-3.20',
npm: {
devDependencies: {
'ember-source': '~3.20.5'
}
}
'ember-source': '~3.20.5',
},
},
},
{
name: 'ember-release',
npm: {
devDependencies: {
'ember-source': await getChannelURL('release')
}
}
'ember-source': await getChannelURL('release'),
},
},
},
{
name: 'ember-beta',
npm: {
devDependencies: {
'ember-source': await getChannelURL('beta')
}
}
'ember-source': await getChannelURL('beta'),
},
},
},
{
name: 'ember-canary',
npm: {
devDependencies: {
'ember-source': await getChannelURL('canary')
}
}
'ember-source': await getChannelURL('canary'),
},
},
},
{
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',
env: {
EMBER_OPTIONAL_FEATURES: JSON.stringify({
'application-template-wrapper': true,
'default-async-observers': false,
'template-only-glimmer-components': false
})
'template-only-glimmer-components': false,
}),
},
npm: {
ember: {
edition: 'classic'
}
}
edition: 'classic',
},
},
},
{
name: 'embroider-tests',
Expand All @@ -91,7 +91,7 @@ module.exports = async function() {
'@embroider/compat': '*',
},
},
}
]
},
],
};
};
4 changes: 2 additions & 2 deletions config/environment.js
@@ -1,5 +1,5 @@
'use strict';

module.exports = function(/* environment, appConfig */) {
return { };
module.exports = function (/* environment, appConfig */) {
return {};
};
3 changes: 3 additions & 0 deletions package.json
Expand Up @@ -24,6 +24,8 @@
"test": "npm-run-all lint:* test:*",
"test:ember": "ember test",
"test:ember-compatibility": "ember try:each",
"format:hbs": "prettier **/*.hbs --write --parser=glimmer",
"format:js": "prettier **/*.js --write",
"release": "standard-version"
},
"dependencies": {
Expand Down Expand Up @@ -64,6 +66,7 @@
"eslint-plugin-node": "^11.1.0",
"loader.js": "^4.7.0",
"npm-run-all": "^4.1.5",
"prettier": "^2.1.2",
"sass": "^1.26.0",
"standard-version": "^9.0.0"
},
Expand Down
4 changes: 2 additions & 2 deletions tests/blanket-options.js
Expand Up @@ -8,8 +8,8 @@ var options = {
enableCoverage: true,
cliOptions: {
reporters: ['lcov'],
autostart: true
}
autostart: true,
},
};
if (typeof exports === 'undefined') {
blanket.options(options);
Expand Down
6 changes: 5 additions & 1 deletion tests/dummy/app/components/boolean-field/template.hbs
@@ -1 +1,5 @@
{{#if @value}}true{{else}}false{{/if}}
{{#if @value}}
true
{{else}}
false
{{/if}}
Expand Up @@ -16,4 +16,4 @@
{{yield value}}
</PageTitlePane::Matryoshka>
{{/if}}
</PageTitlePane::NestedTemplate>
</PageTitlePane::NestedTemplate>
37 changes: 25 additions & 12 deletions tests/dummy/app/components/page-title-pane/template.hbs
@@ -1,22 +1,35 @@
<div class="window-pane has-title">
<div class='window-pane has-title'>
<header>
<span class="close button"></span>
<span class="minimize button"></span>
<span class="maximize button"></span>
<span class='close button'></span>
<span class='minimize button'></span>
<span class='maximize button'></span>
{{#each this.titleList.sortedTokens as |token idx|}}
<span
role="button"
class={{concat "title-token" " " (if token.active "active")}}
{{on "click" (fn this.highlight token)}}
role='button'
class={{concat 'title-token' ' ' (if token.active 'active')}}
{{on 'click' (fn this.highlight token)}}
>
{{token.title}}
</span>
{{#if (lt idx this.lastIndex)}}{{token.separator}}{{/if}}
{{#if (lt idx this.lastIndex)}}
{{token.separator}}
{{/if}}
{{/each}}
</header>
<div>
{{yield (hash
template=(component "page-title-pane/nested-template" titleList=this.titleList onactivate=(fn this.highlight))
matryoshka=(component "page-title-pane/matryoshka" titleList=this.titleList onactivate=(fn this.highlight)))}}
{{yield
(hash
template=(component
'page-title-pane/nested-template'
titleList=this.titleList
onactivate=(fn this.highlight)
)
matryoshka=(component
'page-title-pane/matryoshka'
titleList=this.titleList
onactivate=(fn this.highlight)
)
)
}}
</div>
</div>
</div>
13 changes: 7 additions & 6 deletions tests/dummy/app/components/text-field/template.hbs
@@ -1,13 +1,14 @@
{{!template-lint-disable no-action}}
{{!TODO fix actions when migrating to Glimmer component}}
<input type="text"
<input
type='text'
id={{this.inputId}}
name={{this.name}}
placeholder={{this.placeholder}}
autocomplete="off"
{{on "click" (action "blackHole")}}
{{on "paste" (action "reformat")}}
{{on "change" (action "reformat")}}
{{on "input" (action "reformat")}}
autocomplete='off'
disabled={{this.disabled}}
{{on 'click' (action 'blackHole')}}
{{on 'paste' (action 'reformat')}}
{{on 'change' (action 'reformat')}}
{{on 'input' (action 'reformat')}}
/>
15 changes: 7 additions & 8 deletions tests/dummy/app/components/window-pane/style.scss
@@ -1,7 +1,6 @@
.window-pane {
position: relative;
margin: 0 auto;
max-width: 500px;

transition: all 250ms;
box-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
Expand All @@ -21,7 +20,7 @@
border-bottom: 1px solid #444;

.button {
transition: all .2s;
transition: all 0.2s;
position: absolute;
border-radius: 6px;
width: 12px;
Expand All @@ -48,12 +47,12 @@
& > div {
min-height: 250px;
background: $black;
color: #FFF;
color: #fff;
padding: 20px;
overflow: auto;

.ps1 {
color: #9B9B9B;
color: #9b9b9b;
}

code {
Expand All @@ -62,11 +61,11 @@
}

.ps1 {
color: #AAAAAA;
color: #aaaaaa;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
}
}

Expand Down
8 changes: 4 additions & 4 deletions tests/dummy/app/components/window-pane/template.hbs
@@ -1,8 +1,8 @@
<div class={{concat "window-pane" (if @title " has-title")}}>
<div class={{concat 'window-pane' (if @title ' has-title')}}>
<header>
<span class="close button"></span>
<span class="minimize button"></span>
<span class="maximize button"></span>
<span class='close button'></span>
<span class='minimize button'></span>
<span class='maximize button'></span>
{{@title}}
</header>
<div>
Expand Down

0 comments on commit 94098b8

Please sign in to comment.