@yoamigo.com/core 0.1.1 → 0.1.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/dist/index.js +263 -0
- package/package.json +2 -3
- package/dist/index.css +0 -715
package/dist/index.js
CHANGED
|
@@ -503,6 +503,256 @@ function SafeHtml({ content, className, mode = "read-only" }) {
|
|
|
503
503
|
] });
|
|
504
504
|
}
|
|
505
505
|
|
|
506
|
+
// #style-inject:#style-inject
|
|
507
|
+
function styleInject(css, { insertAt } = {}) {
|
|
508
|
+
if (!css || typeof document === "undefined") return;
|
|
509
|
+
const head = document.head || document.getElementsByTagName("head")[0];
|
|
510
|
+
const style = document.createElement("style");
|
|
511
|
+
style.type = "text/css";
|
|
512
|
+
if (insertAt === "top") {
|
|
513
|
+
if (head.firstChild) {
|
|
514
|
+
head.insertBefore(style, head.firstChild);
|
|
515
|
+
} else {
|
|
516
|
+
head.appendChild(style);
|
|
517
|
+
}
|
|
518
|
+
} else {
|
|
519
|
+
head.appendChild(style);
|
|
520
|
+
}
|
|
521
|
+
if (style.styleSheet) {
|
|
522
|
+
style.styleSheet.cssText = css;
|
|
523
|
+
} else {
|
|
524
|
+
style.appendChild(document.createTextNode(css));
|
|
525
|
+
}
|
|
526
|
+
}
|
|
527
|
+
|
|
528
|
+
// src/components/ya-text.css
|
|
529
|
+
styleInject(`.ya-text-editable {
|
|
530
|
+
cursor: text;
|
|
531
|
+
transition: outline 0.15s ease;
|
|
532
|
+
}
|
|
533
|
+
.ya-text-editable:hover {
|
|
534
|
+
outline: 2px dashed var(--color-primary, #D4A574);
|
|
535
|
+
outline-offset: 4px;
|
|
536
|
+
border-radius: 4px;
|
|
537
|
+
}
|
|
538
|
+
body.builder-selector-active .ya-text-editable:hover {
|
|
539
|
+
outline: none;
|
|
540
|
+
cursor: inherit;
|
|
541
|
+
}
|
|
542
|
+
.ya-text-editing {
|
|
543
|
+
outline: 2px solid var(--color-primary, #D4A574);
|
|
544
|
+
outline-offset: 4px;
|
|
545
|
+
border-radius: 4px;
|
|
546
|
+
position: relative;
|
|
547
|
+
}
|
|
548
|
+
.ya-bubble-menu {
|
|
549
|
+
display: flex;
|
|
550
|
+
gap: 4px;
|
|
551
|
+
padding: 6px 8px;
|
|
552
|
+
background: #1a1a1a;
|
|
553
|
+
border-radius: 8px;
|
|
554
|
+
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
|
|
555
|
+
animation: ya-bubble-fade-in 0.15s ease;
|
|
556
|
+
font-family:
|
|
557
|
+
system-ui,
|
|
558
|
+
-apple-system,
|
|
559
|
+
BlinkMacSystemFont,
|
|
560
|
+
"Segoe UI",
|
|
561
|
+
sans-serif;
|
|
562
|
+
}
|
|
563
|
+
@keyframes ya-bubble-fade-in {
|
|
564
|
+
from {
|
|
565
|
+
opacity: 0;
|
|
566
|
+
transform: translateY(4px);
|
|
567
|
+
}
|
|
568
|
+
to {
|
|
569
|
+
opacity: 1;
|
|
570
|
+
transform: translateY(0);
|
|
571
|
+
}
|
|
572
|
+
}
|
|
573
|
+
.ya-bubble-btn {
|
|
574
|
+
display: flex;
|
|
575
|
+
align-items: center;
|
|
576
|
+
justify-content: center;
|
|
577
|
+
width: 32px;
|
|
578
|
+
height: 32px;
|
|
579
|
+
padding: 0;
|
|
580
|
+
border: none;
|
|
581
|
+
background: transparent;
|
|
582
|
+
color: #e0e0e0;
|
|
583
|
+
border-radius: 6px;
|
|
584
|
+
cursor: pointer;
|
|
585
|
+
transition: all 0.15s ease;
|
|
586
|
+
font-size: 14px;
|
|
587
|
+
}
|
|
588
|
+
.ya-bubble-btn:hover {
|
|
589
|
+
background: rgba(255, 255, 255, 0.1);
|
|
590
|
+
color: #ffffff;
|
|
591
|
+
}
|
|
592
|
+
.ya-bubble-btn.is-active {
|
|
593
|
+
background: var(--color-primary, #D4A574);
|
|
594
|
+
color: #1a1a1a;
|
|
595
|
+
}
|
|
596
|
+
.ya-bubble-btn.is-active:hover {
|
|
597
|
+
background: var(--color-primary, #D4A574);
|
|
598
|
+
filter: brightness(1.1);
|
|
599
|
+
}
|
|
600
|
+
.ya-bubble-divider {
|
|
601
|
+
width: 1px;
|
|
602
|
+
height: 20px;
|
|
603
|
+
background: rgba(255, 255, 255, 0.2);
|
|
604
|
+
margin: 6px 4px;
|
|
605
|
+
}
|
|
606
|
+
.ya-bubble-select {
|
|
607
|
+
appearance: none;
|
|
608
|
+
background: transparent;
|
|
609
|
+
color: #e0e0e0;
|
|
610
|
+
border: 1px solid rgba(255, 255, 255, 0.2);
|
|
611
|
+
border-radius: 6px;
|
|
612
|
+
padding: 6px 24px 6px 10px;
|
|
613
|
+
font-size: 12px;
|
|
614
|
+
cursor: pointer;
|
|
615
|
+
transition: all 0.15s ease;
|
|
616
|
+
min-width: 70px;
|
|
617
|
+
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23e0e0e0' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
|
|
618
|
+
background-repeat: no-repeat;
|
|
619
|
+
background-position: right 6px center;
|
|
620
|
+
}
|
|
621
|
+
.ya-bubble-select:hover {
|
|
622
|
+
border-color: rgba(255, 255, 255, 0.4);
|
|
623
|
+
background-color: rgba(255, 255, 255, 0.05);
|
|
624
|
+
}
|
|
625
|
+
.ya-bubble-select:focus {
|
|
626
|
+
outline: none;
|
|
627
|
+
border-color: var(--color-primary, #D4A574);
|
|
628
|
+
}
|
|
629
|
+
.ya-bubble-select option {
|
|
630
|
+
background: #1a1a1a;
|
|
631
|
+
color: #e0e0e0;
|
|
632
|
+
padding: 8px;
|
|
633
|
+
}
|
|
634
|
+
.ProseMirror {
|
|
635
|
+
outline: none;
|
|
636
|
+
}
|
|
637
|
+
.ProseMirror p {
|
|
638
|
+
margin: 0;
|
|
639
|
+
}
|
|
640
|
+
.ProseMirror a {
|
|
641
|
+
color: var(--color-primary, #D4A574);
|
|
642
|
+
text-decoration: underline;
|
|
643
|
+
}
|
|
644
|
+
.ProseMirror a:hover {
|
|
645
|
+
color: var(--color-secondary, #5C4033);
|
|
646
|
+
}
|
|
647
|
+
.ProseMirror ::selection {
|
|
648
|
+
background: rgba(212, 165, 116, 0.3);
|
|
649
|
+
}
|
|
650
|
+
.ProseMirror p.is-editor-empty:first-child::before {
|
|
651
|
+
content: attr(data-placeholder);
|
|
652
|
+
float: left;
|
|
653
|
+
color: #adb5bd;
|
|
654
|
+
pointer-events: none;
|
|
655
|
+
height: 0;
|
|
656
|
+
}
|
|
657
|
+
.ya-text-actions {
|
|
658
|
+
display: flex;
|
|
659
|
+
gap: 8px;
|
|
660
|
+
position: absolute;
|
|
661
|
+
bottom: -48px;
|
|
662
|
+
right: 0;
|
|
663
|
+
z-index: 10;
|
|
664
|
+
background: rgba(26, 26, 26, 0.8);
|
|
665
|
+
padding: 8px 10px;
|
|
666
|
+
border-radius: 8px;
|
|
667
|
+
font-family:
|
|
668
|
+
system-ui,
|
|
669
|
+
-apple-system,
|
|
670
|
+
BlinkMacSystemFont,
|
|
671
|
+
"Segoe UI",
|
|
672
|
+
sans-serif;
|
|
673
|
+
}
|
|
674
|
+
.ya-text-btn {
|
|
675
|
+
padding: 6px 14px;
|
|
676
|
+
font-size: 12px;
|
|
677
|
+
font-weight: 500;
|
|
678
|
+
border-radius: 6px;
|
|
679
|
+
cursor: pointer;
|
|
680
|
+
transition: all 0.15s ease;
|
|
681
|
+
border: none;
|
|
682
|
+
}
|
|
683
|
+
.ya-text-btn-cancel {
|
|
684
|
+
background: #333333;
|
|
685
|
+
color: #ffffff;
|
|
686
|
+
border: 1px solid #555555;
|
|
687
|
+
}
|
|
688
|
+
.ya-text-btn-cancel:hover {
|
|
689
|
+
background: #444444;
|
|
690
|
+
color: #ffffff;
|
|
691
|
+
border-color: #666666;
|
|
692
|
+
}
|
|
693
|
+
.ya-text-btn-save {
|
|
694
|
+
background: #D4A574;
|
|
695
|
+
color: #1a1a1a;
|
|
696
|
+
}
|
|
697
|
+
.ya-text-btn-save:hover {
|
|
698
|
+
background: #c4956a;
|
|
699
|
+
}
|
|
700
|
+
.ya-link-popover {
|
|
701
|
+
position: fixed;
|
|
702
|
+
z-index: 9999;
|
|
703
|
+
display: flex;
|
|
704
|
+
align-items: center;
|
|
705
|
+
gap: 6px;
|
|
706
|
+
padding: 8px 12px;
|
|
707
|
+
background: #1a1a1a;
|
|
708
|
+
color: #e0e0e0;
|
|
709
|
+
border-radius: 8px;
|
|
710
|
+
font-size: 13px;
|
|
711
|
+
font-weight: 500;
|
|
712
|
+
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
|
|
713
|
+
cursor: pointer;
|
|
714
|
+
white-space: nowrap;
|
|
715
|
+
transform: translateX(-50%);
|
|
716
|
+
pointer-events: auto;
|
|
717
|
+
animation: ya-link-popover-fade-in 0.1s ease;
|
|
718
|
+
}
|
|
719
|
+
.ya-link-popover:hover {
|
|
720
|
+
background: #2a2a2a;
|
|
721
|
+
}
|
|
722
|
+
@keyframes ya-link-popover-fade-in {
|
|
723
|
+
from {
|
|
724
|
+
opacity: 0;
|
|
725
|
+
transform: translateX(-50%) translateY(-4px);
|
|
726
|
+
}
|
|
727
|
+
to {
|
|
728
|
+
opacity: 1;
|
|
729
|
+
transform: translateX(-50%) translateY(0);
|
|
730
|
+
}
|
|
731
|
+
}
|
|
732
|
+
.ya-link-popover::before {
|
|
733
|
+
content: "";
|
|
734
|
+
position: absolute;
|
|
735
|
+
top: -6px;
|
|
736
|
+
left: 50%;
|
|
737
|
+
transform: translateX(-50%);
|
|
738
|
+
border-left: 6px solid transparent;
|
|
739
|
+
border-right: 6px solid transparent;
|
|
740
|
+
border-bottom: 6px solid #1a1a1a;
|
|
741
|
+
}
|
|
742
|
+
.ya-link-popover-icon {
|
|
743
|
+
width: 14px;
|
|
744
|
+
height: 14px;
|
|
745
|
+
opacity: 0.8;
|
|
746
|
+
flex-shrink: 0;
|
|
747
|
+
}
|
|
748
|
+
.ya-link-popover-prefix {
|
|
749
|
+
opacity: 0.7;
|
|
750
|
+
}
|
|
751
|
+
.ya-link-popover-name {
|
|
752
|
+
color: var(--color-primary, #D4A574);
|
|
753
|
+
}
|
|
754
|
+
`);
|
|
755
|
+
|
|
506
756
|
// src/components/YaText.tsx
|
|
507
757
|
import { Fragment as Fragment2, jsx as jsx4, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
508
758
|
var FontSize = Extension.create({
|
|
@@ -907,6 +1157,11 @@ function resolveAssetUrl(path) {
|
|
|
907
1157
|
// src/components/YaTooltip.tsx
|
|
908
1158
|
import { useEffect as useEffect4, useRef as useRef4, useState as useState4, useCallback as useCallback4 } from "react";
|
|
909
1159
|
import { createPortal as createPortal3 } from "react-dom";
|
|
1160
|
+
|
|
1161
|
+
// src/components/ya-tooltip.css
|
|
1162
|
+
styleInject('.ya-tooltip {\n position: fixed;\n z-index: 9999;\n display: flex;\n align-items: center;\n gap: 6px;\n padding: 8px 12px;\n background: #1a1a1a;\n color: white;\n border-radius: 6px;\n font-size: 13px;\n font-weight: 500;\n font-family:\n system-ui,\n -apple-system,\n BlinkMacSystemFont,\n "Segoe UI",\n sans-serif;\n white-space: nowrap;\n box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);\n animation: ya-tooltip-fade-in 0.15s ease;\n pointer-events: none;\n}\n@keyframes ya-tooltip-fade-in {\n from {\n opacity: 0;\n transform: scale(0.95);\n }\n to {\n opacity: 1;\n transform: scale(1);\n }\n}\n.ya-tooltip svg {\n width: 16px;\n height: 16px;\n flex-shrink: 0;\n}\n.ya-tooltip-bottom {\n transform: translateX(-50%);\n}\n.ya-tooltip-bottom::before {\n content: "";\n position: absolute;\n bottom: 100%;\n left: 50%;\n transform: translateX(-50%);\n border: 6px solid transparent;\n border-bottom-color: #1a1a1a;\n}\n.ya-tooltip-top {\n transform: translateX(-50%);\n}\n.ya-tooltip-top::before {\n content: "";\n position: absolute;\n top: 100%;\n left: 50%;\n transform: translateX(-50%);\n border: 6px solid transparent;\n border-top-color: #1a1a1a;\n}\n.ya-tooltip-right {\n transform: translateY(-50%);\n}\n.ya-tooltip-right::before {\n content: "";\n position: absolute;\n right: 100%;\n top: 50%;\n transform: translateY(-50%);\n border: 6px solid transparent;\n border-right-color: #1a1a1a;\n}\n.ya-tooltip-left {\n transform: translateY(-50%);\n}\n.ya-tooltip-left::before {\n content: "";\n position: absolute;\n left: 100%;\n top: 50%;\n transform: translateY(-50%);\n border: 6px solid transparent;\n border-left-color: #1a1a1a;\n}\n');
|
|
1163
|
+
|
|
1164
|
+
// src/components/YaTooltip.tsx
|
|
910
1165
|
import { jsx as jsx5 } from "react/jsx-runtime";
|
|
911
1166
|
function YaTooltip({
|
|
912
1167
|
anchorRef,
|
|
@@ -1032,6 +1287,9 @@ function YaTooltip({
|
|
|
1032
1287
|
);
|
|
1033
1288
|
}
|
|
1034
1289
|
|
|
1290
|
+
// src/components/ya-image.css
|
|
1291
|
+
styleInject('.ya-image-container {\n position: relative;\n display: inline-block;\n min-width: 45px;\n min-height: 45px;\n cursor: pointer;\n transition: outline 0.15s ease;\n}\n.ya-image-container img {\n display: block;\n}\n.ya-image-editable {\n cursor: pointer;\n}\n.ya-image-editable:hover {\n outline: 2px dashed var(--color-primary, #D4A574);\n outline-offset: 4px;\n}\n.ya-image-selected {\n outline: 3px solid var(--color-primary, #D4A574);\n outline-offset: 4px;\n}\n.ya-image-overlay {\n position: absolute;\n inset: 0;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: 8px;\n background: rgba(0, 0, 0, 0.5);\n opacity: 0;\n transition: opacity 0.2s ease;\n pointer-events: none;\n border-radius: inherit;\n}\n.ya-image-editable:hover .ya-image-overlay {\n opacity: 1;\n}\n.ya-image-selected .ya-image-overlay {\n opacity: 0;\n}\n.ya-image-edit-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 48px;\n height: 48px;\n background: white;\n border-radius: 50%;\n color: #1a1a1a;\n box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);\n}\n.ya-image-edit-icon svg {\n width: 24px;\n height: 24px;\n}\n.ya-image-edit-label {\n color: white;\n font-size: 14px;\n font-weight: 500;\n text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);\n}\n@keyframes ya-image-success {\n 0% {\n outline-color: var(--color-primary, #D4A574);\n }\n 50% {\n outline-color: #22c55e;\n outline-width: 4px;\n }\n 100% {\n outline-color: var(--color-primary, #D4A574);\n outline-width: 2px;\n }\n}\n.ya-image-success {\n animation: ya-image-success 0.4s ease;\n}\n.ya-image-loading::after {\n content: "";\n position: absolute;\n inset: 0;\n background:\n linear-gradient(\n 90deg,\n rgba(255, 255, 255, 0) 0%,\n rgba(255, 255, 255, 0.3) 50%,\n rgba(255, 255, 255, 0) 100%);\n background-size: 200% 100%;\n animation: ya-image-shimmer 1.5s infinite;\n}\n@keyframes ya-image-shimmer {\n 0% {\n background-position: -200% 0;\n }\n 100% {\n background-position: 200% 0;\n }\n}\n.ya-image-container:focus {\n outline: 3px solid var(--color-primary, #D4A574);\n outline-offset: 4px;\n}\n.ya-image-container:focus:not(:focus-visible) {\n outline: none;\n}\n.ya-image-container:focus-visible {\n outline: 3px solid var(--color-primary, #D4A574);\n outline-offset: 4px;\n}\n.ya-image-small .ya-image-overlay {\n display: none;\n}\n');
|
|
1292
|
+
|
|
1035
1293
|
// src/components/YaImage.tsx
|
|
1036
1294
|
import { jsx as jsx6, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
1037
1295
|
function parseImageValue(value) {
|
|
@@ -1272,6 +1530,11 @@ import StarterKit2 from "@tiptap/starter-kit";
|
|
|
1272
1530
|
import { TextStyle as TextStyle2 } from "@tiptap/extension-text-style";
|
|
1273
1531
|
import { Extension as Extension2 } from "@tiptap/core";
|
|
1274
1532
|
import { Link as WouterLink, useLocation } from "wouter";
|
|
1533
|
+
|
|
1534
|
+
// src/components/ya-link.css
|
|
1535
|
+
styleInject('.ya-link-wrapper {\n position: relative;\n display: inline;\n}\n.ya-link-editable {\n cursor: pointer;\n transition: outline 0.15s ease;\n}\n.ya-link-editable:hover {\n outline: 2px dashed var(--color-primary, #D4A574);\n outline-offset: 4px;\n border-radius: 4px;\n}\nbody.builder-selector-active .ya-link-editable:hover {\n outline: none;\n cursor: inherit;\n}\n.ya-link-editing {\n outline: 2px solid var(--color-primary, #D4A574);\n outline-offset: 4px;\n border-radius: 4px;\n position: relative;\n}\n.ya-link-actions {\n display: flex;\n gap: 8px;\n position: absolute;\n bottom: -60px;\n right: 0;\n z-index: 10;\n background: rgba(26, 26, 26, 0.95);\n padding: 8px 10px;\n border-radius: 8px;\n box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);\n font-family:\n system-ui,\n -apple-system,\n BlinkMacSystemFont,\n "Segoe UI",\n sans-serif;\n}\n.ya-link-btn {\n padding: 6px 14px;\n font-size: 12px;\n font-weight: 500;\n border-radius: 6px;\n cursor: pointer;\n transition: all 0.15s ease;\n border: none;\n}\n.ya-link-btn-cancel {\n background: #333333;\n color: #ffffff;\n border: 1px solid #555555;\n}\n.ya-link-btn-cancel:hover {\n background: #444444;\n color: #ffffff;\n border-color: #666666;\n}\n.ya-link-btn-save {\n background: #D4A574;\n color: #1a1a1a;\n}\n.ya-link-btn-save:hover {\n background: #c4956a;\n}\n.ya-href-popover {\n position: absolute;\n top: 100%;\n left: 50%;\n margin-top: 8px;\n z-index: 10;\n min-width: 280px;\n max-width: 320px;\n background: #1a1a1a;\n border-radius: 12px;\n box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);\n transform: translateX(-50%);\n animation: ya-href-popover-fade-in 0.15s ease;\n overflow: hidden;\n font-family:\n system-ui,\n -apple-system,\n BlinkMacSystemFont,\n "Segoe UI",\n sans-serif;\n}\n@keyframes ya-href-popover-fade-in {\n from {\n opacity: 0;\n transform: translateX(-50%) translateY(-8px);\n }\n to {\n opacity: 1;\n transform: translateX(-50%) translateY(0);\n }\n}\n.ya-href-popover::before {\n content: "";\n position: absolute;\n top: -6px;\n left: 50%;\n transform: translateX(-50%);\n border-left: 8px solid transparent;\n border-right: 8px solid transparent;\n border-bottom: 8px solid #1a1a1a;\n}\n.ya-href-popover-header {\n padding: 12px 16px;\n font-size: 13px;\n font-weight: 600;\n color: #ffffff;\n border-bottom: 1px solid rgba(255, 255, 255, 0.1);\n}\n.ya-href-popover-section {\n padding: 12px 16px;\n}\n.ya-href-popover-label {\n display: block;\n font-size: 11px;\n font-weight: 500;\n color: rgba(255, 255, 255, 0.6);\n text-transform: uppercase;\n letter-spacing: 0.5px;\n margin-bottom: 8px;\n}\n.ya-href-collapsible-header {\n display: flex;\n align-items: center;\n gap: 6px;\n width: 100%;\n padding: 0;\n background: transparent;\n border: none;\n cursor: pointer;\n transition: color 0.15s ease;\n}\n.ya-href-collapsible-header:hover {\n color: rgba(255, 255, 255, 0.8);\n}\n.ya-href-chevron {\n font-size: 8px;\n color: rgba(255, 255, 255, 0.4);\n}\n.ya-href-popover-pages {\n display: flex;\n flex-direction: column;\n gap: 4px;\n max-height: 200px;\n overflow-y: auto;\n}\n.ya-href-page-btn {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n gap: 4px;\n width: 100%;\n padding: 10px 12px;\n background: rgba(255, 255, 255, 0.05);\n border: 1px solid transparent;\n border-radius: 8px;\n color: #e0e0e0;\n font-size: 13px;\n font-weight: 500;\n text-align: left;\n cursor: pointer;\n transition: all 0.15s ease;\n}\n.ya-href-page-btn:hover {\n background: rgba(255, 255, 255, 0.1);\n border-color: rgba(255, 255, 255, 0.2);\n}\n.ya-href-page-btn.is-selected {\n background: #D4A574;\n color: #1a1a1a;\n}\n.ya-href-page-btn.is-selected .ya-href-page-path {\n color: rgba(26, 26, 26, 0.6);\n}\n.ya-href-page-path {\n font-size: 11px;\n color: rgba(255, 255, 255, 0.4);\n font-family: monospace;\n word-break: break-all;\n}\n.ya-href-external-toggle {\n display: block;\n width: 100%;\n padding: 10px 16px;\n background: transparent;\n border: none;\n border-top: 1px solid rgba(255, 255, 255, 0.1);\n color: #D4A574;\n font-size: 12px;\n font-weight: 500;\n text-align: center;\n cursor: pointer;\n transition: background 0.15s ease;\n}\n.ya-href-external-toggle:hover {\n background: rgba(255, 255, 255, 0.05);\n}\n.ya-href-url-input {\n width: 100%;\n padding: 10px 12px;\n background: rgba(255, 255, 255, 0.05);\n border: 1px solid rgba(255, 255, 255, 0.2);\n border-radius: 8px;\n color: #ffffff;\n font-size: 13px;\n outline: none;\n transition: border-color 0.15s ease;\n}\n.ya-href-url-input::placeholder {\n color: rgba(255, 255, 255, 0.4);\n}\n.ya-href-url-input:focus {\n border-color: var(--color-primary, #D4A574);\n}\n.ya-href-popover-actions {\n display: flex;\n justify-content: flex-end;\n gap: 8px;\n padding: 12px 16px;\n border-top: 1px solid rgba(255, 255, 255, 0.1);\n}\n.ya-link-edit-popover {\n position: absolute;\n top: 100%;\n left: 50%;\n margin-top: 8px;\n z-index: 10;\n background: #2a2a2a;\n border-radius: 6px;\n padding: 4px;\n display: flex;\n gap: 4px;\n box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);\n transform: translateX(-50%);\n animation: ya-edit-popover-fade-in 0.1s ease;\n font-family:\n system-ui,\n -apple-system,\n BlinkMacSystemFont,\n "Segoe UI",\n sans-serif;\n white-space: nowrap;\n}\n@keyframes ya-edit-popover-fade-in {\n from {\n opacity: 0;\n transform: translateX(-50%) translateY(-4px);\n }\n to {\n opacity: 1;\n transform: translateX(-50%) translateY(0);\n }\n}\n.ya-link-edit-popover::before {\n content: "";\n position: absolute;\n top: -5px;\n left: 50%;\n transform: translateX(-50%);\n border-left: 6px solid transparent;\n border-right: 6px solid transparent;\n border-bottom: 6px solid #2a2a2a;\n}\n.ya-link-edit-popover button {\n background: #3a3a3a;\n border: none;\n color: #fff;\n padding: 6px 12px;\n border-radius: 4px;\n cursor: pointer;\n font-size: 13px;\n font-weight: 500;\n transition: background 0.15s ease;\n}\n.ya-link-edit-popover button:hover {\n background: #4a4a4a;\n}\n');
|
|
1536
|
+
|
|
1537
|
+
// src/components/YaLink.tsx
|
|
1275
1538
|
import { Fragment as Fragment3, jsx as jsx7, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
1276
1539
|
function isInternalPath(path) {
|
|
1277
1540
|
if (!path) return false;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yoamigo.com/core",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2",
|
|
4
4
|
"description": "Core components, router, and utilities for YoAmigo templates",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE",
|
|
@@ -30,8 +30,7 @@
|
|
|
30
30
|
"./lib/prod": {
|
|
31
31
|
"types": "./dist/lib-prod.d.ts",
|
|
32
32
|
"import": "./dist/lib-prod.js"
|
|
33
|
-
}
|
|
34
|
-
"./styles.css": "./dist/index.css"
|
|
33
|
+
}
|
|
35
34
|
},
|
|
36
35
|
"files": [
|
|
37
36
|
"dist",
|
package/dist/index.css
DELETED
|
@@ -1,715 +0,0 @@
|
|
|
1
|
-
/* src/components/ya-text.css */
|
|
2
|
-
.ya-text-editable {
|
|
3
|
-
cursor: text;
|
|
4
|
-
transition: outline 0.15s ease;
|
|
5
|
-
}
|
|
6
|
-
.ya-text-editable:hover {
|
|
7
|
-
outline: 2px dashed var(--color-primary, #D4A574);
|
|
8
|
-
outline-offset: 4px;
|
|
9
|
-
border-radius: 4px;
|
|
10
|
-
}
|
|
11
|
-
body.builder-selector-active .ya-text-editable:hover {
|
|
12
|
-
outline: none;
|
|
13
|
-
cursor: inherit;
|
|
14
|
-
}
|
|
15
|
-
.ya-text-editing {
|
|
16
|
-
outline: 2px solid var(--color-primary, #D4A574);
|
|
17
|
-
outline-offset: 4px;
|
|
18
|
-
border-radius: 4px;
|
|
19
|
-
position: relative;
|
|
20
|
-
}
|
|
21
|
-
.ya-bubble-menu {
|
|
22
|
-
display: flex;
|
|
23
|
-
gap: 4px;
|
|
24
|
-
padding: 6px 8px;
|
|
25
|
-
background: #1a1a1a;
|
|
26
|
-
border-radius: 8px;
|
|
27
|
-
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
|
|
28
|
-
animation: ya-bubble-fade-in 0.15s ease;
|
|
29
|
-
font-family:
|
|
30
|
-
system-ui,
|
|
31
|
-
-apple-system,
|
|
32
|
-
BlinkMacSystemFont,
|
|
33
|
-
"Segoe UI",
|
|
34
|
-
sans-serif;
|
|
35
|
-
}
|
|
36
|
-
@keyframes ya-bubble-fade-in {
|
|
37
|
-
from {
|
|
38
|
-
opacity: 0;
|
|
39
|
-
transform: translateY(4px);
|
|
40
|
-
}
|
|
41
|
-
to {
|
|
42
|
-
opacity: 1;
|
|
43
|
-
transform: translateY(0);
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
.ya-bubble-btn {
|
|
47
|
-
display: flex;
|
|
48
|
-
align-items: center;
|
|
49
|
-
justify-content: center;
|
|
50
|
-
width: 32px;
|
|
51
|
-
height: 32px;
|
|
52
|
-
padding: 0;
|
|
53
|
-
border: none;
|
|
54
|
-
background: transparent;
|
|
55
|
-
color: #e0e0e0;
|
|
56
|
-
border-radius: 6px;
|
|
57
|
-
cursor: pointer;
|
|
58
|
-
transition: all 0.15s ease;
|
|
59
|
-
font-size: 14px;
|
|
60
|
-
}
|
|
61
|
-
.ya-bubble-btn:hover {
|
|
62
|
-
background: rgba(255, 255, 255, 0.1);
|
|
63
|
-
color: #ffffff;
|
|
64
|
-
}
|
|
65
|
-
.ya-bubble-btn.is-active {
|
|
66
|
-
background: var(--color-primary, #D4A574);
|
|
67
|
-
color: #1a1a1a;
|
|
68
|
-
}
|
|
69
|
-
.ya-bubble-btn.is-active:hover {
|
|
70
|
-
background: var(--color-primary, #D4A574);
|
|
71
|
-
filter: brightness(1.1);
|
|
72
|
-
}
|
|
73
|
-
.ya-bubble-divider {
|
|
74
|
-
width: 1px;
|
|
75
|
-
height: 20px;
|
|
76
|
-
background: rgba(255, 255, 255, 0.2);
|
|
77
|
-
margin: 6px 4px;
|
|
78
|
-
}
|
|
79
|
-
.ya-bubble-select {
|
|
80
|
-
appearance: none;
|
|
81
|
-
background: transparent;
|
|
82
|
-
color: #e0e0e0;
|
|
83
|
-
border: 1px solid rgba(255, 255, 255, 0.2);
|
|
84
|
-
border-radius: 6px;
|
|
85
|
-
padding: 6px 24px 6px 10px;
|
|
86
|
-
font-size: 12px;
|
|
87
|
-
cursor: pointer;
|
|
88
|
-
transition: all 0.15s ease;
|
|
89
|
-
min-width: 70px;
|
|
90
|
-
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23e0e0e0' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
|
|
91
|
-
background-repeat: no-repeat;
|
|
92
|
-
background-position: right 6px center;
|
|
93
|
-
}
|
|
94
|
-
.ya-bubble-select:hover {
|
|
95
|
-
border-color: rgba(255, 255, 255, 0.4);
|
|
96
|
-
background-color: rgba(255, 255, 255, 0.05);
|
|
97
|
-
}
|
|
98
|
-
.ya-bubble-select:focus {
|
|
99
|
-
outline: none;
|
|
100
|
-
border-color: var(--color-primary, #D4A574);
|
|
101
|
-
}
|
|
102
|
-
.ya-bubble-select option {
|
|
103
|
-
background: #1a1a1a;
|
|
104
|
-
color: #e0e0e0;
|
|
105
|
-
padding: 8px;
|
|
106
|
-
}
|
|
107
|
-
.ProseMirror {
|
|
108
|
-
outline: none;
|
|
109
|
-
}
|
|
110
|
-
.ProseMirror p {
|
|
111
|
-
margin: 0;
|
|
112
|
-
}
|
|
113
|
-
.ProseMirror a {
|
|
114
|
-
color: var(--color-primary, #D4A574);
|
|
115
|
-
text-decoration: underline;
|
|
116
|
-
}
|
|
117
|
-
.ProseMirror a:hover {
|
|
118
|
-
color: var(--color-secondary, #5C4033);
|
|
119
|
-
}
|
|
120
|
-
.ProseMirror ::selection {
|
|
121
|
-
background: rgba(212, 165, 116, 0.3);
|
|
122
|
-
}
|
|
123
|
-
.ProseMirror p.is-editor-empty:first-child::before {
|
|
124
|
-
content: attr(data-placeholder);
|
|
125
|
-
float: left;
|
|
126
|
-
color: #adb5bd;
|
|
127
|
-
pointer-events: none;
|
|
128
|
-
height: 0;
|
|
129
|
-
}
|
|
130
|
-
.ya-text-actions {
|
|
131
|
-
display: flex;
|
|
132
|
-
gap: 8px;
|
|
133
|
-
position: absolute;
|
|
134
|
-
bottom: -48px;
|
|
135
|
-
right: 0;
|
|
136
|
-
z-index: 10;
|
|
137
|
-
background: rgba(26, 26, 26, 0.8);
|
|
138
|
-
padding: 8px 10px;
|
|
139
|
-
border-radius: 8px;
|
|
140
|
-
font-family:
|
|
141
|
-
system-ui,
|
|
142
|
-
-apple-system,
|
|
143
|
-
BlinkMacSystemFont,
|
|
144
|
-
"Segoe UI",
|
|
145
|
-
sans-serif;
|
|
146
|
-
}
|
|
147
|
-
.ya-text-btn {
|
|
148
|
-
padding: 6px 14px;
|
|
149
|
-
font-size: 12px;
|
|
150
|
-
font-weight: 500;
|
|
151
|
-
border-radius: 6px;
|
|
152
|
-
cursor: pointer;
|
|
153
|
-
transition: all 0.15s ease;
|
|
154
|
-
border: none;
|
|
155
|
-
}
|
|
156
|
-
.ya-text-btn-cancel {
|
|
157
|
-
background: #333333;
|
|
158
|
-
color: #ffffff;
|
|
159
|
-
border: 1px solid #555555;
|
|
160
|
-
}
|
|
161
|
-
.ya-text-btn-cancel:hover {
|
|
162
|
-
background: #444444;
|
|
163
|
-
color: #ffffff;
|
|
164
|
-
border-color: #666666;
|
|
165
|
-
}
|
|
166
|
-
.ya-text-btn-save {
|
|
167
|
-
background: #D4A574;
|
|
168
|
-
color: #1a1a1a;
|
|
169
|
-
}
|
|
170
|
-
.ya-text-btn-save:hover {
|
|
171
|
-
background: #c4956a;
|
|
172
|
-
}
|
|
173
|
-
.ya-link-popover {
|
|
174
|
-
position: fixed;
|
|
175
|
-
z-index: 9999;
|
|
176
|
-
display: flex;
|
|
177
|
-
align-items: center;
|
|
178
|
-
gap: 6px;
|
|
179
|
-
padding: 8px 12px;
|
|
180
|
-
background: #1a1a1a;
|
|
181
|
-
color: #e0e0e0;
|
|
182
|
-
border-radius: 8px;
|
|
183
|
-
font-size: 13px;
|
|
184
|
-
font-weight: 500;
|
|
185
|
-
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
|
|
186
|
-
cursor: pointer;
|
|
187
|
-
white-space: nowrap;
|
|
188
|
-
transform: translateX(-50%);
|
|
189
|
-
pointer-events: auto;
|
|
190
|
-
animation: ya-link-popover-fade-in 0.1s ease;
|
|
191
|
-
}
|
|
192
|
-
.ya-link-popover:hover {
|
|
193
|
-
background: #2a2a2a;
|
|
194
|
-
}
|
|
195
|
-
@keyframes ya-link-popover-fade-in {
|
|
196
|
-
from {
|
|
197
|
-
opacity: 0;
|
|
198
|
-
transform: translateX(-50%) translateY(-4px);
|
|
199
|
-
}
|
|
200
|
-
to {
|
|
201
|
-
opacity: 1;
|
|
202
|
-
transform: translateX(-50%) translateY(0);
|
|
203
|
-
}
|
|
204
|
-
}
|
|
205
|
-
.ya-link-popover::before {
|
|
206
|
-
content: "";
|
|
207
|
-
position: absolute;
|
|
208
|
-
top: -6px;
|
|
209
|
-
left: 50%;
|
|
210
|
-
transform: translateX(-50%);
|
|
211
|
-
border-left: 6px solid transparent;
|
|
212
|
-
border-right: 6px solid transparent;
|
|
213
|
-
border-bottom: 6px solid #1a1a1a;
|
|
214
|
-
}
|
|
215
|
-
.ya-link-popover-icon {
|
|
216
|
-
width: 14px;
|
|
217
|
-
height: 14px;
|
|
218
|
-
opacity: 0.8;
|
|
219
|
-
flex-shrink: 0;
|
|
220
|
-
}
|
|
221
|
-
.ya-link-popover-prefix {
|
|
222
|
-
opacity: 0.7;
|
|
223
|
-
}
|
|
224
|
-
.ya-link-popover-name {
|
|
225
|
-
color: var(--color-primary, #D4A574);
|
|
226
|
-
}
|
|
227
|
-
|
|
228
|
-
/* src/components/ya-tooltip.css */
|
|
229
|
-
.ya-tooltip {
|
|
230
|
-
position: fixed;
|
|
231
|
-
z-index: 9999;
|
|
232
|
-
display: flex;
|
|
233
|
-
align-items: center;
|
|
234
|
-
gap: 6px;
|
|
235
|
-
padding: 8px 12px;
|
|
236
|
-
background: #1a1a1a;
|
|
237
|
-
color: white;
|
|
238
|
-
border-radius: 6px;
|
|
239
|
-
font-size: 13px;
|
|
240
|
-
font-weight: 500;
|
|
241
|
-
font-family:
|
|
242
|
-
system-ui,
|
|
243
|
-
-apple-system,
|
|
244
|
-
BlinkMacSystemFont,
|
|
245
|
-
"Segoe UI",
|
|
246
|
-
sans-serif;
|
|
247
|
-
white-space: nowrap;
|
|
248
|
-
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
|
|
249
|
-
animation: ya-tooltip-fade-in 0.15s ease;
|
|
250
|
-
pointer-events: none;
|
|
251
|
-
}
|
|
252
|
-
@keyframes ya-tooltip-fade-in {
|
|
253
|
-
from {
|
|
254
|
-
opacity: 0;
|
|
255
|
-
transform: scale(0.95);
|
|
256
|
-
}
|
|
257
|
-
to {
|
|
258
|
-
opacity: 1;
|
|
259
|
-
transform: scale(1);
|
|
260
|
-
}
|
|
261
|
-
}
|
|
262
|
-
.ya-tooltip svg {
|
|
263
|
-
width: 16px;
|
|
264
|
-
height: 16px;
|
|
265
|
-
flex-shrink: 0;
|
|
266
|
-
}
|
|
267
|
-
.ya-tooltip-bottom {
|
|
268
|
-
transform: translateX(-50%);
|
|
269
|
-
}
|
|
270
|
-
.ya-tooltip-bottom::before {
|
|
271
|
-
content: "";
|
|
272
|
-
position: absolute;
|
|
273
|
-
bottom: 100%;
|
|
274
|
-
left: 50%;
|
|
275
|
-
transform: translateX(-50%);
|
|
276
|
-
border: 6px solid transparent;
|
|
277
|
-
border-bottom-color: #1a1a1a;
|
|
278
|
-
}
|
|
279
|
-
.ya-tooltip-top {
|
|
280
|
-
transform: translateX(-50%);
|
|
281
|
-
}
|
|
282
|
-
.ya-tooltip-top::before {
|
|
283
|
-
content: "";
|
|
284
|
-
position: absolute;
|
|
285
|
-
top: 100%;
|
|
286
|
-
left: 50%;
|
|
287
|
-
transform: translateX(-50%);
|
|
288
|
-
border: 6px solid transparent;
|
|
289
|
-
border-top-color: #1a1a1a;
|
|
290
|
-
}
|
|
291
|
-
.ya-tooltip-right {
|
|
292
|
-
transform: translateY(-50%);
|
|
293
|
-
}
|
|
294
|
-
.ya-tooltip-right::before {
|
|
295
|
-
content: "";
|
|
296
|
-
position: absolute;
|
|
297
|
-
right: 100%;
|
|
298
|
-
top: 50%;
|
|
299
|
-
transform: translateY(-50%);
|
|
300
|
-
border: 6px solid transparent;
|
|
301
|
-
border-right-color: #1a1a1a;
|
|
302
|
-
}
|
|
303
|
-
.ya-tooltip-left {
|
|
304
|
-
transform: translateY(-50%);
|
|
305
|
-
}
|
|
306
|
-
.ya-tooltip-left::before {
|
|
307
|
-
content: "";
|
|
308
|
-
position: absolute;
|
|
309
|
-
left: 100%;
|
|
310
|
-
top: 50%;
|
|
311
|
-
transform: translateY(-50%);
|
|
312
|
-
border: 6px solid transparent;
|
|
313
|
-
border-left-color: #1a1a1a;
|
|
314
|
-
}
|
|
315
|
-
|
|
316
|
-
/* src/components/ya-image.css */
|
|
317
|
-
.ya-image-container {
|
|
318
|
-
position: relative;
|
|
319
|
-
display: inline-block;
|
|
320
|
-
min-width: 45px;
|
|
321
|
-
min-height: 45px;
|
|
322
|
-
cursor: pointer;
|
|
323
|
-
transition: outline 0.15s ease;
|
|
324
|
-
}
|
|
325
|
-
.ya-image-container img {
|
|
326
|
-
display: block;
|
|
327
|
-
}
|
|
328
|
-
.ya-image-editable {
|
|
329
|
-
cursor: pointer;
|
|
330
|
-
}
|
|
331
|
-
.ya-image-editable:hover {
|
|
332
|
-
outline: 2px dashed var(--color-primary, #D4A574);
|
|
333
|
-
outline-offset: 4px;
|
|
334
|
-
}
|
|
335
|
-
.ya-image-selected {
|
|
336
|
-
outline: 3px solid var(--color-primary, #D4A574);
|
|
337
|
-
outline-offset: 4px;
|
|
338
|
-
}
|
|
339
|
-
.ya-image-overlay {
|
|
340
|
-
position: absolute;
|
|
341
|
-
inset: 0;
|
|
342
|
-
display: flex;
|
|
343
|
-
flex-direction: column;
|
|
344
|
-
align-items: center;
|
|
345
|
-
justify-content: center;
|
|
346
|
-
gap: 8px;
|
|
347
|
-
background: rgba(0, 0, 0, 0.5);
|
|
348
|
-
opacity: 0;
|
|
349
|
-
transition: opacity 0.2s ease;
|
|
350
|
-
pointer-events: none;
|
|
351
|
-
border-radius: inherit;
|
|
352
|
-
}
|
|
353
|
-
.ya-image-editable:hover .ya-image-overlay {
|
|
354
|
-
opacity: 1;
|
|
355
|
-
}
|
|
356
|
-
.ya-image-selected .ya-image-overlay {
|
|
357
|
-
opacity: 0;
|
|
358
|
-
}
|
|
359
|
-
.ya-image-edit-icon {
|
|
360
|
-
display: flex;
|
|
361
|
-
align-items: center;
|
|
362
|
-
justify-content: center;
|
|
363
|
-
width: 48px;
|
|
364
|
-
height: 48px;
|
|
365
|
-
background: white;
|
|
366
|
-
border-radius: 50%;
|
|
367
|
-
color: #1a1a1a;
|
|
368
|
-
box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
|
|
369
|
-
}
|
|
370
|
-
.ya-image-edit-icon svg {
|
|
371
|
-
width: 24px;
|
|
372
|
-
height: 24px;
|
|
373
|
-
}
|
|
374
|
-
.ya-image-edit-label {
|
|
375
|
-
color: white;
|
|
376
|
-
font-size: 14px;
|
|
377
|
-
font-weight: 500;
|
|
378
|
-
text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
|
|
379
|
-
}
|
|
380
|
-
@keyframes ya-image-success {
|
|
381
|
-
0% {
|
|
382
|
-
outline-color: var(--color-primary, #D4A574);
|
|
383
|
-
}
|
|
384
|
-
50% {
|
|
385
|
-
outline-color: #22c55e;
|
|
386
|
-
outline-width: 4px;
|
|
387
|
-
}
|
|
388
|
-
100% {
|
|
389
|
-
outline-color: var(--color-primary, #D4A574);
|
|
390
|
-
outline-width: 2px;
|
|
391
|
-
}
|
|
392
|
-
}
|
|
393
|
-
.ya-image-success {
|
|
394
|
-
animation: ya-image-success 0.4s ease;
|
|
395
|
-
}
|
|
396
|
-
.ya-image-loading::after {
|
|
397
|
-
content: "";
|
|
398
|
-
position: absolute;
|
|
399
|
-
inset: 0;
|
|
400
|
-
background:
|
|
401
|
-
linear-gradient(
|
|
402
|
-
90deg,
|
|
403
|
-
rgba(255, 255, 255, 0) 0%,
|
|
404
|
-
rgba(255, 255, 255, 0.3) 50%,
|
|
405
|
-
rgba(255, 255, 255, 0) 100%);
|
|
406
|
-
background-size: 200% 100%;
|
|
407
|
-
animation: ya-image-shimmer 1.5s infinite;
|
|
408
|
-
}
|
|
409
|
-
@keyframes ya-image-shimmer {
|
|
410
|
-
0% {
|
|
411
|
-
background-position: -200% 0;
|
|
412
|
-
}
|
|
413
|
-
100% {
|
|
414
|
-
background-position: 200% 0;
|
|
415
|
-
}
|
|
416
|
-
}
|
|
417
|
-
.ya-image-container:focus {
|
|
418
|
-
outline: 3px solid var(--color-primary, #D4A574);
|
|
419
|
-
outline-offset: 4px;
|
|
420
|
-
}
|
|
421
|
-
.ya-image-container:focus:not(:focus-visible) {
|
|
422
|
-
outline: none;
|
|
423
|
-
}
|
|
424
|
-
.ya-image-container:focus-visible {
|
|
425
|
-
outline: 3px solid var(--color-primary, #D4A574);
|
|
426
|
-
outline-offset: 4px;
|
|
427
|
-
}
|
|
428
|
-
.ya-image-small .ya-image-overlay {
|
|
429
|
-
display: none;
|
|
430
|
-
}
|
|
431
|
-
|
|
432
|
-
/* src/components/ya-link.css */
|
|
433
|
-
.ya-link-wrapper {
|
|
434
|
-
position: relative;
|
|
435
|
-
display: inline;
|
|
436
|
-
}
|
|
437
|
-
.ya-link-editable {
|
|
438
|
-
cursor: pointer;
|
|
439
|
-
transition: outline 0.15s ease;
|
|
440
|
-
}
|
|
441
|
-
.ya-link-editable:hover {
|
|
442
|
-
outline: 2px dashed var(--color-primary, #D4A574);
|
|
443
|
-
outline-offset: 4px;
|
|
444
|
-
border-radius: 4px;
|
|
445
|
-
}
|
|
446
|
-
body.builder-selector-active .ya-link-editable:hover {
|
|
447
|
-
outline: none;
|
|
448
|
-
cursor: inherit;
|
|
449
|
-
}
|
|
450
|
-
.ya-link-editing {
|
|
451
|
-
outline: 2px solid var(--color-primary, #D4A574);
|
|
452
|
-
outline-offset: 4px;
|
|
453
|
-
border-radius: 4px;
|
|
454
|
-
position: relative;
|
|
455
|
-
}
|
|
456
|
-
.ya-link-actions {
|
|
457
|
-
display: flex;
|
|
458
|
-
gap: 8px;
|
|
459
|
-
position: absolute;
|
|
460
|
-
bottom: -60px;
|
|
461
|
-
right: 0;
|
|
462
|
-
z-index: 10;
|
|
463
|
-
background: rgba(26, 26, 26, 0.95);
|
|
464
|
-
padding: 8px 10px;
|
|
465
|
-
border-radius: 8px;
|
|
466
|
-
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
|
|
467
|
-
font-family:
|
|
468
|
-
system-ui,
|
|
469
|
-
-apple-system,
|
|
470
|
-
BlinkMacSystemFont,
|
|
471
|
-
"Segoe UI",
|
|
472
|
-
sans-serif;
|
|
473
|
-
}
|
|
474
|
-
.ya-link-btn {
|
|
475
|
-
padding: 6px 14px;
|
|
476
|
-
font-size: 12px;
|
|
477
|
-
font-weight: 500;
|
|
478
|
-
border-radius: 6px;
|
|
479
|
-
cursor: pointer;
|
|
480
|
-
transition: all 0.15s ease;
|
|
481
|
-
border: none;
|
|
482
|
-
}
|
|
483
|
-
.ya-link-btn-cancel {
|
|
484
|
-
background: #333333;
|
|
485
|
-
color: #ffffff;
|
|
486
|
-
border: 1px solid #555555;
|
|
487
|
-
}
|
|
488
|
-
.ya-link-btn-cancel:hover {
|
|
489
|
-
background: #444444;
|
|
490
|
-
color: #ffffff;
|
|
491
|
-
border-color: #666666;
|
|
492
|
-
}
|
|
493
|
-
.ya-link-btn-save {
|
|
494
|
-
background: #D4A574;
|
|
495
|
-
color: #1a1a1a;
|
|
496
|
-
}
|
|
497
|
-
.ya-link-btn-save:hover {
|
|
498
|
-
background: #c4956a;
|
|
499
|
-
}
|
|
500
|
-
.ya-href-popover {
|
|
501
|
-
position: absolute;
|
|
502
|
-
top: 100%;
|
|
503
|
-
left: 50%;
|
|
504
|
-
margin-top: 8px;
|
|
505
|
-
z-index: 10;
|
|
506
|
-
min-width: 280px;
|
|
507
|
-
max-width: 320px;
|
|
508
|
-
background: #1a1a1a;
|
|
509
|
-
border-radius: 12px;
|
|
510
|
-
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
|
|
511
|
-
transform: translateX(-50%);
|
|
512
|
-
animation: ya-href-popover-fade-in 0.15s ease;
|
|
513
|
-
overflow: hidden;
|
|
514
|
-
font-family:
|
|
515
|
-
system-ui,
|
|
516
|
-
-apple-system,
|
|
517
|
-
BlinkMacSystemFont,
|
|
518
|
-
"Segoe UI",
|
|
519
|
-
sans-serif;
|
|
520
|
-
}
|
|
521
|
-
@keyframes ya-href-popover-fade-in {
|
|
522
|
-
from {
|
|
523
|
-
opacity: 0;
|
|
524
|
-
transform: translateX(-50%) translateY(-8px);
|
|
525
|
-
}
|
|
526
|
-
to {
|
|
527
|
-
opacity: 1;
|
|
528
|
-
transform: translateX(-50%) translateY(0);
|
|
529
|
-
}
|
|
530
|
-
}
|
|
531
|
-
.ya-href-popover::before {
|
|
532
|
-
content: "";
|
|
533
|
-
position: absolute;
|
|
534
|
-
top: -6px;
|
|
535
|
-
left: 50%;
|
|
536
|
-
transform: translateX(-50%);
|
|
537
|
-
border-left: 8px solid transparent;
|
|
538
|
-
border-right: 8px solid transparent;
|
|
539
|
-
border-bottom: 8px solid #1a1a1a;
|
|
540
|
-
}
|
|
541
|
-
.ya-href-popover-header {
|
|
542
|
-
padding: 12px 16px;
|
|
543
|
-
font-size: 13px;
|
|
544
|
-
font-weight: 600;
|
|
545
|
-
color: #ffffff;
|
|
546
|
-
border-bottom: 1px solid rgba(255, 255, 255, 0.1);
|
|
547
|
-
}
|
|
548
|
-
.ya-href-popover-section {
|
|
549
|
-
padding: 12px 16px;
|
|
550
|
-
}
|
|
551
|
-
.ya-href-popover-label {
|
|
552
|
-
display: block;
|
|
553
|
-
font-size: 11px;
|
|
554
|
-
font-weight: 500;
|
|
555
|
-
color: rgba(255, 255, 255, 0.6);
|
|
556
|
-
text-transform: uppercase;
|
|
557
|
-
letter-spacing: 0.5px;
|
|
558
|
-
margin-bottom: 8px;
|
|
559
|
-
}
|
|
560
|
-
.ya-href-collapsible-header {
|
|
561
|
-
display: flex;
|
|
562
|
-
align-items: center;
|
|
563
|
-
gap: 6px;
|
|
564
|
-
width: 100%;
|
|
565
|
-
padding: 0;
|
|
566
|
-
background: transparent;
|
|
567
|
-
border: none;
|
|
568
|
-
cursor: pointer;
|
|
569
|
-
transition: color 0.15s ease;
|
|
570
|
-
}
|
|
571
|
-
.ya-href-collapsible-header:hover {
|
|
572
|
-
color: rgba(255, 255, 255, 0.8);
|
|
573
|
-
}
|
|
574
|
-
.ya-href-chevron {
|
|
575
|
-
font-size: 8px;
|
|
576
|
-
color: rgba(255, 255, 255, 0.4);
|
|
577
|
-
}
|
|
578
|
-
.ya-href-popover-pages {
|
|
579
|
-
display: flex;
|
|
580
|
-
flex-direction: column;
|
|
581
|
-
gap: 4px;
|
|
582
|
-
max-height: 200px;
|
|
583
|
-
overflow-y: auto;
|
|
584
|
-
}
|
|
585
|
-
.ya-href-page-btn {
|
|
586
|
-
display: flex;
|
|
587
|
-
flex-direction: column;
|
|
588
|
-
align-items: flex-start;
|
|
589
|
-
gap: 4px;
|
|
590
|
-
width: 100%;
|
|
591
|
-
padding: 10px 12px;
|
|
592
|
-
background: rgba(255, 255, 255, 0.05);
|
|
593
|
-
border: 1px solid transparent;
|
|
594
|
-
border-radius: 8px;
|
|
595
|
-
color: #e0e0e0;
|
|
596
|
-
font-size: 13px;
|
|
597
|
-
font-weight: 500;
|
|
598
|
-
text-align: left;
|
|
599
|
-
cursor: pointer;
|
|
600
|
-
transition: all 0.15s ease;
|
|
601
|
-
}
|
|
602
|
-
.ya-href-page-btn:hover {
|
|
603
|
-
background: rgba(255, 255, 255, 0.1);
|
|
604
|
-
border-color: rgba(255, 255, 255, 0.2);
|
|
605
|
-
}
|
|
606
|
-
.ya-href-page-btn.is-selected {
|
|
607
|
-
background: #D4A574;
|
|
608
|
-
color: #1a1a1a;
|
|
609
|
-
}
|
|
610
|
-
.ya-href-page-btn.is-selected .ya-href-page-path {
|
|
611
|
-
color: rgba(26, 26, 26, 0.6);
|
|
612
|
-
}
|
|
613
|
-
.ya-href-page-path {
|
|
614
|
-
font-size: 11px;
|
|
615
|
-
color: rgba(255, 255, 255, 0.4);
|
|
616
|
-
font-family: monospace;
|
|
617
|
-
word-break: break-all;
|
|
618
|
-
}
|
|
619
|
-
.ya-href-external-toggle {
|
|
620
|
-
display: block;
|
|
621
|
-
width: 100%;
|
|
622
|
-
padding: 10px 16px;
|
|
623
|
-
background: transparent;
|
|
624
|
-
border: none;
|
|
625
|
-
border-top: 1px solid rgba(255, 255, 255, 0.1);
|
|
626
|
-
color: #D4A574;
|
|
627
|
-
font-size: 12px;
|
|
628
|
-
font-weight: 500;
|
|
629
|
-
text-align: center;
|
|
630
|
-
cursor: pointer;
|
|
631
|
-
transition: background 0.15s ease;
|
|
632
|
-
}
|
|
633
|
-
.ya-href-external-toggle:hover {
|
|
634
|
-
background: rgba(255, 255, 255, 0.05);
|
|
635
|
-
}
|
|
636
|
-
.ya-href-url-input {
|
|
637
|
-
width: 100%;
|
|
638
|
-
padding: 10px 12px;
|
|
639
|
-
background: rgba(255, 255, 255, 0.05);
|
|
640
|
-
border: 1px solid rgba(255, 255, 255, 0.2);
|
|
641
|
-
border-radius: 8px;
|
|
642
|
-
color: #ffffff;
|
|
643
|
-
font-size: 13px;
|
|
644
|
-
outline: none;
|
|
645
|
-
transition: border-color 0.15s ease;
|
|
646
|
-
}
|
|
647
|
-
.ya-href-url-input::placeholder {
|
|
648
|
-
color: rgba(255, 255, 255, 0.4);
|
|
649
|
-
}
|
|
650
|
-
.ya-href-url-input:focus {
|
|
651
|
-
border-color: var(--color-primary, #D4A574);
|
|
652
|
-
}
|
|
653
|
-
.ya-href-popover-actions {
|
|
654
|
-
display: flex;
|
|
655
|
-
justify-content: flex-end;
|
|
656
|
-
gap: 8px;
|
|
657
|
-
padding: 12px 16px;
|
|
658
|
-
border-top: 1px solid rgba(255, 255, 255, 0.1);
|
|
659
|
-
}
|
|
660
|
-
.ya-link-edit-popover {
|
|
661
|
-
position: absolute;
|
|
662
|
-
top: 100%;
|
|
663
|
-
left: 50%;
|
|
664
|
-
margin-top: 8px;
|
|
665
|
-
z-index: 10;
|
|
666
|
-
background: #2a2a2a;
|
|
667
|
-
border-radius: 6px;
|
|
668
|
-
padding: 4px;
|
|
669
|
-
display: flex;
|
|
670
|
-
gap: 4px;
|
|
671
|
-
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
|
|
672
|
-
transform: translateX(-50%);
|
|
673
|
-
animation: ya-edit-popover-fade-in 0.1s ease;
|
|
674
|
-
font-family:
|
|
675
|
-
system-ui,
|
|
676
|
-
-apple-system,
|
|
677
|
-
BlinkMacSystemFont,
|
|
678
|
-
"Segoe UI",
|
|
679
|
-
sans-serif;
|
|
680
|
-
white-space: nowrap;
|
|
681
|
-
}
|
|
682
|
-
@keyframes ya-edit-popover-fade-in {
|
|
683
|
-
from {
|
|
684
|
-
opacity: 0;
|
|
685
|
-
transform: translateX(-50%) translateY(-4px);
|
|
686
|
-
}
|
|
687
|
-
to {
|
|
688
|
-
opacity: 1;
|
|
689
|
-
transform: translateX(-50%) translateY(0);
|
|
690
|
-
}
|
|
691
|
-
}
|
|
692
|
-
.ya-link-edit-popover::before {
|
|
693
|
-
content: "";
|
|
694
|
-
position: absolute;
|
|
695
|
-
top: -5px;
|
|
696
|
-
left: 50%;
|
|
697
|
-
transform: translateX(-50%);
|
|
698
|
-
border-left: 6px solid transparent;
|
|
699
|
-
border-right: 6px solid transparent;
|
|
700
|
-
border-bottom: 6px solid #2a2a2a;
|
|
701
|
-
}
|
|
702
|
-
.ya-link-edit-popover button {
|
|
703
|
-
background: #3a3a3a;
|
|
704
|
-
border: none;
|
|
705
|
-
color: #fff;
|
|
706
|
-
padding: 6px 12px;
|
|
707
|
-
border-radius: 4px;
|
|
708
|
-
cursor: pointer;
|
|
709
|
-
font-size: 13px;
|
|
710
|
-
font-weight: 500;
|
|
711
|
-
transition: background 0.15s ease;
|
|
712
|
-
}
|
|
713
|
-
.ya-link-edit-popover button:hover {
|
|
714
|
-
background: #4a4a4a;
|
|
715
|
-
}
|