Skip to content

Commit a246e03

Browse files
fix: interaction
1 parent 4da154b commit a246e03

File tree

1 file changed

+72
-59
lines changed

1 file changed

+72
-59
lines changed

js/FeedzyBlock/Editor.js

Lines changed: 72 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import {
77
TextControl,
88
Button,
99
Spinner,
10+
Disabled,
1011
} from '@wordpress/components';
1112

1213
import queryString from 'query-string';
@@ -521,18 +522,21 @@ class Editor extends Component {
521522
this.props.attributes.feedData.channel !== null && (
522523
<div className="rss_header">
523524
<h2>
524-
<a
525-
className="rss_title"
526-
href={
527-
this.props.attributes.feedData
528-
.channel.link || '#'
529-
}
530-
>
531-
{unescapeHTML(
532-
this.props.attributes.feedData
533-
.channel.title
534-
)}
535-
</a>
525+
<Disabled>
526+
<a
527+
className="rss_title"
528+
href={
529+
this.props.attributes
530+
.feedData.channel
531+
.link || '#'
532+
}
533+
>
534+
{unescapeHTML(
535+
this.props.attributes
536+
.feedData.channel.title
537+
)}
538+
</a>
539+
</Disabled>
536540
<span className="rss_description">
537541
{' ' +
538542
unescapeHTML(
@@ -673,24 +677,12 @@ class Editor extends Component {
673677
.size + 'px',
674678
}}
675679
>
676-
<a
677-
href={item.link}
678-
title={unescapeHTML(
679-
item.title
680-
)}
681-
style={{
682-
width:
683-
this.props
684-
.attributes
685-
.size + 'px',
686-
height:
687-
this.props
688-
.attributes
689-
.size + 'px',
690-
}}
691-
>
692-
<span
693-
className="fetched"
680+
<Disabled>
681+
<a
682+
href={item.link}
683+
title={unescapeHTML(
684+
item.title
685+
)}
694686
style={{
695687
width:
696688
this.props
@@ -702,44 +694,65 @@ class Editor extends Component {
702694
.attributes
703695
.size +
704696
'px',
705-
backgroundImage:
706-
this.getImageURL(
707-
item,
708-
true
709-
),
710697
}}
711-
title={unescapeHTML(
712-
item.title
713-
)}
714-
></span>
715-
</a>
698+
>
699+
<span
700+
className="fetched"
701+
style={{
702+
width:
703+
this.props
704+
.attributes
705+
.size +
706+
'px',
707+
height:
708+
this.props
709+
.attributes
710+
.size +
711+
'px',
712+
backgroundImage:
713+
this.getImageURL(
714+
item,
715+
true
716+
),
717+
}}
718+
title={unescapeHTML(
719+
item.title
720+
)}
721+
></span>
722+
</a>
723+
</Disabled>
716724
</div>
717725
)}
718726
<div className="rss_content_wrap">
719727
{this.props.attributes.itemTitle &&
720728
this.props.attributes.title !==
721729
0 ? (
722730
<span className="title">
723-
<a href={item.link}>
724-
{this.props.attributes
725-
.title &&
726-
unescapeHTML(item.title)
727-
.length >
728-
this.props
731+
<Disabled>
732+
<a href={item.link}>
733+
{this.props
729734
.attributes
730-
.title
731-
? unescapeHTML(
732-
item.title
733-
).substring(
734-
0,
735-
this.props
736-
.attributes
737-
.title
738-
) + '...'
739-
: unescapeHTML(
740-
item.title
741-
)}
742-
</a>
735+
.title &&
736+
unescapeHTML(
737+
item.title
738+
).length >
739+
this.props
740+
.attributes
741+
.title
742+
? unescapeHTML(
743+
item.title
744+
).substring(
745+
0,
746+
this
747+
.props
748+
.attributes
749+
.title
750+
) + '...'
751+
: unescapeHTML(
752+
item.title
753+
)}
754+
</a>
755+
</Disabled>
743756
</span>
744757
) : (
745758
''

0 commit comments

Comments
 (0)