chatrender

package
v0.0.0-...-f10651d Latest Latest
Warning

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

Go to latest
Published: Oct 7, 2024 License: BSD-3-Clause Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvName

func ConvName(g *libkb.GlobalContext, conv chat1.ConversationLocal, myUsername string) string

Make a name that looks like a tlfname but is sorted by activity and missing myUsername.

func FmtTime

func FmtTime(t time.Time, opts RenderOptions) string

func ShortDurationFromNow

func ShortDurationFromNow(t time.Time) string

Types

type ConversationInfoListView

type ConversationInfoListView []chat1.ConversationLocal

func (ConversationInfoListView) RenderToWriter

func (v ConversationInfoListView) RenderToWriter(g *libkb.GlobalContext, writer io.Writer, width int) error

func (ConversationInfoListView) Show

type ConversationListView

type ConversationListView []chat1.ConversationLocal

func (ConversationListView) RenderToWriter

func (v ConversationListView) RenderToWriter(g *libkb.GlobalContext, writer io.Writer, width int, myUsername string, showDeviceName bool, opts RenderOptions) (err error)

func (ConversationListView) Show

func (v ConversationListView) Show(g *libkb.GlobalContext, myUsername string, showDeviceName bool) (err error)

type ConversationView

type ConversationView struct {
	Conversation chat1.ConversationLocal
	Messages     []chat1.MessageUnboxed
	Opts         RenderOptions
}

func (ConversationView) RenderToWriter

func (v ConversationView) RenderToWriter(g *libkb.GlobalContext, writer io.Writer, width int, showDeviceName bool) error

func (ConversationView) Show

func (v ConversationView) Show(g *libkb.GlobalContext, showDeviceName bool) error

type RenderOptions

type RenderOptions struct {
	UseDateTime     bool
	SkipHeadline    bool
	GetWalletClient func(g *libkb.GlobalContext) (cli stellar1.LocalClient, err error)
}

Jump to

Keyboard shortcuts

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