Skip to content

Commit

Permalink
Merge pull request #33 from aabughosh/fixTable
Browse files Browse the repository at this point in the history
add the missing imports for redhat table
  • Loading branch information
sebrandon1 authored Jan 3, 2024
2 parents a85663f + 23be5d2 commit c40e018
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 7 deletions.
5 changes: 3 additions & 2 deletions html/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,13 @@
import '@patternfly/elements/pf-text-input/pf-text-input.js';
import '@rhds/elements/rh-tabs/rh-tabs.js';
import '@rhds/elements/rh-accordion/rh-accordion.js';
import '@rhds/elements/rh-table/rh-table.js';
import 'https://jspm.dev/@rhds/elements/rh-tag/rh-tag.js'
</script>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.1/dist/css/bootstrap.min.css" integrity="sha256-2TnSHycBDAm2wpZmgdi0z81kykGPJAkiUY+Wf97RbvY=" crossorigin="anonymous">
<link rel="stylesheet" href="https://getbootstrap.com/docs/5.3/assets/css/docs.css" integrity="sha256-X0cPqbNml7z/f/z7c1HiTdJ2aSO4QmaAMDnESV5n7fE=" crossorigin="anonymous">

<link inline rel="stylesheet" href="style.css">
<link rel="stylesheet"
href="https://ux.redhat.com/assets/packages/@rhds/elements/elements/rh-table/rh-table-lightdom.css"> <link inline rel="stylesheet" href="style.css">
<script src="https://cdn.jsdelivr.net/npm/dayjs@1.10.4/dayjs.min.js" integrity="sha256-NTsR4SOm3YHfJrmrmvBtEYqfQ6jQ5yvEKMhgQe3DIl0=" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/dayjs@1.10.4/plugin/duration.min.js" integrity="sha256-6rug74IKp6v/8WINJxMw33zXo8NVOdRw/5Ib21ZzwU4=" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.7.0/jquery.min.js" integrity="sha256-2Pmvv0kuTBOenSvLm6bvfBSSHrUJ+3A7x6P5Ebd07/g=" crossorigin="anonymous"></script>
Expand Down
5 changes: 3 additions & 2 deletions html/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -199,9 +199,10 @@ function hideAllResultsTabObjects () {
// fills the "version" tab element with the data from the claim.json passed in input
function fillVersionsElement (input, element) {
$(element).empty()
$('<thead><tr><th scope="col">Component</th><th scope="col">Version</th></tr></thead><tbody>').appendTo($(element))
$('<colgroup><col><col></colgroup><thead><tr><th scope="col" data-label="Component">Component</th>' +
'<th scope="col" data-label="Version">Version</th></tr></thead><tbody>').appendTo($(element))
for (const key in input) {
$('<tr><td><b>' + key + '</b></td><td>' + input[key] + '</td></tr>').appendTo($(element))
$('<tr><td data-label="Component"><b>' + key + '</b></td><td data-label="Version">' + input[key] + '</td></tr>').appendTo($(element))
}
$('</tbody>').appendTo($(element))
}
Expand Down
Loading

0 comments on commit c40e018

Please sign in to comment.