MCPcopy Index your code
hub / github.com/SpringRoll/SpringRoll / showHashTarget

Function showHashTarget

docs/assets/site.js:67–79  ·  view source on GitHub ↗
(targetId)

Source from the content-addressed store, hash-verified

65}
66
67function showHashTarget(targetId) {
68 if (targetId) {
69 var hashTarget = document.getElementById(targetId);
70 // new target is hidden
71 if (
72 hashTarget &&
73 hashTarget.offsetHeight === 0 &&
74 hashTarget.parentNode.parentNode.classList.contains('display-none')
75 ) {
76 hashTarget.parentNode.parentNode.classList.remove('display-none');
77 }
78 }
79}
80
81function scrollIntoView(targetId) {
82 // Only scroll to element if we don't have a stored scroll position.

Callers 2

gotoCurrentTargetFunction · 0.85
preOpenFunction · 0.85

Calls 1

removeMethod · 0.80

Tested by

no test coverage detected