gitoria

layouts

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commitb05c20feb05c20feBackup tar: --hard-dereference, so mpackdb sidecars are never stored as hard links (Tracker's finding)mreb05c20fe/components/read.hl

1.4 KB

  1. // components/read.hl — `/read/:doc`: a doc or a component README read INSIDE the app shell (header, sidebar), the Markdown
  2. // drawn by the editor's read-only face — the same look as the comments. (The raw files stay at /docs/*.md and
  3. // /components/*/README.md for models and tools; no page of the site links to them.)
  4. parent './main.hl'
  5. import SiteHeader from './site-header.hl'
  6. import SiteSidebar from './site-sidebar.hl'
  7. import ContentFirst from '../theme/shell/content-first.hl'
  8. import TheMdEditor from './md-editor/md-editor.hl'
  9. import { entryOf, textOf } from '../lib/read.hl'
  10. doc = null
  11. Hybrid entry = doc == null ? null : entryOf(doc)
  12. String text = entry == null ? '' : textOf(doc)
  13. String heading = entry == null ? 'Not found' : entry.label
  14. Boolean found = entry != null
  15. Boolean missing = entry == null
  16. __title = 'Docs · WorldAPI layouts'
  17. Style {
  18. 'read-page a.back' { display = 'inline-flex' alignItems = 'center' minWidth = 'var(--layout-tap)' minHeight = 'var(--layout-tap)' marginBottom = '.5rem' fontWeight = '600' }
  19. 'read-page a.back::before' { content = '"‹ "' }
  20. }
  21. View {
  22. readPage {
  23. SiteHeader { current = "/docs" }
  24. ContentFirst {
  25. SiteSidebar { current = "/docs" }
  26. main {
  27. a { class = "back" href = "/docs" "Docs" }
  28. if (found) { TheMdEditor { name = "doc" value = text readonly = "true" } }
  29. if (missing) { h1 { heading } p { class = "empty" "No such page. " a { href = "/docs" "All docs" } } }
  30. }
  31. }
  32. }
  33. }

Branches

Latest commits

  • b05c20feBackup tar: --hard-dereference, so mpackdb sidecars are never stored as hard links (Tracker's finding)mre
  • 8d9ed0b8Re-vendor complete Hybriel plugins and runtime to day39mre
  • ebd00b6cNest caller slot styles in three-panemre
  • 009991efNest caller slot styles in list-firstmre
  • 494d75d4Nest caller slot styles in app-sidebarmre
  • e5571680Align all plugin sources with Hybriel day38bmre
  • 5d204c46Re-vendor layouts to Hybriel set day38bmre
  • 17e0f03eNest html-prefixed theme component overridesmre
  • e54e735eFormat plain theme elements with nested rules and bare mediamre
  • 547f834eRecord LY7 deployment and live verificationmre
  • fa4600b1Link caller-slot style exceptions to hybriel#270mre
  • 413b11e1Record corrected LY7 nesting, exact CSS and Chrome proofmre
  • b810453etracker-demo: nest child and compound selectors in Stylemre
  • 0b5b1d61notes-demo: nest child and compound selectors in Stylemre
  • ab22bdc2mail-demo: nest child and compound selectors in Stylemre
  • fe2d8de9home: nest child and compound selectors in Stylemre
  • e631791buser-menu: nest child and compound selectors in Stylemre
  • 69604944three-pane: nest child and compound selectors in Stylemre
  • 3e389b83main-menu: nest child and compound selectors in Stylemre
  • 05413975list-first: nest child and compound selectors in Stylemre