2020-06-27 20:29:00 +08:00
|
|
|
{{--
|
|
|
|
@type - Type of term (exact, tag)
|
|
|
|
@currentList
|
|
|
|
--}}
|
2022-11-03 20:49:05 +08:00
|
|
|
<div component="add-remove-rows"
|
2020-06-27 20:29:00 +08:00
|
|
|
option:add-remove-rows:remove-selector="button.text-neg"
|
2022-11-03 20:49:05 +08:00
|
|
|
option:add-remove-rows:row-selector=".flex-container-row"
|
|
|
|
class="flex-container-column gap-xs">
|
2020-06-27 20:29:00 +08:00
|
|
|
@foreach(array_merge($currentList, ['']) as $term)
|
2022-11-03 20:49:05 +08:00
|
|
|
<div @if(empty($term)) refs="add-remove-rows@model" @endif
|
|
|
|
class="{{ $term ? '' : 'hidden' }} flex-container-row items-center gap-x-xs">
|
|
|
|
<div>
|
2020-06-27 20:29:00 +08:00
|
|
|
<input class="exact-input outline" type="text" name="{{$type}}[]" value="{{ $term }}">
|
2022-11-03 20:49:05 +08:00
|
|
|
</div>
|
|
|
|
<div>
|
|
|
|
<button type="button" class="text-neg text-button icon-button p-xs">@icon('close')</button>
|
|
|
|
</div>
|
|
|
|
</div>
|
2020-06-27 20:29:00 +08:00
|
|
|
@endforeach
|
2022-11-03 20:49:05 +08:00
|
|
|
<div class="flex py-xs">
|
|
|
|
<button refs="add-remove-rows@add" type="button" class="text-button">
|
|
|
|
@icon('add-circle'){{ trans('common.add') }}
|
|
|
|
</button>
|
|
|
|
</div>
|
|
|
|
</div>
|