PdfElement.text constructor
const
PdfElement.text({
- String? visibleIfKey,
- String? text,
- String? dataKey,
- @Default.new(PdfTextAlignment.left) PdfTextAlignment alignment,
A text element that can display static text or dynamic data from a key.
Implementation
const factory PdfElement.text({
/// Optional key to control visibility based on the provided data.
String? visibleIfKey,
/// Static text to display.
String? text,
/// Key to fetch dynamic text from the provided data map.
String? dataKey,
/// How the text should be aligned.
@Default(PdfTextAlignment.left) PdfTextAlignment alignment,
}) = PdfTextElement;