Skip to content

[TaxonomyPicker] Sometimes term path contains "termsetName" sometimes not in "onChange" event  #1597

@wuxiaojun514

Description

@wuxiaojun514

Category

[ ] Enhancement

[x] Bug

[ ] Question

Version

Please specify what version of the library you are using: [3.14.0 ]

If you are not using the latest release, please update and see if the issue is resolved before submitting an issue.

Expected / Desired Behavior / Question

The problem is at "onChange" event in TaxonomyPicker
In some scenario the path of term contains termset name while sometimes it doesn't have.

I think the term path should not have termset name.

Observed Behavior

If you choose term from panel, then its term path won't contain termset name
PickTermInPanel
However if you pick up term from the suggestion , then its path will start with termset name
PickerTermFromSuggestion
Also you will notice that the title of suggestion item contain double termset name

DoubleTermsetName

I debugged a bit on source code, terms from the suggestion are generated by convertSuggestTermToPickerTerm method which add full path.
image

Steps to Reproduce

You can follow https://pnp.github.io/sp-dev-fx-controls-react/controls/TaxonomyPicker/ to add TaxonomyPicker in webpart or extension to reproduce this issue

I can try to fix it.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions