adf

package
v0.18.1 Latest Latest
Warning

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

Go to latest
Published: Aug 26, 2026 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package adf inspects Atlassian Document Format (ADF) JSON without importing Jira types, so store, origin, and CLI can share it without crossing the store/jira firewall (docs/ARCHITECTURE.md).

PlainText flattens a document for FTS. IsSimple is the format-loss gate (doc / paragraph / text / hardBreak, no marks) ported from web/src/lib/adf.ts isSimpleAdf.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsSimple added in v0.17.0

func IsSimple(raw string) bool

IsSimple is the Go port of web/src/lib/adf.ts isSimpleAdf: empty/null is simple; otherwise only doc/paragraph/text/hardBreak with no marks. A plain-text replace of a non-simple document would drop formatting, so callers refuse unless the user passed force.

func PlainText

func PlainText(raw json.RawMessage) string

PlainText flattens an ADF document to plain text: it is what FTS indexes and what makes a repro-steps custom field searchable. A field that holds a bare string (the older wiki-markup shape) passes through unchanged.

Types

This section is empty.

Jump to

Keyboard shortcuts

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