How to map appTagets in breadcrumbs

When I setup the breadcrumbs component with mapped data source, how can I map the app targets? The appTargetsByIndex is always ["", "", ..., ""]

What I really need is when one of the breadcrumbs is clicked, I want to know which one is clicked and act accordingly.

Thanks
William Tsui

Hello @Will_Tsui!

I just replicated the component with a mapped value and also saw that my 'appTargetsByIndex' is also empty strings in an array. Very odd.

Will report this to our eng team to find out if I am trying to use it incorrectly. I was hoping to find an on click event handler but there doesn't seem to be one built in.

However, after searching breadcrumbs in the docs I found a potential alternative solution to your use case, check it out here as it involves the Stepped Container Component to navigate forward and backward through an app on clicks. Let me know if that works!

Hi Jack,

Thanks for looking into this, hope to hear from the eng team soon.

I understand the alternative solution but not very applicable to my usage. I am showing a path through a tree structure (root node > 2nd level node > 3rd level node > ... > leaf node) as breadcrumbs and want to make it able to jump back to any previous nodes. As for now, my workaround with onClick is to limit it to go back only the previous level.

Hi Will,

Glad you were able to find a workaround with onClick.

The breadcrumb component is fairly new so your feedback/use case will help our engineers refine it down. Will have updates when any changes are made!

To give more background on the usage of appTargetsByIndex this field will only populate when the Breadcrumb component has Content:Manual then in the 'Edit Breadcrumb' modal with the Type set to App, as shown below.

So you would need to "hard code" more or less the node levels, but this could work to access app pages and their URLs for navigation purposes. Let me know if that could be an alternative!

Not for my use case as my breadcrumbs are very dynamic. It will be great if your engineers can add the missing "AppTarget" to the Content:Mapped, right now it only have 4 fields: Label/Icon/Tooltip/Disable

image

Hi @Will_Tsui thank you for the additional feedback!

How would you like the Target field to be used? Should it be for putting in a URL to navigate to on click or the name of the app? Is there another component with a similar 'Target' field that you would like this to be analogous to?

Most importantly is within the onClick event of breadcrumbs, I want to know which breadcrumb is clicked. Then, I can navigate to the right target.

Yes I completely agree, I have added notes to our eng team, it seems that functionality might be possible with hard coded inputs to breadcrumbs but we are currently looking to expand that for easy use to navigate the user across mapped page values via breadcrumb on click event handlers!