Git Product home page Git Product logo

avatar_stack's People

Contributors

cyrax111 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

kunimitsu2 wofbi

avatar_stack's Issues

Ability to make individual avatar clickable

For starters i wanted to say great job on this package.

I am having one issue though. Since the avatars property on the AvatarStack is only able to have ImageProvider widgets i am running into an issue when i want to make each avatar clickable in order to perform some action.

Here is an example of my code

AvatarStack(
   settings: settings,
    height: 60,
    avatars: ride.approvedRiders!.map((e) {
            return NetworkImage(getInitialsAvatarUrl(e.user?.name ?? ''));
    }).toList(),
 )

I want to be able to wrap the NetworkImage in an InkWell for example to have onTap functionality

Is there a way around this or is it currently not supported? If not then will this be something you are willing to add in the future?

Thanks

Make avatars accept widgets

Awesome package!

I think it would be better if we could pass a Widget instead ImageProvider for cases where the users doesn't have a picture but you still want to display their initials.

Ability to make vertical list

Hi there,

I was looking for just this! I need to make the list vertical instead of horizontal. Is this possible?

Thanks in advance

Unsupported operation: Infinity or NaN toInt

`======== Exception caught by widgets library =======================================================
The following UnsupportedError was thrown building LayoutBuilder:
Unsupported operation: Infinity or NaN toInt

The relevant error-causing widget was:
WidgetStack WidgetStack:lib/feature/presentation/widgets/main/header/main_header_widget.dart:164:25
When the exception was thrown, this was the stack:
#0 double.toInt (dart:core-patch/double.dart)
#1 RestrictedPositions._calculateMaxCapacityItems (package:avatar_stack/src/positions/restricted_positions.dart:75:21)
#2 RestrictedPositions.calculate (package:avatar_stack/src/positions/restricted_positions.dart:64:48)
#3 WidgetStack.build. (package:avatar_stack/src/widget_stack.dart:35:29)
#4 _LayoutBuilderElement._layout.layoutCallback (package:flutter/src/widgets/layout_builder.dart:122:31)
#5 BuildOwner.buildScope (package:flutter/src/widgets/framework.dart:2531:19)
#6 _LayoutBuilderElement._layout (package:flutter/src/widgets/layout_builder.dart:154:12)
#7 RenderObject.invokeLayoutCallback. (package:flutter/src/rendering/object.dart:1962:59)
#8 PipelineOwner._enableMutationsToDirtySubtrees (package:flutter/src/rendering/object.dart:910:15)
#9 RenderObject.invokeLayoutCallback (package:flutter/src/rendering/object.dart:1962:14)
#10 RenderConstrainedLayoutBuilder.rebuildIfNecessary (package:flutter/src/widgets/layout_builder.dart:228:7)
#11 _RenderLayoutBuilder.performLayout (package:flutter/src/widgets/layout_builder.dart:317:5)
#12 RenderObject.layout (package:flutter/src/rendering/object.dart:1852:7)
#13 RenderPadding.performLayout (package:flutter/src/rendering/shifted_box.dart:233:12)
#14 RenderObject.layout (package:flutter/src/rendering/object.dart:1852:7)
#15 RenderConstrainedBox.performLayout (package:flutter/src/rendering/proxy_box.dart:277:14)
#16 RenderObject.layout (package:flutter/src/rendering/object.dart:1852:7)
#17 ChildLayoutHelper.layoutChild (package:flutter/src/rendering/layout_helper.dart:56:11)
#18 RenderFlex._computeSizes (package:flutter/src/rendering/flex.dart:829:43)
#19 RenderFlex.performLayout (package:flutter/src/rendering/flex.dart:931:32)
#20 RenderObject._layoutWithoutResize (package:flutter/src/rendering/object.dart:1707:7)
#21 PipelineOwner.flushLayout (package:flutter/src/rendering/object.dart:879:18)
#22 RendererBinding.drawFrame (package:flutter/src/rendering/binding.dart:497:19)
#23 WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:883:13)
#24 RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:363:5)
#25 SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:1145:15)
#26 SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:1082:9)
#27 SchedulerBinding._handleDrawFrame (package:flutter/src/scheduler/binding.dart:996:5)
#31 _invoke (dart:ui/hooks.dart:150:10)
#32 PlatformDispatcher._drawFrame (dart:ui/platform_dispatcher.dart:270:5)
#33 _drawFrame (dart:ui/hooks.dart:114:31)
(elided 3 frames from dart:async)`

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.