summaryrefslogtreecommitdiff
path: root/views/profile.ejs
blob: d3ae10e8bec5bf1eaf6dcca866bb7c321dc532c9 (plain)
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
<!doctype html>
<html>
<head>
	<title>VValls | [[- profile.displayName ]]</title>
	[[ include partials/meta ]]
</head>
<body class="loading">
<div class="rapper page">
	[[- include partials/header ]]
	
	<div class="profilepage">
		[[ if (profile.photo && profile.photo.length) { ]]
		<div class="profilePic" style="background-image:url([[- profile.photo ]])">
		</div>
		[[ } else { ]]
		<div class="profilePic noPic">
			<span class="holder">
			<span class="ion-ios-person-outline"></span>
			[[ if (isOwnProfile) { ]]
				<div>click to add profile pic</div>
				<input id="profile_avatar" name="avatar" class="element file" type="file"> 
			[[ } ]]
			</span>
		</div>
		[[ } ]]
		<div class="bio">
			<div class="holder">
			<h2>[[- profile.displayName ]]</h2>
			[[ if (profile.location) { ]]
			<span>
				[[- profile.location ]]
			</span>
			[[ } ]]
			[[ if (profile.website && profile.website.length) { ]]
			<span>
				<a href="[[- profile.website ]]" target="_blank">[[- profile.website ]]</a>
			</span>
			[[ } ]]
			[[ if (profile.twitterName && profile.twitterName.length) { ]]
			<span>
				<a href="https://twitter.com/[[- profile.twitterName ]]" target="_blank">@[[- profile.twitterName ]]</a>
			</span>
			[[ } ]]
			[[ if (profile.plan_level == 1) { ]]
				<span class="plan_level premium">PREMIUM</span>
			[[ } else if (profile.plan_level == 2) { ]]
				<span class="plan_level pro">PRO</span>
			[[ } ]]
		</div>
	</div>

	[[ if (projects.length) { ]]

		<h1>[[- profile.username ]] has [[- projectCount ]] project[[- projectCount != 1 ? "s" : "" ]]</h1>
    [[ include projects/list-projects ]]

  [[ } else { ]]

    <h1>Welcome to VVALLS</h1>
    <div class="projectList about">
    	<h2>
				VValls lets you create awesome 3D rooms. 
			</h2>
			
			[[ if (isOwnProfile) { ]]
        <h2>
          You don't have any projects yet.
        </h2>
        <h2>
          <a href="#"class="btn" data-role="new-project-modal">Create a New Project</a>
        </h2>
			[[ } else { ]]
			  <h2><a href="/" class="homeLink">Learn more about VValls</a></h2>
			  <h3>This person has no projects.</h3>
			[[ } ]]
		</div>

	[[ } ]]

	</div>
<!-- 
	[[ include partials/edit-subscription ]]
 -->
	[[ include partials/edit-profile ]]
	[[ include projects/layouts-modal ]]	
	[[ include projects/edit-project ]]
	[[ include partials/sign-in ]]
	[[ include partials/confirm-modal ]]
	[[ include partials/footer ]]

</div>


</body>
[[ include partials/scripts ]]
</html>