Skip to content

Conversation

ghost
Copy link

@ghost ghost commented Jun 24, 2025

Description of change

  • Fixed some fallback issues
  • Fixed option on post context menu
  • Fixed bottom nav
  • Fixed Avatar aspect ratio
  • Fixed Comments in home page
  • Fixed empty screen on messages page

Issue Number

closes #216
closes #213

Type of change

  • New (a change which implements a new feature)
  • Update (a change which updates existing functionality)

How the change has been tested

CI and Manual

Change checklist

  • I have ensured that the CI Checks pass locally
  • I have removed any unnecessary logic
  • My code is well documented
  • I have signed my commits
  • My code follows the pattern of the application
  • I have self reviewed my code

Summary by CodeRabbit

  • New Features

    • Added a new Web3Adapter for mapping and synchronizing local data with global web3 representations.
    • Introduced schema-driven JSON mappings for users, posts, comments, chats, messages, and social media posts.
    • Implemented Firestore and Postgres watchers to sync database changes in real time.
    • Added webhook controllers to process incoming global data and update local Firestore and database entities.
    • Introduced dual onboarding flows with pre-verification and asynchronous provisioning in the eID Wallet.
    • Added a new GraphQL mutation for updating meta envelopes by ID.
    • Added follow functionality directly from posts in the home feed.
    • Integrated user profile fetching and display in authenticated layouts and settings pages.
    • Introduced a new SQLite-based mapping database for ID mappings.
    • Added EVaultClient for GraphQL interactions with the eVault service.
    • Added retry logic for Neo4j database connections.
    • Added graceful shutdown and restart capabilities for Firestore watchers.
  • Enhancements

    • Improved UI components with updated branding, image handling, and accessibility enhancements.
    • Enhanced onboarding with pre-verification code input and loading feedback.
    • Refined chat service event emission timing and error handling.
    • Updated GraphQL API with new mutations and robust error handling.
    • Improved state management and error handling in settings and username update flows.
    • Enhanced profile and authentication handling with local storage of owner IDs.
    • Improved webhook processing with concurrency control and error resilience.
  • Bug Fixes

    • Fixed profile update logic to retain existing values when partial updates occur.
    • Added guards in tests to prevent runtime errors from null or missing data.
    • Improved error handling and concurrency control in webhook processing and watchers.
  • Refactor

    • Replaced legacy transformation and webhook logic with a new schema-driven mapping and synchronization system.
    • Updated event subscriber logic to integrate with the new Web3Adapter.
    • Disabled access control checks for simplified development and testing.
    • Restructured EVault initialization to support asynchronous Neo4j driver connection with retry logic.
    • Removed legacy adapter, transformation service, and webhook controller code.
  • Chores

    • Updated dependencies and configuration files across multiple packages and platforms.
    • Added new environment and project configuration files.
    • Reformatted code and improved indentation for consistency.
  • Style

    • Adjusted CSS classes and markup for improved UI alignment and accessibility.
    • Updated modal titles, menu positioning, and avatar/profile image styling with object-cover.
  • Tests

    • Removed outdated test files related to the previous adapter implementation.
  • Documentation

    • Added and updated JSON mapping files documenting data transformation rules.
    • Enhanced example GraphQL queries documentation with new mutation examples.

coodos and others added 16 commits June 17, 2025 15:43
* fix: author-details

* fix: owner-details

* fix: author avatar

* fix: auth user avatar

* fix: error handling

* fix: author image in bottom nav

---------

Co-authored-by: Merul Dhiman <[email protected]>
* fix: corrected the name to blabsy

* fix: extra shit comming.

* fix: fixed the alignment of the display in more to look more like current twitter.
* fix: avatars

* fix: avatar in follow request page

* fix: images uploaded shown in user profile

* fix: button size

* fix: avatar

---------

Co-authored-by: Merul Dhiman <[email protected]>
* fix: post-context-menu

* fix: user id with post

* fix: removed redundant code

* fix: images

* fix: profile data

* fix: profile data

* fix: image cover

* fix: logout
@ghost ghost self-assigned this Jun 24, 2025
@ghost ghost requested a review from coodos as a code owner June 24, 2025 03:34
Copy link
Contributor

coderabbitai bot commented Jun 24, 2025

Walkthrough

This update implements a comprehensive overhaul of the Pictique post context menu ("three dots" menu) to address its previously non-functional state. The changes introduce a new options prop to the Post component, enabling dynamic menu actions such as "Follow." Supporting updates span the UI, state management, and backend logic to ensure proper user identification, authentication, and post interaction. Additional improvements include user profile data handling, authentication utilities, and UI refinements.

Changes

Files/Paths Change Summary
platforms/pictique/src/lib/fragments/Post/Post.svelte
platforms/pictique/src/routes/(protected)/home/+page.svelte
Refactored Post component to accept an options prop for menu actions; added "Follow" functionality to post context menu.
platforms/pictique/src/lib/types.ts
platforms/pictique/src/lib/fragments/Profile/Profile.svelte
platforms/pictique/src/routes/(protected)/profile/[id]/+page.svelte
Updated types and UI to use avatarUrl instead of avatar; improved user profile data handling and display.
platforms/pictique/src/lib/utils/axios.ts
platforms/pictique/src/lib/stores/auth.ts
platforms/pictique/src/routes/(auth)/auth/+page.svelte
Enhanced authentication utilities to store and retrieve ownerId; updated login/logout flows accordingly.
platforms/pictique/src/lib/fragments/SideBar/SideBar.svelte
platforms/pictique/src/lib/fragments/SettingsNavigationButton/SettingsNavigationButton.svelte
Improved profile image source handling and styling for consistency.
platforms/pictique/src/routes/(protected)/+layout.svelte
platforms/pictique/src/routes/(protected)/settings/+page.svelte
Fetched and displayed authenticated user profile in layout; improved settings page to fetch and show user info dynamically.
platforms/pictique/src/routes/(protected)/settings/logout/+page.svelte Implemented real logout logic, clearing authentication and redirecting to login.
platforms/pictique/src/lib/fragments/BottomNav/BottomNav.svelte
platforms/pictique/src/lib/fragments/Comment/Comment.svelte
platforms/pictique/src/lib/fragments/UserRequest/UserRequest.svelte
Minor UI, event, or logic adjustments for consistency and cleanup.
...others (UI, state, utility, and code style changes) Refactoring, indentation, and minor improvements to support main changes.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant PostComponent
    participant HomePage
    participant API

    User->>PostComponent: Clicks 3-dots menu
    PostComponent->>User: Shows menu with "Follow" option
    User->>PostComponent: Selects "Follow"
    PostComponent->>HomePage: Calls handleFollow(authorId)
    HomePage->>API: POST /api/users/{authorId}/follow
    API-->>HomePage: Response (success or error)
    HomePage-->>User: Updates UI or shows error
Loading

Assessment against linked issues

Objective (Issue #) Addressed Explanation
Make 3-dots menu on Pictique posts functional with relevant actions (#216)
Remove strange/placeholder message when clicking the menu (#216)
Integrate context menu actions (e.g., Follow) and ensure proper UI feedback (#216)

Assessment against linked issues: Out-of-scope changes

Code Change Explanation
None found.

Possibly related PRs

Suggested reviewers

  • coodos
  • sosweetham

Poem

Three dots on a post, what could they do?
Now, with a click, a menu pops through!
"Follow" appears—no more empty stare—
Actions abound, with logic to spare.
Rabbits rejoice, the menu's alive,
Pictique's UI has taken a dive—
Into features that thrive! 🐇✨


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 56

🔭 Outside diff range comments (1)
platforms/pictique-api/src/services/PostService.ts (1)

21-44: Method implementation doesn't match its name - returns all posts instead of following feed.

The getFollowingFeed method calculates authorIds but doesn't use it in the query, effectively returning all non-archived posts instead of posts from followed users.

Either rename the method or fix the query:

         const [posts, total] = await this.postRepository.findAndCount({
             where: {
                 isArchived: false,
+                author: { id: In(authorIds) }
             },
🧹 Nitpick comments (43)
platforms/metagram/project.inlang/.gitignore (1)

1-1: Clarify that you intend to ignore a directory, not a file

A trailing slash makes it explicit that the entry refers to a directory.
If you need to ignore cache folders at any depth, use the glob pattern instead.

-cache
+cache/
+# or, to ignore at all levels:
+**/cache/
infrastructure/eid-wallet/package.json (1)

21-29: Move @ngneat/falso to devDependencies if it’s only used for test/demo data

@ngneat/falso is great for seeding fake data, but it adds ~400 kB min-gzipped.
If it isn’t required at runtime (only in stories, tests, or build-time utilities), list it under devDependencies to avoid bloating the production bundle.

platforms/pictique/package.json (1)

52-56: Prefer putting @sveltejs/adapter-node in devDependencies

The adapter is only needed during vite build and is not required by the built artefact at runtime. Moving it to devDependencies keeps the production install lean and speeds up cold starts in serverless environments.

-    "@sveltejs/adapter-node": "^5.2.12",
+  },
+  "devDependencies": {
+    "@sveltejs/adapter-node": "^5.2.12",
platforms/pictique/src/lib/fragments/UploadedPostView/UploadedPostView.svelte (1)

25-30: cn([...].join(' ')) is redundant and defeats the purpose of clsx/tailwind-merge

cn already handles arrays/conditional inputs. Passing a pre-joined string removes its deduping benefit:

-class={cn(
-  [
-    'flex min-h-max max-w-screen flex-row items-center gap-4 overflow-x-auto pr-4 pl-0.5',
-    restProps.class
-  ].join(' ')
-)}
+class={cn(
+  'flex min-h-max max-w-screen flex-row items-center gap-4 overflow-x-auto pr-4 pl-0.5',
+  restProps.class
+)}
platforms/pictique/src/routes/(protected)/profile/+page.svelte (1)

1-3: Remove empty <script> block

The component contains no logic; the empty script is dead code and adds noise. Safe to delete entirely.

-<script>
-</script>
platforms/pictique/src/routes/(protected)/discover/+page.svelte (1)

43-45: Remove debug logging before production.

This $effect appears to be debug code that logs search results to the console. Debug logging should be removed before merging to production.

-	$effect(() => {
-		console.log($searchResults);
-	})
platforms/pictique/src/routes/(protected)/messages/[id]/+page.svelte (1)

42-42: Remove debug log before production deployment.

Console logs should be cleaned up before merging to production to avoid cluttering console output and potential data exposure in messaging functionality.

Apply this diff to remove the debug log:

-			console.log('messages', data);
platforms/pictique-api/src/services/event-emitter.ts (1)

1-3: Good architectural pattern with import protocol improvement needed.

The centralized event emitter is excellent for decoupling components. However, use the node: protocol for Node.js built-in modules as recommended by modern best practices.

Apply this diff to use the node: protocol:

-import { EventEmitter } from "events";
+import { EventEmitter } from "node:events";
platforms/pictique-api/src/services/UserService.ts (1)

8-8: Repository visibility change supports webhook integration.

Making userRepository public enables the WebhookController to access it directly, which aligns with the architectural changes described. While this breaks encapsulation, it serves the practical integration needs.

Consider implementing dependency injection or a repository pattern interface for future refactoring to maintain better encapsulation while supporting cross-service operations.

platforms/pictique/src/lib/stores/posts.ts (1)

3-3: Remove unused import.

The goto import is not used anywhere in this file and should be removed.

-import { goto } from '$app/navigation';
platforms/pictique/src/lib/types.ts (1)

23-23: Consider consistent naming for avatar/image properties.

There's a naming inconsistency: PostData uses avatar (line 23) while userProfile uses avatarUrl (line 38). Consider standardizing on avatarUrl for consistency across types.

 export type PostData = {
     createdAt: string | number | Date;
     id: string;
-    avatar: string;
+    avatarUrl: string;
     userId: string;
     username: string;

Also applies to: 38-38

platforms/pictique/src/lib/stores/auth.ts (1)

9-9: Apply static analysis suggestions for better performance

The static analysis tool suggests improvements for object property access and performance optimization.

Apply these changes to address the static analysis hints:

-		apiClient.defaults.headers.common['Authorization'] = `Bearer ${token}`;
+		apiClient.defaults.headers.common.Authorization = `Bearer ${token}`;
-	apiClient.defaults.headers.common['Authorization'] = `Bearer ${token}`;
+	apiClient.defaults.headers.common.Authorization = `Bearer ${token}`;
-	delete apiClient.defaults.headers.common['Authorization'];
+	apiClient.defaults.headers.common.Authorization = undefined;

Also applies to: 16-16, 23-23

infrastructure/evault-core/src/protocol/graphql-server.ts (1)

34-34: Consider improving type safety by replacing any types

The static analysis tool flagged multiple uses of any which reduces type safety. Consider defining proper TypeScript interfaces for the resolver parameters.

For example, you could define interfaces like:

interface MetaEnvelopeInput {
  ontology: string;
  payload: unknown; // or more specific type
  acl: string[];
}

interface UpdateMetaEnvelopeArgs {
  id: string;
  input: MetaEnvelopeInput;
}

Then use these interfaces instead of any in the resolver signatures.

Also applies to: 39-39, 45-45, 62-62, 68-68, 86-86, 94-94, 120-120, 127-127, 131-131

platforms/blabsy-w3ds-auth-api/src/web3adapter/mappings/chat.mapping.json (1)

1-14: Consider platform consistency for chat entity modeling.

The blabsy platform uses a different approach than pictique for chat entities:

  • Naming: "chat" vs "chats"
  • Participants handling: Direct array field vs junction table
  • Field complexity: More fields and complex transformations

While both approaches are valid, consider documenting the architectural differences between platforms or standardizing the approach if they should be consistent.

platforms/pictique-api/src/database/migrations/1749561069022-migration.ts (1)

1-1: Optimize imports using import type.

The static analysis tool correctly identifies that the TypeORM imports are only used as types. Using import type helps with tree-shaking and compile-time optimization.

-import { MigrationInterface, QueryRunner } from "typeorm";
+import type { MigrationInterface, QueryRunner } from "typeorm";
infrastructure/evault-core/src/db/retry-neo4j.ts (2)

1-1: Fix import type usage for better performance.

The static analysis correctly identifies that Driver is only used as a type annotation.

-import neo4j, { Driver } from "neo4j-driver";
+import neo4j, { type Driver } from "neo4j-driver";

17-18: Consider adjusting default retry parameters for development.

The default values (30 retries, 5000ms delay) result in up to 2.5 minutes of retry time, which might be excessive for development environments.

Consider making defaults environment-aware or documenting the rationale for these high values:

export async function connectWithRetry(
    uri: string,
    user: string,
    password: string,
-   maxRetries = 30,
-   delayMs = 5000,
+   maxRetries = process.env.NODE_ENV === 'production' ? 30 : 5,
+   delayMs = process.env.NODE_ENV === 'production' ? 5000 : 1000,
): Promise<Driver> {
platforms/pictique/src/routes/(protected)/profile/[id]/+page.svelte (1)

22-22: Remove debugging console.log before production.

The console.log statement appears to be for debugging purposes and should be removed before merging to production.

-			console.log(JSON.stringify(profile));
infrastructure/evault-provisioner/src/controllers/VerificationController.ts (2)

228-228: Consider using structured logging instead of console.log.

For production systems, consider using a structured logger (like Winston or similar) instead of console.log for better log management and filtering.

-                        console.log("matched", verificationMatch);
+                        logger.info("Verification match found", { verificationMatch });

236-236: Consider using structured logging instead of console.log.

Similar to the previous comment, structured logging would be more appropriate for production environments.

-                    console.log(body.data.verification.document);
+                    logger.debug("Verification document data", { document: body.data.verification.document });
platforms/pictique/src/lib/fragments/CreatePostModal/CreatePostModal.svelte (1)

74-74: Consider providing meaningful alt text instead of suppressing the warning.

Instead of suppressing the redundant alt text warning, consider providing more descriptive alt text that adds value for screen reader users.

-						<!-- svelte-ignore a11y_img_redundant_alt -->
						<img
							src={image}
-							alt="Post image"
+							alt={`Upload preview ${index + 1}`}
							class="aspect-square w-full rounded-lg object-cover"
						/>
platforms/pictique/src/routes/(protected)/settings/account/username/+page.svelte (2)

5-5: Remove unused import.

The goto import is not used anywhere in this component.

-import { goto } from '$app/navigation';

36-37: Prevent potential memory leak from setTimeout.

The setTimeout should be cleared if the component unmounts before the timeout completes.

Store the timeout ID and clear it on unmount:

+let savedTimeout: ReturnType<typeof setTimeout> | null = null;

 saved = true;
-setTimeout(() => (saved = false), 3_000);
+savedTimeout = setTimeout(() => (saved = false), 3_000);

+onMount(() => {
+  // ... existing code ...
+  return () => {
+    if (savedTimeout) clearTimeout(savedTimeout);
+  };
+});
platforms/pictique-api/src/index.ts (1)

57-58: Remove commented code.

This commented webhook route should be removed since it's replaced by the implementation on line 65.

-// Webhook route (no auth required)
-// app.post("/api/webhook", adapter.webhookHandler.handleWebhook);
platforms/pictique/src/routes/(protected)/settings/+page.svelte (1)

77-94: Consider preserving the onclick handler for disabled button.

While the button is correctly disabled visually, you might want to keep an onclick handler to show a "coming soon" message or track user interest.

-<SettingsNavigationButton>
+<SettingsNavigationButton onclick={() => alert('Data & Storage settings coming soon!')}>
infrastructure/evault-provisioner/src/templates/evault.nomad.ts (1)

208-220: Improve error messages for better debugging.

The error messages could be more descriptive to aid in troubleshooting deployment issues.

-if (!nodePort) throw new Error("No NodePort assigned");
+if (!nodePort) throw new Error(`No NodePort assigned to service 'evault-service' in namespace '${namespaceName}'`);

-if (!node) throw new Error("No nodes found in cluster");
+if (!node) throw new Error("No nodes found in Kubernetes cluster - ensure cluster is properly configured");

-if (!externalIP) throw new Error("No external IP found on node");
+if (!externalIP) throw new Error(`No external IP found on node '${node.metadata?.name}'. Node addresses: ${JSON.stringify(node.status?.addresses)}`);
platforms/pictique/src/lib/utils/axios.ts (1)

34-46: Improve consistency and add validation for auth ID functions.

The auth ID functions should match the style of auth token functions and include validation.

+const OWNER_ID_KEY = 'pictique_owner_id';
+
 // Utility function to store auth id
-export const setAuthId = (id: string): void => {
-    localStorage.setItem('ownerId', id);
+export const setAuthId = (id: string): void => {
+    if (!id || typeof id !== 'string') {
+        throw new Error('Invalid owner ID');
+    }
+    localStorage.setItem(OWNER_ID_KEY, id);
 };

-export const getAuthId = () => {
-    return localStorage.getItem('ownerId');
+export const getAuthId = (): string | null => {
+    return localStorage.getItem(OWNER_ID_KEY);
 };

-// Utility function to remove auth token
+// Utility function to remove auth id
 export const removeAuthId = (): void => {
-    localStorage.removeItem('ownerId');
+    localStorage.removeItem(OWNER_ID_KEY);
 };
platforms/pictique/src/routes/(protected)/home/+page.svelte (1)

10-10: Remove unused import.

The followUser import is not used in the component.

-import { followUser } from '$lib/stores/users';
platforms/pictique/src/lib/fragments/Post/Post.svelte (1)

39-39: Remove debug console.log statements.

Debug logging should not be in production code.

-        console.log('chunks', chunks);
         for (let i = 0; i < chunks.length; i += 2) {
         }
-        console.log('result', result);

         return result;

Also applies to: 56-56

infrastructure/web3-adapter/src/mapper/mapper.types.ts (1)

1-1: Use import type for type-only imports.

The MappingDatabase is only used as a type in this file. Using import type makes this explicit and can improve build performance.

Apply this diff:

-import { MappingDatabase } from "../db";
+import type { MappingDatabase } from "../db";
platforms/blabsy-w3ds-auth-api/src/web3adapter/watchers/firestoreWatcher.ts (2)

1-11: Update imports to follow best practices.

Use import type for type-only imports and the node: protocol for built-in modules.

Apply this diff:

-import {
-    DocumentChange,
-    DocumentData,
-    QuerySnapshot,
-    CollectionReference,
-    CollectionGroup,
-} from "firebase-admin/firestore";
-import path from "path";
+import type {
+    DocumentChange,
+    DocumentData,
+    QuerySnapshot,
+    CollectionReference,
+    CollectionGroup,
+} from "firebase-admin/firestore";
+import path from "node:path";

123-129: Clarify the purpose of the 2-second delay.

The hardcoded 2-second delay for processing documents lacks explanation and could impact performance. If this is addressing a race condition, consider a more robust solution.

Consider:

  1. Adding a comment explaining why this delay is necessary
  2. Making the delay configurable
  3. Implementing a proper synchronization mechanism if this is addressing a race condition
infrastructure/web3-adapter/src/db/mapping.db.ts (2)

1-3: Use Node.js protocol for built-in modules.

Modern Node.js best practices recommend using the node: protocol for built-in modules.

-import sqlite3 from "sqlite3";
-import { join } from "path";
-import { promisify } from "util";
+import sqlite3 from "sqlite3";
+import { join } from "node:path";
+import { promisify } from "node:util";

7-9: Consider improving type safety for promisified methods.

Replace any types with more specific types for better type safety.

-    private runAsync: (sql: string, params?: any) => Promise<void>;
-    private getAsync: (sql: string, params?: any) => Promise<any>;
-    private allAsync: (sql: string, params?: any) => Promise<any[]>;
+    private runAsync: (sql: string, params?: unknown[]) => Promise<void>;
+    private getAsync: (sql: string, params?: unknown[]) => Promise<unknown>;
+    private allAsync: (sql: string, params?: unknown[]) => Promise<unknown[]>;
platforms/pictique-api/src/web3adapter/watchers/subscriber.ts (3)

10-10: Use Node.js protocol for path module.

-import path from "path";
+import path from "node:path";

225-225: Use template literal instead of string concatenation.

-                            tableName: junctionInfo.entity.toLowerCase() + "s",
+                            tableName: `${junctionInfo.entity.toLowerCase()}s`,

1-8: Use import type for type-only imports.

-import {
-    EventSubscriber,
-    EntitySubscriberInterface,
-    InsertEvent,
-    UpdateEvent,
-    RemoveEvent,
-    ObjectLiteral,
-} from "typeorm";
+import {
+    EventSubscriber,
+    type EntitySubscriberInterface,
+    type InsertEvent,
+    type UpdateEvent,
+    type RemoveEvent,
+    type ObjectLiteral,
+} from "typeorm";
platforms/pictique-api/src/controllers/WebhookController.ts (1)

1-1: Use import type for type-only imports.

-import { Request, Response } from "express";
+import type { Request, Response } from "express";
-import { Web3Adapter } from "../../../../infrastructure/web3-adapter/src";
-import { User } from "database/entities/User";
-import { Chat } from "database/entities/Chat";
+import type { Web3Adapter } from "../../../../infrastructure/web3-adapter/src";
+import type { User } from "database/entities/User";
+import type { Chat } from "database/entities/Chat";
-import { Post } from "database/entities/Post";
+import type { Post } from "database/entities/Post";

Also applies to: 6-10

platforms/blabsy-w3ds-auth-api/src/web3adapter/index.ts (1)

3-3: Use Node.js protocol for path module.

-import path from "path";
+import path from "node:path";
infrastructure/web3-adapter/src/index.ts (1)

1-4: Use Node.js protocol prefix and type imports.

Follow modern Node.js conventions for better clarity.

-import * as fs from "fs/promises";
-import path from "path";
-import { IMapping } from "./mapper/mapper.types";
+import * as fs from "node:fs/promises";
+import path from "node:path";
+import type { IMapping } from "./mapper/mapper.types";
infrastructure/eid-wallet/src/routes/(auth)/onboarding/+page.svelte (1)

33-42: Document that passport generation is for demo purposes.

The function uses Math.random() which could produce collisions. Add a comment to clarify this is for demo/testing.

+    // Demo function - generates fake passport numbers for testing
    function generatePassportNumber() {
        const letters = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
        const randomLetters = () =>
            letters.charAt(Math.floor(Math.random() * letters.length)) +
            letters.charAt(Math.floor(Math.random() * letters.length));
        const randomDigits = () =>
            String(Math.floor(1000000 + Math.random() * 9000000)); // 7 digits

        return randomLetters() + randomDigits();
    }
infrastructure/web3-adapter/src/mapper/mapper.ts (1)

60-62: Use const for loop variables that aren't reassigned.

-    for (let [localKey, globalPathRaw] of Object.entries(
+    for (const [localKey, globalPathRaw] of Object.entries(
        mapping.localToUniversalMap,
    )) {

Also applies to: 177-179

platforms/blabsy-w3ds-auth-api/src/controllers/WebhookController.ts (1)

1-4: Use type imports and Node.js protocol.

-import { Request, Response } from "express";
+import type { Request, Response } from "express";
 import { Web3Adapter } from "../../../../infrastructure/web3-adapter/src/index";
-import path from "path";
+import path from "node:path";
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 35798e7 and 5fc2ed2.

⛔ Files ignored due to path filters (27)
  • infrastructure/eid-wallet/src-tauri/gen/android/.idea/.gitignore is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/.idea/AndroidProjectSystem.xml is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/.idea/appInsightsSettings.xml is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/.idea/deploymentTargetSelector.xml is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/.idea/gradle.xml is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/.idea/misc.xml is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/.gitignore is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/build.gradle.kts is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/src/main/java/com/eid_wallet/app/MainActivity.kt is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/src/main/java/com/eid_wallet/app/generated/Ipc.kt is excluded by !**/generated/**, !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/src/main/java/com/eid_wallet/app/generated/Logger.kt is excluded by !**/generated/**, !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/src/main/java/com/eid_wallet/app/generated/PermissionHelper.kt is excluded by !**/generated/**, !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/src/main/java/com/eid_wallet/app/generated/RustWebChromeClient.kt is excluded by !**/generated/**, !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/src/main/java/com/eid_wallet/app/generated/RustWebView.kt is excluded by !**/generated/**, !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/src/main/java/com/eid_wallet/app/generated/RustWebViewClient.kt is excluded by !**/generated/**, !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/src/main/java/com/eid_wallet/app/generated/TauriActivity.kt is excluded by !**/generated/**, !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/src/main/java/com/eid_wallet/app/generated/WryActivity.kt is excluded by !**/generated/**, !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/src/main/java/com/eid_wallet/app/generated/proguard-wry.pro is excluded by !**/generated/**, !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/src/main/java/io/tanglelabs/metastate/eid_wallet/MainActivity.kt is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/app/src/main/res/values/strings.xml is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/buildSrc/src/main/java/io/tanglelabs/metastate/eid_wallet/kotlin/BuildTask.kt is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/android/buildSrc/src/main/java/io/tanglelabs/metastate/eid_wallet/kotlin/RustPlugin.kt is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/apple/eid-wallet.xcodeproj/project.pbxproj is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/apple/eid-wallet.xcodeproj/xcshareddata/xcschemes/eid-wallet_iOS.xcscheme is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/apple/eid-wallet_iOS/Info.plist is excluded by !**/gen/**
  • infrastructure/eid-wallet/src-tauri/gen/apple/project.yml is excluded by !**/gen/**
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (107)
  • infrastructure/eid-wallet/package.json (1 hunks)
  • infrastructure/eid-wallet/src-tauri/tauri.conf.json (1 hunks)
  • infrastructure/eid-wallet/src/routes/(auth)/onboarding/+page.svelte (1 hunks)
  • infrastructure/eid-wallet/src/routes/(auth)/verify/+page.svelte (1 hunks)
  • infrastructure/evault-core/src/db/db.service.spec.ts (2 hunks)
  • infrastructure/evault-core/src/db/db.service.ts (1 hunks)
  • infrastructure/evault-core/src/db/retry-neo4j.ts (1 hunks)
  • infrastructure/evault-core/src/db/types.ts (1 hunks)
  • infrastructure/evault-core/src/evault.ts (5 hunks)
  • infrastructure/evault-core/src/protocol/examples/examples.ts (2 hunks)
  • infrastructure/evault-core/src/protocol/graphql-server.ts (1 hunks)
  • infrastructure/evault-core/src/protocol/typedefs.ts (1 hunks)
  • infrastructure/evault-core/src/protocol/vault-access-guard.ts (1 hunks)
  • infrastructure/evault-provisioner/src/controllers/VerificationController.ts (2 hunks)
  • infrastructure/evault-provisioner/src/index.ts (3 hunks)
  • infrastructure/evault-provisioner/src/templates/evault.nomad.ts (4 hunks)
  • infrastructure/web3-adapter/package.json (1 hunks)
  • infrastructure/web3-adapter/src/__tests__/adapter.test.ts (0 hunks)
  • infrastructure/web3-adapter/src/__tests__/evault.test.ts (0 hunks)
  • infrastructure/web3-adapter/src/adapter.ts (0 hunks)
  • infrastructure/web3-adapter/src/db/index.ts (1 hunks)
  • infrastructure/web3-adapter/src/db/mapping.db.ts (1 hunks)
  • infrastructure/web3-adapter/src/evault/evault.ts (1 hunks)
  • infrastructure/web3-adapter/src/index.ts (1 hunks)
  • infrastructure/web3-adapter/src/mapper/mapper.ts (1 hunks)
  • infrastructure/web3-adapter/src/mapper/mapper.types.ts (1 hunks)
  • infrastructure/web3-adapter/tsconfig.json (1 hunks)
  • platforms/blabsy-w3ds-auth-api/package.json (1 hunks)
  • platforms/blabsy-w3ds-auth-api/src/controllers/AuthController.ts (0 hunks)
  • platforms/blabsy-w3ds-auth-api/src/controllers/WebhookController.ts (1 hunks)
  • platforms/blabsy-w3ds-auth-api/src/index.ts (2 hunks)
  • platforms/blabsy-w3ds-auth-api/src/web3adapter/index.ts (1 hunks)
  • platforms/blabsy-w3ds-auth-api/src/web3adapter/mappings/chat.mapping.json (1 hunks)
  • platforms/blabsy-w3ds-auth-api/src/web3adapter/mappings/message.mapping.json (1 hunks)
  • platforms/blabsy-w3ds-auth-api/src/web3adapter/mappings/social-media-post.mapping.json (1 hunks)
  • platforms/blabsy-w3ds-auth-api/src/web3adapter/mappings/user.mapping.json (1 hunks)
  • platforms/blabsy-w3ds-auth-api/src/web3adapter/watchers/firestoreWatcher.ts (1 hunks)
  • platforms/blabsy/.env.development (1 hunks)
  • platforms/blabsy/package.json (1 hunks)
  • platforms/blabsy/src/components/modal/mobile-sidebar-modal.tsx (1 hunks)
  • platforms/blabsy/src/components/sidebar/more-settings.tsx (1 hunks)
  • platforms/blabsy/src/components/sidebar/sidebar-profile.tsx (1 hunks)
  • platforms/blabsy/src/components/user/user-avatar.tsx (1 hunks)
  • platforms/blabsy/src/lib/types/tweet.ts (1 hunks)
  • platforms/metagram/project.inlang/.gitignore (1 hunks)
  • platforms/metagram/project.inlang/project_id (1 hunks)
  • platforms/metagram/project.inlang/settings.json (1 hunks)
  • platforms/pictique-api/package.json (1 hunks)
  • platforms/pictique-api/src/controllers/MessageController.ts (10 hunks)
  • platforms/pictique-api/src/controllers/PostController.ts (1 hunks)
  • platforms/pictique-api/src/controllers/UserController.ts (1 hunks)
  • platforms/pictique-api/src/controllers/WebhookController.ts (1 hunks)
  • platforms/pictique-api/src/database/data-source.ts (2 hunks)
  • platforms/pictique-api/src/database/migrations/1749561069022-migration.ts (1 hunks)
  • platforms/pictique-api/src/index.ts (1 hunks)
  • platforms/pictique-api/src/middleware/auth.ts (1 hunks)
  • platforms/pictique-api/src/services/ChatService.ts (10 hunks)
  • platforms/pictique-api/src/services/CommentService.ts (3 hunks)
  • platforms/pictique-api/src/services/MessageService.ts (1 hunks)
  • platforms/pictique-api/src/services/PostService.ts (2 hunks)
  • platforms/pictique-api/src/services/UserService.ts (1 hunks)
  • platforms/pictique-api/src/services/event-emitter.ts (1 hunks)
  • platforms/pictique-api/src/web3adapter/config/index.ts (0 hunks)
  • platforms/pictique-api/src/web3adapter/controllers/WebhookController.ts (0 hunks)
  • platforms/pictique-api/src/web3adapter/entities/MetaEnvelopeMap.ts (0 hunks)
  • platforms/pictique-api/src/web3adapter/mappings/chat.mapping.json (1 hunks)
  • platforms/pictique-api/src/web3adapter/mappings/comment.mapping.json (1 hunks)
  • platforms/pictique-api/src/web3adapter/mappings/message.mapping.json (1 hunks)
  • platforms/pictique-api/src/web3adapter/mappings/post.mapping.json (1 hunks)
  • platforms/pictique-api/src/web3adapter/mappings/user.mapping.json (1 hunks)
  • platforms/pictique-api/src/web3adapter/routes/webhook.ts (0 hunks)
  • platforms/pictique-api/src/web3adapter/services/TransformService.ts (0 hunks)
  • platforms/pictique-api/src/web3adapter/services/eVaultService.ts (0 hunks)
  • platforms/pictique-api/src/web3adapter/subscribers/EntitySubscriber.ts (0 hunks)
  • platforms/pictique-api/src/web3adapter/types/index.ts (0 hunks)
  • platforms/pictique-api/src/web3adapter/watchers/subscriber.ts (1 hunks)
  • platforms/pictique/package.json (1 hunks)
  • platforms/pictique/src/lib/fragments/BottomNav/BottomNav.svelte (4 hunks)
  • platforms/pictique/src/lib/fragments/Comment/Comment.svelte (0 hunks)
  • platforms/pictique/src/lib/fragments/CreatePostModal/CreatePostModal.svelte (4 hunks)
  • platforms/pictique/src/lib/fragments/InputFile/InputFile.svelte (1 hunks)
  • platforms/pictique/src/lib/fragments/MessageInput/MessageInput.svelte (1 hunks)
  • platforms/pictique/src/lib/fragments/Post/Post.svelte (4 hunks)
  • platforms/pictique/src/lib/fragments/Profile/Profile.svelte (2 hunks)
  • platforms/pictique/src/lib/fragments/SettingsNavigationButton/SettingsNavigationButton.svelte (1 hunks)
  • platforms/pictique/src/lib/fragments/SideBar/SideBar.svelte (4 hunks)
  • platforms/pictique/src/lib/fragments/UploadedPostView/UploadedPostView.svelte (2 hunks)
  • platforms/pictique/src/lib/fragments/UserRequest/UserRequest.svelte (0 hunks)
  • platforms/pictique/src/lib/store/store.svelte.ts (1 hunks)
  • platforms/pictique/src/lib/stores/auth.ts (1 hunks)
  • platforms/pictique/src/lib/stores/comments.ts (2 hunks)
  • platforms/pictique/src/lib/stores/posts.ts (2 hunks)
  • platforms/pictique/src/lib/stores/users.ts (1 hunks)
  • platforms/pictique/src/lib/types.ts (2 hunks)
  • platforms/pictique/src/lib/utils/axios.ts (1 hunks)
  • platforms/pictique/src/routes/(auth)/auth/+page.svelte (2 hunks)
  • platforms/pictique/src/routes/(protected)/+layout.svelte (6 hunks)
  • platforms/pictique/src/routes/(protected)/discover/+page.svelte (2 hunks)
  • platforms/pictique/src/routes/(protected)/home/+page.svelte (4 hunks)
  • platforms/pictique/src/routes/(protected)/messages/+page.svelte (3 hunks)
  • platforms/pictique/src/routes/(protected)/messages/[id]/+page.svelte (1 hunks)
  • platforms/pictique/src/routes/(protected)/profile/+page.svelte (1 hunks)
  • platforms/pictique/src/routes/(protected)/profile/[id]/+page.svelte (4 hunks)
  • platforms/pictique/src/routes/(protected)/settings/+page.svelte (2 hunks)
  • platforms/pictique/src/routes/(protected)/settings/account/username/+page.svelte (2 hunks)
  • platforms/pictique/src/routes/(protected)/settings/logout/+page.svelte (2 hunks)
  • platforms/pictique/src/routes/+layout.svelte (1 hunks)
⛔ Files not processed due to max files limit (10)
  • platforms/pictique/src/routes/store.ts
  • platforms/pictique/svelte.config.js
  • platforms/pictique/vite.config.ts
  • platforms/registry/src/index.ts
  • platforms/registry/src/jwt.ts
  • services/ontology/schemas/bookmark.json
  • services/ontology/schemas/chat.json
  • services/ontology/schemas/message.json
  • services/ontology/schemas/socialMediaPost.json
  • services/ontology/schemas/user.json
💤 Files with no reviewable changes (14)
  • platforms/blabsy-w3ds-auth-api/src/controllers/AuthController.ts
  • infrastructure/web3-adapter/src/tests/adapter.test.ts
  • platforms/pictique-api/src/web3adapter/routes/webhook.ts
  • platforms/pictique/src/lib/fragments/Comment/Comment.svelte
  • platforms/pictique-api/src/web3adapter/entities/MetaEnvelopeMap.ts
  • platforms/pictique/src/lib/fragments/UserRequest/UserRequest.svelte
  • platforms/pictique-api/src/web3adapter/config/index.ts
  • platforms/pictique-api/src/web3adapter/types/index.ts
  • infrastructure/web3-adapter/src/adapter.ts
  • platforms/pictique-api/src/web3adapter/services/eVaultService.ts
  • platforms/pictique-api/src/web3adapter/controllers/WebhookController.ts
  • infrastructure/web3-adapter/src/tests/evault.test.ts
  • platforms/pictique-api/src/web3adapter/subscribers/EntitySubscriber.ts
  • platforms/pictique-api/src/web3adapter/services/TransformService.ts
🧰 Additional context used
🪛 Biome (1.9.4)
infrastructure/evault-core/src/db/types.ts

[error] 14-14: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 26-26: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 26-26: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 39-39: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 39-39: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 53-53: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 53-53: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)

platforms/blabsy/src/components/user/user-avatar.tsx

[error] 26-33: Provide a href attribute for the a element.

An anchor element should always have a href
Check this thorough explanation to better understand the context.

(lint/a11y/useValidAnchor)

platforms/pictique-api/src/services/event-emitter.ts

[error] 1-1: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)

platforms/pictique-api/src/controllers/MessageController.ts

[error] 323-323: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)

infrastructure/evault-core/src/protocol/graphql-server.ts

[error] 34-34: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 39-39: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 45-45: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 62-62: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 68-68: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 86-86: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 94-94: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 120-120: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 127-127: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 131-131: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)

platforms/pictique/src/lib/stores/auth.ts

[error] 9-9: The computed expression can be simplified without the use of a string literal.

Unsafe fix: Use a literal key instead.

(lint/complexity/useLiteralKeys)


[error] 16-16: The computed expression can be simplified without the use of a string literal.

Unsafe fix: Use a literal key instead.

(lint/complexity/useLiteralKeys)


[error] 23-23: Avoid the delete operator which can impact performance.

Unsafe fix: Use an undefined assignment instead.

(lint/performance/noDelete)


[error] 23-23: The computed expression can be simplified without the use of a string literal.

Unsafe fix: Use a literal key instead.

(lint/complexity/useLiteralKeys)

infrastructure/evault-core/src/db/retry-neo4j.ts

[error] 31-31: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 1-1: Some named imports are only used as types.

This import is only used as a type.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Add inline type keywords.

(lint/style/useImportType)

platforms/pictique-api/src/database/migrations/1749561069022-migration.ts

[error] 1-1: All these imports are only used as types.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Use import type.

(lint/style/useImportType)

platforms/pictique-api/src/index.ts

[error] 27-27: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)

infrastructure/evault-core/src/protocol/vault-access-guard.ts

[error] 50-50: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 65-65: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 83-83: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 84-84: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)

platforms/blabsy-w3ds-auth-api/src/web3adapter/watchers/firestoreWatcher.ts

[error] 8-8: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)


[error] 91-91: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 1-7: Some named imports are only used as types.

This import is only used as a type.

This import is only used as a type.

This import is only used as a type.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Add inline type keywords.

(lint/style/useImportType)

infrastructure/web3-adapter/src/mapper/mapper.types.ts

[error] 1-1: All these imports are only used as types.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Use import type.

(lint/style/useImportType)

platforms/pictique/src/lib/utils/axios.ts

[error] 6-6: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)

infrastructure/web3-adapter/src/db/mapping.db.ts

[error] 2-2: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)


[error] 3-3: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)


[error] 7-7: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 8-8: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 8-8: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 9-9: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 9-9: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 86-86: The catch clause that only rethrows the original error is useless.

An unnecessary catch clause can be confusing.
Unsafe fix: Remove the try/catch clause.

(lint/complexity/noUselessCatch)


[error] 157-157: The catch clause that only rethrows the original error is useless.

An unnecessary catch clause can be confusing.
Unsafe fix: Remove the try/catch clause.

(lint/complexity/noUselessCatch)

infrastructure/web3-adapter/src/mapper/mapper.ts

[error] 3-3: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 3-3: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 25-25: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 63-63: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 143-143: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 162-162: Template literals are preferred over string concatenation.

Unsafe fix: Use a template literal.

(lint/style/useTemplate)


[error] 180-180: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 1-1: All these imports are only used as types.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Use import type.

(lint/style/useImportType)


[error] 60-60: This let declares some variables that are only assigned once.

'localKey' is never reassigned.

'globalPathRaw' is never reassigned.

Safe fix: Use const instead.

(lint/style/useConst)


[error] 64-64: This let declares a variable that is only assigned once.

'targetKey' is never reassigned.

Safe fix: Use const instead.

(lint/style/useConst)


[error] 177-177: This let declares some variables that are only assigned once.

'localKey' is never reassigned.

'globalPathRaw' is never reassigned.

Safe fix: Use const instead.

(lint/style/useConst)

platforms/blabsy-w3ds-auth-api/src/web3adapter/index.ts

[error] 3-3: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)

platforms/pictique-api/src/controllers/WebhookController.ts

[error] 1-1: All these imports are only used as types.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Use import type.

(lint/style/useImportType)


[error] 6-6: All these imports are only used as types.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Use import type.

(lint/style/useImportType)


[error] 7-7: All these imports are only used as types.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Use import type.

(lint/style/useImportType)


[error] 8-8: All these imports are only used as types.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Use import type.

(lint/style/useImportType)


[error] 10-10: All these imports are only used as types.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Use import type.

(lint/style/useImportType)

platforms/pictique-api/src/web3adapter/watchers/subscriber.ts

[error] 10-10: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)


[error] 42-42: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 49-49: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 53-53: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 53-53: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 74-74: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 94-94: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 101-101: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 120-120: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 127-127: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 146-146: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 195-195: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 225-225: Template literals are preferred over string concatenation.

Unsafe fix: Use a template literal.

(lint/style/useTemplate)


[error] 262-262: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 262-262: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 1-8: Some named imports are only used as types.

This import is only used as a type.

This import is only used as a type.

This import is only used as a type.

This import is only used as a type.

This import is only used as a type.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Add inline type keywords.

(lint/style/useImportType)

infrastructure/web3-adapter/src/evault/evault.ts

[error] 8-8: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 64-64: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 67-67: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 72-72: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 83-83: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 86-86: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 91-91: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)

infrastructure/web3-adapter/src/index.ts

[error] 1-1: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)


[error] 2-2: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)


[error] 3-3: All these imports are only used as types.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Use import type.

(lint/style/useImportType)

platforms/blabsy-w3ds-auth-api/src/controllers/WebhookController.ts

[error] 3-3: A Node.js builtin module should be imported with the node: protocol.

Using the node: protocol is more explicit and signals that the imported module belongs to Node.js.
Unsafe fix: Add the node: protocol.

(lint/style/useNodejsImportProtocol)


[error] 33-33: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 92-92: Template literals are preferred over string concatenation.

Unsafe fix: Use a template literal.

(lint/style/useTemplate)


[error] 117-117: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 124-124: This variable implicitly has the any type.

Variable declarations without type annotation and initialization implicitly have the any type. Declare a type or initialize the variable with some value.

(lint/suspicious/noImplicitAnyLet)


[error] 147-147: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 156-156: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 156-156: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 162-162: Other switch clauses can erroneously access this declaration.
Wrap the declaration in a block to restrict its access to the switch clause.

The declaration is defined in this switch clause:

Unsafe fix: Wrap the declaration in a block.

(lint/correctness/noSwitchDeclarations)


[error] 176-176: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 201-201: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 223-225: This else clause can be omitted because previous branches break early.

Unsafe fix: Omit the else clause.

(lint/style/noUselessElse)


[error] 246-246: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 269-269: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 1-1: All these imports are only used as types.

Importing the types with import type ensures that they are removed by the compilers and avoids loading unnecessary modules.
Safe fix: Use import type.

(lint/style/useImportType)

infrastructure/evault-core/src/db/db.service.ts

[error] 377-377: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)


[error] 377-377: Unexpected any. Specify a different type.

any disables many type checking rules. Its use should be avoided.

(lint/suspicious/noExplicitAny)

platforms/pictique-api/src/services/ChatService.ts

[error] 158-158: This type annotation is trivially inferred from its initialization.

Safe fix: Remove the type annotation.

(lint/style/noInferrableTypes)


[error] 238-238: This type annotation is trivially inferred from its initialization.

Safe fix: Remove the type annotation.

(lint/style/noInferrableTypes)

🔇 Additional comments (100)
platforms/pictique/src/lib/fragments/InputFile/InputFile.svelte (1)

29-29: LGTM! CSS class reordering for consistency.

This minor reordering of CSS classes aligns with the broader UI consistency improvements mentioned in the AI summary. The functional behavior remains unchanged.

platforms/metagram/project.inlang/project_id (1)

1-1: Double-check that the project identifier is non-secret

project_id appears to be a unique identifier that will be shared in-repo.
Confirm that this value is not security-sensitive and that rotating it later will not break downstream tooling.

platforms/metagram/project.inlang/settings.json (1)

7-11: Validate the relative pathPattern now to avoid runtime surprises

"../messages/{locale}.json" assumes a sibling messages/ directory relative to project.inlang/.
Make sure that directory exists (or will exist once translations are added) and that build/CI pipelines have the same working directory, otherwise Inlang will fail to discover message files.

If the messages folder lives elsewhere, update the pattern accordingly.

platforms/blabsy/src/components/sidebar/more-settings.tsx (1)

58-58: LGTM - Dropdown positioning fix.

The change from -top-44 to top-0 properly aligns the dropdown menu with its container, addressing the positioning issue mentioned in the PR objectives.

platforms/blabsy/src/components/modal/mobile-sidebar-modal.tsx (1)

123-123: LGTM - Branding consistency update.

The change from "Log out of Twitter?" to "Log out of Blabsy?" properly aligns the modal text with the platform's branding.

platforms/blabsy/src/components/sidebar/sidebar-profile.tsx (2)

46-47: LGTM - Branding consistency updates.

The changes from "Log out of Twitter?" to "Log out of Blabsy?" in both the title and description properly align the modal text with the platform's branding, maintaining consistency across the application.


37-153: LGTM - Code formatting improvements.

The formatting and indentation changes improve code readability without affecting functionality.

platforms/blabsy/package.json (1)

6-8: ```shell
#!/bin/bash

Search for references to old ports in .env files

rg -n --no-heading -e '3000' -g '.env'
rg -n --no-heading -e '80' -g '.env'

Search for port mappings in Docker Compose configs

rg -n --no-heading -e 'ports:' -g 'docker-compose*.yml' -g 'docker-compose*.yaml'
rg -n --no-heading -e '3000' -g 'docker-compose*.yml' -g 'docker-compose*.yaml'
rg -n --no-heading -e '80' -g 'docker-compose*.yml' -g 'docker-compose*.yaml'

Inspect firebase.json for any emulator port overrides

rg -n --no-heading -e '"port"' -g 'firebase.json'


</details>
<details>
<summary>platforms/pictique/src/routes/+layout.svelte (1)</summary>

`3-3`: **LGTM - Authentication refactoring looks good.**

The removal of `ownerId` import aligns with the broader refactoring to use local reactive state management for authentication instead of shared store imports. This pattern is consistent with similar changes across other components mentioned in the AI summary.

</details>
<details>
<summary>platforms/pictique-api/src/controllers/PostController.ts (1)</summary>

`25-25`: **Good cleanup - removing trailing comma improves code style.**

Minor code style improvement with no functional impact. The cleanup aligns with the broader code quality improvements mentioned in the AI summary.

</details>
<details>
<summary>infrastructure/evault-core/src/db/types.ts (1)</summary>

`5-9`: **Good formatting improvements for readability.**

The multi-line formatting makes the type definitions more readable and maintainable. The `any` types flagged by static analysis appear intentional for generic constraints where flexibility is needed (e.g., `Record<string, any>`).



Also applies to: 15-19, 26-33, 39-47, 53-53

</details>
<details>
<summary>platforms/pictique/src/lib/fragments/SettingsNavigationButton/SettingsNavigationButton.svelte (1)</summary>

`41-41`: **Good UI improvement for profile image display.**

Adding `object-cover` ensures profile images maintain their aspect ratio while filling the container, preventing distortion and providing a consistent visual experience.

</details>
<details>
<summary>platforms/pictique-api/package.json (2)</summary>

`21-21`: **LGTM: GraphQL client dependency addition supports new functionality.**

The addition of `graphql-request` aligns with the described web3 adapter and webhook functionality enhancements.

---

`25-25`: **LGTM: TypeORM upgrade brings improvements and fixes.**

The upgrade from `^0.3.20` to `^0.3.24` supports the new PostgresSubscriber functionality and brings bug fixes and improvements.

</details>
<details>
<summary>platforms/pictique/src/lib/stores/comments.ts (1)</summary>

`5-46`: **LGTM: Formatting consistency improvement.**

The indentation changes from spaces to tabs improve code consistency without affecting functionality.

</details>
<details>
<summary>infrastructure/web3-adapter/tsconfig.json (1)</summary>

`2-16`: **LGTM! Modern TypeScript configuration update.**

The TypeScript configuration has been appropriately modernized to target ES2021 with NodeNext module resolution, which aligns well with the new dependencies and architecture mentioned in the summary. This ensures compatibility with modern JavaScript features and proper ESM/CJS interoperability.

</details>
<details>
<summary>platforms/pictique/src/lib/store/store.svelte.ts (1)</summary>

`1-26`: **LGTM! Code style standardization.**

The changes consistently update string literals to single quotes and standardize indentation to tabs. This improves code consistency across the project without affecting functionality.

</details>
<details>
<summary>infrastructure/web3-adapter/src/db/index.ts (1)</summary>

`1-1`: **LGTM! Standard barrel export pattern.**

This creates a clean, centralized export point for the database module, following standard TypeScript/JavaScript module organization patterns.

</details>
<details>
<summary>platforms/pictique/src/routes/(auth)/auth/+page.svelte (2)</summary>

`4-4`: **LGTM! Enhanced authentication state management.**

Good addition of `setAuthId` import to complement the existing token management functionality.

---

`24-25`: ```shell
#!/bin/bash
echo "=== +page.svelte around eventSource ==="
rg -n -C 5 "eventSource" 'platforms/pictique/src/routes/(auth)/auth/+page.svelte' || true

echo
echo "=== Files in src/lib/utils ==="
ls -R platforms/pictique/src/lib/utils || true

echo
echo "=== First 200 lines of axios.ts ==="
sed -n '1,200p' platforms/pictique/src/lib/utils/axios.ts || true

echo
echo "=== apiClient references in utils ==="
rg -n -C 3 "apiClient" platforms/pictique/src/lib/utils || true
infrastructure/eid-wallet/src/routes/(auth)/verify/+page.svelte (2)

21-21: LGTM! Clean resolution of naming conflict.

Good solution to alias the Selfie store import as SelfiePic to avoid conflicts with the Selfie component, improving code clarity.


63-63: LGTM! Consistent usage of renamed store.

The store reset logic correctly uses the new SelfiePic alias, maintaining consistency with the import change.

platforms/pictique-api/src/middleware/auth.ts (1)

13-15: Verify this security change doesn't compromise protected routes.

The middleware now allows requests without Authorization headers to proceed instead of returning 401. While this appears intentional for webhook integration, ensure that routes requiring authentication are still properly protected by subsequent middleware or guards.

#!/bin/bash
# Description: Verify that protected routes still have proper authentication guards
# Expected: Routes requiring authentication should use authGuard or similar protection

# Search for route definitions and authentication usage
rg -A 5 -B 2 "authGuard|authMiddleware" --type ts

# Check for routes that might be unprotected
ast-grep --pattern 'router.$_($_, $_)'
platforms/pictique/src/lib/stores/users.ts (1)

5-44: LGTM - Good formatting consistency improvements.

The indentation changes improve code consistency by standardizing on tabs throughout the file.

platforms/pictique-api/src/controllers/MessageController.ts (1)

26-26: LGTM - Good formatting cleanup.

Removing trailing commas improves code consistency.

Also applies to: 63-63, 92-92, 132-132, 152-152, 175-175, 199-199, 253-253, 312-312

infrastructure/evault-core/src/protocol/typedefs.ts (1)

41-41: LGTM - Well-designed GraphQL mutation addition.

The new updateMetaEnvelopeById mutation follows GraphQL best practices with clear naming, proper input/output types, and consistency with existing mutations.

platforms/pictique-api/src/database/data-source.ts (1)

11-11: Verify the PostgresSubscriber implementation exists.

The import and registration of PostgresSubscriber looks correct, but please ensure the subscriber class is properly implemented at the specified path.

#!/bin/bash
# Description: Verify PostgresSubscriber exists and is properly implemented
# Expected: Find the PostgresSubscriber class with proper TypeORM subscriber implementation

# Check if the PostgresSubscriber file exists
fd -t f "subscriber.ts" platforms/pictique-api/src/web3adapter/watchers/

# Look for the PostgresSubscriber class implementation
ast-grep --pattern 'export class PostgresSubscriber {
  $$$
}'

# Check for TypeORM subscriber decorators/interfaces
rg -A 10 "PostgresSubscriber.*implements.*EventSubscriber|@EventSubscriber" platforms/pictique-api/src/web3adapter/watchers/

Also applies to: 22-22

platforms/blabsy/.env.development (1)

2-2: Review the necessity of switching from localhost to remote URL.

Changing from http://localhost to https://blabsy.w3ds-prototype.merul.org in a development environment file raises several concerns:

  1. Security: This exposes the development environment to external access
  2. Mixed protocols: Using HTTPS for the main URL but HTTP for the base URL could cause issues
  3. Scope: This change seems unrelated to "minor fallback issues" mentioned in the PR title

Please confirm this change is intentional and necessary for the PR objectives.

Also applies to: 5-6

platforms/pictique/src/lib/types.ts (1)

21-21: Good addition of timestamp tracking.

The createdAt property with flexible typing (string | number | Date) is well-designed to handle various timestamp formats.

platforms/pictique/src/lib/fragments/MessageInput/MessageInput.svelte (1)

55-55: Minor styling adjustment - no functional impact.

The CSS class reordering doesn't affect functionality or visual appearance.

infrastructure/web3-adapter/package.json (2)

1-43: Confirm the removal of "type": "module" is intentional.

Removing the "type": "module" field changes the package from ES modules to CommonJS. This could be a breaking change if the codebase uses ES module syntax (import/export). Please verify this change is intentional and that all imports/exports still work correctly.


17-24: Verify all new dependencies are actually used.

Adding multiple new dependencies increases the package size and potential security surface. Please ensure all these dependencies are actually utilized in the codebase:

  • @types/node
  • axios
  • graphql-request
  • sqlite3
  • uuid
#!/bin/bash
# Description: Verify new dependencies are actually used in the codebase
# Expected: Find usage of each new dependency

echo "Checking axios usage:"
rg -l "import.*axios|require.*axios" infrastructure/web3-adapter/src/

echo "Checking graphql-request usage:"
rg -l "import.*graphql-request|require.*graphql-request" infrastructure/web3-adapter/src/

echo "Checking sqlite3 usage:"
rg -l "import.*sqlite3|require.*sqlite3" infrastructure/web3-adapter/src/

echo "Checking uuid usage:"
rg -l "import.*uuid|require.*uuid" infrastructure/web3-adapter/src/

echo "Checking Node.js types usage:"
rg -l "Node\.|NodeJS\." infrastructure/web3-adapter/src/
platforms/pictique/src/routes/(protected)/settings/logout/+page.svelte (3)

5-5: Good addition of authentication utility imports.

The import of removeAuthId and removeAuthToken utilities provides proper separation of concerns for authentication management.


7-11: Well-structured logout implementation.

The handleLogout function properly clears both authentication token and ID before redirecting. Using window.location.href for redirection is appropriate here as it ensures a complete page reload and clears any remaining application state.


27-27: Clean integration with the logout button.

The button callback now uses the dedicated handleLogout function, improving code organization and maintainability.

platforms/blabsy/src/lib/types/tweet.ts (1)

6-16: Clean formatting improvements.

The reformatting enhances code readability and maintains consistent indentation throughout the type definitions. No functional changes detected.

Also applies to: 21-29

platforms/pictique-api/src/controllers/UserController.ts (1)

84-84: Good practice: Fetching existing user data before update.

Retrieving the current user data enables preservation of existing values during partial updates, preventing accidental data loss.

platforms/pictique/src/routes/(protected)/messages/+page.svelte (3)

6-6: Good addition of heading store for improved navigation context.

Importing the heading store enables better user experience by providing contextual information during navigation.


21-22: Excellent defensive programming for undefined latestMessage.

The use of optional chaining (?.) and nullish coalescing (??) properly handles cases where latestMessage may be undefined, preventing runtime errors and providing sensible defaults.


36-39: Enhanced navigation callback with better UX.

Setting the heading with the message username before navigation provides better contextual information for the user. The structured callback approach improves code readability.

platforms/pictique-api/src/web3adapter/mappings/user.mapping.json (1)

1-24: ```shell
#!/bin/bash

Verify timestamp columns in User entity

rg -n 'CreateDateColumn|UpdateDateColumn' -A2 platforms/pictique-api/src/database/entities/User.ts

Verify relational fields for followers/following in User entity

rg -n 'ManyToMany' -A4 platforms/pictique-api/src/database/entities/User.ts


</details>
<details>
<summary>platforms/pictique/src/lib/stores/auth.ts (2)</summary>

`2-2`: **LGTM: Auth ID management integration**

Good addition of `removeAuthId` import to support enhanced authentication state management.

---

`21-25`: **LGTM: Complete authentication cleanup**

The addition of `removeAuthId()` ensures both token and ID are properly cleared during logout, which is essential for complete session cleanup.

</details>
<details>
<summary>infrastructure/evault-core/src/protocol/graphql-server.ts (1)</summary>

`84-118`: **LGTM: Well-implemented mutation resolver**

The new `updateMetaEnvelopeById` mutation resolver is properly structured with:
- Consistent access guard middleware usage
- Proper error handling with try-catch
- Clear parameter destructuring
- Appropriate error logging and re-throwing

The implementation follows the established patterns in the codebase.

</details>
<details>
<summary>platforms/pictique-api/src/services/CommentService.ts (2)</summary>

`6-6`: **LGTM: Repository access modification for webhook integration**

Making `commentRepository` public enables external access, which aligns with the webhook integration system that needs to perform CRUD operations on comments.

---

`9-13`: **LGTM: Consistent formatting improvements**

The formatting changes improve code consistency:
- Multi-line parameter formatting for better readability
- Standardized double quotes for string literals
- Proper trailing newline

These changes don't affect functionality but improve code quality.



Also applies to: 16-16, 22-22, 31-31, 39-39, 46-46, 56-56, 61-62

</details>
<details>
<summary>platforms/pictique-api/src/web3adapter/mappings/post.mapping.json (1)</summary>

`1-19`: **LGTM: Well-structured schema mapping configuration**

The JSON mapping configuration is well-designed with:
- Clear table name and schema ID identification
- Proper owner entity path definition
- Comprehensive field mappings covering all essential post attributes
- Support for junction tables (`post_likes`)
- Proper handling of nested relations and arrays

This configuration effectively bridges local and universal schema formats for the webhook integration system.

</details>
<details>
<summary>infrastructure/evault-core/src/db/db.service.spec.ts (1)</summary>

`55-55`: **LGTM: Defensive programming improvements**

The addition of early return guards after async fetches is excellent defensive programming that:
- Prevents runtime errors from accessing properties on undefined objects
- Makes tests more robust and reliable
- Provides clear exit points when expected data is not available
- Maintains consistency across multiple test methods

These changes improve test reliability without affecting the core test logic.



Also applies to: 171-171, 178-178, 184-184, 189-189

</details>
<details>
<summary>platforms/blabsy-w3ds-auth-api/src/index.ts (4)</summary>

`7-9`: **LGTM: Clean import additions for Firebase and new controllers.**

The new imports are well-structured and follow TypeScript conventions. The Firebase Admin SDK imports are appropriate for server-side initialization.

---

`33-39`: **Good error handling for Web3Adapter initialization.**

The asynchronous initialization with proper error handling and `process.exit(1)` on failure is appropriate. This ensures the server doesn't start in an inconsistent state if the adapter fails to initialize.

---

`48-48`: **LGTM: Clean webhook endpoint registration.**

The webhook endpoint is properly registered using the controller pattern, maintaining consistency with the existing auth endpoints.

---

`29-31`: **Verify Firebase Admin SDK setup and credentials.**

The Firebase initialization uses `applicationDefault()` which relies on environment credentials (service account key file, environment variables, or GCP metadata). Ensure the deployment environment has proper Firebase credentials configured.


```shell
#!/bin/bash
# Description: Check if Firebase configuration files or environment variables exist
# Expected: Find Firebase service account or environment setup

# Check for common Firebase credential patterns
echo "=== Checking for Firebase credentials ==="
fd -t f "firebase" . --exec echo "Found Firebase file: {}"
fd -t f "service-account" . --exec echo "Found service account file: {}"
fd -t f -e json . --exec grep -l "firebase\|service_account" {} \; 2>/dev/null || true

echo -e "\n=== Checking environment files for Firebase vars ==="
fd -t f ".env" . --exec grep -l "FIREBASE\|GOOGLE" {} \; 2>/dev/null || true
platforms/blabsy-w3ds-auth-api/src/web3adapter/mappings/social-media-post.mapping.json (1)

1-14: Review mapping syntax and validate date conversion logic.

The JSON structure is valid, but there are some concerns with the mapping syntax:

  1. Date conversion inconsistency: Line 11 uses __date(calc(...)) while line 12 uses __date(calc(...)) - both should use consistent function naming.
  2. Schema ID validation: The UUID format appears valid but should be verified against the actual schema registry.
  3. Complex mapping syntax: The syntax like user(createdBy),authorId and images[].src,mediaUrls needs validation.
#!/bin/bash
# Description: Validate mapping syntax and find related mapping files
# Expected: Find other mapping files to compare syntax consistency

echo "=== Finding all mapping files ==="
fd -e json -t f "mapping" . --exec echo "Found mapping: {}"

echo -e "\n=== Checking for mapping syntax documentation ==="
rg -A 5 -B 5 "__date|__calc|user\(|tweet\(" . --type json

echo -e "\n=== Looking for mapping schema validation ==="
rg -A 10 "550e8400-e29b-41d4-a716-446655440001" .
platforms/pictique-api/src/web3adapter/mappings/chat.mapping.json (1)

1-15: ```shell
#!/bin/bash

Retrieve the blabsy platform chat mapping to compare tableName and junction config

echo "=== Blabsy chat mapping ==="
cat platforms/blabsy-w3ds-auth-api/src/web3adapter/mappings/chat.mapping.json


</details>
<details>
<summary>platforms/pictique-api/src/database/migrations/1749561069022-migration.ts (2)</summary>

`7-10`: **LGTM: Well-designed ID mapping table with appropriate indexes.**

The table design is solid:
- UUID primary key with auto-generation
- Appropriate varchar fields for ID mapping
- Timestamp fields with sensible defaults
- Strategic indexes on lookup fields (localId, metaEnvelopeId, entityType)

The double underscore prefix (`__web3_id_mapping`) follows the convention for system/internal tables.

---

`13-18`: **LGTM: Proper rollback implementation.**

The down method correctly reverses all changes in the proper order:
1. Drop indexes first
2. Drop table last

This ensures clean rollback without foreign key or dependency issues.

</details>
<details>
<summary>platforms/pictique-api/src/services/MessageService.ts (1)</summary>

`7-9`: **LGTM: Clean implementation of findById method.**

The method correctly handles potential null returns from the database query.

</details>
<details>
<summary>infrastructure/evault-core/src/protocol/examples/examples.ts (2)</summary>

`82-82`: **Good fix: Corrected typographic apostrophe.**

The standardization to regular apostrophe improves consistency in the documentation.

---

`101-131`: **Excellent addition: Comprehensive update example.**

The new example 7 demonstrates updating a MetaEnvelope by ID with clear field mappings and expected response structure. This will be valuable for developers using the API.

</details>
<details>
<summary>platforms/pictique/src/lib/fragments/SideBar/SideBar.svelte (2)</summary>

`7-9`: **Good refactor: Improved state management.**

Moving from a global store to local reactive state with `getAuthId()` makes the component more self-contained and easier to reason about.

---

`162-163`: **Great UI improvement: Enhanced profile image styling.**

The addition of `object-cover` class and proper fallback URL improves the visual consistency of profile images.

</details>
<details>
<summary>platforms/pictique-api/src/web3adapter/mappings/message.mapping.json (1)</summary>

`1-12`: **LGTM: Well-structured mapping configuration.**

The JSON mapping clearly defines the message entity schema with appropriate field mappings between local and universal formats. The owner entity path and relationship mappings look correct for the web3 adapter integration.

</details>
<details>
<summary>platforms/pictique-api/src/web3adapter/mappings/comment.mapping.json (3)</summary>

`1-19`: **LGTM! Well-structured mapping configuration.**

The JSON mapping configuration is properly structured with clear field mappings and appropriate reference paths. The schema follows a consistent pattern with other mapping files in the system.

---

`16-17`: **Verify array reference handling for likedBy and author mappings.**

The mappings for `likedBy` and `author` use different patterns - `likedBy` uses array notation `likedBy[]` while `author` uses direct reference. Ensure the web3 adapter handles both patterns consistently.


```shell
#!/bin/bash
# Description: Check for consistent array reference handling in mapping files

# Search for array reference patterns
rg "users\([^)]*\[\]" --type json

# Search for direct user reference patterns  
rg "users\([^)]*[^\\[\\]]\.id\)" --type json

13-13: ```shell
#!/bin/bash

Display the parentPostId mapping context in post.mapping.json

echo "----- post.mapping.json -----"
sed -n '1,200p' platforms/pictique-api/src/web3adapter/mappings/post.mapping.json | sed -n '1,20p'; sed -n '20,40p'
echo

Display the parentPostId mapping context in comment.mapping.json

echo "----- comment.mapping.json -----"
sed -n '1,200p' platforms/pictique-api/src/web3adapter/mappings/comment.mapping.json | sed -n '1,20p'; sed -n '20,40p'


</details>
<details>
<summary>platforms/blabsy-w3ds-auth-api/src/web3adapter/mappings/user.mapping.json (2)</summary>

`1-17`: **LGTM! Proper Firestore timestamp handling and field mappings.**

The mapping configuration correctly handles Firestore timestamp conversion and provides clear field name transformations. The `__date(calc(createdAt._seconds * 1000))` syntax properly converts Firestore timestamps to JavaScript-compatible milliseconds.

---

`4-4`: **Verify owner path simplicity for user entity.**

The `ownerEnamePath` is set to `"id"` which implies users own themselves. Confirm this is the intended ownership model for the web3 adapter system.


```shell
#!/bin/bash
# Description: Check ownership patterns across different mapping files

# Search for ownerEnamePath patterns in all mapping files
rg "ownerEnamePath" --type json -A 1
platforms/pictique/src/routes/(protected)/profile/[id]/+page.svelte (6)

5-5: LGTM! Appropriate store import update.

Removing the global ownerId import in favor of local state management is a good architectural improvement.


7-7: LGTM! Added necessary authentication utility.

The getAuthId import supports the transition to local authentication state management.


14-14: LGTM! Proper local state initialization.

The local ownerId state variable is correctly initialized to null and typed appropriately.


42-42: LGTM! Good defensive programming with optional chaining.

The optional chaining (profile?.username) prevents potential runtime errors if the profile is null.


56-58: LGTM! Proper reactive effect for authentication state.

The $effect correctly initializes the local ownerId using the getAuthId() utility, maintaining reactivity.


74-74: LGTM! Corrected comparison logic.

The direct string comparison (ownerId === profileId) is correct after removing the .value property access that was needed for the previous store-based approach.

infrastructure/evault-provisioner/src/controllers/VerificationController.ts (2)

43-45: LGTM! Improved code formatting for readability.

The multi-line formatting of the JSON.stringify call improves code readability without changing functionality.


225-226: LGTM! Better code formatting for complex property access.

Breaking the nested property access across multiple lines improves readability, especially for debugging.

platforms/blabsy-w3ds-auth-api/src/web3adapter/mappings/message.mapping.json (2)

1-15: LGTM! Consistent mapping configuration structure.

The message mapping follows the same pattern as other mapping files with proper field transformations and reference paths. The timestamp handling is consistent with the user mapping file.


6-7: Verify circular reference handling between chat and message entities.

The mapping shows both chatId and senderId referencing external entities. Ensure the web3 adapter properly handles potential circular references between chat, message, and user entities.

#!/bin/bash
# Description: Check for potential circular references in mapping configurations

# Search for chat references across mapping files
rg "chat\(" --type json

# Search for message references in other mapping files  
rg "message" --type json

# List all mapping files to understand entity relationships
fd "\.mapping\.json$" --exec echo "=== {} ===" \; --exec cat {} \;
infrastructure/evault-provisioner/src/index.ts (1)

123-127: To confirm how evaultId is used later (e.g., in the register call), let’s search for all its occurrences:

#!/bin/bash
# Show all usages of evaultId in the index.ts file
rg -n "evaultId" -A3 -B3 infrastructure/evault-provisioner/src/index.ts
platforms/pictique-api/src/services/PostService.ts (1)

10-10: Verify the use case for setting initial likes on post creation.

Allowing likedBy to be set during post creation is unusual. Posts typically start with no likes. Please confirm this is intentional and not a security concern.

Also applies to: 65-65

platforms/blabsy-w3ds-auth-api/package.json (2)

28-29: GraphQL dependencies look good.

The addition of GraphQL dependencies aligns with the Web3Adapter integration mentioned in the summary.


22-22: Verify the reason for downgrading firebase-admin.

Downgrading dependencies might introduce security vulnerabilities or miss important bug fixes. Please ensure this downgrade is necessary and doesn't introduce known vulnerabilities.

What are the latest stable versions of firebase-admin npm package and are there any security vulnerabilities in version 12.0.0?
platforms/pictique/src/lib/fragments/CreatePostModal/CreatePostModal.svelte (2)

92-102: UI improvements look good.

The updated styling for the file input label and button size enhance the user interface.


54-54: Use Svelte event syntax instead of HTML DOM attributes.

Svelte's on:event syntax is preferred over HTML onevent attributes for better performance and consistency with Svelte conventions.

-				onclick={closeCreatePostModal}
+				on:click={closeCreatePostModal}
-							onclick={() => removeImage(index)}
+							on:click={() => removeImage(index)}
-				<input type="file" accept="image/*" class="hidden" onchange={handleImageUpload} />
+				<input type="file" accept="image/*" class="hidden" on:change={handleImageUpload} />

Also applies to: 83-83, 96-96

⛔ Skipped due to learnings
Learnt from: pixel-punk-20
PR: MetaState-Prototype-Project/prototype#121
File: platforms/metagram/src/lib/ui/Button/Button.svelte:83-83
Timestamp: 2025-05-08T08:40:51.710Z
Learning: In Svelte 5, event handlers should use lowercase DOM-style attributes (e.g., `onclick={handler}`) rather than the Svelte 3/4 syntax with the `on:` prefix (e.g., `on:click={handler}`). The `on:` syntax is deprecated in Svelte 5 though still supported for backward compatibility.
platforms/pictique/src/routes/(protected)/settings/+page.svelte (1)

16-37: Well-implemented dynamic profile fetching.

The implementation properly handles loading and error states, and correctly uses reactive state for the ownerId.

infrastructure/evault-provisioner/src/templates/evault.nomad.ts (1)

110-113: ```shell
#!/bin/bash
FILE="infrastructure/evault-provisioner/src/templates/evault.nomad.ts"
rg -n "REGISTRY_URL" -C10 "$FILE"


</details>
<details>
<summary>infrastructure/evault-core/src/db/db.service.ts (1)</summary>

`377-378`: **Replace `any` types with proper generics.**

The generic constraint already provides type information.


The `T extends Record<string, any>` constraint is already properly typed and doesn't need modification. The static analysis warning can be safely ignored here as it's a generic type constraint, not a direct use of `any`.

</details>
<details>
<summary>platforms/pictique/src/lib/fragments/Post/Post.svelte (1)</summary>

`36-59`: To get better insight into how `pairAndJoinChunks` is used and what input it receives, let’s locate all references and inspect the surrounding code:


```shell
#!/bin/bash
# 1. Find all definitions and invocations of the helper
rg -n "pairAndJoinChunks" .

# 2. View the top of the Svelte file to see imports, props and chunk sources
sed -n '1,200p' platforms/pictique/src/lib/fragments/Post/Post.svelte
infrastructure/evault-core/src/evault.ts (3)

26-34: Good architectural improvement with the factory pattern.

Moving async operations out of the constructor and using a private constructor with a factory method is a solid design pattern that prevents initialization errors.


36-53: Well-implemented async factory method with proper error handling.

The method properly handles environment variables with fallback values and provides clear warnings when defaults are used. The integration with retry logic enhances connection reliability.


106-108: Correct implementation of async initialization pattern.

The startup sequence properly uses the factory method and handles errors appropriately.

infrastructure/web3-adapter/src/mapper/mapper.types.ts (1)

3-47: Well-structured type definitions with excellent documentation.

The interfaces are clearly defined with comprehensive JSDoc comments, especially the ownerEnamePath property which includes helpful examples for both direct and nested references.

platforms/blabsy-w3ds-auth-api/src/web3adapter/watchers/firestoreWatcher.ts (1)

15-202: Well-structured watcher implementation with good resilience patterns.

The class implements proper retry logic with exponential backoff, concurrency control to prevent overlapping snapshots, and structured error handling. The separation of initial fetch and real-time listening is a good pattern.

platforms/pictique-api/src/services/ChatService.ts (2)

8-20: Good adoption of centralized event handling.

Using a shared event emitter instance promotes consistent event handling across services. Consider documenting why the repository needs to be public if it's for architectural reasons.


312-317: Useful addition for chat retrieval.

The findById method provides a focused way to retrieve chats with their participants, complementing the existing getChatById method which loads more relations.

platforms/pictique/src/routes/(protected)/+layout.svelte (2)

44-56: Correct usage of Svelte store pattern.

The migration from direct assignment to heading.set() properly maintains reactivity in the Svelte store system.


100-176: Safe integration of profile data into UI components.

Good use of optional chaining (profile?.avatarUrl) and null fallback values to prevent runtime errors when profile data is not yet loaded.

platforms/pictique/src/lib/fragments/Profile/Profile.svelte (2)

6-18: Props refactoring looks good!

The consolidation of prop declarations with explicit typing improves code clarity and type safety.


24-30: Property name updates are consistent.

The renaming from avataravatarUrl, usernamehandle, userBiodescription, and textcaption aligns well with the platform-wide data model standardization.

Also applies to: 59-63

platforms/pictique-api/src/web3adapter/watchers/subscriber.ts (1)

160-176: Clarify the purpose of the 2-second delay.

The setTimeout with a fixed 2-second delay could cause race conditions and makes the system less predictable. Consider:

  1. Using a proper queue system if you need to defer processing
  2. Making the delay configurable
  3. Documenting why this delay is necessary

What's the specific reason for this 2-second delay? Is it to ensure database consistency or to avoid overwhelming the Web3Adapter?

platforms/blabsy-w3ds-auth-api/src/web3adapter/index.ts (1)

20-92: Well-structured adapter implementation!

The lifecycle management, error handling, and automatic recovery mechanisms are well implemented. The special handling for the messages collection group shows good understanding of Firestore's capabilities.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review continued from previous batch...

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

♻️ Duplicate comments (1)
platforms/pictique/src/routes/(protected)/home/+page.svelte (1)

43-50: Add user feedback for follow actions.

The handleFollow function only logs errors to console without providing user feedback on success or failure states.

🧹 Nitpick comments (3)
platforms/pictique/src/routes/(protected)/home/+page.svelte (3)

71-74: Fix potential race condition in onMount.

fetchProfile() is called immediately after setting ownerId, but since both operations are synchronous in the same execution context, this should work. However, consider making the relationship explicit.

 onMount(() => {
     ownerId = getAuthId();
-    fetchFeed();
-    fetchProfile();
+    fetchFeed();
+    if (ownerId) {
+        fetchProfile();
+    }
 });

20-22: Remove unused local state variables.

The isCommentsLoading and commentsError state variables are declared but never used. The comments store likely manages its own loading and error states.

 let loading = $state(true);
-let isCommentsLoading = $state(false);
-let commentsError = $state<string | null>(null);

113-113: Verify follow functionality integration.

The options array with Follow action looks correct, but ensure the post author isn't the current user to prevent self-following.

-options = {[{name: "Follow",handler: () => handleFollow(post.author.id)}]}
+options = {post.author.id !== ownerId ? [{name: "Follow",handler: () => handleFollow(post.author.id)}] : []}
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 171ba65 and 45bd18f.

📒 Files selected for processing (1)
  • platforms/pictique/src/routes/(protected)/home/+page.svelte (5 hunks)
🔇 Additional comments (2)
platforms/pictique/src/routes/(protected)/home/+page.svelte (2)

30-41: LGTM! Improved comment submission with proper error handling.

The refactored handleSend function correctly uses the centralized comments store and includes proper error handling with form state reset.


125-129: ```shell
#!/bin/bash

Search for loading and error exports in the comments store

rg -n "loading" platforms/pictique/src/lib/stores/comments.ts || true
rg -n "error" platforms/pictique/src/lib/stores/comments.ts || true


</details>

</blockquote></details>

</details>

<!-- This is an auto-generated comment by CodeRabbit for review status -->

@coodos coodos closed this Aug 12, 2025
@coodos coodos deleted the fix/minor-fallback-issues branch August 12, 2025 05:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Click on 3 dots icon in the right part of the post (in Pictique) lead to strange message Empty screen when click on Messages in Pictique
4 participants