From 4efa19d4357ab204d62397f1849e4651906e0e70 Mon Sep 17 00:00:00 2001 From: polo Date: Sat, 10 May 2025 23:51:37 +0200 Subject: =?UTF-8?q?fichiers=20manquant=20du=20commit=20pr=C3=A9c=C3=A9dent?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/css/main.css | 215 ---------------------------------------------------- public/css/menu.css | 4 +- public/js/main.js | 81 +------------------- 3 files changed, 3 insertions(+), 297 deletions(-) delete mode 100644 public/css/main.css (limited to 'public') diff --git a/public/css/main.css b/public/css/main.css deleted file mode 100644 index 870082a..0000000 --- a/public/css/main.css +++ /dev/null @@ -1,215 +0,0 @@ -main -{ - margin: auto; - /*max-width: 1200px;*/ - background-color: #E3F3FF; - padding: 15px 0; -} -section > h3 -{ - padding: 15px; - margin: 0; - text-align: center; -} -.grid_columns -{ - display: grid; - grid-template-columns: repeat(3, 1fr); -} -@media screen and (max-width: 800px) -{ - .grid_columns - { - grid-template-columns: repeat(2, 1fr); - } -} -@media screen and (max-width: 550px) -{ - .grid_columns - { - display: block; - } -} -.galery_photos -{ - display: flex; - flex-wrap: wrap; - justify-content: space-evenly; -} -.galery_photos .html_from_editor img -{ - max-width: 300px; - max-height: 200px; -} -article -{ - /*display: flex;*/ - background-color: white; - margin: 15px; - padding: 0 15px; - /*min-height: 150px;*/ -} -article .logo2 -{ - vertical-align: middle; - max-width: 200px; - max-height: 200px; - margin-right: 15px; -} -.new_content, .article_content -{ - width: 100%; -} -.new_content -{ - /*max-height: 400;*/ - overflow: hidden; -} -article img -{ - width: 100%; - height: auto; -} - -.action_icon -{ - width: 24px; - vertical-align: bottom; - border: white 2px solid; /* invisible */ -} -button .action_icon -{ - border: none; -} -.action_icon:hover -{ - background-color: #ffff00; - border-radius: 4px; - border: lightgrey 2px outset; - cursor: pointer; -} -button .action_icon:hover -{ - border: none; -} - -.button_zone -{ - display: flex; -} - -.share -{ - float: right; -} -.article_title_zone -{ - padding: 10px; -} -.under_an_article -{ - display: flex; - justify-content: space-between; - font-size: small; -} -.under_an_article img -{ - width: 24px; - margin-right: 5px; - vertical-align: middle; -} -.article_admin_zone -{ - display: flex; - justify-content: end; -} -main button -{ - color: #ff1d04; - font-size: medium; - border-radius: 4px; - background-color: white; - border: lightgrey 2px outset; /* rend identiques les boutons firefox et chromium */ -} -main button:hover -{ - background-color: #ffff00; - border-radius: 4px; - cursor: pointer; -} - -article a:hover -{ - cursor: pointer; -} - - - -/* -- mode modification d'une page -- */ -/*.modif_page_explanations -{ - background-color: white; - padding: 10px; - margin: 10px 20px; -} -.modif_page_explanations div -{ - display: flex; - flex-wrap: wrap; - font-size: smaller; -}*/ -.edit_bloc_zone -{ - background-color: white; - padding: 10px; - margin: 10px 15px; - display: flex; - justify-content: space-evenly; - flex-wrap: wrap; -} -.edit_bloc_zone p -{ - margin: 5px; -} -.new_bloc, .modify_bloc -{ - /*background-color: white; - padding: 10px; - margin: 10px 20px;*/ -} -.new_bloc p -{ - /*margin: 5px;*/ -} -.new_bloc #bloc_title -{ - width: 70%; - max-width: 300px; -} -.new_bloc form select, .new_bloc form input[type=submit], .modify_bloc form input[type=submit] -{ - color: #ff1d04; - font-size: medium; - border-radius: 4px; - background-color: white; - border: lightgrey 2px outset; -} -select:hover -{ - cursor: pointer; -} -.new_bloc form input[type=submit]:hover, .modify_bloc form input[type=submit]:hover -{ - background-color: #ffff00; - border-radius: 4px; - cursor: pointer; -} -.modify_bloc > div -{ - display: flex; - align-items: baseline; -} -.modify_bloc img -{ - vertical-align: middle; -} \ No newline at end of file diff --git a/public/css/menu.css b/public/css/menu.css index 61e8a01..68e2b2a 100644 --- a/public/css/menu.css +++ b/public/css/menu.css @@ -1,4 +1,4 @@ -/* page "Menu et chemins" uniquement */ +/*-- page "Menu et chemins" uniquement --*/ .menu { @@ -68,7 +68,7 @@ { width: 20px; vertical-align: middle; - border: 2px #e3f3ff solid; + border: 2px transparent solid; } .menu #location:hover, .menu input[type=submit]:hover, .move_entry_icon:hover { diff --git a/public/js/main.js b/public/js/main.js index 7dacb7a..071a1db 100644 --- a/public/js/main.js +++ b/public/js/main.js @@ -36,6 +36,7 @@ function toastNotify(message) { setTimeout(function(){ toast.className = toast.className.replace('show', ''); }, 3000); } + // complète les fonctions dans tinymce.js function switchPositions(article_id, direction) { @@ -202,84 +203,4 @@ function findParent(element, tag_name){ element = element.parentElement; } return null; -} - - -/* -- mode Modification d'une page -- */ -function renamePageBloc(bloc_id){ - const input = document.getElementById("bloc_rename_" + bloc_id); - const title = document.getElementById(bloc_id).querySelector("h3"); - - fetch('index.php?bloc_edit=rename_page_bloc', { - method: 'POST', - headers: { - 'Content-Type': 'application/json' - }, - body: JSON.stringify({bloc_title: input.value, bloc_id: bloc_id}) - }) - .then(response => response.json()) - .then(data => { - if(data.success){ - title.innerHTML = data.title; - console.log(data.title); - toastNotify('Le bloc a été renommé: ' + data.title); - } - else{ - console.error('Erreur au renommage du titre.'); - } - }) - .catch(error => { - console.error('Erreur:', error); - }); -} - -function switchBlocsPositions(bloc_id, direction, current_page) { - const current_bloc = document.getElementById(bloc_id); - const current_bloc_edit_zone = document.getElementById("bloc_edit_" + bloc_id); - var other_bloc; - - if(direction == 'down'){ - other_bloc = current_bloc.nextElementSibling; - } - else if(direction == 'up'){ - other_bloc = current_bloc.previousElementSibling; - } - - if(other_bloc == null || other_bloc.tagName !== 'SECTION') - { - console.log('Inversion impossible'); - return; - } - const other_bloc_edit_zone = document.getElementById("bloc_edit_" + other_bloc.id); - - fetch('index.php?page=' + current_page + '&bloc_edit=switch_blocs_positions', { - method: 'POST', - headers: { - 'Content-Type': 'application/json' - }, - body: JSON.stringify({ id1: bloc_id, id2: parseInt(other_bloc.id) }) - }) - .then(response => response.json()) - .then(data => { - if(data.success) - { - if(direction == 'down'){ - current_bloc.parentElement.insertBefore(other_bloc, current_bloc); - current_bloc_edit_zone.parentElement.insertBefore(other_bloc_edit_zone, current_bloc_edit_zone); - console.log('Inversion réussie'); - } - else if(direction == 'up'){ - other_bloc.parentElement.insertBefore(current_bloc, other_bloc); - other_bloc_edit_zone.parentElement.insertBefore(current_bloc_edit_zone, other_bloc_edit_zone); - console.log('Inversion réussie'); - } - } - else { - - console.error('Échec de l\'inversion'); - } - }) - .catch(error => { - console.error('Erreur:', error); - }); } \ No newline at end of file -- cgit v1.2.3