@ssyazilim/ss-shopping-schemas 0.1.21 → 0.1.22
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 +21 -14
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +21 -14
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1224,6 +1224,7 @@ var ADD_REVIEW = () => z14.z.object({
|
|
|
1224
1224
|
|
|
1225
1225
|
// src/schemas/review/schema.ts
|
|
1226
1226
|
var AddReviewSchema = registry.register("addReview", ADD_REVIEW());
|
|
1227
|
+
var messages13 = { tr: notifications, en: notifications2, ru: notifications3, ar: notifications4, fa: notifications5 };
|
|
1227
1228
|
var SHIPPING_ITEM = () => z14.z.object({
|
|
1228
1229
|
title: z14.z.string().meta({ examples: ["Lorem ipsum dolor sit amet"] }),
|
|
1229
1230
|
quantity: z14.z.number().int().meta({ examples: [2] })
|
|
@@ -1235,20 +1236,26 @@ var SHIPPING_ORDER_INFO = () => z14.z.object({
|
|
|
1235
1236
|
totalAmount: z14.z.number().int().optional().meta({ examples: [250] }),
|
|
1236
1237
|
totalAmountCurrency: z14.z.string().optional().meta({ examples: ["TL"] })
|
|
1237
1238
|
});
|
|
1238
|
-
var ADD_SHIPPING_SHIPMENT_ADDRESS = () =>
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
})
|
|
1239
|
+
var ADD_SHIPPING_SHIPMENT_ADDRESS = (locale = "tr") => {
|
|
1240
|
+
const m = messages13[locale];
|
|
1241
|
+
return z14.z.object({
|
|
1242
|
+
name: z14.z.string().min(2, { message: m.public_forms_validations_minLength(2) }).max(254, { message: m.public_forms_validations_maxLength(254) }).meta({ examples: ["Ufuk Sar\u0131"] }),
|
|
1243
|
+
email: z14.z.email().min(6, { message: m.public_forms_validations_minLength(6) }).max(254, { message: m.public_forms_validations_maxLength(254) }).meta({ examples: ["ufuk.sari@mailinator.com"] }),
|
|
1244
|
+
phone: z14.z.e164({ message: m.public_forms_validations_phoneNumber }).meta({ examples: ["+905309464864"] }),
|
|
1245
|
+
address1: z14.z.string().min(2, { message: m.public_forms_validations_minLength(2) }).max(254, { message: m.public_forms_validations_maxLength(254) }).meta({ examples: ["Belek mahallesi Atat\xFCrk caddesi No: 11/1"] }),
|
|
1246
|
+
address2: z14.z.preprocess(
|
|
1247
|
+
(value) => value === "" ? void 0 : value,
|
|
1248
|
+
z14.z.string().min(2, { message: m.public_forms_validations_minLength(2) }).max(254, { message: m.public_forms_validations_maxLength(254) }).optional().meta({ examples: [""] })
|
|
1249
|
+
),
|
|
1250
|
+
countryCode: z14.z.string().min(2, { message: m.public_forms_validations_minLength(2) }).max(254, { message: m.public_forms_validations_maxLength(254) }).meta({ examples: ["TR"] }),
|
|
1251
|
+
cityName: z14.z.string().min(2, { message: m.public_forms_validations_minLength(2) }).max(254, { message: m.public_forms_validations_maxLength(254) }).meta({ examples: ["Antalya"] }),
|
|
1252
|
+
cityCode: z14.z.string().min(2, { message: m.public_forms_validations_minLength(2) }).max(254, { message: m.public_forms_validations_maxLength(254) }).meta({ examples: ["07"] }),
|
|
1253
|
+
districtName: z14.z.string().min(2, { message: m.public_forms_validations_minLength(2) }).max(254, { message: m.public_forms_validations_maxLength(254) }).meta({ examples: ["Belek"] }),
|
|
1254
|
+
zip: z14.z.string().min(2, { message: m.public_forms_validations_minLength(2) }).max(254, { message: m.public_forms_validations_maxLength(254) }).meta({ examples: ["07500"] }),
|
|
1255
|
+
isRecipientAddress: z14.z.boolean().meta({ examples: [true] }),
|
|
1256
|
+
shortName: z14.z.string().min(2, { message: m.public_forms_validations_minLength(2) }).max(254, { message: m.public_forms_validations_maxLength(254) }).meta({ examples: ["UFUKSARI"] })
|
|
1257
|
+
});
|
|
1258
|
+
};
|
|
1252
1259
|
var ADD_SHIPPING_SHIPMENT = () => z14.z.object({
|
|
1253
1260
|
test: z14.z.boolean().meta({ examples: [true] }),
|
|
1254
1261
|
items: z14.z.array(SHIPPING_ITEM()),
|