Skip to content

calternal_dav::areas

Stable, path-safe identities for the Log entry area calendar projection.

An area tag is user text. Its digest is used only as a DAV path segment; the original tag stays in the Log line and the tag Index. This avoids decoding slashes, percent escapes, or Unicode normalization in URL paths. Removing one of several areas changes only that tag; the shared Notes DELETE handles the final copy and retains children (#471; DESIGN §46 A7).

Source: crates/calternal-dav/src/areas.rs

pub fn add_area(entry: &mut LogEntry, tag: &str)

A DAV collection controls only its own area tag. Other categories and sibling areas are source data shared by all projections.

Source: crates/calternal-dav/src/areas.rs:70

pub fn area_tag(tag: &str) -> Option<&str>

No doc comment.

Source: crates/calternal-dav/src/areas.rs:15

pub fn belongs(entry: &LogEntry, tag: Option<&str>) -> bool

No doc comment.

Source: crates/calternal-dav/src/areas.rs:61

pub fn collection_id(tag: &str) -> Option<String>

No doc comment.

Source: crates/calternal-dav/src/areas.rs:20

pub fn copy_id(block_id: &str, collection: &str) -> String

No doc comment.

Source: crates/calternal-dav/src/areas.rs:25

pub fn default_color(tag: &str) -> String

packages/ui/src/tags.ts uses FNV-1a over UTF-16 code units and oklch(0.50 0.12 hue) for generated tag colours. DAV needs opaque sRGB, so convert that same colour to a six-digit hex value for Apple Calendar.

Source: crates/calternal-dav/src/areas.rs:114

pub fn display_name(tag: Option<&str>) -> String

No doc comment.

Source: crates/calternal-dav/src/areas.rs:96

pub fn new_block_id(client_id: &str, collection: &str) -> String

No doc comment.

Source: crates/calternal-dav/src/areas.rs:45

pub fn project(event: &JournalEvent, collection: &str) -> Option<JournalEvent>

The copy has its own resource identity while its visible fields remain a projection of the same source line. Both copies change ETag when that line changes, even when the write arrived through the other calendar.

Source: crates/calternal-dav/src/areas.rs:55

pub fn remove_area(entry: &mut LogEntry, tag: &str) -> bool

Remove only this area tag and report whether another area copy remains. Child lines and non-area Tags stay intact while another copy exists. Notes re-parents the children when the last copy is deleted (#471; §46 A2/A7).

Source: crates/calternal-dav/src/areas.rs:79

pub fn same_log_event(
left_date: &str,
left: &LogEntry,
right_date: &str,
right: &LogEntry,
) -> bool

No doc comment.

Source: crates/calternal-dav/src/areas.rs:84

pub const UNTAGGED: &str

No doc comment.

Source: crates/calternal-dav/src/areas.rs:13