refactor: switched priority null -> 'none' (#2166)

This commit is contained in:
Dakshesh Jain 2023-09-13 13:22:31 +05:30 committed by GitHub
parent e58b76c8a6
commit 23e62c83eb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 5 additions and 5 deletions

View File

@ -52,7 +52,7 @@ const defaultValues: Partial<IIssue> = {
estimate_point: null,
state: "",
parent: null,
priority: null,
priority: "none",
assignees: [],
assignees_list: [],
labels: [],

View File

@ -40,7 +40,7 @@ export const IssuePrioritySelect: React.FC<Props> = ({ value, onChange }) => (
<span>
<PriorityIcon priority={priority} />
</span>
<span className="capitalize">{priority ?? "None"}</span>
<span className="capitalize">{priority}</span>
</div>
</div>
</CustomSelect.Option>

View File

@ -39,7 +39,7 @@ export const PrioritySelect: React.FC<Props> = (props) => {
<WebViewModal.Options
options={
PRIORITIES?.map((priority) => ({
label: priority ? capitalizeFirstLetter(priority) : "None",
label: capitalizeFirstLetter(priority),
value: priority,
checked: priority === value,
onClick: () => {

View File

@ -21,7 +21,7 @@ export const GROUP_CHOICES = {
cancelled: "Cancelled",
};
export const PRIORITIES: TIssuePriorities[] = ["urgent", "high", "medium", "low", null];
export const PRIORITIES: TIssuePriorities[] = ["urgent", "high", "medium", "low", "none"];
export const MONTHS = [
"January",

View File

@ -248,4 +248,4 @@ export interface IIssueViewProps {
properties: Properties;
}
export type TIssuePriorities = "urgent" | "high" | "medium" | "low" | null;
export type TIssuePriorities = "urgent" | "high" | "medium" | "low" | "none";