@dreamtree-org/landing-kit 0.2.0 → 0.2.1
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 +38 -6
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
# @dreamtree-org/landing-kit
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
sections, "Book a demo" dialog, SEO files, Express routes and prerender) with one content-driven
|
|
5
|
-
package that looks like the same family as the `@dreamtree-org/auth-kit` login screens.
|
|
3
|
+
The shared marketing landing pages **and** authentication frame (`<AuthShell>`, `brands`, `getBrand`) for every Dreamtree product: replaces the landing setup copied across billpro, taskpro and venturepro (page chrome, sections, "Book a demo" dialog, SEO files, Express routes and prerender) and the login/signup/reset/platform-admin frame in one package.
|
|
6
4
|
|
|
7
|
-
-
|
|
8
|
-
-
|
|
9
|
-
-
|
|
5
|
+
- Two facades sharing one brand registry (`brands` / `getBrand(id)`):
|
|
6
|
+
- `<LandingPage brand={getBrand('billpro')} content={content} />` — a product's landing page is a content file.
|
|
7
|
+
- `<AuthShell brand={getBrand('billpro')} title="Welcome back">…</AuthShell>` (also available at `@dreamtree-org/landing-kit/auth` + `@dreamtree-org/landing-kit/auth.css`).
|
|
8
|
+
- Plain CSS (`--dt-*` custom properties). It looks the same under Tailwind 3, Tailwind 4 (preflight or not) or no Tailwind. Dark mode via `[data-theme="dark"]` or `.dark`.
|
|
10
9
|
- Built for prerendered, **un-hydrated** pages (fast and crawlable): `enhanceLanding()` wires the menu and the demo button in a few hundred bytes. It also works hydrated in an SPA or Next.js (`'use client'`, `onBookDemo`, `linkComponent`).
|
|
11
10
|
- Responsive from 320px up. The nav folds into a menu below 1024px. Checked with Playwright at 320/375/768/1024/1440, light and dark.
|
|
12
11
|
|
|
@@ -93,6 +92,39 @@ Then prerender it and serve it (Express recipe below), or render it in your SPA
|
|
|
93
92
|
| `createDemoIsland(props)` | mounts `DemoDialog` on demand for un-hydrated pages; returns `{ openDemo }` |
|
|
94
93
|
| `BookDemoButton`, `BrandLockup`, `Section`, `SectionIntro`, `TextLink`, `SmartLink` | building blocks |
|
|
95
94
|
|
|
95
|
+
### `<AuthShell>` & `@dreamtree-org/landing-kit/auth`
|
|
96
|
+
|
|
97
|
+
The shared auth frame for login, signup, password reset, consent and platform-admin sign-in (`desktop [ brand panel 40% | form card ]`, `mobile [ logo · form card · footer · legal links ]`). Import from `@dreamtree-org/landing-kit` or the lightweight `@dreamtree-org/landing-kit/auth` subpath (with `@dreamtree-org/landing-kit/auth.css` or `styles.css`).
|
|
98
|
+
|
|
99
|
+
```jsx
|
|
100
|
+
import { AuthShell, getBrand } from '@dreamtree-org/landing-kit/auth';
|
|
101
|
+
import '@dreamtree-org/landing-kit/auth.css';
|
|
102
|
+
|
|
103
|
+
export default function Login() {
|
|
104
|
+
return (
|
|
105
|
+
<AuthShell
|
|
106
|
+
brand={getBrand('venturepro')}
|
|
107
|
+
linkComponent={Link}
|
|
108
|
+
title="Welcome back"
|
|
109
|
+
subtitle="Sign in to manage your ventures and units."
|
|
110
|
+
footer={<>New here? <Link to="/register">Register now</Link></>}
|
|
111
|
+
>
|
|
112
|
+
{/* your form */}
|
|
113
|
+
</AuthShell>
|
|
114
|
+
);
|
|
115
|
+
}
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
| Prop | Type | Default | Meaning |
|
|
119
|
+
|---|---|---|---|
|
|
120
|
+
| `brand` | `Brand` | required | from `getBrand(id)` (`billpro`, `taskpro`, `venturepro`, `campaignpro`, `firepro`, `procurementpro`, `fitweavepro`, `aiagentbuilder`, `runloompro`, `appforge`) or your own object |
|
|
121
|
+
| `title` | node | required | card heading |
|
|
122
|
+
| `subtitle` | node | | under the heading |
|
|
123
|
+
| `footer` | node | | below the card (e.g. "Register now") |
|
|
124
|
+
| `variant` | `'tenant' \| 'platform'` | `'tenant'` | `'platform'` renders a darker panel + `"Platform"` badge |
|
|
125
|
+
| `legalLinks` | `{label, href}[]` | Privacy, Terms, Data Policy | `[]` hides them |
|
|
126
|
+
| `linkComponent` | component | `<a>` | receives both `to` and `href` |
|
|
127
|
+
|
|
96
128
|
### `@dreamtree-org/landing-kit/enhance`
|
|
97
129
|
|
|
98
130
|
`enhanceLanding(root = document, { openDemo | loadDemo, warmDemo, hash = '#book-demo' })`: wires
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dreamtree-org/landing-kit",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.1",
|
|
4
4
|
"description": "The shared marketing site and auth frame (AuthShell + brands) for every Dreamtree product: content-driven landing pages, login/signup shell, Express routes, prerender and SEO files.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|