@zipify/wysiwyg 4.1.0-0 → 4.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.
Files changed (32) hide show
  1. package/config/build/settings.js +1 -1
  2. package/config/jest/setupTests.js +3 -0
  3. package/dist/cli.js +2 -3
  4. package/dist/wysiwyg.css +37 -37
  5. package/dist/wysiwyg.mjs +920 -846
  6. package/example/ai-component/AiComponent.vue +16 -50
  7. package/lib/Wysiwyg.vue +9 -17
  8. package/lib/components/base/Modal.vue +19 -18
  9. package/lib/components/base/ModalFloating.vue +32 -0
  10. package/lib/components/base/__tests__/Modal.test.js +2 -19
  11. package/lib/components/base/composables/useModalToggler.js +3 -34
  12. package/lib/components/base/dropdown/Dropdown.vue +7 -6
  13. package/lib/components/base/dropdown/DropdownActivator.vue +4 -5
  14. package/lib/components/base/dropdown/__tests__/DropdownActivator.test.js +1 -1
  15. package/lib/components/base/dropdown/__tests__/DropdownOption.test.js +1 -1
  16. package/lib/components/toolbar/Toolbar.vue +29 -13
  17. package/lib/components/toolbar/ToolbarFloating.vue +42 -0
  18. package/lib/components/toolbar/__tests__/Toolbar.test.js +4 -6
  19. package/lib/components/toolbar/controls/LineHeightControl.vue +9 -7
  20. package/lib/components/toolbar/controls/__tests__/LineHeightControl.test.js +2 -4
  21. package/lib/components/toolbar/controls/link/LinkControl.vue +13 -14
  22. package/lib/components/toolbar/controls/link/destination/LinkControlDestination.vue +1 -1
  23. package/lib/components/toolbar/controls/link/destination/LinkControlPageBlock.vue +1 -1
  24. package/lib/composables/__tests__/useEditor.test.js +26 -5
  25. package/lib/composables/index.js +0 -1
  26. package/lib/composables/useEditor.js +7 -2
  27. package/lib/styles/content.css +0 -1
  28. package/package.json +50 -51
  29. package/lib/components/base/composables/__tests__/useModalToggler.test.js +0 -59
  30. package/lib/composables/useToolbar.js +0 -36
  31. /package/config/build/{example.config.js → example.config.mjs} +0 -0
  32. /package/config/build/{lib.config.js → lib.config.mjs} +0 -0
package/dist/wysiwyg.css CHANGED
@@ -345,37 +345,37 @@
345
345
  display: none;
346
346
  }
347
347
 
348
- .zw-modal[data-v-5be0e050] {
348
+ .zw-modal[data-v-078bbe11] {
349
349
  border-radius: 2px;
350
350
  box-shadow: 0 0 4px rgba(var(--zw-color-black), 0.3);
351
351
  background-color: rgb(var(--zw-color-n15));
352
- max-height: var(--zw-modal-max-height);
353
- max-width: var(--zw-modal-max-width);
352
+ max-height: var(--3cdf9de8);
353
+ max-width: var(--8ae6b87e);
354
354
  z-index: 1000;
355
355
  position: fixed;
356
356
  will-change: transform;
357
357
  }
358
- .zw-modal--enter-active[data-v-5be0e050] {
358
+ .zw-modal--enter-active[data-v-078bbe11] {
359
359
  transition: opacity 0.15s ease-out;
360
360
  }
361
- .zw-modal--enter-from[data-v-5be0e050],
362
- .zw-modal--leave-to[data-v-5be0e050] {
361
+ .zw-modal--enter-from[data-v-078bbe11],
362
+ .zw-modal--leave-to[data-v-078bbe11] {
363
363
  opacity: 0;
364
364
  }
365
- .zw-modal--leave-active[data-v-5be0e050] {
365
+ .zw-modal--leave-active[data-v-078bbe11] {
366
366
  transition: opacity 0.1s ease-in;
367
367
  }
368
368
 
369
369
  /* Scrollbar overrides in modal */
370
- .zw-modal[data-v-5be0e050] .simplebar-offset,
371
- .zw-modal[data-v-5be0e050] .simplebar-mask {
370
+ .zw-modal[data-v-078bbe11] .simplebar-offset,
371
+ .zw-modal[data-v-078bbe11] .simplebar-mask {
372
372
  position: initial;
373
373
  }
374
- .zw-modal[data-v-5be0e050] .simplebar-content {
374
+ .zw-modal[data-v-078bbe11] .simplebar-content {
375
375
  max-height: var(--zw-modal-max-height);
376
376
  padding: 0 !important;
377
377
  }
378
- .zw-modal[data-v-5be0e050] .simplebar-content-wrapper {
378
+ .zw-modal[data-v-078bbe11] .simplebar-content-wrapper {
379
379
  overscroll-behavior: contain;
380
380
  }
381
381
 
@@ -465,24 +465,24 @@
465
465
  font-size: var(--zw-font-size-xs);
466
466
  }
467
467
 
468
- .zw-dropdown__activator[data-v-c73e0119] {
468
+ .zw-dropdown__activator[data-v-678de368] {
469
469
  width: 100%;
470
470
  }
471
- .zw-dropdown__activator-title[data-v-c73e0119] {
471
+ .zw-dropdown__activator-title[data-v-678de368] {
472
472
  margin-right: var(--zw-offset-xxs);
473
473
  }
474
- .zw-dropdown__activator-arrow[data-v-c73e0119] {
474
+ .zw-dropdown__activator-arrow[data-v-678de368] {
475
475
  margin-left: auto;
476
476
  }
477
- .zw-dropdown__activator--active .zw-dropdown__activator-arrow[data-v-c73e0119] {
477
+ .zw-dropdown__activator--active .zw-dropdown__activator-arrow[data-v-678de368] {
478
478
  transform: rotateX(180deg);
479
479
  }
480
- .zw-dropdown__activator--gray[data-v-c73e0119] {
480
+ .zw-dropdown__activator--gray[data-v-678de368] {
481
481
  background-color: rgb(var(--zw-color-n20));
482
482
  font-size: var(--zw-font-size-xxs);
483
483
  color: rgb(var(--zw-color-white));
484
484
  }
485
- .zw-dropdown__customized-indicator[data-v-c73e0119] {
485
+ .zw-dropdown__customized-indicator[data-v-678de368] {
486
486
  position: relative;
487
487
  top: calc(0px - var(--zw-offset-xs));
488
488
  min-width: 4px;
@@ -537,7 +537,7 @@
537
537
  padding-bottom: var(--zw-offset-xs);
538
538
  }
539
539
 
540
- .zw-dropdown[data-v-c59753d1] {
540
+ .zw-dropdown[data-v-0d65726d] {
541
541
  position: relative;
542
542
  font-size: var(--zw-font-size-xs);
543
543
  line-height: var(--zw-line-height-xxs);
@@ -559,17 +559,17 @@
559
559
  width: 72px;
560
560
  }
561
561
 
562
- .zw-line-height-control__modal[data-v-74a13b9d] {
562
+ .zw-line-height-control__modal[data-v-8eb86211] {
563
563
  padding: var(--zw-offset-sm);
564
564
  }
565
- .zw-line-height-control__row[data-v-74a13b9d] {
565
+ .zw-line-height-control__row[data-v-8eb86211] {
566
566
  display: flex;
567
567
  align-items: center;
568
568
  }
569
- .zw-line-height-control__range[data-v-74a13b9d] {
569
+ .zw-line-height-control__range[data-v-8eb86211] {
570
570
  width: 156px;
571
571
  }
572
- .zw-line-height-control__field[data-v-74a13b9d] {
572
+ .zw-line-height-control__field[data-v-8eb86211] {
573
573
  width: 64px;
574
574
  margin-left: var(--zw-offset-sm);
575
575
  }
@@ -620,17 +620,17 @@
620
620
  color: rgb(var(--zw-color-white));
621
621
  }
622
622
 
623
- .zw-link-modal[data-v-c3983e26] {
623
+ .zw-link-modal[data-v-5d6cf980] {
624
624
  width: 266px;
625
625
  }
626
- .zw-link-modal__body[data-v-c3983e26] {
626
+ .zw-link-modal__body[data-v-5d6cf980] {
627
627
  padding: var(--zw-offset-sm);
628
628
  }
629
- .zw-link-modal__actions[data-v-c3983e26] {
629
+ .zw-link-modal__actions[data-v-5d6cf980] {
630
630
  display: flex;
631
631
  justify-content: flex-end;
632
632
  }
633
- [data-v-c3983e26] .zw-link-modal-dropdown__option {
633
+ [data-v-5d6cf980] .zw-link-modal-dropdown__option {
634
634
  width: 234px;
635
635
  }
636
636
 
@@ -682,7 +682,7 @@
682
682
  background-color: rgb(var(--zw-color-n30));
683
683
  }
684
684
 
685
- .zw-toolbar[data-v-d3e5d777] {
685
+ .zw-toolbar[data-v-39370f99] {
686
686
  border: 1px solid rgba(var(--zw-color-white), 0.2);
687
687
  border-radius: 2px;
688
688
  background-color: rgba(var(--zw-color-n15), 0.9);
@@ -692,10 +692,10 @@
692
692
  z-index: 999999;
693
693
  text-align: left;
694
694
  position: fixed;
695
- --zw-toolbar-offset-y: calc(var(--c6eda43c) * 1px)
695
+ --zw-toolbar-offset-y: calc(var(--0f007386) * 1px)
696
696
  }
697
- .zw-toolbar[data-v-d3e5d777]::before,
698
- .zw-toolbar[data-v-d3e5d777]::after {
697
+ .zw-toolbar[data-v-39370f99]::before,
698
+ .zw-toolbar[data-v-39370f99]::after {
699
699
  content: "";
700
700
  display: block;
701
701
  width: 100%;
@@ -703,21 +703,21 @@
703
703
  position: absolute;
704
704
  --zw-toolbar-safe-zone: calc(-1 * var(--zw-toolbar-offset-y));
705
705
  }
706
- .zw-toolbar[data-v-d3e5d777]::before {
706
+ .zw-toolbar[data-v-39370f99]::before {
707
707
  top: var(--zw-toolbar-safe-zone);
708
708
  }
709
- .zw-toolbar[data-v-d3e5d777]::after {
709
+ .zw-toolbar[data-v-39370f99]::after {
710
710
  bottom: var(--zw-toolbar-safe-zone);
711
711
  }
712
- .zw-toolbar--enter-active[data-v-d3e5d777],
713
- .zw-toolbar--leave-active[data-v-d3e5d777] {
712
+ .zw-toolbar--enter-active[data-v-39370f99],
713
+ .zw-toolbar--leave-active[data-v-39370f99] {
714
714
  transition: opacity 150ms ease-out;
715
715
  }
716
- .zw-toolbar--leave-active[data-v-d3e5d777] {
716
+ .zw-toolbar--leave-active[data-v-39370f99] {
717
717
  transition: opacity 0s ease-in;
718
718
  }
719
- .zw-toolbar--enter-from[data-v-d3e5d777],
720
- .zw-toolbar--leave-to[data-v-d3e5d777] {
719
+ .zw-toolbar--enter-from[data-v-39370f99],
720
+ .zw-toolbar--leave-to[data-v-39370f99] {
721
721
  opacity: 0;
722
722
  }
723
723
  .zw-wysiwyg {