{"record":{"id":"4b1c73ec515d3a5b","repo":"Semantic-Org/Semantic-UI","slug":"name-cannot-be-set-to-exactly-rulevalue","errorCode":null,"errorMessage":"{name} cannot be set to exactly \"{ruleValue}\"","messagePattern":"(.+?) cannot be set to exactly \"(.+?)\"","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"src/definitions/behaviors/form.js","lineNumber":1265,"sourceCode":"\n  text: {\n    unspecifiedRule  : 'Please enter a valid value',\n    unspecifiedField : 'This field'\n  },\n\n  prompt: {\n    empty                : '{name} must have a value',\n    checked              : '{name} must be checked',\n    email                : '{name} must be a valid e-mail',\n    url                  : '{name} must be a valid url',\n    regExp               : '{name} is not formatted correctly',\n    integer              : '{name} must be an integer',\n    decimal              : '{name} must be a decimal number',\n    number               : '{name} must be set to a number',\n    is                   : '{name} must be \"{ruleValue}\"',\n    isExactly            : '{name} must be exactly \"{ruleValue}\"',\n    not                  : '{name} cannot be set to \"{ruleValue}\"',\n    notExactly           : '{name} cannot be set to exactly \"{ruleValue}\"',\n    contain              : '{name} must contain \"{ruleValue}\"',\n    containExactly       : '{name} must contain exactly \"{ruleValue}\"',\n    doesntContain        : '{name} cannot contain  \"{ruleValue}\"',\n    doesntContainExactly : '{name} cannot contain exactly \"{ruleValue}\"',\n    minLength            : '{name} must be at least {ruleValue} characters',\n    length               : '{name} must be at least {ruleValue} characters',\n    exactLength          : '{name} must be exactly {ruleValue} characters',\n    maxLength            : '{name} cannot be longer than {ruleValue} characters',\n    match                : '{name} must match {ruleValue} field',\n    different            : '{name} must have a different value than {ruleValue} field',\n    creditCard           : '{name} must be a valid credit card number',\n    minCount             : '{name} must have at least {ruleValue} choices',\n    exactCount           : '{name} must have exactly {ruleValue} choices',\n    maxCount             : '{name} must have {ruleValue} or less choices'\n  },\n\n  selector : {\n    checkbox   : 'input[type=\"checkbox\"], input[type=\"radio\"]',","sourceCodeStart":1247,"sourceCodeEnd":1283,"githubUrl":"https://github.com/Semantic-Org/Semantic-UI/blob/597843ab84d565cccfd8fd7719416350ae73e734/src/definitions/behaviors/form.js#L1247-L1283","documentation":"Default prompt for the Semantic UI Form `notExactly` rule (settings.rules.notExactly, form.js:1453). Requires the value to differ from the forbidden `{ruleValue}` using case-SENSITIVE comparison. Shown when the value exactly equals the forbidden string.","triggerScenarios":"`{type:'notExactly[admin]'}` with input `admin` (matches exactly → fails); `Admin` would pass.","commonSituations":"Blocking an exact reserved value while allowing case variants, or the inverse expectation where users think all cases are blocked.","solutions":["Change the value so it is not the exact forbidden string.","If all cases should be blocked, use the `not` rule.","Add a custom `prompt`."],"exampleFix":"// before\nrules: [{ type: 'notExactly[admin]' }]\n\n// after\nrules: [{ type: 'notExactly[admin]', prompt: 'Value cannot be \"admin\"' }]","handlingStrategy":"validation","validationCode":"const blocked = 'admin';\nif ($field.val() === blocked) { /* warn */ }","typeGuard":"const isForbiddenExact = (v, t) => v === t;","tryCatchPattern":null,"preventionTips":["Use not when all cases should be blocked.","Make case sensitivity explicit in the prompt.","Validate server-side as well."],"tags":["semantic-ui","form-validation","inequality","case-sensitive","client-side"],"backgroundTag":null,"analyzedSha":"597843ab84d565cccfd8fd7719416350ae73e734","analyzedAt":"2026-08-13T01:44:23.827Z","schemaVersion":2},"datasetVersion":"2026-08-13T04:17:16.726Z"}