author
int64
658
755k
date
stringlengths
19
19
timezone
int64
-46,800
43.2k
hash
stringlengths
40
40
message
stringlengths
5
490
mods
list
language
stringclasses
20 values
license
stringclasses
3 values
repo
stringlengths
5
68
original_message
stringlengths
12
491
129,184
12.04.2022 15:40:38
14,400
38632c63ef00823a8efc28d774c0f6322eee4214
[web] Remove "active" `transition` for `ColorSelectorButton` component Summary: Addresses feedback from here: Test Plan: Looks as expected: {F38040} Reviewers: def-au1t, palys-swm Subscribers: ashoat, Adrian, karol-bisztyga, benschac, yayabosh, palys-swm
[ { "change_type": "MODIFY", "old_path": "web/modals/threads/color-selector-button.css", "new_path": "web/modals/threads/color-selector-button.css", "diff": "@@ -6,13 +6,11 @@ div.container {\nalign-items: center;\njustify-content: center;\ndisplay: flex;\n- transition: 150ms;\n}\ndiv.active,\ndiv.container:hover {\nbackground-color: var(--color-selector-active-bg);\n- transition: 150ms;\n}\ndiv.colorSplotch {\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Remove "active" `transition` for `ColorSelectorButton` component Summary: Addresses feedback from @palys-swm here: https://phabricator.ashoat.com/D3699#101943 Test Plan: Looks as expected: {F38040} Reviewers: def-au1t, palys-swm Reviewed By: palys-swm Subscribers: ashoat, Adrian, karol-bisztyga, benschac, yayabosh, palys-swm Differential Revision: https://phabricator.ashoat.com/D3714
129,191
14.04.2022 20:26:39
-7,200
9b4481c37d33b74f10f932dc6378bce0ac7e9564
[lib] Fix memoization of useRelationshipPrompt Summary: We were using callbacks but the return value was never memoized. Depends on D3734 Test Plan: Send friend request by using relationship prompt and check if the state was updated. Reviewers: benschac, atul, def-au1t Subscribers: ashoat, Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "lib/hooks/relationship-prompt.js", "new_path": "lib/hooks/relationship-prompt.js", "diff": "@@ -52,10 +52,13 @@ function useRelationshipPrompt(\nonErrorCallback,\n);\n- return {\n+ return React.useMemo(\n+ () => ({\notherUserInfo,\ncallbacks,\n- };\n+ }),\n+ [callbacks, otherUserInfo],\n+ );\n}\nfunction useRelationshipCallbacks(\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib] Fix memoization of useRelationshipPrompt Summary: We were using callbacks but the return value was never memoized. Depends on D3734 Test Plan: Send friend request by using relationship prompt and check if the state was updated. Reviewers: benschac, atul, def-au1t Reviewed By: atul Subscribers: ashoat, Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3735
129,179
19.04.2022 09:46:09
14,400
d77f80b11afb0614c2e8a3f1c161998f2bcf4332
[web] [fix] update thread selected state text Summary: change text color per issue and conversation with ashoat. {F37149} Test Plan: select a chat thread list item on web Reviewers: atul, palys-swm, def-au1t Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/chat/chat-thread-list.css", "new_path": "web/chat/chat-thread-list.css", "diff": "@@ -31,11 +31,11 @@ div.threadListSidebar:hover {\n}\ndiv.activeThread :is(div.dark, .lastMessage span.read, .title) {\n- color: var(--fg);\n+ color: var(--chat-thread-list-color-active);\n}\ndiv.activeThread .lastMessage.read {\n- color: var(--fg);\n+ color: var(--chat-thread-list-color-active);\n}\ndiv.activeThread.thread:hover {\n" }, { "change_type": "MODIFY", "old_path": "web/theme.css", "new_path": "web/theme.css", "diff": "--app-list-icon-disabled-color: var(--shades-white-80);\n--account-settings-label: var(--shades-black-60);\n--account-button-color: var(--violet-dark-100);\n+ --chat-thread-list-color-active: var(--shades-of-white-60);\n--chat-thread-list-menu-color: var(--shades-white-60);\n--chat-thread-list-menu-bg: var(--shades-black-80);\n--chat-thread-list-menu-active-color: var(--shades-white-60);\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] [fix] [ENG-731] update thread selected state text Summary: change text color per issue and conversation with ashoat. https://linear.app/comm/issue/ENG-731/appearance-of-thread-selected-state-makes-it-look-unread {F37149} Test Plan: select a chat thread list item on web Reviewers: atul, palys-swm, def-au1t Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3698
129,179
19.04.2022 12:50:20
14,400
c6f4c30d210e8a092d48485e67787e61e005c430
[web] [fix] add notif dot for thread Summary: adds notif dot to thread in conversation selector {F23185} Test Plan: send your self a message from one user to another, click sidebar to toggle off unread. Reviewers: atul, def-au1t, palys-swm Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga
[ { "change_type": "MODIFY", "old_path": "web/chat/chat-thread-list-sidebar.react.js", "new_path": "web/chat/chat-thread-list-sidebar.react.js", "diff": "@@ -19,10 +19,17 @@ type Props = {\nfunction ChatThreadListSidebar(props: Props): React.Node {\nconst { sidebarInfo } = props;\nconst { threadInfo, mostRecentNonLocalMessage } = sidebarInfo;\n- const threadID = threadInfo.id;\n+ const {\n+ currentUser: { unread },\n+ id: threadID,\n+ } = threadInfo;\nconst active = useThreadIsActive(threadID);\nconst onClick = useOnClickThread(threadInfo);\n+ let unreadDot;\n+ if (unread) {\n+ unreadDot = <div className={css.unreadDot} />;\n+ }\nreturn (\n<div\n@@ -31,6 +38,7 @@ function ChatThreadListSidebar(props: Props): React.Node {\n})}\nonClick={onClick}\n>\n+ <div className={css.dotContainer}>{unreadDot}</div>\n<SidebarItem sidebarInfo={sidebarInfo} />\n<ChatThreadListItemMenu\nthreadInfo={threadInfo}\n" }, { "change_type": "MODIFY", "old_path": "web/chat/chat-thread-list.css", "new_path": "web/chat/chat-thread-list.css", "diff": "@@ -11,7 +11,6 @@ div.threadListSidebar {\ndisplay: flex;\nflex-direction: row;\nheight: 32px;\n- padding-left: 16px;\npadding-right: 10px;\nposition: relative;\ncursor: pointer;\n@@ -158,6 +157,9 @@ div.sidebarTitle {\ncolor: var(--thread-color-read);\nalign-self: flex-start;\n}\n+div.threadListSidebar > div.dotContainer {\n+ width: 16px;\n+}\ndiv.sidebarTitle.unread {\ncolor: var(--fg);\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] [fix] ENG-730 add notif dot for thread Summary: adds notif dot to thread in conversation selector https://linear.app/comm/issue/ENG-730/unread-indication-for-sidebars-is-very-strange {F23185} Test Plan: send your self a message from one user to another, click sidebar to toggle off unread. Reviewers: atul, def-au1t, palys-swm Reviewed By: atul Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga Differential Revision: https://phabricator.ashoat.com/D3444
129,179
19.04.2022 13:02:11
14,400
0aa0ced7a43d4ddb7cb4797a14268289c4f9580c
[web] [fix] dot alignment Summary: dot wasn't aligned with color splotch {F38740} {F38751} Test Plan: send a new message, un read dot should be aligned Reviewers: atul, def-au1t, yayabosh, palys-swm Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/chat/chat-thread-list-item.react.js", "new_path": "web/chat/chat-thread-list-item.react.js", "diff": "@@ -132,10 +132,11 @@ function ChatThreadListItem(props: Props): React.Node {\n<>\n<div className={containerClassName} onClick={onClick}>\n<div className={css.colorContainer}>\n+ <div className={css.colorSplotchContainer}>\n<div className={css.dotContainer}>{unreadDot}</div>\n-\n<div className={css.colorSplotch} style={colorSplotchStyle} />\n</div>\n+ </div>\n<div className={css.threadButton}>\n<p className={breadCrumbsClassName}>{ancestorPath}</p>\n<div className={css.threadRow}>\n" }, { "change_type": "MODIFY", "old_path": "web/chat/chat-thread-list.css", "new_path": "web/chat/chat-thread-list.css", "diff": "@@ -98,10 +98,13 @@ div.colorContainer {\ndiv.spacer,\ndiv.colorSplotch {\n- height: 42px;\nwidth: 42px;\nborder-radius: 1.68px;\n}\n+div.colorSplotchContainer {\n+ height: 42px;\n+ display: flex;\n+}\ndiv.lastActivity {\nfont-size: var(--xxs-font-10);\ncolor: var(--fg);\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] [fix] dot alignment Summary: dot wasn't aligned with color splotch {F38740} {F38751} Test Plan: send a new message, un read dot should be aligned Reviewers: atul, def-au1t, yayabosh, palys-swm Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3723
129,179
19.04.2022 13:07:36
14,400
bcf164d0220b1f7070544c1eda36cfa18cef13bb
[web] [fix] fix unread last message timestamp Summary: size and padding didn't match figma. after: {F38726} before: {F38727} Test Plan: it should match figma Reviewers: atul, def-au1t, palys-swm Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/chat/chat-thread-list.css", "new_path": "web/chat/chat-thread-list.css", "diff": "@@ -109,6 +109,7 @@ div.lastActivity {\nfont-size: var(--xxs-font-10);\ncolor: var(--fg);\nline-height: 1.5;\n+ padding-right: 16px;\nfont-weight: var(--semi-bold);\nwhite-space: nowrap;\nflex-grow: 1;\n@@ -131,7 +132,6 @@ div.threadRow > .lastMessage {\n}\ndiv.unread {\ncolor: var(--fg);\n- font-size: var(--s-font-14);\nfont-weight: var(--semi-bold);\n}\ndiv.lastMessage.unread {\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] [fix] fix unread last message timestamp Summary: size and padding didn't match figma. after: {F38726} before: {F38727} Test Plan: it should match figma https://www.figma.com/file/a1nkbWgbgjRlrOY9LVurTz/Comm-%2F-Desktop-app?node-id=1170%3A79583 Reviewers: atul, def-au1t, palys-swm Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3725
129,190
13.04.2022 16:22:03
-7,200
6a19136b312a06cdcd45e7e5fd81118b25abffb3
[services] Backup - pull backup reactor - logs - write response Summary: Depends on D3635 The logic for `writeResponse` handling writing compaction chunks Test Plan: The same as in D3535 Reviewers: palys-swm, geekbrother Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/server/PullBackupReactor.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/server/PullBackupReactor.h", "diff": "#pragma once\n#include \"BlobGetClientReactor.h\"\n+#include \"DatabaseEntitiesTools.h\"\n#include \"DatabaseManager.h\"\n#include \"ServerWriteReactorBase.h\"\n#include \"ServiceBlobClient.h\"\n#include <iostream>\n#include <memory>\n#include <string>\n+#include <vector>\nnamespace comm {\nnamespace network {\n@@ -33,6 +35,9 @@ class PullBackupReactor : public ServerWriteReactorBase<\nstd::shared_ptr<folly::MPMCQueue<std::string>> dataChunks;\nServiceBlobClient blobClient;\nState state = State::COMPACTION;\n+ std::vector<std::shared_ptr<database::LogItem>> logs;\n+ size_t currentLogIndex = 0;\n+ std::shared_ptr<database::LogItem> currentLog;\nvoid initializeGetReactor(const std::string &holder);\n@@ -83,7 +88,8 @@ void PullBackupReactor::initialize() {\nthis->request.userid() + \"], backup id [\" + this->request.backupid() +\n\"]\");\n}\n- // TODO get logs\n+ this->logs = database::DatabaseManager::getInstance().findLogItemsForBackup(\n+ this->request.backupid());\n}\nstd::unique_ptr<grpc::Status>\n@@ -91,23 +97,52 @@ PullBackupReactor::writeResponse(backup::PullBackupResponse *response) {\n// we make sure that the blob client's state is flushed to the main memory\n// as there may be multiple threads from the pool taking over here\nconst std::lock_guard<std::mutex> lock(this->reactorStateMutex);\n- switch (this->state) {\n- case State::COMPACTION: {\n+ if (this->state == State::COMPACTION) {\nthis->initializeGetReactor(this->backupItem->getCompactionHolder());\nstd::string dataChunk;\nthis->dataChunks->blockingRead(dataChunk);\n- if (dataChunk.empty()) {\n- // TODO try to immediately start writing logs instead of wasting a cycle\n- // sending nothing\n- this->state = State::LOGS;\n+ if (!dataChunk.empty()) {\n+ response->set_compactionchunk(dataChunk);\nreturn nullptr;\n}\n- response->set_compactionchunk(dataChunk);\n+ if (!this->dataChunks->isEmpty()) {\n+ throw std::runtime_error(\n+ \"dangling data discovered after reading compaction\");\n+ }\n+ this->getReactor = nullptr;\n+ this->state = State::LOGS;\n+ }\n+ if (this->state == State::LOGS) {\n+ // TODO make sure logs are received in correct order regardless their size\n+ if (this->logs.empty()) {\n+ return std::make_unique<grpc::Status>(grpc::Status::OK);\n+ }\n+ if (this->currentLogIndex == this->logs.size()) {\n+ return std::make_unique<grpc::Status>(grpc::Status::OK);\n+ }\n+ if (this->currentLogIndex > this->logs.size()) {\n+ throw std::runtime_error(\"log index out of bound\");\n+ }\n+ if (this->currentLog == nullptr) {\n+ this->currentLog = this->logs.at(this->currentLogIndex);\n+ if (this->currentLog->getPersistedInBlob()) {\n+ this->initializeGetReactor(this->currentLog->getValue());\n+ } else {\n+ response->set_logchunk(this->currentLog->getValue());\n+ ++this->currentLogIndex;\n+ this->currentLog = nullptr;\nreturn nullptr;\n}\n- case State::LOGS: {\n- throw std::runtime_error(\"unimplemented\");\n}\n+ std::string dataChunk;\n+ this->dataChunks->blockingRead(dataChunk);\n+ if (dataChunk.empty()) {\n+ ++this->currentLogIndex;\n+ this->currentLog = nullptr;\n+ } else {\n+ response->set_logchunk(dataChunk);\n+ }\n+ return nullptr;\n}\nthrow std::runtime_error(\"unhandled state\");\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Backup - pull backup reactor - logs - write response Summary: Depends on D3635 The logic for `writeResponse` handling writing compaction chunks Test Plan: The same as in D3535 Reviewers: palys-swm, geekbrother Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3636
129,190
13.04.2022 16:22:11
-7,200
7bc7053e2401f804e53a18c153e8af7b81624a5d
[services] Backup - Blob client reactors - add getStatus Summary: Depends on D3719 We need to be able to pull the status by external objects from blob client reactors. Test Plan: ``` cd services yarn run-backup-service ``` Reviewers: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/client/blob/BlobGetClientReactor.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/client/blob/BlobGetClientReactor.h", "diff": "@@ -28,6 +28,7 @@ public:\nstd::unique_ptr<grpc::Status>\nreadResponse(blob::GetResponse &response) override;\nvoid doneCallback() override;\n+ grpc::Status getStatus() const;\n};\nBlobGetClientReactor::BlobGetClientReactor(\n@@ -49,6 +50,10 @@ void BlobGetClientReactor::doneCallback() {\nthis->dataChunks->write(\"\");\n}\n+grpc::Status BlobGetClientReactor::getStatus() const {\n+ return this->status;\n+}\n+\n} // namespace reactor\n} // namespace network\n} // namespace comm\n" }, { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/client/blob/BlobPutClientReactor.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/client/blob/BlobPutClientReactor.h", "diff": "@@ -46,6 +46,7 @@ public:\nblob::PutRequest &request,\nstd::shared_ptr<blob::PutResponse> previousResponse) override;\nvoid doneCallback() override;\n+ grpc::Status getStatus() const;\n};\nBlobPutClientReactor::BlobPutClientReactor(\n@@ -95,6 +96,10 @@ void BlobPutClientReactor::doneCallback() {\nthis->terminationNotifier->notify_one();\n}\n+grpc::Status BlobPutClientReactor::getStatus() const {\n+ return this->status;\n+}\n+\n} // namespace reactor\n} // namespace network\n} // namespace comm\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Backup - Blob client reactors - add getStatus Summary: Depends on D3719 We need to be able to pull the status by external objects from blob client reactors. Test Plan: ``` cd services yarn run-backup-service ``` Reviewers: palys-swm Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3720
129,190
21.04.2022 12:18:28
-7,200
92c64841f20b903c86180017595628ef5b0b11ef
[services] Backup/Blob - wrap terminateCallback into try...catch Summary: Depends on D3720 We need to be able to throw in the `terminationCallback` and handle it gracefully. Test Plan: ``` cd services yarn run-backup-service yarn run-blob-service ``` Reviewers: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "diff": "@@ -65,8 +65,8 @@ template <class Request, class Response>\nvoid ServerBidiReactorBase<Request, Response>::terminate(\nServerBidiReactorStatus status) {\nthis->status = status;\n- this->terminateCallback();\ntry {\n+ this->terminateCallback();\nthis->validate();\n} catch (std::runtime_error &e) {\nthis->status = ServerBidiReactorStatus(\n" }, { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "diff": "@@ -38,8 +38,8 @@ public:\ntemplate <class Request, class Response>\nvoid ServerReadReactorBase<Request, Response>::terminate(grpc::Status status) {\nthis->status = status;\n- this->terminateCallback();\ntry {\n+ this->terminateCallback();\nthis->validate();\n} catch (std::runtime_error &e) {\nthis->status = grpc::Status(grpc::StatusCode::INTERNAL, e.what());\n" }, { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "diff": "@@ -39,11 +39,15 @@ public:\ntemplate <class Request, class Response>\nvoid ServerWriteReactorBase<Request, Response>::terminate(grpc::Status status) {\n+ this->status = status;\n+ try {\nthis->terminateCallback();\n+ } catch (std::runtime_error &e) {\n+ this->status = grpc::Status(grpc::StatusCode::INTERNAL, e.what());\n+ }\nif (!this->status.ok()) {\nstd::cout << \"error: \" << this->status.error_message() << std::endl;\n}\n- this->status = status;\nif (this->finished) {\nreturn;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "diff": "@@ -65,8 +65,8 @@ template <class Request, class Response>\nvoid ServerBidiReactorBase<Request, Response>::terminate(\nServerBidiReactorStatus status) {\nthis->status = status;\n- this->terminateCallback();\ntry {\n+ this->terminateCallback();\nthis->validate();\n} catch (std::runtime_error &e) {\nthis->status = ServerBidiReactorStatus(\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "diff": "@@ -38,8 +38,8 @@ public:\ntemplate <class Request, class Response>\nvoid ServerReadReactorBase<Request, Response>::terminate(grpc::Status status) {\nthis->status = status;\n- this->terminateCallback();\ntry {\n+ this->terminateCallback();\nthis->validate();\n} catch (std::runtime_error &e) {\nthis->status = grpc::Status(grpc::StatusCode::INTERNAL, e.what());\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "diff": "@@ -39,11 +39,15 @@ public:\ntemplate <class Request, class Response>\nvoid ServerWriteReactorBase<Request, Response>::terminate(grpc::Status status) {\n+ this->status = status;\n+ try {\nthis->terminateCallback();\n+ } catch (std::runtime_error &e) {\n+ this->status = grpc::Status(grpc::StatusCode::INTERNAL, e.what());\n+ }\nif (!this->status.ok()) {\nstd::cout << \"error: \" << this->status.error_message() << std::endl;\n}\n- this->status = status;\nif (this->finished) {\nreturn;\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Backup/Blob - wrap terminateCallback into try...catch Summary: Depends on D3720 We need to be able to throw in the `terminationCallback` and handle it gracefully. Test Plan: ``` cd services yarn run-backup-service yarn run-blob-service ``` Reviewers: palys-swm Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3721
129,190
21.04.2022 12:18:57
-7,200
5aefcb036f32244f949de75e538cdb19561de9e0
[services] Backup/Blob - Add validate method to server write reactor base Summary: Depends on D3721 Adding the `validate` method to the server write reactor base Test Plan: ``` cd services yarn run-backup-service yarn run-blob-service ``` Reviewers: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "diff": "@@ -33,6 +33,7 @@ public:\nvirtual std::unique_ptr<grpc::Status> writeResponse(Response *response) = 0;\nvirtual void initialize(){};\n+ virtual void validate(){};\nvirtual void doneCallback(){};\nvirtual void terminateCallback(){};\n};\n@@ -42,6 +43,7 @@ void ServerWriteReactorBase<Request, Response>::terminate(grpc::Status status) {\nthis->status = status;\ntry {\nthis->terminateCallback();\n+ this->validate();\n} catch (std::runtime_error &e) {\nthis->status = grpc::Status(grpc::StatusCode::INTERNAL, e.what());\n}\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "diff": "@@ -33,6 +33,7 @@ public:\nvirtual std::unique_ptr<grpc::Status> writeResponse(Response *response) = 0;\nvirtual void initialize(){};\n+ virtual void validate(){};\nvirtual void doneCallback(){};\nvirtual void terminateCallback(){};\n};\n@@ -42,6 +43,7 @@ void ServerWriteReactorBase<Request, Response>::terminate(grpc::Status status) {\nthis->status = status;\ntry {\nthis->terminateCallback();\n+ this->validate();\n} catch (std::runtime_error &e) {\nthis->status = grpc::Status(grpc::StatusCode::INTERNAL, e.what());\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Backup/Blob - Add validate method to server write reactor base Summary: Depends on D3721 Adding the `validate` method to the server write reactor base Test Plan: ``` cd services yarn run-backup-service yarn run-blob-service ``` Reviewers: palys-swm Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3803
129,190
21.04.2022 12:19:24
-7,200
cc6f856b5658dcf2e77ef0e86b3e740083047397
[services] Backup/Blob - Use this when reffering status Summary: Depends on D3803 Add `this->` when referring to status in base reactor classes Test Plan: ``` cd services yarn run-backup-service yarn run-blob-service ``` Reviewers: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "diff": "@@ -50,7 +50,7 @@ void ServerReadReactorBase<Request, Response>::terminate(grpc::Status status) {\nif (this->finished) {\nreturn;\n}\n- this->Finish(status);\n+ this->Finish(this->status);\nthis->finished = true;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "diff": "@@ -53,7 +53,7 @@ void ServerWriteReactorBase<Request, Response>::terminate(grpc::Status status) {\nif (this->finished) {\nreturn;\n}\n- this->Finish(status);\n+ this->Finish(this->status);\nthis->finished = true;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "diff": "@@ -50,7 +50,7 @@ void ServerReadReactorBase<Request, Response>::terminate(grpc::Status status) {\nif (this->finished) {\nreturn;\n}\n- this->Finish(status);\n+ this->Finish(this->status);\nthis->finished = true;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "diff": "@@ -53,7 +53,7 @@ void ServerWriteReactorBase<Request, Response>::terminate(grpc::Status status) {\nif (this->finished) {\nreturn;\n}\n- this->Finish(status);\n+ this->Finish(this->status);\nthis->finished = true;\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Backup/Blob - Use this when reffering status Summary: Depends on D3803 Add `this->` when referring to status in base reactor classes Test Plan: ``` cd services yarn run-backup-service yarn run-blob-service ``` Reviewers: palys-swm Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3804
129,179
15.04.2022 14:09:41
14,400
862ab3ac242c2dad98feefa276f99e5453b41cbe
[native] [refactor] use usePromoteSidebar hook Summary: use hook in native, remove old code Test Plan: use promote thread feature like you normally would. Reviewers: atul, def-au1t, palys-swm Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "native/chat/settings/thread-settings-promote-sidebar.react.js", "new_path": "native/chat/settings/thread-settings-promote-sidebar.react.js", "diff": "// @flow\nimport * as React from 'react';\n-import { Text, Alert, ActivityIndicator, View } from 'react-native';\n+import { Text, ActivityIndicator, View, Alert } from 'react-native';\n-import {\n- changeThreadSettingsActionTypes,\n- changeThreadSettings,\n-} from 'lib/actions/thread-actions';\n-import { createLoadingStatusSelector } from 'lib/selectors/loading-selectors';\n+import { usePromoteSidebar } from 'lib/hooks/promote-sidebar.react';\nimport type { LoadingStatus } from 'lib/types/loading-types';\n-import {\n- type ThreadInfo,\n- type UpdateThreadRequest,\n- type ChangeThreadSettingsPayload,\n- threadTypes,\n-} from 'lib/types/thread-types';\n-import {\n- type DispatchActionPromise,\n- useServerCall,\n- useDispatchActionPromise,\n-} from 'lib/utils/action-utils';\n+import type { ThreadInfo } from 'lib/types/thread-types';\nimport Button from '../../components/button.react';\n-import { useSelector } from '../../redux/redux-utils';\nimport { type Colors, useColors, useStyles } from '../../themes/colors';\nimport type { ViewStyle } from '../../types/styles';\n@@ -32,16 +17,10 @@ type BaseProps = {\n};\ntype Props = {\n...BaseProps,\n- // Redux state\n+loadingStatus: LoadingStatus,\n+colors: Colors,\n+styles: typeof unboundStyles,\n- // Redux dispatch functions\n- +dispatchActionPromise: DispatchActionPromise,\n- // async functions that hit server APIs\n- +changeThreadSettings: (\n- request: UpdateThreadRequest,\n- ) => Promise<ChangeThreadSettingsPayload>,\n+ +promoteSidebar: () => mixed,\n};\nclass ThreadSettingsPromoteSidebar extends React.PureComponent<Props> {\nrender() {\n@@ -56,7 +35,7 @@ class ThreadSettingsPromoteSidebar extends React.PureComponent<Props> {\nreturn (\n<View style={this.props.styles.container}>\n<Button\n- onPress={this.onPress}\n+ onPress={this.props.promoteSidebar}\nstyle={[this.props.styles.button, this.props.buttonStyle]}\niosFormat=\"highlight\"\niosHighlightUnderlayColor={panelIosHighlightUnderlay}\n@@ -67,28 +46,6 @@ class ThreadSettingsPromoteSidebar extends React.PureComponent<Props> {\n</View>\n);\n}\n-\n- onPress = () => {\n- this.props.dispatchActionPromise(\n- changeThreadSettingsActionTypes,\n- this.changeThreadSettings(),\n- );\n- };\n-\n- async changeThreadSettings() {\n- const threadID = this.props.threadInfo.id;\n- try {\n- return await this.props.changeThreadSettings({\n- threadID,\n- changes: { type: threadTypes.COMMUNITY_OPEN_SUBTHREAD },\n- });\n- } catch (e) {\n- Alert.alert('Unknown error', 'Uhh... try again?', undefined, {\n- cancelable: true,\n- });\n- throw e;\n- }\n- }\n}\nconst unboundStyles = {\n@@ -108,25 +65,29 @@ const unboundStyles = {\n},\n};\n-const loadingStatusSelector = createLoadingStatusSelector(\n- changeThreadSettingsActionTypes,\n-);\n+const onError = () => {\n+ Alert.alert('Unknown error', 'Uhh... try again?', undefined, {\n+ cancelable: true,\n+ });\n+};\nconst ConnectedThreadSettingsPromoteSidebar: React.ComponentType<BaseProps> = React.memo<BaseProps>(\nfunction ConnectedThreadSettingsPromoteSidebar(props: BaseProps) {\n- const loadingStatus = useSelector(loadingStatusSelector);\n+ const { threadInfo } = props;\nconst colors = useColors();\nconst styles = useStyles(unboundStyles);\n- const dispatchActionPromise = useDispatchActionPromise();\n- const callChangeThreadSettings = useServerCall(changeThreadSettings);\n+ const { onPromoteSidebar, loading } = usePromoteSidebar(\n+ threadInfo,\n+ onError,\n+ );\n+\nreturn (\n<ThreadSettingsPromoteSidebar\n{...props}\n- loadingStatus={loadingStatus}\ncolors={colors}\nstyles={styles}\n- dispatchActionPromise={dispatchActionPromise}\n- changeThreadSettings={callChangeThreadSettings}\n+ promoteSidebar={onPromoteSidebar}\n+ loadingStatus={loading}\n/>\n);\n},\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[native] [refactor] [ENG-991] use usePromoteSidebar hook Summary: use hook in native, remove old code https://linear.app/comm/issue/ENG-991/promote-sidebar-to-subthread-on-web Test Plan: use promote thread feature like you normally would. Reviewers: atul, def-au1t, palys-swm Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3748
129,190
22.04.2022 10:06:25
-7,200
c36fd0770f7ab348e3d228ba9d3b48098689a5a4
[services] Backup/Blob - Add comments to delete this Summary: Depends on D3722 Test Plan: None - these are just comments Reviewers: palys-swm, ashoat Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "diff": "@@ -58,6 +58,8 @@ ServerBidiReactorBase<Request, Response>::ServerBidiReactorBase() {\ntemplate <class Request, class Response>\nvoid ServerBidiReactorBase<Request, Response>::OnDone() {\nthis->doneCallback();\n+ // This looks weird but apparently it is okay to do this. More information:\n+ // https://phabricator.ashoat.com/D3246#87890\ndelete this;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "diff": "@@ -65,6 +65,8 @@ ServerReadReactorBase<Request, Response>::ServerReadReactorBase(\ntemplate <class Request, class Response>\nvoid ServerReadReactorBase<Request, Response>::OnDone() {\nthis->doneCallback();\n+ // This looks weird but apparently it is okay to do this. More information:\n+ // https://phabricator.ashoat.com/D3246#87890\ndelete this;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "diff": "@@ -91,6 +91,8 @@ void ServerWriteReactorBase<Request, Response>::NextWrite() {\ntemplate <class Request, class Response>\nvoid ServerWriteReactorBase<Request, Response>::OnDone() {\nthis->doneCallback();\n+ // This looks weird but apparently it is okay to do this. More information:\n+ // https://phabricator.ashoat.com/D3246#87890\ndelete this;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "diff": "@@ -58,6 +58,8 @@ ServerBidiReactorBase<Request, Response>::ServerBidiReactorBase() {\ntemplate <class Request, class Response>\nvoid ServerBidiReactorBase<Request, Response>::OnDone() {\nthis->doneCallback();\n+ // This looks weird but apparently it is okay to do this. More information:\n+ // https://phabricator.ashoat.com/D3246#87890\ndelete this;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "diff": "@@ -65,6 +65,8 @@ ServerReadReactorBase<Request, Response>::ServerReadReactorBase(\ntemplate <class Request, class Response>\nvoid ServerReadReactorBase<Request, Response>::OnDone() {\nthis->doneCallback();\n+ // This looks weird but apparently it is okay to do this. More information:\n+ // https://phabricator.ashoat.com/D3246#87890\ndelete this;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "diff": "@@ -91,6 +91,8 @@ void ServerWriteReactorBase<Request, Response>::NextWrite() {\ntemplate <class Request, class Response>\nvoid ServerWriteReactorBase<Request, Response>::OnDone() {\nthis->doneCallback();\n+ // This looks weird but apparently it is okay to do this. More information:\n+ // https://phabricator.ashoat.com/D3246#87890\ndelete this;\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Backup/Blob - Add comments to delete this Summary: Depends on D3722 https://linear.app/comm/issue/ENG-960/add-comments-for-delete-this Test Plan: None - these are just comments Reviewers: palys-swm, ashoat Reviewed By: palys-swm, ashoat Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3727
129,190
22.04.2022 10:06:27
-7,200
fb4294397173621f36f0160bfe536bbe5be90224
[services] Backup/Blob - Hide nextWrite, expose start Summary: Depends on D3727 Test Plan: The same as D3535 - services should work the same Reviewers: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/BackupServiceImpl.cpp", "new_path": "services/backup/docker-server/contents/server/src/BackupServiceImpl.cpp", "diff": "@@ -43,7 +43,7 @@ BackupServiceImpl::PullBackup(\ngrpc::CallbackServerContext *context,\nconst backup::PullBackupRequest *request) {\nreactor::PullBackupReactor *reactor = new reactor::PullBackupReactor(request);\n- reactor->NextWrite();\n+ reactor->start();\nreturn reactor;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/client/base-reactors/ClientBidiReactorBase.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/client/base-reactors/ClientBidiReactorBase.h", "diff": "@@ -12,6 +12,8 @@ class ClientBidiReactorBase\nbool done = false;\nbool initialized = 0;\n+ void nextWrite();\n+\nprotected:\nRequest request;\ngrpc::Status status = grpc::Status::OK;\n@@ -19,7 +21,7 @@ protected:\npublic:\ngrpc::ClientContext context;\n- void nextWrite();\n+ void start();\nvoid terminate(const grpc::Status &status);\nbool isTerminated();\nbool isDone();\n@@ -56,6 +58,11 @@ void ClientBidiReactorBase<Request, Response>::nextWrite() {\n}\n}\n+template <class Request, class Response>\n+void ClientBidiReactorBase<Request, Response>::start() {\n+ this->nextWrite();\n+}\n+\ntemplate <class Request, class Response>\nvoid ClientBidiReactorBase<Request, Response>::terminate(\nconst grpc::Status &status) {\n" }, { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/client/base-reactors/ClientWriteReactorBase.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/client/base-reactors/ClientWriteReactorBase.h", "diff": "@@ -12,11 +12,12 @@ class ClientWriteReactorBase : public grpc::ClientWriteReactor<Request> {\nbool initialized = 0;\nRequest request;\n+ void nextWrite();\n+\npublic:\nResponse response;\ngrpc::ClientContext context;\n- void nextWrite();\nvoid OnWriteDone(bool ok) override;\nvoid terminate(const grpc::Status &status);\nbool isDone();\n@@ -48,6 +49,11 @@ void ClientWriteReactorBase<Request, Response>::nextWrite() {\n}\n}\n+template <class Request, class Response>\n+void ClientWriteReactorBase<Request, Response>::start() {\n+ this->nextWrite();\n+}\n+\ntemplate <class Request, class Response>\nvoid ClientWriteReactorBase<Request, Response>::OnWriteDone(bool ok) {\nif (!ok) {\n" }, { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "new_path": "services/backup/docker-server/contents/server/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "diff": "@@ -18,6 +18,7 @@ class ServerWriteReactorBase : public grpc::ServerWriteReactor<Response> {\nstd::atomic<bool> finished = false;\nvoid terminate(grpc::Status status);\n+ void nextWrite();\nprotected:\n// this is a const ref since it's not meant to be modified\n@@ -27,7 +28,7 @@ protected:\npublic:\nServerWriteReactorBase(const Request *request);\n- virtual void NextWrite();\n+ void start();\nvoid OnDone() override;\nvoid OnWriteDone(bool ok) override;\n@@ -61,15 +62,15 @@ template <class Request, class Response>\nServerWriteReactorBase<Request, Response>::ServerWriteReactorBase(\nconst Request *request)\n: request(*request) {\n- // we cannot call this->NextWrite() here because it's going to call it on\n+ // we cannot call this->start() here because it's going to call it on\n// the base class, not derived leading to the runtime error of calling\n// a pure virtual function\n- // NextWrite has to be exposed as a public function and called explicitly\n+ // start has to be exposed as a public function and called explicitly\n// to initialize writing\n}\ntemplate <class Request, class Response>\n-void ServerWriteReactorBase<Request, Response>::NextWrite() {\n+void ServerWriteReactorBase<Request, Response>::nextWrite() {\ntry {\nif (!this->initialized) {\nthis->initialize();\n@@ -88,6 +89,11 @@ void ServerWriteReactorBase<Request, Response>::NextWrite() {\n}\n}\n+template <class Request, class Response>\n+void ServerWriteReactorBase<Request, Response>::start() {\n+ this->nextWrite();\n+}\n+\ntemplate <class Request, class Response>\nvoid ServerWriteReactorBase<Request, Response>::OnDone() {\nthis->doneCallback();\n@@ -102,7 +108,7 @@ void ServerWriteReactorBase<Request, Response>::OnWriteDone(bool ok) {\nthis->terminate(grpc::Status(grpc::StatusCode::INTERNAL, \"writing error\"));\nreturn;\n}\n- this->NextWrite();\n+ this->nextWrite();\n}\n} // namespace reactor\n" }, { "change_type": "MODIFY", "old_path": "services/backup/docker-server/contents/server/src/grpc-client/ServiceBlobClient.h", "new_path": "services/backup/docker-server/contents/server/src/grpc-client/ServiceBlobClient.h", "diff": "@@ -33,7 +33,7 @@ public:\n\"put reactor is being used but has not been initialized\");\n}\nthis->stub->async()->Put(&putReactor->context, &(*putReactor));\n- putReactor->nextWrite();\n+ putReactor->start();\n}\nvoid get(std::shared_ptr<reactor::BlobGetClientReactor> getReactor) {\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/BlobServiceImpl.cpp", "new_path": "services/blob/src/BlobServiceImpl.cpp", "diff": "@@ -59,7 +59,7 @@ grpc::ServerWriteReactor<blob::GetResponse> *BlobServiceImpl::Get(\nconst blob::GetRequest *request) {\nreactor::GetReactor *gr = new reactor::GetReactor(request);\n- gr->NextWrite();\n+ gr->start();\nreturn gr;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "diff": "@@ -18,6 +18,7 @@ class ServerWriteReactorBase : public grpc::ServerWriteReactor<Response> {\nstd::atomic<bool> finished = false;\nvoid terminate(grpc::Status status);\n+ void nextWrite();\nprotected:\n// this is a const ref since it's not meant to be modified\n@@ -27,7 +28,7 @@ protected:\npublic:\nServerWriteReactorBase(const Request *request);\n- virtual void NextWrite();\n+ void start();\nvoid OnDone() override;\nvoid OnWriteDone(bool ok) override;\n@@ -61,15 +62,15 @@ template <class Request, class Response>\nServerWriteReactorBase<Request, Response>::ServerWriteReactorBase(\nconst Request *request)\n: request(*request) {\n- // we cannot call this->NextWrite() here because it's going to call it on\n+ // we cannot call this->start() here because it's going to call it on\n// the base class, not derived leading to the runtime error of calling\n// a pure virtual function\n- // NextWrite has to be exposed as a public function and called explicitly\n+ // start has to be exposed as a public function and called explicitly\n// to initialize writing\n}\ntemplate <class Request, class Response>\n-void ServerWriteReactorBase<Request, Response>::NextWrite() {\n+void ServerWriteReactorBase<Request, Response>::nextWrite() {\ntry {\nif (!this->initialized) {\nthis->initialize();\n@@ -88,6 +89,11 @@ void ServerWriteReactorBase<Request, Response>::NextWrite() {\n}\n}\n+template <class Request, class Response>\n+void ServerWriteReactorBase<Request, Response>::start() {\n+ this->nextWrite();\n+}\n+\ntemplate <class Request, class Response>\nvoid ServerWriteReactorBase<Request, Response>::OnDone() {\nthis->doneCallback();\n@@ -102,7 +108,7 @@ void ServerWriteReactorBase<Request, Response>::OnWriteDone(bool ok) {\nthis->terminate(grpc::Status(grpc::StatusCode::INTERNAL, \"writing error\"));\nreturn;\n}\n- this->NextWrite();\n+ this->nextWrite();\n}\n} // namespace reactor\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Backup/Blob - Hide nextWrite, expose start Summary: Depends on D3727 https://linear.app/comm/issue/ENG-1002/replace-nextwrite-with-start-in-reactors Test Plan: The same as D3535 - services should work the same Reviewers: palys-swm Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3728
129,200
22.04.2022 17:06:02
14,400
e6e82dcdb360749557cb3e0917c3b8ca308d2617
[Identity] Reorder Dockerfile contents Summary: Addressing a comment from in a previous diff. We should install rustfmt immediately after setting the user. Test Plan: Build the docker image Reviewers: jimpo, atul Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh, jimpo
[ { "change_type": "MODIFY", "old_path": "services/identity/Dockerfile", "new_path": "services/identity/Dockerfile", "diff": "@@ -4,6 +4,9 @@ FROM rust:1.57\nRUN useradd -m comm\nUSER comm\n+# The build.rs script depends on rustfmt\n+RUN rustup component add rustfmt\n+\nRUN mkdir -p /home/comm/app/identity\nWORKDIR /home/comm/app/identity\nRUN cargo init --bin\n@@ -20,9 +23,6 @@ COPY services/identity .\n# rebuilt\nRUN rm ./target/release/deps/identity*\n-# The build.rs script depends on rustfmt\n-RUN rustup component add rustfmt\n-\nRUN cargo build --release\nCMD [\"./target/release/identity\"]\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[Identity] Reorder Dockerfile contents Summary: Addressing a comment from @jimpo in a previous diff. We should install rustfmt immediately after setting the user. Test Plan: Build the docker image Reviewers: jimpo, atul Reviewed By: atul Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh, jimpo Differential Revision: https://phabricator.ashoat.com/D3818
129,179
25.04.2022 08:23:07
14,400
bdc048e8d4f5b2968cc027c57d892ca81f9d8396
[web,native] [chore] add covariant declarations to props that were missing Summary: Test Plan: run flow on `native` and `web` adding as a reviewer because this was initially a comment of D3811 Reviewers: atul, palys-swm, ashoat, def-au1t, yayabosh Subscribers: Adrian, karol-bisztyga, ashoat
[ { "change_type": "MODIFY", "old_path": "native/calendar/loading-indicator.react.js", "new_path": "native/calendar/loading-indicator.react.js", "diff": "@@ -7,9 +7,9 @@ import Icon from 'react-native-vector-icons/Feather';\nimport type { LoadingStatus } from 'lib/types/loading-types';\ntype Props = {\n- loadingStatus: LoadingStatus,\n- color: string,\n- canUseRed: boolean,\n+ +loadingStatus: LoadingStatus,\n+ +color: string,\n+ +canUseRed: boolean,\n};\nfunction LoadingIndicator(props: Props): React.Node {\nif (props.loadingStatus === 'error') {\n" }, { "change_type": "MODIFY", "old_path": "native/calendar/thread-picker-modal.react.js", "new_path": "native/calendar/thread-picker-modal.react.js", "diff": "@@ -26,8 +26,8 @@ export type ThreadPickerModalParams = {\n};\ntype Props = {\n- navigation: RootNavigationProp<'ThreadPickerModal'>,\n- route: NavigationRoute<'ThreadPickerModal'>,\n+ +navigation: RootNavigationProp<'ThreadPickerModal'>,\n+ +route: NavigationRoute<'ThreadPickerModal'>,\n};\nfunction ThreadPickerModal(props: Props): React.Node {\nconst {\n" }, { "change_type": "MODIFY", "old_path": "native/chat/new-messages-pill.react.js", "new_path": "native/chat/new-messages-pill.react.js", "diff": "@@ -8,10 +8,10 @@ import { useStyles } from '../themes/colors';\nimport type { ViewStyle } from '../types/styles';\ntype Props = {\n- onPress: () => mixed,\n- newMessageCount: number,\n- containerStyle?: ViewStyle,\n- style?: ViewStyle,\n+ +onPress: () => mixed,\n+ +newMessageCount: number,\n+ +containerStyle?: ViewStyle,\n+ +style?: ViewStyle,\n...React.ElementConfig<typeof View>,\n};\nfunction NewMessagesPill(props: Props): React.Node {\n" }, { "change_type": "MODIFY", "old_path": "native/components/clearable-text-input.react.ios.js", "new_path": "native/components/clearable-text-input.react.ios.js", "diff": "@@ -9,7 +9,7 @@ import type { ClearableTextInputProps } from './clearable-text-input';\nimport TextInput from './text-input.react';\ntype State = {\n- textInputKey: number,\n+ +textInputKey: number,\n};\nclass ClearableTextInput extends React.PureComponent<\nClearableTextInputProps,\n" }, { "change_type": "MODIFY", "old_path": "native/components/content-loading.react.js", "new_path": "native/components/content-loading.react.js", "diff": "@@ -6,8 +6,8 @@ import { View, ActivityIndicator, StyleSheet } from 'react-native';\nimport type { Colors } from '../themes/colors';\ntype Props = {\n- fillType: 'flex' | 'absolute',\n- colors: Colors,\n+ +fillType: 'flex' | 'absolute',\n+ +colors: Colors,\n};\nfunction ContentLoading(props: Props): React.Node {\nconst viewStyle =\n" }, { "change_type": "MODIFY", "old_path": "native/components/single-line.react.js", "new_path": "native/components/single-line.react.js", "diff": "@@ -7,7 +7,7 @@ import { firstLine } from 'lib/utils/string-utils';\ntype Props = {\n...React.ElementConfig<typeof Text>,\n- children: ?string,\n+ +children: ?string,\n};\nfunction SingleLine(props: Props): React.Node {\nconst text = firstLine(props.children);\n" }, { "change_type": "MODIFY", "old_path": "native/error-boundary.react.js", "new_path": "native/error-boundary.react.js", "diff": "@@ -16,10 +16,10 @@ global.ErrorUtils.setGlobalHandler(error => {\n});\ntype Props = {\n- children: React.Node,\n+ +children: React.Node,\n};\ntype State = {\n- errorData: $ReadOnlyArray<ErrorData>,\n+ +errorData: $ReadOnlyArray<ErrorData>,\n};\nclass ErrorBoundary extends React.PureComponent<Props, State> {\nstate: State = {\n" }, { "change_type": "MODIFY", "old_path": "native/media/send-media-button.react.js", "new_path": "native/media/send-media-button.react.js", "diff": "@@ -15,10 +15,10 @@ import type { ViewStyle } from '../types/styles';\ntype Props = {\n...React.ElementConfig<typeof View>,\n- onPress: () => mixed,\n- queueCount?: number,\n- containerStyle?: ViewStyle,\n- style?: ViewStyle,\n+ +onPress: () => mixed,\n+ +queueCount?: number,\n+ +containerStyle?: ViewStyle,\n+ +style?: ViewStyle,\n};\nfunction SendMediaButton(props: Props): React.Node {\nconst {\n" }, { "change_type": "MODIFY", "old_path": "native/navigation/action-result-modal.react.js", "new_path": "native/navigation/action-result-modal.react.js", "diff": "@@ -17,8 +17,8 @@ export type ActionResultModalParams = {\n};\ntype Props = {\n- navigation: AppNavigationProp<'ActionResultModal'>,\n- route: NavigationRoute<'ActionResultModal'>,\n+ +navigation: AppNavigationProp<'ActionResultModal'>,\n+ +route: NavigationRoute<'ActionResultModal'>,\n};\nfunction ActionResultModal(props: Props): React.Node {\nconst overlayContext = React.useContext(OverlayContext);\n" }, { "change_type": "MODIFY", "old_path": "native/navigation/header.react.js", "new_path": "native/navigation/header.react.js", "diff": "@@ -7,7 +7,7 @@ import DisconnectedBar from './disconnected-bar.react';\ntype Props = {\n...StackHeaderProps,\n- activeTab: boolean,\n+ +activeTab: boolean,\n};\nexport default function CustomHeader(props: Props): React.Node {\nconst { activeTab, ...rest } = props;\n" }, { "change_type": "MODIFY", "old_path": "native/navigation/modal-pruner.react.js", "new_path": "native/navigation/modal-pruner.react.js", "diff": "@@ -92,7 +92,7 @@ function collectDependencyInfo(\n}\ntype Props = {\n- navContext: NavContextType,\n+ +navContext: NavContextType,\n};\nfunction ModalPruner(props: Props): null {\nconst { state, dispatch } = props.navContext;\n" }, { "change_type": "MODIFY", "old_path": "native/profile/custom-server-modal.react.js", "new_path": "native/profile/custom-server-modal.react.js", "diff": "@@ -32,7 +32,7 @@ type Props = {\n+dispatch: Dispatch,\n};\ntype State = {\n- customServer: string,\n+ +customServer: string,\n};\nclass CustomServerModal extends React.PureComponent<Props, State> {\nconstructor(props: Props) {\n" }, { "change_type": "MODIFY", "old_path": "native/push/in-app-notif.react.js", "new_path": "native/push/in-app-notif.react.js", "diff": "@@ -10,9 +10,9 @@ import type { GlobalTheme } from '../types/themes';\nconst edges = ['top'];\ntype Props = {\n- title: ?string,\n- message: string,\n- activeTheme: ?GlobalTheme,\n+ +title: ?string,\n+ +message: string,\n+ +activeTheme: ?GlobalTheme,\n};\nfunction InAppNotif(props: Props): React.Node {\nconst useLightStyle = Platform.OS === 'ios' && props.activeTheme !== 'dark';\n" }, { "change_type": "MODIFY", "old_path": "web/calendar/calendar.react.js", "new_path": "web/calendar/calendar.react.js", "diff": "@@ -61,7 +61,7 @@ type Props = {\n) => Promise<CalendarQueryUpdateResult>,\n};\ntype State = {\n- filterPanelOpen: boolean,\n+ +filterPanelOpen: boolean,\n};\nclass Calendar extends React.PureComponent<Props, State> {\nstate: State = {\n" }, { "change_type": "MODIFY", "old_path": "web/chat/chat-message-list.react.js", "new_path": "web/chat/chat-message-list.react.js", "diff": "@@ -69,8 +69,8 @@ type PassedProps = {\n+inputState: ?InputState,\n};\ntype ReactDnDProps = {\n- isActive: boolean,\n- connectDropTarget: (node: React.Node) => React.Node,\n+ +isActive: boolean,\n+ +connectDropTarget: (node: React.Node) => React.Node,\n};\ntype Props = {\n...PassedProps,\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web,native] [chore] [ENG-1032] add covariant declarations to props that were missing Summary: https://linear.app/comm/issue/ENG-1032/add-missing-covariant-declarations-in-web-and-native Test Plan: run flow on `native` and `web` adding @ashoat as a reviewer because this was initially a comment of D3811 Reviewers: atul, palys-swm, ashoat, def-au1t, yayabosh Reviewed By: ashoat Subscribers: Adrian, karol-bisztyga, ashoat Differential Revision: https://phabricator.ashoat.com/D3816
129,179
22.04.2022 17:13:26
14,400
2bfb55f8eab6b1e9d99d1adc5388045028a88dd5
[native] [fix] fix prompt copy Summary: Update copy, confirm with adding ashoat as review because it's copy that he should have final review on. Test Plan: N/A not changing functionality, just the content. Reviewers: ashoat Subscribers: palys-swm, Adrian, atul, karol-bisztyga, yayabosh, ashoat
[ { "change_type": "MODIFY", "old_path": "native/chat/settings/thread-settings-promote-sidebar.react.js", "new_path": "native/chat/settings/thread-settings-promote-sidebar.react.js", "diff": "@@ -26,7 +26,7 @@ class ThreadSettingsPromoteSidebar extends React.PureComponent<Props> {\nonClick = () => {\nAlert.alert(\n'Are you sure?',\n- \"This promoting a sidebar to a full thread can't be undone.\",\n+ 'Promoting a sidebar to a full thread cannot be undone.',\n[\n{\ntext: 'Cancel',\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[native] [fix] [ENG-1016] fix prompt copy Summary: Update copy, confirm with @ashoat, adding ashoat as review because it's copy that he should have final review on. Test Plan: N/A not changing functionality, just the content. Reviewers: ashoat Reviewed By: ashoat Subscribers: palys-swm, Adrian, atul, karol-bisztyga, yayabosh, ashoat Differential Revision: https://phabricator.ashoat.com/D3819
129,179
19.04.2022 16:00:43
14,400
691803efd7c9f7aa0e9dbc7702efa03472e39d7f
[web] [fix] Additional Changes for that were missed before landing. Summary: follow up from comments that were not landed Test Plan: make sure all diff review has been addressed correctly. Reviewers: atul, palys-swm, def-au1t, yayabosh, ashoat Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/chat/chat-thread-list-item.react.js", "new_path": "web/chat/chat-thread-list-item.react.js", "diff": "@@ -95,7 +95,7 @@ function ChatThreadListItem(props: Props): React.Node {\nreturn (\n<ChatThreadListSidebar\nsidebarInfo={sidebarInfo}\n- isMultipleSidebarItem={index > 0}\n+ isSubsequentItem={index > 0}\nkey={sidebarInfo.threadInfo.id}\n/>\n);\n" }, { "change_type": "MODIFY", "old_path": "web/chat/chat-thread-list-sidebar.react.js", "new_path": "web/chat/chat-thread-list-sidebar.react.js", "diff": "@@ -15,10 +15,10 @@ import SidebarItem from './sidebar-item.react';\ntype Props = {\n+sidebarInfo: SidebarInfo,\n- +isMultipleSidebarItem: boolean,\n+ +isSubsequentItem: boolean,\n};\nfunction ChatThreadListSidebar(props: Props): React.Node {\n- const { sidebarInfo, isMultipleSidebarItem } = props;\n+ const { sidebarInfo, isSubsequentItem } = props;\nconst { threadInfo, mostRecentNonLocalMessage } = sidebarInfo;\nconst {\ncurrentUser: { unread },\n@@ -40,10 +40,7 @@ function ChatThreadListSidebar(props: Props): React.Node {\nonClick={onClick}\n>\n<div className={css.dotContainer}>{unreadDot}</div>\n- <SidebarItem\n- sidebarInfo={sidebarInfo}\n- extendArrow={isMultipleSidebarItem}\n- />\n+ <SidebarItem sidebarInfo={sidebarInfo} extendArrow={isSubsequentItem} />\n<ChatThreadListItemMenu\nthreadInfo={threadInfo}\nmostRecentNonLocalMessage={mostRecentNonLocalMessage}\n" }, { "change_type": "MODIFY", "old_path": "web/chat/sidebar-item.react.js", "new_path": "web/chat/sidebar-item.react.js", "diff": "@@ -26,9 +26,14 @@ function SidebarItem(props: Props): React.Node {\nconst unreadCls = classNames(css.sidebarTitle, { [css.unread]: unread });\n+ let arrowExtender;\n+ if (extendArrow) {\n+ arrowExtender = <div className={css.threadArrowExtender} />;\n+ }\n+\nreturn (\n<>\n- {extendArrow ? <div className={css.threadArrowExtender} /> : null}\n+ {arrowExtender}\n<SWMansionIcon icon=\"right-angle-arrow\" size={28} />\n<div className={css.spacer} />\n<a className={css.threadButtonSidebar} onClick={onClick}>\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] [fix] [ENG-1024] Additional Changes for ENG-766 that were missed before landing. Summary: follow up from https://phabricator.ashoat.com/D3539 comments that were not landed Test Plan: make sure all diff review has been addressed correctly. Reviewers: atul, palys-swm, def-au1t, yayabosh, ashoat Reviewed By: ashoat Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3782
129,179
25.04.2022 11:33:04
14,400
3969047afed71d4174d7da718e0411e1084904ea
[lib,web,native,landing] [chore] update eslint config to correctly handle cjs files Summary: update eslint config to ignore files, rather than add the comments, Test Plan: go to webpack files, red swiggles are now gone. Reviewers: atul, palys-swm, def-au1t, yayabosh, benschac Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": ".eslintrc.json", "new_path": ".eslintrc.json", "diff": "},\n\"import/ignore\": [\"react-native\"],\n\"import/internal-regex\": \"^(lib|native|keyserver|web)/\"\n+ },\n+ \"overrides\": [\n+ {\n+ \"files\": \"*.cjs\",\n+ \"env\": {\n+ \"node\": true,\n+ \"commonjs\": true\n+ },\n+ \"rules\": {\n+ \"flowtype/require-valid-file-annotation\": 0,\n+ \"flowtype/require-exact-type\": 0\n+ }\n}\n+ ]\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib,web,native,landing] [chore] update eslint config to correctly handle cjs files Summary: update eslint config to ignore files, rather than add the comments, https://eslint.org/docs/user-guide/configuring/ignoring-code Test Plan: go to webpack files, red swiggles are now gone. Reviewers: atul, palys-swm, def-au1t, yayabosh, benschac Reviewed By: benschac Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3761
129,187
25.04.2022 11:47:07
14,400
3ad88fafa1ae96a783940c2f516a9b2baf2e3ea6
[lib] Fix ESLint errors on lib/webpack/shared.cjs Summary: In the parent diff we make ESLint work with `.cjs` files. This diff corrects the resultant errors. Test Plan: `eslint lib/webpack/shared.cjs` Reviewers: benschac Subscribers: palys-swm, Adrian, atul, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "lib/webpack/shared.cjs", "new_path": "lib/webpack/shared.cjs", "diff": "-const webpack = require('webpack');\n-const path = require('path');\n+const { CleanWebpackPlugin } = require('clean-webpack-plugin');\nconst MiniCssExtractPlugin = require('mini-css-extract-plugin');\n-const TerserPlugin = require('terser-webpack-plugin');\nconst OptimizeCssAssetsPlugin = require('optimize-css-assets-webpack-plugin');\n-const { CleanWebpackPlugin } = require('clean-webpack-plugin');\n+const TerserPlugin = require('terser-webpack-plugin');\n+const webpack = require('webpack');\nconst sharedPlugins = [\nnew webpack.optimize.LimitChunkCountPlugin({\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib] Fix ESLint errors on lib/webpack/shared.cjs Summary: In the parent diff we make ESLint work with `.cjs` files. This diff corrects the resultant errors. Test Plan: `eslint lib/webpack/shared.cjs` Reviewers: benschac Reviewed By: benschac Subscribers: palys-swm, Adrian, atul, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3834
129,187
25.04.2022 11:48:43
14,400
ee2a23439c28e8b212ed32799324de92acc7f809
Enable lint-staged for cjs files Summary: Depends on D3834 Test Plan: Ehh I haven't actually tested this. Seems fine though... Reviewers: benschac Subscribers: palys-swm, Adrian, atul, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": ".lintstagedrc.js", "new_path": ".lintstagedrc.js", "diff": "@@ -4,7 +4,7 @@ const { getClangPaths } = require('./scripts/get_clang_paths');\nconst cli = new CLIEngine({});\nmodule.exports = {\n- '*.{js,mjs}': function eslint(files) {\n+ '*.{js,mjs,cjs}': function eslint(files) {\n// This logic is likely broken and needs to be updated. see ENG-1011\nreturn (\n'eslint --cache --fix --max-warnings=0 ' +\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
Enable lint-staged for cjs files Summary: Depends on D3834 Test Plan: Ehh I haven't actually tested this. Seems fine though... Reviewers: benschac Reviewed By: benschac Subscribers: palys-swm, Adrian, atul, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3835
129,179
26.04.2022 10:57:04
14,400
1f0272f1e14fbb0fecb16cda4f0df573452cdfb6
[web] [fix] change modal x default to show on default Summary: re-add the close button {F43992} {F43993} Test Plan: all modals should have the x button by default. attaching screen shots. Reviewers: atul, palys-swm, def-au1t Subscribers: ashoat, Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/modals/modal.react.js", "new_path": "web/modals/modal.react.js", "diff": "@@ -37,7 +37,7 @@ class Modal extends React.PureComponent<Props> {\nfixedHeight,\nname,\nicon,\n- withCloseButton = false,\n+ withCloseButton = true,\n} = this.props;\nconst overlayClasses = classNames(\n" }, { "change_type": "MODIFY", "old_path": "web/modals/threads/confirm-leave-thread-modal.react.js", "new_path": "web/modals/threads/confirm-leave-thread-modal.react.js", "diff": "@@ -18,7 +18,12 @@ function ConfirmLeaveThreadModal(props: Props): React.Node {\nconst { uiName } = threadInfo;\nreturn (\n- <Modal name=\"Leaving channel\" icon=\"warning-circle\" onClose={onClose}>\n+ <Modal\n+ name=\"Leaving channel\"\n+ icon=\"warning-circle\"\n+ withCloseButton={false}\n+ onClose={onClose}\n+ >\n<div className={css.container}>\n<p>\n{'Are you sure you want to leave \"'}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] [fix] [ENG-1033] change modal x default to show on default Summary: re-add the close button {F43992} {F43993} https://linear.app/comm/issue/ENG-1033/close-button-removed-from-modal Test Plan: all modals should have the x button by default. attaching screen shots. Reviewers: atul, palys-swm, def-au1t Reviewed By: atul Subscribers: ashoat, Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3820
129,185
26.04.2022 17:28:05
-7,200
3274d77df84a01bae672d710cb7ee964a831cabf
[web] Remove `Modal`s usused style Summary: The style has not been used anywhere in the project Test Plan: Nothing changes in project Reviewers: palys-swm, atul, benschac Subscribers: ashoat, palys-swm, Adrian, atul, karol-bisztyga, benschac, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/modals/modal.css", "new_path": "web/modals/modal.css", "diff": "@@ -67,18 +67,6 @@ div.modal-header > h2 svg {\ndisplay: flex;\n}\n-div.intro-modal {\n- padding: 10px 21px 12px 21px;\n- border-radius: 5px;\n- border: 1px solid #c8c8c8;\n- background-color: #f8f8f8;\n- width: 310px;\n- position: fixed;\n- font-family: var(--font-stack);\n- margin-top: 100px;\n- box-shadow: 2px 3px 6px 0px rgba(0, 0, 0, 0.1);\n-}\n-\n@media only screen and (-webkit-min-device-pixel-ratio: 2),\nonly screen and (min--moz-device-pixel-ratio: 2),\nonly screen and (-o-min-device-pixel-ratio: 2/1),\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Remove `Modal`s usused style Summary: The style has not been used anywhere in the project Test Plan: Nothing changes in project Reviewers: palys-swm, atul, benschac Reviewed By: atul Subscribers: ashoat, palys-swm, Adrian, atul, karol-bisztyga, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3668
129,185
26.04.2022 17:28:26
-7,200
d8e2452fd22d37e9f544e0a0f346a701299b9e01
[web] Adjust `SubchannelsModal` size to match designs Summary: Changed `SubchannelsModal` content size to match design in Figma. {F36324} Test Plan: Open `SubchannelsModal` from thread actions menu Reviewers: palys-swm, atul, benschac Subscribers: ashoat, palys-swm, Adrian, atul, karol-bisztyga, benschac, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/modals/threads/subchannels/subchannels-modal.css", "new_path": "web/modals/threads/subchannels/subchannels-modal.css", "diff": "@@ -5,6 +5,8 @@ div.subchannelsListContainer {\nline-height: var(--line-height-text);\ncolor: var(--subchannels-modal-color);\nrow-gap: 8px;\n+ width: 383px;\n+ height: 458px;\n}\ndiv.noSubchannels {\n" }, { "change_type": "MODIFY", "old_path": "web/modals/threads/subchannels/subchannels-modal.react.js", "new_path": "web/modals/threads/subchannels/subchannels-modal.react.js", "diff": "@@ -147,6 +147,7 @@ function SubchannelsModal(props: Props): React.Node {\nname=\"Subchannels\"\nsearchPlaceholder=\"Search\"\nonClose={onClose}\n+ size=\"fit-content\"\n>\n{subchannelsContent}\n</SearchModal>\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Adjust `SubchannelsModal` size to match designs Summary: Changed `SubchannelsModal` content size to match design in Figma. {F36324} Test Plan: Open `SubchannelsModal` from thread actions menu Reviewers: palys-swm, atul, benschac Reviewed By: atul Subscribers: ashoat, palys-swm, Adrian, atul, karol-bisztyga, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3672
129,184
27.04.2022 09:19:43
18,000
9c862dfb76d77aae4441852894354590db67d3ea
[keyserver] Bump `firebase-admin` to `10.1.0` Summary: Downstream dependencies have issues surfaced by `yarn audit` Checked the `10.0.2` and `10.1.0` release notes and found no evidence of breaking changes: Test Plan: CI Reviewers: def-au1t, palys-swm, ashoat Subscribers: Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "keyserver/package.json", "new_path": "keyserver/package.json", "diff": "\"dateformat\": \"^3.0.3\",\n\"express\": \"^4.17.1\",\n\"express-ws\": \"^4.0.0\",\n- \"firebase-admin\": \"^10.0.1\",\n+ \"firebase-admin\": \"^10.1.0\",\n\"geoip-lite\": \"^1.4.0\",\n\"invariant\": \"^2.2.4\",\n\"landing\": \"0.0.1\",\n" }, { "change_type": "MODIFY", "old_path": "yarn.lock", "new_path": "yarn.lock", "diff": "lodash.pick \"^4.4.0\"\nlodash.template \"^4.5.0\"\n-\"@firebase/app-types@0.6.3\":\n- version \"0.6.3\"\n- resolved \"https://registry.yarnpkg.com/@firebase/app-types/-/app-types-0.6.3.tgz#3f10514786aad846d74cd63cb693556309918f4b\"\n- integrity sha512-/M13DPPati7FQHEQ9Minjk1HGLm/4K4gs9bR4rzLCWJg64yGtVC0zNg9gDpkw9yc2cvol/mNFxqTtd4geGrwdw==\n-\n\"@firebase/app-types@0.7.0\":\nversion \"0.7.0\"\nresolved \"https://registry.yarnpkg.com/@firebase/app-types/-/app-types-0.7.0.tgz#c9e16d1b8bed1a991840b8d2a725fb58d0b5899f\"\nresolved \"https://registry.yarnpkg.com/@firebase/auth-interop-types/-/auth-interop-types-0.1.6.tgz#5ce13fc1c527ad36f1bb1322c4492680a6cf4964\"\nintegrity sha512-etIi92fW3CctsmR9e3sYM3Uqnoq861M0Id9mdOPF6PWIg38BXL5k4upCNBggGUpLIS0H1grMOvy/wn1xymwe2g==\n-\"@firebase/component@0.5.9\":\n- version \"0.5.9\"\n- resolved \"https://registry.yarnpkg.com/@firebase/component/-/component-0.5.9.tgz#a859f655bd6e5b691bc5596fe43a91b12a443052\"\n- integrity sha512-oLCY3x9WbM5rn06qmUvbtJuPj4dIw/C9T4Th52IiHF5tiCRC5k6YthvhfUVcTwfoUhK0fOgtwuKJKA/LpCPjgA==\n+\"@firebase/component@0.5.13\":\n+ version \"0.5.13\"\n+ resolved \"https://registry.yarnpkg.com/@firebase/component/-/component-0.5.13.tgz#65a382e83bddd109380c9aa1f280791b1b4567c4\"\n+ integrity sha512-hxhJtpD8Ppf/VU2Rlos6KFCEV77TGIGD5bJlkPK1+B/WUe0mC6dTjW7KhZtXTc+qRBp9nFHWcsIORnT8liHP9w==\ndependencies:\n- \"@firebase/util\" \"1.4.2\"\n+ \"@firebase/util\" \"1.5.2\"\ntslib \"^2.1.0\"\n\"@firebase/database-compat@^0.1.1\":\n- version \"0.1.4\"\n- resolved \"https://registry.yarnpkg.com/@firebase/database-compat/-/database-compat-0.1.4.tgz#9bad05a4a14e557271b887b9ab97f8b39f91f5aa\"\n- integrity sha512-dIJiZLDFF3U+MoEwoPBy7zxWmBUro1KefmwSHlpOoxmPv76tuoPm85NumpW/HmMrtTcTkC2qowtb6NjGE8X7mw==\n+ version \"0.1.8\"\n+ resolved \"https://registry.yarnpkg.com/@firebase/database-compat/-/database-compat-0.1.8.tgz#ab627f2bdbe94367f515d5bded880c86886bbd28\"\n+ integrity sha512-dhXr5CSieBuKNdU96HgeewMQCT9EgOIkfF1GNy+iRrdl7BWLxmlKuvLfK319rmIytSs/vnCzcD9uqyxTeU/A3A==\ndependencies:\n- \"@firebase/component\" \"0.5.9\"\n- \"@firebase/database\" \"0.12.4\"\n- \"@firebase/database-types\" \"0.9.3\"\n+ \"@firebase/component\" \"0.5.13\"\n+ \"@firebase/database\" \"0.12.8\"\n+ \"@firebase/database-types\" \"0.9.7\"\n\"@firebase/logger\" \"0.3.2\"\n- \"@firebase/util\" \"1.4.2\"\n+ \"@firebase/util\" \"1.5.2\"\ntslib \"^2.1.0\"\n-\"@firebase/database-types@0.9.3\":\n- version \"0.9.3\"\n- resolved \"https://registry.yarnpkg.com/@firebase/database-types/-/database-types-0.9.3.tgz#d1a8ee34601136fd0047817d94432d89fdba5fef\"\n- integrity sha512-R+YXLWy/Q7mNUxiUYiMboTwvVoprrgfyvf1Viyevskw6IoH1q8HV1UjlkLSgmRsOT9HPWt7XZUEStVZJFknHwg==\n+\"@firebase/database-types@0.9.7\", \"@firebase/database-types@^0.9.3\":\n+ version \"0.9.7\"\n+ resolved \"https://registry.yarnpkg.com/@firebase/database-types/-/database-types-0.9.7.tgz#c5ee0ea9bb2703a13c1c47fe880fc577d5ce7f33\"\n+ integrity sha512-EFhgL89Fz6DY3kkB8TzdHvdu8XaqqvzcF2DLVOXEnQ3Ms7L755p5EO42LfxXoJqb9jKFvgLpFmKicyJG25WFWw==\ndependencies:\n\"@firebase/app-types\" \"0.7.0\"\n- \"@firebase/util\" \"1.4.2\"\n-\n-\"@firebase/database-types@^0.7.2\":\n- version \"0.7.3\"\n- resolved \"https://registry.yarnpkg.com/@firebase/database-types/-/database-types-0.7.3.tgz#819f16dd4c767c864b460004458620f265a3f735\"\n- integrity sha512-dSOJmhKQ0nL8O4EQMRNGpSExWCXeHtH57gGg0BfNAdWcKhC8/4Y+qfKLfWXzyHvrSecpLmO0SmAi/iK2D5fp5A==\n- dependencies:\n- \"@firebase/app-types\" \"0.6.3\"\n+ \"@firebase/util\" \"1.5.2\"\n-\"@firebase/database@0.12.4\":\n- version \"0.12.4\"\n- resolved \"https://registry.yarnpkg.com/@firebase/database/-/database-0.12.4.tgz#7ad26393f59ede2b93444406651f976a7008114d\"\n- integrity sha512-XkrL1kXELRNkqKcltuT4hfG1gWmFiGvjFY+z7Lhb//12MqdkLjwa9YMK8c6Lo+Ro+IkWcJArQaOQYe3GkU5Wgg==\n+\"@firebase/database@0.12.8\":\n+ version \"0.12.8\"\n+ resolved \"https://registry.yarnpkg.com/@firebase/database/-/database-0.12.8.tgz#11a1b6752ba0614892af15c71958e00ce16f5824\"\n+ integrity sha512-JBQVfFLzfhxlQbl4OU6ov9fdsddkytBQdtSSR49cz48homj38ccltAhK6seum+BI7f28cV2LFHF9672lcN+qxA==\ndependencies:\n\"@firebase/auth-interop-types\" \"0.1.6\"\n- \"@firebase/component\" \"0.5.9\"\n+ \"@firebase/component\" \"0.5.13\"\n\"@firebase/logger\" \"0.3.2\"\n- \"@firebase/util\" \"1.4.2\"\n+ \"@firebase/util\" \"1.5.2\"\nfaye-websocket \"0.11.4\"\ntslib \"^2.1.0\"\ndependencies:\ntslib \"^2.1.0\"\n-\"@firebase/util@1.4.2\":\n- version \"1.4.2\"\n- resolved \"https://registry.yarnpkg.com/@firebase/util/-/util-1.4.2.tgz#271c63bb7cce4607f7679dc5624ef241c4cf2498\"\n- integrity sha512-JMiUo+9QE9lMBvEtBjqsOFdmJgObFvi7OL1A0uFGwTmlCI1ZeNPOEBrwXkgTOelVCdiMO15mAebtEyxFuQ6FsA==\n+\"@firebase/util@1.5.2\":\n+ version \"1.5.2\"\n+ resolved \"https://registry.yarnpkg.com/@firebase/util/-/util-1.5.2.tgz#bdd2bc11c956a8a6a0fa25fbd752a13e033558bc\"\n+ integrity sha512-YvBH2UxFcdWG2HdFnhxZptPl2eVFlpOyTH66iDo13JPEYraWzWToZ5AMTtkyRHVmu7sssUpQlU9igy1KET7TOw==\ndependencies:\ntslib \"^2.1.0\"\ndependencies:\nprop-types \"^15.5.10\"\n-\"@google-cloud/common@^3.3.0\":\n- version \"3.4.0\"\n- resolved \"https://registry.yarnpkg.com/@google-cloud/common/-/common-3.4.0.tgz#8951d0dc94c9dfd8af2b49ed125984dc71f1de6b\"\n- integrity sha512-bVMQlK4aZEeopo2oJwDUJiBhPVjRRQHfFCCv9JowmKS3L//PBHNDJzC/LxJixGZEU3fh3YXkUwm67JZ5TBCCNQ==\n- dependencies:\n- \"@google-cloud/projectify\" \"^2.0.0\"\n- \"@google-cloud/promisify\" \"^2.0.0\"\n- arrify \"^2.0.1\"\n- duplexify \"^4.1.1\"\n- ent \"^2.2.0\"\n- extend \"^3.0.2\"\n- google-auth-library \"^6.0.0\"\n- retry-request \"^4.1.1\"\n- teeny-request \"^7.0.0\"\n-\n-\"@google-cloud/firestore@^4.5.0\":\n+\"@google-cloud/firestore@^4.15.1\":\nversion \"4.15.1\"\nresolved \"https://registry.yarnpkg.com/@google-cloud/firestore/-/firestore-4.15.1.tgz#ed764fc76823ce120e68fe8c27ef1edd0650cd93\"\nintegrity sha512-2PWsCkEF1W02QbghSeRsNdYKN1qavrHBP3m72gPDMHQSYrGULOaTi7fSJquQmAtc4iPVB2/x6h80rdLHTATQtA==\ngoogle-gax \"^2.24.1\"\nprotobufjs \"^6.8.6\"\n-\"@google-cloud/paginator@^3.0.0\":\n- version \"3.0.5\"\n- resolved \"https://registry.yarnpkg.com/@google-cloud/paginator/-/paginator-3.0.5.tgz#9d6b96c421a89bd560c1bc2c197c7611ef21db6c\"\n- integrity sha512-N4Uk4BT1YuskfRhKXBs0n9Lg2YTROZc6IMpkO/8DIHODtm5s3xY8K5vVBo23v/2XulY3azwITQlYWgT4GdLsUw==\n+\"@google-cloud/paginator@^3.0.7\":\n+ version \"3.0.7\"\n+ resolved \"https://registry.yarnpkg.com/@google-cloud/paginator/-/paginator-3.0.7.tgz#fb6f8e24ec841f99defaebf62c75c2e744dd419b\"\n+ integrity sha512-jJNutk0arIQhmpUUQJPJErsojqo834KcyB6X7a1mxuic8i1tKXxde8E69IZxNZawRIlZdIK2QY4WALvlK5MzYQ==\ndependencies:\narrify \"^2.0.0\"\nextend \"^3.0.2\"\n\"@google-cloud/projectify@^2.0.0\":\n- version \"2.0.1\"\n- resolved \"https://registry.yarnpkg.com/@google-cloud/projectify/-/projectify-2.0.1.tgz#13350ee609346435c795bbfe133a08dfeab78d65\"\n- integrity sha512-ZDG38U/Yy6Zr21LaR3BTiiLtpJl6RkPS/JwoRT453G+6Q1DhlV0waNf8Lfu+YVYGIIxgKnLayJRfYlFJfiI8iQ==\n+ version \"2.1.1\"\n+ resolved \"https://registry.yarnpkg.com/@google-cloud/projectify/-/projectify-2.1.1.tgz#ae6af4fee02d78d044ae434699a630f8df0084ef\"\n+ integrity sha512-+rssMZHnlh0twl122gXY4/aCrk0G1acBqkHFfYddtsqpYXGxA29nj9V5V9SfC+GyOG00l650f6lG9KL+EpFEWQ==\n\"@google-cloud/promisify@^2.0.0\":\n- version \"2.0.3\"\n- resolved \"https://registry.yarnpkg.com/@google-cloud/promisify/-/promisify-2.0.3.tgz#f934b5cdc939e3c7039ff62b9caaf59a9d89e3a8\"\n- integrity sha512-d4VSA86eL/AFTe5xtyZX+ePUjE8dIFu2T8zmdeNBSa5/kNgXPCx/o/wbFNHAGLJdGnk1vddRuMESD9HbOC8irw==\n+ version \"2.0.4\"\n+ resolved \"https://registry.yarnpkg.com/@google-cloud/promisify/-/promisify-2.0.4.tgz#9d8705ecb2baa41b6b2673f3a8e9b7b7e1abc52a\"\n+ integrity sha512-j8yRSSqswWi1QqUGKVEKOG03Q7qOoZP6/h2zN2YO+F5h2+DHU0bSrHCK9Y7lo2DI9fBd8qGAw795sf+3Jva4yA==\n-\"@google-cloud/storage@^5.3.0\":\n- version \"5.3.0\"\n- resolved \"https://registry.yarnpkg.com/@google-cloud/storage/-/storage-5.3.0.tgz#cf86683911cce68829e46de544abb41947d29da2\"\n- integrity sha512-3t5UF3SZ14Bw2kcBHubCai6EIugU2GnQOstYWVSFuoO8IJ94RAaIOPq/dtexvQbUTpBTAGpd5smVR9WPL1mJVw==\n+\"@google-cloud/storage@^5.18.3\":\n+ version \"5.19.3\"\n+ resolved \"https://registry.yarnpkg.com/@google-cloud/storage/-/storage-5.19.3.tgz#0624f57a7ed5a4e3e0e23d5aaab849cb015f903a\"\n+ integrity sha512-l+8X0BoA7rg9jyZaS4p2DwMg1Ivju+VAL6PeQZE1u2q52LQ0KemrZmdQWhtrplHYo8UdYtqpbj4A6Fc5fKDZdg==\ndependencies:\n- \"@google-cloud/common\" \"^3.3.0\"\n- \"@google-cloud/paginator\" \"^3.0.0\"\n+ \"@google-cloud/paginator\" \"^3.0.7\"\n+ \"@google-cloud/projectify\" \"^2.0.0\"\n\"@google-cloud/promisify\" \"^2.0.0\"\n+ abort-controller \"^3.0.0\"\narrify \"^2.0.0\"\n+ async-retry \"^1.3.3\"\ncompressible \"^2.0.12\"\n- concat-stream \"^2.0.0\"\n- date-and-time \"^0.14.0\"\n- duplexify \"^3.5.0\"\n+ configstore \"^5.0.0\"\n+ date-and-time \"^2.0.0\"\n+ duplexify \"^4.0.0\"\n+ ent \"^2.2.0\"\nextend \"^3.0.2\"\n- gaxios \"^3.0.0\"\n- gcs-resumable-upload \"^3.1.0\"\n+ gaxios \"^4.0.0\"\n+ get-stream \"^6.0.0\"\n+ google-auth-library \"^7.14.1\"\nhash-stream-validation \"^0.2.2\"\n- mime \"^2.2.0\"\n+ mime \"^3.0.0\"\nmime-types \"^2.0.8\"\n- onetime \"^5.1.0\"\np-limit \"^3.0.1\"\npumpify \"^2.0.0\"\n+ retry-request \"^4.2.2\"\nsnakeize \"^0.1.0\"\n- stream-events \"^1.0.1\"\n+ stream-events \"^1.0.4\"\n+ teeny-request \"^7.1.3\"\nxdg-basedir \"^4.0.0\"\n\"@graphql-tools/merge@^8.2.1\":\ndependencies:\ntslib \"~2.3.0\"\n-\"@grpc/grpc-js@^1.4.6\", \"@grpc/grpc-js@~1.4.0\":\n+\"@grpc/grpc-js@^1.4.6\":\nversion \"1.4.6\"\nresolved \"https://registry.yarnpkg.com/@grpc/grpc-js/-/grpc-js-1.4.6.tgz#8108d7ab7c0c21b38c538c1a48583edbbf2c2412\"\nintegrity sha512-Byau4xiXfIixb1PnW30V/P9mkrZ05lknyNqiK+cVY9J5hj3gecxd/anwaUbAM8j834zg1x78NvAbwGnMfWEu7A==\n\"@grpc/proto-loader\" \"^0.6.4\"\n\"@types/node\" \">=12.12.47\"\n-\"@grpc/proto-loader@^0.6.1\", \"@grpc/proto-loader@^0.6.4\":\n+\"@grpc/grpc-js@~1.6.0\":\n+ version \"1.6.7\"\n+ resolved \"https://registry.yarnpkg.com/@grpc/grpc-js/-/grpc-js-1.6.7.tgz#4c4fa998ff719fe859ac19fe977fdef097bb99aa\"\n+ integrity sha512-eBM03pu9hd3VqDQG+kHahiG1x80RGkkqqRb1Pchcwqej/KkAH95gAvKs6laqaHCycYaPK+TKuNQnOz9UXYA8qw==\n+ dependencies:\n+ \"@grpc/proto-loader\" \"^0.6.4\"\n+ \"@types/node\" \">=12.12.47\"\n+\n+\"@grpc/proto-loader@^0.6.1\":\n+ version \"0.6.9\"\n+ resolved \"https://registry.yarnpkg.com/@grpc/proto-loader/-/proto-loader-0.6.9.tgz#4014eef366da733f8e04a9ddd7376fe8a58547b7\"\n+ integrity sha512-UlcCS8VbsU9d3XTXGiEVFonN7hXk+oMXZtoHHG2oSA1/GcDP1q6OUgs20PzHDGizzyi8ufGSUDlk3O2NyY7leg==\n+ dependencies:\n+ \"@types/long\" \"^4.0.1\"\n+ lodash.camelcase \"^4.3.0\"\n+ long \"^4.0.0\"\n+ protobufjs \"^6.10.0\"\n+ yargs \"^16.2.0\"\n+\n+\"@grpc/proto-loader@^0.6.4\":\nversion \"0.6.7\"\nresolved \"https://registry.yarnpkg.com/@grpc/proto-loader/-/proto-loader-0.6.7.tgz#e62a202f4cf5897bdd0e244dec1dbc80d84bdfa1\"\nintegrity sha512-QzTPIyJxU0u+r2qGe8VMl3j/W2ryhEvBv7hc42OjYfthSj370fUrb7na65rG6w3YLZS/fb8p89iTBobfWGDgdw==\ndependencies:\ndefer-to-connect \"^2.0.0\"\n-\"@tootallnate/once@1\":\n- version \"1.1.2\"\n- resolved \"https://registry.yarnpkg.com/@tootallnate/once/-/once-1.1.2.tgz#ccb91445360179a04e7fe6aff78c00ffc1eeaf82\"\n- integrity sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw==\n+\"@tootallnate/once@2\":\n+ version \"2.0.0\"\n+ resolved \"https://registry.yarnpkg.com/@tootallnate/once/-/once-2.0.0.tgz#f544a148d3ab35801c1f633a7441fd87c2e484bf\"\n+ integrity sha512-XCuKFP5PS55gnMVu3dty8KPatLqUoy/ZYzDzAGCQ8JNFCkLXzmI7vNHCR+XpbZaMWQK/vQubr7PkYq8g470J/A==\n\"@types/accepts@^1.3.5\":\nversion \"1.3.5\"\n\"@types/range-parser\" \"*\"\n\"@types/express-unless@*\":\n- version \"0.5.2\"\n- resolved \"https://registry.yarnpkg.com/@types/express-unless/-/express-unless-0.5.2.tgz#07e29883d280778588644b03563d8796f870f20e\"\n- integrity sha512-Q74UyYRX/zIgl1HSp9tUX2PlG8glkVm+59r7aK4KGKzC5jqKIOX6rrVLRQrzpZUQ84VukHtRoeAuon2nIssHPQ==\n+ version \"0.5.3\"\n+ resolved \"https://registry.yarnpkg.com/@types/express-unless/-/express-unless-0.5.3.tgz#271f8603617445568ed0d6efe25a7d2f338544c1\"\n+ integrity sha512-TyPLQaF6w8UlWdv4gj8i46B+INBVzURBNRahCozCSXfsK2VTlL1wNyTlMKw817VHygBtlcl5jfnPadlydr06Yw==\ndependencies:\n\"@types/express\" \"*\"\n@@ -4822,7 +4819,7 @@ array.prototype.flatmap@^1.2.4:\nes-abstract \"^1.18.0-next.1\"\nfunction-bind \"^1.1.1\"\n-arrify@^2.0.0, arrify@^2.0.1:\n+arrify@^2.0.0:\nversion \"2.0.1\"\nresolved \"https://registry.yarnpkg.com/arrify/-/arrify-2.0.1.tgz#c9655e9331e0abcd588d2a7cad7e9956f66701fa\"\nintegrity sha512-3duEwti880xqi4eAMN8AyR4a0ByT90zoYdLlevfrvU43vb0YZwZVfxOgxWrLXXXpyugL0hNZc9G6BiB5B3nUug==\n@@ -4908,7 +4905,7 @@ async-limiter@~1.0.0:\nresolved \"https://registry.yarnpkg.com/async-limiter/-/async-limiter-1.0.1.tgz#dd379e94f0db8310b08291f9d64c3209766617fd\"\nintegrity sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ==\n-async-retry@^1.2.1:\n+async-retry@^1.2.1, async-retry@^1.3.3:\nversion \"1.3.3\"\nresolved \"https://registry.yarnpkg.com/async-retry/-/async-retry-1.3.3.tgz#0e7f36c04d8478e7a58bdbed80cedf977785f280\"\nintegrity sha512-wfr/jstw9xNi/0teMHrRW7dsz3Lt5ARhYNZ2ewpadnhaIp5mbALhOAP+EAdsC7t4Z6wqsDVv9+W6gm1Dk9mEyw==\n@@ -6356,7 +6353,14 @@ component-emitter@^1.2.1:\nresolved \"https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.3.0.tgz#16e4070fba8ae29b679f2215853ee181ab2eabc0\"\nintegrity sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg==\n-compressible@^2.0.12, compressible@~2.0.16:\n+compressible@^2.0.12:\n+ version \"2.0.18\"\n+ resolved \"https://registry.yarnpkg.com/compressible/-/compressible-2.0.18.tgz#af53cca6b070d4c3c0750fbd77286a6d7cc46fba\"\n+ integrity sha512-AF3r7P5dWxL8MxyITRMlORQNaOA2IkAFaTr4k7BUumjPtRpGDTZpl0Pb1XCO6JeDCBdp126Cgs9sMxqSjgYyRg==\n+ dependencies:\n+ mime-db \">= 1.43.0 < 2\"\n+\n+compressible@~2.0.16:\nversion \"2.0.17\"\nresolved \"https://registry.yarnpkg.com/compressible/-/compressible-2.0.17.tgz#6e8c108a16ad58384a977f3a482ca20bff2f38c1\"\nintegrity sha512-BGHeLCK1GV7j1bSmQQAi26X+GgWcTjLr/0tzSvMCl3LH1w1IJ4PFSPoV5316b30cneTziC+B1a+3OjoSUcQYmw==\n@@ -6410,16 +6414,6 @@ concat-stream@^1.5.0, concat-stream@^1.5.2, concat-stream@^1.6.2:\nreadable-stream \"^2.2.2\"\ntypedarray \"^0.0.6\"\n-concat-stream@^2.0.0:\n- version \"2.0.0\"\n- resolved \"https://registry.yarnpkg.com/concat-stream/-/concat-stream-2.0.0.tgz#414cf5af790a48c60ab9be4527d56d5e41133cb1\"\n- integrity sha512-MWufYdFw53ccGjCA+Ol7XJYpAlW6/prSMzuPOTRnJGcGzuhLn4Scrz7qf6o8bROZ514ltazcIFJZevcfbo0x7A==\n- dependencies:\n- buffer-from \"^1.0.0\"\n- inherits \"^2.0.3\"\n- readable-stream \"^3.0.2\"\n- typedarray \"^0.0.6\"\n-\nconcurrently@^5.3.0:\nversion \"5.3.0\"\nresolved \"https://registry.yarnpkg.com/concurrently/-/concurrently-5.3.0.tgz#7500de6410d043c912b2da27de3202cb489b1e7b\"\n@@ -7013,10 +7007,10 @@ data-urls@^2.0.0:\nwhatwg-mimetype \"^2.3.0\"\nwhatwg-url \"^8.0.0\"\n-date-and-time@^0.14.0:\n- version \"0.14.1\"\n- resolved \"https://registry.yarnpkg.com/date-and-time/-/date-and-time-0.14.1.tgz#969634697b78956fb66b8be6fb0f39fbd631f2f6\"\n- integrity sha512-M4RggEH5OF2ZuCOxgOU67R6Z9ohjKbxGvAQz48vj53wLmL0bAgumkBvycR32f30pK+Og9pIR+RFDyChbaE4oLA==\n+date-and-time@^2.0.0:\n+ version \"2.3.1\"\n+ resolved \"https://registry.yarnpkg.com/date-and-time/-/date-and-time-2.3.1.tgz#006675ec4943a0a5f85810e3a3fd6aa96f6130c9\"\n+ integrity sha512-OaIRmSJXifwEN21rMVVDs0Kz8uhJ3wWPYd86atkRiqN54liaMQYEbbrgjZQea75YXOBWL4ZFb3rG/waenw1TEg==\ndate-fns@^2.0.1:\nversion \"2.4.1\"\n@@ -7064,7 +7058,7 @@ debug@3.1.0:\ndependencies:\nms \"2.0.0\"\n-debug@4, debug@^4.0.1, debug@^4.3.1, debug@^4.3.2, debug@^4.3.3:\n+debug@4, debug@^4.0.1, debug@^4.3.1, debug@^4.3.3:\nversion \"4.3.3\"\nresolved \"https://registry.yarnpkg.com/debug/-/debug-4.3.3.tgz#04266e0b70a98d4462e6e288e38259213332b664\"\nintegrity sha512-/zxw5+vh1Tfv+4Qn7a5nsbcJKPaSvCDhojn6FEl9vupwK2VCSDtEiEtqr8DFtzYFOdz63LBkxec7DYuc2jon6Q==\n@@ -7085,7 +7079,7 @@ debug@^3.1.1, debug@^3.2.5, debug@^3.2.6, debug@^3.2.7:\ndependencies:\nms \"^2.1.1\"\n-debug@^4.1.0, debug@^4.1.1:\n+debug@^4.1.0, debug@^4.1.1, debug@^4.3.4:\nversion \"4.3.4\"\nresolved \"https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865\"\nintegrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==\n@@ -7339,11 +7333,11 @@ dicer@0.2.5:\nstreamsearch \"0.1.2\"\ndicer@^0.3.0:\n- version \"0.3.0\"\n- resolved \"https://registry.yarnpkg.com/dicer/-/dicer-0.3.0.tgz#eacd98b3bfbf92e8ab5c2fdb71aaac44bb06b872\"\n- integrity sha512-MdceRRWqltEG2dZqO769g27N/3PXfcKl04VhYnBlo2YhH7zPi88VebsjTKclaOyiuMaGU72hTfw3VkUitGcVCA==\n+ version \"0.3.1\"\n+ resolved \"https://registry.yarnpkg.com/dicer/-/dicer-0.3.1.tgz#abf28921e3475bc5e801e74e0159fd94f927ba97\"\n+ integrity sha512-ObioMtXnmjYs3aRtpIJt9rgQSPCIhKVkFPip+E9GUDyWl8N435znUxK/JfNwGZJ2wnn5JKQ7Ly3vOK5Q5dylGA==\ndependencies:\n- streamsearch \"0.1.2\"\n+ streamsearch \"^1.1.0\"\ndiff-match-patch@^1.0.0:\nversion \"1.0.5\"\n@@ -7504,7 +7498,7 @@ duplexer@~0.1.1:\nresolved \"https://registry.yarnpkg.com/duplexer/-/duplexer-0.1.1.tgz#ace6ff808c1ce66b57d1ebf97977acb02334cfc1\"\nintegrity sha1-rOb/gIwc5mtX0ev5eXessCM0z8E=\n-duplexify@^3.4.2, duplexify@^3.5.0, duplexify@^3.6.0:\n+duplexify@^3.4.2, duplexify@^3.6.0:\nversion \"3.7.1\"\nresolved \"https://registry.yarnpkg.com/duplexify/-/duplexify-3.7.1.tgz#2a4df5317f6ccfd91f86d6fd25d8d8a103b88309\"\nintegrity sha512-07z8uv2wMyS51kKhD1KsdXJg5WQ6t93RneqRxUHnskXVtlYYkLqM0gqStQZ3pj073g687jPCHrqNfCzawLYh5g==\n@@ -8736,21 +8730,21 @@ findup-sync@3.0.0:\nmicromatch \"^3.0.4\"\nresolve-dir \"^1.0.1\"\n-firebase-admin@^10.0.1:\n- version \"10.0.1\"\n- resolved \"https://registry.yarnpkg.com/firebase-admin/-/firebase-admin-10.0.1.tgz#dae1f3d2f75049b88d8255a390e7e4bedec85146\"\n- integrity sha512-p8nrhNJyuAj/Pc3M0TWVU8rd4rPoeCREfRt7dJ+EwkMvFCdJ6Cb21y3ZlN3Qsbok8PEQjuWLNy+C3LQMTfUOcQ==\n+firebase-admin@^10.1.0:\n+ version \"10.1.0\"\n+ resolved \"https://registry.yarnpkg.com/firebase-admin/-/firebase-admin-10.1.0.tgz#53b1f9c16e7dc6b7e04494f4f3740fbde77990d8\"\n+ integrity sha512-4i4wu+EFgNfY4+D4DxXkZcmbD832ozUMNvHMkOFQrf8upyp51n6jrDJS+wLok9sd62yeqcImbnsLOympGlISPA==\ndependencies:\n\"@firebase/database-compat\" \"^0.1.1\"\n- \"@firebase/database-types\" \"^0.7.2\"\n+ \"@firebase/database-types\" \"^0.9.3\"\n\"@types/node\" \">=12.12.47\"\ndicer \"^0.3.0\"\njsonwebtoken \"^8.5.1\"\njwks-rsa \"^2.0.2\"\n- node-forge \"^0.10.0\"\n+ node-forge \"^1.3.1\"\noptionalDependencies:\n- \"@google-cloud/firestore\" \"^4.5.0\"\n- \"@google-cloud/storage\" \"^5.3.0\"\n+ \"@google-cloud/firestore\" \"^4.15.1\"\n+ \"@google-cloud/storage\" \"^5.18.3\"\nflat-cache@^3.0.4:\nversion \"3.0.4\"\n@@ -9067,17 +9061,6 @@ gauge@~2.7.3:\nstrip-ansi \"^3.0.1\"\nwide-align \"^1.1.0\"\n-gaxios@^3.0.0:\n- version \"3.2.0\"\n- resolved \"https://registry.yarnpkg.com/gaxios/-/gaxios-3.2.0.tgz#11b6f0e8fb08d94a10d4d58b044ad3bec6dd486a\"\n- integrity sha512-+6WPeVzPvOshftpxJwRi2Ozez80tn/hdtOUag7+gajDHRJvAblKxTFSSMPtr2hmnLy7p0mvYz0rMXLBl8pSO7Q==\n- dependencies:\n- abort-controller \"^3.0.0\"\n- extend \"^3.0.2\"\n- https-proxy-agent \"^5.0.0\"\n- is-stream \"^2.0.0\"\n- node-fetch \"^2.3.0\"\n-\ngaxios@^4.0.0, gaxios@^4.3.2:\nversion \"4.3.2\"\nresolved \"https://registry.yarnpkg.com/gaxios/-/gaxios-4.3.2.tgz#845827c2dc25a0213c8ab4155c7a28910f5be83f\"\n@@ -9089,7 +9072,7 @@ gaxios@^4.0.0, gaxios@^4.3.2:\nis-stream \"^2.0.0\"\nnode-fetch \"^2.6.1\"\n-gcp-metadata@^4.1.0, gcp-metadata@^4.2.0:\n+gcp-metadata@^4.2.0:\nversion \"4.3.1\"\nresolved \"https://registry.yarnpkg.com/gcp-metadata/-/gcp-metadata-4.3.1.tgz#fb205fe6a90fef2fd9c85e6ba06e5559ee1eefa9\"\nintegrity sha512-x850LS5N7V1F3UcV7PoupzGsyD6iVwTVvsh3tbXfkctZnBnjW5yu5z1/3k3SehF7TyoTIe78rJs02GMMy+LF+A==\n@@ -9097,19 +9080,6 @@ gcp-metadata@^4.1.0, gcp-metadata@^4.2.0:\ngaxios \"^4.0.0\"\njson-bigint \"^1.0.0\"\n-gcs-resumable-upload@^3.1.0:\n- version \"3.1.1\"\n- resolved \"https://registry.yarnpkg.com/gcs-resumable-upload/-/gcs-resumable-upload-3.1.1.tgz#67c766a0555d6a352f9651b7603337207167d0de\"\n- integrity sha512-RS1osvAicj9+MjCc6jAcVL1Pt3tg7NK2C2gXM5nqD1Gs0klF2kj5nnAFSBy97JrtslMIQzpb7iSuxaG8rFWd2A==\n- dependencies:\n- abort-controller \"^3.0.0\"\n- configstore \"^5.0.0\"\n- extend \"^3.0.2\"\n- gaxios \"^3.0.0\"\n- google-auth-library \"^6.0.0\"\n- pumpify \"^2.0.0\"\n- stream-events \"^1.0.4\"\n-\ngenerate-function@^2.3.1:\nversion \"2.3.1\"\nresolved \"https://registry.yarnpkg.com/generate-function/-/generate-function-2.3.1.tgz#f069617690c10c868e73b8465746764f97c3479f\"\n@@ -9379,25 +9349,25 @@ globby@^7.1.1:\npify \"^3.0.0\"\nslash \"^1.0.0\"\n-google-auth-library@^6.0.0:\n- version \"6.0.6\"\n- resolved \"https://registry.yarnpkg.com/google-auth-library/-/google-auth-library-6.0.6.tgz#5102e5c643baab45b4c16e9752cd56b8861f3a82\"\n- integrity sha512-fWYdRdg55HSJoRq9k568jJA1lrhg9i2xgfhVIMJbskUmbDpJGHsbv9l41DGhCDXM21F9Kn4kUwdysgxSYBYJUw==\n+google-auth-library@^7.0.2:\n+ version \"7.11.0\"\n+ resolved \"https://registry.yarnpkg.com/google-auth-library/-/google-auth-library-7.11.0.tgz#b63699c65037310a424128a854ba7e736704cbdb\"\n+ integrity sha512-3S5jn2quRumvh9F/Ubf7GFrIq71HZ5a6vqosgdIu105kkk0WtSqc2jGCRqtWWOLRS8SX3AHACMOEDxhyWAQIcg==\ndependencies:\narrify \"^2.0.0\"\nbase64-js \"^1.3.0\"\necdsa-sig-formatter \"^1.0.11\"\nfast-text-encoding \"^1.0.0\"\n- gaxios \"^3.0.0\"\n- gcp-metadata \"^4.1.0\"\n- gtoken \"^5.0.0\"\n+ gaxios \"^4.0.0\"\n+ gcp-metadata \"^4.2.0\"\n+ gtoken \"^5.0.4\"\njws \"^4.0.0\"\nlru-cache \"^6.0.0\"\n-google-auth-library@^7.0.2, google-auth-library@^7.6.1:\n- version \"7.11.0\"\n- resolved \"https://registry.yarnpkg.com/google-auth-library/-/google-auth-library-7.11.0.tgz#b63699c65037310a424128a854ba7e736704cbdb\"\n- integrity sha512-3S5jn2quRumvh9F/Ubf7GFrIq71HZ5a6vqosgdIu105kkk0WtSqc2jGCRqtWWOLRS8SX3AHACMOEDxhyWAQIcg==\n+google-auth-library@^7.14.0, google-auth-library@^7.14.1:\n+ version \"7.14.1\"\n+ resolved \"https://registry.yarnpkg.com/google-auth-library/-/google-auth-library-7.14.1.tgz#e3483034162f24cc71b95c8a55a210008826213c\"\n+ integrity sha512-5Rk7iLNDFhFeBYc3s8l1CqzbEBcdhwR193RlD4vSNFajIcINKI8W8P0JLmBpwymHqqWbX34pJDQu39cSy/6RsA==\ndependencies:\narrify \"^2.0.0\"\nbase64-js \"^1.3.0\"\n@@ -9410,21 +9380,21 @@ google-auth-library@^7.0.2, google-auth-library@^7.6.1:\nlru-cache \"^6.0.0\"\ngoogle-gax@^2.24.1:\n- version \"2.28.1\"\n- resolved \"https://registry.yarnpkg.com/google-gax/-/google-gax-2.28.1.tgz#99bc234b5769d901d70959d40bd1651729eb4a34\"\n- integrity sha512-2Xjd3FrjlVd6Cmw2B2Aicpc/q92SwTpIOvxPUlnRg9w+Do8nu7UR+eQrgoKlo2FIUcUuDTvppvcx8toND0pK9g==\n+ version \"2.30.2\"\n+ resolved \"https://registry.yarnpkg.com/google-gax/-/google-gax-2.30.2.tgz#ba16940bad5a116099547a5966fdf83f6c026356\"\n+ integrity sha512-BCNCT26kb0iC52zj2SosyOZMhI5sVfXuul1h0Aw5uT9nGAbmS5eOvQ49ft53ft6XotDj11sUSDV6XESEiQqCqg==\ndependencies:\n- \"@grpc/grpc-js\" \"~1.4.0\"\n+ \"@grpc/grpc-js\" \"~1.6.0\"\n\"@grpc/proto-loader\" \"^0.6.1\"\n\"@types/long\" \"^4.0.0\"\nabort-controller \"^3.0.0\"\nduplexify \"^4.0.0\"\nfast-text-encoding \"^1.0.3\"\n- google-auth-library \"^7.6.1\"\n+ google-auth-library \"^7.14.0\"\nis-stream-ended \"^0.1.4\"\nnode-fetch \"^2.6.1\"\n- object-hash \"^2.1.1\"\n- proto3-json-serializer \"^0.1.5\"\n+ object-hash \"^3.0.0\"\n+ proto3-json-serializer \"^0.1.8\"\nprotobufjs \"6.11.2\"\nretry-request \"^4.0.0\"\n@@ -9520,7 +9490,7 @@ growly@^1.3.0:\nresolved \"https://registry.yarnpkg.com/growly/-/growly-1.3.0.tgz#f10748cbe76af964b7c96c93c6bcc28af120c081\"\nintegrity sha1-8QdIy+dq+WS3yWyTxrzCivEgwIE=\n-gtoken@^5.0.0, gtoken@^5.0.4:\n+gtoken@^5.0.4:\nversion \"5.3.1\"\nresolved \"https://registry.yarnpkg.com/gtoken/-/gtoken-5.3.1.tgz#c1c2598a826f2b5df7c6bb53d7be6cf6d50c3c78\"\nintegrity sha512-yqOREjzLHcbzz1UrQoxhBtpk8KjrVhuqPE7od1K2uhyxG2BHjKZetlbLw/SPZak/QqTIQW+addS+EcjqQsZbwQ==\n@@ -9813,12 +9783,12 @@ http-errors@~1.7.2:\nresolved \"https://registry.yarnpkg.com/http-parser-js/-/http-parser-js-0.4.10.tgz#92c9c1374c35085f75db359ec56cc257cbb93fa4\"\nintegrity sha1-ksnBN0w1CF912zWexWzCV8u5P6Q=\n-http-proxy-agent@^4.0.0:\n- version \"4.0.1\"\n- resolved \"https://registry.yarnpkg.com/http-proxy-agent/-/http-proxy-agent-4.0.1.tgz#8a8c8ef7f5932ccf953c296ca8291b95aa74aa3a\"\n- integrity sha512-k0zdNgqWTGA6aeIRVpvfVob4fL52dTfaehylg0Y4UvSySvOq/Y+BOyPrgpUrA7HylqvU8vIZGsRuXmspskV0Tg==\n+http-proxy-agent@^5.0.0:\n+ version \"5.0.0\"\n+ resolved \"https://registry.yarnpkg.com/http-proxy-agent/-/http-proxy-agent-5.0.0.tgz#5129800203520d434f142bc78ff3c170800f2b43\"\n+ integrity sha512-n2hY8YdoRE1i7r6M0w9DIw5GgZN0G25P8zLCRQ8rjXtTU3vsNFBI/vWK/UIeE6g5MUUz6avwAPXmL6Fy9D/90w==\ndependencies:\n- \"@tootallnate/once\" \"1\"\n+ \"@tootallnate/once\" \"2\"\nagent-base \"6\"\ndebug \"4\"\n@@ -11583,12 +11553,12 @@ jwa@^2.0.0:\nsafe-buffer \"^5.0.1\"\njwks-rsa@^2.0.2:\n- version \"2.0.5\"\n- resolved \"https://registry.yarnpkg.com/jwks-rsa/-/jwks-rsa-2.0.5.tgz#5dc911cdade803a149b7d4d41404a7c1bf2c221a\"\n- integrity sha512-fliHfsiBRzEU0nXzSvwnh0hynzGB0WihF+CinKbSRlaqRxbqqKf2xbBPgwc8mzf18/WgwlG8e5eTpfSTBcU4DQ==\n+ version \"2.1.0\"\n+ resolved \"https://registry.yarnpkg.com/jwks-rsa/-/jwks-rsa-2.1.0.tgz#00e4c5eecc40ba41de199b71ab7e489807a1727f\"\n+ integrity sha512-GKOSDBWWBCiQTzawei6mEdRQvji5gecj8F9JwMt0ZOPnBPSmTjo5CKFvvbhE7jGPkU159Cpi0+OTLuABFcNOQQ==\ndependencies:\n\"@types/express-jwt\" \"0.0.42\"\n- debug \"^4.3.2\"\n+ debug \"^4.3.4\"\njose \"^2.0.5\"\nlimiter \"^1.1.5\"\nlru-memoizer \"^2.1.4\"\n@@ -12769,7 +12739,19 @@ mime-db@1.48.0, \"mime-db@>= 1.40.0 < 2\":\nresolved \"https://registry.yarnpkg.com/mime-db/-/mime-db-1.48.0.tgz#e35b31045dd7eada3aaad537ed88a33afbef2d1d\"\nintegrity sha512-FM3QwxV+TnZYQ2aRqhlKBMHxk10lTbMt3bBkMAp54ddrNeVSfcQYOOKuGuy3Ddrm38I04If834fOUSq1yzslJQ==\n-mime-types@^2.0.8, mime-types@^2.1.12, mime-types@^2.1.27, mime-types@~2.1.17, mime-types@~2.1.19, mime-types@~2.1.24:\n+mime-db@1.52.0, \"mime-db@>= 1.43.0 < 2\":\n+ version \"1.52.0\"\n+ resolved \"https://registry.yarnpkg.com/mime-db/-/mime-db-1.52.0.tgz#bbabcdc02859f4987301c856e3387ce5ec43bf70\"\n+ integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==\n+\n+mime-types@^2.0.8:\n+ version \"2.1.35\"\n+ resolved \"https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.35.tgz#381a871b62a734450660ae3deee44813f70d959a\"\n+ integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==\n+ dependencies:\n+ mime-db \"1.52.0\"\n+\n+mime-types@^2.1.12, mime-types@^2.1.27, mime-types@~2.1.17, mime-types@~2.1.19, mime-types@~2.1.24:\nversion \"2.1.31\"\nresolved \"https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.31.tgz#a00d76b74317c61f9c2db2218b8e9f8e9c5c9e6b\"\nintegrity sha512-XGZnNzm3QvgKxa8dpzyhFTHmpP3l5YNusmne07VUOXxou9CqUqYa/HBy124RqtVh/O2pECas/MOcsDgpilPOPg==\n@@ -12781,11 +12763,16 @@ mime@1.6.0:\nresolved \"https://registry.yarnpkg.com/mime/-/mime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1\"\nintegrity sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==\n-mime@^2.2.0, mime@^2.4.1, mime@^2.4.4:\n+mime@^2.4.1, mime@^2.4.4:\nversion \"2.4.4\"\nresolved \"https://registry.yarnpkg.com/mime/-/mime-2.4.4.tgz#bd7b91135fc6b01cde3e9bae33d659b63d8857e5\"\nintegrity sha512-LRxmNwziLPT828z+4YkNzloCFC2YM4wrB99k+AV5ZbEyfGNWfG8SO1FUXLmLDBSo89NrJZ4DIWeLjy1CHGhMGA==\n+mime@^3.0.0:\n+ version \"3.0.0\"\n+ resolved \"https://registry.yarnpkg.com/mime/-/mime-3.0.0.tgz#b374550dca3a0c18443b0c950a6a58f1931cf7a7\"\n+ integrity sha512-jSCU7/VB1loIWBZe14aEYHU/+1UMEHoaO7qxCOVJOw9GgH72VAWppxNcjU+x9a2k3GSIBXNKxXQFqRvvZ7vr3A==\n+\nmimic-fn@^1.0.0:\nversion \"1.2.0\"\nresolved \"https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022\"\n@@ -13219,6 +13206,11 @@ node-forge@0.10.0, node-forge@^0.10.0:\nresolved \"https://registry.yarnpkg.com/node-forge/-/node-forge-0.10.0.tgz#32dea2afb3e9926f02ee5ce8794902691a676bf3\"\nintegrity sha512-PPmu8eEeG9saEUvI97fm4OYxXVB6bFvyNTyiUOBichBpFG8A1Ljw3bY62+5oOjDEMHRnd0Y7HQ+x7uzxOzC6JA==\n+node-forge@^1.3.1:\n+ version \"1.3.1\"\n+ resolved \"https://registry.yarnpkg.com/node-forge/-/node-forge-1.3.1.tgz#be8da2af243b2417d5f646a770663a92b7e9ded3\"\n+ integrity sha512-dPEtOeMvF9VMcYV/1Wb8CPoVAXtp6MKMlcbAt4ddqmGqUJ6fQZFXkNZNkNlfevtNkGtaSoXf/vNNNSvgrdXwtA==\n+\nnode-gyp-build@^4.3.0:\nversion \"4.3.0\"\nresolved \"https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.3.0.tgz#9f256b03e5826150be39c764bf51e993946d71a3\"\n@@ -13522,10 +13514,10 @@ object-copy@^0.1.0:\ndefine-property \"^0.2.5\"\nkind-of \"^3.0.3\"\n-object-hash@^2.1.1:\n- version \"2.2.0\"\n- resolved \"https://registry.yarnpkg.com/object-hash/-/object-hash-2.2.0.tgz#5ad518581eefc443bd763472b8ff2e9c2c0d54a5\"\n- integrity sha512-gScRMn0bS5fH+IuwyIFgnh9zBdo4DV+6GhygmWM9HyNJSgS0hScp1f5vjtm7oIIOiT9trXrShAkLFSc2IqKNgw==\n+object-hash@^3.0.0:\n+ version \"3.0.0\"\n+ resolved \"https://registry.yarnpkg.com/object-hash/-/object-hash-3.0.0.tgz#73f97f753e7baffc0e2cc9d6e079079744ac82e9\"\n+ integrity sha512-RSn9F68PjH9HqtltsSnqYC1XXoWe9Bju5+213R98cNGttag9q9yAOTzdbsqvIa7aNm5WffBZFpWYr2aWrklWAw==\nobject-inspect@^1.10.3, object-inspect@^1.11.1, object-inspect@^1.9.0:\nversion \"1.12.0\"\n@@ -14734,10 +14726,10 @@ proto-list@~1.2.1:\nresolved \"https://registry.yarnpkg.com/proto-list/-/proto-list-1.2.4.tgz#212d5bfe1318306a420f6402b8e26ff39647a849\"\nintegrity sha1-IS1b/hMYMGpCD2QCuOJv85ZHqEk=\n-proto3-json-serializer@^0.1.5:\n- version \"0.1.6\"\n- resolved \"https://registry.yarnpkg.com/proto3-json-serializer/-/proto3-json-serializer-0.1.6.tgz#67cf3b8d5f4c8bebfc410698ad3b1ed64da39c7b\"\n- integrity sha512-tGbV6m6Kad8NqxMh5hw87euPS0YoZSAOIfvR01zYkQV8Gpx1V/8yU/0gCKCvfCkhAJsjvzzhnnsdQxA1w7PSog==\n+proto3-json-serializer@^0.1.8:\n+ version \"0.1.8\"\n+ resolved \"https://registry.yarnpkg.com/proto3-json-serializer/-/proto3-json-serializer-0.1.8.tgz#f80f9afc1efe5ed9a9856bbbd17dc7cabd7ce9a3\"\n+ integrity sha512-ACilkB6s1U1gWnl5jtICpnDai4VCxmI9GFxuEaYdxtDG2oVI3sVFIUsvUZcQbJgtPM6p+zqKbjTKQZp6Y4FpQw==\ndependencies:\nprotobufjs \"^6.11.2\"\n@@ -15632,7 +15624,7 @@ readable-stream@^2.2.2:\nstring_decoder \"~1.1.1\"\nutil-deprecate \"~1.0.1\"\n-readable-stream@^3.0.2, readable-stream@^3.0.6, readable-stream@^3.1.1, readable-stream@^3.4.0, readable-stream@^3.6.0:\n+readable-stream@^3.0.6, readable-stream@^3.1.1, readable-stream@^3.4.0, readable-stream@^3.6.0:\nversion \"3.6.0\"\nresolved \"https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.6.0.tgz#337bbda3adc0706bd3e024426a286d4b4b2c9198\"\nintegrity sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA==\n@@ -16099,12 +16091,13 @@ ret@~0.1.10:\nresolved \"https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc\"\nintegrity sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg==\n-retry-request@^4.0.0, retry-request@^4.1.1:\n- version \"4.1.3\"\n- resolved \"https://registry.yarnpkg.com/retry-request/-/retry-request-4.1.3.tgz#d5f74daf261372cff58d08b0a1979b4d7cab0fde\"\n- integrity sha512-QnRZUpuPNgX0+D1xVxul6DbJ9slvo4Rm6iV/dn63e048MvGbUZiKySVt6Tenp04JqmchxjiLltGerOJys7kJYQ==\n+retry-request@^4.0.0, retry-request@^4.2.2:\n+ version \"4.2.2\"\n+ resolved \"https://registry.yarnpkg.com/retry-request/-/retry-request-4.2.2.tgz#b7d82210b6d2651ed249ba3497f07ea602f1a903\"\n+ integrity sha512-xA93uxUD/rogV7BV59agW/JHPGXeREMWiZc9jhcwY4YdZ7QOtC7qbomYg0n4wyk2lJhggjvKvhNX8wln/Aldhg==\ndependencies:\ndebug \"^4.1.1\"\n+ extend \"^3.0.2\"\nretry@0.13.1:\nversion \"0.13.1\"\n@@ -17129,7 +17122,7 @@ stream-each@^1.1.0:\nend-of-stream \"^1.1.0\"\nstream-shift \"^1.0.0\"\n-stream-events@^1.0.1, stream-events@^1.0.4, stream-events@^1.0.5:\n+stream-events@^1.0.4, stream-events@^1.0.5:\nversion \"1.0.5\"\nresolved \"https://registry.yarnpkg.com/stream-events/-/stream-events-1.0.5.tgz#bbc898ec4df33a4902d892333d47da9bf1c406d5\"\nintegrity sha512-E1GUzBSgvct8Jsb3v2X15pjzN1tYebtbLaMg+eBOUOAxgbLoSbT2NS91ckc5lJD1KfLjId+jXJRgo0qnV5Nerg==\n@@ -17157,6 +17150,11 @@ streamsearch@0.1.2:\nresolved \"https://registry.yarnpkg.com/streamsearch/-/streamsearch-0.1.2.tgz#808b9d0e56fc273d809ba57338e929919a1a9f1a\"\nintegrity sha1-gIudDlb8Jz2Am6VzOOkpkZoanxo=\n+streamsearch@^1.1.0:\n+ version \"1.1.0\"\n+ resolved \"https://registry.yarnpkg.com/streamsearch/-/streamsearch-1.1.0.tgz#404dd1e2247ca94af554e841a8ef0eaa238da764\"\n+ integrity sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg==\n+\nstrict-uri-encode@^1.0.0:\nversion \"1.1.0\"\nresolved \"https://registry.yarnpkg.com/strict-uri-encode/-/strict-uri-encode-1.1.0.tgz#279b225df1d582b1f54e65addd4352e18faa0713\"\n@@ -17576,14 +17574,14 @@ tcomb@^3.2.29:\nresolved \"https://registry.yarnpkg.com/tcomb/-/tcomb-3.2.29.tgz#32404fe9456d90c2cf4798682d37439f1ccc386c\"\nintegrity sha512-di2Hd1DB2Zfw6StGv861JoAF5h/uQVu/QJp2g8KVbtfKnoHdBQl5M32YWq6mnSYBQ1vFFrns5B1haWJL7rKaOQ==\n-teeny-request@^7.0.0:\n- version \"7.0.0\"\n- resolved \"https://registry.yarnpkg.com/teeny-request/-/teeny-request-7.0.0.tgz#0e5c090bd9102ed559ffc8c9ddb00fbe1256db30\"\n- integrity sha512-kWD3sdGmIix6w7c8ZdVKxWq+3YwVPGWz+Mq0wRZXayEKY/YHb63b8uphfBzcFDmyq8frD9+UTc3wLyOhltRbtg==\n+teeny-request@^7.1.3:\n+ version \"7.2.0\"\n+ resolved \"https://registry.yarnpkg.com/teeny-request/-/teeny-request-7.2.0.tgz#41347ece068f08d741e7b86df38a4498208b2633\"\n+ integrity sha512-SyY0pek1zWsi0LRVAALem+avzMLc33MKW/JLLakdP4s9+D7+jHcy5x6P+h94g2QNZsAqQNfX5lsbd3WSeJXrrw==\ndependencies:\n- http-proxy-agent \"^4.0.0\"\n+ http-proxy-agent \"^5.0.0\"\nhttps-proxy-agent \"^5.0.0\"\n- node-fetch \"^2.2.0\"\n+ node-fetch \"^2.6.1\"\nstream-events \"^1.0.5\"\nuuid \"^8.0.0\"\n@@ -19183,7 +19181,7 @@ yargs@^15.1.0, yargs@^15.3.1, yargs@^15.4.1:\ny18n \"^4.0.0\"\nyargs-parser \"^18.1.2\"\n-yargs@^16.1.1:\n+yargs@^16.1.1, yargs@^16.2.0:\nversion \"16.2.0\"\nresolved \"https://registry.yarnpkg.com/yargs/-/yargs-16.2.0.tgz#1c82bf0f6b6a66eafce7ef30e376f49a12477f66\"\nintegrity sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[keyserver] Bump `firebase-admin` to `10.1.0` Summary: Downstream dependencies have issues surfaced by `yarn audit` Checked the `10.0.2` and `10.1.0` release notes and found no evidence of breaking changes: https://github.com/firebase/firebase-admin-node/releases Test Plan: CI Reviewers: def-au1t, palys-swm, ashoat Reviewed By: ashoat Subscribers: Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3855
129,187
27.04.2022 23:15:07
14,400
25931883c550a7645b322f0d736638fef824096e
[keyserver] Dockerfile for Node keyserver Summary: With script dependencies in place, this diff completes the Dockerfile for the Node keyserver. Depends on D3870 Test Plan: `docker-compose up --build` Reviewers: palys-swm, jimpo Subscribers: Adrian, atul, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "keyserver/Dockerfile", "new_path": "keyserver/Dockerfile", "diff": "@@ -40,3 +40,26 @@ COPY native/ios/Podfile native/ios/\n# Actually run yarn\nRUN yarn cleaninstall\n+\n+#-------------------------------------------------------------------------------\n+# STEP 2: COPY IN SOURCE FILES\n+# We run this later so the above layers are cached if only source files change\n+#-------------------------------------------------------------------------------\n+\n+COPY . .\n+\n+#-------------------------------------------------------------------------------\n+# STEP 3: RUN BUILD SCRIPTS\n+# We need to populate keyserver/dist, among other things\n+#-------------------------------------------------------------------------------\n+\n+WORKDIR /app/keyserver\n+RUN yarn prod-build\n+\n+#-------------------------------------------------------------------------------\n+# STEP 4: RUN THE SERVER\n+# Actually run the Node.js keyserver using nvm\n+#-------------------------------------------------------------------------------\n+\n+EXPOSE 3000\n+CMD bash/run-prod.sh\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[keyserver] Dockerfile for Node keyserver Summary: With script dependencies in place, this diff completes the Dockerfile for the Node keyserver. Depends on D3870 Test Plan: `docker-compose up --build` Reviewers: palys-swm, jimpo Reviewed By: palys-swm Subscribers: Adrian, atul, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3871
129,184
27.04.2022 09:33:58
18,000
bd743e58e318110fe2c419ac0bc3e7cc24610b49
[native] Bump `react-native-svg` to `12.3.0` Summary: Downstream dependencies have issues surfaced by `yarn audit` Checked the release notes: and didn't find any breaking changes Depends on D3855 Test Plan: CI Reviewers: def-au1t, palys-swm, ashoat Subscribers: Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "native/ios/Podfile.lock", "new_path": "native/ios/Podfile.lock", "diff": "@@ -895,8 +895,8 @@ PODS:\n- RNScreens (3.8.0):\n- React-Core\n- React-RCTImage\n- - RNSVG (12.1.1):\n- - React\n+ - RNSVG (12.3.0):\n+ - React-Core\n- RNVectorIcons (6.6.0):\n- React\n- SDWebImage (5.12.3):\n@@ -1299,7 +1299,7 @@ SPEC CHECKSUMS:\nRNKeychain: 4f63aada75ebafd26f4bc2c670199461eab85d94\nRNReanimated: e8afbe2a9e08e9e778ea72ddb1a8533445812621\nRNScreens: 6e1ea5787989f92b0671049b808aef64fa1ef98c\n- RNSVG: 551acb6562324b1d52a4e0758f7ca0ec234e278f\n+ RNSVG: 302bfc9905bd8122f08966dc2ce2d07b7b52b9f8\nRNVectorIcons: 0bb4def82230be1333ddaeee9fcba45f0b288ed4\nSDWebImage: 53179a2dba77246efa8a9b85f5c5b21f8f43e38f\nSDWebImageWebPCoder: d0dac55073088d24b2ac1b191a71a8f8d0adac21\n" }, { "change_type": "MODIFY", "old_path": "native/package.json", "new_path": "native/package.json", "diff": "\"react-native-safe-area-context\": \"^3.1.9\",\n\"react-native-safe-area-view\": \"^2.0.0\",\n\"react-native-screens\": \"~3.8.0\",\n- \"react-native-svg\": \"^12.1.1\",\n+ \"react-native-svg\": \"^12.3.0\",\n\"react-native-tab-view\": \"^2.15.2\",\n\"react-native-vector-icons\": \"^6.6.0\",\n\"react-native-video\": \"~5.1.1\",\n" }, { "change_type": "MODIFY", "old_path": "yarn.lock", "new_path": "yarn.lock", "diff": "@@ -6774,7 +6774,7 @@ css-select-base-adapter@^0.1.1:\nresolved \"https://registry.yarnpkg.com/css-select-base-adapter/-/css-select-base-adapter-0.1.1.tgz#3b2ff4972cc362ab88561507a95408a1432135d7\"\nintegrity sha512-jQVeeRG70QI08vSTwf1jHxp74JoZsr2XSgETae8/xC8ovSnL2WF87GTLO86Sbwdt2lK4Umg4HnnwMO4YF3Ce7w==\n-css-select@^2.0.0, css-select@^2.1.0:\n+css-select@^2.0.0:\nversion \"2.1.0\"\nresolved \"https://registry.yarnpkg.com/css-select/-/css-select-2.1.0.tgz#6a34653356635934a81baca68d0255432105dbef\"\nintegrity sha512-Dqk7LQKpwLoH3VovzZnkzegqNSuAziQyNZUcrdDM401iY+R5NkGBXGmtO05/yaXQziALuPogeG0b7UAgjnTJTQ==\n@@ -6784,6 +6784,17 @@ css-select@^2.0.0, css-select@^2.1.0:\ndomutils \"^1.7.0\"\nnth-check \"^1.0.2\"\n+css-select@^4.2.1:\n+ version \"4.3.0\"\n+ resolved \"https://registry.yarnpkg.com/css-select/-/css-select-4.3.0.tgz#db7129b2846662fd8628cfc496abb2b59e41529b\"\n+ integrity sha512-wPpOYtnsVontu2mODhA19JrqWxNsfdatRKd64kmpRbQgh1KtItko5sTnEpPdpSaJszTOhEMlF/RPz28qj4HqhQ==\n+ dependencies:\n+ boolbase \"^1.0.0\"\n+ css-what \"^6.0.1\"\n+ domhandler \"^4.3.1\"\n+ domutils \"^2.8.0\"\n+ nth-check \"^2.0.1\"\n+\ncss-to-react-native@^3.0.0:\nversion \"3.0.0\"\nresolved \"https://registry.yarnpkg.com/css-to-react-native/-/css-to-react-native-3.0.0.tgz#62dbe678072a824a689bcfee011fc96e02a7d756\"\n@@ -6835,6 +6846,11 @@ css-what@^3.2.1:\nresolved \"https://registry.yarnpkg.com/css-what/-/css-what-3.4.2.tgz#ea7026fcb01777edbde52124e21f327e7ae950e4\"\nintegrity sha512-ACUm3L0/jiZTqfzRM3Hi9Q8eZqd6IK37mMWPLz9PJxkLWllYeRf+EHUSHYEtFop2Eqytaq1FizFVh7XfBnXCDQ==\n+css-what@^6.0.1:\n+ version \"6.1.0\"\n+ resolved \"https://registry.yarnpkg.com/css-what/-/css-what-6.1.0.tgz#fb5effcf76f1ddea2c81bdfaa4de44e79bac70f4\"\n+ integrity sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw==\n+\ncssesc@^2.0.0:\nversion \"2.0.0\"\nresolved \"https://registry.yarnpkg.com/cssesc/-/cssesc-2.0.0.tgz#3b13bd1bb1cb36e1bcb5a4dcd27f54c5dcb35703\"\n@@ -7431,6 +7447,15 @@ dom-serializer@0:\ndomelementtype \"^2.0.1\"\nentities \"^2.0.0\"\n+dom-serializer@^1.0.1:\n+ version \"1.4.1\"\n+ resolved \"https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-1.4.1.tgz#de5d41b1aea290215dc45a6dae8adcf1d32e2d30\"\n+ integrity sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag==\n+ dependencies:\n+ domelementtype \"^2.0.1\"\n+ domhandler \"^4.2.0\"\n+ entities \"^2.0.0\"\n+\ndom-walk@^0.1.0:\nversion \"0.1.1\"\nresolved \"https://registry.yarnpkg.com/dom-walk/-/dom-walk-0.1.1.tgz#672226dc74c8f799ad35307df936aba11acd6018\"\n@@ -7451,6 +7476,11 @@ domelementtype@^2.0.1:\nresolved \"https://registry.yarnpkg.com/domelementtype/-/domelementtype-2.0.1.tgz#1f8bdfe91f5a78063274e803b4bdcedf6e94f94d\"\nintegrity sha512-5HOHUDsYZWV8FGWN0Njbr/Rn7f/eWSQi1v7+HsUVwXgn8nWWlL64zKDkS0n8ZmQ3mlWOMuXOnR+7Nx/5tMO5AQ==\n+domelementtype@^2.2.0:\n+ version \"2.3.0\"\n+ resolved \"https://registry.yarnpkg.com/domelementtype/-/domelementtype-2.3.0.tgz#5c45e8e869952626331d7aab326d01daf65d589d\"\n+ integrity sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==\n+\ndomexception@^2.0.1:\nversion \"2.0.1\"\nresolved \"https://registry.yarnpkg.com/domexception/-/domexception-2.0.1.tgz#fb44aefba793e1574b0af6aed2801d057529f304\"\n@@ -7458,6 +7488,13 @@ domexception@^2.0.1:\ndependencies:\nwebidl-conversions \"^5.0.0\"\n+domhandler@^4.2.0, domhandler@^4.3.1:\n+ version \"4.3.1\"\n+ resolved \"https://registry.yarnpkg.com/domhandler/-/domhandler-4.3.1.tgz#8d792033416f59d68bc03a5aa7b018c1ca89279c\"\n+ integrity sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==\n+ dependencies:\n+ domelementtype \"^2.2.0\"\n+\ndomutils@^1.7.0:\nversion \"1.7.0\"\nresolved \"https://registry.yarnpkg.com/domutils/-/domutils-1.7.0.tgz#56ea341e834e06e6748af7a1cb25da67ea9f8c2a\"\n@@ -7466,6 +7503,15 @@ domutils@^1.7.0:\ndom-serializer \"0\"\ndomelementtype \"1\"\n+domutils@^2.8.0:\n+ version \"2.8.0\"\n+ resolved \"https://registry.yarnpkg.com/domutils/-/domutils-2.8.0.tgz#4437def5db6e2d1f5d6ee859bd95ca7d02048135\"\n+ integrity sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==\n+ dependencies:\n+ dom-serializer \"^1.0.1\"\n+ domelementtype \"^2.2.0\"\n+ domhandler \"^4.2.0\"\n+\ndot-prop@^5.2.0:\nversion \"5.2.0\"\nresolved \"https://registry.yarnpkg.com/dot-prop/-/dot-prop-5.2.0.tgz#c34ecc29556dc45f1f4c22697b6f4904e0cc4fcb\"\n@@ -13470,6 +13516,13 @@ nth-check@^1.0.2:\ndependencies:\nboolbase \"~1.0.0\"\n+nth-check@^2.0.1:\n+ version \"2.0.1\"\n+ resolved \"https://registry.yarnpkg.com/nth-check/-/nth-check-2.0.1.tgz#2efe162f5c3da06a28959fbd3db75dbeea9f0fc2\"\n+ integrity sha512-it1vE95zF6dTT9lBsYbxvqh0Soy4SPowchj0UBGj/V6cTPnXXtQOPUbhZ6CmGzAD/rW22LQK6E96pcdJXk4A4w==\n+ dependencies:\n+ boolbase \"^1.0.0\"\n+\nnullthrows@^1.1.1:\nversion \"1.1.1\"\nresolved \"https://registry.yarnpkg.com/nullthrows/-/nullthrows-1.1.1.tgz#7818258843856ae971eae4208ad7d7eb19a431b1\"\n@@ -15332,12 +15385,12 @@ react-native-screens@~3.8.0:\ndependencies:\nwarn-once \"^0.1.0\"\n-react-native-svg@^12.1.1:\n- version \"12.1.1\"\n- resolved \"https://registry.yarnpkg.com/react-native-svg/-/react-native-svg-12.1.1.tgz#5f292410b8bcc07bbc52b2da7ceb22caf5bcaaee\"\n- integrity sha512-NIAJ8jCnXGCqGWXkkJ1GTzO4a3Md5at5sagYV8Vh4MXYnL4z5Rh428Wahjhh+LIjx40EE5xM5YtwyJBqOIba2Q==\n+react-native-svg@^12.3.0:\n+ version \"12.3.0\"\n+ resolved \"https://registry.yarnpkg.com/react-native-svg/-/react-native-svg-12.3.0.tgz#40f657c5d1ee366df23f3ec8dae76fd276b86248\"\n+ integrity sha512-ESG1g1j7/WLD7X3XRFTQHVv0r6DpbHNNcdusngAODIxG88wpTWUZkhcM3A2HJTb+BbXTFDamHv7FwtRKWQ/ALg==\ndependencies:\n- css-select \"^2.1.0\"\n+ css-select \"^4.2.1\"\ncss-tree \"^1.0.0-alpha.39\"\nreact-native-tab-view@^2.15.2:\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[native] Bump `react-native-svg` to `12.3.0` Summary: Downstream dependencies have issues surfaced by `yarn audit` Checked the release notes: https://github.com/react-native-svg/react-native-svg/releases and didn't find any breaking changes --- Depends on D3855 Test Plan: CI Reviewers: def-au1t, palys-swm, ashoat Reviewed By: ashoat Subscribers: Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3856
129,179
02.05.2022 11:23:22
14,400
80abee4eb84a0af9a81c69d2ab318951aec79d36
[lib] [refactor] add memo in inline sidebar hook Summary: updating the hook per my comment in my last diff: Test Plan: use the application like normal. replied should reflect in a sidebar as they do normally. Reviewers: atul, def-au1t, yayabosh, ashoat Subscribers: palys-swm, Adrian, karol-bisztyga
[ { "change_type": "MODIFY", "old_path": "lib/hooks/inline-sidebar-text.react.js", "new_path": "lib/hooks/inline-sidebar-text.react.js", "diff": "@@ -29,7 +29,13 @@ function useInlineSidebarText(\nreturn senders.length > 0 ? `${pluralizeAndTrim(senders, 25)} sent ` : '';\n}, [threadMembers]);\n- return { sendersText, repliesText };\n+ return React.useMemo(\n+ () => ({\n+ sendersText,\n+ repliesText,\n+ }),\n+ [sendersText, repliesText],\n+ );\n}\nexport default useInlineSidebarText;\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib] [refactor] [ENG-530] add memo in inline sidebar hook Summary: updating the hook per my comment in my last diff: https://phabricator.ashoat.com/D3879#inline-23803 Test Plan: use the application like normal. replied should reflect in a sidebar as they do normally. Reviewers: atul, def-au1t, yayabosh, ashoat Reviewed By: ashoat Subscribers: palys-swm, Adrian, karol-bisztyga Differential Revision: https://phabricator.ashoat.com/D3887
129,190
28.04.2022 15:16:07
-7,200
cd7375d7e288fb46a6d144aa7995e62565e37621
[services] Fix clang paths Summary: Fixing clang paths that are broken because of the directory refactoring Test Plan: ``` yarn clang-format-all ``` Reviewers: palys-swm, ashoat Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "native/android/app/src/main/java/app/comm/android/fbjni/NetworkModule.java", "new_path": "native/android/app/src/main/java/app/comm/android/fbjni/NetworkModule.java", "diff": "package app.comm.android.fbjni;\n-public class NetworkModule { public static native void sendPong(); }\n+public class NetworkModule {\n+ public static native void sendPong();\n+}\n" }, { "change_type": "MODIFY", "old_path": "scripts/get_clang_paths.js", "new_path": "scripts/get_clang_paths.js", "diff": "@@ -7,27 +7,27 @@ const clangPaths = [\nexcludes: ['_generated'],\n},\n{\n- path: 'services/tunnelbroker/docker-server/contents/server/src',\n+ path: 'services/tunnelbroker/src',\nextensions: ['cpp', 'h'],\n},\n{\n- path: 'services/backup/docker-server/contents/server/src',\n+ path: 'services/tunnelbroker/test',\nextensions: ['cpp', 'h'],\n},\n{\n- path: 'services/backup/docker-server/contents/server/test',\n+ path: 'services/backup/src',\nextensions: ['cpp', 'h'],\n},\n{\n- path: 'services/backup/docker-server/contents/server/dev',\n+ path: 'services/backup/test',\nextensions: ['cpp', 'h'],\n},\n{\n- path: 'services/blob/docker-server/contents/server/src',\n+ path: 'services/blob/src',\nextensions: ['cpp', 'h'],\n},\n{\n- path: 'services/blob/docker-server/contents/server/test',\n+ path: 'services/blob/test',\nextensions: ['cpp', 'h'],\n},\n{\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "diff": "#include <grpcpp/grpcpp.h>\n+#include <atomic>\n#include <iostream>\n#include <memory>\n#include <string>\n-#include <atomic>\nnamespace comm {\nnamespace network {\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "diff": "#include <grpcpp/grpcpp.h>\n+#include <atomic>\n#include <iostream>\n#include <memory>\n#include <string>\n-#include <atomic>\nnamespace comm {\nnamespace network {\n" }, { "change_type": "MODIFY", "old_path": "services/tunnelbroker/src/Constants.h", "new_path": "services/tunnelbroker/src/Constants.h", "diff": "@@ -36,8 +36,7 @@ const std::string AMQP_HEADER_FROM_DEVICEID = \"fromDeviceID\";\nconst std::string AMQP_HEADER_TO_DEVICEID = \"toDeviceID\";\nconst std::string AMQP_HEADER_MESSAGEID = \"messageID\";\n-const int64_t AMQP_SHORTEST_RECONNECTION_ATTEMPT_INTERVAL =\n- 1000 * 60; // 1 min\n+const int64_t AMQP_SHORTEST_RECONNECTION_ATTEMPT_INTERVAL = 1000 * 60; // 1 min\n// DeviceID\nconst size_t DEVICEID_CHAR_LENGTH = 64;\n" }, { "change_type": "MODIFY", "old_path": "services/tunnelbroker/test/TunnelBrokerTest.cpp", "new_path": "services/tunnelbroker/test/TunnelBrokerTest.cpp", "diff": "#include <gtest/gtest.h>\n-class TunnelBrokerTest : public testing::Test\n-{\n+class TunnelBrokerTest : public testing::Test {\nprotected:\nvirtual void SetUp() {\n//...\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Fix clang paths Summary: https://linear.app/comm/issue/ENG-915/services-fix-clang-paths Fixing clang paths that are broken because of the directory refactoring Test Plan: ``` yarn clang-format-all ``` Reviewers: palys-swm, ashoat Reviewed By: ashoat Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D3873
129,190
05.05.2022 16:40:45
-7,200
df1c524f0670cecf1605db8fc031f92fc7be6d3d
[services] Rename Reactor Utility Summary: Renaming `ReactorUtility` -> `ReactorStatusHolder` Test Plan: services should still build ``` cd services yarn test-blob-service yarn test-backup-service ``` Reviewers: ashoat Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/backup/src/Reactors/BaseReactor.h", "new_path": "services/backup/src/Reactors/BaseReactor.h", "diff": "#pragma once\n-#include \"ReactorUtility.h\"\n+#include \"ReactorStatusHolder.h\"\n#include <grpcpp/grpcpp.h>\n@@ -12,7 +12,7 @@ namespace reactor {\nclass BaseReactor {\npublic:\n- virtual std::shared_ptr<ReactorUtility> getUtility() = 0;\n+ virtual std::shared_ptr<ReactorStatusHolder> getUtility() = 0;\nvirtual void terminate(const grpc::Status &status) = 0;\nvirtual void validate() = 0;\nvirtual void doneCallback() = 0;\n" }, { "change_type": "RENAME", "old_path": "services/backup/src/Reactors/ReactorUtility.h", "new_path": "services/backup/src/Reactors/ReactorStatusHolder.h", "diff": "@@ -16,7 +16,7 @@ enum class ReactorState {\nDONE = 3,\n};\n-class ReactorUtility {\n+class ReactorStatusHolder {\nprivate:\ngrpc::Status status = grpc::Status::OK;\nstd::mutex statusAccessMutex;\n" }, { "change_type": "MODIFY", "old_path": "services/backup/src/Reactors/client/base-reactors/ClientBidiReactorBase.h", "new_path": "services/backup/src/Reactors/client/base-reactors/ClientBidiReactorBase.h", "diff": "@@ -11,7 +11,7 @@ namespace reactor {\ntemplate <class Request, class Response>\nclass ClientBidiReactorBase : public grpc::ClientBidiReactor<Request, Response>,\npublic BaseReactor {\n- std::shared_ptr<ReactorUtility> utility;\n+ std::shared_ptr<ReactorStatusHolder> utility;\nstd::shared_ptr<Response> response = nullptr;\nvoid nextWrite();\n@@ -31,7 +31,7 @@ public:\nvoid OnReadDone(bool ok) override;\nvoid terminate(const grpc::Status &status) override;\nvoid OnDone(const grpc::Status &status) override;\n- std::shared_ptr<ReactorUtility> getUtility() override;\n+ std::shared_ptr<ReactorStatusHolder> getUtility() override;\nvirtual std::unique_ptr<grpc::Status> prepareRequest(\nRequest &request,\n@@ -118,7 +118,7 @@ void ClientBidiReactorBase<Request, Response>::OnDone(\n}\ntemplate <class Request, class Response>\n-std::shared_ptr<ReactorUtility>\n+std::shared_ptr<ReactorStatusHolder>\nClientBidiReactorBase<Request, Response>::getUtility() {\nreturn this->utility;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/backup/src/Reactors/client/base-reactors/ClientReadReactorBase.h", "new_path": "services/backup/src/Reactors/client/base-reactors/ClientReadReactorBase.h", "diff": "@@ -11,7 +11,7 @@ namespace reactor {\ntemplate <class Request, class Response>\nclass ClientReadReactorBase : public grpc::ClientReadReactor<Response>,\npublic BaseReactor {\n- std::shared_ptr<ReactorUtility> utility;\n+ std::shared_ptr<ReactorStatusHolder> utility;\nResponse response;\npublic:\n@@ -27,7 +27,7 @@ public:\nvoid OnReadDone(bool ok) override;\nvoid terminate(const grpc::Status &status) override;\nvoid OnDone(const grpc::Status &status) override;\n- std::shared_ptr<ReactorUtility> getUtility() override;\n+ std::shared_ptr<ReactorStatusHolder> getUtility() override;\nvirtual std::unique_ptr<grpc::Status> readResponse(Response &response) = 0;\n};\n@@ -97,7 +97,7 @@ void ClientReadReactorBase<Request, Response>::OnDone(\n}\ntemplate <class Request, class Response>\n-std::shared_ptr<ReactorUtility>\n+std::shared_ptr<ReactorStatusHolder>\nClientReadReactorBase<Request, Response>::getUtility() {\nreturn this->utility;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/backup/src/Reactors/client/base-reactors/ClientWriteReactorBase.h", "new_path": "services/backup/src/Reactors/client/base-reactors/ClientWriteReactorBase.h", "diff": "@@ -11,7 +11,7 @@ namespace reactor {\ntemplate <class Request, class Response>\nclass ClientWriteReactorBase : public grpc::ClientWriteReactor<Request>,\npublic BaseReactor {\n- std::shared_ptr<ReactorUtility> utility;\n+ std::shared_ptr<ReactorStatusHolder> utility;\nRequest request;\nvoid nextWrite();\n@@ -29,7 +29,7 @@ public:\nvoid OnWriteDone(bool ok) override;\nvoid terminate(const grpc::Status &status) override;\nvoid OnDone(const grpc::Status &status) override;\n- std::shared_ptr<ReactorUtility> getUtility() override;\n+ std::shared_ptr<ReactorStatusHolder> getUtility() override;\nvirtual std::unique_ptr<grpc::Status> prepareRequest(Request &request) = 0;\n};\n@@ -104,7 +104,7 @@ void ClientWriteReactorBase<Request, Response>::OnDone(\n}\ntemplate <class Request, class Response>\n-std::shared_ptr<ReactorUtility>\n+std::shared_ptr<ReactorStatusHolder>\nClientWriteReactorBase<Request, Response>::getUtility() {\nreturn this->utility;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/backup/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "new_path": "services/backup/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "diff": "@@ -26,7 +26,7 @@ struct ServerBidiReactorStatus {\ntemplate <class Request, class Response>\nclass ServerBidiReactorBase : public grpc::ServerBidiReactor<Request, Response>,\npublic BaseReactor {\n- std::shared_ptr<ReactorUtility> utility;\n+ std::shared_ptr<ReactorStatusHolder> utility;\nRequest request;\nResponse response;\n@@ -45,7 +45,7 @@ public:\nvoid OnDone() override;\nvoid OnReadDone(bool ok) override;\nvoid OnWriteDone(bool ok) override;\n- std::shared_ptr<ReactorUtility> getUtility() override;\n+ std::shared_ptr<ReactorStatusHolder> getUtility() override;\nvoid terminate(ServerBidiReactorStatus status);\nServerBidiReactorStatus getStatus() const;\n@@ -147,7 +147,7 @@ void ServerBidiReactorBase<Request, Response>::OnWriteDone(bool ok) {\n}\ntemplate <class Request, class Response>\n-std::shared_ptr<ReactorUtility>\n+std::shared_ptr<ReactorStatusHolder>\nServerBidiReactorBase<Request, Response>::getUtility() {\nreturn this->utility;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/backup/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "new_path": "services/backup/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "diff": "@@ -16,7 +16,7 @@ namespace reactor {\ntemplate <class Request, class Response>\nclass ServerReadReactorBase : public grpc::ServerReadReactor<Request>,\npublic BaseReactor {\n- std::shared_ptr<ReactorUtility> utility;\n+ std::shared_ptr<ReactorStatusHolder> utility;\nRequest request;\nprotected:\n@@ -32,7 +32,7 @@ public:\nvoid OnReadDone(bool ok) override;\nvoid terminate(const grpc::Status &status) override;\nvoid OnDone() override;\n- std::shared_ptr<ReactorUtility> getUtility() override;\n+ std::shared_ptr<ReactorStatusHolder> getUtility() override;\nvirtual std::unique_ptr<grpc::Status> readRequest(Request request) = 0;\n};\n@@ -99,7 +99,7 @@ void ServerReadReactorBase<Request, Response>::OnDone() {\n}\ntemplate <class Request, class Response>\n-std::shared_ptr<ReactorUtility>\n+std::shared_ptr<ReactorStatusHolder>\nServerReadReactorBase<Request, Response>::getUtility() {\nreturn this->utility;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/backup/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "new_path": "services/backup/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "diff": "@@ -16,7 +16,7 @@ namespace reactor {\ntemplate <class Request, class Response>\nclass ServerWriteReactorBase : public grpc::ServerWriteReactor<Response>,\npublic BaseReactor {\n- std::shared_ptr<ReactorUtility> utility;\n+ std::shared_ptr<ReactorStatusHolder> utility;\nResponse response;\nbool initialized = false;\n@@ -39,7 +39,7 @@ public:\nvoid OnWriteDone(bool ok) override;\nvoid terminate(const grpc::Status &status);\nvoid OnDone() override;\n- std::shared_ptr<ReactorUtility> getUtility() override;\n+ std::shared_ptr<ReactorStatusHolder> getUtility() override;\nvirtual std::unique_ptr<grpc::Status> writeResponse(Response *response) = 0;\n};\n@@ -112,7 +112,7 @@ void ServerWriteReactorBase<Request, Response>::OnDone() {\n}\ntemplate <class Request, class Response>\n-std::shared_ptr<ReactorUtility>\n+std::shared_ptr<ReactorStatusHolder>\nServerWriteReactorBase<Request, Response>::getUtility() {\nreturn this->utility;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/BaseReactor.h", "new_path": "services/blob/src/Reactors/BaseReactor.h", "diff": "#pragma once\n-#include \"ReactorUtility.h\"\n+#include \"ReactorStatusHolder.h\"\n#include <grpcpp/grpcpp.h>\n@@ -12,7 +12,7 @@ namespace reactor {\nclass BaseReactor {\npublic:\n- virtual std::shared_ptr<ReactorUtility> getUtility() = 0;\n+ virtual std::shared_ptr<ReactorStatusHolder> getUtility() = 0;\nvirtual void terminate(const grpc::Status &status) = 0;\nvirtual void validate() = 0;\nvirtual void doneCallback() = 0;\n" }, { "change_type": "RENAME", "old_path": "services/blob/src/Reactors/ReactorUtility.h", "new_path": "services/blob/src/Reactors/ReactorStatusHolder.h", "diff": "@@ -16,7 +16,7 @@ enum class ReactorState {\nDONE = 3,\n};\n-class ReactorUtility {\n+class ReactorStatusHolder {\nprivate:\ngrpc::Status status = grpc::Status::OK;\nstd::mutex statusAccessMutex;\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerBidiReactorBase.h", "diff": "@@ -26,7 +26,7 @@ struct ServerBidiReactorStatus {\ntemplate <class Request, class Response>\nclass ServerBidiReactorBase : public grpc::ServerBidiReactor<Request, Response>,\npublic BaseReactor {\n- std::shared_ptr<ReactorUtility> utility;\n+ std::shared_ptr<ReactorStatusHolder> utility;\nRequest request;\nResponse response;\n@@ -45,7 +45,7 @@ public:\nvoid OnDone() override;\nvoid OnReadDone(bool ok) override;\nvoid OnWriteDone(bool ok) override;\n- std::shared_ptr<ReactorUtility> getUtility() override;\n+ std::shared_ptr<ReactorStatusHolder> getUtility() override;\nvoid terminate(ServerBidiReactorStatus status);\nServerBidiReactorStatus getStatus() const;\n@@ -147,7 +147,7 @@ void ServerBidiReactorBase<Request, Response>::OnWriteDone(bool ok) {\n}\ntemplate <class Request, class Response>\n-std::shared_ptr<ReactorUtility>\n+std::shared_ptr<ReactorStatusHolder>\nServerBidiReactorBase<Request, Response>::getUtility() {\nreturn this->utility;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerReadReactorBase.h", "diff": "@@ -16,7 +16,7 @@ namespace reactor {\ntemplate <class Request, class Response>\nclass ServerReadReactorBase : public grpc::ServerReadReactor<Request>,\npublic BaseReactor {\n- std::shared_ptr<ReactorUtility> utility;\n+ std::shared_ptr<ReactorStatusHolder> utility;\nRequest request;\nprotected:\n@@ -32,7 +32,7 @@ public:\nvoid OnReadDone(bool ok) override;\nvoid terminate(const grpc::Status &status) override;\nvoid OnDone() override;\n- std::shared_ptr<ReactorUtility> getUtility() override;\n+ std::shared_ptr<ReactorStatusHolder> getUtility() override;\nvirtual std::unique_ptr<grpc::Status> readRequest(Request request) = 0;\n};\n@@ -99,7 +99,7 @@ void ServerReadReactorBase<Request, Response>::OnDone() {\n}\ntemplate <class Request, class Response>\n-std::shared_ptr<ReactorUtility>\n+std::shared_ptr<ReactorStatusHolder>\nServerReadReactorBase<Request, Response>::getUtility() {\nreturn this->utility;\n}\n" }, { "change_type": "MODIFY", "old_path": "services/blob/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "new_path": "services/blob/src/Reactors/server/base-reactors/ServerWriteReactorBase.h", "diff": "@@ -16,7 +16,7 @@ namespace reactor {\ntemplate <class Request, class Response>\nclass ServerWriteReactorBase : public grpc::ServerWriteReactor<Response>,\npublic BaseReactor {\n- std::shared_ptr<ReactorUtility> utility;\n+ std::shared_ptr<ReactorStatusHolder> utility;\nResponse response;\nbool initialized = false;\n@@ -39,7 +39,7 @@ public:\nvoid OnWriteDone(bool ok) override;\nvoid terminate(const grpc::Status &status);\nvoid OnDone() override;\n- std::shared_ptr<ReactorUtility> getUtility() override;\n+ std::shared_ptr<ReactorStatusHolder> getUtility() override;\nvirtual std::unique_ptr<grpc::Status> writeResponse(Response *response) = 0;\n};\n@@ -112,7 +112,7 @@ void ServerWriteReactorBase<Request, Response>::OnDone() {\n}\ntemplate <class Request, class Response>\n-std::shared_ptr<ReactorUtility>\n+std::shared_ptr<ReactorStatusHolder>\nServerWriteReactorBase<Request, Response>::getUtility() {\nreturn this->utility;\n}\n" }, { "change_type": "ADD", "old_path": null, "new_path": "services/lib/lib_src/BaseReactor.h", "diff": "+#pragma once\n+\n+#include \"ReactorStatusHolder.h\"\n+\n+#include <grpcpp/grpcpp.h>\n+\n+#include <memory>\n+\n+namespace comm {\n+namespace network {\n+namespace reactor {\n+\n+class BaseReactor {\n+public:\n+ virtual std::shared_ptr<ReactorStatusHolder> getUtility() = 0;\n+ virtual void terminate(const grpc::Status &status) = 0;\n+ virtual void validate() = 0;\n+ virtual void doneCallback() = 0;\n+ virtual void terminateCallback() = 0;\n+};\n+\n+} // namespace reactor\n+} // namespace network\n+} // namespace comm\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Rename Reactor Utility Summary: https://linear.app/comm/issue/ENG-1086/discuss-the-structure-of-reactor-utility Renaming `ReactorUtility` -> `ReactorStatusHolder` Test Plan: services should still build ``` cd services yarn test-blob-service yarn test-backup-service ``` Reviewers: ashoat Reviewed By: ashoat Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D3931
129,184
05.05.2022 09:23:55
14,400
8951a8faa85ecafda325635d342cd736577122de
[web] Remove unnecessary `form_footer` div and corresponding styles Summary: There's no need for this div. We can achieve the same thing with just the `modal_form_error` div. Test Plan: Looks as expected: {F50800} Reviewers: ashoat, palys-swm Subscribers: Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/modals/threads/thread-settings-modal.css", "new_path": "web/modals/threads/thread-settings-modal.css", "diff": "@@ -11,16 +11,13 @@ div.modal_body p {\nfont-size: 14px;\ntext-align: center;\n}\n-div.modal_body div.form_footer {\n+div.modal_form_error {\ndisplay: flex;\n- padding-top: 8px;\n-}\n-div.modal_body div.form_footer div.modal_form_error {\n- font-size: 12px;\n+ justify-content: center;\n+ padding-top: 16px;\n+ font-size: 16px;\ncolor: red;\nfont-style: italic;\n- padding-left: 6px;\n- align-self: center;\n}\nul.tab_panel {\n" }, { "change_type": "MODIFY", "old_path": "web/modals/threads/thread-settings-modal.react.js", "new_path": "web/modals/threads/thread-settings-modal.react.js", "diff": "@@ -168,9 +168,7 @@ const ConnectedThreadSettingsModal: React.ComponentType<BaseProps> = React.memo<\n>\n{tabs}\n</Tabs.Container>\n- <div className={css.form_footer}>\n<div className={css.modal_form_error}>{errorMessage}</div>\n- </div>\n</form>\n</div>\n</Modal>\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Remove unnecessary `form_footer` div and corresponding styles Summary: There's no need for this div. We can achieve the same thing with just the `modal_form_error` div. Test Plan: Looks as expected: {F50800} Reviewers: ashoat, palys-swm Reviewed By: ashoat Subscribers: Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3926
129,184
05.05.2022 09:30:49
14,400
b626b982eeffb603aecc36a4e40121b7b6aace3c
[web] Add gear icon to `ThreadSettingsModal` header Summary: Added the gear icon to the header, why not Test Plan: Looks as expected: {F50811} Reviewers: palys-swm, ashoat Subscribers: Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/modals/threads/thread-settings-modal.react.js", "new_path": "web/modals/threads/thread-settings-modal.react.js", "diff": "@@ -159,7 +159,11 @@ const ConnectedThreadSettingsModal: React.ComponentType<BaseProps> = React.memo<\n}\nreturn (\n- <Modal name=\"Thread settings\" onClose={modalContext.popModal}>\n+ <Modal\n+ name=\"Thread settings\"\n+ onClose={modalContext.popModal}\n+ icon=\"settings\"\n+ >\n<div className={css.modal_body}>\n<form method=\"POST\">\n<Tabs.Container\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Add gear icon to `ThreadSettingsModal` header Summary: Added the gear icon to the header, why not Test Plan: Looks as expected: {F50811} Reviewers: palys-swm, ashoat Reviewed By: ashoat Subscribers: Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3927
129,184
05.05.2022 09:38:28
14,400
cb2b044b0ed62bd7a68397b536d0a13a0bfe93b3
[web] Push `<form>` tag down from `ThreadSettingsModal` to child "Tab" components Summary: Addresses feedback from in a previous stack. Makes `ThreadSettingsModal` cleaner. Test Plan: Things continue to look/work as expected: {F50949} Reviewers: ashoat, palys-swm Subscribers: Adrian, karol-bisztyga, yayabosh, palys-swm
[ { "change_type": "MODIFY", "old_path": "web/modals/threads/thread-settings-delete-tab.react.js", "new_path": "web/modals/threads/thread-settings-delete-tab.react.js", "diff": "@@ -76,7 +76,7 @@ function ThreadSettingsDeleteTab(\n);\nreturn (\n- <>\n+ <form method=\"POST\">\n<div>\n<p className={css.italic}>\nYour thread will be permanently deleted. There is no way to reverse\n@@ -102,7 +102,7 @@ function ThreadSettingsDeleteTab(\n<Button onClick={onDelete} variant=\"danger\" disabled={inputDisabled}>\nDelete\n</Button>\n- </>\n+ </form>\n);\n}\n" }, { "change_type": "MODIFY", "old_path": "web/modals/threads/thread-settings-general-tab.react.js", "new_path": "web/modals/threads/thread-settings-general-tab.react.js", "diff": "@@ -130,7 +130,7 @@ function ThreadSettingsGeneralTab(\n);\nreturn (\n- <div>\n+ <form method=\"POST\">\n<div>\n<div className={css.form_title}>Thread name</div>\n<div className={css.form_content}>\n@@ -170,7 +170,7 @@ function ThreadSettingsGeneralTab(\n>\nSave\n</Button>\n- </div>\n+ </form>\n);\n}\n" }, { "change_type": "MODIFY", "old_path": "web/modals/threads/thread-settings-modal.react.js", "new_path": "web/modals/threads/thread-settings-modal.react.js", "diff": "@@ -165,15 +165,10 @@ const ConnectedThreadSettingsModal: React.ComponentType<BaseProps> = React.memo<\nicon=\"settings\"\n>\n<div className={css.modal_body}>\n- <form method=\"POST\">\n- <Tabs.Container\n- activeTab={currentTabType}\n- setTab={setCurrentTabType}\n- >\n+ <Tabs.Container activeTab={currentTabType} setTab={setCurrentTabType}>\n{tabs}\n</Tabs.Container>\n<div className={css.modal_form_error}>{errorMessage}</div>\n- </form>\n</div>\n</Modal>\n);\n" }, { "change_type": "MODIFY", "old_path": "web/modals/threads/thread-settings-privacy-tab.react.js", "new_path": "web/modals/threads/thread-settings-privacy-tab.react.js", "diff": "@@ -99,6 +99,7 @@ function ThreadSettingsPrivacyTab(\n);\nreturn (\n+ <form method=\"POST\">\n<div className={css.edit_thread_privacy_container}>\n<div className={css['modal-radio-selector']}>\n<div className={css.form_title}>Thread type</div>\n@@ -158,6 +159,7 @@ function ThreadSettingsPrivacyTab(\nSave\n</Button>\n</div>\n+ </form>\n);\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Push `<form>` tag down from `ThreadSettingsModal` to child "Tab" components Summary: Addresses feedback from @palys-swm in a previous stack. Makes `ThreadSettingsModal` cleaner. Test Plan: Things continue to look/work as expected: {F50949} Reviewers: ashoat, palys-swm Reviewed By: ashoat Subscribers: Adrian, karol-bisztyga, yayabosh, palys-swm Differential Revision: https://phabricator.ashoat.com/D3928
129,179
05.05.2022 12:40:59
14,400
ea7b3df152a7f3a0f4a7e5e122b6c409cd63ae4d
[chore] bump husky package Summary: yarn upgrade-interactive, chose husky. minor bug fixes in the github tag notes Test Plan: make sure husky is still working. Reviewers: atul, ashoat Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "yarn.lock", "new_path": "yarn.lock", "diff": "@@ -8982,9 +8982,9 @@ human-signals@^2.1.0:\nintegrity sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==\nhusky@^7.0.0:\n- version \"7.0.0\"\n- resolved \"https://registry.yarnpkg.com/husky/-/husky-7.0.0.tgz#3dbd5d28e76234689ee29bb41e048f28e3e46616\"\n- integrity sha512-xK7lO0EtSzfFPiw+oQncQVy/XqV7UVVjxBByc+Iv5iK3yhW9boDoWgvZy3OGo48QKg/hUtZkzz0hi2HXa0kn7w==\n+ version \"7.0.4\"\n+ resolved \"https://registry.yarnpkg.com/husky/-/husky-7.0.4.tgz#242048245dc49c8fb1bf0cc7cfb98dd722531535\"\n+ integrity sha512-vbaCKN2QLtP/vD4yvs6iz6hBEo6wkSzs8HpRah1Z6aGmF2KW5PdYuAd7uX5a+OyBZHBhd+TFLqgjUgytQr4RvQ==\nhyphenate-style-name@^1.0.3:\nversion \"1.0.4\"\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[chore] bump husky package Summary: yarn upgrade-interactive, chose husky. minor bug fixes in the github tag notes Test Plan: make sure husky is still working. Reviewers: atul, ashoat Reviewed By: atul, ashoat Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3922
129,179
05.05.2022 14:33:28
14,400
10c75023f54353c4f2f1d03a842dd36cb2d82aa1
[chore][landing] bump fortawesome package Summary: bumped icon package using yarn upgrade-interactive Test Plan: cleaninstalled, ran landing and checked all components using the fortawesome package. Everything still worked as expected Reviewers: atul Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh
[ { "change_type": "MODIFY", "old_path": "yarn.lock", "new_path": "yarn.lock", "diff": "resolved \"https://registry.yarnpkg.com/@fortawesome/fontawesome-common-types/-/fontawesome-common-types-0.2.36.tgz#b44e52db3b6b20523e0c57ef8c42d315532cb903\"\nintegrity sha512-a/7BiSgobHAgBWeN7N0w+lAhInrGxksn13uK7231n2m8EDPE3BMCl9NZLTGrj9ZXfCmC6LM0QLqXidIizVQ6yg==\n+\"@fortawesome/fontawesome-common-types@^0.3.0\":\n+ version \"0.3.0\"\n+ resolved \"https://registry.yarnpkg.com/@fortawesome/fontawesome-common-types/-/fontawesome-common-types-0.3.0.tgz#949995a05c0d8801be7e0a594f775f1dbaa0d893\"\n+ integrity sha512-CA3MAZBTxVsF6SkfkHXDerkhcQs0QPofy43eFdbWJJkZiq3SfiaH1msOkac59rQaqto5EqWnASboY1dBuKen5w==\n+\n\"@fortawesome/fontawesome-svg-core@^1.2.25\":\n- version \"1.2.25\"\n- resolved \"https://registry.yarnpkg.com/@fortawesome/fontawesome-svg-core/-/fontawesome-svg-core-1.2.25.tgz#24b03391d14f0c6171e8cad7057c687b74049790\"\n- integrity sha512-MotKnn53JKqbkLQiwcZSBJVYtTgIKFbh7B8+kd05TSnfKYPFmjKKI59o2fpz5t0Hzl35vVGU6+N4twoOpZUrqA==\n+ version \"1.3.0\"\n+ resolved \"https://registry.yarnpkg.com/@fortawesome/fontawesome-svg-core/-/fontawesome-svg-core-1.3.0.tgz#343fac91fa87daa630d26420bfedfba560f85885\"\n+ integrity sha512-UIL6crBWhjTNQcONt96ExjUnKt1D68foe3xjEensLDclqQ6YagwCRYVQdrp/hW0ALRp/5Fv/VKw+MqTUWYYvPg==\ndependencies:\n- \"@fortawesome/fontawesome-common-types\" \"^0.2.25\"\n+ \"@fortawesome/fontawesome-common-types\" \"^0.3.0\"\n\"@fortawesome/free-brands-svg-icons@^5.15.4\":\nversion \"5.15.4\"\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[chore][landing] bump fortawesome package Summary: bumped icon package using yarn upgrade-interactive Test Plan: cleaninstalled, ran landing and checked all components using the fortawesome package. Everything still worked as expected Reviewers: atul Reviewed By: atul Subscribers: ashoat, palys-swm, Adrian, karol-bisztyga, yayabosh Differential Revision: https://phabricator.ashoat.com/D3936
129,190
11.04.2022 15:39:43
-7,200
ac99b83189cf0357882c10d92d9b2aa99755f2dc
[services] Dev mode - Fix Backup service Summary: Fix dev mode in backup service. Until now it seems like it was broken. Test Plan: ``` docker-compose down yarn test-blob-service-dev-mode yarn test-backup-service-dev-mode ``` Reviewers: jimpo, palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/backup/src/DatabaseManager.h", "new_path": "services/backup/src/DatabaseManager.h", "diff": "#include <memory>\n#include <string>\n-#ifdef COMM_SERVICES_DEV_MODE\n-#include \"DatabaseSimulator.h\"\n-#endif\n-\nnamespace comm {\nnamespace network {\nnamespace database {\n// this class should be thread-safe in case any shared resources appear\nclass DatabaseManager {\n-#ifdef COMM_SERVICES_DEV_MODE\n- DatabaseSimulator dbSimulator;\n-#endif\n-\nvoid innerPutItem(\nstd::shared_ptr<Item> item,\nconst Aws::DynamoDB::Model::PutItemRequest &request);\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Dev mode - Fix Backup service Summary: Fix dev mode in backup service. Until now it seems like it was broken. Test Plan: ``` docker-compose down yarn test-blob-service-dev-mode yarn test-backup-service-dev-mode ``` Reviewers: jimpo, palys-swm Reviewed By: jimpo, palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3695
129,190
11.04.2022 15:39:46
-7,200
916fd9cdf7709b95c10d83f2546346acd643f0ca
[services] Dev mode - Add localstack to docker compose Summary: Depends on D3695 Adding localstack configuration to the `docker-compose.yml` file. Test Plan: ``` cd services docker-compose down && docker-compose up localstack ``` Reviewers: palys-swm, jimpo, ashoat Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/docker-compose.yml", "new_path": "services/docker-compose.yml", "diff": "@@ -2,6 +2,8 @@ version: \"3.9\"\nnetworks:\nservices-net:\nname: services-net\n+volumes:\n+ localstack:\nservices:\n# tunnelbroker\ntunnelbroker-server:\n@@ -61,3 +63,18 @@ services:\ncontainer_name: identity-server\nports:\n- \"${COMM_SERVICES_PORT_IDENTITY}:50051\"\n+ # localstack\n+ localstack:\n+ image: localstack/localstack\n+ container_name: localstack\n+ hostname: localstack\n+ ports:\n+ - \"4566:4566\"\n+ environment:\n+ - SERVICES=s3,dynamodb\n+ - DATA_DIR=/tmp/localstack\n+ - HOSTNAME_EXTERNAL=localstack\n+ volumes:\n+ - localstack:/tmp/localstack\n+ networks:\n+ - services-net\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Dev mode - Add localstack to docker compose Summary: Depends on D3695 Adding localstack configuration to the `docker-compose.yml` file. Test Plan: ``` cd services docker-compose down && docker-compose up localstack ``` Reviewers: palys-swm, jimpo, ashoat Reviewed By: jimpo, ashoat Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3692
129,190
11.04.2022 15:39:48
-7,200
474b3296954bb6f1010dce88f12d7d002474b896
[services] Dev mode - Add terraform Summary: Depends on D3692 Adding terraform configurations for the S3 and Dynamo DB. Test Plan: ``` cd services/terraform ./run.sh ``` Reviewers: palys-swm, jimpo, ashoat Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh
[ { "change_type": "ADD", "old_path": null, "new_path": "services/terraform/.gitignore", "diff": "+# Local .terraform directories\n+**/.terraform/*\n+\n+# .tfstate files\n+*.tfstate\n+*.tfstate.*\n+\n+# Crash log files\n+crash.log\n+crash.*.log\n+\n+# Exclude all .tfvars files, which are likely to contain sensitive data, such as\n+# password, private keys, and other secrets. These should not be part of version\n+# control as they are data points which are potentially sensitive and subject\n+# to change depending on the environment.\n+*.tfvars\n+*.tfvars.json\n+\n+# Ignore override files as they are usually used to override resources locally and so\n+# are not checked in\n+override.tf\n+override.tf.json\n+*_override.tf\n+*_override.tf.json\n+\n+# Include override files you do wish to add to version control using negated pattern\n+# !example_override.tf\n+\n+# Include tfplan files to ignore the plan output of command: terraform plan -out=tfplan\n+# example: *tfplan*\n+\n+# Ignore CLI configuration files\n+.terraformrc\n+terraform.rc\n" }, { "change_type": "ADD", "old_path": null, "new_path": "services/terraform/.terraform.lock.hcl", "diff": "+# This file is maintained automatically by \"terraform init\".\n+# Manual edits may be lost in future updates.\n+\n+provider \"registry.terraform.io/hashicorp/aws\" {\n+ version = \"4.9.0\"\n+ constraints = \"~> 4.9.0\"\n+ hashes = [\n+ \"h1:OWIIlbMZl/iQ8qR1U7Co3sGjNHL1HJtgNRnnV1kXNuI=\",\n+ \"zh:084b83aef3335ad4f5e4b8323c6fe43c1ff55e17a7647c6a5cad6af519f72b42\",\n+ \"zh:132e47ce69f14de4523b84b213cedf7173398acda14245b1ffe7747aac50f050\",\n+ \"zh:2068baef7dfce3613f3b4f27314175e971f8db68d9cde9ec30b5659f80c68c6c\",\n+ \"zh:63c6f489683d5f1ac55e82a0df387143ed22701d5f22c109a4d5c9924dd4e437\",\n+ \"zh:8115fd21965954fa4568c09331e05bb29da967fab8d077419aed09954378e216\",\n+ \"zh:8efdc95fde108f777ed9c79ae25dc17aea9771903250f5c5c8a4c726b90a345f\",\n+ \"zh:9b12af85486a96aedd8d7984b0ff811a4b42e3d88dad1a3fb4c0b580d04fa425\",\n+ \"zh:9d42a7bc34d84b70c1d1bcc215cabd63abbcbd0352b70bd84da6c3916634932f\",\n+ \"zh:aacbcceb241aa475888c0869e87593182edeced3170c76a0c960dd9c905df449\",\n+ \"zh:c7fe7904511052e4102870256819a1917177572cf684f0611ebf767f9c1fbaa8\",\n+ \"zh:c8e07c3424663d1d0e7e32f4ade8099c19f6326d37c6da98104d90c986ff66fc\",\n+ \"zh:e47cafbd38b56ef14fd8d727b4ffea847c166b1c684f585ee5fb78983b537248\",\n+ ]\n+}\n" }, { "change_type": "ADD", "old_path": null, "new_path": "services/terraform/dynamodb-test.tf", "diff": "+resource \"aws_dynamodb_table\" \"backup-service-backup-test\" {\n+ name = \"backup-service-backup-test\"\n+ hash_key = \"userID\"\n+ range_key = \"backupID\"\n+ write_capacity = 10\n+ read_capacity = 10\n+\n+ attribute {\n+ name = \"userID\"\n+ type = \"S\"\n+ }\n+\n+ attribute {\n+ name = \"backupID\"\n+ type = \"S\"\n+ }\n+\n+ attribute {\n+ name = \"created\"\n+ type = \"S\"\n+ }\n+\n+ global_secondary_index {\n+ name = \"userID-created-index\"\n+ hash_key = \"userID\"\n+ range_key = \"created\"\n+ write_capacity = 10\n+ read_capacity = 10\n+ projection_type = \"INCLUDE\"\n+ non_key_attributes = [\"recoveryData\"]\n+ }\n+}\n+\n+resource \"aws_dynamodb_table\" \"backup-service-log-test\" {\n+ name = \"backup-service-log-test\"\n+ hash_key = \"backupID\"\n+ range_key = \"logID\"\n+ write_capacity = 10\n+ read_capacity = 10\n+\n+ attribute {\n+ name = \"backupID\"\n+ type = \"S\"\n+ }\n+\n+ attribute {\n+ name = \"logID\"\n+ type = \"S\"\n+ }\n+}\n+\n+resource \"aws_dynamodb_table\" \"blob-service-blob-test\" {\n+ name = \"blob-service-blob-test\"\n+ hash_key = \"blobHash\"\n+ write_capacity = 10\n+ read_capacity = 10\n+\n+ attribute {\n+ name = \"blobHash\"\n+ type = \"S\"\n+ }\n+}\n+\n+resource \"aws_dynamodb_table\" \"blob-service-reverse-index-test\" {\n+ name = \"blob-service-reverse-index-test\"\n+ hash_key = \"holder\"\n+ write_capacity = 10\n+ read_capacity = 10\n+\n+ attribute {\n+ name = \"holder\"\n+ type = \"S\"\n+ }\n+\n+ attribute {\n+ name = \"blobHash\"\n+ type = \"S\"\n+ }\n+\n+ global_secondary_index {\n+ name = \"blobHash-index\"\n+ hash_key = \"blobHash\"\n+ write_capacity = 10\n+ read_capacity = 10\n+ projection_type = \"ALL\"\n+ }\n+}\n" }, { "change_type": "ADD", "old_path": null, "new_path": "services/terraform/dynamodb.tf", "diff": "+resource \"aws_dynamodb_table\" \"backup-service-backup\" {\n+ name = \"backup-service-backup\"\n+ hash_key = \"userID\"\n+ range_key = \"backupID\"\n+ write_capacity = 10\n+ read_capacity = 10\n+\n+ attribute {\n+ name = \"userID\"\n+ type = \"S\"\n+ }\n+\n+ attribute {\n+ name = \"backupID\"\n+ type = \"S\"\n+ }\n+\n+ attribute {\n+ name = \"created\"\n+ type = \"S\"\n+ }\n+\n+ global_secondary_index {\n+ name = \"userID-created-index\"\n+ hash_key = \"userID\"\n+ range_key = \"created\"\n+ write_capacity = 10\n+ read_capacity = 10\n+ projection_type = \"INCLUDE\"\n+ non_key_attributes = [\"recoveryData\"]\n+ }\n+}\n+\n+resource \"aws_dynamodb_table\" \"backup-service-log\" {\n+ name = \"backup-service-log\"\n+ hash_key = \"backupID\"\n+ range_key = \"logID\"\n+ write_capacity = 10\n+ read_capacity = 10\n+\n+ attribute {\n+ name = \"backupID\"\n+ type = \"S\"\n+ }\n+\n+ attribute {\n+ name = \"logID\"\n+ type = \"S\"\n+ }\n+}\n+\n+resource \"aws_dynamodb_table\" \"blob-service-blob\" {\n+ name = \"blob-service-blob\"\n+ hash_key = \"blobHash\"\n+ write_capacity = 10\n+ read_capacity = 10\n+\n+ attribute {\n+ name = \"blobHash\"\n+ type = \"S\"\n+ }\n+}\n+\n+resource \"aws_dynamodb_table\" \"blob-service-reverse-index\" {\n+ name = \"blob-service-reverse-index\"\n+ hash_key = \"holder\"\n+ write_capacity = 10\n+ read_capacity = 10\n+\n+ attribute {\n+ name = \"holder\"\n+ type = \"S\"\n+ }\n+\n+ attribute {\n+ name = \"blobHash\"\n+ type = \"S\"\n+ }\n+\n+ global_secondary_index {\n+ name = \"blobHash-index\"\n+ hash_key = \"blobHash\"\n+ write_capacity = 10\n+ read_capacity = 10\n+ projection_type = \"ALL\"\n+ }\n+}\n" }, { "change_type": "ADD", "old_path": null, "new_path": "services/terraform/localstack.tf", "diff": "+variable \"HOST\" {\n+ type = string\n+ default = \"http://localhost:4566\"\n+}\n+\n+// https://registry.terraform.io/providers/hashicorp/aws/latest/docs/guides/custom-service-endpoints#localstack\n+provider \"aws\" {\n+ region = \"us-east-2\"\n+ access_key = \"fake\"\n+ secret_key = \"fake\"\n+ skip_credentials_validation = true\n+ skip_metadata_api_check = true\n+ skip_requesting_account_id = true\n+ s3_use_path_style = true\n+\n+ endpoints {\n+ dynamodb = var.HOST\n+ s3 = var.HOST\n+ }\n+}\n" }, { "change_type": "ADD", "old_path": null, "new_path": "services/terraform/providers.tf", "diff": "+terraform {\n+ required_providers {\n+ aws = {\n+ source = \"hashicorp/aws\"\n+ version = \"~> 4.9.0\"\n+ }\n+ }\n+}\n" }, { "change_type": "ADD", "old_path": null, "new_path": "services/terraform/run.sh", "diff": "+#!/bin/bash\n+\n+set -e\n+\n+terraform init\n+\n+terraform apply -auto-approve\n" }, { "change_type": "ADD", "old_path": null, "new_path": "services/terraform/s3.tf", "diff": "+variable \"s3_bucket_names\" {\n+ type = list\n+ default = [\n+ \"commapp-blob\",\n+ ]\n+}\n+\n+resource \"aws_s3_bucket\" \"comm_buckets\" {\n+ count = length(var.s3_bucket_names)\n+ bucket = var.s3_bucket_names[count.index]\n+}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Dev mode - Add terraform Summary: Depends on D3692 Adding terraform configurations for the S3 and Dynamo DB. Test Plan: ``` cd services/terraform ./run.sh ``` Reviewers: palys-swm, jimpo, ashoat Reviewed By: palys-swm, jimpo, ashoat Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3693
129,190
11.04.2022 15:39:51
-7,200
48bddf139b7b4132f69c4fc7625f8560fb791003
[services] Dev mode - Add scripts for running local cloud Summary: Depends on D3693 Adding scripts so the local cloud can be easily launched. Test Plan: ``` cd services docker-compose down yarn run-local-cloud ``` Reviewers: palys-swm, jimpo Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/package.json", "new_path": "services/package.json", "diff": "\"run-all-services\": \"./scripts/run_all_services.sh\",\n\"test-all-services\": \"./scripts/test_all_services.sh\",\n\"test-all-services-dev-mode\": \"export COMM_SERVICES_DEV_MODE=1 && ./scripts/test_all_services.sh\",\n- \"run-all-services-dev-mode\": \"export COMM_SERVICES_DEV_MODE=1 && ./scripts/run_all_services.sh\"\n+ \"run-all-services-dev-mode\": \"export COMM_SERVICES_DEV_MODE=1 && ./scripts/run_all_services.sh\",\n+ \"run-local-cloud\": \"./scripts/run_local_cloud.sh\"\n}\n}\n" }, { "change_type": "ADD", "old_path": null, "new_path": "services/scripts/run_local_cloud.sh", "diff": "+#!/bin/bash\n+\n+set -e\n+\n+# use the commented-out command to force container recreation\n+# docker-compose up -d --force-recreate localstack\n+docker-compose up -d localstack\n+\n+pushd terraform\n+\n+./run.sh\n+\n+popd # terraform\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Dev mode - Add scripts for running local cloud Summary: Depends on D3693 Adding scripts so the local cloud can be easily launched. Test Plan: ``` cd services docker-compose down yarn run-local-cloud ``` Reviewers: palys-swm, jimpo Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, benschac, yayabosh Differential Revision: https://phabricator.ashoat.com/D3694
129,179
06.05.2022 15:48:11
14,400
7a4b2a0a726400766bce97e0eef428691e5bcb26
[native] [fix] fix hot reload compose component Summary: Test Plan: when editing compose component, it shouldn't move the developer back to inbox Reviewers: atul, palys-swm, def-au1t, yayabosh, ashoat Subscribers: ashoat, Adrian
[ { "change_type": "ADD", "old_path": null, "new_path": "native/chat/composed-message-constants.js", "diff": "+// @flow\n+\n+export const clusterEndHeight = 7;\n" }, { "change_type": "MODIFY", "old_path": "native/chat/composed-message.react.js", "new_path": "native/chat/composed-message.react.js", "diff": "@@ -13,6 +13,7 @@ import { type InputState, InputStateContext } from '../input/input-state';\nimport { type Colors, useColors } from '../themes/colors';\nimport type { ChatMessageInfoItemWithHeight } from '../types/chat-types';\nimport { type AnimatedStyleObj, AnimatedView } from '../types/styles';\n+import { clusterEndHeight } from './composed-message-constants';\nimport { useComposedMessageMaxWidth } from './composed-message-width';\nimport { FailedSend } from './failed-send.react';\nimport {\n@@ -29,8 +30,6 @@ import { useContentAndHeaderOpacity, useDeliveryIconOpacity } from './utils';\nconst { Node } = Animated;\n/* eslint-enable import/no-named-as-default-member */\n-const clusterEndHeight = 7;\n-\ntype SwipeOptions = 'reply' | 'sidebar' | 'both' | 'none';\ntype BaseProps = {\n...React.ElementConfig<typeof View>,\n@@ -221,4 +220,5 @@ const ConnectedComposedMessage: React.ComponentType<BaseProps> = React.memo<Base\n);\n},\n);\n-export { ConnectedComposedMessage as ComposedMessage, clusterEndHeight };\n+\n+export default ConnectedComposedMessage;\n" }, { "change_type": "MODIFY", "old_path": "native/chat/message-header.react.js", "new_path": "native/chat/message-header.react.js", "diff": "@@ -8,7 +8,7 @@ import { stringForUser } from 'lib/shared/user-utils';\nimport { SingleLine } from '../components/single-line.react';\nimport { useStyles } from '../themes/colors';\nimport type { ChatMessageInfoItemWithHeight } from '../types/chat-types';\n-import { clusterEndHeight } from './composed-message.react';\n+import { clusterEndHeight } from './composed-message-constants';\nimport type { DisplayType } from './timestamp.react';\nimport { Timestamp, timestampHeight } from './timestamp.react';\n" }, { "change_type": "MODIFY", "old_path": "native/chat/multimedia-message-utils.js", "new_path": "native/chat/multimedia-message-utils.js", "diff": "@@ -10,7 +10,7 @@ import type {\nChatMultimediaMessageInfoItem,\nMultimediaContentSizes,\n} from '../types/chat-types';\n-import { clusterEndHeight } from './composed-message.react';\n+import { clusterEndHeight } from './composed-message-constants';\nimport { failedSendHeight } from './failed-send.react';\nimport {\ninlineSidebarMarginBottom,\n" }, { "change_type": "MODIFY", "old_path": "native/chat/multimedia-message.react.js", "new_path": "native/chat/multimedia-message.react.js", "diff": "@@ -23,7 +23,7 @@ import {\nimport type { ChatMultimediaMessageInfoItem } from '../types/chat-types';\nimport { type VerticalBounds } from '../types/layout-types';\nimport type { LayoutCoordinates } from '../types/layout-types';\n-import { ComposedMessage } from './composed-message.react';\n+import ComposedMessage from './composed-message.react';\nimport { InnerMultimediaMessage } from './inner-multimedia-message.react';\nimport { multimediaMessageTooltipHeight } from './multimedia-message-tooltip-modal.react';\nimport {\n" }, { "change_type": "MODIFY", "old_path": "native/chat/text-message.react.js", "new_path": "native/chat/text-message.react.js", "diff": "@@ -21,7 +21,7 @@ import { TextMessageTooltipModalRouteName } from '../navigation/route-names';\nimport type { ChatTextMessageInfoItemWithHeight } from '../types/chat-types';\nimport type { VerticalBounds } from '../types/layout-types';\nimport type { ChatNavigationProp } from './chat.react';\n-import { ComposedMessage } from './composed-message.react';\n+import ComposedMessage from './composed-message.react';\nimport { InnerTextMessage } from './inner-text-message.react';\nimport textMessageSendFailed from './text-message-send-failed';\nimport { textMessageTooltipHeight } from './text-message-tooltip-modal.react';\n" }, { "change_type": "MODIFY", "old_path": "native/chat/utils.js", "new_path": "native/chat/utils.js", "diff": "@@ -26,7 +26,7 @@ import type {\nimport type { LayoutCoordinates, VerticalBounds } from '../types/layout-types';\nimport type { AnimatedViewStyle } from '../types/styles';\nimport { ChatContext, useHeightMeasurer } from './chat-context';\n-import { clusterEndHeight } from './composed-message.react';\n+import { clusterEndHeight } from './composed-message-constants';\nimport { failedSendHeight } from './failed-send.react';\nimport {\ninlineSidebarHeight,\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[native] [fix] [ENG-1099] fix hot reload compose component Summary: https://linear.app/comm/issue/ENG-1099/refactor-composed-message-component-to-fix-hot-reload Test Plan: when editing compose component, it shouldn't move the developer back to inbox Reviewers: atul, palys-swm, def-au1t, yayabosh, ashoat Reviewed By: ashoat Subscribers: ashoat, Adrian Differential Revision: https://phabricator.ashoat.com/D3963
129,184
09.05.2022 14:54:09
14,400
bd6e290b586a3dc1a39dbea9e8ca9888149bac1b
[native] `codeVersion` -> 131
[ { "change_type": "MODIFY", "old_path": "native/android/app/build.gradle", "new_path": "native/android/app/build.gradle", "diff": "@@ -434,8 +434,8 @@ android {\napplicationId 'app.comm.android'\nminSdkVersion rootProject.ext.minSdkVersion\ntargetSdkVersion rootProject.ext.targetSdkVersion\n- versionCode 130\n- versionName '1.0.130'\n+ versionCode 131\n+ versionName '1.0.131'\nmissingDimensionStrategy 'react-native-camera', 'general'\nmultiDexEnabled true\n}\n" }, { "change_type": "MODIFY", "old_path": "native/cpp/CommonCpp/NativeModules/CommCoreModule.h", "new_path": "native/cpp/CommonCpp/NativeModules/CommCoreModule.h", "diff": "@@ -13,7 +13,7 @@ namespace comm {\nnamespace jsi = facebook::jsi;\nclass CommCoreModule : public facebook::react::CommCoreModuleSchemaCxxSpecJSI {\n- const int codeVersion{130};\n+ const int codeVersion{131};\nstd::unique_ptr<WorkerThread> databaseThread;\nstd::unique_ptr<WorkerThread> cryptoThread;\n" }, { "change_type": "MODIFY", "old_path": "native/ios/Comm/Info.debug.plist", "new_path": "native/ios/Comm/Info.debug.plist", "diff": "<key>CFBundlePackageType</key>\n<string>APPL</string>\n<key>CFBundleShortVersionString</key>\n- <string>1.0.130</string>\n+ <string>1.0.131</string>\n<key>CFBundleSignature</key>\n<string>????</string>\n<key>CFBundleVersion</key>\n- <string>130</string>\n+ <string>131</string>\n<key>LSApplicationQueriesSchemes</key>\n<array>\n<string>org-appextension-feature-password-management</string>\n" }, { "change_type": "MODIFY", "old_path": "native/ios/Comm/Info.release.plist", "new_path": "native/ios/Comm/Info.release.plist", "diff": "<key>CFBundlePackageType</key>\n<string>APPL</string>\n<key>CFBundleShortVersionString</key>\n- <string>1.0.130</string>\n+ <string>1.0.131</string>\n<key>CFBundleSignature</key>\n<string>????</string>\n<key>CFBundleVersion</key>\n- <string>130</string>\n+ <string>131</string>\n<key>LSApplicationQueriesSchemes</key>\n<array>\n<string>org-appextension-feature-password-management</string>\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[native] `codeVersion` -> 131
129,184
09.05.2022 15:03:54
14,400
d5313f3b0b103715bc43bffadd3b41f1186e5a51
[native] `codeVersion` -> 132
[ { "change_type": "MODIFY", "old_path": "native/android/app/build.gradle", "new_path": "native/android/app/build.gradle", "diff": "@@ -434,8 +434,8 @@ android {\napplicationId 'app.comm.android'\nminSdkVersion rootProject.ext.minSdkVersion\ntargetSdkVersion rootProject.ext.targetSdkVersion\n- versionCode 131\n- versionName '1.0.131'\n+ versionCode 132\n+ versionName '1.0.132'\nmissingDimensionStrategy 'react-native-camera', 'general'\nmultiDexEnabled true\n}\n" }, { "change_type": "MODIFY", "old_path": "native/cpp/CommonCpp/NativeModules/CommCoreModule.h", "new_path": "native/cpp/CommonCpp/NativeModules/CommCoreModule.h", "diff": "@@ -13,7 +13,7 @@ namespace comm {\nnamespace jsi = facebook::jsi;\nclass CommCoreModule : public facebook::react::CommCoreModuleSchemaCxxSpecJSI {\n- const int codeVersion{131};\n+ const int codeVersion{132};\nstd::unique_ptr<WorkerThread> databaseThread;\nstd::unique_ptr<WorkerThread> cryptoThread;\n" }, { "change_type": "MODIFY", "old_path": "native/ios/Comm/Info.debug.plist", "new_path": "native/ios/Comm/Info.debug.plist", "diff": "<key>CFBundlePackageType</key>\n<string>APPL</string>\n<key>CFBundleShortVersionString</key>\n- <string>1.0.131</string>\n+ <string>1.0.132</string>\n<key>CFBundleSignature</key>\n<string>????</string>\n<key>CFBundleVersion</key>\n- <string>131</string>\n+ <string>132</string>\n<key>LSApplicationQueriesSchemes</key>\n<array>\n<string>org-appextension-feature-password-management</string>\n" }, { "change_type": "MODIFY", "old_path": "native/ios/Comm/Info.release.plist", "new_path": "native/ios/Comm/Info.release.plist", "diff": "<key>CFBundlePackageType</key>\n<string>APPL</string>\n<key>CFBundleShortVersionString</key>\n- <string>1.0.131</string>\n+ <string>1.0.132</string>\n<key>CFBundleSignature</key>\n<string>????</string>\n<key>CFBundleVersion</key>\n- <string>131</string>\n+ <string>132</string>\n<key>LSApplicationQueriesSchemes</key>\n<array>\n<string>org-appextension-feature-password-management</string>\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[native] `codeVersion` -> 132
129,187
09.05.2022 18:30:19
14,400
96a7a0a46e9aced94024e4a5bbc7e08d8c689987
[keyserver] Make all url.json files optional Summary: Now we won't crash due to a missing `url.json` file until we actually need it. Depends on D3977 Test Plan: Make sure I can still use the keyserver without `commapp_url.json` or `landing_url.json` Reviewers: atul, palys-swm Subscribers: Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "keyserver/src/creators/report-creator.js", "new_path": "keyserver/src/creators/report-creator.js", "diff": "@@ -27,7 +27,7 @@ import { fetchUsername } from '../fetchers/user-fetchers';\nimport { handleAsyncPromise } from '../responders/handlers';\nimport { createBotViewer } from '../session/bots';\nimport type { Viewer } from '../session/viewer';\n-import { getCommAppURLFacts } from '../utils/urls';\n+import { getAndAssertCommAppURLFacts } from '../utils/urls';\nimport createIDs from './id-creator';\nimport createMessages from './message-creator';\n@@ -144,7 +144,7 @@ function getSquadbotMessage(\nconst { platform, codeVersion } = platformDetails;\nconst platformString = codeVersion ? `${platform} v${codeVersion}` : platform;\nif (request.type === reportTypes.ERROR) {\n- const { baseDomain, basePath } = getCommAppURLFacts();\n+ const { baseDomain, basePath } = getAndAssertCommAppURLFacts();\nreturn (\n`${name} got an error :(\\n` +\n`using ${platformString}\\n` +\n" }, { "change_type": "MODIFY", "old_path": "keyserver/src/fetchers/upload-fetchers.js", "new_path": "keyserver/src/fetchers/upload-fetchers.js", "diff": "@@ -5,7 +5,7 @@ import { ServerError } from 'lib/utils/errors';\nimport { dbQuery, SQL } from '../database/database';\nimport type { Viewer } from '../session/viewer';\n-import { getCommAppURLFacts } from '../utils/urls';\n+import { getAndAssertCommAppURLFacts } from '../utils/urls';\ntype UploadInfo = {\ncontent: Buffer,\n@@ -75,7 +75,7 @@ async function getUploadSize(id: string, secret: string): Promise<number> {\n}\nfunction getUploadURL(id: string, secret: string): string {\n- const { baseDomain, basePath } = getCommAppURLFacts();\n+ const { baseDomain, basePath } = getAndAssertCommAppURLFacts();\nreturn `${baseDomain}${basePath}upload/${id}/${secret}`;\n}\n" }, { "change_type": "MODIFY", "old_path": "keyserver/src/keyserver.js", "new_path": "keyserver/src/keyserver.js", "diff": "@@ -41,8 +41,8 @@ import {\nawait prefetchAllURLFacts();\nconst squadCalBaseRoutePath = getSquadCalURLFacts()?.baseRoutePath;\n- const landingBaseRoutePath = getLandingURLFacts().baseRoutePath;\n- const commAppBaseRoutePath = getCommAppURLFacts().baseRoutePath;\n+ const landingBaseRoutePath = getLandingURLFacts()?.baseRoutePath;\n+ const commAppBaseRoutePath = getCommAppURLFacts()?.baseRoutePath;\nconst compiledFolderOptions =\nprocess.env.NODE_ENV === 'development'\n@@ -134,6 +134,7 @@ import {\n// and prevent commAppRouter and landingRouter from working correctly. So we\n// make sure that squadCalRouter goes last\n+ if (landingBaseRoutePath) {\nconst landingRouter = express.Router();\nlandingRouter.use('/images', express.static('images'));\nlandingRouter.use('/fonts', express.static('fonts'));\n@@ -145,10 +146,13 @@ import {\nlandingRouter.post('/subscribe_email', emailSubscriptionResponder);\nlandingRouter.get('*', landingHandler);\nserver.use(landingBaseRoutePath, landingRouter);\n+ }\n+ if (commAppBaseRoutePath) {\nconst commAppRouter = express.Router();\nsetupAppRouter(commAppRouter);\nserver.use(commAppBaseRoutePath, commAppRouter);\n+ }\nif (squadCalBaseRoutePath) {\nconst squadCalRouter = express.Router();\n" }, { "change_type": "MODIFY", "old_path": "keyserver/src/responders/landing-handler.js", "new_path": "keyserver/src/responders/landing-handler.js", "diff": "@@ -9,7 +9,10 @@ import { promisify } from 'util';\nimport { type LandingSSRProps } from '../landing/landing-ssr.react';\nimport { waitForStream } from '../utils/json-stream';\n-import { getLandingURLFacts, clientPathFromRouterPath } from '../utils/urls';\n+import {\n+ getAndAssertLandingURLFacts,\n+ clientPathFromRouterPath,\n+} from '../utils/urls';\nimport { getMessageForException } from './utils';\nasync function landingHandler(req: $Request, res: $Response) {\n@@ -91,8 +94,6 @@ async function getWebpackCompiledRootComponentForSSR() {\n}\n}\n-const urlFacts = getLandingURLFacts();\n-const { basePath } = urlFacts;\nconst { renderToNodeStream } = ReactDOMServer;\nasync function landingResponder(req: $Request, res: $Response) {\n@@ -105,6 +106,9 @@ async function landingResponder(req: $Request, res: $Response) {\n.map(url => `<link rel=\"stylesheet\" type=\"text/css\" href=\"${url}\" />`)\n.join('');\n+ const urlFacts = getAndAssertLandingURLFacts();\n+ const { basePath } = urlFacts;\n+\n// prettier-ignore\nres.write(html`\n<!DOCTYPE html>\n" }, { "change_type": "MODIFY", "old_path": "keyserver/src/utils/urls.js", "new_path": "keyserver/src/utils/urls.js", "diff": "@@ -46,8 +46,12 @@ function getSquadCalURLFacts(): ?AppURLFacts {\nreturn cachedURLFacts.get('squadcal');\n}\n-function getCommAppURLFacts(): AppURLFacts {\n- const urlFacts = cachedURLFacts.get('commapp');\n+function getCommAppURLFacts(): ?AppURLFacts {\n+ return cachedURLFacts.get('commapp');\n+}\n+\n+function getAndAssertCommAppURLFacts(): AppURLFacts {\n+ const urlFacts = getCommAppURLFacts();\ninvariant(urlFacts, 'keyserver/facts/commapp_url.json missing');\nreturn urlFacts;\n}\n@@ -64,8 +68,12 @@ function getAppURLFactsFromRequestURL(url: string): AppURLFacts {\ninvariant(false, 'request received but no URL facts are present');\n}\n-function getLandingURLFacts(): AppURLFacts {\n- const urlFacts = cachedURLFacts.get('landing');\n+function getLandingURLFacts(): ?AppURLFacts {\n+ return cachedURLFacts.get('landing');\n+}\n+\n+function getAndAssertLandingURLFacts(): AppURLFacts {\n+ const urlFacts = getLandingURLFacts();\ninvariant(urlFacts, 'keyserver/facts/landing_url.json missing');\nreturn urlFacts;\n}\n@@ -82,7 +90,9 @@ export {\nprefetchAllURLFacts,\ngetSquadCalURLFacts,\ngetCommAppURLFacts,\n+ getAndAssertCommAppURLFacts,\ngetLandingURLFacts,\n+ getAndAssertLandingURLFacts,\ngetAppURLFactsFromRequestURL,\nclientPathFromRouterPath,\n};\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[keyserver] Make all url.json files optional Summary: Now we won't crash due to a missing `url.json` file until we actually need it. Depends on D3977 Test Plan: Make sure I can still use the keyserver without `commapp_url.json` or `landing_url.json` Reviewers: atul, palys-swm Reviewed By: palys-swm Subscribers: Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D3978
129,190
10.05.2022 11:54:41
-7,200
723497a431f5635b1008e5f7ba536b2c0ae53fc4
[services] Blob - Delete dangling build_server.sh script Summary: Depends on D3970 I missed deleting this script back in D3906 Test Plan: The blob service should still build properly ``` cd services yarn run-blob-service ``` Reviewers: palys-swm, ashoat Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "DELETE", "old_path": "services/blob/docker/build_server.sh", "new_path": null, "diff": "-#!/bin/bash\n-\n-set -e\n-\n-# folly hack - https://github.com/facebook/folly/pull/1231\n-sed -i 's/#if __has_include(<demangle.h>)/#if __has_include(<Demangle.h>)/g' /usr/lib/folly/folly/detail/Demangle.h\n-\n-rm -rf lib\n-mkdir lib\n-pushd lib\n-ln -s /usr/lib/folly\n-ln -s /usr/lib/glog\n-ln -s /usr/lib/double-conversion\n-popd # lib\n-\n-rm -rf _generated\n-mkdir _generated\n-\n-rm -rf cmake/build\n-mkdir -p cmake/build\n-\n-scripts/proto_codegen.sh\n-scripts/build.sh\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Blob - Delete dangling build_server.sh script Summary: Depends on D3970 I missed deleting this script back in D3906 Test Plan: The blob service should still build properly ``` cd services yarn run-blob-service ``` Reviewers: palys-swm, ashoat Reviewed By: ashoat Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D3985
129,179
10.05.2022 12:45:01
14,400
027afc303a766c3119152701982584e7764be20e
[chore] [web] bump fortawesome in web directory Summary: bump packages in web folder Test Plan: open components like filter-panel.react that use the fortawesome icon package. run `yarn upgrade-interactive` select packages in web Reviewers: atul, palys-swm Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "yarn.lock", "new_path": "yarn.lock", "diff": "dependencies:\ntslib \"^2.1.0\"\n-\"@fortawesome/fontawesome-common-types@^0.2.25\", \"@fortawesome/fontawesome-common-types@^0.2.36\":\n+\"@fortawesome/fontawesome-common-types@^0.2.36\":\nversion \"0.2.36\"\nresolved \"https://registry.yarnpkg.com/@fortawesome/fontawesome-common-types/-/fontawesome-common-types-0.2.36.tgz#b44e52db3b6b20523e0c57ef8c42d315532cb903\"\nintegrity sha512-a/7BiSgobHAgBWeN7N0w+lAhInrGxksn13uK7231n2m8EDPE3BMCl9NZLTGrj9ZXfCmC6LM0QLqXidIizVQ6yg==\n\"@fortawesome/fontawesome-common-types\" \"^0.2.36\"\n\"@fortawesome/free-regular-svg-icons@^5.11.2\":\n- version \"5.11.2\"\n- resolved \"https://registry.yarnpkg.com/@fortawesome/free-regular-svg-icons/-/free-regular-svg-icons-5.11.2.tgz#6edfc5c230094be3b9070fef048c01aa321a8428\"\n- integrity sha512-k0vbThRv9AvnXYBWi1gn1rFW4X7co/aFkbm0ZNmAR5PoWb9vY9EDDDobg8Ay4ISaXtCPypvJ0W1FWkSpLQwZ6w==\n+ version \"5.15.4\"\n+ resolved \"https://registry.yarnpkg.com/@fortawesome/free-regular-svg-icons/-/free-regular-svg-icons-5.15.4.tgz#b97edab436954333bbeac09cfc40c6a951081a02\"\n+ integrity sha512-9VNNnU3CXHy9XednJ3wzQp6SwNwT3XaM26oS4Rp391GsxVYA+0oDR2J194YCIWf7jNRCYKjUCOduxdceLrx+xw==\ndependencies:\n- \"@fortawesome/fontawesome-common-types\" \"^0.2.25\"\n+ \"@fortawesome/fontawesome-common-types\" \"^0.2.36\"\n\"@fortawesome/free-solid-svg-icons@^5.11.2\":\n- version \"5.11.2\"\n- resolved \"https://registry.yarnpkg.com/@fortawesome/free-solid-svg-icons/-/free-solid-svg-icons-5.11.2.tgz#2f2f1459743a27902b76655a0d0bc5ec4d945631\"\n- integrity sha512-zBue4i0PAZJUXOmLBBvM7L0O7wmsDC8dFv9IhpW5QL4kT9xhhVUsYg/LX1+5KaukWq4/cbDcKT+RT1aRe543sg==\n+ version \"5.15.4\"\n+ resolved \"https://registry.yarnpkg.com/@fortawesome/free-solid-svg-icons/-/free-solid-svg-icons-5.15.4.tgz#2a68f3fc3ddda12e52645654142b9e4e8fbb6cc5\"\n+ integrity sha512-JLmQfz6tdtwxoihXLg6lT78BorrFyCf59SAwBM6qV/0zXyVeDygJVb3fk+j5Qat+Yvcxp1buLTY5iDh1ZSAQ8w==\ndependencies:\n- \"@fortawesome/fontawesome-common-types\" \"^0.2.25\"\n+ \"@fortawesome/fontawesome-common-types\" \"^0.2.36\"\n\"@fortawesome/react-fontawesome@^0.1.5\":\n- version \"0.1.5\"\n- resolved \"https://registry.yarnpkg.com/@fortawesome/react-fontawesome/-/react-fontawesome-0.1.5.tgz#8bc3cd5c617749534787a35e29caa7a6cff705c9\"\n- integrity sha512-WYDKTgyAWOncujWhhzhW7k8sgO5Eo2pZTUL51yNzSQNBUwwr6rNKg/JUSE3iebaU1XShHw74aKc1kJ+jvtRNew==\n+ version \"0.1.18\"\n+ resolved \"https://registry.yarnpkg.com/@fortawesome/react-fontawesome/-/react-fontawesome-0.1.18.tgz#dae37f718a24e14d7a99a5496c873d69af3fbd73\"\n+ integrity sha512-RwLIB4TZw0M9gvy5u+TusAA0afbwM4JQIimNH/j3ygd6aIvYPQLqXMhC9ErY26J23rDPyDZldIfPq/HpTTJ/tQ==\ndependencies:\n- prop-types \"^15.5.10\"\n+ prop-types \"^15.8.1\"\n\"@google-cloud/firestore@^4.15.1\":\nversion \"4.15.1\"\n@@ -13815,7 +13815,16 @@ prompts@^2.0.1, prompts@^2.4.0:\nkleur \"^3.0.3\"\nsisteransi \"^1.0.5\"\n-prop-types@^15.5.10, prop-types@^15.5.8, prop-types@^15.6.0, prop-types@^15.6.1, prop-types@^15.6.2, prop-types@^15.7.2:\n+prop-types@^15.5.10, prop-types@^15.8.1:\n+ version \"15.8.1\"\n+ resolved \"https://registry.yarnpkg.com/prop-types/-/prop-types-15.8.1.tgz#67d87bf1a694f48435cf332c24af10214a3140b5\"\n+ integrity sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==\n+ dependencies:\n+ loose-envify \"^1.4.0\"\n+ object-assign \"^4.1.1\"\n+ react-is \"^16.13.1\"\n+\n+prop-types@^15.5.8, prop-types@^15.6.0, prop-types@^15.6.1, prop-types@^15.6.2, prop-types@^15.7.2:\nversion \"15.8.0\"\nresolved \"https://registry.yarnpkg.com/prop-types/-/prop-types-15.8.0.tgz#d237e624c45a9846e469f5f31117f970017ff588\"\nintegrity sha512-fDGekdaHh65eI3lMi5OnErU6a8Ighg2KjcjQxO7m8VHyWjcPyj5kiOgV1LQDOOOgVy3+5FgjXvdSSX7B8/5/4g==\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[chore] [web] bump fortawesome in web directory Summary: bump packages in web folder Test Plan: open components like filter-panel.react that use the fortawesome icon package. run `yarn upgrade-interactive` select @fortawesome packages in web Reviewers: atul, palys-swm Reviewed By: atul Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D3973
129,200
04.05.2022 14:28:36
14,400
086389e20728cffe34f38267165815d5542915ec
[Identity] Set max width to 80 characters Summary: The rustfmt default is 100 characters, but we use 80 in the Comm codebase Depends on D3853 Test Plan: Ran cargo build Reviewers: karol-bisztyga, palys-swm, jimpo, atul Subscribers: ashoat, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/identity/rustfmt.toml", "new_path": "services/identity/rustfmt.toml", "diff": "tab_spaces = 2\n+max_width = 80\n" }, { "change_type": "MODIFY", "old_path": "services/identity/src/config.rs", "new_path": "services/identity/src/config.rs", "diff": "@@ -19,7 +19,9 @@ impl Config {\n}\n}\n-#[derive(Debug, derive_more::Display, derive_more::From, derive_more::Error)]\n+#[derive(\n+ Debug, derive_more::Display, derive_more::From, derive_more::Error,\n+)]\npub enum Error {\n#[display(...)]\nPake(PakeError),\n" }, { "change_type": "MODIFY", "old_path": "services/identity/src/opaque.rs", "new_path": "services/identity/src/opaque.rs", "diff": "use argon2::Argon2;\nuse digest::{generic_array::GenericArray, Digest};\nuse opaque_ke::{\n- ciphersuite::CipherSuite, errors::InternalPakeError, hash::Hash, slow_hash::SlowHash,\n+ ciphersuite::CipherSuite, errors::InternalPakeError, hash::Hash,\n+ slow_hash::SlowHash,\n};\npub struct Cipher;\n" }, { "change_type": "MODIFY", "old_path": "services/identity/src/service.rs", "new_path": "services/identity/src/service.rs", "diff": "@@ -7,8 +7,9 @@ use crate::database::DatabaseClient;\npub use proto::identity_service_server::IdentityServiceServer;\nuse proto::{\n- identity_service_server::IdentityService, LoginRequest, LoginResponse, RegistrationRequest,\n- RegistrationResponse, VerifyUserTokenRequest, VerifyUserTokenResponse,\n+ identity_service_server::IdentityService, LoginRequest, LoginResponse,\n+ RegistrationRequest, RegistrationResponse, VerifyUserTokenRequest,\n+ VerifyUserTokenResponse,\n};\nmod proto {\n@@ -23,8 +24,11 @@ pub struct MyIdentityService {\n#[tonic::async_trait]\nimpl IdentityService for MyIdentityService {\n- type RegisterUserStream =\n- Pin<Box<dyn Stream<Item = Result<RegistrationResponse, Status>> + Send + 'static>>;\n+ type RegisterUserStream = Pin<\n+ Box<\n+ dyn Stream<Item = Result<RegistrationResponse, Status>> + Send + 'static,\n+ >,\n+ >;\nasync fn register_user(\n&self,\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[Identity] Set max width to 80 characters Summary: The rustfmt default is 100 characters, but we use 80 in the Comm codebase Depends on D3853 Test Plan: Ran cargo build Reviewers: karol-bisztyga, palys-swm, jimpo, atul Reviewed By: karol-bisztyga, atul Subscribers: ashoat, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D3920
129,179
11.05.2022 14:39:31
14,400
206d81a9a61887b165d7135b9fda6e5d8f82e68f
[native] [refactor] refactor container margin bottom if statement Summary: use if else syntax the that's used project wide. before: {F53859} after: {F53857} Test Plan: Cluster margin should work as expected in chat view. Reviewers: atul, palys-swm, def-au1t, dereknelson Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "native/chat/composed-message.react.js", "new_path": "native/chat/composed-message.react.js", "diff": "@@ -73,9 +73,15 @@ class ComposedMessage extends React.PureComponent<Props> {\nconst alignStyle = isViewer\n? styles.rightChatBubble\n: styles.leftChatBubble;\n+\n+ let containerMarginBottom = 5;\n+ if (item.endsCluster) {\n+ containerMarginBottom += clusterEndHeight;\n+ }\n+\nconst containerStyle = [\nstyles.alignment,\n- { marginBottom: 5 + (item.endsCluster ? clusterEndHeight : 0) },\n+ { marginBottom: containerMarginBottom },\n];\nconst messageBoxStyle = { maxWidth: composedMessageMaxWidth };\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[native] [refactor] [ENG-530] refactor container margin bottom if statement Summary: use if else syntax the that's used project wide. before: {F53859} after: {F53857} Test Plan: Cluster margin should work as expected in chat view. Reviewers: atul, palys-swm, def-au1t, dereknelson Reviewed By: palys-swm Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D3997
129,190
12.05.2022 11:37:51
-7,200
16867717704f35c9a9df30edfa97ed23839d5680
[services] Base image - Rename contents to docker Summary: Renaming the` contents` folder to the `docker` folder for the base image. Test Plan: ``` cd services yarn build-base-image ``` Reviewers: ashoat Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/base-image/Dockerfile", "new_path": "services/base-image/Dockerfile", "diff": "@@ -20,13 +20,13 @@ RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y \\\nRUN mkdir -p /transferred/scripts\nWORKDIR /transferred/scripts\n-COPY contents/install_grpc.sh .\n+COPY docker/install_grpc.sh .\nRUN ./install_grpc.sh\n-COPY contents/install_aws_sdk.sh .\n+COPY docker/install_aws_sdk.sh .\nRUN ./install_aws_sdk.sh\n-COPY contents/install_folly.sh .\n+COPY docker/install_folly.sh .\nRUN ./install_folly.sh\nCMD /bin/bash\n" }, { "change_type": "RENAME", "old_path": "services/base-image/contents/install_aws_sdk.sh", "new_path": "services/base-image/docker/install_aws_sdk.sh", "diff": "" }, { "change_type": "RENAME", "old_path": "services/base-image/contents/install_folly.sh", "new_path": "services/base-image/docker/install_folly.sh", "diff": "" }, { "change_type": "RENAME", "old_path": "services/base-image/contents/install_grpc.sh", "new_path": "services/base-image/docker/install_grpc.sh", "diff": "" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Base image - Rename contents to docker Summary: https://linear.app/comm/issue/ENG-1121/reconsider-base-imagecontents-directory Renaming the` contents` folder to the `docker` folder for the base image. Test Plan: ``` cd services yarn build-base-image ``` Reviewers: ashoat Reviewed By: ashoat Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D4000
129,185
13.05.2022 10:50:30
-7,200
a4570c8b558d0bfad9efe98d7e6f7d16a2153f21
[web] Introduce custom `Radio` component Summary: Introduce custom "Radio" component matching the one from our design system. GIF: {F51576} Test Plan: The component is not used yet, tested when introducing notification settings. Reviewers: palys-swm, benschac, atul Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "ADD", "old_path": null, "new_path": "web/components/radio.css", "diff": "+.radio {\n+ appearance: none;\n+ background-color: transparent;\n+ width: 24px;\n+ height: 24px;\n+ border: 1px solid var(--radio-border);\n+ border-radius: 50%;\n+ display: flex;\n+ align-items: center;\n+ justify-content: center;\n+}\n+\n+.radio::before {\n+ content: '';\n+ width: 16px;\n+ height: 16px;\n+ border-radius: 50%;\n+ transform: scale(0);\n+ transition: 120ms transform ease-in-out;\n+ background-color: var(--radio-color);\n+}\n+\n+.radio:checked::before {\n+ transform: scale(1);\n+}\n" }, { "change_type": "ADD", "old_path": null, "new_path": "web/components/radio.react.js", "diff": "+// @flow\n+import * as React from 'react';\n+\n+import css from './radio.css';\n+\n+type Props = {\n+ +checked: boolean,\n+};\n+\n+function Radio(props: Props): React.Node {\n+ const { checked } = props;\n+ return <input className={css.radio} type=\"radio\" checked={checked} />;\n+}\n+\n+export default Radio;\n" }, { "change_type": "MODIFY", "old_path": "web/theme.css", "new_path": "web/theme.css", "diff": "--add-members-item-disabled-color-hover: var(--shades-black-60);\n--add-members-remove-pending-color: var(--error-primary);\n--add-members-remove-pending-color-hover: var(--error-light-50);\n+ --radio-border: var(--shades-black-70);\n+ --radio-color: var(--shades-white-60);\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Introduce custom `Radio` component Summary: Introduce custom "Radio" component matching the one from our design system. GIF: {F51576} Test Plan: The component is not used yet, tested when introducing notification settings. Reviewers: palys-swm, benschac, atul Reviewed By: palys-swm, atul Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D3946
129,185
13.05.2022 10:50:30
-7,200
7345b813c94e0d4a269d28fdcbe5194d676eb51e
[web] Introduce `NotificationsOptionInfo` component Summary: Introduce component describing feature of notification settings. It can be true or false (strikethrough text). {F51586} Test Plan: Not used in app yet. Tested after introducing notifications modal. Reviewers: palys-swm, benschac, atul Subscribers: ashoat, Adrian, atul, yayabosh
[ { "change_type": "ADD", "old_path": null, "new_path": "web/modals/threads/notifications/notifications-modal.css", "diff": "+div.optionInfo {\n+ display: flex;\n+ align-items: center;\n+ column-gap: 4px;\n+}\n+\n+div.optionInfoInvalid {\n+ text-decoration: line-through;\n+ color: var(--notification-settings-option-invalid-color);\n+}\n+\n+div.optionContainerSelected div.optionInfoInvalid {\n+ color: var(--notification-settings-option-invalid-selected-color);\n+}\n" }, { "change_type": "ADD", "old_path": null, "new_path": "web/modals/threads/notifications/notifications-option-info.react.js", "diff": "+// @flow\n+\n+import classnames from 'classnames';\n+import * as React from 'react';\n+\n+import SWMansionIcon from '../../../SWMansionIcon.react';\n+import css from './notifications-modal.css';\n+\n+type Props = {\n+ +valid: boolean,\n+ +children: React.Node,\n+};\n+\n+function NotificationsOptionInfo(props: Props): React.Node {\n+ const { valid, children } = props;\n+\n+ const optionInfoClasses = React.useMemo(\n+ () =>\n+ classnames(css.optionInfo, {\n+ [css.optionInfoInvalid]: !valid,\n+ }),\n+ [valid],\n+ );\n+\n+ const icon = React.useMemo(\n+ () => <SWMansionIcon icon={valid ? 'check' : 'cross'} size={12} />,\n+ [valid],\n+ );\n+ return (\n+ <div className={optionInfoClasses}>\n+ {icon}\n+ {children}\n+ </div>\n+ );\n+}\n+\n+export default NotificationsOptionInfo;\n" }, { "change_type": "MODIFY", "old_path": "web/theme.css", "new_path": "web/theme.css", "diff": "--add-members-remove-pending-color-hover: var(--error-light-50);\n--radio-border: var(--shades-black-70);\n--radio-color: var(--shades-white-60);\n+ --notification-settings-option-invalid-color: var(--shades-black-80);\n+ --notification-settings-option-invalid-selected-color: var(--shades-black-60);\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Introduce `NotificationsOptionInfo` component Summary: Introduce component describing feature of notification settings. It can be true or false (strikethrough text). {F51586} Test Plan: Not used in app yet. Tested after introducing notifications modal. Reviewers: palys-swm, benschac, atul Reviewed By: palys-swm, atul Subscribers: ashoat, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D3947
129,185
13.05.2022 10:50:30
-7,200
247f81bf62455b3f70a9d5173a5b56a9924465cd
[web] Introduce `NotificationsOption` component Summary: Introduce a component describing one notification setting with radio button. {F51598} Test Plan: It's not used yet. Tested when introducing modal with multiple options in one of next diffs. Reviewers: palys-swm, atul, benschac Subscribers: ashoat, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/modals/threads/notifications/notifications-modal.css", "new_path": "web/modals/threads/notifications/notifications-modal.css", "diff": "+div.optionContainer {\n+ display: flex;\n+ padding: 16px 32px 16px 16px;\n+ align-items: center;\n+ border-radius: 8px;\n+}\n+\n+div.optionContainerSelected {\n+ background: var(--notification-settings-option-selected-bg);\n+}\n+\n+div.optionIcon {\n+ margin-right: 24px;\n+}\n+\n+div.optionContent {\n+ display: flex;\n+ flex-direction: column;\n+ flex: 1;\n+ line-height: var(--line-height-text);\n+}\n+\n+div.optionTitle {\n+ font-size: var(--m-font-16);\n+ font-weight: var(--semi-bold);\n+ color: var(--notification-settings-option-title-color);\n+ margin-bottom: 4px;\n+}\n+\n+div.optionDescription {\n+ font-size: var(--xs-font-12);\n+ color: var(--notification-settings-option-color);\n+ display: flex;\n+ flex-direction: column;\n+ row-gap: 4px;\n+}\n+\ndiv.optionInfo {\ndisplay: flex;\nalign-items: center;\n" }, { "change_type": "ADD", "old_path": null, "new_path": "web/modals/threads/notifications/notifications-option.react.js", "diff": "+// @flow\n+\n+import classnames from 'classnames';\n+import * as React from 'react';\n+\n+import Radio from '../../../components/radio.react';\n+import css from './notifications-modal.css';\n+import NotificationsOptionInfo from './notifications-option-info.react';\n+\n+type Props = {\n+ +selected: boolean,\n+ +onSelect: () => void,\n+ +icon: React.Node,\n+ +title: string,\n+ +description: $ReadOnlyArray<[string, boolean]>,\n+};\n+\n+function NotificationsOption(props: Props): React.Node {\n+ const { icon, title, description, selected, onSelect } = props;\n+\n+ const descriptionItems = React.useMemo(\n+ () =>\n+ description.map(([text, isValid]) => (\n+ <NotificationsOptionInfo key={text} valid={isValid}>\n+ {text}\n+ </NotificationsOptionInfo>\n+ )),\n+ [description],\n+ );\n+\n+ const optionContainerClasses = React.useMemo(\n+ () =>\n+ classnames(css.optionContainer, {\n+ [css.optionContainerSelected]: selected,\n+ }),\n+ [selected],\n+ );\n+ return (\n+ <div className={optionContainerClasses} onClick={onSelect}>\n+ <div className={css.optionIcon}>{icon}</div>\n+ <div className={css.optionContent}>\n+ <div className={css.optionTitle}>{title}</div>\n+ <div className={css.optionDescription}>{descriptionItems}</div>\n+ </div>\n+ <Radio checked={selected} />\n+ </div>\n+ );\n+}\n+\n+export default NotificationsOption;\n" }, { "change_type": "MODIFY", "old_path": "web/theme.css", "new_path": "web/theme.css", "diff": "--add-members-remove-pending-color-hover: var(--error-light-50);\n--radio-border: var(--shades-black-70);\n--radio-color: var(--shades-white-60);\n+ --notification-settings-option-selected-bg: var(--shades-black-80);\n+ --notification-settings-option-title-color: var(--shades-white-90);\n+ --notification-settings-option-color: var(--shades-white-60);\n--notification-settings-option-invalid-color: var(--shades-black-80);\n--notification-settings-option-invalid-selected-color: var(--shades-black-60);\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Introduce `NotificationsOption` component Summary: Introduce a component describing one notification setting with radio button. {F51598} Test Plan: It's not used yet. Tested when introducing modal with multiple options in one of next diffs. Reviewers: palys-swm, atul, benschac Reviewed By: palys-swm, atul Subscribers: ashoat, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D3949
129,185
13.05.2022 10:50:31
-7,200
3503a1e4c9ea411b307d4023accfd1947759833b
[web] Introduce thread notification settings options in modal Summary: Introduce notification settings options in modal, that can be selected by the user. {F51650} Test Plan: The modal can be tested after introducing notification item in thread actions menu. Reviewers: palys-swm, atul, benschac Subscribers: ashoat, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/modals/threads/notifications/notifications-modal.react.js", "new_path": "web/modals/threads/notifications/notifications-modal.react.js", "diff": "@@ -6,8 +6,10 @@ import { threadInfoSelector } from 'lib/selectors/thread-selectors';\nimport Button from '../../../components/button.react';\nimport { useSelector } from '../../../redux/redux-utils';\n+import SWMansionIcon from '../../../SWMansionIcon.react';\nimport Modal from '../../modal.react';\nimport css from './notifications-modal.css';\n+import NotificationsOption from './notifications-option.react';\ntype NotificationSettings = 'focused' | 'badge-only' | 'background';\n@@ -33,17 +35,95 @@ function NotificationsModal(props: Props): React.Node {\nconst [\nnotificationSettings,\n- // eslint-disable-next-line no-unused-vars\nsetNotificationSettings,\n] = React.useState<NotificationSettings>(initialThreadSetting);\n- const onClickSave = React.useCallback(() => {}, []);\n- const notificationOptions = [];\n+ const notificationIconStyle = React.useMemo(() => ({ width: 'auto' }), []);\n+\n+ const isFocusedSelected = notificationSettings === 'focused';\n+ const focusedItem = React.useMemo(() => {\n+ const description = [\n+ ['Banner notifs', true],\n+ ['Badge count', true],\n+ ['Lives in Focused tab', true],\n+ ];\n+ const icon = (\n+ <SWMansionIcon\n+ icon=\"all-notifs\"\n+ size={86}\n+ style={notificationIconStyle}\n+ />\n+ );\n+ return (\n+ <NotificationsOption\n+ selected={isFocusedSelected}\n+ title=\"Focused (enabled)\"\n+ description={description}\n+ icon={icon}\n+ onSelect={() => setNotificationSettings('focused')}\n+ />\n+ );\n+ }, [isFocusedSelected, notificationIconStyle]);\n+ const isFocusedBadgeOnlySelected = notificationSettings === 'badge-only';\n+ const focusedBadgeOnlyItem = React.useMemo(() => {\n+ const description = [\n+ ['Banner notifs', false],\n+ ['Badge count', true],\n+ ['Lives in Focused tab', true],\n+ ];\n+ const icon = (\n+ <SWMansionIcon\n+ icon=\"badge-notifs\"\n+ size={86}\n+ style={notificationIconStyle}\n+ />\n+ );\n+ return (\n+ <NotificationsOption\n+ selected={isFocusedBadgeOnlySelected}\n+ title=\"Focused (badge only)\"\n+ description={description}\n+ icon={icon}\n+ onSelect={() => setNotificationSettings('badge-only')}\n+ />\n+ );\n+ }, [isFocusedBadgeOnlySelected, notificationIconStyle]);\n+\n+ const isBackgroundSelected = notificationSettings === 'background';\n+ const backgroundItem = React.useMemo(() => {\n+ const description = [\n+ ['Banner notifs', false],\n+ ['Badge count', false],\n+ ['Lives in Backgound tab', true],\n+ ];\n+ const icon = (\n+ <SWMansionIcon\n+ icon=\"muted-notifs\"\n+ size={86}\n+ style={notificationIconStyle}\n+ />\n+ );\n+ return (\n+ <NotificationsOption\n+ selected={isBackgroundSelected}\n+ title=\"Background\"\n+ description={description}\n+ icon={icon}\n+ onSelect={() => setNotificationSettings('background')}\n+ />\n+ );\n+ }, [isBackgroundSelected, notificationIconStyle]);\n+\n+ const onClickSave = React.useCallback(() => {}, []);\nreturn (\n<Modal name=\"Channel notifications\" size=\"fit-content\" onClose={onClose}>\n<div className={css.container}>\n- <div className={css.optionsContainer}>{notificationOptions}</div>\n+ <div className={css.optionsContainer}>\n+ {focusedItem}\n+ {focusedBadgeOnlyItem}\n+ {backgroundItem}\n+ </div>\n<Button\ntype=\"primary\"\nonClick={onClickSave}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Introduce thread notification settings options in modal Summary: Introduce notification settings options in modal, that can be selected by the user. {F51650} Test Plan: The modal can be tested after introducing notification item in thread actions menu. Reviewers: palys-swm, atul, benschac Reviewed By: atul Subscribers: ashoat, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D3953
129,190
11.05.2022 13:46:42
-7,200
0c347d82e6df133e447c75dbc37371e6cf043181
[services] Document base reactor Summary: Depends on D4002 Test Plan: None - there are just comments Reviewers: ashoat, palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/lib/src/BaseReactor.h", "new_path": "services/lib/src/BaseReactor.h", "diff": "@@ -12,10 +12,20 @@ namespace reactor {\nclass BaseReactor {\npublic:\n+ // Returns a status holder that consists of:\n+ // - reactor's state,\n+ // - status of the operation that's being performed by this reactor.\nvirtual std::shared_ptr<ReactorStatusHolder> getStatusHolder() = 0;\n+ // Should be called when we plan to terminate the connection for some reason\n+ // either with a success or a failure status.\n+ // Receives a status indicating a result of the reactor's operation.\nvirtual void terminate(const grpc::Status &status) = 0;\n+ // Validates current values of the reactor's fields.\nvirtual void validate() = 0;\n+ // Should be called when `OnDone` is called. gRPC calls `OnDone` when there\n+ // are not going to be more rpc operations.\nvirtual void doneCallback() = 0;\n+ // Should be called when `terminate` is called.\nvirtual void terminateCallback() = 0;\n};\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Document base reactor Summary: Depends on D4002 https://linear.app/comm/issue/ENG-969/add-documentation-for-the-reactor-base-classes Test Plan: None - there are just comments Reviewers: ashoat, palys-swm Reviewed By: ashoat, palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D4003
129,190
11.05.2022 16:36:21
-7,200
6da201fb0202e529bb4b410c0daeb71859190e34
[services] Add documentation for base reactors Summary: Depends on D4003 Test Plan: None - there are just comments Reviewers: ashoat, palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/lib/src/client-base-reactors/ClientBidiReactorBase.h", "new_path": "services/lib/src/client-base-reactors/ClientBidiReactorBase.h", "diff": "@@ -8,6 +8,11 @@ namespace comm {\nnamespace network {\nnamespace reactor {\n+// This is how this type of reactor works:\n+// - repeat:\n+// - write a request to the server\n+// - read a response from the server\n+// - terminate the connection\ntemplate <class Request, class Response>\nclass ClientBidiReactorBase : public grpc::ClientBidiReactor<Request, Response>,\npublic BaseReactor {\n@@ -21,18 +26,28 @@ protected:\npublic:\ngrpc::ClientContext context;\n+ // this should be called explicitly right after the reactor is created\nvoid start();\n+ // these methods come from the BaseReactor(go there for more information)\nvoid validate() override{};\nvoid doneCallback() override{};\nvoid terminateCallback() override{};\n+ std::shared_ptr<ReactorStatusHolder> getStatusHolder() override;\n+ // these methods come from gRPC\n+ // https://github.com/grpc/grpc/blob/v1.39.x/include/grpcpp/impl/codegen/client_callback.h#L237\nvoid OnWriteDone(bool ok) override;\nvoid OnReadDone(bool ok) override;\nvoid terminate(const grpc::Status &status) override;\nvoid OnDone(const grpc::Status &status) override;\n- std::shared_ptr<ReactorStatusHolder> getStatusHolder() override;\n+ // - argument request - request that's about to be prepared for the next cycle\n+ // - argument previousResponse - response received during the previous cycle\n+ // (may be nullptr)\n+ // - returns status - if the connection is about to be\n+ // continued, nullptr should be returned. Any other returned value will\n+ // terminate the connection with a given status\nvirtual std::unique_ptr<grpc::Status> prepareRequest(\nRequest &request,\nstd::shared_ptr<Response> previousResponse) = 0;\n" }, { "change_type": "MODIFY", "old_path": "services/lib/src/client-base-reactors/ClientReadReactorBase.h", "new_path": "services/lib/src/client-base-reactors/ClientReadReactorBase.h", "diff": "@@ -8,6 +8,10 @@ namespace comm {\nnamespace network {\nnamespace reactor {\n+// This is how this type of reactor works:\n+// - send a request to the server\n+// - read N responses from the server\n+// - terminate the connection\ntemplate <class Request, class Response>\nclass ClientReadReactorBase : public grpc::ClientReadReactor<Response>,\npublic BaseReactor {\n@@ -18,17 +22,26 @@ public:\nRequest request;\ngrpc::ClientContext context;\n+ // this should be called explicitly right after the reactor is created\nvoid start();\n+ // these methods come from the BaseReactor(go there for more information)\nvoid validate() override{};\nvoid doneCallback() override{};\nvoid terminateCallback() override{};\n+ std::shared_ptr<ReactorStatusHolder> getStatusHolder() override;\n+ // these methods come from gRPC\n+ // https://github.com/grpc/grpc/blob/v1.39.x/include/grpcpp/impl/codegen/client_callback.h#L237\nvoid OnReadDone(bool ok) override;\nvoid terminate(const grpc::Status &status) override;\nvoid OnDone(const grpc::Status &status) override;\n- std::shared_ptr<ReactorStatusHolder> getStatusHolder() override;\n+ // - argument response - response from the server that was read during the\n+ // current cycle\n+ // - returns status - if the connection is about to be\n+ // continued, nullptr should be returned. Any other returned value will\n+ // terminate the connection with a given status\nvirtual std::unique_ptr<grpc::Status> readResponse(Response &response) = 0;\n};\n" }, { "change_type": "MODIFY", "old_path": "services/lib/src/client-base-reactors/ClientWriteReactorBase.h", "new_path": "services/lib/src/client-base-reactors/ClientWriteReactorBase.h", "diff": "@@ -8,6 +8,9 @@ namespace comm {\nnamespace network {\nnamespace reactor {\n+// This is how this type of reactor works:\n+// - write N requests to the server\n+// - terminate the connection\ntemplate <class Request, class Response>\nclass ClientWriteReactorBase : public grpc::ClientWriteReactor<Request>,\npublic BaseReactor {\n@@ -20,17 +23,26 @@ public:\nResponse response;\ngrpc::ClientContext context;\n+ // this should be called explicitly right after the reactor is created\nvoid start();\n+ // these methods come from the BaseReactor(go there for more information)\nvoid validate() override{};\nvoid doneCallback() override{};\nvoid terminateCallback() override{};\n+ std::shared_ptr<ReactorStatusHolder> getStatusHolder() override;\n+ // these methods come from gRPC\n+ // https://github.com/grpc/grpc/blob/v1.39.x/include/grpcpp/impl/codegen/client_callback.h#L237\nvoid OnWriteDone(bool ok) override;\nvoid terminate(const grpc::Status &status) override;\nvoid OnDone(const grpc::Status &status) override;\n- std::shared_ptr<ReactorStatusHolder> getStatusHolder() override;\n+ // - argument request - request that should be edited and is going to be sent\n+ // in the current cycle to the server\n+ // - returns status - if the connection is about to be\n+ // continued, nullptr should be returned. Any other returned value will\n+ // terminate the connection with a given status\nvirtual std::unique_ptr<grpc::Status> prepareRequest(Request &request) = 0;\n};\n" }, { "change_type": "MODIFY", "old_path": "services/lib/src/server-base-reactors/ServerBidiReactorBase.h", "new_path": "services/lib/src/server-base-reactors/ServerBidiReactorBase.h", "diff": "@@ -23,6 +23,11 @@ struct ServerBidiReactorStatus {\n}\n};\n+// This is how this type of reactor works:\n+// - repeat:\n+// - read a request from the client\n+// - write a response to the client\n+// - terminate the connection\ntemplate <class Request, class Response>\nclass ServerBidiReactorBase : public grpc::ServerBidiReactor<Request, Response>,\npublic BaseReactor {\n@@ -37,20 +42,30 @@ protected:\npublic:\nServerBidiReactorBase();\n+ // these methods come from the BaseReactor(go there for more information)\nvoid terminate(const grpc::Status &status) override;\nvoid validate() override{};\nvoid doneCallback() override{};\nvoid terminateCallback() override{};\n+ std::shared_ptr<ReactorStatusHolder> getStatusHolder() override;\n+ // these methods come from gRPC\n+ // https://github.com/grpc/grpc/blob/v1.39.x/include/grpcpp/impl/codegen/client_callback.h#L237\nvoid OnDone() override;\nvoid OnReadDone(bool ok) override;\nvoid OnWriteDone(bool ok) override;\n- std::shared_ptr<ReactorStatusHolder> getStatusHolder() override;\nvoid terminate(ServerBidiReactorStatus status);\nServerBidiReactorStatus getStatus() const;\nvoid setStatus(const ServerBidiReactorStatus &status);\n+ // - argument request - request that was sent by the client and received by\n+ // the server in the current cycle\n+ // - argument response - response that will be sent to the client in the\n+ // current cycle\n+ // - returns status - if the connection is about to be\n+ // continued, nullptr should be returned. Any other returned value will\n+ // terminate the connection with a given status\nvirtual std::unique_ptr<ServerBidiReactorStatus>\nhandleRequest(Request request, Response *response) = 0;\n};\n" }, { "change_type": "MODIFY", "old_path": "services/lib/src/server-base-reactors/ServerReadReactorBase.h", "new_path": "services/lib/src/server-base-reactors/ServerReadReactorBase.h", "diff": "@@ -13,6 +13,10 @@ namespace comm {\nnamespace network {\nnamespace reactor {\n+// This is how this type of reactor works:\n+// - read N requests from the client\n+// - write a final response to the client (may be empty)\n+// - terminate the connection\ntemplate <class Request, class Response>\nclass ServerReadReactorBase : public grpc::ServerReadReactor<Request>,\npublic BaseReactor {\n@@ -25,15 +29,22 @@ protected:\npublic:\nServerReadReactorBase(Response *response);\n+ // these methods come from the BaseReactor(go there for more information)\nvoid validate() override{};\nvoid doneCallback() override{};\nvoid terminateCallback() override{};\n+ std::shared_ptr<ReactorStatusHolder> getStatusHolder() override;\n+ // these methods come from gRPC\n+ // https://github.com/grpc/grpc/blob/v1.39.x/include/grpcpp/impl/codegen/client_callback.h#L237\nvoid OnReadDone(bool ok) override;\nvoid terminate(const grpc::Status &status) override;\nvoid OnDone() override;\n- std::shared_ptr<ReactorStatusHolder> getStatusHolder() override;\n+ // - argument request - data read from the client in the current cycle\n+ // - returns status - if the connection is about to be\n+ // continued, nullptr should be returned. Any other returned value will\n+ // terminate the connection with a given status\nvirtual std::unique_ptr<grpc::Status> readRequest(Request request) = 0;\n};\n" }, { "change_type": "MODIFY", "old_path": "services/lib/src/server-base-reactors/ServerWriteReactorBase.h", "new_path": "services/lib/src/server-base-reactors/ServerWriteReactorBase.h", "diff": "@@ -13,6 +13,10 @@ namespace comm {\nnamespace network {\nnamespace reactor {\n+// This is how this type of reactor works:\n+// - read a request from the client\n+// - write N responses to the client\n+// - terminate the connection\ntemplate <class Request, class Response>\nclass ServerWriteReactorBase : public grpc::ServerWriteReactor<Response>,\npublic BaseReactor {\n@@ -29,18 +33,27 @@ protected:\npublic:\nServerWriteReactorBase(const Request *request);\n+ // this should be called explicitly right after the reactor is created\nvoid start();\n+ // these methods come from the BaseReactor(go there for more information)\nvoid validate() override{};\nvoid doneCallback() override{};\nvoid terminateCallback() override{};\n+ std::shared_ptr<ReactorStatusHolder> getStatusHolder() override;\n+ // these methods come from gRPC\n+ // https://github.com/grpc/grpc/blob/v1.39.x/include/grpcpp/impl/codegen/client_callback.h#L237\nvirtual void initialize(){};\nvoid OnWriteDone(bool ok) override;\nvoid terminate(const grpc::Status &status);\nvoid OnDone() override;\n- std::shared_ptr<ReactorStatusHolder> getStatusHolder() override;\n+ // - argument response - should be filled with data that will be sent to the\n+ // client in the current cycle\n+ // - returns status - if the connection is about to be\n+ // continued, nullptr should be returned. Any other returned value will\n+ // terminate the connection with a given status\nvirtual std::unique_ptr<grpc::Status> writeResponse(Response *response) = 0;\n};\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Add documentation for base reactors Summary: Depends on D4003 https://linear.app/comm/issue/ENG-969/add-documentation-for-the-reactor-base-classes Test Plan: None - there are just comments Reviewers: ashoat, palys-swm Reviewed By: ashoat, palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D4004
129,179
12.05.2022 18:22:53
14,400
141a61f432a4839891a2b9686ce5ba28eb4c1f1b
[web] [refactor] use input component Summary: use our input component moving forward Test Plan: type text into input field Reviewers: atul, palys-swm, def-au1t Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/modals/chat/sidebar-list-modal.react.js", "new_path": "web/modals/chat/sidebar-list-modal.react.js", "diff": "@@ -15,6 +15,7 @@ import SidebarItem from '../../chat/sidebar-item.react';\nimport { useSelector } from '../../redux/redux-utils';\nimport globalCSS from '../../style.css';\nimport { MagnifyingGlass } from '../../vectors.react';\n+import Input from '../input.react';\nimport { useModalContext } from '../modal-provider.react';\nimport Modal from '../modal.react';\n@@ -125,7 +126,7 @@ function SidebarListModal(props: Props): React.Node {\n<div>\n<div className={chatThreadListCSS.search}>\n<MagnifyingGlass className={chatThreadListCSS.searchVector} />\n- <input\n+ <Input\ntype=\"text\"\nplaceholder=\"Search sidebars\"\nvalue={searchState.text}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] [refactor] [ENG-536] use input component Summary: use our input component moving forward Test Plan: type text into input field Reviewers: atul, palys-swm, def-au1t Reviewed By: palys-swm Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4023
129,184
12.05.2022 13:07:27
14,400
c951c3f795c8f60b599cd36c8c7d8d81b99684eb
[web] Remove unused/unnecessary selectors from `thread-settings-delete-tab.css` Summary: 1. Remove the `textarea` selector which isn't used 2. Remove the "line" separating the notice from the instructions to delete Depends on 4016 Test Plan: Before: {F54881} After: {F54882} Reviewers: def-au1t, palys-swm, benschac Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/modals/threads/thread-settings-delete-tab.css", "new_path": "web/modals/threads/thread-settings-delete-tab.css", "diff": "@@ -21,23 +21,7 @@ div.form_content input {\nmargin-bottom: 4px;\n}\n-div.form_content textarea {\n- padding: 12px;\n- background: var(--modal-bg);\n- color: var(--fg);\n- border: 1px solid var(--border-color);\n- font-size: var(--m-font-16);\n- border-radius: 4px;\n- width: 100%;\n-}\n-\n.italic {\nfont-style: italic;\ncolor: var(--fg);\n}\n-\n-div.edit_thread_account_password {\n- border-top: 2px solid #efefef;\n- padding-top: 4px;\n- margin-top: 2px;\n-}\n" }, { "change_type": "MODIFY", "old_path": "web/modals/threads/thread-settings-delete-tab.react.js", "new_path": "web/modals/threads/thread-settings-delete-tab.react.js", "diff": "@@ -83,7 +83,7 @@ function ThreadSettingsDeleteTab(\nthis.\n</p>\n</div>\n- <div className={css.edit_thread_account_password}>\n+ <div>\n<p className={css.confirm_account_password}>\nPlease enter your account password to confirm your identity\n</p>\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Remove unused/unnecessary selectors from `thread-settings-delete-tab.css` Summary: 1. Remove the `textarea` selector which isn't used 2. Remove the "line" separating the notice from the instructions to delete --- Depends on 4016 Test Plan: Before: {F54881} After: {F54882} Reviewers: def-au1t, palys-swm, benschac Reviewed By: palys-swm, benschac Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4017
129,184
12.05.2022 13:12:14
14,400
f36c4b80757467339e1d771e1056d08735760978
[web] Use `Input` component in `ThreadSettingsDeleteTab` Summary: Before: {F54894} After: {F54895} Depends on D4017 Test Plan: Looks as expected, flow Reviewers: def-au1t, palys-swm, benschac Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/modals/threads/thread-settings-delete-tab.react.js", "new_path": "web/modals/threads/thread-settings-delete-tab.react.js", "diff": "@@ -14,6 +14,7 @@ import {\n} from 'lib/utils/action-utils';\nimport Button from '../../components/button.react.js';\n+import Input from '../input.react.js';\nimport { useModalContext } from '../modal-provider.react.js';\nimport css from './thread-settings-modal.css';\n@@ -89,9 +90,9 @@ function ThreadSettingsDeleteTab(\n</p>\n<div className={css.form_title}>Account password</div>\n<div className={css.form_content}>\n- <input\n+ <Input\ntype=\"password\"\n- placeholder=\"Personal account password\"\n+ placeholder=\"Password\"\nvalue={accountPassword}\nonChange={onChangeAccountPassword}\ndisabled={inputDisabled}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Use `Input` component in `ThreadSettingsDeleteTab` Summary: Before: {F54894} After: {F54895} --- Depends on D4017 Test Plan: Looks as expected, flow Reviewers: def-au1t, palys-swm, benschac Reviewed By: palys-swm, benschac Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4018
129,191
28.04.2022 15:25:15
-7,200
2fa239ba71a44dd30e6160c8865f2115e6959d78
[web] Add user-cross icon Summary: We need this icon on friend list Test Plan: Display the icon and check if it is displayed correctly Reviewers: benschac, atul, def-au1t Subscribers: yayabosh, Adrian, ashoat
[ { "change_type": "MODIFY", "old_path": "web/SWMansionIcon.react.js", "new_path": "web/SWMansionIcon.react.js", "diff": "@@ -76,7 +76,8 @@ export type Icon =\n| 'all-notifs'\n| 'badge-notifs'\n| 'muted-notifs'\n- | 'check';\n+ | 'check'\n+ | 'user-cross';\ntype SWMansionIconProps = {\n+icon: Icon,\n" }, { "change_type": "MODIFY", "old_path": "web/icons/selection.json", "new_path": "web/icons/selection.json", "diff": "{\n\"IcoMoonType\": \"selection\",\n\"icons\": [\n+ {\n+ \"icon\": {\n+ \"paths\": [\n+ \"M961.293 406.627c12.497-12.497 12.497-32.758 0-45.255s-32.755-12.497-45.252 0l45.252 45.255zM745.374 532.041c-12.497 12.497-12.497 32.755 0 45.252s32.755 12.497 45.252 0l-45.252-45.252zM790.626 361.373c-12.497-12.497-32.755-12.497-45.252 0s-12.497 32.758 0 45.255l45.252-45.255zM916.041 577.293c12.497 12.497 32.755 12.497 45.252 0s12.497-32.755 0-45.252l-45.252 45.252zM853.333 896v32c17.673 0 32-14.327 32-32h-32zM170.667 896h-32c0 17.673 14.327 32 32 32v-32zM916.041 361.373l-170.667 170.668 45.252 45.252 170.667-170.665-45.252-45.255zM745.374 406.627l170.667 170.665 45.252-45.252-170.667-170.668-45.252 45.255zM341.333 672h341.333v-64h-341.333v64zM821.333 810.667v85.333h64v-85.333h-64zM202.667 896v-85.333h-64v85.333h64zM682.667 672c76.582 0 138.667 62.084 138.667 138.667h64c0-111.932-90.735-202.667-202.667-202.667v64zM341.333 608c-111.93 0-202.667 90.735-202.667 202.667h64c0-76.582 62.083-138.667 138.667-138.667v-64zM650.667 298.667c0 76.584-62.084 138.667-138.667 138.667v64c111.932 0 202.667-90.737 202.667-202.667h-64zM512 437.333c-76.582 0-138.667-62.083-138.667-138.667h-64c0 111.93 90.737 202.667 202.667 202.667v-64zM373.333 298.667c0-76.584 62.084-138.667 138.667-138.667v-64c-111.93 0-202.667 90.737-202.667 202.667h64zM512 160c76.582 0 138.667 62.083 138.667 138.667h64c0-111.93-90.735-202.667-202.667-202.667v64zM170.667 928h682.667v-64h-682.667v64z\"\n+ ],\n+ \"attrs\": [],\n+ \"isMulticolor\": false,\n+ \"isMulticolor2\": false,\n+ \"grid\": 24,\n+ \"tags\": [\"user-cross\"],\n+ \"colorPermutations\": {}\n+ },\n+ \"attrs\": [],\n+ \"properties\": {\n+ \"order\": 190,\n+ \"id\": 63,\n+ \"name\": \"user-cross\",\n+ \"prevSize\": 32\n+ },\n+ \"setIdx\": 0,\n+ \"setId\": 6,\n+ \"iconIdx\": 0\n+ },\n{\n\"icon\": {\n\"paths\": [\"M853.333 298.667l-469.332 469.333-213.338-213.333\"],\n}\n],\n\"properties\": {\n- \"order\": 792,\n- \"id\": 63,\n+ \"order\": 191,\n+ \"id\": 0,\n\"name\": \"check\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 0\n+ \"setId\": 6,\n+ \"iconIdx\": 1\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 793,\n- \"id\": 60,\n+ \"order\": 192,\n+ \"id\": 1,\n\"name\": \"all-notifs\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 1\n+ \"setId\": 6,\n+ \"iconIdx\": 2\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 794,\n- \"id\": 61,\n+ \"order\": 193,\n+ \"id\": 2,\n\"name\": \"muted-notifs\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 2\n+ \"setId\": 6,\n+ \"iconIdx\": 3\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 795,\n- \"id\": 62,\n+ \"order\": 194,\n+ \"id\": 3,\n\"name\": \"badge-notifs\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 3\n+ \"setId\": 6,\n+ \"iconIdx\": 4\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 796,\n- \"id\": 58,\n+ \"order\": 195,\n+ \"id\": 4,\n\"name\": \"upload\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 4\n+ \"setId\": 6,\n+ \"iconIdx\": 5\n},\n{\n\"icon\": {\n{}\n],\n\"properties\": {\n- \"order\": 797,\n- \"id\": 59,\n+ \"order\": 196,\n+ \"id\": 5,\n\"name\": \"user-circle\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 5\n+ \"setId\": 6,\n+ \"iconIdx\": 6\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 798,\n- \"id\": 46,\n+ \"order\": 197,\n+ \"id\": 6,\n\"name\": \"arrow-left-small\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 6\n+ \"setId\": 6,\n+ \"iconIdx\": 7\n},\n{\n\"icon\": {\n},\n\"attrs\": [{}],\n\"properties\": {\n- \"order\": 799,\n- \"id\": 47,\n+ \"order\": 198,\n+ \"id\": 7,\n\"name\": \"cross-circle\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 7\n+ \"setId\": 6,\n+ \"iconIdx\": 8\n},\n{\n\"icon\": {\n},\n\"attrs\": [{}],\n\"properties\": {\n- \"order\": 800,\n- \"id\": 48,\n+ \"order\": 199,\n+ \"id\": 8,\n\"name\": \"document-clean\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 8\n+ \"setId\": 6,\n+ \"iconIdx\": 9\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 801,\n- \"id\": 49,\n+ \"order\": 200,\n+ \"id\": 9,\n\"name\": \"globe\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 9\n+ \"setId\": 6,\n+ \"iconIdx\": 10\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 802,\n- \"id\": 50,\n+ \"order\": 201,\n+ \"id\": 10,\n\"name\": \"grid\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 10\n+ \"setId\": 6,\n+ \"iconIdx\": 11\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 803,\n- \"id\": 51,\n+ \"order\": 202,\n+ \"id\": 11,\n\"name\": \"link\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 11\n+ \"setId\": 6,\n+ \"iconIdx\": 12\n},\n{\n\"icon\": {\n},\n\"attrs\": [{}],\n\"properties\": {\n- \"order\": 804,\n- \"id\": 52,\n+ \"order\": 203,\n+ \"id\": 12,\n\"name\": \"lock-on\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 12\n+ \"setId\": 6,\n+ \"iconIdx\": 13\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 805,\n- \"id\": 53,\n+ \"order\": 204,\n+ \"id\": 13,\n\"name\": \"mail\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 13\n+ \"setId\": 6,\n+ \"iconIdx\": 14\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 806,\n- \"id\": 54,\n+ \"order\": 205,\n+ \"id\": 14,\n\"name\": \"message-circle\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 14\n+ \"setId\": 6,\n+ \"iconIdx\": 15\n},\n{\n\"icon\": {\n},\n\"attrs\": [{}],\n\"properties\": {\n- \"order\": 807,\n- \"id\": 55,\n+ \"order\": 206,\n+ \"id\": 15,\n\"name\": \"smartphone\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 15\n+ \"setId\": 6,\n+ \"iconIdx\": 16\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 808,\n- \"id\": 56,\n+ \"order\": 207,\n+ \"id\": 16,\n\"name\": \"user-plus\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 16\n+ \"setId\": 6,\n+ \"iconIdx\": 17\n},\n{\n\"icon\": {\n},\n\"attrs\": [{}],\n\"properties\": {\n- \"order\": 809,\n- \"id\": 57,\n+ \"order\": 208,\n+ \"id\": 17,\n\"name\": \"warning-circle\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 17\n+ \"setId\": 6,\n+ \"iconIdx\": 18\n},\n{\n\"icon\": {\n},\n\"attrs\": [],\n\"properties\": {\n- \"order\": 810,\n- \"id\": 38,\n+ \"order\": 209,\n+ \"id\": 18,\n\"name\": \"bx-bold\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 18\n+ \"setId\": 6,\n+ \"iconIdx\": 19\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 811,\n- \"id\": 39,\n+ \"order\": 210,\n+ \"id\": 19,\n\"name\": \"bx-italic\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 19\n+ \"setId\": 6,\n+ \"iconIdx\": 20\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 812,\n- \"id\": 40,\n+ \"order\": 211,\n+ \"id\": 20,\n\"name\": \"bx-strikethrough\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 20\n+ \"setId\": 6,\n+ \"iconIdx\": 21\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 813,\n- \"id\": 41,\n+ \"order\": 212,\n+ \"id\": 21,\n\"name\": \"bx-underline\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 21\n+ \"setId\": 6,\n+ \"iconIdx\": 22\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 814,\n- \"id\": 42,\n+ \"order\": 213,\n+ \"id\": 22,\n\"name\": \"dino-avatar\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 22\n+ \"setId\": 6,\n+ \"iconIdx\": 23\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 815,\n- \"id\": 43,\n+ \"order\": 214,\n+ \"id\": 23,\n\"name\": \"laptop\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 23\n+ \"setId\": 6,\n+ \"iconIdx\": 24\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 816,\n- \"id\": 44,\n+ \"order\": 215,\n+ \"id\": 24,\n\"name\": \"list-filled\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 24\n+ \"setId\": 6,\n+ \"iconIdx\": 25\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 817,\n- \"id\": 45,\n+ \"order\": 216,\n+ \"id\": 25,\n\"name\": \"reply-chat-bubble\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 25\n+ \"setId\": 6,\n+ \"iconIdx\": 26\n},\n{\n\"icon\": {\n},\n\"attrs\": [{}],\n\"properties\": {\n- \"order\": 818,\n- \"id\": 36,\n+ \"order\": 217,\n+ \"id\": 26,\n\"name\": \"image\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 26\n+ \"setId\": 6,\n+ \"iconIdx\": 27\n},\n{\n\"icon\": {\n},\n\"attrs\": [],\n\"properties\": {\n- \"order\": 819,\n- \"id\": 0,\n+ \"order\": 218,\n+ \"id\": 27,\n\"name\": \"reply-arrow\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 27\n+ \"setId\": 6,\n+ \"iconIdx\": 28\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 820,\n- \"id\": 1,\n+ \"order\": 219,\n+ \"id\": 28,\n\"name\": \"right-angle-arrow\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 28\n+ \"setId\": 6,\n+ \"iconIdx\": 29\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 821,\n- \"id\": 2,\n+ \"order\": 220,\n+ \"id\": 29,\n\"name\": \"wrench\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 29\n+ \"setId\": 6,\n+ \"iconIdx\": 30\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 822,\n- \"id\": 3,\n+ \"order\": 221,\n+ \"id\": 30,\n\"name\": \"message-filled-round\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 30\n+ \"setId\": 6,\n+ \"iconIdx\": 31\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 823,\n- \"id\": 4,\n+ \"order\": 222,\n+ \"id\": 31,\n\"name\": \"bug\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 31\n+ \"setId\": 6,\n+ \"iconIdx\": 32\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 824,\n- \"id\": 5,\n+ \"order\": 223,\n+ \"id\": 32,\n\"name\": \"chevron-right-small\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 32\n+ \"setId\": 6,\n+ \"iconIdx\": 33\n},\n{\n\"icon\": {\n},\n\"attrs\": [{}],\n\"properties\": {\n- \"order\": 825,\n- \"id\": 6,\n+ \"order\": 224,\n+ \"id\": 33,\n\"name\": \"question-circle\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 33\n+ \"setId\": 6,\n+ \"iconIdx\": 34\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 826,\n- \"id\": 7,\n+ \"order\": 225,\n+ \"id\": 34,\n\"name\": \"arrow-left\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 34\n+ \"setId\": 6,\n+ \"iconIdx\": 35\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 827,\n- \"id\": 8,\n+ \"order\": 226,\n+ \"id\": 35,\n\"name\": \"arrow-right-small\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 35\n+ \"setId\": 6,\n+ \"iconIdx\": 36\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 828,\n- \"id\": 9,\n+ \"order\": 227,\n+ \"id\": 36,\n\"name\": \"arrow-right\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 36\n+ \"setId\": 6,\n+ \"iconIdx\": 37\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 829,\n- \"id\": 10,\n+ \"order\": 228,\n+ \"id\": 37,\n\"name\": \"bell-disabled\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 37\n+ \"setId\": 6,\n+ \"iconIdx\": 38\n},\n{\n\"icon\": {\n},\n\"attrs\": [{}],\n\"properties\": {\n- \"order\": 830,\n- \"id\": 11,\n+ \"order\": 229,\n+ \"id\": 38,\n\"name\": \"bell\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 38\n+ \"setId\": 6,\n+ \"iconIdx\": 39\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 831,\n- \"id\": 12,\n+ \"order\": 230,\n+ \"id\": 39,\n\"name\": \"calendar\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 39\n+ \"setId\": 6,\n+ \"iconIdx\": 40\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 832,\n- \"id\": 13,\n+ \"order\": 231,\n+ \"id\": 40,\n\"name\": \"chevron-left\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 40\n+ \"setId\": 6,\n+ \"iconIdx\": 41\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 833,\n- \"id\": 14,\n+ \"order\": 232,\n+ \"id\": 41,\n\"name\": \"chevron-right\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 41\n+ \"setId\": 6,\n+ \"iconIdx\": 42\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 834,\n- \"id\": 15,\n+ \"order\": 233,\n+ \"id\": 42,\n\"name\": \"cloud\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 42\n+ \"setId\": 6,\n+ \"iconIdx\": 43\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 835,\n- \"id\": 16,\n+ \"order\": 234,\n+ \"id\": 43,\n\"name\": \"copy\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 43\n+ \"setId\": 6,\n+ \"iconIdx\": 44\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 836,\n- \"id\": 17,\n+ \"order\": 235,\n+ \"id\": 44,\n\"name\": \"cross\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 44\n+ \"setId\": 6,\n+ \"iconIdx\": 45\n},\n{\n\"icon\": {\n},\n\"attrs\": [{}],\n\"properties\": {\n- \"order\": 837,\n- \"id\": 18,\n+ \"order\": 236,\n+ \"id\": 45,\n\"name\": \"edit\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 45\n+ \"setId\": 6,\n+ \"iconIdx\": 46\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 838,\n- \"id\": 19,\n+ \"order\": 237,\n+ \"id\": 46,\n\"name\": \"emotxd-smile\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 46\n+ \"setId\": 6,\n+ \"iconIdx\": 47\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 839,\n- \"id\": 20,\n+ \"order\": 238,\n+ \"id\": 47,\n\"name\": \"filters\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 47\n+ \"setId\": 6,\n+ \"iconIdx\": 48\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 840,\n- \"id\": 21,\n+ \"order\": 239,\n+ \"id\": 48,\n\"name\": \"inbox\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 48\n+ \"setId\": 6,\n+ \"iconIdx\": 49\n},\n{\n\"icon\": {\n},\n\"attrs\": [{}],\n\"properties\": {\n- \"order\": 841,\n- \"id\": 22,\n+ \"order\": 240,\n+ \"id\": 49,\n\"name\": \"info-circle\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 49\n+ \"setId\": 6,\n+ \"iconIdx\": 50\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 842,\n- \"id\": 23,\n+ \"order\": 241,\n+ \"id\": 50,\n\"name\": \"key\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 50\n+ \"setId\": 6,\n+ \"iconIdx\": 51\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 843,\n- \"id\": 24,\n+ \"order\": 242,\n+ \"id\": 51,\n\"name\": \"logout\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 51\n+ \"setId\": 6,\n+ \"iconIdx\": 52\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 844,\n- \"id\": 25,\n+ \"order\": 243,\n+ \"id\": 52,\n\"name\": \"menu-horizontal\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 52\n+ \"setId\": 6,\n+ \"iconIdx\": 53\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 845,\n- \"id\": 26,\n+ \"order\": 244,\n+ \"id\": 53,\n\"name\": \"menu-vertical\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 53\n+ \"setId\": 6,\n+ \"iconIdx\": 54\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 846,\n- \"id\": 27,\n+ \"order\": 245,\n+ \"id\": 54,\n\"name\": \"message-circle-lines\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 54\n+ \"setId\": 6,\n+ \"iconIdx\": 55\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 847,\n- \"id\": 28,\n+ \"order\": 246,\n+ \"id\": 55,\n\"name\": \"message-square-lines\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 55\n+ \"setId\": 6,\n+ \"iconIdx\": 56\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 848,\n- \"id\": 29,\n+ \"order\": 247,\n+ \"id\": 56,\n\"name\": \"message-square\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 56\n+ \"setId\": 6,\n+ \"iconIdx\": 57\n},\n{\n\"icon\": {\n},\n\"attrs\": [{}],\n\"properties\": {\n- \"order\": 849,\n- \"id\": 30,\n+ \"order\": 248,\n+ \"id\": 57,\n\"name\": \"plus-circle\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 57\n+ \"setId\": 6,\n+ \"iconIdx\": 58\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 850,\n- \"id\": 31,\n+ \"order\": 249,\n+ \"id\": 58,\n\"name\": \"plus\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 58\n+ \"setId\": 6,\n+ \"iconIdx\": 59\n},\n{\n\"icon\": {\n},\n\"attrs\": [{}],\n\"properties\": {\n- \"order\": 851,\n- \"id\": 32,\n+ \"order\": 250,\n+ \"id\": 59,\n\"name\": \"search\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 59\n+ \"setId\": 6,\n+ \"iconIdx\": 60\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 852,\n- \"id\": 33,\n+ \"order\": 251,\n+ \"id\": 60,\n\"name\": \"send\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 60\n+ \"setId\": 6,\n+ \"iconIdx\": 61\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 853,\n- \"id\": 34,\n+ \"order\": 252,\n+ \"id\": 61,\n\"name\": \"settings\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 61\n+ \"setId\": 6,\n+ \"iconIdx\": 62\n},\n{\n\"icon\": {\n}\n],\n\"properties\": {\n- \"order\": 854,\n- \"id\": 35,\n+ \"order\": 253,\n+ \"id\": 62,\n\"name\": \"users\",\n\"prevSize\": 32\n},\n\"setIdx\": 0,\n- \"setId\": 4,\n- \"iconIdx\": 62\n+ \"setId\": 6,\n+ \"iconIdx\": 63\n}\n],\n\"height\": 1024,\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Add user-cross icon Summary: We need this icon on friend list Test Plan: Display the icon and check if it is displayed correctly Reviewers: benschac, atul, def-au1t Reviewed By: benschac, atul Subscribers: yayabosh, Adrian, ashoat Differential Revision: https://phabricator.ashoat.com/D4006
129,191
11.05.2022 17:35:11
-7,200
f8ae5734bbedcb5692bbd24be4bab9c9622a3d93
[web] Memoize friend list row buttons Summary: Shouldn't matter that much, but still it is probably a good idea Depends on D4007 Test Plan: The same as D4007. Also check if cancel request and reject still work. Reviewers: benschac, atul, def-au1t Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/settings/relationship/friend-list-row.react.js", "new_path": "web/settings/relationship/friend-list-row.react.js", "diff": "@@ -16,9 +16,9 @@ function FriendListRow(props: UserRowProps): React.Node {\nconst { userInfo } = props;\nconst { friendUser, unfriendUser } = useRelationshipCallbacks(userInfo.id);\n- let buttons = null;\n+ const buttons = React.useMemo(() => {\nif (userInfo.relationshipStatus === userRelationshipStatus.REQUEST_SENT) {\n- buttons = (\n+ return (\n<button\nclassName={classnames([css.button, css.destructive])}\nonClick={unfriendUser}\n@@ -26,10 +26,11 @@ function FriendListRow(props: UserRowProps): React.Node {\nCancel request\n</button>\n);\n- } else if (\n+ }\n+ if (\nuserInfo.relationshipStatus === userRelationshipStatus.REQUEST_RECEIVED\n) {\n- buttons = (\n+ return (\n<>\n<button className={css.button} onClick={friendUser}>\nAccept\n@@ -42,16 +43,23 @@ function FriendListRow(props: UserRowProps): React.Node {\n</button>\n</>\n);\n- } else if (userInfo.relationshipStatus === userRelationshipStatus.FRIEND) {\n+ }\n+ if (userInfo.relationshipStatus === userRelationshipStatus.FRIEND) {\nconst editIcon = <SWMansionIcon icon=\"edit\" size={22} />;\n- buttons = (\n+ return (\n<div className={css.edit_menu}>\n<Menu icon={editIcon} variant=\"member-actions\">\n- <MenuItem text=\"Unfriend\" icon=\"user-cross\" onClick={unfriendUser} />\n+ <MenuItem\n+ text=\"Unfriend\"\n+ icon=\"user-cross\"\n+ onClick={unfriendUser}\n+ />\n</Menu>\n</div>\n);\n}\n+ return undefined;\n+ }, [friendUser, unfriendUser, userInfo.relationshipStatus]);\nreturn (\n<div className={css.container}>\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Memoize friend list row buttons Summary: Shouldn't matter that much, but still it is probably a good idea Depends on D4007 Test Plan: The same as D4007. Also check if cancel request and reject still work. Reviewers: benschac, atul, def-au1t Reviewed By: benschac, atul Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4008
129,191
12.05.2022 20:37:48
-7,200
a00305277cd0a89983ebfa8db6971911eef710ad
[web] Introduce block list modal Summary: In this modal we display a list of users that are blocked. {F55707} Depends on D4037 Test Plan: Open the list and check if all the blocked users are displayed and sorted. Reviewers: benschac, atul, def-au1t Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "ADD", "old_path": null, "new_path": "web/settings/relationship/block-list-modal.react.js", "diff": "+// @flow\n+\n+import * as React from 'react';\n+\n+import { userRelationshipStatus } from 'lib/types/relationship-types';\n+import type { AccountUserInfo } from 'lib/types/user-types';\n+\n+import BlockListRow from './block-list-row.react';\n+import UserListModal from './user-list-modal.react';\n+\n+function filterUser(userInfo: AccountUserInfo) {\n+ return (\n+ userInfo.relationshipStatus === userRelationshipStatus.BLOCKED_BY_VIEWER ||\n+ userInfo.relationshipStatus === userRelationshipStatus.BOTH_BLOCKED\n+ );\n+}\n+\n+function usersComparator(user1: AccountUserInfo, user2: AccountUserInfo) {\n+ return user1.username.localeCompare(user2.username);\n+}\n+\n+type Props = {\n+ +onClose: () => void,\n+};\n+\n+function BlockListModal(props: Props): React.Node {\n+ const { onClose } = props;\n+ return (\n+ <UserListModal\n+ onClose={onClose}\n+ name=\"Block List\"\n+ userRowComponent={BlockListRow}\n+ filterUser={filterUser}\n+ usersComparator={usersComparator}\n+ />\n+ );\n+}\n+\n+export default BlockListModal;\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Introduce block list modal Summary: In this modal we display a list of users that are blocked. {F55707} https://www.figma.com/file/a1nkbWgbgjRlrOY9LVurTz/Comm-%2F-Desktop-app?node-id=1313%3A98810 Depends on D4037 Test Plan: Open the list and check if all the blocked users are displayed and sorted. Reviewers: benschac, atul, def-au1t Reviewed By: atul Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4038
129,179
13.05.2022 14:48:37
14,400
632ebc627ecfd688d5defd3f870a7bc1d8adaacf
[web] [fix] fix empty chat screen on load Summary: fixes: before: {F55778} after: {F55777} Test Plan: clear application cookies (both user and anonymous) in the browser dev tools. Adding ashoat since we paired on it. Reviewers: atul, ashoat, palys-swm, def-au1t Subscribers: Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/redux/redux-setup.js", "new_path": "web/redux/redux-setup.js", "diff": "@@ -8,6 +8,7 @@ import {\n} from 'lib/actions/user-actions';\nimport baseReducer from 'lib/reducers/master-reducer';\nimport { mostRecentlyReadThreadSelector } from 'lib/selectors/thread-selectors';\n+import { isLoggedIn } from 'lib/selectors/user-selectors';\nimport { invalidSessionDowngrade } from 'lib/shared/account-utils';\nimport type { Shape } from 'lib/types/core';\nimport type { EnabledApps } from 'lib/types/enabled-apps';\n@@ -135,9 +136,10 @@ export function reducer(oldState: AppState | void, action: Action): AppState {\nfunction validateState(oldState: AppState, state: AppState): AppState {\nif (\n- state.navInfo.activeChatThreadID &&\n+ (state.navInfo.activeChatThreadID &&\n!state.navInfo.pendingThread &&\n- !state.threadStore.threadInfos[state.navInfo.activeChatThreadID]\n+ !state.threadStore.threadInfos[state.navInfo.activeChatThreadID]) ||\n+ (!state.navInfo.activeChatThreadID && isLoggedIn(state))\n) {\n// Makes sure the active thread always exists\nstate = {\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] [fix] [ENG-977] fix empty chat screen on load Summary: fixes: https://linear.app/comm/issue/ENG-977/on-initial-load-a-conversation-should-be-selected before: {F55778} after: {F55777} Test Plan: clear application cookies (both user and anonymous) in the browser dev tools. Adding ashoat since we paired on it. Reviewers: atul, ashoat, palys-swm, def-au1t Reviewed By: ashoat Subscribers: Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4040
129,196
17.05.2022 15:08:56
-7,200
e4430fd6d5369b01cccb632ff5a14eae953bef12
Introduce and run clang-format updated to newer version Summary: Update clang-format to v1.8.0 since 1.7.0 does not work on Intel Test Plan: Check that yarn clang-format-all works on Intel mac Reviewers: palys-swm, atul, ashoat Subscribers: Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "native/ios/Comm/CommSecureStore.mm", "new_path": "native/ios/Comm/CommSecureStore.mm", "diff": "@@ -28,4 +28,4 @@ folly::Optional<std::string> CommSecureStore::get(const std::string key) const {\n: folly::none;\n}\n-};\n+}; // namespace comm\n" }, { "change_type": "MODIFY", "old_path": "native/ios/Comm/Logger.mm", "new_path": "native/ios/Comm/Logger.mm", "diff": "@@ -11,4 +11,4 @@ void Logger::log(const std::string str) {\nencoding:[NSString defaultCStringEncoding]]);\n};\n-}\n+} // namespace comm\n" }, { "change_type": "MODIFY", "old_path": "native/ios/Comm/PlatformSpecificTools.mm", "new_path": "native/ios/Comm/PlatformSpecificTools.mm", "diff": "@@ -23,4 +23,4 @@ std::string PlatformSpecificTools::getDeviceOS() {\nreturn std::string{\"ios\"};\n}\n-};\n+}; // namespace comm\n" }, { "change_type": "MODIFY", "old_path": "package.json", "new_path": "package.json", "diff": "},\n\"devDependencies\": {\n\"babel-eslint\": \"^10.1.0\",\n- \"clang-format\": \"^1.7.0\",\n+ \"clang-format\": \"^1.8.0\",\n\"core-js\": \"^3.6.5\",\n\"eslint\": \"^7.22.0\",\n\"eslint-config-prettier\": \"^8.1.0\",\n" }, { "change_type": "MODIFY", "old_path": "yarn.lock", "new_path": "yarn.lock", "diff": "@@ -5277,10 +5277,10 @@ cjs-module-lexer@^0.6.0:\nresolved \"https://registry.yarnpkg.com/cjs-module-lexer/-/cjs-module-lexer-0.6.0.tgz#4186fcca0eae175970aee870b9fe2d6cf8d5655f\"\nintegrity sha512-uc2Vix1frTfnuzxxu1Hp4ktSvM3QaI4oXl4ZUqL1wjTu/BGki9TrCWoqLTg/drR1KwAEarXuRFCG2Svr1GxPFw==\n-clang-format@^1.7.0:\n- version \"1.7.0\"\n- resolved \"https://registry.yarnpkg.com/clang-format/-/clang-format-1.7.0.tgz#c06c63ec1ae2a2590d8eac2562daeb877ca30d44\"\n- integrity sha512-BNuK+rXAK/Fk0rOQ1DW6bpSQUAZz6tpbZHTQn6m4PsgEkE1SNr6AQ/hhFK/b4KJrl4zjcl68molP+rEaKSZRAQ==\n+clang-format@^1.8.0:\n+ version \"1.8.0\"\n+ resolved \"https://registry.yarnpkg.com/clang-format/-/clang-format-1.8.0.tgz#7779df1c5ce1bc8aac1b0b02b4e479191ef21d46\"\n+ integrity sha512-pK8gzfu55/lHzIpQ1givIbWfn3eXnU7SfxqIwVgnn5jEM6j4ZJYjpFqFs4iSBPNedzRMmfjYjuQhu657WAXHXw==\ndependencies:\nasync \"^3.2.3\"\nglob \"^7.0.0\"\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
Introduce and run clang-format updated to newer version Summary: Update clang-format to v1.8.0 since 1.7.0 does not work on Intel Test Plan: Check that yarn clang-format-all works on Intel mac Reviewers: palys-swm, atul, ashoat Reviewed By: palys-swm, ashoat Subscribers: Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4064
129,190
19.05.2022 13:40:00
-7,200
f997677296b611490eb08185abfff57ae21050e8
[services] Move generateUUID to global tools Summary: Depends on D4026 Extracting `generateUUID` from tunnelbroker into the global tools Test Plan: Services still build Reviewers: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/lib/src/GlobalTools.cpp", "new_path": "services/lib/src/GlobalTools.cpp", "diff": "#include \"GlobalTools.h\"\n#include <openssl/sha.h>\n+#include <boost/uuid/uuid.hpp>\n+#include <boost/uuid/uuid_generators.hpp>\n+#include <boost/uuid/uuid_io.hpp>\n#include <chrono>\n#include <iomanip>\n@@ -34,5 +37,10 @@ bool isDevMode() {\nreturn hasEnvFlag(\"COMM_SERVICES_DEV_MODE\");\n}\n+std::string generateUUID() {\n+ thread_local boost::uuids::random_generator random_generator;\n+ return boost::uuids::to_string(random_generator());\n+}\n+\n} // namespace network\n} // namespace comm\n" }, { "change_type": "MODIFY", "old_path": "services/lib/src/GlobalTools.h", "new_path": "services/lib/src/GlobalTools.h", "diff": "@@ -14,5 +14,7 @@ std::string decorateTableName(const std::string &baseName);\nbool isDevMode();\n+std::string generateUUID();\n+\n} // namespace network\n} // namespace comm\n" }, { "change_type": "MODIFY", "old_path": "services/tunnelbroker/src/Service/TunnelbrokerServiceImpl.cpp", "new_path": "services/tunnelbroker/src/Service/TunnelbrokerServiceImpl.cpp", "diff": "#include \"CryptoTools.h\"\n#include \"DatabaseManager.h\"\n#include \"DeliveryBroker.h\"\n+#include \"GlobalTools.h\"\n#include \"Tools.h\"\n#include <glog/logging.h>\n@@ -76,7 +77,7 @@ grpc::Status TunnelBrokerServiceImpl::NewSession(\n}\nconst std::string signature = request->signature();\nconst std::string publicKey = request->publickey();\n- const std::string newSessionID = tools::generateUUID();\n+ const std::string newSessionID = generateUUID();\ntry {\nsessionSignItem =\ndatabase::DatabaseManager::getInstance().findSessionSignItem(deviceID);\n@@ -152,7 +153,7 @@ grpc::Status TunnelBrokerServiceImpl::Send(\n\"No such session found. SessionID: \" + sessionID);\n}\nconst std::string clientDeviceID = sessionItem->getDeviceID();\n- const std::string messageID = tools::generateUUID();\n+ const std::string messageID = generateUUID();\nif (!AmqpManager::getInstance().send(\nmessageID,\nclientDeviceID,\n" }, { "change_type": "MODIFY", "old_path": "services/tunnelbroker/src/Tools/Tools.cpp", "new_path": "services/tunnelbroker/src/Tools/Tools.cpp", "diff": "#include <glog/logging.h>\n#include <boost/lexical_cast.hpp>\n-#include <boost/uuid/uuid.hpp>\n-#include <boost/uuid/uuid_generators.hpp>\n-#include <boost/uuid/uuid_io.hpp>\n#include <chrono>\n#include <iostream>\n@@ -52,11 +49,6 @@ bool validateDeviceID(std::string deviceID) {\n}\n}\n-std::string generateUUID() {\n- thread_local boost::uuids::random_generator random_generator;\n- return boost::uuids::to_string(random_generator());\n-}\n-\nbool validateSessionID(std::string sessionID) {\ntry {\nreturn std::regex_match(sessionID, SESSION_ID_FORMAT_REGEX);\n" }, { "change_type": "MODIFY", "old_path": "services/tunnelbroker/src/Tools/Tools.h", "new_path": "services/tunnelbroker/src/Tools/Tools.h", "diff": "@@ -10,7 +10,6 @@ namespace tools {\nstd::string generateRandomString(std::size_t length);\nint64_t getCurrentTimestamp();\nbool validateDeviceID(std::string deviceID);\n-std::string generateUUID();\nbool validateSessionID(std::string sessionID);\nvoid checkIfNotEmpty(std::string fieldName, std::string stringToCheck);\nvoid checkIfNotZero(std::string fieldName, uint64_t numberToCheck);\n" }, { "change_type": "MODIFY", "old_path": "services/tunnelbroker/test/AmqpManagerTest.cpp", "new_path": "services/tunnelbroker/test/AmqpManagerTest.cpp", "diff": "#include \"ConfigManager.h\"\n#include \"Constants.h\"\n#include \"DeliveryBroker.h\"\n+#include \"GlobalTools.h\"\n#include \"Tools.h\"\n#include <gtest/gtest.h>\n@@ -47,7 +48,7 @@ TEST_F(AmqpManagerTest, SentAndPopedMessagesAreSameOnStaticData) {\n}\nTEST_F(AmqpManagerTest, SentAndPopedMessagesAreSameOnGeneratedData) {\n- const std::string messageID = tools::generateUUID();\n+ const std::string messageID = generateUUID();\nconst std::string toDeviceID =\n\"mobile:\" + tools::generateRandomString(DEVICEID_CHAR_LENGTH);\nconst std::string fromDeviceID =\n" }, { "change_type": "MODIFY", "old_path": "services/tunnelbroker/test/DatabaseManagerTest.cpp", "new_path": "services/tunnelbroker/test/DatabaseManagerTest.cpp", "diff": "#include \"DatabaseManager.h\"\n#include \"ConfigManager.h\"\n#include \"Constants.h\"\n+#include \"GlobalTools.h\"\n#include \"Tools.h\"\n#include <gtest/gtest.h>\n@@ -66,7 +67,7 @@ TEST_F(DatabaseManagerTest, PutAndFoundMessageItemsStaticDataIsSame) {\nTEST_F(DatabaseManagerTest, PutAndFoundMessageItemsGeneratedDataIsSame) {\nconst database::MessageItem item(\n- tools::generateUUID(),\n+ generateUUID(),\n\"mobile:\" + tools::generateRandomString(DEVICEID_CHAR_LENGTH),\n\"web:\" + tools::generateRandomString(DEVICEID_CHAR_LENGTH),\ntools::generateRandomString(256),\n" }, { "change_type": "MODIFY", "old_path": "services/tunnelbroker/test/DeliveryBrokerTest.cpp", "new_path": "services/tunnelbroker/test/DeliveryBrokerTest.cpp", "diff": "#include \"DeliveryBroker.h\"\n+#include \"GlobalTools.h\"\n#include \"Tools.h\"\n#include <gtest/gtest.h>\n@@ -46,7 +47,7 @@ TEST(DeliveryBrokerTest, CheckPushAndPopOnGeneratedValues) {\nconst std::string toDeviceID =\n\"mobile:\" + tools::generateRandomString(DEVICEID_CHAR_LENGTH);\nconst DeliveryBrokerMessage message{\n- .messageID = tools::generateUUID(),\n+ .messageID = generateUUID(),\n.deliveryTag = static_cast<uint64_t>(std::time(0)),\n.fromDeviceID =\n\"mobile:\" + tools::generateRandomString(DEVICEID_CHAR_LENGTH),\n" }, { "change_type": "MODIFY", "old_path": "services/tunnelbroker/test/ToolsTest.cpp", "new_path": "services/tunnelbroker/test/ToolsTest.cpp", "diff": "#include \"Tools.h\"\n#include \"Constants.h\"\n+#include \"GlobalTools.h\"\n#include <gtest/gtest.h>\n@@ -58,7 +59,7 @@ TEST(ToolsTest, ValidateSessionIDReturnsTrueOnValidStaticSessionID) {\n}\nTEST(ToolsTest, ValidateSessionIDReturnsTrueOnValidGeneratedSessionID) {\n- const std::string validSessionID = tools::generateUUID();\n+ const std::string validSessionID = generateUUID();\nEXPECT_EQ(tools::validateSessionID(validSessionID), true)\n<< \"Valid generated sessionID \\\"\" << validSessionID\n<< \"\\\" is invalid by the function\";\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Move generateUUID to global tools Summary: Depends on D4026 Extracting `generateUUID` from tunnelbroker into the global tools Test Plan: Services still build Reviewers: palys-swm Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D4027
129,200
10.05.2022 16:23:08
14,400
8969a3a820b9543c8be4617325ee2da0c8ae5255
[services][identity] helper function to create primary key for DynamoDB Summary: This function takes a partition key and optional sort key and returns a primary key for the DynamoDB client. Depends on D3920 Test Plan: Unit tested Reviewers: jimpo, karol-bisztyga, palys-swm Subscribers: ashoat, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/identity/src/database.rs", "new_path": "services/identity/src/database.rs", "diff": "+use std::collections::HashMap;\n+\nuse rusoto_core::Region;\n-use rusoto_dynamodb::DynamoDbClient;\n+use rusoto_dynamodb::{AttributeValue, DynamoDbClient};\npub struct DatabaseClient {\nclient: DynamoDbClient,\n@@ -12,3 +14,90 @@ impl DatabaseClient {\n}\n}\n}\n+\n+type AttributeName = String;\n+\n+fn create_simple_primary_key(\n+ partition_key: (AttributeName, String),\n+) -> HashMap<AttributeName, AttributeValue> {\n+ HashMap::from([(\n+ partition_key.0,\n+ AttributeValue {\n+ s: Some(partition_key.1),\n+ ..Default::default()\n+ },\n+ )])\n+}\n+\n+fn create_composite_primary_key(\n+ partition_key: (AttributeName, String),\n+ sort_key: (AttributeName, String),\n+) -> HashMap<AttributeName, AttributeValue> {\n+ let mut primary_key = create_simple_primary_key(partition_key);\n+ primary_key.insert(\n+ sort_key.0,\n+ AttributeValue {\n+ s: Some(sort_key.1),\n+ ..Default::default()\n+ },\n+ );\n+ primary_key\n+}\n+\n+#[cfg(test)]\n+mod tests {\n+ use super::*;\n+\n+ #[test]\n+ fn test_create_simple_primary_key() {\n+ let partition_key_name = \"userID\".to_string();\n+ let partition_key_value = \"12345\".to_string();\n+ let partition_key =\n+ (partition_key_name.clone(), partition_key_value.clone());\n+ let primary_key = create_simple_primary_key(partition_key);\n+ assert_eq!(primary_key.len(), 1);\n+ let attribute = primary_key.get(&partition_key_name);\n+ assert!(attribute.is_some());\n+ assert_eq!(\n+ attribute,\n+ Some(AttributeValue {\n+ s: Some(partition_key_value),\n+ ..Default::default()\n+ })\n+ .as_ref()\n+ );\n+ }\n+\n+ #[test]\n+ fn test_create_composite_primary_key() {\n+ let partition_key_name = \"userID\".to_string();\n+ let partition_key_value = \"12345\".to_string();\n+ let partition_key =\n+ (partition_key_name.clone(), partition_key_value.clone());\n+ let sort_key_name = \"deviceID\".to_string();\n+ let sort_key_value = \"54321\".to_string();\n+ let sort_key = (sort_key_name.clone(), sort_key_value.clone());\n+ let primary_key = create_composite_primary_key(partition_key, sort_key);\n+ assert_eq!(primary_key.len(), 2);\n+ let partition_key_attribute = primary_key.get(&partition_key_name);\n+ assert!(partition_key_attribute.is_some());\n+ assert_eq!(\n+ partition_key_attribute,\n+ Some(AttributeValue {\n+ s: Some(partition_key_value),\n+ ..Default::default()\n+ })\n+ .as_ref()\n+ );\n+ let sort_key_attribute = primary_key.get(&sort_key_name);\n+ assert!(sort_key_attribute.is_some());\n+ assert_eq!(\n+ sort_key_attribute,\n+ Some(AttributeValue {\n+ s: Some(sort_key_value),\n+ ..Default::default()\n+ })\n+ .as_ref()\n+ )\n+ }\n+}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services][identity] helper function to create primary key for DynamoDB Summary: This function takes a partition key and optional sort key and returns a primary key for the DynamoDB client. Depends on D3920 Test Plan: Unit tested Reviewers: jimpo, karol-bisztyga, palys-swm Reviewed By: jimpo, karol-bisztyga, palys-swm Subscribers: ashoat, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D4015
129,179
19.05.2022 15:34:05
14,400
4635612d06ef16eef512b752212137e225052b26
[native, lib, web] move search sidebar functionality to lib hooks Summary: move sidebar search to lib/hooks from web,native Test Plan: use feature in both web and native Reviewers: atul, palys-swm, def-au1t, ashoat Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "ADD", "old_path": null, "new_path": "lib/hooks/search-sidebars.js", "diff": "+// @flow\n+\n+import * as React from 'react';\n+\n+import { sidebarInfoSelector } from '../selectors/thread-selectors';\n+import type { SetState } from '../types/hook-types';\n+import type { SidebarInfo, ThreadInfo } from '../types/thread-types';\n+import { useSelector } from '../utils/redux-utils';\n+\n+type SidebarSearchState = {\n+ +text: string,\n+ +results: $ReadOnlySet<string>,\n+};\n+\n+function useSearchSidebars(\n+ threadInfo: ThreadInfo,\n+): {\n+ +listData: $ReadOnlyArray<SidebarInfo>,\n+ +searchState: SidebarSearchState,\n+ +setSearchState: SetState<SidebarSearchState>,\n+} {\n+ const [searchState, setSearchState] = React.useState({\n+ text: '',\n+ results: new Set<string>(),\n+ });\n+\n+ const sidebarInfos = useSelector(\n+ state => sidebarInfoSelector(state)[threadInfo.id] ?? [],\n+ );\n+\n+ const listData = React.useMemo(() => {\n+ if (!searchState.text) {\n+ return sidebarInfos;\n+ }\n+ return sidebarInfos.filter(sidebarInfo =>\n+ searchState.results.has(sidebarInfo.threadInfo.id),\n+ );\n+ }, [sidebarInfos, searchState]);\n+\n+ return React.useMemo(() => ({ listData, searchState, setSearchState }), [\n+ listData,\n+ setSearchState,\n+ searchState,\n+ ]);\n+}\n+\n+export { useSearchSidebars };\n" }, { "change_type": "MODIFY", "old_path": "native/chat/sidebar-list-modal.react.js", "new_path": "native/chat/sidebar-list-modal.react.js", "diff": "import * as React from 'react';\nimport { TextInput, FlatList, StyleSheet } from 'react-native';\n+import { useSearchSidebars } from 'lib/hooks/search-sidebars';\nimport { sidebarInfoSelector } from 'lib/selectors/thread-selectors';\nimport SearchIndex from 'lib/shared/search-index';\nimport { threadSearchText } from 'lib/shared/thread-utils';\n@@ -35,24 +36,13 @@ type Props = {\n};\nfunction SidebarListModal(props: Props): React.Node {\nconst threadID = props.route.params.threadInfo.id;\n+ const { listData, searchState, setSearchState } = useSearchSidebars(\n+ props.route.params.threadInfo,\n+ );\nconst sidebarInfos = useSelector(\nstate => sidebarInfoSelector(state)[threadID] ?? [],\n);\n- const [searchState, setSearchState] = React.useState({\n- text: '',\n- results: new Set<string>(),\n- });\n-\n- const listData = React.useMemo(() => {\n- if (!searchState.text) {\n- return sidebarInfos;\n- }\n- return sidebarInfos.filter(({ threadInfo }) =>\n- searchState.results.has(threadInfo.id),\n- );\n- }, [sidebarInfos, searchState]);\n-\nconst userInfos = useSelector(state => state.userStore.userInfos);\nconst viewerID = useSelector(\nstate => state.currentUserInfo && state.currentUserInfo.id,\n@@ -73,7 +63,7 @@ function SidebarListModal(props: Props): React.Node {\n...curState,\nresults: new Set(searchIndex.getSearchResults(curState.text)),\n}));\n- }, [searchIndex]);\n+ }, [searchIndex, setSearchState]);\nconst onChangeSearchText = React.useCallback(\n(searchText: string) =>\n@@ -81,7 +71,7 @@ function SidebarListModal(props: Props): React.Node {\ntext: searchText,\nresults: new Set(searchIndex.getSearchResults(searchText)),\n}),\n- [searchIndex],\n+ [searchIndex, setSearchState],\n);\nconst searchTextInputRef = React.useRef();\n@@ -111,7 +101,7 @@ function SidebarListModal(props: Props): React.Node {\n}\nnavigateToThread({ threadInfo });\n},\n- [navigateToThread],\n+ [navigateToThread, setSearchState],\n);\nconst renderItem = React.useCallback(\n" }, { "change_type": "MODIFY", "old_path": "web/modals/chat/sidebar-list-modal.react.js", "new_path": "web/modals/chat/sidebar-list-modal.react.js", "diff": "@@ -5,6 +5,7 @@ import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';\nimport classNames from 'classnames';\nimport * as React from 'react';\n+import { useSearchSidebars } from 'lib/hooks/search-sidebars';\nimport { sidebarInfoSelector } from 'lib/selectors/thread-selectors';\nimport SearchIndex from 'lib/shared/search-index';\nimport { threadSearchText } from 'lib/shared/thread-utils';\n@@ -25,10 +26,9 @@ type Props = {\nfunction SidebarListModal(props: Props): React.Node {\nconst { threadInfo } = props;\n- const [searchState, setSearchState] = React.useState({\n- text: '',\n- results: new Set<string>(),\n- });\n+ const { listData, searchState, setSearchState } = useSearchSidebars(\n+ threadInfo,\n+ );\nconst { popModal } = useModalContext();\nconst sidebarInfos = useSelector(\n@@ -36,15 +36,6 @@ function SidebarListModal(props: Props): React.Node {\n);\nconst userInfos = useSelector(state => state.userStore.userInfos);\n- const listData = React.useMemo(() => {\n- if (!searchState.text) {\n- return sidebarInfos;\n- }\n- return sidebarInfos.filter(sidebarInfo =>\n- searchState.results.has(sidebarInfo.threadInfo.id),\n- );\n- }, [sidebarInfos, searchState]);\n-\nconst sidebars = React.useMemo(\n() =>\nlistData.map(item => (\n@@ -82,7 +73,7 @@ function SidebarListModal(props: Props): React.Node {\n...curState,\nresults: new Set(searchIndex.getSearchResults(curState.text)),\n}));\n- }, [searchIndex]);\n+ }, [searchIndex, setSearchState]);\nconst onChangeSearchText = React.useCallback(\n(event: SyntheticEvent<HTMLInputElement>) => {\n@@ -92,15 +83,15 @@ function SidebarListModal(props: Props): React.Node {\nresults: new Set(searchIndex.getSearchResults(searchText)),\n});\n},\n- [searchIndex],\n+ [searchIndex, setSearchState],\n);\nconst clearQuery = React.useCallback(\n(event: SyntheticEvent<HTMLAnchorElement>) => {\nevent.preventDefault();\n- setSearchState({ text: '', results: [] });\n+ setSearchState({ text: '', results: new Set() });\n},\n- [],\n+ [setSearchState],\n);\nlet clearQueryButton = null;\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[native, lib, web] move search sidebar functionality to lib hooks Summary: move sidebar search to lib/hooks from web,native Test Plan: use feature in both web and native Reviewers: atul, palys-swm, def-au1t, ashoat Reviewed By: atul, palys-swm Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4022
129,184
23.05.2022 17:14:44
14,400
2f3a72ed206f58c6d45fdfda290b0e84a746ec64
[CI] Add `keyserver: yarn test` to CI Summary: NA Test Plan: Will test via Buildkite CI Reviewers: def-au1t, palys-swm, benschac, ashoat Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": ".buildkite/eslint_flow_jest.yml", "new_path": ".buildkite/eslint_flow_jest.yml", "diff": "@@ -5,5 +5,6 @@ steps:\n- 'yarn eslint --max-warnings=0 & yarn workspace lib flow & yarn workspace web flow & yarn workspace landing flow & yarn workspace native flow'\n- 'cd keyserver && mkdir secrets && touch secrets/db_config.json && touch secrets/olm_config.json && mkdir facts && touch facts/app_url.json && touch facts/commapp_url.json && touch facts/squadcal_url.json && touch facts/landing_url.json && touch facts/url.json && cd ../ && yarn workspace keyserver flow'\n- 'cd lib && yarn test'\n+ - 'cd ../keyserver && yarn test'\nagents:\n- 'linux=true'\n" }, { "change_type": "MODIFY", "old_path": ".github/workflows/eslint_flow_jest.yml", "new_path": ".github/workflows/eslint_flow_jest.yml", "diff": "@@ -51,3 +51,7 @@ jobs:\n- name: '[lib] test'\nworking-directory: ./lib\nrun: yarn test\n+\n+ - name: '[keyserver] test'\n+ working-directory: ./keyserver\n+ run: yarn test\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[CI] Add `keyserver: yarn test` to CI Summary: NA Test Plan: Will test via Buildkite CI Reviewers: def-au1t, palys-swm, benschac, ashoat Reviewed By: palys-swm, ashoat Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4110
129,184
24.05.2022 16:42:12
14,400
cf76516a57cce6df0f397848bcfdc7070f7d6596
[native] `codeVersion` -> 133
[ { "change_type": "MODIFY", "old_path": "native/android/app/build.gradle", "new_path": "native/android/app/build.gradle", "diff": "@@ -434,8 +434,8 @@ android {\napplicationId 'app.comm.android'\nminSdkVersion rootProject.ext.minSdkVersion\ntargetSdkVersion rootProject.ext.targetSdkVersion\n- versionCode 132\n- versionName '1.0.132'\n+ versionCode 133\n+ versionName '1.0.133'\nmissingDimensionStrategy 'react-native-camera', 'general'\nmultiDexEnabled true\n}\n" }, { "change_type": "MODIFY", "old_path": "native/cpp/CommonCpp/NativeModules/CommCoreModule.h", "new_path": "native/cpp/CommonCpp/NativeModules/CommCoreModule.h", "diff": "@@ -13,7 +13,7 @@ namespace comm {\nnamespace jsi = facebook::jsi;\nclass CommCoreModule : public facebook::react::CommCoreModuleSchemaCxxSpecJSI {\n- const int codeVersion{132};\n+ const int codeVersion{133};\nstd::unique_ptr<WorkerThread> databaseThread;\nstd::unique_ptr<WorkerThread> cryptoThread;\n" }, { "change_type": "MODIFY", "old_path": "native/ios/Comm/Info.debug.plist", "new_path": "native/ios/Comm/Info.debug.plist", "diff": "<key>CFBundlePackageType</key>\n<string>APPL</string>\n<key>CFBundleShortVersionString</key>\n- <string>1.0.132</string>\n+ <string>1.0.133</string>\n<key>CFBundleSignature</key>\n<string>????</string>\n<key>CFBundleVersion</key>\n- <string>132</string>\n+ <string>133</string>\n<key>LSApplicationQueriesSchemes</key>\n<array>\n<string>org-appextension-feature-password-management</string>\n" }, { "change_type": "MODIFY", "old_path": "native/ios/Comm/Info.release.plist", "new_path": "native/ios/Comm/Info.release.plist", "diff": "<key>CFBundlePackageType</key>\n<string>APPL</string>\n<key>CFBundleShortVersionString</key>\n- <string>1.0.132</string>\n+ <string>1.0.133</string>\n<key>CFBundleSignature</key>\n<string>????</string>\n<key>CFBundleVersion</key>\n- <string>132</string>\n+ <string>133</string>\n<key>LSApplicationQueriesSchemes</key>\n<array>\n<string>org-appextension-feature-password-management</string>\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[native] `codeVersion` -> 133
129,190
25.05.2022 11:25:35
-7,200
3667a7b5bd160a9338161dab9dce0b02cf741747
[services] Backup - Implement generating holder Summary: Depends on D4029 Test Plan: Services still build Reviewers: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/backup/src/Tools.cpp", "new_path": "services/backup/src/Tools.cpp", "diff": "#include \"Tools.h\"\n+#include \"GlobalTools.h\"\n+\n#include <chrono>\n#include <cstdlib>\n#include <random>\n@@ -19,5 +21,13 @@ std::string generateRandomString(std::size_t length) {\nreturn random_string;\n}\n+std::string generateHolder(\n+ const std::string &blobHash,\n+ const std::string &backupID,\n+ const std::string &resourceID) {\n+ return backupID + ID_SEPARATOR + resourceID + ID_SEPARATOR + blobHash +\n+ ID_SEPARATOR + generateUUID();\n+}\n+\n} // namespace network\n} // namespace comm\n" }, { "change_type": "MODIFY", "old_path": "services/backup/src/Tools.h", "new_path": "services/backup/src/Tools.h", "diff": "@@ -7,5 +7,10 @@ namespace network {\nstd::string generateRandomString(std::size_t length = 20);\n+std::string generateHolder(\n+ const std::string &blobHash,\n+ const std::string &backupID,\n+ const std::string &resourceID = \"\");\n+\n} // namespace network\n} // namespace comm\n" }, { "change_type": "MODIFY", "old_path": "services/lib/src/GlobalTools.h", "new_path": "services/lib/src/GlobalTools.h", "diff": "namespace comm {\nnamespace network {\n+const std::string ID_SEPARATOR = \":\";\n+\nuint64_t getCurrentTimestamp();\nbool hasEnvFlag(const std::string &flag);\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Backup - Implement generating holder Summary: Depends on D4029 https://linear.app/comm/issue/ENG-1128/implement-generating-holders Test Plan: Services still build Reviewers: palys-swm Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D4030
129,190
25.05.2022 11:31:27
-7,200
89ac57ecc175823a04f872046544429a50b24ff7
[services] Backup - Convert attachment holders from vector to string Summary: Depends on D4076 In we agreed to keep attachment lists in strings delimited with a single character. Test Plan: Services still build Reviewers: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/backup/src/DatabaseEntities/BackupItem.cpp", "new_path": "services/backup/src/DatabaseEntities/BackupItem.cpp", "diff": "#include \"BackupItem.h\"\n#include \"Constants.h\"\n+#include \"GlobalConstants.h\"\nnamespace comm {\nnamespace network {\n@@ -21,7 +22,7 @@ BackupItem::BackupItem(\nuint64_t created,\nstd::string recoveryData,\nstd::string compactionHolder,\n- std::vector<std::string> attachmentHolders)\n+ std::string attachmentHolders)\n: userID(userID),\nbackupID(backupID),\ncreated(created),\n@@ -65,7 +66,7 @@ void BackupItem::assignItemFromDatabase(const AttributeValues &itemFromDB) {\nauto attachmentsHolders =\nitemFromDB.find(BackupItem::FIELD_ATTACHMENT_HOLDERS);\nif (attachmentsHolders != itemFromDB.end()) {\n- this->attachmentHolders = attachmentsHolders->second.GetSS();\n+ this->attachmentHolders = attachmentsHolders->second.GetS();\n}\n} catch (std::logic_error &e) {\nthrow std::runtime_error(\n@@ -107,10 +108,15 @@ std::string BackupItem::getCompactionHolder() const {\nreturn this->compactionHolder;\n}\n-std::vector<std::string> BackupItem::getAttachmentHolders() const {\n+std::string BackupItem::getAttachmentHolders() const {\nreturn this->attachmentHolders;\n}\n+void BackupItem::appendAttachmentHolder(const std::string &attachmentHolder) {\n+ this->attachmentHolders += attachmentHolder;\n+ this->attachmentHolders += ATTACHMENT_DELIMITER;\n+}\n+\n} // namespace database\n} // namespace network\n} // namespace comm\n" }, { "change_type": "MODIFY", "old_path": "services/backup/src/DatabaseEntities/BackupItem.h", "new_path": "services/backup/src/DatabaseEntities/BackupItem.h", "diff": "#include \"Item.h\"\n#include <string>\n-#include <vector>\nnamespace comm {\nnamespace network {\n@@ -37,7 +36,7 @@ class BackupItem : public Item {\nuint64_t created;\nstd::string recoveryData;\nstd::string compactionHolder;\n- std::vector<std::string> attachmentHolders;\n+ std::string attachmentHolders;\nvoid validate() const override;\n@@ -58,7 +57,7 @@ public:\nuint64_t created,\nstd::string recoveryData,\nstd::string compactionHolder,\n- std::vector<std::string> attachmentHolders);\n+ std::string attachmentHolders);\nBackupItem(const AttributeValues &itemFromDB);\nvoid assignItemFromDatabase(const AttributeValues &itemFromDB) override;\n@@ -72,7 +71,9 @@ public:\nuint64_t getCreated() const;\nstd::string getRecoveryData() const;\nstd::string getCompactionHolder() const;\n- std::vector<std::string> getAttachmentHolders() const;\n+ std::string getAttachmentHolders() const;\n+\n+ void appendAttachmentHolder(const std::string &attachmentHolder);\n};\n} // namespace database\n" }, { "change_type": "MODIFY", "old_path": "services/backup/src/DatabaseEntities/LogItem.cpp", "new_path": "services/backup/src/DatabaseEntities/LogItem.cpp", "diff": "#include \"LogItem.h\"\n#include \"Constants.h\"\n+#include \"GlobalConstants.h\"\n#include <stdexcept>\n@@ -21,7 +22,7 @@ LogItem::LogItem(\nconst std::string logID,\nconst bool persistedInBlob,\nconst std::string value,\n- std::vector<std::string> attachmentHolders)\n+ std::string attachmentHolders)\n: backupID(backupID),\nlogID(logID),\npersistedInBlob(persistedInBlob),\n@@ -63,7 +64,7 @@ void LogItem::assignItemFromDatabase(const AttributeValues &itemFromDB) {\nauto attachmentsHolders =\nitemFromDB.find(LogItem::FIELD_ATTACHMENT_HOLDERS);\nif (attachmentsHolders != itemFromDB.end()) {\n- this->attachmentHolders = attachmentsHolders->second.GetSS();\n+ this->attachmentHolders = attachmentsHolders->second.GetS();\n}\n} catch (std::logic_error &e) {\nthrow std::runtime_error(\n@@ -100,10 +101,15 @@ std::string LogItem::getValue() const {\nreturn this->value;\n}\n-std::vector<std::string> LogItem::getAttachmentHolders() const {\n+std::string LogItem::getAttachmentHolders() const {\nreturn this->attachmentHolders;\n}\n+void LogItem::appendAttachmentHolder(const std::string &attachmentHolder) {\n+ this->attachmentHolders += attachmentHolder;\n+ this->attachmentHolders += ATTACHMENT_DELIMITER;\n+}\n+\n} // namespace database\n} // namespace network\n} // namespace comm\n" }, { "change_type": "MODIFY", "old_path": "services/backup/src/DatabaseEntities/LogItem.h", "new_path": "services/backup/src/DatabaseEntities/LogItem.h", "diff": "#include \"Item.h\"\n#include <string>\n-#include <vector>\nnamespace comm {\nnamespace network {\n@@ -23,7 +22,7 @@ class LogItem : public Item {\nstd::string logID;\nbool persistedInBlob;\nstd::string value;\n- std::vector<std::string> attachmentHolders;\n+ std::string attachmentHolders;\nvoid validate() const override;\n@@ -42,7 +41,7 @@ public:\nconst std::string logID,\nconst bool persistedInBlob,\nconst std::string value,\n- std::vector<std::string> attachmentHolders);\n+ std::string attachmentHolders);\nLogItem(const AttributeValues &itemFromDB);\nvoid assignItemFromDatabase(const AttributeValues &itemFromDB) override;\n@@ -55,7 +54,9 @@ public:\nstd::string getLogID() const;\nbool getPersistedInBlob() const;\nstd::string getValue() const;\n- std::vector<std::string> getAttachmentHolders() const;\n+ std::string getAttachmentHolders() const;\n+\n+ void appendAttachmentHolder(const std::string &attachmentHolder);\n};\n} // namespace database\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Backup - Convert attachment holders from vector to string Summary: Depends on D4076 In https://linear.app/comm/issue/ENG-1029/handle-attachments we agreed to keep attachment lists in strings delimited with a single character. Test Plan: Services still build Reviewers: palys-swm Reviewed By: palys-swm Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phabricator.ashoat.com/D4077
129,179
25.05.2022 14:36:56
14,400
e0b2f89460b03829661143efd255019aa6f53823
[lib, native, web] move onChangeSearch to hook Summary: move onChangeSearch to lib/hooks/ from native and web. Test Plan: Use the search sidebar feature in both native and web and confirm functionality still works as expected. Reviewers: atul, palys-swm, def-au1t Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "lib/hooks/search-sidebars.js", "new_path": "lib/hooks/search-sidebars.js", "diff": "@@ -20,7 +20,7 @@ function useSearchSidebars(\n+listData: $ReadOnlyArray<SidebarInfo>,\n+searchState: SidebarSearchState,\n+setSearchState: SetState<SidebarSearchState>,\n- +searchIndex: SearchIndex,\n+ +onChangeSearchInputText: (text: string) => mixed,\n} {\nconst [searchState, setSearchState] = React.useState({\ntext: '',\n@@ -57,6 +57,16 @@ function useSearchSidebars(\nreturn index;\n}, [sidebarInfos, userInfos, viewerID]);\n+ const onChangeSearchInputText = React.useCallback(\n+ (text: string) => {\n+ setSearchState({\n+ text,\n+ results: new Set(searchIndex.getSearchResults(text)),\n+ });\n+ },\n+ [searchIndex, setSearchState],\n+ );\n+\nReact.useEffect(() => {\nsetSearchState(curState => ({\n...curState,\n@@ -65,8 +75,13 @@ function useSearchSidebars(\n}, [searchIndex, setSearchState]);\nreturn React.useMemo(\n- () => ({ listData, searchState, setSearchState, searchIndex }),\n- [listData, setSearchState, searchState, searchIndex],\n+ () => ({\n+ listData,\n+ searchState,\n+ setSearchState,\n+ onChangeSearchInputText,\n+ }),\n+ [listData, setSearchState, searchState, onChangeSearchInputText],\n);\n}\n" }, { "change_type": "MODIFY", "old_path": "native/chat/sidebar-list-modal.react.js", "new_path": "native/chat/sidebar-list-modal.react.js", "diff": "@@ -35,18 +35,9 @@ function SidebarListModal(props: Props): React.Node {\nlistData,\nsearchState,\nsetSearchState,\n- searchIndex,\n+ onChangeSearchInputText,\n} = useSearchSidebars(props.route.params.threadInfo);\n- const onChangeSearchText = React.useCallback(\n- (searchText: string) =>\n- setSearchState({\n- text: searchText,\n- results: new Set(searchIndex.getSearchResults(searchText)),\n- }),\n- [searchIndex, setSearchState],\n- );\n-\nconst searchTextInputRef = React.useRef();\nconst setSearchTextInputRef = React.useCallback(\nasync (textInput: ?React.ElementRef<typeof TextInput>) => {\n@@ -95,7 +86,7 @@ function SidebarListModal(props: Props): React.Node {\n<Modal>\n<Search\nsearchText={searchState.text}\n- onChangeText={onChangeSearchText}\n+ onChangeText={onChangeSearchInputText}\ncontainerStyle={styles.search}\nplaceholder=\"Search sidebars\"\nref={setSearchTextInputRef}\n" }, { "change_type": "MODIFY", "old_path": "web/modals/chat/sidebar-list-modal.react.js", "new_path": "web/modals/chat/sidebar-list-modal.react.js", "diff": "@@ -26,7 +26,7 @@ function SidebarListModal(props: Props): React.Node {\nlistData,\nsearchState,\nsetSearchState,\n- searchIndex,\n+ onChangeSearchInputText,\n} = useSearchSidebars(threadInfo);\nconst { popModal } = useModalContext();\n@@ -47,17 +47,6 @@ function SidebarListModal(props: Props): React.Node {\n[popModal, listData],\n);\n- const onChangeSearchText = React.useCallback(\n- (event: SyntheticEvent<HTMLInputElement>) => {\n- const searchText = event.currentTarget.value;\n- setSearchState({\n- text: searchText,\n- results: new Set(searchIndex.getSearchResults(searchText)),\n- });\n- },\n- [searchIndex, setSearchState],\n- );\n-\nconst clearQuery = React.useCallback(\n(event: SyntheticEvent<HTMLAnchorElement>) => {\nevent.preventDefault();\n@@ -78,6 +67,14 @@ function SidebarListModal(props: Props): React.Node {\n);\n}\n+ const handleOnChangeSearchText = React.useCallback(\n+ (event: SyntheticEvent<HTMLInputElement>) => {\n+ const { value } = event.currentTarget;\n+ onChangeSearchInputText(value);\n+ },\n+ [onChangeSearchInputText],\n+ );\n+\nreturn (\n<Modal name=\"Sidebars\" onClose={popModal}>\n<div\n@@ -93,7 +90,7 @@ function SidebarListModal(props: Props): React.Node {\ntype=\"text\"\nplaceholder=\"Search sidebars\"\nvalue={searchState.text}\n- onChange={onChangeSearchText}\n+ onChange={handleOnChangeSearchText}\n/>\n{clearQueryButton}\n</div>\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib, native, web] move onChangeSearch to hook Summary: move onChangeSearch to lib/hooks/ from native and web. Test Plan: Use the search sidebar feature in both native and web and confirm functionality still works as expected. Reviewers: atul, palys-swm, def-au1t Reviewed By: atul Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4057
129,184
25.05.2022 15:10:42
14,400
2f9948e9a30df83abe6332723014e754d351dfcc
[native] `codeVersion` -> 134
[ { "change_type": "MODIFY", "old_path": "native/android/app/build.gradle", "new_path": "native/android/app/build.gradle", "diff": "@@ -434,8 +434,8 @@ android {\napplicationId 'app.comm.android'\nminSdkVersion rootProject.ext.minSdkVersion\ntargetSdkVersion rootProject.ext.targetSdkVersion\n- versionCode 133\n- versionName '1.0.133'\n+ versionCode 134\n+ versionName '1.0.134'\nmissingDimensionStrategy 'react-native-camera', 'general'\nmultiDexEnabled true\n}\n" }, { "change_type": "MODIFY", "old_path": "native/cpp/CommonCpp/NativeModules/CommCoreModule.h", "new_path": "native/cpp/CommonCpp/NativeModules/CommCoreModule.h", "diff": "@@ -13,7 +13,7 @@ namespace comm {\nnamespace jsi = facebook::jsi;\nclass CommCoreModule : public facebook::react::CommCoreModuleSchemaCxxSpecJSI {\n- const int codeVersion{133};\n+ const int codeVersion{134};\nstd::unique_ptr<WorkerThread> databaseThread;\nstd::unique_ptr<WorkerThread> cryptoThread;\n" }, { "change_type": "MODIFY", "old_path": "native/ios/Comm/Info.debug.plist", "new_path": "native/ios/Comm/Info.debug.plist", "diff": "<key>CFBundlePackageType</key>\n<string>APPL</string>\n<key>CFBundleShortVersionString</key>\n- <string>1.0.133</string>\n+ <string>1.0.134</string>\n<key>CFBundleSignature</key>\n<string>????</string>\n<key>CFBundleVersion</key>\n- <string>133</string>\n+ <string>134</string>\n<key>LSApplicationQueriesSchemes</key>\n<array>\n<string>org-appextension-feature-password-management</string>\n" }, { "change_type": "MODIFY", "old_path": "native/ios/Comm/Info.release.plist", "new_path": "native/ios/Comm/Info.release.plist", "diff": "<key>CFBundlePackageType</key>\n<string>APPL</string>\n<key>CFBundleShortVersionString</key>\n- <string>1.0.133</string>\n+ <string>1.0.134</string>\n<key>CFBundleSignature</key>\n<string>????</string>\n<key>CFBundleVersion</key>\n- <string>133</string>\n+ <string>134</string>\n<key>LSApplicationQueriesSchemes</key>\n<array>\n<string>org-appextension-feature-password-management</string>\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[native] `codeVersion` -> 134
129,184
25.05.2022 15:49:34
14,400
40455fc82eeb0c8c92abe69ed79e8f2bea5eeb92
[yarn] Bump `ansi-regex` Summary: Takes `yarn audit` from 56->47 issues Test Plan: CI Reviewers: ashoat, palys-swm, def-au1t Subscribers: Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "yarn.lock", "new_path": "yarn.lock", "diff": "@@ -3733,17 +3733,17 @@ ansi-html@0.0.7:\nansi-regex@^2.0.0:\nversion \"2.1.1\"\nresolved \"https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df\"\n- integrity sha1-w7M6te42DYbg5ijwRorn7yfWVN8=\n+ integrity sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==\nansi-regex@^3.0.0:\n- version \"3.0.0\"\n- resolved \"https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz#ed0317c322064f79466c02966bddb605ab37d998\"\n- integrity sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=\n+ version \"3.0.1\"\n+ resolved \"https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.1.tgz#123d6479e92ad45ad897d4054e3c7ca7db4944e1\"\n+ integrity sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==\nansi-regex@^4.1.0:\n- version \"4.1.0\"\n- resolved \"https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.0.tgz#8b9f8f08cf1acb843756a839ca8c7e3168c51997\"\n- integrity sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==\n+ version \"4.1.1\"\n+ resolved \"https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.1.tgz#164daac87ab2d6f6db3a29875e2d1766582dabed\"\n+ integrity sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==\nansi-regex@^5.0.0, ansi-regex@^5.0.1:\nversion \"5.0.1\"\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[yarn] Bump `ansi-regex` Summary: Takes `yarn audit` from 56->47 issues Test Plan: CI Reviewers: ashoat, palys-swm, def-au1t Reviewed By: ashoat Subscribers: Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4128
129,179
27.05.2022 13:52:33
14,400
50a152a78c584830761063b41f1a0fabe99b130b
[web, lib] [refactor] move clear query to lib/hooks Summary: move clear query method to lib hooks. Test Plan: clear query functionality should work as it did before on web. This clear query wasn't implemented on native. Reviewers: atul, palys-swm, def-au1t Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "lib/hooks/search-sidebars.js", "new_path": "lib/hooks/search-sidebars.js", "diff": "@@ -21,6 +21,7 @@ function useSearchSidebars(\n+searchState: SidebarSearchState,\n+setSearchState: SetState<SidebarSearchState>,\n+onChangeSearchInputText: (text: string) => mixed,\n+ +clearQuery: (event: SyntheticEvent<HTMLAnchorElement>) => void,\n} {\nconst [searchState, setSearchState] = React.useState({\ntext: '',\n@@ -67,14 +68,29 @@ function useSearchSidebars(\n[searchIndex, setSearchState],\n);\n+ const clearQuery = React.useCallback(\n+ (event: SyntheticEvent<HTMLAnchorElement>) => {\n+ event.preventDefault();\n+ setSearchState({ text: '', results: new Set() });\n+ },\n+ [setSearchState],\n+ );\n+\nreturn React.useMemo(\n() => ({\nlistData,\nsearchState,\nsetSearchState,\nonChangeSearchInputText,\n+ clearQuery,\n}),\n- [listData, setSearchState, searchState, onChangeSearchInputText],\n+ [\n+ listData,\n+ setSearchState,\n+ searchState,\n+ onChangeSearchInputText,\n+ clearQuery,\n+ ],\n);\n}\n" }, { "change_type": "MODIFY", "old_path": "web/modals/chat/sidebar-list-modal.react.js", "new_path": "web/modals/chat/sidebar-list-modal.react.js", "diff": "@@ -25,7 +25,7 @@ function SidebarListModal(props: Props): React.Node {\nconst {\nlistData,\nsearchState,\n- setSearchState,\n+ clearQuery,\nonChangeSearchInputText,\n} = useSearchSidebars(threadInfo);\nconst { popModal } = useModalContext();\n@@ -47,14 +47,6 @@ function SidebarListModal(props: Props): React.Node {\n[popModal, listData],\n);\n- const clearQuery = React.useCallback(\n- (event: SyntheticEvent<HTMLAnchorElement>) => {\n- event.preventDefault();\n- setSearchState({ text: '', results: new Set() });\n- },\n- [setSearchState],\n- );\n-\nlet clearQueryButton = null;\nif (searchState.text) {\nclearQueryButton = (\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web, lib] [refactor] [ENG-536] move clear query to lib/hooks Summary: move clear query method to lib hooks. Test Plan: clear query functionality should work as it did before on web. This clear query wasn't implemented on native. Reviewers: atul, palys-swm, def-au1t Reviewed By: palys-swm Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4058
129,187
01.06.2022 05:13:44
14,400
fc22a7ffc480f3a2309f85a32c103a6306def98e
[keyserver] Run Docker as non-root user Summary: See [Linear task](https://linear.app/comm/issue/ENG-1076/update-node-dockerfile-to-not-run-as-root) Depends on D4177 Test Plan: Make sure `docker-compose down -v && docker-compose up --build` still works Reviewers: palys-swm, atul Subscribers: varun, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "keyserver/Dockerfile", "new_path": "keyserver/Dockerfile", "diff": "FROM node:16.13-bullseye\n-WORKDIR /app\n-\n#-------------------------------------------------------------------------------\n# STEP 0: INSTALL PREREQS\n# Install prereqs first so we don't have to reinstall them if anything changes\n@@ -12,53 +10,66 @@ RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y \\\nrsync \\\n&& rm -rf /var/lib/apt/lists/*\n+#-------------------------------------------------------------------------------\n+# STEP 1: DEVOLVE PRIVILEGES\n+# Create another user to run the rest of the commands\n+#-------------------------------------------------------------------------------\n+\n+RUN useradd -m comm\n+USER comm\n+WORKDIR /home/comm/app\n+\n+#-------------------------------------------------------------------------------\n+# STEP 2: INSTALL NVM\n# We use nvm to make sure we're running the right Node version\n-ENV NVM_DIR /root/.nvm\n+#-------------------------------------------------------------------------------\n+\n+ENV NVM_DIR /home/comm/.nvm\nRUN curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh \\\n| bash\n#-------------------------------------------------------------------------------\n-# STEP 1: YARN CLEANINSTALL\n+# STEP 3: YARN CLEANINSTALL\n# We run yarn cleaninstall before copying most of the files in for build caching\n#-------------------------------------------------------------------------------\n# Copy in package.json and yarn.lock files\n-COPY package.json yarn.lock .\n-COPY keyserver/package.json keyserver/.flowconfig keyserver/\n-COPY lib/package.json lib/.flowconfig lib/\n-COPY web/package.json web/.flowconfig web/\n-COPY native/package.json native/.flowconfig native/\n-COPY landing/package.json landing/.flowconfig landing/\n+COPY --chown=comm package.json yarn.lock .\n+COPY --chown=comm keyserver/package.json keyserver/.flowconfig keyserver/\n+COPY --chown=comm lib/package.json lib/.flowconfig lib/\n+COPY --chown=comm web/package.json web/.flowconfig web/\n+COPY --chown=comm native/package.json native/.flowconfig native/\n+COPY --chown=comm landing/package.json landing/.flowconfig landing/\n# Copy in files needed for patch-package and pod-patch\n-COPY patches patches/\n-COPY native/ios/pod-patch native/ios/pod-patch/\n-COPY native/ios/Podfile native/ios/\n+COPY --chown=comm patches patches/\n+COPY --chown=comm native/ios/pod-patch native/ios/pod-patch/\n+COPY --chown=comm native/ios/Podfile native/ios/\n# Actually run yarn\nRUN yarn cleaninstall\n#-------------------------------------------------------------------------------\n-# STEP 2: WEBPACK BUILD\n+# STEP 4: WEBPACK BUILD\n# We do this first so Docker doesn't rebuild when only keyserver files change\n#-------------------------------------------------------------------------------\n-COPY lib lib/\n-COPY landing landing/\n+COPY --chown=comm lib lib/\n+COPY --chown=comm landing landing/\nRUN yarn workspace landing prod\n-COPY web web/\n+COPY --chown=comm web web/\nRUN yarn workspace web prod\n#-------------------------------------------------------------------------------\n-# STEP 3: COPY IN SOURCE FILES\n+# STEP 5: COPY IN SOURCE FILES\n# We run this later so the above layers are cached if only source files change\n#-------------------------------------------------------------------------------\n-COPY . .\n+COPY --chown=comm . .\n#-------------------------------------------------------------------------------\n-# STEP 4: RUN BUILD SCRIPTS\n+# STEP 6: RUN BUILD SCRIPTS\n# We need to populate keyserver/dist, among other things\n#-------------------------------------------------------------------------------\n@@ -66,10 +77,10 @@ COPY . .\nRUN yarn workspace keyserver prod-build\n#-------------------------------------------------------------------------------\n-# STEP 5: RUN THE SERVER\n+# STEP 7: RUN THE SERVER\n# Actually run the Node.js keyserver using nvm\n#-------------------------------------------------------------------------------\nEXPOSE 3000\n-WORKDIR /app/keyserver\n+WORKDIR /home/comm/app/keyserver\nCMD bash/run-prod.sh\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[keyserver] Run Docker as non-root user Summary: See [Linear task](https://linear.app/comm/issue/ENG-1076/update-node-dockerfile-to-not-run-as-root) Depends on D4177 Test Plan: Make sure `docker-compose down -v && docker-compose up --build` still works Reviewers: palys-swm, atul Reviewed By: atul Subscribers: varun, Adrian, yayabosh Differential Revision: https://phabricator.ashoat.com/D4178
129,185
07.06.2022 11:46:27
-7,200
5e7526cca2b4d76387bc98b579c880484d33bee1
[web] Fix multimedia `onRemove` event propagation Summary: Fix for multimedia remove issue: Test Plan: Try to upload and remove that multimedia on web. It should be removed without being opened. Reviewers: palys-swm, atul Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/media/multimedia.react.js", "new_path": "web/media/multimedia.react.js", "diff": "@@ -97,7 +97,8 @@ class Multimedia extends React.PureComponent<Props> {\n);\n}\n- remove: () => void = () => {\n+ remove: (event: SyntheticEvent<HTMLElement>) => void = event => {\n+ event.stopPropagation();\nconst { remove, pendingUpload } = this.props;\ninvariant(\nremove && pendingUpload,\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Fix multimedia `onRemove` event propagation Summary: Fix for multimedia remove issue: https://linear.app/comm/issue/ENG-1224/uploaded-media-are-displayed-in-fullscreen-modal-when-trying-to-remove Test Plan: Try to upload and remove that multimedia on web. It should be removed without being opened. Reviewers: palys-swm, atul Reviewed By: palys-swm Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phab.comm.dev/D4209
129,187
08.06.2022 00:22:47
-7,200
6576a659bdf279a80ecde77ab5b365b2a7107a23
[keyserver] GitHub Actions CI for Docker keyserver Summary: Linear task: [ENG-997](https://linear.app/comm/issue/ENG-997/add-node-keyserver-docker-build-to-ci) Test Plan: This diff is actually the test! Reviewers: atul Subscribers: palys-swm, Adrian, yayabosh
[ { "change_type": "ADD", "old_path": null, "new_path": ".github/workflows/docker_keyserver.yml", "diff": "+name: Docker keyserver CI\n+\n+on:\n+ push:\n+ branches: [master]\n+ paths-ignore:\n+ - 'native/**'\n+ - 'docs/**'\n+ - 'services/**'\n+\n+jobs:\n+ build:\n+ runs-on: ubuntu-18.04\n+\n+ steps:\n+ - uses: actions/checkout@v2\n+\n+ - name: Build Docker\n+ working-directory: ./keyserver\n+ run: touch .env && bash/dc.sh build --no-cache\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[keyserver] GitHub Actions CI for Docker keyserver Summary: Linear task: [ENG-997](https://linear.app/comm/issue/ENG-997/add-node-keyserver-docker-build-to-ci) Test Plan: This diff is actually the test! Reviewers: atul Reviewed By: atul Subscribers: palys-swm, Adrian, yayabosh Differential Revision: https://phab.comm.dev/D4239
129,184
02.06.2022 18:38:18
14,400
49e3bbd53c0f604c1d8d8990f66d66d22151bdf0
[lib] Rename `reduceThreadUpdates` => `generateOpsForThreadUpdates` Summary: More accurately reflects the behavior of the function Depends on D4197 Test Plan: No other occurences of "reduceThreadUpdates" in the codebase Reviewers: def-au1t, palys-swm Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "lib/reducers/thread-reducer.js", "new_path": "lib/reducers/thread-reducer.js", "diff": "@@ -52,7 +52,7 @@ import { setNewSessionActionType } from '../utils/action-utils';\nimport { getConfig } from '../utils/config';\nimport { sanitizeActionSecrets } from '../utils/sanitization';\n-function reduceThreadUpdates(\n+function generateOpsForThreadUpdates(\nthreadInfos: { +[id: string]: RawThreadInfo },\npayload: {\n+updatesResult: { +newUpdates: $ReadOnlyArray<ClientUpdateInfo>, ... },\n@@ -226,7 +226,7 @@ function reduceThreadInfos(\nthreadStoreOperations: [],\n};\n}\n- const threadStoreOperations = reduceThreadUpdates(\n+ const threadStoreOperations = generateOpsForThreadUpdates(\nstate.threadInfos,\naction.payload,\n);\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib] Rename `reduceThreadUpdates` => `generateOpsForThreadUpdates` Summary: More accurately reflects the behavior of the function --- Depends on D4197 Test Plan: No other occurences of "reduceThreadUpdates" in the codebase Reviewers: def-au1t, palys-swm Reviewed By: palys-swm Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phab.comm.dev/D4198
129,184
02.06.2022 18:53:38
14,400
0b7b96118692029255e016fc9c997ad54aed8723
[lib] Destructure some properties in `reduceThreadInfos` to improve readability Summary: Super minor noop refactor. Thought destructuring some properties would make things a little more readable. Depends on D4198 Test Plan: Noop Reviewers: palys-swm, def-au1t Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "lib/reducers/thread-reducer.js", "new_path": "lib/reducers/thread-reducer.js", "diff": "@@ -219,7 +219,8 @@ function reduceThreadInfos(\naction.type === processUpdatesActionType ||\naction.type === newThreadActionTypes.success\n) {\n- if (action.payload.updatesResult.newUpdates.length === 0) {\n+ const { newUpdates } = action.payload.updatesResult;\n+ if (newUpdates.length === 0) {\nreturn {\nthreadStore: state,\nnewThreadInconsistencies: [],\n@@ -240,18 +241,19 @@ function reduceThreadInfos(\nthreadStoreOperations,\n};\n} else if (action.type === updateSubscriptionActionTypes.success) {\n+ const { threadID, subscription } = action.payload;\nconst newThreadInfo = {\n- ...state.threadInfos[action.payload.threadID],\n+ ...state.threadInfos[threadID],\ncurrentUser: {\n- ...state.threadInfos[action.payload.threadID].currentUser,\n- subscription: action.payload.subscription,\n+ ...state.threadInfos[threadID].currentUser,\n+ subscription,\n},\n};\nconst threadStoreOperations = [\n{\ntype: 'replace',\npayload: {\n- id: action.payload.threadID,\n+ id: threadID,\nthreadInfo: newThreadInfo,\n},\n},\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib] Destructure some properties in `reduceThreadInfos` to improve readability Summary: Super minor noop refactor. Thought destructuring some properties would make things a little more readable. --- Depends on D4198 Test Plan: Noop Reviewers: palys-swm, def-au1t Reviewed By: palys-swm Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phab.comm.dev/D4200
129,187
13.06.2022 14:47:15
25,200
ccb9976f761cdb58ac527c2aeb312872c89edd86
[keyserver] Type BackupConfig Summary: We should really have a type for this Test Plan: Just Flow for this one Reviewers: atul, yayabosh Subscribers: palys-swm, Adrian
[ { "change_type": "MODIFY", "old_path": "keyserver/src/cron/backups.js", "new_path": "keyserver/src/cron/backups.js", "diff": "@@ -16,9 +16,18 @@ const readdir = promisify(fs.readdir);\nconst lstat = promisify(fs.lstat);\nconst unlink = promisify(fs.unlink);\n+type BackupConfig = {\n+ +enabled: boolean,\n+ +directory: string,\n+};\n+\n+function getBackupConfig(): Promise<?BackupConfig> {\n+ return importJSON({ folder: 'facts', name: 'backups' });\n+}\n+\nasync function backupDB() {\nconst [backupConfig, dbConfig] = await Promise.all([\n- importJSON({ folder: 'facts', name: 'backups' }),\n+ getBackupConfig(),\ngetDBConfig(),\n]);\n@@ -185,7 +194,7 @@ function trySaveBackup(\n}\nasync function deleteOldestBackup() {\n- const backupConfig = await importJSON({ folder: 'facts', name: 'backups' });\n+ const backupConfig = await getBackupConfig();\ninvariant(backupConfig, 'backupConfig should be non-null');\nconst files = await readdir(backupConfig.directory);\nlet oldestFile;\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[keyserver] Type BackupConfig Summary: We should really have a type for this Test Plan: Just Flow for this one Reviewers: atul, yayabosh Reviewed By: atul, yayabosh Subscribers: palys-swm, Adrian Differential Revision: https://phab.comm.dev/D4262
129,187
15.06.2022 16:59:02
25,200
cc2960919b8cc354a8729e5425d3c56f0259c388
[keyserver] Extract deleteBackup Summary: Working on [ENG-1234](https://linear.app/comm/issue/ENG-1234/add-functionality-to-limit-disk-space-usage-of-keyserver-mysql-backups), which will also require deleting old backups. Figured I'd extract this code. Test Plan: Tested in combination with the next diff Reviewers: atul, yayabosh Subscribers: palys-swm, Adrian
[ { "change_type": "MODIFY", "old_path": "keyserver/src/cron/backups.js", "new_path": "keyserver/src/cron/backups.js", "diff": "@@ -194,19 +194,19 @@ function trySaveBackup(\n}\nasync function deleteOldestBackup() {\n- const [backupConfig, backupInfos] = await Promise.all([\n- getBackupConfig(),\n- getSortedBackupInfos(),\n- ]);\n-\n- invariant(backupConfig, 'backupConfig should be non-null');\n- if (backupInfos.length === 0) {\n+ const sortedBackupInfos = await getSortedBackupInfos();\n+ if (sortedBackupInfos.length === 0) {\nthrow new Error('no_backups_left');\n}\n+ const oldestFilename = sortedBackupInfos[0].filename;\n+ await deleteBackup(oldestFilename);\n+}\n- const oldestFilename = backupInfos[0].filename;\n+async function deleteBackup(filename: string) {\n+ const backupConfig = await getBackupConfig();\n+ invariant(backupConfig, 'backupConfig should be non-null');\ntry {\n- await unlink(`${backupConfig.directory}/${oldestFilename}`);\n+ await unlink(`${backupConfig.directory}/${filename}`);\n} catch (e) {\n// Check if it's already been deleted\nif (e.code !== 'ENOENT') {\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[keyserver] Extract deleteBackup Summary: Working on [ENG-1234](https://linear.app/comm/issue/ENG-1234/add-functionality-to-limit-disk-space-usage-of-keyserver-mysql-backups), which will also require deleting old backups. Figured I'd extract this code. Test Plan: Tested in combination with the next diff Reviewers: atul, yayabosh Reviewed By: yayabosh Subscribers: palys-swm, Adrian Differential Revision: https://phab.comm.dev/D4282
129,184
16.06.2022 23:22:55
25,200
a00c99afbd5284c79a0597942846f1d9349cfbd7
[native] `codeVersion` -> 135
[ { "change_type": "MODIFY", "old_path": "native/android/app/build.gradle", "new_path": "native/android/app/build.gradle", "diff": "@@ -434,8 +434,8 @@ android {\napplicationId 'app.comm.android'\nminSdkVersion rootProject.ext.minSdkVersion\ntargetSdkVersion rootProject.ext.targetSdkVersion\n- versionCode 134\n- versionName '1.0.134'\n+ versionCode 135\n+ versionName '1.0.135'\nmissingDimensionStrategy 'react-native-camera', 'general'\nmultiDexEnabled true\n}\n" }, { "change_type": "MODIFY", "old_path": "native/cpp/CommonCpp/NativeModules/CommCoreModule.h", "new_path": "native/cpp/CommonCpp/NativeModules/CommCoreModule.h", "diff": "@@ -13,7 +13,7 @@ namespace comm {\nnamespace jsi = facebook::jsi;\nclass CommCoreModule : public facebook::react::CommCoreModuleSchemaCxxSpecJSI {\n- const int codeVersion{134};\n+ const int codeVersion{135};\nstd::unique_ptr<WorkerThread> databaseThread;\nstd::unique_ptr<WorkerThread> cryptoThread;\n" }, { "change_type": "MODIFY", "old_path": "native/ios/Comm/Info.debug.plist", "new_path": "native/ios/Comm/Info.debug.plist", "diff": "<key>CFBundlePackageType</key>\n<string>APPL</string>\n<key>CFBundleShortVersionString</key>\n- <string>1.0.134</string>\n+ <string>1.0.135</string>\n<key>CFBundleSignature</key>\n<string>????</string>\n<key>CFBundleVersion</key>\n- <string>134</string>\n+ <string>135</string>\n<key>LSApplicationQueriesSchemes</key>\n<array>\n<string>org-appextension-feature-password-management</string>\n" }, { "change_type": "MODIFY", "old_path": "native/ios/Comm/Info.release.plist", "new_path": "native/ios/Comm/Info.release.plist", "diff": "<key>CFBundlePackageType</key>\n<string>APPL</string>\n<key>CFBundleShortVersionString</key>\n- <string>1.0.134</string>\n+ <string>1.0.135</string>\n<key>CFBundleSignature</key>\n<string>????</string>\n<key>CFBundleVersion</key>\n- <string>134</string>\n+ <string>135</string>\n<key>LSApplicationQueriesSchemes</key>\n<array>\n<string>org-appextension-feature-password-management</string>\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[native] `codeVersion` -> 135
129,196
07.06.2022 14:21:35
-7,200
3ec3e117814a1da00a239a018868297cceedc7a9
Prepare SQLiteQueryExecutor for single thread retrieval Summary: This diff extends SQLiteQueryExecutor API to include method to retrieve single thread based on its ID Test Plan: No testing plan. Further diffs will use this functionality and provide appropriate testing plan. Reviewers: palys-swm, atul, varun Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "native/cpp/CommonCpp/DatabaseManagers/DatabaseQueryExecutor.h", "new_path": "native/cpp/CommonCpp/DatabaseManagers/DatabaseQueryExecutor.h", "diff": "@@ -25,6 +25,7 @@ namespace jsi = facebook::jsi;\nclass DatabaseQueryExecutor {\npublic:\nvirtual std::string getDraft(std::string key) const = 0;\n+ virtual std::unique_ptr<Thread> getThread(std::string threadID) const = 0;\nvirtual void updateDraft(std::string key, std::string text) const = 0;\nvirtual bool moveDraft(std::string oldKey, std::string newKey) const = 0;\nvirtual std::vector<Draft> getAllDrafts() const = 0;\n" }, { "change_type": "MODIFY", "old_path": "native/cpp/CommonCpp/DatabaseManagers/SQLiteQueryExecutor.cpp", "new_path": "native/cpp/CommonCpp/DatabaseManagers/SQLiteQueryExecutor.cpp", "diff": "@@ -546,6 +546,11 @@ std::string SQLiteQueryExecutor::getDraft(std::string key) const {\nreturn (draft == nullptr) ? \"\" : draft->text;\n}\n+std::unique_ptr<Thread>\n+SQLiteQueryExecutor::getThread(std::string threadID) const {\n+ return SQLiteQueryExecutor::getStorage().get_pointer<Thread>(threadID);\n+}\n+\nvoid SQLiteQueryExecutor::updateDraft(std::string key, std::string text) const {\nDraft draft = {key, text};\nSQLiteQueryExecutor::getStorage().replace(draft);\n" }, { "change_type": "MODIFY", "old_path": "native/cpp/CommonCpp/DatabaseManagers/SQLiteQueryExecutor.h", "new_path": "native/cpp/CommonCpp/DatabaseManagers/SQLiteQueryExecutor.h", "diff": "@@ -23,6 +23,7 @@ public:\nSQLiteQueryExecutor();\nstatic void initialize(std::string &databasePath);\n+ std::unique_ptr<Thread> getThread(std::string threadID) const override;\nstd::string getDraft(std::string key) const override;\nvoid updateDraft(std::string key, std::string text) const override;\nbool moveDraft(std::string oldKey, std::string newKey) const override;\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
Prepare SQLiteQueryExecutor for single thread retrieval Summary: This diff extends SQLiteQueryExecutor API to include method to retrieve single thread based on its ID Test Plan: No testing plan. Further diffs will use this functionality and provide appropriate testing plan. Reviewers: palys-swm, atul, varun Reviewed By: palys-swm Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phab.comm.dev/D4234
129,184
21.06.2022 21:29:59
25,200
15d88b32ad15562cb2749952e32f9ccfda63f255
[lib] Get rid of `emptyArray` in `thread-reducer` Summary: This isn't used anywhere else and doesn't seem necessary? Seems like an unnecesary indirection instead of just placing an empty array (eg `[]`) Depends on D4195 Test Plan: Didn't test Reviewers: def-au1t, palys-swm Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "lib/reducers/thread-reducer.js", "new_path": "lib/reducers/thread-reducer.js", "diff": "@@ -127,14 +127,13 @@ function generateOpsForThreadUpdates(\nreturn threadOperations;\n}\n-const emptyArray = [];\nfunction findInconsistencies(\naction: BaseAction,\nbeforeStateCheck: { +[id: string]: RawThreadInfo },\nafterStateCheck: { +[id: string]: RawThreadInfo },\n): ClientThreadInconsistencyReportCreationRequest[] {\nif (_isEqual(beforeStateCheck)(afterStateCheck)) {\n- return emptyArray;\n+ return [];\n}\nreturn [\n{\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib] Get rid of `emptyArray` in `thread-reducer` Summary: This isn't used anywhere else and doesn't seem necessary? Seems like an unnecesary indirection instead of just placing an empty array (eg `[]`) --- Depends on D4195 Test Plan: Didn't test Reviewers: def-au1t, palys-swm Reviewed By: palys-swm Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phab.comm.dev/D4196
129,191
06.06.2022 13:52:41
-7,200
ee84b8052c24187beaba517b5a22a19fadc92bd0
[web] Introduce add user item Summary: This component will be used on friend and block add lists. {F80067} Test Plan: Render the component on a modal and check if it looks correctly and reacts to user click action Reviewers: def-au1t, atul, benschac Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "ADD", "old_path": null, "new_path": "web/settings/relationship/add-users-list-item.react.js", "diff": "+// @flow\n+\n+import * as React from 'react';\n+\n+import type { AccountUserInfo } from 'lib/types/user-types.js';\n+\n+import css from './add-users-list.css';\n+\n+type Props = {\n+ +userInfo: AccountUserInfo,\n+ +selectUser: (userID: string) => mixed,\n+};\n+\n+function AddUsersListItem(props: Props): React.Node {\n+ const { userInfo, selectUser } = props;\n+ const addUser = React.useCallback(() => selectUser(userInfo.id), [\n+ selectUser,\n+ userInfo.id,\n+ ]);\n+ return (\n+ <button className={css.addUserButton} onClick={addUser}>\n+ <div className={css.addUserButtonUsername}>{userInfo.username}</div>\n+ Add\n+ </button>\n+ );\n+}\n+\n+export default AddUsersListItem;\n" }, { "change_type": "ADD", "old_path": null, "new_path": "web/settings/relationship/add-users-list.css", "diff": "+.addUserButton {\n+ display: flex;\n+ flex-direction: row;\n+ justify-content: space-between;\n+ padding: 16px;\n+ color: var(--relationship-modal-color);\n+ font-size: var(--l-font-18);\n+ line-height: var(--line-height-display);\n+ background: transparent;\n+ border: none;\n+}\n+\n+.addUserButtonUsername {\n+ white-space: nowrap;\n+ overflow: hidden;\n+ text-overflow: ellipsis;\n+}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Introduce add user item Summary: This component will be used on friend and block add lists. {F80067} Test Plan: Render the component on a modal and check if it looks correctly and reacts to user click action Reviewers: def-au1t, atul, benschac Reviewed By: atul Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phab.comm.dev/D4266
129,200
15.06.2022 13:07:16
14,400
05ad755d06d0de0d97963fc2c4e8f3df52639328
[services][identity] clean up some redundancies Summary: just some small refactors. not adding jim since this is a pretty trivial diff Test Plan: ran cargo build Reviewers: palys-swm, karol-bisztyga Subscribers: ashoat, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/identity/src/config.rs", "new_path": "services/identity/src/config.rs", "diff": "@@ -31,5 +31,5 @@ pub enum Error {\nfn get_key_from_file<P: AsRef<Path>>(path: P) -> Result<Key, Error> {\nlet bytes = fs::read(path)?;\n- Key::from_bytes(&bytes).map_err(|e| Error::Pake(e))\n+ Key::from_bytes(&bytes).map_err(Error::Pake)\n}\n" }, { "change_type": "MODIFY", "old_path": "services/identity/src/database.rs", "new_path": "services/identity/src/database.rs", "diff": "@@ -134,12 +134,12 @@ impl DatabaseClient {\nlet valid = parse_valid_attribute(item.remove(\"valid\"))?;\nlet token = parse_token_attribute(item.remove(\"token\"))?;\nOk(Some(AccessToken {\n- user_id: user_id,\n- device_id: device_id,\n- token: token,\n- created: created,\n- auth_type: auth_type,\n- valid: valid,\n+ user_id,\n+ device_id,\n+ token,\n+ created,\n+ auth_type,\n+ valid,\n}))\n}\nOk(_) => {\n@@ -272,7 +272,7 @@ fn parse_created_attribute(\ns: Some(created), ..\n}) = attribute\n{\n- created.parse().map_err(|e| Error::InvalidTimestamp(e))\n+ created.parse().map_err(Error::InvalidTimestamp)\n} else {\nErr(Error::MissingAttribute)\n}\n" }, { "change_type": "MODIFY", "old_path": "services/identity/src/token.rs", "new_path": "services/identity/src/token.rs", "diff": "@@ -26,11 +26,11 @@ impl AccessToken {\nrng: &mut (impl Rng + CryptoRng),\n) -> Self {\nAccessToken {\n- user_id: user_id,\n- device_id: device_id,\n+ user_id,\n+ device_id,\ntoken: Alphanumeric.sample_string(rng, 512),\ncreated: Utc::now(),\n- auth_type: auth_type,\n+ auth_type,\nvalid: true,\n}\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services][identity] clean up some redundancies Summary: just some small refactors. not adding jim since this is a pretty trivial diff Test Plan: ran cargo build Reviewers: palys-swm, karol-bisztyga Reviewed By: palys-swm Subscribers: ashoat, Adrian, atul, yayabosh Differential Revision: https://phab.comm.dev/D4279
129,184
21.06.2022 16:13:09
25,200
e8adf23f4dc8d2885b3ef53ad133af4fcf41dbaf
[lib] Simplify conditional logic in `wrapActionPromise:loadingInfo` Summary: Noticed that some of the logic here could be simplified w/ optional chaining + nullish coalescing... so made those changes Test Plan: Close reading + flow Reviewers: palys-swm, def-au1t, yayabosh, ashoat Subscribers: ashoat, Adrian
[ { "change_type": "MODIFY", "old_path": "lib/utils/action-utils.js", "new_path": "lib/utils/action-utils.js", "diff": "@@ -60,13 +60,8 @@ function wrapActionPromise<\n): PromisedAction {\nconst loadingInfo: LoadingInfo = {\nfetchIndex: nextPromiseIndex++,\n- trackMultipleRequests: !!(\n- loadingOptions && loadingOptions.trackMultipleRequests\n- ),\n- customKeyName:\n- loadingOptions && loadingOptions.customKeyName\n- ? loadingOptions.customKeyName\n- : null,\n+ trackMultipleRequests: !!loadingOptions?.trackMultipleRequests,\n+ customKeyName: loadingOptions?.customKeyName || null,\n};\nreturn async (dispatch: Dispatch): Promise<void> => {\nconst startAction = startingPayload\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib] Simplify conditional logic in `wrapActionPromise:loadingInfo` Summary: Noticed that some of the logic here could be simplified w/ optional chaining + nullish coalescing... so made those changes Test Plan: Close reading + flow Reviewers: palys-swm, def-au1t, yayabosh, ashoat Reviewed By: palys-swm, yayabosh, ashoat Subscribers: ashoat, Adrian Differential Revision: https://phab.comm.dev/D4319
129,184
22.06.2022 12:34:58
25,200
9cf8c25cb67c77bac4257513c30b04edb42d20ba
[lib] Write some tests for `text-utils:trim(...)` Summary: There's only three functions in `text-utils` so might as well crank out some unit tests for all of them. Test Plan: Ran tests Reviewers: def-au1t, palys-swm, yayabosh Subscribers: ashoat, Adrian
[ { "change_type": "MODIFY", "old_path": "lib/utils/text-utils.js", "new_path": "lib/utils/text-utils.js", "diff": "@@ -24,8 +24,10 @@ function pluralize(\nfunction trimText(text: string, maxLength: number): string {\nif (text.length <= maxLength) {\nreturn text;\n+ } else if (maxLength <= 3) {\n+ return text.substring(0, maxLength);\n}\n- return text.substr(0, maxLength - 3) + '...';\n+ return `${text.substring(0, maxLength - 3)}...`;\n}\nfunction pluralizeAndTrim(\n" }, { "change_type": "MODIFY", "old_path": "lib/utils/text-utils.test.js", "new_path": "lib/utils/text-utils.test.js", "diff": "// @flow\n-import { pluralize } from './text-utils.js';\n+import { pluralize, trimText } from './text-utils.js';\ndescribe('pluralize(nouns, maxNumberOfNouns)', () => {\nit('should return an empty string when no words are given', () => {\n@@ -49,3 +49,68 @@ describe('pluralize(nouns, maxNumberOfNouns)', () => {\n);\n});\n});\n+\n+describe('trimText(text, maxLength)', () => {\n+ it('should return the original text when the text is shorter than maxLength', () => {\n+ expect(trimText('a', 2)).toBe('a');\n+ expect(trimText('a', 3)).toBe('a');\n+ expect(trimText('a', 4)).toBe('a');\n+\n+ expect(trimText('ab', 3)).toBe('ab');\n+ expect(trimText('ab', 4)).toBe('ab');\n+\n+ expect(trimText('abc', 4)).toBe('abc');\n+\n+ expect(trimText('the quick brown fox jumps', 400)).toBe(\n+ 'the quick brown fox jumps',\n+ );\n+ });\n+\n+ it('should return the original text when the text length is equal to maxLength', () => {\n+ expect(trimText('a', 1)).toBe('a');\n+ expect(trimText('ab', 2)).toBe('ab');\n+ expect(trimText('abc', 3)).toBe('abc');\n+\n+ expect(trimText('the quick brown fox jumps', 25)).toBe(\n+ 'the quick brown fox jumps',\n+ );\n+ });\n+\n+ it('should return the first maxLength characters of the text when (maxLength <= 3)', () => {\n+ expect(trimText('the quick brown fox jumps', 0)).toBe('');\n+ expect(trimText('the quick brown fox jumps', 1)).toBe('t');\n+ expect(trimText('the quick brown fox jumps', 2)).toBe('th');\n+ expect(trimText('the quick brown fox jumps', 3)).toBe('the');\n+ });\n+\n+ it('should return ellipsized text when (text.length > maxLength) && (maxLength > 3)', () => {\n+ expect(trimText('the quick brown fox jumps', 4)).toBe('t...');\n+ expect(trimText('the quick brown fox jumps', 5)).toBe('th...');\n+ expect(trimText('the quick brown fox jumps', 6)).toBe('the...');\n+ expect(trimText('the quick brown fox jumps', 7)).toBe('the ...');\n+ expect(trimText('the quick brown fox jumps', 8)).toBe('the q...');\n+ expect(trimText('the quick brown fox jumps', 9)).toBe('the qu...');\n+ });\n+\n+ it(\"shouldn't return a string longer than maxLength\", () => {\n+ expect(trimText('', 0).length).toBeLessThanOrEqual(0);\n+ expect(trimText('a', 0).length).toBeLessThanOrEqual(0);\n+ expect(trimText('ab', 0).length).toBeLessThanOrEqual(0);\n+ expect(trimText('abc', 0).length).toBeLessThanOrEqual(0);\n+\n+ expect(trimText('', 1).length).toBeLessThanOrEqual(1);\n+ expect(trimText('a', 1).length).toBeLessThanOrEqual(1);\n+ expect(trimText('ab', 1).length).toBeLessThanOrEqual(1);\n+ expect(trimText('abc', 1).length).toBeLessThanOrEqual(1);\n+\n+ expect(trimText('', 2).length).toBeLessThanOrEqual(2);\n+ expect(trimText('a', 2).length).toBeLessThanOrEqual(2);\n+ expect(trimText('ab', 2).length).toBeLessThanOrEqual(2);\n+ expect(trimText('abc', 2).length).toBeLessThanOrEqual(2);\n+\n+ expect(trimText('', 3).length).toBeLessThanOrEqual(3);\n+ expect(trimText('a', 3).length).toBeLessThanOrEqual(3);\n+ expect(trimText('ab', 3).length).toBeLessThanOrEqual(3);\n+ expect(trimText('abc', 3).length).toBeLessThanOrEqual(3);\n+ });\n+});\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib] Write some tests for `text-utils:trim(...)` Summary: There's only three functions in `text-utils` so might as well crank out some unit tests for all of them. Test Plan: Ran tests Reviewers: def-au1t, palys-swm, yayabosh Reviewed By: palys-swm, yayabosh Subscribers: ashoat, Adrian Differential Revision: https://phab.comm.dev/D4328
129,184
22.06.2022 13:00:46
25,200
c200b83200bf719b6053305d2647b3e9a64da98d
[lib] Write some tests for `text-utils: pluralizeAndTrim(...)` Summary: Did `pluralize(...)` and `trim(...)` so might as well do `pluralizeAndTrim(...)` Test Plan: Ran tests Reviewers: def-au1t, palys-swm, yayabosh Subscribers: ashoat, Adrian
[ { "change_type": "MODIFY", "old_path": "lib/utils/text-utils.js", "new_path": "lib/utils/text-utils.js", "diff": "@@ -40,7 +40,7 @@ function pluralizeAndTrim(\nreturn text;\n}\n}\n- return pluralize(nouns, 1);\n+ return trimText(pluralize(nouns, 1), maxLength);\n}\nexport { pluralize, trimText, pluralizeAndTrim };\n" }, { "change_type": "MODIFY", "old_path": "lib/utils/text-utils.test.js", "new_path": "lib/utils/text-utils.test.js", "diff": "// @flow\n-import { pluralize, trimText } from './text-utils.js';\n+import { pluralize, trimText, pluralizeAndTrim } from './text-utils.js';\ndescribe('pluralize(nouns, maxNumberOfNouns)', () => {\nit('should return an empty string when no words are given', () => {\n@@ -19,39 +19,65 @@ describe('pluralize(nouns, maxNumberOfNouns)', () => {\nexpect(pluralize(['a', 'b', 'c'])).toBe('a, b, and c');\n});\n- it('should return \"X, Y, and {N-2} others\" when N (>=4) words are given', () => {\n+ it(\n+ 'should return \"X, Y, and {N-2} others\"' + ' when N (>=4) words are given',\n+ () => {\nexpect(pluralize(['a', 'b', 'c', 'd'])).toBe('a, b, and 2 others');\nexpect(pluralize(['a', 'b', 'c', 'd', 'e'])).toBe('a, b, and 3 others');\nexpect(pluralize(['a', 'b', 'c', 'd', 'e', 'f'])).toBe(\n'a, b, and 4 others',\n);\n- });\n+ },\n+ );\n- it('should return \"X, Y, and Z\" when three words are given and maxNumNouns = 3', () => {\n+ it(\n+ 'should return \"X, Y, and Z\"' +\n+ ' when three words are given and maxNumNouns = 3',\n+ () => {\nexpect(pluralize(['a', 'b', 'c'])).toBe('a, b, and c');\n- });\n+ },\n+ );\n- it('should return \"X and 2 others\" when three words are given and maxNumNouns = 2', () => {\n+ it(\n+ 'should return \"X and 2 others\"' +\n+ ' when three words are given and maxNumNouns = 2',\n+ () => {\nexpect(pluralize(['cat', 'dog', 'sheep'], 2)).toBe('cat and 2 others');\n- });\n+ },\n+ );\n- it('should return \"3 users\" when three words are given and maxNumNouns = 1', () => {\n+ it(\n+ 'should return \"3 users\"' +\n+ ' when three words are given and maxNumNouns = 1',\n+ () => {\nexpect(pluralize(['cat', 'dog', 'sheep'], 1)).toBe('3 users');\n- });\n+ },\n+ );\n- it('should return an empty string when three words are given and maxNumNouns = 0', () => {\n+ it(\n+ 'should return an empty string' +\n+ ' when three words are given and maxNumNouns = 0',\n+ () => {\nexpect(pluralize(['cat', 'dog', 'sheep'], 0)).toBe('');\n- });\n+ },\n+ );\n- it('should return \"A, B, C, and D\" when four words are given and maxNumNouns = 5', () => {\n+ it(\n+ 'should return \"A, B, C, and D\"' +\n+ ' when four words are given and maxNumNouns = 5',\n+ () => {\nexpect(pluralize(['cat', 'dog', 'sheep', 'moose'], 5)).toBe(\n'cat, dog, sheep, and moose',\n);\n- });\n+ },\n+ );\n});\ndescribe('trimText(text, maxLength)', () => {\n- it('should return the original text when the text is shorter than maxLength', () => {\n+ it(\n+ 'should return the original text' +\n+ ' when the text is shorter than maxLength',\n+ () => {\nexpect(trimText('a', 2)).toBe('a');\nexpect(trimText('a', 3)).toBe('a');\nexpect(trimText('a', 4)).toBe('a');\n@@ -64,9 +90,13 @@ describe('trimText(text, maxLength)', () => {\nexpect(trimText('the quick brown fox jumps', 400)).toBe(\n'the quick brown fox jumps',\n);\n- });\n+ },\n+ );\n- it('should return the original text when the text length is equal to maxLength', () => {\n+ it(\n+ 'should return the original text' +\n+ ' when the text length is equal to maxLength',\n+ () => {\nexpect(trimText('a', 1)).toBe('a');\nexpect(trimText('ab', 2)).toBe('ab');\nexpect(trimText('abc', 3)).toBe('abc');\n@@ -74,23 +104,32 @@ describe('trimText(text, maxLength)', () => {\nexpect(trimText('the quick brown fox jumps', 25)).toBe(\n'the quick brown fox jumps',\n);\n- });\n+ },\n+ );\n- it('should return the first maxLength characters of the text when (maxLength <= 3)', () => {\n+ it(\n+ 'should return the first maxLength characters of the text' +\n+ ' when (maxLength <= 3)',\n+ () => {\nexpect(trimText('the quick brown fox jumps', 0)).toBe('');\nexpect(trimText('the quick brown fox jumps', 1)).toBe('t');\nexpect(trimText('the quick brown fox jumps', 2)).toBe('th');\nexpect(trimText('the quick brown fox jumps', 3)).toBe('the');\n- });\n+ },\n+ );\n- it('should return ellipsized text when (text.length > maxLength) && (maxLength > 3)', () => {\n+ it(\n+ 'should return ellipsized text' +\n+ ' when (text.length > maxLength) && (maxLength > 3)',\n+ () => {\nexpect(trimText('the quick brown fox jumps', 4)).toBe('t...');\nexpect(trimText('the quick brown fox jumps', 5)).toBe('th...');\nexpect(trimText('the quick brown fox jumps', 6)).toBe('the...');\nexpect(trimText('the quick brown fox jumps', 7)).toBe('the ...');\nexpect(trimText('the quick brown fox jumps', 8)).toBe('the q...');\nexpect(trimText('the quick brown fox jumps', 9)).toBe('the qu...');\n- });\n+ },\n+ );\nit(\"shouldn't return a string longer than maxLength\", () => {\nexpect(trimText('', 0).length).toBeLessThanOrEqual(0);\n@@ -114,3 +153,74 @@ describe('trimText(text, maxLength)', () => {\nexpect(trimText('abc', 3).length).toBeLessThanOrEqual(3);\n});\n});\n+\n+describe('pluralizeAndTrim(text, maxLength)', () => {\n+ it('should return an empty string when nouns is an empty array', () => {\n+ expect(pluralizeAndTrim([], 0)).toBe('');\n+ expect(pluralizeAndTrim([], 10)).toBe('');\n+ });\n+\n+ it('should return an emptyString when maxLength is 0', () => {\n+ expect(pluralizeAndTrim(['a', 'b', 'c', 'd'], 0)).toBe('');\n+ });\n+\n+ it(\n+ 'should return the first element of the array' +\n+ ' when the array has only one element',\n+ () => {\n+ expect(pluralizeAndTrim(['a'], 10)).toBe('a');\n+ expect(pluralizeAndTrim(['a'], 0)).toBe('');\n+ },\n+ );\n+\n+ it(\n+ 'should return \"X and Y\"' +\n+ ' when (nouns.length === 2) and (\"X and Y\".length <= maxLength)',\n+ () => {\n+ expect(pluralizeAndTrim(['a', 'b'], 10)).toBe('a and b');\n+ },\n+ );\n+\n+ it(\n+ 'should return \"2 users\"' +\n+ ' when (nouns.length === 2) and (\"X and Y\".length > maxLength)',\n+ () => {\n+ expect(pluralizeAndTrim(['spongebob', 'squarepants'], 10)).toBe(\n+ '2 users',\n+ );\n+ },\n+ );\n+\n+ it(\n+ 'should return \"X, Y, and Z\"' +\n+ ' when there are three nouns and all three will fit within maxLength',\n+ () => {\n+ expect(pluralizeAndTrim(['cat', 'dog', 'sheep'], 20)).toBe(\n+ 'cat, dog, and sheep',\n+ );\n+ },\n+ );\n+\n+ it(\n+ 'should return \"X and 2 others\"' +\n+ ' when there are three nouns but only two will fit within maxLength',\n+ () => {\n+ expect(pluralizeAndTrim(['cat', 'dog', 'sheep'], 16)).toBe(\n+ 'cat and 2 others',\n+ );\n+ },\n+ );\n+\n+ it(\n+ 'should return \"3 users\"' +\n+ ' when there are three nouns but only one will fit within maxLength',\n+ () => {\n+ expect(pluralizeAndTrim(['cat', 'dog', 'sheep'], 10)).toBe('3 users');\n+ },\n+ );\n+\n+ it('should trim the pluralized string to fit within maxLength', () => {\n+ expect(pluralizeAndTrim(['cat', 'dog', 'sheep'], 4)).toBe('3...');\n+ expect(pluralizeAndTrim(['a', 'b', 'c', 'd'], 6)).toBe('4 u...');\n+ });\n+});\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib] Write some tests for `text-utils: pluralizeAndTrim(...)` Summary: Did `pluralize(...)` and `trim(...)` so might as well do `pluralizeAndTrim(...)` Test Plan: Ran tests Reviewers: def-au1t, palys-swm, yayabosh Reviewed By: palys-swm, yayabosh Subscribers: ashoat, Adrian Differential Revision: https://phab.comm.dev/D4329
129,191
06.06.2022 14:54:23
-7,200
3fc1f94f82fb5adad177b2650d049dd592c55250
[web] Prepare a list of users that should be displayed Summary: Create a list of users and sort it by username. Depends on D4269 Test Plan: Render the component and check if the list is sorted correctly. Reviewers: def-au1t, atul Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "MODIFY", "old_path": "web/settings/relationship/add-users-list.react.js", "new_path": "web/settings/relationship/add-users-list.react.js", "diff": "@@ -43,7 +43,6 @@ function AddUsersList(props: Props): React.Node {\nconst searchTextPresent = searchText.length > 0;\nconst userInfos = useSelector(state => state.userStore.userInfos);\n- // eslint-disable-next-line no-unused-vars\nconst mergedUserInfos = React.useMemo(() => {\nconst mergedInfos = {};\n@@ -69,6 +68,15 @@ function AddUsersList(props: Props): React.Node {\nuserStoreSearchResults,\n]);\n+ // eslint-disable-next-line no-unused-vars\n+ const sortedUsers = React.useMemo(\n+ () =>\n+ Object.keys(mergedUserInfos)\n+ .map(userID => mergedUserInfos[userID])\n+ .sort((user1, user2) => user1.username.localeCompare(user2.username)),\n+ [mergedUserInfos],\n+ );\n+\nreturn null;\n}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Prepare a list of users that should be displayed Summary: Create a list of users and sort it by username. Depends on D4269 Test Plan: Render the component and check if the list is sorted correctly. Reviewers: def-au1t, atul Reviewed By: atul Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phab.comm.dev/D4305
129,184
22.06.2022 15:15:21
25,200
79a5ee1c5c9c3a5992f5444b7afba8f1561c4e23
[lib] Rename `threadIsWatched` to `isThreadWatched` Summary: I think this is a better name. This is an "opinionated" change, so open to abandoning if others disagree. Depends on D4334 Test Plan: flow Reviewers: def-au1t, palys-swm, yayabosh Subscribers: ashoat, Adrian
[ { "change_type": "MODIFY", "old_path": "lib/reducers/message-reducer.js", "new_path": "lib/reducers/message-reducer.js", "diff": "@@ -112,7 +112,7 @@ function threadsToMessageIDsFromMessageInfos(\nreturn threads;\n}\n-function threadIsWatched(\n+function isThreadWatched(\nthreadID: string,\nthreadInfo: ?RawThreadInfo,\nwatchedIDs: $ReadOnlyArray<string>,\n@@ -162,7 +162,7 @@ function freshMessageStore(\nconst threadInfo = threadInfos[threadID];\nif (\nthreads[threadID] ||\n- !threadIsWatched(threadID, threadInfo, watchedIDs)\n+ !isThreadWatched(threadID, threadInfo, watchedIDs)\n) {\ncontinue;\n}\n@@ -289,7 +289,7 @@ function mergeNewMessages(\nconst unshimmedNewMessages = unshimMessageInfos(newMessageInfos);\nconst unshimmedNewMessagesOfWatchedThreads = unshimmedNewMessages.filter(\nmsg =>\n- threadIsWatched(\n+ isThreadWatched(\nmsg.threadID,\nthreadInfos[msg.threadID],\nwatchedThreadIDs,\n@@ -579,7 +579,7 @@ function updateMessageStoreWithLatestThreadInfos(\nmessageStoreOperations.push(...reassignMessagesOps);\nconst watchedIDs = [...threadWatcher.getWatchedIDs(), ...reassignedThreadIDs];\nconst watchedThreadInfos = _pickBy((threadInfo: RawThreadInfo) =>\n- threadIsWatched(threadInfo.id, threadInfo, watchedIDs),\n+ isThreadWatched(threadInfo.id, threadInfo, watchedIDs),\n)(threadInfos);\nconst filteredThreads = _pick(Object.keys(watchedThreadInfos))(\n@@ -601,7 +601,7 @@ function updateMessageStoreWithLatestThreadInfos(\nfor (const threadID in threadInfos) {\nconst threadInfo = threadInfos[threadID];\nif (\n- threadIsWatched(threadID, threadInfo, watchedIDs) &&\n+ isThreadWatched(threadID, threadInfo, watchedIDs) &&\n!filteredThreads[threadID]\n) {\nfilteredThreads[threadID] = {\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib] Rename `threadIsWatched` to `isThreadWatched` Summary: I think this is a better name. This is an "opinionated" change, so open to abandoning if others disagree. --- Depends on D4334 Test Plan: flow Reviewers: def-au1t, palys-swm, yayabosh Reviewed By: palys-swm, yayabosh Subscribers: ashoat, Adrian Differential Revision: https://phab.comm.dev/D4335
129,184
22.06.2022 15:48:31
25,200
8a9bef17c3834d98a484c07f9b79b184e98dc035
[lib] Return `mergeNewMessages(...)` directly where possible in `reduceMessageStore(...)` Summary: Basically D4337, but for all the other `mergeNewMessages(...)` callsites. This is just a noop refactor, trying to simplify `message-reducer` Depends on D4337 Test Plan: Close reading, flow Reviewers: def-au1t, palys-swm, yayabosh Subscribers: ashoat, Adrian
[ { "change_type": "MODIFY", "old_path": "lib/reducers/message-reducer.js", "new_path": "lib/reducers/message-reducer.js", "diff": "@@ -726,16 +726,12 @@ function reduceMessageStore(\naction.payload.messagesResult.truncationStatuses,\n);\n- const {\n- messageStoreOperations,\n- messageStore: mergedMessageStore,\n- } = mergeNewMessages(\n+ return mergeNewMessages(\nmessageStore,\nmessagesResult.rawMessageInfos,\nmessagesResult.truncationStatuses,\nnewThreadInfos,\n);\n- return { messageStoreOperations, messageStore: mergedMessageStore };\n} else if (action.type === processUpdatesActionType) {\nif (action.payload.updatesResult.newUpdates.length === 0) {\nreturn { messageStoreOperations: [], messageStore };\n@@ -769,29 +765,21 @@ function reduceMessageStore(\naction.type === processMessagesActionType\n) {\nconst { messagesResult } = action.payload;\n- const {\n- messageStoreOperations,\n- messageStore: mergedMessageStore,\n- } = mergeNewMessages(\n+ return mergeNewMessages(\nmessageStore,\nmessagesResult.rawMessageInfos,\nmessagesResult.truncationStatuses,\nnewThreadInfos,\n);\n- return { messageStoreOperations, messageStore: mergedMessageStore };\n} else if (\naction.type === fetchSingleMostRecentMessagesFromThreadsActionTypes.success\n) {\n- const {\n- messageStoreOperations,\n- messageStore: mergedMessageStore,\n- } = mergeNewMessages(\n+ return mergeNewMessages(\nmessageStore,\naction.payload.rawMessageInfos,\naction.payload.truncationStatuses,\nnewThreadInfos,\n);\n- return { messageStoreOperations, messageStore: mergedMessageStore };\n} else if (\naction.type === fetchMessagesBeforeCursorActionTypes.success ||\naction.type === fetchMostRecentMessagesActionTypes.success\n@@ -831,102 +819,74 @@ function reduceMessageStore(\naction.payload.newMessageInfos,\naction.payload.updatesResult.newUpdates,\n);\n- const {\n- messageStoreOperations,\n- messageStore: mergedMessageStore,\n- } = mergeNewMessages(\n+ return mergeNewMessages(\nmessageStore,\nmessagesResult.rawMessageInfos,\nmessagesResult.truncationStatuses,\nnewThreadInfos,\n);\n- return { messageStoreOperations, messageStore: mergedMessageStore };\n} else if (action.type === registerActionTypes.success) {\nconst truncationStatuses = {};\nfor (const messageInfo of action.payload.rawMessageInfos) {\ntruncationStatuses[messageInfo.threadID] =\nmessageTruncationStatus.EXHAUSTIVE;\n}\n- const {\n- messageStoreOperations,\n- messageStore: mergedMessageStore,\n- } = mergeNewMessages(\n+ return mergeNewMessages(\nmessageStore,\naction.payload.rawMessageInfos,\ntruncationStatuses,\nnewThreadInfos,\n);\n- return { messageStoreOperations, messageStore: mergedMessageStore };\n} else if (\naction.type === changeThreadSettingsActionTypes.success ||\naction.type === removeUsersFromThreadActionTypes.success ||\naction.type === changeThreadMemberRolesActionTypes.success\n) {\n- const {\n- messageStoreOperations,\n- messageStore: mergedMessageStore,\n- } = mergeNewMessages(\n+ return mergeNewMessages(\nmessageStore,\naction.payload.newMessageInfos,\n{ [action.payload.threadID]: messageTruncationStatus.UNCHANGED },\nnewThreadInfos,\n);\n- return { messageStoreOperations, messageStore: mergedMessageStore };\n} else if (\naction.type === createEntryActionTypes.success ||\naction.type === saveEntryActionTypes.success\n) {\n- const {\n- messageStoreOperations,\n- messageStore: mergedMessageStore,\n- } = mergeNewMessages(\n+ return mergeNewMessages(\nmessageStore,\naction.payload.newMessageInfos,\n{ [action.payload.threadID]: messageTruncationStatus.UNCHANGED },\nnewThreadInfos,\n);\n- return { messageStoreOperations, messageStore: mergedMessageStore };\n} else if (action.type === deleteEntryActionTypes.success) {\nconst payload = action.payload;\nif (payload) {\n- const {\n- messageStoreOperations,\n- messageStore: mergedMessageStore,\n- } = mergeNewMessages(\n+ return mergeNewMessages(\nmessageStore,\npayload.newMessageInfos,\n{ [payload.threadID]: messageTruncationStatus.UNCHANGED },\nnewThreadInfos,\n);\n- return { messageStoreOperations, messageStore: mergedMessageStore };\n}\n} else if (action.type === restoreEntryActionTypes.success) {\nconst { threadID } = action.payload;\n- const {\n- messageStoreOperations,\n- messageStore: mergedMessageStore,\n- } = mergeNewMessages(\n+ return mergeNewMessages(\nmessageStore,\naction.payload.newMessageInfos,\n{ [threadID]: messageTruncationStatus.UNCHANGED },\nnewThreadInfos,\n);\n- return { messageStoreOperations, messageStore: mergedMessageStore };\n} else if (action.type === joinThreadActionTypes.success) {\nconst messagesResult = mergeUpdatesWithMessageInfos(\naction.payload.rawMessageInfos,\naction.payload.updatesResult.newUpdates,\n);\n- const {\n- messageStoreOperations,\n- messageStore: mergedMessageStore,\n- } = mergeNewMessages(\n+ return mergeNewMessages(\nmessageStore,\nmessagesResult.rawMessageInfos,\nmessagesResult.truncationStatuses,\nnewThreadInfos,\n);\n- return { messageStoreOperations, messageStore: mergedMessageStore };\n} else if (\naction.type === sendTextMessageActionTypes.started ||\naction.type === sendMultimediaMessageActionTypes.started\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[lib] Return `mergeNewMessages(...)` directly where possible in `reduceMessageStore(...)` Summary: Basically D4337, but for all the other `mergeNewMessages(...)` callsites. This is just a noop refactor, trying to simplify `message-reducer` --- Depends on D4337 Test Plan: Close reading, flow Reviewers: def-au1t, palys-swm, yayabosh Reviewed By: palys-swm, yayabosh Subscribers: ashoat, Adrian Differential Revision: https://phab.comm.dev/D4338
129,184
22.06.2022 19:11:44
25,200
4bea17c16501975a74cd012d1b50c8038f16c9d8
[web][landing] Fix miscellaneous CSS issues Summary: Ran the code analysis tool in IDE which surfaced some misc CSS issues. I'll label each issue inline. Depends on D4338 Test Plan: NA, careful reading Reviewers: palys-swm, def-au1t, yayabosh Subscribers: ashoat, Adrian
[ { "change_type": "MODIFY", "old_path": "landing/info-block.css", "new_path": "landing/info-block.css", "diff": ".description {\nline-height: 1.5;\nfont-weight: 400;\n- font-family: 'IBM Plex Sans';\n+ font-family: 'IBM Plex Sans', sans-serif;\n}\n" }, { "change_type": "MODIFY", "old_path": "landing/subscription-form.css", "new_path": "landing/subscription-form.css", "diff": "@@ -6,11 +6,8 @@ form {\nposition: relative;\nwidth: auto;\nborder: 1px solid white;\n- border-radius: 8px;\nborder-left: none;\n- border-top-left-radius: 0;\n- border-bottom-left-radius: 0;\n-\n+ border-radius: 0 8px 8px 0;\npadding-left: 20px;\npadding-right: 20px;\ncursor: pointer;\n@@ -54,7 +51,6 @@ form {\ninput.email_input {\nflex: 1;\n- border-radius: 8px;\npadding: 20px;\nbackground: rgba(11, 18, 27, 0.25);\n@@ -65,8 +61,7 @@ input.email_input {\nborder: 1px solid white;\nborder-right: none;\n- border-top-right-radius: 0;\n- border-bottom-right-radius: 0;\n+ border-radius: 8px 0 0 8px;\noutline: none;\nmargin-inline: 0;\ntransition: 300ms;\n" }, { "change_type": "MODIFY", "old_path": "web/components/menu.css", "new_path": "web/components/menu.css", "diff": "@@ -38,12 +38,10 @@ button.menuAction {\nbackground-color: transparent;\npadding: 12px 16px;\nline-height: 1.5;\n- background-color: transparent;\nborder: none;\ncursor: pointer;\ndisplay: flex;\nalign-items: center;\n- color: inherit;\nfont-size: inherit;\n}\n" }, { "change_type": "MODIFY", "old_path": "web/theme.css", "new_path": "web/theme.css", "diff": "--app-list-icon-disabled-color: var(--shades-white-80);\n--account-settings-label: var(--shades-black-60);\n--account-button-color: var(--violet-dark-100);\n- --chat-thread-list-color-active: var(--shades-of-white-60);\n+ --chat-thread-list-color-active: var(--shades-white-60);\n--chat-thread-list-menu-color: var(--shades-white-60);\n--chat-thread-list-menu-bg: var(--shades-black-80);\n--chat-thread-list-menu-active-color: var(--shades-white-60);\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web][landing] Fix miscellaneous CSS issues Summary: Ran the code analysis tool in IDE which surfaced some misc CSS issues. I'll label each issue inline. --- Depends on D4338 Test Plan: NA, careful reading Reviewers: palys-swm, def-au1t, yayabosh Reviewed By: palys-swm, yayabosh Subscribers: ashoat, Adrian Differential Revision: https://phab.comm.dev/D4339
129,190
27.06.2022 12:09:42
-7,200
5c6ae6d154c327cfa93f9cd601ca7912f505650d
[services] Tests - Add tools Summary: Depends on D4164 Adding tools with one function: `generate_nbytes`. It returns `n` bytes (that are the same). Test Plan: this doesn't do anything on its own. Tests can be built. Reviewers: palys-swm, geekbrother, varun Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "ADD", "old_path": null, "new_path": "services/commtest/tests/lib/tools.rs", "diff": "+use bytesize::ByteSize;\n+\n+#[allow(dead_code)]\n+pub fn generate_nbytes(number_of_bytes: usize, predefined_byte_value: Option<u8>) -> Vec<u8> {\n+ let byte_value = predefined_byte_value.unwrap_or(b'A');\n+ return vec![byte_value; number_of_bytes];\n+}\n+\n+#[derive(\n+ Debug, derive_more::Display, derive_more::From, derive_more::Error,\n+)]\n+pub enum Error {\n+ #[display(...)]\n+ Proto(std::io::Error),\n+ #[display(...)]\n+ Tonic(tonic::transport::Error),\n+ #[display(...)]\n+ TonicStatus(tonic::Status),\n+}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Tests - Add tools Summary: Depends on D4164 Adding tools with one function: `generate_nbytes`. It returns `n` bytes (that are the same). Test Plan: this doesn't do anything on its own. Tests can be built. Reviewers: palys-swm, geekbrother, varun Reviewed By: palys-swm, varun Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phab.comm.dev/D4225
129,190
27.06.2022 12:09:44
-7,200
0b9ee720e5ac10272d4f531b4ce63e64d32887b2
[services] Tests - Add create new backup Summary: Depends on D4225 Adding a script for creating a new backup. Test Plan: This, for now, doesn't do anything. Reviewers: ashoat, palys-swm, varun Subscribers: jimpo, ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "ADD", "old_path": null, "new_path": "services/commtest/tests/backup/create_new_backup.rs", "diff": "+#[path = \"./backup_utils.rs\"]\n+mod backup_utils;\n+#[path = \"../lib/tools.rs\"]\n+mod tools;\n+\n+use crate::backup_utils::{\n+ proto::create_new_backup_request::Data::*, proto::CreateNewBackupRequest,\n+ BackupData, BackupServiceClient,\n+};\n+\n+use tonic::Request;\n+\n+use crate::tools::generate_nbytes;\n+use crate::tools::Error;\n+\n+pub async fn run(\n+ client: &mut BackupServiceClient<tonic::transport::Channel>,\n+ backup_data: &BackupData,\n+) -> Result<String, Error> {\n+ println!(\"create new backup\");\n+ let cloned_user_id = backup_data.user_id.clone();\n+ let cloned_device_id = backup_data.device_id.clone();\n+ let cloned_backup_chunk_sizes = backup_data.backup_item.chunks_sizes.clone();\n+ let outbound = async_stream::stream! {\n+ println!(\" - sending user id\");\n+ let request = CreateNewBackupRequest {\n+ data: Some(UserId(cloned_user_id)),\n+ };\n+ yield request;\n+ println!(\" - sending device id\");\n+ let request = CreateNewBackupRequest {\n+ data: Some(DeviceId(cloned_device_id)),\n+ };\n+ yield request;\n+ println!(\" - sending key entropy\");\n+ let request = CreateNewBackupRequest {\n+ data: Some(KeyEntropy(vec![65,66,67,68])),\n+ };\n+ yield request;\n+ println!(\" - sending data hash\");\n+ // todo calculate the real hash, this is a mocked value\n+ let request = CreateNewBackupRequest {\n+ data: Some(NewCompactionHash(vec![68,67,66,65,66])),\n+ };\n+ yield request;\n+ for chunk_size in cloned_backup_chunk_sizes {\n+ println!(\" - sending data chunk {}\", chunk_size);\n+ let request = CreateNewBackupRequest {\n+ data: Some(NewCompactionChunk(generate_nbytes(chunk_size, None))),\n+ };\n+ yield request;\n+ }\n+ };\n+\n+ let mut backup_id: String = String::new();\n+ let response = client.create_new_backup(Request::new(outbound)).await?;\n+ let mut inbound = response.into_inner();\n+ while let Some(response) = inbound.message().await? {\n+ if !response.backup_id.is_empty() {\n+ assert!(\n+ backup_id.is_empty(),\n+ \"backup id should be returned only once\"\n+ );\n+ backup_id = response.backup_id;\n+ }\n+ }\n+ assert!(\n+ !backup_id.is_empty(),\n+ \"could not get a backup id from the server\"\n+ );\n+ Ok(backup_id)\n+}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Tests - Add create new backup Summary: Depends on D4225 Adding a script for creating a new backup. Test Plan: This, for now, doesn't do anything. Reviewers: ashoat, palys-swm, varun Reviewed By: palys-swm, varun Subscribers: jimpo, ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phab.comm.dev/D4165
129,190
27.06.2022 12:09:47
-7,200
4605babb58c12a8000a72a828e514bcbf8744a7b
[services] Tests - Add send log Summary: Depends on D4165 Adding a script for sending log. Test Plan: This, for now, doesn't do anything. Reviewers: ashoat, palys-swm, varun Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "ADD", "old_path": null, "new_path": "services/commtest/tests/backup/send_log.rs", "diff": "+#[path = \"./backup_utils.rs\"]\n+mod backup_utils;\n+#[path = \"../lib/tools.rs\"]\n+mod tools;\n+\n+use crate::backup_utils::{\n+ proto::send_log_request::Data::*, proto::SendLogRequest, BackupServiceClient,\n+};\n+\n+use tonic::Request;\n+\n+use crate::backup_utils::BackupData;\n+use crate::tools::generate_nbytes;\n+use crate::tools::Error;\n+\n+pub async fn run(\n+ client: &mut BackupServiceClient<tonic::transport::Channel>,\n+ backup_data: &BackupData,\n+ log_index: usize,\n+) -> Result<String, Error> {\n+ println!(\"send log\");\n+ let cloned_user_id = backup_data.user_id.clone();\n+ let cloned_backup_id = backup_data.backup_item.id.clone();\n+ let cloned_log_sizes = backup_data.log_items[log_index].chunks_sizes.clone();\n+ let outbound = async_stream::stream! {\n+ println!(\" - sending user id\");\n+ let request = SendLogRequest {\n+ data: Some(UserId(cloned_user_id)),\n+ };\n+ yield request;\n+ println!(\" - sending backup id\");\n+ let request = SendLogRequest {\n+ data: Some(BackupId(cloned_backup_id)),\n+ };\n+ yield request;\n+ println!(\" - sending log hash\");\n+ let request = SendLogRequest {\n+ data: Some(LogHash(vec![65,66,67,66+(log_index as u8)])),\n+ };\n+ yield request;\n+ println!(\" - sending log data\");\n+ for log_size in cloned_log_sizes {\n+ println!(\" - sending log data {}\", log_size);\n+ let request = SendLogRequest {\n+ data: Some(LogData(generate_nbytes(log_size, None))),\n+ };\n+ yield request;\n+ }\n+ };\n+\n+ let response = client.send_log(Request::new(outbound)).await?;\n+ let inbound = response.into_inner();\n+ println!(\"send log response: {:?}\", inbound.log_checkpoint);\n+ Ok(inbound.log_checkpoint)\n+}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Tests - Add send log Summary: Depends on D4165 Adding a script for sending log. Test Plan: This, for now, doesn't do anything. Reviewers: ashoat, palys-swm, varun Reviewed By: palys-swm, varun Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phab.comm.dev/D4166
129,190
27.06.2022 12:09:49
-7,200
6ae9b544bcc40848bc5554afeb356f7aae00f8c8
[services] Tests - Add byte size crate Summary: Depends on D4166 Adding `bytesize` crate Test Plan: None, this is not used yet, the project can still be built. Reviewers: palys-swm, varun, geekbrother, ashoat Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/commtest/Cargo.lock", "new_path": "services/commtest/Cargo.lock", "diff": "@@ -35,6 +35,12 @@ version = \"1.1.0\"\nsource = \"registry+https://github.com/rust-lang/crates.io-index\"\nchecksum = \"c4872d67bab6358e59559027aa3b9157c53d9358c51423c17554809a8858e0f8\"\n+[[package]]\n+name = \"bytesize\"\n+version = \"1.1.0\"\n+source = \"registry+https://github.com/rust-lang/crates.io-index\"\n+checksum = \"6c58ec36aac5066d5ca17df51b3e70279f5670a72102f5752cb7e7c856adfc70\"\n+\n[[package]]\nname = \"cfg-if\"\nversion = \"1.0.0\"\n@@ -45,6 +51,7 @@ checksum = \"baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd\"\nname = \"commtest\"\nversion = \"0.1.0\"\ndependencies = [\n+ \"bytesize\",\n\"derive_more\",\n\"tonic-build\",\n]\n" }, { "change_type": "MODIFY", "old_path": "services/commtest/Cargo.toml", "new_path": "services/commtest/Cargo.toml", "diff": "@@ -4,6 +4,7 @@ version = \"0.1.0\"\nedition = \"2021\"\n[dependencies]\n+bytesize = \"1.1.0\"\n[build-dependencies]\ntonic-build = \"0.6\"\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Tests - Add byte size crate Summary: Depends on D4166 Adding `bytesize` crate Test Plan: None, this is not used yet, the project can still be built. Reviewers: palys-swm, varun, geekbrother, ashoat Reviewed By: palys-swm, varun Subscribers: ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phab.comm.dev/D4227
129,190
27.06.2022 12:09:56
-7,200
df941b8c438c469e412fb0b5b7bde7628219f452
[services] Backup - Fix data size database limit Summary: Depends on D4232 The database limit is invalid. I found out in the docs that it should be 400kb (link in the code). Test Plan: - Reviewers: palys-swm, ashoat Subscribers: varun, ashoat, palys-swm, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/backup/src/Constants.h", "new_path": "services/backup/src/Constants.h", "diff": "@@ -18,7 +18,9 @@ const std::string BACKUP_TABLE_NAME =\n// than the chunk limit, once we get the amount of data of size equal to the\n// limit, we wouldn't know if we should put this in the database right away or\n// wait for more data.\n-const size_t LOG_DATA_SIZE_DATABASE_LIMIT = 1 * 1024 * 1024;\n+// 400KB limit (KB, not KiB, that's why it's 1000 not 1024) -\n+// https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/ServiceQuotas.html\n+const size_t LOG_DATA_SIZE_DATABASE_LIMIT = 400 * 1000;\n} // namespace network\n} // namespace comm\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services] Backup - Fix data size database limit Summary: Depends on D4232 The database limit is invalid. I found out in the docs that it should be 400kb (link in the code). Test Plan: - Reviewers: palys-swm, ashoat Reviewed By: palys-swm, ashoat Subscribers: varun, ashoat, palys-swm, Adrian, atul, yayabosh Differential Revision: https://phab.comm.dev/D4233
129,191
13.06.2022 19:16:51
-7,200
cbbc1a7d19815144fa21d93fd1b82db23559b1c5
[web] Introduce block users modal Summary: This modal allows blocking users. Only users that are not blocked by the viewer can be blocked. {F82770} Depends on D4312 Test Plan: Render the modal and check if blocking users works correctly. Reviewers: def-au1t, atul Subscribers: ashoat, Adrian, yayabosh
[ { "change_type": "ADD", "old_path": null, "new_path": "web/settings/relationship/block-users-modal.react.js", "diff": "+// @flow\n+\n+import { faUserShield } from '@fortawesome/free-solid-svg-icons';\n+import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';\n+import * as React from 'react';\n+\n+import {\n+ relationshipActions,\n+ userRelationshipStatus,\n+} from 'lib/types/relationship-types.js';\n+\n+import AddUsersListModal from './add-users-list-modal.react.js';\n+\n+const excludedStatuses = new Set([\n+ userRelationshipStatus.BOTH_BLOCKED,\n+ userRelationshipStatus.BLOCKED_BY_VIEWER,\n+]);\n+\n+type Props = {\n+ +onClose: () => void,\n+};\n+\n+function BlockUsersModal(props: Props): React.Node {\n+ const { onClose } = props;\n+\n+ const buttonContent = (\n+ <div>\n+ <FontAwesomeIcon icon={faUserShield} />\n+ {' Block Users'}\n+ </div>\n+ );\n+\n+ return (\n+ <AddUsersListModal\n+ closeModal={onClose}\n+ name=\"Block Users\"\n+ excludedStatuses={excludedStatuses}\n+ confirmButtonContent={buttonContent}\n+ confirmButtonVariant=\"danger\"\n+ relationshipAction={relationshipActions.BLOCK}\n+ />\n+ );\n+}\n+\n+export default BlockUsersModal;\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[web] Introduce block users modal Summary: This modal allows blocking users. Only users that are not blocked by the viewer can be blocked. {F82770} Depends on D4312 Test Plan: Render the modal and check if blocking users works correctly. Reviewers: def-au1t, atul Reviewed By: atul Subscribers: ashoat, Adrian, yayabosh Differential Revision: https://phab.comm.dev/D4313
129,200
27.06.2022 02:57:48
14,400
a9bf0e442d0806779da81e1f7ff712d74b39f9bd
[services][identity] PAKE workflow enum Summary: This enum lets us determine if a PAKE login request is part of a registration or login workflow, so that we can send back the appropriate response struct Test Plan: cargo build worked Reviewers: jimpo, palys-swm, karol-bisztyga Subscribers: ashoat, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/identity/src/service.rs", "new_path": "services/identity/src/service.rs", "diff": "@@ -26,6 +26,11 @@ mod proto {\ntonic::include_proto!(\"identity\");\n}\n+enum PakeWorkflow {\n+ Registration,\n+ Login,\n+}\n+\n#[derive(derive_more::Constructor)]\npub struct MyIdentityService {\nconfig: Config,\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services][identity] PAKE workflow enum Summary: This enum lets us determine if a PAKE login request is part of a registration or login workflow, so that we can send back the appropriate response struct Test Plan: cargo build worked Reviewers: jimpo, palys-swm, karol-bisztyga Reviewed By: palys-swm Subscribers: ashoat, Adrian, atul, yayabosh Differential Revision: https://phab.comm.dev/D4360
129,200
24.06.2022 09:14:25
14,400
0867427da96b7e27a862b4bd5b7a8a0f498319cd
[services][identity] helper function to start PAKE login Summary: fetch registration data from database, generate challenge for user, return challenge or error Test Plan: tested with method that calls this helper function Reviewers: palys-swm, jimpo, karol-bisztyga Subscribers: ashoat, Adrian, atul, yayabosh
[ { "change_type": "MODIFY", "old_path": "services/identity/src/service.rs", "new_path": "services/identity/src/service.rs", "diff": "use chrono::Utc;\nuse constant_time_eq::constant_time_eq;\nuse futures_core::Stream;\n+use opaque_ke::{\n+ CredentialFinalization, CredentialRequest, ServerLogin,\n+ ServerLoginStartParameters,\n+};\nuse rand::rngs::OsRng;\nuse rand::{CryptoRng, Rng};\nuse rusoto_core::RusotoError;\n@@ -13,6 +17,7 @@ use tonic::{Request, Response, Status};\nuse tracing::{error, info, instrument};\nuse crate::database::DatabaseClient;\n+use crate::opaque::Cipher;\nuse crate::token::{AccessTokenData, AuthType};\nuse crate::{config::Config, database::Error};\n@@ -23,7 +28,12 @@ use proto::{\nlogin_request::Data::WalletLoginRequest,\nlogin_response::Data::PakeLoginResponse,\nlogin_response::Data::WalletLoginResponse,\n- pake_login_response::Data::AccessToken, LoginRequest, LoginResponse,\n+ pake_login_request::Data::PakeCredentialFinalization,\n+ pake_login_request::Data::PakeCredentialRequestAndUserId,\n+ pake_login_response::Data::AccessToken,\n+ pake_login_response::Data::PakeCredentialResponse, LoginRequest,\n+ LoginResponse,\n+ PakeCredentialRequestAndUserId as PakeCredentialRequestAndUserIdStruct,\nPakeLoginResponse as PakeLoginResponseStruct, RegistrationRequest,\nRegistrationResponse, VerifyUserTokenRequest, VerifyUserTokenResponse,\nWalletLoginRequest as WalletLoginRequestStruct,\n@@ -275,3 +285,78 @@ async fn wallet_login_helper(\nErr(e) => Err(e),\n}\n}\n+\n+async fn pake_login_start(\n+ config: Config,\n+ client: DatabaseClient,\n+ user_id: &str,\n+ pake_credential_request: &[u8],\n+ num_messages_received: u8,\n+ pake_workflow: PakeWorkflow,\n+) -> Result<(PakeLoginResponseStruct, ServerLogin<Cipher>), Status> {\n+ if (num_messages_received != 0\n+ && matches!(pake_workflow, PakeWorkflow::Login))\n+ || (num_messages_received != 1\n+ && matches!(pake_workflow, PakeWorkflow::Registration))\n+ {\n+ error!(\"Too many messages received in stream, aborting\");\n+ return Err(Status::aborted(\"please retry\"));\n+ }\n+ if user_id.is_empty() {\n+ error!(\"Incomplete data: user ID not provided\");\n+ return Err(Status::aborted(\"user not found\"));\n+ }\n+ let server_registration =\n+ match client.get_pake_registration(user_id.to_string()).await {\n+ Ok(Some(r)) => r,\n+ Ok(None) => {\n+ return Err(Status::not_found(\"user not found\"));\n+ }\n+ Err(e) => match e {\n+ Error::RusotoGet(RusotoError::Service(\n+ GetItemError::ResourceNotFound(_),\n+ ))\n+ | Error::RusotoGet(RusotoError::Credentials(_)) => {\n+ return Err(Status::failed_precondition(\"internal error\"));\n+ }\n+ Error::RusotoGet(_) => {\n+ return Err(Status::unavailable(\"please retry\"));\n+ }\n+ e => {\n+ error!(\"Encountered an unexpected error: {}\", e);\n+ return Err(Status::failed_precondition(\"unexpected error\"));\n+ }\n+ },\n+ };\n+ let credential_request =\n+ CredentialRequest::deserialize(pake_credential_request).map_err(|e| {\n+ error!(\"Failed to deserialize credential request: {}\", e);\n+ Status::invalid_argument(\"invalid message\")\n+ })?;\n+ match ServerLogin::start(\n+ &mut OsRng,\n+ server_registration,\n+ config.server_keypair.private(),\n+ credential_request,\n+ ServerLoginStartParameters::default(),\n+ ) {\n+ Ok(server_login_start_result) => Ok((\n+ PakeLoginResponseStruct {\n+ data: Some(PakeCredentialResponse(\n+ server_login_start_result.message.serialize().map_err(|e| {\n+ error!(\"Failed to serialize PAKE message: {}\", e);\n+ Status::failed_precondition(\"internal error\")\n+ })?,\n+ )),\n+ },\n+ server_login_start_result.state,\n+ )),\n+ Err(e) => {\n+ error!(\n+ \"Encountered a PAKE protocol error when starting login: {}\",\n+ e\n+ );\n+ Err(Status::aborted(\"server error\"))\n+ }\n+ }\n+}\n" } ]
JavaScript
BSD 3-Clause New or Revised License
comme2e/comm
[services][identity] helper function to start PAKE login Summary: fetch registration data from database, generate challenge for user, return challenge or error Test Plan: tested with method that calls this helper function Reviewers: palys-swm, jimpo, karol-bisztyga Reviewed By: palys-swm, karol-bisztyga Subscribers: ashoat, Adrian, atul, yayabosh Differential Revision: https://phab.comm.dev/D4350