♻️ Add pointer to application sign widget.

This commit is contained in:
Александр Колосов 2024-02-03 02:08:10 +05:00
parent 5384c9bae2
commit 0986060000
3 changed files with 7 additions and 5 deletions

View File

@ -2,6 +2,8 @@
## 🆕 Added
- Created widget _ApplicationSign_
## 💥 Breaking Changed
## 🛠 Changed

View File

View File

@ -7,10 +7,10 @@ type ApplicationSignWidget struct {
year int16
}
func ApplicationSign(name string, year int16) Widget {
return ApplicationSignWidget{name, year}
}
func (widget ApplicationSignWidget) Render() string {
func (widget *ApplicationSignWidget) Render() string {
return `󰗦 ` + widget.name + ", " + strconv.Itoa(int(widget.year))
}
func ApplicationSign(name string, year int16) Widget {
return &ApplicationSignWidget{name, year}
}