diff --git a/carbon-components-ember/package.json b/carbon-components-ember/package.json
index 31b3d0cb..e87eac2a 100644
--- a/carbon-components-ember/package.json
+++ b/carbon-components-ember/package.json
@@ -91,7 +91,6 @@
"ember-power-select": "^8.2.0",
"ember-ref-modifier": "^1.0.0",
"ember-resize-modifier": "^0.6.0",
- "ember-simple-mu-resolver": "^0.1.11",
"ember-template-imports": "^3.4.2",
"ember-template-lint-plugin-prettier": "^4.2.0",
"ember-tooltips": "^3.6.0",
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 0ecf9383..45fb1851 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -202,9 +202,6 @@ importers:
ember-resize-modifier:
specifier: ^0.6.0
version: 0.6.0(@babel/core@7.24.7)(@glint/template@1.4.0)(ember-source@5.10.0)(webpack@5.92.1)
- ember-simple-mu-resolver:
- specifier: ^0.1.11
- version: 0.1.12(@babel/core@7.24.7)
ember-template-imports:
specifier: ^3.4.2
version: 3.4.2
@@ -753,8 +750,8 @@ importers:
specifier: ^10.1.1
version: 10.1.1(@ember/string@3.1.1)(ember-source@5.10.0)
ember-routable-component:
- specifier: ^0.2.0
- version: 0.2.0
+ specifier: ^1.1.0
+ version: 1.2.0(ember-source@5.10.0)
ember-source:
specifier: ^5.9.0
version: 5.10.0(@glimmer/component@1.1.2)(@glint/template@1.4.0)(rsvp@4.8.5)(webpack@5.92.1)
@@ -795,10 +792,10 @@ importers:
specifier: ^4.7.0
version: 4.7.0
prettier:
- specifier: ^3.2.5
+ specifier: ^3.3.2
version: 3.3.2
prettier-plugin-ember-template-tag:
- specifier: ^2.0.1
+ specifier: ^2.0.2
version: 2.0.2(prettier@3.3.2)
puppeteer-chromium-resolver:
specifier: ^22.0.0
@@ -822,7 +819,7 @@ importers:
specifier: ^3.1.1
version: 3.3.0
vite:
- specifier: ^5.3.1
+ specifier: ^5.1.6
version: 5.3.3
webpack:
specifier: ^5.90.3
@@ -13036,14 +13033,6 @@ packages:
/ember-rfc176-data@0.3.18:
resolution: {integrity: sha512-JtuLoYGSjay1W3MQAxt3eINWXNYYQliK90tLwtb8aeCuQK8zKGCRbBodVIrkcTqshULMnRuTOS6t1P7oQk3g6Q==}
- /ember-routable-component@0.2.0:
- resolution: {integrity: sha512-H9dF+qy5cdxHE/OIantBC1gpwQzNxvsnfBbGU2aR2WMHZONXkW/Y1OrjaJMFfvL0Kmt0wlHYlnNF2qDlhQ4jJg==}
- dependencies:
- '@embroider/addon-shim': 1.8.9
- transitivePeerDependencies:
- - supports-color
- dev: true
-
/ember-routable-component@1.2.0(ember-source@5.10.0):
resolution: {integrity: sha512-BzDt/RUkQp0oyKQPrMCPrqGEgj8/f+z2Sp/BWy9vFaI3dEaNI58H9sC1RSzrWXcqGHNwIZbCA79YbLTsu9nEWg==}
peerDependencies:
@@ -13086,18 +13075,6 @@ packages:
- supports-color
dev: true
- /ember-simple-mu-resolver@0.1.12(@babel/core@7.24.7):
- resolution: {integrity: sha512-oDfZrvKRsmy68Kl57973l+KOAXn6LRSVeGuEjsxAZbCsNjVWu2Qcg/DudlTq5gUZg7WOpCTBf9X+1OEqswUPUg==}
- engines: {node: 6.* || 8.* || >= 10.*}
- dependencies:
- '@glimmer/component': 1.1.2(@babel/core@7.24.7)
- broccoli-persistent-filter: 2.3.1
- ember-cli-babel: 7.26.11
- transitivePeerDependencies:
- - '@babel/core'
- - supports-color
- dev: false
-
/ember-source-channel-url@3.0.0:
resolution: {integrity: sha512-vF/8BraOc66ZxIDo3VuNP7iiDrnXEINclJgSJmqwAAEpg84Zb1DHPI22XTXSDA+E8fW5btPUxu65c3ZXi8AQFA==}
engines: {node: 10.* || 12.* || >= 14}
diff --git a/test-app/.eslintrc.js b/test-app/.eslintrc.js
index c6047079..d2e5254f 100644
--- a/test-app/.eslintrc.js
+++ b/test-app/.eslintrc.js
@@ -1,59 +1,44 @@
-module.exports = {
- overrides: [
- // node files
- {
- files: [
- '.ember-cli.js',
- '.eslintrc.js',
- '.prettierrc.js',
- '.stylelintrc.js',
- '.template-lintrc.js',
- 'ember-cli-build.js',
- 'babel.config.js',
- 'testem.js',
- 'blueprints/*/index.js',
- 'config/**/*.js',
- 'lib/*/index.js',
- 'server/**/*.js'
- ],
- excludedFiles: [
- 'app/**',
- ],
- parserOptions: {
- sourceType: 'script',
- ecmaVersion: 2015
- },
- env: {
- browser: false,
- node: true
- },
- plugins: ['n'],
- rules: Object.assign({}, require('eslint-plugin-n').configs.recommended.rules, {
- // add your custom rules and overrides for node files here
+'use strict';
- // this can be removed once the following is fixed
- // https://github.com/mysticatea/eslint-plugin-node/issues/77
- 'node/no-unpublished-require': 'off'
- }),
- extends: [
- 'plugin:node/recommended'
- ],
+module.exports = {
+ root: true,
+ parser: 'ember-eslint-parser',
+ parserOptions: {
+ ecmaVersion: 'latest',
+ sourceType: 'module',
+ babelOptions: {
+ root: __dirname,
},
+ },
+ plugins: ['ember'],
+ extends: ['plugin:ember/recommended', 'plugin:prettier/recommended'],
+ globals: {
+ WithRequired: true,
+ },
+ env: {
+ browser: true,
+ },
+ rules: {
+ '@typescript-eslint/no-explicit-any': 'off',
+ },
+ overrides: [
{
- files: ['**/*.{js,ts}'],
- plugins: ['ember'],
+ files: ['**/*.ts'],
parser: '@typescript-eslint/parser',
extends: [
'eslint:recommended',
- 'plugin:ember/recommended', // or other configuration
+ 'plugin:@typescript-eslint/recommended',
+ 'plugin:ember/recommended',
],
rules: {
- // override / enable optional rules
- 'ember/no-replace-test-comments': 'error'
- }
+ 'ember/no-at-ember-render-modifiers': 'off',
+ '@typescript-eslint/no-explicit-any': 'off',
+ 'ember/no-empty-glimmer-component-classes': 'off',
+ },
},
{
files: ['**/*.gts'],
+ parser: 'ember-eslint-parser',
plugins: ['ember'],
extends: [
'eslint:recommended',
@@ -61,6 +46,11 @@ module.exports = {
'plugin:ember/recommended',
'plugin:ember/recommended-gts',
],
+ rules: {
+ 'ember/no-at-ember-render-modifiers': 'off',
+ '@typescript-eslint/no-explicit-any': 'off',
+ 'ember/no-empty-glimmer-component-classes': 'off',
+ },
},
{
files: ['**/*.gjs'],
@@ -72,12 +62,24 @@ module.exports = {
'plugin:ember/recommended-gjs',
],
},
+ // node files
{
- files: ['tests/**/*.{js,ts,gjs,gts}'],
- rules: {
- // override / enable optional rules
- 'ember/no-replace-test-comments': 'error'
- }
+ files: [
+ './.eslintrc.cjs',
+ './.prettierrc.cjs',
+ './.template-lintrc.cjs',
+ './addon-main.cjs',
+ './babel.config.js',
+ ],
+ parserOptions: {
+ sourceType: 'script',
+ },
+ env: {
+ browser: false,
+ node: true,
+ },
+ plugins: ['n'],
+ extends: ['plugin:n/recommended'],
},
],
};
diff --git a/test-app/.prettierrc.js b/test-app/.prettierrc.js
index e5f7b6d1..d6a52956 100644
--- a/test-app/.prettierrc.js
+++ b/test-app/.prettierrc.js
@@ -1,12 +1,6 @@
'use strict';
module.exports = {
- overrides: [
- {
- files: '*.{js,ts}',
- options: {
- singleQuote: true,
- },
- },
- ],
+ plugins: ['prettier-plugin-ember-template-tag'],
+ singleQuote: true,
};
diff --git a/test-app/package.json b/test-app/package.json
index e69c1a41..c7767207 100644
--- a/test-app/package.json
+++ b/test-app/package.json
@@ -25,7 +25,7 @@
"test": "concurrently \"npm:lint\" \"npm:test:*\" --names \"lint,test:\"",
"build:ember": "EMBROIDER_PREBUILD=true ember b",
"test:ember": "node ./scripts/run-tests.mjs",
- "test:ember:serve": "vite --open tests/"
+ "ember:serve": "vite --open tests/"
},
"devDependencies": {
"@babel/eslint-parser": "^7.22.5",
@@ -64,7 +64,6 @@
"ember-page-title": "^7.0.0",
"ember-qunit": "^8.1.0",
"ember-resolver": "^10.1.1",
- "ember-routable-component": "^0.2.0",
"ember-source": "^5.9.0",
"ember-source-channel-url": "^3.0.0",
"ember-template-lint": "^5.11.0",
@@ -78,8 +77,8 @@
"eslint-plugin-qunit": "^8.0.0",
"js-reporters": "^2.1.0",
"loader.js": "^4.7.0",
- "prettier": "^3.2.5",
- "prettier-plugin-ember-template-tag": "^2.0.1",
+ "prettier": "^3.3.2",
+ "prettier-plugin-ember-template-tag": "^2.0.2",
"puppeteer-chromium-resolver": "^22.0.0",
"qunit": "^2.19.4",
"qunit-dom": "^2.0.0",
@@ -87,8 +86,9 @@
"stylelint-config-standard": "^33.0.0",
"stylelint-prettier": "^3.0.0",
"tracked-built-ins": "^3.1.1",
- "vite": "^5.3.1",
- "webpack": "^5.90.3"
+ "webpack": "^5.90.3",
+ "vite": "^5.1.6",
+ "ember-routable-component": "^1.1.0"
},
"engines": {
"node": "16.* || >= 18"
diff --git a/test-app/tests/components/breadcrumbs-test.gts b/test-app/tests/components/breadcrumbs-test.gts
index bbf56375..195d042c 100644
--- a/test-app/tests/components/breadcrumbs-test.gts
+++ b/test-app/tests/components/breadcrumbs-test.gts
@@ -4,21 +4,25 @@ import { render, click } from '@ember/test-helpers';
import Breadcrumbs from 'carbon-components-ember/components/breadcrumbs';
import { array } from '@ember/helper';
-
module('Integration | Component | Breadcrumbs', (hooks) => {
setupRenderingTest(hooks);
- test('should display items', async function(assert) {
- await render();
+ test('should display items', async function (assert) {
+ await render(
+ ,
+ );
- assert.dom('.cds--breadcrumb-item').exists({ count: 3 }, 'should display all items');
+ assert
+ .dom('.cds--breadcrumb-item')
+ .exists({ count: 3 }, 'should display all items');
});
- test('should allow click without handler', async function(assert) {
+ test('should allow click without handler', async function (assert) {
assert.expect(0);
- await render();
+ await render(
+ ,
+ );
await click('.cds--breadcrumb-item');
});
});
-
diff --git a/test-app/tests/components/button-test.gts b/test-app/tests/components/button-test.gts
index 5827c198..190f7358 100644
--- a/test-app/tests/components/button-test.gts
+++ b/test-app/tests/components/button-test.gts
@@ -3,31 +3,31 @@ import { setupRenderingTest } from 'ember-qunit';
import { render, click, rerender, settled } from '@ember/test-helpers';
import Button from 'carbon-components-ember/components/button';
-
module('Integration | Component | Button', (hooks) => {
setupRenderingTest(hooks);
- test('should set as primary', async function(assert) {
- await render();
- await rerender()
+ test('should set as primary', async function (assert) {
+ await render();
+ await rerender();
assert.dom('button').hasClass('cds--btn--primary');
});
- test('should set as secondary', async function(assert) {
- await render();
+ test('should set as secondary', async function (assert) {
+ await render();
assert.dom('button').hasClass('cds--btn--secondary');
});
- test('should show loading indicator for async click handler', async function(assert) {
-
+ test('should show loading indicator for async click handler', async function (assert) {
let promise;
- const onClick = function() {
- promise = new Promise(res => setTimeout(res, 100));
+ const onClick = function () {
+ promise = new Promise((res) => setTimeout(res, 100));
return promise;
};
- await render();
+ await render(
+ ,
+ );
await click('button');
@@ -38,25 +38,39 @@ module('Integration | Component | Button', (hooks) => {
await promise;
await settled();
- assert.dom('.cds--loading').doesNotExist('should not show loading indicator');
+ assert
+ .dom('.cds--loading')
+ .doesNotExist('should not show loading indicator');
});
- test('cannot click disabled', async function(assert) {
+ test('cannot click disabled', async function (assert) {
assert.expect(2);
- const onClick = function() {
- return new Promise(res => setTimeout(res, 1000));
+ const onClick = function () {
+ return new Promise((res) => setTimeout(res, 1000));
};
- await render();
+ await render(
+
+
+ ,
+ );
try {
await click('button');
} catch (e) {
- assert.deepEqual(e.message, 'Can not `click` disabled [object HTMLButtonElement]', 'cannot click');
+ assert.deepEqual(
+ e.message,
+ 'Can not `click` disabled [object HTMLButtonElement]',
+ 'cannot click',
+ );
}
- assert.dom('button').hasClass('cds--btn--disabled', 'class names should include cds--btn--disabled');
+ assert
+ .dom('button')
+ .hasClass(
+ 'cds--btn--disabled',
+ 'class names should include cds--btn--disabled',
+ );
});
});
-