0

fix(mobile): do not show action menu if there are no actions. Closes #2985

This commit is contained in:
Gabe Kangas 2023-05-04 21:37:52 -07:00
parent 486740ad06
commit c79834a752
No known key found for this signature in database
GPG Key ID: 4345B2060657F330

View File

@ -68,15 +68,19 @@ const ActionButtons: FC<ActionButtonProps> = ({
</ActionButtonRow>
</div>
<div className={styles.mobileActionButtonMenu}>
<ActionButtonMenu
className={styles.actionButtonMenu}
showFollowItem={supportFediverseFeatures}
showNotifyItem={supportsBrowserNotifications}
actions={externalActions}
externalActionSelected={setExternalActionToDisplay}
notifyItemSelected={() => setShowNotifyModal(true)}
followItemSelected={() => setShowFollowModal(true)}
/>
{(supportsBrowserNotifications ||
supportsBrowserNotifications ||
externalActionButtons.length > 0) && (
<ActionButtonMenu
className={styles.actionButtonMenu}
showFollowItem={supportFediverseFeatures}
showNotifyItem={supportsBrowserNotifications}
actions={externalActions}
externalActionSelected={setExternalActionToDisplay}
notifyItemSelected={() => setShowNotifyModal(true)}
followItemSelected={() => setShowFollowModal(true)}
/>
)}
</div>
</>
);