graycoreio / daffodil

Angular Ecommerce PWA Framework
https://next.daff.io
MIT License
156 stars 31 forks source link

feat(design)!: change `daffSizeMixin` to a directive #2925

Closed xelaint closed 3 months ago

xelaint commented 3 months ago

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
[ ] Other... Please describe:

What is the current behavior?

An ElementRef and Renderer need to be constructed for the daffSizeMixin to be extendable or usable in a component.

Part of: #2911

What is the new behavior?

Removed daffSizeMixin in favor of DaffSizableDirective so that a component can use the directive by adding it as a hostDirective. This reduces code complexity.

Dependent on #2913, #2919, #2922, #2923 to be merged first.

Does this PR introduce a breaking change?

[x] Yes
[ ] No

BREAKING CHANGE: daffSizeMixin has been removed in favor of DaffSizableDirective. Update usage by using the hostDirective feature.

Other information