@panphora/hyper-cms 0.10.0 → 0.11.0
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/README.md +33 -0
- package/dist/hypercms.min.js +442 -36
- package/package.json +7 -4
- package/packed-contract.json +1 -0
- package/src/anchor.js +24 -0
- package/src/apply-loop.js +73 -46
- package/src/enhance.js +79 -6
- package/src/events.js +92 -6
- package/src/hooks.js +100 -0
- package/src/hypercms-clayjs.js +10 -0
- package/src/hypercms.js +109 -386
- package/src/inline-icons.js +15 -0
- package/src/lib/content-dom.js +110 -0
- package/src/lib/region-capabilities.js +71 -0
- package/src/morph.js +1 -0
- package/src/place.js +131 -0
- package/src/platform.js +12 -0
- package/src/refresh.js +23 -13
- package/src/richclay-bridge.js +140 -0
- package/src/row-identity.js +4 -6
- package/src/session.js +303 -0
- package/src/shell.js +27 -6
- package/src/targets.js +149 -0
- package/src/theme/pixel-quiet.overrides.css +303 -9
- package/src/theme.generated.css +303 -9
- package/src/toggle.js +627 -34
- package/src/unresolved.js +87 -18
- package/src/views/inline-ghosts.js +139 -0
- package/src/views/inline-layer.js +663 -0
- package/src/views/inline.js +1092 -0
- package/src/views/sidebar.js +97 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/* =====================================================================
|
|
2
2
|
Pixel Quiet — hypercms theme overrides (hypercms-owned).
|
|
3
3
|
|
|
4
|
-
Adapted from cms-sidebar/pixel-quiet/overrides.css. Two jobs:
|
|
4
|
+
Adapted from ARCHIVE_PROJECTS/cms-sidebar/pixel-quiet/overrides.css. Two jobs:
|
|
5
5
|
1. Retune --mirk-* tokens, scoped to .hcms-shell.pixel-quiet (never :root).
|
|
6
6
|
2. Author the panel geometry + the functional chrome the static mockup
|
|
7
7
|
doesn't have (error banner, add/remove/move controls, the engine's
|
|
@@ -112,13 +112,13 @@
|
|
|
112
112
|
position: fixed makes the shell a containing block so the absolute
|
|
113
113
|
minibar anchors to it; flex column so the body owns the scroll.
|
|
114
114
|
============================================================ */
|
|
115
|
-
.hcms-shell.pixel-quiet {
|
|
115
|
+
.hcms-shell.pixel-quiet.hcms-panel {
|
|
116
116
|
box-sizing: border-box;
|
|
117
117
|
position: fixed;
|
|
118
118
|
top: 0;
|
|
119
119
|
right: 0;
|
|
120
120
|
bottom: 0;
|
|
121
|
-
width: 380px;
|
|
121
|
+
width: var(--hcms-shell-width, 380px);
|
|
122
122
|
max-width: 100vw;
|
|
123
123
|
z-index: 2147483000;
|
|
124
124
|
display: flex;
|
|
@@ -128,7 +128,7 @@
|
|
|
128
128
|
border-left: 1px solid var(--mirk-input-border);
|
|
129
129
|
box-shadow: -16px 0 48px -28px rgba(43, 36, 27, 0.45);
|
|
130
130
|
}
|
|
131
|
-
.hcms-shell.pixel-quiet.dark {
|
|
131
|
+
.hcms-shell.pixel-quiet.hcms-panel.dark {
|
|
132
132
|
box-shadow: -16px 0 48px -28px rgba(0, 0, 0, 0.6);
|
|
133
133
|
}
|
|
134
134
|
|
|
@@ -140,13 +140,20 @@
|
|
|
140
140
|
box-shadow: 16px 0 48px -28px rgba(43, 36, 27, 0.45);
|
|
141
141
|
}
|
|
142
142
|
|
|
143
|
-
/* Push the page over so docked content is never hidden underneath
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
143
|
+
/* Push the page over so docked content is never hidden underneath, and publish
|
|
144
|
+
the geometry the floating toggle has to compose with. --hcms-toggle-shift is
|
|
145
|
+
the distance the toggle moves left, which is the shell width only while the
|
|
146
|
+
shell is docked on the right; docked left, as an overlay, or full-viewport it
|
|
147
|
+
is zero. */
|
|
148
|
+
body.hcms-open { --hcms-shell-width: 380px; }
|
|
149
|
+
body.hcms-open:not(.hcms-overlay) { padding-right: var(--hcms-shell-width); }
|
|
150
|
+
body.hcms-open:not(.hcms-overlay):not(.hcms-side-left) { --hcms-toggle-shift: var(--hcms-shell-width); }
|
|
151
|
+
body.hcms-open.hcms-side-left:not(.hcms-overlay) { padding-right: 0; padding-left: var(--hcms-shell-width); }
|
|
152
|
+
body.hcms-open.hcms-overlay { overflow: hidden; --hcms-toggle-display: none; }
|
|
147
153
|
|
|
148
154
|
@media (max-width: 799px) {
|
|
149
|
-
.hcms-
|
|
155
|
+
body.hcms-open { --hcms-shell-width: 100vw; }
|
|
156
|
+
body.hcms-open:not(.hcms-overlay):not(.hcms-side-left) { --hcms-toggle-shift: 0px; }
|
|
150
157
|
body.hcms-open:not(.hcms-overlay),
|
|
151
158
|
body.hcms-open.hcms-side-left:not(.hcms-overlay) { padding-right: 0; padding-left: 0; }
|
|
152
159
|
body.hcms-open { overflow: hidden; }
|
|
@@ -523,6 +530,7 @@ body.hcms-open.hcms-overlay { overflow: hidden; }
|
|
|
523
530
|
.hcms-shell-notice {
|
|
524
531
|
font-size: 12px;
|
|
525
532
|
line-height: 1.45;
|
|
533
|
+
white-space: pre-line;
|
|
526
534
|
color: var(--mirk-mark-fg);
|
|
527
535
|
background: var(--mirk-bevel-bg);
|
|
528
536
|
border: 1px solid var(--mirk-input-border);
|
|
@@ -589,3 +597,289 @@ body.hcms-open.hcms-overlay { overflow: hidden; }
|
|
|
589
597
|
cursor: pointer;
|
|
590
598
|
}
|
|
591
599
|
.hcms-sr-only[hidden] { display: none; }
|
|
600
|
+
|
|
601
|
+
/* ============================================================
|
|
602
|
+
INLINE VIEW GEOMETRY — not a panel. A transparent full-viewport
|
|
603
|
+
host whose children are the only interactive surfaces, so the page
|
|
604
|
+
underneath stays fully usable while the editor is open.
|
|
605
|
+
============================================================ */
|
|
606
|
+
.hcms-shell.pixel-quiet.hcms-inline {
|
|
607
|
+
position: fixed;
|
|
608
|
+
inset: 0;
|
|
609
|
+
z-index: 2147483000;
|
|
610
|
+
/* The host must never intercept a click meant for the page. Each child
|
|
611
|
+
re-enables pointer events for itself. */
|
|
612
|
+
pointer-events: none;
|
|
613
|
+
background: none;
|
|
614
|
+
border: 0;
|
|
615
|
+
box-shadow: none;
|
|
616
|
+
color: var(--mirk-fg);
|
|
617
|
+
}
|
|
618
|
+
.hcms-inline > *,
|
|
619
|
+
.hcms-inline-layer > * { pointer-events: auto; }
|
|
620
|
+
.hcms-inline-layer { position: absolute; inset: 0; pointer-events: none; }
|
|
621
|
+
|
|
622
|
+
.hcms-inline-bar {
|
|
623
|
+
position: absolute;
|
|
624
|
+
left: 50%;
|
|
625
|
+
bottom: 16px;
|
|
626
|
+
transform: translateX(-50%);
|
|
627
|
+
max-width: min(560px, calc(100vw - 32px));
|
|
628
|
+
display: flex;
|
|
629
|
+
flex-direction: column;
|
|
630
|
+
gap: 6px;
|
|
631
|
+
}
|
|
632
|
+
|
|
633
|
+
.hcms-inline-notice,
|
|
634
|
+
.hcms-inline-error {
|
|
635
|
+
padding: 8px 12px;
|
|
636
|
+
border-radius: 8px;
|
|
637
|
+
font-size: 14px;
|
|
638
|
+
line-height: 1.4;
|
|
639
|
+
border: 1px solid var(--mirk-input-border);
|
|
640
|
+
background: var(--mirk-bg);
|
|
641
|
+
color: var(--mirk-fg);
|
|
642
|
+
box-shadow: 0 12px 32px -20px rgba(43, 36, 27, 0.5);
|
|
643
|
+
}
|
|
644
|
+
.hcms-inline-notice { white-space: pre-line; }
|
|
645
|
+
.hcms-inline-error { border-color: var(--mirk-destructive); color: var(--mirk-destructive); }
|
|
646
|
+
.hcms-inline-notice[hidden],
|
|
647
|
+
.hcms-inline-error[hidden] { display: none; }
|
|
648
|
+
|
|
649
|
+
.hcms-inline-pop {
|
|
650
|
+
position: absolute;
|
|
651
|
+
top: 0;
|
|
652
|
+
left: 0;
|
|
653
|
+
box-sizing: border-box;
|
|
654
|
+
width: min(340px, calc(100vw - 24px));
|
|
655
|
+
max-height: calc(100dvh - 24px);
|
|
656
|
+
overflow: auto;
|
|
657
|
+
padding: 16px;
|
|
658
|
+
border-radius: 8px;
|
|
659
|
+
border: 1px solid var(--mirk-input-border);
|
|
660
|
+
background: var(--mirk-bg);
|
|
661
|
+
color: var(--mirk-fg);
|
|
662
|
+
box-shadow: 0 16px 40px -22px rgba(43, 36, 27, 0.55);
|
|
663
|
+
/* Above the handles. They are positioned with z-index: 1 while the popover
|
|
664
|
+
sat at auto, so a handle painted over the very field it had just opened
|
|
665
|
+
and covered the text in it. The popover is what someone is using; a handle
|
|
666
|
+
is only an offer to open one. */
|
|
667
|
+
z-index: 2;
|
|
668
|
+
}
|
|
669
|
+
.hcms-inline-pop[hidden] { display: none; }
|
|
670
|
+
.hcms-inline-pop-header {
|
|
671
|
+
display: flex;
|
|
672
|
+
align-items: center;
|
|
673
|
+
justify-content: space-between;
|
|
674
|
+
gap: 16px;
|
|
675
|
+
margin-bottom: 16px;
|
|
676
|
+
font-size: 14px;
|
|
677
|
+
}
|
|
678
|
+
.hcms-shell .hcms-inline-pop-close {
|
|
679
|
+
display: inline-flex;
|
|
680
|
+
align-items: center;
|
|
681
|
+
justify-content: center;
|
|
682
|
+
min-width: 36px;
|
|
683
|
+
min-height: 36px;
|
|
684
|
+
padding: 4px;
|
|
685
|
+
}
|
|
686
|
+
|
|
687
|
+
.hcms-inline-item-controls {
|
|
688
|
+
position: absolute;
|
|
689
|
+
top: 0;
|
|
690
|
+
left: 0;
|
|
691
|
+
z-index: 1;
|
|
692
|
+
will-change: transform;
|
|
693
|
+
display: flex;
|
|
694
|
+
align-items: center;
|
|
695
|
+
gap: 2px;
|
|
696
|
+
}
|
|
697
|
+
.hcms-inline-item-controls[hidden],
|
|
698
|
+
.hcms-inline-handle[hidden] { display: none; }
|
|
699
|
+
.hcms-inline-item-controls.has-open-settings { z-index: 3; }
|
|
700
|
+
.hcms-inline-settings { position: relative; display: flex; flex: none; }
|
|
701
|
+
.hcms-inline-settings[hidden],
|
|
702
|
+
.hcms-inline-settings-menu[hidden] { display: none; }
|
|
703
|
+
.hcms-inline-settings-menu {
|
|
704
|
+
position: absolute;
|
|
705
|
+
top: calc(100% + 6px);
|
|
706
|
+
right: 0;
|
|
707
|
+
min-width: 120px;
|
|
708
|
+
padding: 4px;
|
|
709
|
+
border: 1px solid var(--mirk-input-border);
|
|
710
|
+
border-radius: 5px;
|
|
711
|
+
background: var(--mirk-bg);
|
|
712
|
+
box-shadow: 0 8px 24px #0003;
|
|
713
|
+
}
|
|
714
|
+
.hcms-inline-settings-menu button {
|
|
715
|
+
display: block;
|
|
716
|
+
box-sizing: border-box;
|
|
717
|
+
width: 100%;
|
|
718
|
+
padding: 10px 12px;
|
|
719
|
+
border: 0;
|
|
720
|
+
background: transparent;
|
|
721
|
+
color: var(--mirk-destructive);
|
|
722
|
+
font: inherit;
|
|
723
|
+
text-align: left;
|
|
724
|
+
cursor: pointer;
|
|
725
|
+
}
|
|
726
|
+
.hcms-inline-settings-menu button:hover,
|
|
727
|
+
.hcms-inline-settings-menu button:focus-visible {
|
|
728
|
+
background: var(--mirk-bevel-bg);
|
|
729
|
+
outline: 1px solid var(--mirk-focus-color);
|
|
730
|
+
}
|
|
731
|
+
|
|
732
|
+
/* Buttons flow within the positioned item container. */
|
|
733
|
+
.hcms-inline-row-controls {
|
|
734
|
+
display: flex;
|
|
735
|
+
gap: 2px;
|
|
736
|
+
}
|
|
737
|
+
.hcms-inline-row-controls[hidden] { display: none; }
|
|
738
|
+
|
|
739
|
+
.hcms-inline-list-add[hidden] { display: none; }
|
|
740
|
+
|
|
741
|
+
.hcms-shell.hcms-inline-ghost {
|
|
742
|
+
box-sizing: border-box;
|
|
743
|
+
position: relative;
|
|
744
|
+
display: flex;
|
|
745
|
+
align-items: center;
|
|
746
|
+
justify-content: center;
|
|
747
|
+
flex: none;
|
|
748
|
+
max-width: 100%;
|
|
749
|
+
min-width: 0;
|
|
750
|
+
margin: 8px 0 0;
|
|
751
|
+
padding: 0;
|
|
752
|
+
border: 1px dashed color-mix(in srgb, currentColor 25%, transparent);
|
|
753
|
+
border-radius: 3px;
|
|
754
|
+
background: color-mix(in srgb, currentColor 3%, transparent);
|
|
755
|
+
color: inherit;
|
|
756
|
+
list-style: none;
|
|
757
|
+
}
|
|
758
|
+
.hcms-shell.hcms-inline-ghost[hidden] { display: none; }
|
|
759
|
+
tr.hcms-shell.hcms-inline-ghost { display: table-row; }
|
|
760
|
+
.hcms-inline-ghost-cell { padding: 0; text-align: center; vertical-align: middle; }
|
|
761
|
+
|
|
762
|
+
.hcms-shell .hcms-inline-handle,
|
|
763
|
+
.hcms-shell .hcms-inline-list-button {
|
|
764
|
+
display: inline-flex;
|
|
765
|
+
align-items: center;
|
|
766
|
+
justify-content: center;
|
|
767
|
+
min-width: 36px;
|
|
768
|
+
min-height: 36px;
|
|
769
|
+
padding: 4px;
|
|
770
|
+
line-height: 1;
|
|
771
|
+
}
|
|
772
|
+
.hcms-inline-handle .mirk-button__label,
|
|
773
|
+
.hcms-inline-list-button .mirk-button__label {
|
|
774
|
+
display: inline-flex;
|
|
775
|
+
align-items: center;
|
|
776
|
+
gap: 6px;
|
|
777
|
+
line-height: 1;
|
|
778
|
+
}
|
|
779
|
+
.hcms-inline-icon { display: block; width: 24px; height: 24px; flex: none; }
|
|
780
|
+
.hcms-inline-handle .hcms-inline-icon { width: 20.4px; height: 20.4px; transform: translateY(-1px); }
|
|
781
|
+
.hcms-inline-list-add .hcms-inline-icon { width: 16.8px; height: 16.8px; }
|
|
782
|
+
.hcms-shell .hcms-inline-list-add { padding-inline: 10px; }
|
|
783
|
+
|
|
784
|
+
.hcms-inline-list-button {
|
|
785
|
+
flex: none;
|
|
786
|
+
}
|
|
787
|
+
.hcms-inline-list-button[hidden] { display: none; }
|
|
788
|
+
.hcms-shell .hcms-inline-list-button:disabled {
|
|
789
|
+
opacity: 1;
|
|
790
|
+
color: #626B96;
|
|
791
|
+
background: var(--mirk-bevel-bg);
|
|
792
|
+
border-color: var(--mirk-bevel-tl) var(--mirk-bevel-br) var(--mirk-bevel-br) var(--mirk-bevel-tl);
|
|
793
|
+
}
|
|
794
|
+
.hcms-shell .hcms-inline-list-button:disabled .mirk-button__label { translate: none; }
|
|
795
|
+
|
|
796
|
+
/* A finger is not a mouse pointer: on touch the same three controls get the
|
|
797
|
+
44px target the platform guidelines ask for. */
|
|
798
|
+
@media (pointer: coarse) {
|
|
799
|
+
.hcms-shell .hcms-inline-handle,
|
|
800
|
+
.hcms-shell .hcms-inline-list-button {
|
|
801
|
+
min-width: 44px;
|
|
802
|
+
min-height: 44px;
|
|
803
|
+
}
|
|
804
|
+
}
|
|
805
|
+
|
|
806
|
+
.hcms-inline-toggle { align-self: center; }
|
|
807
|
+
.hcms-inline-toggle[hidden] { display: none; }
|
|
808
|
+
|
|
809
|
+
/* Fields with no visible anchor can still be edited through the sidebar. */
|
|
810
|
+
.hcms-inline-handoff {
|
|
811
|
+
display: flex;
|
|
812
|
+
align-items: center;
|
|
813
|
+
gap: 10px;
|
|
814
|
+
padding: 6px 6px 6px 12px;
|
|
815
|
+
border-radius: 999px;
|
|
816
|
+
font-size: 13px;
|
|
817
|
+
border: 1px solid var(--mirk-input-border);
|
|
818
|
+
background: var(--mirk-bg);
|
|
819
|
+
color: var(--mirk-fg);
|
|
820
|
+
align-self: center;
|
|
821
|
+
}
|
|
822
|
+
.hcms-inline-handoff[hidden] { display: none; }
|
|
823
|
+
|
|
824
|
+
/* Selected fields only. Scoped to the inline host: [data-hcms-shell] is on BOTH
|
|
825
|
+
hosts, so an unscoped rule hides the sidebar's whole form too. */
|
|
826
|
+
.hcms-inline .hcms-form [data-hcms-path] { display: none; }
|
|
827
|
+
.hcms-inline .hcms-form [data-hcms-path].is-hcms-inline-onpath,
|
|
828
|
+
.hcms-inline .hcms-form [data-hcms-path].is-hcms-inline-active { display: block; }
|
|
829
|
+
|
|
830
|
+
.hcms-inline .hcms-form .is-hcms-inline-onpath,
|
|
831
|
+
.hcms-inline .hcms-form {
|
|
832
|
+
margin: 0;
|
|
833
|
+
padding: 0;
|
|
834
|
+
border: 0;
|
|
835
|
+
border-radius: 0;
|
|
836
|
+
box-shadow: none;
|
|
837
|
+
background: transparent;
|
|
838
|
+
min-width: 0;
|
|
839
|
+
min-height: 0;
|
|
840
|
+
width: 100%;
|
|
841
|
+
}
|
|
842
|
+
.hcms-inline-pop .hcms-object-title,
|
|
843
|
+
.hcms-inline-pop .hcms-array-header,
|
|
844
|
+
.hcms-inline-pop .hcms-drag-handle,
|
|
845
|
+
.hcms-inline-pop [data-hcms-action="add"],
|
|
846
|
+
.hcms-inline-pop [data-hcms-action="remove"],
|
|
847
|
+
.hcms-inline-pop [data-hcms-action="move-up"],
|
|
848
|
+
.hcms-inline-pop [data-hcms-action="move-down"],
|
|
849
|
+
.hcms-inline-pop .hcms-card-controls { display: none; }
|
|
850
|
+
.hcms-inline .hcms-form .hcms-field.is-hcms-inline-active {
|
|
851
|
+
display: flex;
|
|
852
|
+
gap: 8px;
|
|
853
|
+
padding: 0;
|
|
854
|
+
margin: 0 0 16px;
|
|
855
|
+
border: 0;
|
|
856
|
+
min-width: min(260px, 100%);
|
|
857
|
+
}
|
|
858
|
+
.hcms-inline .hcms-form .hcms-field.is-hcms-inline-active:last-child { margin-bottom: 0; }
|
|
859
|
+
.hcms-shell.pixel-quiet .hcms-inline-pop .mirk-input,
|
|
860
|
+
.hcms-shell.pixel-quiet .hcms-inline-pop .mirk-textarea {
|
|
861
|
+
box-sizing: border-box;
|
|
862
|
+
width: 100%;
|
|
863
|
+
min-width: min(260px, 100%);
|
|
864
|
+
min-height: 42px;
|
|
865
|
+
padding: 10px 12px;
|
|
866
|
+
border: 1px solid var(--mirk-input-border);
|
|
867
|
+
background: var(--mirk-input-bg);
|
|
868
|
+
}
|
|
869
|
+
.hcms-inline-pop .mirk-input:focus-visible,
|
|
870
|
+
.hcms-inline-pop .mirk-textarea:focus-visible {
|
|
871
|
+
outline: 2px solid var(--mirk-focus-color);
|
|
872
|
+
outline-offset: 2px;
|
|
873
|
+
}
|
|
874
|
+
|
|
875
|
+
.hcms-inline-highlight {
|
|
876
|
+
position: absolute;
|
|
877
|
+
top: 0;
|
|
878
|
+
left: 0;
|
|
879
|
+
pointer-events: none;
|
|
880
|
+
border: 2px solid var(--mirk-focus-color);
|
|
881
|
+
border-radius: 4px;
|
|
882
|
+
box-sizing: border-box;
|
|
883
|
+
will-change: transform;
|
|
884
|
+
}
|
|
885
|
+
.hcms-inline-highlight[hidden] { display: none; }
|
package/src/theme.generated.css
CHANGED
|
@@ -1012,7 +1012,7 @@
|
|
|
1012
1012
|
/* =====================================================================
|
|
1013
1013
|
Pixel Quiet — hypercms theme overrides (hypercms-owned).
|
|
1014
1014
|
|
|
1015
|
-
Adapted from cms-sidebar/pixel-quiet/overrides.css. Two jobs:
|
|
1015
|
+
Adapted from ARCHIVE_PROJECTS/cms-sidebar/pixel-quiet/overrides.css. Two jobs:
|
|
1016
1016
|
1. Retune --mirk-* tokens, scoped to .hcms-shell.pixel-quiet (never :root).
|
|
1017
1017
|
2. Author the panel geometry + the functional chrome the static mockup
|
|
1018
1018
|
doesn't have (error banner, add/remove/move controls, the engine's
|
|
@@ -1123,13 +1123,13 @@
|
|
|
1123
1123
|
position: fixed makes the shell a containing block so the absolute
|
|
1124
1124
|
minibar anchors to it; flex column so the body owns the scroll.
|
|
1125
1125
|
============================================================ */
|
|
1126
|
-
.hcms-shell.pixel-quiet {
|
|
1126
|
+
.hcms-shell.pixel-quiet.hcms-panel {
|
|
1127
1127
|
box-sizing: border-box;
|
|
1128
1128
|
position: fixed;
|
|
1129
1129
|
top: 0;
|
|
1130
1130
|
right: 0;
|
|
1131
1131
|
bottom: 0;
|
|
1132
|
-
width: 380px;
|
|
1132
|
+
width: var(--hcms-shell-width, 380px);
|
|
1133
1133
|
max-width: 100vw;
|
|
1134
1134
|
z-index: 2147483000;
|
|
1135
1135
|
display: flex;
|
|
@@ -1139,7 +1139,7 @@
|
|
|
1139
1139
|
border-left: 1px solid var(--mirk-input-border);
|
|
1140
1140
|
box-shadow: -16px 0 48px -28px rgba(43, 36, 27, 0.45);
|
|
1141
1141
|
}
|
|
1142
|
-
.hcms-shell.pixel-quiet.dark {
|
|
1142
|
+
.hcms-shell.pixel-quiet.hcms-panel.dark {
|
|
1143
1143
|
box-shadow: -16px 0 48px -28px rgba(0, 0, 0, 0.6);
|
|
1144
1144
|
}
|
|
1145
1145
|
|
|
@@ -1151,13 +1151,20 @@
|
|
|
1151
1151
|
box-shadow: 16px 0 48px -28px rgba(43, 36, 27, 0.45);
|
|
1152
1152
|
}
|
|
1153
1153
|
|
|
1154
|
-
/* Push the page over so docked content is never hidden underneath
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1154
|
+
/* Push the page over so docked content is never hidden underneath, and publish
|
|
1155
|
+
the geometry the floating toggle has to compose with. --hcms-toggle-shift is
|
|
1156
|
+
the distance the toggle moves left, which is the shell width only while the
|
|
1157
|
+
shell is docked on the right; docked left, as an overlay, or full-viewport it
|
|
1158
|
+
is zero. */
|
|
1159
|
+
body.hcms-open { --hcms-shell-width: 380px; }
|
|
1160
|
+
body.hcms-open:not(.hcms-overlay) { padding-right: var(--hcms-shell-width); }
|
|
1161
|
+
body.hcms-open:not(.hcms-overlay):not(.hcms-side-left) { --hcms-toggle-shift: var(--hcms-shell-width); }
|
|
1162
|
+
body.hcms-open.hcms-side-left:not(.hcms-overlay) { padding-right: 0; padding-left: var(--hcms-shell-width); }
|
|
1163
|
+
body.hcms-open.hcms-overlay { overflow: hidden; --hcms-toggle-display: none; }
|
|
1158
1164
|
|
|
1159
1165
|
@media (max-width: 799px) {
|
|
1160
|
-
.hcms-
|
|
1166
|
+
body.hcms-open { --hcms-shell-width: 100vw; }
|
|
1167
|
+
body.hcms-open:not(.hcms-overlay):not(.hcms-side-left) { --hcms-toggle-shift: 0px; }
|
|
1161
1168
|
body.hcms-open:not(.hcms-overlay),
|
|
1162
1169
|
body.hcms-open.hcms-side-left:not(.hcms-overlay) { padding-right: 0; padding-left: 0; }
|
|
1163
1170
|
body.hcms-open { overflow: hidden; }
|
|
@@ -1534,6 +1541,7 @@ body.hcms-open.hcms-overlay { overflow: hidden; }
|
|
|
1534
1541
|
.hcms-shell-notice {
|
|
1535
1542
|
font-size: 12px;
|
|
1536
1543
|
line-height: 1.45;
|
|
1544
|
+
white-space: pre-line;
|
|
1537
1545
|
color: var(--mirk-mark-fg);
|
|
1538
1546
|
background: var(--mirk-bevel-bg);
|
|
1539
1547
|
border: 1px solid var(--mirk-input-border);
|
|
@@ -1600,3 +1608,289 @@ body.hcms-open.hcms-overlay { overflow: hidden; }
|
|
|
1600
1608
|
cursor: pointer;
|
|
1601
1609
|
}
|
|
1602
1610
|
.hcms-sr-only[hidden] { display: none; }
|
|
1611
|
+
|
|
1612
|
+
/* ============================================================
|
|
1613
|
+
INLINE VIEW GEOMETRY — not a panel. A transparent full-viewport
|
|
1614
|
+
host whose children are the only interactive surfaces, so the page
|
|
1615
|
+
underneath stays fully usable while the editor is open.
|
|
1616
|
+
============================================================ */
|
|
1617
|
+
.hcms-shell.pixel-quiet.hcms-inline {
|
|
1618
|
+
position: fixed;
|
|
1619
|
+
inset: 0;
|
|
1620
|
+
z-index: 2147483000;
|
|
1621
|
+
/* The host must never intercept a click meant for the page. Each child
|
|
1622
|
+
re-enables pointer events for itself. */
|
|
1623
|
+
pointer-events: none;
|
|
1624
|
+
background: none;
|
|
1625
|
+
border: 0;
|
|
1626
|
+
box-shadow: none;
|
|
1627
|
+
color: var(--mirk-fg);
|
|
1628
|
+
}
|
|
1629
|
+
.hcms-inline > *,
|
|
1630
|
+
.hcms-inline-layer > * { pointer-events: auto; }
|
|
1631
|
+
.hcms-inline-layer { position: absolute; inset: 0; pointer-events: none; }
|
|
1632
|
+
|
|
1633
|
+
.hcms-inline-bar {
|
|
1634
|
+
position: absolute;
|
|
1635
|
+
left: 50%;
|
|
1636
|
+
bottom: 16px;
|
|
1637
|
+
transform: translateX(-50%);
|
|
1638
|
+
max-width: min(560px, calc(100vw - 32px));
|
|
1639
|
+
display: flex;
|
|
1640
|
+
flex-direction: column;
|
|
1641
|
+
gap: 6px;
|
|
1642
|
+
}
|
|
1643
|
+
|
|
1644
|
+
.hcms-inline-notice,
|
|
1645
|
+
.hcms-inline-error {
|
|
1646
|
+
padding: 8px 12px;
|
|
1647
|
+
border-radius: 8px;
|
|
1648
|
+
font-size: 14px;
|
|
1649
|
+
line-height: 1.4;
|
|
1650
|
+
border: 1px solid var(--mirk-input-border);
|
|
1651
|
+
background: var(--mirk-bg);
|
|
1652
|
+
color: var(--mirk-fg);
|
|
1653
|
+
box-shadow: 0 12px 32px -20px rgba(43, 36, 27, 0.5);
|
|
1654
|
+
}
|
|
1655
|
+
.hcms-inline-notice { white-space: pre-line; }
|
|
1656
|
+
.hcms-inline-error { border-color: var(--mirk-destructive); color: var(--mirk-destructive); }
|
|
1657
|
+
.hcms-inline-notice[hidden],
|
|
1658
|
+
.hcms-inline-error[hidden] { display: none; }
|
|
1659
|
+
|
|
1660
|
+
.hcms-inline-pop {
|
|
1661
|
+
position: absolute;
|
|
1662
|
+
top: 0;
|
|
1663
|
+
left: 0;
|
|
1664
|
+
box-sizing: border-box;
|
|
1665
|
+
width: min(340px, calc(100vw - 24px));
|
|
1666
|
+
max-height: calc(100dvh - 24px);
|
|
1667
|
+
overflow: auto;
|
|
1668
|
+
padding: 16px;
|
|
1669
|
+
border-radius: 8px;
|
|
1670
|
+
border: 1px solid var(--mirk-input-border);
|
|
1671
|
+
background: var(--mirk-bg);
|
|
1672
|
+
color: var(--mirk-fg);
|
|
1673
|
+
box-shadow: 0 16px 40px -22px rgba(43, 36, 27, 0.55);
|
|
1674
|
+
/* Above the handles. They are positioned with z-index: 1 while the popover
|
|
1675
|
+
sat at auto, so a handle painted over the very field it had just opened
|
|
1676
|
+
and covered the text in it. The popover is what someone is using; a handle
|
|
1677
|
+
is only an offer to open one. */
|
|
1678
|
+
z-index: 2;
|
|
1679
|
+
}
|
|
1680
|
+
.hcms-inline-pop[hidden] { display: none; }
|
|
1681
|
+
.hcms-inline-pop-header {
|
|
1682
|
+
display: flex;
|
|
1683
|
+
align-items: center;
|
|
1684
|
+
justify-content: space-between;
|
|
1685
|
+
gap: 16px;
|
|
1686
|
+
margin-bottom: 16px;
|
|
1687
|
+
font-size: 14px;
|
|
1688
|
+
}
|
|
1689
|
+
.hcms-shell .hcms-inline-pop-close {
|
|
1690
|
+
display: inline-flex;
|
|
1691
|
+
align-items: center;
|
|
1692
|
+
justify-content: center;
|
|
1693
|
+
min-width: 36px;
|
|
1694
|
+
min-height: 36px;
|
|
1695
|
+
padding: 4px;
|
|
1696
|
+
}
|
|
1697
|
+
|
|
1698
|
+
.hcms-inline-item-controls {
|
|
1699
|
+
position: absolute;
|
|
1700
|
+
top: 0;
|
|
1701
|
+
left: 0;
|
|
1702
|
+
z-index: 1;
|
|
1703
|
+
will-change: transform;
|
|
1704
|
+
display: flex;
|
|
1705
|
+
align-items: center;
|
|
1706
|
+
gap: 2px;
|
|
1707
|
+
}
|
|
1708
|
+
.hcms-inline-item-controls[hidden],
|
|
1709
|
+
.hcms-inline-handle[hidden] { display: none; }
|
|
1710
|
+
.hcms-inline-item-controls.has-open-settings { z-index: 3; }
|
|
1711
|
+
.hcms-inline-settings { position: relative; display: flex; flex: none; }
|
|
1712
|
+
.hcms-inline-settings[hidden],
|
|
1713
|
+
.hcms-inline-settings-menu[hidden] { display: none; }
|
|
1714
|
+
.hcms-inline-settings-menu {
|
|
1715
|
+
position: absolute;
|
|
1716
|
+
top: calc(100% + 6px);
|
|
1717
|
+
right: 0;
|
|
1718
|
+
min-width: 120px;
|
|
1719
|
+
padding: 4px;
|
|
1720
|
+
border: 1px solid var(--mirk-input-border);
|
|
1721
|
+
border-radius: 5px;
|
|
1722
|
+
background: var(--mirk-bg);
|
|
1723
|
+
box-shadow: 0 8px 24px #0003;
|
|
1724
|
+
}
|
|
1725
|
+
.hcms-inline-settings-menu button {
|
|
1726
|
+
display: block;
|
|
1727
|
+
box-sizing: border-box;
|
|
1728
|
+
width: 100%;
|
|
1729
|
+
padding: 10px 12px;
|
|
1730
|
+
border: 0;
|
|
1731
|
+
background: transparent;
|
|
1732
|
+
color: var(--mirk-destructive);
|
|
1733
|
+
font: inherit;
|
|
1734
|
+
text-align: left;
|
|
1735
|
+
cursor: pointer;
|
|
1736
|
+
}
|
|
1737
|
+
.hcms-inline-settings-menu button:hover,
|
|
1738
|
+
.hcms-inline-settings-menu button:focus-visible {
|
|
1739
|
+
background: var(--mirk-bevel-bg);
|
|
1740
|
+
outline: 1px solid var(--mirk-focus-color);
|
|
1741
|
+
}
|
|
1742
|
+
|
|
1743
|
+
/* Buttons flow within the positioned item container. */
|
|
1744
|
+
.hcms-inline-row-controls {
|
|
1745
|
+
display: flex;
|
|
1746
|
+
gap: 2px;
|
|
1747
|
+
}
|
|
1748
|
+
.hcms-inline-row-controls[hidden] { display: none; }
|
|
1749
|
+
|
|
1750
|
+
.hcms-inline-list-add[hidden] { display: none; }
|
|
1751
|
+
|
|
1752
|
+
.hcms-shell.hcms-inline-ghost {
|
|
1753
|
+
box-sizing: border-box;
|
|
1754
|
+
position: relative;
|
|
1755
|
+
display: flex;
|
|
1756
|
+
align-items: center;
|
|
1757
|
+
justify-content: center;
|
|
1758
|
+
flex: none;
|
|
1759
|
+
max-width: 100%;
|
|
1760
|
+
min-width: 0;
|
|
1761
|
+
margin: 8px 0 0;
|
|
1762
|
+
padding: 0;
|
|
1763
|
+
border: 1px dashed color-mix(in srgb, currentColor 25%, transparent);
|
|
1764
|
+
border-radius: 3px;
|
|
1765
|
+
background: color-mix(in srgb, currentColor 3%, transparent);
|
|
1766
|
+
color: inherit;
|
|
1767
|
+
list-style: none;
|
|
1768
|
+
}
|
|
1769
|
+
.hcms-shell.hcms-inline-ghost[hidden] { display: none; }
|
|
1770
|
+
tr.hcms-shell.hcms-inline-ghost { display: table-row; }
|
|
1771
|
+
.hcms-inline-ghost-cell { padding: 0; text-align: center; vertical-align: middle; }
|
|
1772
|
+
|
|
1773
|
+
.hcms-shell .hcms-inline-handle,
|
|
1774
|
+
.hcms-shell .hcms-inline-list-button {
|
|
1775
|
+
display: inline-flex;
|
|
1776
|
+
align-items: center;
|
|
1777
|
+
justify-content: center;
|
|
1778
|
+
min-width: 36px;
|
|
1779
|
+
min-height: 36px;
|
|
1780
|
+
padding: 4px;
|
|
1781
|
+
line-height: 1;
|
|
1782
|
+
}
|
|
1783
|
+
.hcms-inline-handle .mirk-button__label,
|
|
1784
|
+
.hcms-inline-list-button .mirk-button__label {
|
|
1785
|
+
display: inline-flex;
|
|
1786
|
+
align-items: center;
|
|
1787
|
+
gap: 6px;
|
|
1788
|
+
line-height: 1;
|
|
1789
|
+
}
|
|
1790
|
+
.hcms-inline-icon { display: block; width: 24px; height: 24px; flex: none; }
|
|
1791
|
+
.hcms-inline-handle .hcms-inline-icon { width: 20.4px; height: 20.4px; transform: translateY(-1px); }
|
|
1792
|
+
.hcms-inline-list-add .hcms-inline-icon { width: 16.8px; height: 16.8px; }
|
|
1793
|
+
.hcms-shell .hcms-inline-list-add { padding-inline: 10px; }
|
|
1794
|
+
|
|
1795
|
+
.hcms-inline-list-button {
|
|
1796
|
+
flex: none;
|
|
1797
|
+
}
|
|
1798
|
+
.hcms-inline-list-button[hidden] { display: none; }
|
|
1799
|
+
.hcms-shell .hcms-inline-list-button:disabled {
|
|
1800
|
+
opacity: 1;
|
|
1801
|
+
color: #626B96;
|
|
1802
|
+
background: var(--mirk-bevel-bg);
|
|
1803
|
+
border-color: var(--mirk-bevel-tl) var(--mirk-bevel-br) var(--mirk-bevel-br) var(--mirk-bevel-tl);
|
|
1804
|
+
}
|
|
1805
|
+
.hcms-shell .hcms-inline-list-button:disabled .mirk-button__label { translate: none; }
|
|
1806
|
+
|
|
1807
|
+
/* A finger is not a mouse pointer: on touch the same three controls get the
|
|
1808
|
+
44px target the platform guidelines ask for. */
|
|
1809
|
+
@media (pointer: coarse) {
|
|
1810
|
+
.hcms-shell .hcms-inline-handle,
|
|
1811
|
+
.hcms-shell .hcms-inline-list-button {
|
|
1812
|
+
min-width: 44px;
|
|
1813
|
+
min-height: 44px;
|
|
1814
|
+
}
|
|
1815
|
+
}
|
|
1816
|
+
|
|
1817
|
+
.hcms-inline-toggle { align-self: center; }
|
|
1818
|
+
.hcms-inline-toggle[hidden] { display: none; }
|
|
1819
|
+
|
|
1820
|
+
/* Fields with no visible anchor can still be edited through the sidebar. */
|
|
1821
|
+
.hcms-inline-handoff {
|
|
1822
|
+
display: flex;
|
|
1823
|
+
align-items: center;
|
|
1824
|
+
gap: 10px;
|
|
1825
|
+
padding: 6px 6px 6px 12px;
|
|
1826
|
+
border-radius: 999px;
|
|
1827
|
+
font-size: 13px;
|
|
1828
|
+
border: 1px solid var(--mirk-input-border);
|
|
1829
|
+
background: var(--mirk-bg);
|
|
1830
|
+
color: var(--mirk-fg);
|
|
1831
|
+
align-self: center;
|
|
1832
|
+
}
|
|
1833
|
+
.hcms-inline-handoff[hidden] { display: none; }
|
|
1834
|
+
|
|
1835
|
+
/* Selected fields only. Scoped to the inline host: [data-hcms-shell] is on BOTH
|
|
1836
|
+
hosts, so an unscoped rule hides the sidebar's whole form too. */
|
|
1837
|
+
.hcms-inline .hcms-form [data-hcms-path] { display: none; }
|
|
1838
|
+
.hcms-inline .hcms-form [data-hcms-path].is-hcms-inline-onpath,
|
|
1839
|
+
.hcms-inline .hcms-form [data-hcms-path].is-hcms-inline-active { display: block; }
|
|
1840
|
+
|
|
1841
|
+
.hcms-inline .hcms-form .is-hcms-inline-onpath,
|
|
1842
|
+
.hcms-inline .hcms-form {
|
|
1843
|
+
margin: 0;
|
|
1844
|
+
padding: 0;
|
|
1845
|
+
border: 0;
|
|
1846
|
+
border-radius: 0;
|
|
1847
|
+
box-shadow: none;
|
|
1848
|
+
background: transparent;
|
|
1849
|
+
min-width: 0;
|
|
1850
|
+
min-height: 0;
|
|
1851
|
+
width: 100%;
|
|
1852
|
+
}
|
|
1853
|
+
.hcms-inline-pop .hcms-object-title,
|
|
1854
|
+
.hcms-inline-pop .hcms-array-header,
|
|
1855
|
+
.hcms-inline-pop .hcms-drag-handle,
|
|
1856
|
+
.hcms-inline-pop [data-hcms-action="add"],
|
|
1857
|
+
.hcms-inline-pop [data-hcms-action="remove"],
|
|
1858
|
+
.hcms-inline-pop [data-hcms-action="move-up"],
|
|
1859
|
+
.hcms-inline-pop [data-hcms-action="move-down"],
|
|
1860
|
+
.hcms-inline-pop .hcms-card-controls { display: none; }
|
|
1861
|
+
.hcms-inline .hcms-form .hcms-field.is-hcms-inline-active {
|
|
1862
|
+
display: flex;
|
|
1863
|
+
gap: 8px;
|
|
1864
|
+
padding: 0;
|
|
1865
|
+
margin: 0 0 16px;
|
|
1866
|
+
border: 0;
|
|
1867
|
+
min-width: min(260px, 100%);
|
|
1868
|
+
}
|
|
1869
|
+
.hcms-inline .hcms-form .hcms-field.is-hcms-inline-active:last-child { margin-bottom: 0; }
|
|
1870
|
+
.hcms-shell.pixel-quiet .hcms-inline-pop .mirk-input,
|
|
1871
|
+
.hcms-shell.pixel-quiet .hcms-inline-pop .mirk-textarea {
|
|
1872
|
+
box-sizing: border-box;
|
|
1873
|
+
width: 100%;
|
|
1874
|
+
min-width: min(260px, 100%);
|
|
1875
|
+
min-height: 42px;
|
|
1876
|
+
padding: 10px 12px;
|
|
1877
|
+
border: 1px solid var(--mirk-input-border);
|
|
1878
|
+
background: var(--mirk-input-bg);
|
|
1879
|
+
}
|
|
1880
|
+
.hcms-inline-pop .mirk-input:focus-visible,
|
|
1881
|
+
.hcms-inline-pop .mirk-textarea:focus-visible {
|
|
1882
|
+
outline: 2px solid var(--mirk-focus-color);
|
|
1883
|
+
outline-offset: 2px;
|
|
1884
|
+
}
|
|
1885
|
+
|
|
1886
|
+
.hcms-inline-highlight {
|
|
1887
|
+
position: absolute;
|
|
1888
|
+
top: 0;
|
|
1889
|
+
left: 0;
|
|
1890
|
+
pointer-events: none;
|
|
1891
|
+
border: 2px solid var(--mirk-focus-color);
|
|
1892
|
+
border-radius: 4px;
|
|
1893
|
+
box-sizing: border-box;
|
|
1894
|
+
will-change: transform;
|
|
1895
|
+
}
|
|
1896
|
+
.hcms-inline-highlight[hidden] { display: none; }
|