-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcustomtheme.php
More file actions
45 lines (38 loc) · 1.22 KB
/
customtheme.php
File metadata and controls
45 lines (38 loc) · 1.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
<?php
require_once 'customtheme.civix.php';
use CRM_Customtheme_ExtensionUtil as E;
/**
* Implements hook_civicrm_config().
*
* @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_config/
*/
function customtheme_civicrm_config(&$config): void {
_customtheme_civix_civicrm_config($config);
}
/**
* Implements hook_civicrm_install().
*
* @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_install
*/
function customtheme_civicrm_install(): void {
_customtheme_civix_civicrm_install();
}
/**
* Implements hook_civicrm_enable().
*
* @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_enable
*/
function customtheme_civicrm_enable(): void {
_customtheme_civix_civicrm_enable();
}
/**
* Implements hook_civicrm_coreResourceList().
*/
function customtheme_civicrm_coreResourceList(&$list, $region) {
$resources = CRM_Core_Resources::singleton();
// Load parent theme CSS first
$resources->addStyleFile('riverlea', 'streams/walbrook/css/_variables.css', -10, $region);
$resources->addStyleFile('riverlea', 'streams/walbrook/css/civicrm.css', -10, $region);
// Then load your subtheme CSS
$resources->addStyleFile('com.skvare.customtheme', '/css/civicrm_custom.css', 0, $region);
}