chore(deps): use published bitsocial react hooks

This commit is contained in:
Tommaso Casaburi
2026-04-20 22:11:36 +07:00
parent 338f415f2a
commit c046c542b6
120 changed files with 169 additions and 169 deletions
+1 -1
View File
@@ -11,7 +11,7 @@ const testState = vi.hoisted(() => ({
localForageSetItemMock: vi.fn(),
}));
vi.mock('@bitsocialnet/bitsocial-react-hooks/dist/lib/localforage-lru/index.js', () => ({
vi.mock('@bitsocial/bitsocial-react-hooks/dist/lib/localforage-lru/index.js', () => ({
default: {
createInstance: () => ({
getItem: (url: string) => testState.localForageGetItemMock(url),
@@ -5,7 +5,7 @@ const testState = vi.hoisted(() => ({
communities: {} as Record<string, { roles?: Record<string, { role?: string }> }>,
}));
vi.mock('@bitsocialnet/bitsocial-react-hooks/dist/stores/communities', () => ({
vi.mock('@bitsocial/bitsocial-react-hooks/dist/stores/communities', () => ({
default: {
getState: () => ({
communities: testState.communities,
@@ -1,4 +1,4 @@
import type { Comment } from '@bitsocialnet/bitsocial-react-hooks';
import type { Comment } from '@bitsocial/bitsocial-react-hooks';
import { describe, expect, it } from 'vitest';
import { getRenderableMobileBacklinks } from '../reply-backlink-utils';
+1 -1
View File
@@ -1,4 +1,4 @@
import { Comment } from '@bitsocialnet/bitsocial-react-hooks';
import { Comment } from '@bitsocial/bitsocial-react-hooks';
export function getThreadPostCountsByAuthor(post: Comment | undefined, replies: Comment[] = []): Map<string, number> {
const counts = new Map<string, number>();
+1 -1
View File
@@ -1,4 +1,4 @@
import { ChallengeVerification } from '@bitsocialnet/bitsocial-react-hooks';
import { ChallengeVerification } from '@bitsocial/bitsocial-react-hooks';
import { getFallbackDirectoriesData } from '../../hooks/use-directories';
import { getCommentCommunityAddress } from './comment-utils';
import { getBoardPath } from './route-utils';
+4 -4
View File
@@ -1,7 +1,7 @@
import type { Comment } from '@bitsocialnet/bitsocial-react-hooks';
import feedsStore from '@bitsocialnet/bitsocial-react-hooks/dist/stores/feeds';
import repliesStore, { feedOptionsToFeedName } from '@bitsocialnet/bitsocial-react-hooks/dist/stores/replies';
import communitiesPagesStore from '@bitsocialnet/bitsocial-react-hooks/dist/stores/communities-pages';
import type { Comment } from '@bitsocial/bitsocial-react-hooks';
import feedsStore from '@bitsocial/bitsocial-react-hooks/dist/stores/feeds';
import repliesStore, { feedOptionsToFeedName } from '@bitsocial/bitsocial-react-hooks/dist/stores/replies';
import communitiesPagesStore from '@bitsocial/bitsocial-react-hooks/dist/stores/communities-pages';
import type { DirectoryCommunity } from '../../hooks/use-directories';
import usePostNumberStore from '../../stores/use-post-number-store';
import type { ExternalQuoteReference, ExternalQuoteSearchStatus } from './external-quote-utils';
+1 -1
View File
@@ -1,4 +1,4 @@
import localForageLru from '@bitsocialnet/bitsocial-react-hooks/dist/lib/localforage-lru/index.js';
import localForageLru from '@bitsocial/bitsocial-react-hooks/dist/lib/localforage-lru/index.js';
import { canEmbed } from '../../components/embed';
import memoize from 'memoizee';
import { isValidURL } from './url-utils';
+1 -1
View File
@@ -1,4 +1,4 @@
import type { Comment } from '@bitsocialnet/bitsocial-react-hooks';
import type { Comment } from '@bitsocial/bitsocial-react-hooks';
import { getCommentCommunityAddress } from './comment-utils';
import { getThreadTopNavigationState } from './thread-scroll-utils';
+2 -2
View File
@@ -1,5 +1,5 @@
import type { Comment } from '@bitsocialnet/bitsocial-react-hooks';
import communitiesStore from '@bitsocialnet/bitsocial-react-hooks/dist/stores/communities';
import type { Comment } from '@bitsocial/bitsocial-react-hooks';
import communitiesStore from '@bitsocial/bitsocial-react-hooks/dist/stores/communities';
import { getCommentCommunityAddress } from './comment-utils';
type CommunityLike = {
+1 -1
View File
@@ -1,4 +1,4 @@
import type { Comment } from '@bitsocialnet/bitsocial-react-hooks';
import type { Comment } from '@bitsocial/bitsocial-react-hooks';
import { getCommentCommunityAddress } from './comment-utils';
export type PostMenuProps = {
+1 -1
View File
@@ -1,4 +1,4 @@
import type { Comment } from '@bitsocialnet/bitsocial-react-hooks';
import type { Comment } from '@bitsocial/bitsocial-react-hooks';
import { layout, layoutNextLine, prepare, prepareWithSegments } from '@chenglou/pretext';
import { getCommentMediaInfo, getHasThumbnail } from './media-utils';
import { removeMarkdown } from './post-utils';
+1 -1
View File
@@ -1,4 +1,4 @@
import type { Comment } from '@bitsocialnet/bitsocial-react-hooks';
import type { Comment } from '@bitsocial/bitsocial-react-hooks';
type QuoteTargetAvailability = 'available' | 'unresolved' | 'unavailable';
+1 -1
View File
@@ -1,4 +1,4 @@
import type { Comment } from '@bitsocialnet/bitsocial-react-hooks';
import type { Comment } from '@bitsocial/bitsocial-react-hooks';
interface GetRenderableMobileBacklinksArgs {
cid?: string;