mirror of
https://github.com/n8n-io/n8n.git
synced 2025-02-21 02:56:40 -08:00
A few style tweaks
This commit is contained in:
parent
825a700250
commit
00df04743f
|
@ -8,29 +8,23 @@ const props = defineProps<{
|
|||
const total = props.statistic ? props.statistic.successes + props.statistic.errors : 0;
|
||||
|
||||
const tooltip = `
|
||||
<p>${total} production executions since creation</p>
|
||||
<p>${props.statistic?.successes || 0} successful</p>
|
||||
<p>${props.statistic?.errors || 0} failed</p>
|
||||
${total} production executions<br />
|
||||
${props.statistic?.successes || 0} successful, ${props.statistic?.errors || 0} failed
|
||||
`;
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<n8n-tooltip v-if="statistic && total" placement="top">
|
||||
<div class="statusText">
|
||||
<span class="info-wrapper">
|
||||
<n8n-icon icon="tasks" color="info" />
|
||||
<n8n-text color="text-base" size="small" bold
|
||||
>{{ total }}<span class="separator">|</span></n8n-text
|
||||
>
|
||||
<span class="info-wrapper info-wrapper__total">
|
||||
<n8n-icon icon="tasks" color="text-base" />
|
||||
<n8n-text color="text-base" size="small" bold>{{ total }}</n8n-text>
|
||||
</span>
|
||||
<span v-if="statistic?.successes" class="info-wrapper">
|
||||
<span v-if="statistic?.successes" class="info-wrapper info-wrapper__success">
|
||||
<n8n-icon icon="check-circle" color="success" />
|
||||
<n8n-text color="text-base" size="small" bold
|
||||
>{{ statistic.successes
|
||||
}}<span v-if="statistic?.errors" class="separator">|</span></n8n-text
|
||||
>
|
||||
<n8n-text color="text-base" size="small" bold>{{ statistic.successes }}</n8n-text>
|
||||
</span>
|
||||
<span v-if="statistic?.errors" class="info-wrapper">
|
||||
<span v-if="statistic?.errors" class="info-wrapper info-wrapper__error">
|
||||
<n8n-icon icon="exclamation-triangle" color="danger" />
|
||||
<n8n-text color="text-base" size="small" bold> {{ statistic?.errors }} </n8n-text>
|
||||
</span>
|
||||
|
@ -43,7 +37,7 @@ const tooltip = `
|
|||
|
||||
<style lang="scss" scoped>
|
||||
.statusText {
|
||||
padding-right: var(--spacing-s);
|
||||
padding-right: var(--spacing-l);
|
||||
box-sizing: border-box;
|
||||
text-align: right;
|
||||
display: flex;
|
||||
|
@ -56,9 +50,23 @@ const tooltip = `
|
|||
align-items: center;
|
||||
justify-content: center;
|
||||
gap: var(--spacing-4xs);
|
||||
}
|
||||
|
||||
.separator {
|
||||
margin: 0 var(--spacing-3xs);
|
||||
&__total .n8n-icon {
|
||||
color: var(--color-text-light);
|
||||
}
|
||||
|
||||
&__success .n8n-icon {
|
||||
color: var(--execution-card-border-success);
|
||||
}
|
||||
|
||||
&__error .n8n-icon {
|
||||
color: var(--execution-card-border-error);
|
||||
}
|
||||
|
||||
&:not(:last-child) {
|
||||
margin-right: var(--spacing-2xs);
|
||||
padding-right: var(--spacing-2xs);
|
||||
border-right: 1px solid var(--color-foreground-base);
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
|
Loading…
Reference in a new issue