Closed
Description
Regular servers shows a share icon on the top bar:
it should be hidden for kws servers, since sharing is not an available feature (as today)
Also, take in account the following comment #5022 (comment): Share option should not be available in the bottom sheet.
TASKS
- Research (if needed)
- Create branch fix/remove_share_option_in_kws_accounts
- Development tasks
- Remove
Shareoption from top bar - Remove
Sharefrom bottom sheet - Implement unit tests (if needed)
- Remove
- Code review and apply changes requested
- Design test plan
- QA
- Merge branch fix/remove_share_option_in_kws_accounts into master
Activity
joragua commentedon Oct 28, 2026
Problem
Regular oC10/oCIS servers show a share icon in the top app bar and a
Shareoption in the file bottom sheet. Kiteworks (kws) accounts do not support sharing as a feature today, yet these affordances are still rendered for them. A kws user who taps the share icon or theSharebottom-sheet option reaches a flow that cannot work on their server (confirmed in PR #5022 comment).Desired behavior
When the current account is a Kiteworks server, every entry point to the sharing flow is hidden:
Shareoption in the file bottom sheet is not listed.For non-kws accounts, behavior is unchanged.
User stories
Shareoption in the file bottom sheet, so I'm not led into a flow that can't complete.Constraints
Acceptance criteria
R.id.action_share_file) is not visible in the action mode toolbar nor in the file details screen.R.id.action_share_current_folder) is not visible in the main top app bar.Share(FileMenuOption.SHARE) does not appear as a row in the file bottom sheet.Out of scope
Assumptions
capability.spaces?.hasMultiplePersonalSpaces == true(the same signal already read byCapabilityViewModel.checkMultiPersonal()).AccountManageruser data underKEY_IS_KITEWORKS_SERVER = "is_kiteworks_server"(written inOCLocalAuthenticationDataSource), available as a fallback/alternative without any network request. This flag is currently read only in the auth layer (OwnCloudAccount,AccountAuthenticator,LoginActivity) and never in the file-UI presentation layer.Sharerow are driven by the same source of truth:FilterFileMenuOptionsUseCase.run(...)returns the list ofFileMenuOptions, applied to the toolbar viaMenu.filterMenuOptions(MenuExt.kt) and to the bottom sheet viaMainFileListFragment.setMenuOption. SuppressingFileMenuOption.SHAREthere removes the affordance from both at once.FilterFileMenuOptionsUseCase.runalready fetches the capabilities for the account (capability = capabilityRepository.getStoredCapabilities(params.accountName)), so the multiSpace/kws check can be done in place with no change toParamsand no new dependency.MainFileListFragment.onCreateOptionsMenu(already conditionally removed when picking a folder / non-personal space), so it needs an additional kws check there.Implementation notes
[-][FEATURE REQUEST] Remove share icon from top bar in kws accounts[/-][+][BUG] Remove share icon from top bar in kws accounts[/+]