fable-editor 1.0.1 → 1.0.2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fable-editor",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "description": "FableEditor — a rich text editor with React and Angular wrappers",
5
5
  "author": "Sajin Satheesan <an.sajinsatheesan@gmail.com>",
6
6
  "repository": {
package/style.css CHANGED
@@ -334,6 +334,148 @@
334
334
  fill: #c92a2a;
335
335
  }
336
336
 
337
+ /* template blocks (image + heading/paragraph layouts) */
338
+ .earea .tpl {
339
+ margin: 0 0 1em;
340
+ }
341
+
342
+ .earea .tpl::after {
343
+ content: "";
344
+ display: block;
345
+ clear: both;
346
+ }
347
+
348
+ .earea .tpl.tpl-selected {
349
+ outline: 2px dashed #a8c7f0;
350
+ outline-offset: 4px;
351
+ }
352
+
353
+ .earea .tpl-media {
354
+ text-align: center;
355
+ margin: 0 0 0.5em;
356
+ }
357
+
358
+ .earea .tpl-media img {
359
+ display: inline-block;
360
+ max-width: 100%;
361
+ }
362
+
363
+ .earea .tpl .img-ph {
364
+ display: inline-flex;
365
+ width: 300px;
366
+ max-width: 100%;
367
+ margin: 0;
368
+ box-sizing: border-box;
369
+ }
370
+
371
+ /* floated media shrink-wraps to the image, so a small image leaves
372
+ the text beside it and the paragraph overflows below it */
373
+ .earea .tpl-img-left .tpl-media {
374
+ float: left;
375
+ max-width: 50%;
376
+ margin: 0 1em 0.5em 0;
377
+ }
378
+
379
+ .earea .tpl-img-right .tpl-media {
380
+ float: right;
381
+ max-width: 50%;
382
+ margin: 0 0 0.5em 1em;
383
+ }
384
+
385
+ .earea .tpl-img-left .img-ph,
386
+ .earea .tpl-img-right .img-ph {
387
+ width: 260px;
388
+ }
389
+
390
+ .earea .tpl-text > :first-child {
391
+ margin-top: 0;
392
+ }
393
+
394
+ /* template picker (popup) — miniature previews of each layout */
395
+ .tplpick {
396
+ display: grid;
397
+ grid-template-columns: 1fr 1fr;
398
+ gap: 8px;
399
+ padding: 8px;
400
+ }
401
+
402
+ .tpltile {
403
+ display: flex;
404
+ flex-direction: column;
405
+ gap: 6px;
406
+ width: 132px;
407
+ padding: 6px;
408
+ border: 1px solid #cfd6df;
409
+ border-radius: 8px;
410
+ background: #fff;
411
+ cursor: pointer;
412
+ font: inherit;
413
+ }
414
+
415
+ .tpltile:hover {
416
+ border-color: #006ce7;
417
+ background: #f2f7ff;
418
+ }
419
+
420
+ .tpllbl {
421
+ font-size: 11px;
422
+ color: #556;
423
+ text-align: center;
424
+ }
425
+
426
+ .pv {
427
+ display: flex;
428
+ flex-direction: column;
429
+ gap: 4px;
430
+ height: 78px;
431
+ padding: 7px;
432
+ background: #f7f9fb;
433
+ border-radius: 5px;
434
+ box-sizing: border-box;
435
+ }
436
+
437
+ .pv-row {
438
+ display: flex;
439
+ gap: 5px;
440
+ flex: 1;
441
+ min-height: 0;
442
+ }
443
+
444
+ .pv-col {
445
+ display: flex;
446
+ flex-direction: column;
447
+ gap: 4px;
448
+ flex: 1;
449
+ }
450
+
451
+ .pv-img {
452
+ background: #c9d4e0;
453
+ border-radius: 3px;
454
+ width: 42%;
455
+ flex: none;
456
+ }
457
+
458
+ .pv-c .pv-img {
459
+ width: 68%;
460
+ height: 32px;
461
+ align-self: center;
462
+ }
463
+
464
+ .pv-h {
465
+ height: 7px;
466
+ width: 55%;
467
+ background: #8fa3b8;
468
+ border-radius: 2px;
469
+ flex: none;
470
+ }
471
+
472
+ .pv-l {
473
+ height: 5px;
474
+ background: #dbe3ec;
475
+ border-radius: 2px;
476
+ flex: none;
477
+ }
478
+
337
479
  .earea table.tbl-selected {
338
480
  outline: 2px solid #006ce7;
339
481
  outline-offset: 1px;