mirror of
https://github.com/aljazceru/njump.git
synced 2025-12-17 06:14:22 +01:00
48 lines
826 B
Go
48 lines
826 B
Go
package main
|
|
|
|
import (
|
|
"time"
|
|
|
|
"github.com/nbd-wtf/go-nostr/nip52"
|
|
"github.com/nbd-wtf/go-nostr/nip53"
|
|
"github.com/nbd-wtf/go-nostr/nip94"
|
|
"github.com/nbd-wtf/go-nostr/sdk"
|
|
)
|
|
|
|
type Kind1063Metadata struct {
|
|
nip94.FileMetadata
|
|
}
|
|
|
|
type Kind30311Metadata struct {
|
|
nip53.LiveEvent
|
|
Host *sdk.ProfileMetadata
|
|
}
|
|
|
|
func (le Kind30311Metadata) title() string {
|
|
if le.Host != nil {
|
|
return le.Title + " by " + le.Host.Name
|
|
}
|
|
return le.Title
|
|
}
|
|
|
|
type Kind31922Or31923Metadata struct {
|
|
nip52.CalendarEvent
|
|
}
|
|
|
|
type Kind30818Metadata struct {
|
|
Handle string
|
|
Title string
|
|
Summary string
|
|
PublishedAt time.Time
|
|
}
|
|
|
|
type Kind9802Metadata struct {
|
|
Author sdk.ProfileMetadata
|
|
SourceEvent string
|
|
SourceURL string
|
|
SourceName string
|
|
Context string
|
|
MarkedContext string
|
|
Comment string
|
|
}
|