Assets
Class Assets
Source
File: src/Tickets_Wallet_Plus/Assets.php
class Assets extends Controller {
/**
* @inheritDoc
*/
public function do_register(): void {
$plugin = tribe( Plugin::class );
tribe_asset(
$plugin,
'tec-tickets-wallet-plus-passes-css',
'passes.css',
[],
null,
[
'groups' => [
'tribe-tickets-rsvp',
'tribe-tickets-page-assets',
'tec-tickets-wallet-plus-order-page-assets',
],
]
);
tribe_asset(
$plugin,
'tec-tickets-wallet-plus-admin-settings-css',
'settings.css',
[],
'admin_enqueue_scripts',
[
'conditional' => [ $this, 'is_admin_settings' ]
]
);
}
/**
* Check if the current page is the admin settings page.
*
* @since 1.0.0
*
*
* @return bool
*/
public function is_admin_settings(): bool {
return $this->container->make( Tickets_Settings::class )->is_tec_tickets_settings();
}
/**
* @inheritDoc
*/
public function unregister(): void {
}
}
Changelog
| Version | Description |
|---|---|
| 1.0.0 | Introduced. |
Methods
- do_register
- is_admin_settings — Check if the current page is the admin settings page.
- unregister