Skip to content

Commit 42a84ae

Browse files
committed
Update README.md
1 parent e89d1bb commit 42a84ae

File tree

1 file changed

+10
-7
lines changed

1 file changed

+10
-7
lines changed

README.md

+10-7
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ See also the [Change Log](https://github.com/mar10/jquery-ui-contextmenu/blob/ma
2323

2424
## Demo
2525

26-
[Live demo page](http://wwwendt.de/tech/demo/jquery-contextmenu/demo/):
26+
[Live demo page](http://wwwendt.de/tech/demo/jquery-contextmenu/demo/):<br>
2727
[ ![sample](demo/teaser.png?raw=true) ](http://wwwendt.de/tech/demo/jquery-contextmenu/demo/ "Live demo")
2828

2929

@@ -130,17 +130,19 @@ see [jQueryUI menu] for details:
130130
</ul>
131131
```
132132

133-
**Note:** until jQuery UI 1.10 the use of anchors (`<a>`) in menu items was required:
133+
**Note:** until and including jQuery UI 1.10 the use of anchors (`<a>`) in menu items was required:
134134
```html
135135
<ul id="options" class="ui-helper-hidden">
136136
<li data-command="copy"><a href="#"><span class="ui-icon ui-icon-copy"></span>Copy</a>
137+
...
137138
</ul>
138139
```
139140

140141

141142
### Modify the menu depending on the context
142143

143-
The menu can be modified before display in order to reflect the current context.
144+
Often we need to modify the menu before it is displayed, in order to reflect the current context.
145+
This can be done in the `beforeOpen` event:
144146

145147
```js
146148
$(document).contextmenu({
@@ -398,7 +400,8 @@ $(...).contextmenu({
398400
});
399401
```
400402
401-
Follwing a list of available menu definition properties:
403+
Following a list of available menu definition properties:
404+
402405
<dl>
403406
<dt>action</dt>
404407
<dd>
@@ -408,7 +411,7 @@ Follwing a list of available menu definition properties:
408411
<dt>addClass</dt>
409412
<dd>
410413
Type: <code>String</code>, default: <code>""</code><br>
411-
Additional class name(s) to be added to the entries &ltli> element.
414+
Additional class name(s) to be added to the entries &lt;li> element.
412415
Separate multiple class names with a space.<br>
413416
Custom CSS may be applied like <code>.ui-menu .my-class { color: red; }</code>.
414417
</dd>
@@ -438,11 +441,11 @@ Follwing a list of available menu definition properties:
438441
</dd>
439442
<dt>uiIcon</dt>
440443
<dd>
441-
Type: <code>String</code>, default: ""<br>
444+
Type: <code>String</code>, default: <code>""</code><br>
442445
If defined, an icon is added to the menu entry. For example passing
443446
<code>"ui-icon-copy"</code> will generate this element:
444447
<code>&lt;span class='ui-icon ui-icon-copy' /></code>.<br>
445-
See also <a href="http://api.jqueryui.com/theming/icons/">Icon Overview</a>.
448+
See also the <a href="http://api.jqueryui.com/theming/icons/">Icon Overview</a>.
446449
</dd>
447450
448451
</dl>

0 commit comments

Comments
 (0)