render

package
v0.10.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 21, 2026 License: AGPL-3.0 Imports: 7 Imported by: 0

Documentation

Overview

Package render turns zotero client values into terminal output for humans: aligned tables and detail views. Machine-readable output is internal/output's job. render holds no I/O or network logic — every function writes to an io.Writer so output is easy to test and redirect.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Annotations added in v0.9.0

func Annotations(w io.Writer, attachmentKey string, annotations []zotero.Annotation)

Annotations writes compact annotation metadata without text or comments.

func Attachment added in v0.9.0

func Attachment(w io.Writer, attachment zotero.Attachment)

Attachment writes one attachment's metadata.

func CSV added in v0.2.0

func CSV(w io.Writer, items []zotero.Envelope) error

CSV writes items as a spreadsheet-friendly table with a header row.

func CollectionPaths added in v0.9.0

func CollectionPaths(w io.Writer, paths []zotero.CollectionPath)

CollectionPaths writes requested collection paths in request order.

func Collections

func Collections(w io.Writer, cols []zotero.Envelope, flat bool)

Collections writes collections as an indented tree (by parent), or as a flat key/name table when flat is true.

func Item

func Item(w io.Writer, item zotero.Envelope, children []zotero.Envelope)

Item writes a detailed view of a single item and its children.

func Items

func Items(w io.Writer, items []zotero.Envelope)

Items writes a one-line-per-item table: key, type, title, creator, date.

func Markdown added in v0.2.0

func Markdown(w io.Writer, items []zotero.Envelope) error

Markdown writes items as a bulleted reference list.

func Note added in v0.9.0

func Note(w io.Writer, note zotero.Note)

Note writes one note's metadata followed by Zotero's rich-text HTML.

func Relations added in v0.9.0

func Relations(w io.Writer, itemKey string, relations []zotero.Relation)

Relations writes one item's outgoing relation edges.

func Stats

func Stats(w io.Writer, library string, s zotero.Stats)

Stats writes library-wide counts.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL