Link
The Link component is a reusable and customizable web component designed to easely link to capabilities within apps. It can also be used as a regular hyperlink by passing the href
-property.
Component
jsx
<alliance-link app="the-app-name" capability="edit-action" args={{ id: 'the-object-id' }}>
I am a link
</alliance-link>
Properties
Property | Type | Required | Default | Description |
---|---|---|---|---|
app | string | Yes, unless href is defined. | The target app. | |
capability | string | No | 'launch' | The target app capability. |
args | object | No | {} | Object containing query arguments passed to the capability as query strings. Properties that are not of type string , number or boolean will be stringified. |
href | string | No | Inner anchor tag href attribute. | |
target | string | No | Inner anchor tag target attribute. Only used if href is set. | |
rel | string | No | Inner anchor tag rel attribute. Only used if href is set. | |
download | boolean | No | Inner anchor tag download attribute. Only used if href is set. |
Parts
In Shadow DOM, a "part" is a keyword used to expose elements within the Shadow DOM for styling purposes.
anchor
The inner <a>
tag which wraps the component children. Use this if you need to change the styling of the anchor element.
css
alliance-link::part(anchor) {
display: block;
padding: 10px;
}