Download the PHP package 10quality/wpmvc-addon-resources without Composer
On this page you can find all versions of the php package 10quality/wpmvc-addon-resources. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package wpmvc-addon-resources
WordPress MVC add-on resources
This package provides resources (in the form of assets) that may be shared by different add-ons or WordPress MVC projects.
Setup
Via composer
Install the package via composer:
Via composer.json
Add this package as your add-on dependencies ("require"
):
And run:
Resources
- Font Awesome v4 (css and fonts).
- Select2 (js, css and i18n) and initializer script.
- Spectrum colorpicker (js, css and i18n) and initializer script.
- Datetimepicker (js and css) and initializer script.
- jQuery UI Datepicker (css) and initializer script.
- WP Media uploader (js) and scripts.
- Radio group (custom css).
- Choose (custom css).
- Switch (custom js and css).
- Hide/show (custom js).
- Repeater (custom js).
Usage
This package provides 2 global functions:
wpmvc_register_addon_resource
wpmvc_register_addon_resource()
is used to register the asset.
And:
wpmvc_enqueue_addon_resource()
is used to force enqueue the asset.
Resources list
Resource ID | Description | Type |
---|---|---|
font-awesome |
Hide and show resources. | css |
select2 |
Select2 resources. | css, js |
spectrum |
Spectrum colorpicker resources. | css, js |
datetimepicker |
jQuery datetimepicker resources. | css, js |
jquery-ui-datepicker |
jQuery UI datepicker resources. | css |
wp-media-uploader |
WordPress media uploader resources. | js |
wpmvc-hideshow |
Hide and show resources. | js |
wpmvc-repeater |
Repeater resources (depends on wpmvc-hideshow ). |
css, js |
wpmvc-choose |
Choose resources. | css |
wpmvc-radio |
Redio group resources. | css |
wpmvc-switch |
Redio group resources. | css, js |
wpmvc-select2 |
Select2 implementation resources (depends on select2 ). |
css, js |
wpmvc-colorpicker |
Colorpicker implementation resources (depends on spectrum ). |
js |
wpmvc-datepicker |
Datepicker implementation resources (depends on jquery-ui-datepicker ). |
js |
wpmvc-datetimepicker |
Datetimepicker implementation resources (depends on datetimepicker ). |
js |
wpmvc-media |
Media implementation resources (depends on wp-media-uploader ). |
css, js |
Samples:
Or:
You can also use regular WordPress enqueue functions after the resources have been registered:
Coding Guidelines
PSR-2 coding guidelines.
License
MIT License. (c) 2020 10 Quality.
All versions of wpmvc-addon-resources with dependencies
10quality/wpmvc-core Version >=3.1.0
10quality/wpmvc-addon Version 1.0.*