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
2 changes: 1 addition & 1 deletion packages/constants/src/issue/filter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ export const ISSUE_DISPLAY_FILTERS_BY_PAGE: TIssueFiltersToDisplayByPageType = {
sub_work_items: {
list: {
display_properties: SUB_ISSUES_DISPLAY_PROPERTIES_KEYS,
filters: ["priority", "state", "project", "issue_type", "assignees", "start_date", "target_date"],
filters: ["priority", "state", "issue_type", "assignees", "start_date", "target_date"],
display_filters: {
order_by: ["-created_at", "-updated_at", "start_date", "-priority"],
group_by: ["state", "priority", "assignees", null],
Expand Down
6 changes: 4 additions & 2 deletions web/core/components/dropdowns/state.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ type Props = TDropdownProps & {
filterAvailableStateIds?: boolean;
isForWorkItemCreation?: boolean;
alwaysAllowStateChange?: boolean;
iconSize?: string;
};

export const StateDropdown: React.FC<Props> = observer((props) => {
Expand All @@ -60,6 +61,7 @@ export const StateDropdown: React.FC<Props> = observer((props) => {
value,
renderByDefault = true,
stateIds,
iconSize = "size-4",
} = props;
// states
const [query, setQuery] = useState("");
Expand Down Expand Up @@ -101,7 +103,7 @@ export const StateDropdown: React.FC<Props> = observer((props) => {
<StateGroupIcon
stateGroup={state?.group ?? "backlog"}
color={state?.color}
className="size-4 flex-shrink-0"
className={cn("flex-shrink-0", iconSize)}
percentage={state?.order}
/>
<span className="flex-grow truncate text-left">{state?.name}</span>
Expand Down Expand Up @@ -184,7 +186,7 @@ export const StateDropdown: React.FC<Props> = observer((props) => {
<StateGroupIcon
stateGroup={selectedState?.group ?? "backlog"}
color={selectedState?.color ?? "rgba(var(--color-text-300))"}
className="size-4 flex-shrink-0"
className={cn("flex-shrink-0", iconSize)}
percentage={selectedState?.order}
/>
)}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,10 @@ export const SubIssuesListItemProperties: React.FC<Props> = observer((props) =>
)
}
disabled={!disabled}
buttonVariant="border-with-text"
buttonVariant="transparent-without-text"
buttonClassName="hover:bg-transparent px-0"
iconSize="size-5"
showTooltip
/>
</div>
</WithDisplayPropertiesHOC>
Expand All @@ -80,33 +83,7 @@ export const SubIssuesListItemProperties: React.FC<Props> = observer((props) =>
disabled={!disabled}
buttonVariant="border-without-text"
buttonClassName="border"
/>
</div>
</WithDisplayPropertiesHOC>

<WithDisplayPropertiesHOC displayProperties={displayProperties} displayPropertyKey="start_date">
<div className="h-5 flex-shrink-0" onFocus={handleEventPropagation} onClick={handleEventPropagation}>
<DateDropdown
value={issue.start_date ?? null}
onChange={(val) =>
issue.project_id &&
updateSubIssue(
workspaceSlug,
issue.project_id,
parentIssueId,
issueId,
{
start_date: val ? renderFormattedPayloadDate(val) : null,
},
{ ...issue }
)
}
maxDate={maxDate}
placeholder={t("common.order_by.start_date")}
icon={<CalendarClock className="h-3 w-3 flex-shrink-0" />}
buttonVariant={issue.start_date ? "border-with-text" : "border-without-text"}
optionsClassName="z-30"
disabled={!disabled}
showTooltip
/>
</div>
</WithDisplayPropertiesHOC>
Expand Down