Skip to content

Commit

Permalink
Add ability to highlight specific rows with fragments
Browse files Browse the repository at this point in the history
  • Loading branch information
BrandonXLF committed Apr 25, 2024
1 parent 1e51968 commit 0c6d4ba
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 0 deletions.
1 change: 1 addition & 0 deletions includes/LinkCount.php
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,7 @@ public function getHtml() {

$out->appendContent(
(new OOUI\Tag('div'))->setAttributes([
'id' => $key,
'role' => 'row'
])->appendContent(
(new OOUI\Tag('div'))->addClasses(['type'])->appendContent($label),
Expand Down
34 changes: 34 additions & 0 deletions static/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,25 @@ footer, #out {
border-radius: 0 2px 2px 0;
}

[role="row"]:target .type,
[role="row"]:target .all,
[role="row"]:target .direct,
[role="row"]:target .indirect {
border-top-width: 3px;
border-bottom-width: 3px;
border-color: #36c;
}

[role="row"]:target .type {
border-left-width: 3px;
border-radius: 4px 0 0 4px;
}

[role="row"]:target .indirect {
border-right-width: 3px;
border-radius: 0 4px 4px 0;
}

@media (max-width: 575px) {
.type {
grid-column-start: 1;
Expand Down Expand Up @@ -124,5 +143,20 @@ footer, #out {
.out > :first-child {
display: none;
}

[role="row"]:target .type {
border-right-width: 3px;
border-bottom-width: 1px;
border-radius: 4px 4px 0 0;
}

[role="row"]:target .all {
border-left-width: 3px;
border-radius: 0 0 0 4px;
}

[role="row"]:target .indirect {
border-radius: 0 0 4px 0;
}
}

0 comments on commit 0c6d4ba

Please sign in to comment.