-
Notifications
You must be signed in to change notification settings - Fork 13
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
docs: override prop in manifest #3307
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DavideMininni-Fincons
requested review from
kyubisation and
jeripeierSBB
as code owners
December 17, 2024 14:59
DavideMininni-Fincons
requested review from
TomMenga,
MarioCastigliano and
dauriamarco
December 17, 2024 14:59
github-actions
bot
added
pr: peer review required
A peer review is required for this pull request
target: 2.x
labels
Dec 17, 2024
github-actions
bot
added
preview-available
pr: visual review required
diff-available
labels
Dec 17, 2024
kyubisation
approved these changes
Dec 17, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generally LGTM, apart from the issue with the formatting
github-actions
bot
added
the
pr: lead review approved
Pull request has been approved by a lead review
label
Dec 17, 2024
jeripeierSBB
approved these changes
Dec 18, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! LGTM
jeripeierSBB
changed the title
fix: override prop in manifest
docs: override prop in manifest
Dec 18, 2024
github-actions
bot
removed
the
pr: peer review required
A peer review is required for this pull request
label
Dec 18, 2024
kyubisation
pushed a commit
that referenced
this pull request
Dec 19, 2024
🤖 I have created a release *beep* *boop* --- ## [2.0.2](v2.0.1...v2.0.2) (2024-12-19) ### Bug Fixes * handle scroll events in custom scroll contexts ([#3310](#3310)) ([3634e37](3634e37)), closes [#3276](#3276) * improve null/undefined type handling for Angular wrapper ([#3302](#3302)) ([2f94992](2f94992)) * remove any type for Angular wrapper ([#3297](#3297)) ([dca7ba5](dca7ba5)) * remove leading inline padding from icon list ([#3311](#3311)) ([b9ce6d1](b9ce6d1)) * **sbb-accent-button:** adapt to new design ([#3313](#3313)) ([1af2691](1af2691)) * **sbb-message:** fix image alignment ([#3305](#3305)) ([1d4a5de](1d4a5de)) * **sbb-select:** update displayed value on option label change ([#3300](#3300)) ([3c2f3c5](3c2f3c5)) * **sbb-teaser-hero:** fix image size on custom width ([#3295](#3295)) ([5fc0634](5fc0634)) ### Documentation * override member properties in manifest ([#3307](#3307)) ([ba25320](ba25320)) * standardize usage of terms `CSS` and `Sass` ([#3290](#3290)) ([b52ac99](b52ac99)) ### Code Refactoring * move event handlers to constructors ([#3314](#3314)) ([18660a3](18660a3)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
diff-available
pr: lead review approved
Pull request has been approved by a lead review
pr: visual review required
preview-available
target: 2.x
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
As already experienced with generics (see 5702592), the manifest generation has some issue when working with superclasses and mixin.
This time, i noticed that if an element extends a base class, and the base class implements a mixin and overrides some of its property, the overriding is not considered during the manifest generation, because the inheritance chain is traversed from the outer to the inner element and not vice versa as expected.
Eg. all the buttons extend the
SbbButtonBaseElement
class, which implements theSbbFormAssociatedMixin
.The
SbbButtonBaseElement
defines via getter/setter theform
property by overriding the defaultform
getter from the mixin; however, the override is not reflected in the manifest, which mark theform
member asreadonly
, as does with getters. Also theinheritedFrom
prop refers to the mixin and not to the base class.This behavior is problematic when the Angular classes are generated, so a manual override must be done; I noticed that the corresponding attribute field is not changed when the inheritance chain it traversed, so it can be used as a 'baseline'.
As a consequence, the
form
jsDoc is overridden in all the button components, taking the correct description from theSbbButtonBaseElement
.NOTE: even if this PR fixes the Angular classes generation, it is not possible to automatically fix the type mismatch between get/set, so this should be done manually in the Angular repo.