Merge branch 'issue-433' of https://github.com/isaacwise06/linkwarden into issue-433
This commit is contained in:
commit
8f62f4dffb
|
@ -70,7 +70,7 @@ export default function LinkCard({
|
|||
|
||||
const ref = useRef<HTMLDivElement>(null);
|
||||
const isVisible = useOnScreen(ref);
|
||||
const permissions = usePermissions(collection.id as number);
|
||||
const permissions = usePermissions(collection?.id as number);
|
||||
|
||||
useEffect(() => {
|
||||
let interval: any;
|
||||
|
|
|
@ -64,7 +64,7 @@ export default function LinkCardCompact({
|
|||
);
|
||||
}, [collections, links]);
|
||||
|
||||
const permissions = usePermissions(collection.id as number);
|
||||
const permissions = usePermissions(collection?.id as number);
|
||||
|
||||
const [showInfo, setShowInfo] = useState(false);
|
||||
|
||||
|
|
|
@ -43,7 +43,6 @@ export default function Index() {
|
|||
useState<CollectionIncludingMembersAndLinkCount>();
|
||||
|
||||
const permissions = usePermissions(activeCollection?.id as number);
|
||||
console.log(permissions)
|
||||
|
||||
useLinks({ collectionId: Number(router.query.id), sort: sortBy });
|
||||
|
||||
|
@ -307,6 +306,7 @@ export default function Index() {
|
|||
</div>
|
||||
|
||||
<div className="w-full flex justify-between items-center min-h-[32px]">
|
||||
{links.length > 0 && (
|
||||
<div className="flex gap-3 ml-3">
|
||||
<input
|
||||
type="checkbox"
|
||||
|
@ -320,6 +320,7 @@ export default function Index() {
|
|||
</span>
|
||||
)}
|
||||
</div>
|
||||
)}
|
||||
<div className="flex gap-3">
|
||||
{selectedLinks.length > 0 && (permissions === true || permissions?.canUpdate) &&
|
||||
<button onClick={() => setBulkEditLinksModal(true)} className="btn btn-sm btn-accent dark:border-violet-400 text-white w-fit ml-auto">
|
||||
|
|
|
@ -145,8 +145,7 @@ export default function Index() {
|
|||
</p>
|
||||
<div className="relative">
|
||||
<div
|
||||
className={`dropdown dropdown-bottom font-normal ${
|
||||
activeTag?.name.length && activeTag?.name.length > 8
|
||||
className={`dropdown dropdown-bottom font-normal ${activeTag?.name.length && activeTag?.name.length > 8
|
||||
? "dropdown-end"
|
||||
: ""
|
||||
}`}
|
||||
|
@ -200,6 +199,7 @@ export default function Index() {
|
|||
</div>
|
||||
</div>
|
||||
<LinkComponent
|
||||
showCheckbox={false}
|
||||
links={links.filter((e) =>
|
||||
e.tags.some((e) => e.id === Number(router.query.id))
|
||||
)}
|
||||
|
|
Ŝarĝante…
Reference in New Issue