Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
vartheme_claro
Manage
Activity
Members
Labels
Plan
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
project
vartheme_claro
Commits
a9fea7fa
Commit
a9fea7fa
authored
1 year ago
by
Rajab Natshah
Browse files
Options
Downloads
Patches
Plain Diff
Issue
#3367501
: Fix Error When Using Vartheme Claro 3.0.x on Drupal 10
parent
b179ca84
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
vartheme_claro.theme
+35
-0
35 additions, 0 deletions
vartheme_claro.theme
with
35 additions
and
0 deletions
vartheme_claro.theme
+
35
−
0
View file @
a9fea7fa
...
...
@@ -47,3 +47,38 @@ function vartheme_claro_preprocess_install_page(&$variables) {
// Attach install page library.
$variables
[
'#attached'
][
'library'
][]
=
$profile_name
.
'/install_page'
;
}
/**
* Implements hook_library_info_alter().
*/
function
vartheme_claro_library_info_alter
(
&
$libraries
,
$extension
)
{
if
(
$extension
===
'ckeditor'
&&
version_compare
(
Drupal
::
VERSION
,
'10.0.0'
,
'<'
)
&&
\Drupal
::
service
(
'theme_handler'
)
->
themeExists
(
'claro'
))
{
// Extend claro/ckeditor-editor with the ckeditor/drupal.ckeditor library.
if
(
isset
(
$libraries
[
'ckeditor/drupal.ckeditor'
]))
{
$libraries
[
'ckeditor/drupal.ckeditor'
][
'dependencies'
][]
=
'claro/ckeditor-editor'
;
}
// Extend ckeditor/drupal.ckeditor.admin with the claro/ckeditor-admin library.
if
(
isset
(
$libraries
[
'ckeditor/drupal.ckeditor.admin'
]))
{
$libraries
[
'ckeditor/drupal.ckeditor.admin'
][
'dependencies'
][]
=
'claro/ckeditor-admin'
;
}
// Extend ckeditor/ckeditor with the claro/ckeditor-dialog library.
if
(
isset
(
$libraries
[
'ckeditor/ckeditor'
]))
{
$libraries
[
'ckeditor/ckeditor'
][
'dependencies'
][]
=
'claro/ckeditor-dialog'
;
}
}
if
(
$extension
===
'core'
&&
version_compare
(
Drupal
::
VERSION
,
'10.0.0'
,
'<'
)
&&
\Drupal
::
service
(
'theme_handler'
)
->
themeExists
(
'claro'
))
{
// Extend core/ckeditor with the claro/ckeditor-dialog library.
if
(
isset
(
$libraries
[
'core/ckeditor'
]))
{
$libraries
[
'core/ckeditor'
][
'dependencies'
][]
=
'claro/ckeditor-dialog'
;
}
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment