Page MenuHomePhabricator

D4312.diff
No OneTemporary

D4312.diff

diff --git a/web/settings/relationship/add-friends-modal.react.js b/web/settings/relationship/add-friends-modal.react.js
new file mode 100644
--- /dev/null
+++ b/web/settings/relationship/add-friends-modal.react.js
@@ -0,0 +1,38 @@
+// @flow
+
+import * as React from 'react';
+
+import {
+ relationshipActions,
+ userRelationshipStatus,
+} from 'lib/types/relationship-types.js';
+
+import AddUsersListModal from './add-users-list-modal.react';
+
+const excludedStatuses = new Set([
+ userRelationshipStatus.FRIEND,
+ userRelationshipStatus.BLOCKED_VIEWER,
+ userRelationshipStatus.BOTH_BLOCKED,
+ userRelationshipStatus.REQUEST_SENT,
+ userRelationshipStatus.REQUEST_RECEIVED,
+]);
+
+type Props = {
+ +onClose: () => void,
+};
+
+function AddFriendsModal(props: Props): React.Node {
+ const { onClose } = props;
+
+ return (
+ <AddUsersListModal
+ closeModal={onClose}
+ name="Add Friends"
+ excludedStatuses={excludedStatuses}
+ confirmButtonContent="Send Friend Requests"
+ relationshipAction={relationshipActions.FRIEND}
+ />
+ );
+}
+
+export default AddFriendsModal;

File Metadata

Mime Type
text/plain
Expires
Thu, Dec 19, 9:59 AM (21 h, 12 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2676670
Default Alt Text
D4312.diff (1 KB)

Event Timeline