1
1
/*global BUILD_DATE*/
2
2
import React from "react" ;
3
3
import PropTypes from "prop-types" ;
4
+ import "./Version.scss"
4
5
5
6
const getLink = ( version ) => (
6
7
( / ^ v \d + \. \d + \. \d + $ / . test ( version ) ) ?
@@ -10,17 +11,29 @@ const getLink = (version) => (
10
11
11
12
const Version = ( { version, MTGJSONVersion, boosterRulesVersion} ) => {
12
13
return (
13
- < p > Running Version: { " " }
14
- < a href = { `https://github.com/dr4fters/dr4ft/${ getLink ( version ) } ` } >
15
- { version }
16
- </ a > (build { BUILD_DATE } ) - Using < a href = "https://www.mtgjson.com" > MTGJSON</ a > { " " }
17
- card data { " " }
18
- < a href = { `https://mtgjson.com/changelog/version-5/#_${ MTGJSONVersion . version . replace ( / \. / g, "-" ) } ` } >
19
- v{ MTGJSONVersion . version }
20
- </ a > ({ MTGJSONVersion . date } ) and < a href = { "https://github.com/taw/magic-sealed-data" } > Magic Sealed Data</ a > { " " }
21
- booster rules{ " " }
22
- commit < a href = { `https://github.com/taw/magic-sealed-data/commit/${ boosterRulesVersion } ` } > { boosterRulesVersion . substring ( 0 , 7 ) } </ a >
23
- </ p >
14
+ < div className = "Version" >
15
+ < div >
16
+ dr4ft version: { " " }
17
+ < a href = { `https://github.com/dr4fters/dr4ft/${ getLink ( version ) } ` } className = 'code' >
18
+ < code > { version } </ code >
19
+ </ a > < span className = 'date' > ({ BUILD_DATE } )</ span >
20
+ </ div >
21
+
22
+ < div >
23
+ Card data: < a href = "https://www.mtgjson.com" > MTGJSON</ a > { " " }
24
+ < a href = { `https://mtgjson.com/changelog/version-5/#_${ MTGJSONVersion . version . replace ( / \. / g, "-" ) } ` } className = 'code' >
25
+ < code > v{ MTGJSONVersion . version } </ code >
26
+ </ a > < span className = 'date' > ({ MTGJSONVersion . date } )</ span >
27
+ </ div >
28
+
29
+ < div >
30
+ Booster rules: { " " }
31
+ < a href = { "https://github.com/taw/magic-sealed-data" } > Magic Sealed Data</ a > { " " }
32
+ < a href = { `https://github.com/taw/magic-sealed-data/commit/${ boosterRulesVersion } ` } className = 'code' >
33
+ < code > { boosterRulesVersion . substring ( 0 , 7 ) } </ code >
34
+ </ a >
35
+ </ div >
36
+ </ div >
24
37
) ;
25
38
} ;
26
39
0 commit comments