Skip to content

Instantly share code, notes, and snippets.

View Lzyct's full-sized avatar
:shipit:
Code Geek

Mudassir Lzyct

:shipit:
Code Geek
View GitHub Profile
@Lzyct
Lzyct / custom-vscode.css
Last active August 30, 2024 08:46
VS Code Custom CSS For Catpuccin Mocha (Pink Accent) https://github.com/glennraya/vscode-settings-json
/* Code comment style */
.mtk3 {
font-family: 'MonoLisaAlt Nerd Font', monospace !important;
color: #f5c2e7 !important;
font-weight: 300 !important;
}
.line-numbers {
position: relative !important;
width: 35px !important;
@Lzyct
Lzyct / sample_online_offline.dart
Last active October 14, 2022 05:42
Handle online/offline on Flutter
import 'package:flutter/material.dart';
const Color darkBlue = Color.fromARGB(255, 18, 32, 47);
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
@Lzyct
Lzyct / guest_gift.js
Last active February 10, 2023 03:47
Guest Gift
const wishlist = [
{ name: "Mini Puzzle", size: "small", clatters: "yes", weight: "light" },
{ name: "Toy Car", size: "medium", clatters: "a bit", weight: "medium" },
{ name: "Card Game", size: "small", clatters: "no", weight: "light" }
];
const presents = [
{ size: "medium", clatters: "a bit", weight: "medium" },
{ size: "small", clatters: "yes", weight: "light" },
];
@Lzyct
Lzyct / measure_size.dart
Created September 17, 2020 12:45
Get Measure SIze of Widget in Flutter
import 'package:flutter/material.dart';
import 'package:flutter/scheduler.dart';
typedef void OnWidgetSizeChange(Size size);
class MeasureSize extends StatefulWidget {
final Widget child;
final OnWidgetSizeChange onChange;
const MeasureSize({
@Lzyct
Lzyct / downgradeflutter.md
Last active August 12, 2020 09:14
Downgrade / Change Flutter SDK Version
@Lzyct
Lzyct / downgradeflutter.md
Created August 12, 2020 09:13
Downgrade / Change Flutter SDK Version
@Lzyct
Lzyct / layout.kbd.json
Last active June 13, 2020 03:52 — forked from mmynsted/layout.kbd.json
Untitled Keyboard Layout
[
[
"app",
"F1",
"F2",
"F3",
"F4",
"F5",
"F6",
"F7",
@Lzyct
Lzyct / layout.kbd.json
Last active December 25, 2020 03:17 — forked from mmynsted/layout.kbd.json
Untitled Keyboard Layout
[
[
"Esc",
"!\n1",
"@\n2",
"#\n3",
"$\n4",
"%\n5",
"^\n6",
"&\n7",
@Lzyct
Lzyct / ClearActivityStack.kt
Created September 22, 2019 13:10
Clear Activity Stack
startActivity(Intent(applicationContext, NextActivity::class.java).apply {
flags = Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_CLEAR_TASK or Intent.FLAG_ACTIVITY_CLEAR_TOP
})
@Lzyct
Lzyct / sample.kt
Created September 20, 2019 15:05
Date Format for timestampz
//date format for timestampz
val formatInput = "yyyy-MM-dd'T'HH:mm:ss.SSS'Z'"
val formatOutput = "dd MMMM yyyy HH:mm:ss"
val sdfInput = SimpleDateFormat(formatInput, Locale("id", "ID"))
val sdfOutput = SimpleDateFormat(formatOutput, Locale("id", "ID"))
val date = sdfInput.parse(dataHome.apraisTime)
val newOutput = sdfOutput.format(date)