Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat(site): show version files diff based on active version#11686

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
BrunoQuaresma merged 1 commit intomainfrombq/show-diff-with-active-version
Jan 18, 2024

Conversation

BrunoQuaresma
Copy link
Collaborator

Close#11295

@BrunoQuaresmaBrunoQuaresma requested a review froma teamJanuary 18, 2024 16:28
@BrunoQuaresmaBrunoQuaresma self-assigned thisJan 18, 2024
@BrunoQuaresmaBrunoQuaresma requested review fromParkreiner and removed request fora teamJanuary 18, 2024 16:28
Copy link
Member

@ParkreinerParkreiner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

This all looks really good! Just had one possible suggestion, but I don't know enough about the business to logic to say if it's a good idea

@@ -236,6 +237,38 @@ export const resources = (versionId: string) => {
};
};

export const templateFiles = (fileId: string) => {
return {
queryKey: ["templateFiles", fileId],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Do you think it makes sense to update the query keys fortemplateFiles andpreviousTemplateVersion to start with something like"template"? Feels like it'd be a good way to make sure we have an easy way to invalidate any template queries down the line

Copy link
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

If we had the template ID or name I would say yes, but since they are "isolated" I'm ok to keep the current names until we see value in changing them.

tab,
}) => {
const filenames = Object.keys(currentFiles);
const selectedFilename = filenames[Number(tab.value)];
const currentFile = currentFiles[selectedFilename];
const previousFile =previousFiles &&previousFiles[selectedFilename];
const previousFile =baseFiles &&baseFiles[selectedFilename];
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Not a call out to your code, but there's some weird behavior here (based aroundundefined) that I'm guessing that the compiler isn't complaining about right now, because we don't have it set strictly enough.

Here's aTypeScript snippet with the compiler tightened up. I'm going to be bringing this up at the Frontend Variety later today

Copy link
CollaboratorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

@BrunoQuaresmaBrunoQuaresma merged commit156aaba intomainJan 18, 2024
@BrunoQuaresmaBrunoQuaresma deleted the bq/show-diff-with-active-version branchJanuary 18, 2024 19:08
@github-actionsgithub-actionsbot locked and limited conversation to collaboratorsJan 18, 2024
Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.
Reviewers

@ParkreinerParkreinerParkreiner approved these changes

Assignees

@BrunoQuaresmaBrunoQuaresma

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

template versions: show diff with active version
2 participants
@BrunoQuaresma@Parkreiner

[8]ページ先頭

©2009-2025 Movatter.jp