Comments (8)
Conversation with @hackerwins
Embed data (video, image ..) has a size of 1 like space bar in content and decided to use attributes
field.
After this issue is solved, PR can be registered.
from yorkie-js-sdk.
@ppeeou Sure. If you have any questions while proceeding, please let me know.
from yorkie-js-sdk.
@ppeeou Can I try this issue if you are okay?
from yorkie-js-sdk.
Could I try this issue??!
from yorkie-js-sdk.
@hackerwins In the case of Quill, the value contains the type according to text, images, and video.
This value is already loaded in memory, so it can easily distinguish the type.
However, in the case of yorkie, when serializing value and storing it on the server and passing it to the client, the client must handle whether the value is images, video, or text through JSON.parse.
- if we don't define a type.
try{
return JSON.parse(content) // object
}catch{
return content; // string
}
So, I prefer to follow Quill as it is, but I think we need to define the value inevitably. What do you think??
from yorkie-js-sdk.
@ppeeou Thanks for the good comments. It's been a while since I saw this issue, so I don't remember it well.
As you suggested, I think we should have an explicit type in RichText.
from yorkie-js-sdk.
I have a question regarding this issue..!
I thought the issue only had to be extended by type
In Quill, when data such as image and video are inserted, the size is set to 1 (retain difference is 1), so it can be used like deleting text when using something like delete.
I think we should also receive the size from RichText, not the length of the string from and to (the size depends on the contentType, and the actual content can be base64, URL..)
I have no idea how to change it in the current structure 😭
from yorkie-js-sdk.
oh... yes 😵💫
thank you @mojosoeun
from yorkie-js-sdk.
Related Issues (20)
- Fix high and critical vulnerabilities
- Support Yarn install HOT 4
- Introduce Turborepo to manage packages HOT 3
- Dropping node.js 16 support
- Suggestion: migrate karma to a another test framework
- `debugger` is not positioned properly
- Suggestion: Publish npm package with provenance
- Next.js example is broken on GitHub Pages
- Yorkie-js-sdk api reference document link is broken HOT 1
- Add README and thumbnail on example 'simultaneous-cursors'
- Provide DevTools through Chrome extension
- Unify Error Throwing Methods
- "Not Applicable Datatype" Occurs After Updating to JS SDK v0.4.9 HOT 1
- Parsing error with single quotes in tldraw text HOT 1
- Typo error on Examples!
- Example of simultaneous-cursors not working at official website HOT 1
- Duplicate deregister in Nested Object GC
- Transition to Monorepo using Turborepo, PNPM, Changesets, and Vite
- Missing presence value in `presence-changed` event for initial presence
- Incorrect `fromPath` and `toPath` values in document event for `tree.edit` operation
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from yorkie-js-sdk.