chadtmiller.com/knotless
git that lives in your Atmosphere account
1
10
iOS app edits and deletes one's own comments and opens authors' profiles
Merged Approved
The iOS part does what the body says. A comment's author is now a profile link. A comment of one's own offers Edit and Delete in place of Report. Edit reuses Composer through editing and sends editItem. Delete confirms, then sends the new Writes.deleteComment, whose repo and subject match dev.knotless.deleteComment. I did not run it, and the body says edit and delete were not tried against a live appview.
- Doc comment misplaced: in
Writes.swift,deleteCommentwas inserted betweenrerun's doc comment andrerun, sorerunnow carriesdeleteComment's doc text and its own is attached to nothing useful. Move it abovererun. - Unrelated changes in the diff:
pull_diffalso shows the agent and invite change forknotless-agent --ownerfinding private repos. That coverscrates/knotless-agent,crates/knotless/src/manage.rs,deploy.yml, the docs pages and.changeset/owner-watches-private.md. The title and body don't mention any of it. If it came in from another branch, drop it from this pull. If it is meant to ship here, add it to the body. I did not review that part in depth.
ios/Knotless/API/Writes.swiftline 105
/// Takes back one's own comment or review. | |
static func deleteComment(repo: RepoRef, subject: String) -> Write { | |
Write(method: "deleteComment", input: ["repo": repo.uri, "subject": subject]) | |
} |
rerun's doc comment ("The runners run a pull's head…") sits above deleteComment's own, which leaves rerun without a description. Put deleteComment above that comment.
All checks have passed
8 passed, 2 skipped
Merged as 3357f98
What changes
A comment's author opens their profile. In a pull's or issue's thread, a comment's avatar and handle are now a link to its author's profile, as the item's author already was.
One's own comment can be edited and deleted. Signed in, the menu on a comment of one's own offers Edit and Delete in place of Report. Edit opens the comment composer filled with its body, titled "Edit comment", and saves with
editItem; Delete asks "Delete this comment for good?", as the web pages do, then sends a newWrites.deleteComment(dev.knotless.deleteComment,repoandsubject). Either re-reads the thread; a failure shows "That didn't work". Others' comments still offer only Report.Why
The web pages let a comment's author edit and delete it, and open an author's profile from it; the app did neither. The existing
Composertakes aneditingbody rather than a second editor being added.How it was checked
Built for the simulator;
just ios-look issue-openwith the fixture viewer (alice.test), who wrote the issue's comment, tapping the menu, then Edit and Delete, light and dark: pictures attached.Shortcomings
Saving an edit and deleting were not exercised against a live appview, only drawn from fixtures.