"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }var _chunkUBRUS4CKjs = require('./chunk-UBRUS4CK.js');var _chunkX6JGAYTFjs = require('./chunk-X6JGAYTF.js');var _chunkC3IDIQ6Zjs = require('./chunk-C3IDIQ6Z.js');var _react = require('react');var _badges = require('@baseapp-frontend/design-system/components/native/badges');var _icons = require('@baseapp-frontend/design-system/components/native/icons');var _views = require('@baseapp-frontend/design-system/components/native/views');var _reactrelay = require('react-relay');var _jsxruntime = require('react/jsx-runtime');function c(t){"@babel/helpers - typeof";return c=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(t)}function l(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter(function(u){return Object.getOwnPropertyDescriptor(t,u).enumerable})),r.push.apply(r,i)}return r}function y(t){for(var e=1;e<arguments.length;e++){var r=arguments[e]!=null?arguments[e]:{};e%2?l(Object(r),!0).forEach(function(i){b(t,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):l(Object(r)).forEach(function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(r,i))})}return t}function b(t,e,r){return(e=d(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function d(t){var e=v(t,"string");return c(e)=="symbol"?e:e+""}function v(t,e){if(c(t)!="object"||!t)return t;var r=t[Symbol.toPrimitive];if(r!==void 0){var i=r.call(t,e||"default");if(c(i)!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var S=function(e){var r=e.isActive,i=r===void 0?!1:r,u=_reactrelay.useLazyLoadQuery.call(void 0, _chunkX6JGAYTFjs.a,{},{fetchPolicy:"store-and-network"}),m=u.me,o=_reactrelay.useFragment.call(void 0, _chunkUBRUS4CKjs.a,m);return _chunkC3IDIQ6Zjs.a.call(void 0, _optionalChain([o, 'optionalAccess', _ => _.id])),_jsxruntime.jsxs.call(void 0, _views.View,{children:[_jsxruntime.jsx.call(void 0, _icons.BellIcon,{width:"24",height:"24",isActive:i}),!!(o!=null&&o.notificationsUnreadCount)&&_jsxruntime.jsx.call(void 0, _badges.Badge,{children:o.notificationsUnreadCount>99?"99+":o.notificationsUnreadCount})]})},B=function(e){var r=e.isActive;return _jsxruntime.jsx.call(void 0, _react.Suspense,{fallback:_jsxruntime.jsx.call(void 0, _icons.BellIcon,{width:"24",height:"24",isActive:r}),children:_jsxruntime.jsx.call(void 0, S,y({},e))})},W= exports.a =B;exports.a = W;
//# sourceMappingURL=chunk-LB6J66DX.js.map