[eric] apps: the full tool-ui widget set is vendored into every app workspace behind an @toolui alias, deps exact-pinned to the host's locked versions

This commit is contained in:
ciregenz
2026-08-08 01:22:43 -07:00
parent 610ba00a9d
commit a12047ae66
225 changed files with 25736 additions and 2 deletions
+22
View File
@@ -0,0 +1,22 @@
#!/usr/bin/env bash
# Vendors the tool-ui component system into the app template (ENG-203).
# frontend/src/toolui is the single source of truth; the copy under
# webapp_template is GENERATED — never hand-edit it, rerun this instead.
set -euo pipefail
ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
SRC="$ROOT/frontend/src/toolui"
DST="$ROOT/backend/apps/outputs/webapp_template/frontend/src/toolui"
rm -rf "$DST"
mkdir -p "$DST"
# node_modules never exists inside src/toolui, so a straight copy is fine.
cp -R "$SRC/" "$DST/"
cat > "$DST/GENERATED.md" <<'EOF'
This directory is a GENERATED copy of OpenSwarm's `frontend/src/toolui`
(vendored per app template so generated apps can use the tool-ui components).
Do not hand-edit; run `scripts/sync-toolui-template.sh` from the OpenSwarm
repo root to refresh it.
EOF
echo "Synced $(find "$DST" -type f | wc -l | tr -d ' ') files into the template."