Skip to content

Commit

Permalink
Merge pull request #501 from ember-learn/revive
Browse files Browse the repository at this point in the history
[lts-v3] basic updates to get it running again
  • Loading branch information
mansona authored Jan 26, 2024
2 parents 3d52103 + f348b07 commit 6216711
Show file tree
Hide file tree
Showing 126 changed files with 19,353 additions and 16,349 deletions.
1 change: 0 additions & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

root = true


[*]
end_of_line = lf
charset = utf-8
Expand Down
2 changes: 2 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
# misc
/coverage/
!.*
.*/
.eslintcache

# ember-try
/.node_modules.ember-try/
Expand Down
63 changes: 31 additions & 32 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,54 +1,53 @@
'use strict';

module.exports = {
root: true,
parser: 'babel-eslint',
parserOptions: {
ecmaVersion: 2017,
sourceType: 'module'
ecmaVersion: 2018,
sourceType: 'module',
ecmaFeatures: {
legacyDecorators: true,
},
},
plugins: [
'ember'
],
plugins: ['ember'],
extends: [
'eslint:recommended',
'plugin:ember/recommended'
'plugin:ember/recommended',
'plugin:prettier/recommended',
],
env: {
browser: true
},
rules: {
'no-useless-escape': 'off'
browser: true,
},
rules: {},
overrides: [
// node files
{
files: [
'.eslintrc.js',
'.stylelintrc.js',
'.template-lintrc.js',
'ember-cli-build.js',
'index.js',
'testem.js',
'blueprints/*/index.js',
'config/**/*.js',
'tests/dummy/config/**/*.js'
],
excludedFiles: [
'addon/**',
'addon-test-support/**',
'app/**',
'tests/dummy/app/**'
'./.eslintrc.js',
'./.prettierrc.js',
'./.template-lintrc.js',
'./ember-cli-build.js',
'./index.js',
'./testem.js',
'./blueprints/*/index.js',
'./config/**/*.js',
'./tests/dummy/config/**/*.js',
],
parserOptions: {
sourceType: 'script',
ecmaVersion: 2015
},
env: {
browser: false,
node: true
node: true,
},
plugins: ['node'],
rules: Object.assign({}, require('eslint-plugin-node').configs.recommended.rules, {
// add your custom rules and overrides for node files here
})
}
]
extends: ['plugin:node/recommended'],
},
{
// Test files:
files: ['tests/**/*-test.{js,ts}'],
extends: ['plugin:qunit/recommended'],
},
],
};
70 changes: 70 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
name: CI

on:
push:
branches:
- lts-v3
pull_request: {}

concurrency:
group: ci-${{ github.head_ref || github.ref }}
cancel-in-progress: true

jobs:
test:
name: "Tests"
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18.x
cache: pnpm
- run: pnpm i --frozen-lockfile
- run: pnpm run test:ember

floating:
name: "Floating Dependencies"
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18.x
cache: pnpm
- run: pnpm install --no-lockfile
- run: pnpm run test:ember

try-scenarios:
name: ${{ matrix.try-scenario }}
runs-on: ubuntu-latest
needs: 'test'

strategy:
fail-fast: false
matrix:
try-scenario:
- ember-lts-3.28
- embroider-safe
- embroider-optimized

steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: 8
- uses: actions/setup-node@v4
with:
node-version: 18.x
cache: pnpm
- run: pnpm i --frozen-lockfile
- name: Run Tests
run: pnpm ember try:one ${{ matrix.try-scenario }}
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@
/node_modules/

# misc
/.env*
/.pnp*
/.sass-cache
/.eslintcache
/connect.lock
/coverage/
/libpeerconnection.log
Expand Down
7 changes: 7 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,24 @@
/.bowerrc
/.editorconfig
/.ember-cli
/.env*
/.eslintcache
/.eslintignore
/.eslintrc.js
/.git/
/.gitignore
/.prettierignore
/.prettierrc.js
/.template-lintrc.js
/.travis.yml
/.watchmanconfig
/bower.json
/config/ember-try.js
/CONTRIBUTING.md
/ember-cli-build.js
/testem.js
/tests/
/yarn-error.log
/yarn.lock
.gitkeep

Expand Down
21 changes: 21 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -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
5 changes: 5 additions & 0 deletions .prettierrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
'use strict';

module.exports = {
singleQuote: true,
};
51 changes: 0 additions & 51 deletions .travis.yml

This file was deleted.

25 changes: 25 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# How To Contribute

## Installation

* `git clone <repository-url>`
* `cd ember-styleguide`
* `npm install`

## Linting

* `npm run lint`
* `npm run lint:fix`

## Running tests

* `ember test` – Runs the test suite on the current Ember version
* `ember test --server` – Runs the test suite in "watch mode"
* `ember try:each` – Runs the test suite against multiple Ember versions

## Running the dummy application

* `ember serve`
* Visit the dummy application at [http://localhost:4200](http://localhost:4200).

For more information on using ember-cli, visit [https://ember-cli.com/](https://ember-cli.com/).
File renamed without changes.
6 changes: 1 addition & 5 deletions addon/components/es-accordion.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import Component from '@ember/component';
import layout from '../templates/components/es-accordion';
import {
get,
getProperties,
Expand All @@ -14,10 +13,7 @@ import {
} from '@ember/array';

export default Component.extend({
layout,

classNames: ['accordion-group'],

activeItem: null,
focusIndex: null,
accordionItemIndexes: null,
Expand Down Expand Up @@ -128,5 +124,5 @@ export default Component.extend({
registerIndex(accordionItemIndex) {
get(this, 'accordionItemIndexes').push(accordionItemIndex);
},
},
}
});
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
<div class="accordion-heading {{if isExpanded "active"}}">
<div class="accordion-heading {{if this.isExpanded "active"}}">
<div class="content" data-role="title">
{{title}}
{{this.title}}
</div>
<div class="content" data-role="availability">
Avail: <span class="content-sub">{{availabilityMessage}}</span>
Avail: <span class="content-sub">{{this.availabilityMessage}}</span>
</div>
<div class="content">
Status:
<span class="content-sub text-{{statusTextColor}}" data-role="status">
<i class="fa {{statusIcon}}"></i>
{{statusLabel}}
<span class="content-sub text-{{this.statusTextColor}}" data-role="status">
<i class="fa {{this.statusIcon}}"></i>
{{this.statusLabel}}
</span>
</div>
<button
class="button-icon"
data-role="accordion-item-button"
aria-label="expand collapse"
aria-expanded={{isExpanded}}
aria-expanded={{this.isExpanded}}
>
<i class="fa fa-chevron-down" aria-hidden="true"></i>
</button>
</div>
<div class="accordion-body {{unless isExpanded "collapse"}}">
<div class="accordion-body {{unless this.isExpanded "collapse"}}">
<div class="accordion-content">
{{yield}}
</div>
Expand Down
6 changes: 1 addition & 5 deletions addon/components/es-accordion/es-item.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import Component from '@ember/component';
import layout from '../../templates/components/es-accordion/es-item';
import {
get,
getProperties,
Expand All @@ -19,10 +18,7 @@ import {
} from '@ember/utils';

export default Component.extend({
layout,

classNames: ['accordion'],

accordionState: null,
availability: null,
accordionItemIndex: null,
Expand Down Expand Up @@ -127,5 +123,5 @@ export default Component.extend({
}

setActiveItem(index);
},
}
});
File renamed without changes.
Loading

0 comments on commit 6216711

Please sign in to comment.