fluentcart-developer 2.0.2 → 2.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. package/README.md +59 -59
  2. package/dist/cards/fluentcart/tools.d.ts.map +1 -1
  3. package/dist/cards/fluentcart/tools.js +184 -18
  4. package/dist/cards/fluentcart/tools.js.map +1 -1
  5. package/dist/skills/fluentcart-developer/.claude-plugin/plugin.json +12 -12
  6. package/dist/skills/fluentcart-developer/.mcp.json +11 -11
  7. package/dist/skills/fluentcart-developer/examples/fluentcart-starter-child-theme/fluent-cart/checkout.php +32 -32
  8. package/dist/skills/fluentcart-developer/examples/fluentcart-starter-child-theme/functions.php +40 -40
  9. package/dist/skills/fluentcart-developer/examples/sample-fee-surcharge-plugin/fluentcart-fee-surcharge.php +38 -38
  10. package/dist/skills/fluentcart-developer/references/action-hooks-cart-checkout.md +1355 -1355
  11. package/dist/skills/fluentcart-developer/references/action-hooks-customers-users.md +266 -266
  12. package/dist/skills/fluentcart-developer/references/action-hooks-licenses.md +855 -855
  13. package/dist/skills/fluentcart-developer/references/action-hooks-orders.md +631 -631
  14. package/dist/skills/fluentcart-developer/references/action-hooks-payments-integrations.md +963 -963
  15. package/dist/skills/fluentcart-developer/references/action-hooks-products-coupons.md +585 -585
  16. package/dist/skills/fluentcart-developer/references/action-hooks-subscriptions.md +661 -661
  17. package/dist/skills/fluentcart-developer/references/database-models-query-builder.md +194 -194
  18. package/dist/skills/fluentcart-developer/references/database-models-reference.md +604 -604
  19. package/dist/skills/fluentcart-developer/references/engineering-notes.md +154 -154
  20. package/dist/skills/fluentcart-developer/references/fee-system-guide.md +449 -449
  21. package/dist/skills/fluentcart-developer/references/filter-hooks-cart-checkout.md +1202 -1202
  22. package/dist/skills/fluentcart-developer/references/filter-hooks-integrations-advanced.md +1598 -1598
  23. package/dist/skills/fluentcart-developer/references/filter-hooks-products-pricing.md +628 -628
  24. package/dist/skills/fluentcart-developer/references/filter-hooks-settings-configuration.md +1177 -1177
  25. package/dist/skills/fluentcart-developer/references/fluentcart-developer-guide.md +154 -154
  26. package/dist/skills/fluentcart-developer/references/ghost-product-selling.md +458 -458
  27. package/dist/skills/fluentcart-developer/references/modules-and-extensions-reference.md +224 -224
  28. package/dist/skills/fluentcart-developer/references/payment-gateway-integration.md +761 -761
  29. package/dist/skills/fluentcart-developer/references/rest-api-customer-profile.md +190 -190
  30. package/dist/skills/fluentcart-developer/references/rest-api-customers.md +1121 -1121
  31. package/dist/skills/fluentcart-developer/references/rest-api-dashboard-utilities.md +219 -219
  32. package/dist/skills/fluentcart-developer/references/rest-api-email-notifications.md +619 -619
  33. package/dist/skills/fluentcart-developer/references/rest-api-files.md +290 -290
  34. package/dist/skills/fluentcart-developer/references/rest-api-integrations.md +324 -324
  35. package/dist/skills/fluentcart-developer/references/rest-api-labels-attributes.md +321 -321
  36. package/dist/skills/fluentcart-developer/references/rest-api-order-bumps.md +200 -200
  37. package/dist/skills/fluentcart-developer/references/rest-api-overview.md +131 -131
  38. package/dist/skills/fluentcart-developer/references/rest-api-public-shop.md +172 -172
  39. package/dist/skills/fluentcart-developer/references/rest-api-reference.md +552 -552
  40. package/dist/skills/fluentcart-developer/references/rest-api-reports.md +377 -377
  41. package/dist/skills/fluentcart-developer/references/rest-api-roles-permissions.md +147 -147
  42. package/dist/skills/fluentcart-developer/references/rest-api-settings.md +528 -528
  43. package/dist/skills/fluentcart-developer/references/rest-api-shipping.md +799 -799
  44. package/dist/skills/fluentcart-developer/references/rest-api-tax.md +356 -356
  45. package/dist/skills/fluentcart-developer/references/subscription-customization.md +197 -197
  46. package/dist/skills/fluentcart-developer/scripts/cli.js +1 -1
  47. package/dist/version.d.ts +1 -1
  48. package/dist/version.js +1 -1
  49. package/package.json +65 -65
  50. package/dist/skills/fluentcart-developer/references/client-integration-contract.md +0 -299
  51. package/dist/skills/fluentcart-developer/references/device-licensing-and-hardware-tracking.md +0 -241
  52. package/dist/skills/fluentcart-developer/references/trial-abuse-prevention.md +0 -304
@@ -1,40 +1,40 @@
1
- <?php
2
- /**
3
- * Child Theme Functions for FluentCart Compatibility
4
- *
5
- * Theme Name: FluentCart Starter Child Theme
6
- * Author: Fastrsoft
7
- * License: MIT
8
- */
9
-
10
- if (!defined('ABSPATH')) {
11
- exit; // Exit if accessed directly
12
- }
13
-
14
- // 1. Declare FluentCart Theme Support in Child Theme
15
- add_action('after_setup_theme', function() {
16
- // Enables template overriding and page detection in FluentCart
17
- add_theme_support('fluent_cart');
18
- });
19
-
20
- // 2. Enqueue Custom Child Theme & FluentCart Styling Assets
21
- add_action('wp_enqueue_scripts', function() {
22
- // Enqueue parent theme stylesheet
23
- wp_enqueue_style('parent-style', get_template_directory_uri() . '/style.css');
24
-
25
- // Enqueue custom FluentCart store overrides stylesheet
26
- wp_enqueue_style(
27
- 'fluentcart-child-custom',
28
- get_stylesheet_directory_uri() . '/fluent-cart-custom.css',
29
- ['parent-style'],
30
- '1.0.0'
31
- );
32
- });
33
-
34
- // 3. Example Hook: Inject Custom Notice above Checkout Form
35
- add_action('fluent_cart/checkout/before_form', function() {
36
- // Output custom customer guarantee banner on checkout page
37
- echo '<div class="fluentcart-custom-notice" style="background:#eef6ff; border:1px solid #b6d4fe; padding:12px; margin-bottom:20px; border-radius:6px;">';
38
- echo '🔒 <strong>100% Secure Checkout Guarantee:</strong> Your data is protected by 256-bit SSL encryption.';
39
- echo '</div>';
40
- });
1
+ <?php
2
+ /**
3
+ * Child Theme Functions for FluentCart Compatibility
4
+ *
5
+ * Theme Name: FluentCart Starter Child Theme
6
+ * Author: Fastrsoft
7
+ * License: MIT
8
+ */
9
+
10
+ if (!defined('ABSPATH')) {
11
+ exit; // Exit if accessed directly
12
+ }
13
+
14
+ // 1. Declare FluentCart Theme Support in Child Theme
15
+ add_action('after_setup_theme', function() {
16
+ // Enables template overriding and page detection in FluentCart
17
+ add_theme_support('fluent_cart');
18
+ });
19
+
20
+ // 2. Enqueue Custom Child Theme & FluentCart Styling Assets
21
+ add_action('wp_enqueue_scripts', function() {
22
+ // Enqueue parent theme stylesheet
23
+ wp_enqueue_style('parent-style', get_template_directory_uri() . '/style.css');
24
+
25
+ // Enqueue custom FluentCart store overrides stylesheet
26
+ wp_enqueue_style(
27
+ 'fluentcart-child-custom',
28
+ get_stylesheet_directory_uri() . '/fluent-cart-custom.css',
29
+ ['parent-style'],
30
+ '1.0.0'
31
+ );
32
+ });
33
+
34
+ // 3. Example Hook: Inject Custom Notice above Checkout Form
35
+ add_action('fluent_cart/checkout/before_form', function() {
36
+ // Output custom customer guarantee banner on checkout page
37
+ echo '<div class="fluentcart-custom-notice" style="background:#eef6ff; border:1px solid #b6d4fe; padding:12px; margin-bottom:20px; border-radius:6px;">';
38
+ echo '🔒 <strong>100% Secure Checkout Guarantee:</strong> Your data is protected by 256-bit SSL encryption.';
39
+ echo '</div>';
40
+ });
@@ -1,38 +1,38 @@
1
- <?php
2
- /**
3
- * Plugin Name: FluentCart Fee Surcharge Addon
4
- * Description: Example plugin demonstrating dynamic conditional fee surcharges (e.g. Gift Wrapping & Heavy Freight fees) in FluentCart.
5
- * Version: 1.0.0
6
- * Author: Developer Team
7
- */
8
-
9
- if (!defined('ABSPATH')) {
10
- exit;
11
- }
12
-
13
- // Hook into FluentCart fee calculation lifecycle
14
- add_filter('fluent_cart/fee_items', function ($fees, $cart) {
15
- // Calculate subtotal in cents
16
- $subtotal = $cart->getSubTotal();
17
-
18
- // Condition 1: Add $3.50 (350 cents) Gift Wrapping Fee for orders under $50.00 (5000 cents)
19
- if ($subtotal < 5000) {
20
- $fees[] = [
21
- 'id' => 'gift_wrap_fee',
22
- 'title' => __('Optional Gift Packaging', 'fc-fee-addon'),
23
- 'amount' => 350, // 350 cents = $3.50
24
- 'taxable' => false,
25
- ];
26
- }
27
-
28
- // Condition 2: Add 2% Payment Surcharge (percentage fee)
29
- $surchargeAmount = (int) round($subtotal * 0.02); // 2% calculation in cents
30
- $fees[] = [
31
- 'id' => 'payment_surcharge',
32
- 'title' => __('Payment Processing Surcharge (2%)', 'fc-fee-addon'),
33
- 'amount' => $surchargeAmount,
34
- 'taxable' => false,
35
- ];
36
-
37
- return $fees;
38
- }, 10, 2);
1
+ <?php
2
+ /**
3
+ * Plugin Name: FluentCart Fee Surcharge Addon
4
+ * Description: Example plugin demonstrating dynamic conditional fee surcharges (e.g. Gift Wrapping & Heavy Freight fees) in FluentCart.
5
+ * Version: 1.0.0
6
+ * Author: Developer Team
7
+ */
8
+
9
+ if (!defined('ABSPATH')) {
10
+ exit;
11
+ }
12
+
13
+ // Hook into FluentCart fee calculation lifecycle
14
+ add_filter('fluent_cart/fee_items', function ($fees, $cart) {
15
+ // Calculate subtotal in cents
16
+ $subtotal = $cart->getSubTotal();
17
+
18
+ // Condition 1: Add $3.50 (350 cents) Gift Wrapping Fee for orders under $50.00 (5000 cents)
19
+ if ($subtotal < 5000) {
20
+ $fees[] = [
21
+ 'id' => 'gift_wrap_fee',
22
+ 'title' => __('Optional Gift Packaging', 'fc-fee-addon'),
23
+ 'amount' => 350, // 350 cents = $3.50
24
+ 'taxable' => false,
25
+ ];
26
+ }
27
+
28
+ // Condition 2: Add 2% Payment Surcharge (percentage fee)
29
+ $surchargeAmount = (int) round($subtotal * 0.02); // 2% calculation in cents
30
+ $fees[] = [
31
+ 'id' => 'payment_surcharge',
32
+ 'title' => __('Payment Processing Surcharge (2%)', 'fc-fee-addon'),
33
+ 'amount' => $surchargeAmount,
34
+ 'taxable' => false,
35
+ ];
36
+
37
+ return $fees;
38
+ }, 10, 2);