Skip to content

Instantly share code, notes, and snippets.

View davinaleong's full-sized avatar
🕶️
Developing Something Faith-based

Davina Leong davinaleong

🕶️
Developing Something Faith-based
View GitHub Profile
@davinaleong
davinaleong / power-bi-dax.txt
Last active April 15, 2025 10:58
DA Expressions to Power BI Hands-on Practice
// Date Table
Date = Calendar(Date(2005,01,01), Date(2011,12,31))
Weeknumber = WEEKNUM('Date'[Date])
Daynumber = WEEKDAY('Date'[Date], 2)
Dayname = IF('Date'[Daynumber]=1, "Monday",
IF('Date'[Daynumber]=2, "Tuesday",
IF('Date'[Daynumber]=3, "Wednesday",
@davinaleong
davinaleong / BCG SQL - 3.2.6.sql
Last active April 23, 2025 08:31
IU 3.2.6 SQL 101 SQL Mini-project
# IU3.2.6SQLMini-project
# Davina Leong
/*
[Q1] Create a new database schema (named 'sql_mini_proj') in a local
instance of MySQL Workbench, and set it as default schema
*/
CREATE SCHEMA IF NOT EXISTS sql_mini_proj;
USE sql_mini_proj;
@davinaleong
davinaleong / BCG SQL - 3.2.3 Slide 13.sql
Last active March 31, 2025 06:52
BCG SQL Practice Questions
# UI3.2.3BasicSQL - Hands-on Practice 1 (Slide 13)
# Code from Davina Leong
USE sql_101;
/*
1. View all rows for each of the sales and managers tables.
*/
SELECT * FROM sales;
SELECT * FROM managers;
@davinaleong
davinaleong / reset.css
Created July 29, 2022 05:46
CSS Reset file.
/** Reset **/
/* https://piccalil.li/blog/a-modern-css-reset */
/* Box sizing rules */
*,
*::before,
*::after {
box-sizing: border-box;
}
* {
margin: 0;
padding: 0;
border: 0;
font-size: 100%;
font: inherit;
vertical-align: baseline;
box-sizing: border-box;
}
@davinaleong
davinaleong / _colors,scss
Created September 4, 2019 08:34
SASS Material Colors
/// Colors
/// C.1. Color Definition
$black: #000;
$white: #fff;
$gray: #9e9e9e;
/// C.2. Tints
/// C.2.a Red Tints
$red-50: #ffebee;
@davinaleong
davinaleong / material-colors.json
Created February 26, 2019 22:27 — forked from kawanet/material-colors.json
Material Design Style Color Palette as JSON
{
"red": {
"50": "#ffebee",
"100": "#ffcdd2",
"200": "#ef9a9a",
"300": "#e57373",
"400": "#ef5350",
"500": "#f44336",
"600": "#e53935",
"700": "#d32f2f",
@davinaleong
davinaleong / gen-fontface.js
Created January 16, 2019 15:29
Generate Font Faces using console.log
const fontPath = './fonts/';
const montserrat = 'Montserrat';
const ptmono = 'PT Mono';
const ptsans = 'PT Sans';
const ptserif = 'PT Serif';
const normal = 'normal';
const regular = 'normal';
const bold = 'bold';
@davinaleong
davinaleong / reset.css
Created November 29, 2018 15:45
Reset CSS
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed,
@davinaleong
davinaleong / form.blade.php
Created September 17, 2018 06:14
Bootstrap 4 Laravel Blade example
<?php $var = "Hello World" ?>
@extends('main')
@section('title', 'Form')
@section('content')
<form id="formSignup" method="post" action="">
<div class="form-group">
<label for="name">Name <span class="text-danger">*</span></label>
<input id="name" name="name" type="text" class="form-control" maxLength="50" required>