import { resolveSchema as m } from "../../../../../sdk/dist/shared/utils/schema-resolver.js";
const r = () => !0;
function d(n, a = r, s = []) {
  return Object.entries(n.properties).map(([e, t]) => [e, m(t)]).filter(([, e]) => e["ui:field"] !== "hidden").filter(([e, t]) => a(t, e)).map(([e, t]) => {
    const i = [...s, e];
    return {
      id: e,
      label: t.title,
      path: i.join("."),
      ...t.metadata && { metadata: t.metadata },
      ...t.description ? { description: t.description } : {},
      ...t.metadata?.group ? {
        children: d(t, a, i)
      } : { schema: t }
      // : prop.type === "object" && !prop["ui:field"]
      // ? { schema: getNavItemsFromManifest(prop as TObject, filter, nextPathParts) }
      // : { schema: prop }),
    };
  }).flat();
}
export {
  d as getNavItemsFromManifest
};
//# sourceMappingURL=form-utils.js.map
