Skip to content

SidePane: fire event on show #596

Closed
Closed
@wkeese

Description

@wkeese

Although mySidePane.show("content") will fire the delite-after-show event, mySidePane.show() will not.

It's because mySidePane.show() shows the <d-side-pane> itself rather than one of the children of the <d-side-pane>, and thus it doesn't execute the code in DisplayContainer.

Seems like a bug, although technically the description of the delite-after-show event in DisplayContainer.js does specifically use the word "child":

/**
 * Dispatched after child is shown.
 * @example
 * document.addEventListener("delite-after-show", function (evt) {
 *      console.log("just displayed child", evt.child);
 * });
 * @event module:delite/DisplayContainer#delite-after-show
 * @property {Element} child - reference to child element
 */

Still, seems counterintuitive.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions