gitoria

notes

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commiteeaea980eeaea980report 007: say which runs included the removed checkmreeeaea980/components/styles.hl

5.9 KB

  1. // components/styles.hl — ALL of the app's CSS, served as /__hl/app.css. Components carry no Style blocks: markup is domain
  2. // tags (<note-book>, <note-list>, <note-reader>, …), this file lays them out. Tokens: shared/tokens.hl (verbatim
  3. // copy of loreana worldapi-tokens/tokens.hl); the app sets only its accent (yellow).
  4. // In a styles file a bare name is a TAG (camelCase → kebab), a quoted name is a selector written verbatim.
  5. // MOBILE FIRST: every rule is the phone's (the list first; a selected note replaces it); the one min-width block
  6. // adds the wide layout (list and note side by side).
  7. import { var } from 'hl:web/css'
  8. import { yellow, colorText, colorBackground, colorTextStrong, colorTextMuted, colorBackgroundSunken, colorAccentText, colorSurface, colorBorder, colorDanger } from '../shared/tokens.hl'
  9. colorAccent = var(yellow) // the app's accent: the only token this app sets
  10. '*,
  11. *::before,
  12. *::after' { boxSizing = 'border-box' }
  13. html { colorScheme = 'dark' }
  14. body { margin = '0' font = '16px/1.5 system-ui, sans-serif' color = colorText background = colorBackground }
  15. a { color = colorAccent textDecoration = 'none' }
  16. 'a:hover' { textDecoration = 'underline' }
  17. h1 { margin = '0' fontSize = '1.3rem' lineHeight = '1.3' color = colorTextStrong overflowWrap = 'anywhere' }
  18. p { margin = '0' }
  19. 'input,
  20. textarea' { font = 'inherit' width = '100%' padding = '.5rem .7rem' color = colorTextStrong background = colorBackgroundSunken border = '1px solid ' + colorBorder borderRadius = '.4rem' }
  21. button { font = 'inherit' fontWeight = '600' padding = '.55rem 1.1rem' color = colorAccentText background = colorAccent border = '0' borderRadius = '.4rem' cursor = 'pointer' }
  22. 'button:hover' { filter = 'brightness(1.1)' }
  23. 'button.quiet' { color = colorText background = 'transparent' border = '1px solid ' + colorBorder padding = '.35rem .8rem' fontSize = '.9rem' }
  24. 'button.danger' { color = colorTextStrong background = colorDanger padding = '.35rem .8rem' fontSize = '.9rem' }
  25. // ---- the shell ---------------------------------------------------------------------------
  26. applicationHeader { position = 'sticky' top = '0' zIndex = '5' display = 'flex' flexWrap = 'wrap' alignItems = 'center' gap = '.5rem 1rem' padding = '.6rem 1rem' background = colorBackgroundSunken borderBottom = '1px solid ' + colorBorder }
  27. 'application-header .brand' { fontWeight = '800' fontSize = '1.15rem' color = colorAccent marginRight = 'auto' }
  28. main { display = 'block' padding = '1rem' }
  29. userBox { display = 'flex' flexWrap = 'wrap' alignItems = 'center' justifyContent = 'flex-end' gap = '.4rem .6rem' marginLeft = 'auto' maxWidth = '100%' }
  30. // the identity selector: ident's shadow DOM, restyled to the accent
  31. identSelector { '--ident-accent' = colorAccent '--ident-accent-text' = colorAccentText '--ident-background' = colorSurface '--ident-border' = colorBorder '--ident-font' = '600 .9rem/1.4 system-ui, sans-serif' }
  32. 'ident-selector::part(button)' { padding = '.35rem .8rem' }
  33. 'ident-selector::part(status)' { padding = '.35rem .8rem' }
  34. 'a.button' { display = 'inline-block' fontWeight = '600' fontSize = '.9rem' padding = '.35rem .8rem' color = colorAccent border = '1px solid ' + colorAccent borderRadius = '.4rem' }
  35. 'a.button:hover' { textDecoration = 'none' background = colorSurface }
  36. '.message' { color = colorDanger fontSize = '.9rem' }
  37. '.message:empty' { display = 'none' }
  38. '.banner' { margin = '0' padding = '.5rem 1rem' background = colorSurface }
  39. '.empty' { padding = '1rem' textAlign = 'center' color = colorTextMuted border = '1px dashed ' + colorBorder borderRadius = '.5rem' }
  40. '.muted' { fontSize = '.9rem' color = colorTextMuted }
  41. // ---- the notes: the list first; a selected note (noteBook.open) replaces it on a phone ------------------
  42. noteBook { display = 'block' }
  43. noteList { display = 'grid' gap = '.6rem' alignContent = 'start' }
  44. 'note-list > header' { display = 'flex' alignItems = 'center' justifyContent = 'space-between' gap = '1rem' }
  45. '#notes' { display = 'grid' gap = '.3rem' margin = '0' padding = '0' listStyle = 'none' }
  46. '#notes a' { display = 'block' padding = '.55rem .8rem' color = colorText background = colorSurface border = '1px solid ' + colorBorder borderRadius = '.4rem' overflowWrap = 'anywhere' }
  47. '#notes a:hover' { textDecoration = 'none' borderColor = colorAccent }
  48. '#notes a.selected' { color = colorTextStrong borderColor = colorAccent borderLeftWidth = '.3rem' }
  49. noteReader { display = 'block' minWidth = '0' }
  50. noteEditor { display = 'grid' gap = '.8rem' }
  51. 'note-editor footer' { display = 'flex' flexWrap = 'wrap' alignItems = 'center' gap = '.6rem' }
  52. 'note-editor .back' { justifySelf = 'start' }
  53. '.ask' { display = 'none' alignItems = 'center' gap = '.6rem' }
  54. '.ask.open' { display = 'flex' flexWrap = 'wrap' }
  55. 'note-book.open note-list' { display = 'none' }
  56. 'note-book:not(.open) note-reader' { display = 'none' }
  57. // the page's clock (components/notes.hl): an invisible endless 1 s animation, each round is a tick
  58. notesTick { position = 'fixed' left = '0' top = '0' width = '1px' height = '1px' opacity = '0' pointerEvents = 'none' animation = 'notes-tick 1s linear infinite' }
  59. '@keyframes notes-tick' = {
  60. 'from' = { opacity = '0' }
  61. to = { opacity = '0' }
  62. }
  63. mdEditor { '--md-background' = colorBackgroundSunken '--md-text' = colorText '--md-text-strong' = colorTextStrong '--md-text-muted' = colorTextMuted '--md-border' = colorBorder '--md-accent' = colorAccent '--md-accent-text' = colorAccentText '--md-link' = colorAccent '--md-code-background' = colorSurface '--md-toolbar-background' = colorSurface '--md-danger' = colorDanger '--md-min-height' = '18rem' color = colorText }
  64. '@media (min-width: 50rem)' = {
  65. noteBook = { display = 'grid' gridTemplateColumns = '20rem minmax(0, 1fr)' gap = '1.5rem' alignItems = 'start' }
  66. 'note-book.open note-list' = { display = 'grid' }
  67. 'note-book:not(.open) note-reader' = { display = 'block' }
  68. 'note-editor .back' = { display = 'none' }
  69. }

Branches

Latest commits

  • eeaea980report 007: say which runs included the removed checkmre
  • 8a8ad9banotes mission 007: report, LOG, STATUSmre
  • 2cce9c96code order: plain declarations where never reassigned (letcount 0 never); gate: scan every IndexedDB at log-out, soft mode for old-code runs, drop a check that could not failmre
  • 7f6a4090README: offline in Hybriel (hl:web offline, continuation, known md-editor gap); gate waits report instead of crash; realdata-offline checkmre
  • 632223f2notes#4: delete notes-offline.js and sw.js (hl:web's generated worker and kept state replace them)mre
  • 52a2acadgate: offline checks on hl:web's worker/queue, Chrome offline via CDP (reload offline first), one-offline conflict, log-out forgets the kept copymre
  • e5785b03notes#4: the notes page in Hybriel — hl:web offline = [Notes], queued faces notesPut/notesDrop, push notesChanged, value-form notesPull on a tick; notes-offline.js/sw.js no longer loaded or routedmre
  • 510aff75notes#4: server continues a run of saves of one login (by + since), loser keeps writing into its copy; notesFor listmre
  • 0176c4b5mission brief 007mre
  • 06cfa870notes mission 006: re-vendor hybriel 0f396652 (static), reportmre
  • 6c07bd91mission brief w6mre
  • cf64d3d5notes mission 005: stopped at a Hybriel gap (for list repainted during hl:web boot throws, rowKidless); report, LOG, STATUSmre
  • a43b5d2dmission brief 005mre
  • 04a625edmission 004: re-vendor hybriel a832f73b (native bin + plugins as tickets), compose HL_CACHE_DIR volume + tmpfs /tmp, deploy URL wait 120 s, tests wait 120 s per start; gate 57/0 old and new; real-data same output. Not deployed.mre
  • aefb9d44mission brief w4mre
  • 202098b3docker-compose: init: true (hybriel#156, PID 1 ignored SIGTERM, every restart waited 10 s)mre
  • 304f6a9dnotes mission 003 (#5): report, STATUS, LOGmre
  • 9acc27f8notes mission 003 (#5): GitHub pipe tables in md-editor (parse, render, type, write) + gate checksmre
  • 2149e902notes mission 002 (4/4): code order — README file map + same-output test, STATUS, LOG, report; tests/letcount.py, tests/realdata-baseline.mjs, tests/realdata-compare.pymre
  • 47db4fc1notes mission 002 (3/4): code order — let only where reassigned (58 dropped; 34 left: 19 reassigned, 15 loop-bound); gates 50/0 + 18/0, live-data run = step 2mre