From 67a151fc194e48b2de3f97eb5891ddbf65f9cca9 Mon Sep 17 00:00:00 2001 From: Nikolas Rimikis Date: Fri, 29 Sep 2023 21:46:50 +0200 Subject: [PATCH] refactor(neon): make nextcloud logo size adjustable Signed-off-by: Nikolas Rimikis --- .../neon/neon/lib/src/widgets/nextcloud_logo.dart | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/packages/neon/neon/lib/src/widgets/nextcloud_logo.dart b/packages/neon/neon/lib/src/widgets/nextcloud_logo.dart index c6324ca3..f86e8a73 100644 --- a/packages/neon/neon/lib/src/widgets/nextcloud_logo.dart +++ b/packages/neon/neon/lib/src/widgets/nextcloud_logo.dart @@ -2,15 +2,25 @@ import 'package:flutter/widgets.dart'; import 'package:neon/l10n/localizations.dart'; import 'package:vector_graphics/vector_graphics.dart'; +/// The Nextcloud logo, in widget form. +/// +/// For guidelines on using the Nextcloud logo, visit https://nextcloud.com/trademarks. class NextcloudLogo extends StatelessWidget { + /// Creates a widget that shows the Nextcloud logo. const NextcloudLogo({ + this.size = 100, super.key, }); + /// The size of the logo in logical pixels. + /// + /// The logo will be fit into a square this size. + final double size; + @override Widget build(final BuildContext context) => VectorGraphic( - width: 100, - height: 100, + width: size, + height: size, loader: const AssetBytesLoader( 'assets/logo_nextcloud.svg.vec', packageName: 'neon',