mirror of
https://github.com/immich-app/immich.git
synced 2024-11-27 09:21:05 +02:00
chore(deps): update dependency @types/node to v20.11.27 (#8012)
* chore(deps): update dependency @types/node to v20.11.27 * fixes * fixes --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Daniel Dietzler <mail@ddietzler.dev> Co-authored-by: Marty Fuhry <martyfuhry@gmail.com>
This commit is contained in:
parent
4aae1da841
commit
50924f0b3d
6
e2e/package-lock.json
generated
6
e2e/package-lock.json
generated
@ -1158,9 +1158,9 @@
|
||||
"dev": true
|
||||
},
|
||||
"node_modules/@types/node": {
|
||||
"version": "20.11.25",
|
||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.11.25.tgz",
|
||||
"integrity": "sha512-TBHyJxk2b7HceLVGFcpAUjsa5zIdsPWlR6XHfyGzd0SFu+/NFgQgMAl96MSDZgQDvJAvV6BKsFOrt6zIL09JDw==",
|
||||
"version": "20.11.27",
|
||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.11.27.tgz",
|
||||
"integrity": "sha512-qyUZfMnCg1KEz57r7pzFtSGt49f6RPkPBis3Vo4PbS7roQEDn22hiHzl/Lo1q4i4hDEgBJmBF/NTNg2XR0HbFg==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"undici-types": "~5.26.4"
|
||||
|
1
mobile/assets/immich-logo.json
Normal file
1
mobile/assets/immich-logo.json
Normal file
File diff suppressed because one or more lines are too long
13
mobile/lib/shared/providers/immich_logo_provider.dart
Normal file
13
mobile/lib/shared/providers/immich_logo_provider.dart
Normal file
@ -0,0 +1,13 @@
|
||||
import 'dart:convert';
|
||||
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:riverpod_annotation/riverpod_annotation.dart';
|
||||
|
||||
part 'immich_logo_provider.g.dart';
|
||||
|
||||
@riverpod
|
||||
Future<Uint8List> immichLogo(ImmichLogoRef ref) async {
|
||||
final json = await rootBundle.loadString('assets/immich-logo.json');
|
||||
final j = jsonDecode(json);
|
||||
return base64Decode(j['content']);
|
||||
}
|
BIN
mobile/lib/shared/providers/immich_logo_provider.g.dart
generated
Normal file
BIN
mobile/lib/shared/providers/immich_logo_provider.g.dart
generated
Normal file
Binary file not shown.
@ -4,6 +4,7 @@ import 'package:flutter/material.dart';
|
||||
import 'package:hooks_riverpod/hooks_riverpod.dart';
|
||||
import 'package:immich_mobile/extensions/build_context_extensions.dart';
|
||||
import 'package:immich_mobile/shared/models/store.dart';
|
||||
import 'package:immich_mobile/shared/providers/immich_logo_provider.dart';
|
||||
import 'package:immich_mobile/shared/ui/app_bar_dialog/app_bar_dialog.dart';
|
||||
import 'package:immich_mobile/shared/ui/user_circle_avatar.dart';
|
||||
|
||||
@ -26,6 +27,7 @@ class ImmichAppBar extends ConsumerWidget implements PreferredSizeWidget {
|
||||
final bool isEnableAutoBackup =
|
||||
backupState.backgroundBackup || backupState.autoBackup;
|
||||
final ServerInfo serverInfoState = ref.watch(serverInfoProvider);
|
||||
final immichLogo = ref.watch(immichLogoProvider);
|
||||
final user = Store.tryGet(StoreKey.currentUser);
|
||||
final isDarkTheme = context.isDarkTheme;
|
||||
const widgetSize = 30.0;
|
||||
@ -152,14 +154,29 @@ class ImmichAppBar extends ConsumerWidget implements PreferredSizeWidget {
|
||||
builder: (BuildContext context) {
|
||||
return Row(
|
||||
children: [
|
||||
Container(
|
||||
padding: const EdgeInsets.only(top: 3),
|
||||
height: 30,
|
||||
child: Image.asset(
|
||||
context.isDarkTheme
|
||||
? 'assets/immich-logo-inline-dark.png'
|
||||
: 'assets/immich-logo-inline-light.png',
|
||||
),
|
||||
Builder(
|
||||
builder: (context) {
|
||||
final today = DateTime.now();
|
||||
if (today.month == 4 && today.day == 1) {
|
||||
if (immichLogo.value == null) {
|
||||
return const SizedBox.shrink();
|
||||
}
|
||||
return Image.memory(
|
||||
immichLogo.value!,
|
||||
fit: BoxFit.cover,
|
||||
height: 80,
|
||||
);
|
||||
}
|
||||
return Padding(
|
||||
padding: const EdgeInsets.only(top: 3.0),
|
||||
child: Image.asset(
|
||||
height: 30,
|
||||
context.isDarkTheme
|
||||
? 'assets/immich-logo-inline-dark.png'
|
||||
: 'assets/immich-logo-inline-light.png',
|
||||
),
|
||||
);
|
||||
},
|
||||
),
|
||||
],
|
||||
);
|
||||
|
1
web/src/lib/assets/immich-logo.json
Normal file
1
web/src/lib/assets/immich-logo.json
Normal file
File diff suppressed because one or more lines are too long
@ -2,8 +2,10 @@
|
||||
import logoDarkUrl from '$lib/assets/immich-logo-inline-dark.svg';
|
||||
import logoLightUrl from '$lib/assets/immich-logo-inline-light.svg';
|
||||
import logoNoText from '$lib/assets/immich-logo.svg';
|
||||
import { content as alternativeLogo } from '$lib/assets/immich-logo.json';
|
||||
import { Theme } from '$lib/constants';
|
||||
import { colorTheme } from '$lib/stores/preferences.store';
|
||||
import { DateTime } from 'luxon';
|
||||
import type { HTMLImgAttributes } from 'svelte/elements';
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
@ -14,11 +16,17 @@
|
||||
|
||||
export let noText = false;
|
||||
export let draggable = false;
|
||||
|
||||
const today = DateTime.now().toLocal();
|
||||
</script>
|
||||
|
||||
<img
|
||||
src={noText ? logoNoText : $colorTheme.value == Theme.LIGHT ? logoLightUrl : logoDarkUrl}
|
||||
alt="Immich Logo"
|
||||
{draggable}
|
||||
{...$$restProps}
|
||||
/>
|
||||
{#if today.month === 4 && today.day === 1}
|
||||
<img src="data:image/png;base64, {alternativeLogo}" alt="Immich Logo" class="h-20" {draggable} />
|
||||
{:else}
|
||||
<img
|
||||
src={noText ? logoNoText : $colorTheme.value == Theme.LIGHT ? logoLightUrl : logoDarkUrl}
|
||||
alt="Immich Logo"
|
||||
{draggable}
|
||||
{...$$restProps}
|
||||
/>
|
||||
{/if}
|
||||
|
Loading…
Reference in New Issue
Block a user