Skip to content

Feat/w3id log generation #98

New issue

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

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

Already on GitHub? Sign in to your account

Merged
merged 29 commits into from
Apr 14, 2025
Merged

Feat/w3id log generation #98

merged 29 commits into from
Apr 14, 2025

Conversation

coodos
Copy link
Contributor

@coodos coodos commented Apr 9, 2025

Description of change

Add key rotation stuff

Issue Number

closes #18
closes #19
closes #20
closes #21

Type of change

  • New (a change which implements a new feature)

How the change has been tested

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

    • Introduced new dependencies to enhance functionality.
    • Added new error classes to improve error handling for specific conditions in log management.
    • Implemented a log manager class for generating and managing historic event logs.
    • Added utility functions for data type conversions and array operations, improving data handling capabilities.
  • Bug Fixes

    • Enhanced error handling for log event creation, addressing potential issues with invalid options.
  • Tests

    • Established a suite of unit tests for logging and codec utilities, ensuring functionality and robustness through various scenarios.

@coodos coodos marked this pull request as ready for review April 9, 2025 08:18
@coodos coodos force-pushed the feat/w3id-log-generation branch from 3cfcf75 to 0654e1e Compare April 9, 2025 12:05
@coodos coodos force-pushed the feat/w3id-log-generation branch from 0654e1e to bdf3bd1 Compare April 9, 2025 12:06
Copy link
Contributor

coderabbitai bot commented Apr 9, 2025

Warning

Rate limit exceeded

@sosweetham has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 10 minutes and 53 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

📥 Commits

Reviewing files that changed from the base of the PR and between 123fa49 and c9c6d5e.

📒 Files selected for processing (2)
  • infrastructure/w3id/src/logs/log.types.ts (1 hunks)
  • infrastructure/w3id/src/utils/hash.ts (1 hunks)

Walkthrough

This pull request introduces several new features and utilities for the W3ID infrastructure. Three new dependencies are added to the package configuration. New error classes specifically for log chain and signature validations are implemented. The log management subsystem now includes an IDLogManager class with methods for creating genesis and rotation log entries, validating log chains, and handling log event creation. Additional TypeScript types, utility functions for arrays, encoding/decoding, and hashing are also added, along with comprehensive tests for log management functionality.

Changes

File(s) Change Summary
infrastructure/w3id/package.json Added dependencies: canonicalize@^2.1.0, multiformats@^13.3.2, and tweetnacl@^1.0.3.
infrastructure/w3id/src/errors/errors.ts Added five new error classes: MalformedIndexChainError, MalformedHashChainError, BadSignatureError, BadNextKeySpecifiedError, and BadOptionsSpecifiedError.
infrastructure/w3id/src/logs/log-manager.ts Introduced IDLogManager class with methods: validateLogChain, appendEntry, createGenesisEntry, and createLogEvent for managing log events.
infrastructure/w3id/src/logs/log.types.ts Added types and type guard functions for log events: LogEvent, VerifierCallback, Signer, RotationLogOptions, GenesisLogOptions, and CreateLogEventOptions.
infrastructure/w3id/src/utils/array.ts Added the utility function isSubsetOf to determine if one array is a subset of another.
infrastructure/w3id/src/utils/codec.ts Added utility functions uint8ArrayToHex, hexToUint8Array, and stringToUint8Array for data conversion.
infrastructure/w3id/src/utils/hash.ts Introduced an asynchronous hash function to compute a SHA-256 hash from a string or an object, with canonicalization support.
infrastructure/w3id/tests/logs/log.test.ts Added a new test suite for log management including an in-memory storage class, log event creation tests, signature verification via verifierCallback, and a helper createSigner function.
infrastructure/w3id/tests/utils/codec.test.ts Added tests for utility functions: uint8ArrayToHex, hexToUint8Array, and stringToUint8Array.

Sequence Diagram(s)

sequenceDiagram
  participant C as Client/Application
  participant LM as IDLogManager
  participant VC as verifyCallback

  C->>LM: createLogEvent(options)
  alt Genesis Entry
    LM->>LM: createGenesisEntry(options)
  else Rotation Entry
    LM->>LM: appendEntry(entries, options)
  end
  LM->>VC: verify signature
  VC-->>LM: verification result
  LM->>C: Return log event
Loading

Assessment against linked issues

Objective Addressed Explanation
Pre-Rotation Key Setup (#18)
Generate Rotation Log Entry (#19)
Data Integrity Proof for Rotation (#20)
Update DID Document for Rotation (#21) DID Document update logic is not present in these changes.

Poem

I'm a rabbit hopping through the code,
New logs and errors light my abode. 🐇
Dependencies join the joyful race,
Signing entries with a gentle grace.
I nibble bugs, skip errors in my stride,
Celebrating changes with a boundless pride!


🪧 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.
    • Generate unit testing code for this file.
    • 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 generate unit testing code for this file.
    • @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 generate unit testing code.
    • @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.

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 resolve resolve all the CodeRabbit review comments.
  • @coderabbitai plan to trigger planning for file edits and PR creation.
  • @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: 1

♻️ Duplicate comments (2)
infrastructure/w3id/src/logs/log.types.ts (1)

1-9: Consider renaming LogEvent for clarity.
The past review comment suggested that LogEvent is ambiguous and should be renamed to a more descriptive name (e.g., EventType). This aligns with prior feedback and might improve clarity.

infrastructure/w3id/src/logs/log-manager.ts (1)

74-95: 🛠️ Refactor suggestion

Clarify error case in verifyLogEventProof.
When !proof, the code simply throws a generic Error(). Consider throwing a more descriptive error class (like BadSignatureError or similar) for better debugging consistency.

 if (!proof) {
-  throw new Error();
+  throw new BadSignatureError("No proof found in the log event.");
 }
🧹 Nitpick comments (12)
infrastructure/w3id/src/utils/array.ts (4)

1-4: Documentation should be more detailed.

The function documentation is quite minimal. Consider expanding it to include:

  • Parameter descriptions
  • Return value explanation
  • Example usage
  • Edge case handling
 /**
  * Utility function to check if A is subset of B
+ * 
+ * @param a Array to check if it's a subset
+ * @param b Array to check against
+ * @returns true if every element in 'a' is present in 'b' with at least the same frequency
+ * @example
+ * isSubsetOf([1, 2], [1, 2, 3]) // returns true
+ * isSubsetOf([1, 1, 2], [1, 2, 3]) // returns false (not enough 1's in b)
+ * isSubsetOf([], [1, 2]) // returns true (empty set is a subset of any set)
  */

5-5: Consider using more type-safe parameters.

Using unknown[] provides flexibility but may lead to unexpected behavior with complex objects. Consider using generics to maintain type safety while preserving flexibility.

-export function isSubsetOf(a: unknown[], b: unknown[]) {
+export function isSubsetOf<T>(a: T[], b: T[]): boolean {

5-20: Consider adding error handling for edge cases.

The function doesn't explicitly handle cases where the inputs might be null or undefined, which could lead to runtime errors.

 export function isSubsetOf(a: unknown[], b: unknown[]) {
+	if (!Array.isArray(a) || !Array.isArray(b)) {
+		throw new TypeError('Both arguments must be arrays');
+	}
+
 	const map = new Map();

 	for (const el of b) {

6-17: Consider using more descriptive variable names.

The variable names a, b, and el are very generic. More descriptive names would make the code more readable.

-export function isSubsetOf(a: unknown[], b: unknown[]) {
-	const map = new Map();
+export function isSubsetOf(subset: unknown[], superset: unknown[]) {
+	const elementCounts = new Map();

-	for (const el of b) {
-		map.set(el, (map.get(el) || 0) + 1);
+	for (const element of superset) {
+		elementCounts.set(element, (elementCounts.get(element) || 0) + 1);
 	}

-	for (const el of a) {
-		if (!map.has(el) || map.get(el) === 0) {
+	for (const element of subset) {
+		if (!elementCounts.has(element) || elementCounts.get(element) === 0) {
 			return false;
 		}
-		map.set(el, map.get(el) - 1);
+		elementCounts.set(element, elementCounts.get(element) - 1);
 	}
infrastructure/w3id/src/errors/errors.ts (1)

1-9: Consider enhancing error classes with constructors and context information

While the error classes are correctly extending the base Error class, they lack custom constructors and contextual properties. This limits their usefulness in providing detailed error information.

Consider enhancing the error classes with custom constructors:

-export class MalformedIndexChainError extends Error {}
+export class MalformedIndexChainError extends Error {
+  constructor(message: string = "Malformed index chain detected") {
+    super(message);
+    this.name = "MalformedIndexChainError";
+  }
+}

-export class MalformedHashChainError extends Error {}
+export class MalformedHashChainError extends Error {
+  constructor(message: string = "Malformed hash chain detected") {
+    super(message);
+    this.name = "MalformedHashChainError";
+  }
+}

// Apply similar pattern to other error classes

This would provide more descriptive error messages and make it easier to identify the error type in stack traces.

infrastructure/w3id/src/utils/hash.ts (1)

1-26: Well-implemented hash function with a minor opportunity for reuse

The hash function implementation correctly handles both string and object inputs with appropriate canonicalization. The SHA-256 algorithm is a good choice for this use case.

Consider two minor improvements:

  1. Provide more context in the canonicalization error message:
-throw new Error("Failed to canonicalize object");
+throw new Error(`Failed to canonicalize object: ${JSON.stringify(input).substring(0, 100)}...`);
  1. The hex conversion logic at lines 21-23 could be extracted to a reusable function, as similar logic appears in the codec.ts file:
-const hashHex = hashArray
-  .map((b) => b.toString(16).padStart(2, "0"))
-  .join("");
+import { uint8ArrayToHex } from "./codec";
+const hashHex = uint8ArrayToHex(new Uint8Array(hashBuffer));

This would require resolving any circular dependencies if they occur.

infrastructure/w3id/src/logs/log.types.ts (2)

17-20: Rename overshadowed parameter in sign.
In the Signer type, the parameter (string: string) shadows the type name. Consider renaming it to message: string or similar to avoid confusion.

 type Signer = {
-  sign: (string: string) => Promise<string> | string;
+  sign: (message: string) => Promise<string> | string;
   pubKey: string;
 };

22-26: Optional alignment between RotationLogOptions and GenesisLogOptions.
Both interfaces share similar fields such as nextKeyHashes and signer. If your roadmap allows, consider consolidating common properties in a base interface to reduce duplication.

Also applies to: 28-32, 45-45

infrastructure/w3id/tests/logs/log.test.ts (2)

27-63: Ensure robust error handling in InMemoryStorage.
The Not found error is quite generic. Consider using or extending your domain-specific errors for consistency and clarity when an item is missing.


200-200: Avoid performance overhead from delete operator.
Static analysis warns that using delete may have performance impacts. You could set events[1].proof = undefined; instead to handle property removal while avoiding potential performance pitfalls.

- delete events[1].proof;
+ events[1].proof = undefined;
🧰 Tools
🪛 Biome (1.9.4)

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

Unsafe fix: Use an undefined assignment instead.

(lint/performance/noDelete)

infrastructure/w3id/src/logs/log-manager.ts (2)

27-27: Add documentation for the TODO.
A TODO is noted, but it’s unclear what the specification link should contain. Please clarify the doc reference or remove the TODO if no longer needed.


97-121: Watch for concurrency in appendEntry.
If multiple clients concurrently append, you might need to ensure no race conditions occur with reading latestEntry from storage. Consider synchronizing or using transaction logic if concurrency is expected.

📜 Review details

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

📥 Commits

Reviewing files that changed from the base of the PR and between a356077 and 5042403.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (8)
  • infrastructure/w3id/package.json (1 hunks)
  • infrastructure/w3id/src/errors/errors.ts (1 hunks)
  • infrastructure/w3id/src/logs/log-manager.ts (1 hunks)
  • infrastructure/w3id/src/logs/log.types.ts (1 hunks)
  • infrastructure/w3id/src/utils/array.ts (1 hunks)
  • infrastructure/w3id/src/utils/codec.ts (1 hunks)
  • infrastructure/w3id/src/utils/hash.ts (1 hunks)
  • infrastructure/w3id/tests/logs/log.test.ts (1 hunks)
🧰 Additional context used
🧬 Code Graph Analysis (1)
infrastructure/w3id/src/logs/log-manager.ts (4)
infrastructure/w3id/src/logs/log.types.ts (7)
  • LogEvent (1-9)
  • VerifierCallback (11-15)
  • RotationLogOptions (22-26)
  • GenesisLogOptions (28-32)
  • CreateLogEventOptions (45-45)
  • isRotationOptions (39-43)
  • isGenesisOptions (34-38)
infrastructure/w3id/src/errors/errors.ts (5)
  • MalformedIndexChainError (1-1)
  • MalformedHashChainError (3-3)
  • BadSignatureError (5-5)
  • BadNextKeySpecifiedError (7-7)
  • BadOptionsSpecifiedError (9-9)
infrastructure/w3id/src/utils/hash.ts (1)
  • hash (3-26)
infrastructure/w3id/src/utils/array.ts (1)
  • isSubsetOf (5-20)
🪛 Biome (1.9.4)
infrastructure/w3id/tests/logs/log.test.ts

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

Unsafe fix: Use an undefined assignment instead.

(lint/performance/noDelete)

🔇 Additional comments (10)
infrastructure/w3id/src/utils/array.ts (1)

5-20: Function implementation is correct and efficient.

The implementation correctly checks if array a is a subset of array b using a Map to track element occurrences, handling duplicates properly. The time complexity is O(|a| + |b|) which is optimal for this operation.

infrastructure/w3id/package.json (1)

22-24: New dependencies added for W3ID infrastructure

The addition of these three dependencies is appropriate for the key rotation functionality being implemented:

  • canonicalize for consistent JSON serialization (used in hash.ts)
  • multiformats for handling various data formats
  • tweetnacl for cryptographic operations (signatures, verification)

All are using caret versioning which allows for compatible updates while maintaining major version stability.

infrastructure/w3id/src/utils/codec.ts (3)

1-5: Well-implemented hex encoding function

The uint8ArrayToHex function efficiently converts binary data to a hexadecimal string representation using a clean approach with proper zero-padding.


7-16: Thorough implementation with proper validation

The hexToUint8Array function correctly validates input and efficiently converts hex strings to binary data. The validation for even-length strings is particularly important for preventing errors.


18-20: Simple and effective string to binary conversion

The stringToUint8Array function uses the standard TextEncoder API, which is the correct approach for converting strings to binary data in modern JavaScript environments.

infrastructure/w3id/src/logs/log.types.ts (1)

34-43: Good use of type guards.
The isGenesisOptions and isRotationOptions functions correctly narrow the union type. It helps ensure type safety when handling log creation logic and improves maintainability.

infrastructure/w3id/tests/logs/log.test.ts (2)

70-85: Good approach to signature verification
Implementing a verifierCallback that decodes and verifies signatures with tweetnacl is clear. This helps ensure the correctness of logs while keeping cryptographic operations modular.


87-98: Clean signer creation.
The createSigner helper is straightforward and matches your sign/verify logic, promoting test clarity. Good job verifying that the correct signature is produced.

infrastructure/w3id/src/logs/log-manager.ts (2)

36-72: Comprehensive log chain validation.
The validateLogChain method properly checks index sequences, hash matching, and calls verifyLogEventProof. This coverage fosters robust chain integrity. Good job.


139-147: Concise creation logic
Using isRotationOptions or isGenesisOptions to branch logic is clean and maintainable. Properly throws BadOptionsSpecifiedError for mismatching options.

* starting with generating it's first log entry
*/

// TODO: Create a specification link inside our docs for how generation of identifier works

Choose a reason for hiding this comment

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

I would remove the TODO and create an issue instead

Copy link
Member

Choose a reason for hiding this comment

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

concur @coodos, unless you had something else in mind

currentNextKeyHashesSeen,
);
if (!updateKeysSeen || lastHash !== _hash)
throw new MalformedHashChainError();

Choose a reason for hiding this comment

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

If we add a message or error key we can add more details here. It makes it easier to debug in production

Copy link
Member

@sosweetham sosweetham Apr 9, 2025

Choose a reason for hiding this comment

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

might be vague on purpose, @coodos confirm pl, although i dont see much of a problem throwing out the key in the message cuz it's wrong anyways lol

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: 0

🧹 Nitpick comments (2)
infrastructure/w3id/tests/utils/codec.test.ts (2)

1-7: Remove unused import.

The falso import from "@ngneat/falso" is not used anywhere in this test file and should be removed.

import {
  uint8ArrayToHex,
  hexToUint8Array,
  stringToUint8Array,
} from "../../src/utils/codec";
-import falso from "@ngneat/falso";
import { describe, test, expect } from "vitest";

9-34: Consider adding more edge case tests.

While the current tests cover basic functionality, consider adding tests for:

  • Empty inputs for all functions
  • Non-hexadecimal characters for hexToUint8Array
  • Unicode characters for stringToUint8Array

This would improve test coverage and ensure robustness of these utility functions.

📜 Review details

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

📥 Commits

Reviewing files that changed from the base of the PR and between 5042403 and 9c35430.

📒 Files selected for processing (1)
  • infrastructure/w3id/tests/utils/codec.test.ts (1 hunks)
🧰 Additional context used
🧬 Code Graph Analysis (1)
infrastructure/w3id/tests/utils/codec.test.ts (1)
infrastructure/w3id/src/utils/codec.ts (3)
  • uint8ArrayToHex (1-5)
  • hexToUint8Array (7-16)
  • stringToUint8Array (18-20)
🔇 Additional comments (4)
infrastructure/w3id/tests/utils/codec.test.ts (4)

10-14: Test looks good.

The test case for uint8ArrayToHex properly verifies the expected behavior with a simple input array.


16-20: Test looks good.

The test case for hexToUint8Array correctly verifies the conversion from hex string to Uint8Array.


22-27: Test looks good.

The test appropriately verifies the error handling for invalid input (odd-length hex string).


29-33: Test looks good.

The test case for stringToUint8Array correctly verifies UTF-8 encoding of a simple string.

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: 0

🧹 Nitpick comments (3)
infrastructure/w3id/src/utils/array.ts (1)

1-11: Consider clarifying how non-primitive array elements are handled.
The doc examples focus on numeric elements, but the function parameters are typed as unknown[]. When arrays contain objects or other complex types, this code relies on reference equality, which may be unintuitive.

infrastructure/w3id/src/logs/log-manager.ts (2)

27-27: Replace TODO comment with an issue reference.
Longstanding TODOs can become stale. Consider removing the comment and opening an issue to track documentation improvements.

Do you want help creating an issue for this?


36-72: Check for undefined canonicalize(e).
While canonicalize normally returns a string, in edge cases it could return undefined. Consider handling or validating the return before casting to string.

📜 Review details

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

📥 Commits

Reviewing files that changed from the base of the PR and between 9c35430 and af977ed.

📒 Files selected for processing (3)
  • infrastructure/w3id/src/logs/log-manager.ts (1 hunks)
  • infrastructure/w3id/src/utils/array.ts (1 hunks)
  • infrastructure/w3id/tests/utils/codec.test.ts (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • infrastructure/w3id/tests/utils/codec.test.ts
🧰 Additional context used
🧬 Code Graph Analysis (1)
infrastructure/w3id/src/logs/log-manager.ts (4)
infrastructure/w3id/src/logs/log.types.ts (7)
  • LogEvent (1-9)
  • VerifierCallback (11-15)
  • RotationLogOptions (22-26)
  • GenesisLogOptions (28-32)
  • CreateLogEventOptions (45-45)
  • isRotationOptions (39-43)
  • isGenesisOptions (34-38)
infrastructure/w3id/src/errors/errors.ts (5)
  • MalformedIndexChainError (1-1)
  • MalformedHashChainError (3-3)
  • BadSignatureError (5-5)
  • BadNextKeySpecifiedError (7-7)
  • BadOptionsSpecifiedError (9-9)
infrastructure/w3id/src/utils/hash.ts (1)
  • hash (3-26)
infrastructure/w3id/src/utils/array.ts (1)
  • isSubsetOf (13-28)
🔇 Additional comments (8)
infrastructure/w3id/src/utils/array.ts (1)

13-28: Verify intended behavior for reference equality.
If arrays contain objects, the map checks by strict object reference. Confirm that this is the desired behavior and doesn't require a deep comparison. Otherwise, you might need a custom comparator or hashing approach for object elements.

infrastructure/w3id/src/logs/log-manager.ts (7)

1-21: Imports and type references look good.
No issues found with the imported modules or type references.


22-25: Doc comment for IDLogManager is succinct and clear.
Provides a concise overview of the class responsibilities.


29-34: Constructor implementation is straightforward.
No potential issues found; it properly assigns the repository.


74-95: No major concerns in log event proof verification.
The logic and error handling are properly scoped.


97-121: Rotation entry logic appears correct.
It validates the signer's key against latestEntry.nextKeyHashes and constructs a new log event. Implementation aligns with the code's stated objectives.


123-137: Ensure that the ID contains an '@' delimiter.
Splitting id by '@' might result in undefined for versionId if there's no separator. Confirm or sanitize id to ensure valid versionId strings are produced.


139-148: createLogEvent method is cohesive and well-structured.
The logic cleanly branches between genesis and rotation flows.

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

🧹 Nitpick comments (1)
infrastructure/w3id/src/utils/hash.ts (1)

27-28: Consider adding try/catch for crypto operations.

While the function has error handling for canonicalization, it might be beneficial to add try/catch blocks around the crypto operations to handle potential errors from crypto.subtle.digest.

  let dataToHash: string;

  if (typeof input === "string") {
    dataToHash = input;
  } else {
    const canonical = canonicalize(input);
    if (!canonical) {
      throw new Error(
        `Failed to canonicalize object: ${JSON.stringify(input).substring(0, 100)}...`,
      );
    }
    dataToHash = canonical;
  }

  const buffer = new TextEncoder().encode(dataToHash);
+ try {
    const hashBuffer = await crypto.subtle.digest("SHA-256", buffer);
    const hashHex = uint8ArrayToHex(
      new Uint8Array(hashBuffer),
    );

    return hashHex;
+ } catch (error) {
+   throw new Error(`Failed to compute hash: ${error instanceof Error ? error.message : String(error)}`);
+ }
}
📜 Review details

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

📥 Commits

Reviewing files that changed from the base of the PR and between af977ed and 123fa49.

📒 Files selected for processing (2)
  • infrastructure/w3id/src/errors/errors.ts (1 hunks)
  • infrastructure/w3id/src/utils/hash.ts (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • infrastructure/w3id/src/errors/errors.ts
🧰 Additional context used
🧬 Code Graph Analysis (1)
infrastructure/w3id/src/utils/hash.ts (1)
infrastructure/w3id/src/utils/codec.ts (1)
  • uint8ArrayToHex (1-5)
🔇 Additional comments (3)
infrastructure/w3id/src/utils/hash.ts (3)

1-3: Good choice of imports for the hashing utility.

The canonicalize package is appropriate for ensuring consistent JSON representation of objects, and importing uint8ArrayToHex from a local utility module follows good modular design principles.


4-6: Function signature is well-defined.

The async function declaration with proper TypeScript typings (string or Record input, Promise output) provides a clear contract to callers.


7-19: Input validation and canonicalization handling is thorough.

The code properly handles both string and object inputs, with appropriate error handling when canonicalization fails. The error message includes a truncated version of the input which is helpful for debugging without overwhelming logs.

@JulienAuvo JulienAuvo merged commit 6bccab0 into main Apr 14, 2025
4 checks passed
@coodos coodos deleted the feat/w3id-log-generation branch April 14, 2025 14:18
@coderabbitai coderabbitai bot mentioned this pull request Apr 16, 2025
6 tasks
@nsergey82
Copy link
Contributor

Meta-question: not sure how you, folks, feel about necro-comments into merged PRs -- would you rather I opened an issue?

And the actual question (not the only one): here you refer to "log" in the KERI sense, not in the sense assumed by Alex in design document, right?

coodos added a commit that referenced this pull request Jul 7, 2025
* chore: create basic log generation mechanism

* chore: add hashing utility function

* chore: rotation event

* feat: genesis entry

* feat: generalize hash function

* feat: append entry

* chore: basic tests

* chore: add tests for rotation

* feat: add malform throws

* chore: add the right errors

* chore: fix CI stuff

* chore: add missing file

* chore: fix event type enum

* chore: format

* feat: add proper error

* chore: format

* chore: remove eventtypes enum

* chore: add new error for bad options

* chore: add options tests

* feat: add codec tests

* fix: err handling && jsdoc

* fix: run format

* fix: remove unused import

* fix: improve default error messages

* fix: move redundant logic to function

* fix: run format

* fix: type shadow

* fix: useless conversion/cast

* fix: run format

---------

Co-authored-by: Soham Jaiswal <[email protected]>
coodos added a commit that referenced this pull request Jul 7, 2025
* initial commit

* chore: add w3id readme (#3)

* chore: add w3id readme

* chore: bold text

* chore: better formatting

* docs: add w3id details

* chore: format

* chore: add links

* fix: id spec considerations addressal (#8)

* fix: id spec considerations addressal

* fix: identity -> indentifier

* chore: expand on trust list based recovery

* chore: expand on AKA

---------

Co-authored-by: Merul Dhiman <[email protected]>

* Docs/eid wallet (#10)

* chore: add eid-wallet folder

* chore: add eid wallet docs

* feat: add (#9)

* feat(w3id): basic setup (#11)

* feat(w3id): basic setup

* fix(root): add infrastructure workspaces

* update: lock file

* feat(eidw): setup tauri (#40)

* Feat/setup daisyui (#46)

* feat: setup-daisyui

* fix: index file

* feat: colors added

* feat: Archivo font added

* fix: postcss added

* fix: +layout.svelte file added

* fix: packages

* fix: fully migrating to tailwind v4

* feat: add Archivo font

* feat: add danger colors

* feat: twmerge and clsx added

* feat: shadcn function added

---------

Co-authored-by: Bekiboo <[email protected]>
Co-authored-by: Julien <[email protected]>

* feat: add storybook (#45)

* feat: add storybook

* update: lockfile

* feat: created connection button (#48)

* created connection button

* added restprops to parent class

* added onClick btn and storybook

* fix: make font work in storybook (#54)

* Feat/header (#55)

* feat: add icons lib

* fix: make font work in storybook

* feat: Header

* feat: runtime global added, icon library created, icons added, type file added

* feat: header props added

* fix: remove icons and type file as we are using lib for icons

* fix: heading style

* fix: color and icons, git merge branch 51, 54

* fix: color

* fix: header-styling

* fix: classes

* chore: handlers added

* chore: handlers added

* fix: added heading

---------

Co-authored-by: Soham Jaiswal <[email protected]>

* Alternative w3id diagram (#52)

* Feat/cupertino pane (#49)

* feat: Drawer

* feat: Drawer and added a function for clickoutside in utils

* fix: classes

* fix: drawer button position

* fix: style and clickoutside

* fix: pane height

* fix: border-radius

* fix: drawer as bulletin

* fix: styling

* fix: component with inbuilt features

* fix: remove redundant code

* fix: remove redundant code

* fix: cancel button

* fix: css in storybook

* fix: position

* fix: height of pane

* fix: remove redundant code

* feat: add button action component (#47)

* feat: add button action component

* fix: add correct weights to Archivo fontt

* feat: add base button

* fix: set prop classes last

* feat: improve loading state

* chore: cleanup

* feat: add button action component

* fix: add correct weights to Archivo fontt

* feat: add base button

* fix: set prop classes last

* feat: improve loading state

* chore: cleanup

* chore: add documentation

* fix: configure Storybook

* chore: storybook gunk removal

* feat: enhance ButtonAction component with type prop and better error handling

---------

Co-authored-by: JulienAuvo <[email protected]>

* Feat/splash screen (#63)

* feat: SplashScreen

* fix: remove redundant code

* fix: as per given suggestion

* fix: font-size

* fix: logo

* feat: input-pin (#56)

* feat: input-pin

* fix: styling as per our design

* fix: added small variant

* fix: hide pin on select

* fix: gap between pins

* fix: color of focus state

* fix: removed legacy code and also fix some css to tailwind css

* fix: css

* fix: optional props

* feat: added color variants

* Feat/improve button component (#60)

* feat: add white variant

* feat: add small variant

* chore: update doc and story for button

* chore: rename cb into callback

* update: improve small size

* update: modify loading style

* fix: return getAbsolutePath function to storybook (#58)

Co-authored-by: Bekiboo <[email protected]>

* feat: add selector component (#59)

* feat: add selector component

* feat: improve selector + add flag-icon lib

* feat: improve selector + doc

* feat: add utility function to get language with country name

* feat: test page for language selectors

* chore: add Selector Story

* chore: clean test page

* fix: types

* fix: normalize custom tailwind colors (#71)

* feat: workflows (#64)

* feat: workflows

* fix: node version

* fix: use pnpm 10

* fix: check message

* Fix/codebase linting (#73)

* fix: Check Lint / lint

* fix: Check Lint / lint

* fix: Check Lint / lint

* fix: Check Lint / lint

* fix: Check Code / lint

* fix: Check Format / lint

* fix: Check Code / lint

* fix: Check Format / lint

* fix: Check Code / lint

* fix: Check Format / lint

* fix: Check Code / lint

* fix: Check Code / lint

* fix: Check Format / lint

* fix: unknown property warning

* fix: unknown property warning

* chore: improve args type

* settings nav button :) (#75)

* setting bav button all done :)

* lint fixski

* added component to index.ts

* Feat/#32 identity card fragment (#74)

* identity card

* identity card

* lint fixski

* lint fixski

* lint fixski

* fixed the font weight

* added component to index.ts

* changed span to buttton

* feat: add icon button component (#68)

* feat: add icon button component

* feat: finish up buttonIcon + stories

* fix: update with new color naming

* feat: polish button icon (and button action too)

* chore: format lint

* chore: sort imports

* chore: format, not sure why

* Feat/onboarding flow (#67)

* feat: onboarding-page

* fix: line height and added handlers

* fix: button variant

* fix: text-decoration

* fix: subtext

* fix: underline

* fix: padding and button spacing

* fix: according to design update

* feat: Drawer

* feat: verify-pae

* fix: verify-page styling

* feat: drawer for both confirm pin and add bio metrics added

* feat: modal added in fragments

* fix: icons and flow

* feat: Identifier Card

* fix: copy to clipboard

* feat: e-passport page

* fix: error state

* fix: colors

* fix: lint error

* fix: lint

* feat: Typography

* fix: typograpy

* fix: as per given suggestion

* fix: font-sizing

* fix: identity card implementation

* fix: spacing

* fix: padding

* fix: padding and spacing

* fix: splashscreen

* fix: error state

* fix: styling to avoid

* fix:typo

* Fix/remove daisyui (#82)

* refactoring: remove DaisyUI + refactor some tailwind classes and logic

* refactoring: remove DaisyUI + refactor some tailwind classes and logic

* feat: add Button.Nav (#77)

* feat: add Button.Nav

* chore: format

* chore: sort imports

* update: remove unused snippet and add missing props

* feat: stick to fragment definition

* update: documentation

* fix: stories

* chore: sort imports

* Feat/splashscreen animation (#81)

* feat: add animation to splashScreen

* feat: implement data loading logic with splash screen delay

* chore: sort import

* update: use ButtonIcon is IdentityCard (#78)

* update: use ButtonIcon is IdentityCard

* feat: refactor ButtonIcon to be used anywhere in the app

* chore: format indent

* chore: remove useless change

* feat: setup safe area (#80)

* feat: setup safe area

* chore: simplify implementation

* chore: format

* Feat/uuidv5 generation (#61)

* feat: setup uuidv5

* chore: add test for deterministic UUID

* feat: add Hero fragment (#88)

* feat: add Hero fragment

* chore: sort imports + add doc

* feat: add storage specification abstract class (#92)

* feat: add storage specification abstract class

* chore: format and ignore lint

* chore: change format checker on w3id

* feat: settings-flow (#86)

* feat: settings-flow

* feat: settings and language page

* feat
: history page

* feat: change pin page

* fix: height of selector

* fix: pin change page

* fix: size of input pin

* fix: spacing of pins

* feat: AppNav fragment

* fix: height of page

* fix: padding

* fix: remove redundant code

* feat: privacy page

* chore: add doc

* fix: error state

* feat: remove redundant code

* chore: used app nav component

---------

Co-authored-by: JulienAuvo <[email protected]>

* feat: AppNav fragment (#90)

* feat: AppNav fragment

* chore: add doc

* feat: Main page flow (#93)

* feat: create root page + layout

* feat: complete main page flow beta

* chore: fix ts block

* chore: sort imports

* feat: integrate-flows (#94)

* feat: intigrate-flows

* fix: spacing in e-passport page

* fix: page connectivity

* feat: app page transitions

* fix: z index

* fix: pages

* fix: view transition effect on splashscreen

* fix: drawer pill and cancel button removed

* fix: share button removed when onboarding

* fix: remove share and view button when on onboarding flow

* fix: remove view button

* fix: ci checks

* fix: transitions

* fix: transititon according to direction

* fix: lint error

* fix: loop holes

* Feat/w3id log generation (#98)

* chore: create basic log generation mechanism

* chore: add hashing utility function

* chore: rotation event

* feat: genesis entry

* feat: generalize hash function

* feat: append entry

* chore: basic tests

* chore: add tests for rotation

* feat: add malform throws

* chore: add the right errors

* chore: fix CI stuff

* chore: add missing file

* chore: fix event type enum

* chore: format

* feat: add proper error

* chore: format

* chore: remove eventtypes enum

* chore: add new error for bad options

* chore: add options tests

* feat: add codec tests

* fix: err handling && jsdoc

* fix: run format

* fix: remove unused import

* fix: improve default error messages

* fix: move redundant logic to function

* fix: run format

* fix: type shadow

* fix: useless conversion/cast

* fix: run format

---------

Co-authored-by: Soham Jaiswal <[email protected]>

* Feat/core id creation logic (#99)

* feat: create w3id builder

* fix: w3id builder

* feat: add global config var for w3id

* chore: add docs

* chore: change rand to crng

* chore: add ts type again

* chore: fix lint and format

* chore: add w3id tests github workflow

* Feat/evault core (#100)

* feat: migrate neo4j

* chore: envelope logic works

* chore: envelope logic works

* feat: parsed envelopes search

* feat: generics

* feat: protocol

* feat: jwt sigs in w3id

* chore: stuff works

* chore: tests for evault core

* chore: format

* chore: fix test

* Feat/docker compose and docs (#101)

* chore: stash dockerfile progress

* fix: getEnvelopesByOntology thing

* chore: fix tests

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

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* chore: remove unused import

* chore: remove package

* chore: fix pnpm lock

* chore: fix workflow

* chore: fix port in dockerfile

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* Feat/registry and evault provisioning (#106)

* feat: evault provisioning

* chore: fianlly fixed provisioner

* feat: add logic for metadata in consul

* feat: registry

* chore: format

* Feat/watchers logs (#114)

* feat: alloc according to entropy and namespace

* chore: move exports

* chore: docs

* feat: `whois` endpoint

* feat: watcher endpoints

* chore: fix format and lint

* chore: fix tests

* feat: web3 adapter (#115)

* feat: tauri plugins setup (#97)

* feat: tauri plugins setup

* fix: add editorconfig

* fix: add missing biome json

* fix: run formatter

* feat: biometry homework

* feat: add pin set logic

* feat: add biometric enabling logic

* fix: sec controller qol

* feat: stub user controller

* fix: run format && lint

* fix: sort imports

* fix: import statement sort

* feat: user controller

* feat: pin flow

* feat: biometrics unavailable

* fix: pin input not working

* feat: make checks pass

* fix: scan works

* fix: actions

* feat: format on save

* fix: coderabbit suggestions

* chore: run format lint check

* fix: scan on decline too

* feat: documentation links (#117)

* feat: bad namespace test (#116)

* fix: layouts (#119)

* fix: layouts

* fix: Onboarding page scroll fixed

* fix: page layout and prevent from scroll in all devices

* fix: pages layout

* chore: try to fix emulator

* fix: units

* fix: safezones for ios

* fix: styling

---------

Co-authored-by: Soham Jaiswal <[email protected]>

* feat: setup-metagram (#121)

* feat: setup-metagram

* chore: tailwind css worked

* feat: fonts added

* feat: typography

* fix: removed stories and fixed setup for icons lib

* feat: icons and story file

* fix: type of args in story

* fix: lint errors

* feat: colors added

* feat: Button

* fix: format and lint

* fix: colors

* fix: spinner

* fix: code rebbit suggestions

* fix: code rebbit suggestions

* fix: paraglide removed

* fix: lock file

* feat: added user avatar. (#130)

* feat: Button (#129)

* feat: Button

* fix: colors of variants

* feat: Input (#131)

* feat: Input

* feat: styling added

* fix: styling

* fix: styling

* fix: added a new story

* fix: focus states

* fix: input states

* Feat/settings navigation button (#140)

* feat: settings-navigation-button

* fix: handler added

* chore: another variant added

* fix: as per given suggestion

* feat: BottomNav (#132)

* feat: BottomNav

* fix: icons

* feat: profile icons created

* feat: handler added

* feat: handler added

* fix: correct tags

* fix: as per given suggestion, bottomnav moved to fragments and also implemented on page

* fix: handler

* chore: routes added

* feat: app transitions added

* fix: direction of transition

* fix: transition css

* fix: directionable transition

* fix: used button instead of label, and used page from state

* feat: added post fragment. (#137)

* feat: FileInput (#150)

* feat: FileInput

* fix: added icon

* feat: cancel upload

* fix: remove redundant code

* fix: usage docs added and as per requirements
'

* fix: moved to framents

* feat: Toggle Switch (#143)

* feat: Toggle Switch

* feat: Toggle Switch

* fix: as per our design

* fix: as per our design

* feat: Label (#146)

* feat: Select (#148)

* feat: Select

* fix: as per our design

* fix: code format and as per svelte 5

* fix: font-size

* fix: font-size

* fix: icon

* feat: message-input (#144)

* feat: message-input

* fix: classes merge and a files as a prop

* feat: variant added

* feat: icon replaced

* fix: as per code rabbit suggestions

* fix: icon

* fix: input file button

* fix: as per suggestion

* fix: classes

* fix: no need of error and disabled classes

* fix: input

* feat: invalid inputs

* feat: add number input storybook

---------

Co-authored-by: Soham Jaiswal <[email protected]>

* feat:Drawer (#152)

* feat:Drawer

* feat: Drawer with clickoutside

* fix: settings

* Feat/metagram header (#133)

* feat: added metagram header primary linear gradient.

* feat: added flash icon.

* feat: added secondary state of header.

* feat: added secondary state of header with menu.

* chore: cleaned some code.

* docs: updated component docs.

---------

Co-authored-by: SoSweetHam <[email protected]>

* Feat/metagram message (#135)

* feat: added metagram message component.

* feat: added both states of message component.

* docs: added usage docs.

* chore: exposed component from ui.

* fix: component -> fragement

---------

Co-authored-by: SoSweetHam <[email protected]>

* feat: modal (#154)

* fix: styling of modal

* fix: modal props

* fix: conflicting styles

* fix: styles of drawer

* fix: hide scrollbar in drawer

* fix: padding

* fix: used native method for dismissing of drawer

* feat: Context-Menu (#156)

* feat: Context-Menu

* fix: name of component

* fix: as per suggestion

* fix: action menu position

* fix: class

* feat: responsive-setup (#157)

* feat: responsive-setup

* fix: background color

* fix: added font fmaily

* feat: responsive setup for mobile and desktop (#159)

* feat: responsive setup for mobile and desktop

* fix: width of sidebar and rightaside

* fix: responsive layout

* feat: SideBar

* fix: added some finishing touches to sidebar and button

* fix: prevent pages transition on desktop

* fix: icon center

* feat: settings page and icon added

* feat/layout-enhancement (#168)

* feat/infinite-scroll (#170)

* feat/infinite-scroll

* fix: aspect ratio of post

* fix: bottom nav background

* settings page (#169)

* settings page layout done

* settings page layout done

* formt fix

* format fix

* format fix

* routing for settings page fixed

* settings page buttons

* merge conflict

* settings page tertiary pages

* settings pages all done

* settings pages unnecessary page deleted

* requested changes done

* requested changes done

* Feat/comments pane (#171)

* feat/comments-pane

* fix: overflow and drawer swipe

* feat: Comment fragment

* fix: comments added

* fix: comment fragment

* feat: Comments reply

* fix: message input position

* fix: post type shifted to types file

* fix: one level deep only

* fix: drawer should only be render on mobile

* fix: comments on layout page

* fix: format

* feat: messages (#174)

* feat: messages

* feat: ChatMessae

* feat: messages by id

* fix: messages page

* fix: icon name

* fix: hide bottom nav for chat

* fix: header

* fix: message bubble

* fix: message bubble

* fix: message bubble

* fix: as per suggestion

* fix: messaging

* chore: change from nomad to k8s (#179)

* chore: change from nomad to k8s

* Update infrastructure/eid-wallet/src/routes/+layout.svelte

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* feat: uri extraction

* feat: regitry stuff

* feat: registry using local db

* 📝 Add docstrings to `feat/switch-to-k8s` (#181)

Docstrings generation was requested by @coodos.

* #179 (comment)

The following files were modified:

* `infrastructure/evault-provisioner/src/templates/evault.nomad.ts`

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* chore: format

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* fix: make scan qr page work again (#185)

* feat: Discover Page (#180)

* refactor/Post (#186)

* refactor/Post

* fix: format and lint

* fix: added dots for gallery

* fix: added dots for gallery

* fix: added dots for gallery

* fix: plural name

* feat: splash-screen (#187)

* Feat/evault provisioning via phone (#188)

* feat: eid wallet basic ui for verification

* chore: evault provisioning

* feat: working wallet with provisioning

* feat: restrict people on dupes

* 📝 Add docstrings to `feat/evault-provisioning-via-phone` (#189)

Docstrings generation was requested by @coodos.

* #188 (comment)

The following files were modified:

* `infrastructure/eid-wallet/src/lib/utils/capitalize.ts`
* `infrastructure/evault-provisioner/src/utils/hmac.ts`

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* feat: added uploaded post view component. (#182)

* feat: added uploaded post view component.

* fix: fixed the outline and color.

* fix: moved function to external definition.

* fix: fixed the restProps.

* profile page (#178)

* basic layout for profile page

* fixed alt text

* merge conflict

* profile page for other users implemented

* fix: profile pages and logics

* fixed all the pages of profile

* fixed all the pages of profile

* fix: format

---------

Co-authored-by: gourav <[email protected]>

* Feat/radio input (#176)

* feat: added a radio button custom

* docs: added name option in docs.

* chore: cleaned the unnecessary classes and variables for input type radio.

* fix: moved input radio to its own component.

* fix: keydown events added.

* feat: added settings tile component. (#184)

* feat: added settings tile component.

* chore: fixed the naming convention

* chore: renamed callback to onclick

* fix: fixed the use of restProps

* fix: fixed the unnecessary onclick expose.

* fix: fixed the join function params.

* Feat/textarea (#194)

* chore: removed redundant radio

* feat: added textarea.

* fix: tabindex

* fix: removed type inconsitency.

* Feat/mobile upload flow (#193)

* fix: header logic in secondary

* fix: fixed the text in header in post

* feat: trying some hack to get file image input.

* feat: added image input on clicking the post bottom nav

* chore: got rid of non-required code.

* feat: added the logic to get the images from user on clicking post tab.

* feat: added store.

* feat: added correct conversion of files.

* feat: added the correct display of image when uploading.

* feat: added settings tile to the post page and fixed the settingsTile component type of currentStatus

* feat: added hte correct header for the audience page.

* fix: fixed the page transition not happening to audience page.

* feat: added audience setting

* feat: added store to audience.

* chore: removed console log

* feat: added post button.

* feat: correct button placement

* fix: horizontal scroll

* fix: positioning of the post button.

* fix: protecting post route when no image is selected.

* fix: improved type saftey

* feat: added memory helper function

* feat: added memory cleanup.

* Feat/social media platforms (#195)

* chore: this part works now wooohooo

* chore: stash progress

* chore: stash progress

* chore: init message data models

* feat: different socials

* chore: blabsy ready for redesign

* Feat/social media platforms (#196)

* chore: this part works now wooohooo

* chore: stash progress

* chore: stash progress

* chore: init message data models

* feat: different socials

* chore: blabsy ready for redesign

* chore: add other socials

* Feat/blabsy add clone (#198)

* chore: clone twitter

* feat: custom auth with firebase using w3ds

* chore: add chat

* feat: chat works with sync

* feat: twittex

* feat: global schemas

* feat: blabsy adapter

* refactor: shift some text messages to work on blabsy (#199)

* chore: stash progress

* chore: stash adapters

* chore: stash working extractor

* feat: adapter working properly for translating to global with globalIDs

* feat: adapter toGlobal pristine

* chore: stash

* feat: adapter working

* chore: stash until global translation from pictique

* feat: bi-directional sync prestino

* feat: bidir adapters

* chore: login redir

* chore: swap out for sqlite3

* chore: swap out for sqlite3

* chore: server conf

* feat: messages one way

* feat: ready to deploy

* feat: ready to deploy

* chore: auth thing pictique

* chore: set adapter to node

* chore: fix auth token thingy

* chore: auth thing

* chore: fix auth token thingy

* chore: port for blabsy

* feat: provision stuff

* feat: provision

* feat: provision

* feat: provision

* chore: fix sync

* feat: temporary id thing

* chore: android

* chore: fix mapper sync

* chore: fallback

* feat: add error handling on stores

* feat: fix issue with posts

* chore: fix retry loop

* Fix/author details (#229)

* 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/change name (#228)

* 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 (#226)

* 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]>

* chore: temp fix sync

* chore: stash progress

* Fix/post context menu (#231)

* 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

* Fix/wallet text (#234)

* changed text as per the request and fixed styling on pages with useless scroll

* added settings button in main page which went missing somehow

* fix: consistent padding

* chore: change tags

* feat: change icon

* feat: webhook dynamic registry

* feat: make camera permission work properlyh

* chore: removed all locking mechanism thing from platforms

* feat: synchronization works perfectly

* feat: fixed everything up

* feat: changes

* chore: stats fix

* chore: fix pictique visual issues

* chore: fix cosmetic name issue

* feat: fix sync issue

* chore: fix logical issue here

* chore: add qrcode ename

* feat: add packages (#235)

* feat: add packages

* feat: add sample funcs + docs

* fixed the filled color on like icon for liked post (#239)

* feat: fake passport name

* feat: double confirmation

* chore: fix pictique login issue

* fix: make no user case redir to login

* fix: issues with wallet

---------

Co-authored-by: Soham Jaiswal <[email protected]>
Co-authored-by: SoSweetHam <[email protected]>
Co-authored-by: Gourav Saini <[email protected]>
Co-authored-by: Bekiboo <[email protected]>
Co-authored-by: Julien <[email protected]>
Co-authored-by: Ananya Rana <[email protected]>
Co-authored-by: Sergey <[email protected]>
Co-authored-by: Julien Connault <[email protected]>
Co-authored-by: Ananya Rana <[email protected]>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: Sahil Garg <[email protected]>
Co-authored-by: Sahil Garg <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
5 participants