pfeifferNet

nui

Table of Contents

Functions

register_styles()  : void
Register styles.
enqueue_assets()  : void
Enqueue the scripts and styles.
requeue_child_assets()  : void
Dequeue and enqueue the child theme styles.
get_asset_path()  : string
Return the asset filepath.
get_asset_uri()  : string
Return the asset URI.
get_asset_version()  : string
Return the version.
editor_iframe_styles()  : void
Enqueue styles to the editor iframe.
testing_body_classes()  : array<string|int, mixed>
Add "testing" body class.
theme_support()  : void
Override theme supported features.
page_excerpt_support()  : void
Enable excerpts for pages.

Functions

register_styles()

Register styles.

register_styles() : void
  • The asset must NOT start with a leading slash. It is relative to the assets directory.
Tags
since
0.0.0
since
0.2.0

Improve style dependencies.

since
2.0.0

Improve asset handling and versioning.

enqueue_assets()

Enqueue the scripts and styles.

enqueue_assets() : void
Tags
since
0.0.0

requeue_child_assets()

Dequeue and enqueue the child theme styles.

requeue_child_assets() : void
  • This is necessary to ensure the child theme stylesheet is enqueued after the parent theme styles, and thus can override them.
Tags
since
2.0.0

get_asset_path()

Return the asset filepath.

get_asset_path(string $asset) : string
Parameters
$asset : string

The target asset - no leading slash.

Tags
since
0.2.0
since
2.0.0

Improve asset handling and versioning.

Return values
string

The resource filesystem path.

get_asset_uri()

Return the asset URI.

get_asset_uri(string $asset) : string
Parameters
$asset : string

The target asset - no leading slash.

Tags
since
0.2.0
since
2.0.0

Improve asset handling and versioning.

Return values
string

The resource URL.

get_asset_version()

Return the version.

get_asset_version(string $asset) : string
Parameters
$asset : string

The fully qualified server file path of the target asset.

Tags
since
0.0.0
Return values
string

The resource version.

editor_iframe_styles()

Enqueue styles to the editor iframe.

editor_iframe_styles() : void
  • This is needed to include the common CSS definitions in the editor.
  • This likely belongs in pNet->admin->class-assets.
Tags
since
2.0.0

testing_body_classes()

Add "testing" body class.

testing_body_classes(array<string|int, mixed> $classes) : array<string|int, mixed>
  • Use developer tools to remove this class to see normal styles.
Parameters
$classes : array<string|int, mixed>

Existing body classes.

Tags
since
2.0.0
Return values
array<string|int, mixed>

Modified body classes.

theme_support()

Override theme supported features.

theme_support() : void
Tags
since
0.0.0

page_excerpt_support()

Enable excerpts for pages.

page_excerpt_support() : void
Tags
since
0.0.0

        
On this page

Search results