Skip to content

Add additional api menu entries#255

Open
alecslupu wants to merge 3 commits into
developfrom
feature/additional-api
Open

Add additional api menu entries#255
alecslupu wants to merge 3 commits into
developfrom
feature/additional-api

Conversation

@alecslupu
Copy link
Copy Markdown
Contributor

@alecslupu alecslupu commented Feb 9, 2026

This PR adds the docs links for the work done in:

Summary by CodeRabbit

  • Documentation
    • Added accountability component documentation to the API reference, including CRUD operations and milestone management guides.
    • Added budgets component documentation with create, update, delete operations and nested project management documentation.

Review Change Stack

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Feb 9, 2026

📝 Walkthrough

Walkthrough

API documentation navigation is expanded with new xref entries for the accountability and budgets components. The entries reference create/update/delete operations and related subpages (milestone operations for accountability, and nested projects operations for budgets) and are positioned before the existing debates component section.

Changes

API Reference Navigation

Layer / File(s) Summary
API reference component navigation entries
docs/en/modules/ROOT/nav.adoc
New xref entries added for accountability component (including create/update/delete and milestone create/update/delete subpages) and budgets component (including create/update/delete plus nested projects create/update/delete subpages), inserted before the existing debates section.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

🐰 The nav grows with intent so clear,
More paths for those who venture near,
Accountability and budgets shine,
Organized in Asciidoc's design,
A documentation warren divine! ✨

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: adding new API menu entries to the documentation navigation file.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/additional-api

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@alecslupu alecslupu marked this pull request as ready for review May 23, 2026 02:32
Copilot AI review requested due to automatic review settings May 23, 2026 02:32
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds new API reference navigation entries so the documentation site exposes the newly documented Budgets and Accountability API operations (as referenced in the linked decidim/decidim PRs).

Changes:

  • Add Budgets API reference menu group with Budget and Project CRUD operation links.
  • Add Accountability API reference menu group with Result and Milestone CRUD operation links.
Comments suppressed due to low confidence (1)

docs/en/modules/ROOT/nav.adoc:270

  • The action links under Accountability are ordered Create → Delete → Update. For consistency with other action lists in this same section, consider reordering to Create → Update → Delete.
****** xref:develop:api/reference/components/accountability/create.adoc[Create Result]
****** xref:develop:api/reference/components/accountability/delete.adoc[Delete Result]
****** xref:develop:api/reference/components/accountability/update.adoc[Update Result]
****** xref:develop:api/reference/components/accountability/milestone/create.adoc[Create Milestone]
****** xref:develop:api/reference/components/accountability/milestone/update.adoc[Update Milestone]
****** xref:develop:api/reference/components/accountability/milestone/delete.adoc[Delete Milestone]

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread docs/en/modules/ROOT/nav.adoc
Comment thread docs/en/modules/ROOT/nav.adoc Outdated
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docs/en/modules/ROOT/nav.adoc`:
- Around line 257-270: The new xrefs in docs/en/modules/ROOT/nav.adoc reference
non-existent pages (e.g.,
develop:api/reference/components/accountability/create.adoc,
develop:api/reference/components/accountability/milestone/create.adoc,
develop:api/reference/components/budgets/create.adoc,
develop:api/reference/components/budgets/projects/create.adoc); either change
those xref targets to the actual existing docs under admin (for example point to
admin pages like
docs/en/modules/admin/pages/components/accountability/results.adoc or
docs/en/modules/admin/pages/components/budgets/projects.adoc) or add the missing
develop:api/reference/... .adoc files so the xrefs resolve; update the lines
that list the xrefs in docs/en/modules/ROOT/nav.adoc to use the correct target
strings or ensure the matching files are created with the expected names.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 7855dd46-52ca-4f82-93ac-97841eea417e

📥 Commits

Reviewing files that changed from the base of the PR and between 873816d and dffcd3b.

📒 Files selected for processing (1)
  • docs/en/modules/ROOT/nav.adoc

Comment on lines +257 to +270
***** xref:develop:api/reference/components/accountability.adoc[Accountability]
****** xref:develop:api/reference/components/accountability/create.adoc[Create Result]
****** xref:develop:api/reference/components/accountability/update.adoc[Update Result]
****** xref:develop:api/reference/components/accountability/delete.adoc[Delete Result]
****** xref:develop:api/reference/components/accountability/milestone/create.adoc[Create Milestone]
****** xref:develop:api/reference/components/accountability/milestone/update.adoc[Update Milestone]
****** xref:develop:api/reference/components/accountability/milestone/delete.adoc[Delete Milestone]
***** xref:develop:api/reference/components/budgets.adoc[Budgets]
****** xref:develop:api/reference/components/budgets/create.adoc[Create Budget]
****** xref:develop:api/reference/components/budgets/update.adoc[Update Budget]
****** xref:develop:api/reference/components/budgets/delete.adoc[Delete Budget]
****** xref:develop:api/reference/components/budgets/projects/create.adoc[Create Project]
****** xref:develop:api/reference/components/budgets/projects/update.adoc[Update Project]
****** xref:develop:api/reference/components/budgets/projects/delete.adoc[Delete Project]
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Description: Verify all new API reference files exist in the repository

# Define the base path for API reference docs
BASE_PATH="docs/en/modules/develop/pages/api/reference/components"

# Check accountability files
echo "=== Checking Accountability files ==="
fd -t f "accountability.adoc" "$BASE_PATH"
fd -t f "create.adoc" "$BASE_PATH/accountability"
fd -t f "update.adoc" "$BASE_PATH/accountability"
fd -t f "delete.adoc" "$BASE_PATH/accountability"
fd -t f "create.adoc" "$BASE_PATH/accountability/milestone"
fd -t f "update.adoc" "$BASE_PATH/accountability/milestone"
fd -t f "delete.adoc" "$BASE_PATH/accountability/milestone"

# Check budgets files
echo "=== Checking Budgets files ==="
fd -t f "budgets.adoc" "$BASE_PATH"
fd -t f "create.adoc" "$BASE_PATH/budgets"
fd -t f "update.adoc" "$BASE_PATH/budgets"
fd -t f "delete.adoc" "$BASE_PATH/budgets"
fd -t f "create.adoc" "$BASE_PATH/budgets/projects"
fd -t f "update.adoc" "$BASE_PATH/budgets/projects"
fd -t f "delete.adoc" "$BASE_PATH/budgets/projects"

# List all files to see what's actually there
echo "=== All files in components directory ==="
tree -L 4 "$BASE_PATH" || find "$BASE_PATH" -type f -name "*.adoc" | sort

Repository: decidim/documentation

Length of output: 2567


🏁 Script executed:

#!/bin/bash
set -euo pipefail

cd "$(git rev-parse --show-toplevel 2>/dev/null || pwd)"

# Filenames referenced by the new xrefs (relative to the xref "components/...")
files=(
  "accountability.adoc"
  "accountability/create.adoc"
  "accountability/update.adoc"
  "accountability/delete.adoc"
  "accountability/milestone/create.adoc"
  "accountability/milestone/update.adoc"
  "accountability/milestone/delete.adoc"
  "budgets.adoc"
  "budgets/create.adoc"
  "budgets/update.adoc"
  "budgets/delete.adoc"
  "budgets/projects/create.adoc"
  "budgets/projects/update.adoc"
  "budgets/projects/delete.adoc"
)

echo "=== Repo matches for each referenced filename ==="
for f in "${files[@]}"; do
  name="$(basename "$f")"
  echo "--- $f (looking for *$name) ---"
  # Prefer exact relative match if present; otherwise show all occurrences of the basename.
  # (Avoid huge output by limiting to first 50 matches per file.)
  matches="$(fd -t f "$name" . --hidden --follow 2>/dev/null | head -n 50 || true)"
  if [[ -z "${matches}" ]]; then
    echo "MISSING: no matches for *${name}"
  else
    echo "$matches" | sed 's#^./##'
  fi
done

echo "=== Attempt exact path matches for each xref-derived path ==="
# Try to resolve the exact xref-derived paths that the original script assumed:
# docs/en/modules/develop/pages/api/reference/components/<f>
BASE="docs/en/modules/develop/pages/api/reference/components"
for f in "${files[@]}"; do
  p="$BASE/$f"
  if [[ -f "$p" ]]; then
    echo "OK: $p"
  else
    echo "MISSING: $p"
  fi
done

Repository: decidim/documentation

Length of output: 3957


🏁 Script executed:

#!/bin/bash
set -euo pipefail
cd "$(git rev-parse --show-toplevel 2>/dev/null || pwd)"

# Search for exact xref target paths used in nav.adoc
rg -n --hidden --no-ignore-vcs -S "accountability/create\.adoc|accountability/update\.adoc|accountability/delete\.adoc|accountability/milestone/(create|update|delete)\.adoc|budgets/(create|update|delete)\.adoc|budgets/projects/(create|update|delete)\.adoc" docs/en/modules/ROOT/nav.adoc . \
  || true

# Also show whether there are any files named exactly create.adoc/update.adoc/delete.adoc (anywhere)
echo "=== Any files named exactly create.adoc/update.adoc/delete.adoc ==="
fd -t f "create.adoc" . --hidden --follow || true
fd -t f "update.adoc" . --hidden --follow || true
fd -t f "delete.adoc" . --hidden --follow || true

Repository: decidim/documentation

Length of output: 3115


🏁 Script executed:

#!/bin/bash
set -euo pipefail
cd "$(git rev-parse --show-toplevel 2>/dev/null || pwd)"

# 1) Check whether the originally assumed api reference components directory exists
echo "=== Directory existence checks ==="
for p in \
  "docs/en/modules/develop/pages/api/reference" \
  "docs/en/modules/develop/pages/api/reference/components" \
  "docs/en/modules/develop/pages/api/reference/components/accountability" \
  "docs/en/modules/develop/pages/api/reference/components/budgets" ; do
  if [[ -d "$p" ]]; then
    echo "OK DIR: $p"
  else
    echo "MISSING DIR: $p"
  fi
done

# 2) Find any files under develop api reference that mention accountability/budgets
echo "=== Files under develop api reference mentioning accountability/budgets ==="
if [[ -d "docs/en/modules/develop/pages/api/reference" ]]; then
  find docs/en/modules/develop/pages/api/reference -type f \( -name "*accountability*" -o -name "*budgets*" \) -maxdepth 8 | sort | sed -n '1,200p'
else
  echo "SKIP: docs/en/modules/develop/pages/api/reference does not exist"
fi

# 3) Search for the exact xref targets (path-like) as strings across repo
echo "=== String search for xref targets ==="
rg -n --hidden --no-ignore-vcs "api/reference/components/accountability/create\.adoc|api/reference/components/accountability/update\.adoc|api/reference/components/accountability/delete\.adoc|api/reference/components/accountability/milestone/create\.adoc|api/reference/components/accountability/milestone/update\.adoc|api/reference/components/accountability/milestone/delete\.adoc|api/reference/components/budgets/create\.adoc|api/reference/components/budgets/update\.adoc|api/reference/components/budgets/delete\.adoc|api/reference/components/budgets/projects/create\.adoc|api/reference/components/budgets/projects/update\.adoc|api/reference/components/budgets/projects/delete\.adoc" . || true

# 4) Search for any .adoc files whose basename is create.adoc/update.adoc/delete.adoc inside api/reference
echo "=== Basename checks for create/update/delete under api/reference ==="
if [[ -d "docs/en/modules/develop/pages/api/reference" ]]; then
  fd -t f "create.adoc" docs/en/modules/develop/pages/api/reference --hidden --follow | head -n 200 || true
  fd -t f "update.adoc" docs/en/modules/develop/pages/api/reference --hidden --follow | head -n 200 || true
  fd -t f "delete.adoc" docs/en/modules/develop/pages/api/reference --hidden --follow | head -n 200 || true
fi

Repository: decidim/documentation

Length of output: 2136


🏁 Script executed:

#!/bin/bash
set -euo pipefail
cd "$(git rev-parse --show-toplevel 2>/dev/null || pwd)"

echo "=== Case-insensitive existence of create/update/delete .adoc anywhere ==="
for pat in "create.adoc" "update.adoc" "delete.adoc"; do
  echo "--- Searching for *${pat} (case-insensitive) ---"
  fd -t f -i "$pat" . --hidden --follow | head -n 200 || true
done

echo "=== Inspect existing accountability directories/files (admin pages) ==="
for p in \
  "docs/en/modules/admin/pages/components/accountability" \
  "docs/en/modules/admin/pages/components/budgets" \
  "docs/en/modules/admin/pages/components/budgets/projects" ; do
  if [[ -d "$p" ]]; then
    echo "=== tree: $p ==="
    tree -L 6 "$p" || true
  else
    echo "MISSING DIR: $p"
  fi
done

echo "=== Find all accountability* and budgets* paths under docs/en/modules/*/pages/components ==="
find docs/en/modules -path "*/pages/components/*" -type f \( -iname "*accountability*" -o -iname "*budgets*" \) | sort | head -n 200 || true

Repository: decidim/documentation

Length of output: 1085


Fix broken xref targets for new accountability/budgets API reference pages

  • docs/en/modules/ROOT/nav.adoc (lines 257-270) adds xrefs to develop:api/reference/components/.../*.adoc, but docs/en/modules/develop/pages/api/reference/ doesn’t exist in this repo and the referenced files (e.g., accountability/create.adoc, budgets/projects/create.adoc, etc.) are missing.
  • The only corresponding content found is under docs/en/modules/admin/pages/components/ (e.g., accountability/results.adoc, budgets/budgets.adoc, budgets/projects.adoc), so these xrefs will likely 404.
  • Update the xref targets to the actual existing doc paths or add the missing develop:api/reference/... pages.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@docs/en/modules/ROOT/nav.adoc` around lines 257 - 270, The new xrefs in
docs/en/modules/ROOT/nav.adoc reference non-existent pages (e.g.,
develop:api/reference/components/accountability/create.adoc,
develop:api/reference/components/accountability/milestone/create.adoc,
develop:api/reference/components/budgets/create.adoc,
develop:api/reference/components/budgets/projects/create.adoc); either change
those xref targets to the actual existing docs under admin (for example point to
admin pages like
docs/en/modules/admin/pages/components/accountability/results.adoc or
docs/en/modules/admin/pages/components/budgets/projects.adoc) or add the missing
develop:api/reference/... .adoc files so the xrefs resolve; update the lines
that list the xrefs in docs/en/modules/ROOT/nav.adoc to use the correct target
strings or ensure the matching files are created with the expected names.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants