hunk.code_window:   channels?: StepTypeEnum[];
     _digestedNotificationId?: string;
     to?: string;
  
hunk.labels: keep keep keep keep keep replace keep
hunk.after_edit:   // eslint-disable-next-line @typescript-eslint/no-explicit-any
     to?: any;
  
hunk.file_path: libs/dal/src/repositories/notification/notification.entity.ts
hunk.type: replace
file: import { INotificationTrigger, TriggerTypeEnum } from '@novu/shared';
  import styled from 'styled-components';
  
  import { colors, Tabs, Text } from '../../design-system';
  import { TriggerSnippetTabs } from '../../components/templates/TriggerSnippetTabs';
  
  const TriggerTitle = styled(Text)`
    font-size: 14px;
    font-weight: 700;
    line-height: 17px;
    padding-bottom: 20px;
  `;
  
  const buildTrigger = (identifier, subscriberVariables, payload): INotificationTrigger => {
    subscriberVariables = JSON.parse(subscriberVariables || '{}');
  
    return {
      type: TriggerTypeEnum.EVENT,
      identifier,
      variables: payload ? Object.entries(payload).map(([name, value]) => ({ name, value })) : [],
      subscriberVariables: Object.keys(subscriberVariables).map((key) => {
        return {
          name: key,
          value: subscriberVariables[key],
        };
      }),
    };
  };
  
  export const ExecutionDetailTrigger = ({ step, subscriberVariables }) => {
    const { identifier, payload } = step || {};
    const trigger = buildTrigger(identifier, subscriberVariables, payload);
  
    return (
      <>
        <TriggerTitle>Trigger information</TriggerTitle>
        <TriggerSnippetTabs trigger={trigger} />
      </>
    );
  };
  