Merge pull request #33063 from jaulz/patch-1

[tinycon] update types
This commit is contained in:
Mine Starks
2019-02-15 08:25:03 -08:00
committed by GitHub
2 changed files with 15 additions and 2 deletions

View File

@@ -1,9 +1,10 @@
// Type definitions for tinycon 0.6
// Project: https://github.com/tommoor/tinycon
// Definitions by: Daniel Waxweiler <https://github.com/dwaxweiler>
// Julian Hundeloh <https://github.com/jaulz>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
export function setBubble(count: number): void;
export function setBubble(count: number | string | null): void;
export function setOptions(options: TinyconOptions): void;
@@ -11,7 +12,7 @@ export interface TinyconOptions {
abbreviate?: boolean;
background?: string;
color?: string;
fallback?: boolean;
fallback?: boolean | 'force';
font?: string;
height?: number;
width?: number;

View File

@@ -10,4 +10,16 @@ Tinycon.setOptions({
width: 7
});
Tinycon.setOptions({
abbreviate: false,
background: '#549A2F',
color: '#ffffff',
fallback: 'force',
font: '10px arial',
height: 9,
width: 7
});
Tinycon.setBubble(7);
Tinycon.setBubble(null);