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

Redesigns Portfolio View to help with self-navigation #167

Merged
merged 7 commits into from
Jan 24, 2024
Merged
Show file tree
Hide file tree
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
4 changes: 4 additions & 0 deletions frontend/assets/css/overrides.css
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,7 @@ div.p-chips .p-chips-multiple-container {
div.p-chips .p-chips-multiple-container .p-chips-token {
margin-right: 0;
}

div.p-accordion .p-accordion-header:not(.p-disabled).p-highlight .p-accordion-header-link {
background-color: #f5f5f5
}
27 changes: 27 additions & 0 deletions frontend/components/BulkActionsDrawer.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<script setup lang="ts">
const { t } = useI18n()

const prefix = 'components/BulkActionsDrawer'
const statePrefix = `${prefix}[${useStateIDGenerator().id()}]`
const tt = (s: string) => t(`${prefix}.${s}`)

const open = useState<boolean>(`${statePrefix}.open`, () => false)
const icon = computed(() => open.value ? 'pi pi-chevron-left' : 'pi pi-chevron-right')
const classes = computed(() => open.value ? 'border-2 border-primary' : 'p-button-outlined border-round')
</script>

<template>
<span class="p-buttonset w-fit">
<PVButton
:label="tt('Bulk Actions')"
class="p-button-sm"
:class="classes"
:icon="icon"
icon-pos="right"
@click="() => { open = !open}"
/>
<template v-if="open">
<slot />
</template>
</span>
</template>
29 changes: 29 additions & 0 deletions frontend/components/CommonAccordionHeader.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<script setup lang="ts">
interface Props {
heading: string
subHeading?: string | undefined
icon?: string | undefined
}
const props = defineProps<Props>()
</script>

<template>
<div class="flex justify-content-between align-items-center w-full flex-wrap px-2">
<div class="flex gap-1 flex-column">
<div class="text-lg font-bold">
{{ props.heading }}
</div>
<div
v-if="props.subHeading"
class="text-sm font-light"
>
{{ props.subHeading }}
</div>
</div>
<i
v-if="props.icon"
:class="props.icon"
/>
<slot />
</div>
</template>
2 changes: 1 addition & 1 deletion frontend/components/DownloadButton.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const { t } = useI18n()

interface Props {
value: string
cta: string
cta?: string | undefined
fileName: string
}
const props = defineProps<Props>()
Expand Down
21 changes: 9 additions & 12 deletions frontend/components/analysis/StatusChip.vue
Original file line number Diff line number Diff line change
Expand Up @@ -24,28 +24,25 @@ const status = computed(() => {
}
return tt('Running')
})
const bg = computed(() => {
const severity = computed(() => {
if (props.analysis.completedAt !== undefined) {
if (props.analysis.failureMessage !== undefined) {
return 'bg-red-400'
return 'danger'
} else {
return 'bg-green-200'
return 'success'
}
}
if (isStale(props.analysis)) {
return 'bg-red-200'
return 'danger'
}
return 'bg-yellow-200'
return 'warn'
})
</script>

<template>
<div
:class="bg"
class="p-1 align-self-stretch flex align-items-center justify-content-center border-round-lg"
<PVInlineMessage
:severity="severity"
>
<span>
{{ status }}
</span>
</div>
{{ status }}
</PVInlineMessage>
</template>
2 changes: 1 addition & 1 deletion frontend/components/modal/Group.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script setup lang="ts" />

<template>
<div>
<div id="modal-group">
<ModalError />
<ModalLoading />
<ModalPermissionDenied />
Expand Down
Loading
Loading