fix: update documentation message for file access clarification (#221)

* fix: update documentation message for file access clarification
* fix(ui): upload message only for upload
This commit is contained in:
Ferenc Sárai
2026-03-13 15:56:22 +01:00
committed by Bálint Ujvári
parent fa8a26e80d
commit ae63615c7c
3 changed files with 10 additions and 10 deletions
+1 -5
View File
@@ -20,11 +20,7 @@ export function AssetSummary({ reference }: Props): ReactElement {
{isHash && <ExpandableListItemKey label="Swarm hash" value={reference || ''} />} {isHash && <ExpandableListItemKey label="Swarm hash" value={reference || ''} />}
{!isHash && <ExpandableListItemLink label="ENS" value={reference || ''} />} {!isHash && <ExpandableListItemLink label="ENS" value={reference || ''} />}
</Box> </Box>
<DocumentationText> <DocumentationText>Files are accessed through your configured Bee API endpoint.</DocumentationText>
The Swarm Gateway is graciously provided by the Swarm Foundation. This service is under development and provided
for testing purposes only. Learn more at{' '}
<a href="https://gateway.ethswarm.org/">https://gateway.ethswarm.org/</a>.
</DocumentationText>
</> </>
) )
} }
+8 -4
View File
@@ -4,7 +4,7 @@ import { saveAs } from 'file-saver'
import JSZip from 'jszip' import JSZip from 'jszip'
import { useSnackbar } from 'notistack' import { useSnackbar } from 'notistack'
import { ReactElement, useContext, useEffect, useRef, useState } from 'react' import { ReactElement, useContext, useEffect, useRef, useState } from 'react'
import { useNavigate, useParams } from 'react-router-dom' import { useLocation, useNavigate, useParams } from 'react-router-dom'
import { HistoryHeader } from '../../components/HistoryHeader' import { HistoryHeader } from '../../components/HistoryHeader'
import { Loading } from '../../components/Loading' import { Loading } from '../../components/Loading'
@@ -26,6 +26,8 @@ export function Share(): ReactElement {
const { status } = useContext(BeeContext) const { status } = useContext(BeeContext)
const { hash } = useParams() const { hash } = useParams()
const location = useLocation()
const fromUpload = Boolean(location.state?.fromUpload)
const navigate = useNavigate() const navigate = useNavigate()
const { enqueueSnackbar } = useSnackbar() const { enqueueSnackbar } = useSnackbar()
@@ -239,9 +241,11 @@ export function Share(): ReactElement {
<Box mb={4}> <Box mb={4}>
<AssetSummary isWebsite={metadata?.isWebsite} reference={hash} /> <AssetSummary isWebsite={metadata?.isWebsite} reference={hash} />
</Box> </Box>
<Box mb={4}> {fromUpload && (
<AssetSyncing reference={hash} /> <Box mb={4}>
</Box> <AssetSyncing reference={hash} />
</Box>
)}
<DownloadActionBar <DownloadActionBar
onOpen={onOpen} onOpen={onOpen}
onCancel={onClose} onCancel={onClose}
+1 -1
View File
@@ -120,7 +120,7 @@ export function Upload(): ReactElement {
putHistory(LocalStorageKeys.uploadHistory, hash.reference.toHex(), getAssetNameFromFiles(files)) putHistory(LocalStorageKeys.uploadHistory, hash.reference.toHex(), getAssetNameFromFiles(files))
if (uploadOrigin.origin === FileOrigin.Upload) { if (uploadOrigin.origin === FileOrigin.Upload) {
navigate(ROUTES.HASH.replace(':hash', hash.reference.toHex()), { replace: true }) navigate(ROUTES.HASH.replace(':hash', hash.reference.toHex()), { replace: true, state: { fromUpload: true } })
} else { } else {
updateFeed(beeApi, identity as Identity, hash.reference, stamp.batchID, password as string).then(() => { updateFeed(beeApi, identity as Identity, hash.reference, stamp.batchID, password as string).then(() => {
persistIdentity(identities, identity as Identity) persistIdentity(identities, identity as Identity)