Skip to content

Instantly share code, notes, and snippets.

View Krato's full-sized avatar
🗺️
Working!

Eric Lagarda Krato

🗺️
Working!
View GitHub Profile
@Krato
Krato / interface.css
Created February 10, 2023 16:17
Interface.css for pagedjs
/* CSS for Paged.js interface – v0.4 */
/* Change the look */
:root {
--color-background: whitesmoke;
--color-pageSheet: #cfcfcf;
--color-pageBox: violet;
--color-paper: white;
--color-marginBox: transparent;
--pagedjs-crop-color: black;
@Krato
Krato / Laravel Nova snippets.md
Last active November 25, 2020 23:02
A set of snippets I use in Laravel Nova

A set of snippets I use in Laravel Nova

Snippets

Vue,js devtools (Only with manual installation)

cd ./nova 
yarn
mv webpack.mix.js.dist webpack.mix.js
@Krato
Krato / micromodal.css
Created April 6, 2020 13:00
Micromodal CSS
.modal__overlay {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: rgba(0,0,0,0.6);
display: flex;
justify-content: center;
align-items: center;
@Krato
Krato / spain_covid19.csv
Last active March 23, 2020 11:36
Datos del Coronavirus COVID19 en Espña
CCAA Nº Casos
Andalucía 1961
Aragón 638
Asturias 594
Baleares 400
Canarias 481
Cantabria 347
Castilla La Mancha 2078
Castilla y León 2055
Cataluña 5925
var am4geodata_spainProvinces = {
"svg": {
"defs": {
"amcharts:ammap": {
"projection": "mercator",
"leftLongitude": "-9.301684",
"topLatitude": "43.792633",
"rightLongitude": "4.313022",
"bottomLatitude": "31.733447"
}

Keybase proof

I hereby claim:

  • I am krato on github.
  • I am krato (https://keybase.io/krato) on keybase.
  • I have a public key ASCTFLnXpk7HE1fNb8uxCkhYeN-RY-B-H6ZzsXes45gFkQo

To claim this, I am signing this object:

@Krato
Krato / versioned_asset.php
Last active May 6, 2019 10:40
Laravel versioned assets helper #laravel
<?php
/**
* Generate a URL to an application asset with a versioned timestamp parameter.
*
* @param string $path
* @param boolean $secure
* @return string
*/
function versioned_asset($path, $secure = null)
{
@Krato
Krato / Laravel 5 - Multiple optionals parameters in route.md
Last active May 6, 2019 10:40
Laravel 5 - Multiple optionals parameters in route #laravel

Laravel 5 Multiple optionals parameters in route

This is an approach to get the solution of this problem: Imagine that you want to get all files inside a subdirectory and you want to show the url like: yoursite.com/files/folders/first. But you need also to go to yoursite.com/files/folders/second/inside.

How can you achieve that?

With the Laravel Regular Expression Constraint

Route::get('/files/{path?}', 'MyController@view')->where('path', '.*');
/*
Redactor 10.2.3
License: http://imperavi.com/redactor/license/
Updated: August 8, 2016
Modded by Eric Lagarda https://github.com/Krato
*/
(function($)
{