nl_tokens: / * Get the label for a given product recursively including parent names .
pl_tokens: function getProductCategoryLabel ( state , categoryId , siteId = getSelectedSiteId ( state ) ) { const categoryState = getRawCategoryState ( state , siteId ) ; const categories = categoryState . items || { } ; const category = categories [ categoryId ] ; if ( ! category ) { return '' ; } if ( ! Number ( category . parent ) ) { return category . name ; } return getProductCategoryLabel ( state , <mask> . parent , siteId ) + ` ${ category . name } ` ; }