Skip to content

Commit c711310

Browse files
committed
docs: update README with data-triggle-target description and usage example
1 parent 34c041b commit c711310

File tree

1 file changed

+17
-17
lines changed

1 file changed

+17
-17
lines changed

README.md

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -145,23 +145,23 @@ You can animate elements using the following trigger types via `data-triggle`:
145145

146146
## Attributes Reference
147147

148-
| Attribute | Type | Description |
149-
| -------------------------- | ------------ | ------------------------------------------------------------------ |
150-
| `data-triggle` | `string` | Comma-separated events (e.g. `click,mouseenter`) |
151-
| `data-triggle-class` | `string` | Space-separated CSS classes to animate |
152-
| `data-triggle-reset` | `true/false` | Removes animation class after it finishes |
153-
| `data-triggle-delay` | `string` | CSS `animation-delay` (e.g., `0.5s`) |
154-
| `data-triggle-duration` | `string` | CSS `animation-duration` (e.g., `1s`) |
155-
| `data-triggle-toggle` | `true/false` | Toggles class on and off (instead of just adding) |
156-
| `data-triggle-once` | `true/false` | Triggers animation only once |
157-
| `data-triggle-target` | `string` | CSS selector for the element to animate (defaults to self) |
158-
| `data-triggle-key` | `string` | Keyboard filter (e.g. `enter`, `ctrl+s`, `a*`) |
159-
| `data-triggle-next` | `string` | CSS selector of element to animate **after this one finishes** |
160-
| `data-triggle-chain-delay` | `number` | Delay (in ms) before triggering `data-triggle-next` |
161-
| `data-triggle-group` | `string` | Group name to animate multiple elements together |
162-
| `data-triggle-stagger` | `number` | Delay (in ms) between each group's element animation |
163-
| `data-triggle-scroll` | `true/false` | Use IntersectionObserver to animate when element scrolls into view |
164-
| `data-triggle-chain-loop` | `true` | Enables infinite looping between chained elements |
148+
| Attribute | Type | Description |
149+
| -------------------------- | ------------ | ---------------------------------------------------------------------------------------------------- |
150+
| `data-triggle` | `string` | Comma-separated events (e.g. `click,mouseenter`) |
151+
| `data-triggle-class` | `string` | Space-separated CSS classes to animate |
152+
| `data-triggle-reset` | `true/false` | Removes animation class after it finishes |
153+
| `data-triggle-delay` | `string` | CSS `animation-delay` (e.g., `0.5s`) |
154+
| `data-triggle-duration` | `string` | CSS `animation-duration` (e.g., `1s`) |
155+
| `data-triggle-toggle` | `true/false` | Toggles class on and off (instead of just adding) |
156+
| `data-triggle-once` | `true/false` | Triggers animation only once |
157+
| `data-triggle-target` | `string` | CSS selector(s) for external element(s) to animate instead of the trigger itself (e.g. `.box1, #id`) |
158+
| `data-triggle-key` | `string` | Keyboard filter (e.g. `enter`, `ctrl+s`, `a*`) |
159+
| `data-triggle-next` | `string` | CSS selector of element to animate **after this one finishes** |
160+
| `data-triggle-chain-delay` | `number` | Delay (in ms) before triggering `data-triggle-next` |
161+
| `data-triggle-group` | `string` | Group name to animate multiple elements together |
162+
| `data-triggle-stagger` | `number` | Delay (in ms) between each group's element animation |
163+
| `data-triggle-scroll` | `true/false` | Use IntersectionObserver to animate when element scrolls into view |
164+
| `data-triggle-chain-loop` | `true` | Enables infinite looping between chained elements |
165165

166166
## Hover with Delay and Duration
167167

0 commit comments

Comments
 (0)