UNPKG

@yolain/validation

Version:

Validation library inspired by Laravel's Validator

40 lines (39 loc) 1.57 kB
module.exports = { accepted: ':attribute必須接受。', alpha: ':attribute只能包含字母。', alpha_dash: ':attribute只能包含字母,連字符和下划線。', alpha_num: ':attribute只能包含字母和數字。', between: ':attribute的值只能在:min和:max之間。', confirmed: ':attribute與確認輸入不一致。', email: ':attribute的格式錯誤。', date: ':attribute的日期格式錯誤。', def: ':attribute屬性錯誤。', digits: ':attribute必須是:digits位小數。', digits_between: ':attribute 必須介於 :min 至 :max 位數字。', different: ':attribute和:different必須不同。', in: '選擇的:attribute無效', integer: ':attribute必須是一個整數。', hex: ':attribute 必須是十六進位格式', min: { numeric: ':attribute不能小於:min。', string: ':attribute的長度不能小於:min.' }, max: { numeric: ':attribute不能大於:max。', string: ':attribute的長度不能大於:max.' }, not_in: '所選的:attribute無效。', numeric: ':attribute必須是一個數字。', present: ':attribute 一定要有值 (可以是空值)。', required: ':attribute不能空白。', required_if: '當:other是:value時,:attribute不能空白。', same: ':attribute和:same必須一致。', size: { numeric: ':attribute必須等於:size。', string: ':attribute的長度必須等於:size.' }, string: ':attribute必須是一個字串。', url: ':attribute格式不正確。', regex: ':attribute格式不正確。', attributes: {} };