identity

package
v0.172.5 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2024 License: MPL-2.0, MPL-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TwitterID      = "__twitter"
	PersonalSiteID = "__personal_site"
	GithubID       = "__github"
	YoutubeID      = "__youtube"
	DiscordID      = "__discord"
	TelegramID     = "__telegram"
)

static links which need to be decorated by the UI clients

Variables

This section is empty.

Functions

func Slices

func Slices(compressedPubkey []byte) (res [4][]byte, err error)

compressedPubKey = |1.5 bytes chars cutoff|20 bytes emoji hash|10 bytes color hash|1.5 bytes chars cutoff|

func ToBigBase

func ToBigBase(value *big.Int, base uint64) (res [](uint64))

func ToBigInt

func ToBigInt(t *testing.T, str string) *big.Int

func ToColorID added in v0.98.3

func ToColorID(pubkey string) (int64, error)

func ToCompressedKey

func ToCompressedKey(pubkey string) ([]byte, error)

Types

type SocialLink struct {
	Text string `json:"text"`
	URL  string `json:"url"`
}

func (*SocialLink) Equal added in v0.156.1

func (s *SocialLink) Equal(link *SocialLink) bool

func (*SocialLink) ToProtobuf added in v0.156.1

func (s *SocialLink) ToProtobuf() *protobuf.SocialLink
type SocialLinks []*SocialLink
func NewSocialLinks(links []*protobuf.SocialLink) SocialLinks

func (*SocialLinks) Contains added in v0.156.1

func (s *SocialLinks) Contains(link *SocialLink) bool

func (*SocialLinks) Equal added in v0.156.1

func (s *SocialLinks) Equal(links SocialLinks) bool

Equal means the same links at the same order

func (*SocialLinks) Serialize added in v0.105.1

func (s *SocialLinks) Serialize() ([]byte, error)

func (*SocialLinks) ToProtobuf added in v0.105.1

func (s *SocialLinks) ToProtobuf() []*protobuf.SocialLink

func (*SocialLinks) ToSyncProtobuf added in v0.156.1

func (s *SocialLinks) ToSyncProtobuf(clock uint64) *protobuf.SyncSocialLinks

type SocialLinksInfo added in v0.156.1

type SocialLinksInfo struct {
	Links   []*SocialLink `json:"links"`
	Removed bool          `json:"removed"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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