display

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Jun 27, 2025 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ColorReset  = "\033[0m"
	ColorRed    = "\033[31m"
	ColorGreen  = "\033[32m"
	ColorYellow = "\033[33m"
	ColorBlue   = "\033[34m"
	ColorPurple = "\033[35m"
	ColorCyan   = "\033[36m"
	ColorWhite  = "\033[37m"
	ColorBold   = "\033[1m"
)

ANSI color codes for terminal output

Variables

This section is empty.

Functions

func DisplayAlbum

func DisplayAlbum(album spotify.Album, client *spotify.Client, imageSize int)

DisplayAlbum renders album information with cover art

func DisplayArtist

func DisplayArtist(artist spotify.Artist, client *spotify.Client, imageSize int)

DisplayArtist renders artist information with profile image

func DisplayTrack

func DisplayTrack(track spotify.Track, client *spotify.Client, imageSize int)

DisplayTrack renders track information with album art

Types

type ImageRenderer

type ImageRenderer struct {
	// contains filtered or unexported fields
}

ImageRenderer handles terminal image rendering using Unicode blocks

func NewImageRenderer

func NewImageRenderer(size int) *ImageRenderer

NewImageRenderer creates an image renderer with specified size

func (*ImageRenderer) RenderImageLines

func (r *ImageRenderer) RenderImageLines(imageURL string) []string

RenderImageLines converts image URL to terminal-displayable lines

Jump to

Keyboard shortcuts

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