passman/templates/views/partials/icon-picker.html
2021-03-16 22:08:39 +01:00

45 lines
1.8 KiB
HTML

<div class="cell fa fa-lock" ng-if="!credential.url && !credential.icon"></div>
<div class="cell" ng-if="credential.url || credential.icon">
<span class="icon">
<credential-icon credential="credential"></credential-icon>
</span>
</div>
<div style="display: none" id="iconPicker" title="{{ 'pick.icon' | translate }}">
<div class="iconList">
<div ng-repeat="(groupName, icons) in iconGroups">
<div ng-click="expanded = !expanded" ng-init="expanded=true">
<div class="icon-triangle-s arrow" ng-class="{ 'icon-triangle-e': !expanded , 'icon-triangle-s': expanded }"></div>
<div class="collapsible" id="{{groupName}}">{{groupName}}</div>
</div>
<div ng-class="{ 'content_show': expanded , 'content': !expanded }">
<div class="icon" ng-repeat="icon in icons" ng-click="selectIcon(icon)">
<img ng-src="{{icon.url}}" height="32">
</div>
</div>
</div>
</div>
<div class="iconModifier">
<input id="iconPicker-Search" class="iconSearch" type="text" placeholder="{{ 'pick.icon.search' | translate }}">
<label for="iconPicker-CustomIcon">{{ 'pick.icon.custom.label' | translate }}</label>
<input id="iconPicker-CustomIcon" class="iconSearch" type="file"/>
<!--
<div ng-repeat="(groupName, icons) in iconGroups">
<a ng-click="jumpToGroup(groupName)">{{groupName}}</a>
</div>-->
<div ng-if="selectedIcon || customIcon">
{{ 'selected.icon' | translate}}: <br />
<img ng-src="{{selectedIcon.url}}" height="32" ng-if="!customIcon">
<img src="{{customIcon.data}}" height="32" ng-if="customIcon">
<br />
<button ng-click="useIcon()">{{ 'use.icon' | translate}}</button>
</div>
<div >
<button ng-click="deleteIcon()" ng-if="credential.icon">{{ 'use.icon.delete' | translate}}</button>
<button ng-click="refreshUrlIcon()">{{ 'use.icon.refresh' | translate}}</button>
</div>
</div>
</div>