Semono design system — Astro
Content-free building blocks of the Semono template, mirrored from the Framer components and from the design system of the
Next.js version: the same component names, props and Tailwind classes, so both versions render the same DOM. Components never
import src/content — sections pass data in through props. Import a component by its path
(import Button from "../design-system/components/actions/Button.astro"); there is no barrel. See them all together at
/style-guide: public, noindex, not in the sitemap and not linked from the site.
Conventions
Section titled “Conventions”- Tokens, not raw values.
text.h2,bg-ink,text-soft,spring— never a hex or a font size typed into a component, and a value used twice becomes a token. Keep class names standard (bg-<color>,md:,lg:). Phone is the default;mdis 810 andlg1200. - No content imports. A component takes its data through props; sections map content with
src/lib/to-ui.ts. No copy lives in a component (the only strings are the form’s fallbacks: “Submit”, “Thank you”, “Something went wrong”). cnonly joins class names. It does not merge Tailwind classes: two classes for the same property and variant are decided by their order in the generated CSS, not by the call. Where a default has to change it is a prop that takes a whole class string (Sectionpaddingandgap,RichTextwidth,LoadSpinnerclass,PageTitleleadClass) or another variant.- Positioning belongs to the caller. A component does not place itself (no
absolute, offsets, margins or grid placement of its own); the caller adds them throughclass. A defaultrelativecan beat a caller’sabsolute, because the order in the CSS decides, not the call. - State and motion are scripts, not framework islands. A component with state writes its markup in the state it starts
in and calls an
init*()function from its own<script>; the function lives inscripts/(or insrc/components/site/for the header), takes no arguments and finds its elements bydata-*attributes (see Scripts). Hover isdata-hover+data-motion(scripts/hover.ts). - One component per file. Constants a component shares live in a sibling
.ts(layout/section.ts,actions/button.ts,forms/field.ts,forms/form-state.ts,icons/paths.ts), the shapes of the data the components take intypes.ts. PropsclassName/innerClassNameof the Next.js version areclass/innerClasshere. - A repeated slot is a function of the index. A slot renders once, so a component that repeats or wraps each child
takes
count(oritems) and a slot like{(i: number) => <Card {...cards[i]} />}:Accordion,CardColumns,LoadOnScroll.Tickerrenders its items once and prints them again for each copy. - Framer first. The components follow the original Framer design; a deliberate refinement is written in the component’s leading comment.
Tokens
Section titled “Tokens”| File | Holds |
|---|---|
theme.css |
The colours, the breakpoints (md 810, lg 1200), the font variable (font-sans is Inter), the spring easing curves, the animations with their keyframes, the page background and text colour — the same file as the Next.js version; src/styles/global.css imports it after Tailwind |
tokens/text.ts |
The 13 text styles (text.h2 …), per breakpoint |
tokens/motion.ts |
The five Framer springs A–E as plain objects for Motion’s animate(), and the names usable in data-transition |
utils/cn.ts, utils/href.ts |
cn; isExternalHref and externalLinkProps (http(s) links open in a new tab, mailto and tel do not) |
utils/image.ts |
image(src): the imported file of a /images/<file> path (src/assets/images); imageUrl, isRemote for a CMS image |
utils/motion.ts, utils/play.ts |
motionStates(rest, hover) for data-motion; play(), Motion’s animate() with the visitor’s reduced-motion setting honoured the way the Next.js MotionConfig does |
Colours
Section titled “Colours”| Token | Hex | Framer style | Used for |
|---|---|---|---|
ink |
#000000 | Black | headings, the black buttons and cards, the footer, the plus mark |
soft |
#616161 | Soft Black | leads, descriptions, meta, labels, list dots |
grey |
#EBEBEB | Grey | hairlines, the page-title chip, field borders, the open row’s minus, the footer’s links |
lime |
#E4FE00 | Lime | the accent: buttons, label dots, chips, tags, arrow circles |
green |
#0F3D3A | Green | text and icons on Lime, the arrow circle’s hover fill |
background |
#F7F7F7 | Background | the page, the form fields, the header bar once it turns light |
white |
#FFFFFF | White | cards, white buttons, text over photos |
red |
#FF0000 | Red | the required asterisk, the error label of the Send button |
error-fill |
rgba(255, 34, 68, 0.15) | Red 15 | the Send button’s fill after a failed send (a pinker red than Red, so not an opacity modifier of it) |
spinner |
#999999 | (the Loading component’s own) | the ring of the loading spinner |
Translucent colours are opacity modifiers on a token: Black 50 = ink/50 (the cover over the photos of the Home hero, the
call-to-action band and the 404, a select’s placeholder), Black 25 = ink/25 (the veil over a video, a focused field’s border).
Corners are 5px (rounded-[5px]: buttons, cards, photos, form fields, the lime chips, the video), 3px on the grey chips
(a page title’s label, a position’s place and type), round on dots, arrow circles, avatars and the play button.
Text styles
Section titled “Text styles”Named as in Framer. Inter is one variable font with an optical-size axis, pinned per style: headings use size 32 (Framer’s “Inter Display”), every other style 14. Weight 500 (text in a field 400), letter spacing −0.03em (Menu and Button −0.04em), line height 1.1 for the headings and 1.2 for the rest.
| Token | Framer name | Phone / tablet (md) / desktop (lg) |
Used for |
|---|---|---|---|
text.display |
Display 1 | 48 / 59 / 74 | the Home hero’s title |
text.h1 |
Heading 1 | 42 / 48 / 54 | page titles, the big numbers |
text.h2 |
Heading 2 | 34 / 38 / 42 | section titles, post headings |
text.h3 |
Heading 3 | 28 / 32 / 36 | contact and FAQ titles, legal headings, the black card’s title |
text.h4 |
Heading 4 | 24 / 26 / 28 | the quote beside the services’ closing line, a story’s results |
text.h5 |
Heading 5 | 20 / 22 / 24 | results on cards, the video’s caption, the career sections’ titles |
text.h6 |
Heading 6 | 18 / 19 / 20 | card, row, tab and accordion titles |
text.big |
Big Paragraph | 18 | the hero’s lead, quotes on cards |
text.paragraph |
Medium Paragraph | 16 | leads, descriptions, rich text |
text.small |
Small Paragraph | 14 | labels, chips, card text, meta |
text.menu |
Menu | 16 | the header’s links |
text.button |
Button | 15 | button labels, links with an arrow |
text.tiny |
Tiny | 12 | roles, the footer’s taglines and legal links |
Spacing
Section titled “Spacing”Section sets the page’s rhythm; its constants (layout/section.ts) are exported for the few blocks that lay out their own box.
| Constant | Phone / tablet / desktop |
|---|---|
sectionGutters |
side padding 15 / 20 / 30 |
sectionPadding |
vertical padding 60 / 80 / 100 |
sectionGap |
gap between the blocks of a section 50 / 60 / 80 |
The content is at most 1400 wide. The fixed header is 58 tall on phones and 82 from tablets up; the root layout pads
<main> by that (nothing on Home and the 404, whose first section carries data-header-cover).
Motion
Section titled “Motion”| Spring | Token | Values | Used by |
|---|---|---|---|
| A | spring |
no bounce, 0.4 s | every hover and look change: buttons, links, the header, accordion and collapse rows — and everything that sets no transition of its own |
| B | springSoft |
bounce 0.2, 0.4 s | the hamburger lines, PlusMinus, the LinkedIn button, VideoCard, the process tabs’ fill |
| C | revealSpring, revealDistance (40 px) |
stiffness 200, damping 30, mass 1 | Reveal |
| D | wordSpring |
stiffness 200, damping 40, mass 1 | WordReveal |
| E | introSpring |
stiffness 250, damping 55, mass 2.9 | Intro, which runs in CSS (ease-spring-e): the constant records the numbers |
Spring A is the default of play() and of the hover runtime: a part of a hovered control (the rolling label, the arrow)
has no transition of its own in the Next.js version and runs the provider’s default, spring A — Motion’s own default spring
would overshoot. Reduced motion: moves, turns and sizes jump, fades and colours still animate.
The easing and animation tokens of theme.css (Tailwind utilities ease-spring-a, animate-intro …):
| Token | Holds |
|---|---|
--ease-spring-a, -b, -e |
Springs A, B and E as linear() curves: A settles in 0.37 s without bounce, B overshoots slightly (0.36 s), E takes about a second |
--ease-row-hover |
cubic-bezier(0.5, 0, 0.88, 0.77), an ease-in: the ServiceRow hover (0.4 s) |
--ease-form |
cubic-bezier(0.44, 0, 0.56, 1): the SubmitButton’s colours (0.2 s) and the LoadSpinner fade (0.3 s) |
--ease-page-change |
cubic-bezier(0.73, 0, 0.33, 1): the page change (0.6 s each way, in styles/page-change.css: a cross-document view transition) |
--animate-intro, --animate-intro-fade |
the page-load rise of 60 px (960 ms) and its fade-only version for reduced motion; the delay is set on the element |
--animate-ticker |
the Ticker belt, one copy’s width (--ticker-period); each Ticker sets its duration inline |
--animate-turn |
one turn a second: the spinners of SubmitButton and LoadSpinner |
Components
Section titled “Components”Files are components/<group>/<Name>.astro. A slot is the component’s content (a label, a list of items).
| Group | Component | What it is | Props that matter | Used in |
|---|---|---|---|---|
| actions | Button |
Framer Button (Primary, Secondary, Small): a 5px box in Lime, White or Black; the label rolls up to a second copy on hover and, with arrow, a 17px arrow nudges 5px. A link with href (an external one opens in a new tab), otherwise a <button>. The slot is the label |
tone (lime default, white, black), arrow, small (the header’s), href, type, data-* |
Header (also the phone menu), Home hero and CTA band, the Action blocks, 404, Careers rows, process tabs, Services process, other services, MoreCard, ActionQuote |
| actions | MenuLink |
Framer Button/Menu: a header link in the bar’s colour at 80% over a 1px line; hover goes to 100% and a solid line grows across | href, current (aria-current), stacked (the phone menu’s row, no hover), data-* |
Header |
| actions | ArrowLink |
Framer Button/Secondary: a label and an 18px lime circle with an arrow; hover turns the circle Green and slides the arrow out as a second one comes in | href (mailto, tel and http(s) give a plain <a>) |
ServiceRow (“Learn more”), Why Choose, Contact (e-mail, phone) |
| actions | FooterLink |
Framer Button/Secondary Small/White: a Grey link, Lime on hover, with a lime arrow sliding in at the right end | href, sameTab (other sites otherwise open in a new tab) |
Footer |
| actions | PlusMinus |
Framer Plus Min: the 24px round mark of an accordion row — a white plus on Black when closed, a Soft Black minus on Grey when open | open |
Accordion, FaqList, the process tabs on phones |
| brand | Logo |
the wordmark and its ™ as inline SVG in the text colour, 102 × 20 | href, label (the link’s name), compact (93 wide on phones), class (the colour, text-white) |
Header (compact), Footer (white), Process, the Action card |
| icons | Icon |
a Phosphor icon as inline SVG in the text colour; the 17 icons are in icons/paths.ts |
name (IconName), class (the size, size-5; 14px when left out), label (an image with a name; decorative without) |
inside Button, the links, PlusMinus, SectionLabel, IconCard, TeamCard, VideoCard; the footer’s taglines |
| motion | Reveal |
Framer block reveal: the block comes from 40px lower and from nothing, once, when it comes into view (spring C): the share amount of the block is on the screen, or the block covers that share of the screen when it is taller than it |
as (div, section, li, ul, p, span, article), delay, amount (the share of its height that must show) |
nearly every section |
| motion | WordReveal |
Framer text reveal: every word rises on its own, 0.05 s apart, once (spring D); screen readers get the text once | as (h1–h3, p, span, div), text, delay, stagger, amount (0.5) |
section titles, PageTitle, the career title, 404 |
| motion | Collapse |
the part of an accordion row that opens and closes: its height goes from 0 to auto with spring A; closed content is hidden from the keyboard and screen readers | open, id (the button’s aria-controls) |
Accordion, FaqList, the process tabs on phones |
| motion | Intro |
Framer page-load intro: the block rises 60px from nothing as the page paints (spring E, a CSS animation that needs no script); reduced motion fades only | as (div, h1, p, span), delay |
Home hero, Header |
| navigation | Hamburger |
the phone menu button, 24 × 18: three lines that become an X (spring B) | label, controls (the menu’s id), open (the state it starts in), demo (toggles on its own: the style guide) |
Header (phones) |
| layout | Section |
a page section: gutters, vertical padding, content at most 1400 wide, clipped like Framer’s sections. Also sectionGutters, sectionPadding, sectionGap (layout/section.ts) |
padding, gap (whole class strings), innerClass, class, id, as, label, headerSwitch |
every page section except the hero, the CTA band, the Action block, the article and the 404; the style guide |
| layout | SectionLabel |
Framer Label: a 20px lime circle with a bold asterisk and a Small Paragraph; light is the hero’s (a shield, Medium Paragraph in Background) |
light |
the title block of a section; the Home hero (light) |
| layout | PageTitle |
Framer Title Section: an optional grey chip, the page’s <h1> (its words rise) and a lead |
label, title, text, balance, leadClass (a whole class) |
About, Blog, Careers, Contact, a service page, Services, Team, Testimonial |
| cards | ServiceRow |
Framer Service List row: the photo, a white card (number, title, text, “Learn more”, which carries the title as hidden text) and a “What’s Included” card; on desktop hover turns the row White and zooms the photo | ServiceRowData (href, number, title, text, image, includedLabel, included, moreLabel), heading (h3; h2 under a page’s h1) |
Home, Services, a service page (other services) |
| cards | PostCard |
Framer Blog card: a 3:2 photo, a white card with the category chip, the date, the title and the excerpt (two lines each); the whole card is the link and hover settles the photo | PostCardData (href, title, excerpt, image, category, date, dateTime), heading, class |
Home, Blog, Testimonial (latest posts), a post (related posts) |
| cards | TestimonialCard |
Framer Testimonial card, 300 or 400 tall: a figure with the quote (blockquote), the client (figcaption: round photo, name, role, company logo) and two results |
variant (logo, plain, results-below, results-above), quote, name, role, photo, logo with logoWidth and logoHeight, results |
Home and Services (the quote grid) |
| cards | IconCard |
Framer Card/Icon Text: a white card with a lime square holding a light icon and, at the bottom, a title and a line; it has no height of its own | icon, title, text, titleAs (h3, p), class (the height) |
Home (About), About (Mission), Careers |
| cards | TeamCard |
Framer Card/Team: a 2:3 portrait with a round LinkedIn button and a white name card | TeamCardData (name, role, photo, linkedin, linkedinLabel), nameAs (h3, h2), sizes, preload |
About, Team |
| cards | MoreCard |
Framer More: the black 2:3 card that ends the team grid, a text and a lime arrow button | text, link, title (the Team page’s heading) |
About, Team |
| media | VideoCard |
Framer Card/Video: a 16:9 poster under a 25% veil and a play button; a press plays the clip muted and looping in place (the <video> is added by the script on the first press, so the file is only fetched then) |
src, poster, label, caption |
Home (Services), About (Mission) |
| media | FillImage, SizedImage |
the images of the components: FillImage fills its positioned parent (next/image fill), SizedImage is drawn at a given size (next/image with width and height); /images/<file> paths from the content, or a CMS URL |
src, alt, sizes, priority (FillImage); width, height (SizedImage); class |
every photo |
| data | FactList |
Framer Fact Number: four numbers in a row (two by two on tablets), each over a line, a label and a description; they rise one after the other | items (FactData), amount |
Home, About, a service page |
| patterns | RichText |
CMS rich text: headings, paragraphs (with italic and line breaks), bulleted and numbered lists, nested | blocks, headings (h2 or h3 style), width (a whole class) |
a post, the legal pages |
| patterns | CardColumns |
Framer CMS list in Masonry: three columns on desktop, two on tablets, one on phones; the cards are dealt out from the left. With pageSize it loads on scroll (the Blog) |
count + slot (i) => card, shown (per layout), pageSize (per layout), loading (the spinner’s label) |
Home, Blog, Testimonial (latest posts), a post (related posts) |
| patterns | Ticker |
Framer Ticker: items moving left forever, slowed to a stop by the pointer, still for reduced motion | speed (px a second), gapClass, copies, label; the slot is the items |
the client logos (Home, Services) |
| patterns | Accordion |
Framer accordion: white rows with a number, a title and a PlusMinus; one row open at a time |
items ({ title }) + slot (i) => content, id, defaultOpen (0), titleAs |
Home (Why Choose) |
| patterns | FaqList |
Framer FAQ: the same rows, each opening on its own | items ({ question, answer }), id, defaultOpen ([0]), reveal |
Contact |
| patterns | LoadOnScroll, LoadSpinner |
Framer “load on scroll”: the first pageSize blocks, and a spinner under them that asks for the next page within 500px of the screen; every block is in the page, hidden, for crawlers and without JavaScript. LoadSpinner is the ring on its own |
count, pageSize, label + slot (i) => block; spinner: label, class (a whole class) |
Services, Testimonial; the Blog list (the spinner) |
| patterns | ActionQuote |
Framer Details: a closing line with two buttons beside a client quote | text, primary, secondary, quote, delays |
Home (Services), About (Mission) |
| forms | Form |
a form that sends its fields and shows its progress on the Submit button: a spinner, then Thank you and the fields reset (or a redirect), or an error and the fields keep what was typed; a honeypot field (fax). It posts to endpoint (a form service, a webhook or the site’s own /api/forms route) or, without one, runs a demo |
name (contact, consultation, application), subject, endpoint, hidden, submitLabel, successLabel, errorLabel, redirectTo, demo ("fail": the style guide’s failing sample), submitClass, class |
Contact, a service page, a career page |
| forms | FormField, FieldControl, fieldSurface |
Framer form field: a label over a control, with a red asterisk on a required one; FieldControl is the control without the label, fieldSurface (forms/field.ts) its class string |
name, label, type (text, email, tel, url, date, select, textarea), placeholder, required, autoComplete, defaultValue, options, class (the grid placement) |
the three forms |
| forms | SubmitButton |
Framer Submit (Default, Loading, Success, Error), 40 tall; the markup holds the four looks and the form script switches data-status |
status (idle, pending, success, error), label, successLabel, errorLabel |
inside Form |
| forms | honeypotField |
the name of the hidden field bots fill in (forms/form-state.ts, shared by Form and the server route) |
— | scripts/form.ts, src/lib/forms/deliver.ts |
| utils | CurrentYear |
the visitor’s current year: the page ships the build year and a tiny script swaps in the current one | — | Footer |
Internal pieces (not meant to be used on their own): cards/TestimonialClient, cards/TestimonialResults,
patterns/FaqRow, patterns/RichTextBlock, patterns/RichTextInline.
Page sections (the hero, the services, the process …) live in src/components/sections/; the header and footer in
src/components/site/.
Scripts
Section titled “Scripts”Every script is a scripts/<name>.ts that exports init*() functions without arguments (the HTML edition is generated
from this version and calls each of them; helpers with arguments have other names). A component calls its function from its
own <script>; each function marks what it has processed (data-*-ready), so calling it twice does nothing.
| File | Function | What it does |
|---|---|---|
hover.ts |
initHover() |
plays the data-motion states of every data-hover element on hover (called by the layout) |
reveal.ts |
initReveal() |
Reveal blocks and WordReveal words rise when they come into view |
accordion.ts |
initAccordions() |
Accordion (one row open) and FaqList (every row on its own) |
collapse.ts, plus-minus.ts |
setCollapse(), setPlusMinus() |
open / close a Collapse and switch a PlusMinus (used by the row scripts) |
tabs.ts |
initTabs() |
the process tabs: tab buttons, arrow keys, the phone rows |
video-card.ts |
initVideoCards() |
VideoCard: press, hover, the <video> |
ticker.ts |
initTickers() |
Ticker: measures one copy, slows to a stop under the pointer |
load-on-scroll.ts |
initLoadOnScroll(), initLoadSpinners() |
LoadOnScroll and the Blog masonry; the spinner’s ring |
hamburger.ts |
initHamburgerDemos(), setHamburger() |
the stand-alone hamburger demos; the lines, aria-expanded |
form.ts |
initForms() |
Form: send, the Submit states, reset |
current-year.ts |
initCurrentYear() |
CurrentYear |
style-guide.ts |
initReplays(), initSpringDemos(), initCollapseDemos() |
the style guide’s demos (src/components/style-guide): Replay puts a specimen back and plays it again, the spring tracks, the Collapse row |
../../components/site/header.ts |
initHeader() |
the header’s light look past the About block, the phone menu |
New component: put it in the right group, add it to /style-guide and to this table; new interactivity: a script as above.