Documentation
¶
Index ¶
- func IsSupported() bool
- type Notification
- type NotificationManager
- func (nm *NotificationManager) Send(notification Notification) error
- func (nm *NotificationManager) SendBreakReminder(duration time.Duration) error
- func (nm *NotificationManager) SendEndOfDayReminder(totalTime time.Duration, targetHours float64) error
- func (nm *NotificationManager) SendIdleDetected(idleDuration time.Duration) error
- func (nm *NotificationManager) SendSessionComplete(duration time.Duration, project string) error
- func (nm *NotificationManager) TestNotification() error
- type NotificationType
- type Priority
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsSupported ¶
func IsSupported() bool
IsSupported returns true if notifications are supported on the current platform
Types ¶
type Notification ¶
type Notification struct {
Title string
Message string
Type NotificationType
Priority Priority
Sound bool
Icon string
}
Notification represents a system notification
type NotificationManager ¶
type NotificationManager struct {
// contains filtered or unexported fields
}
NotificationManager handles cross-platform notifications
func NewNotificationManager ¶
func NewNotificationManager(enabled bool) *NotificationManager
NewNotificationManager creates a new notification manager
func (*NotificationManager) Send ¶
func (nm *NotificationManager) Send(notification Notification) error
Send sends a notification to the OS
func (*NotificationManager) SendBreakReminder ¶
func (nm *NotificationManager) SendBreakReminder(duration time.Duration) error
SendBreakReminder sends a break reminder notification
func (*NotificationManager) SendEndOfDayReminder ¶
func (nm *NotificationManager) SendEndOfDayReminder(totalTime time.Duration, targetHours float64) error
SendEndOfDayReminder sends an end-of-day reminder notification
func (*NotificationManager) SendIdleDetected ¶
func (nm *NotificationManager) SendIdleDetected(idleDuration time.Duration) error
SendIdleDetected sends an idle detection notification
func (*NotificationManager) SendSessionComplete ¶
func (nm *NotificationManager) SendSessionComplete(duration time.Duration, project string) error
SendSessionComplete sends a session completion notification
func (*NotificationManager) TestNotification ¶
func (nm *NotificationManager) TestNotification() error
TestNotification sends a test notification to verify the system is working
type NotificationType ¶
type NotificationType int
NotificationType represents different types of notifications
const ( BreakReminder NotificationType = iota EndOfDayReminder SessionComplete IdleDetected Custom )
Click to show internal directories.
Click to hide internal directories.