gitoria

tracker

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commit2f986ca32f986ca3Log: RT50 passmre2f986ca3/components/franchisewidget.hl

3.1 KB

  1. // components/franchisewidget.hl — THE FRANCHISE WIDGET on a show / movie page (tracker.worldapi.org#19, mission 066), composed
  2. // by components/show.hl: `FranchiseWidget { widgets = … }` (franchises.hl widgetsOf). One per timeline the title is in:
  3. //
  4. // Star Trek ← the franchise (only when the timeline has one) → its index
  5. // ‹ Prequel | Star Trek — Prime | Sequel › ← links to the title before / after this one; an end is greyed out
  6. //
  7. // The timeline's name links to /timelines/<slug>. Each side shows the title it leads to under the word.
  8. widgets = []
  9. // HM49: component rules keep the existing selectors and shared theme variables.
  10. Style {
  11. franchiseWidgets {
  12. display = 'block'
  13. margin = '0'
  14. @media {
  15. minWidth = '40rem'
  16. margin = '.5rem 0'
  17. }
  18. }
  19. 'franchise-widgets:not(:has(franchise-widget))' {
  20. display = 'none'
  21. }
  22. franchiseWidget {
  23. display = 'block'
  24. padding = '.5rem .6rem'
  25. marginBottom = '.5rem'
  26. background = 'var(--color-surface)'
  27. borderRadius = 'var(--radius-large)'
  28. }
  29. aFwFranchise {
  30. display = 'block'
  31. padding = '.8rem 0'
  32. marginBottom = '0'
  33. fontSize = '.8rem'
  34. fontWeight = '600'
  35. letterSpacing = '.04em'
  36. textTransform = 'uppercase'
  37. textAlign = 'center'
  38. }
  39. fwRow {
  40. display = 'grid'
  41. gridTemplateColumns = 'minmax(0, 1fr) minmax(0, 1.2fr) minmax(0, 1fr)'
  42. alignItems = 'center'
  43. gap = '.5rem'
  44. @media {
  45. minWidth = '40rem'
  46. gridTemplateColumns = 'minmax(0, 1fr) minmax(0, 1.5fr) minmax(0, 1fr)'
  47. }
  48. }
  49. fwSide {
  50. display = 'flex'
  51. flexDirection = 'column'
  52. justifyContent = 'center'
  53. minHeight = '2.75rem'
  54. minWidth = '0'
  55. color = 'var(--color-accent)'
  56. }
  57. fwNext {
  58. alignItems = 'flex-end'
  59. textAlign = 'right'
  60. }
  61. '.fw-side.off' {
  62. color = 'var(--color-text-muted)'
  63. opacity = '.5'
  64. }
  65. 'a.fw-side' {
  66. hover {
  67. textDecoration = 'none'
  68. fwDir {
  69. textDecoration = 'underline'
  70. }
  71. }
  72. }
  73. fwDir {
  74. fontWeight = '600'
  75. whiteSpace = 'nowrap'
  76. }
  77. fwTitle {
  78. fontSize = '.8rem'
  79. color = 'var(--color-text-muted)'
  80. whiteSpace = 'nowrap'
  81. overflow = 'hidden'
  82. textOverflow = 'ellipsis'
  83. maxWidth = '100%'
  84. }
  85. aFwTimeline {
  86. minWidth = '0'
  87. fontWeight = '600'
  88. color = 'var(--color-text-strong)'
  89. textAlign = 'center'
  90. overflowWrap = 'anywhere'
  91. padding = '0 .4rem'
  92. }
  93. }
  94. View {
  95. franchiseWidgets {
  96. for (w of widgets) {
  97. franchiseWidget { "data-timeline" = w.id
  98. if (w.hasFranchise) { a { Style.aFwFranchise href = w.franchiseHref w.franchiseName } }
  99. fwRow {
  100. if (w.hasPrev) {
  101. a { Style.fwSide class = "fw-prev" href = w.prevHref title = w.prevTitle
  102. fwDir { "‹ Prequel" }
  103. fwTitle { w.prevTitle }
  104. }
  105. }
  106. if (w.noPrev) { span { Style.fwSide class = "fw-prev off" "aria-disabled" = "true" fwDir { "‹ Prequel" } } }
  107. a { Style.aFwTimeline href = w.href w.name }
  108. if (w.hasNext) {
  109. a { Style.fwSide Style.fwNext href = w.nextHref title = w.nextTitle
  110. fwDir { "Sequel ›" }
  111. fwTitle { w.nextTitle }
  112. }
  113. }
  114. if (w.noNext) { span { Style.fwSide Style.fwNext class = "off" "aria-disabled" = "true" fwDir { "Sequel ›" } } }
  115. }
  116. }
  117. }
  118. }
  119. }

Branches

Latest commits

  • 2f986ca3Log: RT50 passmre
  • 1c4715a4RT50 mission: day50 repro retestmre
  • 57d1c0dcLog: day50 retest requestmre
  • 60b1f419Log: Anton #336 result, wake checkmre
  • 919a18aalog: scratchmre
  • 6b504440status tidymre
  • 9332bd10log: DP70 livemre
  • be11daa0DP70 brief fixmre
  • 886a7028DP70 brief, HM67 mergedmre
  • b41cdd6dMerge hm67-searchids: packed search IDsmre
  • 385904eaReport HM67 matched heap measurements and gate proofmre
  • e5c9b659Pack retained search IDs into UTF-8 bytesmre
  • 62a5f6c7HM67 brief, HM66 mergedmre
  • b32b8440Merge hm66-catalogindex: packed catalog indexmre
  • 2db0f7adReport HM66 heap measurements and validationmre
  • 6ce15623Pack catalog lists and membership maps in UTF-8 bytesmre
  • 71134e21HM66 briefmre
  • ed4cbab2status timemre
  • e982c26dlog: HM65 mergedmre
  • 6e72f9d1Merge hm65-fields: episode boot scan reads three fieldsmre