Skip to content

Add controller class for <fjs-frame> #1

@skylardarkfox

Description

@skylardarkfox

The <fjs-frame> element is at present purely a container element. However, adding a controller class will allow navigation methods to be defined, making it easier to transition between <fjs-page>s within the given <fjs-frame>.

These methods should ideally include:

Method name Description
previous() navigate to the previous page in the frame history
next() navigate to the next page in the frame history (applicable only if previous() was used and there is forward history availaible)
navigateTo(page) navigate to the specific page named in the argument

In the future, navigateTo() should also allow for an optional parameter (an object) that can be used to instantiate the <fjs-page> with specific variables. But for now, a basic page name will be sufficient, and instantiation with specific parameters can be handled in userspace with connectedCallback().

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions