added panel rtl theme

pull/44/head
A1Gard 6 months ago
parent 56d18b1766
commit 6b1b8baeaa

@ -4,7 +4,7 @@ APP_KEY=
APP_DEBUG=true
APP_DEPLOYED=false
APP_TIMEZONE=UTC
APP_URL=http://localhost
APP_URL=http://localhost:8000
APP_LOCALE=en
APP_FALLBACK_LOCALE=en

@ -6,8 +6,43 @@ use App\Models\Area;
use App\Models\Part;
use Illuminate\Support\Facades\Route;
/**
* @param $langCode string code like fa
* @return bool
*/
function langIsRTL($langCode) {
$rtlLanguages = [
'ar', // Arabic
'arc', // Aramaic
'dv', // Divehi
'fa', // Persian (Farsi)
'ha', // Hausa
'he', // Hebrew
'khw', // Khowar
'ks', // Kashmiri
'ku', // Kurdish
'ps', // Pashto
'ur', // Urdu
'yi', // Yiddish
'ug', // Uyghur
'sd', // Sindhi
'syr', // Syriac
'dhv', // Dhivehi
'sqr', // Siirt Arabic
'sam', // Samaritan Aramaic
'man', // Mandaic
'men', // Mende
'nqo', // N'Ko
'phn', // Phoenician
'syr', // Syriac
'th', // Thaana
];
return in_array(strtolower($langCode), $rtlLanguages);
}
/**
* @param $lang code like fa
* @param $lang string code like fa
* @return string
*/
function getEmojiLanguagebyCode($lang): string

@ -6,7 +6,7 @@
@import 'panel/variables';
// Bootstrap
@import 'bootstrap/scss/bootstrap';
//@import 'bootstrap/scss/bootstrap';
/* width */
::-webkit-scrollbar {

@ -38,7 +38,7 @@
color: white;
&:hover {
color: $indigo;
color: $secondary-color-panel;
}
}
}

@ -8,3 +8,4 @@ $line-height-base: 1.6;
$primary-color-panel: #6e0000;
$secondary-color-panel: rgba(139, 0, 139, 0.86) ;
$lighter-color: #282d47;
$text-muted: silver;

@ -1,3 +1,9 @@
@if(langIsRTL(config('app.locale')))
<link rel="stylesheet" href="{{asset('assets/vendor/bootstrap/dist/css/bootstrap.rtl.min.css')}}">
@else
<link rel="stylesheet" href="{{asset('assets/vendor/bootstrap/dist/css/bootstrap.min.css')}}">
@endif
@if(config('app.debug') && !config('app.deployed'))
<!-- Scripts -->
@vite(['resources/sass/app.scss', 'resources/js/app.js'])

@ -16,4 +16,4 @@
@include('components.assets')
</head>
<body>
<body class="@yield('body-class')" @if(langIsRTL(config('app.locale'))) dir="rtl" @endif>

Loading…
Cancel
Save