@embedreach/components 0.2.72 → 0.2.73

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.
@@ -22169,7 +22169,7 @@ function scaleChannelMetrics(channelMetrics, options) {
22169
22169
  });
22170
22170
  }
22171
22171
  }
22172
- function generateTimeseriesForChannel(channel, totalSpend, totalRevenue, totalClicks, totalImpressions, targetChannelRoas, queryStartDate, queryEndDate, requestedDaysTotal, numDataPoints) {
22172
+ function generateTimeseriesForChannel(totalSpend, totalRevenue, totalClicks, totalImpressions, targetChannelRoas, queryStartDate, queryEndDate, requestedDaysTotal, numDataPoints) {
22173
22173
  const series = [];
22174
22174
  let currentDate = new Date(queryStartDate);
22175
22175
  let cumulativeSpend = 0;
@@ -22255,7 +22255,6 @@ function calculateAggregatedTimeseries(options) {
22255
22255
  )
22256
22256
  );
22257
22257
  const googleTimeseries = generateTimeseriesForChannel(
22258
- "google",
22259
22258
  totalScaledGoogleSpend,
22260
22259
  totalScaledGoogleRevenue,
22261
22260
  totalScaledGoogleClicks,
@@ -22267,7 +22266,6 @@ function calculateAggregatedTimeseries(options) {
22267
22266
  numDataPoints
22268
22267
  );
22269
22268
  const metaTimeseries = generateTimeseriesForChannel(
22270
- "meta",
22271
22269
  totalScaledMetaSpend,
22272
22270
  totalScaledMetaRevenue,
22273
22271
  totalScaledMetaClicks,
@@ -22381,7 +22379,7 @@ function generateAndDistributeOrders({
22381
22379
  return allGeneratedOrders;
22382
22380
  }
22383
22381
  function filterOrdersByChannel(orders, channel) {
22384
- if (channel === "all") {
22382
+ if (!channel || channel === "all") {
22385
22383
  return orders;
22386
22384
  }
22387
22385
  return orders.filter((order) => {
@@ -22652,7 +22650,7 @@ const handlers = [
22652
22650
  const url = new URL(req.request.url);
22653
22651
  const startDateString = url.searchParams.get("startDate");
22654
22652
  const endDateString = url.searchParams.get("endDate");
22655
- const channel = url.searchParams.get("channel") || "all";
22653
+ const channel = url.searchParams.get("channel");
22656
22654
  const limit = parseInt(url.searchParams.get("limit") || "25", 10);
22657
22655
  const cursorParam = url.searchParams.get("cursor");
22658
22656
  const orderByParam = url.searchParams.get("orderBy");
package/dist/index.d.ts CHANGED
@@ -175,7 +175,7 @@ export declare enum ReachMergeFieldTypeEnum {
175
175
  DYNAMIC = "dynamic"
176
176
  }
177
177
 
178
- export declare const ReachProvider: ({ authToken, language, children, theme, debug, callbacks, sandbox, clientEntryPoint, }: ReachConfig & _PrivateProps) => JSX_2.Element;
178
+ export declare const ReachProvider: ({ authToken, language, children, theme, debug, callbacks, feature, sandbox, clientEntryPoint, }: ReachConfig & _PrivateProps) => JSX_2.Element;
179
179
 
180
180
  /**
181
181
  * Callback function for requesting new token from parent
package/dist/index.es.js CHANGED
@@ -1,11 +1,13 @@
1
- import { Y, _, a0, a1, Z, a2, a3 } from "./chunks/index.js";
1
+ import { A, C, b, E, a, S, V } from "./chunks/index.js";
2
+ import "@tanstack/react-query";
2
3
  import "react";
4
+ import "posthog-js";
3
5
  export {
4
- Y as AutomationTriggerType,
5
- _ as CreateAutomationDialog,
6
- a0 as CreateAutomationModal,
7
- a1 as Engage,
8
- Z as ReachProvider,
9
- a2 as SegmentBuilderDialog,
10
- a3 as ViewAutomationModal
6
+ A as AutomationTriggerType,
7
+ C as CreateAutomationDialog,
8
+ b as CreateAutomationModal,
9
+ E as Engage,
10
+ a as ReachProvider,
11
+ S as SegmentBuilderDialog,
12
+ V as ViewAutomationModal
11
13
  };