Add hyperlink-vs-button rule; register new contracts in router

- controls-selection: forbid hyperlinks for opening modals/elements
  unless explicitly requested; buttons required instead.
- AGENT-BOOTSTRAP: add router entries for hardware-ingest-json and
  submodule-integration contracts (lint was failing without them).
This commit is contained in:
Mikhail Chusavitin
2026-08-18 17:07:04 +03:00
parent 1977730d93
commit e092fea98f
2 changed files with 8 additions and 1 deletions
+4
View File
@@ -41,6 +41,8 @@ Read additional contracts by task type:
`go-api`, `go-background-tasks`, `go-logging` `go-api`, `go-background-tasks`, `go-logging`
- DB queries, migrations, backups, startup DB safety: - DB queries, migrations, backups, startup DB safety:
`go-database`, `backup-management` `go-database`, `backup-management`
- Hardware inventory ingest, Redfish/CMDB import payloads:
`hardware-ingest-json`
- Local-first desktop migration/recovery: - Local-first desktop migration/recovery:
`local-first-recovery` `local-first-recovery`
- Tables, bulk actions, filters, pagination: - Tables, bulk actions, filters, pagination:
@@ -65,6 +67,8 @@ Read additional contracts by task type:
`secret-management` `secret-management`
- Project architecture documentation rules: - Project architecture documentation rules:
`go-project-bible` `go-project-bible`
- Git submodules, shared library/vendored dependency integration:
`submodule-integration`
## Default Rule ## Default Rule
@@ -1,6 +1,6 @@
# Contract: Controls + Selection # Contract: Controls + Selection
Version: 1.1 Version: 1.2
## Shared Base ## Shared Base
@@ -16,6 +16,9 @@ Version: 1.1
- Button text should describe the action outcome, not implementation detail. - Button text should describe the action outcome, not implementation detail.
- Buttons are text-first; icons are optional and must not replace labels on primary/danger actions. - Buttons are text-first; icons are optional and must not replace labels on primary/danger actions.
- Base examples must show both `disabled` and `loading` states. - Base examples must show both `disabled` and `loading` states.
- Do not use a hyperlink (`<a>`/link-styled text) to open a modal, drawer, detail view, or any
other in-page element. Use a `button` (or button-styled control) instead, unless the user
explicitly asks for a hyperlink. Hyperlinks are reserved for navigation to another URL/page.
## Checkbox Selection ## Checkbox Selection