Status |
---|
colour | Yellow |
---|
title | RELEASE 2.6.0 OR ABOVE |
---|
|
public setLock(selector: String)
It limits editing by specifying a DOM selector.
When applied, it is represented by a lock icon (
HTML |
---|
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="16px"
height="16px" viewBox="0 0 16 16" enable-background="new 0 0 16 16" xml:space="preserve">
<rect x="3" y="13.009" display="inline" fill="#596468" width="10" height="1.995"/>
<rect x="3" y="10.061" display="inline" fill="#EA4952" width="10" height="1.996"/>
<rect x="3" y="7.055" display="inline" fill="#596468" width="10" height="1.996"/>
<path display="inline" fill="#596468" d="M12.018,5c0-2.207-1.799-3.996-4.017-3.996c-2.22,0-4.018,1.789-4.018,4.401v2.802h0.958
V5.405c0-2.086,1.368-3.448,3.06-3.448c1.688,0,3.058,1.36,3.058,3.042v2.595c0,0.264,0.213,0.476,0.482,0.476
c0.262,0,0.477-0.212,0.477-0.476V5L12.018,5z"/>
</svg>
|
).
Applicable to
- DIV
- Elements with "se-contents" and "se-div" classes specified
- TABLE
- TD
- TH
Params: selector
Name | Type | Description |
---|
selector | string | Selectors to import the DOM to limit editing |
Example:
Code Block |
---|
|
window.editor.setLock('#lock_element_Id');
window.editor.setLock('.not_editable'); |
Source view
You can add 'se-unlock' class to the applied element in the Source View Mode of the editor.
Experiencing
Include Page |
---|
| SEDEMO:Partial Editing Restrictions |
---|
| SEDEMO:Partial Editing Restrictions |
---|
|