c2a95b484f
* New Text Styles. Initial FE2 changes * More fe2 styling classes * Minor update * Minor update * Fix build * More updates for discussion * More styling updates * Minor updates to inputs * More text updates * More font class swapping * Revert dui3 changes * Confirmed Lineheights * Add story files for new text styles * Minor copy changes * Minor typo * andrew/web-1371-misalignment-in-account-dropdown * andrew/web-1374-settings-text-styles-are-not-right * andrew/web-1375-nav-texts-should-be-14px * andrew/web-1376-decrease-size-of-versions-header * andrew/web-1377-version-card-title * semibold>medium * Measure mode * Changes from PR * Tweaked nav menu * Revert prose change. Add prose-sm --------- Co-authored-by: Mike Tasset <mike.tasset@gmail.com>
65 lines
1.5 KiB
Vue
65 lines
1.5 KiB
Vue
<template>
|
|
<div class="col-span-1">
|
|
<h2 class="h6 font-medium mb-6">Model</h2>
|
|
<div class="w-full">
|
|
<ProjectModelsBasicCardView
|
|
v-if="triggerModels.length"
|
|
:items="triggerModels"
|
|
vertical
|
|
:project="project"
|
|
:project-id="project.id"
|
|
/>
|
|
<CommonGenericEmptyState
|
|
v-else
|
|
message="No valid models found for this automation. They may have been deleted."
|
|
/>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
<script setup lang="ts">
|
|
import { isNonNullable } from '@speckle/shared'
|
|
import { graphql } from '~/lib/common/generated/gql'
|
|
import type {
|
|
ProjectPageAutomationHeader_AutomationFragment,
|
|
ProjectPageAutomationHeader_ProjectFragment
|
|
} from '~/lib/common/generated/gql/graphql'
|
|
|
|
graphql(`
|
|
fragment ProjectPageAutomationHeader_Automation on Automation {
|
|
id
|
|
name
|
|
enabled
|
|
isTestAutomation
|
|
currentRevision {
|
|
id
|
|
triggerDefinitions {
|
|
... on VersionCreatedTriggerDefinition {
|
|
model {
|
|
...ProjectPageLatestItemsModelItem
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
`)
|
|
|
|
graphql(`
|
|
fragment ProjectPageAutomationHeader_Project on Project {
|
|
id
|
|
...ProjectPageModelsCardProject
|
|
}
|
|
`)
|
|
|
|
const props = defineProps<{
|
|
project: ProjectPageAutomationHeader_ProjectFragment
|
|
automation: ProjectPageAutomationHeader_AutomationFragment
|
|
}>()
|
|
|
|
const triggerModels = computed(
|
|
() =>
|
|
props.automation.currentRevision?.triggerDefinitions
|
|
.map((t) => t.model)
|
|
.filter(isNonNullable) || []
|
|
)
|
|
</script>
|