Skip to content

Commit 2502f26

Browse files
authored
Affiche les zones de saisie même lorsque les CSS sont désactivées (#1120)
* add fake border and label when css is disabled * add tiptap placeholder extension * visually show editor when css is disabled * rename classes * only show placeholde when editor is editable * remove tiptap placeholder * fix wrong import * fix yarn lock * add end line to yarn lock * update changelog
1 parent 31e8c93 commit 2502f26

2 files changed

Lines changed: 37 additions & 1 deletion

File tree

CHANGELOG.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,16 @@
44

55
<h2 class="fr-sr-only" id="2025">2025</h2>
66

7+
### 28/05/2025
8+
9+
#### <span aria-hidden="true">⚙️</span> Autres changements
10+
11+
- Modifie le thème visuel des blocs de code de l’éditeur pour assurer un bon contraste des couleurs ([#1124](https://github.com/DISIC/Ara/pull/1124))
12+
13+
#### <span aria-hidden="true">🐛</span> Corrections
14+
15+
- Corrige l’affichage de l’éditeur lorsque les CSS sont désactivées ([#1120](https://github.com/DISIC/Ara/pull/1120))
16+
717
### 22/05/2025
818

919
#### <span aria-hidden="true">🐛</span> Corrections

confiture-web-app/src/components/tiptap/TiptapEditor.vue

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,14 +270,40 @@ defineExpose({
270270
</ul>
271271
</li>
272272
</ul>
273-
<editor-content :editor="editor" />
273+
274+
<!-- Visually show the editor with a border and a label when CSS is disabled -->
275+
<p class="tiptap__fake-label" aria-hidden="true">
276+
Erreur et recommandation
277+
</p>
278+
<table
279+
role="presentation"
280+
border="1"
281+
width="100%"
282+
class="tiptap__fake-table"
283+
>
284+
<tr>
285+
<td>
286+
<editor-content :editor="editor" />
287+
</td>
288+
</tr>
289+
</table>
274290
</div>
275291
</template>
276292

277293
<style>
278294
@import url("./tiptap.css");
279295
@import url("./tiptap-hljs.css");
280296
297+
/* Handle case when CSS is disabled */
298+
.tiptap__fake-label {
299+
display: none;
300+
}
301+
302+
.tiptap__fake-table,
303+
.tiptap__fake-table td {
304+
border: none;
305+
}
306+
281307
/* Container */
282308
.tiptap-container {
283309
position: relative;

0 commit comments

Comments
 (0)