mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-27 01:39:47 +00:00
[feat] Show conflicting status for installed packages with compatibility issues (#4579)
Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -32,8 +32,9 @@ type StatusProps = {
|
|||||||
severity: MessageSeverity
|
severity: MessageSeverity
|
||||||
}
|
}
|
||||||
|
|
||||||
const { statusType } = defineProps<{
|
const { statusType, hasCompatibilityIssues } = defineProps<{
|
||||||
statusType: Status
|
statusType: Status
|
||||||
|
hasCompatibilityIssues?: boolean
|
||||||
}>()
|
}>()
|
||||||
|
|
||||||
const statusPropsMap: Record<Status, StatusProps> = {
|
const statusPropsMap: Record<Status, StatusProps> = {
|
||||||
@@ -71,10 +72,14 @@ const statusPropsMap: Record<Status, StatusProps> = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const statusLabel = computed(
|
const statusLabel = computed(() =>
|
||||||
() => statusPropsMap[statusType]?.label || 'unknown'
|
hasCompatibilityIssues
|
||||||
|
? 'conflicting'
|
||||||
|
: statusPropsMap[statusType]?.label || 'unknown'
|
||||||
)
|
)
|
||||||
const statusSeverity = computed(
|
const statusSeverity = computed(() =>
|
||||||
() => statusPropsMap[statusType]?.severity || 'secondary'
|
hasCompatibilityIssues
|
||||||
|
? 'error'
|
||||||
|
: statusPropsMap[statusType]?.severity || 'secondary'
|
||||||
)
|
)
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -32,6 +32,7 @@
|
|||||||
:status-type="
|
:status-type="
|
||||||
nodePack.status as components['schemas']['NodeVersionStatus']
|
nodePack.status as components['schemas']['NodeVersionStatus']
|
||||||
"
|
"
|
||||||
|
:has-compatibility-issues="hasCompatibilityIssues"
|
||||||
/>
|
/>
|
||||||
</MetadataRow>
|
</MetadataRow>
|
||||||
<MetadataRow :label="t('manager.version')">
|
<MetadataRow :label="t('manager.version')">
|
||||||
@@ -131,9 +132,9 @@ const conflictResult = computed((): ConflictDetectionResult | null => {
|
|||||||
return null
|
return null
|
||||||
})
|
})
|
||||||
|
|
||||||
const hasCompatibilityIssues = computed(
|
const hasCompatibilityIssues = computed(() => {
|
||||||
() => conflictResult.value?.has_conflict ?? false
|
return isInstalled.value && conflictResult.value?.has_conflict ? true : false
|
||||||
)
|
})
|
||||||
|
|
||||||
const infoItems = computed<InfoItem[]>(() => [
|
const infoItems = computed<InfoItem[]>(() => [
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -190,7 +190,8 @@
|
|||||||
"flagged": "Flagged",
|
"flagged": "Flagged",
|
||||||
"deleted": "Deleted",
|
"deleted": "Deleted",
|
||||||
"banned": "Banned",
|
"banned": "Banned",
|
||||||
"unknown": "Unknown"
|
"unknown": "Unknown",
|
||||||
|
"conflicting": "Conflicting"
|
||||||
},
|
},
|
||||||
"sort": {
|
"sort": {
|
||||||
"downloads": "Most Popular",
|
"downloads": "Most Popular",
|
||||||
|
|||||||
Reference in New Issue
Block a user