# app/components/UI/Notification/index.coffee # Добавление стилей компонента if globalThis.stylFns and globalThis.stylFns['app/components/UI/Notification/index.styl'] styleElement = document.createElement('style') styleElement.type = 'text/css' styleElement.textContent = globalThis.stylFns['app/components/UI/Notification/index.styl'] document.head.appendChild(styleElement) else log '⚠️ Стили уведомлений не найдены' module.exports = name: 'notification-container' props: notifications: type: Array default: -> [] methods: closeNotification: (id) -> @$emit 'close-notification', id formatTime: (timestamp) -> return '' unless timestamp date = new Date(timestamp) date.toLocaleTimeString('ru-RU', { hour: '2-digit', minute: '2-digit' }) render: (new Function '_ctx', '_cache', globalThis.renderFns['app/components/UI/Notification/index.pug'])()