Skip to content

Fix UserSettingsRepositoriesPage to show user repos when only added via public code (no code host connections)

Warren Gifford requested to merge upr-count into main

Created by: arussellsaw

closes #19161 (closed) closes #19162 (closed)

I spotted this morning that if you added code via public repos without any code host connections, nothing would appear. this is because we were testing for the existence of code hosts to show the FilteredConnection element. It also meant that there was no entrypoint to add public code without a code host connection, i've fixed that as well with updated copy & different logic for showing the add/manage repos button.

There's some slightly janky state in here, as we need to present the filtered connection in order to populate the hasRepos state, and then hide it if there's nothing. If there's a better way for me to directly call queryRepositories without creating too many extra network requests please let me know, but i wasn't sure how i could do that.

Merge request reports

Loading