Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release: v5.7.0 #4968

Merged
merged 96 commits into from
Dec 4, 2024
Merged
Show file tree
Hide file tree
Changes from 94 commits
Commits
Show all changes
96 commits
Select commit Hold shift + click to select a range
c925f73
feat(TagDigest): refactor TagDigest.Feed component
Kechicode Nov 12, 2024
843247f
feat(TagDigest): update Feed stories
Kechicode Nov 13, 2024
85008e1
fix(TagDigest): remove unused props
Kechicode Nov 13, 2024
bf711a7
feat(Tags): revise all tag pages
Kechicode Nov 13, 2024
d47ac56
Merge branch 'feat/new-tag-component' into feat/new-all-tag-page
Kechicode Nov 14, 2024
6b030dd
fix(Tags): fix layout
Kechicode Nov 14, 2024
2e8c164
feat(AggregateResults): revise tag layout
Kechicode Nov 14, 2024
8d4bbe3
feat(AggregateResult): Revise title and tabs
Kechicode Nov 14, 2024
2bc924d
feat(TagDetail): remove cover and revise header
Kechicode Nov 15, 2024
becd38c
feat(TagDetail): revise tabs
Kechicode Nov 15, 2024
4c53463
feat(TagDetail): remove unused control actions
Kechicode Nov 15, 2024
6db96f9
feat(TagDetail): revise RelatedTags
Kechicode Nov 15, 2024
4b8721d
Merge branch 'develop' into feat/new-tag-component
Kechicode Nov 18, 2024
ba5ab05
Merge pull request #4938 from thematters/feat/new-tag-component
Kechicode Nov 18, 2024
9e6a088
Merge branch 'develop' into feat/new-all-tag-page
Kechicode Nov 18, 2024
c868e07
feat(tag): retire unused tag management features
gitwoz Nov 18, 2024
009327b
feat(tag): remove unused
gitwoz Nov 18, 2024
4c66219
feat(tag): remove unused
gitwoz Nov 18, 2024
9fefdb3
Merge branch 'feat/new-all-tag-page' into feat/new-search-tag-page
Kechicode Nov 18, 2024
81d85c7
feat(Tags): revise all tag pages
Kechicode Nov 13, 2024
94d743f
fix(Tags): fix layout
Kechicode Nov 14, 2024
61e55a6
Merge branch 'feat/new-all-tag-page' into feat/new-search-tag-page
Kechicode Nov 18, 2024
d2ccd27
feat: remove unused translations
gitwoz Nov 18, 2024
965a774
Merge branch 'feat/new-search-tag-page' into feat/revise-tag-detail-page
Kechicode Nov 19, 2024
a5d2493
feat(TagDetail): revise bookmark button
Kechicode Nov 19, 2024
63982d3
feat(TagDetail): align spacing
Kechicode Nov 19, 2024
b403546
fix(tag): fix tests
gitwoz Nov 19, 2024
70e4b84
fix(tag): fix tests
gitwoz Nov 19, 2024
f063d13
Merge pull request #4945 from thematters/feat/retire-tag
gitwoz Nov 19, 2024
f7b1228
Merge branch 'develop' into feat/new-all-tag-page
Kechicode Nov 20, 2024
962d7b5
Merge pull request #4944 from thematters/feat/new-all-tag-page
Kechicode Nov 20, 2024
dae90cf
Merge branch 'develop' into feat/new-search-tag-page
Kechicode Nov 20, 2024
1db50ff
Merge pull request #4946 from thematters/feat/new-search-tag-page
Kechicode Nov 20, 2024
3b2b0c4
Merge branch 'develop' into fix/campaign-featured-tag
gitwoz Nov 20, 2024
4adc90d
Merge pull request #4951 from thematters/fix/campaign-featured-tag
gitwoz Nov 20, 2024
6286b52
feat(TagDetail): add tag recommended authors
Kechicode Nov 20, 2024
8db5b73
fix(lang): format
Kechicode Nov 20, 2024
f73fa14
feat(TagDetail): add recommended author in article feed
Kechicode Nov 20, 2024
a9f07ce
feat(Bookmark): revise copy
Kechicode Nov 20, 2024
2184236
feat(TagDetail): add toast after follow/unfollow
Kechicode Nov 20, 2024
ebe175d
feat(EmptyTagArticles): update icon
Kechicode Nov 20, 2024
ab0f757
Merge branch 'develop' into feat/revise-tag-detail-page
Kechicode Nov 21, 2024
79fd322
fix(TagDetail): update variable name
Kechicode Nov 21, 2024
885c6cb
fix(TagDetail): remove random filter
Kechicode Nov 21, 2024
3eb0435
fix(TagDetail): remove private fields in gql
Kechicode Nov 21, 2024
73193cd
fix(TagDetail): default tab set to latest & remove unused tab option
Kechicode Nov 21, 2024
3e10445
feat(tag): hide feed tabs when tag has no articles
Kechicode Nov 21, 2024
f8a8549
Merge pull request #4952 from thematters/feat/revise-tag-detail-page
Kechicode Nov 21, 2024
1a4162e
feat(UserProfile): Remove tag following functionality from Following …
Kechicode Nov 21, 2024
067470a
fix: correct copy of CollectionDigest
gitwoz Nov 21, 2024
78570dc
Merge pull request #4953 from thematters/fix/collection-digest-copy
gitwoz Nov 22, 2024
ab30d3a
feat(Bookmarks): split bookmarks into articles and tags views
Kechicode Nov 22, 2024
3567a9b
refactor(TagDigest): remove TagDigest.Rich component
Kechicode Nov 22, 2024
cbddd9b
Merge branch 'develop' into feat/remove-following-tag-feed
Kechicode Nov 22, 2024
388b4e0
Merge pull request #4954 from thematters/feat/remove-following-tag-feed
Kechicode Nov 22, 2024
299390a
feat(TagDigest): add Bookmark component
Kechicode Nov 25, 2024
ee292c8
feat(TagDetail): migrate TagDetailButtons.BookmarkButton to TagBookma…
Kechicode Nov 25, 2024
5c56b1f
fix(campaign): dedup participant list if total count is less than max…
gitwoz Nov 25, 2024
f401d9d
Merge pull request #4957 from thematters/fix/campaign-filter-viewer
gitwoz Nov 25, 2024
b74fe02
feat(Bookmark): update bookmarks tag view to use TagDigest.Bookmark
Kechicode Nov 26, 2024
d9c2164
fix(bookmarks): add isFollower check and improve private data loading
Kechicode Nov 26, 2024
20cc5a2
Merge branch 'develop' into feat/revise-my-bookmark-page
Kechicode Nov 26, 2024
2c49038
fix(i18n): update copy
Kechicode Nov 26, 2024
917995d
feat(TagDigest): add Bookmark component tests
Kechicode Nov 26, 2024
8a8895b
Merge pull request #4958 from thematters/feat/revise-my-bookmark-page
Kechicode Nov 27, 2024
c315aa2
fix(TagDetail): delay private data loading to ensure proper state upd…
Kechicode Nov 27, 2024
237c080
Merge pull request #4959 from thematters/fix/tag-private-cache-error
Kechicode Nov 27, 2024
5733db9
fix: adjust padding and max-width for last items in grid layouts
Kechicode Nov 27, 2024
7b0a5a3
Merge branch 'develop' into fix/last-item-clamp-issue
Kechicode Nov 27, 2024
a2829db
refactor: extract Infinite Scroll Logic into Reusable Component
Kechicode Nov 27, 2024
9407967
feat(TagDetail): Hide tag feed tabs when no hottest articles
Kechicode Nov 27, 2024
28346f6
Merge pull request #4960 from thematters/fix/last-item-clamp-issue
Kechicode Nov 27, 2024
6e18590
Merge branch 'develop' into feat/revise-tag-tabs
Kechicode Nov 27, 2024
50ee6bb
fix(TagDetail): Optimize tag detail query by reducing hottestArticles…
Kechicode Nov 27, 2024
b1e279e
Merge branch 'feat/revise-tag-tabs' of https://github.com/thematters/…
Kechicode Nov 27, 2024
2c7f103
Merge pull request #4961 from thematters/feat/revise-tag-tabs
Kechicode Nov 27, 2024
d6ee834
feat(tracker): add the tracker for article reading timer
zeckli Nov 29, 2024
956764c
fix(TagDigest): add word-break to tag names for better text wrapping
Kechicode Dec 2, 2024
27227cd
fix(i18n): fix copy
Kechicode Dec 2, 2024
e16337d
fix(tag): add space separator between tag words
Kechicode Dec 2, 2024
7c84f73
fix(Tags): add reactive tag data fetching
Kechicode Dec 2, 2024
efa0814
feat(TagDetail): enhance RecommendedAuthors with Slides component
Kechicode Dec 2, 2024
3f78e4f
fix(Tag): fix tails on letters cut off
Kechicode Dec 2, 2024
7d5a781
fix(BookmarksTags): revise empty state
Kechicode Dec 2, 2024
300c695
fix(Bookmarks): add followed tags check in BookmarksTags
Kechicode Dec 2, 2024
c81f5d4
fix(Bookmarks): ensure tag bookmarks update with refetch
Kechicode Dec 2, 2024
58c5aa6
Merge pull request #4962 from thematters/feat/tracker
zeckli Dec 3, 2024
4c53af1
feat(tag): revise tag queries
gitwoz Dec 2, 2024
f21aa32
Merge pull request #4964 from thematters/feat/tag-queries
gitwoz Dec 3, 2024
eaab49c
Merge branch 'develop' into fix/product-test-feedback
Kechicode Dec 3, 2024
abedc51
fix(TagDigest): delete Bookmark test
Kechicode Dec 3, 2024
b317d03
Merge pull request #4963 from thematters/fix/product-test-feedback
Kechicode Dec 3, 2024
ad84630
feat(tag): use numArticles instead of articles.totalCount for tag art…
gitwoz Dec 3, 2024
e8b95e6
Merge pull request #4965 from thematters/fix/remove-unused-tag-count
pauljusti Dec 4, 2024
c99d2f1
chore(release): v5.7.0
gitwoz Dec 4, 2024
ec73302
Merge pull request #4967 from thematters/release/v5.7.0
pauljusti Dec 4, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
184 changes: 31 additions & 153 deletions lang/default.json

Large diffs are not rendered by default.

184 changes: 31 additions & 153 deletions lang/en.json

Large diffs are not rendered by default.

184 changes: 31 additions & 153 deletions lang/zh-Hans.json

Large diffs are not rendered by default.

184 changes: 31 additions & 153 deletions lang/zh-Hant.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions src/common/enums/events.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ export const SUPPORT_SUCCESS_ANIMATION = 'supportSuccessAnimation'
export enum UNIVERSAL_AUTH_TRIGGER {
appreciation = 'appreciation',
bookmark = 'bookmark',
bookmarkTag = 'bookmarkTag',
circlePrice = 'circlePrice',
circleSubscription = 'circleSubscription',
collectArticle = 'collectArticle',
Expand Down
30 changes: 3 additions & 27 deletions src/common/enums/oauth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export const OAUTH_SCOPE_TREE = {
zh_hans: '草稿',
},
},
subscriptions: {
bookmarkedArticles: {
_t: {
zh_hant: '收藏作品',
zh_hans: '收藏作品',
Expand Down Expand Up @@ -87,42 +87,18 @@ export const OAUTH_SCOPE_TREE = {
zh_hant: '管理個人資料、標籤、評論、封鎖、追蹤等',
zh_hans: '管理个人资料、标签、评论、封锁、关注等',
},
toggleSubscribeArticle: {
toggleBookmarkArticle: {
_t: {
zh_hant: '收藏作品',
zh_hans: '收藏作品',
},
},
toggleFollowTag: {
toggleBookmarkTag: {
_t: {
zh_hant: '追蹤標籤',
zh_hans: '关注标签',
},
},
updateTagSetting: {
_t: {
zh_hant: '管理標籤',
zh_hans: '管理标签',
},
},
addArticlesTags: {
_t: {
zh_hant: '添加作品到標籤',
zh_hans: '添加作品到标签',
},
},
updateArticlesTags: {
_t: {
zh_hant: '管理標籤作品',
zh_hans: '管理标签作品',
},
},
deleteArticlesTags: {
_t: {
zh_hant: '移除標籤作品',
zh_hans: '移除标签作品',
},
},
togglePinComment: {
_t: {
zh_hant: '精选評論',
Expand Down
6 changes: 4 additions & 2 deletions src/common/enums/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@ type ROUTE_KEY =
| 'ME_DRAFTS'
| 'ME_PUBLISHED'
| 'ME_ARCHIVED'
| 'ME_BOOKMARKS'
| 'ME_BOOKMARKS_ARTICLES'
| 'ME_BOOKMARKS_TAGS'
| 'ME_HISTORY'
| 'ME_HISTORY_COMMENTS'
| 'ME_HISTORY_LIKES_SENT'
Expand Down Expand Up @@ -146,7 +147,8 @@ export const ROUTES: {
{ key: 'ME_DRAFTS', pathname: '/me/drafts' },
{ key: 'ME_PUBLISHED', pathname: '/me/published' },
{ key: 'ME_ARCHIVED', pathname: '/me/archived' },
{ key: 'ME_BOOKMARKS', pathname: '/me/bookmarks' },
{ key: 'ME_BOOKMARKS_ARTICLES', pathname: '/me/bookmarks/articles' },
{ key: 'ME_BOOKMARKS_TAGS', pathname: '/me/bookmarks/tags' },
{ key: 'ME_HISTORY', pathname: '/me/history' },
{ key: 'ME_HISTORY_COMMENTS', pathname: '/me/history/comments' },
{ key: 'ME_HISTORY_LIKES_SENT', pathname: '/me/history/likes/sent' },
Expand Down
4 changes: 2 additions & 2 deletions src/common/enums/test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,9 @@ export enum TEST_ID {
DIGEST_USER_RICH_DISPLAY_NAME = 'digest/user/rich/display-name',
DIGEST_USER_VERBOSE = 'digest/user/verbose',
DIGEST_TAG_CONCISE = 'digest/tag/concise',
DIGEST_TAG_BOOKMARK = 'digest/tag/bookmark',
DIGEST_TAG_FEED = 'digest/tag/feed',
DIGEST_TAG_FEED_COVER = 'digest/tag/feed/cover',
DIGEST_TAG_FEED_NUM_ARTICLES = 'digest/tag/feed/num-articles',
DIGEST_TAG_RICH = 'digest/tag/rich',
DIGEST_TAG_SIDEBAR = 'digest/tag/sidebar',
DIGRET_CIRCLE_PLAIN = 'digest/circle/plain',
Expand All @@ -44,7 +45,6 @@ export enum TEST_ID {
DIGEST_CIRCLE_MEMBER_COUNT = 'digest/circle/member-count',
DIGEST_CIRCLE_ARTICLE_COUNT = 'digest/circle/article-count',
DIGEST_CIRCLE_PRICE = 'digest/circle/price',
DIGEST_TAG_SIDEBAR_COVER = 'digest/tag/sidebar/cover',
DIGEST_COLLECTION_FEED = 'digest/collection/feed',
DIGEST_DRAFT_FEED = 'digest/draft/feed',
// dialogs
Expand Down
1 change: 1 addition & 0 deletions src/common/styles/variables/spacing.css
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
--sp12: 0.75rem; /* 12px */
--sp14: 0.875rem; /* 14px */
--sp16: 1rem; /* 16px */
--sp18: 1.125rem; /* 18px */
--sp20: 1.25rem; /* 20px */
--sp24: 1.5rem; /* 24px */
--sp32: 2rem; /* 32px */
Expand Down
7 changes: 7 additions & 0 deletions src/common/utils/analytics.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ type EventArgs =
| ['authenticate', AuthenticateProp]
| ['billboard_exposure', BillboardExposureProp]
| ['click_billboard', ClickBillboardProp]
| ['read_time', ReadTimeProp]

/**
* Event: Page View
Expand Down Expand Up @@ -239,6 +240,11 @@ interface AuthenticateProp {
trigger?: string
}

interface ReadTimeProp {
articleId: string
time: number
}

// content type
export type ContentType =
| 'article'
Expand Down Expand Up @@ -340,6 +346,7 @@ type UserFeedType =
| 'tag_detail_latest'
| 'tag_detail_selected'
| 'tag_detail_community'
| 'tag_detail_recommended_authors'
| 'transaction'

type TagFeedType =
Expand Down
2 changes: 1 addition & 1 deletion src/common/utils/text/tag.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const stripTagAllPunct = (content: string) => {
return words[0]
default:
const [first, ...rest] = words
return `${first} ${rest.join('')}`
return `${first} ${rest.join(' ')}`
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/common/utils/url.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ const changeExt = ({ key, ext }: { key: string; ext?: 'webp' }) => {
}

export const toSizedImageURL = ({
url,
url = '',
width,
height,
ext,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ const ARCHIVE_ARTICLE = gql`
editArticle(input: { id: $id, state: archived }) {
id
articleState: state
sticky
}
}
`
Expand Down Expand Up @@ -52,7 +51,6 @@ const ArchiveArticleDialog = ({
editArticle: {
id: article.id,
articleState: 'archived' as any,
sticky: false,
__typename: 'Article',
},
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -190,19 +190,8 @@ describe('<ArticleDigest/DropdownActions>', () => {
expect($archiveButton).toBeInTheDocument()
})

// hasSetTagSelected
// hasSetTagUnselected
// hasRemoveTag
it('should render tag buttons', async () => {
render(
<DropdownActions
article={MOCK_ARTILCE}
tagDetailId="1"
hasSetTagSelected
hasSetTagUnselected
hasRemoveTag
/>
)
render(<DropdownActions article={MOCK_ARTILCE} tagDetailId="1" />)

const $button = screen.getByLabelText('More Actions')
expect($button).toBeInTheDocument()
Expand All @@ -211,24 +200,6 @@ describe('<ArticleDigest/DropdownActions>', () => {
$button.click()
const $menu = screen.getByRole('menu')
expect($menu).toBeInTheDocument()

// hasSetTagSelected
const $setTagSelectedBtn = screen.getByRole('menuitem', {
name: 'Add to Featured',
})
expect($setTagSelectedBtn).toBeInTheDocument()

// hasUnsetTagSelected
const $setTagUnselectedBtn = screen.getByRole('menuitem', {
name: 'Unpin from Trending',
})
expect($setTagUnselectedBtn).toBeInTheDocument()

// hasRemoveTag
const $removeTagBtn = screen.getByRole('menuitem', {
name: 'Remove Article',
})
expect($removeTagBtn).toBeInTheDocument()
})

// hasSetTopCollection
Expand Down

This file was deleted.

This file was deleted.

Loading
Loading