docs
evals
scenario-1
scenario-10
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
{
"context": "This criteria evaluates how well the engineer uses the @rc-component/input-number package to handle high-precision numeric values. The focus is on correctly implementing string mode to prevent precision loss for large numbers and properly configuring formatting, parsing, and validation features.",
"type": "weighted_checklist",
"checklist": [
{
"name": "String mode enabled",
"description": "The component uses the stringMode prop set to true to ensure values are returned as strings rather than numbers, preventing precision loss for large values.",
"max_score": 30
},
{
"name": "Formatter implementation",
"description": "The component uses the formatter prop with a function that adds currency symbol ($ ) and thousand separators to format the display value (e.g., transforming 1234567.89 to $ 1,234,567.89).",
"max_score": 20
},
{
"name": "Parser implementation",
"description": "The component uses the parser prop with a function that removes currency symbols, spaces, and thousand separators from the formatted string to extract the numeric value.",
"max_score": 20
},
{
"name": "Step configuration",
"description": "The component uses the step prop set to 0.01 (or the string '0.01') to allow increments and decrements by one cent.",
"max_score": 10
},
{
"name": "Minimum value constraint",
"description": "The component uses the min prop set to 0 to prevent negative transaction amounts.",
"max_score": 10
},
{
"name": "Precision configuration",
"description": "The component uses the precision prop set to 8 to support up to 8 decimal places for fractional amounts.",
"max_score": 10
}
]
}