af_readability: fix selector
This commit is contained in:
parent
760a26e484
commit
5cec4eb015
|
@ -1,9 +1,11 @@
|
||||||
|
/* global xhr, App, Plugins, Article, Notify */
|
||||||
|
|
||||||
Plugins.Af_Readability = {
|
Plugins.Af_Readability = {
|
||||||
orig_attr_name: 'data-readability-orig-content',
|
orig_attr_name: 'data-readability-orig-content',
|
||||||
self: this,
|
self: this,
|
||||||
embed: function(id) {
|
embed: function(id) {
|
||||||
const content = App.find(App.isCombinedMode() ? ".cdm[data-article-id=" + id + "] .content-inner" :
|
const content = App.find(App.isCombinedMode() ? `.cdm[data-article-id="${id}"] .content-inner` :
|
||||||
".post[data-article-id=" + id + "] .content");
|
`.post[data-article-id="${id}"] .content`);
|
||||||
|
|
||||||
if (content.hasAttribute(self.orig_attr_name)) {
|
if (content.hasAttribute(self.orig_attr_name)) {
|
||||||
content.innerHTML = content.getAttribute(self.orig_attr_name);
|
content.innerHTML = content.getAttribute(self.orig_attr_name);
|
||||||
|
|
Loading…
Reference in New Issue