@agent-native/core 0.77.4 → 0.77.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (192) hide show
  1. package/corpus/README.md +1 -1
  2. package/corpus/core/CHANGELOG.md +31 -0
  3. package/corpus/core/package.json +3 -3
  4. package/corpus/core/src/agent/production-agent.ts +35 -0
  5. package/corpus/core/src/agent/run-store.ts +2 -0
  6. package/corpus/core/src/agent/thread-data-builder.ts +21 -2
  7. package/corpus/core/src/cli/create.ts +35 -1
  8. package/corpus/core/src/cli/skills.ts +8 -0
  9. package/corpus/core/src/client/AgentPanel.tsx +57 -25
  10. package/corpus/core/src/client/MultiTabAssistantChat.tsx +31 -1
  11. package/corpus/core/src/client/analytics.ts +24 -2
  12. package/corpus/core/src/client/changelog/Changelog.tsx +22 -10
  13. package/corpus/core/src/client/extensions/ExtensionsSidebarSection.tsx +405 -35
  14. package/corpus/core/src/client/use-agent-engine-configured.ts +29 -15
  15. package/corpus/core/src/client/use-chat-threads.ts +104 -55
  16. package/corpus/core/src/server/analytics.ts +27 -3
  17. package/corpus/core/src/sharing/access.ts +35 -13
  18. package/corpus/core/src/sharing/actions/share-resource.ts +32 -9
  19. package/corpus/core/src/sharing/actions/unshare-resource.ts +25 -2
  20. package/corpus/core/src/sharing/registry.ts +9 -0
  21. package/corpus/core/src/vite/client.ts +3 -0
  22. package/corpus/templates/analytics/actions/data-source-status.ts +25 -14
  23. package/corpus/templates/analytics/app/components/layout/NewAnalysisDialog.tsx +2 -2
  24. package/corpus/templates/analytics/app/lib/data-source-status.ts +47 -6
  25. package/corpus/templates/analytics/app/lib/data-sources.ts +14 -3
  26. package/corpus/templates/analytics/app/pages/DataSources.tsx +24 -5
  27. package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/PanelEditorDialog.tsx +15 -43
  28. package/corpus/templates/analytics/changelog/2026-06-25-fixed-hubspot-data-source-status-so-private-app-tokens-legac.md +6 -0
  29. package/corpus/templates/analytics/netlify.toml +1 -0
  30. package/corpus/templates/analytics/server/lib/credential-keys.ts +3 -1
  31. package/corpus/templates/analytics/server/routes/api/test-connection.post.ts +12 -3
  32. package/corpus/templates/assets/app/components/layout/Sidebar.tsx +5 -2
  33. package/corpus/templates/assets/changelog/2026-06-25-create-now-returns-from-agent-settings-to-the-asset-chat-eve.md +6 -0
  34. package/corpus/templates/assets/netlify.toml +1 -0
  35. package/corpus/templates/brain/netlify.toml +1 -0
  36. package/corpus/templates/calendar/app/i18n-data.ts +12 -0
  37. package/corpus/templates/calendar/app/lib/clipboard.ts +58 -0
  38. package/corpus/templates/calendar/app/pages/AvailabilitySettings.tsx +15 -9
  39. package/corpus/templates/calendar/app/pages/BookingLinksPage.tsx +6 -2
  40. package/corpus/templates/calendar/changelog/2026-06-25-booking-link-copy-buttons-no-longer-fail-when-clipboard-perm.md +6 -0
  41. package/corpus/templates/calendar/netlify.toml +1 -0
  42. package/corpus/templates/chat/netlify.toml +1 -0
  43. package/corpus/templates/clips/AGENTS.md +9 -7
  44. package/corpus/templates/clips/actions/add-vocabulary-term.ts +2 -2
  45. package/corpus/templates/clips/actions/archive-recording.ts +5 -2
  46. package/corpus/templates/clips/actions/clear-edits.ts +5 -2
  47. package/corpus/templates/clips/actions/create-folder.ts +7 -2
  48. package/corpus/templates/clips/actions/delete-folder.ts +7 -4
  49. package/corpus/templates/clips/actions/delete-recording-permanent.ts +5 -2
  50. package/corpus/templates/clips/actions/finalize-recording.ts +5 -2
  51. package/corpus/templates/clips/actions/import-loom-recording.ts +2 -1
  52. package/corpus/templates/clips/actions/list-notifications.ts +9 -5
  53. package/corpus/templates/clips/actions/list-organization-state.ts +2 -1
  54. package/corpus/templates/clips/actions/list-recordings.ts +4 -1
  55. package/corpus/templates/clips/actions/move-recording.ts +5 -1
  56. package/corpus/templates/clips/actions/rename-folder.ts +6 -3
  57. package/corpus/templates/clips/actions/request-transcript.ts +5 -2
  58. package/corpus/templates/clips/actions/restore-recording.ts +5 -2
  59. package/corpus/templates/clips/actions/save-browser-diagnostics.ts +21 -8
  60. package/corpus/templates/clips/actions/set-chapters.ts +5 -2
  61. package/corpus/templates/clips/actions/set-thumbnail.ts +5 -2
  62. package/corpus/templates/clips/actions/split-recording.ts +5 -2
  63. package/corpus/templates/clips/actions/stitch-recordings.ts +6 -2
  64. package/corpus/templates/clips/actions/trash-recording.ts +5 -2
  65. package/corpus/templates/clips/actions/undo-edit.ts +5 -2
  66. package/corpus/templates/clips/actions/view-screen.ts +2 -1
  67. package/corpus/templates/clips/app/components/library/recording-card.tsx +24 -7
  68. package/corpus/templates/clips/app/i18n/ar-SA.ts +14 -0
  69. package/corpus/templates/clips/app/i18n/de-DE.ts +14 -0
  70. package/corpus/templates/clips/app/i18n/en-US.ts +14 -0
  71. package/corpus/templates/clips/app/i18n/es-ES.ts +14 -0
  72. package/corpus/templates/clips/app/i18n/fr-FR.ts +14 -0
  73. package/corpus/templates/clips/app/i18n/hi-IN.ts +14 -0
  74. package/corpus/templates/clips/app/i18n/ja-JP.ts +14 -0
  75. package/corpus/templates/clips/app/i18n/ko-KR.ts +14 -0
  76. package/corpus/templates/clips/app/i18n/pt-BR.ts +14 -0
  77. package/corpus/templates/clips/app/i18n/zh-CN.ts +14 -0
  78. package/corpus/templates/clips/app/lib/browser-diagnostics-capture.ts +5 -1
  79. package/corpus/templates/clips/app/root.tsx +2 -2
  80. package/corpus/templates/clips/app/routes/_app.extensions.$id.tsx +4 -1
  81. package/corpus/templates/clips/app/routes/_app.extensions._index.tsx +4 -1
  82. package/corpus/templates/clips/app/routes/_app.settings._index.tsx +12 -5
  83. package/corpus/templates/clips/changelog/2026-06-25-chrome-extension-recordings-now-upload-large-capture-bursts.md +6 -0
  84. package/corpus/templates/clips/changelog/2026-06-25-console-diagnostics-keep-more-useful-non-secret-details-when.md +6 -0
  85. package/corpus/templates/clips/changelog/2026-06-25-fixed-owner-recognition-so-clips-created-from-desktop-and-we.md +6 -0
  86. package/corpus/templates/clips/changelog/2026-06-25-localized-clips-settings-changelog-and-extension-sidebar-lab.md +6 -0
  87. package/corpus/templates/clips/chrome-extension/package.json +3 -0
  88. package/corpus/templates/clips/chrome-extension/public/manifest.json +1 -1
  89. package/corpus/templates/clips/chrome-extension/src/background.ts +85 -9
  90. package/corpus/templates/clips/chrome-extension/src/content-script.ts +55 -0
  91. package/corpus/templates/clips/chrome-extension/src/offscreen.ts +79 -3
  92. package/corpus/templates/clips/chrome-extension/src/options.ts +10 -0
  93. package/corpus/templates/clips/chrome-extension/src/overlay.ts +6 -0
  94. package/corpus/templates/clips/chrome-extension/src/permission.ts +8 -1
  95. package/corpus/templates/clips/chrome-extension/src/popup.ts +65 -39
  96. package/corpus/templates/clips/chrome-extension/src/sentry.ts +206 -0
  97. package/corpus/templates/clips/chrome-extension/vite.config.ts +47 -0
  98. package/corpus/templates/clips/desktop/src/overlays/countdown.tsx +4 -2
  99. package/corpus/templates/clips/desktop/src/styles.css +15 -1
  100. package/corpus/templates/clips/netlify.toml +1 -0
  101. package/corpus/templates/clips/server/db/index.ts +1 -0
  102. package/corpus/templates/clips/server/lib/google-calendar-oauth.ts +35 -23
  103. package/corpus/templates/clips/server/lib/public-agent-context.ts +8 -1
  104. package/corpus/templates/clips/server/lib/recordings.ts +18 -2
  105. package/corpus/templates/clips/server/lib/slack-oauth.ts +9 -6
  106. package/corpus/templates/clips/server/plugins/onboarding-calendar.ts +6 -2
  107. package/corpus/templates/clips/server/routes/api/public-recording.get.ts +2 -2
  108. package/corpus/templates/clips/server/routes/api/recordings/[recordingId]/thumbnail.post.ts +5 -2
  109. package/corpus/templates/clips/server/routes/api/uploads/[recordingId]/abort.post.ts +5 -2
  110. package/corpus/templates/clips/server/routes/api/uploads/[recordingId]/chunk.post.ts +5 -2
  111. package/corpus/templates/clips/server/routes/api/uploads/[recordingId]/reset-chunks.post.ts +5 -2
  112. package/corpus/templates/clips/shared/browser-diagnostics.ts +14 -4
  113. package/corpus/templates/content/netlify.toml +1 -0
  114. package/corpus/templates/design/netlify.toml +1 -0
  115. package/corpus/templates/dispatch/netlify.toml +1 -0
  116. package/corpus/templates/forms/netlify.toml +1 -0
  117. package/corpus/templates/macros/netlify.toml +1 -0
  118. package/corpus/templates/mail/app/components/email/EmailList.tsx +7 -3
  119. package/corpus/templates/mail/app/components/email/EmailThread.tsx +4 -1
  120. package/corpus/templates/mail/app/components/layout/AppLayout.tsx +10 -2
  121. package/corpus/templates/mail/app/hooks/use-compose-state.ts +15 -5
  122. package/corpus/templates/mail/app/hooks/use-google-auth.ts +47 -9
  123. package/corpus/templates/mail/changelog/2026-06-25-account-avatars-stay-stable-while-mail-refreshes-google-acco.md +6 -0
  124. package/corpus/templates/mail/changelog/2026-06-25-mail-background-draft-saves-and-thread-prefetches-no-longer.md +6 -0
  125. package/corpus/templates/mail/netlify.toml +1 -0
  126. package/corpus/templates/plan/.agents/skills/visual-plan/references/canvas.md +8 -0
  127. package/corpus/templates/plan/netlify.toml +1 -0
  128. package/corpus/templates/slides/netlify.toml +1 -0
  129. package/corpus/templates/videos/netlify.toml +1 -0
  130. package/dist/agent/production-agent.d.ts.map +1 -1
  131. package/dist/agent/production-agent.js +31 -0
  132. package/dist/agent/production-agent.js.map +1 -1
  133. package/dist/agent/run-store.d.ts +2 -0
  134. package/dist/agent/run-store.d.ts.map +1 -1
  135. package/dist/agent/run-store.js +2 -0
  136. package/dist/agent/run-store.js.map +1 -1
  137. package/dist/agent/thread-data-builder.d.ts.map +1 -1
  138. package/dist/agent/thread-data-builder.js +23 -2
  139. package/dist/agent/thread-data-builder.js.map +1 -1
  140. package/dist/cli/create.d.ts.map +1 -1
  141. package/dist/cli/create.js +28 -1
  142. package/dist/cli/create.js.map +1 -1
  143. package/dist/cli/skills.d.ts +1 -1
  144. package/dist/cli/skills.d.ts.map +1 -1
  145. package/dist/cli/skills.js +8 -0
  146. package/dist/cli/skills.js.map +1 -1
  147. package/dist/client/AgentPanel.d.ts +8 -2
  148. package/dist/client/AgentPanel.d.ts.map +1 -1
  149. package/dist/client/AgentPanel.js +29 -15
  150. package/dist/client/AgentPanel.js.map +1 -1
  151. package/dist/client/MultiTabAssistantChat.d.ts.map +1 -1
  152. package/dist/client/MultiTabAssistantChat.js +4 -4
  153. package/dist/client/MultiTabAssistantChat.js.map +1 -1
  154. package/dist/client/analytics.d.ts.map +1 -1
  155. package/dist/client/analytics.js +22 -2
  156. package/dist/client/analytics.js.map +1 -1
  157. package/dist/client/changelog/Changelog.d.ts +7 -2
  158. package/dist/client/changelog/Changelog.d.ts.map +1 -1
  159. package/dist/client/changelog/Changelog.js +9 -7
  160. package/dist/client/changelog/Changelog.js.map +1 -1
  161. package/dist/client/extensions/ExtensionsSidebarSection.d.ts.map +1 -1
  162. package/dist/client/extensions/ExtensionsSidebarSection.js +339 -11
  163. package/dist/client/extensions/ExtensionsSidebarSection.js.map +1 -1
  164. package/dist/client/use-agent-engine-configured.d.ts.map +1 -1
  165. package/dist/client/use-agent-engine-configured.js +23 -13
  166. package/dist/client/use-agent-engine-configured.js.map +1 -1
  167. package/dist/client/use-chat-threads.d.ts +4 -0
  168. package/dist/client/use-chat-threads.d.ts.map +1 -1
  169. package/dist/client/use-chat-threads.js +49 -4
  170. package/dist/client/use-chat-threads.js.map +1 -1
  171. package/dist/collab/routes.d.ts +1 -1
  172. package/dist/file-upload/actions/upload-image.d.ts +2 -2
  173. package/dist/observability/routes.d.ts +7 -7
  174. package/dist/server/agent-engine-api-key-route.d.ts +2 -2
  175. package/dist/server/analytics.d.ts +4 -0
  176. package/dist/server/analytics.d.ts.map +1 -1
  177. package/dist/server/analytics.js +19 -3
  178. package/dist/server/analytics.js.map +1 -1
  179. package/dist/sharing/access.d.ts.map +1 -1
  180. package/dist/sharing/access.js +26 -12
  181. package/dist/sharing/access.js.map +1 -1
  182. package/dist/sharing/actions/share-resource.js +20 -9
  183. package/dist/sharing/actions/share-resource.js.map +1 -1
  184. package/dist/sharing/actions/unshare-resource.js +13 -2
  185. package/dist/sharing/actions/unshare-resource.js.map +1 -1
  186. package/dist/sharing/registry.d.ts +9 -0
  187. package/dist/sharing/registry.d.ts.map +1 -1
  188. package/dist/sharing/registry.js.map +1 -1
  189. package/dist/vite/client.d.ts.map +1 -1
  190. package/dist/vite/client.js +1 -0
  191. package/dist/vite/client.js.map +1 -1
  192. package/package.json +3 -3
@@ -11,6 +11,7 @@ import { HoverCard, HoverCardContent, HoverCardTrigger, } from "../components/ui
11
11
  import { Popover, PopoverContent, PopoverTrigger, } from "../components/ui/popover.js";
12
12
  import { Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, } from "../components/ui/tooltip.js";
13
13
  import { PromptComposer } from "../composer/PromptComposer.js";
14
+ import { DEFAULT_LOCALE, useOptionalLocale } from "../i18n.js";
14
15
  import { cn } from "../utils.js";
15
16
  import { deleteOrHideExtension, invalidateExtensionRemoval, } from "./delete-extension.js";
16
17
  import { applyToolsOrder, getToolsOrder, setToolsOrder, } from "./extension-order.js";
@@ -19,6 +20,332 @@ const FAVORITES_KEY = "extensions-favorites";
19
20
  const COLLAPSED_EXTENSION_COUNT = 3;
20
21
  const EXTENSIONS_OPEN_KEY = "extensions-sidebar-open";
21
22
  const EXTENSIONS_SORT_MODE_KEY = "extensions-sort-mode";
23
+ const EXTENSIONS_COPY = {
24
+ "en-US": {
25
+ title: "Extensions",
26
+ description: "Build small sandboxed apps that can read app data, call actions, and save their own state.",
27
+ open: "Open extensions",
28
+ learnMore: "Learn more",
29
+ sortOptions: "Extensions sort options",
30
+ sortTooltip: "Extensions sort",
31
+ sortBy: "Sort by",
32
+ mostUsed: "Most used",
33
+ alphabetical: "Alphabetical",
34
+ manualOrder: "Manual order",
35
+ showHidden: "Show hidden",
36
+ newExtension: "New extension",
37
+ createPlaceholder: "Describe what you'd like to build...",
38
+ collapse: "Collapse extensions",
39
+ expand: "Expand extensions",
40
+ reorder: (name) => `Reorder ${name}`,
41
+ dragToReorder: "Drag to reorder",
42
+ hiddenFromEveryone: "Hidden from everyone",
43
+ file: "File",
44
+ unfavorite: "Unfavorite",
45
+ favorite: "Favorite",
46
+ actions: "Extension actions",
47
+ editInFiles: "Edit in files",
48
+ rename: "Rename",
49
+ unhideForEveryone: "Unhide for everyone",
50
+ hideFromEveryone: "Hide from everyone",
51
+ removeFromMyList: "Remove from my list",
52
+ delete: "Delete",
53
+ showLess: "show less",
54
+ showMore: "show more",
55
+ },
56
+ "zh-CN": {
57
+ title: "扩展",
58
+ description: "构建可读取应用数据、调用操作并保存自身状态的小型沙盒应用。",
59
+ open: "打开扩展",
60
+ learnMore: "了解更多",
61
+ sortOptions: "扩展排序选项",
62
+ sortTooltip: "扩展排序",
63
+ sortBy: "排序方式",
64
+ mostUsed: "最常用",
65
+ alphabetical: "按字母顺序",
66
+ manualOrder: "手动排序",
67
+ showHidden: "显示隐藏项",
68
+ newExtension: "新建扩展",
69
+ createPlaceholder: "描述你想构建的内容...",
70
+ collapse: "收起扩展",
71
+ expand: "展开扩展",
72
+ reorder: (name) => `重新排序 ${name}`,
73
+ dragToReorder: "拖动以重新排序",
74
+ hiddenFromEveryone: "已对所有人隐藏",
75
+ file: "文件",
76
+ unfavorite: "取消收藏",
77
+ favorite: "收藏",
78
+ actions: "扩展操作",
79
+ editInFiles: "在文件中编辑",
80
+ rename: "重命名",
81
+ unhideForEveryone: "对所有人取消隐藏",
82
+ hideFromEveryone: "对所有人隐藏",
83
+ removeFromMyList: "从我的列表中移除",
84
+ delete: "删除",
85
+ showLess: "收起",
86
+ showMore: "显示更多",
87
+ },
88
+ "es-ES": {
89
+ title: "Extensiones",
90
+ description: "Crea pequeñas apps aisladas que pueden leer datos de la app, llamar acciones y guardar su propio estado.",
91
+ open: "Abrir extensiones",
92
+ learnMore: "Más información",
93
+ sortOptions: "Opciones de orden de extensiones",
94
+ sortTooltip: "Orden de extensiones",
95
+ sortBy: "Ordenar por",
96
+ mostUsed: "Más usadas",
97
+ alphabetical: "Alfabético",
98
+ manualOrder: "Orden manual",
99
+ showHidden: "Mostrar ocultas",
100
+ newExtension: "Nueva extensión",
101
+ createPlaceholder: "Describe lo que quieres crear...",
102
+ collapse: "Contraer extensiones",
103
+ expand: "Expandir extensiones",
104
+ reorder: (name) => `Reordenar ${name}`,
105
+ dragToReorder: "Arrastra para reordenar",
106
+ hiddenFromEveryone: "Oculta para todos",
107
+ file: "Archivo",
108
+ unfavorite: "Quitar de favoritos",
109
+ favorite: "Favorito",
110
+ actions: "Acciones de extensión",
111
+ editInFiles: "Editar en archivos",
112
+ rename: "Renombrar",
113
+ unhideForEveryone: "Mostrar para todos",
114
+ hideFromEveryone: "Ocultar para todos",
115
+ removeFromMyList: "Quitar de mi lista",
116
+ delete: "Eliminar",
117
+ showLess: "mostrar menos",
118
+ showMore: "mostrar más",
119
+ },
120
+ "fr-FR": {
121
+ title: "Extensions",
122
+ description: "Créez de petites apps sandboxées capables de lire les données de l'app, d'appeler des actions et d'enregistrer leur propre état.",
123
+ open: "Ouvrir les extensions",
124
+ learnMore: "En savoir plus",
125
+ sortOptions: "Options de tri des extensions",
126
+ sortTooltip: "Tri des extensions",
127
+ sortBy: "Trier par",
128
+ mostUsed: "Les plus utilisées",
129
+ alphabetical: "Alphabétique",
130
+ manualOrder: "Ordre manuel",
131
+ showHidden: "Afficher les masquées",
132
+ newExtension: "Nouvelle extension",
133
+ createPlaceholder: "Décrivez ce que vous voulez créer...",
134
+ collapse: "Replier les extensions",
135
+ expand: "Déplier les extensions",
136
+ reorder: (name) => `Réordonner ${name}`,
137
+ dragToReorder: "Faire glisser pour réordonner",
138
+ hiddenFromEveryone: "Masquée pour tout le monde",
139
+ file: "Fichier",
140
+ unfavorite: "Retirer des favoris",
141
+ favorite: "Favori",
142
+ actions: "Actions de l'extension",
143
+ editInFiles: "Modifier dans les fichiers",
144
+ rename: "Renommer",
145
+ unhideForEveryone: "Afficher pour tout le monde",
146
+ hideFromEveryone: "Masquer pour tout le monde",
147
+ removeFromMyList: "Retirer de ma liste",
148
+ delete: "Supprimer",
149
+ showLess: "afficher moins",
150
+ showMore: "afficher plus",
151
+ },
152
+ "de-DE": {
153
+ title: "Erweiterungen",
154
+ description: "Erstelle kleine Sandbox-Apps, die App-Daten lesen, Aktionen aufrufen und ihren eigenen Zustand speichern können.",
155
+ open: "Erweiterungen öffnen",
156
+ learnMore: "Mehr erfahren",
157
+ sortOptions: "Sortieroptionen für Erweiterungen",
158
+ sortTooltip: "Erweiterungen sortieren",
159
+ sortBy: "Sortieren nach",
160
+ mostUsed: "Am häufigsten genutzt",
161
+ alphabetical: "Alphabetisch",
162
+ manualOrder: "Manuelle Reihenfolge",
163
+ showHidden: "Ausgeblendete anzeigen",
164
+ newExtension: "Neue Erweiterung",
165
+ createPlaceholder: "Beschreibe, was du erstellen möchtest...",
166
+ collapse: "Erweiterungen einklappen",
167
+ expand: "Erweiterungen ausklappen",
168
+ reorder: (name) => `${name} neu anordnen`,
169
+ dragToReorder: "Zum Neuordnen ziehen",
170
+ hiddenFromEveryone: "Für alle ausgeblendet",
171
+ file: "Datei",
172
+ unfavorite: "Aus Favoriten entfernen",
173
+ favorite: "Favorisieren",
174
+ actions: "Erweiterungsaktionen",
175
+ editInFiles: "In Dateien bearbeiten",
176
+ rename: "Umbenennen",
177
+ unhideForEveryone: "Für alle einblenden",
178
+ hideFromEveryone: "Für alle ausblenden",
179
+ removeFromMyList: "Aus meiner Liste entfernen",
180
+ delete: "Löschen",
181
+ showLess: "weniger anzeigen",
182
+ showMore: "mehr anzeigen",
183
+ },
184
+ "ja-JP": {
185
+ title: "拡張機能",
186
+ description: "アプリデータを読み取り、アクションを呼び出し、独自の状態を保存できる小さなサンドボックスアプリを作成します。",
187
+ open: "拡張機能を開く",
188
+ learnMore: "詳しく見る",
189
+ sortOptions: "拡張機能の並べ替えオプション",
190
+ sortTooltip: "拡張機能の並べ替え",
191
+ sortBy: "並べ替え",
192
+ mostUsed: "よく使う順",
193
+ alphabetical: "アルファベット順",
194
+ manualOrder: "手動順",
195
+ showHidden: "非表示を表示",
196
+ newExtension: "新しい拡張機能",
197
+ createPlaceholder: "作りたいものを説明してください...",
198
+ collapse: "拡張機能を折りたたむ",
199
+ expand: "拡張機能を展開",
200
+ reorder: (name) => `${name} を並べ替え`,
201
+ dragToReorder: "ドラッグして並べ替え",
202
+ hiddenFromEveryone: "全員に非表示",
203
+ file: "ファイル",
204
+ unfavorite: "お気に入り解除",
205
+ favorite: "お気に入り",
206
+ actions: "拡張機能の操作",
207
+ editInFiles: "ファイルで編集",
208
+ rename: "名前を変更",
209
+ unhideForEveryone: "全員に表示",
210
+ hideFromEveryone: "全員に非表示",
211
+ removeFromMyList: "自分のリストから削除",
212
+ delete: "削除",
213
+ showLess: "少なく表示",
214
+ showMore: "さらに表示",
215
+ },
216
+ "ko-KR": {
217
+ title: "확장",
218
+ description: "앱 데이터를 읽고, 액션을 호출하고, 자체 상태를 저장할 수 있는 작은 샌드박스 앱을 만듭니다.",
219
+ open: "확장 열기",
220
+ learnMore: "자세히 알아보기",
221
+ sortOptions: "확장 정렬 옵션",
222
+ sortTooltip: "확장 정렬",
223
+ sortBy: "정렬 기준",
224
+ mostUsed: "가장 많이 사용",
225
+ alphabetical: "가나다순",
226
+ manualOrder: "수동 순서",
227
+ showHidden: "숨김 항목 표시",
228
+ newExtension: "새 확장",
229
+ createPlaceholder: "만들고 싶은 것을 설명하세요...",
230
+ collapse: "확장 접기",
231
+ expand: "확장 펼치기",
232
+ reorder: (name) => `${name} 순서 변경`,
233
+ dragToReorder: "드래그하여 순서 변경",
234
+ hiddenFromEveryone: "모두에게 숨김",
235
+ file: "파일",
236
+ unfavorite: "즐겨찾기 해제",
237
+ favorite: "즐겨찾기",
238
+ actions: "확장 작업",
239
+ editInFiles: "파일에서 편집",
240
+ rename: "이름 변경",
241
+ unhideForEveryone: "모두에게 표시",
242
+ hideFromEveryone: "모두에게 숨기기",
243
+ removeFromMyList: "내 목록에서 제거",
244
+ delete: "삭제",
245
+ showLess: "덜 보기",
246
+ showMore: "더 보기",
247
+ },
248
+ "pt-BR": {
249
+ title: "Extensões",
250
+ description: "Crie pequenos apps isolados que podem ler dados do app, chamar ações e salvar o próprio estado.",
251
+ open: "Abrir extensões",
252
+ learnMore: "Saiba mais",
253
+ sortOptions: "Opções de ordenação das extensões",
254
+ sortTooltip: "Ordenação das extensões",
255
+ sortBy: "Ordenar por",
256
+ mostUsed: "Mais usadas",
257
+ alphabetical: "Alfabética",
258
+ manualOrder: "Ordem manual",
259
+ showHidden: "Mostrar ocultas",
260
+ newExtension: "Nova extensão",
261
+ createPlaceholder: "Descreva o que você quer criar...",
262
+ collapse: "Recolher extensões",
263
+ expand: "Expandir extensões",
264
+ reorder: (name) => `Reordenar ${name}`,
265
+ dragToReorder: "Arraste para reordenar",
266
+ hiddenFromEveryone: "Oculta para todos",
267
+ file: "Arquivo",
268
+ unfavorite: "Remover dos favoritos",
269
+ favorite: "Favoritar",
270
+ actions: "Ações da extensão",
271
+ editInFiles: "Editar em arquivos",
272
+ rename: "Renomear",
273
+ unhideForEveryone: "Mostrar para todos",
274
+ hideFromEveryone: "Ocultar para todos",
275
+ removeFromMyList: "Remover da minha lista",
276
+ delete: "Excluir",
277
+ showLess: "mostrar menos",
278
+ showMore: "mostrar mais",
279
+ },
280
+ "hi-IN": {
281
+ title: "एक्सटेंशन",
282
+ description: "छोटे सैंडबॉक्स ऐप बनाएं जो ऐप डेटा पढ़ सकते हैं, कार्रवाइयां चला सकते हैं और अपना स्टेट सहेज सकते हैं।",
283
+ open: "एक्सटेंशन खोलें",
284
+ learnMore: "और जानें",
285
+ sortOptions: "एक्सटेंशन क्रम विकल्प",
286
+ sortTooltip: "एक्सटेंशन क्रम",
287
+ sortBy: "इसके अनुसार क्रमबद्ध करें",
288
+ mostUsed: "सबसे अधिक उपयोग",
289
+ alphabetical: "वर्णानुक्रम",
290
+ manualOrder: "मैन्युअल क्रम",
291
+ showHidden: "छिपे हुए दिखाएं",
292
+ newExtension: "नया एक्सटेंशन",
293
+ createPlaceholder: "बताएं कि आप क्या बनाना चाहते हैं...",
294
+ collapse: "एक्सटेंशन समेटें",
295
+ expand: "एक्सटेंशन फैलाएं",
296
+ reorder: (name) => `${name} का क्रम बदलें`,
297
+ dragToReorder: "क्रम बदलने के लिए खींचें",
298
+ hiddenFromEveryone: "सभी से छिपा हुआ",
299
+ file: "फ़ाइल",
300
+ unfavorite: "पसंदीदा से हटाएं",
301
+ favorite: "पसंदीदा",
302
+ actions: "एक्सटेंशन कार्रवाइयां",
303
+ editInFiles: "फ़ाइलों में संपादित करें",
304
+ rename: "नाम बदलें",
305
+ unhideForEveryone: "सभी के लिए दिखाएं",
306
+ hideFromEveryone: "सभी से छिपाएं",
307
+ removeFromMyList: "मेरी सूची से हटाएं",
308
+ delete: "हटाएं",
309
+ showLess: "कम दिखाएं",
310
+ showMore: "और दिखाएं",
311
+ },
312
+ "ar-SA": {
313
+ title: "الإضافات",
314
+ description: "أنشئ تطبيقات صغيرة معزولة يمكنها قراءة بيانات التطبيق واستدعاء الإجراءات وحفظ حالتها الخاصة.",
315
+ open: "فتح الإضافات",
316
+ learnMore: "معرفة المزيد",
317
+ sortOptions: "خيارات ترتيب الإضافات",
318
+ sortTooltip: "ترتيب الإضافات",
319
+ sortBy: "ترتيب حسب",
320
+ mostUsed: "الأكثر استخدامًا",
321
+ alphabetical: "أبجديًا",
322
+ manualOrder: "ترتيب يدوي",
323
+ showHidden: "إظهار المخفية",
324
+ newExtension: "إضافة جديدة",
325
+ createPlaceholder: "صف ما تريد إنشاءه...",
326
+ collapse: "طي الإضافات",
327
+ expand: "توسيع الإضافات",
328
+ reorder: (name) => `إعادة ترتيب ${name}`,
329
+ dragToReorder: "اسحب لإعادة الترتيب",
330
+ hiddenFromEveryone: "مخفية عن الجميع",
331
+ file: "ملف",
332
+ unfavorite: "إزالة من المفضلة",
333
+ favorite: "إضافة إلى المفضلة",
334
+ actions: "إجراءات الإضافة",
335
+ editInFiles: "تحرير في الملفات",
336
+ rename: "إعادة تسمية",
337
+ unhideForEveryone: "إظهار للجميع",
338
+ hideFromEveryone: "إخفاء عن الجميع",
339
+ removeFromMyList: "إزالة من قائمتي",
340
+ delete: "حذف",
341
+ showLess: "إظهار أقل",
342
+ showMore: "إظهار المزيد",
343
+ },
344
+ };
345
+ function useExtensionsCopy() {
346
+ const locale = useOptionalLocale()?.locale ?? DEFAULT_LOCALE;
347
+ return EXTENSIONS_COPY[locale] ?? EXTENSIONS_COPY[DEFAULT_LOCALE];
348
+ }
22
349
  function getFavorites() {
23
350
  try {
24
351
  const raw = localStorage.getItem(FAVORITES_KEY);
@@ -84,16 +411,17 @@ function sortByName(items) {
84
411
  return name !== 0 ? name : a.id.localeCompare(b.id);
85
412
  });
86
413
  }
87
- function ExtensionSortMenu({ value, onChange, showHidden, onShowHiddenChange, }) {
88
- return (_jsxs(DropdownMenu, { children: [_jsxs(Tooltip, { children: [_jsx(TooltipTrigger, { asChild: true, children: _jsx(DropdownMenuTrigger, { asChild: true, children: _jsx("button", { type: "button", className: "inline-flex h-6 w-6 shrink-0 items-center justify-center rounded-md text-muted-foreground/45 opacity-0 transition-all hover:bg-accent hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring group-hover/extensions-section:opacity-100", "aria-label": "Extensions sort options", children: _jsx(IconSettings, { className: "h-3.5 w-3.5" }) }) }) }), _jsx(TooltipContent, { children: "Extensions sort" })] }), _jsxs(DropdownMenuContent, { side: "right", align: "start", className: "w-44", children: [_jsx(DropdownMenuLabel, { children: "Sort by" }), _jsxs(DropdownMenuRadioGroup, { value: value, onValueChange: (next) => {
414
+ function ExtensionSortMenu({ value, onChange, showHidden, onShowHiddenChange, copy, }) {
415
+ return (_jsxs(DropdownMenu, { children: [_jsxs(Tooltip, { children: [_jsx(TooltipTrigger, { asChild: true, children: _jsx(DropdownMenuTrigger, { asChild: true, children: _jsx("button", { type: "button", className: "inline-flex h-6 w-6 shrink-0 items-center justify-center rounded-md text-muted-foreground/45 opacity-0 transition-all hover:bg-accent hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring group-hover/extensions-section:opacity-100", "aria-label": copy.sortOptions, children: _jsx(IconSettings, { className: "h-3.5 w-3.5" }) }) }) }), _jsx(TooltipContent, { children: copy.sortTooltip })] }), _jsxs(DropdownMenuContent, { side: "right", align: "start", className: "w-44", children: [_jsx(DropdownMenuLabel, { children: copy.sortBy }), _jsxs(DropdownMenuRadioGroup, { value: value, onValueChange: (next) => {
89
416
  if (next === "most-used" ||
90
417
  next === "alphabetical" ||
91
418
  next === "manual") {
92
419
  onChange(next);
93
420
  }
94
- }, children: [_jsx(DropdownMenuRadioItem, { value: "most-used", children: "Most used" }), _jsx(DropdownMenuRadioItem, { value: "alphabetical", children: "Alphabetical" }), _jsx(DropdownMenuSeparator, {}), _jsx(DropdownMenuRadioItem, { value: "manual", children: "Manual order" })] }), _jsx(DropdownMenuSeparator, {}), _jsx(DropdownMenuCheckboxItem, { checked: showHidden, onCheckedChange: (checked) => onShowHiddenChange(Boolean(checked)), children: "Show hidden" })] })] }));
421
+ }, children: [_jsx(DropdownMenuRadioItem, { value: "most-used", children: copy.mostUsed }), _jsx(DropdownMenuRadioItem, { value: "alphabetical", children: copy.alphabetical }), _jsx(DropdownMenuSeparator, {}), _jsx(DropdownMenuRadioItem, { value: "manual", children: copy.manualOrder })] }), _jsx(DropdownMenuSeparator, {}), _jsx(DropdownMenuCheckboxItem, { checked: showHidden, onCheckedChange: (checked) => onShowHiddenChange(Boolean(checked)), children: copy.showHidden })] })] }));
95
422
  }
96
423
  export function ExtensionsSidebarSection() {
424
+ const copy = useExtensionsCopy();
97
425
  const location = useLocation();
98
426
  const navigate = useNavigate();
99
427
  const queryClient = useQueryClient();
@@ -292,7 +620,7 @@ export function ExtensionsSidebarSection() {
292
620
  };
293
621
  return (_jsx(TooltipProvider, { delayDuration: 200, children: _jsxs("div", { className: "relative min-w-0 py-1", children: [_jsxs("div", { className: cn("group/extensions-section relative flex w-full min-w-0 items-center rounded-md text-sm font-medium transition-all hover:text-primary", location.pathname.startsWith("/extensions")
294
622
  ? "text-sidebar-accent-foreground"
295
- : "text-muted-foreground hover:bg-sidebar-accent/50", extensionsOpen && sortedTools.length > 0 && "mb-1"), children: [_jsx("button", { type: "button", onClick: toggleExtensionsOpen, className: "absolute inset-0 rounded-md focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring", "aria-label": extensionsOpen ? "Collapse extensions" : "Expand extensions", "aria-expanded": extensionsOpen }), _jsxs("div", { className: "pointer-events-none relative z-10 flex min-w-0 flex-1 items-center gap-2 px-3 py-1.5 pr-20", children: [_jsx(IconTool, { className: "h-4 w-4 shrink-0" }), _jsxs(HoverCard, { openDelay: 1200, closeDelay: 200, children: [_jsx(HoverCardTrigger, { asChild: true, children: _jsx("span", { className: "pointer-events-auto min-w-0 select-none truncate", onClick: toggleExtensionsOpen, children: "Extensions" }) }), _jsxs(HoverCardContent, { side: "top", align: "start", sideOffset: 8, className: "w-72 space-y-3 p-3", children: [_jsxs("div", { children: [_jsx("p", { className: "text-sm font-semibold text-foreground", children: "Extensions" }), _jsx("p", { className: "mt-1 text-xs leading-relaxed text-muted-foreground", children: "Build small sandboxed apps that can read app data, call actions, and save their own state." })] }), _jsxs("div", { className: "flex items-center gap-2", children: [_jsx(Link, { to: "/extensions", className: "inline-flex h-8 items-center rounded-md border px-2.5 text-xs font-medium text-foreground transition-colors hover:bg-accent", children: "Open extensions" }), _jsx("a", { href: "https://agent-native.com/docs/extensions", target: "_blank", rel: "noopener noreferrer", className: "inline-flex h-8 items-center rounded-md px-2.5 text-xs font-medium text-muted-foreground transition-colors hover:bg-accent hover:text-foreground", children: "Learn more" })] })] })] })] }), _jsxs("div", { className: "absolute right-1 top-1/2 z-20 flex -translate-y-1/2 items-center", children: [_jsx(ExtensionSortMenu, { value: sortModeState, onChange: setExtensionSortMode, showHidden: showGloballyHidden, onShowHiddenChange: setShowGloballyHidden }), _jsxs(Popover, { open: showCreate, onOpenChange: setShowCreate, children: [_jsx(PopoverTrigger, { asChild: true, children: _jsx("button", { type: "button", className: "inline-flex h-6 w-6 shrink-0 cursor-pointer items-center justify-center rounded-md text-muted-foreground/70 transition-colors hover:bg-accent hover:text-accent-foreground", "aria-label": "New extension", children: _jsx(IconPlus, { className: "h-3.5 w-3.5" }) }) }), _jsxs(PopoverContent, { side: "right", align: "start", className: "w-[420px] p-3", children: [_jsx("p", { className: "px-1 pb-2 text-sm font-semibold text-foreground", children: "New extension" }), _jsx(PromptComposer, { autoFocus: true, placeholder: "Describe what you'd like to build...", draftScope: "extensions:sidebar-create", onSubmit: handleCreate })] })] }), _jsx("button", { type: "button", onClick: toggleExtensionsOpen, className: "flex h-6 w-6 shrink-0 items-center justify-center rounded-md text-muted-foreground/70 hover:bg-accent hover:text-foreground", "aria-label": extensionsOpen ? "Collapse extensions" : "Expand extensions", "aria-expanded": extensionsOpen, children: _jsx(IconChevronDown, { className: cn("h-3.5 w-3.5 shrink-0 transition-transform", !extensionsOpen && "-rotate-90") }) })] })] }), extensionsOpen &&
623
+ : "text-muted-foreground hover:bg-sidebar-accent/50", extensionsOpen && sortedTools.length > 0 && "mb-1"), children: [_jsx("button", { type: "button", onClick: toggleExtensionsOpen, className: "absolute inset-0 rounded-md focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring", "aria-label": extensionsOpen ? copy.collapse : copy.expand, "aria-expanded": extensionsOpen }), _jsxs("div", { className: "pointer-events-none relative z-10 flex min-w-0 flex-1 items-center gap-2 px-3 py-1.5 pr-20", children: [_jsx(IconTool, { className: "h-4 w-4 shrink-0" }), _jsxs(HoverCard, { openDelay: 1200, closeDelay: 200, children: [_jsx(HoverCardTrigger, { asChild: true, children: _jsx("span", { className: "pointer-events-auto min-w-0 select-none truncate", onClick: toggleExtensionsOpen, children: copy.title }) }), _jsxs(HoverCardContent, { side: "top", align: "start", sideOffset: 8, className: "w-72 space-y-3 p-3", children: [_jsxs("div", { children: [_jsx("p", { className: "text-sm font-semibold text-foreground", children: copy.title }), _jsx("p", { className: "mt-1 text-xs leading-relaxed text-muted-foreground", children: copy.description })] }), _jsxs("div", { className: "flex items-center gap-2", children: [_jsx(Link, { to: "/extensions", className: "inline-flex h-8 items-center rounded-md border px-2.5 text-xs font-medium text-foreground transition-colors hover:bg-accent", children: copy.open }), _jsx("a", { href: "https://agent-native.com/docs/extensions", target: "_blank", rel: "noopener noreferrer", className: "inline-flex h-8 items-center rounded-md px-2.5 text-xs font-medium text-muted-foreground transition-colors hover:bg-accent hover:text-foreground", children: copy.learnMore })] })] })] })] }), _jsxs("div", { className: "absolute right-1 top-1/2 z-20 flex -translate-y-1/2 items-center", children: [_jsx(ExtensionSortMenu, { value: sortModeState, onChange: setExtensionSortMode, showHidden: showGloballyHidden, onShowHiddenChange: setShowGloballyHidden, copy: copy }), _jsxs(Popover, { open: showCreate, onOpenChange: setShowCreate, children: [_jsx(PopoverTrigger, { asChild: true, children: _jsx("button", { type: "button", className: "inline-flex h-6 w-6 shrink-0 cursor-pointer items-center justify-center rounded-md text-muted-foreground/70 transition-colors hover:bg-accent hover:text-accent-foreground", "aria-label": copy.newExtension, children: _jsx(IconPlus, { className: "h-3.5 w-3.5" }) }) }), _jsxs(PopoverContent, { side: "right", align: "start", className: "w-[420px] p-3", children: [_jsx("p", { className: "px-1 pb-2 text-sm font-semibold text-foreground", children: copy.newExtension }), _jsx(PromptComposer, { autoFocus: true, placeholder: copy.createPlaceholder, draftScope: "extensions:sidebar-create", onSubmit: handleCreate })] })] }), _jsx("button", { type: "button", onClick: toggleExtensionsOpen, className: "flex h-6 w-6 shrink-0 items-center justify-center rounded-md text-muted-foreground/70 hover:bg-accent hover:text-foreground", "aria-label": extensionsOpen ? copy.collapse : copy.expand, "aria-expanded": extensionsOpen, children: _jsx(IconChevronDown, { className: cn("h-3.5 w-3.5 shrink-0 transition-transform", !extensionsOpen && "-rotate-90") }) })] })] }), extensionsOpen &&
296
624
  (isLoading ? (_jsx("div", { className: "min-w-0 space-y-0.5 px-0.5", children: [1, 2, 3].map((i) => (_jsx("div", { className: "flex items-center rounded-md px-2 py-1.5", children: _jsx("div", { className: "h-3 rounded bg-muted animate-pulse", style: { width: `${60 + i * 20}px` } }) }, i))) })) : sortedTools.length === 0 ? null : (_jsxs("div", { className: "min-w-0 space-y-0.5 px-0.5", children: [visibleTools.map((extension) => {
297
625
  const isActive = isExtensionPathname(location.pathname, extension.id);
298
626
  const isFav = favoriteIds.has(extension.id);
@@ -324,7 +652,7 @@ export function ExtensionsSidebarSection() {
324
652
  }, onDragEnd: () => {
325
653
  setDraggingId(null);
326
654
  setDragOverId(null);
327
- }, className: "-ml-2 cursor-grab rounded p-0.5 text-muted-foreground/30 opacity-0 transition-colors hover:text-muted-foreground/70 active:cursor-grabbing group-hover/extension:opacity-100 group-focus-within/extension:opacity-100", "aria-label": `Reorder ${extension.name}`, children: _jsx(IconGripVertical, { className: "h-3 w-3" }) }) }), _jsx(TooltipContent, { children: "Drag to reorder" })] }), _jsx(Link, { to: extensionPath(extension.id, extension.name), className: cn("flex min-w-0 flex-1 items-center rounded-md px-2 py-1.5 pr-12 text-xs transition-[padding,color,background-color] md:pr-2 md:group-hover/extension:pr-12 md:group-focus-within/extension:pr-12", actionsVisible && "md:pr-12", isActive
655
+ }, className: "-ml-2 cursor-grab rounded p-0.5 text-muted-foreground/30 opacity-0 transition-colors hover:text-muted-foreground/70 active:cursor-grabbing group-hover/extension:opacity-100 group-focus-within/extension:opacity-100", "aria-label": copy.reorder(extension.name), children: _jsx(IconGripVertical, { className: "h-3 w-3" }) }) }), _jsx(TooltipContent, { children: copy.dragToReorder })] }), _jsx(Link, { to: extensionPath(extension.id, extension.name), className: cn("flex min-w-0 flex-1 items-center rounded-md px-2 py-1.5 pr-12 text-xs transition-[padding,color,background-color] md:pr-2 md:group-hover/extension:pr-12 md:group-focus-within/extension:pr-12", actionsVisible && "md:pr-12", isActive
328
656
  ? "bg-accent text-accent-foreground font-medium"
329
657
  : "text-muted-foreground hover:bg-accent/50 hover:text-accent-foreground"), children: isRenamingThis ? (_jsx("input", { autoFocus: true, value: renameValue, onChange: (e) => setRenameValue(e.target.value), onBlur: () => submitRename(extension.id), onKeyDown: (e) => {
330
658
  if (e.key === "Enter")
@@ -334,17 +662,17 @@ export function ExtensionsSidebarSection() {
334
662
  }, onClick: (e) => {
335
663
  e.preventDefault();
336
664
  e.stopPropagation();
337
- }, className: "min-w-0 flex-1 truncate border-b border-primary bg-transparent px-0 py-0 text-xs outline-none" })) : (_jsxs("span", { className: "flex min-w-0 items-center gap-1.5", children: [extension.globallyHidden && (_jsx(IconEyeOff, { className: "h-3 w-3 shrink-0 text-muted-foreground/60", "aria-label": "Hidden from everyone" })), _jsx("span", { className: "block truncate", children: extension.name }), isLocalExtension && (_jsx("span", { className: "shrink-0 rounded border border-border px-1 text-[9px] font-medium uppercase tracking-wide text-muted-foreground/70", children: "File" }))] })) }), _jsxs("div", { className: cn("pointer-events-none absolute right-1 top-1/2 flex -translate-y-1/2 items-center gap-0.5 opacity-100 transition-opacity md:opacity-0 md:group-hover/extension:opacity-100 md:group-focus-within/extension:opacity-100", actionsVisible && "md:opacity-100"), children: [_jsx("button", { type: "button", onClick: (e) => {
665
+ }, className: "min-w-0 flex-1 truncate border-b border-primary bg-transparent px-0 py-0 text-xs outline-none" })) : (_jsxs("span", { className: "flex min-w-0 items-center gap-1.5", children: [extension.globallyHidden && (_jsx(IconEyeOff, { className: "h-3 w-3 shrink-0 text-muted-foreground/60", "aria-label": copy.hiddenFromEveryone })), _jsx("span", { className: "block truncate", children: extension.name }), isLocalExtension && (_jsx("span", { className: "shrink-0 rounded border border-border px-1 text-[9px] font-medium uppercase tracking-wide text-muted-foreground/70", children: copy.file }))] })) }), _jsxs("div", { className: cn("pointer-events-none absolute right-1 top-1/2 flex -translate-y-1/2 items-center gap-0.5 opacity-100 transition-opacity md:opacity-0 md:group-hover/extension:opacity-100 md:group-focus-within/extension:opacity-100", actionsVisible && "md:opacity-100"), children: [_jsx("button", { type: "button", onClick: (e) => {
338
666
  e.preventDefault();
339
667
  e.stopPropagation();
340
668
  toggleFavorite(extension.id);
341
669
  }, className: cn("pointer-events-auto cursor-pointer rounded p-0.5 transition-colors", isFav
342
670
  ? "text-yellow-500"
343
- : "text-muted-foreground/40 hover:text-yellow-500"), "aria-label": isFav ? "Unfavorite" : "Favorite", children: isFav ? (_jsx(IconStarFilled, { className: "h-3 w-3" })) : (_jsx(IconStar, { className: "h-3 w-3" })) }), _jsxs(DropdownMenu, { open: menuOpenId === extension.id, onOpenChange: (open) => setMenuOpenId(open ? extension.id : null), children: [_jsx(DropdownMenuTrigger, { asChild: true, children: _jsx("button", { type: "button", className: "pointer-events-auto cursor-pointer rounded p-0.5 text-muted-foreground/40 transition-colors hover:text-foreground", "aria-label": "Extension actions", children: _jsx(IconDots, { className: "h-3 w-3" }) }) }), _jsxs(DropdownMenuContent, { align: "end", sideOffset: 4, className: "min-w-[140px]", children: [isLocalExtension ? (_jsxs(DropdownMenuItem, { disabled: true, children: [_jsx(IconPencil, { className: "h-3.5 w-3.5" }), "Edit in files"] })) : (_jsxs(DropdownMenuItem, { onSelect: () => startRename(extension), children: [_jsx(IconPencil, { className: "h-3.5 w-3.5" }), "Rename"] })), !isLocalExtension &&
671
+ : "text-muted-foreground/40 hover:text-yellow-500"), "aria-label": isFav ? copy.unfavorite : copy.favorite, children: isFav ? (_jsx(IconStarFilled, { className: "h-3 w-3" })) : (_jsx(IconStar, { className: "h-3 w-3" })) }), _jsxs(DropdownMenu, { open: menuOpenId === extension.id, onOpenChange: (open) => setMenuOpenId(open ? extension.id : null), children: [_jsx(DropdownMenuTrigger, { asChild: true, children: _jsx("button", { type: "button", className: "pointer-events-auto cursor-pointer rounded p-0.5 text-muted-foreground/40 transition-colors hover:text-foreground", "aria-label": copy.actions, children: _jsx(IconDots, { className: "h-3 w-3" }) }) }), _jsxs(DropdownMenuContent, { align: "end", sideOffset: 4, className: "min-w-[140px]", children: [isLocalExtension ? (_jsxs(DropdownMenuItem, { disabled: true, children: [_jsx(IconPencil, { className: "h-3.5 w-3.5" }), copy.editInFiles] })) : (_jsxs(DropdownMenuItem, { onSelect: () => startRename(extension), children: [_jsx(IconPencil, { className: "h-3.5 w-3.5" }), copy.rename] })), !isLocalExtension &&
344
672
  extension.canDelete !== false &&
345
- (extension.globallyHidden ? (_jsxs(DropdownMenuItem, { onSelect: () => handleGlobalUnhide(extension), children: [_jsx(IconEye, { className: "h-3.5 w-3.5" }), "Unhide for everyone"] })) : (_jsxs(DropdownMenuItem, { onSelect: () => handleGlobalHide(extension), children: [_jsx(IconEyeOff, { className: "h-3.5 w-3.5" }), "Hide from everyone"] }))), !isLocalExtension && (_jsxs(DropdownMenuItem, { onSelect: () => handleDelete(extension), className: "text-destructive focus:text-destructive", children: [_jsx(IconTrash, { className: "h-3.5 w-3.5" }), extension.canDelete === false
346
- ? "Remove from my list"
347
- : "Delete"] }))] })] })] })] }, extension.id));
348
- }), hasMoreExtensions && (_jsx("button", { type: "button", "aria-expanded": showAllExtensions, onClick: () => setShowAllExtensions((current) => !current), className: "ml-5 mt-1 inline-flex h-5 items-center rounded px-1.5 text-[11px] font-medium text-muted-foreground/60 transition-colors hover:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-1", children: showAllExtensions ? "show less" : "show more" }))] })))] }) }));
673
+ (extension.globallyHidden ? (_jsxs(DropdownMenuItem, { onSelect: () => handleGlobalUnhide(extension), children: [_jsx(IconEye, { className: "h-3.5 w-3.5" }), copy.unhideForEveryone] })) : (_jsxs(DropdownMenuItem, { onSelect: () => handleGlobalHide(extension), children: [_jsx(IconEyeOff, { className: "h-3.5 w-3.5" }), copy.hideFromEveryone] }))), !isLocalExtension && (_jsxs(DropdownMenuItem, { onSelect: () => handleDelete(extension), className: "text-destructive focus:text-destructive", children: [_jsx(IconTrash, { className: "h-3.5 w-3.5" }), extension.canDelete === false
674
+ ? copy.removeFromMyList
675
+ : copy.delete] }))] })] })] })] }, extension.id));
676
+ }), hasMoreExtensions && (_jsx("button", { type: "button", "aria-expanded": showAllExtensions, onClick: () => setShowAllExtensions((current) => !current), className: "ml-5 mt-1 inline-flex h-5 items-center rounded px-1.5 text-[11px] font-medium text-muted-foreground/60 transition-colors hover:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-1", children: showAllExtensions ? copy.showLess : copy.showMore }))] })))] }) }));
349
677
  }
350
678
  //# sourceMappingURL=ExtensionsSidebarSection.js.map