Logo
Animated SVG logo component that transitions between "SD" and "$D" every 4 seconds, synchronized with the SmartDebt component animation. The logo automatically adapts to the current theme (light/dark) and uses the theme's primary brand color.
Light Background
Primary color background with white text. The gold accent dot stays secondary color. Animation cycles S ↔ $D.
<BrandLogo brand="sd" variant="leafDot" animate /> Dark Background
Inverted colors: white leaf, primary color text. The gold accent dot stays secondary.
<BrandLogo brand="sd" variant="leafDot" animate dark /> Favicon
SD leaf-dot logo variant optimized for browser tabs and bookmarks. Static display for professional appearance.
Light Background
Dark Background
Props
| Prop | Type | Default | Description |
|---|---|---|---|
brand | "sd" | "ts" | "sd" | Brand to display (SmartDebt or Talbot Stevens) |
variant | "leafDot" | "leafSquare" | "leafRect" | "circle" | "leafDot" | Logo shape variant |
dark | boolean | false | Invert colors for dark backgrounds (white bg, primary text) |
animate | boolean | false | Enable S ↔ $D animation (SD logos only) |
class | string | "" | Additional CSS classes |
Talbot Stevens Assets
Brand assets for Talbot Stevens personal brand sites.
Header Variants
Customized headers with "Talbot Stevens" branding. The header component supports optional tagline and background color customization.
With Tagline
Without Tagline
TS Logo (Light)
Blue circle with white "TS" text. Uses TS brand blue color.
<BrandLogo brand="ts" /> TS Logo (Dark)
Inverted: white circle with blue "TS" text.
<BrandLogo brand="ts" dark /> Favicon
Blue circle with white "TS" text. Matches the TS logo design.
Light Background
Dark Background
$MART DEBT Entity
Branded text component where "SMART DEBT" animates with S ⟷ $ transformation. All instances cycle together every 4 seconds. SEO-preserved the HTML always contains "SMART DEBT" plus optional entity text.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
entity | string | undefined | Optional entity text appended after "SMART DEBT" (e.g., "Coach", "Strategies", "Mission") |
delay | number | random 0-4000ms | Delay in milliseconds before starting the animation cycle (0-4000ms). If not provided, each instance gets a random delay between 0-4000ms so they start at different times. |
Usage
import SmartDebt from "../components/brand/SmartDebt.astro";
<SmartDebt /> // "SMART DEBT" (random delay 0-4000ms)
<SmartDebt entity="Coach" /> // "SMART DEBT Coach" (random delay)
<SmartDebt entity="Strategies" /> // "SMART DEBT Strategies" (random delay)
<SmartDebt delay={2000} /> // "SMART DEBT" (starts after 2 seconds)
<SmartDebt entity="Plan" delay={0} /> // "SMART DEBT Plan" (starts immediately)
💡 Unique Implementation: This component uses a vanilla JavaScript Web Component
(smart-debt-element), not Astro or Alpine.js. It's a custom element that
provides framework-agnostic functionality with SEO preservation and accessibility features.
SMART DEBT Plan
Client-first
-
SMART DEBT Coach website SMART DEBT App (mini-app)- White paper: mission, win-win-win future
SMART DEBT Myths eBooklet-
SMART DEBT Insights (blog, video, audio) -
SMART DEBT Academy (Certification courses) - Education and Marketing solutions
-
SMART DEBT Coaching (training, speaking, consulting) -
SMART DEBT Wealth (investment and credit products)
More ...
Versatile "More ..." link functionality that adapts to three different modes: Manual Inline (hides text inside paragraph), Auto-Block (truncates content by height), and Simple Link (standard anchor).
Props
| Prop | Type | Default | Description |
|---|---|---|---|
href | string | undefined | If provided, component renders as a standard <a> link. Example: href="/about" |
lines | number | undefined | If provided, truncates the wrapped content to this number of lines (approximate)
using max-height. Example: lines={3} (note the curly
braces for number values) |
label | string | "More ..." | The text for the link or button when collapsed. |
labelExpanded | string | "Less" | The text for the button when expanded (Inline/Block modes only). |
1. Manual Inline Mode
Use Case: You have a paragraph where you want some initial content visible, and the rest hidden until the user clicks the More... link
This is a very long paragraph, that is truncated here,
<p>
This is a very long paragraph, that is truncated here,
<More>
so that only viewers who want to see all of the content...
</More>
</p>
2. Auto-Block Mode
Use Case: You have a long section (like a bio or a list) and you want to cap it at a specific height (e.g., 3 lines) with a fade-out effect.
Author Bio (Default Label)
Jane Doe is a senior engineer with over 20 years of experience. She has contributed to major open source projects and speaks at conferences worldwide regarding distributed systems architecture.
She currently lives in Toronto with her two cats.
Author Bio (Custom Label)
Jane Doe is a senior engineer with over 20 years of experience. She has contributed to major open source projects and speaks at conferences worldwide regarding distributed systems architecture.
She currently lives in Toronto with her two cats.
<More lines={3}>
<p>Jane Doe is a senior engineer...</p>
</More>
<More lines={3} label="Full bio" labelExpanded="Close bio">
<p>Jane Doe is a senior engineer...</p>
</More>
3. Simple Link Mode
Use Case: A standard link styled consistently with the expanders.
Interested in learning more about our company? More ...
<p>
Interested in learning more about our company?
<More href="/about" />
</p>
Video
Responsive video component supporting native HTML5 video, YouTube embeds, and Vimeo embeds with Schema.org VideoObject markup for SEO.
YouTube Embed
Different Aspect Ratios
Usage Notes
- YouTube: Use
youtubeId="VIDEO_ID"for privacy-enhanced embeds (youtube-nocookie.com) - Vimeo: Use
vimeoId="VIDEO_ID"for Vimeo embeds - Native: Use
src="VIDEO_URL"for self-hosted HTML5 video - Schema.org: Set
showSchema={true}to include VideoObject markup for SEO - Aspect ratio options:
"16/9","4/3","1/1"
Typewriter
Animated typewriter effect that cycles through text character by character. Integrates seamlessly with SmartDebt branding and inherits all typography from parent element.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
dynamicText | string[] | ["one", "two", "three"] | Array of strings to cycle through with typewriter effect |
typingDelay | number | 100 | Delay in ms between typing each character. Example: typingDelay={150} |
deletingDelay | number | 50 | Delay in ms between deleting each character (faster than typing) |
dynamicTextDuration | number | 2000 | How long to display complete text before starting to delete |
pauseBeforeNext | number | 500 | Pause after deleting before typing next string |
cursorChar | string | "|" | Character to use for blinking cursor |
showCursor | boolean | true | Whether to show the blinking cursor |
dynamicTextClass | string | undefined | CSS class(es) to apply to the dynamic text element. Use this to style the typed text
(e.g.,
dynamicTextClass="smart-debt-entity" to match SmartDebt entity styling) |
1. SmartDebt Entities
Showcase all $MART DEBT entities with typewriter effect. The S→$ animation runs independently while entity names cycle. Cursor is hidden for a cleaner look.
SMART DEBT
<h1>
<Typewriter
dynamicText={["Coach", "Insights", "Strategies", "Community", "Myths", "App", "Academy"]}
typingDelay={100}
dynamicTextDuration={2000}
dynamicTextClass="smart-debt-entity"
showCursor={false}
>
<SmartDebt delay={0} />
</Typewriter>
</h1>
2. Hero Title
Use in hero sections with static initial text and dynamic phrases.
Build wealth with
<h1>
Build wealth with
<Typewriter
dynamicText={["smart strategies", "proven methods", "expert guidance"]}
/>
</h1>
Tabs
Simple tabs component using Alpine state. Keyboard and ARIA friendly.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
items | Array of objects | [] | Array of tab items: {id: string, label: string, content: string} |
Accordion
Accessible accordion with smooth transitions. Single or multiple open.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
items | Array of objects | [] | Array of accordion items: {id: string, title: string, content: string} |
Buttons
Versatile button component with 6 variants and 4 sizes for different use cases.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
variant | "default" | "secondary" | "outline" | "ghost" | "destructive" | "link" | "default" | Visual style variant of the button |
size | "sm" | "default" | "lg" | "icon" | "default" | Size of the button |
disabled | boolean | false | Whether the button is disabled |
class | string | "" | Additional CSS classes |
Variants
Sizes
States
MegaMenu
Multi-column dropdown navigation with AlpineJS interactions. Hover or click to open, press Escape to close. Hidden on mobile (use hamburger menu instead).
Usage Notes
- Desktop: Hover to open, click to toggle, Escape to close, click outside to close
- Mobile: Hidden below 768px width (use hamburger menu instead)
- Keyboard: Tab to navigate items, Enter to select, Escape to close
- Columns: Auto-fit grid with minimum 200px per column
- Featured Item: Optional highlighted item with badge support
Search
Full-featured site search powered by Pagefind. Opens in a modal dialog with keyboard shortcuts (Ctrl+K/Cmd+K), search result highlighting, and full dark mode support. Automatically indexes all static and markdown/MDX pages during build.
🔍 Technology: This component uses Pagefind , a client-side search library for static sites. Pagefind provides fast, typo-tolerant search with result highlighting, automatic indexing during build, and zero runtime dependencies. The search modal is fully accessible with ARIA labels, keyboard navigation, and focus management.
Interactive Demo
Features
- Keyboard shortcut: Ctrl+K / Cmd+K
- Press Esc to close the search modal
- Search result highlighting on selected pages
- Full dark mode support
- Fully accessible with ARIA labels
- Automatic indexing of all static and markdown/MDX pages
- Typo-tolerant search with fuzzy matching
- Zero runtime dependencies (client-side only)
Layout Components
Structural components for organizing page content and controlling responsive behavior.
Container
Controls maximum width and centers content. Available in "text" (25-100rem), "content" (20-90rem), and "full" sizes.
Section
Adds vertical spacing between content areas. Supports 9 spacing levels from "xs" to "5xl" using fluid design tokens.
Grid
Responsive CSS Grid system that collapses to 1 column on mobile. Supports 1-12 columns with 4 gap sizes.
Cards
Container components with consistent styling for grouping related content.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
style | "none" | "header" | "none" | Card style variant. "header" adds a colored header section with white text (primary color background) |
backgroundColor | string | undefined | Custom background color (e.g., "#ececec"). Defaults to "#ececec" when style="header" |
class | string | "" | Additional CSS classes |
Usage
import Card from "../components/ui/Card.astro";
// Default card
<Card>Content</Card>
// Header style with default background
<Card style="header">
<h2 slot="title">Title</h2>
Content
</Card>
// Header style with custom background
<Card style="header" backgroundColor="#f0f0f0">
<h2 slot="title">Title</h2>
Content
</Card>
Card Example 1
Simple card for organizing content with consistent styling and shadow.
Card Example 2
Cards automatically adapt to grid layouts and work at all breakpoints.
Card Example 3
Perfect for product listings, testimonials, or feature highlights.
Badges
Small labels for tagging and categorizing content with multiple style variants.
Alerts
Inline notification messages for contextual feedback. For page-level notifications with positioning, use Banner component.
✓ Success: Your changes have been saved successfully.
✕ Error: Unable to process your request. Please try again.
Note: For page-level notifications with fixed positioning (top/bottom), use the Banner component instead.
Form Components
Complete form components for creating accessible and functional input forms.
Labels
Accessible form labels properly associated with inputs.
Separators
Visual dividers for separating content sections.
Content before
Content after
Interactive Components
Components for user interaction and control.
Dropdown Menu
Customizable dropdown menu with positioning options.
Switch Toggle
Accessible toggle switches for boolean settings.
Feedback & Notifications
Components for communicating with users through banners, modals, and alerts.
Banner
Sticky banners positioned above or below header. All dismissible.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
variant | "info" | "warning" | "success" | "alert" | "highlight" | "highlight" | Visual style variant of the banner |
position | "above-header" | "below-header" | "below-header" | Position of the banner relative to the header |
dismissible | boolean | true | Whether the banner can be dismissed by the user |
id | string | auto-generated | Unique ID for the banner (used for localStorage persistence) |
class | string | "" | Additional CSS classes |
Variants
All banner variants can be positioned above or below the header:
-
info- Informational (blue/primary color) -
warning- Warning (orange/warning color) success- Success (green)-
alert- Alert/error (red/destructive) -
highlight- Special offer/highlight (accent color)
Page-Level Demo Banners:
Test Above Header:
Test Below Header:
Modal
Overlayed dialog box with close and action buttons. Test different delay variants.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
title | string | "Modal" | Modal title/heading text |
delay | number | 5000 | Delay in milliseconds before showing the modal (default: 5 seconds) |
dismissible | boolean | true | Whether the modal can be closed by the user |
backdrop | boolean | true | Whether to show the backdrop overlay |
size | "sm" | "md" | "lg" | "md" | Size of the modal dialog |
id | string | auto-generated | Unique ID for the modal (used for programmatic control) |
class | string | "" | Additional CSS classes |
Manual Triggers:
Instant Modal
Announcement (2 sec delay)
Special Notice (5 sec delay)
Supporting Components
Navigation, gallery, and comparison components for enhanced user experience.
Breadcrumbs
Navigation breadcrumb trail with Schema.org BreadcrumbList markup. Shows hierarchical page location with semantic HTML.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
crumbs | Crumb[] | - | Array of breadcrumb items |
showSchema | boolean | true | Include Schema.org markup |
separator | string | "/" | Separator character |
class | string | "" | Additional CSS classes |
Pagination
Page navigation with ellipsis for large page ranges. Includes first/last and prev/next buttons with ARIA labels.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
currentPage | number | - | Current page (1-indexed) |
totalPages | number | - | Total number of pages |
baseUrl | string | - | Base URL for links |
showFirstLast | boolean | true | Show first/last buttons |
showPrevNext | boolean | true | Show prev/next buttons |
maxVisible | number | 7 | Max visible page numbers |
Image Gallery
Responsive image grid with optional lightbox modal. Click images to view fullsize. Keyboard navigation with arrow keys and Escape.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
images | GalleryImage[] | - | Array of image objects |
columns | 2 | 3 | 4 | 3 | Number of columns |
lightbox | boolean | true | Enable lightbox modal |
class | string | "" | Additional CSS classes |
Productive workspace setup
Creative inspiration
Peaceful nature scene
Morning motivation
Working together
Digital transformation
Comparison Table
Feature comparison table for pricing tiers. Responsive with sticky header and fixed first column for horizontal scrolling.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
title | string | - | Optional table title |
features | Feature[] | - | Array of features |
highlightColumn | "basic" | "pro" | "enterprise" | - | Column to highlight |
class | string | "" | Additional CSS classes |
Pricing Plans Comparison
| Feature | Basic | Pro Recommended | Enterprise |
|---|---|---|---|
| Users | 1-5 | 1-25 | Unlimited |
| Storage | 10 GB | 100 GB | 1 TB |
| Email Support | ✓ | ✓ | ✓ |
| Priority Support | ✗ | ✓ | ✓ |
| Custom Integrations | ✗ | ✗ | ✓ |
| Advanced Analytics | ✗ | ✓ | ✓ |
| API Access | ✗ | ✓ | ✓ |
| SSO/SAML | ✗ | ✗ | ✓ |
| Dedicated Account Manager | ✗ | ✗ | ✓ |
| SLA Guarantee | ✗ | 99.5% | 99.9% |
Mini-Apps
Standalone SvelteKit apps, embeddable anywhere via a single <iframe> tag.
Architecture
- Mini-apps live in
apps/— each is a standalone SvelteKit PWA deployed independently to Cloudflare Pages - Client-side apps (e.g. gross-up): pure Svelte 5 logic, no backend, deployed as static SPA
- Proprietary apps (future): SvelteKit frontend + private API backend — backend is invisible to the embedder
- Embed pattern: one
<iframe>tag — works on any website, blog, or third-party page
Live Demo — RRSP Gross-Up Calculator:
Embed Code:
<!-- Client-side mini-app (no backend required) -->
<iframe
src="https://sd-app-eu1.pages.dev/ca/en/gross-up?embed"
title="RRSP Gross-Up Calculator"
width="100%" height="400"
style="border:none; border-radius:0.5rem;"
loading="lazy"
></iframe>
<!-- Proprietary mini-app (backend called internally) -->
<iframe
src="https://analysis.smartdebt.ca/equity-report"
title="Equity Analysis"
width="100%" height="700"
style="border:none; border-radius:0.5rem;"
loading="lazy"
></iframe>