Skip to content

Instantly share code, notes, and snippets.

Artur Rymarz artrmz

Block or report user

Report or block artrmz

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View wave_clipper.dart
class WaveClipper extends CustomClipper<Path> {
final double percentage;
final double animation;
WaveClipper(this.percentage, this.animation);
@override
Path getClip(Size size) {
var progress = (percentage > 100.0 ? 100.0 : percentage) / 100.0;
progress = 1.0 - progress;
View water_drop.dart
Stack(
alignment: Alignment.center,
children: <Widget>[
Center(child: Image.asset('assets/images/drop.png')),
Center(
child: AnimatedBuilder(
animation: CurvedAnimation(
parent: animationController,
curve: Curves.easeInOut),
builder: (context, child) => ClipPath(
View bubbles.dart
class Bubbles extends StatefulWidget {
@override
State<StatefulWidget> createState() {
return _BubblesState();
}
}
class _BubblesState extends State<Bubbles> with TickerProviderStateMixin {
AnimationController animationController;
final bubbles = <Bubble>[];
View toggle_animation.dart
@override
initState() {
final Curve curve = Curves.easeOut;
_animationController =
AnimationController(vsync: this, duration: Duration(milliseconds: 500));
_translateButton = Tween<double>(
begin: _fabHeight,
end: -8.0,
).animate(CurvedAnimation(
View menu.dart
toggleMenu() {
if (!isOpened) {
_animationController.forward();
} else {
_animationController.reverse();
}
View container_wrapper.dart
class ContainerWrapper extends StatelessWidget {
final Widget child;
final double widthScale;
ContainerWrapper({@required this.child, this.widthScale = 0.8});
@override
Widget build(BuildContext context) {
var size = MediaQuery.of(context).size;
return SizedBox(
View database_manager.dart
void insert(List<DatabaseModel> models) async {
var db = await database;
var batch = db.batch();
for (var model in models) {
DatabaseTable table = _tables[model.runtimeType];
if (table == null) {
return;
}
batch.insert(table.name, model.toMap());
View Watermaniac.dart
@override
void paint(Canvas canvas, Size size) {
Paint paint = new Paint()
..color = Color(0xFFc7d0df)
..strokeWidth = 6.0
..strokeCap = StrokeCap.round
..style = PaintingStyle.stroke;
canvas.drawLine(Offset(0.0, 6.0), Offset(size.width * 0.15, size.height - 6.0), paint);
canvas.drawLine(Offset(0.0, 6.0), Offset(size.width, 6.0), paint);
View ViewController.swift
private func donate(name: String) {
// 1
let intent = CheckMyGitHubIntent()
// 2
intent.suggestedInvocationPhrase = "Check my GitHub"
intent.name = name
// 3
let interaction = INInteraction(intent: intent, response: nil)
View IntentViewController.swift
class IntentViewController: UIViewController, INUIHostedViewControlling {
@IBOutlet weak var reposLabel: UILabel!
@IBOutlet weak var followersLabel: UILabel!
@IBOutlet weak var activityIndicator: UIActivityIndicatorView!
// MARK: - INUIHostedViewControlling
// Prepare your view controller for the interaction to handle.
func configureView(for parameters: Set<INParameter>, of interaction: INInteraction, interactiveBehavior: INUIInteractiveBehavior, context: INUIHostedViewContext, completion: @escaping (Bool, Set<INParameter>, CGSize) -> Void) {
You can’t perform that action at this time.