Skip to content

Commit 2f08d49

Browse files
committed
fix: missing deps & type fixes
1 parent 06671a2 commit 2f08d49

File tree

19 files changed

+300
-262
lines changed

19 files changed

+300
-262
lines changed

package.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,15 @@
99
"devDependencies": {
1010
"@changesets/cli": "^2.27.11",
1111
"@changesets/get-github-info": "^0.6.0",
12-
"@glint/core": "^1.5.1",
12+
"@glint/core": "^1.5.2",
1313
"dotenv": "^16.4.7"
1414
},
1515
"packageManager": "pnpm@10.0.0+sha512.b8fef5494bd3fe4cbd4edabd0745df2ee5be3e4b0b8b08fa643aa3e4c6702ccc0f00d68fa8a8c9858a735a0032485a44990ed2810526c875e416f001b17df12b",
1616
"pnpm": {
1717
"patchedDependencies": {
1818
"@embroider/core": "patches/@embroider__core.patch",
19-
"@glint/environment-ember-loose": "patches/@glint__environment-ember-loose.patch"
19+
"@glint/environment-ember-loose": "patches/@glint__environment-ember-loose.patch",
20+
"broccoli-asset-rewrite": "patches/broccoli-asset-rewrite.patch"
2021
}
2122
}
2223
}

packages/components/package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -76,10 +76,10 @@
7676
"@babel/runtime": "^7.26.0",
7777
"@ember/test-helpers": "^4.0.4",
7878
"@embroider/addon-dev": "^7.1.1",
79-
"@glint/core": "^1.5.1",
80-
"@glint/environment-ember-loose": "^1.5.1",
81-
"@glint/environment-ember-template-imports": "^1.5.1",
82-
"@glint/template": "^1.5.1",
79+
"@glint/core": "^1.5.2",
80+
"@glint/environment-ember-loose": "^1.5.2",
81+
"@glint/environment-ember-template-imports": "^1.5.2",
82+
"@glint/template": "^1.5.2",
8383
"@rollup/plugin-babel": "^6.0.4",
8484
"@tsconfig/ember": "^3.0.8",
8585
"@types/ember-qunit": "^6.1.3",

packages/components/src/components/hds/breadcrumb/item.hbs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
</div>
1515
{{else}}
1616
{{#if @isRouteExternal}}
17+
{{! @glint-expect-error: FIXME: pnpm migration }}
1718
<LinkToExternal
1819
class="hds-breadcrumb__link"
1920
@current-when={{@current-when}}

packages/components/src/components/hds/interactive/index.hbs

+1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
{{! NOTICE: we can't support the direct use of the "href" HTML attribute via ...attributes in the <a> elements, because we need to rely on the "@href" Ember argument to differentiate between different types of generated output }}
44
{{~#if @route~}}
55
{{~#if this.isRouteExternal~}}
6+
{{! @glint-expect-error: FIXME: pnpm migration }}
67
<LinkToExternal
78
@current-when={{@current-when}}
89
@models={{hds-link-to-models @model @models}}

packages/components/src/components/hds/interactive/index.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export interface HdsInteractiveSignature {
1616
route?: string;
1717
models?: unknown[];
1818
model?: unknown;
19-
query?: Record<string, unknown>;
19+
query?: Record<string, string>;
2020
'current-when'?: string | boolean;
2121
replace?: boolean;
2222
};

packages/components/src/components/hds/time/index.hbs

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
{{~#if this.hasTooltip~}}
99
<Hds::TooltipButton
1010
class="hds-time-wrapper"
11+
{{! @glint-expect-error: FIXME: pnpm migration }}
1112
@text={{if
1213
display.options.tooltipFormat
1314
(hds-format-date this.date display.options.tooltipFormat)

packages/components/src/components/hds/time/index.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ export default class HdsTime extends Component<HdsTimeSignature> {
118118
return {
119119
options: undefined,
120120
difference: { absValueInMs: 0, valueInMs: 0 },
121-
relative: { value: 0, unit: '' },
121+
relative: { value: 0, unit: undefined },
122122
};
123123
}
124124

packages/components/src/helpers/hds-format-date.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ import { helper } from '@ember/component/helper';
1717
*/
1818

1919
export function hdsFormatDate([date, options]: [
20-
Date,
21-
{
20+
date: Date | undefined,
21+
options: {
2222
month: Intl.DateTimeFormatOptions['month'];
2323
day: Intl.DateTimeFormatOptions['day'];
2424
year?: Intl.DateTimeFormatOptions['year'];

packages/components/src/helpers/hds-format-relative.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ import { helper } from '@ember/component/helper';
1616
*/
1717

1818
export function hdsFormatRelative([value, unit]: [
19-
number,
20-
Intl.RelativeTimeFormatUnit,
19+
value: number,
20+
unit?: Intl.RelativeTimeFormatUnit,
2121
]): string {
2222
if (unit) {
2323
return new Intl.RelativeTimeFormat(navigator.language).format(value, unit);

packages/components/src/services/hds-time-types.ts

+7-7
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,17 @@ export type DefaultDisplayType = {
1111
};
1212

1313
export type DisplayFormatType = {
14-
month: string;
15-
day: string;
16-
year: string;
17-
hour?: string;
18-
minute?: string;
19-
second?: string;
14+
month: Intl.DateTimeFormatOptions['month'];
15+
day: Intl.DateTimeFormatOptions['day'];
16+
year?: Intl.DateTimeFormatOptions['year'];
17+
hour?: Intl.DateTimeFormatOptions['hour'];
18+
minute?: Intl.DateTimeFormatOptions['minute'];
19+
second?: Intl.DateTimeFormatOptions['second'];
2020
timeZoneName?: string;
2121
};
2222

2323
export type DisplayType = {
2424
options?: DefaultDisplayType;
2525
difference: { absValueInMs: number; valueInMs: number };
26-
relative: { value: number; unit: string };
26+
relative: { value: number; unit?: Intl.RelativeTimeFormatUnit };
2727
};

packages/components/src/services/hds-time.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -161,8 +161,8 @@ export default class TimeService extends Service {
161161
// Formats the value of a relative unit.
162162
formatTimeRelativeUnit(
163163
value: number,
164-
unit: string
165-
): { value: number; unit: string } {
164+
unit: Intl.RelativeTimeFormatUnit
165+
): { value: number; unit: Intl.RelativeTimeFormatUnit } {
166166
return {
167167
value: Math.trunc(value),
168168
unit,
@@ -178,7 +178,7 @@ export default class TimeService extends Service {
178178
hour: number;
179179
day: number;
180180
} = DEFAULT_RELATIVE_THRESHOLDS
181-
): { value: number; unit: string } {
181+
): { value: number; unit: Intl.RelativeTimeFormatUnit } {
182182
if (absValueInMs < thresholds[HdsTimeRelativeUnitValues.Second]) {
183183
return this.formatTimeRelativeUnit(
184184
valueInMs / SECOND_IN_MS,

packages/ember-flight-icons/package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -50,10 +50,10 @@
5050
"@embroider/addon-dev": "^7.1.1",
5151
"@glimmer/component": "^1.1.2",
5252
"@glimmer/tracking": "^1.1.2",
53-
"@glint/core": "^1.5.1",
54-
"@glint/environment-ember-loose": "^1.5.1",
55-
"@glint/environment-ember-template-imports": "^1.5.1",
56-
"@glint/template": "^1.5.1",
53+
"@glint/core": "^1.5.2",
54+
"@glint/environment-ember-loose": "^1.5.2",
55+
"@glint/environment-ember-template-imports": "^1.5.2",
56+
"@glint/template": "^1.5.2",
5757
"@rollup/plugin-babel": "^6.0.4",
5858
"@tsconfig/ember": "^3.0.8",
5959
"@typescript-eslint/eslint-plugin": "^8.18.1",

patches/broccoli-asset-rewrite.patch

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
diff --git a/index.js b/index.js
2+
index 7d3e96c4fafc3ef01e7f6a5a884d0500fa031b31..c78d43eff3a69b24fc23605d8ee0e8c3a15e64e3 100644
3+
--- a/index.js
4+
+++ b/index.js
5+
@@ -106,7 +106,7 @@ AssetRewrite.prototype.rewriteAssetPath = function (string, assetPath, replaceme
6+
* ["\')>\s] - Match one of "'(\n> exactly one time
7+
*/
8+
9+
- var re = new RegExp('["\'(=]\\s*([^"\'()=]*' + escapeRegExp(assetPath) + '[^"\n\'()\\>=]*)(\\?[^"\')> ]*)?\\s*\\\\*\\s*["\')>\s]', 'g');
10+
+ var re = new RegExp('["\'(=]\\s*([^"\'()=]*' + escapeRegExp(assetPath) + '[^"\n\'()\\>=]*)(\\?[^"\')> ]*)?\\s*\\\\*\\s*["=\')>\s]', 'g');
11+
var match = null;
12+
13+
/*

0 commit comments

Comments
 (0)