From f84e5304ce20b82923c7eaf9c4a80534fe497f3c Mon Sep 17 00:00:00 2001 From: Mimi <1119186082@qq.com> Date: Fri, 8 Oct 2021 22:01:04 +0800 Subject: [PATCH] Remove DOMTokenList.prototype.replace polyfill --- source/css/_common/components/post/post-header.styl | 1 - source/js/utils.js | 8 -------- 2 files changed, 9 deletions(-) diff --git a/source/css/_common/components/post/post-header.styl b/source/css/_common/components/post/post-header.styl index 2bcbe6f..ba04ce4 100644 --- a/source/css/_common/components/post/post-header.styl +++ b/source/css/_common/components/post/post-header.styl @@ -79,7 +79,6 @@ time { border-bottom: 1px dashed $grey-dark; - cursor: pointer; } } diff --git a/source/js/utils.js b/source/js/utils.js index 76d95f6..0a0665b 100644 --- a/source/js/utils.js +++ b/source/js/utils.js @@ -6,14 +6,6 @@ HTMLElement.prototype.wrap = function(wrapper) { wrapper.appendChild(this); }; -// https://caniuse.com/mdn-api_element_classlist_replace -if (typeof DOMTokenList.prototype.replace !== 'function') { - DOMTokenList.prototype.replace = function(remove, add) { - this.remove(remove); - this.add(add); - }; -} - (function() { const onPageLoaded = () => document.dispatchEvent( new Event('page:loaded', {