Shape: community card#4261
Conversation
…unity-card # Conflicts: # Explorer/Assets/DCL/PluginSystem/Global/Global Plugins Settings.asset
…unity-card # Conflicts: # Explorer/Assets/DCL/Communities/Communities.asmdef
…unity-card # Conflicts: # Explorer/Assets/DCL/PluginSystem/Global/Global Plugins Settings.asset
…unity-card # Conflicts: # Explorer/Assets/DCL/Communities/Communities.asmdef
…unity-card # Conflicts: # Explorer/Assets/DCL/Communities/CommunitiesDataProvider/DTOs/GetCommunityMembersResponse.cs
sandrade-dcl
left a comment
There was a problem hiding this comment.
Thanks for the changes! I will approve and I will leave the comment where I tagged @QThund in order to him to give his feedback 👍
QThund
left a comment
There was a problem hiding this comment.
Good job man! Most of the comments are not so important but there is a pair of them that I think they are. Let's discuss it later.
QThund
left a comment
There was a problem hiding this comment.
Good work applying all the changes (I saw you even added the error messages Romi mentioned, nice!). Please read the comments and consider applying those few changes too.
…unity-card # Conflicts: # Explorer/Assets/DCL/Communities/Communities.asmdef # Explorer/Assets/DCL/Communities/CommunitiesBrowser/CommunitiesBrowserController.cs # Explorer/Assets/DCL/PluginSystem/Global/ExplorePanelPlugin.cs
DafGreco
left a comment
There was a problem hiding this comment.
✔️ PR reviewed and approved by QA on both platforms following instructions playing both happy and un-happy path
Some items are missing testing since I cannot corroborate the backend of this PR but the merge is needed in order to be tested . Approving PR.
* add alfa-communities feature flag * common base structure * add communities plugin * add communities plugin into Global Plugins Settgins asset * Create a new Communities section in Explorer menu (#4155) * fix conficts from previous merge * First iteration of the data provider for Communities features * Communities data provider instantiated in plugin and passed to view * Added the member value to the CommunityMemberRole enum * data provider async fix * Added Serializable attribute to DTOs and replaced class with struct in internal data * Added GetCommunity and SetMemberRole methods and removed others GetCommunityPhotos, GetCommunityPlaces and GetCommunityEvents removed. * Added extra fields to members from GetOnlineCommunityMembers response * added missing memberCount field + None value for CommunityMemberRole * added name arg in GetUserCommunitiesAsync * change totalPages field by totalAmount * Several agreed changes * Add textures to Communities and Common folders. Organise and rename a few assets. Update atlases. * Delete duplicated asset. * Move asset to correct folder. * Make asset sliceable. * Add missing texture * Add textures for the new options of the context menu * Update empty events and photos images * Revert "Delete duplicated asset." This reverts commit 0d44362. * Delete duplicated warning asset * Add and update modal images * Add Communities icon * Update controls texture and prefab * Update modal image for when deleting something * Delete texture that won't be necessary * fix: Try to fix the masks issue (renaming + updating atlases) * Revert "fix: Try to fix the masks issue (renaming + updating atlases)" This reverts commit 115086c. * Update Atlas.spriteatlasv2.meta * [SHAPE-UP] Communities (Communities Browser) (#4199) * Added basic animations for the new explorer section * Unlock cursor when the explore section is open * Update CommunitiesBrowser.prefab * Create results container * Create my communities side section * Update browser prefab * Starting testing LoopList and LoopGrid components * Mock My Communities section * Mock My Communities section (II) * Update CommunitiesBrowserController.cs * improve fake data * missing conflicts * Mock results section * implemented infinite scroll for results * fix conflicts * implemented view all my communities * implemented search * Minor fixes * fix conflicts from base latest changes * Added new info into results community card * add isLive mark * make the cards clickable buttons to open/join a community * implemented join community action * Added mutal friends in the results card * some improvements * add live mark into my community card * Update CommunitiesBrowser.prefab * several fixes * Apply feedback: Split communities browser in several prefabs * Apply feedback: Refactor relationship between controllers and views * Apply feedback: AddRange * Apply feedback: Extract "Results for '{searchText}'" into a constant * Apply feedback: Extract "{formattedCount} members" into a constant * Apply feedback: Cache rolesToInclude filters * Make the search bar apply the search when submit + Show communities counter always * Add BETA label in the Communities section button * Update Communities icon in the section button (+ prepare animator) * Apply feedback: Fix event names * Apply feedback: Use of UniTaskVoid * Apply feedback: Use SetSearchBarClearButtonActive from the view * Apply feedback: Create IsResultsScrollPositionAtBottom view property * Apply feedback: Modify SetUserRole() * Update CommunitiesBrowserController.cs * Apply feedback: Move loop list/grid management to the view * add hover/imhover animations for results card * Create CommunitiesDataProvider * [SHAPE-UP] Communities (GET Communities endpoint integration) (#4321) * Add onlyMemberOf param into GetUserCommunitiesAsync * integrate GetUserCommunitiesAsync * Manage errors notifications * Manage errors notifications (II) * add default sprite for communities without thumbnail * Manage the case for when join a community fails * apply feedback: Make use of SuppressToResultAsync * Upload new textures. Delete unused ones. * Update LeaveRedIcn.png * Update assets * Rename and move the imag to the get a name prompt. * Update default thumbnail texture * Shape: community card (#4261) * Fixes after the merge from dev, it includes CommunitiesDataProvider.asmdef cleanup Some community UI classes adapted to use the ProfileRepositoryWrapper instead of the ViewDependencies. * change communities base url * Shape: community card - places (#4368) * Community conversation: New chat panel view (#4178) (#4336) * Added topics or community id to the multiplayer messages It requires the latest version of our livekit library. For now, it is sending custom-topic in the private messages. * Using the new livekit package version from git Added a new prefab to show the title of a community conversation. Added a new prefab to show the conversation icon in the chat conversation toolbar. Now adding a channel has been split into 3 to allow different type of data to be provided depending on the type of conversation. IProfileThumbnailCache renamed to IThumbnailCache, as an attempt to make it more generic. IThumbnailCache is used for getting the image of the community asynchronously. Now the multiplayer bus handles community conversation messages too. Now community messages send a topic along with the messages. Messages are sent to a special user created server-side which resends them to members of the community specified in the topic. Now a new conversation is added to the chat when the user logs in for each community he belongs to. Multiple users can communicate using a community conversation. * The name of the routing user now depends on the environment * Added context menu for the title bar * View community, Add community conversation and remove community conversation * Protocol updated to include the ForwardedFrom field and chat code adapted * integrate community thumbnails from backend * Delete empty folders * Fixed private conversations not appearing in toolbar * Shape: community card - events (#4400) * Re-fixed private conversations in toolbar * [SHAPE-UP] Communities (Community Creation - Part 1) (#4325) * Add the new creation (empty) panel into communities plugin * small changes * Modifications in the prefab * add links into the get name panel * add links into the get name panel (II) * fix conflicts from previous merge * Update CommunitiesBrowserController.cs * fix membersCount naming * fix dispose * Update CommunityCreationEdition.prefab * Check INftNamesProvider to see if we can create communities * create skeleton for the creation/edition wizard * implemented create button availability * create a community with the basics * solve missing conflicts from previous merge * Make use of AnimatedShowAsync for the warning notification * small changes * Working on the places selector * fix missing conflicts from previous merge * Working on the places selector (II) * Create CommunityCreationEditionEventBus * prepare implementation for create/update community * add file browser package * implemented thumbnail selection for creation community * several changes * fix missing conflicts from previous merge * make the first letter of the role in the MyCommunity card to be upper case * hide missing flows * Fine tune UI * Update copy in the button to create a community * Update beta label roundness * load community image in edition mode * Update title font style * small fixes in communities thumbnails * Update CommunityCreationEditionController.cs * Update ThumbnailDefault.png * Add clarification TODOs * Apply feedback * Apply feedback: Execute CleanCreationPanel when close wizard * Apply feedback: Rename CheckForCreateButtonAvailability by UpdateCreateButtonAvailability * Fine tune GetNamePanel * Fine tune CreateOrEditCommunityPanel UI * Add rect mask to communities browser right section * Add rect mask to communities browser left section * Rename SetScrollPositionToBottom by SetScrollPositionToBottomAsync * Reuse texture selected from the selector to create the sprite * reset browser's scroll vertical positions * Fix rect mask in communities browser left section * Update CommunitiesBrowser_LeftSection.prefab * ui refinement * fix missing conflicts from previous merge * Update packages-lock.json --------- Co-authored-by: Romina Marchetti <rma.marchetti@gmail.com> * Added a way to open a community chat using the bus Also some renaming and documenting. * Community conversations Member list (#4436) * Added titlebar for community member list * Chat titlebar prefabs refactored and simplified, buttons now belong to main bar * Now the Member list is reused in both Nearby and Communities It shows the actual members in the list in each community. It updates the number of members dynamically. The member list data structure has been renamed to ChatUserData, so it does not matter the origin of the data (communities endpoints or profile repository), the same method and data layout is sent to the member list and to the input box for comparing the cached profiles with the members. Also replaces the Members with Online in the title bars. * Added category to the result error trace for communities * [SHAPE-UP] Communities (Sidebar Button) (#4459) * Shape: community card - general improvements (#4434) * Implemented CommunitiesDataProvider.GetCommunityPlacesAsync * Implemented PlacesAPIClient.GetPlacesByIdsAsync (basic version) * Now the titlebar of the community member list is the same as Nearby's The changes of the community variant of the titlebar have been applied to the parent. * Fix after the merge from dev * Conversations that receive a message appear at the top of the chat toolbar (#4463) * Now conversation icons move to top when a message is added (#4309) * Fix: When private conversation did not exist, it was failing to open on first message * GetChannelMembers renamed to add Async suffix * Renamed HandleContextMenuuserProfileButton to add Async suffix * [SHAPE-UP] Communities (Data Provider Events) (#4480) * Now default thumbnails are displayed when the community does not have one (#4393) (#4467) * Communities feature flag applied to the Chat (#4464) The chat will not react to anything related to Communities (#4387) * [SHAPE-UP] Communities (Community Creation - Part 2) (#4440) * get lands and worlds by owner * Added "placeIds" multipart form field in community creation * small refinements in prefabs * fix thumbnail in the creation * small fixes in the browser * fix conflicts * Update edit thumbnail button highlighted color * Update chat nav bar community button container * Fix scrollview left margin * Add hover animation to create and view all buttons * Update button animation hover color for edit and back buttons * Fix flickering sidebar's buttons' container * Shape: community card improvements - 2 (#4469) * Fix: Title of chat messages in Nearby channel appear with wrong username (#4500) * Fix (2): Title of chat messages in Nearby channel appear with wrong username (#4500) * Fix close chat icon size * Fix scroll to bottom font style * Fix margins of the chat entries * Remove unused textures * Fix sidebar animations * Delete unused icons. Update those which needed to be fix or rename. * Fix explore panel tab bar animations * Fix skybox icon broken animation * Communities shape: Chat bubbles (#4536) * Added the community name to the chat bubbles * Added background to text * The bubble is resized according to the width of the community name * Received messages now show the community name too Signed-off-by: Alex Villalba <lince3d@gmail.com> * Fixed white background while moving the camera Also, the color of the background is now more transparent. --------- Signed-off-by: Alex Villalba <lince3d@gmail.com> * Analytics: community_id is now sent when a message is sent in a community chat * Dim up minimap and sidebar container. Afterward, tweak tint buttons colours. * Shape: misc community card improvements (#4526) * Error messages related to web responses in chat have been modified (#4441) * [SHAPE-UP] Communities (Community Edition) (#4475) * get lands and worlds by owner * Added "placeIds" multipart form field in community creation * small refinements in prefabs * fix thumbnail in the creation * small fixes in the browser * fix conflicts * initial commit * load community places/worlds * load community places and manage removal * Implemented the PUT endpoint for communities edition * make the cards pictures envolve the parent * Revert "make the cards pictures envolve the parent" This reverts commit cf4890c. * fix conflicts * Make join/leave actions update the corresponding cards in the browser * fix my communities removal * fix: after close thefile browser in mac, the last click affects to the modal behind * small fixes * Make community name edition available only for owners * Shape: event info panel (#4552) * [SHAPE-UP] Communities (Wallets Allowlist) (#4579) * Implement IsUserAllowedToUseTheFeatureAsync * small refactor * Update CommunitiesUtility.cs * refactor: create CommunitiesFeatureAccess class * Update CommunitiesFeatureAccess.cs * Update asmdef files * Sprite caching system for UI images (#4484) * First implementation of the sprite cache, a refactor of IThumbnailCache IThumbnailCache renamed to ISpriteCache and moved to UI. Used in the ProfilePictureView and the ImageController. The ImageController can use either a web request controller or a sprite cache. It only works with URLs, not IDs. The cache of the Community Browser is shared with Community Card Controller when opening a card. Otherwise the Community Card Controller creates its own. An ObjectProxy is used so the reference to the proxy is stored when the views are instantiated, and its content is set afterwards during the OnViewShow. Added a Clear method to SpriteCache which empties all the internal dictionaries, called when the Community Browser is closed, or when the Community Card is closed if it uses its own cache. * Community creation/edition wizard adapted AND response structure fixed * Now the browser and the community card show new thumbnail after edition * fix double refresh on items + fix exception logging (#4602) * destroy sprites on cache clear + add fade in animation in ImageController (#4605) * Communities URL now starts with social-api instead of communities * Apply feedback: Avoid creating landsAndWorlds collection * Apply feedback: Avoid allocation in AddCommunityPlace * Apply feedback: Add .SuppressToResultAsync to all WarningNotificationView.AnimatedShowAsync * Use FeatureFlagsConfiguration as a singleton in CommunitiesFeatureAccess * Apply feedback: Convert CommunitiesFeatureAccess class into a singleton * React to joining and leaving events to show or hide chat conversations (#4614) * React to joining and leaving events to show or hide chat conversations (#4408) Created the RPC communities service, which consumes the new connectivity messages and broadcasts them using the communities event bus. The char controller is subscribed to the bus and creates / closes the conversation of the community. The protocol source code has been updated. * fix: missing comma concatenating places in the community creation (#4656) * Shape review fixes ObjectProxy removed from Communities browser. CommunityChatConversationsToolbarViewItem now uses a cancellation token. Using a switch in MultiplayerChatMessagesBus. Stop using SafeRestart in constructor of MultiplayerChatMessagesBus. * Shape: communities - review changes (#4627) * fix: pictures with transparent background can overlap the load image icon in community creation (#4658) * fix: make joining a community refresh only the affected card (#4667) * fix: Manage cancellations properly in async methods (#4666) * Shape: community card fixes (#4668) * [SHAPE-UP] Communities (Creation Wizard polishments) (#4595) * several polishments - Give 2 separated error messages when we select a wrong image file in the Creation Wizard. - Show/hide the char counter when focus/unfocus the inputs in the Creation Wizard. * Update CreateOrEditCommunityPanel.prefab * fix: subscribe data provider events only when the browser is open * Update CommunityCreationEditionController.cs * Re-designed places selector * Update CommunityCreationEditionController.cs * add object pooling in SelectorButtonView * Update CommunityCreationWizard.prefab * Update CommunityCreationEditionController.cs * Update CommunityCreationEditionController.cs * Update CommunitiesDataProvider.cs * Convert the indirect flow of getting data to the direct assignment (#4669) * fix warnings related to nullable rules (#4671) * [SHAPE-UP] Communities (Open community card after creation) (#4685) * Open the community card after creation * Update CommunityCreationEditionController.cs * fix gray right corners leak (#4684) * ImageController removed from Communities UI classes (#4675) * Removed from my community card * ImageController removed from Community card view * ImageController removed from Communities and ThumbnailLoader implemented * fix resharper warning * Added exception handling to ImageController --------- Signed-off-by: Alex Villalba <lince3d@gmail.com> Co-authored-by: lorenzo-ranciaffi <lorenzo.ranciaffi@decentraland.org> Co-authored-by: Alejandro Villalba <lince3d@gmail.com> Co-authored-by: Romina Marchetti <rma.marchetti@gmail.com> Co-authored-by: lorenzo-ranciaffi <41125365+lorenzo-ranciaffi@users.noreply.github.com> Co-authored-by: Mikhail Agapov <118179774+mikhail-dcl@users.noreply.github.com>
Pull Request Description
Fixes #4141
What does this PR change?
This PR creates the community card UI including some subsections:
Every data you see is mocked, no real data is used.
Test Instructions
Prerequisites
Test Steps
Test that:
ownerormoderatorroleBANNEDsection. Same applies for the modal above)BANNEDsection, theUNBANbutton (should remove the user from the list)Code Review Reference
Please review our Code Review Standards before submitting.