From 76666b56aa5f071ca91333da1c2c2f85ff25b7e0 Mon Sep 17 00:00:00 2001 From: farid saravi Date: Mon, 10 Aug 2020 19:51:23 +0430 Subject: [PATCH] fix: remove translatable package --- composer.json | 1 - composer.lock | 81 +--------------------- config/translatable.php | 148 ---------------------------------------- 3 files changed, 1 insertion(+), 229 deletions(-) delete mode 100644 config/translatable.php diff --git a/composer.json b/composer.json index ecc3613..adb1df0 100644 --- a/composer.json +++ b/composer.json @@ -9,7 +9,6 @@ "license": "MIT", "require": { "php": "^7.2", - "astrotomic/laravel-translatable": "^11.8", "coraxster/flysystem-aws-s3-v3-minio": "^1.0", "fideloper/proxy": "^4.0", "kalnoy/nestedset": "^5.0", diff --git a/composer.lock b/composer.lock index ccba472..3f28f9a 100644 --- a/composer.lock +++ b/composer.lock @@ -4,87 +4,8 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "33b920bcb91c0553dd5f2a2920690079", + "content-hash": "c41e87ebe57c9f47a0c594757501d667", "packages": [ - { - "name": "astrotomic/laravel-translatable", - "version": "v11.8.3", - "source": { - "type": "git", - "url": "https://github.com/Astrotomic/laravel-translatable.git", - "reference": "104f9501bf94738b6d82984685010e3d8040e891" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Astrotomic/laravel-translatable/zipball/104f9501bf94738b6d82984685010e3d8040e891", - "reference": "104f9501bf94738b6d82984685010e3d8040e891", - "shasum": "" - }, - "require": { - "illuminate/contracts": "5.8.* || ^6.0 || ^7.0", - "illuminate/database": "5.8.* || ^6.0 || ^7.0", - "illuminate/support": "5.8.* || ^6.0 || ^7.0", - "php": ">=7.2" - }, - "require-dev": { - "orchestra/testbench": "3.8.* || ^4.0 || ^5.0", - "phpunit/phpunit": "^8.0 || ^9.0" - }, - "type": "library", - "extra": { - "laravel": { - "providers": [ - "Astrotomic\\Translatable\\TranslatableServiceProvider" - ] - } - }, - "autoload": { - "psr-4": { - "Astrotomic\\Translatable\\": "src/Translatable/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Tom Witkowski", - "email": "gummibeer@astrotomic.info", - "homepage": "https://gummibeer.de", - "role": "Developer" - }, - { - "name": "Dimitrios Savvopoulos", - "email": "ds@dimsav.com", - "homepage": "http://dimsav.com", - "role": "Developer" - } - ], - "description": "A Laravel package for multilingual models", - "homepage": "https://astrotomic.info", - "keywords": [ - "database", - "language", - "laravel", - "translation" - ], - "funding": [ - { - "url": "https://offset.earth/treeware", - "type": "custom" - }, - { - "url": "https://github.com/Gummibeer", - "type": "github" - }, - { - "url": "https://issuehunt.io/r/astrotomic", - "type": "issuehunt" - } - ], - "time": "2020-07-08T17:21:18+00:00" - }, { "name": "aws/aws-sdk-php", "version": "3.134.3", diff --git a/config/translatable.php b/config/translatable.php deleted file mode 100644 index be62d78..0000000 --- a/config/translatable.php +++ /dev/null @@ -1,148 +0,0 @@ - [ - Language::PERSIAN, - Language::ENGLISH, - Language::ARABIC, - ], - - /* - |-------------------------------------------------------------------------- - | Locale separator - |-------------------------------------------------------------------------- - | - | This is a string used to glue the language and the country when defining - | the available locales. Example: if set to '-', then the locale for - | colombian spanish will be saved as 'es-CO' into the database. - | - */ - 'locale_separator' => '-', - - /* - |-------------------------------------------------------------------------- - | Default locale - |-------------------------------------------------------------------------- - | - | As a default locale, Translatable takes the locale of Laravel's - | translator. If for some reason you want to override this, - | you can specify what default should be used here. - | If you set a value here it will only use the current config value - | and never fallback to the translator one. - | - */ - 'locale' => Language::PERSIAN, - - /* - |-------------------------------------------------------------------------- - | Use fallback - |-------------------------------------------------------------------------- - | - | Determine if fallback locales are returned by default or not. To add - | more flexibility and configure this option per "translatable" - | instance, this value will be overridden by the property - | $useTranslationFallback when defined - | - */ - 'use_fallback' => false, - - /* - |-------------------------------------------------------------------------- - | Use fallback per property - |-------------------------------------------------------------------------- - | - | The property fallback feature will return the translated value of - | the fallback locale if the property is empty for the selected - | locale. Note that 'use_fallback' must be enabled. - | - */ - 'use_property_fallback' => true, - - /* - |-------------------------------------------------------------------------- - | Fallback Locale - |-------------------------------------------------------------------------- - | - | A fallback locale is the locale being used to return a translation - | when the requested translation is not existing. To disable it - | set it to false. - | If set to null it will loop through all configured locales until - | one existing is found or end of list reached. The locales are looped - | from top to bottom and for country based locales the simple one - | is used first. So "es" will be checked before "es_MX". - | - */ - 'fallback_locale' => 'en', - - /* - |-------------------------------------------------------------------------- - | Translation Model Namespace - |-------------------------------------------------------------------------- - | - | Defines the default 'Translation' class namespace. For example, if - | you want to use App\Translations\CountryTranslation instead of App\CountryTranslation - | set this to 'App\Translations'. - | - */ - 'translation_model_namespace' => null, - - /* - |-------------------------------------------------------------------------- - | Translation Suffix - |-------------------------------------------------------------------------- - | - | Defines the default 'Translation' class suffix. For example, if - | you want to use CountryTrans instead of CountryTranslation - | application, set this to 'Trans'. - | - */ - 'translation_suffix' => 'Translation', - - /* - |-------------------------------------------------------------------------- - | Locale key - |-------------------------------------------------------------------------- - | - | Defines the 'locale' field name, which is used by the - | translation model. - | - */ - 'locale_key' => 'language_id', - - /* - |-------------------------------------------------------------------------- - | Always load translations when converting to array - |-------------------------------------------------------------------------- - | Setting this to false will have a performance improvement but will - | not return the translations when using toArray(), unless the - | translations relationship is already loaded. - | - */ - 'to_array_always_loads_translations' => true, - - /* - |-------------------------------------------------------------------------- - | Configure the default behavior of the rule factory - |-------------------------------------------------------------------------- - | The default values used to control the behavior of the RuleFactory. - | Here you can set your own default format and delimiters for - | your whole app. - * - */ - 'rule_factory' => [ - 'format' => \Astrotomic\Translatable\Validation\RuleFactory::FORMAT_ARRAY, - 'prefix' => '%', - 'suffix' => '%', - ], -];