Skip to content

Instantly share code, notes, and snippets.

@atmonshi
atmonshi / GMDColors.php
Last active December 10, 2016 13:54
A Simple function to return Hex Color Code base on google material design colors , thanks to https://github.com/danlevan/google-material-color . to see all colors check https://material.google.com/style/color.html#color-color-palette.
/**
* A Simple function to return Hex Color Code base on google material design colors
*
* thanks to https://github.com/danlevan/google-material-color
*
* to see all colors : https://material.google.com/style/color.html#color-color-palette .
* check the code for the White and Black , there is more Options
*
* @param string $color the color name , just replace any spaces with _ as : Deep Purple => Deep_Purple
* @param string $accent the accent of the color you want like 900 or A700 . default is 500
@atmonshi
atmonshi / Apple_mobile_device_types.php
Last active September 26, 2018 08:42 — forked from adamawolf/Apple_mobile_device_types.txt
a PHP function to get matching product names for Apple's mobile device codes types a.k.a. machine ids
function getAppleDeviceName($modle)
{
switch ($modle) {
case "i386" :
return "iPhone Sireturnv mulator";
case "x86_64" :
return "iPhone Sireturn mulator";
case "iPhone1,1" :
return "iPhone";
case "iPhone1,2" :
@atmonshi
atmonshi / Wizard.php
Created October 28, 2023 23:19
reactive Wizard filament
<?php
namespace App\Filament\Pages;
use Filament\Forms\Components\Select;
use Filament\Forms\Components\TextInput;
use Filament\Forms\Form;
use Filament\Forms\Get;
use Filament\Pages\Page;
use Filament\Forms\Components\Wizard as WizardField;