Methods
getDefaultFolder(resolveopt) → {number}
Get the default folder and resolve if for example "Last queried folder".
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
resolve |
boolean |
<optional> |
true | If false the rmlOpts.others.defaultFolder is returned in raw, so -2 is possible for example |
Returns:
- Type
- number
handleClick()
Handle click on a menu item so the correct admin page can be called.
module:components/Breadcrumb()
Simple breadcrumbs with arrows and a home icon.
Properties:
Name | Type | Description |
---|---|---|
path |
Array.<string> | The pathes |
module:components/FolderBox()
A component showing a container for a folder option. For example the metabox
or manual placement for nodes (rearrange).
module:components/FolderSelector(target, input, props, store) → {object}
Create the folder selector in a given target.
Parameters:
Name | Type | Description |
---|---|---|
target |
HTMLElement | |
input |
HTMLElement | An input where the selected id is stored (usually input[type="hidden"]) |
props |
object | The properties for FolderSelector control |
store |
object |
Returns:
The created store
- Type
- object
module:hooks/permissions(element, selectedopt)
Show a locked button with tooltip in toolbar depending the permissions.
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
element |
module:AppTree | The AppTree | ||
selected |
object |
<optional> |
Current | The node |
module:others/mediaViews()
Modify the media-views.js components (Backbone) in a way
to make them compatible with the AIOT component.
module:others/optionsScreen()
Do the options screen with a nav bar (WordPress standard). This
nav bar is not ReactJS.
module:others/renderOrderMenu()
Render the order menu.
module:others/renderSortMenu()
Render the order menu.
patchWpMediaDialogCacheIssue()
WordPress 5.4 - 5.6 has issues with caching in their media dialog. Apply the official changeset for
the fix for WordPress 5.7 to old versions.
- See:
-
- https://core.trac.wordpress.org/ticket/52650
- https://core.trac.wordpress.org/changeset/50067
- https://github.com/WordPress/WordPress/blob/9ff4499281663b0c772787fd4a60538288f842e9/wp-includes/js/media-models.js#L923-L930
- https://github.com/WordPress/WordPress/blob/9ff4499281663b0c772787fd4a60538288f842e9/wp-includes/js/media-models.js#L1325-L1404
renderMenu()
A function which is called to render the dropdown menu.