Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/v3' into release/v3.11.3
Browse files Browse the repository at this point in the history
  • Loading branch information
ChayanitBm committed Nov 28, 2024
2 parents 6716cc9 + ac537ff commit f68bb28
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 13 deletions.
34 changes: 28 additions & 6 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,54 @@

All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.

### 3.11.3 (2024-11-28)


### Bug Fixes

* ASC-27000 - prepend post on feed ([#743](https://github.com/AmityCo/Amity-Social-Cloud-UIKit-Web/issues/743)) ([56af0ae](https://github.com/AmityCo/Amity-Social-Cloud-UIKit-Web/commit/56af0ae3ead6b7b8e8a2c217e976b15ae79e54a0))

### 3.11.2 (2024-11-22)

## 3.11.0 (2024-10-25)

### 3.10.3 (2024-10-18)
### Bug Fixes

* lint error ([8dfea91](https://github.com/AmityCo/Amity-Social-Cloud-UIKit-Web/commit/8dfea918096e59128389064ce471e0e55e75ad49))

### 3.10.1 (2024-09-12)

### 3.10.2 (2024-09-12)

### Bug Fixes

- skeleton style ([#646](https://github.com/AmityCo/Amity-Social-Cloud-UIKit-Web-OpenSource/issues/646)) ([644f00f](https://github.com/AmityCo/Amity-Social-Cloud-UIKit-Web-OpenSource/commit/644f00f03997b53aa304c80084d6c069f51c3808))
* skeleton style ([#646](https://github.com/AmityCo/Amity-Social-Cloud-UIKit-Web/issues/646)) ([8ebc957](https://github.com/AmityCo/Amity-Social-Cloud-UIKit-Web/commit/8ebc9574189116ee2d70af2ee58fce97f81fabd5))

## 3.11.0 (2024-10-25)

### 3.10.2 (2024-10-18)

### 3.10.1 (2024-09-12)

### 3.10.1 (2024-09-10)

### Bug Fixes

- change provider export path ([4c4b0a2](https://github.com/AmityCo/Amity-Social-Cloud-UIKit-Web-OpenSource/commit/4c4b0a2c371c979880fd29ed04d9b97496dc125e))
* skeleton style ([#646](https://github.com/AmityCo/Amity-Social-Cloud-UIKit-Web/issues/646)) ([8ebc957](https://github.com/AmityCo/Amity-Social-Cloud-UIKit-Web/commit/8ebc9574189116ee2d70af2ee58fce97f81fabd5))

## 3.10.0 (2024-09-02)

## 3.9.0 (2024-08-16)

## 3.8.0 (2024-07-12)

### Bug Fixes

* pnpm install in pipeline ([4d48319](https://github.com/AmityCo/Amity-Social-Cloud-UIKit-Web/commit/4d48319dbc3dfe41899495ef5181fed35035c3bf))

## 3.7.0 (2024-06-24)

### Bug Fixes

- remove expose v4 component ([dbf1665](https://github.com/AmityCo/Amity-Social-Cloud-UIKit-Web/commit/dbf1665b9bb1aac7f717814b3df901f4c6caa6b4))

## 3.6.0 (2024-06-07)

### Bug Fixes
Expand Down
12 changes: 9 additions & 3 deletions src/social/components/Feed/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,8 @@ const MyFeed = ({
membership: 'member',
});

const { prependItem } = useFeed();

const loadMoreCommunitiesCB = useCallback(() => {
loadMoreCommunities?.();
}, [loadMoreCommunities]);
Expand All @@ -158,7 +160,7 @@ const MyFeed = ({
enablePostTargetPicker={false}
hasMoreCommunities={hasMoreCommunities}
loadMoreCommunities={loadMoreCommunitiesCB}
onCreateSuccess={onPostCreated}
onCreateSuccess={(newPost) => onPostCreated || prependItem(newPost)}
/>
<FeedScrollContainer
className={className}
Expand Down Expand Up @@ -239,6 +241,8 @@ const CommunityFeed = ({
feedType,
});

const { prependItem } = useFeed();

function renderLoadingSkeleton() {
return new Array(3).fill(3).map((_, index) => <DefaultPostRenderer key={index} loading />);
}
Expand All @@ -251,7 +255,7 @@ const CommunityFeed = ({
targetType={targetType}
targetId={targetId}
enablePostTargetPicker={false}
onCreateSuccess={onPostCreated}
onCreateSuccess={(newPost) => onPostCreated || prependItem(newPost)}
/>
) : null}
<FeedScrollContainer
Expand Down Expand Up @@ -339,6 +343,8 @@ const BaseFeed = ({
membership: 'member',
});

const { prependItem } = useFeed();

function renderLoadingSkeleton() {
return new Array(3).fill(3).map((_, index) => <DefaultPostRenderer key={index} loading />);
}
Expand All @@ -354,7 +360,7 @@ const BaseFeed = ({
enablePostTargetPicker={false}
hasMoreCommunities={hasMoreCommunities}
loadMoreCommunities={loadMoreCommunities}
onCreateSuccess={onPostCreated}
onCreateSuccess={(newPost) => onPostCreated || prependItem(newPost)}
/>
)}
<FeedScrollContainer
Expand Down
5 changes: 1 addition & 4 deletions src/social/components/post/Creator/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -264,10 +264,7 @@ const PostCreatorBar = ({
const backgroundImage = target.targetType === 'community' ? CommunityImage : UserImage;

const CurrentTargetAvatar = (
<Avatar
avatar={targetUser?.avatarCustomUrl || avatarFileUrl || undefined}
backgroundImage={backgroundImage}
/>
<Avatar avatar={user?.avatar?.fileUrl || undefined} backgroundImage={backgroundImage} />
);
const isDisabled =
(!text && postImages.length === 0 && postVideos.length === 0 && postFiles.length === 0) ||
Expand Down

0 comments on commit f68bb28

Please sign in to comment.