Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PRO-6870 Export Templates #99

Merged
merged 4 commits into from
Jan 9, 2025
Merged

PRO-6870 Export Templates #99

merged 4 commits into from
Jan 9, 2025

Conversation

ValJed
Copy link
Contributor

@ValJed ValJed commented Jan 6, 2025

PRO-6871
PRO-6870

PRs

Summary

  • Add margin top to grid
  • Gets related types in export modal for all checked doc types (and not for the doc template module itself).

What are the specific steps to test this change?

  • There is a nice margin between the manager toolbar and the grid.
  • When export batching, the related types you can check should match all the types of templates you checked (and not the related types of the template module).

Cypress tests: 🟠

What kind of change does this PR introduce?

  • Bug fix
  • New feature
  • Refactor
  • Documentation
  • Build-related changes
  • Other

Make sure the PR fulfills these requirements:

  • It includes a) the existing issue ID being resolved, b) a convincing reason for adding this feature, or c) a clear description of the bug it resolves
  • The changelog is updated
  • Related documentation has been updated
  • Related tests have been updated

@ValJed ValJed marked this pull request as draft January 6, 2025 16:26
@ValJed ValJed self-assigned this Jan 6, 2025
return this.moduleName === '@apostrophecms/page' && !this.type
? [ ...new Set(this.checkedTypes) ]
: [ this.type ];
return this.checkedTypes || [ this.type ];
Copy link
Contributor Author

Choose a reason for hiding this comment

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

checkedTypes is passed when meant to be used (like for pages and templates).

@ValJed ValJed force-pushed the pro-6870-export-templates branch from 268580e to 92d77f4 Compare January 6, 2025 16:27
@ValJed ValJed force-pushed the pro-6870-export-templates branch from 5f6536e to cd5cd9e Compare January 7, 2025 09:49
@@ -151,7 +151,7 @@ export default {
},
checkedTypes: {
type: Array,
default: () => []
default: null
Copy link
Contributor Author

Choose a reason for hiding this comment

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

checkedTypes must be null and unused unless passed from another component.

name="fade"
:duration="200"
name="slide"
duration="200"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixing transition that wasn't working anymore.

? moduleOptions.pluralLabel
: moduleOptions.label;
? labels.pluralLabel
: labels.label;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

We know use moduleLabels if existing.

? this.checkedRelatedTypes.length * CONTAINER_ITEM_HEIGHT + CONTAINER_DESCRIPTION_HEIGHT
: CONTAINER_MINIMUM_HEIGHT;

await this.$nextTick();
Copy link
Contributor Author

Choose a reason for hiding this comment

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

It worked until now because we make an http request before. But without the ref container isn't accessible.
Just a guard to make sure it'll work whatever time takes the request.


100% {
height: var(--container-height);
}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixing broken animation.

haroun
haroun previously approved these changes Jan 9, 2025
@ValJed ValJed force-pushed the pro-6870-export-templates branch from 76160dd to d460c75 Compare January 9, 2025 09:39
@ValJed ValJed requested a review from haroun January 9, 2025 09:44
@ValJed ValJed merged commit d406584 into main Jan 9, 2025
9 checks passed
@ValJed ValJed deleted the pro-6870-export-templates branch January 9, 2025 13:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants