Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions apps/space/app/issues/[anchor]/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -127,10 +127,10 @@ function IssuesLayout(props: Route.ComponentProps) {
return (
<>
<div className="relative flex h-screen min-h-[500px] w-screen flex-col overflow-hidden">
<div className="relative flex h-[60px] flex-shrink-0 select-none items-center border-b border-strong bg-surface-1">
<div className="relative flex h-[60px] shrink-0 select-none items-center border-b border-subtle-1 bg-surface-1">
<IssuesNavbarRoot publishSettings={publishSettings} />
</div>
<div className="relative h-full w-full overflow-hidden bg-surface-2">
<div className="relative size-full bg-surface-2 overflow-hidden">
<Outlet />
</div>
</div>
Expand Down
7 changes: 3 additions & 4 deletions apps/space/core/components/editor/toolbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export function IssueCommentToolbar(props: Props) {
}, [editorRef, updateActiveStates]);

return (
<div className="flex h-9 w-full items-stretch gap-1.5 bg-surface-2 overflow-x-scroll">
<div className="flex h-9 w-full items-stretch gap-1.5 overflow-x-scroll">
<div className="flex w-full items-stretch justify-between gap-2 rounded-sm border-[0.5px] border-subtle p-1">
<div className="flex items-stretch">
{Object.keys(toolbarItems).map((key, index) => (
Expand All @@ -75,9 +75,9 @@ export function IssueCommentToolbar(props: Props) {
type="button"
onClick={() => executeCommand(item)}
className={cn(
"grid place-items-center aspect-square rounded-xs p-0.5 text-placeholder hover:bg-layer-1",
"grid place-items-center aspect-square rounded-xs p-0.5 text-placeholder hover:bg-layer-transparent-hover",
{
"bg-layer-1 text-primary": isItemActive,
"bg-layer-transparent-hover text-primary": isItemActive,
}
)}
>
Expand All @@ -99,7 +99,6 @@ export function IssueCommentToolbar(props: Props) {
<Button
type="button"
variant="primary"
className="px-2.5 py-1.5 text-11"
onClick={handleSubmit}
disabled={isCommentEmpty}
loading={isSubmitting}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ interface IFilterHeader {

export function FilterHeader({ title, isPreviewEnabled, handleIsPreviewEnabled }: IFilterHeader) {
return (
<div className="sticky top-0 flex items-center justify-between gap-2 bg-surface-1">
<div className="flex-grow truncate text-11 font-medium text-tertiary">{title}</div>
<div className="sticky top-0 flex items-center justify-between gap-2">
<div className="grow truncate text-11 font-medium text-tertiary">{title}</div>
<button
type="button"
className="grid h-5 w-5 flex-shrink-0 place-items-center rounded-sm hover:bg-layer-1"
className="grid h-5 w-5 shrink-0 place-items-center rounded-sm hover:bg-layer-transparent-hover"
onClick={handleIsPreviewEnabled}
>
{isPreviewEnabled ? <ChevronUpIcon height={14} width={14} /> : <ChevronDownIcon height={14} width={14} />}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,19 @@ export function FilterOption(props: Props) {
return (
<button
type="button"
className="flex w-full items-center gap-2 rounded-sm p-1.5 hover:bg-layer-1"
className="flex w-full items-center gap-2 rounded-sm p-1.5 hover:bg-layer-transparent-hover"
onClick={onClick}
>
<div
className={`grid h-3 w-3 flex-shrink-0 place-items-center border bg-surface-2 ${
className={`grid h-3 w-3 shrink-0 place-items-center border ${
isChecked ? "border-accent-strong bg-accent-primary text-on-color" : "border-strong"
} ${multiple ? "rounded-xs" : "rounded-full"}`}
>
{isChecked && <Check size={10} strokeWidth={3} />}
</div>
<div className="flex items-center gap-2 truncate">
{icon && <div className="grid w-5 flex-shrink-0 place-items-center">{icon}</div>}
<div className="flex-grow truncate text-11 text-secondary">{title}</div>
{icon && <div className="grid w-5 shrink-0 place-items-center">{icon}</div>}
<div className="grow truncate text-11 text-secondary">{title}</div>
</div>
</button>
);
Expand Down
2 changes: 1 addition & 1 deletion apps/space/core/components/issues/filters/root.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export const IssueFiltersDropdown = observer(function IssueFiltersDropdown(props
);

return (
<div className="z-10 flex h-full w-full flex-col">
<div className="relative">
<FiltersDropdown title="Filters" placement="bottom-end">
<FilterSelection
filters={issueFilters?.filters ?? {}}
Expand Down
4 changes: 2 additions & 2 deletions apps/space/core/components/issues/filters/selection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export const FilterSelection = observer(function FilterSelection(props: Props) {

return (
<div className="flex h-full w-full flex-col overflow-hidden">
<div className="bg-surface-1 p-2.5 pb-0">
<div className="p-2.5 pb-0">
<div className="flex items-center gap-1.5 rounded-sm border-[0.5px] border-subtle bg-surface-2 px-1.5 py-1 text-11">
<Search className="text-placeholder" size={12} strokeWidth={2} />
<input
Expand All @@ -41,7 +41,7 @@ export const FilterSelection = observer(function FilterSelection(props: Props) {
)}
</div>
</div>
<div className="h-full w-full divide-y divide-subtle-1 overflow-y-auto px-2.5">
<div className="h-full w-full divide-y divide-subtle-1 overflow-y-auto px-2.5">
{/* priority */}
{isFilterEnabled("priority") && (
<div className="py-2">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,14 @@ export const IssueLayoutHOC = observer(function IssueLayoutHOC(props: Props) {

if (getIssueLoader() === "init-loader" || issueCount === undefined) {
return (
<div className="relative flex h-screen w-full items-center justify-center">
<div className="relative size-full grid place-items-center">
<LogoSpinner />
</div>
);
}

if (getGroupIssueCount(undefined, undefined, false) === 0) {
return <div className="flex w-full h-full items-center justify-center">No work items Found</div>;
return <div className="size-full grid place-items-center text-secondary">No work items found</div>;
}

return <>{props.children}</>;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,10 @@ export const IssueKanbanLayoutRoot = observer(function IssueKanbanLayoutRoot(pro
return (
<IssueLayoutHOC getGroupIssueCount={getGroupIssueCount} getIssueLoader={getIssueLoader}>
<div
className={`horizontal-scrollbar scrollbar-lg relative flex h-full w-full bg-surface-2 overflow-x-auto overflow-y-hidden`}
className="horizontal-scrollbar scrollbar-lg relative flex size-ful overflow-x-auto overflow-y-hidden"
ref={scrollableContainerRef}
>
<div className="relative h-full w-max min-w-full bg-surface-2">
<div className="relative h-full w-max min-w-full">
<div className="h-full w-max">
<KanBan
groupedIssueIds={groupedIssueIds ?? {}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,10 @@ export const KanbanIssueBlock = observer(function KanbanIssueBlock(props: IssueB
<div className={cn("group/kanban-block relative p-1.5")}>
<div
className={cn(
"relative block rounded-sm border-[1px] outline-[0.5px] outline-transparent w-full border-subtle bg-surface-1 text-13 transition-all hover:border-strong-1",
{ "border border-accent-strong hover:border-accent-strong": getIsIssuePeeked(issue.id) }
"relative block rounded-sm w-full border border-subtle hover:border-strong bg-layer-2 text-13 transition-all",
{
"border-accent-strong hover:border-accent-strong": getIsIssuePeeked(issue.id),
}
)}
>
<Link
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,8 @@ export const KanbanIssueBlocksList = observer(function KanbanIssueBlocksList(pro

return (
<>
{issueIds && issueIds.length > 0 ? (
<>
{issueIds.map((issueId) => {
{issueIds && issueIds.length > 0
? issueIds.map((issueId) => {
if (!issueId) return null;

let draggableId = issueId;
Expand All @@ -37,9 +36,8 @@ export const KanbanIssueBlocksList = observer(function KanbanIssueBlocksList(pro
scrollableContainerRef={scrollableContainerRef}
/>
);
})}
</>
) : null}
})
: null}
</>
);
});
78 changes: 38 additions & 40 deletions apps/space/core/components/issues/issue-layouts/kanban/default.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -80,48 +80,46 @@ export const KanBan = observer(function KanBan(props: IKanBan) {
};

return (
<div className={`relative w-full flex gap-2 px-2 ${subGroupBy ? "h-full" : "h-full"}`}>
{groupList &&
groupList.length > 0 &&
groupList.map((subList: IGroupByColumn) => {
const groupByVisibilityToggle = visibilityGroupBy(subList);
<div className="relative size-full flex gap-2 px-2">
{groupList?.map((subList) => {
const groupByVisibilityToggle = visibilityGroupBy(subList);

if (groupByVisibilityToggle.showGroup === false) return <></>;
return (
<div
key={subList.id}
className={`group relative flex flex-shrink-0 flex-col ${
groupByVisibilityToggle.showIssues ? `w-[350px]` : ``
} `}
>
{isNil(subGroupBy) && (
<div className="sticky top-0 z-[2] w-full flex-shrink-0 bg-surface-2 py-1">
<HeaderGroupByCard
groupBy={groupBy}
icon={subList.icon as any}
title={subList.name}
count={getGroupIssueCount(subList.id, undefined, false) ?? 0}
/>
</div>
)}

{groupByVisibilityToggle.showIssues && (
<KanbanGroup
groupId={subList.id}
groupedIssueIds={groupedIssueIds}
displayProperties={displayProperties}
subGroupBy={subGroupBy}
subGroupId={subGroupId}
scrollableContainerRef={scrollableContainerRef}
loadMoreIssues={loadMoreIssues}
getGroupIssueCount={getGroupIssueCount}
getPaginationData={getPaginationData}
getIssueLoader={getIssueLoader}
if (groupByVisibilityToggle.showGroup === false) return <></>;
return (
<div
key={subList.id}
className={`group relative flex shrink-0 flex-col ${
groupByVisibilityToggle.showIssues ? `w-[350px]` : ``
} `}
>
{isNil(subGroupBy) && (
<div className="sticky top-0 z-2 w-full shrink-0 py-1">
<HeaderGroupByCard
groupBy={groupBy}
icon={subList.icon as any}
title={subList.name}
count={getGroupIssueCount(subList.id, undefined, false) ?? 0}
/>
)}
</div>
);
})}
</div>
)}

{groupByVisibilityToggle.showIssues && (
<KanbanGroup
groupId={subList.id}
groupedIssueIds={groupedIssueIds}
displayProperties={displayProperties}
subGroupBy={subGroupBy}
subGroupId={subGroupId}
scrollableContainerRef={scrollableContainerRef}
loadMoreIssues={loadMoreIssues}
getGroupIssueCount={getGroupIssueCount}
getPaginationData={getPaginationData}
getIssueLoader={getIssueLoader}
/>
)}
</div>
);
})}
</div>
);
});
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,13 @@ export const HeaderGroupByCard = observer(function HeaderGroupByCard(props: IHea

return (
<>
<div className={`relative flex flex-shrink-0 gap-2 p-1.5 w-full flex-row items-center`}>
<div className="flex h-[20px] w-[20px] flex-shrink-0 items-center justify-center overflow-hidden rounded-xs">
<div className="relative flex shrink-0 gap-2 p-1.5 w-full flex-row items-center">
<div className="flex size-5 shrink-0 items-center justify-center overflow-hidden rounded-xs">
{icon ? icon : <Circle width={14} strokeWidth={2} />}
</div>

<div className={`relative flex items-center gap-1 w-full flex-row overflow-hidden`}>
<div className={`line-clamp-1 inline-block overflow-hidden truncate font-medium text-primary`}>{title}</div>
<div className={`flex-shrink-0 text-13 font-medium text-tertiary pl-2`}>{count || 0}</div>
<div className="relative flex items-center gap-1 w-full flex-row overflow-hidden">
<div className="line-clamp-1 inline-block overflow-hidden truncate font-medium text-primary">{title}</div>
<div className="shrink-0 text-13 font-medium text-tertiary pl-2">{count || 0}</div>
</div>
</div>
</>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ export const KanbanGroup = observer(function KanbanGroup(props: IKanbanGroup) {
<div
className="w-full p-3 text-13 font-medium text-accent-primary hover:text-accent-secondary hover:underline cursor-pointer"
onClick={loadMoreIssuesInThisGroup}
role="button"
>
{" "}
Load More &darr;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export const IssuesListLayoutRoot = observer(function IssuesListLayoutRoot(props

return (
<IssueLayoutHOC getGroupIssueCount={getGroupIssueCount} getIssueLoader={getIssueLoader}>
<div className={`relative size-full bg-surface-2`}>
<div className="relative size-full">
<List
displayProperties={displayProperties}
groupBy={"state"}
Expand Down
12 changes: 6 additions & 6 deletions apps/space/core/components/issues/issue-layouts/list/block.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,18 +50,18 @@ export const IssueBlock = observer(function IssueBlock(props: IssueBlockProps) {
<div
ref={issueRef}
className={cn(
"group/list-block min-h-11 relative flex flex-col md:flex-row md:items-center gap-3 bg-surface-1 hover:bg-surface-2 p-3 pl-1.5 text-13 transition-colors border-b border-b-subtle-1",
"group/list-block min-h-11 relative flex flex-col md:flex-row md:items-center gap-3 hover:bg-layer-transparent-hover p-3 pl-1.5 text-13 transition-colors border border-transparent border-b-subtle",
{
"border-accent-strong": getIsIssuePeeked(issue.id),
"border-accent-strong!": getIsIssuePeeked(issue.id),
"last:border-b-transparent": !getIsIssuePeeked(issue.id),
}
)}
>
<div className="flex w-full truncate">
<div className="flex flex-grow items-center gap-0.5 truncate">
<div className="flex grow items-center gap-0.5 truncate">
<div className="flex items-center gap-1">
{displayProperties && displayProperties?.key && (
<div className="flex-shrink-0 text-11 font-medium text-tertiary px-4">
<div className="shrink-0 text-11 font-medium text-tertiary px-4">
{projectIdentifier}-{issue.sequence_id}
</div>
)}
Expand All @@ -79,9 +79,9 @@ export const IssueBlock = observer(function IssueBlock(props: IssueBlockProps) {
</Link>
</div>
</div>
<div className="flex flex-shrink-0 items-center gap-2">
<div className="flex shrink-0 items-center gap-2">
<IssueProperties
className="relative flex flex-wrap md:flex-grow md:flex-shrink-0 items-center gap-2 whitespace-nowrap"
className="relative flex flex-wrap md:grow md:shrink-0 items-center gap-2 whitespace-nowrap"
issue={issue}
displayProperties={displayProperties}
/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,10 @@ export function IssueBlocksList(props: Props) {
const { issueIds = [], groupId, displayProperties } = props;

return (
<div className="relative h-full w-full">
{issueIds &&
issueIds?.length > 0 &&
issueIds.map((issueId: string) => (
<IssueBlock key={issueId} issueId={issueId} displayProperties={displayProperties} groupId={groupId} />
))}
<div className="relative size-full">
{issueIds?.map((issueId) => (
<IssueBlock key={issueId} issueId={issueId} displayProperties={displayProperties} groupId={groupId} />
))}
</div>
);
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import type {
TGroupedIssues,
IIssueDisplayProperties,
TIssueGroupByOptions,
IGroupByColumn,
TPaginationData,
TLoader,
} from "@plane/types";
Expand Down Expand Up @@ -67,7 +66,7 @@ export const List = observer(function List(props: IList) {
ref={containerRef}
className="size-full vertical-scrollbar scrollbar-lg relative overflow-auto vertical-scrollbar-margin-top-md"
>
{groupList.map((group: IGroupByColumn) => (
{groupList.map((group) => (
<ListGroup
key={group.id}
groupIssueIds={groupedIssueIds?.[group.id]}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,15 @@ export const HeaderGroupByCard = observer(function HeaderGroupByCard(props: IHea
return (
<>
<div
className="group/list-header relative w-full flex-shrink-0 flex items-center gap-2 py-1.5"
className="group/list-header relative w-full shrink-0 flex items-center gap-2 py-1.5 hover:bg-layer-transparent-hover px-2 py-1"
onClick={() => toggleListGroup(groupID)}
role="button"
>
<div className="flex-shrink-0 grid place-items-center overflow-hidden">
<div className="shrink-0 size-3.5 grid place-items-center overflow-hidden">
{icon ?? <CircleDashed className="size-3.5" strokeWidth={2} />}
</div>

<div className="relative flex w-full flex-row items-center gap-1 overflow-hidden cursor-pointer">
<div className="relative flex w-full items-center gap-1 overflow-hidden cursor-pointer">
<div className="inline-block line-clamp-1 truncate font-medium text-primary">{title}</div>
<div className="pl-2 text-13 font-medium text-tertiary">{count || 0}</div>
</div>
Expand Down
Loading