From d14fe3c9ee248d02f687137cc760b32b5583fc67 Mon Sep 17 00:00:00 2001
From: "cedric@yterium.com" <>
Date: Fri, 28 Jan 2011 18:02:40 +0000
Subject: [PATCH] la page d'edition d'un document passe en squelette (et est
 renommee document_edit pour coller a la convention future). Corrections pour
 s'adapter a la version dev.

---
 .gitattributes                                |  16 +--
 exec/documents_edit.php                       | 113 ------------------
 formulaires/editer_document.html              |   8 +-
 formulaires/editer_document.php               |   3 +
 formulaires/illustrer_document.html           |  10 +-
 formulaires/illustrer_document.php            |  10 +-
 images/article-12.png                         | Bin 619 -> 0 bytes
 images/tourner-180.gif                        | Bin 104 -> 0 bytes
 images/tourner-droite.gif                     | Bin 99 -> 0 bytes
 images/tourner-gauche.gif                     | Bin 97 -> 0 bytes
 lang/medias_fr.php                            |   1 +
 modeles/document_case.html                    |   8 +-
 modeles/document_desc.html                    |   8 +-
 prive/editer/document.html                    |   9 --
 prive/inc-galerie.html                        |   2 +-
 prive/squelettes/contenu/document_edit.html   |  15 +++
 .../inclure/document_infos.html}              |   3 +
 .../squelettes/navigation/document_edit.html  |   1 +
 prive/themes/spip/images/document-16.png      | Bin 0 -> 362 bytes
 prive/themes/spip/images/document-24.png      | Bin 0 -> 652 bytes
 prive/themes/spip/images/document-32.png      | Bin 0 -> 919 bytes
 prive/themes/spip/images/tourner-180-10.png   | Bin 0 -> 284 bytes
 .../themes/spip/images/tourner-droite-10.png  | Bin 0 -> 268 bytes
 .../themes/spip/images/tourner-gauche-10.png  | Bin 0 -> 272 bytes
 24 files changed, 56 insertions(+), 151 deletions(-)
 delete mode 100644 exec/documents_edit.php
 delete mode 100644 images/article-12.png
 delete mode 100644 images/tourner-180.gif
 delete mode 100644 images/tourner-droite.gif
 delete mode 100644 images/tourner-gauche.gif
 delete mode 100644 prive/editer/document.html
 create mode 100644 prive/squelettes/contenu/document_edit.html
 rename prive/{navigation/documents_edit.html => squelettes/inclure/document_infos.html} (82%)
 create mode 100644 prive/squelettes/navigation/document_edit.html
 create mode 100644 prive/themes/spip/images/document-16.png
 create mode 100644 prive/themes/spip/images/document-24.png
 create mode 100644 prive/themes/spip/images/document-32.png
 create mode 100644 prive/themes/spip/images/tourner-180-10.png
 create mode 100644 prive/themes/spip/images/tourner-droite-10.png
 create mode 100644 prive/themes/spip/images/tourner-gauche-10.png

diff --git a/.gitattributes b/.gitattributes
index 85f161ae..274a485b 100644
--- a/.gitattributes
+++ b/.gitattributes
@@ -10,7 +10,6 @@ action/tourner.php -text
 action/verifier_documents_brises.php -text
 base/medias.php -text
 base/typedoc.php -text
-exec/documents_edit.php -text
 exec/portfolio.php -text
 formulaires/changer_fichier_document.html -text
 formulaires/changer_fichier_document.php -text
@@ -26,7 +25,6 @@ formulaires/inc-portfolio_documents.html -text
 formulaires/inc-upload_document.html -text
 formulaires/joindre_document.html -text
 formulaires/joindre_document.php -text
-images/article-12.png -text
 images/audio-16.png -text
 images/audio-22.png -text
 images/audio-32.png -text
@@ -50,9 +48,6 @@ images/photo-32.png -text
 images/portfolio-128.png -text
 images/portfolio-24.png -text
 images/portfolio-64.png -text
-images/tourner-180.gif -text
-images/tourner-droite.gif -text
-images/tourner-gauche.gif -text
 images/unreadable-22.png -text
 images/video-16.png -text
 images/video-22.png -text
@@ -90,15 +85,22 @@ modeles/document_desc.html -text
 prive/bouton/inc-supprimer-orphelins.html -text
 prive/contenu/portfolio_document.html -text
 prive/editer/colonne_document.html -text
-prive/editer/document.html -text
 prive/editer/document_popup.html -text
 prive/galerie.html -text
 prive/inc-ajouter-documents.html -text
 prive/inc-galerie.html -text
 prive/infos/document.html -text
-prive/navigation/documents_edit.html -text
+prive/squelettes/contenu/document_edit.html -text
+prive/squelettes/inclure/document_infos.html -text
+prive/squelettes/navigation/document_edit.html -text
 prive/style_prive_plugin_medias.html -text
+prive/themes/spip/images/document-16.png -text
+prive/themes/spip/images/document-24.png -text
+prive/themes/spip/images/document-32.png -text
 prive/themes/spip/images/portfolio-16.png -text
+prive/themes/spip/images/tourner-180-10.png -text
+prive/themes/spip/images/tourner-droite-10.png -text
+prive/themes/spip/images/tourner-gauche-10.png -text
 squelettes/contenu/document.html -text
 squelettes/document.html -text
 squelettes/head/document.html -text
diff --git a/exec/documents_edit.php b/exec/documents_edit.php
deleted file mode 100644
index cbe1d0c7..00000000
--- a/exec/documents_edit.php
+++ /dev/null
@@ -1,113 +0,0 @@
-<?php
-
-/***************************************************************************\
- *  SPIP, Systeme de publication pour l'internet                           *
- *                                                                         *
- *  Copyright (c) 2001-2011                                                *
- *  Arnaud Martin, Antoine Pitrou, Philippe Riviere, Emmanuel Saint-James  *
- *                                                                         *
- *  Ce programme est un logiciel libre distribue sous licence GNU/GPL.     *
- *  Pour plus de details voir le fichier COPYING.txt ou l'aide en ligne.   *
-\***************************************************************************/
-
-if (!defined("_ECRIRE_INC_VERSION")) return;
-
-include_spip('inc/presentation');
-
-function exec_documents_edit_dist()
-{
-	exec_documents_edit_args(intval(_request('id_document')),_request('parent'),_request('new'));
-}
-
-/**
- * Edition d'un document
- * parent est de la forme id_objet|objet (ex : 123|article)
- *
- * @param int $id_document
- * @param string $parent
- * @param string $new
- */
-function exec_documents_edit_args($id_document, $parent, $new){
-
-	$row = false;
-	if (!( ($new!='oui' AND (!autoriser('voir','document',$id_document) OR !autoriser('modifier','document', $id_document)))
-	       OR ($new=='oui' AND !autoriser('creer','document')) )) {
-		if ($new != "oui")
-			$row = sql_fetsel("*", "spip_documents", "id_document=$id_document");
-		else $row = true;
-	}
-	if (!$row) {
-		include_spip('inc/minipres');
-		echo minipres();
-	}
-	else
-		documents_edit_ok($row, $id_document, $parent, $new);
-}
-
-function documents_edit_ok($row, $id_document, $parent, $new)
-{
-
-	if (defined('_AJAX') AND _AJAX){
-		$contexte = array(
-		'redirect'=>'',//generer_url_ecrire("portfolio"),
-		'new'=>$new == "oui"?$new:$id_document,
-		'parent'=>$parent,
-		'config_fonc'=>'documents_edit_config',
-		'fichier'=>$row['fichier']
-		);
-
-		include_spip('inc/actions');
-		ajax_retour(recuperer_fond("prive/editer/document_popup", $contexte));
-		return;
-	}
-
-	if ($new != 'oui') {
-		$id_document=$row['id_document'];
-		$titre=$row['titre']?$row['titre']:$row['fichier'];
-		$statut=$row['statut'];
-	}
-	else {
-		$titre = "";
-		$statut = "prop";
-	}
-
-	$commencer_page = charger_fonction('commencer_page', 'inc');
-	pipeline('exec_init',array('args'=>array('exec'=>'documents_edit','id_document'=>$id_document),'data'=>''));
-
-	echo $commencer_page(_T('medias:titre_page_documents_edit', array('titre' => $titre)), "naviguer", "documents");
-
-	echo debut_gauche('', true);
-	$boite = pipeline ('boite_infos', array('data' => '',
-		'args' => array(
-			'type'=>'document',
-			'id' => $id_document,
-			'row' => $row
-		)
-	));
-
-	echo debut_boite_info(true). $boite . fin_boite_info(true);
-	
-	echo recuperer_fond("prive/navigation/documents_edit",array('id_document'=>$id_document));
-	echo pipeline('affiche_gauche',array('args'=>array('exec'=>'documents_edit','id_document'=>$id_document),'data'=>''));
-	echo creer_colonne_droite('', true);
-	echo pipeline('affiche_droite',array('args'=>array('exec'=>'documents_edit','id_document'=>$id_document),'data'=>''));
-	echo debut_droite('', true);
-
-	$redirect = _request('redirect') ? _request('redirect') : generer_url_ecrire("portfolio");
-	$contexte = array(
-	'icone_retour'=>$new=='oui'?'':icone_inline(_T('icone_retour'),$redirect, find_in_path("images/document-24.png"), "rien.gif",$GLOBALS['spip_lang_left']),
-	'redirect'=>_request('redirect',''),//generer_url_ecrire("portfolio"),
-	'titre'=>$titre,
-	'new'=>$new == "oui"?$new:$id_document,
-	'parent'=>$parent,
-	'config_fonc'=>'documents_edit_config'
-	);
-
-	$milieu = recuperer_fond("prive/editer/document", $contexte);
-	echo pipeline('affiche_milieu',array('args'=>array('exec'=>'documents_edit','id_document'=>$id_document),'data'=>$milieu));
-
-	echo fin_gauche(), fin_page();
-
-}
-
-?>
diff --git a/formulaires/editer_document.html b/formulaires/editer_document.html
index 06ff2679..20eb48fe 100644
--- a/formulaires/editer_document.html
+++ b/formulaires/editer_document.html
@@ -40,9 +40,9 @@
 		  	<label><:medias:label_apercu:></label>
 		  	[(#ENV{apercu}|oui)
 				<div class="tourner">
-					<input class="image" type="image" name="tournerL90" src="#CHEMIN{images/tourner-gauche.gif}" alt="<:medias:tourner_90L:>" />
-					<input class="image" type="image" name="tournerR90" src="#CHEMIN{images/tourner-droite.gif}" alt="<:medias:tourner_90R:>" />
-					<input class="image" type="image" name="tourner180" src="#CHEMIN{images/tourner-180.gif}" alt="<:medias:tourner_180:>" />
+					<input class="image" type="image" name="tournerL90" src="#CHEMIN_IMAGE{tourner-gauche-10.png}" alt="<:medias:tourner_90L:>" />
+					<input class="image" type="image" name="tournerR90" src="#CHEMIN_IMAGE{tourner-droite-10.png}" alt="<:medias:tourner_90R:>" />
+					<input class="image" type="image" name="tourner180" src="#CHEMIN_IMAGE{tourner-180-10.png}" alt="<:medias:tourner_180:>" />
 				</div>
 				[<a href='#ENV{apercu}'>(#ENV{apercu}|image_reduire{300,200})</a>]
 				]
@@ -94,7 +94,7 @@
 	  </ul>
 	  [(#REM) ajouter les saisies supplementaires : extra et autre, a cet endroit ]
 	  <!--extra-->
-	  <p class="boutons"><input type='submit' class='submit' value='<:bouton_enregistrer:>' /></p>
+	  <p class="boutons"><span class='image_loading'>&nbsp;</span><input type='submit' class='submit' value='<:bouton_enregistrer:>' /></p>
 	</div></form>
 	#INCLURE{fond=formulaires/dateur/inc-dateur}
 	]
diff --git a/formulaires/editer_document.php b/formulaires/editer_document.php
index 8464e7c7..b4bfafcf 100644
--- a/formulaires/editer_document.php
+++ b/formulaires/editer_document.php
@@ -164,6 +164,9 @@ function formulaires_editer_document_traiter_dist($id_document='new', $id_parent
 	if (!isset($res['message_erreur']))
 		$res['message_ok'] = _L('Votre modification a &eacute;t&eacute; enregistr&eacute;e').$autoclose;
 
+	if ($res['message_ok'])
+		$res['message_ok'].='<script type="text/javascript">if (window.jQuery) ajaxReload("document_infos");</script>';
+
 	return $res;
 }
 
diff --git a/formulaires/illustrer_document.html b/formulaires/illustrer_document.html
index 3c71d52a..02836c4d 100644
--- a/formulaires/illustrer_document.html
+++ b/formulaires/illustrer_document.html
@@ -8,13 +8,13 @@
 			<li class="editer_fichier[ (#ENV**{erreurs}|table_valeur{fichier}|oui)erreur]">
 				<label for="fichier"><:medias:label_fichier_vignette:></label>[
 				<span class='erreur_message'>(#ENV**{erreurs}|table_valeur{fichier})</span>
-				]
-				[
-				(#ENV*{vignette}|image_reduire{#CONFIG{taille_preview}})
+				][
+				(#CONFIG{taille_preview}|intval|?{#ENV*{vignette}|image_reduire{#CONFIG{taille_preview}},#ENV*{vignette}|balise_img})
 				][(#ENV*{vignette}|non)<:medias:aucune_vignette:>]
 				<p class='actions'>
-				[(#ENV{id_vignette}|oui)  <input type='submit' class='submit' name='supprimer' value='<:medias:bouton_supprimer|attribut_html:>' />]
-				&#91;<a href='#' onclick='jQuery("#illustrer_document").toggle("fast");return false;'><:bouton_changer:></a>&#93;
+				[(#ENV{id_vignette}|oui|et{#AUTORISER{supprimer,document,#ENV{id_vignette}}})  <input type='submit' class='submit' name='supprimer' value='<:medias:bouton_supprimer|attribut_html:>' />]
+				[(#ENV{id_vignette}|non|ou{#AUTORISER{modifier,document,#ENV{id_vignette}}}) &#91;<a href='#' onclick='jQuery("#illustrer_document").toggle("fast");return false;'><:bouton_changer:></a>&#93;]
+				<span class='image_loading'>&nbsp;</span>
 				</p>
 				<div id='illustrer_document' style='display:none;'>
 				[(#INCLURE{fond=formulaires/inc-upload_document}{env}{joindre_upload=oui})]
diff --git a/formulaires/illustrer_document.php b/formulaires/illustrer_document.php
index 05c6aef4..5dee1135 100644
--- a/formulaires/illustrer_document.php
+++ b/formulaires/illustrer_document.php
@@ -21,10 +21,11 @@ function formulaires_illustrer_document_charger_dist($id_document){
 	$valeurs['id'] = $id_document;
 	$valeurs['_hidden'] = "<input name='id_document' value='$id_document' type='hidden' />";
 	$valeurs['mode'] = 'vignette'; // pour les id dans le dom
-	$vignette = sql_fetsel('fichier,largeur,hauteur','spip_documents','id_document='.$valeurs['id_vignette']);
+	$vignette = sql_fetsel('fichier,largeur,hauteur,id_document','spip_documents','id_document='.$valeurs['id_vignette']);
 	$valeurs['vignette'] = get_spip_doc($vignette['fichier']);
 	$valeurs['hauteur'] = $vignette['hauteur'];
 	$valeurs['largeur'] = $vignette['largeur'];
+	$valeurs['id_vignette'] = $vignette['id_document'];
 	$valeurs['_pipeline'] = array('editer_contenu_objet',array('type'=>'illustrer_document','id'=>$id_document));
 
 	return $valeurs;
@@ -49,9 +50,10 @@ function formulaires_illustrer_document_traiter_dist($id_document){
 	$res = array('editable'=>true);
 	if (_request('supprimer')){
 		$supprimer_document = charger_fonction('supprimer_document','action');
-		if ($id_vignette)
-			$supprimer_document($id_vignette);
-		$res['message_ok'] = _T('medias:vignette_supprimee');
+		if ($id_vignette AND $supprimer_document($id_vignette))
+			$res['message_ok'] = _T('medias:vignette_supprimee');
+	  else
+		  $res['message_erreur'] = _T('medias:erreur_suppression_vignette');
 	}
 	else {
 		$ajouter_documents = charger_fonction('ajouter_documents', 'action');
diff --git a/images/article-12.png b/images/article-12.png
deleted file mode 100644
index 35d3d3d5951a8d06859ed9030fe34aa1a4924d36..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 619
zcmeAS@N?(olHy`uVBq!ia0vp^JRr=$3?vg*uel1OSkfJR9T^zbpD<_bdI{u9mbgZg
z1m~xflqVLYGB~E>C#5QQ<|d}62BjvZR2H60wP9djWDW2Mam~occ>DHkZEbB)QBh@O
zWmQ#G>k@|cr3?=q+$||7TD*9%o}SLPZ(l<~Lhs(a8xiGq`}XZUd-iNN#du)<{`Ay>
z%zB2SFBy&<JNDzp4@YN{*x1;X*8114Ure1kwY|MV$&eu_HR{u+PpejLN={DB&dx5Y
z^_#JYD?Z6zU0p3M(SPB*jlI1+K;ReP^85GihK2?gcdhR3?!$+U78e)iWR)-4&G-4^
z-=?Of^o)!-b7zK!ht8d`yQ$ap(%CmVcI=4Hve>t8-?wkyZe4rr?CgB{^y!29&o<U~
zZ``=Ct7CF-m|tFQ?y08?(`NQPfA;dujrSYRGu*#_f6A08zkdB{YilbjEBg-yS7Z)H
z0z)mlB*-rqB0_DFVPCT8W1tnCo-U3d6}NQGxr!Zf5MjOOUQj;$!Mk_wX0iQxU$42u
za_8n*q9t#%mmD)yYH|OwzV55ApXKyL8glKtsZKnT9Pekp-Q%sUm@jE3%x{-!<GCU4
z{pzC&rDlBKUsx}5hwJkqTWuw&nx8(;CfEoI<}cS@+O_+l=tlcu-}VjDl=4H1CmRZF
fkriD$pMja7B3L2II9KmI&`}JYu6{1-oD!M<t9ML)

diff --git a/images/tourner-180.gif b/images/tourner-180.gif
deleted file mode 100644
index 392a87496a1794edb282a28e30c2c4783eacb4e8..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 104
zcmZ?wbhEHb<YM4rSj5h-Wy_WqFJ2TB6il2r@zkkP*4EZ{?%a9(`nBRu7DfgJb_N{=
zAONXlVAicrK9l@>iYGV6CLV@oX9E->Zn&_tg-0EUFqp)!<O&1ZU2ek(hINezEd~cv
H7#OSp984w9

diff --git a/images/tourner-droite.gif b/images/tourner-droite.gif
deleted file mode 100644
index abcc6c238a702cd8e82d60c7dad473a6be3e4613..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 99
zcmZ?wbhEHb<YM4rSj5io;>C;Q%a^;myWhBR!@|O%prGK;p+m1<zgGOo!pOkD&Y;5p
z1R%8x%o-eA!EDcYoSOw6#wvAuZ!8y`&uru(=<t9s;Nn46L6Pkrd!K%E{oKyNU=0A^
CA0vMN

diff --git a/images/tourner-gauche.gif b/images/tourner-gauche.gif
deleted file mode 100644
index 24295e3c3ad2e3bfaddeb080d3747736702f1fa6..0000000000000000000000000000000000000000
GIT binary patch
literal 0
HcmV?d00001

literal 97
zcmZ?wbhEHb<YM4rSj5io{Q2{fCr|F!v19u5>A}IlrlzKijg7BgzgGOo!pOkD&Y;5p
z1R%8x%xV?vMjsMd13NgTPd)qHR7O$ku#$kAK*LfMn>CAE9CXfqi=Axlr^a9n0KB>)
A761SM

diff --git a/lang/medias_fr.php b/lang/medias_fr.php
index 1ae4fca1..e16c44e6 100644
--- a/lang/medias_fr.php
+++ b/lang/medias_fr.php
@@ -71,6 +71,7 @@ $GLOBALS[$GLOBALS['idx_lang']] = array(
 	'erreur_copie_fichier' => 'Impossible de copier le fichier @nom@',
 	'erreur_format_fichier_image' => 'Le format de @nom@ ne convient pas pour une image',
 	'erreur_upload_vignette' => 'Erreur lors du chargement de la vignette @nom@',
+	'erreur_suppression_vignette' => 'Erreur lors de la suppression de la vignette',
 	
 	// F
 	'format_date_incorrect' => 'La date ou l\'heure sont incorrectes',
diff --git a/modeles/document_case.html b/modeles/document_case.html
index ad121c5b..0929d8ca 100644
--- a/modeles/document_case.html
+++ b/modeles/document_case.html
@@ -16,9 +16,9 @@
 		<div class="infos">
 			[(#EXTENSION|match{gif|png|jpg}|oui) #SET{id,#ID_VIGNETTE|?{#ID_VIGNETTE,#ID_DOCUMENT}}
 			<div class="tourner">
-				[(#BOUTON_ACTION{[(#CHEMIN{images/tourner-gauche.gif}|balise_img{<:medias:tourner_90L:>})],#URL_ACTION_AUTEUR{tourner,#GET{id}|concat{',-90'},#SELF},ajax})]
-				[(#BOUTON_ACTION{[(#CHEMIN{images/tourner-droite.gif}|balise_img{<:medias:tourner_90R:>})],#URL_ACTION_AUTEUR{tourner,#GET{id}|concat{',90'},#SELF},ajax})]
-				[(#BOUTON_ACTION{[(#CHEMIN{images/tourner-180.gif}|balise_img{<:medias:tourner_180:>})],#URL_ACTION_AUTEUR{tourner,#GET{id}|concat{',180'},#SELF},ajax})]
+				[(#BOUTON_ACTION{[(#CHEMIN_IMAGE{tourner-gauche-10.png}|balise_img{<:medias:tourner_90L:>})],#URL_ACTION_AUTEUR{tourner,#GET{id}|concat{',-90'},#SELF},ajax})]
+				[(#BOUTON_ACTION{[(#CHEMIN_IMAGE{tourner-droite-10.png}|balise_img{<:medias:tourner_90R:>})],#URL_ACTION_AUTEUR{tourner,#GET{id}|concat{',90'},#SELF},ajax})]
+				[(#BOUTON_ACTION{[(#CHEMIN_IMAGE{tourner-180-10.png}|balise_img{<:medias:tourner_180:>})],#URL_ACTION_AUTEUR{tourner,#GET{id}|concat{',180'},#SELF},ajax})]
 			</div>]
 			[(#LOGO_DOCUMENT{#URL_DOCUMENT})]
 			<BOUCLE_type_doc(TYPES_DOCUMENTS){extension}>
@@ -40,7 +40,7 @@
 				<BOUCLE_compte(documents_liens){id_document}{0,2} />
 				[(#TOTAL_BOUCLE|=={1}|et{#AUTORISER{modifier,#OBJET,#ID_OBJET}})[(#BOUTON_ACTION{<:medias:bouton_enlever_supprimer_document:>,#URL_ACTION_AUTEUR{dissocier_document,#ID_OBJET-#OBJET-#ID_DOCUMENT-suppr,#SELF},ajax,<:medias:bouton_enlever_supprimer_document_confirmation:>})]<span>|</span>]
 				[(#AUTORISER{modifier,#OBJET,#ID_OBJET})[(#BOUTON_ACTION{<:medias:bouton_enlever_document:>,#URL_ACTION_AUTEUR{dissocier_document,#ID_OBJET-#OBJET-#ID_DOCUMENT,#SELF},ajax})]<span>|</span>]
-				<a href="#URL_ECRIRE{documents_edit,id_document=#ID_DOCUMENT}" target="_blank" class="editbox"><:medias:bouton_modifier_document:></a>
+				<a href="#URL_ECRIRE{document_edit,id_document=#ID_DOCUMENT}" target="_blank" class="editbox"><:medias:bouton_modifier_document:></a>
 				<//B_compte>
 				[(#PIPELINE{document_desc_actions,#ARRAY{args,#ARRAY{id_document,#ID_DOCUMENT,position,document_case},data,''}})]
 			</div>
diff --git a/modeles/document_desc.html b/modeles/document_desc.html
index d6138c2e..d2ccad73 100644
--- a/modeles/document_desc.html
+++ b/modeles/document_desc.html
@@ -10,9 +10,9 @@
 	<div class="item #MODE vu_#VU statut_#STATUT[(#DISTANT|=={oui}|oui)distant]" id="doc#ID_DOCUMENT">
 		[(#EXTENSION|match{gif|png|jpg}|oui) #SET{id,#ID_VIGNETTE|?{#ID_VIGNETTE,#ID_DOCUMENT}}
 		<div class="tourner">
-			[(#BOUTON_ACTION{[(#CHEMIN{images/tourner-gauche.gif}|balise_img{<:medias:tourner_90L:>})],#URL_ACTION_AUTEUR{tourner,#GET{id}|concat{',-90'},#SELF},ajax})]
-			[(#BOUTON_ACTION{[(#CHEMIN{images/tourner-droite.gif}|balise_img{<:medias:tourner_90R:>})],#URL_ACTION_AUTEUR{tourner,#GET{id}|concat{',90'},#SELF},ajax})]
-			[(#BOUTON_ACTION{[(#CHEMIN{images/tourner-180.gif}|balise_img{<:medias:tourner_180:>})],#URL_ACTION_AUTEUR{tourner,#GET{id}|concat{',180'},#SELF},ajax})]
+			[(#BOUTON_ACTION{[(#CHEMIN_IMAGE{tourner-gauche-10.png}|balise_img{<:medias:tourner_90L:>})],#URL_ACTION_AUTEUR{tourner,#GET{id}|concat{',-90'},#SELF},ajax})]
+			[(#BOUTON_ACTION{[(#CHEMIN_IMAGE{tourner-droite-10.png}|balise_img{<:medias:tourner_90R:>})],#URL_ACTION_AUTEUR{tourner,#GET{id}|concat{',90'},#SELF},ajax})]
+			[(#BOUTON_ACTION{[(#CHEMIN_IMAGE{tourner-180-10.png}|balise_img{<:medias:tourner_180:>})],#URL_ACTION_AUTEUR{tourner,#GET{id}|concat{',180'},#SELF},ajax})]
 		</div>]
 		[(#LOGO_DOCUMENT{#URL_DOCUMENT,60,60})]
 		<h4 class="titrem">
@@ -36,7 +36,7 @@
 			<BOUCLE_compte(documents_liens){id_document}{0,2} />
 			[(#TOTAL_BOUCLE|=={1}|et{#AUTORISER{modifier,#OBJET,#ID_OBJET}})[(#BOUTON_ACTION{<:medias:bouton_enlever_supprimer_document:>,#URL_ACTION_AUTEUR{dissocier_document,#ID_OBJET-#OBJET-#ID_DOCUMENT-suppr-safe,#SELF},ajax,<:medias:bouton_enlever_supprimer_document_confirmation:>})]<span>|</span>]
 			[(#AUTORISER{modifier,#OBJET,#ID_OBJET})[(#BOUTON_ACTION{<:medias:bouton_enlever_document:>,#URL_ACTION_AUTEUR{dissocier_document,#ID_OBJET-#OBJET-#ID_DOCUMENT--safe,#SELF},ajax})]<span>|</span>]
-			<a href="#URL_ECRIRE{documents_edit,id_document=#ID_DOCUMENT}" target="_blank" class="editbox"><:medias:bouton_modifier_document:></a>
+			<a href="#URL_ECRIRE{document_edit,id_document=#ID_DOCUMENT}" target="_blank" class="editbox"><:medias:bouton_modifier_document:></a>
 			<//B_compte>
 			[(#PIPELINE{document_desc_actions,#ARRAY{args,#ARRAY{id_document,#ID_DOCUMENT,position,document_desc},data,''}})]
 		</div>
diff --git a/prive/editer/document.html b/prive/editer/document.html
deleted file mode 100644
index b853f631..00000000
--- a/prive/editer/document.html
+++ /dev/null
@@ -1,9 +0,0 @@
-<div class='cadre-formulaire-editer'>
-<div class="entete-formulaire">
-	#ENV**{icone_retour}
-	[<:medias:info_modifier_document:>
-	<h1>(#ENV{titre})</h1>]
-</div>
-#FORMULAIRE_EDITER_DOCUMENT{#ENV{new},#ENV{parent},#ENV{redirect},#ENV{lier_trad},#ENV{config_fonc}}
-#FORMULAIRE_ILLUSTRER_DOCUMENT{#ENV{new}}
-</div>
diff --git a/prive/inc-galerie.html b/prive/inc-galerie.html
index d693079e..317fac52 100644
--- a/prive/inc-galerie.html
+++ b/prive/inc-galerie.html
@@ -136,7 +136,7 @@
 		<td>
 		[(#REM) Utilisation de la galerie en mode portfolio, avec renvoi vers l'edition]
 		[(#GET{editable})
-		[(#AUTORISER{modifier,document,#ID_DOCUMENT})&#91;<a href='#URL_ECRIRE{documents_edit,id_document=#ID_DOCUMENT}'><:bouton_modifier:></a>&#93;]
+		[(#AUTORISER{modifier,document,#ID_DOCUMENT})&#91;<a href='#URL_ECRIRE{document_edit,id_document=#ID_DOCUMENT}'><:bouton_modifier:></a>&#93;]
 		[<span class='supprimer'>(#GET{supprimer}|et{#AUTORISER{supprimer,document,#ID_DOCUMENT}})[(#BOUTON_ACTION{<:medias:bouton_supprimer:>,#URL_ACTION_AUTEUR{supprimer_document,#ID_DOCUMENT,#SELF},ajax})]</span>]
 		]
 		[(#PIPELINE{document_desc_actions,#ARRAY{args,#ARRAY{id_document,#ID_DOCUMENT,position,galerie},data,''}})]
diff --git a/prive/squelettes/contenu/document_edit.html b/prive/squelettes/contenu/document_edit.html
new file mode 100644
index 00000000..249fb14c
--- /dev/null
+++ b/prive/squelettes/contenu/document_edit.html
@@ -0,0 +1,15 @@
+[(#ID_DOCUMENT|interdire_acces)]
+[(#AUTORISER{modifier,document,#ID_DOCUMENT}|interdire_acces)]
+<div class='cadre-formulaire-editer'>
+<div class="entete-formulaire">
+	[(#ENV{redirect}|sinon{#URL_ECRIRE{portfolio}}|icone_verticale{<:icone_retour:>,document,'',left})]
+	[<:medias:info_modifier_document:>
+	<h1>(#INFO_TITRE{document,#ID_DOCUMENT}|sinon{#INFO_FICHIER*{document,#ID_DOCUMENT}})</h1>]
+</div>
+<div class="ajax">
+#FORMULAIRE_EDITER_DOCUMENT{#ID_DOCUMENT,#ENV{parent,''},#ENV{redirect,''},#ENV{lier_trad}}
+</div>
+<div class="ajax">
+#FORMULAIRE_ILLUSTRER_DOCUMENT{#ID_DOCUMENT}
+</div>
+</div>
diff --git a/prive/navigation/documents_edit.html b/prive/squelettes/inclure/document_infos.html
similarity index 82%
rename from prive/navigation/documents_edit.html
rename to prive/squelettes/inclure/document_infos.html
index 21620b07..3b3a0b9d 100644
--- a/prive/navigation/documents_edit.html
+++ b/prive/squelettes/inclure/document_infos.html
@@ -1,3 +1,6 @@
+#BOITE_OUVRIR{'','info'}
+#PIPELINE{boite_infos,#ARRAY{data,'',args,#ARRAY{'type','document','id',#ENV{id_document}}}}
+#BOITE_FERMER
 <div class='document_utilisations'>
 <B_liens>
 		<h3>[(#TOTAL_BOUCLE|singulier_ou_pluriel{medias:une_utilisation,medias:des_utilisations})]</h3>
diff --git a/prive/squelettes/navigation/document_edit.html b/prive/squelettes/navigation/document_edit.html
new file mode 100644
index 00000000..e4b9dc0a
--- /dev/null
+++ b/prive/squelettes/navigation/document_edit.html
@@ -0,0 +1 @@
+<INCLURE{fond=prive/squelettes/inclure/document_infos,env,ajax=document_infos}>
\ No newline at end of file
diff --git a/prive/themes/spip/images/document-16.png b/prive/themes/spip/images/document-16.png
new file mode 100644
index 0000000000000000000000000000000000000000..f93078194dace800212c0a05f999f335d39d4fc0
GIT binary patch
literal 362
zcmV-w0hRuVP)<h;3K|Lk000e1NJLTq000mG000mO1^@s6AM^iV0000PbVXQnQ*UN;
zcVTj606}DLVr3vnZDD6+Qe|Oed2z{QJOBUz3`s;mRCwBAoH=vmninr#1T&BZ!t3hl
zR)JZKjg9|F1yDT<Aj|?Y^6lHV4FCT91G5<!8R1sJ*dUsjnVEr~pC833a05V^Z{50u
zq5&Cz_?nuU7=B?v=BTTy<8=Wxz=Et0*#+o;C>N-ysbR742QaYM8JL)u@Vfv6+P6Hx
z8+Ubqiuk<%0%pp88C><b7%o44$8hV32wdTf=idpt00bUhd&n^7IwRP?Kc6mu#h5wx
z7#O&9i8J8Iqo)iI$1pPd|M!RC&+qTRF!;d0rK5{AfHAzls%nd(fE6t!@VcPdPY$dI
zJtmOFa2g;aB*Z`tU=a}!+1k|9<V}hupq`a*Z-H_YB>*760Az)IbQ4=Q1^@s607*qo
IM6N<$f<!!+tN;K2

literal 0
HcmV?d00001

diff --git a/prive/themes/spip/images/document-24.png b/prive/themes/spip/images/document-24.png
new file mode 100644
index 0000000000000000000000000000000000000000..3d511c6b9ae8e6e4c461af4851d2776515bab6ba
GIT binary patch
literal 652
zcmV;70(1R|P)<h;3K|Lk000e1NJLTq000;O000;W1^@s6;CDUv0000PbVXQnQ*UN;
zcVTj606}DLVr3vnZDD6+Qe|Oed2z{QJOBU!E=fc|RCwC7R!dJ4Q562}odQCYgaq0&
zT@rR0S1K(nB`PHR4*ml%0bQsV(1kyRKftB|!Yix@0bE!EHM9%?f`J;_nd^Pc?F<y{
z(DZap=f37VzjI~?V+`#iiZ)ZkKUw(l={>)_ZABoD$cH!6Gw=KhhUY)eu~tdTFft>J
ztSA%;uq;a+Ap8eH#3hNCv00EKaW<Ju{yRh-DIrS0+WP8^O(>-|C^Itp{~R<@kWOVl
z_1wc7r9^w6ttV)pvPlJBmrk2X?(}3LoB~QI9M_fe=YtN$pY~wq=nUVA{kP8VA6JY)
zP1V8H_GVzSyR(X}NH6-LEMUa-@gCeiS87f}D0uN~7>Psz9(2kVeOTPIv2ie9!dI~i
zaI3%h{kzUR2^XSLsbrve{$m&CzPx}rsQoI*q4l5_h(d-me3F?GSUmh$$G%34>(o%I
zRyh7I(DV4oojHiyg$fBv9oLSb?5%xEtOv>?go5>rHH@S)@*x2~&m%&hEhPaci}0{8
zb&wiPBNmI{q+CXRC0{Qo;_DFgfuz?jC&J~xwry!uE}Ih=G}UZ8;Q*A-<QL`p2%7`X
zxcsvAfCQVH_c#7(Lhaov$((c9F+QfsYD%=_%4!jN;}!1Vfl@?Oa}(`DcTy>k);%G<
z+%%;i9*?)@mFc?fNB-KJZAIYGVR0%D0smKpuNsBohnyd27UQVyU82UsLsiZd(MdR8
ma=y}Yhxvq(c7L|~6<`2qTjSp)Ix;Z;0000<MNUMnLSTXnL?~+j

literal 0
HcmV?d00001

diff --git a/prive/themes/spip/images/document-32.png b/prive/themes/spip/images/document-32.png
new file mode 100644
index 0000000000000000000000000000000000000000..bc5e97e036e342f622a2b5fc16ad90054b0866d2
GIT binary patch
literal 919
zcmV;I18Dq-P)<h;3K|Lk000e1NJLTq001BW001Be1^@s6b9#F80000PbVXQnQ*UN;
zcVTj606}DLVr3vnZDD6+Qe|Oed2z{QJOBU#IY~r8RCwCNS5HqGK@@-c#}y^C&|1_q
zrfFIrG%-<YOgZ&C^b62~H@`!#J@(|$giqi{=&cvin2<D)gAEofJ=Ed`!NLN&eUC89
zFwU^M#KxCQ<}K{b`@P@q?Yvpd^E|ju)8U@YWR9k3!+C#y|D9=?C3F*pVSujd;JPjh
z1_OWe`+a}r{b|3UUE}<|R4N^^n8dy*B0?YsySuvy28td=Kp;xRUx)M)dwY8a=pITL
zV1|g3G*_$DAppuC9*=|LI6hO1EuJ~mH3O1Pr)iC(QUd;F7KAM(`m$LSJai2(Bfa^c
ze4x|QQ~&=kL8*qa*{oEOsQ?%YB9Kfb^Zywj&G`j+7J?X{jB~l1GFWH^R1y%KvoOGZ
z4+VfRAS=Rhxg07GZ(Cbi(HP(*I6gjx&CSg*8@d5?{VBZ3{)SXy5x!JBuv;l5<!fGb
z0+bAZE(5@daA#-7e~2v<pZ^Qb(pgBwUqNQ&=GKC}b^|=Of2)on0bmbOJ%}2&ofurU
ze!z`$1{Z%~LIL%m+o-|y+1H60Vrz&694LV-3)i*ab2$ly-Up}m2xS=qyuSDbnqfls
z>L+-E-Y~r&3Cw8{$acb|MIC(uJqxthc=2w_hK79(snr+YB~q~bZ~+lb0tm&xsB<ab
z<NEiiwBntP4VtwC_T?3L`T|_wp7C-;iw;114MiR8rmbi|*tonHblNuPC_}SVMF7ty
z3UKBc;3$B0t2ur1F)ZjIi=I19glQidfVv|BynVeEsTD^qLcRu$j*eh^d)vPzUnY$V
ztSVq62?~V*bh}-D(MqK<Q6s9J;4h9RsrB{s=l~dU^7+j2`FtP)K|5dMcFfz!$%(RA
z$)1^s0agPtN*M!mQVzocF%ZPUR0%|545;*{j5jtmBAtws67a_|k%4I}h{y6E79wrM
zvg4HqGU}(E2q1x(HF1##$z;-JWNvN_X8nfb0a})Y?Fm+JTv7iL0npdblX|`Wu~;mA
zK!4#bzX1_Qr&g<dLU)xmY#hI6ch)#6Eu5BdJjOxk&yQ}r3+s%MZR2R*ILFZ%)|o_0
t3LG0Yd}?ubW7LIuBid<rtX}>JFaXoX*rl0;A)x>O002ovPDHLkV1ii;nc4sV

literal 0
HcmV?d00001

diff --git a/prive/themes/spip/images/tourner-180-10.png b/prive/themes/spip/images/tourner-180-10.png
new file mode 100644
index 0000000000000000000000000000000000000000..205fa26c2d55adc322308b259178601bce02cb24
GIT binary patch
literal 284
zcmV+%0ptFOP)<h;3K|Lk000e1NJLTq000UA000UI1^@s6jWW-@0000PbVXQnQ*UN;
zcVTj606}DLVr3vnZDD6+Qe|Oed2z{QJOBUyzDYzuRCwBKQ85mLAP`*Cl7z$`7#bfS
zKd__MxA+2nLctsCEqsK%CRVnFb4W07caxB1huK*c*l`?Wt@Ycs(Kni=A+0qDAy@^%
zIY<Ant}96?sp~plr3b?>gag1BlNDvc*yg@(uapXo5k)FI&yyg!t}7G$IPUu%;xpXK
z&GQ`A>xfoBUDuf#_L#m%iMDNtb57GVQEGs@7cq&BWmz&5#JunOP|Wb)7$7=8i1>Vf
iUzUZ&aSYr?fB^tsLQP9P+|+vj0000<MNUMnLSTaBrE+%w

literal 0
HcmV?d00001

diff --git a/prive/themes/spip/images/tourner-droite-10.png b/prive/themes/spip/images/tourner-droite-10.png
new file mode 100644
index 0000000000000000000000000000000000000000..a247053e48c18526c60bd2b2c811f59256236262
GIT binary patch
literal 268
zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4NtU=qlmzFem6RtIr7}3C<R_&n
zc;+Uirv{}arc@T5Otk?jTIcEF7*cVo$A2U55d|I-72B7Wl?@#;R=$|2Af3Xm<}tHS
zqLFoi(yA1uf4L{u+g$Rl=lxM*H~(nmJYKmS>$tzwwhJ(2tWA_)Yut0fa(mQk_Xw}X
z#}+U4uhTyB*@yX1wSV9D+UB6Hdvdq8H6CH>7PxjxU+~%sE2GBjImJ^9m%22iMs^&Y
z^SD^5Gjmo{&%~_co(FQAmAc*cA4<oco>1fQ{*Js#_3`)#|2qWq8QB=79JPov`;e~>
PbUA~ktDnm{r-UW|7{6#-

literal 0
HcmV?d00001

diff --git a/prive/themes/spip/images/tourner-gauche-10.png b/prive/themes/spip/images/tourner-gauche-10.png
new file mode 100644
index 0000000000000000000000000000000000000000..7a4dd63b51a91c580ae29e89f2af1777e97a0db9
GIT binary patch
literal 272
zcmeAS@N?(olHy`uVBq!ia0vp^AT}2V8<6ZZI=>f4NtU=qlmzFem6RtIr7}3C<R_&n
zc;+Uirv{}arc@T5Otk?j+T`it7*cVo$NwN_i-Eu#52+1|2Sp~><Q{aF3!5nP>GWwM
zrj>`aShNNH{PJLS(vucYDwpAFi8b52+4zl(zrecJUbnX;-Y@sL+#)rn_*iFw4EwcG
zR}RM5>kHpkZ^`YJNM2bv?ZzgZla}rEGoDNG=4PywmtRt4&vf&l6GvK)=V5~b)%=>O
z#|m{?YIsvt|JZX@Yw4t|+kWhtD%bcbC35eQ<@2(9bM~1TzYJf%rvGu)55WY6^J$Lz
UmR-0h33NS!r>mdKI;Vst0CzxXZ~y=R

literal 0
HcmV?d00001

-- 
GitLab