-
Notifications
You must be signed in to change notification settings - Fork 254
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
feat(xo-lite): Add collapsible table row for alarm pool #7641
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In addition, the toggle icon + toggle behavior + collapsible row should only be added in case there is an additional description.
@@ -0,0 +1,139 @@ | |||
<template> | |||
<tr v-if="isMobile" class="mobile" @click="handleCollapse"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can wrap all tr
related to mobile in a <tbody v-if="isMobile">
, then all tr
related to desktop in a <tbody v-else>
<div v-tooltip="new Date(parseDateTime(alarm.timestamp)).toLocaleString()" class="ellipsis time"> | ||
<RelativeTime :date="alarm.timestamp" /> | ||
</div> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A div
can not be a direct child of tr
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As we discussed, this component can be removed.
.mobile, | ||
.desktop { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd suggest to replace these classes with a alarm-row
class on the wrappers.
</td> | ||
</tr> | ||
|
||
<tr v-if="!isDescriptionCollapsedRef && isMobile" class="collapsible-description"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This collapsible-description
class is not used and can therefore be deleted.
</tr> | ||
|
||
<tr v-if="!isDescriptionCollapsedRef && isMobile" class="collapsible-description"> | ||
<td class="collapsible-description__content" colspan="5"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't use BEM across the codebase and prefer short, meaningful class names
@xen-orchestra/lite/src/components/pool/dashboard/ArrowCollapseButton.vue
Outdated
Show resolved
Hide resolved
Co-authored-by: Thierry Goettelmann <thierry@byscripts.info>
Co-authored-by: Thierry Goettelmann <thierry@byscripts.info>
Co-authored-by: Thierry Goettelmann <thierry@byscripts.info>
Co-authored-by: Thierry Goettelmann <thierry@byscripts.info>
…eButton.vue Co-authored-by: Thierry Goettelmann <thierry@byscripts.info>
This component is a table row with a collapsible description.