Skip to content

Commit 347a864

Browse files
committed
rename filamerce to webard
1 parent 87ce48d commit 347a864

File tree

16 files changed

+58
-58
lines changed

16 files changed

+58
-58
lines changed

README.md

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# Filament Translatable
22

3-
[![Latest Version on Packagist](https://img.shields.io/packagist/v/filamerce/filament-translatable.svg?style=flat-square)](https://packagist.org/packages/filamerce/filament-translatable)
4-
[![Total Downloads](https://img.shields.io/packagist/dt/filamerce/filament-translatable.svg?style=flat-square)](https://packagist.org/packages/filamerce/filament-translatable)
3+
[![Latest Version on Packagist](https://img.shields.io/packagist/v/webard/filament-translatable.svg?style=flat-square)](https://packagist.org/packages/webard/filament-translatable)
4+
[![Total Downloads](https://img.shields.io/packagist/dt/webard/filament-translatable.svg?style=flat-square)](https://packagist.org/packages/webard/filament-translatable)
55

66
Filament Translatable is a set of tools that help manage translations.
77

8-
![translatable component](https://raw.githubusercontent.com/filamerce/filament-translatable/refs/heads/filament-4/screenshots/component.png)
8+
![translatable component](https://raw.githubusercontent.com/webard/filament-translatable/refs/heads/filament-4/screenshots/component.png)
99

1010
## Installation
1111

@@ -17,7 +17,7 @@ Filament Translatable is a set of tools that help manage translations.
1717
You can install the package via composer:
1818

1919
```bash
20-
composer require filamerce/filament-translatable
20+
composer require webard/filament-translatable
2121
```
2222

2323
Publish the assets:
@@ -37,12 +37,12 @@ The package from [Spatie](https://github.com/spatie/laravel-translatable) is the
3737

3838
The package from [Astrotomic](https://github.com/astrotomic/laravel-translatable) is an alternative supported way of handling translations.
3939

40-
Follow the [instructions](https://docs.astrotomic.info/laravel-translatable/installation#models) to properly configure your models, but instead of using the `Translatable` trait from the Astrotomic package, please use `Filamerce\FilamentTranslatable\Traits\AstrotomicTranslatable`.
40+
Follow the [instructions](https://docs.astrotomic.info/laravel-translatable/installation#models) to properly configure your models, but instead of using the `Translatable` trait from the Astrotomic package, please use `Webard\FilamentTranslatable\Traits\AstrotomicTranslatable`.
4141

4242
If you use the Astrotomic package, please configure the plugin to work in Astrotomic mode:
4343

4444
```php
45-
use Filamerce\FilamentTranslatable\Enums\TranslationMode;
45+
use Webard\FilamentTranslatable\Enums\TranslationMode;
4646

4747
FilamentTranslatablePlugin::make()
4848
->translationMode(TranslationMode::Astrotomic)
@@ -66,7 +66,7 @@ Or per field:
6666
## Setup
6767

6868
```php
69-
use Filamerce\FilamentTranslatable\FilamentTranslatablePlugin;
69+
use Webard\FilamentTranslatable\FilamentTranslatablePlugin;
7070

7171
public function panel(Panel $panel): Panel
7272
{
@@ -150,7 +150,7 @@ TextInput::make('name')
150150
->translatable()
151151
```
152152

153-
![translatable macro](https://raw.githubusercontent.com/filamerce/filament-translatable/refs/heads/filament-4/screenshots/macro.png)
153+
![translatable macro](https://raw.githubusercontent.com/webard/filament-translatable/refs/heads/filament-4/screenshots/macro.png)
154154

155155
#### Marking field as required for specified locale
156156

@@ -205,7 +205,7 @@ TextInput::make('price')
205205
->flagWidth('48px')
206206
```
207207

208-
![translatable custom macro](https://raw.githubusercontent.com/filamerce/filament-translatable/refs/heads/filament-4/screenshots/macro2.png)
208+
![translatable custom macro](https://raw.githubusercontent.com/webard/filament-translatable/refs/heads/filament-4/screenshots/macro2.png)
209209

210210
> [!CAUTION]
211211
> Be sure to set field-specific methods like `required()` or `requiredDefaultLocale()` **before** calling the `translatable()` method.
@@ -216,15 +216,15 @@ TextInput::make('price')
216216
By using the `Translations` component, you can easily configure your [form fields](https://filamentphp.com/docs/4.x/forms/fields/getting-started) to support multiple languages and provide translations for each locale.
217217

218218
```php
219-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
219+
use Webard\FilamentTranslatable\Forms\Component\Translations;
220220

221221
Translations::make('translations') // name is required to properly handle actions
222222
->schema([
223223
TextInput::make('name')
224224
])
225225
```
226226

227-
![translatable horizontal component](https://raw.githubusercontent.com/filamerce/filament-translatable/refs/heads/filament-4/screenshots/horizontal-component.png)
227+
![translatable horizontal component](https://raw.githubusercontent.com/webard/filament-translatable/refs/heads/filament-4/screenshots/horizontal-component.png)
228228

229229
> [!NOTE]
230230
> Using the `translatable()` method within the `Translations` component is not needed.
@@ -247,7 +247,7 @@ Translations::make('translations')
247247
You have the flexibility to customize the translation label for each field in each locale. You can use the `fieldTranslatableLabel()` method to provide custom labels based on the field instance and the current locale.
248248

249249
```php
250-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
250+
use Webard\FilamentTranslatable\Forms\Component\Translations;
251251

252252
Translations::make()
253253
->schema([
@@ -261,7 +261,7 @@ use Filamerce\FilamentTranslatable\Forms\Component\Translations;
261261
If you want to add a prefix or suffix locale label to the form field, you can use the `prefixLocaleLabel()` or `suffixLocaleLabel()` method. This makes it easier for users to identify the language associated with each field.
262262

263263
```php
264-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
264+
use Webard\FilamentTranslatable\Forms\Component\Translations;
265265

266266
Translations::make('translations')
267267
->schema([
@@ -276,7 +276,7 @@ Translations::make('translations')
276276
By default, the prefix/suffix locale display name is generated from the locale code and enclosed in parentheses, "()". You may customize this using the `preformLocaleLabelUsing()` method:
277277

278278
```php
279-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
279+
use Webard\FilamentTranslatable\Forms\Component\Translations;
280280

281281
Translations::make('translations')
282282
->preformLocaleLabelUsing(fn (string $locale, string $label) => "[{$label}]");
@@ -288,7 +288,7 @@ Additionally, if you need to access the current form field instance, you can inj
288288

289289
```php
290290
use Filament\Forms\Components\Component;
291-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
291+
use Webard\FilamentTranslatable\Forms\Component\Translations;
292292

293293
Translations::make('translations')
294294
// ...
@@ -310,7 +310,7 @@ You may add actions before each container of child components using the `actions
310310
```php
311311

312312
use Filament\Forms\Components\Actions\Action;
313-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
313+
use Webard\FilamentTranslatable\Forms\Component\Translations;
314314

315315
Translations::make('translations')
316316
->actions([
@@ -325,7 +325,7 @@ If you wish to access the locale that has been passed to the action, define an `
325325
```php
326326

327327
use Filament\Forms\Components\Actions\Action;
328-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
328+
use Webard\FilamentTranslatable\Forms\Component\Translations;
329329

330330
Translations::make()
331331
->actions([
@@ -345,7 +345,7 @@ If you wish to access the current locale instance for the field, define a `$loca
345345
```php
346346

347347
use Filament\Forms\Components\TextInput;
348-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
348+
use Webard\FilamentTranslatable\Forms\Component\Translations;
349349

350350
Translations::make()
351351
->schema(fn (string $locale) => [TextInput::make('title')->required($locale == 'en')])
@@ -355,7 +355,7 @@ Translations::make()
355355
By default, the translate component and its content are wrapped in a container styled as a card. You may remove the styled container using `contained()`:
356356

357357
```php
358-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
358+
use Webard\FilamentTranslatable\Forms\Component\Translations;
359359

360360
Translations::make()
361361
->contained(false)
@@ -366,7 +366,7 @@ Translations::make()
366366
You can display translations as vertical tabs:
367367

368368
```php
369-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
369+
use Webard\FilamentTranslatable\Forms\Component\Translations;
370370

371371
Translations::make()
372372
->vertical()
@@ -377,7 +377,7 @@ Translations::make()
377377
You can customize plugin settings directly on the component:
378378

379379
```php
380-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
380+
use Webard\FilamentTranslatable\Forms\Component\Translations;
381381

382382
Translations::make()
383383
->displayNamesInLocaleLabels(false)
@@ -389,7 +389,7 @@ Translations::make()
389389
The `exclude` feature allows you to specify fields that you don't want to include in the translation process. This can be useful for fields that contain dynamic content or that shouldn't be translated into other languages.
390390

391391
```php
392-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
392+
use Webard\FilamentTranslatable\Forms\Component\Translations;
393393

394394
Translations::make('translations')
395395
->schema([
@@ -429,7 +429,7 @@ With `exclude`:
429429
To publish the views, run:
430430

431431
```bash
432-
php artisan vendor:publish --provider="Filamerce\\FilamentTranslatable\\FilamentTranslatableProvider" --tag="filament-translatable-views"
432+
php artisan vendor:publish --provider="Webard\\FilamentTranslatable\\FilamentTranslatableProvider" --tag="filament-translatable-views"
433433
```
434434

435435
## Testing

composer.json

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
{
2-
"name": "filamerce/filament-translatable",
2+
"name": "webard/filament-translatable",
33
"description": "Highly customizable Translation component for FilamentPHP.",
44
"keywords": [
55
"webard",
6-
"filamerce",
6+
"webard",
77
"laravel",
88
"filament",
99
"filamentphp",
@@ -15,10 +15,10 @@
1515
"filament-translatable",
1616
"filament-translate-field"
1717
],
18-
"homepage": "https://github.com/filamerce/filament-translatable",
18+
"homepage": "https://github.com/webard/filament-translatable",
1919
"support": {
20-
"issues": "https://github.com/filamerce/filament-translatable/issues",
21-
"source": "https://github.com/filamerce/filament-translatable"
20+
"issues": "https://github.com/webard/filament-translatable/issues",
21+
"source": "https://github.com/webard/filament-translatable"
2222
},
2323
"license": "MIT",
2424
"authors": [
@@ -47,13 +47,13 @@
4747
},
4848
"autoload": {
4949
"psr-4": {
50-
"Filamerce\\FilamentTranslatable\\": "src/",
51-
"Filamerce\\FilamentTranslatable\\Database\\Factories\\": "database/factories/"
50+
"Webard\\FilamentTranslatable\\": "src/",
51+
"Webard\\FilamentTranslatable\\Database\\Factories\\": "database/factories/"
5252
}
5353
},
5454
"autoload-dev": {
5555
"psr-4": {
56-
"Filamerce\\FilamentTranslatable\\Tests\\": "tests/src"
56+
"Webard\\FilamentTranslatable\\Tests\\": "tests/src"
5757
}
5858
},
5959
"scripts": {
@@ -73,7 +73,7 @@
7373
"extra": {
7474
"laravel": {
7575
"providers": [
76-
"Filamerce\\FilamentTranslatable\\FilamentTranslatableServiceProvider"
76+
"Webard\\FilamentTranslatable\\FilamentTranslatableServiceProvider"
7777
]
7878
}
7979
},

resources/views/forms/components/translation-tab.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
'tabindex' => '0',
3030
'wire:key' =>
3131
"{$this->getId()}.{$getStatePath()}." .
32-
\Filamerce\FilamentTranslatable\Forms\Component\Translations::class .
32+
\Webard\FilamentTranslatable\Forms\Component\Translations::class .
3333
".tabs.{$id}",
3434
],
3535
escape: false,

resources/views/forms/components/translations.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
@php
2-
use Filamerce\FilamentTranslatable\Forms\Component\Translations\Tab;
2+
use Webard\FilamentTranslatable\Forms\Component\Translations\Tab;
33
$activeTab = $getActiveTab();
44
$isContained = $isContained();
55
$isVertical = $isVertical();

src/Enums/TranslationMode.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
declare(strict_types=1);
44

5-
namespace Filamerce\FilamentTranslatable\Enums;
5+
namespace Webard\FilamentTranslatable\Enums;
66

77
enum TranslationMode
88
{

src/FilamentTranslatablePlugin.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
<?php
22

3-
namespace Filamerce\FilamentTranslatable;
3+
namespace Webard\FilamentTranslatable;
44

55
use Closure;
66
use Filament\Contracts\Plugin;
77
use Filament\Panel;
88
use Filament\Support\Concerns\EvaluatesClosures;
9-
use Filamerce\FilamentTranslatable\Enums\TranslationMode;
9+
use Webard\FilamentTranslatable\Enums\TranslationMode;
1010

1111
class FilamentTranslatablePlugin implements Plugin
1212
{

src/FilamentTranslatableServiceProvider.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
<?php
22

3-
namespace Filamerce\FilamentTranslatable;
3+
namespace Webard\FilamentTranslatable;
44

55
use Closure;
66
use Filament\Forms\Components\Field;
77
use Filament\Support\Assets\Asset;
88
use Filament\Support\Assets\Css;
99
use Filament\Support\Facades\FilamentAsset;
10-
use Filamerce\FilamentTranslatable\Forms\Component\Translations;
11-
use Filamerce\FilamentTranslatable\Testing\TestsFilamentTranslateField;
10+
use Webard\FilamentTranslatable\Forms\Component\Translations;
11+
use Webard\FilamentTranslatable\Testing\TestsFilamentTranslateField;
1212
use Livewire\Features\SupportTesting\Testable;
1313
use Spatie\LaravelPackageTools\Package;
1414
use Spatie\LaravelPackageTools\PackageServiceProvider;
@@ -104,7 +104,7 @@ public function packageBooted(): void
104104

105105
protected function getAssetPackageName(): ?string
106106
{
107-
return 'filamerce/filament-translatable';
107+
return 'webard/filament-translatable';
108108
}
109109

110110
/**

src/Forms/Component/Translations.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
<?php
22

3-
namespace Filamerce\FilamentTranslatable\Forms\Component;
3+
namespace Webard\FilamentTranslatable\Forms\Component;
44

55
use Closure;
66
use Filament\Actions\Action;
77
use Filament\Forms\Components\Field;
88
use Filament\Schemas\Components\Component;
99
use Filament\Schemas\Components\Tabs;
1010
use Filament\Schemas\Schema;
11-
use Filamerce\FilamentTranslatable\Enums\TranslationMode;
12-
use Filamerce\FilamentTranslatable\FilamentTranslatablePlugin;
13-
use Filamerce\FilamentTranslatable\Forms\Component\Translations\Tab;
11+
use Webard\FilamentTranslatable\Enums\TranslationMode;
12+
use Webard\FilamentTranslatable\FilamentTranslatablePlugin;
13+
use Webard\FilamentTranslatable\Forms\Component\Translations\Tab;
1414
use Illuminate\Contracts\Support\Htmlable;
1515
use Illuminate\Support\Collection;
1616
use Illuminate\Support\HtmlString;

src/Forms/Component/Translations/Tab.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Filamerce\FilamentTranslatable\Forms\Component\Translations;
3+
namespace Webard\FilamentTranslatable\Forms\Component\Translations;
44

55
class Tab extends \Filament\Schemas\Components\Tabs\Tab
66
{

src/Testing/TestsFilamentTranslateField.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?php
22

3-
namespace Filamerce\FilamentTranslatable\Testing;
3+
namespace Webard\FilamentTranslatable\Testing;
44

55
use Livewire\Features\SupportTesting\Testable;
66

0 commit comments

Comments
 (0)