Skip to content

Instantly share code, notes, and snippets.

View code-vagabond's full-sized avatar

Linh Phung code-vagabond

View GitHub Profile
const robot = require('robotjs');
// The middle of the number 1 in numpad
const NUMAPAD_CALIBRATION_XY = { x: 696, y: 350 }
const ENTER_BUTTON = { x: 768, y: 500 }
const DISTANCE_BEETWEEN_NUMBERS = 72; // Assume horizontal and vertical distances are the same
const PIN_MAX = 999999;
const START_AT = 38280;
const END_AT = 50000;
@code-vagabond
code-vagabond / en.json
Created May 25, 2020 12:10
techboost/common
{
"login": {
"label": "Email address",
"invalidEmail": "Invalid Email",
"password": "Password",
"login": "Login"
},
"invitation": {
"title": "Invitation",
"subtitle": {
{
"login": {
"forgotPassword": "Forgot password ?",
"error": {
"notParticipant": "You are not registered as a participant, please login on website dedicated to organizer."
}
},
"profile": {
"edit": "Edit your profile",
"firstLoginDialog": {
@code-vagabond
code-vagabond / package.json
Created March 16, 2020 14:10
ekipa package.json
{
"name": "web",
"version": "0.0.0",
"license": "MIT",
"scripts": {
"start": "ng serve ekipa --configuration dev --hmr",
"start:ekipa": "ng serve ekipa --configuration dev --hmr",
"start:ekipa:integration": "ng serve ekipa --configuration integration --hmr",
"start:ekipa:production": "node --max_old_space_size=8000 ./node_modules/@angular/cli/bin/ng serve ekipa --configuration production --hmr",
"start:admin": "ng serve admin --configuration dev --hmr",
<div class="d-flex justify-content-center">
<div class="progress-bullets" style="width: 22.5rem;">
<div class="progress-outer">
<div class="line"></div>
<div class="steps d-flex flex-row justify-content-between align-items-center">
<div class="step">
<div class="circle"></div>
<div>Qualifikation</div>
</div>
<div class="step">
@code-vagabond
code-vagabond / reverse.pipe.ts
Created September 16, 2018 23:11
Reverse an observable
import { Pipe, PipeTransform } from '@angular/core';
@Pipe({
name: 'reverse'
})
export class ReversePipe implements PipeTransform {
transform(value) {
if (!value) { return; }
@code-vagabond
code-vagabond / timestamp.js
Created September 16, 2018 21:14
getTimestamp for firestore
getTimeStamp() {
const now = new Date();
now.setUTCHours(now.getUTCHours() + 2);
const date =
now.getUTCFullYear() +
'/' +
(now.getUTCMonth() + 1) +
'/' +
now.getUTCDate();
@code-vagabond
code-vagabond / login.css
Created August 31, 2018 23:40
Styling for login with dark background and white outline, using mat-form-field, appearance = "outline"
input::placeholder {
color: $grey-lighter !important;
}
.mat-form-field-outline {
color: whitesmoke !important;
}
.mat-form-field-outline-thick {
color: white !important;
box-shadow: 1px 0px 10px 0.125em rgba(255, 255, 255, 0.27) !important;
@code-vagabond
code-vagabond / tree
Last active February 18, 2018 13:19
tree src/ -P "*.api.ts"
https://stackoverflow.com/questions/3455625/linux-command-to-print-directory-structure-in-the-form-of-a-tree
export enum SignInActionTypes {
SignIn = '[Auth] Signing In'
}
export class SignIn implements Action {
readonly type = SignInActionTypes.SignIn;
constructor(public payload: {err: any}) {}
}