1
0
mirror of https://github.com/BookStackApp/BookStack.git synced 2025-07-30 04:23:11 +03:00

Updated entity-selector-popup to reset on selection

Better links the core selector component to the popup version, with new
public methods for direct controlling.

For #3528
This commit is contained in:
Dan Brown
2022-06-25 14:13:17 +01:00
parent 0801955a26
commit c9d0e22132
3 changed files with 19 additions and 3 deletions

View File

@ -1,10 +1,11 @@
<div class="form-group entity-selector-container">
<div component="entity-selector"
refs="entity-selector-popup@selector"
class="entity-selector {{$selectorSize ?? ''}}"
option:entity-selector:entity-types="{{ $entityTypes ?? 'book,chapter,page' }}"
option:entity-selector:entity-permission="{{ $entityPermission ?? 'view' }}">
<input refs="entity-selector@input" type="hidden" name="{{$name}}" value="">
<input refs="entity-selector@search entity-selector-popup@searchInput" type="text" placeholder="{{ trans('common.search') }}" @if($autofocus ?? false) autofocus @endif>
<input refs="entity-selector@search" type="text" placeholder="{{ trans('common.search') }}" @if($autofocus ?? false) autofocus @endif>
<div class="text-center loading" refs="entity-selector@loading">@include('common.loading-icon')</div>
<div refs="entity-selector@results"></div>
@if($showAdd ?? false)