Changes in / [ded7d95:0b6c6fc] in OpenWorkouts-current
- Location:
- ow
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
ow/static/css/main.css
rded7d95 r0b6c6fc 663 663 border-radius: 4px; 664 664 padding: 0; 665 width: auto; 666 background-color: white; 665 667 } 666 668 .workout-options li { … … 1009 1011 font-size: 13px; 1010 1012 font-size: 0.8125rem; 1013 margin-right: 2em; 1011 1014 } 1012 1015 .user-profile-account { 1013 1016 background-color: #fbfbfb; 1017 border-bottom: 1px solid #e1e1e1; 1014 1018 padding: 2em 1em; 1015 1019 } … … 1018 1022 padding: 2em 6em; 1019 1023 } 1024 } 1025 .user-profile-account > div { 1026 display: flex; 1027 align-items: center; 1020 1028 } 1021 1029 .user-profile-account img { … … 1025 1033 border-radius: 50%; 1026 1034 margin-bottom: 0.5em; 1035 margin-right: 1em; 1027 1036 } 1028 1037 .user-profile-account h2 { … … 1030 1039 font-size: 21px; 1031 1040 font-size: 1.3125rem; 1041 font-weight: 400; 1032 1042 } 1033 1043 .user-profile-account p { … … 1050 1060 font-size: 14px; 1051 1061 font-size: 0.875rem; 1062 background-color: white; 1063 padding: 0.5em 0.75em; 1064 border-radius: 4px; 1065 border: 1px solid #e1e1e1; 1052 1066 } 1053 1067 .profile-data li { 1054 margin-bottom: 0.25em; 1068 display: flex; 1069 justify-content: space-between; 1070 color: #959595; 1071 } 1072 .profile-data li:not(:last-child) { 1073 margin-bottom: 0.5em; 1074 padding-bottom: 0.5em; 1075 border-bottom: 1px solid #e1e1e1; 1076 } 1077 .profile-data li span { 1078 font-weight: bold; 1079 color: #151515; 1055 1080 } 1056 1081 .profile-bio { 1057 margin: 1em 0; 1082 margin: 0.5em 0; 1083 font-size: 14px; 1084 font-size: 0.875rem; 1058 1085 } 1059 1086 .month-stats, 1060 1087 .latest-workouts { 1061 max-width: 40vw; 1062 margin: 0 auto; 1088 max-width: 700px; 1089 } 1090 .center { 1091 text-align: center; 1092 } 1093 .month-stats { 1094 margin-bottom: 4em; 1063 1095 } 1064 1096 .latest-workouts h4 { -
ow/static/less/modules/workout.less
rded7d95 r0b6c6fc 122 122 border-radius: 4px; 123 123 padding: 0; 124 width: auto; 125 background-color: white; 124 126 li{ 125 127 display: inline-block; -
ow/static/less/pages/profile.less
rded7d95 r0b6c6fc 2 2 .workout-options { 3 3 .font-size(13); 4 margin-right: 2em; 4 5 } 5 6 } … … 7 8 .user-profile-account { 8 9 background-color: @color-main-xtralight; 10 border-bottom: 1px solid @color-main-light; 9 11 padding: 2em 1em; 10 12 @media (min-width: @screen-s){ 11 13 padding: 2em 6em; 14 } 15 >div { 16 display: flex; 17 align-items: center; 12 18 } 13 19 img { … … 17 23 border-radius: 50%; 18 24 margin-bottom: .5em; 25 margin-right: 1em; 19 26 } 20 27 h2 { 21 28 margin: 0 0 .15em 0; 22 29 .font-size(21); 30 font-weight: 400; 23 31 } 24 32 p{ … … 40 48 padding: 0; 41 49 .font-size(14); 50 background-color: white; 51 padding: .5em .75em; 52 border-radius: 4px; 53 border: 1px solid @color-main-light; 42 54 li { 43 margin-bottom: .25em; 55 display: flex; 56 justify-content: space-between; 57 color: @color-main-medium; 58 &:not(:last-child) { 59 margin-bottom: .5em; 60 padding-bottom: .5em; 61 border-bottom: 1px solid @color-main-light; 62 } 63 span { 64 font-weight: bold; 65 color: @color-main; 66 } 44 67 } 45 68 } 46 69 47 70 .profile-bio { 48 margin: 1em 0; 71 margin: .5em 0; 72 .font-size(14); 49 73 } 50 74 51 75 .month-stats, 52 76 .latest-workouts { 53 max-width: 40vw; 54 margin: 0 auto; 77 max-width: 700px 78 } 79 80 .center { 81 text-align: center; 82 } 83 84 .month-stats { 85 margin-bottom: 4em; 55 86 } 56 87 -
ow/templates/profile.pt
rded7d95 r0b6c6fc 16 16 <div class="user-profile"> 17 17 <div class="user-profile-account"> 18 <tal:c tal:condition="getattr(context, 'picture', None)"> 19 <img tal:attributes="src request.resource_path(context, 'picture')" 20 width="450" /> 21 </tal:c> 22 <h2> 23 <tal:fullname tal:content="context.fullname"></tal:fullname> 24 </h2> 25 <p> 26 <tal:has-nickname tal:condition="context.nickname"> 27 <tal:nickname tal:content="context.nickname"></tal:nickname> 28 </tal:has-nickname> | 29 <span><tal:email tal:content="context.email"></tal:email></span> 30 </p> 18 <div> 19 <tal:c tal:condition="getattr(context, 'picture', None)"> 20 <img tal:attributes="src request.resource_path(context, 'picture')" 21 width="450" /> 22 </tal:c> 23 <div> 24 <h2> 25 <tal:fullname tal:content="context.fullname"></tal:fullname> 26 </h2> 27 <p> 28 <tal:has-nickname tal:condition="context.nickname"> 29 <tal:nickname tal:content="context.nickname"></tal:nickname> 30 </tal:has-nickname> | 31 <span><tal:email tal:content="context.email"></tal:email></span> 32 </p> 33 <div class="profile-bio" tal:content="getattr(context, 'bio', '')"></div> 34 <ul class="workout-options"> 35 <li><a href="" 36 tal:attributes="href request.resource_url(context, 'edit')" 37 i18n:translate="">edit profile</a></li> 38 <li><a href="" 39 tal:attributes="href request.resource_url(context, 'passwd')" 40 i18n:translate="">change password</a></li> 41 </ul> 42 </div> 43 </div> 31 44 32 <div class="profile-bio" tal:content="getattr(context, 'bio', '')"></div>33 34 <ul class="profile-data">35 <li>36 <tal:t i18n:translate="">Gender:</tal:t>37 <tal:c tal:content="getattr(context, 'gender', '-')"></tal:c>38 </li>39 <li tal:define="birth_date getattr(context, 'birth_date', None)">40 <tal:t i18n:translate="">Birth date:</tal:t>41 <tal:c tal:condition="birth_date"42 tal:content="birth_date.strftime('%d/%m/%Y')"></tal:c>43 <tal:c tal:condition="birth_date is None">-</tal:c>44 </li>45 <li>46 <tal:t i18n:translate="">Height:</tal:t>47 <tal:c tal:content="getattr(context, 'height', '-')"></tal:c> meters48 </li>49 <li>50 <tal:t i18n:translate="">Weight:</tal:t>51 <tal:c tal:content="getattr(context, 'weight', '-')"></tal:c> kg52 </li>53 </ul>54 <ul class="workout-options">55 <li><a href=""56 tal:attributes="href request.resource_url(context, 'edit')"57 i18n:translate="">edit profile</a></li>58 <li><a href=""59 tal:attributes="href request.resource_url(context, 'passwd')"60 i18n:translate="">change password</a></li>61 </ul>62 45 </div> 63 46 64 <div class="total-workouts"> 65 <tal:w tal:replace="context.num_workouts"></tal:w> 66 <tal:t i18n:translate="">workouts</tal:t> 67 </div> 47 <div class="workout-content"> 48 <div class="workout-list"> 49 <div class="total-workouts"> 50 <tal:w tal:replace="context.num_workouts"></tal:w> 51 <tal:t i18n:translate="">workouts</tal:t> 52 </div> 68 53 69 <div class="month-stats js-month-stats"> 70 <div class="svg-cotent"> 71 <svg width="800" height="180" viewBox="0 0 800 180"></svg> 72 </div> 73 <ul class="workout-options filters js-filters"> 74 <li><a href="#" class="js-distance is-active" i18n:translate="">distance</a></li> 75 <li><a href="#" class="js-time" i18n:translate="">time</a></li> 76 <li><a href="#" class="js-elevation" i18n:translate="">elevation</a></li> 77 </ul> 54 <div class="month-stats js-month-stats"> 55 <div class="svg-cotent"> 56 <svg width="900" height="180" viewBox="0 0 900 180"></svg> 57 </div> 58 <div class="center"> 59 <ul class="workout-options filters js-filters"> 60 <li><a href="#" class="js-distance is-active" i18n:translate="">distance</a></li> 61 <li><a href="#" class="js-time" i18n:translate="">time</a></li> 62 <li><a href="#" class="js-elevation" i18n:translate="">elevation</a></li> 63 </ul> 78 64 79 <ul class="workout-options switcher js-switcher"> 80 <li><a href="#" class="js-weekly" i18n:translate="">weekly</a></li> 81 <li><a href="#" class="js-monthly is-active" i18n:translate="">monthly</a></li> 82 </ul> 83 </div> 65 <ul class="workout-options switcher js-switcher"> 66 <li><a href="#" class="js-weekly" i18n:translate="">weekly</a></li> 67 <li><a href="#" class="js-monthly is-active" i18n:translate="">monthly</a></li> 68 </ul> 69 </div> 70 </div> 84 71 85 72 86 <tal:r tal:repeat="workout workouts">73 <tal:r tal:repeat="workout workouts"> 87 74 88 <a name="workouts"></a>75 <article class="workout-resume"> 89 76 77 <h2 class="workout-title"> 78 <a href="" tal:content="workout.title" 79 tal:attributes="href request.resource_url(workout)"></a> 80 </h2> 90 81 91 <article class="workout-resume"> 82 <ul class="workout-info"> 83 <li> 84 <tal:c tal:content="workout.start_in_timezone(context.timezone)"></tal:c> 85 </li> 86 <li> 87 <!--! use the properly formatted duration instead of the timedelta object --> 88 <tal:c tal:content="workout._duration"></tal:c> 89 </li> 90 <li tal:condition="workout.distance"> 91 <tal:c tal:content="workout.rounded_distance"></tal:c> km 92 </li> 93 </ul> 92 94 93 <h2 class="workout-title"> 94 <a href="" tal:content="workout.title" 95 tal:attributes="href request.resource_url(workout)"></a> 96 </h2> 95 <ul class="workout-info" tal:define="hr workout.hr; cad workout.cad"> 96 <li tal:condition="hr"> 97 <span i18n:translate="">HR (bpm)</span>: 98 <tal:c tal:content="hr['min']"></tal:c> 99 <tal:t i18n:translate="">Min.</tal:t>, 100 <tal:c tal:content="hr['avg']"></tal:c> 101 <tal:t i18n:translate="">Avg.</tal:t>, 102 <tal:c tal:content="hr['max']"></tal:c> 103 <tal:t i18n:translate="">Max.</tal:t> 104 </li> 105 <li tal:condition="cad"> 106 <span i18n:translate="">Cad</span>: 107 <tal:c tal:content="cad['min']"></tal:c> 108 <tal:t i18n:translate="">Min.</tal:t>, 109 <tal:c tal:content="cad['avg']"></tal:c> 110 <tal:t i18n:translate="">Avg.</tal:t>, 111 <tal:c tal:content="cad['max']"></tal:c> 112 <tal:t i18n:translate="">Max.</tal:t> 113 </li> 114 </ul> 97 115 98 <ul class="workout-info"> 116 <div class="workout-intro" tal:content="workout.notes"></div> 117 118 <div class="workout-map" tal:condition="workout.has_gpx"> 119 <a href="" tal:attributes="href request.resource_url(workout)"> 120 <img src="" tal:attributes="src request.static_url(workout.map_screenshot); 121 alt workout.title; title workout.title"> 122 </a> 123 </div> 124 125 </article> 126 127 </tal:r> 128 </div> 129 130 <div class="workout-aside"> 131 <ul class="profile-data"> 99 132 <li> 100 <tal:c tal:content="workout.start_in_timezone(context.timezone)"></tal:c> 133 <span><tal:t i18n:translate="">Gender:</tal:t></span> 134 <tal:c tal:content="getattr(context, 'gender', '-')"></tal:c> 135 </li> 136 <li tal:define="birth_date getattr(context, 'birth_date', None)"> 137 <span><tal:t i18n:translate="">Birth date:</tal:t></span> 138 <tal:c tal:condition="birth_date" 139 tal:content="birth_date.strftime('%d/%m/%Y')"></tal:c> 140 <tal:c tal:condition="birth_date is None">-</tal:c> 101 141 </li> 102 142 <li> 103 < !--! use the properly formatted duration instead of the timedelta object -->104 <tal:c tal:content=" workout._duration"></tal:c>143 <span><tal:t i18n:translate="">Height:</tal:t></span> 144 <tal:c tal:content="getattr(context, 'height', '-')"></tal:c> meters 105 145 </li> 106 <li tal:condition="workout.distance"> 107 <tal:c tal:content="workout.rounded_distance"></tal:c> km 146 <li> 147 <span><tal:t i18n:translate="">Weight:</tal:t></span> 148 <tal:c tal:content="getattr(context, 'weight', '-')"></tal:c> kg 108 149 </li> 109 150 </ul> 110 111 <ul class="workout-info" tal:define="hr workout.hr; cad workout.cad"> 112 <li tal:condition="hr"> 113 <span i18n:translate="">HR (bpm)</span>: 114 <tal:c tal:content="hr['min']"></tal:c> 115 <tal:t i18n:translate="">Min.</tal:t>, 116 <tal:c tal:content="hr['avg']"></tal:c> 117 <tal:t i18n:translate="">Avg.</tal:t>, 118 <tal:c tal:content="hr['max']"></tal:c> 119 <tal:t i18n:translate="">Max.</tal:t> 120 </li> 121 <li tal:condition="cad"> 122 <span i18n:translate="">Cad</span>: 123 <tal:c tal:content="cad['min']"></tal:c> 124 <tal:t i18n:translate="">Min.</tal:t>, 125 <tal:c tal:content="cad['avg']"></tal:c> 126 <tal:t i18n:translate="">Avg.</tal:t>, 127 <tal:c tal:content="cad['max']"></tal:c> 128 <tal:t i18n:translate="">Max.</tal:t> 129 </li> 130 </ul> 131 132 <div class="workout-intro" tal:content="workout.notes"></div> 133 134 <div class="workout-map" tal:condition="workout.has_gpx"> 135 <a href="" tal:attributes="href request.resource_url(workout)"> 136 <img src="" tal:attributes="src request.static_url(workout.map_screenshot); 137 alt workout.title; title workout.title"> 138 </a> 139 </div> 140 141 </article> 142 143 </tal:r> 151 </div> 152 </div> 144 153 </div> 145 154
Note: See TracChangeset
for help on using the changeset viewer.