@fern-api/fdr-sdk 1.2.45-1a67633024 → 1.2.45-3a874ebe1e

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2024,13 +2024,19 @@ function buildFullRootFromSegments(options) {
2024
2024
  }
2025
2025
  let rootPointsTo;
2026
2026
  if (child.type === "productgroup") {
2027
- const defaultProduct = child.children.find((p) => p.default) ?? child.children[0];
2028
- rootPointsTo = defaultProduct?.type === "product" ? defaultProduct.pointsTo : void 0;
2027
+ if (child.landingPage != null && !child.landingPage.hidden) {
2028
+ rootPointsTo = child.landingPage.slug;
2029
+ } else {
2030
+ const defaultProduct = child.children.find((p) => p.default) ?? child.children[0];
2031
+ rootPointsTo = defaultProduct?.type === "product" ? defaultProduct.pointsTo : void 0;
2032
+ }
2029
2033
  } else if (child.type === "versioned") {
2030
2034
  const defaultVersion = child.children.find((v) => v.default) ?? child.children[0];
2031
2035
  rootPointsTo = defaultVersion?.pointsTo;
2032
2036
  } else if (child.type === "unversioned") {
2033
- if (tabs.length > 0) {
2037
+ if (child.landingPage != null && !child.landingPage.hidden) {
2038
+ rootPointsTo = child.landingPage.slug;
2039
+ } else if (tabs.length > 0) {
2034
2040
  const firstTab = tabs[0];
2035
2041
  const pt = firstTab != null ? metaStr(firstTab.metadata, "pointsTo") : void 0;
2036
2042
  rootPointsTo = pt != null ? pointsToSlug(pt) : void 0;