Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
Lesson Template
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
prace-lessons
Lesson Template
Commits
f994dfbe
Commit
f994dfbe
authored
8 years ago
by
Raniere Silva
Committed by
GitHub
8 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Revert "ensure dt elements have an id set"
parent
d68646c5
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
_includes/javascript.html
+0
-19
0 additions, 19 deletions
_includes/javascript.html
with
0 additions
and
19 deletions
_includes/javascript.html
+
0
−
19
View file @
f994dfbe
...
...
@@ -12,22 +12,3 @@
ga
(
'
create
'
,
'
UA-37305346-2
'
,
'
auto
'
);
ga
(
'
send
'
,
'
pageview
'
);
</script>
<script>
// This snippet fixes a bug caused by Github's pages-gem using kramdown v1.11.1.
// In order for anchor links to point to the correct place in the glossary, they must have an id
// This snippet ensures every definition term has an id
// See https://github.com/swcarpentry/styles/pull/129
$
(
'
dt
'
).
each
(
function
()
{
if
(
!
this
.
id
)
{
var
id
=
$
(
this
).
text
();
// If there's a ( in the name (e.g., "comma-separated values (CSV)") - just take everything up to the first (
var
index
=
id
.
indexOf
(
'
(
'
);
if
(
index
>
0
)
{
id
=
id
.
substring
(
0
,
index
);
}
// Strip leading and trailing whitespace, convert spaces to dashes and convert everything to lowercase
id
=
id
.
trim
().
replace
(
/ /g
,
'
-
'
).
toLowerCase
();
this
.
id
=
id
;
}
});
</script>
This diff is collapsed.
Click to expand it.
Preview
0%
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