feat: loading error struct

This commit is contained in:
Joel
2024-11-20 11:50:33 +08:00
parent 386ee7b07b
commit e6a03f7a58
5 changed files with 38 additions and 4 deletions

View File

@ -4,7 +4,7 @@ import React, { useEffect } from 'react'
import type { GitHubItemAndMarketPlaceDependency, Plugin } from '../../../types'
import { pluginManifestToCardPluginProps } from '../../utils'
import { useUploadGitHub } from '@/service/use-plugins'
import Loading from './loading'
import Loading from '../../base/loading'
import LoadedItem from './loaded-item'
type Props = {

View File

@ -1,23 +0,0 @@
'use client'
import React from 'react'
import Placeholder from '../../../card/base/placeholder'
import Checkbox from '@/app/components/base/checkbox'
const Loading = () => {
return (
<div className='flex items-center space-x-2'>
<Checkbox
className='shrink-0'
checked={false}
disabled
/>
<div className='grow relative p-4 pb-3 border-[0.5px] border-components-panel-border bg-components-panel-on-panel-item-bg hover-bg-components-panel-on-panel-item-bg rounded-xl shadow-xs'>
<Placeholder
wrapClassName='w-full'
/>
</div>
</div>
)
}
export default React.memo(Loading)

View File

@ -2,7 +2,7 @@
import type { FC } from 'react'
import React from 'react'
import type { Plugin } from '../../../types'
import Loading from './loading'
import Loading from '../../base/loading'
import LoadedItem from './loaded-item'
type Props = {