foundation.link =============== ``foundation.link`` is an :ref:`action of foundation-collection-action `. When the action is triggered, it will cause the user agent to navigate to a URI, using `window.open `_. It supports the following parameters: config.data.href The URI Template that will be expanded into a URI that the user agent navigates to. The URI Template is expanded using variables satisfying the following interface: .. code-block:: ts interface FoundationCollectionActionFoundationLinkVariables { /** * The value of data-foundation-collection-id attribute of the given collection parameter. */ id: string; /** * The array of values of data-foundation-collection-item-id attribute of the given selections parameter. */ item: string[]; } config.data.target The target of the navigation. This is the ``strWindowName`` parameter of the window.open(). Example ------- Given a simple button: .. code-block:: html You can annotate it with ``foundation-collection-action`` to navigate to a URL based on collection selections when the user click it: .. code-block:: html Relationship Graph ------------------ .. graphviz:: digraph "foundation-collection" { rankdir=BT; "foundation-selections" -> "foundation-collection" [label="extends", weight=8]; "foundation-collection-action" -> "foundation-selections" [label="reacts to"]; "foundation.link" -> "foundation-collection-action" [label="provides action to"]; "foundation.pushstate" -> "foundation-collection-action" [label="provides action to"]; }