ducky/web

Paddy 2015-06-30 Parent:99a43a6d1d30

11:3bdc03963abe Go to Latest

ducky/web/src/styles/base/_buttons.scss

Implement OAuth token refreshing helper. Create an ampersand-sync/XHR request wrapper that will detect when a request fails because an OAuth2 token has expired, and will try to refresh the token then retry the request.

History
1 #{$all-button-inputs},
2 button {
3 @include appearance(none);
4 -webkit-font-smoothing: antialiased;
5 background-color: $action-color;
6 border-radius: $base-border-radius;
7 border: none;
8 color: #fff;
9 cursor: pointer;
10 display: inline-block;
11 font-family: $base-font-family;
12 font-size: $base-font-size;
13 font-weight: 600;
14 line-height: 1;
15 padding: 0.75em 1em;
16 text-decoration: none;
17 user-select: none;
18 vertical-align: middle;
19 white-space: nowrap;
21 &:hover,
22 &:focus {
23 background-color: darken($action-color, 15%);
24 color: #fff;
25 }
27 &:disabled {
28 cursor: not-allowed;
29 opacity: 0.5;
30 }
31 }