Skip to content

Instantly share code, notes, and snippets.

View wizlif's full-sized avatar
👨‍💻
Coding

Isaac Obella wizlif

👨‍💻
Coding
View GitHub Profile
@wizlif
wizlif / context.ext.dart
Created May 16, 2024 01:26
Context extension for theming simplification
import 'package:flutter/material.dart';
/// Extension methods to simplify theming accessibility.
///
/// Usage:
/// ```dart
/// ...
/// Icon(color: context.kTheme.accent500)
/// ```
extension ThemeBuildContextX on BuildContext {
@wizlif
wizlif / firebase_auth_exceptions.md
Last active October 17, 2023 19:12
Firebase Auth Exception Codes

Future confirmPasswordReset(String code, String newPassword)

A [FirebaseAuthException] maybe thrown with the following error code:

  • expired-action-code: - Thrown if the action code has expired.
  • invalid-action-code: - Thrown if the action code is invalid. This can happen if the code is malformed or has already been used.
  • user-disabled:
  • Thrown if the user corresponding to the given action code has been
@wizlif
wizlif / colors.dart
Created May 20, 2020 05:28
Material Color Palettes for flutter users.
import 'package:flutter/material.dart';
class MaterialColors{
// red
static Color get red => Color(0xFFF44336);
static Color get redLighten5 => Color(0xFFFFEBEE);
static Color get redLighten4 => Color(0xFFFFCDD2);
static Color get redLighten3 => Color(0xFFEF9A9A);
static Color get redLighten2 => Color(0xFFE57373);
static Color get redLighten1 => Color(0xFFEF5350);
@wizlif
wizlif / couchdb2cb.py
Created December 2, 2017 09:55 — forked from necaris/couchdb2cb.py
Simple script to transfer data from CouchDB to Couchbase
#-*-coding: utf-8-*-
"""
Simple script to dump documents out of a CouchDB database and straight into
a Couchbase instance.
"""
import time
import sys
import argparse
/**
* Created by root on 8/21/17.
*/
public class RecyclerTouchListener implements RecyclerView.OnItemTouchListener {
private GestureDetector gestureDetector;
private ClickListener clickListener;
public RecyclerTouchListener(Context context, final RecyclerView recyclerView, final ClickListener clickListener) {
getInput(documents, crop_data) {
let crop = crop_data.crop;
let inputs = {
'title': crop,
'src': this.global.imageUrl+crop_data.src,
category: []
};
let actual_documents = [];
for (let document of documents) {
@wizlif
wizlif / home.html
Last active December 10, 2022 20:41
pouchdb real-time UI update
<ion-header>
<ion-navbar>
<ion-title>
Couch Blog
</ion-title>
</ion-navbar>
</ion-header>
<ion-content>