Download web/src/customer-grid/AppFrame.tsx from fsanyoto/loopable: direct link, hf CLI and curl.
- Browser
- Download file 817 Bytes
-
https://huggingface.co/spaces/fsanyoto/loopable/resolve/main/web/src/customer-grid/AppFrame.tsx
- Command line
-
hf download hf://spaces/fsanyoto/loopable/web/src/customer-grid/AppFrame.tsx
-
curl -L -o AppFrame.tsx https://huggingface.co/spaces/fsanyoto/loopable/resolve/main/web/src/customer-grid/AppFrame.tsx
817 Bytes
| import type { ReactNode } from "react"; | |
| import "../styles/sdlc76/app-frame.css"; | |
| interface AppFrameProps { | |
| appName: string; | |
| actions?: ReactNode; | |
| rail?: ReactNode; | |
| children?: ReactNode; | |
| } | |
| export function AppFrame({ appName, actions, rail, children }: AppFrameProps) { | |
| const header = <header className="cg-map-bar cg-app-frame-header"> | |
| {rail ? null : <a className="cg-app-frame-back" href="#/app">Back to Apps</a>} | |
| <span className="cg-app-map-name cg-app-frame-name" title={appName} aria-label="App name"> | |
| <strong>{appName}</strong> | |
| </span> | |
| {actions} | |
| </header>; | |
| // With a rail, the header and body share one column beside it, and the rail carries the Back. | |
| return rail | |
| ? <>{rail}<div className="cg-app-frame-main">{header}{children}</div></> | |
| : <>{header}{children}</>; | |
| } | |