components
All repositories: gitoria
5.1 KB
// components/styles.hl — the SITE's own CSS (page layout: header, main, the home list), served as /__hl/app.css. Every component// carries its own Style in its file (components/*/*.hl). The site shows the library's BASE LOOK (ticket #15): black, white and the greys of// shared/base.hl — it declares none of the WorldAPI tokens (--color-…), so every component shows its own base fallbacks, as in a bare app.// Light: white page, black text; the header is the one black block. No frames. In a styles file a bare name is a TAG (camelCase → kebab), a quoted name is a// selector written verbatim. MOBILE FIRST: every rule is the phone's; the min-width block adds the wide layout.import { var } from 'hl:web/css'import { black, greyDark, grey, greyLight, greyLighter, white } from '../shared/base.hl'// the box model for every element: ::before and ::after have no form in the language, so the selector list stays quoted'*, *::before, *::after' { boxSizing = 'border-box' }html { colorScheme = 'light' }body {margin = '0'font = '16px/1.5 system-ui, sans-serif'color = blackbackground = white}a {color = blacktextDecoration = 'underline'textUnderlineOffset = '.2em'hover { textDecorationThickness = '2px' }}h1 {margin = '0 0 1rem'fontSize = '1.3rem'lineHeight = '1.3'color = black}h2 {margin = '0'fontSize = '1.1rem'color = black}'.muted' { color = greyDark }button {font = 'inherit'fontWeight = '600'minHeight = '2.75rem'padding = '.4rem .9rem'color = whitebackground = blackborder = '0'borderRadius = '.4rem'cursor = 'pointer'hover { background = greyDark }}'button.quiet' {color = blackbackground = greyLighterhover { background = greyLight }}applicationHeader {position = 'sticky'top = '0'zIndex = '5'display = 'flex'flexWrap = 'wrap'alignItems = 'baseline'gap = '.2rem 1rem'padding = '.3rem 1rem'color = whitebackground = black'.brand' {display = 'inline-flex'alignItems = 'center'minHeight = '2.75rem'fontWeight = '800'fontSize = '1.15rem'color = whitetextDecoration = 'none'}// the tagline only where there is room: on a phone the header is the brand alone (44 px target, no second line)p {display = 'none'margin = '0'color = greyfontSize = '.9rem'@media {minWidth = '40rem'display = 'block'}}}// ---- offline (mission 046, components/main.hl): the note under the header, and the probe whose endless animation is// the shell's 1 s tick (it must be rendered for the animation to run — not display none — so: invisible)offlineNote {display = 'block'padding = '.5rem 1rem'color = blackbackground = greyLight}netProbe {position = 'fixed'left = '0'top = '0'width = '1px'height = '1px'opacity = '0'pointerEvents = 'none'animation = 'components-net-tick 1s linear infinite'}'@keyframes components-net-tick' = {'from' = { opacity = '0' }to = { opacity = '0' }}main {display = 'block'maxWidth = '40rem'margin = '0 auto'padding = '1rem'}// ---- the home ---------------------------------------------------------------------------------'#components' {display = 'grid'gap = '.5rem'margin = '0'padding = '0'listStyle = 'none'li {display = 'grid'gap = '.15rem'padding = '.7rem 1rem'background = greyLighterborderRadius = '.5rem'}p {margin = '0'color = greyDark}a {display = 'flex'alignItems = 'center'minHeight = '2.75rem'}}// the demo pages' Send row: air between the field and its button, whatever the page's paragraph margin'.demo-send' { margin = '1rem 0 0' }// "You are: alice bob nobody": a labelled group of buttons, the chosen one filled, the others quiet'.comments-who' {display = 'flex'flexWrap = 'wrap'alignItems = 'center'gap = '.5rem'}// ---- the Markdown editor demo ------------------------------------------------------------------mdEditorDemo {h2 {margin = '1rem 0 .3rem'fontSize = '1rem'}pre {margin = '0 0 1rem'whiteSpace = 'pre-wrap'overflowWrap = 'anywhere'}}// a child combinator: no form in the language'md-editor-demo form > md-editor' { margin = '0 0 1rem' }// ---- the modal demo --------------------------------------------------------------------------------'.modal-openers' {display = 'flex'flexWrap = 'wrap'gap = '.5rem'}modalDemo {input {font = 'inherit'padding = '.35rem .6rem'color = blackbackground = greyLighterborder = '0'borderRadius = '.4rem'}}// ---- the pick-first demo (files upload in pick mode, ticket #18): a chat input — the field and Send in one row, Send 44 px high'#sent' {display = 'grid'gap = '.5rem'margin = '0 0 1rem'padding = '0'listStyle = 'none'li {padding = '.5rem .8rem'background = greyLighterborderRadius = '.5rem'}p {margin = '0'overflowWrap = 'anywhere'}'.sent-files' {fontSize = '.85rem'color = greyDark}}'#chat-form' {display = 'flex'gap = '.5rem'alignItems = 'flex-end'}'#chat-text' {flex = '1'minWidth = '0'minHeight = '2.75rem'font = 'inherit'padding = '.5rem .7rem'color = blackbackground = greyLighterborder = '0'borderRadius = '.4rem'resize = 'vertical'}'#chat-send' {minHeight = '2.75rem'minWidth = '2.75rem'}
Branches
Latest commits
- a06fc778Reset virtual-list window when the host changes resetKeyAtlas
- 3aab598cRe-vendor complete Hybriel day73 set for virtual-list resetAtlas
- 337ca075MD1 gate check measures frames in the page, not milliseconds from outside, and takes the middle load (components#30)mre
- f5f131c5Record AP29 autoplay comparisons and passing gatesmre
- 51c38187Gate media autoplay on first load and after client mountmre
- a3f2223dRecord successful B44 deployment and live proofmre
- 06c1e021Record passing B44 browser rerunmre
- c9861533Record B44 component proof and browser gate blockermre
- 1b7413beIgnore detached media events and space demo option outputsmre
- ca3b4959Re-vendor complete Hybriel plugins and runtime to day44mre
- df9e7df9Last-item checks run in the browser gate (components#26 fixed on day41); media-player loop is a plain Booleanmre
- 895a5afcRe-vendor complete Hybriel plugins and runtime to day41mre
- 16006bb3Backup tar: --hard-dereference, so mpackdb sidecars are never stored as hard links (Tracker's finding)mre
- 88397fc3Re-vendor complete Hybriel plugins and runtime to day39mre
- 9b872cedRecord IC28 deployment and live icon verificationmre
- 46fefaa7Count the icons entry in the offline home-page checkmre
- c7e14cabRecord IC28 rerun and unchanged-main baseline comparisonmre
- 5e090ffdRecord IC28 review evidence and gate resultsmre
- adfe2c4dAdd shuffle, repeat and repeatOne shared iconsmre
- c96709c8media-player: skip = false and repeat = 'one' options (jukebox#19)mre