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

feat(module:modal): expose componentRef nzContent #8389

Conversation

Nicoss54
Copy link
Collaborator

@Nicoss54 Nicoss54 commented Feb 2, 2024

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

[ ] Bugfix
[X] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Documentation content changes
[ ] Application (the showcase website) / infrastructure changes
[ ] Other... Please describe:

What is the current behavior?

Currently modalRef don't expose the componentRef of nzContent which is too restricted. With the new API of Angular, user must have he possibilities to retrieve the ref of the component of nzContent to use for exemple APIs like setInput

Issue Number: N/A

What is the new behavior?

Now ModalRef expose the component Ref of the nzContent when nzContent is a component. This exposition is done by the mehtod getComponentRef which return the ref in a readonly mode

Does this PR introduce a breaking change?

[ ] Yes
[X] No

Other information

Copy link

zorro-bot bot commented Feb 2, 2024

This preview will be available after the AzureCI is passed.

Copy link

codecov bot commented Feb 2, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (f71162b) 91.74% compared to head (1bd9fa0) 91.75%.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #8389   +/-   ##
=======================================
  Coverage   91.74%   91.75%           
=======================================
  Files         520      520           
  Lines       18023    18028    +5     
  Branches     2838     2838           
=======================================
+ Hits        16535    16541    +6     
+ Misses       1185     1184    -1     
  Partials      303      303           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@HyperLife1119
Copy link
Collaborator

Can you add Chinese documentation? :D

@Nicoss54
Copy link
Collaborator Author

Nicoss54 commented Feb 8, 2024

Can you add Chinese documentation? :D

I'm sorry i don't speak chinese, but if you can give me the translation i will add it :)

@HyperLife1119
Copy link
Collaborator

Can you add Chinese documentation? :D

I'm sorry i don't speak chinese, but if you can give me the translation i will add it :)

Never mind, let's finish it in a subsequent PR.

@EnochGao Are you interested in translating this document? And #8339 :)

Copy link
Collaborator

@HyperLife1119 HyperLife1119 left a comment

Choose a reason for hiding this comment

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

LGTM

@HyperLife1119 HyperLife1119 merged commit e53000e into NG-ZORRO:master Feb 8, 2024
9 checks passed
@Nicoss54 Nicoss54 deleted the feature/expose-content-component-ref-modal branch February 8, 2024 16:58
@EnochGao
Copy link
Contributor

EnochGao commented Feb 8, 2024

Can you add Chinese documentation? :D

I'm sorry i don't speak chinese, but if you can give me the translation i will add it :)

Never mind, let's finish it in a subsequent PR.

@EnochGao Are you interested in translating this document? And #8339 :)

Ok, I will translate after the merger is successful. ^o^

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants