New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Редактор с проверкой упражнения #660
Conversation
9c479ce
to
8821335
Compare
45eb24f
to
ee5ee5d
Compare
ee5ee5d
to
279ce55
Compare
Codecov Report
@@ Coverage Diff @@
## master #660 +/- ##
============================================
- Coverage 83.59% 78.93% -4.66%
- Complexity 174 192 +18
============================================
Files 56 58 +2
Lines 707 788 +81
============================================
+ Hits 591 622 +31
- Misses 116 166 +50
Continue to review full report at Codecov.
|
</a> | ||
</li> | ||
</ul> | ||
<div class="tab-content card-body" id="pills-tabContent"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
странное ID
используется и kebab-case и camel-case
мб есть линтер на вьюхи чтобы такое ловить? (чтобы в одном стиле было)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
линтера на вьюху нету, фиксанул айдишник
{{ BsForm::open(null, ['wire:submit.prevent' => 'check']) }} | ||
@if(\App\Helpers\ExerciseHelper::exerciseHasTests($exercise)) | ||
@switch($state) | ||
@case(\App\Http\Livewire\ExerciseEditor::STATE_SUCCESS) | ||
<div class="alert alert-success" role="alert"> | ||
{{ __('exercise.show.editor.message.success') }} | ||
</div> | ||
@break | ||
@case(\App\Http\Livewire\ExerciseEditor::STATE_FAILED) | ||
<div class="alert alert-warning" role="alert"> | ||
{{ __('exercise.show.editor.message.failed') }} | ||
</div> | ||
@break | ||
@endswitch | ||
@else | ||
@if ($state === \App\Http\Livewire\ExerciseEditor::STATE_SUCCESS) | ||
<div class="alert alert-success" role="alert"> | ||
{{ __('exercise.show.editor.message.success') }} ({{ __('exercise.show.editor.auth.required') }}) | ||
</div> | ||
@else | ||
<div class="alert alert-success" role="alert"> | ||
{{ __('exercise.show.editor.message.has_not_tests') }} | ||
</div> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
меня вот этот набор алертов несколько смущает, это нельзя сделать как-то аккуратнее?
типа хелпера, который будет возвращать тип алерта и текст внутри? чтобы во вьюхе от такой сложной логики уйти?
897cfbc
to
05c77d1
Compare
124830a
to
feae5bb
Compare
feae5bb
to
a7cde54
Compare
Ограничения:
Можно загружать решение несколько раз со страницы (нет дизейбла после загрузки)
https://fey-sicp.herokuapp.com/exercises/3