mirror of
https://github.com/johndoe6345789/metabuilder.git
synced 2026-04-24 13:54:57 +00:00
docs: social,packages,nextjs (2 files)
This commit is contained in:
@@ -66,6 +66,8 @@ Full-featured sections with business logic:
|
||||
|
||||
**Editors:** SchemaEditor, CodeEditor, LuaEditor, JsonEditor, NerdModeIDE
|
||||
|
||||
`NerdModeIDE` is a thin wrapper that re-exports the modular implementation under `components/nerd-mode-ide/`.
|
||||
|
||||
**Managers:** DatabaseManager, UserManagement, PackageManager, ThemeEditor
|
||||
|
||||
**Features:** IRCWebchat, WorkflowEditor, AuditLogViewer, ScreenshotAnalyzer
|
||||
|
||||
13
packages/social_hub/seed/scripts/analytics.lua
Normal file
13
packages/social_hub/seed/scripts/analytics.lua
Normal file
@@ -0,0 +1,13 @@
|
||||
local Analytics = {}
|
||||
|
||||
function Analytics.aggregate(events)
|
||||
local summary = { views = 0, likes = 0, comments = 0 }
|
||||
for _, event in ipairs(events or {}) do
|
||||
summary.views = summary.views + (event.views or 0)
|
||||
summary.likes = summary.likes + (event.likes or 0)
|
||||
summary.comments = summary.comments + (event.comments or 0)
|
||||
end
|
||||
return summary
|
||||
end
|
||||
|
||||
return Analytics
|
||||
Reference in New Issue
Block a user