Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
term_glossary
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
term_glossary
Merge requests
!18
Issue
#3503011
by mably: Enable glossary on a per node/content basis
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Issue
#3503011
by mably: Enable glossary on a per node/content basis
issue/term_glossary-3503011:3503011-enable-glossary-on
into
4.2.x
Overview
0
Commits
1
Pipelines
19
Changes
15
Merged
Frank Mably
requested to merge
issue/term_glossary-3503011:3503011-enable-glossary-on
into
4.2.x
3 months ago
Overview
0
Commits
1
Pipelines
19
Changes
15
Expand
Closes
#3503011
0
0
Merge request reports
Compare
4.2.x
version 18
f317c305
3 months ago
version 17
983fccfa
3 months ago
version 16
0a406192
3 months ago
version 15
55d7ccfd
3 months ago
version 14
8150fc8f
3 months ago
version 13
6ad3bab6
3 months ago
version 12
6cb105f5
3 months ago
version 11
9f418f18
3 months ago
version 10
80ea5112
3 months ago
version 9
54e645c4
3 months ago
version 8
7c215822
3 months ago
version 7
faf9ab6d
3 months ago
version 6
d902879e
3 months ago
version 5
245899e3
3 months ago
version 4
6a78e89f
3 months ago
version 3
d422f527
3 months ago
version 2
70e13ae3
3 months ago
version 1
47d27f63
3 months ago
4.2.x (base)
and
latest version
latest version
f317c305
1 commit,
3 months ago
version 18
f317c305
1 commit,
3 months ago
version 17
983fccfa
1 commit,
3 months ago
version 16
0a406192
1 commit,
3 months ago
version 15
55d7ccfd
1 commit,
3 months ago
version 14
8150fc8f
1 commit,
3 months ago
version 13
6ad3bab6
1 commit,
3 months ago
version 12
6cb105f5
1 commit,
3 months ago
version 11
9f418f18
1 commit,
3 months ago
version 10
80ea5112
1 commit,
3 months ago
version 9
54e645c4
1 commit,
3 months ago
version 8
7c215822
1 commit,
3 months ago
version 7
faf9ab6d
1 commit,
3 months ago
version 6
d902879e
1 commit,
3 months ago
version 5
245899e3
1 commit,
3 months ago
version 4
6a78e89f
1 commit,
3 months ago
version 3
d422f527
1 commit,
3 months ago
version 2
70e13ae3
1 commit,
3 months ago
version 1
47d27f63
1 commit,
3 months ago
15 files
+
650
−
73
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
15
Search (e.g. *.vue) (Ctrl+P)
assets/js/toggle-autocomplete.js
0 → 100644
+
36
−
0
Options
// noinspection JSJQueryEfficiency
/**
* @file
* Js for Glossary Content.
*/
((
Drupal
,
once
)
=>
{
Drupal
.
behaviors
.
GlossaryToggleAutocomplete
=
{
attach
(
context
)
{
once
(
'
term-glossary-toggle-autocomplete
'
,
'
input.toggle-vocabulary-autocomplete
'
,
context
,
).
forEach
((
checkbox
)
=>
{
// We strip out the "edit-" prefix.
const
drupalSelector
=
checkbox
.
dataset
.
drupalSelector
.
slice
(
5
);
const
autocompleteField
=
context
.
querySelector
(
`.form-item-
${
drupalSelector
}
-vocabulary`
,
);
// Initial state
if
(
!
checkbox
.
checked
)
{
autocompleteField
.
classList
.
add
(
'
hidden
'
);
}
// Toggle on checkbox change
checkbox
.
addEventListener
(
'
change
'
,
function
onChange
()
{
if
(
this
.
checked
)
{
autocompleteField
.
classList
.
remove
(
'
hidden
'
);
}
else
{
autocompleteField
.
classList
.
add
(
'
hidden
'
);
}
});
});
},
};
})(
Drupal
,
once
);
Loading