Proto commits in yorkie-team/yorkie-js-sdk

These 82 commits are when the Protocol Buffers files have changed:

Commit:45c9d3d
Author:Yourim Cha
Committer:GitHub

Remove deprecated MinSyncedTicket and MaxCreatedAtMapByActor (#969) This commit removes legacy fields and logic related to Lamport timestamp synchronization: - Removed `MinSyncedTicket` and its associated logic - Removed `MaxCreatedAtMapByActor` and related code These were previously retained for backward compatibility during the migration to VersionVectors and are no longer needed.

The documentation is generated from this commit.

Commit:1a2bb22
Author:Youngteac Hong
Committer:Youngteac Hong

Add schema support

Commit:6a2351f
Author:Youngteac Hong
Committer:Youngteac Hong

Add schema support

Commit:14e0fc2
Author:Yourim Cha
Committer:Yourim Cha

Removed the deprecated MaxCreatedAtMapByActor field and its associated logic

The documentation is generated from this commit.

Commit:59661f3
Author:Yourim Cha

Remove deprecated MinSyncedTicket field and related functionality

Commit:a2c785c
Author:emplam27
Committer:GitHub

Add metadata to Client for MAU tracking (#942) Enhances client information tracking by adding metadata fields. These additions enable accurate Monthly Active User measurements and allow for storage of additional user-specific data in the analytics system.

Commit:2124689
Author:JOOHOJANG
Committer:GitHub

Introducing version vector to solve GC problem (#899) This change introduces Lamport Synced Version Vector to resolve defects in the existing garbage collection system that used syncedSeq. Key improvements include: - Added Version Vector implementation with Lamport timestamp support - Implemented database storage and update mechanisms for version vectors - Created min version vector computation for safe garbage collection - Added handling for detached client's version vectors to prevent memory leaks - Updated change ID generation to incorporate version vector information The Version Vector ensures all changes are properly synchronized across replicas before garbage collection occurs, improving system reliability and reducing memory waste from detached clients. --------- Co-authored-by: Youngteac Hong <susukang98@gmail.com>

Commit:cdeeef7
Author:Youngteac Hong
Committer:GitHub

Update target to ES2020 and replace Long with bigint (#912) This commit Streamlines data type handling by replacing Long with native. It also updates target to ECMAScript 2020. Despite the introduction of bigint, but Long still remains in Counter. We need to remove Long.

Commit:ee8e411
Author:JOOHOJANG

Remove min synced version vector from proto

Commit:cae3f9c
Author:JOOHOJANG

Remove snapshot version vector

Commit:e0988d0
Author:JOOHOJANG

Update Proto

Commit:6f0c315
Author:JOOHOJANG

Build proto to reflect versionvector and min synced version vector

Commit:2f1cd8b
Author:Gunwoo Baik
Committer:Youngteac Hong

Introduce monorepo to manage packages using `pnpm` (#880) Workspace: ``` examples/ - nextjs-scheduler - profile-stack - react-tldraw - react-todomvc - simultaneous-cursors - vanilla-codemirror6 - vanilla-quill - vuejs-kanban packages/ - create-yorkie-app - devtools - sdk <-- previous yorkie-js-sdk package ``` Command: ``` `sdk` - [x] pnpm sdk build - [x] pnpm sdk build:proto - [x] pnpm sdk build:docs - [x] pnpm sdk build:ghpages - [x] pnpm sdk dev - [x] pnpm sdk test - [x] pnpm sdk test:watch - [x] pnpm sdk test:bench - [x] pnpm sdk test:ci - [x] pnpm sdk test:yorkie.dev - [x] pnpm sdk lint - [x] pnpm sdk prepare `devtools` - [x] pnpm devtools dev - [x] pnpm devtools build - [x] pnpm devtools test `create-yorkie-app` - [x] pnpm create-yorkie-app start - [x] pnpm create-yorkie-app build - [x] pnpm create-yorkie-app build:copy-assets ``` --------- Co-authored-by: Youngteac Hong <susukang98@gmail.com>

Commit:ef412fa
Author:Youngteac Hong
Committer:Youngteac Hong

Introduce VersionVector

Commit:9e12b9e
Author:JiHwan Yim
Committer:GitHub

Add RHTNode removal to converter for consistency (#842) This commit addresses the missing `isRemoved` encoding in the RHT. Similar to other CRDTs like ElementRHT, including tombstone nodes like `isRemoved` during encoding is crucial. However, the RHT did not include tombstone nodes in its encoding, leading to inconsistencies in snapshots. --------- Co-authored-by: Youngteac Hong <susukang98@gmail.com>

Commit:e086ad7
Author:JiHwan Yim
Committer:GitHub

Handle concurrent editing and styling in Tree (#803) We will use maxCreatedAtMapByActor until the introduction of VersionVector.

Commit:2af8a0c
Author:JiHwan Yim
Committer:GitHub

Implement Protocol Changes for Tree.RemoveStyle (#755) This commit reflects protocol changes for the Tree.RemoveStyle. Proto file and converter were modified to reflect requirements related to the Tree.RemoveStyle patch.

Commit:2882578
Author:Sejong Kim
Committer:GitHub

Restore interface changes due to server DB sharding (#740) This commit restores passing sharding keys to the SDK in accordance with yorkie-team/yorkie#776.

Commit:363229b
Author:Sejong Kim
Committer:GitHub

Reflect interface changes of server DB sharding (#726) This commit reflects passing sharding keys to the SDK in advance before releasing the server with MongoDB sharding applied.

Commit:7368454
Author:Kevin Park
Committer:Youngteac Hong

Migrate RPC to ConnectRPC (#698) With this support, we can resolve several issues: - Removes dependency with Envoy proxy to communicate with grpc-web - Reduces SDK bundle size by half bundle size of #434 - Standardizes API interfaces to powerful fetch API For more information about this migration, follow: yorkie#703 --------- Co-authored-by: Youngteac Hong <susukang98@gmail.com>

Commit:6e8150c
Author:Kevin Park

Set connect-es js import style to commonjs & enable benchmark

Commit:2b52110
Author:Youngteac Hong
Committer:Youngteac Hong

Clean up yorkie.proto and remove grpc-web from package.json

Commit:4cc4c10
Author:Kevin Park
Committer:Kevin Park

Update client runWatchLoop to avoid async promise executor

Commit:1280b13
Author:Kevin Park
Committer:Kevin Park

Update protobuf and client

Commit:2b0b7f6
Author:Youngteac Hong
Committer:GitHub

Implement splitLevel of Tree.Edit (#704) When a user positions the cursor within a paragraph and hits the enter key, the paragraph is divided into two separate paragraphs: - Original: `<p>a|b</p>` - Result: `<p>a</p><p>b</p>` In this commit, `splitLevel` is introduced to support this scenario. ```ts doc.update((root) => { root.tree.edit([0,0], {type:'p',children:[{type:'text', value: 'ab'}]}); root.tree.edit([2,2], undefined, 1); // split the paragraph }); ``` This commit does not cover all test cases that may arise due to the split operation. This is because we need to verify the interface first. we need to add test cases in the simultaneous editing situation to verify the algorithm later. Tasks: - Refactor Tree.Edit logic to implement splitLevel of Tree.Edit - Remove skip from the unit tests related to splitLevel

Commit:5716e26
Author:Yourim Cha

Remove createdAtMapByActor in EditReverseOperation

Commit:5f9263f
Author:Yourim Cha
Committer:Yourim Cha

Replace TextNodeIDWithLength to RGATreeSplitPos

Commit:d2a88c2
Author:Yourim Cha

Merge branch 'feat/undo-redo-arch' of https://github.com/yorkie-team/yorkie-js-sdk into feat/text-edit-reverse

Commit:fd6ae03
Author:Yourim Cha
Committer:Yourim Cha

Merge branch 'main' of https://github.com/yorkie-team/yorkie-js-sdk into feat/undo-redo-arch

Commit:ce14cb0
Author:Yourim Cha
Committer:Yourim Cha

Add fields markOpsBefore and markOpsAfter to TextNode in protobuf

Commit:5bef0ad
Author:MoonGyu1
Committer:MoonGyu1

Add boundary type 'none' and apply lint

Commit:79c4f41
Author:MoonGyu1

Update protocol

Commit:4b1d850
Author:hyemmie

Update protocol buffer to add EditReverse

Commit:1594345
Author:gyuwonMoon
Committer:GitHub

Support concurrent formatting of Text (#642) Currently, we are unable to check for concurrent cases when applying the Text.setStyle operation. This pull request introduces a map called latestCreatedAtMapByActor to track the causality between the operations of the two clients and ensures that the results converge into one.

Commit:76370be
Author:hyemmie

Update protocol buffer

Commit:5523983
Author:JOOHOJANG
Committer:GitHub

Change TreeNode to have IDs instead of insPrev, insNext (#627) During the conversion, it's hard to find insPrev, insNext nodes from IDs because we can't use LLRB at that moment. Therefore, this commit changed it to keep IDs of insPrev and insNext and find the actual nodes when we need them.

Commit:990a6d6
Author:ehua
Committer:GitHub

Concurrent case handling for Yorkie.tree (#611) Introduced a new logical timestamp for identifying the position in local/remote editing, and ensures commutative editing in concurrent cases. This logical timestamp consists of {parentID, leftSiblingID}. This allows editing at the front of text nodes by using a reference to the parent, as well as getting rid of the local offset used to access an element node's children previously by using the leftSiblingID. --------- Co-authored-by: JOOHOJANG <jayjangjoo@gmail.com> Co-authored-by: Youngteac Hong <susukang98@gmail.com> Co-authored-by: sejongk <sepaper@naver.com> Co-authored-by: MoonGyu1 <s201801402@hufs-gsuite.kr>

Commit:7b390c6
Author:Yourim Cha
Committer:Yourim Cha

Cleanup proto - Remove unused client id(key) from API response - Change clientID type from bytes to string in the API

Commit:eb7ef2f
Author:Yourim Cha
Committer:Yourim Cha

Change 'Documents' from plural to singular in DocEvent

Commit:78f36dd
Author:Yourim Cha
Committer:GitHub

Move Presence from Client to Document (#574) To ensure atomic delivery of data for `Document` and `Presence` to users, we are removing `Presence` from the `Client` and moving it to the `Document`. In the future, we plan to further modify it by changing `Document` to `Channel` or `Room` and rename `Root` as `Document`. UpdatePresence `UpdatePresence API` has been removed. Now, document and presence changes are transmitted using the `PushPull API`. Consequently, the presence is no longer transmitted as a component of the `Client`, but rather included within the change. ChangePack now contains `presence`. WatchDocument In the `WatchDocument API`, both the request and response only include the client ID, excluding the presence. --------- Co-authored-by: Youngteac Hong <susukang98@gmail.com>

Commit:a300e36
Author:Yourim Cha
Committer:Yourim Cha

Update presence batch protobuf

Commit:3ce9b66
Author:Yourim Cha
Committer:Yourim Cha

Merge branch 'main' of https://github.com/yorkie-team/yorkie-js-sdk into presence-batch

Commit:36cf042
Author:JOOHOJANG
Committer:GitHub

Bump up protobuf (#570)

Commit:6132b6a
Author:Yourim Cha

Rename PresenceInfo to Presence

Commit:69a2b88
Author:Yourim Cha
Committer:Yourim Cha

Remove clock infomation from presence

Commit:de51392
Author:Yourim Cha

Merge branch 'main' of https://github.com/yorkie-team/yorkie-js-sdk into presence-batch

Commit:5b0e809
Author:Youngteac Hong
Committer:GitHub

Implement Tree.Style and Tree.StyleByPath (#542) * Implement pathToPosRange (#545) * Implement Tree.Style and Tree.StyleByPath * Move Parse/Stringify object method to object util and apply those methods when tree editing/styling --------- Co-authored-by: JOOHOJANG <jayjangjoo@gmail.com>

Commit:9852473
Author:Yourim Cha

Change documents event to singular form

Commit:0b1c274
Author:Yourim Cha

Build the presence map from the snapshot

Commit:5fe4b8d
Author:JOOHOJANG

update proto

Commit:814b4c7
Author:Yourim Cha

Handle peers-changed events via `peers` topic in `doc.subscribe`

Commit:02ad604
Author:Yourim Cha
Committer:Yourim Cha

Merge branch 'main' of https://github.com/yorkie-team/yorkie-js-sdk into presence-batch

Commit:b64d829
Author:Youngteac Hong
Committer:Youngteac Hong

Implement yorkie.Tree for text editors using tree model (#507) In order to support collaborative editing in text editors like ProseMirror that use Tree-based model, yorkie.Tree is provided. yorkie.Tree is implemented based on RGATreeSplit. The Tree allows specifying the position of content using index or path --------- Co-authored-by: 장주호 <jooho.jang@navercorp.com> Co-authored-by: easylogic <cyberuls@gmail.com>

Commit:5492370
Author:Youngteac Hong

Clean up codes and add proto message for yorkie.Tree

Commit:4b116e4
Author:Yourim Cha
Committer:Yourim Cha

Send updated PresenceInfo within the Change instead of ChangePack

Commit:600186f
Author:Yourim Cha
Committer:Yourim Cha

Move presence from client to document and include presence updates in ChangePack

Commit:913d608
Author:Yourim Cha
Committer:GitHub

Add Client sync mode (#495) Co-authored-by: Youngteac Hong <susukang98@gmail.com>

Commit:1e2c32d
Author:Yourim Cha
Committer:GitHub

Add RemoveDocument API (#480) Co-authored-by: Youngteac Hong <susukang98@gmail.com>

Commit:738d1dd
Author:Yourim Cha
Committer:GitHub

Remove duplicated key from TextNodeAttr (#429) * Remove duplicated key from TextNodeAttr * Rename getAttr to getAttrs

Commit:afcdb1a
Author:Yourim Cha
Committer:GitHub

Merge Text and RichText (#425)

Commit:e18ed0d
Author:Youngteac Hong
Committer:GitHub

Bump up proto files to the latest (#367)

Commit:a4e5c57
Author:Youngteac Hong
Committer:GitHub

Rename Client Metadata to Presence (#293)

Commit:b7143f2
Author:Youngteac Hong
Committer:GitHub

Remove Collection from Document (#292)

Commit:12c89ea
Author:Hackerwins
Committer:Hackerwins

Bump up yorkie.proto

Commit:ecc77f1
Author:Youngteac Hong
Committer:GitHub

Add client.UpdateMetadata (#236)

Commit:80d0472
Author:Hackerwins

Update yorkie.proto changes https://github.com/yorkie-team/yorkie/pull/189

Commit:8206827
Author:Youngteac Hong
Committer:GitHub

Add AuthInterceptor (#199)

Commit:8b4795b
Author:Dongcheol Choe
Committer:GitHub

Improve the container type naming of JSONElement (#139) Object and Array are keywords in TypeScript. So we use different names to avoid collisions after transpiling. Co-authored-by: Youngteac Hong <susukang98@gmail.com>

Commit:0c97825
Author:Jonghyeop Na
Committer:GitHub

Replace the type of client_id to a byte array to reduce payload (#133) Replace the type of client_id to correspond with the Agent. For more details: https://github.com/yorkie-team/yorkie/pull/145

Commit:94584b1
Author:Youngteac Hong
Committer:GitHub

Add customizable metadata for peer awareness (#123) Users seems to be more comfortable using Object literal than Map, so change it. And change the peer change event name more concisely. Co-authored-by: M. Habib Rosyad <habib.ryd@gmail.com>

Commit:9c008a3
Author:hyunwoo.jo
Committer:Youngteac Hong

#32 Rename updatedAt to movedAt

Commit:80279c0
Author:Dongcheol Choe
Committer:GitHub

Add a custom CRDT data type, Counter Previously, We introduced the Increase operation to Primitive datatype. However, in JavaScript, if we extended the increase method on the number type, it was difficult for the user to get the value like a native numeric type. So, We add a new custom CRDT data type, Counter. Co-authored-by: Youngteac Hong <susukang98@gmail.com>

Commit:4acaae9
Author:hackerwins
Committer:Youngteac Hong

Add Watched/Unwatched events

Commit:93c9385
Author:hackerwins
Committer:Youngteac Hong

Add RichText

Commit:59844e6
Author:hackerwins
Committer:Youngteac Hong

Add move operation in an array

Commit:6030439
Author:hackerwins

Replace deletedAt with removedAt

Commit:54cbc95
Author:hackerwins
Committer:Youngteac Hong

Add logic to pull snapshot if changes more than threshold

Commit:d6c9c36
Author:Hackerwins

Move the remove flag to the Element to prepare fore garbage collection

Commit:fc72638
Author:Hackerwins
Committer:hackerwins

Update selection on Text

Commit:9d53c5a
Author:hackerwins
Committer:hackerwins

Add watch API relevant ticket: https://github.com/hackerwins/yorkie/issues/5.

Commit:1885dd0
Author:Hackerwins
Committer:Hackerwins

Add pb converter to convert protobuf to model or vice versa

Commit:1d281a4
Author:Hackerwins
Committer:Hackerwins

Introduce Typescript, gRPC, Envoy, Karma and Webpack - Implement ActivateClient/DeactivateClient