passage à du plus joli

This commit is contained in:
newick 2019-04-04 12:54:22 +02:00
parent f6ded6f5fa
commit b5581c7127
5 changed files with 282 additions and 153 deletions

View File

@ -11,10 +11,12 @@
<meta name="description" content=" "> <meta name="description" content=" ">
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<link crossorigin="anonymous" rel="stylesheet" href="https://rawgit.com/twbs/bootstrap/v4-dev/dist/css/bootstrap-reboot.css"> <link crossorigin="anonymous" rel="stylesheet"
href="https://rawgit.com/twbs/bootstrap/v4-dev/dist/css/bootstrap-reboot.css">
<link rel="stylesheet" href="style.css"> <link rel="stylesheet" href="style.css">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.5.0/css/all.css" integrity="sha384-B4dIYHKNBt8Bc12p+WXckhzcICo0wtJAoU8YZTY5qE0Id1GSseTk6S+L3BlXeVIU" crossorigin="anonymous"> <link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.5.0/css/all.css"
integrity="sha384-B4dIYHKNBt8Bc12p+WXckhzcICo0wtJAoU8YZTY5qE0Id1GSseTk6S+L3BlXeVIU" crossorigin="anonymous">
</head> </head>
@ -25,7 +27,21 @@
</section> </section>
<section> <section>
<p>Je veux ajouter des dates <select id="ajouterDesHoraires"><option>sans</option><option>avec des</option></select> horaires<span id="identiquesDifferentsPourChaqueJour" style="display:none"> <select id="horairesIdentiquesOuDifferents"><option>identiques</option><option>différents</option></select> pour chaque jour</span>.</p> <p>Je veux ajouter des dates
<span class=select-wrapper>
<select id="ajouterDesHoraires">
<option>sans</option>
<option>avec des</option>
</select>
</span>
horaires
<span id="identiquesDifferentsPourChaqueJour" style="display:none">
<select id="horairesIdentiquesOuDifferents">
<option>identiques</option>
<option>différents</option>
</select>
</span>
pour chaque jour.</p>
</section> </section>
<section> <section>
@ -57,7 +73,7 @@
</li> </li>
</ul> </ul>
<button id="addDateButton">Ajouter une date</button> <button id="addDateButton" class="btn btn-secondary">Ajouter une date</button>
<ul class="horaire-identique" style="display:none"> <ul class="horaire-identique" style="display:none">
<li> <li>
@ -78,6 +94,5 @@
<script src="script.js"></script> <script src="script.js"></script>
</body> </body>
</html>
</html>

View File

@ -11,7 +11,8 @@
<meta name="description" content=" "> <meta name="description" content=" ">
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<link crossorigin="anonymous" rel="stylesheet" href="https://rawgit.com/twbs/bootstrap/v4-dev/dist/css/bootstrap-reboot.css"> <link crossorigin="anonymous" rel="stylesheet"
href="https://rawgit.com/twbs/bootstrap/v4-dev/dist/css/bootstrap-reboot.css">
<link rel="stylesheet" href="style.css"> <link rel="stylesheet" href="style.css">
</head> </head>
@ -19,51 +20,66 @@
<section> <section>
<p>Je veux que <p>Je veux que
<select name="" id=""> <span class="select-wrapper">
<option value="">tout le monde</option> <select name="" id="">
<option value="">moi uniquement</option> <option value="">tout le monde</option>
</select> <option value="">moi uniquement</option>
puisse voir les réponses du sondage. </select>
</select>. D'ailleurs, il sera supprimé le <input type="date" name="" id="">. </span>
puisse voir les réponses du sondage jusqu'à sa suppression le <input type="date" name="" id="">.
</p> </p>
<p>Les personnes sondées pourront voter jusqu'à <p>Les personnes sondées pourront voter jusqu'à
<select name="" id=""> <span class="select-wrapper">
<option value="">la suppression du sondate</option> <select name="" id="">
<option value="">date</option> <option value="">la suppression du sondage</option>
</select> <option value="">date</option>
<select name="" id=""> </select>
<option value="">sans avoir</option> </span>
<option value="">en ayant</option> <span class="select-wrapper">
</select> <select name="" id="">
<option value="">sans avoir</option>
<option value="">en ayant</option>
</select>
</span>
la possibilité de modifier la possibilité de modifier
<select name="" id=""> <span class="select-wrapper">
<option value="">leur vote</option> <select name="" id="">
<option value="">tous les votes</option>. <option value="">leur vote</option>
</select> <option value="">tous les votes</option>.
</select>
</span>
</p> </p>
<p>Je peux retrouver ce sondage grâce à mon email : <input type="email" id="email" name="email" value="monemail@example.com">.</p> <p>Je peux retrouver ce sondage grâce à mon email : <input type="email" id="email" name="email"
value="monemail@example.com">.</p>
<p> <p>
Je Je
<select name="" id=""> <span class="select-wrapper">
<option value="">veux</option> <select name="" id="">
<option value="">ne veux pas</option> <option value="">veux</option>
</select> que l'accès du sondage soit protégé par (un) ce mot de passe : <input type="password" name="" id="">. <option value="">ne veux pas</option>
</select>
</span>
que l'accès du sondage soit protégé par (un) ce mot de passe : <input type="password" name="" id="">.
</p> </p>
<p> <p>
<select name="" id=""> <span class="select-wrapper">
<option value="">J'ai envie</option> <select name="" id="">
<option value="">Je n'ai pas envie</option> <option value="">J'ai envie</option>
</select> <option value="">Je n'ai pas envie</option>
</select>
</span>
d'être tenu-e au courant par mail à chaque d'être tenu-e au courant par mail à chaque
<select name="" id=""> <span class="select-wrapper">
<option value="">nouveau commentaire</option> <select name="" id="">
<option value="">nouvelle participation</option> <option value="">nouveau commentaire</option>
<option value="">nouveau commentaire et nouvelle participation</option> <option value="">nouvelle participation</option>
</select> <option value="">nouveau commentaire et nouvelle participation</option>
</select>
</span>
</p> </p>
</section> </section>

View File

@ -20,10 +20,12 @@
<section> <section>
<p> <p>
Je veux créer un sondage Je veux créer un sondage
<select id="type_sondage"> <span class=select-wrapper>
<option>special dates</option> <select id="type_sondage">
<option>classique</option> <option>spécial dates</option>
</select> <option>classique</option>
</select>
</span>
dont le titre sera&nbsp;:&nbsp;<input type="text" id="title" name="title" value="" class="nfl-textfield"> dont le titre sera&nbsp;:&nbsp;<input type="text" id="title" name="title" value="" class="nfl-textfield">
</p> </p>
<p> <p>

View File

@ -11,7 +11,8 @@
<meta name="description" content=" "> <meta name="description" content=" ">
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<link crossorigin="anonymous" rel="stylesheet" href="https://rawgit.com/twbs/bootstrap/v4-dev/dist/css/bootstrap-reboot.css"> <link crossorigin="anonymous" rel="stylesheet"
href="https://rawgit.com/twbs/bootstrap/v4-dev/dist/css/bootstrap-reboot.css">
<link rel="stylesheet" href="style.css"> <link rel="stylesheet" href="style.css">
</head> </head>
@ -21,12 +22,14 @@
<h1>Choix des sujets</h1> <h1>Choix des sujets</h1>
<p> <p>
Je veux proposer des réponses avec Je veux proposer des réponses avec
<select> <span class=select-wrapper>
<option>du texte</option> <select>
<option>des images</option> <option>du texte</option>
<option>des liens</option> <option>des images</option>
<option>des images avec des liens</option> <option>des liens</option>
</select> <option>des images avec des liens</option>
</select>
</span>
</p> </p>
<ul id="responses"> <ul id="responses">
</ul> </ul>
@ -41,6 +44,5 @@
<script src="script.js"></script> <script src="script.js"></script>
</body> </body>
</html>
</html>

View File

@ -1,201 +1,295 @@
:root {
--primary-color: royalblue;
}
body { body {
max-width: 320px; max-width: 320px;
margin: auto; margin: auto;
padding: 30px 20px; padding: 30px 20px;
font-family: sans-serif; font-family: Arial, sans-serif;
font-size: 16px; font-size: 16px;
line-height: 2; line-height: 2;
} }
/* Titres */ /* Titres */
h1 { h1 {
text-align: center; text-align: center;
font-size: 20px; font-size: 20px;
} }
h1 span { h1 span {
font-size: 60%; font-size: 60%;
font-weight: 400; font-weight: 400;
} }
/* Formulaires */ /* Formulaires */
.select-wrapper {
position: relative;
display: inline-block;
margin-bottom: 12px;
}
.select-wrapper:after {
content: '▾';
position: absolute;
top: 0;
right: 10px;
line-height: 44px;
}
select {
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
padding: 10px 30px 10px 10px;
color: var(--primary-color);
font-weight: bold;
border: 1px solid rgb(128, 126, 126);
background: none;
}
.btn, .btn,
button, button,
[type="submit"] { [type="submit"] {
display: block; display: block;
width: 200px; width: 200px;
margin: 10px auto auto; margin: 10px auto auto;
padding: 8px 0; padding: 8px 0;
text-align: center; text-align: center;
color: #4a90e2; color: var(--primary-color);
font-weight: 600; font-weight: 600;
border: 2px solid #4a90e2; border: 2px solid var(--primary-color);
border-radius: 4px; border-radius: 4px;
background-color: white; background-color: white;
transition: all 0.2s ease-in-out; transition: all 0.2s ease-in-out;
cursor: pointer; cursor: pointer;
} }
.btn:hover, .btn:hover,
button:hover, button:hover,
[type="submit"]:hover { [type="submit"]:hover {
color: #fff; color: #fff;
background-color: #4a90e2; background-color: var(--primary-color);
text-decoration: none; text-decoration: none;
} }
.champ-vide-long { .champ-vide-long {
min-width: 100px; min-width: 100px;
display: inline-block; display: inline-block;
height: 20px; height: 20px;
} }
.btn.btn-primary { .btn.btn-primary {
color: #fff; color: #fff;
background-color: #4a90e2; background-color: var(--primary-color);
}
.btn.btn-primary:hover {
color: #4a90e2;
background-color: #fff;
} }
.btn.btn-primary:hover {
color: var(--primary-color);
background-color: #fff;
}
.btn.btn-secondary {
position: relative;
display: inline;
width: auto;
padding: 0;
color: var(--primary-color);
border: none;
border-bottom: 1px solid var(--primary-color);
border-radius: 0;
}
.btn.btn-secondary:before {
content: '+';
margin-right: 10px;
}
.btn.btn-secondary:after {
content: '';
position: absolute;
bottom: 0;
left: 0;
display: block;
width: 100%;
height: 1px;
background-color: var(--primary-color);
}
.btn.btn-secondary:hover {
background: none;
}
.btn.btn-secondary:hover:after {
height: 2px;
}
.btn-no-style { .btn-no-style {
display: inline-block; display: inline-block;
width: auto; width: auto;
margin: 0; margin: 0;
padding: 0; padding: 0;
border: 0; border: 0;
color: inherit; color: inherit;
} }
section button { section button {
width: 100%; width: 100%;
color: #4a4a4a; color: #4a4a4a;
border-color: #4a4a4a; border-color: #4a4a4a;
} }
section button:hover { section button:hover {
color: #fff; color: #fff;
background-color: #4a4a4a; background-color: #4a4a4a;
} }
label, label,
input { input {
display: inline; display: inline;
} }
p { p {
margin-bottom: 2rem; margin-bottom: 2rem;
/* line-height: 2.7; */
} }
/* Listes */ /* Listes */
ul { ul {
padding-left: 0; padding-left: 0;
list-style-type: none; list-style-type: none;
} }
li + li { li+li {
margin-top: 20px; margin-top: 20px;
} }
.default-list { .default-list {
padding-left: 20px; padding-left: 20px;
list-style-type: disc; list-style-type: disc;
} }
.default-list li + li { .default-list li+li {
margin-top: 0; margin-top: 0;
} }
/* Apparence */ /* Apparence */
section:not(:last-of-type) { section:not(:last-of-type) {
margin-bottom: 30px; margin-bottom: 30px;
} }
input[type="text"] { input[type="text"] {
border:0; border: 0;
border-bottom:1px solid black; border-bottom: 1px solid black;
line-height:60%; line-height: 60%;
} }
input[type="date"] { input[type="date"] {
width: 60%; width: 60%;
padding: 5px; border-radius: 4px;
border: 1px solid #9b9b9b;
border-radius: 4px;
} }
input[type="date"]:disabled { input[type="date"]:disabled {
opacity: 0.7; opacity: 0.7;
} }
[type="email"] { [type="email"] {
width: 100%; width: 100%;
} }
textarea { textarea {
display: block; display: block;
width: 100%; width: 100%;
min-height: 130px; min-height: 130px;
padding: 0.5em; margin-top: 12px;
} }
select,
.toggle-field,
textarea,
[type=date],
[type=email],
[type=password] {
color: black;
line-height: 1.5;
font-weight: normal;
background-color: rgba(65, 105, 225, .2);
border: none;
}
.toggle-field,
textarea,
[type=date],
[type=email],
[type=password] {
padding: 8px 10px;
}
.toggle-field { .toggle-field {
color: #4a90e2; min-height: 42px;
cursor: pointer; height: auto;
border-bottom: 1px solid #4a4a4a; cursor: pointer;
/* border: 1px solid rgb(128, 126, 126); */
} }
.overlay { .overlay {
background: rgba(1, 1, 1, .3); background: rgba(1, 1, 1, .3);
height: 100%; height: 100%;
top: 0; top: 0;
left: 0; left: 0;
position: absolute; position: absolute;
width: 100%; width: 100%;
z-index: 5; z-index: 5;
} }
.modal { .modal {
background: #fff; background: #fff;
top: 10%; top: 10%;
left: 40%; left: 40%;
padding: 10px; padding: 10px;
position: absolute; position: absolute;
z-index: 10; z-index: 10;
} }
i { i {
color: #4a4a4a; color: #4a4a4a;
} }
.fa-calendar-alt { .fa-calendar-alt {
font-size: 22px; font-size: 22px;
margin-right: .2em; margin-right: .2em;
} }
.fa-trash-alt { .fa-trash-alt {
color: #9b9b9b; color: #9b9b9b;
} }
.item-disabled { .item-disabled {
opacity: 0.7; opacity: 0.7;
} }
section + nav { section+nav {
margin-top: 100px; margin-top: 2rem;
} }
.w100 { .w100 {
width: 100%; width: 100%;
}
.bold {
font-weight: 600;
} }
article + article { .bold {
margin-top: 40px; font-weight: 600;
}
article+article {
margin-top: 40px;
} }
a { a {
color: #4a4a4a; color: #4a4a4a;
} }
a:hover { a:hover {
color: #4a90e2; color: var(--primary-color);
} }