{"id":411579,"date":"2026-11-26T06:58:52","date_gmt":"2026-11-26T06:58:52","guid":{"rendered":"https:\/\/wordpress.org\/plugins\/devdiggers-crowdfunding-for-woocommerce\/"},"modified":"2026-11-26T06:58:28","modified_gmt":"2026-11-26T06:58:28","slug":"devdiggers-crowdfunding-for-woocommerce","status":"publish","type":"plugin","link":"https:\/\/wordpress.org\/plugins\/devdiggers-crowdfunding-for-woocommerce\/","author":20777317,"comment_status":"closed","ping_status":"closed","template":"","meta":{"version":"1.1.0","stable_tag":"1.1.0","tested":"7.1.5","requires":"6.5","requires_php":"7.4","requires_plugins":null,"header_name":"DevDiggers Crowdfunding for WooCommerce","header_author":"DevDiggers","header_description":"Run donation and crowdfunding campaigns in WooCommerce. Goals, end dates, reward tiers, a live progress card, a supporters wall and share buttons, paid through your normal checkout.","last_updated":"2026-11-26 06:58:28","external_support_url":"","external_repository_url":"","donate_link":"","header_plugin_uri":"https:\/\/github.com\/DevDiggers-Technologies\/crowdfunding-for-woocommerce","header_author_uri":"https:\/\/devdiggers.com\/","rating":0,"author_block_rating":0,"active_installs":0,"downloads":16,"num_ratings":0,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","faq","changelog"],"tags":{"1.1.0":{"tag":"1.1.0","author":"devdiggers","date":"2026-11-26 06:58:28","revision":3825662}},"upgrade_notice":{"1.1.0":"<p>Adds AI assistant (MCP) tools for your campaigns and the DevDiggers AI &amp; MCP page.<\/p>","1.0.0":"<p>First release.<\/p>"},"ratings":[],"assets_icons":{"icon-128x128.gif":{"filename":"icon-128x128.gif","revision":3825660,"resolution":"128x128","location":"assets","locale":"","width":128,"height":128},"icon-256x256.gif":{"filename":"icon-256x256.gif","revision":3825660,"resolution":"256x256","location":"assets","locale":"","width":256,"height":256}},"assets_banners":{"banner-1544x500-rtl.png":{"filename":"banner-1544x500-rtl.png","revision":3825660,"resolution":"1544x500","location":"assets","locale":"","width":1544,"height":500},"banner-1544x500.png":{"filename":"banner-1544x500.png","revision":3825660,"resolution":"1544x500","location":"assets","locale":"","width":1544,"height":500},"banner-772x250-rtl.png":{"filename":"banner-772x250-rtl.png","revision":3825660,"resolution":"772x250","location":"assets","locale":"","width":772,"height":250},"banner-772x250.png":{"filename":"banner-772x250.png","revision":3825660,"resolution":"772x250","location":"assets","locale":"","width":772,"height":250}},"assets_blueprints":{"blueprint.json":{"filename":"blueprint.json","revision":3825662,"resolution":false,"location":"assets","locale":"","contents":"{\"$schema\":\"https:\\\/\\\/playground.wordpress.net\\\/blueprint-schema.json\",\"meta\":{\"title\":\"Crowdfunding for WooCommerce demo\",\"description\":\"A neighbourhood fund running six crowdfunding campaigns with goals, reward tiers, a supporters wall and a dashboard.\",\"author\":\"devdiggers\",\"categories\":[\"WooCommerce\"]},\"landingPage\":\"\\\/wp-admin\\\/admin.php?page=ddwccf-dashboard\",\"preferredVersions\":{\"php\":\"8.3\",\"wp\":\"latest\"},\"features\":{\"networking\":true},\"steps\":[{\"step\":\"installPlugin\",\"pluginData\":{\"resource\":\"wordpress.org\\\/plugins\",\"slug\":\"woocommerce\"},\"options\":{\"activate\":true}},{\"step\":\"installPlugin\",\"pluginData\":{\"resource\":\"wordpress.org\\\/plugins\",\"slug\":\"devdiggers-crowdfunding-for-woocommerce\"},\"options\":{\"activate\":true}},{\"step\":\"installTheme\",\"themeData\":{\"resource\":\"wordpress.org\\\/themes\",\"slug\":\"kadence\"},\"options\":{\"activate\":true}},{\"step\":\"setSiteOptions\",\"options\":{\"woocommerce_onboarding_profile\":{\"skipped\":true},\"woocommerce_task_list_hidden\":\"yes\",\"woocommerce_task_list_complete\":\"yes\",\"woocommerce_show_marketplace_suggestions\":\"no\",\"woocommerce_allow_tracking\":\"no\",\"woocommerce_coming_soon\":\"no\",\"ddfw_setup_wizard_completed_devdiggers-crowdfunding-for-woocommerce\":true}},{\"step\":\"runPHP\",\"code\":\"<?php\\n\\\/\\\/ Seed for the wordpress.org Live Preview of Crowdfunding for WooCommerce (free).\\n\\\/\\\/ Runs once, as runPHP, after WooCommerce, the plugin and Kadence are installed and active.\\nrequire '\\\/wordpress\\\/wp-load.php';\\nrequire_once ABSPATH . 'wp-admin\\\/includes\\\/image.php';\\nuse DDWCCrowdFunding\\\\Helper\\\\DDWCCF_Event_Helper;\\n\\n\\\/\\\/ No outgoing mail while seeding orders.\\nadd_filter( 'pre_wp_mail', '__return_true' );\\n\\\/\\\/ Building WooCommerce emails inside the browser runs out of memory, so switch every email off while seeding.\\nforeach ( WC()->mailer()->get_emails() as $ddwc_email ) {\\n\\tadd_filter( 'woocommerce_email_enabled_' . $ddwc_email->id, '__return_false' );\\n}\\nremove_all_actions( 'ddwccf_mail_notification' );\\ndelete_transient( '_wc_activation_redirect' );\\ndelete_transient( 'ddfw_activation_redirect_devdiggers-crowdfunding-for-woocommerce' );\\nmt_srand( 42 );\\n\\n\\\/\\\/ ---- People: real portraits (they load in the visitor's browser, nothing is stored) ----\\n$faces = [\\n\\t'admin@localhost.com'      => 'https:\\\/\\\/randomuser.me\\\/api\\\/portraits\\\/women\\\/68.jpg',\\n\\t'amara.okafor@example.com' => 'https:\\\/\\\/randomuser.me\\\/api\\\/portraits\\\/women\\\/44.jpg',\\n\\t'liam.carter@example.com'  => 'https:\\\/\\\/randomuser.me\\\/api\\\/portraits\\\/men\\\/32.jpg',\\n\\t'sofia.romero@example.com' => 'https:\\\/\\\/randomuser.me\\\/api\\\/portraits\\\/women\\\/65.jpg',\\n];\\nwp_mkdir_p( WPMU_PLUGIN_DIR );\\nfile_put_contents(\\n\\tWPMU_PLUGIN_DIR . '\\\/demo-avatars.php',\\n\\t\\\"<?php\\\\n\\\/\\\/ Live Preview only: show a portrait for each demo person.\\\\nadd_filter( 'pre_get_avatar_data', function ( \\\\$args, \\\\$id ) {\\\\n\\\\t\\\\$faces = \\\" . var_export( $faces, true ) . \\\";\\\\n\\\\t\\\\$email = '';\\\\n\\\\tif ( is_numeric( \\\\$id ) ) { \\\\$u = get_userdata( (int) \\\\$id ); \\\\$email = \\\\$u ? \\\\$u->user_email : ''; }\\\\n\\\\telseif ( is_string( \\\\$id ) ) { \\\\$email = \\\\$id; }\\\\n\\\\telseif ( \\\\$id instanceof WP_User ) { \\\\$email = \\\\$id->user_email; }\\\\n\\\\telseif ( \\\\$id instanceof WP_Comment ) { \\\\$email = \\\\$id->comment_author_email; }\\\\n\\\\t\\\\$email = strtolower( \\\\$email );\\\\n\\\\tif ( isset( \\\\$faces[ \\\\$email ] ) ) { \\\\$args['url'] = \\\\$faces[ \\\\$email ]; \\\\$args['found_avatar'] = true; }\\\\n\\\\treturn \\\\$args;\\\\n}, 10, 2 );\\\\n\\\"\\n);\\n\\n\\\/\\\/ ---- Store: a neighbourhood fund that runs its campaigns on its own site ----\\nupdate_option( 'blogname', 'Larkspur Collective' );\\nupdate_option( 'blogdescription', 'Neighbours funding the projects that make Portland better' );\\nupdate_option( 'woocommerce_currency', 'USD' );\\nupdate_option( 'woocommerce_store_address', '418 Larch Street' );\\nupdate_option( 'woocommerce_store_city', 'Portland' );\\nupdate_option( 'woocommerce_default_country', 'US:OR' );\\nupdate_option( 'woocommerce_store_postcode', '97209' );\\nwp_update_user( [ 'ID' => 1, 'display_name' => 'Maya Lin', 'first_name' => 'Maya', 'last_name' => 'Lin', 'user_email' => 'admin@localhost.com' ] );\\n\\n\\\/\\\/ ---- Plugin settings: free features only ----\\nupdate_option( '_ddwccf_button_label', 'Back this campaign' );\\nupdate_option( '_ddwccf_preset_amounts', '10, 25, 50, 100' );\\nupdate_option( '_ddwccf_allow_anonymous', 'yes' );\\nupdate_option( '_ddwccf_allow_messages', 'yes' );\\nupdate_option( '_ddwccf_show_supporters', 'yes' );\\nupdate_option( '_ddwccf_supporters_count', 10 );\\nupdate_option( '_ddwccf_accent_color', '#0256ff' );\\nadd_option( 'ddwccf_installed_at', time() - 45 * DAY_IN_SECONDS );\\n\\n\\\/\\\/ ---- Campaign images: real photos that ship inside WooCommerce ----\\n$img_dir = WP_PLUGIN_DIR . '\\\/woocommerce\\\/assets\\\/images\\\/pattern-placeholders\\\/';\\n$upload  = function ( $file, $title ) use ( $img_dir ) {\\n\\t$up     = wp_upload_bits( $file, null, file_get_contents( $img_dir . $file ) );\\n\\t$att_id = wp_insert_attachment( [ 'post_mime_type' => 'image\\\/jpeg', 'post_title' => $title, 'post_status' => 'inherit' ], $up['file'] );\\n\\twp_update_attachment_metadata( $att_id, wp_generate_attachment_metadata( $att_id, $up['file'] ) );\\n\\treturn $att_id;\\n};\\n\\n\\\/\\\/ ---- Supporters ----\\n$people = [\\n\\t'amara' => [ 'Amara', 'Okafor', 'amara.okafor@example.com', 'Seattle', 'WA', '98101' ],\\n\\t'liam'  => [ 'Liam', 'Carter', 'liam.carter@example.com', 'Denver', 'CO', '80203' ],\\n\\t'sofia' => [ 'Sofia', 'Romero', 'sofia.romero@example.com', 'San Diego', 'CA', '92101' ],\\n];\\n$users = [];\\nforeach ( $people as $login => $p ) {\\n\\t$users[ $login ] = wp_insert_user( [ 'user_login' => $login, 'user_pass' => 'password', 'user_email' => $p[2], 'first_name' => $p[0], 'last_name' => $p[1], 'display_name' => $p[0] . ' ' . $p[1], 'role' => 'customer' ] );\\n}\\n$guests = [\\n\\t[ 'Daniel', 'Reyes' ], [ 'Priya', 'Sharma' ], [ 'Noah', 'Fischer' ], [ 'Hannah', 'Brooks' ], [ 'Kenji', 'Watanabe' ],\\n\\t[ 'Zoe', 'Adler' ], [ 'Marcus', 'Bell' ], [ 'Ines', 'Moreau' ], [ 'Tom', 'Hughes' ], [ 'Grace', 'Liu' ], [ 'Owen', 'Price' ], [ 'Elena', 'Petrova' ],\\n];\\n$messages = [\\n\\t'Happy to help, this neighbourhood needs it.', 'Keep going, you are so close!', 'Shared it with my whole street.', 'Proud to back this one.',\\n\\t'My kids cannot wait to see it.', 'Thank you for doing this work.', 'Small gift, big hopes.', 'Cannot wait for the update!', '', '', '',\\n];\\n\\n\\\/\\\/ ---- Campaigns: [title, photo, story, goal, raised target, days left, rewards, supporters, type] ----\\n$campaigns = [\\n\\t[\\n\\t\\t'Plant 10,000 Native Trees Along the Creek', 'tree-branch-plant-wood-leaf-flower.jpg',\\n\\t\\t'Our creek lost a third of its shade in the last decade. With your help, volunteers will plant 10,000 native trees along three miles of bank, with weekend planting days for families and local schools.',\\n\\t\\t10000, 7240, 21,\\n\\t\\t[ [ 'Name a tree', 100, 'Your name on a trail marker next to a tree you helped plant.', 100, '+4 months' ], [ 'Planting day for two', 250, 'Join us on a planting weekend, gloves and lunch included.', 40, '+3 months' ], [ 'Founding neighbour', 750, 'A thank you plaque at the trailhead and a seat at the opening picnic.', 10, '+6 months' ] ],\\n\\t],\\n\\t[\\n\\t\\t'Youth Trail Camp for 40 Kids', 'girls-in-the-hills.jpg',\\n\\t\\t'A free week of hiking, camping and river science for 40 kids from Portland schools who have never slept outside. Your gift covers tents, boots, meals and two trained guides per group.',\\n\\t\\t8000, 5360, 16,\\n\\t\\t[ [ 'Sponsor a pair of boots', 60, 'A pair of trail boots for one camper and a postcard from them.', 0, '+2 months' ], [ 'Sponsor a camper', 200, 'A full week for one child and a photo from camp.', 40, '+2 months' ], [ 'Sponsor a tent group', 900, 'Four campers, their tent and their meals.', 8, '+2 months' ] ],\\n\\t],\\n\\t[\\n\\t\\t'Community Bike Library', 'orange-wall-with-bicycle.jpg',\\n\\t\\t'A free bike library for the Larch Street neighbourhood: 30 refurbished bikes, locks and helmets, checked out with a library card and maintained by a volunteer repair crew.',\\n\\t\\t6000, 6450, 9,\\n\\t\\t[ [ 'Bell and a thank you', 25, 'A bike bell engraved with a thank you from the crew.', 0, '+1 month' ], [ 'Sponsor a bike', 180, 'One refurbished bike with your name on the frame tag.', 30, '+2 months' ] ],\\n\\t],\\n\\t[\\n\\t\\t'Press 300 Vinyl Copies of Our Debut LP', 'music-needle-turntable-black-and-white-white-photography.jpg',\\n\\t\\t'Twelve songs recorded live in a Portland church hall. Pre-order the record and we press it on 180g vinyl with a printed lyric booklet.',\\n\\t\\t5000, 3180, 27,\\n\\t\\t[ [ 'Digital download', 15, 'The full album the day it is mastered.', 0, '+1 month' ], [ 'Vinyl record', 35, 'Signed 180g vinyl and the lyric booklet.', 300, '+4 months' ], [ 'Record and a house concert', 600, 'Vinyl, plus a private acoustic set at your place.', 5, '+6 months' ] ],\\n\\t],\\n\\t[\\n\\t\\t'Reopen the Neighbourhood Pottery Studio', 'sun-glass-vase-green-ceramic-shelf.jpg',\\n\\t\\t'The wheel room on Alder Street closed last winter. We need a new kiln, six wheels and glazes to reopen with open studio nights and free classes for teens.',\\n\\t\\t4000, 1960, 33,\\n\\t\\t[ [ 'Hand-thrown mug', 45, 'A mug made in the first firing.', 60, '+4 months' ], [ 'Vase from the first kiln load', 120, 'A glazed vase from the reopening batch.', 25, '+4 months' ] ],\\n\\t],\\n\\t[\\n\\t\\t'Print the Riverside Zine, Issue Five', 'writing-typing-keyboard-technology-white-vintage.jpg',\\n\\t\\t'Neighbours write, draw and photograph the riverside. Your support pays for printing 500 copies on recycled paper, handed out free at libraries and cafes.',\\n\\t\\t1500, 1290, 12,\\n\\t\\t[ [ 'Issue five in the mail', 12, 'A printed copy of the zine.', 0, '+2 months' ], [ 'Back issues bundle', 40, 'Issues one to five and a tote bag.', 50, '+2 months' ] ],\\n\\t],\\n];\\n\\n$ids = [];\\nforeach ( $campaigns as $k => $c ) {\\n\\t$rewards = [];\\n\\tforeach ( $c[6] as $i => $r ) {\\n\\t\\t$rewards[] = [ 'id' => 'rw' . $k . $i, 'title' => $r[0], 'amount' => (float) $r[1], 'description' => $r[2], 'limit' => (int) $r[3], 'delivery' => $r[4] ? gmdate( 'F Y', strtotime( $r[4] ) ) : '', 'claimed' => 0 ];\\n\\t}\\n\\t$prod = new WC_Product_Simple();\\n\\t$prod->set_name( $c[0] );\\n\\t$prod->set_short_description( wp_trim_words( $c[2], 24 ) );\\n\\t$prod->set_description( $c[2] );\\n\\t$prod->set_regular_price( 10 );\\n\\t$prod->set_price( 10 );\\n\\t$prod->set_virtual( true );\\n\\t$prod->set_sold_individually( true );\\n\\t$prod->set_tax_status( 'none' );\\n\\t$prod->set_catalog_visibility( 'hidden' );\\n\\t$prod->set_manage_stock( false );\\n\\t$prod->set_stock_status( 'instock' );\\n\\t$prod->set_image_id( $upload( $c[1], $c[0] ) );\\n\\t$prod->set_status( 'publish' );\\n\\t$ids[ $k ] = $prod->save();\\n\\twp_update_post( [ 'ID' => $ids[ $k ], 'post_author' => 1, 'post_excerpt' => wp_trim_words( $c[2], 24 ) ] );\\n\\tDDWCCF_Event_Helper::update_event_data(\\n\\t\\t$ids[ $k ],\\n\\t\\t[\\n\\t\\t\\t'contribution_type' => 'dynamic',\\n\\t\\t\\t'target_amount'     => (string) $c[3],\\n\\t\\t\\t'end_date'          => gmdate( 'Y-m-d', time() + $c[5] * DAY_IN_SECONDS ),\\n\\t\\t\\t'collected_amount'  => 0,\\n\\t\\t\\t'contributors'      => [],\\n\\t\\t\\t'rewards'           => $rewards,\\n\\t\\t\\t'ended_notified'    => '',\\n\\t\\t]\\n\\t);\\n}\\n\\n\\\/\\\/ ---- Contributions: real orders, counted by the plugin's own status hooks, spread over 30 days ----\\n$pool     = [ 50, 75, 100, 100, 150, 150, 250, 250, 500 ];\\n$n_orders = 0;\\nforeach ( $campaigns as $k => $c ) {\\n\\t$target = $c[4];\\n\\t$sum    = 0;\\n\\t$rewards = $c[6];\\n\\t$count  = 0;\\n\\twhile ( $sum < $target ) {\\n\\t\\t$left = $target - $sum;\\n\\t\\t$amt  = $pool[ mt_rand( 0, count( $pool ) - 1 ) ];\\n\\t\\tif ( $amt > $left ) {\\n\\t\\t\\t$amt = $left;\\n\\t\\t\\tif ( $amt < 5 ) {\\n\\t\\t\\t\\tbreak;\\n\\t\\t\\t}\\n\\t\\t}\\n\\t\\t\\\/\\\/ Pick the best reward this amount qualifies for (about two thirds of supporters choose one).\\n\\t\\t$reward = null;\\n\\t\\tif ( mt_rand( 0, 2 ) > 0 ) {\\n\\t\\t\\tforeach ( $rewards as $ri => $r ) {\\n\\t\\t\\t\\tif ( $amt >= $r[1] ) {\\n\\t\\t\\t\\t\\t$reward = 'rw' . $k . $ri;\\n\\t\\t\\t\\t\\t$rt     = $r[0];\\n\\t\\t\\t\\t}\\n\\t\\t\\t}\\n\\t\\t}\\n\\t\\t$who = mt_rand( 0, 5 );\\n\\t\\tif ( $who < 2 ) {\\n\\t\\t\\t$keys = array_keys( $people );\\n\\t\\t\\t$key  = $keys[ mt_rand( 0, 2 ) ];\\n\\t\\t\\t$p    = $people[ $key ];\\n\\t\\t\\t$cid  = $users[ $key ];\\n\\t\\t\\t$bill = [ 'first_name' => $p[0], 'last_name' => $p[1], 'email' => $p[2], 'city' => $p[3], 'state' => $p[4], 'postcode' => $p[5], 'country' => 'US' ];\\n\\t\\t} else {\\n\\t\\t\\t$g    = $guests[ mt_rand( 0, count( $guests ) - 1 ) ];\\n\\t\\t\\t$cid  = 0;\\n\\t\\t\\t$bill = [ 'first_name' => $g[0], 'last_name' => $g[1], 'email' => strtolower( $g[0] . '.' . $g[1] ) . '@example.com', 'city' => 'Portland', 'state' => 'OR', 'postcode' => '97209', 'country' => 'US' ];\\n\\t\\t}\\n\\t\\t$order = wc_create_order( [ 'customer_id' => $cid ] );\\n\\t\\t$item_id = $order->add_product( wc_get_product( $ids[ $k ] ), 1, [ 'subtotal' => $amt, 'total' => $amt ] );\\n\\t\\t$item    = $order->get_item( $item_id );\\n\\t\\tif ( $reward ) {\\n\\t\\t\\t$item->add_meta_data( '_ddwccf_reward_id', $reward, true );\\n\\t\\t\\t$item->add_meta_data( '_ddwccf_reward', $rt, true );\\n\\t\\t}\\n\\t\\t$msg = $messages[ mt_rand( 0, count( $messages ) - 1 ) ];\\n\\t\\tif ( $msg ) {\\n\\t\\t\\t$item->add_meta_data( '_ddwccf_message', $msg, true );\\n\\t\\t}\\n\\t\\tif ( 0 === mt_rand( 0, 6 ) ) {\\n\\t\\t\\t$item->add_meta_data( '_ddwccf_anonymous', 'yes', true );\\n\\t\\t}\\n\\t\\t$item->save();\\n\\t\\t$order->set_address( $bill, 'billing' );\\n\\t\\t$order->set_payment_method_title( 'Credit card' );\\n\\t\\t\\\/\\\/ Spread over eight weeks with more gifts lately, so both months have a shape.\\n\\t\\t$days = (int) floor( 55 * pow( mt_rand( 0, 1000 ) \\\/ 1000, 1.3 ) );\\n\\t\\t$order->set_date_created( time() - $days * DAY_IN_SECONDS - mt_rand( 0, 70000 ) );\\n\\t\\t$order->calculate_totals();\\n\\t\\t$order->save();\\n\\t\\tDDWCCF_Event_Helper::tag_event_order( $order );\\n\\t\\t$order->set_status( 'completed' );\\n\\t\\t$order->save();\\n\\t\\t$sum += $amt;\\n\\t\\t$count++;\\n\\t\\t$n_orders++;\\n\\t}\\n}\\n\\n\\\/\\\/ Amara backs three campaigns with her own account, so her Backed Campaigns page is full.\\nforeach ( [ [ 0, 100, 'rw00' ], [ 2, 180, 'rw21' ], [ 3, 35, 'rw31' ] ] as $row ) {\\n\\t$p       = $people['amara'];\\n\\t$order   = wc_create_order( [ 'customer_id' => $users['amara'] ] );\\n\\t$item_id = $order->add_product( wc_get_product( $ids[ $row[0] ] ), 1, [ 'subtotal' => $row[1], 'total' => $row[1] ] );\\n\\t$item    = $order->get_item( $item_id );\\n\\t$item->add_meta_data( '_ddwccf_reward_id', $row[2], true );\\n\\t$item->add_meta_data( '_ddwccf_reward', $campaigns[ $row[0] ][6][ (int) substr( $row[2], -1 ) ][0], true );\\n\\t$item->add_meta_data( '_ddwccf_message', 'Proud to back this one.', true );\\n\\t$item->save();\\n\\t$order->set_address( [ 'first_name' => $p[0], 'last_name' => $p[1], 'email' => $p[2], 'city' => $p[3], 'state' => $p[4], 'postcode' => $p[5], 'country' => 'US' ], 'billing' );\\n\\t$order->set_payment_method_title( 'Credit card' );\\n\\t$order->set_date_created( time() - ( 3 + $row[0] * 4 ) * DAY_IN_SECONDS );\\n\\t$order->calculate_totals();\\n\\t$order->save();\\n\\tDDWCCF_Event_Helper::tag_event_order( $order );\\n\\t$order->set_status( 'completed' );\\n\\t$order->save();\\n}\\nwp_cache_flush();\\n\\n\\\/\\\/ ---- Storefront ----\\n\\\/\\\/ ---- DevDiggers Live Preview demo kit (Apple design language on Kadence) ----\\n\\\/**\\n * Inserted by build.py where a seed says \\\/\\\/ @kit. Call, after products and users exist:\\n *   ddwc_demo_kit_style( [ 'accent' => '#0071e3', 'css' => '' ] )  Kadence + global CSS.\\n *   ddwc_demo_kit_home( [...] )                                     Home page, set as front page.\\n *   ddwc_demo_kit_menu( [ 'Shop' => url, ... ] )                    Primary menu.\\n *   ddwc_demo_kit_switcher( $views_php )                            \\\"View as\\\" switcher mu-plugin.\\n *   ddwc_demo_kit_icon( 'chat' )                                    SVG line icon (names in the list below).\\n * Widget classes for the hero showcase: dk-widget, dk-w-head, dk-w-app, dk-w-label, dk-w-title,\\n * dk-w-big, dk-w-row, dk-w-pill, dk-w-avatar, dk-w-bubble, dk-w-note.\\n *\\\/\\n\\nfunction ddwc_demo_kit_icon( $name, $size = 24 ) {\\n\\t$paths = [\\n\\t\\t'admin'    => '<rect x=\\\"3\\\" y=\\\"3\\\" width=\\\"7\\\" height=\\\"9\\\" rx=\\\"1.5\\\"\\\/><rect x=\\\"14\\\" y=\\\"3\\\" width=\\\"7\\\" height=\\\"5\\\" rx=\\\"1.5\\\"\\\/><rect x=\\\"14\\\" y=\\\"12\\\" width=\\\"7\\\" height=\\\"9\\\" rx=\\\"1.5\\\"\\\/><rect x=\\\"3\\\" y=\\\"16\\\" width=\\\"7\\\" height=\\\"5\\\" rx=\\\"1.5\\\"\\\/>',\\n\\t\\t'customer' => '<circle cx=\\\"12\\\" cy=\\\"8\\\" r=\\\"4\\\"\\\/><path d=\\\"M4 21c0-4 3.6-7 8-7s8 3 8 7\\\"\\\/>',\\n\\t\\t'store'    => '<path d=\\\"M3 9l1.5-5h15L21 9\\\"\\\/><path d=\\\"M3 9h18v2a3 3 0 0 1-6 0 3 3 0 0 1-6 0 3 3 0 0 1-6 0z\\\"\\\/><path d=\\\"M5 13v8h14v-8\\\"\\\/><path d=\\\"M10 21v-5h4v5\\\"\\\/>',\\n\\t\\t'product'  => '<path d=\\\"M20.6 13.4 13.4 20.6a2 2 0 0 1-2.8 0L3 13V3h10l7.6 7.6a2 2 0 0 1 0 2.8z\\\"\\\/><circle cx=\\\"7.5\\\" cy=\\\"7.5\\\" r=\\\"1.5\\\"\\\/>',\\n\\t\\t'cart'     => '<circle cx=\\\"9\\\" cy=\\\"20\\\" r=\\\"1.5\\\"\\\/><circle cx=\\\"18\\\" cy=\\\"20\\\" r=\\\"1.5\\\"\\\/><path d=\\\"M2 3h3l2.7 12.4a2 2 0 0 0 2 1.6h8.6a2 2 0 0 0 2-1.5L22 7H6\\\"\\\/>',\\n\\t\\t'chat'     => '<path d=\\\"M21 12a8 8 0 0 1-11.6 7.1L4 20l1-4.6A8 8 0 1 1 21 12z\\\"\\\/>',\\n\\t\\t'wallet'   => '<path d=\\\"M3 7a2 2 0 0 1 2-2h13v4\\\"\\\/><rect x=\\\"3\\\" y=\\\"7\\\" width=\\\"18\\\" height=\\\"13\\\" rx=\\\"2\\\"\\\/><circle cx=\\\"16.5\\\" cy=\\\"13.5\\\" r=\\\"1.3\\\"\\\/>',\\n\\t\\t'star'     => '<path d=\\\"m12 3 2.8 5.7 6.2.9-4.5 4.4 1.1 6.2L12 17.3 6.4 20.2l1.1-6.2L3 9.6l6.2-.9z\\\"\\\/>',\\n\\t\\t'register' => '<rect x=\\\"3\\\" y=\\\"4\\\" width=\\\"18\\\" height=\\\"12\\\" rx=\\\"2\\\"\\\/><path d=\\\"M7 20h10M12 16v4M7 8h4M7 11h2\\\"\\\/>',\\n\\t\\t'link'     => '<path d=\\\"M10 14a4 4 0 0 0 5.7 0l3-3a4 4 0 0 0-5.7-5.7l-1 1\\\"\\\/><path d=\\\"M14 10a4 4 0 0 0-5.7 0l-3 3a4 4 0 0 0 5.7 5.7l1-1\\\"\\\/>',\\n\\t\\t'cube'     => '<path d=\\\"M12 2 21 7v10l-9 5-9-5V7z\\\"\\\/><path d=\\\"m3 7 9 5 9-5M12 12v10\\\"\\\/>',\\n\\t\\t'ar'       => '<path d=\\\"M3 7V4h3M21 7V4h-3M3 17v3h3M21 17v3h-3\\\"\\\/><rect x=\\\"8\\\" y=\\\"8\\\" width=\\\"8\\\" height=\\\"8\\\" rx=\\\"1.5\\\"\\\/>',\\n\\t\\t'rx'       => '<path d=\\\"M9 3h6v4H9z\\\"\\\/><path d=\\\"M7 5H5v16h14V5h-2\\\"\\\/><path d=\\\"M9 12h6M9 16h4\\\"\\\/>',\\n\\t\\t'phone'    => '<rect x=\\\"6\\\" y=\\\"2\\\" width=\\\"12\\\" height=\\\"20\\\" rx=\\\"3\\\"\\\/><path d=\\\"M11 18h2\\\"\\\/>',\\n\\t\\t'orders'   => '<path d=\\\"M4 7 12 3l8 4v10l-8 4-8-4z\\\"\\\/><path d=\\\"m4 7 8 4 8-4M12 11v10\\\"\\\/>',\\n\\t\\t'calendar' => '<rect x=\\\"3\\\" y=\\\"5\\\" width=\\\"18\\\" height=\\\"16\\\" rx=\\\"2\\\"\\\/><path d=\\\"M3 10h18M8 3v4M16 3v4\\\"\\\/>',\\n\\t\\t'clock'    => '<circle cx=\\\"12\\\" cy=\\\"13\\\" r=\\\"8\\\"\\\/><path d=\\\"M12 9v4l2.5 2.5M9 2h6\\\"\\\/>',\\n\\t\\t'mail'     => '<rect x=\\\"3\\\" y=\\\"5\\\" width=\\\"18\\\" height=\\\"14\\\" rx=\\\"2\\\"\\\/><path d=\\\"m3 7 9 6 9-6\\\"\\\/>',\\n\\t\\t'chart'    => '<path d=\\\"M3 3v18h18\\\"\\\/><path d=\\\"m7 15 4-4 3 3 5-6\\\"\\\/>',\\n\\t\\t'card'     => '<rect x=\\\"2\\\" y=\\\"5\\\" width=\\\"20\\\" height=\\\"14\\\" rx=\\\"2\\\"\\\/><path d=\\\"M2 10h20M6 15h4\\\"\\\/>',\\n\\t\\t'scan'     => '<path d=\\\"M3 7V5a2 2 0 0 1 2-2h2M17 3h2a2 2 0 0 1 2 2v2M21 17v2a2 2 0 0 1-2 2h-2M7 21H5a2 2 0 0 1-2-2v-2M7 8v8M11 8v8M14 8v8M17 8v8\\\"\\\/>',\\n\\t\\t'receipt'  => '<path d=\\\"M5 3h14v18l-3-2-2 2-2-2-2 2-2-2-3 2z\\\"\\\/><path d=\\\"M9 8h6M9 12h6\\\"\\\/>',\\n\\t\\t'heart'    => '<path d=\\\"M12 21s-7-4.4-7-10a4 4 0 0 1 7-2.6A4 4 0 0 1 19 11c0 5.6-7 10-7 10z\\\"\\\/>',\\n\\t\\t'upload'   => '<path d=\\\"M12 16V4M7 9l5-5 5 5\\\"\\\/><path d=\\\"M4 16v3a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-3\\\"\\\/>',\\n\\t\\t'lock'     => '<rect x=\\\"4\\\" y=\\\"11\\\" width=\\\"16\\\" height=\\\"10\\\" rx=\\\"2\\\"\\\/><path d=\\\"M8 11V7a4 4 0 0 1 8 0v4\\\"\\\/>',\\n\\t\\t'shield'   => '<path d=\\\"M12 3 4 6v6c0 4.5 3.4 8 8 9 4.6-1 8-4.5 8-9V6z\\\"\\\/><path d=\\\"m8.5 12 2.5 2.5 4.5-5\\\"\\\/>',\\n\\t\\t'wifi'     => '<path d=\\\"M2 8.8a15 15 0 0 1 20 0M5 12.5a10 10 0 0 1 14 0M8.5 16a5 5 0 0 1 7 0\\\"\\\/><circle cx=\\\"12\\\" cy=\\\"19.5\\\" r=\\\"1\\\"\\\/>',\\n\\t\\t'bell'     => '<path d=\\\"M6 8a6 6 0 0 1 12 0c0 7 3 8 3 8H3s3-1 3-8\\\"\\\/><path d=\\\"M10.3 21a1.9 1.9 0 0 0 3.4 0\\\"\\\/>',\\n\\t\\t'gift'     => '<rect x=\\\"3\\\" y=\\\"8\\\" width=\\\"18\\\" height=\\\"13\\\" rx=\\\"2\\\"\\\/><path d=\\\"M3 12h18M12 8v13M12 8C10 5 7 5 7 7s3 1 5 1c2 0 5 1 5-1s-3-2-5 1\\\"\\\/>',\\n\\t\\t'bolt'     => '<path d=\\\"M13 2 4 14h7l-1 8 9-12h-7z\\\"\\\/>',\\n\\t\\t'ask'      => '<circle cx=\\\"12\\\" cy=\\\"12\\\" r=\\\"9\\\"\\\/><path d=\\\"M9.5 9.5a2.5 2.5 0 1 1 3.5 2.3c-.7.3-1 .9-1 1.7M12 17h.01\\\"\\\/>',\\n\\t\\t'check'    => '<path d=\\\"m5 12 5 5 9-10\\\"\\\/>',\\n\\t\\t'pay'      => '<rect x=\\\"3\\\" y=\\\"6\\\" width=\\\"18\\\" height=\\\"13\\\" rx=\\\"2\\\"\\\/><path d=\\\"M3 10h18M7 15h3\\\"\\\/>',\\n\\t];\\n\\treturn '<svg viewBox=\\\"0 0 24 24\\\" width=\\\"' . (int) $size . '\\\" height=\\\"' . (int) $size . '\\\" fill=\\\"none\\\" stroke=\\\"currentColor\\\" stroke-width=\\\"1.7\\\" stroke-linecap=\\\"round\\\" stroke-linejoin=\\\"round\\\" aria-hidden=\\\"true\\\">' . ( $paths[ $name ] ?? $paths['store'] ) . '<\\\/svg>';\\n}\\n\\n\\\/** Product photo URL (for hero_img and tile img). *\\\/\\nfunction ddwc_demo_kit_img( $product_id, $size = 'large' ) {\\n\\treturn wp_get_attachment_image_url( get_post_thumbnail_id( $product_id ), $size );\\n}\\n\\n\\\/**\\n * Brand the store: Apple's neutral system (SF Pro via the system font stack, #1d1d1f \\\/ #6e6e73 \\\/ #f5f5f7)\\n * with one accent colour per brand. Global CSS goes in an mu-plugin so the seed may still use Additional CSS.\\n *\\n * @param array $a accent (hex), css (extra CSS appended after the kit CSS).\\n *\\\/\\nfunction ddwc_demo_kit_style( $a ) {\\n\\t$a      = array_merge( [ 'accent' => '#0071e3', 'css' => '' ], $a );\\n\\t$accent = $a['accent'];\\n\\t$rgb    = sscanf( $accent, '#%02x%02x%02x' );\\n\\t$dark   = vsprintf( '#%02x%02x%02x', array_map( function ( $c ) { return (int) round( $c * 0.84 ); }, $rgb ) );\\n\\t$tint   = vsprintf( 'rgba(%d,%d,%d,.1)', $rgb );\\n\\t$stack  = '-apple-system,BlinkMacSystemFont,\\\"SF Pro Text\\\",\\\"SF Pro Display\\\",\\\"Helvetica Neue\\\",Helvetica,Arial,sans-serif';\\n\\n\\t$colors  = [ $accent, $dark, '#1d1d1f', '#1d1d1f', '#6e6e73', '#86868b', '#d2d2d7', '#f5f5f7', '#ffffff', '#ffffff', '#248a3d', '#0071e3', '#d70015', '#bf4800', '#b25e09' ];\\n\\t$palette = [];\\n\\tforeach ( $colors as $i => $color ) {\\n\\t\\t$palette[] = [ 'color' => $color, 'slug' => 'palette' . ( $i + 1 ), 'name' => 'Palette Color ' . ( $i + 1 ) ];\\n\\t}\\n\\tupdate_option( 'kadence_global_palette', wp_json_encode( [ 'palette' => $palette, 'second-palette' => $palette, 'third-palette' => $palette, 'active' => 'palette' ] ) );\\n\\n\\tset_theme_mod( 'base_font', [ 'family' => $stack, 'google' => false, 'weight' => '400', 'variant' => 'regular', 'size' => [ 'desktop' => 17 ], 'lineHeight' => [ 'desktop' => 1.47 ], 'color' => 'palette4' ] );\\n\\tset_theme_mod( 'heading_font', [ 'family' => $stack, 'google' => false, 'weight' => '600', 'variant' => [ '600' ] ] );\\n\\tforeach ( [ 'h1_font' => [ 48, 1.08 ], 'h2_font' => [ 40, 1.1 ], 'h3_font' => [ 28, 1.14 ], 'h4_font' => [ 21, 1.2 ], 'h5_font' => [ 17, 1.3 ], 'h6_font' => [ 14, 1.4 ] ] as $mod => $size ) {\\n\\t\\tset_theme_mod( $mod, [ 'size' => [ 'desktop' => $size[0] ], 'lineHeight' => [ 'desktop' => $size[1] ], 'family' => 'inherit', 'google' => false, 'weight' => '600', 'variant' => '600', 'color' => 'palette3' ] );\\n\\t}\\n\\tset_theme_mod( 'load_fonts_local', false );\\n\\n\\tset_theme_mod( 'site_background', [ 'desktop' => [ 'color' => 'palette9' ] ] );\\n\\tset_theme_mod( 'content_background', [ 'desktop' => [ 'color' => 'palette9' ] ] );\\n\\tset_theme_mod( 'page_content_style', 'unboxed' );\\n\\tset_theme_mod( 'product_archive_content_style', 'unboxed' );\\n\\tset_theme_mod( 'product_content_style', 'unboxed' );\\n\\tset_theme_mod( 'product_archive_columns', '4' );\\n\\tset_theme_mod( 'buttons_border_radius', [ 'size' => [ 980, 980, 980, 980 ], 'unit' => 'px', 'locked' => true ] );\\n\\tset_theme_mod( 'buttons_typography', [ 'size' => [ 'desktop' => 15 ], 'family' => 'inherit', 'weight' => '400', 'variant' => 'regular', 'letterSpacing' => [ 'desktop' => -0.01 ], 'letterType' => 'em' ] );\\n\\tset_theme_mod( 'buttons_padding', [ 'size' => [ 'desktop' => [ 11, 22, 11, 22 ] ], 'unit' => [ 'desktop' => 'px' ], 'locked' => [ 'desktop' => false ] ] );\\n\\n\\t\\\/\\\/ Header: one slim frosted bar, logo left, menu and bag right.\\n\\tset_theme_mod(\\n\\t\\t'header_desktop_items',\\n\\t\\t[\\n\\t\\t\\t'top'    => [ 'top_left' => [], 'top_left_center' => [], 'top_center' => [], 'top_right_center' => [], 'top_right' => [] ],\\n\\t\\t\\t'main'   => [ 'main_left' => [ 'logo' ], 'main_left_center' => [], 'main_center' => [], 'main_right_center' => [], 'main_right' => [ 'navigation', 'cart' ] ],\\n\\t\\t\\t'bottom' => [ 'bottom_left' => [], 'bottom_left_center' => [], 'bottom_center' => [], 'bottom_right_center' => [], 'bottom_right' => [] ],\\n\\t\\t]\\n\\t);\\n\\tset_theme_mod( 'header_sticky', 'main' );\\n\\tset_theme_mod( 'header_main_height', [ 'size' => [ 'mobile' => 52, 'tablet' => 52, 'desktop' => 52 ], 'unit' => [ 'mobile' => 'px', 'tablet' => 'px', 'desktop' => 'px' ] ] );\\n\\tset_theme_mod( 'header_main_background', [ 'desktop' => [ 'color' => 'rgba(255,255,255,0.8)' ] ] );\\n\\tset_theme_mod( 'header_sticky_background', [ 'desktop' => [ 'color' => 'rgba(255,255,255,0.8)' ] ] );\\n\\tset_theme_mod( 'header_main_bottom_border', [ 'desktop' => [ 'width' => 1, 'unit' => 'px', 'style' => 'solid', 'color' => 'rgba(0,0,0,0.08)' ] ] );\\n\\tset_theme_mod( 'brand_typography', [ 'size' => [ 'desktop' => 19 ], 'family' => 'inherit', 'google' => false, 'weight' => '600', 'variant' => '600', 'letterSpacing' => [ 'desktop' => -0.02 ], 'letterType' => 'em', 'color' => 'palette3' ] );\\n\\tset_theme_mod( 'primary_navigation_typography', [ 'size' => [ 'desktop' => 13 ], 'family' => 'inherit', 'weight' => '400', 'variant' => 'regular' ] );\\n\\tset_theme_mod( 'primary_navigation_color', [ 'color' => 'palette4', 'hover' => 'palette1', 'active' => 'palette3' ] );\\n\\n\\tset_theme_mod( 'page_title_layout', 'above' );\\n\\tset_theme_mod( 'page_title_background', [ 'desktop' => [ 'color' => 'palette8' ] ] );\\n\\tset_theme_mod( 'product_archive_title_background', [ 'desktop' => [ 'color' => 'palette8' ] ] );\\n\\tset_theme_mod( 'footer_html_content', '{copyright} {year} {site-title}. A DevDiggers live demo store.' );\\n\\tset_theme_mod( 'footer_bottom_background', [ 'desktop' => [ 'color' => 'palette8' ] ] );\\n\\n\\t$css = <<<'DDWCCSS'\\n:root{--dk-accent:__A__;--dk-accent-dark:__D__;--dk-tint:__T__;--dk-ink:#1d1d1f;--dk-gray:#6e6e73;--dk-line:#d2d2d7;--dk-fog:#f5f5f7;--dk-ease:cubic-bezier(.25,.1,.25,1)}\\nbody{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;letter-spacing:-.022em;color:var(--dk-ink)}\\nh1,h2,h3,h4{letter-spacing:-.015em}\\na{color:var(--dk-accent)}\\n#masthead .site-main-header-wrap,#masthead .item-is-fixed{-webkit-backdrop-filter:saturate(180%) blur(20px);backdrop-filter:saturate(180%) blur(20px)}\\n.main-navigation .primary-menu-container>ul>li.menu-item>a{padding-left:.9em;padding-right:.9em;opacity:.85}\\n.main-navigation .primary-menu-container>ul>li.menu-item>a:hover{opacity:1}\\n.button,button.button,.wp-element-button,input[type=submit],.woocommerce a.button,.woocommerce button.button{background:var(--dk-accent);color:#fff;border:0;box-shadow:none!important;transition:background .2s var(--dk-ease)}\\n.button:hover,.wp-element-button:hover,input[type=submit]:hover,.woocommerce a.button:hover,.woocommerce button.button:hover{background:var(--dk-accent-dark);color:#fff}\\ninput[type=text],input[type=email],input[type=tel],input[type=password],input[type=number],input[type=search],textarea,select{border:1px solid var(--dk-line)!important;border-radius:12px!important;padding:12px 14px!important;background:#fff!important;font-size:17px;transition:border-color .2s,box-shadow .2s}\\ninput:focus,textarea:focus,select:focus{border-color:var(--dk-accent)!important;box-shadow:0 0 0 4px var(--dk-tint)!important;outline:0}\\n.entry-hero .entry-header,.page-title{padding-top:56px;padding-bottom:40px}\\n.entry-hero h1,.page-title h1,.woocommerce-products-header__title{font-size:48px;letter-spacing:-.02em}\\n.woocommerce-store-notice{display:none!important}\\n.woocommerce-message,.woocommerce-info,.woocommerce-error{border:0!important;border-radius:14px;background:var(--dk-fog)!important;color:var(--dk-ink)}\\n\\\/* Product cards, Apple Store style. *\\\/\\nul.products li.product{background:#fff;border-radius:18px;padding:0 0 22px;overflow:hidden;box-shadow:0 2px 12px rgba(0,0,0,.08);transition:box-shadow .3s var(--dk-ease),transform .3s var(--dk-ease)}\\nul.products li.product:hover{box-shadow:0 10px 34px rgba(0,0,0,.14);transform:translateY(-2px)}\\nul.products li.product img{border-radius:0!important;aspect-ratio:1\\\/1;object-fit:cover;margin:0!important}\\nul.products li.product .woocommerce-loop-product__title,ul.products li.product .product-details,ul.products li.product .entry-content-wrap{padding-left:20px;padding-right:20px}\\nul.products li.product .woocommerce-loop-product__title{font-size:17px;font-weight:600;margin-top:16px}\\nul.products li.product .price{color:var(--dk-gray);font-size:15px;font-weight:400}\\nul.products li.product .button{font-size:14px;padding:8px 16px}\\nul.products li.product .onsale{border-radius:980px;background:var(--dk-accent);font-weight:600;font-size:12px}\\n.single-product div.product .product_title{font-size:40px;letter-spacing:-.02em}\\n.single-product div.product .price{font-size:21px;color:var(--dk-ink)}\\n.single-product div.product .woocommerce-product-gallery img{border-radius:24px}\\n\\\/* My account, as a settings sidebar. *\\\/\\n.woocommerce-MyAccount-navigation ul{background:var(--dk-fog);border-radius:18px;padding:8px!important}\\n.woocommerce-MyAccount-navigation ul li{border:0!important}\\n.woocommerce-MyAccount-navigation ul li a{display:block;padding:10px 14px!important;border-radius:10px;color:var(--dk-ink)!important;font-size:15px}\\n.woocommerce-MyAccount-navigation ul li.is-active a{background:#fff;font-weight:600;box-shadow:0 1px 4px rgba(0,0,0,.08)}\\ntable.shop_table{border-radius:18px!important;border-color:var(--dk-line)!important;overflow:hidden}\\n.site-footer{font-size:12px;color:var(--dk-gray)}\\n\\\/* Home page building blocks. *\\\/\\n.dk-wrap{max-width:1180px;margin:0 auto;padding-left:22px;padding-right:22px}\\n.dk-hero{text-align:center;padding-top:72px}\\n.dk-eyebrow{display:inline-block;color:var(--dk-accent);font-size:17px;font-weight:600;letter-spacing:-.01em;margin-bottom:10px}\\n.dk-hero h1{font-size:clamp(44px,7vw,80px);line-height:1.05;letter-spacing:-.025em;margin:0 auto 14px!important;max-width:16ch;text-wrap:balance}\\n.dk-lead{font-size:clamp(19px,2.2vw,24px);line-height:1.38;color:var(--dk-gray);max-width:36em;margin:0 auto 28px!important;text-wrap:pretty;letter-spacing:-.015em}\\n.dk-ctas{display:flex;gap:28px;justify-content:center;align-items:center;flex-wrap:wrap}\\n.dk-btn{display:inline-flex;align-items:center;padding:12px 24px;border-radius:980px;background:var(--dk-accent);color:#fff!important;font-size:17px;text-decoration:none!important;transition:background .2s var(--dk-ease)}\\n.dk-btn:hover{background:var(--dk-accent-dark)}\\n.dk-btn.is-light{background:#fff;color:var(--dk-ink)!important}.dk-btn.is-light:hover{background:#e8e8ed}\\n.dk-more{font-size:17px;color:var(--dk-accent)!important;text-decoration:none!important}\\n.dk-more:after{content:\\\"\\\\203A\\\";display:inline-block;margin-left:6px;font-size:1.2em;line-height:0;transition:transform .2s var(--dk-ease)}\\n.dk-more:hover{text-decoration:underline!important}.dk-more:hover:after{transform:translateX(3px)}\\n.dk-stage{position:relative;margin:56px auto 0;max-width:1180px;border-radius:32px;overflow:hidden;background:var(--dk-fog);aspect-ratio:16\\\/9}\\n.dk-stage>img{width:100%;height:100%;object-fit:cover;display:block}\\n.dk-stage.is-trio{display:grid;grid-template-columns:repeat(3,1fr);gap:4px;background:#fff}\\n.dk-stage.is-trio>img{min-width:0}\\n.dk-stage .dk-widget{position:absolute;right:32px;bottom:32px}\\n.dk-widget{width:330px;max-width:calc(100% - 32px);text-align:left;padding:18px;border-radius:22px;background:rgba(255,255,255,.78);-webkit-backdrop-filter:saturate(180%) blur(24px);backdrop-filter:saturate(180%) blur(24px);box-shadow:0 22px 60px rgba(0,0,0,.18),inset 0 0 0 .5px rgba(255,255,255,.6);color:var(--dk-ink);font-size:15px;line-height:1.35}\\n.dk-w-head{display:flex;align-items:center;gap:10px;margin-bottom:12px}\\n.dk-w-app{flex:none;display:grid;place-items:center;width:34px;height:34px;border-radius:9px;background:var(--dk-accent);color:#fff}\\n.dk-w-app svg{width:19px;height:19px}\\n.dk-w-label{display:block;font-size:12px;font-weight:600;color:var(--dk-gray);letter-spacing:0;text-transform:uppercase}\\n.dk-w-title{display:block;font-size:16px;font-weight:600;letter-spacing:-.02em}\\n.dk-w-big{display:block;font-size:40px;font-weight:600;letter-spacing:-.03em;line-height:1.1;margin:4px 0}\\n.dk-w-row{display:flex;justify-content:space-between;gap:12px;padding:9px 0;border-top:.5px solid rgba(0,0,0,.12);font-size:14px}\\n.dk-w-row span:last-child{color:var(--dk-gray)}\\n.dk-w-row.is-total{font-weight:600}.dk-w-row.is-total span:last-child{color:var(--dk-ink)}\\n.dk-w-pill{display:inline-flex;align-items:center;gap:6px;padding:4px 10px;border-radius:980px;background:var(--dk-tint);color:var(--dk-accent);font-size:13px;font-weight:600}\\n.dk-w-avatar{flex:none;width:34px;height:34px;border-radius:50%;object-fit:cover}\\n.dk-w-bubble{padding:10px 14px;border-radius:18px 18px 18px 6px;background:#e9e9eb;font-size:15px;margin-top:6px}\\n.dk-w-bubble.is-me{border-radius:18px 18px 6px 18px;background:var(--dk-accent);color:#fff;margin-left:30px}\\n.dk-w-note{display:block;font-size:12px;color:var(--dk-gray);margin-top:10px}\\n.dk-cd{display:flex;gap:8px;margin:10px 0 4px}.dk-cd span{flex:1;text-align:center;padding:10px 0 8px;border-radius:12px;background:var(--dk-ink);color:#fff;font-size:22px;font-weight:600;font-variant-numeric:tabular-nums;letter-spacing:-.02em}\\n.dk-cd small{display:block;font-size:10px;font-weight:500;color:#a1a1a6;letter-spacing:.04em;text-transform:uppercase;margin-top:3px}\\n.dk-band{background:var(--dk-fog);margin-top:96px;padding:88px 0}\\n.dk-title{text-align:center!important;font-size:clamp(34px,4.6vw,56px);letter-spacing:-.025em;line-height:1.08;margin:0 auto 48px!important;max-width:20ch;text-wrap:balance}\\n.dk-shelf-title{font-size:clamp(28px,3.4vw,40px);letter-spacing:-.02em;line-height:1.1;margin:0 0 28px}\\n.dk-shelf-title span{color:var(--dk-gray)}\\n.dk-features{display:grid;grid-template-columns:repeat(3,1fr);gap:20px}\\n.dk-feature{background:#fff;border-radius:28px;padding:36px 32px 40px}\\n.dk-feature svg{color:var(--dk-accent);width:36px;height:36px}\\n.dk-feature h3{font-size:24px;letter-spacing:-.02em;margin:18px 0 8px}\\n.dk-feature p{margin:0;font-size:17px;color:var(--dk-gray)}\\n.dk-shelf{padding-top:96px}\\n.dk-shelf-head{display:flex;justify-content:space-between;align-items:baseline;gap:16px;flex-wrap:wrap}\\n.dk-tile{margin:96px auto 104px;display:grid;grid-template-columns:1fr 1fr;align-items:center;border-radius:32px;overflow:hidden;background:#000;color:#f5f5f7}\\n.dk-tile-copy{padding:64px}\\n.dk-tile h2{color:#f5f5f7;font-size:clamp(32px,3.8vw,48px);letter-spacing:-.025em;line-height:1.08;margin:0 0 16px}\\n.dk-tile p{color:#a1a1a6;font-size:19px;line-height:1.42}\\n.dk-tile .dk-more{color:#2997ff!important}\\n.dk-tile img{width:100%;height:100%;min-height:440px;max-height:600px;object-fit:cover;display:block}\\n.dk-stats{display:flex;gap:36px;margin:28px 0}.dk-stats b{display:block;font-size:32px;font-weight:600;letter-spacing:-.02em;color:#f5f5f7}.dk-stats span{font-size:14px;color:#a1a1a6}\\n.dk-list{list-style:none;padding:0;margin:24px 0}.dk-list li{display:flex;gap:12px;align-items:center;padding:10px 0;border-top:.5px solid rgba(255,255,255,.16);color:#f5f5f7;font-size:17px}\\n.dk-list li b{display:grid;place-items:center;flex:none;width:26px;height:26px;border-radius:50%;background:#f5f5f7;color:#000;font-size:13px}\\n@media(max-width:900px){.dk-features,.dk-tile{grid-template-columns:1fr}.dk-stage{aspect-ratio:4\\\/5;border-radius:24px}.dk-stage .dk-widget{left:16px;right:16px;bottom:16px;width:auto}.dk-stage.is-trio{grid-template-columns:1fr 1fr}.dk-stage.is-trio>img:nth-child(3){display:none}.dk-tile-copy{padding:40px 28px}.dk-tile img{min-height:300px}.dk-band{padding:64px 0}}\\n@media(prefers-reduced-motion:reduce){*{transition:none!important}}\\nDDWCCSS;\\n\\t$css  = str_replace( [ '__A__', '__D__', '__T__' ], [ $accent, $dark, $tint ], $css ) . $a['css'];\\n\\t$code = \\\"<?php\\\\n\\\/\\\/ Live Preview only: the demo kit's global stylesheet.\\\\nadd_action( 'wp_head', function () { echo '<style id=\\\\\\\"ddwc-demo-kit\\\\\\\">' . \\\" . var_export( $css, true ) . \\\" . '<\\\/style>'; }, 99 );\\\\n\\\";\\n\\twp_mkdir_p( WPMU_PLUGIN_DIR );\\n\\tfile_put_contents( WPMU_PLUGIN_DIR . '\\\/demo-style.php', $code );\\n}\\n\\n\\\/**\\n * Build the home page and make it the front page.\\n *\\n * @param array $h eyebrow, title, lead, ctas [ [label, url], [label, url] ] (first is the filled button),\\n *                 hero_img (url, or three urls for a photo trio), hero_alt, widget (HTML on the hero stage), after_ctas (HTML, e.g. a shortcode),\\n *                 features_title, features [ [title, text, icon] ], shelf_title, shelf_sub, shelf (shortcode),\\n *                 shelf_more [label, url], tile [title, text, cta [label, url], img, alt, extra HTML], script.\\n * @return int Page ID.\\n *\\\/\\nfunction ddwc_demo_kit_home( $h ) {\\n\\t$ctas = '';\\n\\tforeach ( $h['ctas'] as $i => $cta ) {\\n\\t\\t$ctas .= '<a class=\\\"' . ( $i ? 'dk-more' : 'dk-btn' ) . '\\\" href=\\\"' . esc_url( $cta[1] ) . '\\\">' . esc_html( $cta[0] ) . '<\\\/a>';\\n\\t}\\n\\t$features = '';\\n\\tforeach ( $h['features'] as $f ) {\\n\\t\\t$features .= '<div class=\\\"dk-feature\\\">' . ddwc_demo_kit_icon( $f[2], 36 ) . '<h3>' . $f[0] . '<\\\/h3><p>' . $f[1] . '<\\\/p><\\\/div>';\\n\\t}\\n\\t\\\/\\\/ One wide photo, or three product photos side by side (works with portrait shots).\\n\\t$trio = is_array( $h['hero_img'] );\\n\\t$imgs = '';\\n\\tforeach ( (array) $h['hero_img'] as $src ) {\\n\\t\\t$imgs .= '<img src=\\\"' . esc_url( $src ) . '\\\" alt=\\\"' . esc_attr( $h['hero_alt'] ) . '\\\"\\\/>';\\n\\t}\\n\\t$t    = $h['tile'];\\n\\t$more = $h['shelf_more'] ?? [ 'View all products', wc_get_page_permalink( 'shop' ) ];\\n\\t$html = '<!-- wp:html --><section class=\\\"dk-hero dk-wrap\\\"><span class=\\\"dk-eyebrow\\\">' . $h['eyebrow'] . '<\\\/span><h1>' . $h['title'] . '<\\\/h1><p class=\\\"dk-lead\\\">' . $h['lead'] . '<\\\/p><div class=\\\"dk-ctas\\\">' . $ctas . ( $h['after_ctas'] ?? '' ) . '<\\\/div>'\\n\\t\\t. '<div class=\\\"dk-stage' . ( $trio ? ' is-trio' : '' ) . '\\\">' . $imgs . $h['widget'] . '<\\\/div><\\\/section><!-- \\\/wp:html -->'\\n\\t\\t. '<!-- wp:html --><section class=\\\"dk-band\\\"><div class=\\\"dk-wrap\\\"><h2 class=\\\"dk-title\\\">' . $h['features_title'] . '<\\\/h2><div class=\\\"dk-features\\\">' . $features . '<\\\/div><\\\/div><\\\/section><!-- \\\/wp:html -->'\\n\\t\\t. '<!-- wp:html --><section class=\\\"dk-shelf dk-wrap\\\"><div class=\\\"dk-shelf-head\\\"><h2 class=\\\"dk-shelf-title\\\">' . $h['shelf_title'] . ' <span>' . $h['shelf_sub'] . '<\\\/span><\\\/h2><a class=\\\"dk-more\\\" href=\\\"' . esc_url( $more[1] ) . '\\\">' . esc_html( $more[0] ) . '<\\\/a><\\\/div><!-- \\\/wp:html -->'\\n\\t\\t. '<!-- wp:shortcode -->' . $h['shelf'] . '<!-- \\\/wp:shortcode -->'\\n\\t\\t. '<!-- wp:html --><\\\/section><!-- \\\/wp:html -->'\\n\\t\\t. '<!-- wp:html --><section class=\\\"dk-wrap\\\"><div class=\\\"dk-tile\\\"><div class=\\\"dk-tile-copy\\\"><h2>' . $t['title'] . '<\\\/h2><p>' . $t['text'] . '<\\\/p>' . ( $t['extra'] ?? '' ) . '<p><a class=\\\"dk-btn is-light\\\" href=\\\"' . esc_url( $t['cta'][1] ) . '\\\">' . esc_html( $t['cta'][0] ) . '<\\\/a><\\\/p><\\\/div><img src=\\\"' . esc_url( $t['img'] ) . '\\\" alt=\\\"' . esc_attr( $t['alt'] ) . '\\\"\\\/><\\\/div><\\\/section>' . ( $h['script'] ?? '' ) . '<!-- \\\/wp:html -->';\\n\\n\\t$id = wp_insert_post( [ 'post_type' => 'page', 'post_status' => 'publish', 'post_title' => 'Home', 'post_content' => $html ] );\\n\\tforeach ( [ '_kad_post_title' => 'hide', '_kad_post_layout' => 'fullwidth', '_kad_post_content_style' => 'unboxed', '_kad_post_vertical_padding' => 'hide', '_kad_post_feature' => 'hide' ] as $k => $v ) {\\n\\t\\tupdate_post_meta( $id, $k, $v );\\n\\t}\\n\\tupdate_option( 'show_on_front', 'page' );\\n\\tupdate_option( 'page_on_front', $id );\\n\\twp_delete_post( 2, true ); \\\/\\\/ Sample Page.\\n\\twp_delete_post( 1, true ); \\\/\\\/ Hello world.\\n\\tupdate_option( 'permalink_structure', '\\\/%postname%\\\/' );\\n\\tflush_rewrite_rules();\\n\\treturn $id;\\n}\\n\\n\\\/**\\n * Primary menu.\\n *\\n * @param array $items label => url.\\n *\\\/\\nfunction ddwc_demo_kit_menu( $items ) {\\n\\t$menu_id = wp_create_nav_menu( 'Main menu' );\\n\\tif ( is_wp_error( $menu_id ) ) {\\n\\t\\t$menu_id = wp_get_nav_menu_object( 'Main menu' )->term_id;\\n\\t}\\n\\tforeach ( $items as $label => $url ) {\\n\\t\\twp_update_nav_menu_item( $menu_id, 0, [ 'menu-item-title' => $label, 'menu-item-url' => $url, 'menu-item-status' => 'publish', 'menu-item-type' => 'custom' ] );\\n\\t}\\n\\t$locations            = get_theme_mod( 'nav_menu_locations', [] );\\n\\t$locations['primary'] = $menu_id;\\n\\t$locations['mobile']  = $menu_id;\\n\\tset_theme_mod( 'nav_menu_locations', $locations );\\n}\\n\\n\\\/**\\n * Write the \\\"View as\\\" switcher mu-plugin.\\n *\\n * Pass a PHP expression string that returns the views array; each view:\\n *   [ 'label' => 'Store admin', 'hint' => 'Dashboard & settings', 'icon' => 'admin', 'user' => 'admin', 'url' => admin_url(...) ]\\n * user '' logs the visitor out. icon: any ddwc_demo_kit_icon() name.\\n *\\n * @param string $views_php PHP code (no <?php) that returns the array.\\n *\\\/\\nfunction ddwc_demo_kit_switcher( $views_php ) {\\n\\t$icons = [];\\n\\tforeach ( [ 'admin', 'customer', 'store', 'product', 'cart', 'chat', 'wallet', 'star', 'register', 'link', 'cube', 'rx', 'phone', 'orders', 'calendar' ] as $n ) {\\n\\t\\t$icons[ $n ] = ddwc_demo_kit_icon( $n, 18 );\\n\\t}\\n\\t$code = <<<'DDWCKIT'\\n<?php\\n\\\/**\\n * Live Preview only: \\\"View as\\\" switcher so visitors can jump between the store owner's\\n * admin and the shopper's side without any password.\\n *\\\/\\nfunction ddwc_demo_switcher_views() {\\n\\t__VIEWS__\\n}\\n\\nadd_action(\\n\\t'init',\\n\\tfunction () {\\n\\t\\tif ( ! isset( $_GET['ddwc_demo_view'] ) ) { \\\/\\\/ phpcs:ignore WordPress.Security.NonceVerification -- demo site only.\\n\\t\\t\\treturn;\\n\\t\\t}\\n\\t\\t$views = ddwc_demo_switcher_views();\\n\\t\\t$view  = $views[ absint( $_GET['ddwc_demo_view'] ) ] ?? null; \\\/\\\/ phpcs:ignore WordPress.Security.NonceVerification\\n\\t\\tif ( ! $view ) {\\n\\t\\t\\treturn;\\n\\t\\t}\\n\\t\\twp_clear_auth_cookie();\\n\\t\\twp_set_current_user( 0 );\\n\\t\\t$user = $view['user'] ? get_user_by( 'login', $view['user'] ) : null;\\n\\t\\tif ( $user ) {\\n\\t\\t\\twp_set_current_user( $user->ID );\\n\\t\\t\\twp_set_auth_cookie( $user->ID, true );\\n\\t\\t}\\n\\t\\twp_safe_redirect( $view['url'] );\\n\\t\\texit;\\n\\t},\\n\\t1\\n);\\n\\n\\\/\\\/ Live Preview: keep the storefront clean, the admin bar only appears in wp-admin.\\nadd_filter( 'show_admin_bar', '__return_false' );\\n\\nfunction ddwc_demo_switcher_render() {\\n\\t$icons   = __ICONS__;\\n\\t$views   = ddwc_demo_switcher_views();\\n\\t$current = wp_get_current_user();\\n\\t$here    = untrailingslashit( set_url_scheme( 'http:\\\/\\\/' . ( $_SERVER['HTTP_HOST'] ?? '' ) . ( $_SERVER['REQUEST_URI'] ?? '' ) ) ); \\\/\\\/ phpcs:ignore\\n\\t$items   = '';\\n\\t$label   = '';\\n\\tforeach ( $views as $i => $view ) {\\n\\t\\t$active = untrailingslashit( set_url_scheme( $view['url'] ) ) === $here && ( ! $view['user'] || ( $current->exists() && $current->user_login === $view['user'] ) );\\n\\t\\tif ( $active ) {\\n\\t\\t\\t$label = $view['label'];\\n\\t\\t}\\n\\t\\t$items .= sprintf(\\n\\t\\t\\t'<a href=\\\"%s\\\" class=\\\"ddwc-ds-item%s\\\"><span class=\\\"ddwc-ds-ico\\\">%s<\\\/span><span class=\\\"ddwc-ds-text\\\"><strong>%s<\\\/strong><small>%s<\\\/small><\\\/span><\\\/a>',\\n\\t\\t\\tesc_url( add_query_arg( 'ddwc_demo_view', $i, home_url( '\\\/' ) ) ),\\n\\t\\t\\t$active ? ' is-active' : '',\\n\\t\\t\\t$icons[ $view['icon'] ?? 'store' ] ?? $icons['store'],\\n\\t\\t\\tesc_html( $view['label'] ),\\n\\t\\t\\tesc_html( $view['hint'] ?? '' )\\n\\t\\t);\\n\\t}\\n\\t?>\\n\\t<div id=\\\"ddwc-demo-switcher\\\">\\n\\t\\t<div class=\\\"ddwc-ds-panel\\\" role=\\\"menu\\\">\\n\\t\\t\\t<div class=\\\"ddwc-ds-head\\\">Explore this live demo<\\\/div>\\n\\t\\t\\t<?php echo $items; \\\/\\\/ phpcs:ignore WordPress.Security.EscapeOutput -- escaped above. ?>\\n\\t\\t<\\\/div>\\n\\t\\t<button type=\\\"button\\\" class=\\\"ddwc-ds-toggle\\\" aria-expanded=\\\"false\\\">\\n\\t\\t\\t<span class=\\\"ddwc-ds-dot\\\"><\\\/span>\\n\\t\\t\\t<span>View as<?php echo $label ? ' <b>' . esc_html( $label ) . '<\\\/b>' : ''; ?><\\\/span>\\n\\t\\t\\t<svg viewBox=\\\"0 0 24 24\\\" width=\\\"14\\\" height=\\\"14\\\" fill=\\\"none\\\" stroke=\\\"currentColor\\\" stroke-width=\\\"2.2\\\" stroke-linecap=\\\"round\\\" aria-hidden=\\\"true\\\"><path d=\\\"m6 15 6-6 6 6\\\"\\\/><\\\/svg>\\n\\t\\t<\\\/button>\\n\\t<\\\/div>\\n\\t<style>\\n\\t\\t#ddwc-demo-switcher{position:fixed;left:20px;bottom:20px;z-index:999999;font:400 14px\\\/1.3 -apple-system,BlinkMacSystemFont,\\\"SF Pro Text\\\",\\\"Helvetica Neue\\\",Arial,sans-serif;letter-spacing:-.01em;color:#1d1d1f;-webkit-font-smoothing:antialiased}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-toggle{display:flex;align-items:center;gap:9px;padding:10px 16px;border:0;border-radius:980px;background:rgba(29,29,31,.82);-webkit-backdrop-filter:saturate(180%) blur(20px);backdrop-filter:saturate(180%) blur(20px);color:#f5f5f7;font:inherit;cursor:pointer;box-shadow:0 10px 30px rgba(0,0,0,.24)}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-toggle b{font-weight:600;color:#fff}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-toggle svg{transition:transform .25s cubic-bezier(.25,.1,.25,1);opacity:.7}\\n\\t\\t#ddwc-demo-switcher.is-open .ddwc-ds-toggle svg{transform:rotate(180deg)}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-dot{width:7px;height:7px;border-radius:50%;background:#30d158;box-shadow:0 0 0 3px rgba(48,209,88,.28)}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-panel{position:absolute;left:0;bottom:calc(100% + 10px);width:300px;max-width:calc(100vw - 40px);padding:6px;border-radius:18px;background:rgba(255,255,255,.82);-webkit-backdrop-filter:saturate(180%) blur(24px);backdrop-filter:saturate(180%) blur(24px);box-shadow:0 24px 70px rgba(0,0,0,.22),inset 0 0 0 .5px rgba(0,0,0,.08);opacity:0;visibility:hidden;transform:translateY(6px) scale(.98);transform-origin:bottom left;transition:opacity .2s,transform .25s cubic-bezier(.25,.1,.25,1),visibility .2s}\\n\\t\\t#ddwc-demo-switcher.is-open .ddwc-ds-panel{opacity:1;visibility:visible;transform:none}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-head{padding:10px 12px 8px;font-size:12px;font-weight:600;color:#6e6e73}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-item{display:flex;align-items:center;gap:12px;padding:9px 10px;border-radius:12px;color:#1d1d1f;text-decoration:none}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-item:hover{background:rgba(0,0,0,.05)}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-item.is-active{background:rgba(0,113,227,.1)}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-ico{flex:none;display:grid;place-items:center;width:32px;height:32px;border-radius:9px;background:#e8e8ed;color:#1d1d1f}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-item.is-active .ddwc-ds-ico{background:#0071e3;color:#fff}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-text{display:flex;flex-direction:column;min-width:0}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-text strong{font-weight:600;font-size:14px}\\n\\t\\t#ddwc-demo-switcher .ddwc-ds-text small{font-size:12px;color:#6e6e73}\\n\\t\\t@media (max-width:782px){#ddwc-demo-switcher{left:12px;bottom:auto;top:58px}#ddwc-demo-switcher .ddwc-ds-panel{bottom:auto;top:calc(100% + 10px);transform-origin:top left}}\\n\\t<\\\/style>\\n\\t<script>\\n\\t\\t(function(){var w=document.getElementById('ddwc-demo-switcher');if(!w)return;var b=w.querySelector('.ddwc-ds-toggle');b.addEventListener('click',function(e){e.stopPropagation();var o=w.classList.toggle('is-open');b.setAttribute('aria-expanded',o)});document.addEventListener('click',function(e){if(!w.contains(e.target)){w.classList.remove('is-open');b.setAttribute('aria-expanded','false')}});try{if(!sessionStorage.getItem('ddwcDemoSeen')){w.classList.add('is-open');sessionStorage.setItem('ddwcDemoSeen','1');setTimeout(function(){w.classList.remove('is-open');b.setAttribute('aria-expanded','false')},5000)}}catch(e){}})();\\n\\t<\\\/script>\\n\\t<?php\\n}\\nadd_action( 'wp_footer', 'ddwc_demo_switcher_render' );\\nadd_action( 'admin_footer', 'ddwc_demo_switcher_render' );\\nDDWCKIT;\\n\\twp_mkdir_p( WPMU_PLUGIN_DIR );\\n\\tfile_put_contents( WPMU_PLUGIN_DIR . '\\\/demo-switcher.php', str_replace( [ '__VIEWS__', '__ICONS__' ], [ $views_php, var_export( $icons, true ) ], $code ) );\\n}\\n\\n\\nwp_set_current_user( 1 );\\nddwc_demo_kit_style( [ 'accent' => '#0256ff' ] );\\n\\n$shop    = wc_get_page_permalink( 'shop' );\\n$account = wc_get_page_permalink( 'myaccount' );\\n$first   = get_permalink( $ids[0] );\\n$d0      = DDWCCF_Event_Helper::get_event_data( $ids[0] );\\n$pct     = DDWCCF_Event_Helper::get_progress( $d0 );\\nddwc_demo_kit_home( [\\n\\t'eyebrow'        => 'Fund it together',\\n\\t'title'          => 'Back the projects your neighbours care about.',\\n\\t'lead'           => 'Larkspur Collective runs its campaigns on its own site. Pick a campaign, choose a reward and give through the same checkout you already know.',\\n\\t'ctas'           => [ [ 'See the campaigns', '#campaigns' ], [ 'Open a campaign page', $first ] ],\\n\\t'hero_img'       => [ wp_get_attachment_url( get_post_thumbnail_id( $ids[0] ) ), wp_get_attachment_url( get_post_thumbnail_id( $ids[1] ) ), wp_get_attachment_url( get_post_thumbnail_id( $ids[2] ) ) ],\\n\\t'hero_alt'       => 'Native trees, young campers on a hill and a community bike',\\n\\t'widget'         => '<div class=\\\"dk-widget\\\"><div class=\\\"dk-w-head\\\"><span class=\\\"dk-w-app\\\">' . ddwc_demo_kit_icon( 'heart' ) . '<\\\/span><span><span class=\\\"dk-w-label\\\">Live campaign<\\\/span><span class=\\\"dk-w-title\\\">Plant 10,000 Native Trees Along the Creek<\\\/span><\\\/span><\\\/div>'\\n\\t\\t. '<span class=\\\"dk-w-big\\\">$' . number_format( $d0['collected_amount'] ) . '<\\\/span>'\\n\\t\\t. '<span class=\\\"dk-w-pill\\\">' . (int) $pct . '% of $' . number_format( (float) $d0['target_amount'] ) . ' goal<\\\/span>'\\n\\t\\t. '<div class=\\\"dk-w-row\\\"><span>Supporters<\\\/span><b>' . count( $d0['contributors'] ) . '<\\\/b><\\\/div>'\\n\\t\\t. '<div class=\\\"dk-w-row\\\"><span>Days left<\\\/span><b>' . (int) DDWCCF_Event_Helper::get_days_left( $d0 ) . '<\\\/b><\\\/div><\\\/div>',\\n\\t'features_title' => 'A fundraising page that lives on your own store.',\\n\\t'features'       => [\\n\\t\\t[ 'A live progress card', 'Amount raised, percent funded, supporters and a countdown, right on the campaign page.', 'chart' ],\\n\\t\\t[ 'Reward tiers', 'Offer rewards with a minimum amount, a quantity limit and a delivery date. Limited ones sell out on their own.', 'heart' ],\\n\\t\\t[ 'Your checkout, your gateways', 'Gifts are ordinary WooCommerce orders, so every payment method you already use keeps working.', 'orders' ],\\n\\t],\\n\\t'shelf_title'    => 'Campaigns you can back today.',\\n\\t'shelf_sub'      => 'Every one is a real WooCommerce product with a goal and an end date.',\\n\\t'shelf'          => '<div id=\\\"campaigns\\\">[ddwccf_campaigns limit=\\\"6\\\" columns=\\\"3\\\"]<\\\/div>',\\n\\t'tile'           => [\\n\\t\\t'title' => 'Follow every campaign you backed.',\\n\\t\\t'text'  => 'Supporters get a Backed Campaigns page in My Account with each campaign, their reward and how close it is to the goal.',\\n\\t\\t'cta'   => [ 'Open Backed Campaigns', trailingslashit( $account ) . 'ddwccf-backed\\\/' ],\\n\\t\\t'img'   => wp_get_attachment_url( get_post_thumbnail_id( $ids[3] ) ),\\n\\t\\t'alt'   => 'A turntable playing a record',\\n\\t],\\n] );\\nddwc_demo_kit_menu( [ 'Campaigns' => home_url( '\\\/#campaigns' ), 'My account' => $account ] );\\n\\nforeach ( [ 'cart', 'checkout' ] as $page ) {\\n\\t$pid = wc_get_page_id( $page );\\n\\tif ( $pid > 0 ) {\\n\\t\\twp_update_post( [ 'ID' => $pid, 'post_content' => wp_slash( str_replace( [ '{\\\"align\\\":\\\"wide\\\"}', ' alignwide' ], [ '', '' ], get_post_field( 'post_content', $pid ) ) ) ] );\\n\\t}\\n}\\nflush_rewrite_rules();\\nupdate_option( 'ddwc_demo_campaign', $ids[0] );\\nddwc_demo_kit_switcher( <<<'DDWCVIEWS'\\nreturn [\\n\\t\\t[ 'label' => 'Organiser dashboard', 'hint' => 'Money raised, supporters and the daily trend', 'icon' => 'admin', 'user' => 'admin', 'url' => admin_url( 'admin.php?page=ddwccf-dashboard' ) ],\\n\\t\\t[ 'label' => 'Campaigns and contributions', 'hint' => 'Progress, supporters and order status per campaign', 'icon' => 'orders', 'user' => 'admin', 'url' => admin_url( 'admin.php?page=ddwccf-dashboard&menu=events' ) ],\\n\\t\\t[ 'label' => 'Visitor: campaign page', 'hint' => 'Progress card, rewards and supporters wall', 'icon' => 'heart', 'user' => '', 'url' => get_permalink( (int) get_option( 'ddwc_demo_campaign' ) ) ],\\n\\t\\t[ 'label' => 'Supporter: Backed Campaigns', 'hint' => 'Amara follows the campaigns she gave to', 'icon' => 'customer', 'user' => 'amara', 'url' => trailingslashit( wc_get_page_permalink( 'myaccount' ) ) . 'ddwccf-backed\\\/' ],\\n\\t\\t[ 'label' => 'Storefront', 'hint' => 'The campaigns grid your visitors see', 'icon' => 'store', 'user' => '', 'url' => home_url( '\\\/' ) ],\\n\\t];\\nDDWCVIEWS\\n);\\n\"},{\"step\":\"login\",\"username\":\"admin\",\"password\":\"password\"}]}"}},"all_blocks":[],"tagged_versions":["1.1.0"],"block_files":[],"assets_screenshots":{"screenshot-1.png":{"filename":"screenshot-1.png","revision":3825660,"resolution":"1","location":"assets","locale":"","width":1600,"height":1000},"screenshot-2.png":{"filename":"screenshot-2.png","revision":3825660,"resolution":"2","location":"assets","locale":"","width":1600,"height":1000},"screenshot-3.png":{"filename":"screenshot-3.png","revision":3825660,"resolution":"3","location":"assets","locale":"","width":1600,"height":1000},"screenshot-4.png":{"filename":"screenshot-4.png","revision":3825660,"resolution":"4","location":"assets","locale":"","width":1600,"height":1000},"screenshot-5.png":{"filename":"screenshot-5.png","revision":3825660,"resolution":"5","location":"assets","locale":"","width":1600,"height":1000},"screenshot-6.png":{"filename":"screenshot-6.png","revision":3825660,"resolution":"6","location":"assets","locale":"","width":1600,"height":1000},"screenshot-7.png":{"filename":"screenshot-7.png","revision":3825660,"resolution":"7","location":"assets","locale":"","width":1600,"height":1000},"screenshot-8.png":{"filename":"screenshot-8.png","revision":3825660,"resolution":"8","location":"assets","locale":"","width":1600,"height":1000},"screenshot-9.png":{"filename":"screenshot-9.png","revision":3825660,"resolution":"9","location":"assets","locale":"","width":1600,"height":1000}},"screenshots":{"1":"Campaign page with a progress bar, countdown and reward tiers.","2":"Dashboard with amount raised, contributions, supporters, success rate and a daily trend.","3":"Contribution form with reward tiers, quick pick amounts and a message.","4":"Supporters wall listing backers, amounts and messages.","5":"Campaigns list with raised amount, supporters, end date and status.","6":"Contributions list with supporter, campaign, amount and reward.","7":"Contribution settings for button label, preset amounts and gateways.","8":"Display settings for countdown, supporters wall and campaign tabs.","9":"Setup wizard that sets the defaults in a few steps."}},"plugin_section":[],"plugin_tags":[6452,617,5801,16748,295574],"plugin_category":[45],"plugin_contributors":[220149],"plugin_business_model":[],"class_list":["post-411579","plugin","type-plugin","status-publish","hentry","plugin_tags-crowdfunding","plugin_tags-donation","plugin_tags-fundraising","plugin_tags-kickstarter","plugin_tags-woocommerce-crowdfunding","plugin_category-ecommerce","plugin_contributors-devdiggers","plugin_committers-devdiggers"],"banners":{"banner":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/banner-772x250.png?rev=3825660","banner_2x":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/banner-1544x500.png?rev=3825660","banner_rtl":false,"banner_2x_rtl":false},"icons":{"svg":false,"icon":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/icon-128x128.gif?rev=3825660","icon_2x":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/icon-256x256.gif?rev=3825660","generated":false},"screenshots":[{"src":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/screenshot-1.png?rev=3825660","caption":"Campaign page with a progress bar, countdown and reward tiers."},{"src":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/screenshot-2.png?rev=3825660","caption":"Dashboard with amount raised, contributions, supporters, success rate and a daily trend."},{"src":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/screenshot-3.png?rev=3825660","caption":"Contribution form with reward tiers, quick pick amounts and a message."},{"src":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/screenshot-4.png?rev=3825660","caption":"Supporters wall listing backers, amounts and messages."},{"src":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/screenshot-5.png?rev=3825660","caption":"Campaigns list with raised amount, supporters, end date and status."},{"src":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/screenshot-6.png?rev=3825660","caption":"Contributions list with supporter, campaign, amount and reward."},{"src":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/screenshot-7.png?rev=3825660","caption":"Contribution settings for button label, preset amounts and gateways."},{"src":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/screenshot-8.png?rev=3825660","caption":"Display settings for countdown, supporters wall and campaign tabs."},{"src":"https:\/\/ps.w.org\/devdiggers-crowdfunding-for-woocommerce\/assets\/screenshot-9.png?rev=3825660","caption":"Setup wizard that sets the defaults in a few steps."}],"raw_content":"<!--section=description-->\n<p>You want to raise money for a project, a cause or a product that does not exist yet. A donation button does not show how close you are, and a separate fundraising platform takes a cut and sends your supporters somewhere else.<\/p>\n\n<p><strong>Crowdfunding for WooCommerce<\/strong> is a free <strong><a href=\"https:\/\/devdiggers.com\/product\/woocommerce-crowdfunding\/\">WooCommerce crowdfunding plugin<\/a><\/strong> that turns any campaign into a page on your own store. Set a goal and an end date, add reward tiers, and supporters pay through your normal WooCommerce checkout, so every payment gateway you already use keeps working. The campaign page shows the money raised, a progress bar, a countdown and everyone who backed it.<\/p>\n\n<p>There is no platform fee and no account to create. Contributions are ordinary WooCommerce orders in your own database, and campaign and supporter data never leave your store.<\/p>\n\n<h4>Quick links<\/h4>\n\n<ul>\n<li><a href=\"https:\/\/docs.devdiggers.com\/woocommerce-crowdfunding\/\">Documentation<\/a><\/li>\n<li><a href=\"https:\/\/wordpress.org\/support\/plugin\/devdiggers-crowdfunding-for-woocommerce\/\">Support<\/a><\/li>\n<li><a href=\"https:\/\/github.com\/DevDiggers-Technologies\/crowdfunding-for-woocommerce\">Source code on GitHub<\/a><\/li>\n<li><a href=\"https:\/\/demo.devdiggers.com\/crowdfunding-for-woocommerce\/\">Free Demo<\/a><\/li>\n<li><a href=\"https:\/\/demo.devdiggers.com\/woocommerce-crowdfunding\/\">Pro Demo<\/a><\/li>\n<li><a href=\"https:\/\/devdiggers.com\/product\/woocommerce-crowdfunding\/#free-vs-pro\">Free vs Pro Comparison<\/a><\/li>\n<li><a href=\"https:\/\/devdiggers.com\/product\/woocommerce-crowdfunding\/\">Upgrade to Pro<\/a><\/li>\n<\/ul>\n\n<h4>Who it is for<\/h4>\n\n<ul>\n<li>Schools, clubs and charities collecting money for a project<\/li>\n<li>Stores that pre-sell a new product and only build it once enough people back it<\/li>\n<li>Creators who want a campaign page on their own site instead of a third party platform<\/li>\n<li>Anyone who wants a donation page that shows real progress<\/li>\n<\/ul>\n\n<h4>How it works<\/h4>\n\n<ol>\n<li>Create a campaign under <strong>Crowdfunding &gt; Campaigns<\/strong>: a story, a cover image, a goal, an end date and as many reward tiers as you need.<\/li>\n<li>Put <code>[ddwccf_campaigns]<\/code> on a page, or link straight to the campaign.<\/li>\n<li>Supporters pick a reward, choose an amount and pay through your WooCommerce checkout.<\/li>\n<li>As soon as the order is paid, the contribution counts toward the goal. If the order is cancelled, refunded or fails, it comes off again.<\/li>\n<\/ol>\n\n<h4>What the free plugin does<\/h4>\n\n<h3>Campaign page<\/h3>\n\n<ul>\n<li>Amount raised, goal and a progress bar at the top of the product page<\/li>\n<li>Funded percentage, supporter count and days left<\/li>\n<li>A live countdown to the end date<\/li>\n<li>The organiser's name and avatar<\/li>\n<li>Story, Rewards and Supporters tabs in place of the usual product tabs<\/li>\n<li>Share buttons for Facebook, X, WhatsApp, LinkedIn, email and copy link<\/li>\n<li>Your own accent color for the progress bar and highlights<\/li>\n<\/ul>\n\n<h3>Giving<\/h3>\n\n<ul>\n<li>Fixed contributions, or supporters choose the amount with quick pick buttons such as $10, $25, $50 and $100<\/li>\n<li>A minimum per campaign and an optional maximum per contribution<\/li>\n<li>Reward tiers, as many per campaign as you need, each with a minimum amount, an optional quantity limit and an estimated delivery date. Limited rewards show how many are left and switch to Sold out on their own.<\/li>\n<li>Anonymous giving that hides the name from the public supporters wall<\/li>\n<li>A short public message of support<\/li>\n<li>Limit which payment gateways are offered when the cart holds a contribution<\/li>\n<li>Close a campaign automatically once it reaches its goal, or let it keep raising until the end date<\/li>\n<\/ul>\n\n<h3>Supporters<\/h3>\n\n<ul>\n<li>A supporters wall with recent supporters, amounts and messages. It shows first name and last initial only.<\/li>\n<li>A <strong>Backed Campaigns<\/strong> page in My Account where supporters follow every campaign they backed<\/li>\n<\/ul>\n\n<h3>Admin<\/h3>\n\n<ul>\n<li><strong>Dashboard<\/strong>: amount raised, contributions, supporters, average contribution and success rate with period comparison, a trend chart, campaign status, top campaigns, recent contributions and campaigns ending soon<\/li>\n<li><strong>Campaigns<\/strong>: progress, supporters, end date and status for every campaign, with search, sorting and bulk enable, disable and trash<\/li>\n<li><strong>Contributions<\/strong>: every contribution with its order status, reward, message and whether it counts toward the goal, filterable by campaign<\/li>\n<li><strong>Setup wizard<\/strong> that gets a new store ready in a few steps<\/li>\n<\/ul>\n\n<h3>Emails<\/h3>\n\n<p>Four notifications, each with its own on and off switch and your own subject, heading and message with placeholders such as {campaign_name}, {amount} and {supporter_name}. They use your WooCommerce email design:<\/p>\n\n<ul>\n<li>Thank you to the supporter<\/li>\n<li>New contribution to the organiser<\/li>\n<li>Goal reached<\/li>\n<li>Campaign ended<\/li>\n<\/ul>\n\n<h3>Shortcodes<\/h3>\n\n<ul>\n<li><code>[ddwccf_campaigns]<\/code> shows a grid of campaign cards, with options for columns, limit, order, status, pagination and hand picked IDs<\/li>\n<li><code>[ddwccf_campaign id=\"123\"]<\/code> shows the card of one campaign<\/li>\n<\/ul>\n\n<h3>AI assistants (MCP)<\/h3>\n\n<p>Ask Claude, ChatGPT, Cursor, VS Code or any MCP client about your campaigns in plain words: \"How is my crowdfunding doing this month?\", \"Which campaigns will miss their goal?\", \"Who backed this campaign?\"<\/p>\n\n<ul>\n<li>Tools for an overview, campaigns with their progress (raised against goal, backers, days left), one campaign with its reward tiers, the backers of a campaign and the campaigns ending soon with their pace<\/li>\n<li>A Campaign performance review prompt<\/li>\n<li>Optional: let the assistant extend a campaign's end date or enable or disable a campaign, logged under WooCommerce &gt; Status &gt; Logs<\/li>\n<li>Store managers only, managed in DevDiggers Plugins &gt; AI &amp; MCP with an on and off switch per plugin and per write tool (write tools start off)<\/li>\n<li>Needs WordPress 6.9 or later and the MCP Adapter, which WooCommerce 10.3 and later bundles. Developers can change the tools with the <code>ddwccf_mcp_abilities<\/code> filter.<\/li>\n<\/ul>\n\n<h4>Free vs Pro<\/h4>\n\n<p>The free plugin is a complete way to run your own campaigns. <a href=\"https:\/\/devdiggers.com\/product\/woocommerce-crowdfunding\/\">Pro<\/a> turns your store into a fundraising platform where customers run campaigns too. Inside the free plugin you can see each Pro feature where it would sit, marked PRO.<\/p>\n\n<h3>Customer campaigns (Pro)<\/h3>\n\n<ul>\n<li>Customers start and manage their own campaigns from My Account, with a sectioned editor and image upload.<\/li>\n<li>Approve new campaigns before they go live, exclude roles and limit how long a campaign can run.<\/li>\n<li>Creators see their supporters and request a payout once their campaign closes.<\/li>\n<\/ul>\n\n<h3>Payouts and fees (Pro)<\/h3>\n\n<ul>\n<li>A platform fee as a percentage or fixed amount, with an override per campaign.<\/li>\n<li>\"Cover the fee\" so supporters can add the fee on top and the creator gets the full gift.<\/li>\n<li>Payout requests you mark as paid or reject, or pay straight into the creator's DevDiggers Wallet.<\/li>\n<\/ul>\n\n<h3>Kickstarter style funding (Pro)<\/h3>\n\n<ul>\n<li><strong>All or nothing<\/strong> campaigns that only release the money when the goal is met, with one click refunds of every supporter when it is missed.<\/li>\n<li><strong>Stretch goals<\/strong> marked on the progress bar.<\/li>\n<li><strong>Campaign updates<\/strong> in an Updates tab, emailed to every supporter in the background.<\/li>\n<\/ul>\n\n<h3>Discovery and sharing (Pro)<\/h3>\n\n<ul>\n<li>A filterable campaigns page with search, category, status and sort filters.<\/li>\n<li>Campaign categories and featured campaigns.<\/li>\n<li>An embed code that puts a live campaign card on other websites.<\/li>\n<li>Share button shape, style, size and label options.<\/li>\n<\/ul>\n\n<h3>Management (Pro)<\/h3>\n\n<ul>\n<li>A Needs Attention list for approvals, payouts and refunds.<\/li>\n<li>CSV export of campaigns and contributions.<\/li>\n<li>Six more email notifications for the Pro features: campaign submitted, campaign approved, campaign update and the three payout emails.<\/li>\n<\/ul>\n\n<h3>External services<\/h3>\n\n<p>Campaigns, contributions and supporter details are stored in your WordPress database, and notifications go out through the WooCommerce mailer. The plugin has no licence checks, no update checks and no tracking. It connects to the outside services below only in the situations described, and none of them receives campaign, order or customer data.<\/p>\n\n<p><strong>1. Gravatar (avatar images)<\/strong><\/p>\n\n<ul>\n<li>What it is: Gravatar, the avatar service run by Automattic, used through WordPress core's <code>get_avatar()<\/code>.<\/li>\n<li>What it is used for: Showing the organiser's avatar on campaign pages, and supporter and user avatars on the admin screens. This is standard WordPress behaviour.<\/li>\n<li>When data is sent: When one of those pages is viewed and avatars are turned on under <strong>Settings &gt; Discussion<\/strong>. Turning avatars off there stops the requests.<\/li>\n<li>What data is sent: A hash of the person's email address inside the image URL, plus the usual details of the viewer's browser request, such as IP address and user agent.<\/li>\n<li>Terms of Service: https:\/\/gravatar.com\/tos<\/li>\n<li>Privacy Policy: https:\/\/gravatar.com\/privacy<\/li>\n<\/ul>\n\n<p><strong>2. Share buttons<\/strong><\/p>\n\n<p>The share buttons are plain links. Nothing is loaded from the networks until a visitor clicks one, which opens that network's share page in a new tab with the campaign title and link. No tracking scripts are added.<\/p>\n\n<ul>\n<li>Facebook: https:\/\/www.facebook.com\/privacy\/policy\/<\/li>\n<li>X: https:\/\/x.com\/en\/privacy<\/li>\n<li>WhatsApp: https:\/\/www.whatsapp.com\/legal\/privacy-policy<\/li>\n<li>LinkedIn: https:\/\/www.linkedin.com\/legal\/privacy-policy<\/li>\n<\/ul>\n\n<p>The bundled DevDiggers framework, which draws the admin screens, can connect to the two DevDiggers services below. Both are off until an administrator asks for them, and both run only inside the WordPress admin.<\/p>\n\n<p><strong>3. DevDiggers extensions list (opt in)<\/strong><\/p>\n\n<ul>\n<li>What it is: A read only API on devdiggers.com that returns the public list of DevDiggers extensions.<\/li>\n<li>What it is used for: Showing the list on the <strong>DevDiggers Plugins &gt; Extensions<\/strong> admin page.<\/li>\n<li>When data is sent: Only after an administrator clicks <strong>Load extensions from devdiggers.com<\/strong> on that page. Until then the page makes no request and shows a link to the list on devdiggers.com instead. The response is cached for a day, and <strong>Stop loading it<\/strong> at the bottom of the page turns the requests off again and clears the cache.<\/li>\n<li>What data is sent: A standard request from your server, which reveals its IP address and a \"DevDiggers Framework\" user agent. Once the list is shown, the administrator's browser also loads each extension's image from devdiggers.com. No personal data and no store data are sent.<\/li>\n<li>Endpoint: https:\/\/devdiggers.com\/wp-json\/ddwcs\/v1\/plugins<\/li>\n<\/ul>\n\n<p><strong>4. DevDiggers newsletter (opt in)<\/strong><\/p>\n\n<ul>\n<li>What it is: A contact and newsletter endpoint on devdiggers.com.<\/li>\n<li>What it is used for: Adding your email address to the DevDiggers newsletter, only if you choose to subscribe.<\/li>\n<li>When data is sent: Only when an administrator types an email address into the newsletter form on the <strong>DevDiggers Plugins &gt; Dashboard<\/strong> page and clicks Subscribe. Nothing is sent automatically.<\/li>\n<li>What data is sent: The email address you enter and your site URL.<\/li>\n<li>Endpoint: https:\/\/devdiggers.com\/?fluentcrm=1&amp;route=contact<\/li>\n<\/ul>\n\n<p>Both DevDiggers services are provided by DevDiggers under its Terms and Conditions (https:\/\/devdiggers.com\/terms-and-conditions\/) and Privacy Policy (https:\/\/devdiggers.com\/privacy-policy\/).<\/p>\n\n<h3>Source code and build tools<\/h3>\n\n<p>The admin and storefront JavaScript and CSS in <code>assets\/<\/code> are compiled from the human readable source in the <code>src\/<\/code> folder, which ships with the plugin. The full source, including the build configuration, is also published on GitHub:<\/p>\n\n<p>https:\/\/github.com\/DevDiggers-Technologies\/crowdfunding-for-woocommerce<\/p>\n\n<p>To build the assets from source:<\/p>\n\n<ol>\n<li>Run <code>npm install<\/code> to install the build dependencies listed in <code>package.json<\/code>.<\/li>\n<li>Run <code>npm run build<\/code> to compile the production assets into <code>assets\/js<\/code> and <code>assets\/css<\/code>.<\/li>\n<\/ol>\n\n<p>The build configuration is in <code>webpack.config.js<\/code> and <code>babel.config.js<\/code>.<\/p>\n\n<p>The admin screens share the bundled DevDiggers Framework. The human readable source of its compiled files in <code>devdiggers-framework\/assets\/js<\/code> and <code>devdiggers-framework\/assets\/css<\/code> (framework, dashboard, dashboard analytics, setup wizard, review notice and the AI &amp; MCP page) is in the same GitHub repository under <code>devdiggers-framework\/src<\/code>, with its own <code>package.json<\/code>, <code>webpack.config.js<\/code> and <code>babel.config.js<\/code>. To rebuild them, clone the repository, then run <code>npm install<\/code> and <code>npm run build<\/code> inside the <code>devdiggers-framework<\/code> folder.<\/p>\n\n<p>Two third party libraries used by the admin screens ship unmodified under the MIT licence inside <code>devdiggers-framework\/assets\/js\/<\/code>: Chart.js (https:\/\/www.chartjs.org) and Select2 (https:\/\/select2.org).<\/p>\n\n<!--section=installation-->\n<h4>Automatic installation<\/h4>\n\n<ol>\n<li>In your WordPress admin, go to <strong>Plugins &gt; Add New<\/strong>.<\/li>\n<li>Search for \"Crowdfunding for WooCommerce\".<\/li>\n<li>Click <strong>Install Now<\/strong>, then <strong>Activate<\/strong>.<\/li>\n<\/ol>\n\n<h4>Manual installation<\/h4>\n\n<ol>\n<li>Download the plugin zip.<\/li>\n<li>Go to <strong>Plugins &gt; Add New &gt; Upload Plugin<\/strong> and upload the zip.<\/li>\n<li>Activate the plugin.<\/li>\n<\/ol>\n\n<h4>After activating<\/h4>\n\n<p>The setup wizard opens. Then create your first campaign under <strong>Crowdfunding &gt; Campaigns &gt; Add Campaign<\/strong> and add <code>[ddwccf_campaigns]<\/code> to a page, since campaigns are hidden from the shop.<\/p>\n\n<h4>Requirements<\/h4>\n\n<ul>\n<li>WordPress 6.5 or later<\/li>\n<li>WooCommerce 9.0 or later<\/li>\n<li>PHP 7.4 or later<\/li>\n<\/ul>\n\n<!--section=faq-->\n<dl>\n<dt id=\"which%20payment%20gateways%20work%3F\"><h3>Which payment gateways work?<\/h3><\/dt>\n<dd><p>All of them. Contributions go through the normal WooCommerce checkout, so any gateway your store uses accepts them. You can limit which gateways are offered for contributions under Configuration &gt; Contributions.<\/p><\/dd>\n<dt id=\"when%20does%20a%20contribution%20count%20toward%20the%20goal%3F\"><h3>When does a contribution count toward the goal?<\/h3><\/dt>\n<dd><p>When its order is paid, which means Processing or Completed. It is removed again if the order is cancelled, refunded or fails, and an order is never counted twice.<\/p><\/dd>\n<dt id=\"are%20campaigns%20shown%20in%20my%20shop%3F\"><h3>Are campaigns shown in my shop?<\/h3><\/dt>\n<dd><p>No. Campaigns are hidden from the shop and search, so they never mix with your products. Use the <code>[ddwccf_campaigns]<\/code> shortcode to list them on a page.<\/p><\/dd>\n<dt id=\"can%20supporters%20give%20anonymously%3F\"><h3>Can supporters give anonymously?<\/h3><\/dt>\n<dd><p>Yes, when you allow it. Their name is hidden from the public supporters wall, while you still see who gave.<\/p><\/dd>\n<dt id=\"can%20supporters%20choose%20how%20much%20to%20give%3F\"><h3>Can supporters choose how much to give?<\/h3><\/dt>\n<dd><p>Yes. Choose \"Supporters choose the amount\" on a campaign and set a minimum. Quick pick amounts are set under Configuration &gt; Contributions.<\/p><\/dd>\n<dt id=\"how%20many%20reward%20tiers%20can%20a%20campaign%20have%3F\"><h3>How many reward tiers can a campaign have?<\/h3><\/dt>\n<dd><p>As many as you like. Each tier has a minimum amount, an optional quantity limit and an estimated delivery date.<\/p><\/dd>\n<dt id=\"can%20customers%20create%20their%20own%20campaigns%3F\"><h3>Can customers create their own campaigns?<\/h3><\/dt>\n<dd><p>That is part of Pro, together with approvals, platform fees and creator payouts. In the free plugin you create every campaign from the admin and can name any user as its organiser.<\/p><\/dd>\n<dt id=\"does%20it%20work%20with%20the%20block%20checkout%20and%20hpos%3F\"><h3>Does it work with the block checkout and HPOS?<\/h3><\/dt>\n<dd><p>Yes. It works with the classic and block checkout and with WooCommerce High Performance Order Storage (HPOS).<\/p><\/dd>\n<dt id=\"will%20my%20campaigns%20be%20kept%20if%20i%20upgrade%20to%20pro%3F\"><h3>Will my campaigns be kept if I upgrade to Pro?<\/h3><\/dt>\n<dd><p>Yes. Pro uses the same campaigns, contributions and settings, so nothing has to be set up again.<\/p><\/dd>\n<dt id=\"do%20i%20need%20a%20kickstarter%2C%20gofundme%20or%20paypal%20account%3F\"><h3>Do I need a Kickstarter, GoFundMe or PayPal account?<\/h3><\/dt>\n<dd><p>No. Campaigns live on your own WooCommerce store and are paid through the gateways you already use, so there is no platform fee and nothing to sign up for. Unlike Kickstarter, the free plugin does not hold money back until a goal is met. That all or nothing mode is part of Pro.<\/p><\/dd>\n<dt id=\"can%20i%20translate%20the%20plugin%3F\"><h3>Can I translate the plugin?<\/h3><\/dt>\n<dd><p>Yes. Every string is translatable, and a <code>.pot<\/code> file ships in the <code>i18n<\/code> folder.<\/p><\/dd>\n\n<\/dl>\n\n<!--section=changelog-->\n<h4>1.1.0 - 2026-11-24<\/h4>\n\n<ul>\n<li>New: AI assistants (MCP). Ask Claude, ChatGPT, Cursor, VS Code or any MCP client about your campaigns: an overview, progress against goal, reward tiers, backers and campaigns ending soon, plus a Campaign performance review prompt.<\/li>\n<li>New: Optional AI tools to extend a campaign's end date or enable or disable a campaign. They stay off until you allow them.<\/li>\n<li>New: DevDiggers Plugins &gt; AI &amp; MCP page. Connect Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code or any MCP client by signing in and clicking Allow, with an on and off switch per plugin and per write tool, a Try panel and an activity log.<\/li>\n<li>Improved: Updated the DevDiggers framework to 1.3.0. The title bar with Save stays visible on edit screens while you scroll on desktop, and admin charts and pickers keep working when a theme or plugin replaces the shared Select2 script.<\/li>\n<\/ul>\n\n<h4>1.0.0 - 2026-10-17<\/h4>\n\n<ul>\n<li>New: Crowdfunding and donation campaigns with a goal, an end date or both.<\/li>\n<li>New: Fixed or \"choose your amount\" contributions with quick pick amounts.<\/li>\n<li>New: Reward tiers with quantity limits and delivery dates, as many per campaign as you need.<\/li>\n<li>New: Option to remove or rename the \"No reward\" choice.<\/li>\n<li>New: Campaign progress card, countdown, Story, Rewards and Supporters tabs.<\/li>\n<li>New: Supporters wall with messages and anonymous giving.<\/li>\n<li>New: Share buttons and a Backed Campaigns page in My Account.<\/li>\n<li>New: Dashboard, Campaigns and Contributions screens and a setup wizard.<\/li>\n<li>New: Four email notifications with editable subject, heading and message, and two shortcodes.<\/li>\n<\/ul>","raw_excerpt":"Run crowdfunding and fundraising campaigns in WooCommerce: goals, reward tiers, a progress bar, countdown and a backer wall, Kickstarter style.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/411579","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=411579"}],"author":[{"embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/devdiggers"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=411579"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=411579"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=411579"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=411579"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=411579"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=411579"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}