This repository has been archived by the owner on Sep 5, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(tabs): add accessibility links between tabs and content
Additionally, the static tabs demo now has aria links between tabs and content.
- Loading branch information
Showing
23 changed files
with
632 additions
and
521 deletions.
There are no files selected for viewing
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
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
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,33 @@ | ||
<div ng-controller="AppCtrl" class="sample"> | ||
|
||
<md-tabs selected="selectedIndex"> | ||
<md-tab ng-repeat="tab in tabs" | ||
on-select="onTabSelected(tab)" | ||
on-deselect="announceDeselected(tab)" | ||
ng-disabled="tab.disabled" | ||
label="{{tab.title}}"> | ||
<md-tabs selected="selectedIndex"> | ||
<md-tab ng-repeat="tab in tabs" | ||
on-select="announceSelected(tab)" | ||
on-deselect="announceDeselected(tab)" | ||
ng-disabled="tab.disabled" | ||
label="{{tab.title}}"> | ||
|
||
<div ng-class="tab.style" layout="vertical" layout-fill layout-align="center center"> | ||
<div flex ng-bind="tab.content" class="tab-text"></div> | ||
<md-button class="remove-tab md-warn" | ||
ng-click="removeTab( tab )">Remove Tab | ||
</md-button> | ||
</div> | ||
</md-tab> | ||
</md-tabs> | ||
<div class="demo-tab tab{{$index%4}}" layout="vertical" layout-fill layout-align="space-around center"> | ||
<div ng-bind="tab.content"></div> | ||
<md-button class="md-warn" ng-click="removeTab( tab )"> | ||
Remove Tab | ||
</md-button> | ||
</div> | ||
</md-tab> | ||
</md-tabs> | ||
|
||
<form ng-submit="addTab(tTitle,tContent)" flex> | ||
<div layout="vertical" layout-sm="horizontal" layout-padding layout-align="left center"> | ||
<md-text-float label="Active Index" ng-model="selectedIndex" disabled></md-text-float> | ||
<md-text-float label="Active Title" ng-model="tabs[selectedIndex].title"></md-text-float> | ||
<md-text-float label="Active Content" ng-model="tabs[selectedIndex].content" class="long"></md-text-float> | ||
</div> | ||
<div layout="vertical" layout-sm="horizontal" layout-padding layout-align="left center"> | ||
<span class="title">Add a new Tab:</span> | ||
<md-text-float label="Label" ng-model="tTitle"></md-text-float> | ||
<md-text-float label="Content" ng-model="tContent" ></md-text-float> | ||
<md-button class="add-tab md-primary" type="submit" style="max-height: 40px" >Add Tab</md-button> | ||
</div> | ||
</form> | ||
<form ng-submit="addTab(tTitle,tContent)" flex> | ||
<div layout="vertical" layout-sm="horizontal" layout-padding layout-align="left center"> | ||
<md-text-float label="Active Index" ng-model="selectedIndex" disabled></md-text-float> | ||
<md-text-float label="Active Title" ng-model="tabs[selectedIndex].title"></md-text-float> | ||
</div> | ||
<div layout="vertical" layout-sm="horizontal" layout-padding layout-align="left center"> | ||
<span class="title">Add a new Tab:</span> | ||
<md-text-float label="Label" ng-model="tTitle"></md-text-float> | ||
<md-text-float label="Content" ng-model="tContent" ></md-text-float> | ||
<md-button class="add-tab md-primary" type="submit" style="max-height: 40px" >Add Tab</md-button> | ||
</div> | ||
</form> | ||
|
||
|
||
</div> |
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
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
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.