# all files / dist/ validator.js

85.85% Statements 734/855
68.61% Branches 330/481
92.59% Functions 175/189
87.56% Lines 711/812

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    142
    143
    144
    145
    146
    147
    148
    149
    150
    151
    152
    153
    154
    155
    156
    157
    158
    159
    160
    161
    162
    163
    164
    165
    166
    167
    168
    169
    170
    171
    172
    173
    174
    175
    176
    177
    178
    179
    180
    181
    182
    183
    184
    185
    186
    187
    188
    189
    190
    191
    192
    193
    194
    195
    196
    197
    198
    199
    200
    201
    202
    203
    204
    205
    206
    207
    208
    209
    210
    211
    212
    213
    214
    215
    216
    217
    218
    219
    220
    221
    222
    223
    224
    225
    226
    227
    228
    229
    230
    231
    232
    233
    234
    235
    236
    237
    238
    239
    240
    241
    242
    243
    244
    245
    246
    247
    248
    249
    250
    251
    252
    253
    254
    255
    256
    257
    258
    259
    260
    261
    262
    263
    264
    265
    266
    267
    268
    269
    270
    271
    272
    273
    274
    275
    276
    277
    278
    279
    280
    281
    282
    283
    284
    285
    286
    287
    288
    289
    290
    291
    292
    293
    294
    295
    296
    297
    298
    299
    300
    301
    302
    303
    304
    305
    306
    307
    308
    309
    310
    311
    312
    313
    314
    315
    316
    317
    318
    319
    320
    321
    322
    323
    324
    325
    326
    327
    328
    329
    330
    331
    332
    333
    334
    335
    336
    337
    338
    339
    340
    341
    342
    343
    344
    345
    346
    347
    348
    349
    350
    351
    352
    353
    354
    355
    356
    357
    358
    359
    360
    361
    362
    363
    364
    365
    366
    367
    368
    369
    370
    371
    372
    373
    374
    375
    376
    377
    378
    379
    380
    381
    382
    383
    384
    385
    386
    387
    388
    389
    390
    391
    392
    393
    394
    395
    396
    397
    398
    399
    400
    401
    402
    403
    404
    405
    406
    407
    408
    409
    410
    411
    412
    413
    414
    415
    416
    417
    418
    419
    420
    421
    422
    423
    424
    425
    426
    427
    428
    429
    430
    431
    432
    433
    434
    435
    436
    437
    438
    439
    440
    441
    442
    443
    444
    445
    446
    447
    448
    449
    450
    451
    452
    453
    454
    455
    456
    457
    458
    459
    460
    461
    462
    463
    464
    465
    466
    467
    468
    469
    470
    471
    472
    473
    474
    475
    476
    477
    478
    479
    480
    481
    482
    483
    484
    485
    486
    487
    488
    489
    490
    491
    492
    493
    494
    495
    496
    497
    498
    499
    500
    501
    502
    503
    504
    505
    506
    507
    508
    509
    510
    511
    512
    513
    514
    515
    516
    517
    518
    519
    520
    521
    522
    523
    524
    525
    526
    527
    528
    529
    530
    531
    532
    533
    534
    535
    536
    537
    538
    539
    540
    541
    542
    543
    544
    545
    546
    547
    548
    549
    550
    551
    552
    553
    554
    555
    556
    557
    558
    559
    560
    561
    562
    563
    564
    565
    566
    567
    568
    569
    570
    571
    572
    573
    574
    575
    576
    577
    578
    579
    580
    581
    582
    583
    584
    585
    586
    587
    588
    589
    590
    591
    592
    593
    594
    595
    596
    597
    598
    599
    600
    601
    602
    603
    604
    605
    606
    607
    608
    609
    610
    611
    612
    613
    614
    615
    616
    617
    618
    619
    620
    621
    622
    623
    624
    625
    626
    627
    628
    629
    630
    631
    632
    633
    634
    635
    636
    637
    638
    639
    640
    641
    642
    643
    644
    645
    646
    647
    648
    649
    650
    651
    652
    653
    654
    655
    656
    657
    658
    659
    660
    661
    662
    663
    664
    665
    666
    667
    668
    669
    670
    671
    672
    673
    674
    675
    676
    677
    678
    679
    680
    681
    682
    683
    684
    685
    686
    687
    688
    689
    690
    691
    692
    693
    694
    695
    696
    697
    698
    699
    700
    701
    702
    703
    704
    705
    706
    707
    708
    709
    710
    711
    712
    713
    714
    715
    716
    717
    718
    719
    720
    721
    722
    723
    724
    725
    726
    727
    728
    729
    730
    731
    732
    733
    734
    735
    736
    737
    738
    739
    740
    741
    742
    743
    744
    745
    746
    747
    748
    749
    750
    751
    752
    753
    754
    755
    756
    757
    758
    759
    760
    761
    762
    763
    764
    765
    766
    767
    768
    769
    770
    771
    772
    773
    774
    775
    776
    777
    778
    779
    780
    781
    782
    783
    784
    785
    786
    787
    788
    789
    790
    791
    792
    793
    794
    795
    796
    797
    798
    799
    800
    801
    802
    803
    804
    805
    806
    807
    808
    809
    810
    811
    812
    813
    814
    815
    816
    817
    818
    819
    820
    821
    822
    823
    824
    825
    826
    827
    828
    829
    830
    831
    832
    833
    834
    835
    836
    837
    838
    839
    840
    841
    842
    843
    844
    845
    846
    847
    848
    849
    850
    851
    852
    853
    854
    855
    856
    857
    858
    859
    860
    861
    862
    863
    864
    865
    866
    867
    868
    869
    870
    871
    872
    873
    874
    875
    876
    877
    878
    879
    880
    881
    882
    883
    884
    885
    886
    887
    888
    889
    890
    891
    892
    893
    894
    895
    896
    897
    898
    899
    900
    901
    902
    903
    904
    905
    906
    907
    908
    909
    910
    911
    912
    913
    914
    915
    916
    917
    918
    919
    920
    921
    922
    923
    924
    925
    926
    927
    928
    929
    930
    931
    932
    933
    934
    935
    936
    937
    938
    939
    940
    941
    942
    943
    944
    945
    946
    947
    948
    949
    950
    951
    952
    953
    954
    955
    956
    957
    958
    959
    960
    961
    962
    963
    964
    965
    966
    967
    968
    969
    970
    971
    972
    973
    974
    975
    976
    977
    978
    979
    980
    981
    982
    983
    984
    985
    986
    987
    988
    989
    990
    991
    992
    993
    994
    995
    996
    997
    998
    999
    1000
    1001
    1002
    1003
    1004
    1005
    1006
    1007
    1008
    1009
    1010
    1011
    1012
    1013
    1014
    1015
    1016
    1017
    1018
    1019
    1020
    1021
    1022
    1023
    1024
    1025
    1026
    1027
    1028
    1029
    1030
    1031
    1032
    1033
    1034
    1035
    1036
    1037
    1038
    1039
    1040
    1041
    1042
    1043
    1044
    1045
    1046
    1047
    1048
    1049
    1050
    1051
    1052
    1053
    1054
    1055
    1056
    1057
    1058
    1059
    1060
    1061
    1062
    1063
    1064
    1065
    1066
    1067
    1068
    1069
    1070
    1071
    1072
    1073
    1074
    1075
    1076
    1077
    1078
    1079
    1080
    1081
    1082
    1083
    1084
    1085
    1086
    1087
    1088
    1089
    1090
    1091
    1092
    1093
    1094
    1095
    1096
    1097
    1098
    1099
    1100
    1101
    1102
    1103
    1104
    1105
    1106
    1107
    1108
    1109
    1110
    1111
    1112
    1113
    1114
    1115
    1116
    1117
    1118
    1119
    1120
    1121
    1122
    1123
    1124
    1125
    1126
    1127
    1128
    1129
    1130
    1131
    1132
    1133
    1134
    1135
    1136
    1137
    1138
    1139
    1140
    1141
    1142
    1143
    1144
    1145
    1146
    1147
    1148
    1149
    1150
    1151
    1152
    1153
    1154
    1155
    1156
    1157
    1158
    1159
    1160
    1161
    1162
    1163
    1164
    1165
    1166
    1167
    1168
    1169
    1170
    1171
    1172
    1173
    1174
    1175
    1176
    1177
    1178
    1179
    1180
    1181
    1182
    1183
    1184
    1185
    1186
    1187
    1188
    1189
    1190
    1191
    1192
    1193
    1194
    1195
    1196
    1197
    1198
    1199
    1200
    1201
    1202
    1203
    1204
    1205
    1206
    1207
    1208
    1209
    1210
    1211
    1212
    1213
    1214
    1215
    1216
    1217
    1218
    1219
    1220
    1221
    1222
    1223
    1224
    1225
    1226
    1227
    1228
    1229
    1230
    1231
    1232
    1233
    1234
    1235
    1236
    1237
    1238
    1239
    1240
    1241
    1242
    1243
    1244
    1245
    1246
    1247
    1248
    1249
    1250
    1251
    1252
    1253
    1254
    1255
    1256
    1257
    1258
    1259
    1260
    1261
    1262
    1263
    1264
    1265
    1266
    1267
    1268
    1269
    1270
    1271
    1272
    1273
    1274
    1275
    1276
    1277
    1278
    1279
    1280
    1281
    1282
    1283
    1284
    1285
    1286
    1287
    1288
    1289
    1290
    1291
    1292
    1293
    1294
    1295
    1296
    1297
    1298
    1299
    1300
    1301
    1302
    1303
    1304
    1305
    1306
    1307
    1308
    1309
    1310
    1311
    1312
    1313
    1314
    1315
    1316
    1317
    1318
    1319
    1320
    1321
    1322
    1323
    1324
    1325
    1326
    1327
    1328
    1329
    1330
    1331
    1332
    1333
    1334
    1335
    1336
    1337
    1338
    1339
    1340
    1341
    1342
    1343
    1344
    1345
    1346
    1347
    1348
    1349
    1350
    1351
    1352
    1353
    1354
    1355
    1356
    1357
    1358
    1359
    1360
    1361
    1362
    1363
    1364
    1365
    1366
    1367
    1368
    1369
    1370
    1371
    1372
    1373
    1374
    1375
    1376
    1377
    1378
    1379
    1380
    1381
    1382
    1383
    1384
    1385
    1386
    1387
    1388
    1389
    1390
    1391
    1392
    1393
    1394
    1395
    1396
    1397
    1398
    1399
    1400
    1401
    1402
    1403
    1404
    1405
    1406
    1407
    1408
    1409
    1410
    1411
    1412
    1413
    1414
    1415
    1416
    1417
    1418
    1419
    1420
    1421
    1422
    1423
    1424
    1425
    1426
    1427
    1428
    1429
    1430
    1431
    1432
    1433
    1434
    1435
    1436
    1437
    1438
    1439
    1440
    1441
    1442
    1443
    1444
    1445
    1446
    1447
    1448
    1449
    1450
    1451
    1452
    1453
    1454
    1455
    1456
    1457
    1458
    1459
    1460
    1461
    1462
    1463
    1464
    1465
    1466
    1467
    1468
    1469
    1470
    1471
    1472
    1473
    1474
    1475
    1476
    1477
    1478
    1479
    1480
    1481
    1482
    1483
    1484
    1485
    1486
    1487
    1488
    1489
    1490
    1491
    1492
    1493
    1494
    1495
    1496
    1497
    1498
    1499
    1500
    1501
    1502
    1503
    1504
    1505
    1506
    1507
    1508
    1509
    1510
    1511
    1512
    1513
    1514
    1515
    1516
    1517
    1518
    1519
    1520
    1521
    1522
    1523
    1524
    1525
    1526
    1527
    1528
    1529
    1530
    1531
    1532
    1533
    1534
    1535
    1536
    1537
    1538
    1539
    1540
    1541
    1542
    1543
    1544
    1545
    1546
    1547
    1548
    1549
    1550
    1551
    1552
    1553
    1554
    1555
    1556
    1557
    1558
    1559
    1560
    1561
    1562
    1563
    1564
    1565
    1566
    1567
    1568
    1569
    1570
    1571
    1572
    1573
    1574
    1575
    1576
    1577
    1578
    1579
    1580
    1581
    1582
    1583
    1584
    1585
    1586
    1587
    1588
    1589
    1590
    1591
    1592
    1593
    1594
    1595
    1596
    1597
    1598
    1599
    1600
    1601
    1602
    1603
    1604
    1605
    1606
    1607
    1608
    1609
    1610
    1611
    1612
    1613
    1614
    1615
    1616
    1617
    1618
    1619
    1620
    1621
    1622
    1623
    1624
    1625
    1626
    1627
    1628
    1629
    1630
    1631
    1632
    1633
    1634
    1635
    1636
    1637
    1638
    1639
    1640
    1641
    1642
    1643
    1644
    1645
    1646
    1647
    1648
    1649
    1650
    1651
    1652
    1653
    1654
    1655
    1656
    1657
    1658
    1659
    1660
    1661
    1662
    1663
    1664
    1665
    1666
    1667
    1668
    1669
    1670
    1671
    1672
    1673
    1674
    1675
    1676
    1677
    1678
    1679
    1680
    1681
    1682
    1683
    1684
    1685
    1686
    1687
    1688
    1689
    1690
    1691
    1692
    1693
    1694
    1695
    1696
    1697
    1698
    1699
    1700
    1701
    1702
    1703
    1704
    1705
    1706
    1707
    1708
    1709
    1710
    1711
    1712
    1713
    1714
    1715
    1716
    1717
    1718
    1719
    1720
    1721
    1722
    1723
    1724
    1725
    1726
    1727
    1728
    1729
    1730
    1731
    1732
    1733
    1734
    1735
    1736
    1737
    1738
    1739
    1740
    1741
    1742
    1743
    1744
    1745
    1746
    1747
    1748
    1749
    1750
    1751
    1752
    1753
    1754
    1755
    1756
    1757
    1758
    1759
    1760
    1761
    1762
    1763
    1764
    1765
    1766
    1767
    1768
    1769
    1770
    1771
    1772
    1773
    1774
    1775
    1776
    1777
    1778
    1779
    1780
    1781
    1782
    1783
    1784
    1785
    1786
    1787
    1788
    1789
    1790
    1791
    1792
    1793
    1794
    1795
    1796
    1797
    1798
    1799
    1800
    1801
    1802
    1803
    1804
    1805
    1806
    1807
    1808
    1809
    1810
    1811
    1812
    1813
    1814
    1815
    1816
    1817
    1818
    1819
    1820
    1821
    1822
    1823
    1824
    1825
    1826
    1827
    1828
    1829
    1830
    1831
    1832
    1833
    1834
    1835
    1836
    1837
    1838
    1839
    1840
    1841
    1842
    1843
    1844
    1845
    1846
    1847
    1848
    1849
    1850
    1851
    1852
    1853
    1854
    1855
    1856
    1857
    1858
    1859
    1860
    1861
    1862
    1863
    1864
    1865
    1866
    1867
    1868
    1869
    1870
    1871
    1872
    1873
    1874
    1875
    1876
    1877
    1878
    1879
    1880
    1881
    1882
    1883
    1884
    1885
    1886
    1887
    1888
    1889
    1890
    1891
    1892
    1893
    1894
    1895
    1896
    1897
    1898
    1899
    1900
    1901
    1902
    1903
    1904
    1905
    1906
    1907
    1908
    1909
    1910
    1911
    1912
    1913
    1914
    1915
    1916
    1917
    1918
    1919
    1920
    1921
    1922
    1923
    1924
    1925
    1926
    1927
    1928
    1929
    1930
    1931
    1932
    1933
    1934
    1935
    1936
    1937
    1938
    1939
    1940
    1941
    1942
    1943
    1944
    1945
    1946
    1947
    1948
    1949
    1950
    1951
    1952
    1953
    1954
    1955
    1956
    1957
    1958
    1959
    1960
    1961
    1962
    1963
    1964
    1965
    1966
    1967
    1968
    1969
    1970
    1971
    1972
    1973
    1974
    1975
    1976
    1977
    1978
    1979
    1980
    1981
    1982
    1983
    1984
    1985
    1986
    1987
    1988
    1989
    1990
    1991
    1992
    1993
    1994
    1995
    1996
    1997
    1998
    1999
    2000
    2001
    2002
    2003
    2004
    2005
    2006
    2007
    2008
    2009
    2010
    2011
    2012
    2013
    2014
    2015
    2016
    2017
    2018
    2019
    2020
    2021
    2022
    2023
    2024
    2025
    2026
    2027
    2028
    2029
    2030
    2031
    2032
    2033
    2034
    2035
    2036
    2037
    2038
    2039
    2040
    2041
    2042
    2043
    2044
    2045
    2046
    2047
    2048
    2049
    2050
    2051
    2052
    2053
    2054
    2055
    2056
    2057
    2058
    2059
    2060
    2061
    2062
    2063
    2064
    2065
    2066
    2067
    2068
    2069
    2070
    2071
    2072
    2073
    2074
    2075
    2076
    2077
    2078
    2079
    2080
    2081
    2082
    2083
    2084
    2085
    2086
    2087
    2088
    2089
    2090
    2091
    2092
    2093
    2094
    2095
    2096
    2097
    2098
    2099
    2100
    2101
    2102
    2103
    2104
    2105
    2106
    2107
    2108
    2109
    2110
    2111
    2112
    2113
    2114
    2115
    2116
    2117
    2118
    2119
    2120
    2121
    2122
    2123
    2124
    2125
    2126
    2127
    2128
    2129
    2130
    2131
    2132
    2133
    2134
    2135
    2136
    2137
    2138
    2139
    2140
    2141
    2142
    2143
    2144
    2145
    2146
    2147
    2148
    2149
    2150
    2151
    2152
    2153
    2154
    2155
    2156
    2157
    2158
    2159
    2160
    2161
    2162
    2163
    2164
    2165
    2166
    2167
    2168
    2169
    2170
    2171
    2172
    2173
    2174
    2175
    2176
    2177
    2178
    2179
    2180
    2181
    2182
    2183
    2184
    2185
    2186
    2187
    2188
    2189
    2190
    2191
    2192
    2193
    2194
    2195
    2196
    2197
    2198
    2199
    2200
    2201
    2202
    2203
    2204
    2205
    2206
    2207
    2208
    2209
    2210
    2211
    2212
    2213
    2214
    2215
    2216
    2217
    2218
    2219
    2220
    2221
    2222
    2223
    2224
    2225
    2226
    2227
    2228
    2229
    2230
    2231
    2232
    2233
    2234
    2235
    2236
    2237
    2238
    2239
    2240
    2241
    2242
    2243
    2244
    2245
    2246
    2247
    2248
    2249
    2250
    2251
    2252
    2253
    2254
    2255
    2256
    2257
    2258
    2259
    2260
    2261
    2262
    2263
    2264
    2265
    2266
    2267
    2268
    2269
    2270
    2271
    2272
    2273
    2274
    2275
    2276
    2277
    2278
    2279
    2280
    2281
    2282
    2283
    2284
    2285
    2286
    2287
    2288
    2289
    2290
    2291
    2292
    2293
    2294
    2295
    2296
    2297
    2298
    2299
    2300
    2301
    2302
    2303
    2304
    2305
    2306
    2307
    2308
    2309
    2310
    2311
    2312
    2313
    2314
    2315
    2316
    2317
    2318
    2319
    2320
    2321
    2322
    2323
    2324
    2325
    2326
    2327
    2328
    2329
    2330
    2331
    2332
    2333
    2334
    2335
    2336
    2337
    2338
    2339
    2340
    2341
    2342
    2343
    2344
    2345
    2346
    2347
    2348
    2349
    2350
    2351
    2352
    2353
    2354
    2355
    2356
    2357
    2358
    2359
    2360
    2361
    2362
    2363
    2364
    2365
    2366
    2367
    2368
    2369
    2370
    2371
    2372
    2373
    2374
    2375
    2376
    2377
    2378
    2379
    2380
    2381
    2382
    2383
    2384
    2385
    2386
    2387
    2388
    2389
    2390
    2391
    2392
    2393
    2394
    2395
    2396
    2397
    2398
    2399
    2400
    2401
    2402
    2403
    2404
    2405
    2406
    2407
    2408
    2409
    2410
    2411
    2412
    2413
    2414
    2415
    2416
    2417
    2418
    2419
    2420
    2421
    2422
    2423
    2424
    2425
    2426
    2427
    2428
    2429
    2430
    2431
    2432
    2433
    2434
    2435
    2436
    2437
    2438
    2439
    2440
    2441
    2442
    2443
    2444
    2445
    2446
    2447
    2448
    2449
    2450
    2451
    2452
    2453
    2454
    2455
    2456
    2457
    2458
    2459
    2460
    2461
    2462
    2463
    2464
    2465
    2466
    2467
    2468
    2469
    2470
    2471
    2472
    2473
    2474
    2475
    2476
    2477
    2478
    2479
    2480
    2481
    2482
    2483
    2484
    2485
    2486
    2487
    2488
    2489
    2490
    2491
    2492
    2493
    2494
    2495
    2496
    2497
    2498
    2499
    2500
    2501
    2502
    2503
    2504
    2505
    2506
    2507
    2508
    2509
    2510
    2511
    2512
    2513
    2514
    2515
    2516
    2517
    2518
    2519
    2520
    2521
    2522
    2523
    2524
    2525
    2526
    16×

    1×

    1×
    1×

    1×
    132×
    132×
    132×
    132×
    132×

    1×

    1×

    1×

    1×

    1×

    1×

    1×

    1×

    1×

    1×
    79×

    79×
    79×

    1×

    1×

    1×

    1×

    1×

    2×

    1×
    1×
    1×
    1×

    1×
    1×
    1×

    1×
    79×

    79×
    79×

    79×

    79×

    79×
    79×

    79×
    79×
    79×

    79×
    13×

    66×
    66×
    66×

    66×

    66×

    66×
    66×
    66×

    66×
    66×
    66×

    66×

    66×

    1×
    79×
    79×
    79×

    79×

    79×
    79×

    79×

    79×

    79×

    1×
    79×
    79×

    79×

    79×
    79×
    79×

    1×

    79×
    79×

    79×
    79×
    79×
    79×
    79×
    79×
    79×

    79×

    79×

    79×
    13×

    66×
    66×

    1×
    395×

    1×

    1×

    1×

    1×

    1×

    1×
    68×

    1×
    79×

    1×
    66×

    1×

    1×

    1×

    1×

    1×

    1×

    1×
    79×

    79×

    79×

    79×

    1×

    1×
    16×
    16×
    16×
    16×
    16×
    16×
    16×

    1×

    28×
    28×
    28×
    28×

    28×
    28×
    20×
    8×
    8×
    8×

    28×

    28×

    44×
    16×

    28×
    16×

    16×

    1×

    1×

    5×
    5×

    5×
    5×

    3×
    3×

    5×
    5×

    3×
    3×
    3×

    3×
    3×

    3×
    3×
    3×

    5×
    5×

    5×
    5×

    3×
    3×

    3×
    3×

    7×
    7×

    1×
    318×

    1×

    1×
    344×

    1×

    295×
    207×

    295×
    209×

    21×
    19×

    2×

    94×
    92×

    2×

    3×

    413×
    200×

    213×

    1×

    1×

    1×

    1×

    1×

    2×

    22×
    22×
    4×

    22×

    367×
    1×
    1×
    1×

    1×
    1×

    344×
    344×

    1×

    1×

    1×

    1×
    344×
    344×
    344×
    344×

    1×

    510×

    12×

    345×

    345×
    345×
    25×
    320×

    320×
    320×

    320×

    295×
    1×

    294×

    294×
    294×
    50×

    244×

    294×

    294×
    294×
    294×
    294×

    294×
    584×
    584×
    10×
    10×
    574×
    271×
    271×

    294×
    30×

    294×

    294×

    294×
    294×

    294×
    294×

    294×
    628×

    294×

    1×

    1×
    1×

    1×
    18×

    1×
    107×
    10×

    97×
    95×
    95×
    1×

    95×
    79×

    18×
    18×
    18×
    18×

    18×

    18×

    18×
    3×

    15×

    15×

    15×

    15×

    1×

    636×

    636×
    79×

    557×
    557×

    9×
    9×
    9×

    5×
    5×
    5×

    7×
    7×

    7×

    7×
    14×
    2×

    5×

    5×
    2×

    3×

    7×

    7×
    12×
    2×

    5×

    18×

    8×
    8×

    8×

    8×

    2×

    32×
    32×

    16×
    16×

    23×
    23×
    23×
    23×
    23×

    16×
    16×

    27×

    27×

    27×
    14×

    13×

    8×

    6×

    7×

    7×

    6×

    11×
    11×

    11×
    4×

    7×

    9×
    9×

    9×
    4×

    5×

    12×

    12×
    12×

    12×
    10×

    10×
    20×
    18×

    20×
    6×

    4×

    2×
    2×
    4×
    1×

    1×

    10×
    10×
    10×

    10×
    22×

    22×
    18×

    22×
    4×
    4×

    10×

    26×
    12×

    14×

    7×

    7×
    2×

    5×

    22×

    4×
    4×
    2×

    2×

    29×
    29×
    29×
    29×
    29×
    29×

    51×

    2×

    7×
    7×

    7×

    7×

    7×
    2×

    5×

    7×
    7×

    7×

    7×

    7×
    4×

    3×

    7×
    7×

    7×

    7×

    7×
    2×

    5×

    7×
    7×

    7×

    7×

    7×
    4×

    3×

    10×

    1×

    1×

    1×
    1173×
    1173×
    1173×
    1173×
    1173×

    1×

    1099×
    1099×
    1099×
    28×
    28×
    28×

    28×
    12×

    16×

    1071×

    1099×

    1099×

    1099×
    1099×
    1099×

    394×

    394×
    203×

    394×

    394×
    6×

    394×

    79×

    79×
    2×

    77×
    28×

    49×
    10×

    39×

    30×
    11×

    19×

    28×
    28×
    28×

    1173×

    1395×

    296×

    1×

    1173×
    1173×
    1173×
    1173×

    1655×
    13549×
    24×

    1631×

    674×

    22×

    4×
    4×

    10×
    10×

    2×
    2×

    1×
    1×

    1×

    1×
    1×
    1×
    1×
    1×

    1×
    344×
    344×

    344×
    344×
    344×

    344×
    344×

    344×
    344×

    1×

    462×

    462×
    591×
    591×

    591×
    1×

    590×
    646×
    646×

    646×
    73×

    573×
    573×
    287×

    573×
    3×

    462×

    16×
    16×
    16×

    16×
    8×

    16×
    16×
    8×

    8×

    16×

    16×
    28×
    28×
    28×
    28×

    16×
    20×
    20×

    20×
    1×

    19×
    28×

    28×

    28×

    28×

    16×
    16×

    295×
    295×
    295×

    375×

    1×
    867×
    2×

    865×
    470×

    395×
    395×
    495×
    495×

    395×
    1×

    375×
    372×

    375×

    693×
    496×

    197×
    197×
    197×
    181×
    181×

    197×
    571×
    476×

    95×

    102×

    344×
    344×

    344×

    417×

    417×

    344×

    459×
    30×

    429×

    30×
    30×

    30×
    30×
    42×
    42×
    42×

    429×

    429×
    28×

    429×
    401×

    429×
    482×
    482×
    166×
    166×

    482×
    12×

    482×

    429×

    169×
    164×

    5×
    5×
    5×

    5×
    5×
    1×

    4×

    5×

    5×

    166×
    166×
    166×
    6×
    3×
    3×

    166×

    28×

    28×
    35×
    2×
    4×

    33×

    28×

    4×

    478×

    478×

    478×
    162×
    162×
    162×

    478×

    683×
    683×
    789×
    18×

    665×

    72×

    674×
    214×

    460×

    573×
    573×
    568×

    5×
    3×

    2×

    12×

    345×

    1173×

    2×

    260×
    259×
    9×

    250×

    220×
    219×
    7×

    212×

    478×
    478×

    478×

    1×
    1×
    1×

    1×
    1×

    1×
    4×

    1×
    370×

    1×
    2×

    1×
    2×

    1×
    8×
    8×
    8×

    1×
    2×
    2×
    2×

    1×
    10×
    10×
    10×

    1×
    2×
    2×
    2×

    1×
    1×

    1×

     /*! validatorjs - v3.22.0 -  - 2020-12-03 */
    (function(f){Iif(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else Iif(typeof define==="function"&&define.amd){define([],f)}else{var g;Eif(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.Validator = f()}})(function(){var define,module,exports;return (function(){function r(e,n,t){function o(i,f){if(!n[i]){Iif(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;i<t.length;i++)o(t[i]);return o}return r})()({1:[function(require,module,exports){
    "use strict";

    Object.defineProperty(exports, "__esModule", {
      value: true
    });
    exports.default = getTimezoneOffsetInMilliseconds;
    var MILLISECONDS_IN_MINUTE = 60000;
    /**
     * Google Chrome as of 67.0.3396.87 introduced timezones with offset that includes seconds.
     * They usually appear for dates that denote time before the timezones were introduced
     * (e.g. for 'Europe/Prague' timezone the offset is GMT+00:57:44 before 1 October 1891
     * and GMT+01:00:00 after that date)
     *
     * Date#getTimezoneOffset returns the offset in minutes and would return 57 for the example above,
     * which would lead to incorrect calculations.
     *
     * This function returns the timezone offset in milliseconds that takes seconds in account.
     */

    function getTimezoneOffsetInMilliseconds(dirtyDate) {
      var date = new Date(dirtyDate.getTime());
      var baseTimezoneOffset = date.getTimezoneOffset();
      date.setSeconds(0, 0);
      var millisecondsPartOfTimezoneOffset = date.getTime() % MILLISECONDS_IN_MINUTE;
      return baseTimezoneOffset * MILLISECONDS_IN_MINUTE + millisecondsPartOfTimezoneOffset;
    }

    module.exports = exports.default;
    },{}],2:[function(require,module,exports){
    "use strict";

    Object.defineProperty(exports, "__esModule", {
      value: true
    });
    exports.default = toInteger;

    function toInteger(dirtyNumber) {
      if (dirtyNumber === null || dirtyNumber === true || dirtyNumber === false) {
        return NaN;
      }

      var number = Number(dirtyNumber);

      if (isNaN(number)) {
        return number;
      }

      return number < 0 ? Math.ceil(number) : Math.floor(number);
    }

    module.exports = exports.default;
    },{}],3:[function(require,module,exports){
    "use strict";

    Object.defineProperty(exports, "__esModule", {
      value: true
    });
    exports.default = isValid;

    var _index = _interopRequireDefault(require("../toDate/index.js"));

    function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

    /**
     * @name isValid
     * @category Common Helpers
     * @summary Is the given date valid?
     *
     * @description
     * Returns false if argument is Invalid Date and true otherwise.
     * Argument is converted to Date using `toDate`. See [toDate]{@link https://date-fns.org/docs/toDate}
     * Invalid Date is a Date, whose time value is NaN.
     *
     * Time value of Date: http://es5.github.io/#x15.9.1.1
     *
     * ### v2.0.0 breaking changes:
     *
     * - [Changes that are common for the whole library](https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#Common-Changes).
     *
     * - Now `isValid` doesn't throw an exception
     *   if the first argument is not an instance of Date.
     *   Instead, argument is converted beforehand using `toDate`.
     *
     *   Examples:
     *
     *   | `isValid` argument        | Before v2.0.0 | v2.0.0 onward |
     *   |---------------------------|---------------|---------------|
     *   | `new Date()`              | `true`        | `true`        |
     *   | `new Date('2016-01-01')`  | `true`        | `true`        |
     *   | `new Date('')`            | `false`       | `false`       |
     *   | `new Date(1488370835081)` | `true`        | `true`        |
     *   | `new Date(NaN)`           | `false`       | `false`       |
     *   | `'2016-01-01'`            | `TypeError`   | `true`        |
     *   | `''`                      | `TypeError`   | `false`       |
     *   | `1488370835081`           | `TypeError`   | `true`        |
     *   | `NaN`                     | `TypeError`   | `false`       |
     *
     *   We introduce this change to make *date-fns* consistent with ECMAScript behavior
     *   that try to coerce arguments to the expected type
     *   (which is also the case with other *date-fns* functions).
     *
     * @param {*} date - the date to check
     * @returns {Boolean} the date is valid
     * @throws {TypeError} 1 argument required
     *
     * @example
     * // For the valid date:
     * var result = isValid(new Date(2014, 1, 31))
     * //=> true
     *
     * @example
     * // For the value, convertable into a date:
     * var result = isValid(1393804800000)
     * //=> true
     *
     * @example
     * // For the invalid date:
     * var result = isValid(new Date(''))
     * //=> false
     */
    function isValid(dirtyDate) {
      Iif (arguments.length < 1) {
        throw new TypeError('1 argument required, but only ' + arguments.length + ' present');
      }

      var date = (0, _index.default)(dirtyDate);
      return !isNaN(date);
    }

    module.exports = exports.default;
    },{"../toDate/index.js":5}],4:[function(require,module,exports){
    "use strict";

    Object.defineProperty(exports, "__esModule", {
      value: true
    });
    exports.default = parseISO;

    var _index = _interopRequireDefault(require("../_lib/toInteger/index.js"));

    var _index2 = _interopRequireDefault(require("../_lib/getTimezoneOffsetInMilliseconds/index.js"));

    function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

    var MILLISECONDS_IN_HOUR = 3600000;
    var MILLISECONDS_IN_MINUTE = 60000;
    var DEFAULT_ADDITIONAL_DIGITS = 2;
    var patterns = {
      dateTimeDelimiter: /[T ]/,
      timeZoneDelimiter: /[Z ]/i,
      timezone: /([Z+-].*)$/
    };
    var dateRegex = /^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/;
    var timeRegex = /^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/;
    var timezoneRegex = /^([+-])(\d{2})(?::?(\d{2}))?$/;
    /**
     * @name parseISO
     * @category Common Helpers
     * @summary Parse ISO string
     *
     * @description
     * Parse the given string in ISO 8601 format and return an instance of Date.
     *
     * Function accepts complete ISO 8601 formats as well as partial implementations.
     * ISO 8601: http://en.wikipedia.org/wiki/ISO_8601
     *
     * If the argument isn't a string, the function cannot parse the string or
     * the values are invalid, it returns Invalid Date.
     *
     * ### v2.0.0 breaking changes:
     *
     * - [Changes that are common for the whole library](https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#Common-Changes).
     *
     * - The previous `parse` implementation was renamed to `parseISO`.
     *
     *   ```javascript
     *   // Before v2.0.0
     *   parse('2016-01-01')
     *
     *   // v2.0.0 onward
     *   parseISO('2016-01-01')
     *   ```
     *
     * - `parseISO` now validates separate date and time values in ISO-8601 strings
     *   and returns `Invalid Date` if the date is invalid.
     *
     *   ```javascript
     *   parseISO('2018-13-32')
     *   //=> Invalid Date
     *   ```
     *
     * - `parseISO` now doesn't fall back to `new Date` constructor
     *   if it fails to parse a string argument. Instead, it returns `Invalid Date`.
     *
     * @param {String} argument - the value to convert
     * @param {Object} [options] - an object with options.
     * @param {0|1|2} [options.additionalDigits=2] - the additional number of digits in the extended year format
     * @returns {Date} the parsed date in the local time zone
     * @throws {TypeError} 1 argument required
     * @throws {RangeError} `options.additionalDigits` must be 0, 1 or 2
     *
     * @example
     * // Convert string '2014-02-11T11:30:30' to date:
     * var result = parseISO('2014-02-11T11:30:30')
     * //=> Tue Feb 11 2014 11:30:30
     *
     * @example
     * // Convert string '+02014101' to date,
     * // if the additional number of digits in the extended year format is 1:
     * var result = parseISO('+02014101', { additionalDigits: 1 })
     * //=> Fri Apr 11 2014 00:00:00
     */

    function parseISO(argument, dirtyOptions) {
      Iif (arguments.length < 1) {
        throw new TypeError('1 argument required, but only ' + arguments.length + ' present');
      }

      var options = dirtyOptions || {};
      var additionalDigits = options.additionalDigits == null ? DEFAULT_ADDITIONAL_DIGITS : (0, _index.default)(options.additionalDigits);

      Iif (additionalDigits !== 2 && additionalDigits !== 1 && additionalDigits !== 0) {
        throw new RangeError('additionalDigits must be 0, 1 or 2');
      }

      Iif (!(typeof argument === 'string' || Object.prototype.toString.call(argument) === '[object String]')) {
        return new Date(NaN);
      }

      var dateStrings = splitDateString(argument);
      var date;

      Eif (dateStrings.date) {
        var parseYearResult = parseYear(dateStrings.date, additionalDigits);
        date = parseDate(parseYearResult.restDateString, parseYearResult.year);
      }

      if (isNaN(date) || !date) {
        return new Date(NaN);
      }

      var timestamp = date.getTime();
      var time = 0;
      var offset;

      Iif (dateStrings.time) {
        time = parseTime(dateStrings.time);

        if (isNaN(time) || time === null) {
          return new Date(NaN);
        }
      }

      Iif (dateStrings.timezone) {
        offset = parseTimezone(dateStrings.timezone);

        if (isNaN(offset)) {
          return new Date(NaN);
        }
      } else {
        var fullTime = timestamp + time;
        var fullTimeDate = new Date(fullTime);
        offset = (0, _index2.default)(fullTimeDate); // Adjust time when it's coming from DST

        var fullTimeDateNextDay = new Date(fullTime);
        fullTimeDateNextDay.setDate(fullTimeDate.getDate() + 1);
        var offsetDiff = (0, _index2.default)(fullTimeDateNextDay) - offset;

        Iif (offsetDiff > 0) {
          offset += offsetDiff;
        }
      }

      return new Date(timestamp + time + offset);
    }

    function splitDateString(dateString) {
      var dateStrings = {};
      var array = dateString.split(patterns.dateTimeDelimiter);
      var timeString;

      Iif (/:/.test(array[0])) {
        dateStrings.date = null;
        timeString = array[0];
      } else {
        dateStrings.date = array[0];
        timeString = array[1];

        Iif (patterns.timeZoneDelimiter.test(dateStrings.date)) {
          dateStrings.date = dateString.split(patterns.timeZoneDelimiter)[0];
          timeString = dateString.substr(dateStrings.date.length, dateString.length);
        }
      }

      Iif (timeString) {
        var token = patterns.timezone.exec(timeString);

        if (token) {
          dateStrings.time = timeString.replace(token[1], '');
          dateStrings.timezone = token[1];
        } else {
          dateStrings.time = timeString;
        }
      }

      return dateStrings;
    }

    function parseYear(dateString, additionalDigits) {
      var regex = new RegExp('^(?:(\\d{4}|[+-]\\d{' + (4 + additionalDigits) + '})|(\\d{2}|[+-]\\d{' + (2 + additionalDigits) + '})$)');
      var captures = dateString.match(regex); // Invalid ISO-formatted year

      Iif (!captures) return {
        year: null
      };
      var year = captures[1] && parseInt(captures[1]);
      var century = captures[2] && parseInt(captures[2]);
      return {
        year: century == null ? year : century * 100,
        restDateString: dateString.slice((captures[1] || captures[2]).length)
      };
    }

    function parseDate(dateString, year) {
      // Invalid ISO-formatted year
      Iif (year === null) return null;
      var captures = dateString.match(dateRegex); // Invalid ISO-formatted string

      Iif (!captures) return null;
      var isWeekDate = !!captures[4];
      var dayOfYear = parseDateUnit(captures[1]);
      var month = parseDateUnit(captures[2]) - 1;
      var day = parseDateUnit(captures[3]);
      var week = parseDateUnit(captures[4]);
      var dayOfWeek = parseDateUnit(captures[5]) - 1;

      Iif (isWeekDate) {
        if (!validateWeekDate(year, week, dayOfWeek)) {
          return new Date(NaN);
        }

        return dayOfISOWeekYear(year, week, dayOfWeek);
      } else {
        var date = new Date(0);

        if (!validateDate(year, month, day) || !validateDayOfYearDate(year, dayOfYear)) {
          return new Date(NaN);
        }

        date.setUTCFullYear(year, month, Math.max(dayOfYear, day));
        return date;
      }
    }

    function parseDateUnit(value) {
      return value ? parseInt(value) : 1;
    }

    function parseTime(timeString) {
      var captures = timeString.match(timeRegex);
      if (!captures) return null; // Invalid ISO-formatted time

      var hours = parseTimeUnit(captures[1]);
      var minutes = parseTimeUnit(captures[2]);
      var seconds = parseTimeUnit(captures[3]);

      if (!validateTime(hours, minutes, seconds)) {
        return NaN;
      }

      return hours * MILLISECONDS_IN_HOUR + minutes * MILLISECONDS_IN_MINUTE + seconds * 1000;
    }

    function parseTimeUnit(value) {
      return value && parseFloat(value.replace(',', '.')) || 0;
    }

    function parseTimezone(timezoneString) {
      if (timezoneString === 'Z') return 0;
      var captures = timezoneString.match(timezoneRegex);
      if (!captures) return 0;
      var sign = captures[1] === '+' ? -1 : 1;
      var hours = parseInt(captures[2]);
      var minutes = captures[3] && parseInt(captures[3]) || 0;

      if (!validateTimezone(hours, minutes)) {
        return NaN;
      }

      return sign * (hours * MILLISECONDS_IN_HOUR + minutes * MILLISECONDS_IN_MINUTE);
    }

    function dayOfISOWeekYear(isoWeekYear, week, day) {
      var date = new Date(0);
      date.setUTCFullYear(isoWeekYear, 0, 4);
      var fourthOfJanuaryDay = date.getUTCDay() || 7;
      var diff = (week - 1) * 7 + day + 1 - fourthOfJanuaryDay;
      date.setUTCDate(date.getUTCDate() + diff);
      return date;
    } // Validation functions
    // February is null to handle the leap year (using ||)

    var daysInMonths = [31, null, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];

    function isLeapYearIndex(year) {
      return year % 400 === 0 || year % 4 === 0 && year % 100;
    }

    function validateDate(year, month, date) {
      return month >= 0 && month <= 11 && date >= 1 && date <= (daysInMonths[month] || (isLeapYearIndex(year) ? 29 : 28));
    }

    function validateDayOfYearDate(year, dayOfYear) {
      return dayOfYear >= 1 && dayOfYear <= (isLeapYearIndex(year) ? 366 : 365);
    }

    function validateWeekDate(_year, week, day) {
      return week >= 1 && week <= 53 && day >= 0 && day <= 6;
    }

    function validateTime(hours, minutes, seconds) {
      if (hours === 24) {
        return minutes === 0 && seconds === 0;
      }

      return seconds >= 0 && seconds < 60 && minutes >= 0 && minutes < 60 && hours >= 0 && hours < 25;
    }

    function validateTimezone(_hours, minutes) {
      return minutes >= 0 && minutes <= 59;
    }

    module.exports = exports.default;
    },{"../_lib/getTimezoneOffsetInMilliseconds/index.js":1,"../_lib/toInteger/index.js":2}],5:[function(require,module,exports){
    "use strict";

    Object.defineProperty(exports, "__esModule", {
      value: true
    });
    exports.default = toDate;

    /**
     * @name toDate
     * @category Common Helpers
     * @summary Convert the given argument to an instance of Date.
     *
     * @description
     * Convert the given argument to an instance of Date.
     *
     * If the argument is an instance of Date, the function returns its clone.
     *
     * If the argument is a number, it is treated as a timestamp.
     *
     * If the argument is none of the above, the function returns Invalid Date.
     *
     * **Note**: *all* Date arguments passed to any *date-fns* function is processed by `toDate`.
     *
     * @param {Date|Number} argument - the value to convert
     * @returns {Date} the parsed date in the local time zone
     * @throws {TypeError} 1 argument required
     *
     * @example
     * // Clone the date:
     * const result = toDate(new Date(2014, 1, 11, 11, 30, 30))
     * //=> Tue Feb 11 2014 11:30:30
     *
     * @example
     * // Convert the timestamp to date:
     * const result = toDate(1392098430000)
     * //=> Tue Feb 11 2014 11:30:30
     */
    function toDate(argument) {
      Iif (arguments.length < 1) {
        throw new TypeError('1 argument required, but only ' + arguments.length + ' present');
      }

      var argStr = Object.prototype.toString.call(argument); // Clone the date

      Eif (argument instanceof Date || typeof argument === 'object' && argStr === '[object Date]') {
        // Prevent the date to lose the milliseconds when passed to new Date() in IE10
        return new Date(argument.getTime());
      } else if (typeof argument === 'number' || argStr === '[object Number]') {
        return new Date(argument);
      } else {
        if ((typeof argument === 'string' || argStr === '[object String]') && typeof console !== 'undefined') {
          // eslint-disable-next-line no-console
          console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as arguments. Please use `parseISO` to parse strings. See: https://git.io/fjule"); // eslint-disable-next-line no-console

          console.warn(new Error().stack);
        }

        return new Date(NaN);
      }
    }

    module.exports = exports.default;
    },{}],6:[function(require,module,exports){
    function AsyncResolvers(onFailedOne, onResolvedAll) {
      this.onResolvedAll = onResolvedAll;
      this.onFailedOne = onFailedOne;
      this.resolvers = {};
      this.resolversCount = 0;
      this.passed = [];
      this.failed = [];
      this.firing = false;
    }

    AsyncResolvers.prototype = {

      /**
       * Add resolver
       *
       * @param {Rule} rule
       * @return {integer}
       */
      add: function(rule) {
        var index = this.resolversCount;
        this.resolvers[index] = rule;
        this.resolversCount++;
        return index;
      },

      /**
       * Resolve given index
       *
       * @param  {integer} index
       * @return {void}
       */
      resolve: function(index) {
        var rule = this.resolvers[index];
        if (rule.passes === true) {
          this.passed.push(rule);
        } else Eif (rule.passes === false) {
          this.failed.push(rule);
          this.onFailedOne(rule);
        }

        this.fire();
      },

      /**
       * Determine if all have been resolved
       *
       * @return {boolean}
       */
      isAllResolved: function() {
        return (this.passed.length + this.failed.length) === this.resolversCount;
      },

      /**
       * Attempt to fire final all resolved callback if completed
       *
       * @return {void}
       */
      fire: function() {

        if (!this.firing) {
          return;
        }

        if (this.isAllResolved()) {
          this.onResolvedAll(this.failed.length === 0);
        }

      },

      /**
       * Enable firing
       *
       * @return {void}
       */
      enableFiring: function() {
        this.firing = true;
      }

    };

    module.exports = AsyncResolvers;

    },{}],7:[function(require,module,exports){
    var replacements = {

      /**
       * Between replacement (replaces :min and :max)
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      between: function(template, rule) {
        var parameters = rule.getParameters();
        return this._replacePlaceholders(rule, template, {
          min: parameters[0],
          max: parameters[1]
        });
      },

      /**
       * Digits-Between replacement (replaces :min and :max)
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      digits_between: function(template, rule) {
        var parameters = rule.getParameters();
        return this._replacePlaceholders(rule, template, {
          min: parameters[0],
          max: parameters[1]
        });
      },

      /**
       * Required_if replacement.
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      required_if: function(template, rule) {
        var parameters = rule.getParameters();
        return this._replacePlaceholders(rule, template, {
          other: this._getAttributeName(parameters[0]),
          value: parameters[1]
        });
      },

      /**
       * Required_unless replacement.
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      required_unless: function(template, rule) {
        var parameters = rule.getParameters();
        return this._replacePlaceholders(rule, template, {
          other: this._getAttributeName(parameters[0]),
          value: parameters[1]
        });
      },

      /**
       * Required_with replacement.
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      required_with: function(template, rule) {
        var parameters = rule.getParameters();
        return this._replacePlaceholders(rule, template, {
          field: this._getAttributeName(parameters[0])
        });
      },

      /**
       * Required_with_all replacement.
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      required_with_all: function(template, rule) {
        var parameters = rule.getParameters();
        var getAttributeName = this._getAttributeName.bind(this);
        return this._replacePlaceholders(rule, template, {
          fields: parameters.map(getAttributeName).join(', ')
        });
      },

      /**
       * Required_without replacement.
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      required_without: function(template, rule) {
        var parameters = rule.getParameters();
        return this._replacePlaceholders(rule, template, {
          field: this._getAttributeName(parameters[0])
        });
      },

      /**
       * Required_without_all replacement.
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      required_without_all: function(template, rule) {
        var parameters = rule.getParameters();
        var getAttributeName = this._getAttributeName.bind(this);
        return this._replacePlaceholders(rule, template, {
          fields: parameters.map(getAttributeName).join(', ')
        });
      },

      /**
       * After replacement.
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      after: function(template, rule) {
        var parameters = rule.getParameters();
        return this._replacePlaceholders(rule, template, {
          after: this._getAttributeName(parameters[0])
        });
      },

      /**
       * Before replacement.
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      before: function(template, rule) {
        var parameters = rule.getParameters();
        return this._replacePlaceholders(rule, template, {
          before: this._getAttributeName(parameters[0])
        });
      },

      /**
       * After_or_equal replacement.
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      after_or_equal: function(template, rule) {
        var parameters = rule.getParameters();
        return this._replacePlaceholders(rule, template, {
          after_or_equal: this._getAttributeName(parameters[0])
        });
      },

      /**
       * Before_or_equal replacement.
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      before_or_equal: function(template, rule) {
        var parameters = rule.getParameters();
        return this._replacePlaceholders(rule, template, {
          before_or_equal: this._getAttributeName(parameters[0])
        });
      },

      /**
       * Same replacement.
       *
       * @param  {string} template
       * @param  {Rule} rule
       * @return {string}
       */
      same: function(template, rule) {
        var parameters = rule.getParameters();
        return this._replacePlaceholders(rule, template, {
          same: this._getAttributeName(parameters[0])
        });
      },
    };

    function formatter(attribute) {
      return attribute.replace(/[_\[]/g, ' ').replace(/]/g, '');
    }

    module.exports = {
      replacements: replacements,
      formatter: formatter
    };

    },{}],8:[function(require,module,exports){
    var Errors = function() {
      this.errors = {};
    };

    Errors.prototype = {
      constructor: Errors,

      /**
       * Add new error message for given attribute
       *
       * @param  {string} attribute
       * @param  {string} message
       * @return {void}
       */
      add: function(attribute, message) {
        if (!this.has(attribute)) {
          this.errors[attribute] = [];
        }

        if (this.errors[attribute].indexOf(message) === -1) {
          this.errors[attribute].push(message);
        }
      },

      /**
       * Returns an array of error messages for an attribute, or an empty array
       *
       * @param  {string} attribute A key in the data object being validated
       * @return {array} An array of error messages
       */
      get: function(attribute) {
        if (this.has(attribute)) {
          return this.errors[attribute];
        }

        return [];
      },

      /**
       * Returns the first error message for an attribute, false otherwise
       *
       * @param  {string} attribute A key in the data object being validated
       * @return {string|false} First error message or false
       */
      first: function(attribute) {
        if (this.has(attribute)) {
          return this.errors[attribute][0];
        }

        return false;
      },

      /**
       * Get all error messages from all failing attributes
       *
       * @return {Object} Failed attribute names for keys and an array of messages for values
       */
      all: function() {
        return this.errors;
      },

      /**
       * Determine if there are any error messages for an attribute
       *
       * @param  {string}  attribute A key in the data object being validated
       * @return {boolean}
       */
      has: function(attribute) {
        if (this.errors.hasOwnProperty(attribute)) {
          return true;
        }

        return false;
      }
    };

    module.exports = Errors;

    },{}],9:[function(require,module,exports){
    var Messages = require('./messages');

    require('./lang/en');

    var require_method = require;

    var container = {

      messages: {},

      /**
       * Set messages for language
       *
       * @param {string} lang
       * @param {object} rawMessages
       * @return {void}
       */
      _set: function(lang, rawMessages) {
        this.messages[lang] = rawMessages;
      },

      /**
       * Set message for given language's rule.
       *
       * @param {string} lang
       * @param {string} attribute
       * @param {string|object} message
       * @return {void}
       */
      _setRuleMessage: function(lang, attribute, message) {
        this._load(lang);
        if (message === undefined) {
          message = this.messages[lang].def;
        }

        this.messages[lang][attribute] = message;
      },

      /**
       * Load messages (if not already loaded)
       *
       * @param  {string} lang
       * @return {void}
       */
      _load: function(lang) {
        if (!this.messages[lang]) {
          try {
            var rawMessages = require_method('./lang/' + lang);
            this._set(lang, rawMessages);
          } catch (e) {}
        }
      },

      /**
       * Get raw messages for language
       *
       * @param  {string} lang
       * @return {object}
       */
      _get: function(lang) {
        this._load(lang);
        return this.messages[lang];
      },

      /**
       * Make messages for given language
       *
       * @param  {string} lang
       * @return {Messages}
       */
      _make: function(lang) {
        this._load(lang);
        return new Messages(lang, this.messages[lang]);
      }

    };

    module.exports = container;

    },{"./lang/en":10,"./messages":11}],10:[function(require,module,exports){
    module.exports = {
      accepted: 'The :attribute must be accepted.',
      after: 'The :attribute must be after :after.',
      after_or_equal: 'The :attribute must be equal or after :after_or_equal.',
      alpha: 'The :attribute field must contain only alphabetic characters.',
      alpha_dash: 'The :attribute field may only contain alpha-numeric characters, as well as dashes and underscores.',
      alpha_num: 'The :attribute field must be alphanumeric.',
      before: 'The :attribute must be before :before.',
      before_or_equal: 'The :attribute must be equal or before :before_or_equal.',
      between: 'The :attribute field must be between :min and :max.',
      confirmed: 'The :attribute confirmation does not match.',
      email: 'The :attribute format is invalid.',
      date: 'The :attribute is not a valid date format.',
      def: 'The :attribute attribute has errors.',
      digits: 'The :attribute must be :digits digits.',
      digits_between: 'The :attribute field must be between :min and :max digits.',
      different: 'The :attribute and :different must be different.',
      in: 'The selected :attribute is invalid.',
      integer: 'The :attribute must be an integer.',
      hex: 'The :attribute field should have hexadecimal format',
      min: {
        numeric: 'The :attribute must be at least :min.',
        string: 'The :attribute must be at least :min characters.'
      },
      max: {
        numeric: 'The :attribute may not be greater than :max.',
        string: 'The :attribute may not be greater than :max characters.'
      },
      not_in: 'The selected :attribute is invalid.',
      numeric: 'The :attribute must be a number.',
      present: 'The :attribute field must be present (but can be empty).',
      required: 'The :attribute field is required.',
      required_if: 'The :attribute field is required when :other is :value.',
      required_unless: 'The :attribute field is required when :other is not :value.',
      required_with: 'The :attribute field is required when :field is not empty.',
      required_with_all: 'The :attribute field is required when :fields are not empty.',
      required_without: 'The :attribute field is required when :field is empty.',
      required_without_all: 'The :attribute field is required when :fields are empty.',
      same: 'The :attribute and :same fields must match.',
      size: {
        numeric: 'The :attribute must be :size.',
        string: 'The :attribute must be :size characters.'
      },
      string: 'The :attribute must be a string.',
      url: 'The :attribute format is invalid.',
      regex: 'The :attribute format is invalid.',
      attributes: {}
    };

    },{}],11:[function(require,module,exports){
    var Attributes = require('./attributes');

    var Messages = function(lang, messages) {
      this.lang = lang;
      this.messages = messages;
      this.customMessages = {};
      this.attributeNames = {};
    };

    Messages.prototype = {
      constructor: Messages,

      /**
       * Set custom messages
       *
       * @param {object} customMessages
       * @return {void}
       */
      _setCustom: function(customMessages) {
        this.customMessages = customMessages || {};
      },

      /**
       * Set custom attribute names.
       *
       * @param {object} attributes
       */
      _setAttributeNames: function(attributes) {
        this.attributeNames = attributes;
      },

      /**
       * Set the attribute formatter.
       *
       * @param {fuction} func
       * @return {void}
       */
      _setAttributeFormatter: function(func) {
        this.attributeFormatter = func;
      },

      /**
       * Get attribute name to display.
       *
       * @param  {string} attribute
       * @return {string}
       */
      _getAttributeName: function(attribute) {
        var name = attribute;
        if (this.attributeNames.hasOwnProperty(attribute)) {
          return this.attributeNames[attribute];
        } else Iif (this.messages.attributes.hasOwnProperty(attribute)) {
          name = this.messages.attributes[attribute];
        }

        Eif (this.attributeFormatter) {
          name = this.attributeFormatter(name);
        }

        return name;
      },

      /**
       * Get all messages
       *
       * @return {object}
       */
      all: function() {
        return this.messages;
      },

      /**
       * Render message
       *
       * @param  {Rule} rule
       * @return {string}
       */
      render: function(rule) {
        if (rule.customMessage) {
          return rule.customMessage;
        }
        var template = this._getTemplate(rule);

        var message;
        if (Attributes.replacements[rule.name]) {
          message = Attributes.replacements[rule.name].apply(this, [template, rule]);
        } else {
          message = this._replacePlaceholders(rule, template, {});
        }

        return message;
      },

      /**
       * Get the template to use for given rule
       *
       * @param  {Rule} rule
       * @return {string}
       */
      _getTemplate: function(rule) {

        var messages = this.messages;
        var template = messages.def;
        var customMessages = this.customMessages;
        var formats = [rule.name + '.' + rule.attribute, rule.name];

        for (var i = 0, format; i < formats.length; i++) {
          format = formats[i];
          if (customMessages.hasOwnProperty(format)) {
            template = customMessages[format];
            break;
          } else if (messages.hasOwnProperty(format)) {
            template = messages[format];
            break;
          }
        }

        if (typeof template === 'object') {
          template = template[rule._getValueType()];
        }

        return template;
      },

      /**
       * Replace placeholders in the template using the data object
       *
       * @param  {Rule} rule
       * @param  {string} template
       * @param  {object} data
       * @return {string}
       */
      _replacePlaceholders: function(rule, template, data) {
        var message, attribute;

        data.attribute = this._getAttributeName(rule.attribute);
        data[rule.name] = data[rule.name] || rule.getParameters().join(',');

        Eif (typeof template === 'string' && typeof data === 'object') {
          message = template;

          for (attribute in data) {
            message = message.replace(new RegExp(':' + attribute, 'g'), data[attribute]);
          }
        }

        return message;
      }

    };

    module.exports = Messages;

    },{"./attributes":7}],12:[function(require,module,exports){
    var isDateValid = require('date-fns/isValid');
    var parseISO = require('date-fns/parseISO');

    function leapYear(year) {
      return (year % 4 === 0 && year % 100 !== 0) || year % 400 === 0;
    }

    function isValidDate(inDate) {
      if (inDate instanceof Date) {
        return !isNaN(inDate);
      }

      // reformat if supplied as mm.dd.yyyy (period delimiter)
      if (typeof inDate === 'string') {
        var pos = inDate.indexOf('.');
        if (pos > 0 && pos <= 6) {
          inDate = inDate.replace(/\./g, '-');
        }
        if (inDate.length === 10) {
          return isDateValid(parseISO(inDate));
        }
      }

      var testDate = new Date(inDate);
      var yr = testDate.getFullYear();
      var mo = testDate.getMonth();
      var day = testDate.getDate();

      var daysInMonth = [31, leapYear(yr) ? 29 : 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];

      Iif (yr < 1000) {
        return false;
      }
      if (isNaN(mo)) {
        return false;
      }
      Iif (mo + 1 > 12) {
        return false;
      }
      Iif (isNaN(day)) {
        return false;
      }
      Iif (day > daysInMonth[mo]) {
        return false;
      }

      return true;
    }

    var rules = {
      required: function(val) {
        var str;

        if (val === undefined || val === null) {
          return false;
        }

        str = String(val).replace(/\s/g, '');
        return str.length > 0 ? true : false;
      },

      required_if: function(val, req, attribute) {
        req = this.getParameters();
        Eif (this.validator._objectPath(this.validator.input, req[0]) === req[1]) {
          return this.validator.getRule('required').validate(val);
        }

        return true;
      },

      required_unless: function(val, req, attribute) {
        req = this.getParameters();
        Eif (this.validator._objectPath(this.validator.input, req[0]) !== req[1]) {
          return this.validator.getRule('required').validate(val);
        }

        return true;
      },

      required_with: function(val, req, attribute) {
        Eif (this.validator._objectPath(this.validator.input, req)) {
          return this.validator.getRule('required').validate(val);
        }

        return true;
      },

      required_with_all: function(val, req, attribute) {
        req = this.getParameters();

        for (var i = 0; i < req.length; i++) {
          if (!this.validator._objectPath(this.validator.input, req[i])) {
            return true;
          }
        }

        return this.validator.getRule('required').validate(val);
      },

      required_without: function(val, req, attribute) {
        if (this.validator._objectPath(this.validator.input, req)) {
          return true;
        }

        return this.validator.getRule('required').validate(val);
      },

      required_without_all: function(val, req, attribute) {
        req = this.getParameters();

        for (var i = 0; i < req.length; i++) {
          if (this.validator._objectPath(this.validator.input, req[i])) {
            return true;
          }
        }

        return this.validator.getRule('required').validate(val);
      },

      boolean: function(val) {
        return (
          val === true ||
          val === false ||
          val === 0 ||
          val === 1 ||
          val === '0' ||
          val === '1' ||
          val === 'true' ||
          val === 'false'
        );
      },

      // compares the size of strings
      // with numbers, compares the value
      size: function(val, req, attribute) {
        Eif (val) {
          req = parseFloat(req);

          var size = this.getSize();

          return size === req;
        }

        return true;
      },

      string: function(val, req, attribute) {
        return typeof val === 'string';
      },

      sometimes: function(val) {
        return true;
      },

      /**
       * Compares the size of strings or the value of numbers if there is a truthy value
       */
      min: function(val, req, attribute) {
        var size = this.getSize();
        return size >= req;
      },

      /**
       * Compares the size of strings or the value of numbers if there is a truthy value
       */
      max: function(val, req, attribute) {
        var size = this.getSize();
        return size <= req;
      },

      between: function(val, req, attribute) {
        req = this.getParameters();
        var size = this.getSize();
        var min = parseFloat(req[0], 10);
        var max = parseFloat(req[1], 10);
        return size >= min && size <= max;
      },

      email: function(val) {
        var re = /^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;
        return re.test(val);
      },

      numeric: function(val) {
        var num;

        num = Number(val); // tries to convert value to a number. useful if value is coming from form element

        if (typeof num === 'number' && !isNaN(num) && typeof val !== 'boolean') {
          return true;
        } else {
          return false;
        }
      },

      array: function(val) {
        return val instanceof Array;
      },

      url: function(url) {
        return /https?:\/\/(www\.)?[-a-zA-Z0-9@:%._\+~#=]{1,256}\.[a-z]{2,63}\b([-a-zA-Z0-9@:%_\+.~#?&/=]*)/i.test(url);
      },

      alpha: function(val) {
        return /^[a-zA-Z]+$/.test(val);
      },

      alpha_dash: function(val) {
        return /^[a-zA-Z0-9_\-]+$/.test(val);
      },

      alpha_num: function(val) {
        return /^[a-zA-Z0-9]+$/.test(val);
      },

      same: function(val, req) {
        var val1 = this.validator._flattenObject(this.validator.input)[req];
        var val2 = val;

        if (val1 === val2) {
          return true;
        }

        return false;
      },

      different: function(val, req) {
        var val1 = this.validator._flattenObject(this.validator.input)[req];
        var val2 = val;

        if (val1 !== val2) {
          return true;
        }

        return false;
      },

      in: function(val, req) {
        var list, i;

        Eif (val) {
          list = this.getParameters();
        }

        if (val && !(val instanceof Array)) {
          var localValue = val;

          for (i = 0; i < list.length; i++) {
            if (typeof list[i] === 'string') {
              localValue = String(val);
            }

            if (localValue === list[i]) {
              return true;
            }
          }

          return false;
        }

        Eif (val && val instanceof Array) {
          for (i = 0; i < val.length; i++) {
            if (list.indexOf(val[i]) < 0) {
              return false;
            }
          }
        }

        return true;
      },

      not_in: function(val, req) {
        var list = this.getParameters();
        var len = list.length;
        var returnVal = true;

        for (var i = 0; i < len; i++) {
          var localValue = val;

          if (typeof list[i] === 'string') {
            localValue = String(val);
          }

          if (localValue === list[i]) {
            returnVal = false;
            break;
          }
        }

        return returnVal;
      },

      accepted: function(val) {
        if (val === 'on' || val === 'yes' || val === 1 || val === '1' || val === true) {
          return true;
        }

        return false;
      },

      confirmed: function(val, req, key) {
        var confirmedKey = key + '_confirmation';

        if (this.validator.input[confirmedKey] === val) {
          return true;
        }

        return false;
      },

      integer: function(val) {
        return String(parseInt(val, 10)) === String(val);
      },

      digits: function(val, req) {
        var numericRule = this.validator.getRule('numeric');
        if (numericRule.validate(val) && String(val).length === parseInt(req)) {
          return true;
        }

        return false;
      },

      digits_between: function(val) {
        var numericRule = this.validator.getRule('numeric');
        var req = this.getParameters();
        var valueDigitsCount = String(val).length;
        var min = parseFloat(req[0], 10);
        var max = parseFloat(req[1], 10);

        if (numericRule.validate(val) && valueDigitsCount >= min && valueDigitsCount <= max) {
          return true;
        }

        return false;
      },

      regex: function(val, req) {
        var mod = /[g|i|m]{1,3}$/;
        var flag = req.match(mod);
        flag = flag ? flag[0] : '';
        req = req.replace(mod, '').slice(1, -1);
        req = new RegExp(req, flag);
        return !!req.test(val);
      },

      date: function(val, format) {
        return isValidDate(val);
      },

      present: function(val) {
        return typeof val !== 'undefined';
      },

      after: function(val, req) {
        var val1 = this.validator.input[req];
        var val2 = val;

        Iif (!isValidDate(val1)) {
          return false;
        }
        Iif (!isValidDate(val2)) {
          return false;
        }

        if (new Date(val1).getTime() < new Date(val2).getTime()) {
          return true;
        }

        return false;
      },

      after_or_equal: function(val, req) {
        var val1 = this.validator.input[req];
        var val2 = val;

        Iif (!isValidDate(val1)) {
          return false;
        }
        Iif (!isValidDate(val2)) {
          return false;
        }

        if (new Date(val1).getTime() <= new Date(val2).getTime()) {
          return true;
        }

        return false;
      },

      before: function(val, req) {
        var val1 = this.validator.input[req];
        var val2 = val;

        Iif (!isValidDate(val1)) {
          return false;
        }
        Iif (!isValidDate(val2)) {
          return false;
        }

        if (new Date(val1).getTime() > new Date(val2).getTime()) {
          return true;
        }

        return false;
      },

      before_or_equal: function(val, req) {
        var val1 = this.validator.input[req];
        var val2 = val;

        Iif (!isValidDate(val1)) {
          return false;
        }
        Iif (!isValidDate(val2)) {
          return false;
        }

        if (new Date(val1).getTime() >= new Date(val2).getTime()) {
          return true;
        }

        return false;
      },

      hex: function(val) {
        return /^[0-9a-f]+$/i.test(val);
      }
    };

    var missedRuleValidator = function() {
      throw new Error('Validator `' + this.name + '` is not defined!');
    };
    var missedRuleMessage;

    function Rule(name, fn, async) {
      this.name = name;
      this.fn = fn;
      this.passes = null;
      this._customMessage = undefined;
      this.async = async;
    }

    Rule.prototype = {
      /**
       * Validate rule
       *
       * @param  {mixed} inputValue
       * @param  {mixed} ruleValue
       * @param  {string} attribute
       * @param  {function} callback
       * @return {boolean|undefined}
       */
      validate: function(inputValue, ruleValue, attribute, callback) {
        var _this = this;
        this._setValidatingData(attribute, inputValue, ruleValue);
        if (typeof callback === 'function') {
          this.callback = callback;
          var handleResponse = function(passes, message) {
            _this.response(passes, message);
          };

          if (this.async) {
            return this._apply(inputValue, ruleValue, attribute, handleResponse);
          } else {
            return handleResponse(this._apply(inputValue, ruleValue, attribute));
          }
        }
        return this._apply(inputValue, ruleValue, attribute);
      },

      /**
       * Apply validation function
       *
       * @param  {mixed} inputValue
       * @param  {mixed} ruleValue
       * @param  {string} attribute
       * @param  {function} callback
       * @return {boolean|undefined}
       */
      _apply: function(inputValue, ruleValue, attribute, callback) {
        var fn = this.isMissed() ? missedRuleValidator : this.fn;

        return fn.apply(this, [inputValue, ruleValue, attribute, callback]);
      },

      /**
       * Set validating data
       *
       * @param {string} attribute
       * @param {mixed} inputValue
       * @param {mixed} ruleValue
       * @return {void}
       */
      _setValidatingData: function(attribute, inputValue, ruleValue) {
        this.attribute = attribute;
        this.inputValue = inputValue;
        this.ruleValue = ruleValue;
      },

      /**
       * Get parameters
       *
       * @return {array}
       */
      getParameters: function() {
        var value = [];

        if (typeof this.ruleValue === 'string') {
          value = this.ruleValue.split(',');
        }

        Iif (typeof this.ruleValue === 'number') {
          value.push(this.ruleValue);
        }

        if (this.ruleValue instanceof Array) {
          value = this.ruleValue;
        }

        return value;
      },

      /**
       * Get true size of value
       *
       * @return {integer|float}
       */
      getSize: function() {
        var value = this.inputValue;

        if (value instanceof Array) {
          return value.length;
        }

        if (typeof value === 'number') {
          return value;
        }

        if (this.validator._hasNumericRule(this.attribute)) {
          return parseFloat(value, 10);
        }

        return value.length;
      },

      /**
       * Get the type of value being checked; numeric or string.
       *
       * @return {string}
       */
      _getValueType: function() {
        if (typeof this.inputValue === 'number' || this.validator._hasNumericRule(this.attribute)) {
          return 'numeric';
        }

        return 'string';
      },

      /**
       * Set the async callback response
       *
       * @param  {boolean|undefined} passes  Whether validation passed
       * @param  {string|undefined} message Custom error message
       * @return {void}
       */
      response: function(passes, message) {
        this.passes = passes === undefined || passes === true;
        this._customMessage = message;
        this.callback(this.passes, message);
      },

      /**
       * Set validator instance
       *
       * @param {Validator} validator
       * @return {void}
       */
      setValidator: function(validator) {
        this.validator = validator;
      },

      /**
       * Check if rule is missed
       *
       * @return {boolean}
       */
      isMissed: function() {
        return typeof this.fn !== 'function';
      },

      get customMessage() {
        return this.isMissed() ? missedRuleMessage : this._customMessage;
      }
    };

    var manager = {
      /**
       * List of async rule names
       *
       * @type {Array}
       */
      asyncRules: [],

      /**
       * Implicit rules (rules to always validate)
       *
       * @type {Array}
       */
      implicitRules: [
        'required',
        'required_if',
        'required_unless',
        'required_with',
        'required_with_all',
        'required_without',
        'required_without_all',
        'accepted',
        'present'
      ],

      /**
       * Get rule by name
       *
       * @param  {string} name
       * @param {Validator}
       * @return {Rule}
       */
      make: function(name, validator) {
        var async = this.isAsync(name);
        var rule = new Rule(name, rules[name], async);
        rule.setValidator(validator);
        return rule;
      },

      /**
       * Determine if given rule is async
       *
       * @param  {string}  name
       * @return {boolean}
       */
      isAsync: function(name) {
        for (var i = 0, len = this.asyncRules.length; i < len; i++) {
          if (this.asyncRules[i] === name) {
            return true;
          }
        }
        return false;
      },

      /**
       * Determine if rule is implicit (should always validate)
       *
       * @param {string} name
       * @return {boolean}
       */
      isImplicit: function(name) {
        return this.implicitRules.indexOf(name) > -1;
      },

      /**
       * Register new rule
       *
       * @param  {string}   name
       * @param  {function} fn
       * @return {void}
       */
      register: function(name, fn) {
        rules[name] = fn;
      },

      /**
       * Register new implicit rule
       *
       * @param  {string}   name
       * @param  {function} fn
       * @return {void}
       */
      registerImplicit: function(name, fn) {
        this.register(name, fn);
        this.implicitRules.push(name);
      },

      /**
       * Register async rule
       *
       * @param  {string}   name
       * @param  {function} fn
       * @return {void}
       */
      registerAsync: function(name, fn) {
        this.register(name, fn);
        this.asyncRules.push(name);
      },

      /**
       * Register implicit async rule
       *
       * @param  {string}   name
       * @param  {function} fn
       * @return {void}
       */
      registerAsyncImplicit: function(name, fn) {
        this.registerImplicit(name, fn);
        this.asyncRules.push(name);
      },

      registerMissedRuleValidator: function(fn, message) {
        missedRuleValidator = fn;
        missedRuleMessage = message;
      }
    };

    module.exports = manager;

    },{"date-fns/isValid":3,"date-fns/parseISO":4}],13:[function(require,module,exports){
    var Rules = require('./rules');
    var Lang = require('./lang');
    var Errors = require('./errors');
    var Attributes = require('./attributes');
    var AsyncResolvers = require('./async');

    var Validator = function (input, rules, customMessages) {
      var lang = Validator.getDefaultLang();
      this.input = input || {};

      this.messages = Lang._make(lang);
      this.messages._setCustom(customMessages);
      this.setAttributeFormatter(Validator.prototype.attributeFormatter);

      this.errors = new Errors();
      this.errorCount = 0;

      this.hasAsync = false;
      this.rules = this._parseRules(rules);
    };

    Validator.prototype = {

      constructor: Validator,

      /**
       * Default language
       *
       * @type {string}
       */
      lang: 'en',

      /**
       * Numeric based rules
       *
       * @type {array}
       */
      numericRules: ['integer', 'numeric'],

      /**
       * Attribute formatter.
       *
       * @type {function}
       */
      attributeFormatter: Attributes.formatter,

      /**
       * Run validator
       *
       * @return {boolean} Whether it passes; true = passes, false = fails
       */
      check: function () {
        var self = this;

        for (var attribute in this.rules) {
          var attributeRules = this.rules[attribute];
          var inputValue = this._objectPath(this.input, attribute);

          if (this._hasRule(attribute, ['sometimes']) && !this._suppliedWithData(attribute)) {
            continue;
          }

          for (var i = 0, len = attributeRules.length, rule, ruleOptions, rulePassed; i < len; i++) {
            ruleOptions = attributeRules[i];
            rule = this.getRule(ruleOptions.name);

            if (!this._isValidatable(rule, inputValue)) {
              continue;
            }

            rulePassed = rule.validate(inputValue, ruleOptions.value, attribute);
            if (!rulePassed) {
              this._addFailure(rule);
            }

            if (this._shouldStopValidating(attribute, rulePassed)) {
              break;
            }
          }
        }

        return this.errorCount === 0;
      },

      /**
       * Run async validator
       *
       * @param {function} passes
       * @param {function} fails
       * @return {void}
       */
      checkAsync: function (passes, fails) {
        var _this = this;
        passes = passes || function () {};
        fails = fails || function () {};

        var failsOne = function (rule, message) {
          _this._addFailure(rule, message);
        };

        var resolvedAll = function (allPassed) {
          if (allPassed) {
            passes();
          } else {
            fails();
          }
        };

        var asyncResolvers = new AsyncResolvers(failsOne, resolvedAll);

        var validateRule = function (inputValue, ruleOptions, attribute, rule) {
          return function () {
            var resolverIndex = asyncResolvers.add(rule);
            rule.validate(inputValue, ruleOptions.value, attribute, function () {
              asyncResolvers.resolve(resolverIndex);
            });
          };
        };

        for (var attribute in this.rules) {
          var attributeRules = this.rules[attribute];
          var inputValue = this._objectPath(this.input, attribute);

          if (this._hasRule(attribute, ['sometimes']) && !this._suppliedWithData(attribute)) {
            continue;
          }

          for (var i = 0, len = attributeRules.length, rule, ruleOptions; i < len; i++) {
            ruleOptions = attributeRules[i];

            rule = this.getRule(ruleOptions.name);

            Iif (!this._isValidatable(rule, inputValue)) {
              continue;
            }

            validateRule(inputValue, ruleOptions, attribute, rule)();
          }
        }

        asyncResolvers.enableFiring();
        asyncResolvers.fire();
      },

      /**
       * Add failure and error message for given rule
       *
       * @param {Rule} rule
       */
      _addFailure: function (rule) {
        var msg = this.messages.render(rule);
        this.errors.add(rule.attribute, msg);
        this.errorCount++;
      },

      /**
       * Flatten nested object, normalizing { foo: { bar: 1 } } into: { 'foo.bar': 1 }
       *
       * @param  {object} nested object
       * @return {object} flattened object
       */
      _flattenObject: function (obj) {
        var flattened = {};

        function recurse(current, property) {
          if (!property && Object.getOwnPropertyNames(current).length === 0) {
            return;
          }
          if (Object(current) !== current || Array.isArray(current)) {
            flattened[property] = current;
          } else {
            var isEmpty = true;
            for (var p in current) {
              isEmpty = false;
              recurse(current[p], property ? property + '.' + p : p);
            }
            if (isEmpty) {
              flattened[property] = {};
            }
          }
        }
        if (obj) {
          recurse(obj);
        }
        return flattened;
      },

      /**
       * Extract value from nested object using string path with dot notation
       *
       * @param  {object} object to search in
       * @param  {string} path inside object
       * @return {any|void} value under the path
       */
      _objectPath: function (obj, path) {
        if (Object.prototype.hasOwnProperty.call(obj, path)) {
          return obj[path];
        }

        var keys = path.replace(/\[(\w+)\]/g, '.$1').replace(/^\./, '').split('.');
        var copy = {};
        for (var attr in obj) {
          Eif (Object.prototype.hasOwnProperty.call(obj, attr)) {
            copy[attr] = obj[attr];
          }
        }

        for (var i = 0, l = keys.length; i < l; i++) {
          if (typeof copy === 'object' && copy !== null && Object.hasOwnProperty.call(copy, keys[i])) {
            copy = copy[keys[i]];
          } else {
            return;
          }
        }
        return copy;
      },

      /**
       * Parse rules, normalizing format into: { attribute: [{ name: 'age', value: 3 }] }
       *
       * @param  {object} rules
       * @return {object}
       */
      _parseRules: function (rules) {

        var parsedRules = {};
        rules = this._flattenObject(rules);

        for (var attribute in rules) {

          var rulesArray = rules[attribute];

          this._parseRulesCheck(attribute, rulesArray, parsedRules);
        }
        return parsedRules;

      },

      _parseRulesCheck: function (attribute, rulesArray, parsedRules, wildCardValues) {
        if (attribute.indexOf('*') > -1) {
          this._parsedRulesRecurse(attribute, rulesArray, parsedRules, wildCardValues);
        } else {
          this._parseRulesDefault(attribute, rulesArray, parsedRules, wildCardValues);
        }
      },

      _parsedRulesRecurse: function (attribute, rulesArray, parsedRules, wildCardValues) {
        var parentPath = attribute.substr(0, attribute.indexOf('*') - 1);
        var propertyValue = this._objectPath(this.input, parentPath);

        Eif (propertyValue) {
          for (var propertyNumber = 0; propertyNumber < propertyValue.length; propertyNumber++) {
            var workingValues = wildCardValues ? wildCardValues.slice() : [];
            workingValues.push(propertyNumber);
            this._parseRulesCheck(attribute.replace('*', propertyNumber), rulesArray, parsedRules, workingValues);
          }
        }
      },

      _parseRulesDefault: function (attribute, rulesArray, parsedRules, wildCardValues) {
        var attributeRules = [];

        if (rulesArray instanceof Array) {
          rulesArray = this._prepareRulesArray(rulesArray);
        }

        if (typeof rulesArray === 'string') {
          rulesArray = rulesArray.split('|');
        }

        for (var i = 0, len = rulesArray.length, rule; i < len; i++) {
          rule = typeof rulesArray[i] === 'string' ? this._extractRuleAndRuleValue(rulesArray[i]) : rulesArray[i];
          if (rule.value) {
            rule.value = this._replaceWildCards(rule.value, wildCardValues);
            this._replaceWildCardsMessages(wildCardValues);
          }

          if (Rules.isAsync(rule.name)) {
            this.hasAsync = true;
          }
          attributeRules.push(rule);
        }

        parsedRules[attribute] = attributeRules;
      },

      _replaceWildCards: function (path, nums) {

        if (!nums) {
          return path;
        }

        var path2 = path;
        nums.forEach(function (value) {
          Iif(Array.isArray(path2)){
            path2 = path2[0];
          }
          const pos = path2.indexOf('*');
          if (pos === -1) {
            return path2;
          }
          path2 = path2.substr(0, pos) + value + path2.substr(pos + 1);
        });
        Iif(Array.isArray(path)){
          path[0] = path2;
          path2 = path;
        }
        return path2;
      },

      _replaceWildCardsMessages: function (nums) {
        var customMessages = this.messages.customMessages;
        var self = this;
        Object.keys(customMessages).forEach(function (key) {
          if (nums) {
            var newKey = self._replaceWildCards(key, nums);
            customMessages[newKey] = customMessages[key];
          }
        });

        this.messages._setCustom(customMessages);
      },
      /**
       * Prepare rules if it comes in Array. Check for objects. Need for type validation.
       *
       * @param  {array} rulesArray
       * @return {array}
       */
      _prepareRulesArray: function (rulesArray) {
        var rules = [];

        for (var i = 0, len = rulesArray.length; i < len; i++) {
          if (typeof rulesArray[i] === 'object') {
            for (var rule in rulesArray[i]) {
              rules.push({
                name: rule,
                value: rulesArray[i][rule]
              });
            }
          } else {
            rules.push(rulesArray[i]);
          }
        }

        return rules;
      },

      /**
       * Determines if the attribute is supplied with the original data object.
       *
       * @param  {array} attribute
       * @return {boolean}
       */
      _suppliedWithData: function (attribute) {
        return this.input.hasOwnProperty(attribute);
      },

      /**
       * Extract a rule and a value from a ruleString (i.e. min:3), rule = min, value = 3
       *
       * @param  {string} ruleString min:3
       * @return {object} object containing the name of the rule and value
       */
      _extractRuleAndRuleValue: function (ruleString) {
        var rule = {},
          ruleArray;

        rule.name = ruleString;

        if (ruleString.indexOf(':') >= 0) {
          ruleArray = ruleString.split(':');
          rule.name = ruleArray[0];
          rule.value = ruleArray.slice(1).join(':');
        }

        return rule;
      },

      /**
       * Determine if attribute has any of the given rules
       *
       * @param  {string}  attribute
       * @param  {array}   findRules
       * @return {boolean}
       */
      _hasRule: function (attribute, findRules) {
        var rules = this.rules[attribute] || [];
        for (var i = 0, len = rules.length; i < len; i++) {
          if (findRules.indexOf(rules[i].name) > -1) {
            return true;
          }
        }
        return false;
      },

      /**
       * Determine if attribute has any numeric-based rules.
       *
       * @param  {string}  attribute
       * @return {Boolean}
       */
      _hasNumericRule: function (attribute) {
        return this._hasRule(attribute, this.numericRules);
      },

      /**
       * Determine if rule is validatable
       *
       * @param  {Rule}   rule
       * @param  {mixed}  value
       * @return {boolean}
       */
      _isValidatable: function (rule, value) {
        if (Rules.isImplicit(rule.name)) {
          return true;
        }

        return this.getRule('required').validate(value);
      },

      /**
       * Determine if we should stop validating.
       *
       * @param  {string} attribute
       * @param  {boolean} rulePassed
       * @return {boolean}
       */
      _shouldStopValidating: function (attribute, rulePassed) {

        var stopOnAttributes = this.stopOnAttributes;
        if (typeof stopOnAttributes === 'undefined' || stopOnAttributes === false || rulePassed === true) {
          return false;
        }

        if (stopOnAttributes instanceof Array) {
          return stopOnAttributes.indexOf(attribute) > -1;
        }

        return true;
      },

      /**
       * Set custom attribute names.
       *
       * @param {object} attributes
       * @return {void}
       */
      setAttributeNames: function (attributes) {
        this.messages._setAttributeNames(attributes);
      },

      /**
       * Set the attribute formatter.
       *
       * @param {fuction} func
       * @return {void}
       */
      setAttributeFormatter: function (func) {
        this.messages._setAttributeFormatter(func);
      },

      /**
       * Get validation rule
       *
       * @param  {string} name
       * @return {Rule}
       */
      getRule: function (name) {
        return Rules.make(name, this);
      },

      /**
       * Stop on first error.
       *
       * @param  {boolean|array} An array of attributes or boolean true/false for all attributes.
       * @return {void}
       */
      stopOnError: function (attributes) {
        this.stopOnAttributes = attributes;
      },

      /**
       * Determine if validation passes
       *
       * @param {function} passes
       * @return {boolean|undefined}
       */
      passes: function (passes) {
        var async = this._checkAsync('passes', passes);
        if (async) {
          return this.checkAsync(passes);
        }
        return this.check();
      },

      /**
       * Determine if validation fails
       *
       * @param {function} fails
       * @return {boolean|undefined}
       */
      fails: function (fails) {
        var async = this._checkAsync('fails', fails);
        if (async) {
          return this.checkAsync(function () {}, fails);
        }
        return !this.check();
      },

      /**
       * Check if validation should be called asynchronously
       *
       * @param  {string}   funcName Name of the caller
       * @param  {function} callback
       * @return {boolean}
       */
      _checkAsync: function (funcName, callback) {
        var hasCallback = typeof callback === 'function';
        Iif (this.hasAsync && !hasCallback) {
          throw funcName + ' expects a callback when async rules are being tested.';
        }

        return this.hasAsync || hasCallback;
      }

    };

    /**
     * Set messages for language
     *
     * @param {string} lang
     * @param {object} messages
     * @return {this}
     */
    Validator.setMessages = function (lang, messages) {
      Lang._set(lang, messages);
      return this;
    };

    /**
     * Get messages for given language
     *
     * @param  {string} lang
     * @return {Messages}
     */
    Validator.getMessages = function (lang) {
      return Lang._get(lang);
    };

    /**
     * Set default language to use
     *
     * @param {string} lang
     * @return {void}
     */
    Validator.useLang = function (lang) {
      this.prototype.lang = lang;
    };

    /**
     * Get default language
     *
     * @return {string}
     */
    Validator.getDefaultLang = function () {
      return this.prototype.lang;
    };

    /**
     * Set the attribute formatter.
     *
     * @param {fuction} func
     * @return {void}
     */
    Validator.setAttributeFormatter = function (func) {
      this.prototype.attributeFormatter = func;
    };

    /**
     * Stop on first error.
     *
     * @param  {boolean|array} An array of attributes or boolean true/false for all attributes.
     * @return {void}
     */
    Validator.stopOnError = function (attributes) {
      this.prototype.stopOnAttributes = attributes;
    };

    /**
     * Register custom validation rule
     *
     * @param  {string}   name
     * @param  {function} fn
     * @param  {string}   message
     * @return {void}
     */
    Validator.register = function (name, fn, message) {
      var lang = Validator.getDefaultLang();
      Rules.register(name, fn);
      Lang._setRuleMessage(lang, name, message);
    };

    /**
     * Register custom validation rule
     *
     * @param  {string}   name
     * @param  {function} fn
     * @param  {string}   message
     * @return {void}
     */
    Validator.registerImplicit = function (name, fn, message) {
      var lang = Validator.getDefaultLang();
      Rules.registerImplicit(name, fn);
      Lang._setRuleMessage(lang, name, message);
    };

    /**
     * Register asynchronous validation rule
     *
     * @param  {string}   name
     * @param  {function} fn
     * @param  {string}   message
     * @return {void}
     */
    Validator.registerAsync = function (name, fn, message) {
      var lang = Validator.getDefaultLang();
      Rules.registerAsync(name, fn);
      Lang._setRuleMessage(lang, name, message);
    };

    /**
     * Register asynchronous validation rule
     *
     * @param  {string}   name
     * @param  {function} fn
     * @param  {string}   message
     * @return {void}
     */
    Validator.registerAsyncImplicit = function (name, fn, message) {
      var lang = Validator.getDefaultLang();
      Rules.registerAsyncImplicit(name, fn);
      Lang._setRuleMessage(lang, name, message);
    };

    /**
     * Register validator for missed validation rule
     *
     * @param  {string}   name
     * @param  {function} fn
     * @param  {string}   message
     * @return {void}
     */
    Validator.registerMissedRuleValidator = function(fn, message) {
      Rules.registerMissedRuleValidator(fn, message);
    };

    module.exports = Validator;

    },{"./async":6,"./attributes":7,"./errors":8,"./lang":9,"./rules":12}]},{},[13])(13)
    });