@getlupa/client 1.6.1 → 1.6.2

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.
@@ -6389,12 +6389,12 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
6389
6389
  });
6390
6390
  return output;
6391
6391
  };
6392
- const inputMatches = (input, possibleValues) => {
6392
+ const inputsAreEqual = (input, possibleValues) => {
6393
6393
  if (!input) {
6394
6394
  return false;
6395
6395
  }
6396
6396
  const normalizedInput = getNormalizedString(input);
6397
- return possibleValues.some((v) => getNormalizedString(v).startsWith(normalizedInput));
6397
+ return possibleValues.some((v) => getNormalizedString(v) === normalizedInput);
6398
6398
  };
6399
6399
  const initAnalyticsTracking = (analyticsOptions) => {
6400
6400
  try {
@@ -7401,7 +7401,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
7401
7401
  if (!((_b = (_a = redirections.value) == null ? void 0 : _a.rules) == null ? void 0 : _b.length)) {
7402
7402
  return false;
7403
7403
  }
7404
- const redirectTo = redirections.value.rules.find((r) => inputMatches(input, r.sources));
7404
+ const redirectTo = redirections.value.rules.find((r) => inputsAreEqual(input, r.sources));
7405
7405
  if (!redirectTo) {
7406
7406
  return false;
7407
7407
  }
@@ -6389,12 +6389,12 @@ const escapeHtml = (value) => {
6389
6389
  });
6390
6390
  return output;
6391
6391
  };
6392
- const inputMatches = (input, possibleValues) => {
6392
+ const inputsAreEqual = (input, possibleValues) => {
6393
6393
  if (!input) {
6394
6394
  return false;
6395
6395
  }
6396
6396
  const normalizedInput = getNormalizedString(input);
6397
- return possibleValues.some((v) => getNormalizedString(v).startsWith(normalizedInput));
6397
+ return possibleValues.some((v) => getNormalizedString(v) === normalizedInput);
6398
6398
  };
6399
6399
  const initAnalyticsTracking = (analyticsOptions) => {
6400
6400
  try {
@@ -7401,7 +7401,7 @@ const useRedirectionStore = defineStore("redirections", () => {
7401
7401
  if (!((_b = (_a = redirections.value) == null ? void 0 : _a.rules) == null ? void 0 : _b.length)) {
7402
7402
  return false;
7403
7403
  }
7404
- const redirectTo = redirections.value.rules.find((r) => inputMatches(input, r.sources));
7404
+ const redirectTo = redirections.value.rules.find((r) => inputsAreEqual(input, r.sources));
7405
7405
  if (!redirectTo) {
7406
7406
  return false;
7407
7407
  }
@@ -6387,12 +6387,12 @@ const escapeHtml = (value) => {
6387
6387
  });
6388
6388
  return output;
6389
6389
  };
6390
- const inputMatches = (input, possibleValues) => {
6390
+ const inputsAreEqual = (input, possibleValues) => {
6391
6391
  if (!input) {
6392
6392
  return false;
6393
6393
  }
6394
6394
  const normalizedInput = getNormalizedString(input);
6395
- return possibleValues.some((v) => getNormalizedString(v).startsWith(normalizedInput));
6395
+ return possibleValues.some((v) => getNormalizedString(v) === normalizedInput);
6396
6396
  };
6397
6397
  const initAnalyticsTracking = (analyticsOptions) => {
6398
6398
  try {
@@ -7399,7 +7399,7 @@ const useRedirectionStore = defineStore("redirections", () => {
7399
7399
  if (!((_b = (_a = redirections.value) == null ? void 0 : _a.rules) == null ? void 0 : _b.length)) {
7400
7400
  return false;
7401
7401
  }
7402
- const redirectTo = redirections.value.rules.find((r) => inputMatches(input, r.sources));
7402
+ const redirectTo = redirections.value.rules.find((r) => inputsAreEqual(input, r.sources));
7403
7403
  if (!redirectTo) {
7404
7404
  return false;
7405
7405
  }
@@ -6391,12 +6391,12 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
6391
6391
  });
6392
6392
  return output;
6393
6393
  };
6394
- const inputMatches = (input, possibleValues) => {
6394
+ const inputsAreEqual = (input, possibleValues) => {
6395
6395
  if (!input) {
6396
6396
  return false;
6397
6397
  }
6398
6398
  const normalizedInput = getNormalizedString(input);
6399
- return possibleValues.some((v) => getNormalizedString(v).startsWith(normalizedInput));
6399
+ return possibleValues.some((v) => getNormalizedString(v) === normalizedInput);
6400
6400
  };
6401
6401
  const initAnalyticsTracking = (analyticsOptions) => {
6402
6402
  try {
@@ -7403,7 +7403,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
7403
7403
  if (!((_b = (_a = redirections.value) == null ? void 0 : _a.rules) == null ? void 0 : _b.length)) {
7404
7404
  return false;
7405
7405
  }
7406
- const redirectTo = redirections.value.rules.find((r) => inputMatches(input, r.sources));
7406
+ const redirectTo = redirections.value.rules.find((r) => inputsAreEqual(input, r.sources));
7407
7407
  if (!redirectTo) {
7408
7408
  return false;
7409
7409
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@getlupa/client",
3
- "version": "1.6.1",
3
+ "version": "1.6.2",
4
4
  "main": "dist/lupaSearch.js",
5
5
  "module": "dist/index.mjs",
6
6
  "types": "dist/src/index.d.ts",
@@ -20,7 +20,7 @@
20
20
  },
21
21
  "devDependencies": {
22
22
  "@getlupa/client-sdk": "^1.3.4",
23
- "@getlupa/vue": "0.7.1",
23
+ "@getlupa/vue": "0.7.2",
24
24
  "@rushstack/eslint-patch": "^1.3.2",
25
25
  "@tsconfig/node18": "^2.0.1",
26
26
  "@types/jsdom": "^21.1.1",