Skip to content

feat(android): support rename, move, and trash in SAF picker#440

Open
terrerox wants to merge 2 commits into
feature/PB-5927-folder-file-listingfrom
feature/PB-5930-rename-move-trash
Open

feat(android): support rename, move, and trash in SAF picker#440
terrerox wants to merge 2 commits into
feature/PB-5927-folder-file-listingfrom
feature/PB-5930-rename-move-trash

Conversation

@terrerox
Copy link
Copy Markdown

  • Override renameDocument, moveDocument, and deleteDocument in InternxtDocumentsProvider so SAF surfaces the corresponding row actions.
  • Surface FLAG_SUPPORTS_RENAME | FLAG_SUPPORTS_DELETE | FLAG_SUPPORTS_MOVE on file and folder rows; keep root and placeholder rows mutation-free.
  • Cache item kind (file vs folder) per UUID so mutations resolve their endpoint without an extra round-trip on the happy path.
  • Notify affected child-document URIs after each mutation so the picker refreshes without manual reload.
  • Fix InternxtApiClient.renameFile / renameFolder to match the SDK: PUT /{files|folders}/{uuid}/meta with { plainName }, void response.
  • Await clearCredentials in signOutThunk so the SAF root is hidden immediately after logout instead of lingering until documentsui refreshes.

  - Implement queryChildDocuments to paginate folders + files for a parent UUID
  - Implement queryDocument to resolve real metadata via folders/{uuid}/meta
    and files/{uuid}/meta, with a UUID-named placeholder fallback for
    offline / transient failures
  - Add InternxtApiClient.getFolder / getFile (404 → null) plus tests
  - Introduce DocumentRowBuilder (column-keyed rows) and MimeTypes
    (hand-rolled table + Android MimeTypeMap fallback) with tests
  - Surface InternxtApiException + null auth-config via Log.w so silent
    failures are no longer invisible
  - Fix auth slice to sync newToken (not token) to native credentials so
    the documents provider authenticates against drive endpoints
  - Override renameDocument, moveDocument, and deleteDocument in InternxtDocumentsProvider so SAF surfaces the corresponding row actions.
  - Surface FLAG_SUPPORTS_RENAME | FLAG_SUPPORTS_DELETE | FLAG_SUPPORTS_MOVE on file and folder rows; keep root and placeholder rows mutation-free.
  - Cache item kind (file vs folder) per UUID so mutations resolve their endpoint without an extra round-trip on the happy path.
  - Notify affected child-document URIs after each mutation so the picker refreshes without manual reload.
  - Fix InternxtApiClient.renameFile / renameFolder to match the SDK: PUT /{files|folders}/{uuid}/meta with { plainName }, void response.
  - Await clearCredentials in signOutThunk so the SAF root is hidden immediately after logout instead of lingering until documentsui refreshes.
@terrerox terrerox self-assigned this Apr 30, 2026
@sonarqubecloud
Copy link
Copy Markdown

@terrerox terrerox requested a review from CandelR May 1, 2026 04:54
@terrerox terrerox force-pushed the feature/PB-5927-folder-file-listing branch from 7c7801a to 600ee1d Compare May 13, 2026 04:28
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.

1 participant