@akinon/projectzero 1.115.0-snapshot-ZERO-3855-20251209090338 → 1.115.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,6 +1,10 @@
1
1
  # @akinon/projectzero
2
2
 
3
- ## 1.115.0-snapshot-ZERO-3855-20251209090338
3
+ ## 1.115.0
4
+
5
+ ### Minor Changes
6
+
7
+ - b59bed4d: ZERO-3878: Reintegrated similar products and removed localStorage checks and implemented props based showing of buttons
4
8
 
5
9
  ## 1.114.0
6
10
 
@@ -1,5 +1,43 @@
1
1
  # projectzeronext
2
2
 
3
+ ## 1.115.0
4
+
5
+ ### Minor Changes
6
+
7
+ - b59bed4d: ZERO-3878: Reintegrated similar products and removed localStorage checks and implemented props based showing of buttons
8
+
9
+ ### Patch Changes
10
+
11
+ - Updated dependencies [b59bed4d]
12
+ - Updated dependencies [b5f9d75c]
13
+ - Updated dependencies [cbcfdf4d]
14
+ - Updated dependencies [1880978c]
15
+ - Updated dependencies [71882722]
16
+ - Updated dependencies [7056203a]
17
+ - @akinon/next@1.115.0
18
+ - @akinon/pz-virtual-try-on@1.115.0
19
+ - @akinon/pz-akifast@1.115.0
20
+ - @akinon/pz-apple-pay@1.115.0
21
+ - @akinon/pz-b2b@1.115.0
22
+ - @akinon/pz-basket-gift-pack@1.115.0
23
+ - @akinon/pz-bkm@1.115.0
24
+ - @akinon/pz-checkout-gift-pack@1.115.0
25
+ - @akinon/pz-click-collect@1.115.0
26
+ - @akinon/pz-credit-payment@1.115.0
27
+ - @akinon/pz-cybersource-uc@1.115.0
28
+ - @akinon/pz-flow-payment@1.115.0
29
+ - @akinon/pz-gpay@1.115.0
30
+ - @akinon/pz-hepsipay@1.115.0
31
+ - @akinon/pz-masterpass@1.115.0
32
+ - @akinon/pz-masterpass-rest@1.115.0
33
+ - @akinon/pz-multi-basket@1.115.0
34
+ - @akinon/pz-one-click-checkout@1.115.0
35
+ - @akinon/pz-otp@1.115.0
36
+ - @akinon/pz-pay-on-delivery@1.115.0
37
+ - @akinon/pz-saved-card@1.115.0
38
+ - @akinon/pz-tabby-extension@1.115.0
39
+ - @akinon/pz-tamara-extension@1.115.0
40
+
3
41
  ## 1.114.0
4
42
 
5
43
  ### Patch Changes
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "projectzeronext",
3
- "version": "1.114.0",
3
+ "version": "1.115.0",
4
4
  "private": true,
5
5
  "license": "MIT",
6
6
  "scripts": {
@@ -24,29 +24,29 @@
24
24
  "test:middleware": "jest middleware-matcher.test.ts --bail"
25
25
  },
26
26
  "dependencies": {
27
- "@akinon/next": "1.114.0",
28
- "@akinon/pz-akifast": "1.114.0",
29
- "@akinon/pz-apple-pay": "1.114.0",
30
- "@akinon/pz-b2b": "1.114.0",
31
- "@akinon/pz-basket-gift-pack": "1.114.0",
32
- "@akinon/pz-bkm": "1.114.0",
33
- "@akinon/pz-checkout-gift-pack": "1.114.0",
34
- "@akinon/pz-click-collect": "1.114.0",
35
- "@akinon/pz-credit-payment": "1.114.0",
36
- "@akinon/pz-cybersource-uc": "1.114.0",
37
- "@akinon/pz-flow-payment": "1.114.0",
38
- "@akinon/pz-gpay": "1.114.0",
39
- "@akinon/pz-hepsipay": "1.114.0",
40
- "@akinon/pz-masterpass": "1.114.0",
41
- "@akinon/pz-masterpass-rest": "1.114.0",
42
- "@akinon/pz-multi-basket": "1.114.0",
43
- "@akinon/pz-one-click-checkout": "1.114.0",
44
- "@akinon/pz-otp": "1.114.0",
45
- "@akinon/pz-pay-on-delivery": "1.114.0",
46
- "@akinon/pz-saved-card": "1.114.0",
47
- "@akinon/pz-tabby-extension": "1.114.0",
48
- "@akinon/pz-tamara-extension": "1.114.0",
49
- "@akinon/pz-virtual-try-on": "1.114.0",
27
+ "@akinon/next": "1.115.0",
28
+ "@akinon/pz-akifast": "1.115.0",
29
+ "@akinon/pz-apple-pay": "1.115.0",
30
+ "@akinon/pz-b2b": "1.115.0",
31
+ "@akinon/pz-basket-gift-pack": "1.115.0",
32
+ "@akinon/pz-bkm": "1.115.0",
33
+ "@akinon/pz-checkout-gift-pack": "1.115.0",
34
+ "@akinon/pz-click-collect": "1.115.0",
35
+ "@akinon/pz-credit-payment": "1.115.0",
36
+ "@akinon/pz-cybersource-uc": "1.115.0",
37
+ "@akinon/pz-flow-payment": "1.115.0",
38
+ "@akinon/pz-gpay": "1.115.0",
39
+ "@akinon/pz-hepsipay": "1.115.0",
40
+ "@akinon/pz-masterpass": "1.115.0",
41
+ "@akinon/pz-masterpass-rest": "1.115.0",
42
+ "@akinon/pz-multi-basket": "1.115.0",
43
+ "@akinon/pz-one-click-checkout": "1.115.0",
44
+ "@akinon/pz-otp": "1.115.0",
45
+ "@akinon/pz-pay-on-delivery": "1.115.0",
46
+ "@akinon/pz-saved-card": "1.115.0",
47
+ "@akinon/pz-tabby-extension": "1.115.0",
48
+ "@akinon/pz-tamara-extension": "1.115.0",
49
+ "@akinon/pz-virtual-try-on": "1.115.0",
50
50
  "@hookform/resolvers": "2.9.0",
51
51
  "@next/third-parties": "14.1.0",
52
52
  "@react-google-maps/api": "2.17.1",
@@ -69,7 +69,7 @@
69
69
  "yup": "0.32.11"
70
70
  },
71
71
  "devDependencies": {
72
- "@akinon/eslint-plugin-projectzero": "1.114.0",
72
+ "@akinon/eslint-plugin-projectzero": "1.115.0",
73
73
  "@semantic-release/changelog": "6.0.2",
74
74
  "@semantic-release/exec": "6.0.3",
75
75
  "@semantic-release/git": "10.0.1",
@@ -29,7 +29,25 @@
29
29
  "clean": "clean",
30
30
  "categories": "CATEGORIES",
31
31
  "view_all": "VIEW ALL",
32
- "not_found": "Search Results Not Found"
32
+ "not_found": "Search Results Not Found",
33
+ "image_search": {
34
+ "title": "Search by Image",
35
+ "upload_image": "Upload an image to find similar products",
36
+ "select_image": "Select Image",
37
+ "crop_image": "Crop Image",
38
+ "cancel_crop": "Cancel Crop",
39
+ "apply_crop": "Apply Crop",
40
+ "try_another": "Try Another Image",
41
+ "search_image": "Search Image",
42
+ "similar_products": "Similar Products",
43
+ "loading_cropper": "Loading cropper...",
44
+ "no_products": "No similar products found",
45
+ "best_results": "For best results:",
46
+ "tip_1": "Upload clear images of products",
47
+ "tip_2": "Use images with simple backgrounds",
48
+ "tip_3": "Focus on the main product",
49
+ "tip_4": "Use the crop tool to focus on specific details"
50
+ }
33
51
  },
34
52
  "page_404": {
35
53
  "title": "Page not found.",
@@ -74,6 +92,29 @@
74
92
  "select_file": "Select File",
75
93
  "no_file": "No file selected"
76
94
  },
95
+ "product": {
96
+ "no_products": "No products found",
97
+ "new_image": "New Image",
98
+ "view_similar_styles": "View Similar Styles",
99
+ "clear_all_filters": "Clear All Filters",
100
+ "reset_to_original": "Reset to Original",
101
+ "similar_styles": "Similar Styles",
102
+ "filters": "Filters",
103
+ "active_filters": "Active Filters"
104
+ },
105
+ "similar_products": {
106
+ "errors": {
107
+ "file_size_too_large": "Image size should be less than 5MB",
108
+ "invalid_image_file": "The selected file is not a valid image",
109
+ "invalid_image_format": "Invalid image format detected",
110
+ "search_failed": "Search failed. Please try again later",
111
+ "connection_failed": "Image search failed. Please check your connection and try again",
112
+ "invalid_image_properties": "Invalid image properties detected",
113
+ "file_read_error": "Error reading the file",
114
+ "processing_error": "Error processing image",
115
+ "crop_processing_error": "Error processing cropped image"
116
+ }
117
+ },
77
118
  "forms": {
78
119
  "sending": "Sending...",
79
120
  "success": "Form submitted successfully!",
@@ -77,10 +77,10 @@
77
77
  "photo_preview": "Photo Preview",
78
78
  "error_title": "An Error Occurred",
79
79
  "legal": {
80
- "title": "Terms & Conditions",
81
- "text": "By using this virtual try-on feature, you agree to our terms and conditions. Your image will be processed securely and not stored permanently. We use your photo only to generate the virtual try-on result.",
80
+ "title": "Consent Statement",
81
+ "text": "I hereby declare that I give my <strong>explicit consent</strong> for the image I will upload to be used for <strong>AI-powered processing, enhancement, analysis, and content creation</strong> purposes.",
82
82
  "accept": "Accept",
83
- "error": "Please accept the terms and conditions."
83
+ "error": "Please accept the consent statement."
84
84
  },
85
85
  "multiple_results_title": "Virtual Try-On Results",
86
86
  "multiple_results_subtitle": "Try-on completed for {{count}} products",
@@ -29,7 +29,25 @@
29
29
  "clean": "temizle",
30
30
  "categories": "KATEGORİLER",
31
31
  "view_all": "HEPSİNİ GÖSTER",
32
- "not_found": "Arama Sonuçları Bulunamadı"
32
+ "not_found": "Arama Sonuçları Bulunamadı",
33
+ "image_search": {
34
+ "title": "Görsel ile Ara",
35
+ "upload_image": "Benzer ürünleri bulmak için bir görsel yükleyin",
36
+ "select_image": "Görsel Seç",
37
+ "crop_image": "Görsel Kırp",
38
+ "cancel_crop": "Kırpmayı İptal Et",
39
+ "apply_crop": "Kırpmayı Uygula",
40
+ "try_another": "Başka Görsel Dene",
41
+ "search_image": "Arama Görseli",
42
+ "similar_products": "Benzer Ürünler",
43
+ "loading_cropper": "Kırpıcı yükleniyor...",
44
+ "no_products": "Benzer ürün bulunamadı",
45
+ "best_results": "En iyi sonuçlar için:",
46
+ "tip_1": "Net ürün görselleri yükleyin",
47
+ "tip_2": "Basit arka planlı görseller kullanın",
48
+ "tip_3": "Ana ürüne odaklanın",
49
+ "tip_4": "Belirli detaylara odaklanmak için kırpma aracını kullanın"
50
+ }
33
51
  },
34
52
  "page_404": {
35
53
  "title": "Sayfa bulunamadı.",
@@ -74,6 +92,29 @@
74
92
  "select_file": "Dosya Seç",
75
93
  "no_file": "Dosya seçilmedi"
76
94
  },
95
+ "product": {
96
+ "no_products": "Ürün bulunamadı",
97
+ "new_image": "Yeni Görsel",
98
+ "view_similar_styles": "Benzer Stillere Göz At",
99
+ "clear_all_filters": "Tüm Filtreleri Temizle",
100
+ "reset_to_original": "Orjinale Dön",
101
+ "similar_styles": "Benzer Stillere Göz At",
102
+ "filters": "Filtreler",
103
+ "active_filters": "Aktif Filtreler"
104
+ },
105
+ "similar_products": {
106
+ "errors": {
107
+ "file_size_too_large": "Görsel boyutu 5MB'dan küçük olmalıdır",
108
+ "invalid_image_file": "Seçilen dosya geçerli bir görsel değil",
109
+ "invalid_image_format": "Geçersiz görsel formatı tespit edildi",
110
+ "search_failed": "Arama başarısız oldu. Lütfen daha sonra tekrar deneyin",
111
+ "connection_failed": "Görsel arama başarısız oldu. Lütfen bağlantınızı kontrol edip tekrar deneyin",
112
+ "invalid_image_properties": "Geçersiz görsel özellikleri tespit edildi",
113
+ "file_read_error": "Dosya okuma hatası",
114
+ "processing_error": "Görsel işleme hatası",
115
+ "crop_processing_error": "Kırpılan görsel işleme hatası"
116
+ }
117
+ },
77
118
  "forms": {
78
119
  "sending": "Gönderiliyor...",
79
120
  "success": "Form başarıyla gönderildi!",
@@ -80,7 +80,7 @@
80
80
  "cabin": "Sanal Deneme Kabini",
81
81
  "legal": {
82
82
  "title": "Açık Rıza Metni",
83
- "text": "Açık rıza metnini okudum ve onaylıyorum.",
83
+ "text": "Yükleyeceğim görselin, <strong>yapay zekâ destekli işleme, iyileştirme, analiz ve içerik oluşturma</strong> amaçlarıyla kullanılmasına <strong>açık rıza verdiğimi</strong> beyan ederim.",
84
84
  "accept": "Onayla",
85
85
  "error": "Lütfen açık rıza metnini onaylayın."
86
86
  },
@@ -0,0 +1 @@
1
+ export * from '@akinon/next/api/image-proxy';
@@ -0,0 +1 @@
1
+ export * from '@akinon/next/api/product-categories';
@@ -0,0 +1 @@
1
+ export * from '@akinon/next/api/similar-product-list';
@@ -0,0 +1 @@
1
+ export * from '@akinon/next/api/similar-products';
@@ -21,5 +21,7 @@ module.exports = [
21
21
  'pz-virtual-try-on',
22
22
  'pz-cybersource-uc',
23
23
  'pz-hepsipay',
24
- 'pz-masterpass-rest'
24
+ 'pz-masterpass-rest',
25
+ 'pz-similar-products',
26
+ 'pz-haso'
25
27
  ];
@@ -27,7 +27,8 @@ enum ACCOUNT_ROUTES {
27
27
 
28
28
  enum ORDER_ROUTES {
29
29
  CHECKOUT = '/orders/checkout',
30
- CHECKOUT_COMPLETED = '/orders/completed'
30
+ CHECKOUT_COMPLETED = '/orders/completed',
31
+ PAYMENT_GATEWAY_HASO = '/payment-gateway/haso'
31
32
  }
32
33
 
33
34
  enum FLATPAGE_ROUTES {
@@ -9,6 +9,7 @@ import { Icon } from '@theme/components';
9
9
  import Results from './results';
10
10
  import { ROUTES } from '@theme/routes';
11
11
  import { useLocalization, useRouter } from '@akinon/next/hooks';
12
+ import PluginModule, { Component } from '@akinon/next/components/plugin-module';
12
13
 
13
14
  export default function Search() {
14
15
  const { t } = useLocalization();
@@ -78,6 +79,15 @@ export default function Search() {
78
79
  placeholder={t('common.search.placeholder')}
79
80
  ref={inputRef}
80
81
  />
82
+
83
+ <PluginModule
84
+ component={Component.HeaderImageSearchFeature}
85
+ props={{
86
+ enableTextSearch: true,
87
+ isEnabled: true
88
+ }}
89
+ />
90
+
81
91
  <Icon
82
92
  name="close"
83
93
  size={14}
@@ -89,6 +89,17 @@ export default function ProductInfoSlider({ product }: ProductSliderItem) {
89
89
  <div className="relative lg:col-span-5">
90
90
  <FavButton className="absolute right-8 top-6 z-[20] sm:hidden" />
91
91
 
92
+ <PluginModule
93
+ component={Component.ProductImageSearchFeature}
94
+ props={{
95
+ product,
96
+ activeIndex,
97
+ showResetButton: true,
98
+ enableTextSearch: true,
99
+ isEnabled: true
100
+ }}
101
+ />
102
+
92
103
  <PluginModule
93
104
  component={Component.VirtualTryOnPlugin}
94
105
  props={{
@@ -152,6 +152,14 @@ export default async () => {
152
152
  {
153
153
  name: 'Masterpass Rest',
154
154
  value: 'pz-masterpass-rest'
155
+ },
156
+ {
157
+ name: 'Similar Products',
158
+ value: 'pz-similar-products'
159
+ },
160
+ {
161
+ name: 'Haso Payment Gateway',
162
+ value: 'pz-haso'
155
163
  }
156
164
  ];
157
165
 
@@ -1,196 +1,274 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || function (mod) {
1
+ 'use strict';
2
+ var __createBinding =
3
+ (this && this.__createBinding) ||
4
+ (Object.create
5
+ ? function (o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (
9
+ !desc ||
10
+ ('get' in desc ? !m.__esModule : desc.writable || desc.configurable)
11
+ ) {
12
+ desc = {
13
+ enumerable: true,
14
+ get: function () {
15
+ return m[k];
16
+ }
17
+ };
18
+ }
19
+ Object.defineProperty(o, k2, desc);
20
+ }
21
+ : function (o, m, k, k2) {
22
+ if (k2 === undefined) k2 = k;
23
+ o[k2] = m[k];
24
+ });
25
+ var __setModuleDefault =
26
+ (this && this.__setModuleDefault) ||
27
+ (Object.create
28
+ ? function (o, v) {
29
+ Object.defineProperty(o, 'default', { enumerable: true, value: v });
30
+ }
31
+ : function (o, v) {
32
+ o['default'] = v;
33
+ });
34
+ var __importStar =
35
+ (this && this.__importStar) ||
36
+ function (mod) {
19
37
  if (mod && mod.__esModule) return mod;
20
38
  var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
39
+ if (mod != null)
40
+ for (var k in mod)
41
+ if (k !== 'default' && Object.prototype.hasOwnProperty.call(mod, k))
42
+ __createBinding(result, mod, k);
22
43
  __setModuleDefault(result, mod);
23
44
  return result;
24
- };
25
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
26
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
45
+ };
46
+ var __awaiter =
47
+ (this && this.__awaiter) ||
48
+ function (thisArg, _arguments, P, generator) {
49
+ function adopt(value) {
50
+ return value instanceof P
51
+ ? value
52
+ : new P(function (resolve) {
53
+ resolve(value);
54
+ });
55
+ }
27
56
  return new (P || (P = Promise))(function (resolve, reject) {
28
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
29
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
30
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
31
- step((generator = generator.apply(thisArg, _arguments || [])).next());
32
- });
33
- };
34
- var __importDefault = (this && this.__importDefault) || function (mod) {
35
- return (mod && mod.__esModule) ? mod : { "default": mod };
36
- };
37
- Object.defineProperty(exports, "__esModule", { value: true });
38
- const fs = __importStar(require("fs"));
39
- const path_1 = __importDefault(require("path"));
40
- const child_process_1 = require("child_process");
41
- const semver_1 = __importDefault(require("semver"));
42
- const prompts_1 = require("@inquirer/prompts");
43
- const rootDir = path_1.default.resolve(process.cwd());
44
- function checkVersion(pkg) {
45
- return __awaiter(this, void 0, void 0, function* () {
46
- const packageName = '@akinon/next';
47
- const registryUrl = `https://registry.npmjs.org/${packageName}`;
57
+ function fulfilled(value) {
48
58
  try {
49
- const response = yield fetch(registryUrl);
50
- const pkgInfo = (yield response.json());
51
- const latestVersion = pkgInfo['dist-tags'].latest;
52
- if (!semver_1.default.satisfies(pkg.dependencies['@akinon/next'], latestVersion)) {
53
- console.warn(`\x1b[43mWarning: The "${packageName}" package is currently at version ${pkg.dependencies['@akinon/next']}. Please upgrade it to the latest version (${latestVersion}) to ensure plugin compatibility.`, '\x1b[0m\n');
54
- }
59
+ step(generator.next(value));
60
+ } catch (e) {
61
+ reject(e);
55
62
  }
56
- catch (error) {
57
- console.error(`\x1b[41mError: ${error === null || error === void 0 ? void 0 : error.message}`, '\x1b[0m\n');
63
+ }
64
+ function rejected(value) {
65
+ try {
66
+ step(generator['throw'](value));
67
+ } catch (e) {
68
+ reject(e);
58
69
  }
70
+ }
71
+ function step(result) {
72
+ result.done
73
+ ? resolve(result.value)
74
+ : adopt(result.value).then(fulfilled, rejected);
75
+ }
76
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
59
77
  });
78
+ };
79
+ var __importDefault =
80
+ (this && this.__importDefault) ||
81
+ function (mod) {
82
+ return mod && mod.__esModule ? mod : { default: mod };
83
+ };
84
+ Object.defineProperty(exports, '__esModule', { value: true });
85
+ const fs = __importStar(require('fs'));
86
+ const path_1 = __importDefault(require('path'));
87
+ const child_process_1 = require('child_process');
88
+ const semver_1 = __importDefault(require('semver'));
89
+ const prompts_1 = require('@inquirer/prompts');
90
+ const rootDir = path_1.default.resolve(process.cwd());
91
+ function checkVersion(pkg) {
92
+ return __awaiter(this, void 0, void 0, function* () {
93
+ const packageName = '@akinon/next';
94
+ const registryUrl = `https://registry.npmjs.org/${packageName}`;
95
+ try {
96
+ const response = yield fetch(registryUrl);
97
+ const pkgInfo = yield response.json();
98
+ const latestVersion = pkgInfo['dist-tags'].latest;
99
+ if (
100
+ !semver_1.default.satisfies(
101
+ pkg.dependencies['@akinon/next'],
102
+ latestVersion
103
+ )
104
+ ) {
105
+ console.warn(
106
+ `\x1b[43mWarning: The "${packageName}" package is currently at version ${pkg.dependencies['@akinon/next']}. Please upgrade it to the latest version (${latestVersion}) to ensure plugin compatibility.`,
107
+ '\x1b[0m\n'
108
+ );
109
+ }
110
+ } catch (error) {
111
+ console.error(
112
+ `\x1b[41mError: ${
113
+ error === null || error === void 0 ? void 0 : error.message
114
+ }`,
115
+ '\x1b[0m\n'
116
+ );
117
+ }
118
+ });
60
119
  }
61
- exports.default = () => __awaiter(void 0, void 0, void 0, function* () {
120
+ exports.default = () =>
121
+ __awaiter(void 0, void 0, void 0, function* () {
62
122
  function findPluginsFilePath() {
63
- const option1 = path_1.default.resolve(rootDir, './src/plugins.js');
64
- const option2 = path_1.default.resolve(rootDir, './packages/akinon-next/plugins.js');
65
- if (fs.existsSync(option1)) {
66
- return option1;
67
- }
68
- else if (fs.existsSync(option2)) {
69
- return option2;
70
- }
71
- else {
72
- throw new Error('plugins.js was not found in either of the expected locations.');
73
- }
123
+ const option1 = path_1.default.resolve(rootDir, './src/plugins.js');
124
+ const option2 = path_1.default.resolve(
125
+ rootDir,
126
+ './packages/akinon-next/plugins.js'
127
+ );
128
+ if (fs.existsSync(option1)) {
129
+ return option1;
130
+ } else if (fs.existsSync(option2)) {
131
+ return option2;
132
+ } else {
133
+ throw new Error(
134
+ 'plugins.js was not found in either of the expected locations.'
135
+ );
136
+ }
74
137
  }
75
138
  const pkg = require(path_1.default.resolve(rootDir, './package.json'));
76
139
  yield checkVersion(pkg);
77
140
  const pluginsFilePath = findPluginsFilePath();
78
141
  let installedPlugins = [];
79
142
  try {
80
- installedPlugins = require(pluginsFilePath);
81
- }
82
- catch (error) {
83
- console.error('Error loading installed plugins:', error);
84
- process.exit(1);
143
+ installedPlugins = require(pluginsFilePath);
144
+ } catch (error) {
145
+ console.error('Error loading installed plugins:', error);
146
+ process.exit(1);
85
147
  }
86
148
  const definedPlugins = [
87
- {
88
- name: 'Akifast',
89
- value: 'pz-akifast'
90
- },
91
- {
92
- name: 'Apple Pay',
93
- value: 'pz-apple-pay'
94
- },
95
- {
96
- name: 'B2B',
97
- value: 'pz-b2b'
98
- },
99
- {
100
- name: 'Basket Gift Pack',
101
- value: 'pz-basket-gift-pack'
102
- },
103
- {
104
- name: 'BKM Express',
105
- value: 'pz-bkm'
106
- },
107
- {
108
- name: 'Checkout Gift Pack',
109
- value: 'pz-checkout-gift-pack'
110
- },
111
- {
112
- name: 'Click & Collect',
113
- value: 'pz-click-collect'
114
- },
115
- {
116
- name: 'Credit Payment',
117
- value: 'pz-credit-payment'
118
- },
119
- {
120
- name: 'Garanti Pay',
121
- value: 'pz-gpay'
122
- },
123
- {
124
- name: 'Masterpass',
125
- value: 'pz-masterpass'
126
- },
127
- {
128
- name: 'Multi Basket',
129
- value: 'pz-multi-basket'
130
- },
131
- {
132
- name: 'One Click Checkout',
133
- value: 'pz-one-click-checkout'
134
- },
135
- {
136
- name: 'Otp',
137
- value: 'pz-otp'
138
- },
139
- {
140
- name: 'Pay On Delivery',
141
- value: 'pz-pay-on-delivery'
142
- },
143
- {
144
- name: 'Saved Card',
145
- value: 'pz-saved-card'
146
- },
147
- {
148
- name: 'Tabby Payment Extension',
149
- value: 'pz-tabby-extension'
150
- },
151
- {
152
- name: 'Tamara Payment Extension',
153
- value: 'pz-tamara-extension'
154
- },
155
- {
156
- name: 'Hepsipay',
157
- value: 'pz-hepsipay'
158
- },
159
- {
160
- name: 'Flow Payment',
161
- value: 'pz-flow-payment'
162
- },
163
- {
164
- name: 'Virtual Try-On',
165
- value: 'pz-virtual-try-on'
166
- },
167
- {
168
- name: 'Masterpass Rest',
169
- value: 'pz-masterpass-rest'
170
- }
149
+ {
150
+ name: 'Akifast',
151
+ value: 'pz-akifast'
152
+ },
153
+ {
154
+ name: 'Apple Pay',
155
+ value: 'pz-apple-pay'
156
+ },
157
+ {
158
+ name: 'B2B',
159
+ value: 'pz-b2b'
160
+ },
161
+ {
162
+ name: 'Basket Gift Pack',
163
+ value: 'pz-basket-gift-pack'
164
+ },
165
+ {
166
+ name: 'BKM Express',
167
+ value: 'pz-bkm'
168
+ },
169
+ {
170
+ name: 'Checkout Gift Pack',
171
+ value: 'pz-checkout-gift-pack'
172
+ },
173
+ {
174
+ name: 'Click & Collect',
175
+ value: 'pz-click-collect'
176
+ },
177
+ {
178
+ name: 'Credit Payment',
179
+ value: 'pz-credit-payment'
180
+ },
181
+ {
182
+ name: 'Garanti Pay',
183
+ value: 'pz-gpay'
184
+ },
185
+ {
186
+ name: 'Masterpass',
187
+ value: 'pz-masterpass'
188
+ },
189
+ {
190
+ name: 'Multi Basket',
191
+ value: 'pz-multi-basket'
192
+ },
193
+ {
194
+ name: 'One Click Checkout',
195
+ value: 'pz-one-click-checkout'
196
+ },
197
+ {
198
+ name: 'Otp',
199
+ value: 'pz-otp'
200
+ },
201
+ {
202
+ name: 'Pay On Delivery',
203
+ value: 'pz-pay-on-delivery'
204
+ },
205
+ {
206
+ name: 'Saved Card',
207
+ value: 'pz-saved-card'
208
+ },
209
+ {
210
+ name: 'Tabby Payment Extension',
211
+ value: 'pz-tabby-extension'
212
+ },
213
+ {
214
+ name: 'Tamara Payment Extension',
215
+ value: 'pz-tamara-extension'
216
+ },
217
+ {
218
+ name: 'Hepsipay',
219
+ value: 'pz-hepsipay'
220
+ },
221
+ {
222
+ name: 'Flow Payment',
223
+ value: 'pz-flow-payment'
224
+ },
225
+ {
226
+ name: 'Virtual Try-On',
227
+ value: 'pz-virtual-try-on'
228
+ },
229
+ {
230
+ name: 'Masterpass Rest',
231
+ value: 'pz-masterpass-rest'
232
+ },
233
+ {
234
+ name: 'Similar Products',
235
+ value: 'pz-similar-products'
236
+ },
237
+ {
238
+ name: 'Haso Payment Gateway',
239
+ value: 'pz-haso'
240
+ }
171
241
  ];
172
242
  try {
173
- const answers = yield (0, prompts_1.checkbox)({
174
- message: 'Please check/uncheck plugins to install/uninstall.',
175
- choices: definedPlugins.map((plugin) => ({
176
- name: plugin.name,
177
- value: plugin.value,
178
- checked: installedPlugins.includes(plugin.value)
179
- }))
180
- });
181
- if (!answers.length) {
182
- console.log('\x1b[33m%s\x1b[0m', `\nUninstalling all plugins.`);
243
+ const answers = yield (0, prompts_1.checkbox)({
244
+ message: 'Please check/uncheck plugins to install/uninstall.',
245
+ choices: definedPlugins.map((plugin) => ({
246
+ name: plugin.name,
247
+ value: plugin.value,
248
+ checked: installedPlugins.includes(plugin.value)
249
+ }))
250
+ });
251
+ if (!answers.length) {
252
+ console.log('\x1b[33m%s\x1b[0m', `\nUninstalling all plugins.`);
253
+ }
254
+ console.log('\x1b[36m%s\x1b[0m', `\nPlease wait...`);
255
+ fs.writeFileSync(
256
+ pluginsFilePath,
257
+ `module.exports = ${JSON.stringify(answers)};\n`,
258
+ {
259
+ encoding: 'utf-8'
183
260
  }
184
- console.log('\x1b[36m%s\x1b[0m', `\nPlease wait...`);
185
- fs.writeFileSync(pluginsFilePath, `module.exports = ${JSON.stringify(answers)};\n`, {
186
- encoding: 'utf-8'
187
- });
188
- (0, child_process_1.execSync)('yarn install', { stdio: 'pipe' });
189
- console.log('\x1b[32m%s\x1b[0m', `\n✓ ${answers.length
261
+ );
262
+ (0, child_process_1.execSync)('yarn install', { stdio: 'pipe' });
263
+ console.log(
264
+ '\x1b[32m%s\x1b[0m',
265
+ `\n✓ ${
266
+ answers.length
190
267
  ? 'Installed selected plugins'
191
- : 'Uninstalled all plugins'}.\n`);
192
- }
193
- catch (error) {
194
- process.exit(1);
268
+ : 'Uninstalled all plugins'
269
+ }.\n`
270
+ );
271
+ } catch (error) {
272
+ process.exit(1);
195
273
  }
196
- });
274
+ });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@akinon/projectzero",
3
- "version": "1.115.0-snapshot-ZERO-3855-20251209090338",
3
+ "version": "1.115.0",
4
4
  "private": false,
5
5
  "description": "CLI tool to manage your Project Zero Next project",
6
6
  "bin": {