ether-code 0.5.5 → 0.5.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/cli/ether.js CHANGED
@@ -6,7 +6,7 @@ const http = require('http')
6
6
  const { EtherCompiler } = require('./compiler')
7
7
  const { Watcher } = require('./watcher')
8
8
 
9
- const VERSION = '0.5.5'
9
+ const VERSION = '0.5.6'
10
10
 
11
11
  const COLORS = {
12
12
  reset: '\x1b[0m',
@@ -101,7 +101,6 @@ corps
101
101
  min-hauteur: 100vh
102
102
 
103
103
  .hero
104
- min-hauteur: 100vh
105
104
  position: relative
106
105
  debordement: hidden
107
106
 
@@ -174,6 +174,9 @@ class CSSGenerator {
174
174
  'repetition-fond': 'background-repeat',
175
175
  'repetition fond': 'background-repeat',
176
176
  'fond-repetition': 'background-repeat',
177
+ 'répétition-fond': 'background-repeat',
178
+ 'répétition fond': 'background-repeat',
179
+ 'fond-répétition': 'background-repeat',
177
180
  'attachement-fond': 'background-attachment',
178
181
  'attachement fond': 'background-attachment',
179
182
  'fond-attachement': 'background-attachment',
@@ -182,9 +185,15 @@ class CSSGenerator {
182
185
  'decoupe-fond': 'background-clip',
183
186
  'decoupe fond': 'background-clip',
184
187
  'fond-decoupe': 'background-clip',
188
+ 'découpe-fond': 'background-clip',
189
+ 'découpe fond': 'background-clip',
190
+ 'fond-découpe': 'background-clip',
185
191
  'mode-melange': 'mix-blend-mode',
186
192
  'mode melange': 'mix-blend-mode',
187
193
  'melange-mode': 'mix-blend-mode',
194
+ 'mode-mélange': 'mix-blend-mode',
195
+ 'mode mélange': 'mix-blend-mode',
196
+ 'mélange-mode': 'mix-blend-mode',
188
197
  'mode-fusion': 'mix-blend-mode',
189
198
  'mode fusion': 'mix-blend-mode',
190
199
  'couleur-bordure': 'border-color',
@@ -216,6 +225,9 @@ class CSSGenerator {
216
225
  'decoration-texte': 'text-decoration',
217
226
  'decoration texte': 'text-decoration',
218
227
  'texte-decoration': 'text-decoration',
228
+ 'décoration-texte': 'text-decoration',
229
+ 'décoration texte': 'text-decoration',
230
+ 'texte-décoration': 'text-decoration',
219
231
  'transformation-texte': 'text-transform',
220
232
  'transformation texte': 'text-transform',
221
233
  'texte-transformation': 'text-transform',
@@ -225,6 +237,9 @@ class CSSGenerator {
225
237
  'debordement-texte': 'text-overflow',
226
238
  'debordement texte': 'text-overflow',
227
239
  'texte-debordement': 'text-overflow',
240
+ 'débordement-texte': 'text-overflow',
241
+ 'débordement texte': 'text-overflow',
242
+ 'texte-débordement': 'text-overflow',
228
243
  'renvoi-mots': 'word-wrap',
229
244
  'renvoi mots': 'word-wrap',
230
245
  'cesure-mots': 'word-break',
@@ -247,6 +262,9 @@ class CSSGenerator {
247
262
  'retrecissement-flex': 'flex-shrink',
248
263
  'retrecissement flex': 'flex-shrink',
249
264
  'flex-retrecissement': 'flex-shrink',
265
+ 'rétrécissement-flex': 'flex-shrink',
266
+ 'rétrécissement flex': 'flex-shrink',
267
+ 'flex-rétrécissement': 'flex-shrink',
250
268
  'base-flex': 'flex-basis',
251
269
  'base flex': 'flex-basis',
252
270
  'flex-base': 'flex-basis',
@@ -256,6 +274,9 @@ class CSSGenerator {
256
274
  'aligner-elements': 'align-items',
257
275
  'aligner elements': 'align-items',
258
276
  'elements-aligner': 'align-items',
277
+ 'aligner-éléments': 'align-items',
278
+ 'aligner éléments': 'align-items',
279
+ 'éléments-aligner': 'align-items',
259
280
  'aligner-soi': 'align-self',
260
281
  'aligner soi': 'align-self',
261
282
  'soi-aligner': 'align-self',
@@ -283,6 +304,9 @@ class CSSGenerator {
283
304
  'ecart-grille': 'grid-gap',
284
305
  'ecart grille': 'grid-gap',
285
306
  'grille-ecart': 'grid-gap',
307
+ 'écart-grille': 'grid-gap',
308
+ 'écart grille': 'grid-gap',
309
+ 'grille-écart': 'grid-gap',
286
310
  'flux-automatique-grille': 'grid-auto-flow',
287
311
  'flux automatique grille': 'grid-auto-flow',
288
312
  'colonnes-automatiques-grille': 'grid-auto-columns',
@@ -314,6 +338,9 @@ class CSSGenerator {
314
338
  'cote-legendes': 'caption-side',
315
339
  'cote legendes': 'caption-side',
316
340
  'legendes-cote': 'caption-side',
341
+ 'côté-légendes': 'caption-side',
342
+ 'côté légendes': 'caption-side',
343
+ 'légendes-côté': 'caption-side',
317
344
  'cellules-vides': 'empty-cells',
318
345
  'cellules vides': 'empty-cells',
319
346
  'vides-cellules': 'empty-cells',
@@ -329,12 +356,24 @@ class CSSGenerator {
329
356
  'defilement x': 'overflow-x',
330
357
  'defilement-y': 'overflow-y',
331
358
  'defilement y': 'overflow-y',
359
+ 'débordement': 'overflow',
360
+ 'débordement-x': 'overflow-x',
361
+ 'débordement x': 'overflow-x',
362
+ 'débordement-y': 'overflow-y',
363
+ 'débordement y': 'overflow-y',
364
+ 'défilement-x': 'overflow-x',
365
+ 'défilement x': 'overflow-x',
366
+ 'défilement-y': 'overflow-y',
367
+ 'défilement y': 'overflow-y',
332
368
  'comportement-defilement': 'scroll-behavior',
333
369
  'comportement defilement': 'scroll-behavior',
334
370
  'defilement-comportement': 'scroll-behavior',
335
371
  'accrochage-defilement': 'scroll-snap-type',
336
372
  'accrochage defilement': 'scroll-snap-type',
337
373
  'defilement-accrochage': 'scroll-snap-type',
374
+ 'accrochage-défilement': 'scroll-snap-type',
375
+ 'accrochage défilement': 'scroll-snap-type',
376
+ 'défilement-accrochage': 'scroll-snap-type',
338
377
  'origine-transformation': 'transform-origin',
339
378
  'origine transformation': 'transform-origin',
340
379
  'transformation-origine': 'transform-origin',
@@ -344,18 +383,28 @@ class CSSGenerator {
344
383
  'face-arriere-visible': 'backface-visibility',
345
384
  'face arriere visible': 'backface-visibility',
346
385
  'visibilite-face-arriere': 'backface-visibility',
386
+ 'visibilité-face-arrière': 'backface-visibility',
347
387
  'origine-perspective': 'perspective-origin',
348
388
  'origine perspective': 'perspective-origin',
349
389
  'perspective-origine': 'perspective-origin',
350
390
  'delai-transition': 'transition-delay',
351
391
  'delai transition': 'transition-delay',
352
392
  'transition-delai': 'transition-delay',
393
+ 'délai-transition': 'transition-delay',
394
+ 'délai transition': 'transition-delay',
395
+ 'transition-délai': 'transition-delay',
353
396
  'duree-transition': 'transition-duration',
354
397
  'duree transition': 'transition-duration',
355
398
  'transition-duree': 'transition-duration',
399
+ 'durée-transition': 'transition-duration',
400
+ 'durée transition': 'transition-duration',
401
+ 'transition-durée': 'transition-duration',
356
402
  'propriete-transition': 'transition-property',
357
403
  'propriete transition': 'transition-property',
358
404
  'transition-propriete': 'transition-property',
405
+ 'propriété-transition': 'transition-property',
406
+ 'propriété transition': 'transition-property',
407
+ 'transition-propriété': 'transition-property',
359
408
  'fonction-transition': 'transition-timing-function',
360
409
  'fonction transition': 'transition-timing-function',
361
410
  'transition-fonction': 'transition-timing-function',
@@ -365,15 +414,24 @@ class CSSGenerator {
365
414
  'duree-animation': 'animation-duration',
366
415
  'duree animation': 'animation-duration',
367
416
  'animation-duree': 'animation-duration',
417
+ 'durée-animation': 'animation-duration',
418
+ 'durée animation': 'animation-duration',
419
+ 'animation-durée': 'animation-duration',
368
420
  'fonction-animation': 'animation-timing-function',
369
421
  'fonction animation': 'animation-timing-function',
370
422
  'animation-fonction': 'animation-timing-function',
371
423
  'delai-animation': 'animation-delay',
372
424
  'delai animation': 'animation-delay',
373
425
  'animation-delai': 'animation-delay',
426
+ 'délai-animation': 'animation-delay',
427
+ 'délai animation': 'animation-delay',
428
+ 'animation-délai': 'animation-delay',
374
429
  'iterations-animation': 'animation-iteration-count',
375
430
  'iterations animation': 'animation-iteration-count',
376
431
  'animation-iterations': 'animation-iteration-count',
432
+ 'itérations-animation': 'animation-iteration-count',
433
+ 'itérations animation': 'animation-iteration-count',
434
+ 'animation-itérations': 'animation-iteration-count',
377
435
  'direction-animation': 'animation-direction',
378
436
  'direction animation': 'animation-direction',
379
437
  'animation-direction': 'animation-direction',
@@ -383,6 +441,9 @@ class CSSGenerator {
383
441
  'etat-lecture-animation': 'animation-play-state',
384
442
  'etat lecture animation': 'animation-play-state',
385
443
  'animation-etat-lecture': 'animation-play-state',
444
+ 'état-lecture-animation': 'animation-play-state',
445
+ 'état lecture animation': 'animation-play-state',
446
+ 'animation-état-lecture': 'animation-play-state',
386
447
  'ajustement-objet': 'object-fit',
387
448
  'ajustement objet': 'object-fit',
388
449
  'objet-ajustement': 'object-fit',
@@ -392,15 +453,27 @@ class CSSGenerator {
392
453
  'selection-utilisateur': 'user-select',
393
454
  'selection utilisateur': 'user-select',
394
455
  'utilisateur-selection': 'user-select',
456
+ 'sélection-utilisateur': 'user-select',
457
+ 'sélection utilisateur': 'user-select',
458
+ 'utilisateur-sélection': 'user-select',
395
459
  'evenements-pointeur': 'pointer-events',
396
460
  'evenements pointeur': 'pointer-events',
397
461
  'pointeur-evenements': 'pointer-events',
462
+ 'évènements-pointeur': 'pointer-events',
463
+ 'évènements pointeur': 'pointer-events',
464
+ 'pointeur-évènements': 'pointer-events',
465
+ 'événements-pointeur': 'pointer-events',
466
+ 'événements pointeur': 'pointer-events',
467
+ 'pointeur-événements': 'pointer-events',
398
468
  'comportement-tactile': 'touch-action',
399
469
  'comportement tactile': 'touch-action',
400
470
  'tactile-comportement': 'touch-action',
401
471
  'sens-ecriture': 'writing-mode',
402
472
  'sens ecriture': 'writing-mode',
403
473
  'ecriture-sens': 'writing-mode',
474
+ 'sens-écriture': 'writing-mode',
475
+ 'sens écriture': 'writing-mode',
476
+ 'écriture-sens': 'writing-mode',
404
477
  'direction-texte': 'direction',
405
478
  'direction texte': 'direction',
406
479
  'texte-direction': 'direction',
@@ -416,12 +489,19 @@ class CSSGenerator {
416
489
  'colonnes-largeur': 'column-width',
417
490
  'ecart-colonnes': 'column-gap',
418
491
  'ecart colonnes': 'column-gap',
492
+ 'écart-colonnes': 'column-gap',
493
+ 'écart colonnes': 'column-gap',
419
494
  'colonnes-ecart': 'column-gap',
495
+ 'colonnes-écart': 'column-gap',
420
496
  'regle-colonnes': 'column-rule',
497
+ 'règle-colonnes': 'column-rule',
421
498
  'regle colonnes': 'column-rule',
499
+ 'règle colonnes': 'column-rule',
422
500
  'colonnes-regle': 'column-rule',
423
501
  'etendue-colonnes': 'column-span',
424
- 'etendue colonnes': 'column-span',
502
+ 'étendue-colonnes': 'column-span',
503
+ 'etendue-colonnes': 'column-span',
504
+ 'étendue colonnes': 'column-span',
425
505
  'colonnes-etendue': 'column-span',
426
506
  'remplissage-colonnes': 'column-fill',
427
507
  'remplissage colonnes': 'column-fill',
@@ -429,8 +509,45 @@ class CSSGenerator {
429
509
  'modele-boite': 'box-sizing',
430
510
  'modele boite': 'box-sizing',
431
511
  'boite-modele': 'box-sizing',
512
+ 'modèle-boite': 'box-sizing',
513
+ 'modèle-boîte': 'box-sizing',
514
+ 'modèle boite': 'box-sizing',
515
+ 'modèle boîte': 'box-sizing',
516
+ 'boite modele': 'box-sizing',
517
+ 'boîte modèle': 'box-sizing',
518
+ 'boîte-modèle': 'box-sizing',
432
519
  'dimensionnement-boite': 'box-sizing',
433
520
  'dimensionnement boite': 'box-sizing',
521
+ 'dimensionnement-boîte': 'box-sizing',
522
+ 'dimensionnement boîte': 'box-sizing',
523
+ 'boite': 'box-sizing',
524
+ 'boîte': 'box-sizing',
525
+ 'taille-boite': 'box-sizing',
526
+ 'taille boite': 'box-sizing',
527
+ 'boite-taille': 'box-sizing',
528
+ 'taille-boîte': 'box-sizing',
529
+ 'taille boîte': 'box-sizing',
530
+ 'boîte-taille': 'box-sizing',
531
+ 'largeur-max': 'max-width',
532
+ 'largeur max': 'max-width',
533
+ 'hauteur-max': 'max-height',
534
+ 'hauteur max': 'max-height',
535
+ 'largeur-min': 'min-width',
536
+ 'largeur min': 'min-width',
537
+ 'hauteur-min': 'min-height',
538
+ 'hauteur min': 'min-height',
539
+ 'bordure-rayon': 'border-radius',
540
+ 'bordure rayon': 'border-radius',
541
+ 'rayon-bordure': 'border-radius',
542
+ 'rayon bordure': 'border-radius',
543
+ 'rayon bordure': 'border-radius',
544
+ 'texte-aligner': 'text-align',
545
+ 'texte aligner': 'text-align',
546
+ 'aligner-texte': 'text-align',
547
+ 'texte-decoration': 'text-decoration',
548
+ 'texte decoration': 'text-decoration',
549
+ 'liste-style': 'list-style',
550
+ 'style-liste': 'list-style',
434
551
  'couleur-caret': 'caret-color',
435
552
  'couleur caret': 'caret-color',
436
553
  'caret-couleur': 'caret-color',
@@ -467,9 +584,15 @@ class CSSGenerator {
467
584
  'chemin-decoupe': 'clip-path',
468
585
  'chemin decoupe': 'clip-path',
469
586
  'decoupe-chemin': 'clip-path',
587
+ 'chemin-découpé': 'clip-path',
588
+ 'chemin découpé': 'clip-path',
589
+ 'découpe-chemin': 'clip-path',
470
590
  'forme-exterieure': 'shape-outside',
471
591
  'forme exterieure': 'shape-outside',
472
592
  'exterieure-forme': 'shape-outside',
593
+ 'forme-extérieure': 'shape-outside',
594
+ 'forme extérieure': 'shape-outside',
595
+ 'extérieure-forme': 'shape-outside',
473
596
  'marge-forme': 'shape-margin',
474
597
  'marge forme': 'shape-margin',
475
598
  'forme-marge': 'shape-margin'
@@ -503,11 +626,11 @@ class CSSGenerator {
503
626
  return `var(--${varName})`
504
627
  })
505
628
 
506
- result = result.replace(/dégradé linéaire:\s*/gi, 'linear-gradient(')
629
+ result = result.replace(/dégradé linéaire:\s*/gi, 'linear-gradient(')
507
630
  result = result.replace(/degrade lineaire:\s*/gi, 'linear-gradient(')
508
- result = result.replace(/dégradé radial:\s*/gi, 'radial-gradient(')
631
+ result = result.replace(/dégradé radial:\s*/gi, 'radial-gradient(')
509
632
  result = result.replace(/degrade radial:\s*/gi, 'radial-gradient(')
510
- result = result.replace(/dégradé conique:\s*/gi, 'conic-gradient(')
633
+ result = result.replace(/dégradé conique:\s*/gi, 'conic-gradient(')
511
634
  result = result.replace(/degrade conique:\s*/gi, 'conic-gradient(')
512
635
 
513
636
  result = result.replace(/rgba:\s*(\d+),\s*(\d+),\s*(\d+),\s*([\d.]+)/gi, 'rgba($1, $2, $3, $4)')
@@ -516,30 +639,30 @@ class CSSGenerator {
516
639
  result = result.replace(/hsla:\s*(\d+),\s*([\d.]+%?),\s*([\d.]+%?),\s*([\d.]+)/gi, 'hsla($1, $2, $3, $4)')
517
640
 
518
641
  result = result.replace(/flou:\s*([\d.]+\w*)/gi, 'blur($1)')
519
- result = result.replace(/luminosité:\s*([\d.]+%?)/gi, 'brightness($1)')
642
+ result = result.replace(/luminosité:\s*([\d.]+%?)/gi, 'brightness($1)')
520
643
  result = result.replace(/luminosite:\s*([\d.]+%?)/gi, 'brightness($1)')
521
644
  result = result.replace(/contraste:\s*([\d.]+%?)/gi, 'contrast($1)')
522
645
  result = result.replace(/niveaux-gris:\s*([\d.]+%?)/gi, 'grayscale($1)')
523
646
  result = result.replace(/niveaux gris:\s*([\d.]+%?)/gi, 'grayscale($1)')
524
647
  result = result.replace(/inverser:\s*([\d.]+%?)/gi, 'invert($1)')
525
648
  result = result.replace(/saturation:\s*([\d.]+%?)/gi, 'saturate($1)')
526
- result = result.replace(/sépia:\s*([\d.]+%?)/gi, 'sepia($1)')
649
+ result = result.replace(/sépia:\s*([\d.]+%?)/gi, 'sepia($1)')
527
650
  result = result.replace(/sepia:\s*([\d.]+%?)/gi, 'sepia($1)')
528
651
  result = result.replace(/teinte:\s*([\d.]+\w*)/gi, 'hue-rotate($1)')
529
652
 
530
- result = result.replace(/déplacer-y:\s*([\d.\-]+\w*)/gi, 'translateY($1)')
653
+ result = result.replace(/déplacer-y:\s*([\d.\-]+\w*)/gi, 'translateY($1)')
531
654
  result = result.replace(/deplacer-y:\s*([\d.\-]+\w*)/gi, 'translateY($1)')
532
- result = result.replace(/déplacer-x:\s*([\d.\-]+\w*)/gi, 'translateX($1)')
655
+ result = result.replace(/déplacer-x:\s*([\d.\-]+\w*)/gi, 'translateX($1)')
533
656
  result = result.replace(/deplacer-x:\s*([\d.\-]+\w*)/gi, 'translateX($1)')
534
- result = result.replace(/déplacer:\s*([\d.\-]+\w*),?\s*([\d.\-]+\w*)?/gi, (match, x, y) => {
657
+ result = result.replace(/déplacer:\s*([\d.\-]+\w*),?\s*([\d.\-]+\w*)?/gi, (match, x, y) => {
535
658
  if (y) return `translate(${x}, ${y})`
536
659
  return `translate(${x})`
537
660
  })
538
661
  result = result.replace(/rotation:\s*([\d.\-]+\w*)/gi, 'rotate($1)')
539
- result = result.replace(/échelle:\s*([\d.]+)/gi, 'scale($1)')
662
+ result = result.replace(chelle:\s*([\d.]+)/gi, 'scale($1)')
540
663
  result = result.replace(/echelle:\s*([\d.]+)/gi, 'scale($1)')
541
664
 
542
- result = result.replace(/répéter:\s*([^,]+),\s*minmax:\s*([^,]+),\s*([^\s\)]+)/gi, 'repeat($1, minmax($2, $3))')
665
+ result = result.replace(/répéter:\s*([^,]+),\s*minmax:\s*([^,]+),\s*([^\s\)]+)/gi, 'repeat($1, minmax($2, $3))')
543
666
  result = result.replace(/repeter:\s*([^,]+),\s*minmax:\s*([^,]+),\s*([^\s\)]+)/gi, 'repeat($1, minmax($2, $3))')
544
667
  result = result.replace(/minmax:\s*([^,]+),\s*([^\s\)]+)/gi, 'minmax($1, $2)')
545
668
 
@@ -670,16 +793,16 @@ class CSSGenerator {
670
793
  'aucun': 'none',
671
794
  'aucune': 'none',
672
795
  'auto': 'auto',
673
- 'hériter': 'inherit',
796
+ 'hériter': 'inherit',
674
797
  'heriter': 'inherit',
675
798
  'initial': 'initial',
676
- 'caché': 'hidden',
799
+ 'caché': 'hidden',
677
800
  'cache': 'hidden',
678
801
  'visible': 'visible',
679
- 'défiler': 'scroll',
802
+ 'défiler': 'scroll',
680
803
  'defiler': 'scroll',
681
804
  'fixe': 'fixed',
682
- 'fixée': 'fixed',
805
+ 'fixée': 'fixed',
683
806
  'fixee': 'fixed',
684
807
  'absolue': 'absolute',
685
808
  'absolu': 'absolute',
@@ -689,17 +812,17 @@ class CSSGenerator {
689
812
  'collant': 'sticky',
690
813
  'collante': 'sticky',
691
814
  'centre': 'center',
692
- 'centré': 'center',
693
- 'début': 'flex-start',
815
+ 'centré': 'center',
816
+ 'début': 'flex-start',
694
817
  'debut': 'flex-start',
695
818
  'fin': 'flex-end',
696
819
  'espace-entre': 'space-between',
697
820
  'espace entre': 'space-between',
698
821
  'espace-autour': 'space-around',
699
822
  'espace autour': 'space-around',
700
- 'espace-égal': 'space-evenly',
823
+ 'espacegal': 'space-evenly',
701
824
  'espace egal': 'space-evenly',
702
- 'étirer': 'stretch',
825
+ 'étirer': 'stretch',
703
826
  'etirer': 'stretch',
704
827
  'ligne': 'row',
705
828
  'colonne': 'column',
@@ -713,9 +836,9 @@ class CSSGenerator {
713
836
  'gras': 'bold',
714
837
  'normal': 'normal',
715
838
  'italique': 'italic',
716
- 'souligné': 'underline',
839
+ 'souligné': 'underline',
717
840
  'souligne': 'underline',
718
- 'barré': 'line-through',
841
+ 'barré': 'line-through',
719
842
  'barre': 'line-through',
720
843
  'majuscules': 'uppercase',
721
844
  'minuscules': 'lowercase',
@@ -736,14 +859,14 @@ class CSSGenerator {
736
859
  'grille': 'grid',
737
860
  'grille-en-ligne': 'inline-grid',
738
861
  'grille en ligne': 'inline-grid',
739
- 'préservé': 'pre',
862
+ 'préservé': 'pre',
740
863
  'preserve': 'pre',
741
- 'pré-ligne': 'pre-line',
864
+ 'pré-ligne': 'pre-line',
742
865
  'pre-ligne': 'pre-line',
743
- 'pré-enveloppe': 'pre-wrap',
866
+ 'pré-enveloppe': 'pre-wrap',
744
867
  'pre-enveloppe': 'pre-wrap',
745
868
  'solide': 'solid',
746
- 'pointillée': 'dotted',
869
+ 'pointillée': 'dotted',
747
870
  'pointillee': 'dotted',
748
871
  'tirets': 'dashed',
749
872
  'double': 'double',
@@ -752,7 +875,7 @@ class CSSGenerator {
752
875
  'ease-in': 'ease-in',
753
876
  'ease-out': 'ease-out',
754
877
  'ease-in-out': 'ease-in-out',
755
- 'linéaire': 'linear',
878
+ 'linéaire': 'linear',
756
879
  'lineaire': 'linear',
757
880
  'infini': 'infinite',
758
881
  'alternatif': 'alternate',
@@ -761,6 +884,19 @@ class CSSGenerator {
761
884
  'en avant': 'forwards',
762
885
  'en arriere': 'backwards',
763
886
  'les deux': 'both',
887
+ 'bordure-boite': 'border-box',
888
+ 'boite-bordure': 'border-box',
889
+ 'boite bordure': 'border-box',
890
+ 'bordure-boîte': 'border-box',
891
+ 'boîte-bordure': 'border-box',
892
+ 'boîte bordure': 'border-box',
893
+ 'boîte-contenu': 'content-box',
894
+ 'boîte contenu': 'content-box',
895
+ 'contenu-boîte': 'content-box',
896
+ 'boite-contenu': 'content-box',
897
+ 'boite contenu': 'content-box',
898
+ 'contenu-boite': 'content-box',
899
+ 'remplissage-boite': 'padding-box',
764
900
  'en pause': 'paused',
765
901
  'en cours': 'running',
766
902
  'ombre': 'box-shadow',
@@ -810,7 +946,7 @@ class CSSGenerator {
810
946
  }
811
947
 
812
948
  for (const [fr, en] of Object.entries(keywords)) {
813
- const regex = new RegExp(`\\b${fr}\\b`, 'gi')
949
+ const regex = new RegExp(`(?<![a-zA-ZÀ-ÿ])${fr}(?![a-zA-ZÀ-ÿ])`, 'gi')
814
950
  result = result.replace(regex, en)
815
951
  }
816
952
 
@@ -845,8 +981,8 @@ class CSSGenerator {
845
981
  'espacement lettres': 'letter-spacing',
846
982
  'alignement-texte': 'text-align',
847
983
  'alignement texte': 'text-align',
848
- 'décoration-texte': 'text-decoration',
849
- 'décoration texte': 'text-decoration',
984
+ 'décoration-texte': 'text-decoration',
985
+ 'décoration texte': 'text-decoration',
850
986
  'decoration-texte': 'text-decoration',
851
987
  'decoration texte': 'text-decoration',
852
988
  'transformation-texte': 'text-transform',
@@ -931,13 +1067,13 @@ class CSSGenerator {
931
1067
  'droite': 'right',
932
1068
  'index-z': 'z-index',
933
1069
  'z-index': 'z-index',
934
- 'débordement': 'overflow',
1070
+ 'débordement': 'overflow',
935
1071
  'debordement': 'overflow',
936
- 'débordement-x': 'overflow-x',
1072
+ 'débordement-x': 'overflow-x',
937
1073
  'debordement-x': 'overflow-x',
938
- 'débordement-y': 'overflow-y',
1074
+ 'débordement-y': 'overflow-y',
939
1075
  'debordement-y': 'overflow-y',
940
- 'opacité': 'opacity',
1076
+ 'opacité': 'opacity',
941
1077
  'opacite': 'opacity',
942
1078
  'curseur': 'cursor',
943
1079
  'transition': 'transition',
@@ -957,11 +1093,11 @@ class CSSGenerator {
957
1093
  'flou fond': 'backdrop-filter',
958
1094
  'ombre-boîte': 'box-shadow',
959
1095
  'ombre-boite': 'box-shadow',
960
- 'ombre boîte': 'box-shadow',
1096
+ 'ombre boîte': 'box-shadow',
961
1097
  'ombre boite': 'box-shadow',
962
- 'modèle-boîte': 'box-sizing',
1098
+ 'modèle-boîte': 'box-sizing',
963
1099
  'modele-boite': 'box-sizing',
964
- 'modèle boîte': 'box-sizing',
1100
+ 'modèle boîte': 'box-sizing',
965
1101
  'modele boite': 'box-sizing',
966
1102
  'espace': 'gap',
967
1103
  'espace ligne': 'row-gap',
@@ -970,9 +1106,9 @@ class CSSGenerator {
970
1106
  'espace-colonne': 'column-gap',
971
1107
  'justifier-contenu': 'justify-content',
972
1108
  'justifier contenu': 'justify-content',
973
- 'aligner-éléments': 'align-items',
1109
+ 'aligner-éléments': 'align-items',
974
1110
  'aligner-elements': 'align-items',
975
- 'aligner éléments': 'align-items',
1111
+ 'aligner éléments': 'align-items',
976
1112
  'aligner elements': 'align-items',
977
1113
  'aligner-contenu': 'align-content',
978
1114
  'aligner contenu': 'align-content',
@@ -991,13 +1127,13 @@ class CSSGenerator {
991
1127
  'liste-style': 'list-style',
992
1128
  'liste style': 'list-style',
993
1129
  'contenu': 'content',
994
- 'évènements-pointeur': 'pointer-events',
1130
+ 'évènements-pointeur': 'pointer-events',
995
1131
  'evenements-pointeur': 'pointer-events',
996
- 'évènements pointeur': 'pointer-events',
1132
+ 'évènements pointeur': 'pointer-events',
997
1133
  'evenements pointeur': 'pointer-events',
998
- 'découpe-fond': 'background-clip',
1134
+ 'découpe-fond': 'background-clip',
999
1135
  'decoupe-fond': 'background-clip',
1000
- 'découpe fond': 'background-clip',
1136
+ 'découpe fond': 'background-clip',
1001
1137
  'decoupe fond': 'background-clip',
1002
1138
  'couleur-remplissage-texte': '-webkit-text-fill-color',
1003
1139
  'couleur remplissage texte': '-webkit-text-fill-color',
@@ -1010,12 +1146,13 @@ class CSSGenerator {
1010
1146
  'decoration': 'text-decoration',
1011
1147
  'ombre': 'box-shadow',
1012
1148
  'ecart': 'gap',
1149
+ 'écart': 'gap',
1013
1150
  'direction': 'flex-direction',
1014
1151
  'envelopper': 'flex-wrap',
1015
1152
  'justifier': 'justify-content',
1016
1153
  'aligner': 'align-items',
1017
1154
  'visibilite': 'visibility',
1018
- 'visibilité': 'visibility',
1155
+ 'visibilité': 'visibility',
1019
1156
  'redimensionnement': 'resize',
1020
1157
  'apparence': 'appearance',
1021
1158
  'contour': 'outline'
@@ -1030,31 +1167,31 @@ class CSSGenerator {
1030
1167
 
1031
1168
  result = result.replace(/:racine\b/gi, ':root')
1032
1169
  result = result.replace(/::avant\b/gi, '::before')
1033
- result = result.replace(/::après\b/gi, '::after')
1170
+ result = result.replace(/::après\b/gi, '::after')
1034
1171
  result = result.replace(/::apres\b/gi, '::after')
1035
- result = result.replace(/::première-lettre\b/gi, '::first-letter')
1172
+ result = result.replace(/::première-lettre\b/gi, '::first-letter')
1036
1173
  result = result.replace(/::premiere-lettre\b/gi, '::first-letter')
1037
- result = result.replace(/::première-ligne\b/gi, '::first-line')
1174
+ result = result.replace(/::première-ligne\b/gi, '::first-line')
1038
1175
  result = result.replace(/::premiere-ligne\b/gi, '::first-line')
1039
- result = result.replace(/::sélection\b/gi, '::selection')
1176
+ result = result.replace(/::sélection\b/gi, '::selection')
1040
1177
  result = result.replace(/::selection\b/gi, '::selection')
1041
1178
  result = result.replace(/::marqueur\b/gi, '::marker')
1042
1179
 
1043
1180
  result = result.replace(/\bau survol\b/gi, ':hover')
1044
- result = result.replace(/\bquand survolé\b/gi, ':hover')
1181
+ result = result.replace(/\bquand survolé\b/gi, ':hover')
1045
1182
  result = result.replace(/\bquand survole\b/gi, ':hover')
1046
1183
  result = result.replace(/\ben survol\b/gi, ':hover')
1047
1184
  result = result.replace(/\bau clic\b/gi, ':active')
1048
- result = result.replace(/\bquand cliqué\b/gi, ':active')
1185
+ result = result.replace(/\bquand cliqué\b/gi, ':active')
1049
1186
  result = result.replace(/\bquand clique\b/gi, ':active')
1050
1187
  result = result.replace(/\ben clic\b/gi, ':active')
1051
1188
  result = result.replace(/\bactif\b/gi, ':active')
1052
1189
  result = result.replace(/\bau focus\b/gi, ':focus')
1053
- result = result.replace(/\bquand focalisé\b/gi, ':focus')
1190
+ result = result.replace(/\bquand focalisé\b/gi, ':focus')
1054
1191
  result = result.replace(/\bquand focalise\b/gi, ':focus')
1055
1192
  result = result.replace(/\ben focus\b/gi, ':focus')
1056
1193
  result = result.replace(/\bau focus dans\b/gi, ':focus-within')
1057
- result = result.replace(/\bvisité\b/gi, ':visited')
1194
+ result = result.replace(/\bvisité\b/gi, ':visited')
1058
1195
  result = result.replace(/\bvisite\b/gi, ':visited')
1059
1196
 
1060
1197
  result = result.replace(/\s+(:hover|:active|:focus|:focus-within|:visited|:checked|:disabled|:enabled|:required|:optional|:valid|:invalid|:empty|:target)/gi, '$1')
@@ -1068,18 +1205,18 @@ class CSSGenerator {
1068
1205
  result = result.replace(/\bunique de type\b/gi, ':only-of-type')
1069
1206
  result = result.replace(/\bvide\b/gi, ':empty')
1070
1207
  result = result.replace(/\bcible\b/gi, ':target')
1071
- result = result.replace(/\bcoché\b/gi, ':checked')
1208
+ result = result.replace(/\bcoché\b/gi, ':checked')
1072
1209
  result = result.replace(/\bcoche\b/gi, ':checked')
1073
- result = result.replace(/\bdésactivé\b/gi, ':disabled')
1210
+ result = result.replace(/\bdésactivé\b/gi, ':disabled')
1074
1211
  result = result.replace(/\bdesactive\b/gi, ':disabled')
1075
- result = result.replace(/\bactivé\b/gi, ':enabled')
1212
+ result = result.replace(/\bactivé\b/gi, ':enabled')
1076
1213
  result = result.replace(/\brequis\b/gi, ':required')
1077
1214
  result = result.replace(/\boptionnel\b/gi, ':optional')
1078
1215
  result = result.replace(/\bvalide\b/gi, ':valid')
1079
1216
  result = result.replace(/\binvalide\b/gi, ':invalid')
1080
1217
 
1081
1218
  result = result.replace(/\bcorps\b/gi, 'body')
1082
- result = result.replace(/\btête\b/gi, 'head')
1219
+ result = result.replace(/\btête\b/gi, 'head')
1083
1220
  result = result.replace(/\btete\b/gi, 'head')
1084
1221
  result = result.replace(/\btitre1\b/gi, 'h1')
1085
1222
  result = result.replace(/\btitre2\b/gi, 'h2')
@@ -1094,24 +1231,24 @@ class CSSGenerator {
1094
1231
  result = result.replace(/\bformulaire\b/gi, 'form')
1095
1232
  result = result.replace(/\bchamp\b/gi, 'input')
1096
1233
  result = result.replace(/\bliste\b/gi, 'ul')
1097
- result = result.replace(/\bliste-ordonnée\b/gi, 'ol')
1234
+ result = result.replace(/\bliste-ordonnée\b/gi, 'ol')
1098
1235
  result = result.replace(/\bliste-ordonnee\b/gi, 'ol')
1099
- result = result.replace(/\bélément-liste\b/gi, 'li')
1236
+ result = result.replace(/\bélément-liste\b/gi, 'li')
1100
1237
  result = result.replace(/\belement-liste\b/gi, 'li')
1101
1238
  result = result.replace(/\btableau\b/gi, 'table')
1102
1239
  result = result.replace(/\bligne-tableau\b/gi, 'tr')
1103
1240
  result = result.replace(/\bcellule\b/gi, 'td')
1104
- result = result.replace(/\bentête\b/gi, 'header')
1241
+ result = result.replace(/\bentête\b/gi, 'header')
1105
1242
  result = result.replace(/\bentete\b/gi, 'header')
1106
1243
  result = result.replace(/\bpied\b/gi, 'footer')
1107
1244
  result = result.replace(/\bnavigation\b/gi, 'nav')
1108
1245
  result = result.replace(/\bsection\b/gi, 'section')
1109
1246
  result = result.replace(/\barticle\b/gi, 'article')
1110
- result = result.replace(/\bcôté\b/gi, 'aside')
1247
+ result = result.replace(/\bcôté\b/gi, 'aside')
1111
1248
  result = result.replace(/\bcote\b/gi, 'aside')
1112
1249
  result = result.replace(/\bprincipal\b/gi, 'main')
1113
1250
  result = result.replace(/\bdivision\b/gi, 'div')
1114
- result = result.replace(/\bportée\b/gi, 'span')
1251
+ result = result.replace(/\bportée\b/gi, 'span')
1115
1252
  result = result.replace(/\bportee\b/gi, 'span')
1116
1253
 
1117
1254
  return result
@@ -1370,7 +1507,7 @@ class CSSGenerator {
1370
1507
  translateMediaQuery(query) {
1371
1508
  let result = query
1372
1509
 
1373
- result = result.replace(/écran/gi, 'screen')
1510
+ result = result.replace(cran/gi, 'screen')
1374
1511
  result = result.replace(/ecran/gi, 'screen')
1375
1512
  result = result.replace(/imprimante/gi, 'print')
1376
1513
  result = result.replace(/tous/gi, 'all')
@@ -1402,9 +1539,9 @@ class CSSGenerator {
1402
1539
 
1403
1540
  const plusPetitMatch = condition.match(/plus petit que\s+([\d.]+\w*)/i)
1404
1541
  const plusGrandMatch = condition.match(/plus grand que\s+([\d.]+\w*)/i)
1405
- const inferieurMatch = condition.match(/inférieur[e]?\s+à\s+([\d.]+\w*)/i) || condition.match(/inferieur[e]?\s+a\s+([\d.]+\w*)/i)
1406
- const superieurMatch = condition.match(/supérieur[e]?\s+à\s+([\d.]+\w*)/i) || condition.match(/superieur[e]?\s+a\s+([\d.]+\w*)/i)
1407
- const egalMatch = condition.match(/égal[e]?\s+à\s+([\d.]+\w*)/i) || condition.match(/egal[e]?\s+a\s+([\d.]+\w*)/i)
1542
+ const inferieurMatch = condition.match(/inférieur[e]?\s+a\s+([\d.]+\w*)/i) || condition.match(/inferieur[e]?\s+a\s+([\d.]+\w*)/i)
1543
+ const superieurMatch = condition.match(/supérieur[e]?\s+a\s+([\d.]+\w*)/i) || condition.match(/superieur[e]?\s+a\s+([\d.]+\w*)/i)
1544
+ const egalMatch = condition.match(gal[e]?\s+a\s+([\d.]+\w*)/i) || condition.match(/egal[e]?\s+a\s+([\d.]+\w*)/i)
1408
1545
  const simpleInfMatch = condition.match(/<\s*([\d.]+\w*)/i)
1409
1546
  const simpleSupMatch = condition.match(/>\s*([\d.]+\w*)/i)
1410
1547
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ether-code",
3
- "version": "0.5.5",
3
+ "version": "0.5.6",
4
4
  "description": "Ether - Le langage intentionnel",
5
5
  "main": "cli/compiler.js",
6
6
  "bin": {