1
0
Fork 0

Better icon names

This commit is contained in:
Chocobozzz 2022-06-13 11:26:20 +02:00
parent 93c728a25a
commit dc1296a9ab
No known key found for this signature in database
GPG key ID: 583A612D890159BE
7 changed files with 9 additions and 17 deletions

View file

@ -132,7 +132,7 @@ export class MenuService {
path: '/videos/trending'
},
{
icon: 'recently-added' as 'recently-added',
icon: 'add' as 'add',
label: $localize`Recently added videos`,
shortLabel: $localize`Recently added`,
path: '/videos/recently-added'

View file

@ -50,8 +50,8 @@
fragment="video-sensitive-content-policy" #settingsSensitiveContentPolicy
(click)="onActiveLinkScrollToAnchor(settingsSensitiveContentPolicy)"
>
<my-global-icon class="hover-display-toggle" [hidden]="user.nsfwPolicy === 'display'" iconName="sensitive" aria-hidden="true"></my-global-icon>
<my-global-icon class="hover-display-toggle" [hidden]="user.nsfwPolicy !== 'display'" iconName="unsensitive" aria-hidden="true"></my-global-icon>
<my-global-icon class="hover-display-toggle" [hidden]="user.nsfwPolicy === 'display'" iconName="eye-open" aria-hidden="true"></my-global-icon>
<my-global-icon class="hover-display-toggle" [hidden]="user.nsfwPolicy !== 'display'" iconName="eye-close" aria-hidden="true"></my-global-icon>
<span i18n>Sensitive:</span>
<span class="ms-auto muted">{{ nsfwPolicy }}</span>
</a>

View file

@ -6,8 +6,8 @@
/>
<button *ngIf="withToggle" (click)="toggle()" type="button" class="btn btn-outline-secondary" [title]="toggleTitle">
<my-global-icon *ngIf="show" iconName="sensitive"></my-global-icon>
<my-global-icon *ngIf="!show" iconName="unsensitive"></my-global-icon>
<my-global-icon *ngIf="show" iconName="eye-open"></my-global-icon>
<my-global-icon *ngIf="!show" iconName="eye-close"></my-global-icon>
</button>
<button

View file

@ -1,7 +1,7 @@
import { Component, forwardRef, Input } from '@angular/core'
import { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms'
import { Notifier } from '@app/core'
import { GlobalIconName } from '../shared-icons'
@Component({
selector: 'my-input-text',
@ -48,12 +48,6 @@ export class InputTextComponent implements ControlValueAccessor {
this.notifier.success($localize`Copied`)
}
getEyeIcon (): GlobalIconName {
if (this.show) return 'sensitive'
return 'unsensitive'
}
propagateChange = (_: any) => { /* empty */ }
writeValue (value: string) {

View file

@ -29,7 +29,6 @@ const icons = {
alert: require('!!raw-loader?!../../../assets/images/feather/alert.svg').default,
globe: require('!!raw-loader?!../../../assets/images/feather/globe.svg').default,
home: require('!!raw-loader?!../../../assets/images/feather/home.svg').default,
'recently-added': require('!!raw-loader?!../../../assets/images/feather/recently-added.svg').default,
trending: require('!!raw-loader?!../../../assets/images/feather/trending.svg').default,
search: require('!!raw-loader?!../../../assets/images/feather/search.svg').default,
upload: require('!!raw-loader?!../../../assets/images/feather/upload.svg').default,
@ -64,8 +63,8 @@ const icons = {
film: require('!!raw-loader?!../../../assets/images/feather/film.svg').default,
edit: require('!!raw-loader?!../../../assets/images/feather/edit-2.svg').default,
'external-link': require('!!raw-loader?!../../../assets/images/feather/external-link.svg').default,
sensitive: require('!!raw-loader?!../../../assets/images/feather/eye.svg').default,
unsensitive: require('!!raw-loader?!../../../assets/images/feather/eye-off.svg').default,
'eye-open': require('!!raw-loader?!../../../assets/images/feather/eye.svg').default,
'eye-close': require('!!raw-loader?!../../../assets/images/feather/eye-off.svg').default,
refresh: require('!!raw-loader?!../../../assets/images/feather/refresh-cw.svg').default,
command: require('!!raw-loader?!../../../assets/images/feather/command.svg').default,
go: require('!!raw-loader?!../../../assets/images/feather/arrow-up-right.svg').default,

View file

@ -30,7 +30,7 @@
<p class="stat-value">{{ serverStats.totalLocalVideoViews | number }}</p>
<p class="stat-label" i18n>views</p>
</div>
<my-global-icon iconName="sensitive"></my-global-icon>
<my-global-icon iconName="eye-open"></my-global-icon>
</div>
</div>

View file

@ -1 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-plus-circle"><circle cx="12" cy="12" r="10"></circle><line x1="12" y1="8" x2="12" y2="16"></line><line x1="8" y1="12" x2="16" y2="12"></line></svg>

Before

Width:  |  Height:  |  Size: 351 B