FIX: Don't error when clicking on a custom link in community section (#22174)
This commit is contained in:
parent
fc199d42fa
commit
cee15d4177
|
@ -17,11 +17,15 @@
|
||||||
@prefixValue={{link.prefixValue}}
|
@prefixValue={{link.prefixValue}}
|
||||||
@href={{link.value}}
|
@href={{link.value}}
|
||||||
@class={{link.linkDragCss}}
|
@class={{link.linkDragCss}}
|
||||||
{{draggable
|
{{(if
|
||||||
didStartDrag=link.didStartDrag
|
this.section.reorderable
|
||||||
didEndDrag=link.didEndDrag
|
(modifier
|
||||||
dragMove=link.dragMove
|
"draggable"
|
||||||
}}
|
didStartDrag=link.didStartDrag
|
||||||
|
didEndDrag=link.didEndDrag
|
||||||
|
dragMove=link.dragMove
|
||||||
|
)
|
||||||
|
)}}
|
||||||
/>
|
/>
|
||||||
{{else}}
|
{{else}}
|
||||||
<Sidebar::SectionLink
|
<Sidebar::SectionLink
|
||||||
|
@ -43,7 +47,7 @@
|
||||||
@currentWhen={{link.currentWhen}}
|
@currentWhen={{link.currentWhen}}
|
||||||
@class={{link.linkDragCss}}
|
@class={{link.linkDragCss}}
|
||||||
{{(if
|
{{(if
|
||||||
link.didStartDrag
|
this.section.reorderable
|
||||||
(modifier
|
(modifier
|
||||||
"draggable"
|
"draggable"
|
||||||
didStartDrag=link.didStartDrag
|
didStartDrag=link.didStartDrag
|
||||||
|
|
|
@ -44,6 +44,8 @@ export default class CommunitySection {
|
||||||
@tracked links;
|
@tracked links;
|
||||||
@tracked moreLinks;
|
@tracked moreLinks;
|
||||||
|
|
||||||
|
reorderable = false;
|
||||||
|
|
||||||
constructor({ section, owner }) {
|
constructor({ section, owner }) {
|
||||||
setOwner(this, owner);
|
setOwner(this, owner);
|
||||||
|
|
||||||
|
|
|
@ -14,6 +14,8 @@ export default class Section {
|
||||||
@tracked dragCss;
|
@tracked dragCss;
|
||||||
@tracked links;
|
@tracked links;
|
||||||
|
|
||||||
|
reorderable = true;
|
||||||
|
|
||||||
constructor({ section, owner }) {
|
constructor({ section, owner }) {
|
||||||
setOwner(this, owner);
|
setOwner(this, owner);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue