@anchrd/intel 0.59.0
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.
- package/README.md +496 -0
- package/bin/intel.mjs +134 -0
- package/dist/adapters/cloudflare/cloudflare-flow-workflow.d.ts +42 -0
- package/dist/adapters/cloudflare/cloudflare-flow-workflow.js +89 -0
- package/dist/adapters/cloudflare/cloudflare.d.ts +29 -0
- package/dist/adapters/cloudflare/cloudflare.js +416 -0
- package/dist/adapters/cloudflare/cloudflare.types.d.ts +31 -0
- package/dist/adapters/cloudflare/cloudflare.types.js +1 -0
- package/dist/adapters/content/content.d.ts +3 -0
- package/dist/adapters/content/content.js +128 -0
- package/dist/adapters/content/content.types.d.ts +38 -0
- package/dist/adapters/content/content.types.js +1 -0
- package/dist/adapters/db/db-audit.d.ts +62 -0
- package/dist/adapters/db/db-audit.js +150 -0
- package/dist/adapters/db/db-boards.d.ts +6 -0
- package/dist/adapters/db/db-boards.js +324 -0
- package/dist/adapters/db/db-feed.d.ts +30 -0
- package/dist/adapters/db/db-feed.js +276 -0
- package/dist/adapters/db/db-flows.d.ts +42 -0
- package/dist/adapters/db/db-flows.js +1311 -0
- package/dist/adapters/db/db-grants.d.ts +133 -0
- package/dist/adapters/db/db-grants.js +269 -0
- package/dist/adapters/db/db-indexing.d.ts +3 -0
- package/dist/adapters/db/db-indexing.js +200 -0
- package/dist/adapters/db/db-oauth.d.ts +3 -0
- package/dist/adapters/db/db-oauth.js +26 -0
- package/dist/adapters/db/db-prompts.d.ts +46 -0
- package/dist/adapters/db/db-prompts.js +144 -0
- package/dist/adapters/db/db.d.ts +6 -0
- package/dist/adapters/db/db.js +1687 -0
- package/dist/adapters/db/db.types.d.ts +16 -0
- package/dist/adapters/db/db.types.js +1 -0
- package/dist/adapters/document-converter/document-converter.d.ts +2 -0
- package/dist/adapters/document-converter/document-converter.js +26 -0
- package/dist/adapters/document-converter/document-converter.types.d.ts +17 -0
- package/dist/adapters/document-converter/document-converter.types.js +1 -0
- package/dist/adapters/flow-runtime/flow-runtime.d.ts +3 -0
- package/dist/adapters/flow-runtime/flow-runtime.js +22 -0
- package/dist/adapters/flow-runtime/flow-runtime.types.d.ts +19 -0
- package/dist/adapters/flow-runtime/flow-runtime.types.js +1 -0
- package/dist/adapters/index-queue/index-queue.d.ts +10 -0
- package/dist/adapters/index-queue/index-queue.js +12 -0
- package/dist/adapters/index-queue/index-queue.types.d.ts +11 -0
- package/dist/adapters/index-queue/index-queue.types.js +1 -0
- package/dist/adapters/json-schema/json-schema.d.ts +2 -0
- package/dist/adapters/json-schema/json-schema.js +77 -0
- package/dist/adapters/openid/openid.d.ts +5 -0
- package/dist/adapters/openid/openid.js +301 -0
- package/dist/adapters/portal-tokens/portal-tokens.d.ts +8 -0
- package/dist/adapters/portal-tokens/portal-tokens.js +79 -0
- package/dist/adapters/remote-tools/remote-tools.d.ts +5 -0
- package/dist/adapters/remote-tools/remote-tools.js +129 -0
- package/dist/adapters/semantic-index/semantic-index.d.ts +2 -0
- package/dist/adapters/semantic-index/semantic-index.js +139 -0
- package/dist/adapters/semantic-index/semantic-index.types.d.ts +56 -0
- package/dist/adapters/semantic-index/semantic-index.types.js +1 -0
- package/dist/adapters/session-cookie/session-cookie.d.ts +5 -0
- package/dist/adapters/session-cookie/session-cookie.js +87 -0
- package/dist/adapters/tool-source-policy/tool-source-policy.d.ts +1 -0
- package/dist/adapters/tool-source-policy/tool-source-policy.js +22 -0
- package/dist/audit/audit.d.ts +2 -0
- package/dist/audit/audit.js +87 -0
- package/dist/audit/audit.types.d.ts +23 -0
- package/dist/audit/audit.types.js +1 -0
- package/dist/auth/auth.d.ts +2 -0
- package/dist/auth/auth.js +284 -0
- package/dist/auth/auth.types.d.ts +108 -0
- package/dist/auth/auth.types.js +1 -0
- package/dist/boards/boards.d.ts +44 -0
- package/dist/boards/boards.js +447 -0
- package/dist/boards/boards.types.d.ts +117 -0
- package/dist/boards/boards.types.js +1 -0
- package/dist/build/build.d.ts +2 -0
- package/dist/build/build.js +192 -0
- package/dist/build/build.types.d.ts +17 -0
- package/dist/build/build.types.js +1 -0
- package/dist/bundle/bundle.d.ts +4 -0
- package/dist/bundle/bundle.js +1194 -0
- package/dist/bundle/bundle.types.d.ts +33 -0
- package/dist/bundle/bundle.types.js +1 -0
- package/dist/cli/cli.d.ts +4 -0
- package/dist/cli/cli.js +262 -0
- package/dist/cli/cli.types.d.ts +14 -0
- package/dist/cli/cli.types.js +1 -0
- package/dist/contract/audit.d.ts +50 -0
- package/dist/contract/audit.js +72 -0
- package/dist/contract/board.d.ts +150 -0
- package/dist/contract/board.js +262 -0
- package/dist/contract/bundle.d.ts +147 -0
- package/dist/contract/bundle.js +139 -0
- package/dist/contract/contract.d.ts +112 -0
- package/dist/contract/contract.js +143 -0
- package/dist/contract/feed.d.ts +126 -0
- package/dist/contract/feed.js +149 -0
- package/dist/contract/flow-run.d.ts +346 -0
- package/dist/contract/flow-run.js +194 -0
- package/dist/contract/flow.d.ts +1057 -0
- package/dist/contract/flow.js +552 -0
- package/dist/contract/node.d.ts +551 -0
- package/dist/contract/node.js +456 -0
- package/dist/contract/share.d.ts +216 -0
- package/dist/contract/share.js +134 -0
- package/dist/contract/table.d.ts +171 -0
- package/dist/contract/table.js +117 -0
- package/dist/contract/tool.d.ts +122 -0
- package/dist/contract/tool.js +172 -0
- package/dist/feed/feed.d.ts +2 -0
- package/dist/feed/feed.js +77 -0
- package/dist/feed/feed.types.d.ts +23 -0
- package/dist/feed/feed.types.js +1 -0
- package/dist/flows/flows.d.ts +41 -0
- package/dist/flows/flows.js +2216 -0
- package/dist/flows/flows.types.d.ts +339 -0
- package/dist/flows/flows.types.js +1 -0
- package/dist/http/http.d.ts +9 -0
- package/dist/http/http.js +874 -0
- package/dist/http/http.types.d.ts +22 -0
- package/dist/http/http.types.js +1 -0
- package/dist/indexing/indexing.d.ts +6 -0
- package/dist/indexing/indexing.js +239 -0
- package/dist/indexing/indexing.types.d.ts +11 -0
- package/dist/indexing/indexing.types.js +1 -0
- package/dist/intel/intel.d.ts +3 -0
- package/dist/intel/intel.js +194 -0
- package/dist/intel/intel.types.d.ts +24 -0
- package/dist/intel/intel.types.js +1 -0
- package/dist/mcp/mcp.d.ts +2 -0
- package/dist/mcp/mcp.js +1292 -0
- package/dist/mcp/mcp.types.d.ts +25 -0
- package/dist/mcp/mcp.types.js +1 -0
- package/dist/nodes/document-links/document-links.d.ts +20 -0
- package/dist/nodes/document-links/document-links.js +57 -0
- package/dist/nodes/nodes.d.ts +2 -0
- package/dist/nodes/nodes.js +1667 -0
- package/dist/nodes/nodes.types.d.ts +511 -0
- package/dist/nodes/nodes.types.js +1 -0
- package/dist/prepare/prepare.d.ts +4 -0
- package/dist/prepare/prepare.js +16 -0
- package/dist/prepare/prepare.types.d.ts +9 -0
- package/dist/prepare/prepare.types.js +1 -0
- package/dist/prompts/prompts.d.ts +2 -0
- package/dist/prompts/prompts.js +65 -0
- package/dist/prompts/prompts.types.d.ts +71 -0
- package/dist/prompts/prompts.types.js +1 -0
- package/dist/shared/callers/callers.d.ts +28 -0
- package/dist/shared/callers/callers.js +30 -0
- package/dist/shared/csv/csv.d.ts +13 -0
- package/dist/shared/csv/csv.js +85 -0
- package/dist/shared/document-text/document-text.d.ts +21 -0
- package/dist/shared/document-text/document-text.js +31 -0
- package/dist/shared/gate-authorization/gate-authorization.d.ts +5 -0
- package/dist/shared/gate-authorization/gate-authorization.js +26 -0
- package/dist/shared/grant-expiry/grant-expiry.d.ts +19 -0
- package/dist/shared/grant-expiry/grant-expiry.js +26 -0
- package/dist/shared/intel-error/intel-error.d.ts +22 -0
- package/dist/shared/intel-error/intel-error.js +27 -0
- package/dist/shared/plain-title/plain-title.d.ts +16 -0
- package/dist/shared/plain-title/plain-title.js +45 -0
- package/dist/shared/problem-details/problem-details.d.ts +30 -0
- package/dist/shared/problem-details/problem-details.js +18 -0
- package/dist/shared/report-unexpected-error/report-unexpected-error.d.ts +1 -0
- package/dist/shared/report-unexpected-error/report-unexpected-error.js +37 -0
- package/dist/shared/safe-return-path/safe-return-path.d.ts +2 -0
- package/dist/shared/safe-return-path/safe-return-path.js +11 -0
- package/dist/shared/sha256/sha256.d.ts +2 -0
- package/dist/shared/sha256/sha256.js +14 -0
- package/dist/tools/tool-servers/tool-servers.d.ts +46 -0
- package/dist/tools/tool-servers/tool-servers.js +177 -0
- package/dist/tools/tools.d.ts +2 -0
- package/dist/tools/tools.js +207 -0
- package/dist/tools/tools.types.d.ts +56 -0
- package/dist/tools/tools.types.js +1 -0
- package/examples/branding/favicon.svg +5 -0
- package/examples/branding/logo.svg +5 -0
- package/examples/branding/theme.css +16 -0
- package/examples/dev.vars.example +7 -0
- package/examples/intel.json +9 -0
- package/migrations/0000_intel_foundation.sql +203 -0
- package/migrations/0001_portal_native_tools.sql +21 -0
- package/migrations/0002_flows_in_the_knowledge_tree.sql +34 -0
- package/migrations/0003_folder_permissions.sql +211 -0
- package/migrations/0004_subflow_runs.sql +14 -0
- package/migrations/0005_flow_node_cleanup.sql +28 -0
- package/migrations/0005_tables_in_the_knowledge_tree.sql +68 -0
- package/migrations/0006_links_are_written_in_the_text.sql +20 -0
- package/migrations/0007_no_node_waits.sql +69 -0
- package/migrations/0008_three_layers.sql +130 -0
- package/migrations/0009_no_context_policy.sql +48 -0
- package/migrations/0010_no_run_waits_a_year.sql +27 -0
- package/migrations/0011_one_name_for_the_tree.sql +53 -0
- package/migrations/0012_table_snapshots.sql +29 -0
- package/migrations/0017_a_vector_per_card.sql +38 -0
- package/migrations/0018_no_context_policy_at_last.sql +97 -0
- package/migrations/0019_one_name_for_the_grants.sql +52 -0
- package/migrations/0020_cascade_purge_replay.sql +11 -0
- package/migrations/0021_a_flow_carries_its_own_grant.sql +44 -0
- package/migrations/0022_a_cursor_over_the_journal.sql +14 -0
- package/migrations/0023_a_board_and_its_tasks.sql +116 -0
- package/migrations/0024_the_archive_is_a_column.sql +33 -0
- package/migrations/0025_archiving_takes_the_subtree.sql +29 -0
- package/migrations/0026_one_feed_over_two_kinds.sql +23 -0
- package/migrations/0027_the_runs_of_every_flow.sql +27 -0
- package/migrations/0028_a_prompt_name_over_two_kinds.sql +70 -0
- package/package.json +118 -0
- package/src/contract/CLAUDE.md +152 -0
- package/src/contract/README.md +102 -0
- package/src/contract/audit.ts +85 -0
- package/src/contract/board.ts +306 -0
- package/src/contract/bundle.ts +157 -0
- package/src/contract/contract.ts +161 -0
- package/src/contract/feed.ts +165 -0
- package/src/contract/flow-run.ts +241 -0
- package/src/contract/flow.ts +675 -0
- package/src/contract/node.ts +583 -0
- package/src/contract/share.ts +196 -0
- package/src/contract/table.ts +178 -0
- package/src/contract/tool.ts +202 -0
- package/ui/README.md +110 -0
- package/ui/components.json +21 -0
- package/ui/index.html +13 -0
- package/ui/package.json +11 -0
- package/ui/scripts/lint-tokens.mjs +187 -0
- package/ui/src/access-summary/access-summary.tsx +385 -0
- package/ui/src/app/action-slot/action-slot.tsx +27 -0
- package/ui/src/app/app-sidebar/app-sidebar.tsx +71 -0
- package/ui/src/app/app-tree/app-tree.tsx +1175 -0
- package/ui/src/app/app.tsx +87 -0
- package/ui/src/app/header-search/header-search.tsx +294 -0
- package/ui/src/app/reindex-dialog/reindex-dialog.tsx +79 -0
- package/ui/src/app/settings-dialog/settings-dialog.tsx +135 -0
- package/ui/src/app/sidebar-preferences/sidebar-preferences.ts +68 -0
- package/ui/src/app/sidebar-preferences/sidebar-preferences.types.ts +15 -0
- package/ui/src/app/sidebar-resize-handle/sidebar-resize-handle.tsx +86 -0
- package/ui/src/app/tree-expansion/tree-expansion.ts +107 -0
- package/ui/src/app/tree-expansion/tree-expansion.types.ts +31 -0
- package/ui/src/app/tree-move/tree-move.tsx +427 -0
- package/ui/src/app/tree-reveal/tree-reveal.ts +64 -0
- package/ui/src/app/tree-reveal/tree-reveal.types.ts +16 -0
- package/ui/src/app/user-footer/user-footer.tsx +188 -0
- package/ui/src/app/view-menu/view-menu.tsx +115 -0
- package/ui/src/app-root/app-root.tsx +109 -0
- package/ui/src/app-root/app-root.types.ts +27 -0
- package/ui/src/archive/archive.tsx +417 -0
- package/ui/src/attachment-detail/attachment-detail.ts +52 -0
- package/ui/src/attachment-viewer/attachment-viewer.tsx +166 -0
- package/ui/src/blocknote-view/blocknote-view.tsx +30 -0
- package/ui/src/board/board-assignee/board-assignee-picker.tsx +132 -0
- package/ui/src/board/board-assignee/board-assignee.ts +48 -0
- package/ui/src/board/board-assignee/board-assignee.tsx +75 -0
- package/ui/src/board/board-chip/board-chip.tsx +46 -0
- package/ui/src/board/board-crumbs/board-crumbs.ts +56 -0
- package/ui/src/board/board-crumbs/board-crumbs.tsx +111 -0
- package/ui/src/board/board-data/board-data.ts +195 -0
- package/ui/src/board/board-data/board-data.types.ts +38 -0
- package/ui/src/board/board-dates/board-dates.ts +40 -0
- package/ui/src/board/board-dates/board-dates.tsx +105 -0
- package/ui/src/board/board-kanban/board-kanban.ts +162 -0
- package/ui/src/board/board-kanban/board-kanban.tsx +680 -0
- package/ui/src/board/board-open-task/board-open-task.ts +32 -0
- package/ui/src/board/board-panel/board-panel.tsx +259 -0
- package/ui/src/board/board-settings/board-settings.tsx +226 -0
- package/ui/src/board/board-status/board-status.tsx +60 -0
- package/ui/src/board/board-stripes/board-stripes.ts +128 -0
- package/ui/src/board/board-table/board-table.ts +53 -0
- package/ui/src/board/board-table/board-table.tsx +610 -0
- package/ui/src/board/board-task/board-task.ts +108 -0
- package/ui/src/board/board-task/board-task.tsx +335 -0
- package/ui/src/board/board-title-row/board-title-row.tsx +66 -0
- package/ui/src/branding/branding.tsx +17 -0
- package/ui/src/branding/custom-logo.ts +1 -0
- package/ui/src/branding/favicon.default.svg +5 -0
- package/ui/src/branding/favicon.svg +5 -0
- package/ui/src/components/ui/avatar.tsx +39 -0
- package/ui/src/components/ui/button.tsx +64 -0
- package/ui/src/components/ui/collapsible.tsx +20 -0
- package/ui/src/components/ui/command.tsx +160 -0
- package/ui/src/components/ui/dialog.tsx +143 -0
- package/ui/src/components/ui/dropdown-menu.tsx +187 -0
- package/ui/src/components/ui/input.tsx +21 -0
- package/ui/src/components/ui/popover.tsx +41 -0
- package/ui/src/components/ui/select.tsx +163 -0
- package/ui/src/components/ui/separator.tsx +26 -0
- package/ui/src/components/ui/sheet.tsx +136 -0
- package/ui/src/components/ui/sidebar.tsx +693 -0
- package/ui/src/components/ui/skeleton.tsx +13 -0
- package/ui/src/components/ui/switch.tsx +25 -0
- package/ui/src/components/ui/table.tsx +82 -0
- package/ui/src/components/ui/tabs.tsx +52 -0
- package/ui/src/components/ui/tooltip.tsx +51 -0
- package/ui/src/data/intel-data-provider/intel-data-provider.ts +685 -0
- package/ui/src/data/intel-data-provider/intel-data-provider.types.ts +266 -0
- package/ui/src/data/query-client.ts +18 -0
- package/ui/src/data/request-refusal/refusal-notice.tsx +36 -0
- package/ui/src/data/request-refusal/request-refusal.ts +51 -0
- package/ui/src/data/sign-in/sign-in.ts +97 -0
- package/ui/src/data/sign-in/sign-in.types.ts +15 -0
- package/ui/src/document-link/document-link.tsx +114 -0
- package/ui/src/document-markdown/document-markdown.ts +195 -0
- package/ui/src/editor-schema/editor-schema.ts +23 -0
- package/ui/src/entry-picker/entry-picker.tsx +238 -0
- package/ui/src/feed/feed.tsx +344 -0
- package/ui/src/file-preview/file-preview-view.tsx +496 -0
- package/ui/src/file-preview/file-preview.tsx +28 -0
- package/ui/src/file-preview/pdf-file-preview.tsx +5 -0
- package/ui/src/file-preview/presentation-file-preview.tsx +21 -0
- package/ui/src/file-preview/spreadsheet-file-preview.tsx +5 -0
- package/ui/src/file-preview/word-file-preview.tsx +5 -0
- package/ui/src/flow-runs/flow-runs.tsx +238 -0
- package/ui/src/flows/flows.tsx +1646 -0
- package/ui/src/flows/node-icon/node-icon.ts +34 -0
- package/ui/src/flows/node-palette/node-palette.tsx +214 -0
- package/ui/src/flows/node-palette/node-palette.types.ts +15 -0
- package/ui/src/folder-contents/folder-contents.tsx +321 -0
- package/ui/src/folder-index/folder-index.ts +55 -0
- package/ui/src/frontmatter/frontmatter.tsx +193 -0
- package/ui/src/graph-pane/graph-pane.tsx +53 -0
- package/ui/src/hooks/use-mobile.ts +19 -0
- package/ui/src/i18n/custom.json +4 -0
- package/ui/src/i18n/de.json +609 -0
- package/ui/src/i18n/en.json +609 -0
- package/ui/src/i18n/es.json +609 -0
- package/ui/src/i18n/i18n-context.tsx +65 -0
- package/ui/src/i18n/i18n-languages/i18n-languages.ts +83 -0
- package/ui/src/i18n/i18n.ts +32 -0
- package/ui/src/i18n/i18n.types.ts +49 -0
- package/ui/src/kind-icon.ts +97 -0
- package/ui/src/lib/utils.ts +6 -0
- package/ui/src/main.tsx +68 -0
- package/ui/src/modal/modal.tsx +53 -0
- package/ui/src/node-details/node-details.tsx +545 -0
- package/ui/src/node-editor/node-editor.tsx +304 -0
- package/ui/src/node-graph/graph-notice.tsx +21 -0
- package/ui/src/node-graph/node-graph.ts +214 -0
- package/ui/src/node-graph/node-graph.tsx +295 -0
- package/ui/src/node-import/node-import.tsx +418 -0
- package/ui/src/node-save-error.ts +46 -0
- package/ui/src/node-source/node-source.tsx +128 -0
- package/ui/src/node-table/node-table.tsx +107 -0
- package/ui/src/nodes/nodes.tsx +240 -0
- package/ui/src/rename-resource/rename-resource.ts +80 -0
- package/ui/src/resolved-names/resolved-names.tsx +67 -0
- package/ui/src/resource-error.ts +33 -0
- package/ui/src/resource-menu/resource-menu.tsx +1156 -0
- package/ui/src/router/router-context.ts +6 -0
- package/ui/src/router/router.tsx +67 -0
- package/ui/src/router/router.types.ts +8 -0
- package/ui/src/router/selection-search.ts +88 -0
- package/ui/src/save-button/save-button.tsx +94 -0
- package/ui/src/section-hint/section-hint.tsx +40 -0
- package/ui/src/sign-in-refused/sign-in-refused.tsx +35 -0
- package/ui/src/styles.css +189 -0
- package/ui/src/table-columns/table-columns.tsx +379 -0
- package/ui/src/theme/custom.css +1 -0
- package/ui/src/theme/theme-context.tsx +89 -0
- package/ui/src/theme/theme.ts +70 -0
- package/ui/src/time/relative-time.tsx +41 -0
- package/ui/src/time/time-context.tsx +78 -0
- package/ui/src/time/time.ts +165 -0
- package/ui/src/title-row/title-row.tsx +185 -0
- package/ui/src/tools/tools.tsx +546 -0
- package/ui/src/user-name/user-name.ts +61 -0
- package/ui/src/verbatim/verbatim.tsx +68 -0
- package/ui/tsconfig.json +17 -0
- package/ui/vite.config.ts +129 -0
package/ui/README.md
ADDED
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
# The Intel browser application
|
|
2
|
+
|
|
3
|
+
Intelligence, Flows and Tools, served by the Intel Worker. It travels inside
|
|
4
|
+
[`@anchrd/intel`](https://www.npmjs.com/package/@anchrd/intel) at `ui/`, and it ships **source, not a
|
|
5
|
+
bundle**: you compile it yourself so your own theme, logo and languages are applied at build time and
|
|
6
|
+
the output belongs to you — no customer build artifact ever lives in `node_modules`.
|
|
7
|
+
|
|
8
|
+
## Install
|
|
9
|
+
|
|
10
|
+
```bash
|
|
11
|
+
npm install @anchrd/intel
|
|
12
|
+
npx intel build
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
The CLI applies `intel.json` and writes the static output to `.intel/ui`, which the Intel Worker
|
|
16
|
+
serves through its `ASSETS` binding.
|
|
17
|
+
|
|
18
|
+
## Reserved names
|
|
19
|
+
|
|
20
|
+
A document called **`index`** inside a folder is the **text of that folder**. `index`, `Index` and
|
|
21
|
+
`index.md` all count, upper and lower case alike.
|
|
22
|
+
|
|
23
|
+
Such a document does not appear as a row under its folder. It appears in that folder's **Details**,
|
|
24
|
+
where it is read and written like anywhere else, and a link there opens it on its own screen — which
|
|
25
|
+
is where it is moved, shared or archived.
|
|
26
|
+
|
|
27
|
+
⚠️ **The flip side is the same sentence read backwards:** naming a document `index` for any other
|
|
28
|
+
reason changes how its folder reads. If a document has to keep that name and stay a row of its own,
|
|
29
|
+
give it a name of its own — `index-2024.md` or `overview` — or file it one folder deeper.
|
|
30
|
+
|
|
31
|
+
Two documents of that name in one folder are allowed: the **oldest** becomes the folder's text and
|
|
32
|
+
every other one stays an ordinary row. Nothing disappears.
|
|
33
|
+
|
|
34
|
+
⚠️ **The top level is not a folder**, so the name means nothing there: a document called `index` at
|
|
35
|
+
the root keeps its row like any other. It has no details panel to be shown in, and a row taken away
|
|
36
|
+
with nowhere to reappear is a document nobody can navigate to.
|
|
37
|
+
|
|
38
|
+
Over MCP nothing is hidden at all: `node_list` and `node_get` answer for such a document exactly as
|
|
39
|
+
they do for any other, and `node_create` says so in its own description.
|
|
40
|
+
|
|
41
|
+
## Theming
|
|
42
|
+
|
|
43
|
+
Theme CSS overrides shadcn semantic variables such as `--primary`, `--background`, `--sidebar` and
|
|
44
|
+
`--radius`. It loads after Intel's defaults, so customer tokens win without forking a single React
|
|
45
|
+
component. Every product component uses semantic tokens rather than palette colours, which is
|
|
46
|
+
enforced by a lint rule.
|
|
47
|
+
|
|
48
|
+
Point `intel.json` at your files:
|
|
49
|
+
|
|
50
|
+
```json
|
|
51
|
+
{
|
|
52
|
+
"ui": {
|
|
53
|
+
"theme": "./branding/theme.css",
|
|
54
|
+
"logo": "./branding/logo.svg",
|
|
55
|
+
"favicon": "./branding/favicon.svg",
|
|
56
|
+
"defaultLanguage": "en",
|
|
57
|
+
"languages": {}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
Missing assets, non-SVG branding and incomplete language catalogs fail the build rather than
|
|
63
|
+
silently producing a half-branded application.
|
|
64
|
+
|
|
65
|
+
## What an empty screen means
|
|
66
|
+
|
|
67
|
+
Most "the UI is broken" reports are one of four situations, and the application distinguishes them
|
|
68
|
+
rather than showing one blank page for all of them. The full explanation of the two permission
|
|
69
|
+
layers is in the
|
|
70
|
+
[package README](../README.md); what follows is what each one looks like here.
|
|
71
|
+
|
|
72
|
+
| On screen | What it is |
|
|
73
|
+
|---|---|
|
|
74
|
+
| "You do not have permission to see this." | The Gate capability is missing — `nodes.read` and friends |
|
|
75
|
+
| An empty tree, no error | Nothing has been shared with this person yet |
|
|
76
|
+
| "This is not available to you. It may not exist, or it may no longer be shared with you." | A node that was reachable and is not any more, or never existed — Intel deliberately does not say which |
|
|
77
|
+
| Skeletons that never resolve | Should no longer happen: a refusal ends the loading state on the first answer, and no button offers a retry that cannot change anything |
|
|
78
|
+
|
|
79
|
+
A node somebody shares appears in the recipient's sidebar on its own, at the top level, without
|
|
80
|
+
naming the folders above it. Nobody needs to be sent a link.
|
|
81
|
+
|
|
82
|
+
The sharing dialog grants to an email address or to the whole organization. It never shows a raw
|
|
83
|
+
user id: where Intel cannot name an account it says so. ⚠️ Choosing **execute for the whole
|
|
84
|
+
organization** on a folder makes that folder a library that flows from anywhere may call into, and
|
|
85
|
+
withdrawing it is refused while a caller remains — the dialog says so before the click.
|
|
86
|
+
|
|
87
|
+
The Tools screen tells four situations apart — refused, expired, broken, and started-but-never-
|
|
88
|
+
answered — and offers a second attempt everywhere a second attempt could change the answer.
|
|
89
|
+
|
|
90
|
+
The editor answers "Nothing to save" rather than "Saved" when the write produced no new version.
|
|
91
|
+
The two are different outcomes and only one of them means the text is safe to walk away from.
|
|
92
|
+
|
|
93
|
+
⚠️ The editor opens **empty** on content it cannot parse. Documents written over HTTP or MCP have to
|
|
94
|
+
carry the BlockNote media type to be editable in the browser; see the wire schemas under
|
|
95
|
+
`src/contract`.
|
|
96
|
+
|
|
97
|
+
## What is inside
|
|
98
|
+
|
|
99
|
+
Vite, React, TanStack Router and Query, with shadcn components. The node editor uses BlockNote and
|
|
100
|
+
plain SVG for the radial relation graph, Flows uses React Flow, and Tools presents the discovered MCP
|
|
101
|
+
catalog. Route-level code splitting keeps both editors out of the initial bundle.
|
|
102
|
+
|
|
103
|
+
Server state lives only in TanStack Query, and one data provider is the sole module that talks to the
|
|
104
|
+
Intel HTTP surface. The application uses same-origin `HttpOnly` sessions established by the Intel
|
|
105
|
+
Worker against Gate OAuth: it holds no service key and stores no access token in the browser.
|
|
106
|
+
|
|
107
|
+
## License
|
|
108
|
+
|
|
109
|
+
Proprietary. Published publicly for installation convenience; this is not an open-source license and
|
|
110
|
+
grants no right to use, copy, modify or redistribute the software. Contact Anchrd for licensing.
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://ui.shadcn.com/schema.json",
|
|
3
|
+
"style": "new-york",
|
|
4
|
+
"rsc": false,
|
|
5
|
+
"tsx": true,
|
|
6
|
+
"tailwind": {
|
|
7
|
+
"config": "",
|
|
8
|
+
"css": "src/styles.css",
|
|
9
|
+
"baseColor": "neutral",
|
|
10
|
+
"cssVariables": true,
|
|
11
|
+
"prefix": ""
|
|
12
|
+
},
|
|
13
|
+
"aliases": {
|
|
14
|
+
"components": "@/components",
|
|
15
|
+
"utils": "@/lib/utils",
|
|
16
|
+
"ui": "@/components/ui",
|
|
17
|
+
"lib": "@/lib",
|
|
18
|
+
"hooks": "@/hooks"
|
|
19
|
+
},
|
|
20
|
+
"iconLibrary": "lucide"
|
|
21
|
+
}
|
package/ui/index.html
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
+
<link rel="icon" href="/src/branding/favicon.svg" />
|
|
7
|
+
<title>Intel</title>
|
|
8
|
+
</head>
|
|
9
|
+
<body>
|
|
10
|
+
<div id="root"></div>
|
|
11
|
+
<script type="module" src="/src/main.tsx"></script>
|
|
12
|
+
</body>
|
|
13
|
+
</html>
|
package/ui/package.json
ADDED
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
// Semantic tokens only: no hex colours, no Tailwind palette classes. The check this replaces was a
|
|
3
|
+
// single grep, and it could not tell `#101` — a ticket number in a comment — from `#101` the
|
|
4
|
+
// colour, because nothing separates them but where they stand (issue 104).
|
|
5
|
+
//
|
|
6
|
+
// ⚠️ The fix is to look at less, not to match less. Comments are stripped and everything else is
|
|
7
|
+
// checked with exactly the patterns the grep used, so no colour that used to be caught slips
|
|
8
|
+
// through. A colour named in a comment paints nothing; a colour in code paints something.
|
|
9
|
+
//
|
|
10
|
+
// ⚠️ Stripping comments needs to know what a comment is. `//` inside a string is a URL, not a
|
|
11
|
+
// comment, and getting that wrong would blind the check to real code — the failure mode this file
|
|
12
|
+
// exists to avoid. Hence the small scanner rather than a regex over the raw text.
|
|
13
|
+
|
|
14
|
+
import { readdir, readFile } from "node:fs/promises";
|
|
15
|
+
import { join, relative } from "node:path";
|
|
16
|
+
import process from "node:process";
|
|
17
|
+
|
|
18
|
+
const ROOT = process.argv[2] ?? "src";
|
|
19
|
+
|
|
20
|
+
// Exactly the patterns the shell version used.
|
|
21
|
+
const FORBIDDEN = [
|
|
22
|
+
{ name: "hex colour", pattern: /#[0-9a-fA-F]{3,8}\b/ },
|
|
23
|
+
{
|
|
24
|
+
name: "palette class",
|
|
25
|
+
pattern:
|
|
26
|
+
/\b(bg|text|border|ring|shadow|fill|stroke)-(white|black|slate|gray|zinc|neutral|stone|red|orange|amber|yellow|lime|green|emerald|teal|cyan|sky|blue|indigo|violet|purple|fuchsia|pink|rose)(-\d{2,3})?\b/,
|
|
27
|
+
},
|
|
28
|
+
];
|
|
29
|
+
|
|
30
|
+
// Test files may spell anything out — they are where a rule gets stated, including by counter
|
|
31
|
+
// example. Same exclusion the shell version carried.
|
|
32
|
+
const SKIP_FILE = /\.unit\.tsx?$/;
|
|
33
|
+
const CHECK_FILE = /\.(tsx?|css)$/;
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* The file with its comments blanked out, line structure intact so line numbers still mean
|
|
37
|
+
* something. Strings keep their contents: a hex colour in a string is exactly what must be caught.
|
|
38
|
+
*/
|
|
39
|
+
function withoutComments(source, isCss) {
|
|
40
|
+
let out = "";
|
|
41
|
+
let i = 0;
|
|
42
|
+
// "code" | "line" | "block" | quote character for a string
|
|
43
|
+
let state = "code";
|
|
44
|
+
while (i < source.length) {
|
|
45
|
+
const char = source[i];
|
|
46
|
+
const next = source[i + 1];
|
|
47
|
+
if (state === "code") {
|
|
48
|
+
// A regex literal would be the third thing that can hold a `/`, but none in this package
|
|
49
|
+
// contains `//` or `/*`, and treating one as a comment would only ever blind the check to
|
|
50
|
+
// something inside a regex — never let a colour through.
|
|
51
|
+
if (!isCss && char === "/" && next === "/") {
|
|
52
|
+
state = "line";
|
|
53
|
+
out += " ";
|
|
54
|
+
i += 2;
|
|
55
|
+
continue;
|
|
56
|
+
}
|
|
57
|
+
if (char === "/" && next === "*") {
|
|
58
|
+
state = "block";
|
|
59
|
+
out += " ";
|
|
60
|
+
i += 2;
|
|
61
|
+
continue;
|
|
62
|
+
}
|
|
63
|
+
if (char === '"' || char === "'" || char === "`") {
|
|
64
|
+
state = char;
|
|
65
|
+
out += char;
|
|
66
|
+
i += 1;
|
|
67
|
+
continue;
|
|
68
|
+
}
|
|
69
|
+
out += char;
|
|
70
|
+
i += 1;
|
|
71
|
+
continue;
|
|
72
|
+
}
|
|
73
|
+
if (state === "line") {
|
|
74
|
+
if (char === "\n") {
|
|
75
|
+
state = "code";
|
|
76
|
+
out += char;
|
|
77
|
+
} else {
|
|
78
|
+
out += " ";
|
|
79
|
+
}
|
|
80
|
+
i += 1;
|
|
81
|
+
continue;
|
|
82
|
+
}
|
|
83
|
+
if (state === "block") {
|
|
84
|
+
if (char === "*" && next === "/") {
|
|
85
|
+
state = "code";
|
|
86
|
+
out += " ";
|
|
87
|
+
i += 2;
|
|
88
|
+
continue;
|
|
89
|
+
}
|
|
90
|
+
out += char === "\n" ? char : " ";
|
|
91
|
+
i += 1;
|
|
92
|
+
continue;
|
|
93
|
+
}
|
|
94
|
+
// Inside a string: kept as it stands, escapes skipped so `\"` does not end it early.
|
|
95
|
+
if (char === "\\") {
|
|
96
|
+
out += source.slice(i, i + 2);
|
|
97
|
+
i += 2;
|
|
98
|
+
continue;
|
|
99
|
+
}
|
|
100
|
+
if (char === state) state = "code";
|
|
101
|
+
out += char;
|
|
102
|
+
i += 1;
|
|
103
|
+
}
|
|
104
|
+
return out;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
/**
|
|
108
|
+
* The checker checked, on every run.
|
|
109
|
+
*
|
|
110
|
+
* ⚠️ This is here because of how the shell version could have failed: a pattern that matches
|
|
111
|
+
* nothing, or an exclusion that swallows the whole tree, reports success. `Checked 0 files` and
|
|
112
|
+
* `checked everything, all clean` look identical from the outside, and the second one is what
|
|
113
|
+
* everybody reads. Stating the cases the check exists for — and the ones it must stay quiet about —
|
|
114
|
+
* means a rule that stops working says so instead of going green.
|
|
115
|
+
*/
|
|
116
|
+
function selfTest() {
|
|
117
|
+
const mustCatch = [
|
|
118
|
+
['const c = "#fff";', "a three-digit hex in a string"],
|
|
119
|
+
['const c = "#a1b2c3";', "a six-digit hex"],
|
|
120
|
+
['const c = "#11223344";', "an eight-digit hex with alpha"],
|
|
121
|
+
[" color: #fff;", "a hex in CSS"],
|
|
122
|
+
['<div className="bg-red-500" />', "a palette class"],
|
|
123
|
+
['<div className="text-white" />', "a palette colour without a number"],
|
|
124
|
+
];
|
|
125
|
+
const mustAllow = [
|
|
126
|
+
["// the folder table, since (#101)", "a ticket number in a line comment"],
|
|
127
|
+
["/* archived like a document (#109) */", "a ticket number in a block comment"],
|
|
128
|
+
["{/* two lists say what they show (#99) */}", "a ticket number in a JSX comment"],
|
|
129
|
+
['<div className="bg-background text-muted-foreground" />', "semantic tokens"],
|
|
130
|
+
];
|
|
131
|
+
// ⚠️ Not in either list, and deliberately: a URL fragment that happens to read like a colour —
|
|
132
|
+
// `https://example.com/#fff` — is still reported. The grep did the same, so nothing regressed
|
|
133
|
+
// here, and the one way to stop it would be to make the colour pattern narrower. That trade goes
|
|
134
|
+
// the wrong way: a false alarm costs one rewritten line, a missed colour costs the rule. The
|
|
135
|
+
// first attempt at this file listed it as "must allow" and this check refused it, which is the
|
|
136
|
+
// check doing its job.
|
|
137
|
+
const failures = [];
|
|
138
|
+
for (const [line, what] of mustCatch) {
|
|
139
|
+
const code = withoutComments(line, line.startsWith(" color:"));
|
|
140
|
+
if (!FORBIDDEN.some(({ pattern }) => pattern.test(code))) {
|
|
141
|
+
failures.push(`stopped catching ${what}: ${line}`);
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
for (const [line, what] of mustAllow) {
|
|
145
|
+
const code = withoutComments(line, false);
|
|
146
|
+
if (FORBIDDEN.some(({ pattern }) => pattern.test(code))) {
|
|
147
|
+
failures.push(`started refusing ${what}: ${line}`);
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
if (failures.length > 0) {
|
|
151
|
+
console.error("The token check is no longer checking what it is for:\n");
|
|
152
|
+
for (const failure of failures) console.error(` ${failure}`);
|
|
153
|
+
process.exit(1);
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
async function* files(dir) {
|
|
158
|
+
for (const entry of await readdir(dir, { withFileTypes: true })) {
|
|
159
|
+
const path = join(dir, entry.name);
|
|
160
|
+
if (entry.isDirectory()) yield* files(path);
|
|
161
|
+
else if (CHECK_FILE.test(entry.name) && !SKIP_FILE.test(entry.name)) yield path;
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
selfTest();
|
|
166
|
+
|
|
167
|
+
const findings = [];
|
|
168
|
+
for await (const path of files(ROOT)) {
|
|
169
|
+
const source = await readFile(path, "utf8");
|
|
170
|
+
const code = withoutComments(source, path.endsWith(".css"));
|
|
171
|
+
code.split("\n").forEach((line, index) => {
|
|
172
|
+
for (const { name, pattern } of FORBIDDEN) {
|
|
173
|
+
const hit = pattern.exec(line);
|
|
174
|
+
if (hit) findings.push(`${relative(".", path)}:${index + 1} ${name} ${hit[0]}`);
|
|
175
|
+
}
|
|
176
|
+
});
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
if (findings.length > 0) {
|
|
180
|
+
console.error(
|
|
181
|
+
`Use semantic tokens instead. ${findings.length} hard-coded value${findings.length === 1 ? "" : "s"}:\n`,
|
|
182
|
+
);
|
|
183
|
+
for (const finding of findings) console.error(` ${finding}`);
|
|
184
|
+
console.error("\nA ticket reference in a comment is fine — comments are not checked.");
|
|
185
|
+
process.exit(1);
|
|
186
|
+
}
|
|
187
|
+
console.log(`No hard-coded colours or palette classes in ${ROOT}.`);
|