Rename all 1,169 components to path-based names with namespace support

Component names now reflect filesystem location using / as path separator
and : as namespace separator for shared components:
  ~sx-header → ~layouts/header
  ~layout-app-body → ~shared:layout/app-body
  ~blog-admin-dashboard → ~admin/dashboard

209 files, 4,941 replacements across all services.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-12 22:00:12 +00:00
parent de80d921e9
commit b0920a1121
209 changed files with 4620 additions and 4620 deletions

View File

@@ -1,9 +1,9 @@
;; Notification components
(defcomp ~federation-notification-preview (&key (preview :as string))
(defcomp ~notifications/preview (&key (preview :as string))
(div :class "text-sm text-stone-500 mt-1 truncate" preview))
(defcomp ~federation-notification-card (&key (cls :as string) avatar (from-name :as string) (from-username :as string) (from-domain :as string) (action-text :as string) preview (time :as string))
(defcomp ~notifications/card (&key (cls :as string) avatar (from-name :as string) (from-username :as string) (from-domain :as string) (action-text :as string) preview (time :as string))
(div :class cls
(div :class "flex items-start gap-3"
avatar
@@ -15,14 +15,14 @@
preview
(div :class "text-xs text-stone-400 mt-1" time)))))
(defcomp ~federation-notifications-list (&key (items :as list))
(defcomp ~notifications/list (&key (items :as list))
(div :class "space-y-2" items))
(defcomp ~federation-notifications-page (&key notifs)
(defcomp ~notifications/page (&key notifs)
(h1 :class "text-2xl font-bold mb-6" "Notifications") notifs)
;; Assembled notification card — replaces Python _notification_sx
(defcomp ~federation-notification-from-data (&key (notif :as dict))
(defcomp ~notifications/from-data (&key (notif :as dict))
(let* ((from-name (or (get notif "from_actor_name") "?"))
(from-username (or (get notif "from_actor_username") ""))
(from-domain (or (get notif "from_actor_domain") ""))
@@ -44,9 +44,9 @@
((= ntype "mention") "mentioned you")
((= ntype "reply") "replied to your post")
(true ""))))
(~federation-notification-card
(~notifications/card
:cls (str "bg-white rounded-lg shadow-sm border border-stone-200 p-4" border)
:avatar (~avatar
:avatar (~shared:misc/avatar
:src from-icon
:cls (if from-icon "w-8 h-8 rounded-full"
"w-8 h-8 rounded-full bg-stone-300 flex items-center justify-center text-stone-600 font-bold text-xs")
@@ -55,15 +55,15 @@
:from-username (escape from-username)
:from-domain (if from-domain (str "@" (escape from-domain)) "")
:action-text action-text
:preview (when preview (~federation-notification-preview :preview (escape preview)))
:preview (when preview (~notifications/preview :preview (escape preview)))
:time created)))
;; Assembled notifications content — replaces Python _notifications_content_sx
(defcomp ~federation-notifications-content (&key (notifications :as list))
(~federation-notifications-page
(defcomp ~notifications/content (&key (notifications :as list))
(~notifications/page
:notifs (if (empty? notifications)
(~empty-state :message "No notifications yet." :cls "text-stone-500")
(~federation-notifications-list
(~shared:misc/empty-state :message "No notifications yet." :cls "text-stone-500")
(~notifications/list
:items (map (lambda (n)
(~federation-notification-from-data :notif n))
(~notifications/from-data :notif n))
notifications)))))