stimeo-ui 0.1.0.pre.alpha.1 → 0.1.0.pre.beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +75 -0
- data/README.md +119 -6
- data/dist/cable/index.js +563 -0
- data/dist/controllers/combobox_controller.js +16 -0
- data/dist/controllers/count_up_controller.js +86 -0
- data/dist/controllers/form_validation_controller.js +62 -1
- data/dist/controllers/hover_card_controller.js +40 -5
- data/dist/controllers/intersection_controller.js +173 -0
- data/dist/controllers/lazy_frame_controller.js +57 -9
- data/dist/controllers/listbox_controller.js +13 -0
- data/dist/controllers/optimistic_controller.js +58 -0
- data/dist/controllers/pointer_drag_controller.js +406 -0
- data/dist/controllers/popover_controller.js +39 -0
- data/dist/controllers/portal_controller.js +62 -6
- data/dist/controllers/reading_progress_controller.js +49 -0
- data/dist/controllers/roving_controller.js +1 -0
- data/dist/controllers/scrollspy_controller.js +65 -19
- data/dist/controllers/smart_sticky_header_controller.js +76 -0
- data/dist/controllers/sortable_controller.js +167 -0
- data/dist/controllers/sticky_observer_controller.js +60 -15
- data/dist/controllers/submit_once_controller.js +23 -2
- data/dist/controllers/tabs_controller.js +1 -1
- data/dist/controllers/tooltip_controller.js +44 -5
- data/dist/index.js +1321 -83
- data/lib/stimeo/ui/version.rb +3 -3
- metadata +14 -4
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 43ec968d086165fbfd9daeda12d003a6cf0cb9e8375a9abfb34924aab3383959
|
|
4
|
+
data.tar.gz: 8c1fde6bff018d4f47ac745df3e18b2eaaa95d3658ea1ce05fd03bda5b35dc46
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0ab3a420ebc50b56abce77cd1a4b36be4c3891d4495bd4c2ab8961a42978dc6f79443822ab389dea100b308d236064e76c2e3a0445e0daeb260e7ce4653c71d1
|
|
7
|
+
data.tar.gz: 1ffc55e37df21a692a21da69f4e98b303ca1600bc57286a132584425392be40f654ba6570227c70436934f5b0ca2bf3d0a5dee9c39c2f24f61e70632e2992751
|
data/CHANGELOG.md
ADDED
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project are documented here.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
+
While the version is `0.x`, the public API (the `stimeo--*` data attributes) may
|
|
8
|
+
change between releases.
|
|
9
|
+
|
|
10
|
+
## [0.1.0-beta.2] - 2026-07-12
|
|
11
|
+
|
|
12
|
+
The Inspector grows two new faces: an MCP server for AI coding agents and a
|
|
13
|
+
VS Code extension that checks markup as you type.
|
|
14
|
+
|
|
15
|
+
### Added
|
|
16
|
+
|
|
17
|
+
- **MCP server** (`stimeo-ui mcp`): the Inspector engine now runs as a Model
|
|
18
|
+
Context Protocol server, so AI coding agents (Claude Code, Cursor, …) can
|
|
19
|
+
discover the catalog, fetch a controller's exact contract and verified
|
|
20
|
+
example markup, and check generated HTML/ERB before presenting it. Four
|
|
21
|
+
read-only tools (`stimeo_check`, `stimeo_catalog`, `stimeo_controller`,
|
|
22
|
+
`stimeo_example`), preloadable resources (`stimeo://manifest`,
|
|
23
|
+
`stimeo://examples/<id>`), and two prompts (`stimeo_build_ui`,
|
|
24
|
+
`stimeo_fix_markup`) — hand-written like the rest of the Inspector, adding
|
|
25
|
+
zero runtime dependencies.
|
|
26
|
+
- **VS Code extension — Stimeo UI Inspector**: live diagnostics, quick fixes,
|
|
27
|
+
manifest-driven completions, and contract hovers for `stimeo--*` markup in
|
|
28
|
+
HTML/ERB, published on the
|
|
29
|
+
[Visual Studio Marketplace](https://marketplace.visualstudio.com/items?itemName=stimeo-labs.stimeo-ui)
|
|
30
|
+
and [Open VSX](https://open-vsx.org/extension/stimeo-labs/stimeo-ui).
|
|
31
|
+
- Ten new components — the catalog now spans **111 controllers**: count-up,
|
|
32
|
+
intersection, optimistic, pointer-drag, reading-progress,
|
|
33
|
+
smart-sticky-header, sortable, and — backed by Action Cable — live-counter,
|
|
34
|
+
presence, and typing-indicator.
|
|
35
|
+
- pointer-drag: opt-in follow mode that translates the dragged element while
|
|
36
|
+
the pointer moves.
|
|
37
|
+
- Inspector: checks now also cover keyboard-focusability prerequisites,
|
|
38
|
+
controller-managed ARIA that must not be hardcoded, and conditional
|
|
39
|
+
cross-controller composition rules (manifest schema v5). Verified example
|
|
40
|
+
markup for every component ships with the package.
|
|
41
|
+
|
|
42
|
+
### Fixed
|
|
43
|
+
|
|
44
|
+
- listbox, combobox, and multi-select: the active option now scrolls into
|
|
45
|
+
view while navigating with the keyboard (`aria-activedescendant` lists
|
|
46
|
+
keep the highlighted option visible).
|
|
47
|
+
|
|
48
|
+
## [0.1.0-beta.1] - 2026-06-30
|
|
49
|
+
|
|
50
|
+
First beta. The 101 core components meet the accessibility quality bar, so the
|
|
51
|
+
library graduates from the `alpha` channel to `beta`.
|
|
52
|
+
|
|
53
|
+
### Added
|
|
54
|
+
|
|
55
|
+
- multi-select: emits named hidden fields so the current selection submits with
|
|
56
|
+
the form, no application JavaScript required.
|
|
57
|
+
- form-validation: declarative per-constraint messages and a `disallow=whitespace`
|
|
58
|
+
rule.
|
|
59
|
+
- hover-card, tooltip, and popover: opt-in dismiss when the page scrolls.
|
|
60
|
+
- submit-once: auto-subscribes to `turbo:submit-start` on connect.
|
|
61
|
+
|
|
62
|
+
### Fixed
|
|
63
|
+
|
|
64
|
+
- Ignore keydown events fired during IME composition in tags-input, multi-select,
|
|
65
|
+
and combobox, so selecting a candidate no longer triggers shortcuts.
|
|
66
|
+
|
|
67
|
+
## [0.1.0-alpha.1] - 2026-06-20
|
|
68
|
+
|
|
69
|
+
Initial public alpha: 101 behavior-only, accessible Stimulus controllers driven
|
|
70
|
+
by `data-*` attributes, shipping no CSS. Published to npm (with provenance) and
|
|
71
|
+
RubyGems.
|
|
72
|
+
|
|
73
|
+
[0.1.0-beta.2]: https://github.com/taiyaky/stimeo-ui/releases/tag/v0.1.0-beta.2
|
|
74
|
+
[0.1.0-beta.1]: https://github.com/taiyaky/stimeo-ui/releases/tag/v0.1.0-beta.1
|
|
75
|
+
[0.1.0-alpha.1]: https://github.com/taiyaky/stimeo-ui/releases/tag/v0.1.0-alpha.1
|
data/README.md
CHANGED
|
@@ -1,4 +1,13 @@
|
|
|
1
|
-
|
|
1
|
+
<h1 align="center">
|
|
2
|
+
<picture>
|
|
3
|
+
<source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/taiyaky/stimeo-ui/main/assets/logo-wordmark-dark.png">
|
|
4
|
+
<img alt="Stimeo UI" src="https://raw.githubusercontent.com/taiyaky/stimeo-ui/main/assets/logo-wordmark.png" width="240">
|
|
5
|
+
</picture>
|
|
6
|
+
</h1>
|
|
7
|
+
|
|
8
|
+
<p align="center"><a href="https://stimeo-labs.com"><strong>Live demo (beta) →</strong></a></p>
|
|
9
|
+
|
|
10
|
+
[](https://github.com/taiyaky/stimeo-ui/actions/workflows/ci.yml) [](https://www.npmjs.com/package/stimeo-ui) [](https://rubygems.org/gems/stimeo-ui) [](LICENSE)
|
|
2
11
|
|
|
3
12
|
**Headless Stimulus UI framework for Ruby on Rails.** Stimeo UI ships *behavior*
|
|
4
13
|
— ARIA state, keyboard interaction, focus management, Turbo resilience — as
|
|
@@ -14,7 +23,7 @@ owns the look entirely.
|
|
|
14
23
|
- Public controller identifiers use the `stimeo--` namespace (e.g.
|
|
15
24
|
`stimeo--dropdown`).
|
|
16
25
|
|
|
17
|
-
> Status: **
|
|
26
|
+
> Status: **beta** (`0.x`). The `stimeo--*` attribute API may still change before
|
|
18
27
|
> 1.0 — pin your version.
|
|
19
28
|
|
|
20
29
|
## Install
|
|
@@ -22,7 +31,7 @@ owns the look entirely.
|
|
|
22
31
|
### Rails with importmap (recommended)
|
|
23
32
|
|
|
24
33
|
```bash
|
|
25
|
-
bundle add stimeo-ui
|
|
34
|
+
bundle add stimeo-ui --version "0.1.0.pre.beta.2"
|
|
26
35
|
bin/rails generate stimeo:install
|
|
27
36
|
```
|
|
28
37
|
|
|
@@ -41,7 +50,7 @@ Stimulus application. Then drive components from HTML alone:
|
|
|
41
50
|
### npm (jsbundling or any bundler)
|
|
42
51
|
|
|
43
52
|
```bash
|
|
44
|
-
npm install stimeo-ui @hotwired/stimulus
|
|
53
|
+
npm install stimeo-ui@beta @hotwired/stimulus
|
|
45
54
|
```
|
|
46
55
|
|
|
47
56
|
```js
|
|
@@ -61,12 +70,116 @@ Need only a few controllers? Import them individually from
|
|
|
61
70
|
- **No CSS is shipped.** Style the components yourself; controllers only toggle
|
|
62
71
|
ARIA state and `data-*` hooks.
|
|
63
72
|
|
|
73
|
+
## Linting
|
|
74
|
+
|
|
75
|
+
Stimeo UI is headless, so **you** author the WAI-ARIA roles, states, and
|
|
76
|
+
properties — and some controllers use explicit roles as selector contracts (the
|
|
77
|
+
data-grid finds its rows via `[role="row"]`). Your markup therefore contains
|
|
78
|
+
valid custom-widget ARIA such as `<ul role="menu">`, `<div role="radio">`, and
|
|
79
|
+
`<table role="grid">…<td role="gridcell">`.
|
|
80
|
+
|
|
81
|
+
Strict static a11y linters — Biome's `recommended` preset (≥ 2.5) and
|
|
82
|
+
`eslint-plugin-jsx-a11y` — report these valid
|
|
83
|
+
[APG](https://www.w3.org/WAI/ARIA/apg/) patterns as errors, because their
|
|
84
|
+
heuristics assume native semantic elements (there is no native equivalent for a
|
|
85
|
+
custom, fully-stylable radio). Relax the conflicting rules **only for the paths
|
|
86
|
+
where you author Stimeo UI markup** — set `includes` to your own component
|
|
87
|
+
directories (the value below is a placeholder; adjust it to your layout) and
|
|
88
|
+
keep the rules on everywhere else. For Biome:
|
|
89
|
+
|
|
90
|
+
```json
|
|
91
|
+
{
|
|
92
|
+
"overrides": [
|
|
93
|
+
{
|
|
94
|
+
"includes": ["app/components/**"],
|
|
95
|
+
"linter": {
|
|
96
|
+
"rules": {
|
|
97
|
+
"a11y": {
|
|
98
|
+
"noNoninteractiveElementToInteractiveRole": "off",
|
|
99
|
+
"noRedundantRoles": "off",
|
|
100
|
+
"useSemanticElements": "off",
|
|
101
|
+
"useFocusableInteractive": "off",
|
|
102
|
+
"noNoninteractiveTabindex": "off"
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
]
|
|
108
|
+
}
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
The `eslint-plugin-jsx-a11y` equivalents are
|
|
112
|
+
`no-noninteractive-element-to-interactive-role`, `no-redundant-roles`,
|
|
113
|
+
`prefer-tag-over-role`, `interactive-supports-focus`, and
|
|
114
|
+
`no-noninteractive-tabindex`. These components' real accessibility is exercised
|
|
115
|
+
with axe-core and real screen readers in this project's own test suite.
|
|
116
|
+
|
|
117
|
+
## Inspector CLI & MCP server
|
|
118
|
+
|
|
119
|
+
Stimeo UI bundles a zero-dependency static checker for its own markup contract
|
|
120
|
+
— spelling of controllers/targets/values, required structure, and the ARIA
|
|
121
|
+
attributes you (the author) must supply:
|
|
122
|
+
|
|
123
|
+
```bash
|
|
124
|
+
npx stimeo-ui check app/views # check your templates (exit 1 on errors)
|
|
125
|
+
npx stimeo-ui catalog # list every controller's public API
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
Both commands accept `--json` for machine-readable output, so `check` drops
|
|
129
|
+
straight into CI.
|
|
130
|
+
|
|
131
|
+
The same engine runs as a **Model Context Protocol** server, so AI coding
|
|
132
|
+
agents (Claude Code, Cursor, …) can discover the catalog, fetch verified
|
|
133
|
+
reference markup, and validate generated HTML/ERB before presenting it:
|
|
134
|
+
|
|
135
|
+
```bash
|
|
136
|
+
claude mcp add stimeo -- npx -y stimeo-ui mcp
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
or in `.mcp.json` (Claude Code) / `.cursor/mcp.json` (Cursor):
|
|
140
|
+
|
|
141
|
+
```json
|
|
142
|
+
{
|
|
143
|
+
"mcpServers": {
|
|
144
|
+
"stimeo": {
|
|
145
|
+
"command": "npx",
|
|
146
|
+
"args": ["-y", "stimeo-ui", "mcp"]
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
```
|
|
151
|
+
|
|
152
|
+
It exposes four read-only tools — `stimeo_check` (validate a source string),
|
|
153
|
+
`stimeo_catalog`, `stimeo_controller` (one controller's full contract,
|
|
154
|
+
accessibility requirements included), and `stimeo_example` (verified example
|
|
155
|
+
markup: the official catalog demo under [`examples/`](examples/), bundled at
|
|
156
|
+
build time and guaranteed to pass the checker) — plus MCP resources
|
|
157
|
+
(`stimeo://manifest`, `stimeo://examples/<id>`) for preloading context without
|
|
158
|
+
a tool round-trip. The server reads only its bundled manifest and example
|
|
159
|
+
index; there are no write-capable tools.
|
|
160
|
+
|
|
161
|
+
The same checks also run **live in your editor**: the **Stimeo UI Inspector**
|
|
162
|
+
extension on the
|
|
163
|
+
[VS Code Marketplace](https://marketplace.visualstudio.com/items?itemName=stimeo-labs.stimeo-ui)
|
|
164
|
+
and [Open VSX](https://open-vsx.org/extension/stimeo-labs/stimeo-ui) (for Cursor /
|
|
165
|
+
VSCodium / Windsurf) gives as-you-type diagnostics, quick fixes, completions,
|
|
166
|
+
and contract hovers. No setup: the engine and a manifest snapshot are bundled,
|
|
167
|
+
and when your workspace installs `stimeo-ui`, the nearest installed version
|
|
168
|
+
wins — so diagnostics always match what you run.
|
|
169
|
+
|
|
64
170
|
## Contributing
|
|
65
171
|
|
|
66
172
|
Bug reports and feature requests are very welcome — please open a GitHub issue.
|
|
67
173
|
For code changes, open an issue first to discuss direction; see
|
|
68
174
|
[`CONTRIBUTING.md`](CONTRIBUTING.md).
|
|
69
175
|
|
|
70
|
-
## License
|
|
176
|
+
## License & Pro
|
|
177
|
+
|
|
178
|
+
Free and open source under the [MIT License](LICENSE) © Stimeo Labs. Every
|
|
179
|
+
component in this repository is Core, and the MIT grant is irrevocable.
|
|
71
180
|
|
|
72
|
-
|
|
181
|
+
**Stimeo UI Pro** — advanced behavior components that are the most work to
|
|
182
|
+
build yourself — is planned around 1.0 as a separately licensed commercial
|
|
183
|
+
track, built alongside (never carved out of) Core. For release news and
|
|
184
|
+
early access, join the waitlist at
|
|
185
|
+
[stimeo-labs.com/waitlist](https://stimeo-labs.com/waitlist).
|