Commit 4ede9a3a4db11df3243d37066c3fda35d7857861
Committed by
GitHub
1 parent
a7a8623f
Fix toolbar and share buttons (#2646)
Showing
4 changed files
with
13 additions
and
38 deletions
@@ -69,7 +69,7 @@ | @@ -69,7 +69,7 @@ | ||
69 | </mat-form-field> | 69 | </mat-form-field> |
70 | <div fxLayout="column" [fxShow]="!isEdit && (dashboardScope === 'tenant' && isPublic(entity) | 70 | <div fxLayout="column" [fxShow]="!isEdit && (dashboardScope === 'tenant' && isPublic(entity) |
71 | || dashboardScope === 'customer' && isCurrentPublicCustomer(entity))"> | 71 | || dashboardScope === 'customer' && isCurrentPublicCustomer(entity))"> |
72 | - <tb-social-share-panel style="padding-bottom: 10px;" | 72 | + <tb-social-share-panel style="padding-bottom: 1.25em;" |
73 | shareTitle="{{ 'dashboard.socialshare-title' | translate:{dashboardTitle: entity?.title} }}" | 73 | shareTitle="{{ 'dashboard.socialshare-title' | translate:{dashboardTitle: entity?.title} }}" |
74 | shareText="{{ 'dashboard.socialshare-text' | translate:{dashboardTitle: entity?.title} }}" | 74 | shareText="{{ 'dashboard.socialshare-text' | translate:{dashboardTitle: entity?.title} }}" |
75 | shareLink="{{ publicLink }}" | 75 | shareLink="{{ publicLink }}" |
@@ -24,29 +24,12 @@ $mobile-toolbar-height-total: 84px !default; | @@ -24,29 +24,12 @@ $mobile-toolbar-height-total: 84px !default; | ||
24 | tb-dashboard-toolbar { | 24 | tb-dashboard-toolbar { |
25 | mat-fab-toolbar { | 25 | mat-fab-toolbar { |
26 | mat-fab-trigger { | 26 | mat-fab-trigger { |
27 | - .mat-button { | ||
28 | - &.mat-fab { | ||
29 | - width: 36px; | ||
30 | - height: 36px; | ||
31 | - margin: 4px 0 0 4px; | ||
32 | - line-height: 36px; | ||
33 | - .mat-button-wrapper { | ||
34 | - width: 36px; | ||
35 | - height: 36px; | ||
36 | - padding: 0 6px; | ||
37 | - box-sizing: border-box; | ||
38 | - } | ||
39 | - mat-icon { | ||
40 | - display: block; | ||
41 | - position: absolute; | ||
42 | - top: 25%; | ||
43 | - width: 18px; | ||
44 | - min-width: 18px; | ||
45 | - height: 18px; | ||
46 | - min-height: 18px; | ||
47 | - margin: 0; | ||
48 | - line-height: 18px; | ||
49 | - } | 27 | + .mat-fab { |
28 | + width: 36px; | ||
29 | + height: 36px; | ||
30 | + margin: 4px 0 0 4px; | ||
31 | + .mat-button-wrapper { | ||
32 | + padding: 0; | ||
50 | } | 33 | } |
51 | } | 34 | } |
52 | } | 35 | } |
@@ -16,7 +16,7 @@ | @@ -16,7 +16,7 @@ | ||
16 | 16 | ||
17 | --> | 17 | --> |
18 | <div fxLayout="row" fxLayoutGap="12px" [fxHide]="isShareLinkLocal()"> | 18 | <div fxLayout="row" fxLayoutGap="12px" [fxHide]="isShareLinkLocal()"> |
19 | - <button mat-button mat-icon-button mat-raised-button class="mat-primary" | 19 | + <button mat-icon-button mat-raised-button class="mat-primary" |
20 | shareButton="facebook" | 20 | shareButton="facebook" |
21 | title="{{ shareTitle }}" | 21 | title="{{ shareTitle }}" |
22 | description="{{ shareText }}" | 22 | description="{{ shareText }}" |
@@ -25,7 +25,7 @@ | @@ -25,7 +25,7 @@ | ||
25 | matTooltip="{{ 'action.share-via' | translate:{provider:'Facebook'} }}"> | 25 | matTooltip="{{ 'action.share-via' | translate:{provider:'Facebook'} }}"> |
26 | <mat-icon svgIcon="mdi:facebook"></mat-icon> | 26 | <mat-icon svgIcon="mdi:facebook"></mat-icon> |
27 | </button> | 27 | </button> |
28 | - <button mat-button mat-icon-button mat-raised-button class="mat-primary" | 28 | + <button mat-icon-button mat-raised-button class="mat-primary" |
29 | shareButton="twitter" | 29 | shareButton="twitter" |
30 | title="{{ shareTitle }}" | 30 | title="{{ shareTitle }}" |
31 | tags="{{ shareHashTags }}" | 31 | tags="{{ shareHashTags }}" |
@@ -34,7 +34,7 @@ | @@ -34,7 +34,7 @@ | ||
34 | matTooltip="{{ 'action.share-via' | translate:{provider:'Twitter'} }}"> | 34 | matTooltip="{{ 'action.share-via' | translate:{provider:'Twitter'} }}"> |
35 | <mat-icon svgIcon="mdi:twitter"></mat-icon> | 35 | <mat-icon svgIcon="mdi:twitter"></mat-icon> |
36 | </button> | 36 | </button> |
37 | - <button mat-button mat-icon-button mat-raised-button class="mat-primary" | 37 | + <button mat-icon-button mat-raised-button class="mat-primary" |
38 | shareButton="linkedin" | 38 | shareButton="linkedin" |
39 | title="{{ shareTitle }}" | 39 | title="{{ shareTitle }}" |
40 | url="{{ shareLink }}" | 40 | url="{{ shareLink }}" |
@@ -42,7 +42,7 @@ | @@ -42,7 +42,7 @@ | ||
42 | matTooltip="{{ 'action.share-via' | translate:{provider:'Linkedin'} }}"> | 42 | matTooltip="{{ 'action.share-via' | translate:{provider:'Linkedin'} }}"> |
43 | <mat-icon svgIcon="mdi:linkedin"></mat-icon> | 43 | <mat-icon svgIcon="mdi:linkedin"></mat-icon> |
44 | </button> | 44 | </button> |
45 | - <button mat-button mat-icon-button mat-raised-button class="mat-primary" | 45 | + <button mat-icon-button mat-raised-button class="mat-primary" |
46 | shareButton="reddit" | 46 | shareButton="reddit" |
47 | title="{{ shareTitle }}" | 47 | title="{{ shareTitle }}" |
48 | url="{{ shareLink }}" | 48 | url="{{ shareLink }}" |
@@ -14,16 +14,8 @@ | @@ -14,16 +14,8 @@ | ||
14 | /// limitations under the License. | 14 | /// limitations under the License. |
15 | /// | 15 | /// |
16 | 16 | ||
17 | -import { Component, Input, OnDestroy, OnInit } from '@angular/core'; | ||
18 | -import { User } from '@shared/models/user.model'; | ||
19 | -import { Authority } from '@shared/models/authority.enum'; | ||
20 | -import { select, Store } from '@ngrx/store'; | ||
21 | -import { AppState } from '@core/core.state'; | ||
22 | -import { selectAuthUser, selectUserDetails } from '@core/auth/auth.selectors'; | ||
23 | -import { map } from 'rxjs/operators'; | ||
24 | -import { AuthService } from '@core/auth/auth.service'; | ||
25 | -import { Router } from '@angular/router'; | ||
26 | -import {isLocalUrl} from '@core/utils'; | 17 | +import { Component, Input, OnInit } from '@angular/core'; |
18 | +import { isLocalUrl } from '@core/utils'; | ||
27 | 19 | ||
28 | @Component({ | 20 | @Component({ |
29 | selector: 'tb-social-share-panel', | 21 | selector: 'tb-social-share-panel', |