Commit Graph

27 Commits

Author SHA1 Message Date
1e2b8321fd Extract pages into lib/page/ modules; thin down bbs.rb
Each page is now a self-contained module with a configure(tui) class
method. Shared helpers live in TUIHelpers. bbs.rb is reduced to
constants, chrome, and wiring.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 22:23:10 +02:00
1cd1eceb1c Switch TUI theme from blue to black background
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 22:10:19 +02:00
a01dad96d9 Game catalog shows story and links; new_msg returns to menu on send
Game catalog: replaced emoji badges with the story field (word-wrapped)
and external links listed as label + URL. GameModel gains story and
external_links attributes.

New message: navigates back to idle immediately after a successful send
instead of sitting on the sent confirmation screen.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 22:08:31 +02:00
bbeea678cf Fix frozen string crash in new_msg; remove redundant inner titles
Bug: frozen_string_literal: true makes '' a frozen String literal.
@input << ch raised FrozenError immediately on any keystroke, causing
the TUI runner to exit. Fixed by using +'' (mutable string) for @input
everywhere it is initialised or reset.

Also removed the section header text lines that were being drawn inside
each page's content area — the page title is already embedded in the
right panel's box border, so the inner header was redundant.

Adjusted content offsets and scroll window sizes to use the reclaimed row.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 22:02:46 +02:00
5c9cb269fb Redesign TUI with DOS Navigator look and two-panel layout
Full blue background (screen_fill), double-line bordered panels side
by side: left panel for the menu, right panel for content. The right
panel's title bar shows the current page name, username and online count.

Color theme (THEME constant) maps to combined fg+bg ANSI codes so all
elements look native on the blue background: bright cyan borders, white
normal text, yellow labels, black-on-cyan selection highlights.

Status bar at the bottom mimics the NC function key bar with bright key
labels on cyan background.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:53:18 +02:00
2a4aafd96f Rewrite TUI using page-based DSL
Each BBS screen is now a declarative `page` block. Shared rendering
logic (wiki list, scroll helpers, wiki page opening) lives in a `helpers`
block. The persistent chrome (header bar, sidebar menu, footer) is
defined once in a `chrome` block rendered every frame.

The main flow no longer reaches into runner internals: context flows
through naturally via the updated rubbs `tui` step.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-11 21:32:42 +02:00
6c9b249a3a tui version 2026-05-11 21:06:59 +02:00
4244a2cc12 Add entrypoint.sh that updates rubbs before starting
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-30 10:37:18 +02:00
3a90dd541e Move COLORS and c() to BBS::Color in rubbs
include BBS::Color at top level — c() available everywhere
including instance_eval blocks and OutputBuilder.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-30 10:34:47 +02:00
304c130fa9 Replace module C with COLORS hash
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-30 10:31:37 +02:00
ac77420888 Pin Gemfile.lock; restore proper Docker cache invalidation
Docker can't detect external git changes — Gemfile.lock change is
the signal. Workflow: after pushing rubbs, run bundle update bbs
and commit the new Gemfile.lock.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-30 10:07:06 +02:00
bafd7e1f25 Fix: bundle install resolves fresh without lockfile
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-30 09:59:40 +02:00
ac56b4974c Always pull latest rubbs on docker build
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-30 09:58:56 +02:00
78184ad62f Add OutputBuilder DSL for catalog rendering
sep / line / cols / para / badge methods replace manual string
concatenation. badges auto-flush before the next content line.
render { } wraps a block in the builder via instance_eval.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-30 09:55:13 +02:00
390142d892 Add c(:color, text) helper, replace all inline ANSI constants
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-30 09:50:48 +02:00
9ab2e09b3f Add Model/Repository postfix to all class and file names
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-30 09:40:14 +02:00
6856b073f6 Introduce model/ and repository/ structure under lib/
Models: Message, WikiPage, Game (typed structs instead of raw hashes)
Repositories: MessageBoard, OnlineUsers, WikiClient, CatalogClient
bbs.rb uses attribute access (page.title, game.play_path, …) throughout

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-30 09:37:57 +02:00
75d1063572 Replace display.rb with DSL primitives in bbs.rb
All content rendering now lives in bbs.rb via the rubbs DSL.
fetch/pick handle wiki list + article drill-down; output handles
the multi-line game catalog. display.rb is gone.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-30 09:28:21 +02:00
5dfc2ed5c9 remove unused compose file, add new README 2026-04-28 23:06:26 +02:00
f72fbb7581 remove golang related files 2026-04-28 23:04:12 +02:00
4ac5f1632f ruby version 2026-04-28 22:58:37 +02:00
6f6dcd062f wiki fix 2026-03-13 17:15:45 +01:00
454e625ef3 rename color constants 2026-03-11 21:14:56 +01:00
2157425b24 refact round 3 2026-03-11 20:42:07 +01:00
Zsolt Tasnadi
d843df816a refact round 2 2026-03-11 07:28:14 +01:00
e837a9a04e refact 2026-03-10 21:26:04 +01:00
b8e6df3a04 initial commit 2026-03-10 18:54:17 +01:00