mirror of
https://github.com/24eme/signaturepdf.git
synced 2023-08-25 09:33:08 +02:00
Création d'un motif pas le même mode dessin, texte ou import en
fonction du type signature, parapahe et tampon
This commit is contained in:
parent
4f2d5e3cf7
commit
3691f24520
@ -104,6 +104,9 @@ loadingTask.promise.then(function(pdf) {
|
||||
document.querySelectorAll('.btn-add-svg-type').forEach(function(item) {
|
||||
item.addEventListener('click', function(event) {
|
||||
document.getElementById('input-svg-type').value = this.dataset.type;
|
||||
if(this.dataset.modalnav) {
|
||||
bootstrap.Tab.getOrCreateInstance(document.querySelector('#modalAddSvg #nav-tab '+this.dataset.modalnav)).show();
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
@ -210,7 +213,11 @@ loadingTask.promise.then(function(pdf) {
|
||||
})});
|
||||
|
||||
document.getElementById('modalAddSvg').addEventListener('shown.bs.modal', function (event) {
|
||||
document.querySelector('#modalAddSvg #nav-tab button:first-child').focus()
|
||||
document.querySelector('#modalAddSvg #nav-tab button:first-child').focus();
|
||||
var tab = document.querySelector('#modalAddSvg .tab-pane.active');
|
||||
if(tab.querySelector('input')) {
|
||||
tab.querySelector('input').focus();
|
||||
}
|
||||
})
|
||||
|
||||
document.getElementById('modalAddSvg').addEventListener('hidden.bs.modal', function (event) {
|
||||
|
@ -37,12 +37,12 @@
|
||||
<div id="svg_list_initials" class="list-item-add"></div>
|
||||
<div class="d-grid gap-2 mb-2 list-item-add">
|
||||
<input type="radio" class="btn-check" id="radio_svg_initials_add" name="svg_2_add" autocomplete="off" value="intials">
|
||||
<label data-bs-toggle="modal" data-bs-target="#modalAddSvg" data-type="initials" class="btn btn-outline-secondary text-black text-start btn-add-svg-type" for="radio_svg_initials_add"><i class="bi bi-type"></i> Paraphe <small class="text-muted float-end">Ajouter</small></label>
|
||||
<label data-bs-toggle="modal" data-bs-target="#modalAddSvg" data-type="initials" data-modalnav="#nav-type-tab" class="btn btn-outline-secondary text-black text-start btn-add-svg-type" for="radio_svg_initials_add"><i class="bi bi-type"></i> Paraphe <small class="text-muted float-end">Ajouter</small></label>
|
||||
</div>
|
||||
<div id="svg_list_rubber_stamber" class="list-item-add"></div>
|
||||
<div class="d-grid gap-2 mb-2 list-item-add">
|
||||
<input type="radio" class="btn-check" id="radio_svg_rubber_stamber_add" name="svg_2_add" autocomplete="off" value="rubber_stamber">
|
||||
<label data-bs-toggle="modal" data-bs-target="#modalAddSvg" data-type="rubber_stamber" class="btn btn-outline-secondary text-black text-start btn-add-svg-type" for="radio_svg_rubber_stamber_add"><i class="bi bi-card-text"></i> Tampon <small class="text-muted float-end">Ajouter</small></label>
|
||||
<label data-bs-toggle="modal" data-bs-target="#modalAddSvg" data-type="rubber_stamber" data-modalnav="#nav-import-tab" class="btn btn-outline-secondary text-black text-start btn-add-svg-type" for="radio_svg_rubber_stamber_add"><i class="bi bi-card-text"></i> Tampon <small class="text-muted float-end">Ajouter</small></label>
|
||||
</div>
|
||||
<div class="d-grid gap-2 mb-2 list-item-add">
|
||||
<input type="radio" class="btn-check" id="radio_svg_text" name="svg_2_add" autocomplete="off" value="text">
|
||||
|
Loading…
x
Reference in New Issue
Block a user