This repository has been archived by the owner on Dec 8, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 28
Adopt @skyux/theme #458
Merged
Merged
Adopt @skyux/theme #458
Changes from 2 commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
1b38831
Adopt @skyux/theme
Blackbaud-SteveBrush c8bcdf4
Added theme to dependency
Blackbaud-SteveBrush 3d2628d
Upgrade skyux
Blackbaud-SteveBrush e5fc239
Removed theme from dependencies
Blackbaud-SteveBrush 07f3794
Removed package lock
Blackbaud-SteveBrush File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 was deleted.
Oops, something went wrong.
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,33 +1,3 @@ | ||
import * as FontFaceObserver from 'fontfaceobserver'; | ||
|
||
import { Injectable } from '@angular/core'; | ||
|
||
@Injectable() | ||
export class SkyAppStyleLoader { | ||
public static readonly LOAD_TIMEOUT: number = 3000; | ||
public isLoaded: boolean = false; | ||
|
||
public loadStyles(): Promise<any> { | ||
const fontAwesome = new FontFaceObserver('FontAwesome'); | ||
const blackbaudSans = new FontFaceObserver('Blackbaud Sans'); | ||
|
||
return Promise | ||
.all([ | ||
// Specify a character for FontAwesome since some browsers will fail to detect | ||
// when the font is loaded unless a known character with a different width | ||
// than the default is not specified. | ||
fontAwesome.load('\uf0fc', SkyAppStyleLoader.LOAD_TIMEOUT), | ||
blackbaudSans.load(undefined, SkyAppStyleLoader.LOAD_TIMEOUT) | ||
]) | ||
.then(() => { | ||
this.isLoaded = true; | ||
}) | ||
.catch((error) => { | ||
// Errors loading the font should not stop the page from rendering. | ||
// Passing the error along in case the client wants to do something with it. | ||
return Promise.resolve({ | ||
error: error | ||
}); | ||
}); | ||
} | ||
} | ||
export { | ||
SkyAppStyleLoader | ||
} from '@skyux/theme/style-loader'; |
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,21 +1,3 @@ | ||
import { | ||
Injectable | ||
} from '@angular/core'; | ||
|
||
import { ReplaySubject } from 'rxjs/ReplaySubject'; | ||
|
||
/** | ||
* Provides information about the state of the application's viewport. | ||
*/ | ||
@Injectable() | ||
export class SkyAppViewportService { | ||
|
||
/** | ||
* Updated when the viewport becomes visible. While the page is rendered, the | ||
* viewport may remain hidden as fonts and styles are loaded asynchronously; | ||
* this is done to avoid a FOUC (Flash Of Unstyled Content) before the fonts | ||
* and styles are ready. | ||
*/ | ||
public visible = new ReplaySubject<boolean>(1); | ||
|
||
} | ||
export { | ||
SkyAppViewportService | ||
} from '@skyux/theme/viewport.service'; |
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,2 +1,2 @@ | ||
import '@blackbaud/skyux/dist/css/sky.css'; | ||
import '@skyux/theme/css/sky.css'; | ||
import '@blackbaud/skyux/dist/core'; |
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 |
---|---|---|
|
@@ -18,8 +18,7 @@ | |
"types": [ | ||
"core-js", | ||
"node", | ||
"jasmine", | ||
"fontfaceobserver" | ||
"jasmine" | ||
], | ||
"baseUrl": ".", | ||
"paths": { | ||
|
This file was deleted.
Oops, something went wrong.
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
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.
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.
This was added as a dependency to make the tests pass, but it should be removed once it's added as a dependency of SKY UX.
See: blackbaud/skyux2#1930