pub struct Mark {Show 18 fields
pub mark: String,
pub id: String,
pub anchor: Anchor,
pub from: Option<u32>,
pub to: Option<u32>,
pub detached: bool,
pub words: String,
pub quote: String,
pub link: Option<String>,
pub label: Option<String>,
pub by: String,
pub principal: String,
pub at: i64,
pub changed_at: Option<i64>,
pub changed_by: Option<String>,
pub component: Option<String>,
pub version: Option<String>,
pub props: Option<Map<String, Value>>,
}Expand description
NOTES-5: a mark — an agent’s underline on a range of a note, which follows its words as a question’s range does: a link, a line of state, or both. It sits on the text, never in it: no mark writes the note.
Fields§
§mark: StringIts id, 8 characters as a note’s.
id: StringThe note it is on.
anchor: AnchorThe range as the note’s CRDT holds it: two Yjs relative positions (base64), which follow the text.
from: Option<u32>The range now, in characters of the text — absent when it is detached.
to: Option<u32>§detached: boolEvery character it was on was deleted: the mark is kept, listed last, drawn nowhere.
words: StringThe words the range holds now (empty when it is detached).
quote: StringThe words it held when it was made.
link: Option<String>What a click on its underline opens: a ticket (KILN-12), an address of the app (#/…) or an https address.
label: Option<String>Its line of state, drawn under the passage that holds it.
by: StringWho left it: their name, and their principal.
principal: String§at: i64When, unix milliseconds.
changed_at: Option<i64>When it was last changed (unix milliseconds) and by whom — absent until it is.
changed_by: Option<String>§component: Option<String>The component placed under the passage that holds the range (the page draws it there, never in the text) — absent when it places none.
version: Option<String>The kept version that holds it, its whole hash.
props: Option<Map<String, Value>>Its props, a JSON object (mark_props patches them) — with a component alone.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Mark
impl<'de> Deserialize<'de> for Mark
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for Mark
Source§impl JsonSchema for Mark
impl JsonSchema for Mark
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read moreimpl StructuralPartialEq for Mark
Auto Trait Implementations§
impl Forget for Mark
impl Freeze for Mark
impl Move for Mark
impl RefUnwindSafe for Mark
impl Send for Mark
impl Sync for Mark
impl Unpin for Mark
impl UnsafeUnpin for Mark
impl UnwindSafe for Mark
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.