Plugin Directory

Changeset 3211875


Ignore:
Timestamp:
12/22/2024 05:52:43 PM (16 months ago)
Author:
Elvin.Haci
Message:

1.0.1 UI improvements

Location:
cartlink-generator
Files:
14 added
8 edited

Legend:

Unmodified
Added
Removed
  • cartlink-generator/trunk/assets/admin-scripts.js

    r3211475 r3211875  
    1313        clearTimeout(timeout);
    1414
     15        jQuery(".gvncl_notfound").remove();
    1516        // Set a new timeout to delay the AJAX request
    1617        timeout = setTimeout(() => {
     
    3233                const suggestions = response.data;
    3334
     35               
    3436                // Create the dropdown
    3537                let dropdown = document.getElementById('autocomplete-dropdown');
     
    3840                    dropdown.id = 'autocomplete-dropdown';
    3941                    document.querySelector('.wrapautogen').appendChild(dropdown);
     42                }
     43
     44                if(suggestions==''){
     45                    jQuery("#autocomplete-dropdown").html('<p class="gvncl_notfound">No products found</p>');
     46                    return;
    4047                }
    4148
     
    6976                        dropdown.innerHTML = '';
    7077                        jQuery(".pregenerate").parent().show();
     78                        jQuery("#selected-products").show();
    7179                    });
    7280                });
  • cartlink-generator/trunk/assets/admin-styles.css

    r3211475 r3211875  
    11#selected-products .quantity{width:60px}
    2 #selected-products .product-row,.wrapnput{display:flex;padding:10px;max-width:100%;width:500px}
     2#selected-products .product-row,.wrapnput{display:flex;padding:10px;max-width:100%;}
    33#selected-products .product-row-inner{display:flex;align-self:center}
    44#selected-products .product-row>span{flex-grow:1;padding-right:10px}
     
    88#product-search{width:100%}
    99.autogenresponse{margin-top:30px;margin-left:10px;margin-right:10px}
    10 .wrapautogen{padding-left:15px}
     10
     11.wrapautogen{margin:20px}
     12/* General Styles */
     13#wpbody-content {
     14    font-family: Arial, sans-serif;
     15    background: #f9f9f9;
     16    padding: 20px;
     17    border-radius: 10px;
     18    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
     19    box-sizing: border-box;
     20}
     21
     22/* Page Title */
     23h1 {
     24    text-align: center;
     25    font-size: 2em;
     26    color: #333;
     27    margin-bottom: 30px;
     28}
     29
     30/* Search Box */
     31.wrapnput {
     32    display: flex;
     33    justify-content: center;
     34    margin-bottom: 20px;
     35    margin-left:0px;
     36    margin-right:0px;
     37}
     38
     39#product-search {
     40    width: 60%;
     41    padding: 12px 15px;
     42    font-size: 1.1em;
     43    border: 2px solid #ddd;
     44    border-radius: 30px;
     45    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
     46    transition: all 0.3s ease;
     47}
     48
     49#product-search:focus {
     50    outline: none;
     51    border-color: #007cba;
     52    box-shadow: 0 4px 8px rgba(0, 123, 186, 0.2);
     53}
     54
     55/* Autocomplete Dropdown */
     56#autocomplete-dropdown {
     57    margin-top: 10px;
     58    max-width: 60%;
     59    margin-left: auto;
     60    margin-right: auto;
     61    background: #fff;
     62    border: 0px solid #ddd;
     63    border-radius: 10px;
     64    overflow: hidden;
     65    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
     66}
     67
     68.autocomplete-item {
     69    padding: 10px 15px;
     70    font-size: 1em;
     71    cursor: pointer;
     72    transition: background 0.3s ease;
     73}
     74.gvncl_notfound{padding:10px}
     75.autocomplete-item:hover {
     76    background: #f0f8ff;
     77}
     78
     79/* Selected Products Section */
     80#selected-products {
     81    max-width: calc(60% - 40px);
     82    margin: 20px auto;
     83    padding: 10px;
     84    background: #fff;
     85    border: 1px solid #ddd;
     86    border-radius: 10px;
     87    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
     88}
     89
     90
     91.product-row {
     92    display: flex;
     93    align-items: center;
     94    justify-content: space-between;
     95    padding: 10px 15px;
     96    border-bottom: 1px solid #eee;
     97}
     98
     99.product-row:last-child {
     100    border-bottom: none;
     101}
     102
     103.product-row span {
     104    flex-grow: 1;
     105    font-size: 1.1em;
     106    color: #333;
     107}
     108
     109.product-row-inner {
     110    margin-left: 10px;
     111}
     112
     113.quantity, .price {
     114    width: 80px;
     115    padding: 5px 10px;
     116    font-size: 1em;
     117    border: 1px solid #ddd;
     118    border-radius: 5px;
     119}
     120
     121/* Generate Link Section */
     122#generate-link {
     123    display: block;
     124    margin: 20px auto;
     125    padding: 12px 30px;
     126    background: #007cba;
     127    color: #fff;
     128    font-size: 1.2em;
     129    border: none;
     130    border-radius: 30px;
     131    cursor: pointer;
     132    transition: background 0.3s ease;
     133}
     134
     135#generate-link:hover {
     136    background: #005f8c;
     137}
     138
     139/* Footer Section */
     140div[style*="margin-top:100px"] {
     141    text-align: center;
     142    font-size: 0.9em;
     143    color: #666;
     144}
     145
     146div[style*="margin-top:100px"] a {
     147    color: #007cba;
     148    text-decoration: none;
     149    font-weight: bold;
     150}
     151
     152div[style*="margin-top:100px"] a:hover {
     153    text-decoration: underline;
     154}
     155
     156/* Responsive Adjustments */
     157@media (max-width: 768px) {
     158    #selected-products,#autocomplete-dropdown,#product-search {
     159        width: 90%; max-width: 90% !important;
     160    }
     161
     162    #autocomplete-dropdown, #selected-products {
     163        max-width: 90%;
     164    }
     165}
     166
     167
     168/* Style for the Custom Discount and Expire Days sections */
     169#customdiscount, #expiredays {
     170    display: flex;
     171    align-items: center;
     172    justify-content: center;
     173    margin: 20px auto;
     174    font-size: 1.1em;
     175    color: #333;
     176}
     177
     178/* Input Fields */
     179#customdiscount input, #expiredays input {
     180    margin-left: 10px;
     181    padding: 10px;
     182    width: 80px;
     183    font-size: 1em;
     184    border: 1px solid #ddd;
     185    border-radius: 5px;
     186    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
     187    transition: all 0.3s ease;
     188}
     189
     190#customdiscount input:focus, #expiredays input:focus {
     191    outline: none;
     192    border-color: #007cba;
     193    box-shadow: 0 4px 8px rgba(0, 123, 186, 0.2);
     194}
     195
     196/* Label Alignment */
     197#customdiscount label, #expiredays label {
     198    display: flex;
     199    align-items: center;
     200    justify-content: space-between;
     201    font-size: 1.1em;
     202    font-weight: bold;
     203    color: #555;
     204}
     205
     206/* Container Wrapping */
     207#customdiscount, #expiredays {
     208    max-width: 400px;
     209    text-align: left;
     210}
     211
     212/* Responsive Adjustments */
     213@media (max-width: 768px) {
     214    #customdiscount, #expiredays {
     215        flex-direction: column;
     216        align-items: flex-start;
     217    }
     218
     219    #customdiscount input, #expiredays input {
     220        margin-left: 0;
     221        margin-top: 10px;
     222    }
     223}
  • cartlink-generator/trunk/cartlink-generator.php

    r3211475 r3211875  
    33 * Plugin Name: CartLink Generator for WooCommerce
    44 * Description: Create dynamic cart links with pre-filled products, quantities, and custom prices, perfect for businesses interacting via chat to reduce purchase steps and drive faster conversions.
    5  * Version: 1.0.0
     5 * Version: 1.0.1
    66 * Author: Guaven Labs
    77 * Text Domain: cartlink-generator
     
    1818define( 'GUAVEN_CARTLINK_GENERATOR_PATH', plugin_dir_path( __FILE__ ) );
    1919define( 'GUAVEN_CARTLINK_GENERATOR_URL', plugin_dir_url( __FILE__ ) );
    20 define( 'GUAVEN_CARTLINK_GENERATOR_VERSION', '1.0.0.2');
     20define( 'GUAVEN_CARTLINK_GENERATOR_VERSION', '1.0.1.0');
    2121
    2222
  • cartlink-generator/trunk/readme.txt

    r3211752 r3211875  
    88WC tested up to: 9.4
    99Requires Plugins: woocommerce
    10 Stable tag: 1.0.0
     10Stable tag: 1.0.1
    1111License: GPLv2 or later
    1212License URI: https://www.gnu.org/licenses/gpl-2.0.html
     
    1717
    1818Create pre-filled **cart and checkout links** for your customers with one click!
    19 CartLink Generator for WooCommerce empowers store owners and merchants to create dynamic cart links with pre-filled products, quantities, and custom prices. This is particularly helpful for shops and businesses that interact with customers via chat, enabling them to quickly generate cart links for faster conversions. The plugin simplifies the customer journey, reducing the steps to purchase by 3-4 steps compared to traditional e-commerce workflows.
     19
     20CartLink Generator for WooCommerce empowers store owners and merchants to create dynamic cart links with pre-filled products, quantities, and custom prices. This is particularly helpful for shops and businesses that interact with customers via chat, enabling them to quickly generate cart links for faster conversions.
     21The plugin reduces the steps to purchase by 3-4 steps compared to traditional e-commerce workflows.
    2022
    2123### Key Features:
    22 - Create and share dynamic cart links.
     24- Create and share dynamic cart/checkout links.
    2325- Customize redirection to either the **Cart** page or **Checkout** page.
    2426- Add the menu as a top-level item or under the WooCommerce submenu.
     
    7880== Screenshots ==
    7981
    80 1. **Admin Interface**: Easily configure and generate cart links.
     821. **Conversation with Your Clients**.
    81832. **Product Autocomplete**: Search and add products efficiently to cart links.
    82 3. **Generated Direct Checkout Page**: Shareable cart link ready for customers to use.
     843. **Admin Interface**: Easily configure and generate cart links.
     854. **Generated Direct Checkout Page**: Shareable cart link ready for customers to use.
     865. **Generated Direct Checkout Page**: Shareable cart link ready for customers to use.
    8387
    8488== Changelog ==
     89
     90= 1.0.1 =
     91* UI improvements.
    8592
    8693= 1.0.0 =
  • cartlink-generator/trunk/templates/admin-page.php

    r3211475 r3211875  
    77<div class="clear clearfix"></div>
    88<div class="wrapautogen"></div>
    9 <div id="selected-products"></div>
     9<div id="selected-products" style="display:none"></div>
    1010
     11<br>
    1112<!-- Add fixed subtotal field -->
    12 <label style=" display: none;margin-left: 10px; margin-top: 20px; margin-bottom: 10px; ">Custom Subtotal Discount (if there is): <input type="text" class="pregenerate" id="fixed-subtotal"
    13 style="width: 50px; max-width: 100%;">
     13<p  id="expiredays"><label style="display: none;margin-left: 10px; margin-top: 20px; margin-bottom: 10px; ">Custom Subtotal Discount (if there is):
     14    <input type="text" class="pregenerate" id="fixed-subtotal" style="width: 50px; max-width: 100%;">
    1415</label>
    15 <br>
     16</p>
    1617
    17 <p><label style="display: none;margin-left: 10px; margin-top: 20px; margin-bottom: 10px; ">Expire Days: <input type="number" class="pregenerate" id="expire-days"  value="1" placeholder="Default 1"
     18<p id="customdiscount"><label style="display: none;margin-left: 10px; margin-top: 20px; margin-bottom: 10px; ">Expire Days: <input type="number" class="pregenerate" id="expire-days"  value="1" placeholder="Default 1"
    1819    style="width: 50px; max-width: 100%;">
    1920</label></p>
Note: See TracChangeset for help on using the changeset viewer.