mirror of
https://github.com/tenrok/vue-context.git
synced 2026-06-23 22:30:33 +03:00
Accessibility (#22)
This commit is contained in:
@@ -7,16 +7,12 @@
|
||||
[](https://vuejs.org)
|
||||
|
||||
`vue-context` provides a simple yet flexible context menu for Vue. It is styled for the standard `<ul>` tag, but any menu template can be used.
|
||||
The menu is lightweight with its only dependency being `vue-clickaway`. The menu has some basic styles applied to it but they can be easily
|
||||
The menu is lightweight with its only dependencies being `vue-clickaway` and `core-js`. The menu has some basic styles applied to it but they can be easily
|
||||
overridden by your own styles.
|
||||
<br><br>
|
||||
The menu disappears when you expect by utilizing `vue-clickaway` and it also optionally disappears when clicked on.
|
||||
|
||||

|
||||
|
||||
## Note
|
||||
The API has changed since the last major release. Check [v2 documentation](https://vue-context.com/docs/2.0/overview)
|
||||
if you use the old version.
|
||||

|
||||
|
||||
## Getting Started
|
||||
|
||||
@@ -63,10 +59,12 @@ Next add an element to the page that will trigger the context menu to appear, an
|
||||
</div>
|
||||
|
||||
<vue-context ref="menu">
|
||||
<ul>
|
||||
<li @click="onClick($event.target.innerText)">Option 1</li>
|
||||
<li @click="onClick($event.target.innerText)">Option 2</li>
|
||||
</ul>
|
||||
<li>
|
||||
<a href="#" @click.prevent="onClick($event.target.innerText)">Option 1</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" @click.prevent="onClick($event.target.innerText)">Option 2</a>
|
||||
</li>
|
||||
</vue-context>
|
||||
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user