mirror of
https://github.com/langgenius/dify.git
synced 2026-07-25 13:38:31 +08:00
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> Co-authored-by: GareArc <garethcxy@dify.ai>
20 lines
593 B
TypeScript
20 lines
593 B
TypeScript
'use client'
|
|
|
|
import { atom } from 'jotai'
|
|
import { systemFeaturesQueryOptions } from '@/features/system-features/client'
|
|
import { atomWithResolvedSuspenseQuery } from '@/utils/query-atoms'
|
|
|
|
const systemFeaturesQueryAtom = atomWithResolvedSuspenseQuery(() => systemFeaturesQueryOptions())
|
|
|
|
const systemFeaturesAtom = atom((get) => {
|
|
return get(systemFeaturesQueryAtom).data
|
|
})
|
|
|
|
export const deploymentEditionAtom = atom((get) => {
|
|
return get(systemFeaturesAtom).deployment_edition
|
|
})
|
|
|
|
export const brandingEnabledAtom = atom((get) => {
|
|
return get(systemFeaturesAtom).branding.enabled
|
|
})
|