Skip to content

Instantly share code, notes, and snippets.

View talamaska's full-sized avatar

Zlati Pehlivanov talamaska

View GitHub Profile
@talamaska
talamaska / scroll_parent_on_overflow.dart
Created August 15, 2024 18:11 — forked from slightfoot/scroll_parent_on_overflow.dart
Scroll Parent On Overflow - by Simon lightfoot - Humpday Q&A :: 20th March 2024 #Flutter #Dart - https://www.youtube.com/watch?v=qByAoUXOb2M
// MIT License
//
// Copyright (c) 2024 Simon Lightfoot
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
@talamaska
talamaska / logout_button.dart
Created July 12, 2024 19:38 — forked from Luckey-Elijah/logout_button.dart
A useful OverlayPortal widget wrapper for building based on the anchor/target's position.
import 'positioned_overlay_builder.dart';
import 'package:flutter/material.dart';
class LogoutButton extends StatelessWidget {
const LogoutButton({super.key});
@override
Widget build(BuildContext context) {
return PositionedOverlayBuilder(
anchorBuilder: (context, controller) {
@talamaska
talamaska / humpday_2024-06-26_1.dart
Created June 30, 2024 23:48 — forked from slightfoot/humpday_2024-06-26_1.dart
Search Box Overlays - by Simon Lightfoot - Humpday Q&A :: 26th June 2024 #Flutter #Dart https://www.youtube.com/watch?v=X0bin1qozYg
// MIT License
//
// Copyright (c) 2024 Simon Lightfoot
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
@talamaska
talamaska / smooth_scroll.dart
Created June 26, 2024 19:45 — forked from slightfoot/smooth_scroll.dart
Correct smooth scroll for Flutter Web - by Simon Lightfoot - 14th July 2022
// MIT License
//
// Copyright (c) 2022 Simon Lightfoot
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
// MIT License
//
// Copyright (c) 2024 Simon Lightfoot
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
@talamaska
talamaska / app_lifecycle_aware.dart
Created January 31, 2024 15:22 — forked from dinko7/app_lifecycle_aware.dart
Android style app lifecycle awareness mixin for Flutter
import 'package:flutter/material.dart';
mixin AppLifecycleAware<T extends StatefulWidget> on State<T> {
late final AppLifecycleListener _listener;
@override
void initState() {
super.initState();
_listener = AppLifecycleListener(
onDetach: onDetach,

ssh-agent checker/launcher

about

A bash script for managing ssh-agent that I use for Ubuntu and OSX.

Started as a variation from this classic on Stack Overflow How to check if ssh-agent is already running and then adapted it to align with behaivor I want.

This version does the following:

  • checks for ssh agent forward (remote login) and if so does not setup ssh-agent or any keys
@talamaska
talamaska / chat_message_render_box.dart
Created April 27, 2023 12:58 — forked from craiglabenz/chat_message_render_box.dart
Demonstrates a custom RenderObject that draws chat messages like WhatsApp, where the `sentAt` timestamp is tucked into the last line if it fits
import 'dart:math';
import 'package:flutter/material.dart';
import 'package:flutter/rendering.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
import 'package:flutter/material.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
@talamaska
talamaska / main.dart
Created March 10, 2023 13:34 — forked from daveols/main.dart
Scrollable tabs within DraggableScrollableSheet
import 'package:flutter/material.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(