From 7d1cef71ffde1559646501b2dbf9b358906930f4 Mon Sep 17 00:00:00 2001 From: Jarek Radosz Date: Mon, 12 Apr 2021 17:52:53 +0200 Subject: [PATCH] DEV: Remove ScrollTop mixin (#12673) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It was deprecated (incorrectly! see the import 😅) 5 years ago. No references found anymore in core and all-the-plugins. --- .../javascripts/discourse/app/mixins/scroll-top.js | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/app/assets/javascripts/discourse/app/mixins/scroll-top.js b/app/assets/javascripts/discourse/app/mixins/scroll-top.js index 93c72ae445..8ca49c218e 100644 --- a/app/assets/javascripts/discourse/app/mixins/scroll-top.js +++ b/app/assets/javascripts/discourse/app/mixins/scroll-top.js @@ -1,6 +1,4 @@ import DiscourseURL from "discourse/lib/url"; -import Mixin from "@ember/object/mixin"; -import { deprecated } from "discourse/mixins/scroll-top"; import { isTesting } from "discourse-common/config/environment"; import { scheduleOnce } from "@ember/runloop"; @@ -20,14 +18,4 @@ function scrollTop() { scheduleOnce("afterRender", context, context._scrollTop); } -export default Mixin.create({ - didInsertElement() { - deprecated( - "The `ScrollTop` mixin is deprecated. Replace it with a `{{d-section}}` component" - ); - this._super(...arguments); - scrollTop(); - }, -}); - export { scrollTop };