bunnyquery 1.8.6 → 1.8.9
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/bunnyquery.css +95 -5
- package/bunnyquery.js +1470 -111
- package/dist/engine.cjs +1071 -80
- package/dist/engine.cjs.map +1 -1
- package/dist/engine.d.mts +608 -169
- package/dist/engine.d.ts +608 -169
- package/dist/engine.mjs +1048 -81
- package/dist/engine.mjs.map +1 -1
- package/package.json +1 -1
- package/src/engine/budget.ts +207 -68
- package/src/engine/config.ts +48 -0
- package/src/engine/errors.ts +38 -0
- package/src/engine/history.ts +546 -6
- package/src/engine/host.ts +7 -0
- package/src/engine/image_preview.ts +0 -0
- package/src/engine/index.ts +15 -1
- package/src/engine/indexing_groups.ts +248 -3
- package/src/engine/links.ts +143 -6
- package/src/engine/office.ts +24 -1
- package/src/engine/prompts/chat_system_prompt.ts +1 -1
- package/src/engine/requests.ts +164 -11
- package/src/engine/session.ts +544 -35
- package/src/widget.css +35 -1
- package/styles/chat.css +60 -4
package/src/widget.css
CHANGED
|
@@ -757,7 +757,7 @@
|
|
|
757
757
|
cursor: pointer;
|
|
758
758
|
z-index: 1;
|
|
759
759
|
}
|
|
760
|
-
.bq-attach-btn:hover:not(:disabled) { color: var(--bq-main); }
|
|
760
|
+
.bq-attach-btn:hover:not(:disabled) { color: var(--bq-main);transform: none; }
|
|
761
761
|
.bq-attach-btn:disabled { opacity: 0.5; cursor: not-allowed; }
|
|
762
762
|
.bq-attach-input { display: none; }
|
|
763
763
|
.bq-input {
|
|
@@ -821,6 +821,40 @@
|
|
|
821
821
|
pointer-events: none;
|
|
822
822
|
}
|
|
823
823
|
.bq-attachment.is-uploading > * { position: relative; z-index: 1; }
|
|
824
|
+
/* The two indeterminate phases, both drawn as a barber pole over the full chip
|
|
825
|
+
because neither has a percentage to show (mirror of agent.vue):
|
|
826
|
+
is-preparing: before the first byte-progress event, while get-signed-url
|
|
827
|
+
is in flight. A bar at 0% here reads as a stalled upload.
|
|
828
|
+
is-finalizing: bytes done, post-upload work (signed url, src:: record,
|
|
829
|
+
indexing dispatch) still running. A bar frozen at a solid
|
|
830
|
+
100% reads as hung.
|
|
831
|
+
Between them the bar is determinate and driven by --att-progress. */
|
|
832
|
+
.bq-attachment.is-preparing::before,
|
|
833
|
+
.bq-attachment.is-finalizing::before {
|
|
834
|
+
width: 100%;
|
|
835
|
+
background: repeating-linear-gradient(
|
|
836
|
+
-45deg,
|
|
837
|
+
color-mix(in srgb, var(--bq-main) 22%, transparent) 0 8px,
|
|
838
|
+
color-mix(in srgb, var(--bq-main) 10%, transparent) 8px 16px
|
|
839
|
+
);
|
|
840
|
+
background-size: 22.6px 100%;
|
|
841
|
+
animation: bq-att-barber 0.8s linear infinite;
|
|
842
|
+
transition: none;
|
|
843
|
+
}
|
|
844
|
+
.bq-attachment.is-preparing .bq-attachment-meta::after,
|
|
845
|
+
.bq-attachment.is-finalizing .bq-attachment-meta::after {
|
|
846
|
+
content: ".";
|
|
847
|
+
display: inline-block;
|
|
848
|
+
width: 1.1em;
|
|
849
|
+
text-align: left;
|
|
850
|
+
animation: bq-att-dots 1.2s steps(1) infinite;
|
|
851
|
+
}
|
|
852
|
+
@keyframes bq-att-barber { to { background-position: 22.6px 0; } }
|
|
853
|
+
@keyframes bq-att-dots {
|
|
854
|
+
0% { content: "."; }
|
|
855
|
+
33% { content: ".."; }
|
|
856
|
+
66% { content: "..."; }
|
|
857
|
+
}
|
|
824
858
|
.bq-attachment.is-error { border-color: var(--bq-danger); background: var(--bq-danger-bg); }
|
|
825
859
|
.bq-attachment.is-error .bq-attachment-meta,
|
|
826
860
|
.bq-attachment.is-error .bq-attachment-name { color: var(--bq-danger); }
|
package/styles/chat.css
CHANGED
|
@@ -28,6 +28,7 @@
|
|
|
28
28
|
.bq-message.is-assistant { justify-content: flex-start; }
|
|
29
29
|
|
|
30
30
|
.bq-bubble {
|
|
31
|
+
max-width: 100%;
|
|
31
32
|
padding: 0.55rem 0.7rem;
|
|
32
33
|
border: 1px solid var(--bq-line);
|
|
33
34
|
white-space: pre-wrap;
|
|
@@ -222,6 +223,24 @@
|
|
|
222
223
|
state does not know. A slow fade says "pending" without claiming progress. */
|
|
223
224
|
.bq-index-group.is-resolving .bq-index-icon svg { animation: bq-index-fade 1.6s ease-in-out infinite; }
|
|
224
225
|
@keyframes bq-index-fade { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }
|
|
226
|
+
/* Expand-triggered history fetch: spinning arrows in the row head while the
|
|
227
|
+
run's passes are being paged in. A SEPARATE element from the status icon on
|
|
228
|
+
purpose — the row keeps its verdict (green check, grey clock) and this only
|
|
229
|
+
says "fetching more detail about it", whatever that verdict is. */
|
|
230
|
+
.bq-index-fetch {
|
|
231
|
+
width: 0.85rem;
|
|
232
|
+
height: 0.85rem;
|
|
233
|
+
flex: none;
|
|
234
|
+
margin-left: 0.35rem;
|
|
235
|
+
color: var(--bq-muted);
|
|
236
|
+
display: inline-flex;
|
|
237
|
+
}
|
|
238
|
+
.bq-index-fetch svg { width: 100%; height: 100%; display: block; animation: bq-index-spin 1.1s linear infinite; }
|
|
239
|
+
/* The in-row loading note under an OPEN row while its passes stream in. */
|
|
240
|
+
.bq-index-note .bq-loader { margin-left: 0.15rem; }
|
|
241
|
+
@media (prefers-reduced-motion: reduce) {
|
|
242
|
+
.bq-index-fetch svg { animation-duration: 3s; }
|
|
243
|
+
}
|
|
225
244
|
@media (prefers-reduced-motion: reduce) {
|
|
226
245
|
.bq-index-group.is-active .bq-index-icon svg { animation-duration: 3s; }
|
|
227
246
|
/* A fade has no end state to settle on, so it stops rather than slows. */
|
|
@@ -259,7 +278,7 @@
|
|
|
259
278
|
line-height: 1.3;
|
|
260
279
|
letter-spacing: 0.02em;
|
|
261
280
|
cursor: pointer;
|
|
262
|
-
box-shadow:
|
|
281
|
+
box-shadow: 2px 2px rgba(0, 0, 0, 0.12);
|
|
263
282
|
opacity: 0.8;
|
|
264
283
|
}
|
|
265
284
|
.bq-index-cancel:hover:not(.is-disabled) { background: var(--bq-warning-bg); color: var(--bq-warning); opacity: 1; }
|
|
@@ -313,10 +332,12 @@
|
|
|
313
332
|
font-size: 0.78rem;
|
|
314
333
|
color: var(--bq-muted);
|
|
315
334
|
}
|
|
316
|
-
/* An open row animates for as long as the file is indexing, which can be
|
|
317
|
-
|
|
335
|
+
/* An open row animates for as long as the file is indexing, which can be
|
|
336
|
+
minutes, and the user-side drafting bubble animates for as long as a draft
|
|
337
|
+
sits in the composer. Readers who ask for less motion get the static dots. */
|
|
318
338
|
@media (prefers-reduced-motion: reduce) {
|
|
319
|
-
.bq-index-tail .bq-loader::after
|
|
339
|
+
.bq-index-tail .bq-loader::after,
|
|
340
|
+
.bq-user-drafting .bq-loader::after { animation: none; content: '...'; }
|
|
320
341
|
}
|
|
321
342
|
.bq-index-note {
|
|
322
343
|
padding: 0 0.6rem 0.45rem;
|
|
@@ -482,3 +503,38 @@
|
|
|
482
503
|
.bq-md strong { font-weight: 600; }
|
|
483
504
|
.bq-md em { font-style: italic; }
|
|
484
505
|
.bq-md del { text-decoration: line-through; }
|
|
506
|
+
/* ---- host-page insulation -------------------------------------------------*/
|
|
507
|
+
/* The markdown above renders into whatever page this chat sits in: the admin
|
|
508
|
+
app with its own global stylesheet, or - for the embedded widget - a HOST
|
|
509
|
+
page with arbitrary CSS. Element-level globals leak straight into it, and
|
|
510
|
+
form controls are the class nothing above styles on purpose: the admin app
|
|
511
|
+
styles every <input> as a 3rem bordered mono text field, which turned a GFM
|
|
512
|
+
task-list checkbox into a giant text box. `revert` rolls each property back
|
|
513
|
+
to the BROWSER default (as if no author CSS existed), which is the honest
|
|
514
|
+
baseline for a control the markdown produced; `initial`/`unset` would
|
|
515
|
+
instead strip even the user-agent's own control styling. */
|
|
516
|
+
.bq-md input,
|
|
517
|
+
.bq-md select,
|
|
518
|
+
.bq-md textarea,
|
|
519
|
+
.bq-md button {
|
|
520
|
+
all: revert;
|
|
521
|
+
}
|
|
522
|
+
/* GFM task list: `- [x] item` renders as a disabled checkbox in the list item.
|
|
523
|
+
Re-state the little we DO want on top of the revert: sit on the text
|
|
524
|
+
baseline with a small gap, brand accent. The geometry (width/height/
|
|
525
|
+
min-height/padding) is pinned explicitly, at higher specificity than the
|
|
526
|
+
revert rule, so a host sheet whose input rules are more specific than
|
|
527
|
+
`.bq-md input` still loses the properties that actually break layout. */
|
|
528
|
+
.bq-md input[type="checkbox"] {
|
|
529
|
+
width: auto;
|
|
530
|
+
height: auto;
|
|
531
|
+
min-height: 0;
|
|
532
|
+
padding: 0;
|
|
533
|
+
margin: 0 0.4em 0.1em 0;
|
|
534
|
+
vertical-align: middle;
|
|
535
|
+
accent-color: var(--bq-main);
|
|
536
|
+
}
|
|
537
|
+
/* GitHub-style: a task-list item shows the checkbox INSTEAD of a bullet, not
|
|
538
|
+
next to one. :has() is safe here - every supported browser ships it, and a
|
|
539
|
+
miss only means a redundant bullet. */
|
|
540
|
+
.bq-md li:has(> input[type="checkbox"]:first-child) { list-style: none; }
|