This repository has been archived by the owner on Dec 4, 2017. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 879
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
style-guide(add-a11y): Add accessibility quick wins
- Loading branch information
1 parent
0664a27
commit 51a166a
Showing
17 changed files
with
387 additions
and
1 deletion.
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
8 changes: 8 additions & 0 deletions
8
public/docs/_examples/style-guide/ts/10-01/app/app.component.ts
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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import { Component } from '@angular/core'; | ||
|
||
@Component({ | ||
selector: 'sg-app', | ||
template: `<div>I am a page set to US English</div>` | ||
}) | ||
export class AppComponent { | ||
} |
14 changes: 14 additions & 0 deletions
14
public/docs/_examples/style-guide/ts/10-01/app/index.avoid.html
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 |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<!-- avoid --> | ||
|
||
<!DOCTYPE html> | ||
<!-- #docregion page-lang--> | ||
<html> | ||
<!-- #enddocregion page-lang--> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<title>Title</title> | ||
</head> | ||
<body> | ||
<!--Some content--> | ||
</body> | ||
</html> |
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 |
---|---|---|
@@ -0,0 +1,12 @@ | ||
<!DOCTYPE html> | ||
<!-- #docregion page-lang--> | ||
<html lang="en-US"> | ||
<!-- #enddocregion page-lang --> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<title>Title</title> | ||
</head> | ||
<body> | ||
<!--Some content--> | ||
</body> | ||
</html> |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
export * from './app.component'; |
13 changes: 13 additions & 0 deletions
13
public/docs/_examples/style-guide/ts/10-02/app/app.component.avoid.css
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 |
---|---|---|
@@ -0,0 +1,13 @@ | ||
/* #docregion */ | ||
/* avoid */ | ||
|
||
:focus { | ||
outline: 0; | ||
} | ||
|
||
/* or */ | ||
|
||
:focus { | ||
outline: none; | ||
} | ||
/* #enddocregion */ |
7 changes: 7 additions & 0 deletions
7
public/docs/_examples/style-guide/ts/10-02/app/app.component.html
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<label>Name: | ||
<input [(ngModel)]="name"> | ||
</label> | ||
<label>Surname: | ||
<input [(ngModel)]="surname"> | ||
</label> | ||
{{name}}{{surname}} |
11 changes: 11 additions & 0 deletions
11
public/docs/_examples/style-guide/ts/10-02/app/app.component.ts
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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import { Component } from '@angular/core'; | ||
|
||
@Component({ | ||
moduleId: module.id, | ||
selector: 'sg-app', | ||
templateUrl: 'app.component.html' | ||
}) | ||
export class AppComponent { | ||
name: string; | ||
surname: string; | ||
} |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
export * from './app.component'; |
4 changes: 4 additions & 0 deletions
4
public/docs/_examples/style-guide/ts/10-03/app/app.component.avoid.html
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 |
---|---|---|
@@ -0,0 +1,4 @@ | ||
<!-- #docregion --> | ||
<!--avoid--> | ||
<div class="button" (click)="saveData()">Press me</div> | ||
<!-- #enddocregion --> |
11 changes: 11 additions & 0 deletions
11
public/docs/_examples/style-guide/ts/10-03/app/app.component.css
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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
.button { | ||
font-family: Arial; | ||
background-color: #eee; | ||
border: none; | ||
padding: 5px 10px; | ||
border-radius: 4px; | ||
margin-bottom: 5px; | ||
width: 75px; | ||
cursor: pointer; | ||
cursor: hand; | ||
} |
3 changes: 3 additions & 0 deletions
3
public/docs/_examples/style-guide/ts/10-03/app/app.component.html
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<!-- #docregion--> | ||
<button (click)="saveData()">Press me</button> | ||
<!-- #enddocregion --> |
15 changes: 15 additions & 0 deletions
15
public/docs/_examples/style-guide/ts/10-03/app/app.component.ts
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 |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import { Component } from '@angular/core'; | ||
|
||
@Component({ | ||
moduleId: module.id, | ||
selector: 'sg-app', | ||
templateUrl: 'app.component.html', | ||
styleUrls: ['app.component.css'] | ||
}) | ||
export class AppComponent { | ||
|
||
saveData() { | ||
alert('Button pressed.'); | ||
} | ||
|
||
} |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
export * from './app.component'; |
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
Oops, something went wrong.