Commit Graph

1142 Commits

Author SHA1 Message Date
Tommaso Casaburi
cc31ca7a74 fix(dev): restore dev home page render 2026-04-28 14:04:06 +07:00
Tommaso Casaburi
f56594cc32 chore: drop old plebbit list, rename to use-default-subscriptions
Rename the hook file and exports from use-default-subplebbits to
use-default-subscriptions. Switch the fetch URL from
plebbit/lists default-multisub.json to bitsocialnet/lists
seedit-default-subscriptions.json.

A 404 from the new (not-yet-populated) list gracefully resolves
to empty defaults so new users see an empty subscription feed
(like a fresh Reddit account). The list will be populated later.
2026-04-27 19:26:58 +07:00
Tommaso Casaburi
c5348a0aa1 fix(community-rebrand): address Cursor Bugbot and CodeRabbit findings
- Use getCommunityIdentifier in every useCommunity / useCommunityStats
  call site so hash-style (publicKey) community addresses are routed
  to the correct CommunityIdentifier branch instead of always being
  treated as { name }.
- Move the create-community redirect in community-settings.tsx out
  of the render body and into useEffect to avoid the "cannot update
  a component while rendering" warning and re-fire on every render.
- useMemo Object.keys(accountCommunities) in mod.tsx so feedOptions
  and the three useFeed calls receive a stable communityAddresses
  array.
- Simplify the tautological logo-avatar guard in header.tsx.
- (Verified flattenCommentsPages import resolves; left as-is.)
- (Comment import in mod.tsx confirmed from @bitsocial/...)
2026-04-27 18:51:49 +07:00
Tommaso Casaburi
c5cb66ec0c refactor: rename subplebbit → community throughout UI layer
Cosmetic rename of local variables, prop names, type names, CSS classes,
function names, and code comments from the legacy `subplebbit` terminology
to `community` across components, hooks, stores, views, and utilities.

API protocol keys (e.g. `subplebbitAddress:` in publish options) are
intentionally preserved. A new `getCommentCommunityAddress` dual-read
helper in `comment-utils.ts` reads `communityAddress` first and falls
back to the legacy `subplebbitAddress` field for backward compat.

Renamed hook files:
- use-is-nsfw-subplebbit.ts → use-is-nsfw-community.ts
- use-is-broadly-nsfw-subplebbit.ts → use-is-broadly-nsfw-community.ts
2026-04-27 16:15:47 +07:00
Tommaso Casaburi
309c553c5a refactor: rename subplebbit -> community across seedit
Apply the broader subplebbit -> community rebrand on top of the
package switch:

- Rename hook usages (useSubplebbit -> useCommunity, useSubplebbits
  -> useCommunities, useSubplebbitStats -> useCommunityStats,
  useSubplebbitsStates -> useCommunitiesStates,
  useAccountSubplebbits -> useAccountCommunities,
  usePublishSubplebbitEdit -> usePublishCommunityEdit,
  usePlebbitRpcSettings -> usePkcRpcSettings) and types (Subplebbit
  -> Community, PublishSubplebbitEditOptions ->
  PublishCommunityEditOptions).
- Rename seedit identifiers (variables, types, store names) from
  subplebbit/Subplebbit to community/Community.
- git mv view directories, store files, hook files, and CSS modules
  from subplebbit-* to community-*. Update all imports.
- Rename the React Router :subplebbitAddress route param to
  :communityAddress (path /s/ unchanged).
- Update English translation values for community-related strings.
- Drop src/lib/bitsocial-react-hooks-compat.ts (no longer needed
  now that @bitsocial/bitsocial-react-hooks exposes the community
  names natively).
- Add src/hooks/use-community-identifier.ts and
  src/lib/utils/address-utils.ts as small adapters for the new
  CommunityIdentifier shape and short-address utility.
- Fix src/hooks/use-default-subplebbits.ts to import Community
  instead of Subplebbit (PR #813 will rename the file in a
  follow-up; tiny merge conflict expected on that one file).

Build, lint, and type-check all pass.
2026-04-27 14:38:23 +07:00
Tommaso Casaburi
8d017a1ab7 refactor: switch import scope from @bitsocialnet to @bitsocial
Mechanical scope rename across src/. Build is intentionally broken
at this commit — Phase 3 renames the symbols (useSubplebbit ->
useCommunity, etc.) to match the new package's API.
2026-04-27 13:47:45 +07:00
Tommaso Casaburi
6040835a94 feat(hooks): migrate seedit to bitsocial-react-hooks
Swap the app to the latest bitsocial-react-hooks commit, add a local compatibility shim for the legacy subplebbit API surface, and keep the in-flight account-history improvements that now use hook-side paging/filtering.
2026-03-31 19:29:45 +07:00
plebeius
05afd1ce29 refactor: extract timeout management into useScheduledReset hook 2026-01-30 12:00:27 +08:00
plebeius
216a6a322a Update sidebar.tsx 2026-01-29 18:56:03 +08:00
plebeius
3ff4f3ae66 fix: improve timeout and interval cleanup to prevent memory leaks
Refactored timeout and interval management across components to use refs for proper cleanup. Fixed memory leak in use-time-filter hook by tracking interval lifecycle. Improved error handling type safety in error-display component.
2026-01-28 17:29:34 +08:00
plebeius
edfceaeee3 chore(deps): update React types and react-markdown for React 19
Updated @types/react and @types/react-dom from 18.x to ^19.1.2 to match React 19. Upgraded react-markdown from 8.0.6 to ^10.1.0 for React 19 compatibility. Fixed TypeScript errors across components including useRef initial values, ref type mismatches, JSX namespace issues, and react-markdown component prop types.
2026-01-28 15:55:15 +08:00
plebeius
7fc8758341 style(post): update share link domain to seedit.app 2026-01-27 17:12:40 +08:00
plebeius
1d6ab6f221 feat(search-bar): add same community alert 2026-01-27 16:49:30 +08:00
plebeius
a61e26d57c Replace "p/" route prefix with "s/" for community routes 2026-01-16 17:44:09 +01:00
plebeius
27b4c3d98c update links for rebrand 2026-01-16 17:21:37 +01:00
plebeius
1ce08b388b fix: add leading slashes to sort links in header for all/mod/domain views 2026-01-15 19:16:05 +01:00
plebeius
9cdb57ebca fix lint warnings 2026-01-15 19:09:03 +01:00
plebeius
87183af08b Refactor Plebbit.getShortAddress usage to accept object 2026-01-03 19:37:54 +01:00
plebeius
cc524d4595 Remove 'anti-spam' wording from challenge UI 2025-10-12 22:38:27 +02:00
plebeius
ac7bb7c436 feat(challenge modal): improve iframe challenge confirmation message 2025-10-12 22:27:36 +02:00
plebeius
0bdcb4b985 fix(challenge-modal): add allow-same-origin to iframe sandbox 2025-10-11 17:11:38 +02:00
plebeius
d66fc83a68 fix(challenge): update challenge iframe type 2025-10-11 17:01:58 +02:00
plebeius
af4695299d better wording 2025-10-08 00:06:13 +02:00
plebeius
2e1262232c fix(challenge-modal): prevent stale closures in keyboard event handler 2025-10-07 23:55:01 +02:00
plebeius
56b5555b4a feat(challenges): handle iframe challenges in regular challenge flow 2025-10-07 23:49:19 +02:00
plebeius
7603ba990c fix(challenge): adjust padding and improve error log 2025-10-04 16:04:47 +02:00
plebeius
5f14d03aa4 use more user-friendly wording 2025-10-03 18:35:46 +02:00
plebeius
acf0130467 fix(challenge-modal): tighten iframe handling, fix styling 2025-10-03 18:08:08 +02:00
plebeius
759e1389f3 fix type error 2025-10-02 22:50:45 +02:00
plebeius
888bfbbe50 fix spacing 2025-10-02 22:50:06 +02:00
plebeius
f23c16c833 refactor(challenge-modal): normalize hook usage across challenge modes 2025-10-02 17:06:00 +02:00
plebeius
8dd91b48e1 Update challenge-modal.tsx 2025-10-01 17:08:04 +02:00
plebeius
e06ac3f412 refactor(challenge-modal): sync iframe parent data and theme updates 2025-10-01 17:07:27 +02:00
plebeius
911e2f51ce remove inline styling 2025-10-01 17:05:17 +02:00
plebeius
41967c59c1 refactor(challenge): consolidate iframe and regular challenge components 2025-10-01 16:43:35 +02:00
plebeius
bcea4eb642 fix(challenge): scope iframe messaging to trusted origin 2025-09-30 18:30:30 +02:00
plebeius
4e5f134c0f remove unnecessary effect 2025-09-30 18:24:17 +02:00
plebeius
e881abf0b7 feat(challenge): add dark mode to iframe, improve security 2025-09-30 18:21:22 +02:00
plebeius
610ff8ee35 feat(challenges): add iframe modal for external authentication challenges
implements mintpass challenge
2025-09-30 18:10:45 +02:00
plebeius
6b5e002d78 feat(header,account-bar): remove unnecessary effects and derive values from route/visibility 2025-09-27 13:05:24 +02:00
plebeius
1f69dc9405 fix(posts): handle whitespace-only post titles properly 2025-08-11 16:01:00 +02:00
plebeius
4251325b2a fix: edit comment state would get stuck at pending 2025-08-08 19:51:19 +02:00
plebeius
9be49c0a92 fix(subplebbit): sub with no posts could appear offline 2025-08-06 13:14:39 +02:00
plebeius
0ff116efb8 update link to default subs list 2025-08-04 23:09:41 +02:00
plebeius
dfea8c1080 Update author-sidebar.tsx 2025-08-03 22:07:35 +02:00
plebeius
1badab4a68 fix(embeds): make iframe width fix truly Safari-specific 2025-08-01 23:14:07 +02:00
plebeius
3a60a61570 add wip alert 2025-07-16 22:09:34 +02:00
plebeius
704c2fe779 add smooth fade and slide animations to info tooltip 2025-07-15 23:19:44 +02:00
plebeius
d21b5ddb5b feat: add info tooltips 2025-07-15 22:41:00 +02:00
plebeius
8f974349e6 feat(moderation): implement comment purging
purging a comment removes it from the subplebbit's database
2025-06-30 22:13:45 +02:00