Skip to content
Open
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
6 changes: 1 addition & 5 deletions frontend/app/.betterer.results
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,12 @@ exports[`fix ts error`] = {
"src/entities/branches/domain/rebase-branch.ts:1637423651": [
[14, 13, 12, "tsc: Type \'\\"MERGED\\" | \\"NEED_REBASE\\" | \\"NEED_UPGRADE_REBASE\\" | \\"OPEN\\"; sync_with_git: boolean | ({ branchName, waitUntilCompletion, }: RebaseBranchParams) => Promise<{ branch: { id: string; name: string; description: string | null; branched_from: string | null; created_at: string | null; has_schema_changes: boolean | null; is_default: boolean | null; origin_branch: string | null; status: \\"DELETING\\" | null; }; relatedTaskId: string | null; }>\' is not assignable to type \'RebaseBranch\'.\\n Type \'\\"MERGED\\" | \\"NEED_REBASE\\" | \\"NEED_UPGRADE_REBASE\\" | \\"OPEN\\"; sync_with_git: boolean | Promise<{ branch: { id: string; name: string; description: string | null; branched_from: string | null; created_at: string | null; has_schema_changes: boolean | null; is_default: boolean | null; origin_branch: string | null; status: \\"DELETING\\" | null; }; relatedTaskId: string | null; }>\' is not assignable to type \'Promise<null; } | { branch: Branch; relatedTaskId: string>\'.\\n Type \'\\"MERGED\\" | \\"NEED_REBASE\\" | \\"NEED_UPGRADE_REBASE\\" | \\"OPEN\\"; sync_with_git: boolean | null; branched_from: string | null; created_at: string | null; has_schema_changes: boolean | null; is_default: boolean | null; origin_branch: string | null; status: \\"DELETING\\" | null; } | null; }; relatedTaskId: string | { branch: { id: string; name: string; description: string\' is not assignable to type \'{ branch: Branch; relatedTaskId: string | null; }\'.\\n Types of property \'branch\' are incompatible.\\n Type \'\\"MERGED\\" | \\"NEED_REBASE\\" | \\"NEED_UPGRADE_REBASE\\" | \\"OPEN\\"; sync_with_git: boolean | null; branched_from: string | null; created_at: string | null; has_schema_changes: boolean | null; is_default: boolean | null; origin_branch: string | null; status: \\"DELETING\\" | null; } | { id: string; name: string; description: string\' is missing 3 properties from type \'Branch\'", "3009771795"]
],
"src/entities/branches/ui/branch-create-form.tsx:341871100": [
"src/entities/branches/ui/branch-create-form.tsx:2904341468": [
[34, 33, 13, "tsc: Argument of type \'BranchListItem\' is not assignable to parameter of type \'Branch\'.\\n Type \'BranchListItem\' is missing 3 properties from type \'Branch\'", "2717214769"],
[54, 7, 10, "tsc: Property \'attribute\' is missing in type \'\\"Required\\"; minLength: ({ value }: Pick<FormFieldValue, \\"value\\">) => string | true; }; }; } | undefined; autoFocus: true; rules: { required: true; validate: { required: ({ value }: Pick<FormFieldValue, \\"value\\">) => true | { name: string; label: string; defaultValue: { source: { type: \\"user\\"; }; value: string; }\' but required in type \'InputFieldProps\'.", "1610618705"],
[70, 7, 10, "tsc: Property \'attribute\' is missing in type \'{ name: string; label: string; }\' but required in type \'InputFieldProps\'.", "1610618705"],
[72, 7, 13, "tsc: Property \'attribute\' is missing in type \'{ name: string; label: string; rules: { required: true; }; }\' but required in type \'FormFieldProps\'.", "3862624788"]
],
"src/entities/branches/ui/branch-selector.tsx:938066799": [
[131, 16, 6, "tsc: Type \'null | null | null | null | undefined; created_at: string | undefined; has_schema_changes: boolean | undefined; is_default: boolean | undefined; } | { id: string; name: string; status: BranchStatus; sync_with_git: boolean\' is missing 6 properties from type \'Branch\'", "1513838097"],
[132, 51, 6, "tsc: Argument of type \'null | null | null | null | undefined; created_at: string | undefined; has_schema_changes: boolean | undefined; is_default: boolean | undefined; } | { id: string; name: string; status: BranchStatus; sync_with_git: boolean\' is not assignable to parameter of type \'Branch\'.\\n Type \'null | null | null | null | undefined; created_at: string | undefined; has_schema_changes: boolean | undefined; is_default: boolean | undefined; } | { id: string; name: string; status: BranchStatus; sync_with_git: boolean\' is missing 6 properties from type \'Branch\'", "1513838097"]
],
"src/entities/diff/ui/artifact-diff/artifact-content-diff.tsx:2250610657": [
[8, 39, 9, "tsc: Could not find a declaration file for module \'unidiff\'. \'../../../../../node_modules/.pnpm/unidiff@1.0.4/node_modules/unidiff/index.js\' implicitly has an \'any\' type.\\n Try \`npm i --save-dev @types/unidiff\` if it exists or add a new declaration (.d.ts) file containing \`declare module \'unidiff\';\`", "1870574010"],
[30, 13, 23, "tsc: No overload matches this call.\\n Overload 1 of 3, \'(message: Buffer<ArrayBufferLike> | string, options?: Sha1AsStringOptions | undefined): string\', gave the following error.\\n Argument of type \'number\' is not assignable to parameter of type \'Buffer<ArrayBufferLike> | string\'.\\n Overload 2 of 3, \'(message: Buffer<ArrayBufferLike> | string, options?: Sha1AsBytesOptions | undefined): Uint8Array<ArrayBufferLike>\', gave the following error.\\n Argument of type \'number\' is not assignable to parameter of type \'string | Buffer<ArrayBufferLike>\'.\\n Overload 3 of 3, \'(message: string | Buffer<ArrayBufferLike>, options?: Sha1Options | Uint8Array<ArrayBufferLike> | undefined): string\', gave the following error.\\n Argument of type \'number\' is not assignable to parameter of type \'string | Buffer<ArrayBufferLike>\'.", "1877915893"],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,13 @@ const BranchCreateForm = ({ defaultBranchName, onCancel, onSuccess }: BranchCrea
<CheckboxField name="sync_with_git" label="Sync with Git" rules={{ required: true }} />

<Row className="justify-end">
<Button variant="outline" onPress={onCancel}>
<Button variant="outline" size="sm" onPress={onCancel}>
Cancel
</Button>

<FormSubmit data-testid="submit-create-new-branch">Create a new branch</FormSubmit>
<FormSubmit size="sm" data-testid="submit-create-new-branch">
Create a new branch
</FormSubmit>
</Row>
</Form>
);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
import { Badge, type BadgeProps } from "@/shared/components/ui/badge";
import type { BadgeProps } from "@/shared/components/ui/badge";
import { classNames } from "@/shared/utils/common";

export function BranchDefaultBadge({ className, ...props }: BadgeProps) {
return (
<Badge className={classNames("rounded-full font-normal text-gray-700", className)} {...props}>
<span
className={classNames(
"rounded-full border border-stone-300 bg-transparent px-1.5 py-0.5 text-stone-600 text-xs",
className
)}
{...props}
>
default
</Badge>
</span>
);
}
Loading
Loading