upd
This commit is contained in:
@@ -25,7 +25,9 @@ export function Clients({ showTitle = true }: { showTitle?: boolean }) {
|
||||
|
||||
useEffect(() => {
|
||||
if (!companies) return;
|
||||
setShuffled(shuffle(companies.filter((company) => company.logo)));
|
||||
setShuffled(
|
||||
shuffle(companies.slice(0, -1).filter((company) => company.logo))
|
||||
);
|
||||
}, [companies]);
|
||||
|
||||
const ref = useRef<HTMLDivElement>(null);
|
||||
@@ -68,7 +70,7 @@ export function Clients({ showTitle = true }: { showTitle?: boolean }) {
|
||||
}`}
|
||||
ref={ref}
|
||||
>
|
||||
<div className="flex items-center justify-between">
|
||||
<div className="flex justify-between items-center">
|
||||
{showTitle && (
|
||||
<Title className="mx-auto">
|
||||
<span className="text-gradient">
|
||||
@@ -79,14 +81,14 @@ export function Clients({ showTitle = true }: { showTitle?: boolean }) {
|
||||
)}
|
||||
<OpenFormModalWrapper
|
||||
modal={<CompanyFormModal action="create" />}
|
||||
className="flex flex-col items-center justify-center gap-3 aspect-square"
|
||||
className="aspect-square flex flex-col gap-3 justify-center items-center"
|
||||
>
|
||||
<GradientButton>
|
||||
<div className="text-white lg:size-[1.944vw] size-7">
|
||||
<AddIcon />
|
||||
</div>
|
||||
</GradientButton>
|
||||
<p className="font-medium btnl">Добавить</p>
|
||||
<p className="btnl font-medium">Добавить</p>
|
||||
</OpenFormModalWrapper>
|
||||
</div>
|
||||
{companies && !!shuffled.length && (
|
||||
@@ -140,9 +142,9 @@ export function Clients({ showTitle = true }: { showTitle?: boolean }) {
|
||||
<RestartIcon />
|
||||
</div>
|
||||
</GradientButton>
|
||||
<p className="font-medium select-none btnl">Перемешать</p>
|
||||
<p className="btnl font-medium select-none">Перемешать</p>
|
||||
</div>
|
||||
<div className="absolute inset-0 lg:hidden" />
|
||||
<div className="lg:hidden absolute inset-0" />
|
||||
</GridDropZone>
|
||||
</GridContextProvider>
|
||||
)}
|
||||
|
||||
Reference in New Issue
Block a user