diff --git a/docs/03-contributing.md b/docs/03-contributing.md index dcffe706..06a4c787 100644 --- a/docs/03-contributing.md +++ b/docs/03-contributing.md @@ -23,9 +23,26 @@ Follow these steps to set up your development environment and gain access to all * Install Enpass (our team's shared password manager). * Ensure you have access to the shared KROW vault for all project credentials (API keys, service accounts, etc.). -5. **Install Recommended Development Tools:** - * **IDE:** We recommend **VS Code** or **Vim/Neovim** for development. - * **Diagramming:** Use **MermaidChart.com** for creating and editing diagrams (Mermaid syntax). +5. **Install Required Development Tools:** + + Before running the project, ensure you have the following installed: + + * **Node.js (v20+):** We recommend using **[nvm](https://github.com/nvm-sh/nvm)** (Node Version Manager) to install and manage Node versions. + * **pnpm:** Our preferred package manager for JavaScript projects. (`npm install -g pnpm`) + * **Flutter Version Management (FVM):** We use **[FVM](https://fvm.app/)** to manage Flutter SDK versions per project. Install it via Homebrew (`brew install fvm`) or Dart (`dart pub global activate fvm`). + * **Firebase CLI:** Required for emulation and deployment. (`npm install -g firebase-tools`) + * **Google Cloud CLI (gcloud):** Required for backend authentication and resource management. + + **Recommended IDE:** + * **[Google Project IDX (Antigravity)](https://idx.google.com/)** or **VS Code**. + * **Essential Extensions:** + * Flutter & Dart + * Firebase + * Tailwind CSS IntelliSense + * ESLint & Prettier + + **Diagramming:** + * Use **MermaidChart.com** for creating and editing diagrams (Mermaid syntax). 6. **Local Development Environment Setup:** * Clone the monorepo: `git clone git@github.com:Oloodi/krow-workforce.git` diff --git a/internal/launchpad/assets/js/links-loader.js b/internal/launchpad/assets/js/links-loader.js index 9bca36f7..47f20edf 100644 --- a/internal/launchpad/assets/js/links-loader.js +++ b/internal/launchpad/assets/js/links-loader.js @@ -46,8 +46,13 @@ async function loadLinks() {
- ${group.links.map(link => ` - { + const isPrototype = link.url.startsWith('/prototypes/'); + const hrefAttr = isPrototype ? 'href="#"' : `href="${link.url}" target="_blank"`; + const onclickAttr = isPrototype ? `onclick="event.preventDefault(); showView('iframe', this, '${link.url}', '${link.title}')"` : ''; + + return ` +
${link.iconClass ? `
` : link.iconSvg} @@ -69,7 +74,7 @@ async function loadLinks() { ` : ''}
- `).join('')} + `}).join('')}
`).join(''); diff --git a/internal/launchpad/index.html b/internal/launchpad/index.html index 472f97d7..55c7fb9e 100644 --- a/internal/launchpad/index.html +++ b/internal/launchpad/index.html @@ -310,6 +310,22 @@ + + + @@ -454,6 +470,13 @@ const documentViewer = document.getElementById('document-viewer'); const documentContainer = document.getElementById('document-container'); const documentTitle = document.getElementById('document-title'); + + // Iframe Elements + const iframeViewer = document.getElementById('iframe-viewer'); + const iframeContent = document.getElementById('content-iframe'); + const iframeTitle = document.getElementById('iframe-title'); + const iframeExternalLink = document.getElementById('iframe-external-link'); + const zoomInBtn = document.getElementById('zoomInBtn'); const zoomOutBtn = document.getElementById('zoomOutBtn'); const resetBtn = document.getElementById('resetBtn'); @@ -681,16 +704,30 @@ } diagramContainer.innerHTML = ''; documentContainer.innerHTML = ''; + // Reset iframe + iframeContent.src = 'about:blank'; currentScale = 1; if (viewName === 'home') { homeView.classList.remove('hidden'); diagramViewer.classList.add('hidden'); documentViewer.classList.add('hidden'); + iframeViewer.classList.add('hidden'); + } else if (viewName === 'iframe') { + // New Iframe View + homeView.classList.add('hidden'); + diagramViewer.classList.add('hidden'); + documentViewer.classList.add('hidden'); + iframeViewer.classList.remove('hidden'); + + iframeTitle.textContent = title; + iframeExternalLink.href = filePath; + iframeContent.src = filePath; } else if (viewName === 'diagram') { homeView.classList.add('hidden'); diagramViewer.classList.remove('hidden'); documentViewer.classList.add('hidden'); + iframeViewer.classList.add('hidden'); diagramTitle.textContent = title; diagramContainer.innerHTML = `
@@ -766,6 +803,7 @@ homeView.classList.add('hidden'); diagramViewer.classList.add('hidden'); documentViewer.classList.remove('hidden'); + iframeViewer.classList.add('hidden'); documentTitle.textContent = title; documentContainer.innerHTML = `