Browse Source

Remove Roster getBanner, directly use the Contact one

Update the dependencies
pull/1228/head
Timothée Jaussoin 2 years ago
parent
commit
46cf840866
  1. 7
      app/Roster.php
  2. 2
      app/widgets/ContactActions/_contactactions_drawer.tpl
  3. 2
      app/widgets/ContactHeader/_contactheader.tpl
  4. 54
      composer.lock

7
app/Roster.php

@ -98,13 +98,6 @@ class Roster extends Model
: avatarPlaceholder($this->truename);
}
public function getBanner($size = 'xxl')
{
$banner = !empty($this->id) ? getPhoto($this->id . '_banner', $size) : null;
return $banner == null ? $this->getPhoto($size) : $banner;
}
public function getTruenameAttribute()
{
if ($this->name && !filter_var($this->name, FILTER_VALIDATE_EMAIL)) {

2
app/widgets/ContactActions/_contactactions_drawer.tpl

@ -1,6 +1,6 @@
<section>
<header class="big color {$contact->jid|stringToColor}"
style="background-image: linear-gradient(to bottom, rgba(23,23,23,0.8) 0%, rgba(23,23,23,0.5) 100%), url('{if="$roster"}{$roster->getBanner('xxl')}{else}{$contact->getBanner('xxl')}{/if}');"
style="background-image: linear-gradient(to bottom, rgba(23,23,23,0.8) 0%, rgba(23,23,23,0.5) 100%), url('{$contact->getBanner('xxl')}');"
>
<ul class="list thick">
<li>

2
app/widgets/ContactHeader/_contactheader.tpl

@ -7,7 +7,7 @@
<header class="big top color {$contact->jid|stringToColor}"
style="
background-image:
linear-gradient(to top, rgba(23,23,23,0.9) 0, rgba(23,23,23,0.6) 5rem, rgba(23,23,23,0) 12rem), url('{if="$roster"}{$roster->getBanner('xxl')}{else}{$contact->getBanner('xxl')}{/if}');
linear-gradient(to top, rgba(23,23,23,0.9) 0, rgba(23,23,23,0.6) 5rem, rgba(23,23,23,0) 12rem), url('{$contact->getBanner('xxl')}');
">
<ul class="list thick">

54
composer.lock

@ -1793,7 +1793,7 @@
},
{
"name": "illuminate/bus",
"version": "v10.16.1",
"version": "v10.17.1",
"source": {
"type": "git",
"url": "https://github.com/illuminate/bus.git",
@ -1846,16 +1846,16 @@
},
{
"name": "illuminate/collections",
"version": "v10.16.1",
"version": "v10.17.1",
"source": {
"type": "git",
"url": "https://github.com/illuminate/collections.git",
"reference": "07ec467c42b90ec6e7e2faec381e3457dcfd5571"
"reference": "66ff5aab0dd10659aff0efe3ff101819db192dfe"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/illuminate/collections/zipball/07ec467c42b90ec6e7e2faec381e3457dcfd5571",
"reference": "07ec467c42b90ec6e7e2faec381e3457dcfd5571",
"url": "https://api.github.com/repos/illuminate/collections/zipball/66ff5aab0dd10659aff0efe3ff101819db192dfe",
"reference": "66ff5aab0dd10659aff0efe3ff101819db192dfe",
"shasum": ""
},
"require": {
@ -1897,11 +1897,11 @@
"issues": "https://github.com/laravel/framework/issues",
"source": "https://github.com/laravel/framework"
},
"time": "2023-07-24T14:56:19+00:00"
"time": "2023-08-02T14:57:32+00:00"
},
{
"name": "illuminate/conditionable",
"version": "v10.16.1",
"version": "v10.17.1",
"source": {
"type": "git",
"url": "https://github.com/illuminate/conditionable.git",
@ -1947,7 +1947,7 @@
},
{
"name": "illuminate/container",
"version": "v10.16.1",
"version": "v10.17.1",
"source": {
"type": "git",
"url": "https://github.com/illuminate/container.git",
@ -1998,16 +1998,16 @@
},
{
"name": "illuminate/contracts",
"version": "v10.16.1",
"version": "v10.17.1",
"source": {
"type": "git",
"url": "https://github.com/illuminate/contracts.git",
"reference": "ec47d1aa1a1b1a679d8553836b417343881b8215"
"reference": "eb1a7e72e159136a832f2c0467de5570bdc208ae"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/illuminate/contracts/zipball/ec47d1aa1a1b1a679d8553836b417343881b8215",
"reference": "ec47d1aa1a1b1a679d8553836b417343881b8215",
"url": "https://api.github.com/repos/illuminate/contracts/zipball/eb1a7e72e159136a832f2c0467de5570bdc208ae",
"reference": "eb1a7e72e159136a832f2c0467de5570bdc208ae",
"shasum": ""
},
"require": {
@ -2042,20 +2042,20 @@
"issues": "https://github.com/laravel/framework/issues",
"source": "https://github.com/laravel/framework"
},
"time": "2023-06-27T14:35:49+00:00"
"time": "2023-07-26T21:27:34+00:00"
},
{
"name": "illuminate/database",
"version": "v10.16.1",
"version": "v10.17.1",
"source": {
"type": "git",
"url": "https://github.com/illuminate/database.git",
"reference": "2d4d2c0e3c728124c6d2b8e419c455d43902c2f7"
"reference": "099b3078d98a2761a9b777ff78b3c4cfb9e69100"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/illuminate/database/zipball/2d4d2c0e3c728124c6d2b8e419c455d43902c2f7",
"reference": "2d4d2c0e3c728124c6d2b8e419c455d43902c2f7",
"url": "https://api.github.com/repos/illuminate/database/zipball/099b3078d98a2761a9b777ff78b3c4cfb9e69100",
"reference": "099b3078d98a2761a9b777ff78b3c4cfb9e69100",
"shasum": ""
},
"require": {
@ -2111,11 +2111,11 @@
"issues": "https://github.com/laravel/framework/issues",
"source": "https://github.com/laravel/framework"
},
"time": "2023-07-24T14:38:25+00:00"
"time": "2023-08-01T13:53:21+00:00"
},
{
"name": "illuminate/events",
"version": "v10.16.1",
"version": "v10.17.1",
"source": {
"type": "git",
"url": "https://github.com/illuminate/events.git",
@ -2170,7 +2170,7 @@
},
{
"name": "illuminate/macroable",
"version": "v10.16.1",
"version": "v10.17.1",
"source": {
"type": "git",
"url": "https://github.com/illuminate/macroable.git",
@ -2216,7 +2216,7 @@
},
{
"name": "illuminate/pipeline",
"version": "v10.16.1",
"version": "v10.17.1",
"source": {
"type": "git",
"url": "https://github.com/illuminate/pipeline.git",
@ -2264,16 +2264,16 @@
},
{
"name": "illuminate/support",
"version": "v10.16.1",
"version": "v10.17.1",
"source": {
"type": "git",
"url": "https://github.com/illuminate/support.git",
"reference": "40b87e80d150339bc186256576e11ea3be3d0ff5"
"reference": "7549dd081cc45c742b7d97064b64cf67fab4c7b6"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/illuminate/support/zipball/40b87e80d150339bc186256576e11ea3be3d0ff5",
"reference": "40b87e80d150339bc186256576e11ea3be3d0ff5",
"url": "https://api.github.com/repos/illuminate/support/zipball/7549dd081cc45c742b7d97064b64cf67fab4c7b6",
"reference": "7549dd081cc45c742b7d97064b64cf67fab4c7b6",
"shasum": ""
},
"require": {
@ -2285,7 +2285,7 @@
"illuminate/conditionable": "^10.0",
"illuminate/contracts": "^10.0",
"illuminate/macroable": "^10.0",
"nesbot/carbon": "^2.62.1",
"nesbot/carbon": "^2.67",
"php": "^8.1",
"voku/portable-ascii": "^2.0"
},
@ -2331,7 +2331,7 @@
"issues": "https://github.com/laravel/framework/issues",
"source": "https://github.com/laravel/framework"
},
"time": "2023-07-25T19:33:34+00:00"
"time": "2023-07-31T15:02:41+00:00"
},
{
"name": "league/commonmark",

Loading…
Cancel
Save