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

Set up dataset page #9

Merged
merged 8 commits into from
Feb 1, 2024
Merged

Set up dataset page #9

merged 8 commits into from
Feb 1, 2024

Conversation

tkohr
Copy link
Member

@tkohr tkohr commented Jan 30, 2024

The goal of this PR is to set a base for the dataset page by

  • providing it with the relevant information to display via the MdViewFacade
  • setting up a basic template
  • ensure routing to and re-loading the dataset page works properly

To-dos for upcoming UI work are marked in the template.

Copy link
Contributor

@Angi-Kinas Angi-Kinas left a comment

Choose a reason for hiding this comment

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

Thanks for setting up the dataset details page 🚀 !
I think for the initial setup it looks good. Later on we can exchange the components and adapt it to the MEL style.
I couldn't find a dataset that has API, so I did not test this part.
Maybe you also want to add some e2e tests? Just to check if the main components are present.

</div>
<!-- TODO: create corresponding UI component -->
<div>
<div>mel.dataset.informations</div>
Copy link
Contributor

Choose a reason for hiding this comment

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

Did you add this key in the translation file already? I could not find it, but it still seems to work..?

Copy link
Member Author

Choose a reason for hiding this comment

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

Ah, good catch, I even forgot to add the translate attribute. Strangely this does not get extracted even after adding the attribute 🤔

</div>
</div>
} }
<div
Copy link
Contributor

Choose a reason for hiding this comment

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

I think this should be the @else case?

Copy link
Member Author

Choose a reason for hiding this comment

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

Good point, I've updated this

>
<div class="bg-primary-opacity-10 py-8">
<div class="flex flex-col px-4 gap-8 container-lg lg:mx-auto">
<div class="flex flex-wrap justify-between sm:mb-2 ng-star-inserted">
Copy link
Contributor

Choose a reason for hiding this comment

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

What does the ng-star-inserted do? Isn't that something internally from angular?

Copy link
Member Author

Choose a reason for hiding this comment

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

Not sure, this comes from gn-ui for now but will surely still change

tkohr added 5 commits January 31, 2024 16:09
allowing to display relevant information from mdview.facade
based on gn-ui's record-apis and underlying components
which was broken due to StoreRouterConnectingModule.forRoot()
somehow mel.dataset.informations is not extracted and keys already translated in gn-ui are extracted
@tkohr
Copy link
Member Author

tkohr commented Jan 31, 2024

Thanks for the review @Angi-Kinas. I haven't added any e2e tests here yet, as the goal was just to make the information accessible to the UI parts. I think we should add the e2e tests when we implement the UI, as the DOM and tag names will still change significantly. What do you think?

There is still an issue open with the i18n extraction not working properly in this PR, however.

@tkohr
Copy link
Member Author

tkohr commented Feb 1, 2024

The i18n translation issue has been solved by updating to @vendure/ngx-translate-extract. The former package does not support angular control-flow syntax and is not maintained anymore.

Copy link
Contributor

@Angi-Kinas Angi-Kinas left a comment

Choose a reason for hiding this comment

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

Looks good to me 👍

@tkohr tkohr merged commit 9b63169 into main Feb 1, 2024
6 checks passed
@tkohr tkohr deleted the dataset-smart branch February 1, 2024 14:15
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