mirror of
https://github.com/cinnyapp/cinny.git
synced 2025-01-18 19:56:01 +01:00
hide upload image button when user can not edit pack
This commit is contained in:
parent
f4bf351743
commit
4618ab5cdc
1 changed files with 52 additions and 48 deletions
|
@ -330,8 +330,10 @@ export const ImagePackContent = as<'div', ImagePackContentProps>(
|
||||||
/>
|
/>
|
||||||
</SequenceCard>
|
</SequenceCard>
|
||||||
</Box>
|
</Box>
|
||||||
|
{images.length === 0 && !canEdit ? null : (
|
||||||
<Box direction="Column" gap="100">
|
<Box direction="Column" gap="100">
|
||||||
<Text size="L400">Images</Text>
|
<Text size="L400">Images</Text>
|
||||||
|
{canEdit && (
|
||||||
<SequenceCard
|
<SequenceCard
|
||||||
style={{ padding: config.space.S300 }}
|
style={{ padding: config.space.S300 }}
|
||||||
variant="SurfaceVariant"
|
variant="SurfaceVariant"
|
||||||
|
@ -356,6 +358,7 @@ export const ImagePackContent = as<'div', ImagePackContentProps>(
|
||||||
}
|
}
|
||||||
/>
|
/>
|
||||||
</SequenceCard>
|
</SequenceCard>
|
||||||
|
)}
|
||||||
{files.map((file) => (
|
{files.map((file) => (
|
||||||
<SequenceCard
|
<SequenceCard
|
||||||
key={file.name}
|
key={file.name}
|
||||||
|
@ -378,6 +381,7 @@ export const ImagePackContent = as<'div', ImagePackContentProps>(
|
||||||
{uploadedImages.map(renderImage)}
|
{uploadedImages.map(renderImage)}
|
||||||
{images.map(renderImage)}
|
{images.map(renderImage)}
|
||||||
</Box>
|
</Box>
|
||||||
|
)}
|
||||||
</Box>
|
</Box>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue