@kl1/contracts 1.2.85-uat → 1.2.86-uat

Sign up to get free protection for your applications and to get access to all the features.
package/dist/index.mjs CHANGED
@@ -6869,21 +6869,48 @@ var FieldsSchema = z85.object({ data: z85.array(z85.string()) });
6869
6869
  var WidgetPositionSchema = z85.union([
6870
6870
  z85.literal("menu"),
6871
6871
  z85.literal("ticket_detail"),
6872
- z85.literal("contact_detail")
6872
+ z85.literal("contact_detail"),
6873
+ z85.literal("contact_profile"),
6874
+ z85.literal("inbox_detail")
6875
+ ]);
6876
+ var WidgetTypeSchema = z85.union([
6877
+ z85.literal("iframe"),
6878
+ z85.literal("custom")
6879
+ ]);
6880
+ var WidgetHeaderSchema = z85.object({
6881
+ key: z85.string(),
6882
+ value: z85.string()
6883
+ });
6884
+ var WidgetMethodSchema = z85.union([
6885
+ z85.literal("get"),
6886
+ z85.literal("post")
6873
6887
  ]);
6874
6888
  var WidgetSchema = DefaultEntitySchema.extend({
6875
6889
  name: z85.string(),
6876
6890
  description: z85.string().nullable(),
6877
- position: WidgetPositionSchema.nullable(),
6891
+ position: WidgetPositionSchema,
6878
6892
  fields: FieldsSchema,
6879
- url: z85.string()
6893
+ url: z85.string(),
6894
+ upload: UploadSchema.nullable(),
6895
+ type: WidgetTypeSchema.nullable(),
6896
+ headers: z85.array(WidgetHeaderSchema).nullable(),
6897
+ method: WidgetMethodSchema.nullable()
6880
6898
  });
6881
6899
 
6882
6900
  // src/widget/validation.ts
6883
6901
  import z86 from "zod";
6902
+ var WidgetUploadAttachmentSchema = z86.object({
6903
+ bucketName: z86.string(),
6904
+ fileKey: z86.string(),
6905
+ fileName: z86.string(),
6906
+ fileSize: z86.number(),
6907
+ url: z86.string().nullable(),
6908
+ fileType: z86.string(),
6909
+ thumbnailUrl: z86.string().optional()
6910
+ });
6884
6911
  var CreateWidgetSchema = z86.object({
6885
6912
  name: z86.string(),
6886
- description: z86.string(),
6913
+ description: z86.string().optional(),
6887
6914
  url: z86.string(),
6888
6915
  position: WidgetPositionSchema,
6889
6916
  fields: z86.object({
@@ -6891,7 +6918,11 @@ var CreateWidgetSchema = z86.object({
6891
6918
  // Array of attribute system names
6892
6919
  z86.array(z86.string())
6893
6920
  )
6894
- }).optional()
6921
+ }).optional(),
6922
+ widgetUploadAttachment: WidgetUploadAttachmentSchema.optional(),
6923
+ type: WidgetTypeSchema,
6924
+ headers: z86.array(WidgetHeaderSchema).optional(),
6925
+ method: WidgetMethodSchema.optional()
6895
6926
  });
6896
6927
  var UpdateWidgetSchema = CreateWidgetSchema;
6897
6928
  var GetWidgetUrlPathQuerySchema = z86.object({