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(material/tabs): add alignTabs in MatTabsConfig #29779

Merged
merged 1 commit into from
Sep 26, 2024

Conversation

naaajii
Copy link
Contributor

@naaajii naaajii commented Sep 23, 2024

users can align tabs label via config now rather than adding mat-tab-align property on each tab group

fixes #29685

@angular-robot angular-robot bot added the detected: feature PR contains a feature commit label Sep 23, 2024
@naaajii naaajii force-pushed the feat/29685 branch 2 times, most recently from 0021fc8 to 60f2556 Compare September 24, 2024 00:05
@naaajii naaajii marked this pull request as ready for review September 24, 2024 00:14
@naaajii naaajii requested a review from a team as a code owner September 24, 2024 00:15
@naaajii naaajii requested review from crisbeto and wagnermaciel and removed request for a team September 24, 2024 00:15
@crisbeto crisbeto added action: merge The PR is ready for merge by the caretaker target: major This PR is targeted for the next major release labels Sep 25, 2024
@crisbeto crisbeto removed the request for review from wagnermaciel September 25, 2024 06:55
@@ -147,6 +148,10 @@ export class MatTabGroup implements AfterContentInit, AfterContentChecked, OnDes
@Input({alias: 'mat-stretch-tabs', transform: booleanAttribute})
stretchTabs: boolean = true;

/** Alignment for tabs label. */
@Input({alias: 'mat-align-tabs'})
alignTabs: 'start' | 'center' | 'end' | null = null;
Copy link
Member

Choose a reason for hiding this comment

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

While this is the correct type, it looks like we'll have to set it to string | null since it breaks some cases internally.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I updated it but internal cases CI is still pending not sure if recent push triggered it or not.

image

also this is wrong place to ask but when I run yarn after fork it keeps failing with:

[3/5] Fetching packages...
error Couldn't find match for "36946be4df61f6549ae3829c026022e47674eae2" in "refs/heads/main" for "https://github.com/angular/dev-infra-private-ng-dev-builds.git".
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
my-pc@mypc-Latitude-3310:~/Development/angular-projects/open-source/components$ 

I tried to manually install the package in a clean folder with only @angular/ng-dev package but it still failed I have a global setting for specific NPM packages but they only work with npm (not sure if they will collide with yarn) & also this is something that came up recently, I was able to install packages before IIRC.

@naaajii naaajii changed the title feat(material/tabs): add align in MatTabsConfig feat(material/tabs): add alignTabs in MatTabsConfig Sep 25, 2024
users can align tabs label via config now rather than adding `mat-tab-align` property on each tab group

fixes angular#29685
@crisbeto crisbeto merged commit ff3d342 into angular:main Sep 26, 2024
20 of 22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
action: merge The PR is ready for merge by the caretaker detected: feature PR contains a feature commit target: major This PR is targeted for the next major release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat(MatTabsModule): Allow alignTabs and stretchTabs on MAT_TABS_CONFIG
2 participants