@getcommunity/gc-validators 0.0.32 → 0.0.34
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 +52 -55
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +6 -6
- package/dist/index.d.ts +6 -6
- package/dist/index.js +52 -55
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1042,7 +1042,8 @@ var SUtmLinkBuilderPartCampaignDateOptions = [
|
|
|
1042
1042
|
"annually",
|
|
1043
1043
|
"quarterly",
|
|
1044
1044
|
"monthly",
|
|
1045
|
-
"on a specific date"
|
|
1045
|
+
"on a specific date",
|
|
1046
|
+
"no date"
|
|
1046
1047
|
];
|
|
1047
1048
|
var SUtmLinkBuilderTableForm = v4__namespace.object({
|
|
1048
1049
|
creator: IsValidReferenceDocumentId,
|
|
@@ -1074,65 +1075,61 @@ var SUtmLinkBuilderTableForm = v4__namespace.object({
|
|
|
1074
1075
|
v4__namespace.minLength(1, "Please select at least one medium."),
|
|
1075
1076
|
v4__namespace.maxLength(10, "You can select up to 10 mediums.")
|
|
1076
1077
|
),
|
|
1077
|
-
campaign: v4__namespace.
|
|
1078
|
-
v4__namespace.
|
|
1079
|
-
|
|
1078
|
+
campaign: v4__namespace.object({
|
|
1079
|
+
campaign_phase: v4__namespace.pipe(
|
|
1080
|
+
v4__namespace.string(),
|
|
1081
|
+
v4__namespace.trim(),
|
|
1082
|
+
v4__namespace.maxLength(LIMIT_SHORT_STRING_MAX_LENGTH, "This medium value is too long.")
|
|
1083
|
+
),
|
|
1084
|
+
campaign_product: v4__namespace.optional(
|
|
1085
|
+
v4__namespace.pipe(
|
|
1080
1086
|
v4__namespace.string(),
|
|
1081
1087
|
v4__namespace.trim(),
|
|
1082
1088
|
v4__namespace.maxLength(LIMIT_SHORT_STRING_MAX_LENGTH, "This medium value is too long.")
|
|
1083
|
-
),
|
|
1084
|
-
campaign_product: v4__namespace.optional(
|
|
1085
|
-
v4__namespace.pipe(
|
|
1086
|
-
v4__namespace.string(),
|
|
1087
|
-
v4__namespace.trim(),
|
|
1088
|
-
v4__namespace.maxLength(LIMIT_SHORT_STRING_MAX_LENGTH, "This medium value is too long.")
|
|
1089
|
-
)
|
|
1090
|
-
),
|
|
1091
|
-
campaign_targeting: v4__namespace.optional(
|
|
1092
|
-
v4__namespace.pipe(
|
|
1093
|
-
v4__namespace.array(
|
|
1094
|
-
v4__namespace.pipe(
|
|
1095
|
-
v4__namespace.string(),
|
|
1096
|
-
v4__namespace.trim(),
|
|
1097
|
-
v4__namespace.maxLength(LIMIT_SHORT_STRING_MAX_LENGTH, "This value is too long.")
|
|
1098
|
-
)
|
|
1099
|
-
),
|
|
1100
|
-
v4__namespace.minLength(1, "Please select at least one targeting option."),
|
|
1101
|
-
v4__namespace.maxLength(10, "You can select up to 10 targeting options."),
|
|
1102
|
-
v4__namespace.transform((value) => value.join(","))
|
|
1103
|
-
)
|
|
1104
|
-
),
|
|
1105
|
-
campaign_key: v4__namespace.optional(
|
|
1106
|
-
v4__namespace.pipe(
|
|
1107
|
-
v4__namespace.string("please provide a value"),
|
|
1108
|
-
v4__namespace.trim(),
|
|
1109
|
-
v4__namespace.minLength(
|
|
1110
|
-
LIMIT_MIN_VALUE,
|
|
1111
|
-
`the value is too short, it must be at least ${LIMIT_MIN_VALUE} characters`
|
|
1112
|
-
),
|
|
1113
|
-
v4__namespace.maxLength(
|
|
1114
|
-
LIMIT_SHORT_STRING_MAX_LENGTH,
|
|
1115
|
-
`the value is too long, it must be ${LIMIT_SHORT_STRING_MAX_LENGTH} characters or less`
|
|
1116
|
-
),
|
|
1117
|
-
v4__namespace.regex(REGEX_UTM_VALUE, `the value ${ERROR_MESSAGE_REGEX_UTM_VALUE}`)
|
|
1118
|
-
)
|
|
1119
|
-
),
|
|
1120
|
-
campaign_date: v4__namespace.optional(
|
|
1121
|
-
v4__namespace.object({
|
|
1122
|
-
format: v4__namespace.picklist(
|
|
1123
|
-
SUtmLinkBuilderPartCampaignDateOptions,
|
|
1124
|
-
"Please select a valid campaign date format."
|
|
1125
|
-
),
|
|
1126
|
-
value: v4__namespace.object({
|
|
1127
|
-
year: v4__namespace.number(),
|
|
1128
|
-
quarter: v4__namespace.optional(v4__namespace.number()),
|
|
1129
|
-
month: v4__namespace.optional(v4__namespace.number()),
|
|
1130
|
-
day: v4__namespace.optional(v4__namespace.number())
|
|
1131
|
-
})
|
|
1132
|
-
})
|
|
1133
1089
|
)
|
|
1090
|
+
),
|
|
1091
|
+
campaign_targeting: v4__namespace.optional(
|
|
1092
|
+
v4__namespace.pipe(
|
|
1093
|
+
v4__namespace.array(
|
|
1094
|
+
v4__namespace.pipe(
|
|
1095
|
+
v4__namespace.string(),
|
|
1096
|
+
v4__namespace.trim(),
|
|
1097
|
+
v4__namespace.maxLength(LIMIT_SHORT_STRING_MAX_LENGTH, "This value is too long.")
|
|
1098
|
+
)
|
|
1099
|
+
),
|
|
1100
|
+
v4__namespace.minLength(1, "Please select at least one targeting option."),
|
|
1101
|
+
v4__namespace.maxLength(10, "You can select up to 10 targeting options."),
|
|
1102
|
+
v4__namespace.transform((value) => value.join(","))
|
|
1103
|
+
)
|
|
1104
|
+
),
|
|
1105
|
+
campaign_key: v4__namespace.optional(
|
|
1106
|
+
v4__namespace.pipe(
|
|
1107
|
+
v4__namespace.string("please provide a value"),
|
|
1108
|
+
v4__namespace.trim(),
|
|
1109
|
+
v4__namespace.minLength(
|
|
1110
|
+
LIMIT_MIN_VALUE,
|
|
1111
|
+
`the value is too short, it must be at least ${LIMIT_MIN_VALUE} characters`
|
|
1112
|
+
),
|
|
1113
|
+
v4__namespace.maxLength(
|
|
1114
|
+
LIMIT_SHORT_STRING_MAX_LENGTH,
|
|
1115
|
+
`the value is too long, it must be ${LIMIT_SHORT_STRING_MAX_LENGTH} characters or less`
|
|
1116
|
+
),
|
|
1117
|
+
v4__namespace.regex(REGEX_UTM_VALUE, `the value ${ERROR_MESSAGE_REGEX_UTM_VALUE}`)
|
|
1118
|
+
)
|
|
1119
|
+
),
|
|
1120
|
+
campaign_date: v4__namespace.object({
|
|
1121
|
+
format: v4__namespace.picklist(
|
|
1122
|
+
SUtmLinkBuilderPartCampaignDateOptions,
|
|
1123
|
+
"Please select a valid campaign date format."
|
|
1124
|
+
),
|
|
1125
|
+
value: v4__namespace.object({
|
|
1126
|
+
year: v4__namespace.number(),
|
|
1127
|
+
quarter: v4__namespace.optional(v4__namespace.number()),
|
|
1128
|
+
month: v4__namespace.optional(v4__namespace.number()),
|
|
1129
|
+
day: v4__namespace.optional(v4__namespace.number())
|
|
1130
|
+
})
|
|
1134
1131
|
})
|
|
1135
|
-
),
|
|
1132
|
+
}),
|
|
1136
1133
|
contents: v4__namespace.optional(
|
|
1137
1134
|
v4__namespace.pipe(
|
|
1138
1135
|
v4__namespace.string(),
|