@webbycrown/webbycommerce 1.1.0 → 1.2.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.
@@ -88,6 +88,19 @@ const en = {
88
88
  "webbycommerce.settings.apiCollections.verifyOtp.usage.verify": "Submit the OTP code received via email or SMS.",
89
89
  "webbycommerce.settings.apiCollections.verifyOtp.usage.token": "Receive a JWT token for authenticated API requests.",
90
90
  "webbycommerce.settings.apiCollections.verifyOtp.usage.store": "Store the JWT token securely and include it in subsequent requests.",
91
+ "webbycommerce.settings.apiCollections.authMethod.title": "Get Authentication Method",
92
+ "webbycommerce.settings.apiCollections.authMethod.summary": "Get the current authentication method (default or otp) configured in the plugin settings. Use this endpoint in your frontend to determine which authentication flow to display.",
93
+ "webbycommerce.settings.apiCollections.authMethod.auth": "Auth: public (no authentication required).",
94
+ "webbycommerce.settings.apiCollections.authMethod.usage.frontend": "Call this endpoint on app initialization to determine which auth UI to show.",
95
+ "webbycommerce.settings.apiCollections.authMethod.usage.conditional": 'If method is "otp", show OTP login/register form. If "default", show email/password form.',
96
+ "webbycommerce.settings.apiCollections.authMethod.usage.dynamic": "Method can change based on plugin settings, so check this endpoint periodically.",
97
+ "webbycommerce.settings.apiCollections.unifiedAuth.title": "Unified Authentication",
98
+ "webbycommerce.settings.apiCollections.unifiedAuth.summary": "Unified authentication endpoint that supports both OTP and default (email/password) methods. Automatically detects which method to use based on request body. Perfect for frontends that want to support both authentication methods simultaneously.",
99
+ "webbycommerce.settings.apiCollections.unifiedAuth.auth": "Auth: public (no authentication required).",
100
+ "webbycommerce.settings.apiCollections.unifiedAuth.usage.unified": "Use this single endpoint for all authentication needs - OTP and default methods.",
101
+ "webbycommerce.settings.apiCollections.unifiedAuth.usage.otp": 'For OTP: First call with step="request" and email/mobile, then call with step="verify" and OTP code.',
102
+ "webbycommerce.settings.apiCollections.unifiedAuth.usage.default": 'For default: Call with step="login" and identifier/password, or step="register" with username/email/password.',
103
+ "webbycommerce.settings.apiCollections.unifiedAuth.usage.auto": 'Method is auto-detected from request body, or specify authMethod="otp" or "default" explicitly.',
91
104
  "webbycommerce.settings.apiCollections.defaultLogin.title": "Default Login (Email/Password)",
92
105
  "webbycommerce.settings.apiCollections.defaultLogin.summary": "Use Strapi's built-in /auth/local endpoint for email/password login when the authentication method is set to Default.",
93
106
  "webbycommerce.settings.apiCollections.defaultLogin.auth": "Auth: public (uses Strapi's core Users & Permissions authentication).",
@@ -130,6 +143,8 @@ const en = {
130
143
  "webbycommerce.settings.loginRegister.method.default.description": "Uses Strapi's built-in authentication system with email and password.",
131
144
  "webbycommerce.settings.loginRegister.method.otp": "OTP (Email/Mobile Verification)",
132
145
  "webbycommerce.settings.loginRegister.method.otp.description": "Users can login or register using email or mobile number. An OTP (One-Time Password) will be sent for verification.",
146
+ "webbycommerce.settings.loginRegister.method.both": "Both Methods (Unified)",
147
+ "webbycommerce.settings.loginRegister.method.both.description": "Users can choose between OTP or email/password authentication. Use the unified /auth/unified endpoint to support both methods simultaneously.",
133
148
  "webbycommerce.settings.loginRegister.save": "Save settings",
134
149
  "webbycommerce.settings.loginRegister.save.success": "Settings updated successfully.",
135
150
  "webbycommerce.settings.loginRegister.save.error": "Failed to save settings.",
@@ -86,6 +86,19 @@ const en = {
86
86
  "webbycommerce.settings.apiCollections.verifyOtp.usage.verify": "Submit the OTP code received via email or SMS.",
87
87
  "webbycommerce.settings.apiCollections.verifyOtp.usage.token": "Receive a JWT token for authenticated API requests.",
88
88
  "webbycommerce.settings.apiCollections.verifyOtp.usage.store": "Store the JWT token securely and include it in subsequent requests.",
89
+ "webbycommerce.settings.apiCollections.authMethod.title": "Get Authentication Method",
90
+ "webbycommerce.settings.apiCollections.authMethod.summary": "Get the current authentication method (default or otp) configured in the plugin settings. Use this endpoint in your frontend to determine which authentication flow to display.",
91
+ "webbycommerce.settings.apiCollections.authMethod.auth": "Auth: public (no authentication required).",
92
+ "webbycommerce.settings.apiCollections.authMethod.usage.frontend": "Call this endpoint on app initialization to determine which auth UI to show.",
93
+ "webbycommerce.settings.apiCollections.authMethod.usage.conditional": 'If method is "otp", show OTP login/register form. If "default", show email/password form.',
94
+ "webbycommerce.settings.apiCollections.authMethod.usage.dynamic": "Method can change based on plugin settings, so check this endpoint periodically.",
95
+ "webbycommerce.settings.apiCollections.unifiedAuth.title": "Unified Authentication",
96
+ "webbycommerce.settings.apiCollections.unifiedAuth.summary": "Unified authentication endpoint that supports both OTP and default (email/password) methods. Automatically detects which method to use based on request body. Perfect for frontends that want to support both authentication methods simultaneously.",
97
+ "webbycommerce.settings.apiCollections.unifiedAuth.auth": "Auth: public (no authentication required).",
98
+ "webbycommerce.settings.apiCollections.unifiedAuth.usage.unified": "Use this single endpoint for all authentication needs - OTP and default methods.",
99
+ "webbycommerce.settings.apiCollections.unifiedAuth.usage.otp": 'For OTP: First call with step="request" and email/mobile, then call with step="verify" and OTP code.',
100
+ "webbycommerce.settings.apiCollections.unifiedAuth.usage.default": 'For default: Call with step="login" and identifier/password, or step="register" with username/email/password.',
101
+ "webbycommerce.settings.apiCollections.unifiedAuth.usage.auto": 'Method is auto-detected from request body, or specify authMethod="otp" or "default" explicitly.',
89
102
  "webbycommerce.settings.apiCollections.defaultLogin.title": "Default Login (Email/Password)",
90
103
  "webbycommerce.settings.apiCollections.defaultLogin.summary": "Use Strapi's built-in /auth/local endpoint for email/password login when the authentication method is set to Default.",
91
104
  "webbycommerce.settings.apiCollections.defaultLogin.auth": "Auth: public (uses Strapi's core Users & Permissions authentication).",
@@ -128,6 +141,8 @@ const en = {
128
141
  "webbycommerce.settings.loginRegister.method.default.description": "Uses Strapi's built-in authentication system with email and password.",
129
142
  "webbycommerce.settings.loginRegister.method.otp": "OTP (Email/Mobile Verification)",
130
143
  "webbycommerce.settings.loginRegister.method.otp.description": "Users can login or register using email or mobile number. An OTP (One-Time Password) will be sent for verification.",
144
+ "webbycommerce.settings.loginRegister.method.both": "Both Methods (Unified)",
145
+ "webbycommerce.settings.loginRegister.method.both.description": "Users can choose between OTP or email/password authentication. Use the unified /auth/unified endpoint to support both methods simultaneously.",
131
146
  "webbycommerce.settings.loginRegister.save": "Save settings",
132
147
  "webbycommerce.settings.loginRegister.save.success": "Settings updated successfully.",
133
148
  "webbycommerce.settings.loginRegister.save.error": "Failed to save settings.",
@@ -92,7 +92,7 @@ const index = {
92
92
  defaultMessage: "Configure"
93
93
  },
94
94
  to: `${PLUGIN_ID}`,
95
- Component: () => import("./Settings-BWuSG1Bc.mjs")
95
+ Component: () => import("./Settings-yLx-YvVy.mjs")
96
96
  }
97
97
  );
98
98
  },
@@ -106,14 +106,14 @@ const index = {
106
106
  locales.map(async (locale) => {
107
107
  if (locale === "en") {
108
108
  try {
109
- const { default: data } = await import("./en-7gtFcumM.mjs");
109
+ const { default: data } = await import("./en-DE15m4xZ.mjs");
110
110
  return { data, locale };
111
111
  } catch {
112
112
  return { data: {}, locale };
113
113
  }
114
114
  }
115
115
  try {
116
- const { default: data } = await __variableDynamicImportRuntimeHelper(/* @__PURE__ */ Object.assign({ "./translations/en.json": () => import("./en-7gtFcumM.mjs") }), `./translations/${locale}.json`, 3);
116
+ const { default: data } = await __variableDynamicImportRuntimeHelper(/* @__PURE__ */ Object.assign({ "./translations/en.json": () => import("./en-DE15m4xZ.mjs") }), `./translations/${locale}.json`, 3);
117
117
  return { data, locale };
118
118
  } catch {
119
119
  return { data: {}, locale };
@@ -93,7 +93,7 @@ const index = {
93
93
  defaultMessage: "Configure"
94
94
  },
95
95
  to: `${PLUGIN_ID}`,
96
- Component: () => Promise.resolve().then(() => require("./Settings-C3yoIgMy.js"))
96
+ Component: () => Promise.resolve().then(() => require("./Settings-DZXAkI24.js"))
97
97
  }
98
98
  );
99
99
  },
@@ -107,14 +107,14 @@ const index = {
107
107
  locales.map(async (locale) => {
108
108
  if (locale === "en") {
109
109
  try {
110
- const { default: data } = await Promise.resolve().then(() => require("./en-DIeqB4AB.js"));
110
+ const { default: data } = await Promise.resolve().then(() => require("./en-CiQ97iC8.js"));
111
111
  return { data, locale };
112
112
  } catch {
113
113
  return { data: {}, locale };
114
114
  }
115
115
  }
116
116
  try {
117
- const { default: data } = await __variableDynamicImportRuntimeHelper(/* @__PURE__ */ Object.assign({ "./translations/en.json": () => Promise.resolve().then(() => require("./en-DIeqB4AB.js")) }), `./translations/${locale}.json`, 3);
117
+ const { default: data } = await __variableDynamicImportRuntimeHelper(/* @__PURE__ */ Object.assign({ "./translations/en.json": () => Promise.resolve().then(() => require("./en-CiQ97iC8.js")) }), `./translations/${locale}.json`, 3);
118
118
  return { data, locale };
119
119
  } catch {
120
120
  return { data: {}, locale };
@@ -1,3 +1,3 @@
1
1
  "use strict";
2
- const index = require("../_chunks/index-CtxKh-aM.js");
2
+ const index = require("../_chunks/index-DgocXUgC.js");
3
3
  module.exports = index.index;
@@ -1,4 +1,4 @@
1
- import { i } from "../_chunks/index-DIGoLhGE.mjs";
1
+ import { i } from "../_chunks/index-CXGrFKp6.mjs";
2
2
  export {
3
3
  i as default
4
4
  };