Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolves #3081 - metrics: fix tables in mobile view (int) #3392

Merged
merged 1 commit into from
Jan 6, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 26 additions & 1 deletion src/views/About/Metrics.vue
Original file line number Diff line number Diff line change
Expand Up @@ -710,8 +710,33 @@ export default {

<!-- Add "scoped" attribute to limit CSS to this component only -->
<style scoped lang="scss">
//Equally space data cells in metrics tables

// Equally space data cells in metrics tables
// Numbers in metrics tables look better right-aligned.

td {
width: auto !important;
text-align: right !important;
}

// For the mobile screen sizes, this overrides the settings in cveTableStacked,
// which was causing tables to be split into multiple tables and the year
// headings to be hidden. This keeps the tables intact. Mobile users will
// be able to horizontally scroll as normal.

@media only screen and (max-width: $desktop) {

td {
display: table-cell;
}

thead th {
display: table-cell;
}

tr {
display: table-row !important;
}
}

</style>