|
@@ -1,6 +1,7 @@
|
|
|
import { computed, ref, watch } from 'vue'
|
|
|
import { useAppStore } from '~src/store'
|
|
|
import { isNullES } from 'js-fast-way'
|
|
|
+import { setElementMainColor } from 'js-fast-way'
|
|
|
|
|
|
export function useProject() {
|
|
|
const useAppState = useAppStore()
|
|
@@ -18,12 +19,25 @@ export function useProject() {
|
|
|
contractId.value = cid
|
|
|
projectInfo.value = pinfo
|
|
|
contractInfo.value = cinfo
|
|
|
+ setYunNanTheme(pid)
|
|
|
}, { deep: true })
|
|
|
|
|
|
const isAppLoading = computed(() => {
|
|
|
return !isNullES(projectId.value) && !isNullES(contractId.value)
|
|
|
})
|
|
|
-
|
|
|
+ const setYunNanTheme = (pid)=>{
|
|
|
+ console.log( projectId.value, ' projectId.value ')
|
|
|
+
|
|
|
+ const id = '1891312830718746625'
|
|
|
+ let isYunNan = pid === id
|
|
|
+ if (isYunNan) {
|
|
|
+ setElementMainColor('#409eff')
|
|
|
+ let colorName = 'blue'
|
|
|
+ let theme = 'light'
|
|
|
+ document.documentElement.setAttribute('class', `${theme} color-${colorName}`)
|
|
|
+ return
|
|
|
+ }
|
|
|
+ }
|
|
|
return {
|
|
|
projectId,
|
|
|
contractId,
|