Skip to content

Commit

Permalink
Merge pull request #352 from ilhm344/2.0
Browse files Browse the repository at this point in the history
correction of translation of resources
  • Loading branch information
DissNik authored Dec 16, 2023
2 parents be391d3 + f5b43b6 commit ab482d0
Show file tree
Hide file tree
Showing 17 changed files with 40 additions and 39 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<x-sub-title id="make">Make</x-sub-title>

<x-p>
Sometimes you may want to return only part of a template in your HTTP response. For this you can use
Sometimes you need to return only part of a template in your HTTP response. For this you can use
<x-link link="https://laravel.com/docs/blade#rendering-blade-fragments" target="_blank">Blade Fragments</x-link>.<br />
The <em>Fragment</em> decorator allows you to create corresponding blocks.
</x-p>
Expand All @@ -25,7 +25,7 @@
</x-code>

<x-p>
The <code>name()</code> method sets the name for the fragment.
Method <code>name()</code> sets the name for the fragment.
</x-p>

<x-code language="php">
Expand All @@ -50,7 +50,7 @@ public function components(): array
<x-sub-title id="async">Asynchronous event</x-sub-title>

<x-p>
You can wrap an area in a Fragment and hang an event on this area,
You can incorporate an area in a Fragment and set an event on this area,
by calling which it will be possible to update the fragment
</x-p>

Expand Down
4 changes: 2 additions & 2 deletions resources/views/pages/en/components/system_profile.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<x-sub-title id="make">Make</x-sub-title>

<x-p>
The <em>Profile</em> system component is used to display information about an authorized user in
The system component <em>Profile</em> is used to display information about an authorized user in
<strong>MoonShine</strong>.
</x-p>

Expand All @@ -24,7 +24,7 @@ class <code>Profile</code>.
</x-code>

<x-p>
<code>$withBorder</code> - split before the component.
<code>$withBorder</code> - to split before the component.
</x-p>

<x-code language="php">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
</x-p>

<x-p>
You can create a <em>Sidebar</em> using the static <code>make()</code> method
You can create a <em>Sidebar</em> using the static method <code>make()</code>
class <code>Sidebar</code>.
</x-p>

Expand Down
8 changes: 4 additions & 4 deletions resources/views/pages/en/components/system_top_bar.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
</x-p>

<x-p>
You can create a <em>TopBar</em> using the static <code>make()</code> method
You can create a <em>TopBar</em> using the static method <code>make()</code>
class <code>TopBar</code>.
</x-p>

Expand All @@ -24,7 +24,7 @@ class <code>TopBar</code>.
</x-code>

<x-p>
В качестве параметра метод <code>make()</code> принимает массив с компонентами.
As a parameter, method <code>make()</code> takes an array with components.
</x-p>

<x-code language="php">
Expand Down Expand Up @@ -58,8 +58,8 @@ public static function build(): LayoutBuilder
<x-sub-title id="actions">Actions</x-sub-title>

<x-p>
The <code>actions()</code> method of the <em>TopBar</em> component allows you to add additional elements to the areas
<em>actions</em>. The method takes an array of components as a parameter.
Method <code>actions()</code> of the <em>TopBar</em> component allows you to add additional elements to the
<em>actions</em> areas. The method takes an array of components as a parameter.
</x-p>

<x-code language="php">
Expand Down
2 changes: 1 addition & 1 deletion resources/views/pages/en/resources/authorization.blade.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<x-page title="Authorization">

<x-p>
We do not deviate from the Laravel concept and with the help of Laravel policy we can work with
We do not deviate from the Laravel concept and with the Laravel policy help we can work with
access rights within the MoonShine admin panel
</x-p>

Expand Down
5 changes: 3 additions & 2 deletions resources/views/pages/en/resources/events.blade.php
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
<x-page title="Events">

<x-p>
Since MoonShine works based on standard eloquent methods for adding, editing and deleting, you can easily use standard Laravel events:
Since MoonShine operates using standard eloquent methods for adding, editing, and deleting, it is effortless to utilise standard Laravel events:
<x-link link="https://laravel.com/docs/eloquent#events">events</x-link>
</x-p>
<x-p>
But there is also a need to become attached specifically to events within the MoonShine resources! To do this, you need to implement the events you need in the resource.
However, it is also essential to connect with the events within the MoonShine resources.
To achieve this, you must incorporate the necessary events into the resource.
</x-p>

<x-code language="php">
Expand Down
2 changes: 1 addition & 1 deletion resources/views/pages/en/resources/fields.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public function fields(): array // [tl! focus:start]
<x-sub-title id="separate">Field separation</x-sub-title>

<x-p>
Sometimes there is a need to exclude or change the order of some fields in an index or detail page.
Sometimes there is a need to exclude or change the order of some fields order in an index or detail page.
To do this, you can use methods that allow you to redefine fields for the corresponding pages:
<code>indexFields()</code>, <code>formFields()</code> or <code>detailFields()</code>.
</x-p>
Expand Down
4 changes: 2 additions & 2 deletions resources/views/pages/en/resources/filters.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<x-p>
To create filters, fields are also used:
they are displayed only on the main page of the section.
they are displayed only on the section main page.
</x-p>

<x-p>
Expand Down Expand Up @@ -55,7 +55,7 @@ public function filters(): array // [tl! focus:start]
</x-moonshine::alert>

<x-p>
If you need to cache the state of filters, use the <code>saveFilterState</code> property in the resource
If you need to cache the filters state, use the <code>saveFilterState</code> property in the resource
</x-p>
<x-code language="php">
namespace App\MoonShine\Resources;
Expand Down
4 changes: 2 additions & 2 deletions resources/views/pages/en/resources/form.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
</x-p>

<x-p>
It is enough to add rules in the <code>rules()</code> method of the model resource in the usual manner.
It is enough to add rules in the model resource <code>rules()</code> method in the usual manner.
</x-p>

<x-code language="php">
Expand Down Expand Up @@ -132,7 +132,7 @@ public function formButtons(): array
</x-code>

<x-p>
You can also use the <code>buttons</code> method, but in this case the buttons will be on all other pages of the resource
You can also use the <code>buttons</code> method, but in this case, the buttons will be on the resource all other pages
</x-p>

<x-code>
Expand Down
6 changes: 3 additions & 3 deletions resources/views/pages/en/resources/import_export.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public function filters(): array
</x-code>

<x-moonshine::alert type="default" icon="heroicons.information-circle">
Be sure to add ID to the import, otherwise records will only be added without updating existing ones.
Be sure to add ID to the import, otherwise, records will only be added without updating existing ones.
</x-moonshine::alert>

<x-moonshine::divider label="Handler" />
Expand Down Expand Up @@ -239,7 +239,7 @@ public function export(): ?ExportHandler

<x-p>
<em>ImportHandler</em> and <em>ExportHandler</em> extend the base class <em>Handler</em>
which implements additional methods.
that implements additional methods.
</x-p>

<x-moonshine::divider label="icon" />
Expand Down Expand Up @@ -301,7 +301,7 @@ public function import(): ?ImportHandler
</x-p>

<x-moonshine::alert type="default" icon="heroicons.book-open">
The <code>unless()</code> method is the inverse of the <code>when()</code> method.
The <code>unless()</code> method is the <code>when()</code> method the inverse.
</x-moonshine::alert>


Expand Down
16 changes: 8 additions & 8 deletions resources/views/pages/en/resources/index.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<x-sub-title id="basics">Basics</x-sub-title>

<x-p>
At the heart of any admin panel are sections for editing data.
At any admin panel heart are sections for editing data.
<strong>MoonShine</strong> is no exception to this
and uses <code>Eloquent</code> models to work with the database,
and for sections there are standard Laravel resource controllers and resource routes.
Expand All @@ -39,7 +39,7 @@
</x-code>

<x-p>
But this work can be entrusted to the <strong>MoonShine</strong> admin panel,
However, this work can be entrusted to the <strong>MoonShine</strong> admin panel,
which will generate and declare them independently.
</x-p>

Expand All @@ -56,7 +56,7 @@

<x-p>
<ul>
<li>- change the name of your resource if required</li>
<li>- change your resource name if required</li>
<li>- select resource type</li>
</ul>
</x-p>
Expand All @@ -80,7 +80,7 @@
</x-p>

<x-p>
As a result, a <code>PostResource</code> class will be created, which will be the basis of a new section in the panel.<br />
As a result, a <code>PostResource</code> class will be created, which will be a new section basis in the panel.<br />
It is located, by default, in the <code>app/MoonShine/Resources</code> directory.<br />
MoonShine will automatically, based on the name, link the resource to the <code>app/Models/Post</code> model.<br />
The section title will also be generated automatically and will be “Posts”.
Expand Down Expand Up @@ -137,7 +137,7 @@ class PostResource extends ModelResource

<x-p>
Register the resource in the system and immediately add a link to the section in the navigation menu
You can use the service provider <code>MoonShineServiceProvider</code>.
you can use the service provider <code>MoonShineServiceProvider</code>.
</x-p>

<x-code language="php">
Expand Down Expand Up @@ -239,7 +239,7 @@ class PostResource extends ModelResource

<x-p>
By default, when creating and editing a record, a redirect is made to the page with the form,
but this behavior can be controlled
but this behaviour can be controlled
</x-p>

<x-code>
Expand All @@ -263,7 +263,7 @@ public function redirectAfterDelete(): string

<x-p>
It often happens that it is necessary to create a resource in which the ability to delete will be excluded,
or add or edit. And here we are not talking about authorization, but about the global exclusion of these sections.
or add or edit. In addition, here we are not talking about authorization, but about the global exclusion of these sections.
This is done extremely simply using the <code>getActiveActions</code> method in the resource
</x-p>

Expand All @@ -285,7 +285,7 @@ public function getActiveActions(): array // [tl! focus:start]
<x-sub-title id="boot">Boot</x-sub-title>

<x-p>
If you need to add logic to the operation of a resource when it is active and loaded,
If you need to add logic to a resource operation when it is active and loaded,
then use the <code>onBoot</code> method
</x-p>

Expand Down
2 changes: 1 addition & 1 deletion resources/views/pages/en/resources/metrics.blade.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<x-page title="Metrics" :sectionMenu="$sectionMenu ?? null">

<x-p>
On the index page of the resource model, you can display information blocks with statistics - metrics.<br />
On the resource model index page, you can display information blocks with statistics - metrics.<br />
To do this, in the <code>metrics()</code> method, return an array from <code>ValueMetric</code>.
</x-p>

Expand Down
6 changes: 3 additions & 3 deletions resources/views/pages/en/resources/pages.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<x-sub-title id="basics">Basics</x-sub-title>

<x-p>
<strong>MoonShine</strong> provides the ability to customize the crud of <em>ModelResource</em> pages,
<strong>MoonShine</strong> provides the ability to customize the <em>ModelResource</em> pages crud,
for this it is necessary, when creating a resource through the command,
select resource type<br />
<code>Model resource with pages</code>.
Expand Down Expand Up @@ -66,7 +66,7 @@ public function pages(): array // [tl! focus:start]
<x-p>
<x-link link="{{ route('moonshine.page', 'fields-index') }}">Fields</x-link>
in <strong>MoonShine</strong> are used not only for data input, but also for their output.<br />
The <code>fields()</code> method in the <em>crud</em> class of the page allows you to specify the required fields.
The <code>fields()</code> method in the page <em>crud</em> class allows you to specify the required fields.
</x-p>

<x-code language="php">
Expand Down Expand Up @@ -110,7 +110,7 @@ public function fields(): array // [tl! focus:start]

<x-p>
To customize layers, the corresponding methods are used: <code>topLayer()</code>, <code>mainLayer()</code> and
<code>bottomLayer()</code>. Methods must return an array of <x-link link="{{ route('moonshine.page', 'page-class') . '#components' }}">Components</x-link>.
<code>bottomLayer()</code>. Methods must return <x-link link="{{ route('moonshine.page', 'page-class') . '#components' }}">Components</x-link> an array.
</x-p>

<x-code language="php">
Expand Down
4 changes: 2 additions & 2 deletions resources/views/pages/en/resources/query.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<x-sub-title id="filter">Request</x-sub-title>

<x-p>
It is often necessary to initially change all of the resource's queries to the database.<br />
It is often necessary to initially change the resource's queries all to the database.<br />
You can easily override <em>query builder</em> in a resource.
</x-p>

Expand Down Expand Up @@ -106,7 +106,7 @@ public function searchQuery(): Builder // [tl! focus:start]
<x-sub-title id="order">Sorting</x-sub-title>

<x-p>
By overriding the <code>resolveOrder()</code> method, you can customize the sorting of records.
By overriding the <code>resolveOrder()</code> method, you can customize the records sorting.
</x-p>

<x-code language="php">
Expand Down
2 changes: 1 addition & 1 deletion resources/views/pages/en/resources/query_tags.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<x-sub-title id="basics">Basics</x-sub-title>

<x-p>
Sometimes there is a need to create a set of filters (a selection of results)
Sometimes there is a need to create filters (results a selection) a set
and display it on the listing. Tags have been created for such situations.
</x-p>

Expand Down
4 changes: 2 additions & 2 deletions resources/views/pages/en/resources/search.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ public function search(): array
<x-sub-title id="relation">Search by relationship</x-sub-title>

<x-p>
You can search by relationships; to do this, you need to specify which field of the relationship to search.
You can search by relationships; to do this, you need to specify which the relationship field to search.
</x-p>

<x-code language="php">
Expand Down Expand Up @@ -180,7 +180,7 @@ public function search(): array
</x-p>

<x-p>
This package uses the <code>Algolia</code> search engine, which takes into account the context and type of request,
This package uses the <code>Algolia</code> search engine, which takes into account the context, and request type,
possible typos, synonyms and word forms, entering queries in different languages and much more.
</x-p>

Expand Down
2 changes: 1 addition & 1 deletion resources/views/pages/en/resources/table.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public function buttons(): array
<x-sub-title id="attributes">Attributes</x-sub-title>

<x-p>
Through model resources, it is possible to customize the <code>tr</code> and <code>td</code> of the data table.<br />
Through model resources, it is possible to customize the data table <code>tr</code> and <code>td</code>.<br />
To do this, you must use the appropriate <code>trAttributes()</code> and <code>tdAttributes()</code> methods,
which need to pass a closure that returns attributes for the <x-link link="{{ route('moonshine.page', 'components-table') }}">table component</x-link>.
</x-p>
Expand Down

0 comments on commit ab482d0

Please sign in to comment.