Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
T
tf-build
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Benedikt Wildenhain
tf-build
Commits
d2fc0879
Commit
d2fc0879
authored
2 years ago
by
Austin Anderson
Browse files
Options
Downloads
Patches
Plain Diff
Fix it all, finally
parent
8627ab4d
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
tf_oss_dashboard/script.js
+10
-6
10 additions, 6 deletions
tf_oss_dashboard/script.js
tf_oss_dashboard/template.html.pug
+1
-1
1 addition, 1 deletion
tf_oss_dashboard/template.html.pug
with
11 additions
and
7 deletions
tf_oss_dashboard/script.js
+
10
−
6
View file @
d2fc0879
...
@@ -97,15 +97,19 @@ $(function () {
...
@@ -97,15 +97,19 @@ $(function () {
history
.
replaceState
(
null
,
null
,
'
'
)
history
.
replaceState
(
null
,
null
,
'
'
)
})
})
// When the page loads, if there is a commit ID in the location hash, show
// When the page loads, check the location hash, and...
// the matching modal -- that is, if you load dashboard#commit, show the modal
// - If there's a matching category on the page, scroll to it
// for that commit. Also, show the matching modal if a CL is provided instead.
// - If there is a commit ID in the location hash, show that commit
// - If there is a CL in the location hash, show that CL's commit
// - If there is a PR in the location hash, show that PR's commit
unescaped
=
decodeURIComponent
(
window
.
location
.
hash
).
replace
(
"
#
"
,
""
).
replace
(
"
+
"
,
""
)
unescaped
=
decodeURIComponent
(
window
.
location
.
hash
).
replace
(
"
#
"
,
""
).
replace
(
"
+
"
,
""
)
// Nothing to do if no hash in the URL
if
(
window
.
location
.
hash
.
length
<=
1
)
{
if
(
window
.
location
.
hash
.
length
<=
1
)
{
//
Empty!
//
Nothing to do if no hash in the URL
// If the hash matches a Category on the page, then scroll to it
// If the hash matches a Category on the page, then scroll to it
.
}
else
if
(
document
.
getElementById
(
unescaped
))
{
}
else
if
(
document
.
getElementById
(
unescaped
))
{
// Google Chrome, at least, does not scroll if the tab is opened in the
// background, so we try and scroll a moment after the first time the tab
// gets focus, or immediately if it has focus already.
if
(
document
.
hasFocus
())
{
if
(
document
.
hasFocus
())
{
document
.
getElementById
(
unescaped
).
scrollIntoView
();
document
.
getElementById
(
unescaped
).
scrollIntoView
();
}
else
{
}
else
{
...
...
This diff is collapsed.
Click to expand it.
tf_oss_dashboard/template.html.pug
+
1
−
1
View file @
d2fc0879
...
@@ -21,7 +21,7 @@ html(lang="en")
...
@@ -21,7 +21,7 @@ html(lang="en")
nav.navbar.navbar-dark.navbar-expand-lg.py-0.mb-2
nav.navbar.navbar-dark.navbar-expand-lg.py-0.mb-2
.container-fluid.py-0
.container-fluid.py-0
.d-flex.flex-row
.d-flex.flex-row
a.navbar-brand TensorFlow GitHub CI
a
(href=)
.navbar-brand TensorFlow GitHub CI
.navbar-text#tf-now(data-isonow=isonow) Last updated on
.navbar-text#tf-now(data-isonow=isonow) Last updated on
a(title="Check the dashboard deployment GitHub Actions workflow" href="https://github.com/tensorflow/build/actions/workflows/dashboard.yml") #{now}
a(title="Check the dashboard deployment GitHub Actions workflow" href="https://github.com/tensorflow/build/actions/workflows/dashboard.yml") #{now}
|
|
...
...
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