@timardex/cluemart-shared 1.3.14 → 1.3.16

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.
package/dist/index.cjs CHANGED
@@ -204,7 +204,7 @@ __export(index_exports, {
204
204
  useMarkAllNotificationsRead: () => useMarkAllNotificationsRead,
205
205
  useMarkNotificationRead: () => useMarkNotificationRead,
206
206
  usePartnerForm: () => usePartnerForm,
207
- usePostform: () => usePostform,
207
+ usePostForm: () => usePostForm,
208
208
  useRefreshToken: () => useRefreshToken,
209
209
  useRegister: () => useRegister,
210
210
  useRegisterForm: () => useRegisterForm,
@@ -5325,7 +5325,9 @@ var POST_CONTENT_DATA_FIELDS_FRAGMENT = import_client59.gql`
5325
5325
  }
5326
5326
  list {
5327
5327
  title
5328
- items
5328
+ items {
5329
+ text
5330
+ }
5329
5331
  }
5330
5332
  }
5331
5333
  ${RESOURCE_IMAGE_FIELDS_FRAGMENT}
@@ -6148,7 +6150,11 @@ var videoContentSchema = yup9.object({
6148
6150
  });
6149
6151
  var listContentSchema = yup9.object({
6150
6152
  list: yup9.object({
6151
- items: yup9.array().of(yup9.string().required()).min(1, "List must contain at least one item").required(),
6153
+ items: yup9.array().of(
6154
+ yup9.object({
6155
+ text: yup9.string().required("List item text is required")
6156
+ })
6157
+ ).min(1, "List must contain at least one item").required(),
6152
6158
  title: yup9.string().optional()
6153
6159
  }).required()
6154
6160
  });
@@ -6183,9 +6189,10 @@ var postContentSchema = yup9.object().shape({
6183
6189
  contentType: yup9.mixed().oneOf(Object.values(EnumPostContentType)).required()
6184
6190
  });
6185
6191
  var postSchema = yup9.object().shape({
6192
+ active: yup9.boolean().required(),
6186
6193
  content: yup9.array().of(postContentSchema).required(),
6187
6194
  postType: yup9.mixed().oneOf(Object.values(EnumPostType)).required(),
6188
- tags: yup9.array().of(yup9.string()).nullable().optional(),
6195
+ tags: yup9.array().of(yup9.string().required()).nullable().optional(),
6189
6196
  title: yup9.string().required()
6190
6197
  });
6191
6198
 
@@ -7244,12 +7251,13 @@ var import_yup15 = require("@hookform/resolvers/yup");
7244
7251
  var import_react4 = __toESM(require("react"));
7245
7252
  var import_react_hook_form15 = require("react-hook-form");
7246
7253
  var defaultValues10 = {
7254
+ active: true,
7247
7255
  content: [],
7248
7256
  postType: "daily_meets" /* DAILY_MEETS */,
7249
7257
  tags: [],
7250
7258
  title: ""
7251
7259
  };
7252
- function usePostform(data) {
7260
+ function usePostForm(data) {
7253
7261
  const {
7254
7262
  control,
7255
7263
  formState: { errors },
@@ -7265,6 +7273,7 @@ function usePostform(data) {
7265
7273
  import_react4.default.useEffect(() => {
7266
7274
  if (data) {
7267
7275
  reset({
7276
+ active: data.active,
7268
7277
  content: data.content,
7269
7278
  postType: data.postType,
7270
7279
  tags: data.tags,
@@ -7274,10 +7283,11 @@ function usePostform(data) {
7274
7283
  reset(defaultValues10);
7275
7284
  }
7276
7285
  }, [data]);
7277
- const { content, postType, tags, title } = getValues();
7286
+ const { active, content, postType, tags, title } = getValues();
7278
7287
  return {
7279
7288
  control,
7280
7289
  fields: {
7290
+ active,
7281
7291
  content,
7282
7292
  postType,
7283
7293
  tags,
@@ -7521,7 +7531,7 @@ var EnumActivity = /* @__PURE__ */ ((EnumActivity2) => {
7521
7531
  useMarkAllNotificationsRead,
7522
7532
  useMarkNotificationRead,
7523
7533
  usePartnerForm,
7524
- usePostform,
7534
+ usePostForm,
7525
7535
  useRefreshToken,
7526
7536
  useRegister,
7527
7537
  useRegisterForm,