@ohhwells/bridge 0.1.52 → 0.1.53
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.
- package/README.md +12 -1
- package/dist/index.cjs +374 -290
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +154 -70
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -194,12 +194,23 @@ For links whose **destination URL** is edited in the canvas, use a plain `<a>` w
|
|
|
194
194
|
</a>
|
|
195
195
|
```
|
|
196
196
|
|
|
197
|
+
Section / body CTAs use the same two-phase select + Edit-link toolbar with `data-ohw-role="button"` (preferred). `navbar-button` remains supported as an alias for nav header CTAs:
|
|
198
|
+
|
|
199
|
+
```tsx
|
|
200
|
+
<a href="/contact" data-ohw-href-key="hero-cta-href" data-ohw-role="button" data-ohw-drag-disabled="true">
|
|
201
|
+
<span data-ohw-editable="text" data-ohw-key="hero-cta-label">
|
|
202
|
+
Get started
|
|
203
|
+
</span>
|
|
204
|
+
</a>
|
|
205
|
+
```
|
|
206
|
+
|
|
197
207
|
| Attribute | Purpose |
|
|
198
208
|
|-----------|---------|
|
|
199
209
|
| `data-ohw-href-key` | Storage key for the link destination |
|
|
200
210
|
| `href` | Default URL for SSR / first paint |
|
|
201
211
|
| `data-ohw-key` + `data-ohw-editable` on inner span | Editable label text |
|
|
202
|
-
| `data-ohw-role="
|
|
212
|
+
| `data-ohw-role="button"` | Section CTA — two-phase select + link-action toolbar (no reorder/More) |
|
|
213
|
+
| `data-ohw-role="navbar-button"` | Alias of `button` for navbar / header CTAs |
|
|
203
214
|
|
|
204
215
|
The bridge persists and restores `href` values (including after React re-renders). No template-side wrapper component is required.
|
|
205
216
|
|