Skip to content

Commit 0c63a73

Browse files
DEV: Bump dependencies and fix linting (#142)
1 parent 111c499 commit 0c63a73

File tree

9 files changed

+756
-600
lines changed

9 files changed

+756
-600
lines changed

assets/javascripts/discourse/components/follow-button.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { action } from "@ember/object";
33
import { alias } from "@ember/object/computed";
44
import { ajax } from "discourse/lib/ajax";
55
import { popupAjaxError } from "discourse/lib/ajax-error";
6-
import discourseComputed from "discourse-common/utils/decorators";
6+
import discourseComputed from "discourse/lib/decorators";
77

88
export default class FollowButton extends Component {
99
loading = false;

assets/javascripts/discourse/components/follow-statistic.gjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import i18n from "discourse-common/helpers/i18n";
1+
import { i18n } from "discourse-i18n";
22

33
const FollowStatistic = <template>
44
<div class="follow-statistic">

assets/javascripts/discourse/components/follow-users-list.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import Component from "@ember/component";
22
import { notEmpty } from "@ember/object/computed";
33
import { propertyEqual } from "discourse/lib/computed";
4-
import discourseComputed from "discourse-common/utils/decorators";
4+
import discourseComputed from "discourse/lib/decorators";
55

66
export default class FollowUsersList extends Component {
77
@notEmpty("users") hasUsers;

assets/javascripts/discourse/initializers/follow-initializer.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { withPluginApi } from "discourse/lib/plugin-api";
22
import { userPath } from "discourse/lib/url";
3-
import I18n from "I18n";
3+
import { i18n } from "discourse-i18n";
44

55
export default {
66
name: "follow-plugin-initializer",
@@ -29,7 +29,7 @@ export default {
2929
(NotificationTypeBase) => {
3030
return class extends NotificationTypeBase {
3131
get linkTitle() {
32-
return I18n.t("notifications.titles.following");
32+
return i18n("notifications.titles.following");
3333
}
3434

3535
get linkHref() {
@@ -45,7 +45,7 @@ export default {
4545
}
4646

4747
get description() {
48-
return I18n.t("notifications.following_description", {});
48+
return i18n("notifications.following_description", {});
4949
}
5050
};
5151
}

assets/javascripts/discourse/models/post-stream.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ import { reads } from "@ember/object/computed";
33
import { on } from "@ember-decorators/object";
44
import { Promise } from "rsvp";
55
import { ajax } from "discourse/lib/ajax";
6+
import discourseComputed from "discourse/lib/decorators";
67
import Category from "discourse/models/category";
78
import RestModel from "discourse/models/rest";
8-
import discourseComputed from "discourse-common/utils/decorators";
99

1010
// this class implements an interface similar to the `UserStream` class in core
1111
// (app/models/user-stream.js) so we can use it with the `{{user-stream}}`

package.json

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,16 @@
11
{
22
"private": true,
33
"devDependencies": {
4-
"@discourse/lint-configs": "2.2.2",
5-
"ember-template-lint": "6.0.0",
6-
"eslint": "9.15.0",
4+
"@discourse/lint-configs": "2.4.0",
5+
"ember-template-lint": "6.1.0",
6+
"eslint": "9.19.0",
77
"prettier": "2.8.8"
88
},
99
"engines": {
10-
"node": ">= 18",
10+
"node": ">= 22",
1111
"npm": "please-use-pnpm",
1212
"yarn": "please-use-pnpm",
13-
"pnpm": ">= 9"
14-
}
13+
"pnpm": "9.x"
14+
},
15+
"packageManager": "[email protected]"
1516
}

pnpm-lock.yaml

Lines changed: 737 additions & 582 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

test/javascripts/acceptance/follow-notification-test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { visit } from "@ember/test-helpers";
22
import { test } from "qunit";
33
import { acceptance } from "discourse/tests/helpers/qunit-helpers";
4-
import I18n from "I18n";
4+
import { i18n } from "discourse-i18n";
55

66
acceptance("Discourse Follow - notification", function (needs) {
77
needs.user();
@@ -55,7 +55,7 @@ acceptance("Discourse Follow - notification", function (needs) {
5555

5656
assert.strictEqual(
5757
notification.querySelector("a").title,
58-
I18n.t("notifications.titles.following"),
58+
i18n("notifications.titles.following"),
5959
"displays the right title"
6060
);
6161
});

test/javascripts/acceptance/follow-posts-feed-test.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import {
66
query,
77
queryAll,
88
} from "discourse/tests/helpers/qunit-helpers";
9-
import I18n from "I18n";
9+
import { i18n } from "discourse-i18n";
1010

1111
acceptance("Discourse Follow - Follow Posts Feed", function (needs) {
1212
needs.user();
@@ -166,7 +166,7 @@ acceptance("Discourse Follow - Follow Posts Feed", function (needs) {
166166
);
167167
assert.equal(
168168
query(".user-navigation-secondary a.active").textContent.trim(),
169-
I18n.t("user.feed.label"),
169+
i18n("user.feed.label"),
170170
"feed tab is labelled correctly"
171171
);
172172
});
@@ -203,7 +203,7 @@ acceptance("Discourse Follow - Empty Follow Posts Feed", function (needs) {
203203
await visit("/u/eviltrout/follow/feed");
204204
assert.equal(
205205
query(".user-content.user-follows-tab").textContent.trim(),
206-
I18n.t("user.feed.empty_feed_you"),
206+
i18n("user.feed.empty_feed_you"),
207207
"empty posts feed notice is shown"
208208
);
209209
});

0 commit comments

Comments
 (0)