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
|
// @flow
import * as React from 'react';
import { Component, Text, View, Styles } from 'reactxp';
import { colors } from '../config';
const styles = {
header: {
default: Styles.createViewStyle({
flexGrow: 0,
flexShrink: 0,
flexBasis: 'auto',
paddingTop: 16,
paddingRight: 24,
paddingLeft: 24,
paddingBottom: 24,
}),
linux: Styles.createViewStyle({
WebkitAppRegion: 'drag',
}),
},
title: Styles.createTextStyle({
fontFamily: 'DINPro',
fontSize: 32,
fontWeight: '900',
lineHeight: 40,
color: colors.white,
}),
subtitle: Styles.createTextStyle({
marginTop: 4,
fontFamily: 'Open Sans',
fontSize: 13,
fontWeight: '600',
overflow: 'visible',
color: colors.white80,
lineHeight: 20,
letterSpacing: -0.2,
}),
};
export default class SettingsHeader extends Component {
render() {
return (
<View style={[styles.header.default, styles.header[process.platform], this.props.style]}>
{this.props.children}
</View>
);
}
}
export class HeaderTitle extends Component {
render() {
return <Text style={[styles.title]}>{this.props.children}</Text>;
}
}
export class HeaderSubTitle extends Component {
render() {
return <Text style={[styles.subtitle]}>{this.props.children}</Text>;
}
}
|