PageSourceSearch

https://norder.ai/_next/static/chunks/993.93c0d93128a17249.js

js norder.ai collected 2026-10-05 13:37:48 UTC 6,516 bytes, 1 lines download raw bytes

1try{let e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="e2689bda-87f5-4efb-ae9e-69d60ac664d1",e._sentryDebugIdIdentifier="sentry-dbid-e2689bda-87f5-4efb-ae9e-69d60ac664d1")}catch(e){}"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[993],{10993:(e,t,n)=>{n.r(t),n.d(t,{clearAllNotifications:()=>_,createInAppNotification:()=>l,deleteNotification:()=>m,getNotificationSettings:()=>o,getStoredNotifications:()=>r,getUnreadNotificationCount:()=>d,handleMentionNotification:()=>b,handleMessageNotification:()=>p,markAllNotificationsAsRead:()=>f,markNotificationAsRead:()=>u,requestNotificationPermission:()=>g,shouldSendNotification:()=>s,showDesktopNotification:()=>h,updateNotificationSettings:()=>c});var i=n(96648),a=n(27483);async function o(e,t){if(!t)return{notificationPreference:"all",isMuted:!1};{let{data:n,error:a}=await i.supabase.from("team_chat_channel_members").select("notification_preference, is_muted").eq("channel_id",t).eq("member_id",e).single();return a||!n?{channelId:t,notificationPreference:"all",isMuted:!1}:{channelId:t,notificationPreference:n.notification_preference,isMuted:n.is_muted||!1}}}async function c(e,t,n){let{error:a}=await i.supabase.from("team_chat_channel_members").update({notification_preference:n.notificationPreference,is_muted:n.isMuted}).eq("channel_id",t).eq("member_id",e);if(a)throw a}async function s(e,t,n){var a,c,s,l,r,d,u,f,m,_,g,h,p,b,N,y,w,I,S,v,D;let T=await o(e,t);if(T.isMuted)return!1;if(null==(a=T.doNotDisturb)?void 0:a.enabled){let e=new Date,t="".concat(e.getHours().toString().padStart(2,"0"),":").concat(e.getMinutes().toString().padStart(2,"0"));if(T.doNotDisturb.startTime&&T.doNotDisturb.endTime){if(T.doNotDisturb.startTime<=T.doNotDisturb.endTime){if(t>=T.doNotDisturb.startTime||t<=T.doNotDisturb.endTime)return!1}else if(t>=T.doNotDisturb.startTime&&t<=T.doNotDisturb.endTime)return!1}}let k=!0;switch(T.notificationPreference){case"all":default:k=!0;break;case"mentions":k="mention"===n;break;case"none":k=!1}if(!k)return!1;try{let{data:t}=await i.supabase.from("workspace_members").select("notification_preferences").eq("id",e).single(),a=null!=(f=null==t?void 0:t.notification_preferences)?f:{push_enabled:!0,team_chat:{mention_all:!0,mention_direct:!0,mention_here:!0,mention_channel:!0,all_messages:!0,threads_participated:!0}};if(!(null==(m=a.push_enabled)||m))return!1;let o={mention_all:null==(g=null!=(_=null==(c=a.team_chat)?void 0:c.mention_all)?_:a.mention_all)||g,mention_direct:null==(p=null!=(h=null==(s=a.team_chat)?void 0:s.mention_direct)?h:a.mention_direct)||p,mention_here:null==(N=null!=(b=null==(l=a.team_chat)?void 0:l.mention_here)?b:a.mention_here)||N,mention_channel:null==(w=null!=(y=null==(r=a.team_chat)?void 0:r.mention_channel)?y:a.mention_channel)||w,all_messages:null==(S=null!=(I=null==(d=a.team_chat)?void 0:d.all_messages)?I:a.all_messages)||S,threads_participated:null==(D=null!=(v=null==(u=a.team_chat)?void 0:u.threads_participated)?v:a.threads_participated)||D};if("mention"===n){if(!(o.mention_direct||o.mention_all||o.mention_here||o.mention_channel))return!1}else if("message"===n){if(!o.all_messages)return!1}else if("thread_reply"===n&&!o.threads_participated)return!1}catch(e){console.warn("[TeamChat] Failed to load global notification preferences:",e)}return!0}async function l(e,t){let n="notifications_".concat(e),a=r(e),o={...t,id:crypto.randomUUID(),read:!1,createdAt:new Date().toISOString()},c=[o,...a].slice(0,100);localStorage.setItem(n,JSON.stringify(c));let s=i.supabase.channel("notifications:user:".concat(e));await s.subscribe(),await s.send({type:"broadcast",event:"new_notification",payload:o}),await s.unsubscribe()}function r(e){let t=localStorage.getItem("notifications_".concat(e));return t?JSON.parse(t):[]}function d(e){return r(e).filter(e=>!e.read).length}function u(e,t){let n=r(e).map(e=>e.id===t?{...e,read:!0}:e),i="notifications_".concat(e);localStorage.setItem(i,JSON.stringify(n))}function f(e){let t=r(e).map(e=>({...e,read:!0})),n="notifications_".concat(e);localStorage.setItem(n,JSON.stringify(t))}function m(e,t){let n=r(e).filter(e=>e.id!==t),i="notifications_".concat(e);localStorage.setItem(i,JSON.stringify(n))}function _(e){localStorage.removeItem("notifications_".concat(e))}async function g(){return"Notification"in window?"granted"===Notification.permission||"denied"!==Notification.permission&&"granted"===await Notification.requestPermission():(console.warn("This browser does not support notifications"),!1)}function h(e,t){var n,i,o,c;if(null==(n=window.electron)?void 0:n.isElectron){let n,a=null!=(c=null==t?void 0:t.body)?c:"",s=null==t?void 0:t.data;(null==s?void 0:s.channelId)&&(n="/team-chat?channel=".concat(s.channelId),s.messageId&&(n+="&message=".concat(s.messageId))),null==(i=(o=window.electron).notify)||i.call(o,{title:e,body:a,data:{url:n}});return}if(!("Notification"in window)||"granted"!==Notification.permission)return;let s=new Notification(e,{icon:"/icon-192x192.png",badge:"/badge-72x72.png",...t});s.onclick=e=>{if(e.preventDefault(),window.focus(),s.close(),null==t?void 0:t.data){let e=t.data;if(e.channelId){let t=e.messageId?"&message=".concat(e.messageId):"";(0,a.navigateToUrl)("/team-chat?channel=".concat(e.channelId).concat(t))}}},setTimeout(()=>s.close(),5e3)}async function p(e,t,n,i){await s(i,e.channelId,"message")&&(await l(i,{type:"message",title:"".concat(t.name),body:"".concat(n.displayName,": ").concat(e.content.substring(0,100)),data:{channelId:t.id,messageId:e.id,senderId:e.senderMemberId,senderName:n.displayName}}),document.hidden&&h("".concat(n.displayName," - ").concat(t.name),{body:e.content.substring(0,100),tag:"message-".concat(e.id),data:{channelId:t.id,messageId:e.id}}))}async function b(e,t,n,i,a){if(!await s(i,e.channelId,"mention"))return;let o="user"===a?"".concat(n.displayName," があなたにメンションしました"):"channel"===a?"".concat(n.displayName," がチャンネル全体にメンションしました"):"".concat(n.displayName," が全員にメンションしました");await l(i,{type:"mention",title:o,body:e.content.substring(0,100),data:{channelId:t.id,messageId:e.id,senderId:e.senderMemberId,senderName:n.displayName}}),h(o,{body:e.content.substring(0,100),tag:"mention-".concat(e.id),requireInteraction:!0,data:{channelId:t.id,messageId:e.id}})}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.