Projet

Général

Profil

0001-rouen-customize-user-info-zone-25153.patch

Emmanuel Cazenave, 09 juillet 2018 17:06

Télécharger (4,18 ko)

Voir les différences:

Subject: [PATCH] rouen: customize user-info zone (#25153)

 static/rouen/_custom.scss                     | 46 +++++++++++++++++++
 static/rouen/img/picto_btn_connexion.svg      | 14 ++++++
 .../variants/rouen/combo/page_template.html   | 19 ++++++++
 3 files changed, 79 insertions(+)
 create mode 100644 static/rouen/img/picto_btn_connexion.svg
 create mode 100644 templates/variants/rouen/combo/page_template.html
static/rouen/_custom.scss
239 239
		}
240 240
	}
241 241
}
242

  
243
div#toplinks {
244
	border: none;
245
	border-radius: 0;
246
	box-shadow: none;
247
	padding: 0;
248
	a.login,a.logout {
249
		@include flexbox();
250
		@include vendor-prefix(justify-content, flex-end);
251
		div.logtext {
252
			background: $primary-color;
253
			display: block;
254
			color: $black;
255
			font-size: 122%;
256
			font-weight: 700;
257
			height: 2em;
258
			padding: 0 0.5em;
259
			text-align: center;
260
			line-height: 2em;
261
		}
262
		div.logicon {
263
			background-color: $black;
264
			background-image: url(img/picto_btn_connexion.svg);
265
			background-position: center;
266
			background-repeat: no-repeat;
267
			background-size: 70%;
268
			content: "";
269
			display: block;
270
			width: 2em;
271
		}
272
	}
273
	a.registration {
274
		@include flexbox();
275
		@include vendor-prefix(justify-content, flex-end);
276
		color: #C64A59;
277
		font-weight: 500;
278
		margin-top: 0.4em;
279
		span.pre-register {
280
			color: #333333;
281
			margin-right: 0.2em;
282
		}
283
		span.register {
284
			text-decoration: underline;
285
		}
286
	}
287
}
static/rouen/img/picto_btn_connexion.svg
1
<?xml version="1.0" encoding="utf-8"?>
2
<!-- Generator: Adobe Illustrator 19.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0)  -->
3
<svg version="1.1" id="Capa_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
4
	 width="516.4px" height="516.4px" viewBox="-39 162.5 516.4 516.4" style="enable-background:new -39 162.5 516.4 516.4;"
5
	 xml:space="preserve">
6
<style type="text/css">
7
	.st0{fill:#EE787C;}
8
</style>
9
<g>
10
	<path class="st0" d="M137.9,225.8c-44.9,44.9-44.9,117.6,0,162.5c9.6,9.6,21,17.2,33.5,23.9l0,200.8l47.8,47.8L267,613l-28.7-28.7
11
		l28.7-28.7L238.3,527l28.7-28.7v-86c11.5-5.7,22.9-13.4,33.5-23.9c44.9-44.9,44.9-117.6,0-162.5S182.9,180.9,137.9,225.8z
12
		 M247.9,288c-16.3,16.3-41.1,16.3-57.4,0c-16.3-16.3-16.3-41.1,0-57.4s41.1-16.3,57.4,0S264.1,271.7,247.9,288z"/>
13
</g>
14
</svg>
templates/variants/rouen/combo/page_template.html
1
{% extends "../../combo/page_template.html" %}
2
{% load combo %}
3

  
4
{% block user-info %}
5
{% skeleton_extra_placeholder user-info %}
6
          {% if user.is_authenticated %}
7
          <a accesskey="o" class="logout" href="{% url 'auth_logout' %}"><div class="logtext">D&eacute;connexion</div><div class="logicon"></div></a>
8
            {% if idp_account_url %}<a class="registration" href="{{idp_account_url}}">{% endif %}
9
            <span>{{user.first_name}} {{user.last_name}}</span>{% if idp_account_url %}</a>{% endif %}
10
          {% else %}
11
            {% if idp_registration_url %}
12
             <a accesskey="2" class="login" href="{% url 'auth_login' %}"><div class="logtext">Connexion</div><div class="logicon"></div></a>
13
             <a class="registration" href="{{idp_registration_url}}"><span class="pre-register">Pas de compte ?</span><span class="register">Enregistrez vous !</span></a>
14
            {% else %}
15
            <a accesskey="2" class="registration" href="{% url 'auth_login' %}">Connexion <span class="sep">/</span> Inscription</a>
16
            {% endif %}
17
          {% endif %}
18
{% end_skeleton_extra_placeholder %}
19
{% endblock %}
0
-