Skip to content
This repository was archived by the owner on Oct 8, 2021. It is now read-only.

Commit af08283

Browse files
Rob DiCiuccioarschmitz
authored andcommitted
Pagecontainer: Pass triggerData with load event
Fixes gh-7580 Closes gh-7581
1 parent 2637803 commit af08283

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

js/widgets/pagecontainer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -550,7 +550,7 @@ define( [
550550
// Note that it is the responsibility of the listener/handler
551551
// that called preventDefault(), to resolve/reject the
552552
// deferred object within the triggerData.
553-
if ( this._triggerWithDeprecated( "load" ).event.isDefaultPrevented() ) {
553+
if ( this._triggerWithDeprecated( "load", triggerData ).event.isDefaultPrevented() ) {
554554
return;
555555
}
556556

tests/integration/pagecontainer/page_event_sequence_core.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,11 +98,11 @@ asyncTest( "Event sequence during navigation to another page", function() {
9898

9999
// Deprecated as of 1.4.0
100100
{ type: "pageload", target: "the-body",
101-
data: { prevPage: undefined, nextPage: undefined, toPage: undefined } },
101+
data: { prevPage: "start-page", nextPage: undefined, toPage: "other-page" } },
102102

103103
// Valid
104104
{ type: "pagecontainerload", target: "the-body",
105-
data: { prevPage: undefined, nextPage: undefined, toPage: undefined } },
105+
data: { prevPage: "start-page", nextPage: undefined, toPage: "other-page" } },
106106

107107
// Valid - page widget events
108108
{ type: "pagebeforecreate", target: "other-page",

0 commit comments

Comments
 (0)