@edusight/notification-widget 1.0.30 → 1.0.32

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -28,6 +28,7 @@
28
28
  relative group flex items-start gap-3 px-4 py-3 border-b border-border-light
29
29
  transition-all duration-200
30
30
  bg-widget-background hover:bg-widget-hover
31
+ min-w-[20rem]
31
32
  ${s?"bg-widget-primary-light":""}
32
33
  `,onMouseEnter:()=>l(!0),onMouseLeave:()=>l(!1),"data-testid":"notification-item","data-notification-id":t.id,children:[a&&e.jsx("div",{className:"flex-shrink-0 pt-0.5",children:e.jsx("input",{type:"checkbox",checked:s,onChange:y,className:"w-4 h-4 text-[var(--widget-primary)] border-[var(--widget-border)] rounded cursor-pointer focus:ring-2 focus:ring-[var(--widget-primary)] focus:ring-offset-0","aria-label":`Select notification: ${t.subject}`})}),e.jsx("div",{className:"flex-shrink-0",children:t.avatar?e.jsx("img",{src:t.avatar,alt:"",className:"w-10 h-10 rounded-full object-cover border border-border","aria-hidden":"true",loading:"lazy"}):e.jsx("div",{className:"w-10 h-10 rounded-full bg-gradient-to-br from-widget-primary to-widget-primary-hover flex items-center justify-center shadow-sm",children:e.jsx("span",{className:"text-white font-semibold text-base",children:t.subject.charAt(0).toUpperCase()})})}),e.jsxs("div",{className:"flex-1 min-w-0",children:[e.jsxs("div",{className:"flex items-start justify-between gap-2 mb-0.5",children:[e.jsx("h3",{className:`text-sm leading-5 text-[var(--widget-text)] ${t.isRead?"font-medium":"font-semibold"}`,children:t.subject}),!t.isRead&&e.jsx("div",{className:"flex-shrink-0 mt-1.5 ml-1",children:e.jsx("div",{className:"w-2 h-2 rounded-full bg-unread-indicator shadow-sm","aria-label":"Unread",role:"img"})})]}),e.jsx("p",{className:"text-sm text-[var(--widget-text-secondary)] line-clamp-2 leading-relaxed mb-2",children:t.body}),t.actions&&t.actions.length>0&&e.jsx("div",{className:"flex items-center gap-2 mb-2",children:t.actions.map((d,v)=>e.jsx("button",{onClick:p=>{p.stopPropagation(),o(d)},className:`
33
34
  px-3 py-1.5 rounded-md text-sm font-medium transition-colors
@@ -67,4 +68,4 @@
67
68
  focus:outline-none focus:ring-2 focus:ring-[var(--widget-primary)] focus:border-transparent\r
68
69
  transition-colors\r
69
70
  `,placeholder:"Search notifications...",value:g,onChange:b=>S(b.target.value),"aria-label":"Search notifications"})]})}),e.jsx(Ee,{notifications:l,activeTab:p,onTabChange:b=>i(b),size:y}),e.jsx("div",{className:"flex-1 overflow-y-auto widget-scrollbar",style:{backgroundColor:"var(--widget-background)",maxHeight:"calc(var(--widget-popover-max-height) - 200px)"},children:e.jsx($,{fallback:e.jsx(Te,{}),children:e.jsx(Se,{notifications:re,onNotificationAction:h})})}),B>0&&e.jsx("div",{className:"flex-shrink-0 px-4 py-2.5 border-t border-[var(--widget-border)]",style:{backgroundColor:"var(--widget-bg-hover)"},children:e.jsx("button",{type:"button",className:"w-full px-4 py-2 text-sm font-medium text-[var(--widget-primary)] hover:text-[var(--widget-primary-hover)] hover:bg-[var(--widget-primary-light)] rounded-lg transition-colors",onClick:()=>{const b=l.filter(j=>!j.isRead).map(j=>j.id);te(b)},"aria-label":`Mark all ${B} notifications as read`,children:"Mark all as read"})})]}):e.jsx("div",{className:"flex-1 overflow-y-auto widget-scrollbar",children:e.jsx($,{fallback:e.jsx(U,{}),children:f&&m?e.jsx(ee,{preferences:f,onPreferenceChange:m,isLoading:o,onBack:()=>n("notifications")}):e.jsx(U,{})})})]})]})};exports.BellComponent=he;exports.ComponentErrorBoundary=$;exports.InboxPopover=Be;exports.LoadingFallback=Ae;exports.MdError=ge;exports.MdRefresh=Ne;exports.NotificationItem=Z;exports.PreferencesView=ee;exports.SDKConnectionFallback=Ie;
70
- //# sourceMappingURL=components-B9Z6HsnI.cjs.map
71
+ //# sourceMappingURL=components-KafszaqK.cjs.map