-
Notifications
You must be signed in to change notification settings - Fork 58
Expand file tree
/
Copy pathoverlay.css
More file actions
126 lines (113 loc) · 2.76 KB
/
Copy pathoverlay.css
File metadata and controls
126 lines (113 loc) · 2.76 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
/*
* overlay.css — persistent left-gutter change bars for agent-edited regions.
*
* Wrap any HTML region that Claude edited with:
* <span data-cf-change="ch-your-slug">…edited content…</span>
*
* Works alongside make-pages-interactive's own feedback styles without touching them.
* Pair with overlay.js to number the changes and build the floating "Changes (N)" chip.
*
* License: MIT (same as the make-pages-interactive repository).
*/
/* Left-gutter bar on every changed region. */
[data-cf-change] {
position: relative;
border-left: 4px solid #ffd33d;
padding-left: 14px !important;
margin-left: -18px !important;
background: linear-gradient(90deg, rgba(255, 211, 61, 0.10) 0%, rgba(255, 211, 61, 0) 60%);
border-radius: 2px;
transition: background 0.3s;
}
[data-cf-change]:hover {
background: linear-gradient(90deg, rgba(255, 211, 61, 0.18) 0%, rgba(255, 211, 61, 0.02) 60%);
}
/* Numbered badge — overlay.js sets data-cf-num. */
[data-cf-change]::before {
content: attr(data-cf-num);
position: absolute;
left: -32px;
top: 4px;
background: #ffd33d;
color: #1f2328;
font-size: 11px;
font-weight: 700;
width: 20px;
height: 20px;
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
font-family: -apple-system, sans-serif;
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}
/* Floating "Changes (N)" jump chip, top-right corner. */
#changes-chip {
position: fixed;
top: 16px;
right: 16px;
background: #fff;
border: 1px solid #d0d7de;
border-radius: 8px;
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
font-size: 13px;
z-index: 9999;
max-width: 320px;
font-family: -apple-system, BlinkMacSystemFont, sans-serif;
}
#changes-chip-header {
padding: 8px 14px;
cursor: pointer;
font-weight: 600;
display: flex;
align-items: center;
gap: 8px;
user-select: none;
}
#changes-chip-header::before {
content: "●";
color: #ffd33d;
font-size: 14px;
}
#changes-chip-list {
display: none;
border-top: 1px solid #d0d7de;
max-height: 60vh;
overflow-y: auto;
}
#changes-chip.open #changes-chip-list {
display: block;
}
#changes-chip-list a {
display: block;
padding: 8px 14px;
color: #1f2328;
text-decoration: none;
border-bottom: 1px solid #f0f3f6;
font-size: 12px;
line-height: 1.4;
}
#changes-chip-list a:hover {
background: #f6f8fa;
}
#changes-chip-list a:last-child {
border-bottom: 0;
}
#changes-chip-list .num {
display: inline-block;
width: 18px;
height: 18px;
background: #ffd33d;
color: #1f2328;
border-radius: 50%;
text-align: center;
font-size: 10px;
font-weight: 700;
line-height: 18px;
margin-right: 8px;
vertical-align: middle;
}
/* Reserve left-margin space so gutter badges have room. */
body {
padding-left: 56px !important;
}