Plugin Directory

Changeset 3842005


Ignore:
Timestamp:
12/03/2026 09:13:00 AM (14 hours ago)
Author:
quantumcloud
Message:

Release 9.7 (upload 4).3

Location:
chatbot/trunk/includes/chatbot
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • chatbot/trunk/includes/chatbot/CHANGELOG.md

    r3836976 r3842005  
    11# Changelog
    22
    3 ## Unreleased (lead capture plan, step 1: lead source and honest consent)
     3## 0.67.2 (Automator removed)
     4
     5Owner, 2 December 2026: "remove automator completely from WPBot free and pro".
     6- Saving a chat session no longer schedules Automator's delayed trigger (`wpbot_automator_delayed_trigger`, `Session_Store::after_save()`). `qcld_wpbot_chat/session_saved` fires as before.
     7
     8## 0.67.1 (Message box: two rows for long text)
     9
     10Owner, 2 December 2026 (via the Voice rebuild session): a long message wrapped in the left part of the box only, beside Try asking, the upload button, the mic and Send.
     11- **Two rows once the text wraps:** `window.js` `size()` measures the text in the one-row layout and adds `.qcw-multi` when it needs more than one line; the text then takes the full width and every button after it goes to a row underneath, on the right (`window.css`). Short or empty text keeps one row. Floating island's pill becomes a rounded box in two rows.
     12- **Try asking hides while typing** (owner's option 1): it only helps on an empty box (`.qcw-typing`). The upload button and the mic stay.
     13
     14## 0.67.0 (Lead capture, session-review fixes, Train bulk approve; owner's 1 December list)
     15
     16### Owner's bug list (1 December 2026)
     17- **Language item without a picker:** the window menu showed "Language" whenever the site had two or more languages, but the picker is printed only when the host turns it on (the page decides the language by default), so a click emptied the menu. The item now shows only when there is a picker (`templates/window.php` keeps the source only when the picker printed something; `window.js` checks for it). The copied picker has no ids and passes a change on once.
     18- **Google Calendar beside the window:** the calendar panel of Conversational Forms' calendar field opened at the bottom of the page (its stylesheet was written for the old floating windows). It now floats beside the window, on the side facing the page; full screen on phones (`window.css`).
     19
     20### Lead capture plan, step 1: lead source and honest consent
    421Owner's lead capture and settings plan, 30 November 2026.
    522- **`qcld_wpbot_chat/lead_captured` (additive):** every lead now carries `channel`, `consent` and an optional `source` (where in the chat it came from). `consent` is `marketing` only when the visitor asked to subscribe or ticked the consent box; everything else is `contact`, so AI Marketing keeps it as a lead and never emails newsletters to it (`Leads::consent_for()`). Before, leads fired without a consent and counted as subscriptions. An existing subscriber who opts in again is passed on too. The REST `lead` route reads `source` and `consent`.
  • chatbot/trunk/includes/chatbot/assets/window/window.css

    r3834625 r3842005  
    11041104        color: color-mix(in srgb, var(--qcw-fg) 60%, var(--qcw-composer)) !important;
    11051105}
     1106/* Owner, 2 December 2026: a long message wrapped in the left part of the box only, beside the buttons.
     1107   Try asking only helps on an empty box, so it hides while the visitor types. Once the text wraps
     1108   (window.js size() adds .qcw-multi), the text takes the full width and every button after it goes to a
     1109   row underneath, on the right. */
     1110.qcw #wp-chatbot-editor-container.qcw-typing .qcw-try {
     1111        display: none !important;
     1112}
     1113.qcw #wp-chatbot-board-container #wp-chatbot-editor-container.qcw-multi {
     1114        flex-wrap: wrap;
     1115        justify-content: flex-end;
     1116        row-gap: 2px;
     1117        padding-top: 6px !important;
     1118}
     1119.qcw #wp-chatbot-board-container #wp-chatbot-editor-container.qcw-multi #wp-chatbot-editor {
     1120        flex: 1 0 100%;
     1121        padding: 4px 8px 0 0 !important;
     1122}
     1123/* Floating island's pill becomes a rounded box with two rows. */
     1124.qcw.qcw-d-island #wp-chatbot-board-container #wp-chatbot-editor-container.qcw-multi {
     1125        border-radius: 22px !important;
     1126}
    11061127/* The buttons beside the message: the AI file upload (the hosts' js/qcld-wp-chatbot-plugin.js) and the
    11071128   Voice add-on's mic (#botstartvoice / #botstartvoicemicro, a Font Awesome glyph nothing styled). Owner,
    … …  
    12931314        clip-path: inset(0 0 0 0);
    12941315}
     1316/* ---------- Google Calendar (Conversational Forms' calendar field). Its own stylesheet places the
     1317   panel beside the old floating windows (position:absolute; right:100%); in this window
     1318   .wp-chatbot-container is in the page flow, so the panel ended up at the bottom of the page (owner,
     1319   1 December 2026). It now floats beside the window, on the side facing the page, like the product
     1320   details; full screen on phones. ---------- */
     1321.qcw .wp-chatbot-gcal-container.active-chatbot-gcal-details {
     1322        position: fixed !important;
     1323        top: auto !important;
     1324        right: calc(var(--qcw-edge) + var(--qcw-w) + 12px) !important;
     1325        bottom: var(--qcw-lift) !important;
     1326        left: auto !important;
     1327        z-index: 9999998 !important;
     1328        width: min(600px, calc(100vw - var(--qcw-w) - 2 * var(--qcw-edge) - 12px)) !important;
     1329        max-height: calc(100vh - var(--qcw-lift) - 24px) !important;
     1330        margin: 0 !important;
     1331        overflow: auto !important;
     1332}
     1333.qcw.qcw-side-left .wp-chatbot-gcal-container.active-chatbot-gcal-details {
     1334        right: auto !important;
     1335        left: calc(var(--qcw-edge) + var(--qcw-w) + 12px) !important;
     1336}
     1337.qcw .wp-chatbot-gcal-container .wp-chatbot-gcal-details {
     1338        width: auto !important;
     1339        margin: 0 !important;
     1340}
     1341@media (max-width: 768px) {
     1342        .qcw .wp-chatbot-gcal-container.active-chatbot-gcal-details {
     1343                top: 0 !important;
     1344                right: 0 !important;
     1345                bottom: 0 !important;
     1346                left: 0 !important;
     1347                width: auto !important;
     1348                max-height: none !important;
     1349                z-index: 10000000 !important;
     1350        }
     1351}
     1352
    12951353@media (prefers-reduced-motion: reduce) {
    12961354        .qcw .wp-chatbot-product-container,
  • chatbot/trunk/includes/chatbot/assets/window/window.js

    r3834625 r3842005  
    163163                                return;
    164164                        }
    165                         // Hidden (window closed) or empty: back to the stylesheet's one-line height.
     165                        var box = editor.parentNode;
     166                        // Hidden (window closed) or empty: back to the stylesheet's one-line height and one row.
    166167                        if ( '' === editor.value || null === editor.offsetParent ) {
    167168                                editor.style.height = '';
    168169                                editor.style.overflowY = 'hidden';
    169                                 return;
    170                         }
     170                                box.classList.remove( 'qcw-typing', 'qcw-multi' );
     171                                return;
     172                        }
     173                        // Try asking only helps on an empty box (owner, 2 December 2026).
     174                        box.classList.toggle( 'qcw-typing', '' !== editor.value.trim() );
     175                        // Once the text wraps, it gets the full width and the buttons go underneath (owner, 2 December
     176                        // 2026: a long message used only the left part of the box). Measured in the one-row layout every
     177                        // time, so the layout never flips back and forth at the edge.
     178                        box.classList.remove( 'qcw-multi' );
    171179                        editor.style.height = 'auto';
     180                        var cs = window.getComputedStyle( editor );
     181                        var line = parseFloat( cs.lineHeight ) || 1.3 * parseFloat( cs.fontSize ) || 21;
     182                        var pad = ( parseFloat( cs.paddingTop ) || 0 ) + ( parseFloat( cs.paddingBottom ) || 0 );
     183                        if ( editor.scrollHeight > pad + line * 1.5 ) {
     184                                box.classList.add( 'qcw-multi' );
     185                                editor.style.height = 'auto';
     186                        }
    172187                        var h = Math.max( editor.scrollHeight, 0 );
    173188                        editor.style.height = Math.min( 110, h ) + 'px';
    … …  
    474489                        } );
    475490                        var group2 = [ 'sound', 'text', 'lang' ].filter( function ( k ) {
    476                                 return list.indexOf( k ) > -1 && ( 'lang' !== k || langSource() );
     491                                // The Language item only when there is a picker to show.
     492                                return list.indexOf( k ) > -1 && ( 'lang' !== k || ( langSource() && langSource().firstElementChild ) );
    477493                        } );
    478494                        group1.forEach( function ( k ) {
    … …  
    637653                                                menu.innerHTML = '';
    638654                                                var box = el( 'div', { class: 'qcw-lang' } );
    639                                                 box.appendChild( src.firstElementChild ? src.firstElementChild.cloneNode( true ) : document.createTextNode( '' ) );
     655                                                if ( ! src.firstElementChild ) {
     656                                                        closeMenu();
     657                                                        return;
     658                                                }
     659                                                var copy = src.firstElementChild.cloneNode( true );
     660                                                // The copy has no ids: the page keeps one #wpbot_language, so the add-on's handler runs once.
     661                                                copy.removeAttribute( 'id' );
     662                                                Array.prototype.forEach.call( copy.querySelectorAll( '[id]' ), function ( n ) {
     663                                                        n.removeAttribute( 'id' );
     664                                                } );
     665                                                box.appendChild( copy );
    640666                                                menu.appendChild( box );
    641                                                 // Changes on the copy are passed to the add-on's own control.
     667                                                // Changes on the copy are passed to the add-on's own control, once.
    642668                                                box.addEventListener( 'change', function ( ev ) {
    643669                                                        var orig = src.querySelector( 'select' );
    644670                                                        if ( orig && 'SELECT' === ev.target.tagName ) {
    645671                                                                orig.value = ev.target.value;
    646                                                                 orig.dispatchEvent( new Event( 'change', { bubbles: true } ) );
    647672                                                                if ( window.jQuery ) {
    648673                                                                        window.jQuery( orig ).trigger( 'change' );
     674                                                                } else {
     675                                                                        orig.dispatchEvent( new Event( 'change', { bubbles: true } ) );
    649676                                                                }
    650677                                                                closeMenu();
  • chatbot/trunk/includes/chatbot/chatbot.php

    r3836976 r3842005  
    2020require_once __DIR__ . '/loader.php';
    2121
    22 qcld_wpbot_chat_register_version( '0.66.0', __DIR__ );
     22qcld_wpbot_chat_register_version( '0.67.2', __DIR__ );
Note: See TracChangeset for help on using the changeset viewer.