Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
patricklx committed Feb 22, 2024
1 parent 1a7ef56 commit 3bd4782
Show file tree
Hide file tree
Showing 5 changed files with 14,359 additions and 9 deletions.
1 change: 1 addition & 0 deletions index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
import 'ember-source/types/stable'
3 changes: 1 addition & 2 deletions lib/hbs-imports-babel-plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import ImportProcessor from './import-processor';
import p from 'path';
import type * as BabelCoreNamespace from '@babel/core';
import type * as BabelTypesNamespace from '@babel/types';
import type { NodePath } from '@babel/traverse';
import { PluginObj } from '@babel/core';
import { V8IntrinsicIdentifier } from '@babel/types';

Expand Down Expand Up @@ -39,7 +38,7 @@ module.exports = function hbsImports({ types: t }: { types: BabelTypes}) {
if (!fileName) return;
const importedStyles = allImports && [...allImports.others]
.filter(x => x.endsWith('.scss'))
.map(x => x.replace(new RegExp('^'+ImportProcessor.options.namespace + '\/'), ''))
.map(x => x.replace(new RegExp('^'+ImportProcessor.options.namespace + '/'), ''))
.map(x => p.relative(p.dirname(fileName), p.join(ImportProcessor.options.root, x)))
.map(x => x.startsWith('.') ? x : `./${x}`);
importedStyles?.forEach((s) => {
Expand Down
12 changes: 5 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,10 @@
"test:all": "ember try:each"
},
"dependencies": {
"@babel/core": "^7.23.9",
"@babel/types": "^7.23.9",
"@glimmer/reference": "^0.84.2",
"@glimmer/syntax": "^0.84.2",
"@types/ember__runloop": "^4.0.1",
"broccoli-asset-rev": "^2.7.0",
"broccoli-concat": "^4.2.4",
"broccoli-funnel": "^3.0.3",
Expand All @@ -48,9 +49,7 @@
"@commitlint/config-conventional": "^7.1.2",
"@ember/optional-features": "^2.0.0",
"@ember/test-helpers": "^2.7.0",
"@types/ember": "^4.0.0",
"@types/babel__traverse": "^7.18.3",
"@types/babel__core": "^7.18.3",
"@types/node": "^18.15.3",
"@typescript-eslint/eslint-plugin": "^3.1.0",
"@typescript-eslint/parser": "^3.1.0",
"ember-auto-import": "^2.4.1",
Expand All @@ -61,21 +60,20 @@
"ember-cli-sass": "^10.0.1",
"ember-cli-sri": "^2.1.1",
"ember-template-lint": "^4.6.0",
"ember-cli-uglify": "^2.1.0",
"ember-cli-terser": "^4.0.2",
"ember-disable-prototype-extensions": "^1.1.3",
"ember-load-initializers": "^2.1.2",
"ember-maybe-import-regenerator": "^0.1.6",
"ember-modifier": "^3.2.7",
"ember-resolver": "^10.1.0",
"ember-source": "^4.3.0",
"ember-source": "^5.6.0",
"ember-source-channel-url": "^1.1.0",
"ember-try": "^1.0.0",
"eslint": "^7.12.1",
"eslint-plugin-ember": "^5.2.0",
"eslint-plugin-node": "^7.0.1",
"husky": "^1.3.1",
"loader.js": "^4.7.0",
"node-sass": "^5.0.0",
"ember-qunit": "^5.1.5",
"qunit": "^2.19.1",
"semantic-release": "^15.13.2",
Expand Down
Loading

0 comments on commit 3bd4782

Please sign in to comment.