File tree Expand file tree Collapse file tree 3 files changed +837
-940
lines changed
components/overlay/notifications Expand file tree Collapse file tree 3 files changed +837
-940
lines changed Original file line number Diff line number Diff line change @@ -67,9 +67,10 @@ function NotificationOverlayComponent(props: NotificationComponentProps) {
6767 return (
6868 < Show when = { visible ( ) } >
6969 < div
70- class = "flex flex-col overflow-hidden rounded-lg bg-component-bg"
70+ class = "flex flex-col overflow-hidden border border-border/05 rounded-lg bg-component-bg shadow-sm active:brightness-80 hover:brightness-90 "
7171 onMouseEnter = { ( ) => onEnter ( ) }
7272 onMouseLeave = { ( ) => onLeave ( ) }
73+ onMouseUp = { ( ) => hide ( ) }
7374 >
7475 < div class = "px-2" >
7576 < NotificationPopupComponent { ...props } />
@@ -112,7 +113,7 @@ function NotificationPopupComponent(props: NotificationComponentProps) {
112113 </ div >
113114
114115 < Show when = { props . fraction !== undefined && props . fraction !== null && ! fractionEnded ( props . fraction ) } >
115- < div class = "h-1.5 w-full overflow-hidden rounded-full bg-brand-disabled" >
116+ < div class = "h-1.5 w-full overflow-hidden rounded-full bg-brand-disabled/10 " >
116117 < div
117118 class = "h-full max-w-full min-w-0 rounded-full bg-brand transition-width"
118119 style = { {
Original file line number Diff line number Diff line change @@ -18,6 +18,17 @@ export function NotificationProvider(props: ParentProps) {
1818 let unlisten : UnlistenFn | undefined ;
1919
2020 onMount ( ( ) => {
21+ document . addEventListener ( 'keypress' , ( e ) => {
22+ if ( e . key === 'n' )
23+ setNotifications ( notifications => ( {
24+ ...notifications ,
25+ [ Math . random ( ) . toString ( ) ] : {
26+ title : 'Test' ,
27+ message : 'This is a test notification' ,
28+ } ,
29+ } ) ) ;
30+ } ) ;
31+
2132 events . ingressPayload . listen ( ( e ) => {
2233 setNotifications ( notifications => ( {
2334 ...notifications ,
You can’t perform that action at this time.
0 commit comments