By default, all blades and parts are 'pinnable'. Pinning a blade creates a part on the currently active dashboard.
Every blade in the portal has a default representation. The default part for a blade uses a button part. The title, subtitle, and icon provided in the blade view model provide the data needed to create the default view.
While the default pinned part is often sufficient, there are a few places where you may want to show a custom part representation.
To use a custom pinned part, it's as easy as
\SamplesExtension\Extension\Client\extension.pdl
<!--
Create a part in the <definition> element, making it available
in the catalog.
-->
<Part Name="SDKPartType"
ViewModel="SDKPartViewModel"
PartKind="Button">
<BladeAction Blade="SDKBlade"/>
</Part>
<Blade Name="SDKBlade"
ViewModel="SDKBladeViewModel">
<!--
The pinned part tag simply refers to a part already in the catalog.
-->
<PinnedPart PartType="SDKPartType" />
...
</Blade>
In the simple example above, the part in the catalog does not require inputs. In the event that the part does require an input, the inputs must match the properties passed into the blade view model. To learn more, check out building pinnable parts.
There are some cases where a blade should not be pinned. Those generally include:
- Create flows
- Editable forms
- Steps in a wizard
[WACOM.NOTE] Users generally expect blades to be pinnable. Only use Pinnable="False" in places where the pinned blade truly adds no value.
To prevent a blade from being pinned, set Pinnable="False"
in the blade definition.
\SamplesExtension\Extension\Client\Security\Security.pdl
<Blade Name="SecuritySampleBlade"
Pinnable="False">
...