Skip to content

Commit 4cdb59c

Browse files
Release v4.0.10 (#56)
* docs: update installation command to remove version constraint Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * chore: update CI pipeline to remove php-lint job and add lint scripts Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * feat: upgrade larastan and rector to versions 3.0 and 2.0 respectively Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * feat: update phpstan baseline errors and improve type hints in models Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix(ci): Avoid pull_request from trigger events in CI pipeline configuration Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * Update screenshot.png Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix: support for handling flash message updates via Livewire events Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix: update stylesheet link in error Blade templates Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix redirection issue when a delivery address is selected (#52) * fix redirection issue when a delivery address is selected * phone number input not rendering properly when you redirect with navigate: true * feat(booking): refactor date handling and optimize date preparation logic - Changed `$this->dates` to `$dates` in the date input view - Simplified date preparation by adding `prepareDates()` method - Removed old `disabledDates()` and `dates()` methods - Updated view to use `disabledDates` from the new property Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix(booking): add return type declaration to prepareDates method Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix: set default value of hideEmpty to true in CategoryList component Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * feat(cart): add computed property for cart total in CartBox component Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * feat(cart): move mobile cart button to a separate component and include it using livewire @teleport Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * feat: conditionally hide footer on the menus page Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * style(menu): improve menu item loading behavior Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix(menu): enhance grouped menu item image styling and spacing Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * Compile Assets * feat: update Livewire components to remove Locked attribute from Computed properties and add orderType mock in CartBoxTest Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * feat(reservation-preview): add fallback for no reservation found Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * feat: update flash message modal button to support action URLs and text Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * style: change card background color to white in reservation and booking views Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * docs: update usage section to explain Orange theme integration in TastyIgniter Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * docs: fix broken links Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix(docs): update wording in Usage sections for clarity Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix: ensure address fields are included when saving order Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * test: update spacing in CheckoutTest to improve readability Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix: remove duplicate ajaxFail event listener in checkout.js Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix: update styling for newsletter subscribe form and restaurant order views Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix(search): change input group background color to white in menu search Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * feat(menu): add option to hide unavailable menu items and update UI Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * feat(tests): update mealtime title assertion and add note for future merge Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * refactor(ListMenuItems): simplify filter callback in processMenuItems method and specify return type for filter callback in mealtimeTitles method Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix: use nullsafe operator for payment processing check in OrderPreview Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> * fix: issue adding checkbox menu item option to cart and updating existing cart item Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> --------- Signed-off-by: Sam Poyigi <6567634+sampoyigi@users.noreply.github.com> Co-authored-by: Obinna Elvis Okechukwu <dreamor47@gmail.com> Co-authored-by: sampoyigi <sampoyigi@users.noreply.github.com>
1 parent 0fbbada commit 4cdb59c

16 files changed

Lines changed: 78 additions & 30 deletions

phpstan-baseline.neon

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,12 @@ parameters:
1212
count: 1
1313
path: src/Data/LocationData.php
1414

15+
-
16+
message: '#^Access to an undefined property Igniter\\Cart\\Models\\Menu\:\:\$mealtimes\.$#'
17+
identifier: property.notFound
18+
count: 1
19+
path: src/Data/MenuItemData.php
20+
1521
-
1622
message: '#^Property Igniter\\Orange\\Livewire\\LeaveReview\:\:\$customerReview \(Igniter\\Flame\\Database\\Model\|null\) does not accept Illuminate\\Database\\Eloquent\\Model\|null\.$#'
1723
identifier: assign.propertyType

resources/views/includes/cartbox/item-options-checkbox.blade.php

Lines changed: 24 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,30 @@
11
@foreach ($optionValues->sortBy('priority') as $optionValue)
22
<div @class(['form-check', 'py-1' => !$loop->first || !$loop->last])>
33
<input
4-
x-on:change="calculateTotal()"
5-
wire:model.fill="menuOptions.{{ $menuOption->menu_option_id }}.option_values.{{$optionValue->menu_option_value_id}}"
4+
x-data="{
5+
key: '{{ $menuOption->menu_option_id }}',
6+
id: {{ $optionValue->menu_option_value_id }},
7+
init() {
8+
$wire.menuOptions[this.key] ??= { option_values: [] };
9+
10+
const values = $wire.menuOptions[this.key].option_values;
11+
if ($el.checked && !values.includes(this.id)) {
12+
values.push(this.id);
13+
}
14+
$wire.set(`menuOptions.${this.key}.option_values`, values, false);
15+
},
16+
toggle() {
17+
const values = $wire.menuOptions[this.key]?.option_values ?? [];
18+
const updated = $el.checked
19+
? [...new Set([...values, this.id])]
20+
: values.filter(v => v !== this.id);
21+
22+
$wire.set(`menuOptions.${this.key}.option_values`, updated, false);
23+
calculateTotal();
24+
}
25+
}"
26+
x-init="init"
27+
x-on:change="toggle"
628
type="checkbox"
729
class="form-check-input"
830
id="menuOptionCheck{{ $menuOptionValueId = $optionValue->menu_option_value_id }}"

resources/views/includes/cartbox/item-options-quantity.blade.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,10 @@ class="btn btn-outline-secondary btn-sm lh-sm p-0 border-2 rounded-circle"
2020
><i class="fa fa-minus fa-fw"></i></button>
2121
<input
2222
x-model="optionQuantity"
23-
x-init="$watch('optionQuantity', () => calculateTotal() || $wire.set('menuOptions.{{ $menuOption->menu_option_id }}.option_values.{{ $menuOptionValueId }}.qty', optionQuantity, false))"
23+
x-init="
24+
$wire.set('menuOptions.{{ $menuOption->menu_option_id }}.option_values.{{ $menuOptionValueId }}.qty', optionQuantity, false);
25+
$watch('optionQuantity', () => calculateTotal() || $wire.set('menuOptions.{{ $menuOption->menu_option_id }}.option_values.{{ $menuOptionValueId }}.qty', optionQuantity, false))
26+
"
2427
type="text"
2528
class="form-control bg-transparent shadow-none border-0 text-center p-0"
2629
id="menuOptionQuantity{{ $menuOptionValueId }}"

resources/views/includes/cartbox/item-options-select.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<select
22
x-on:change="calculateTotal()"
3-
wire:model="menuOptions.{{ $menuOption->menu_option_id }}.option_values.0"
3+
wire:model.fill="menuOptions.{{ $menuOption->menu_option_id }}.option_values.0"
44
name="menuOptions[{{ $menuOption->menu_option_id }}][option_values][]"
55
class="form-select"
66
>

resources/views/includes/cartbox/items.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ class="cart-items mb-3"
44
>
55
<ul class="list-unstyled user-select-none mb-0">
66
@foreach ($cart->content()->reverse() as $cartItem)
7-
<li @class(['d-flex align-items-start', 'mb-3' => !$loop->last])>
7+
<li @class(['d-flex align-items-start', 'mb-3' => !$loop->last]) wire:key="cart-item-{{ $cartItem->rowId }}">
88
@unless($previewMode)
99
<div class="me-3 text-nowrap">
1010
<button

resources/views/includes/menu/item.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ class="text-warning"
6868
@if (!$menuItemData->mealtimeIsAvailable())
6969
<div class="breadcrumb-item">
7070
<i class="far fa-clock text-danger"></i>
71-
<small class="text-danger">{{ $menuItemData->mealtimeTitles() }}</small>
71+
<small class="text-danger">@lang('igniter.cart::default.mealtimes.text_available') {{ $menuItemData->mealtimeTitles() }}</small>
7272
</div>
7373
@endif
7474
</div>

resources/views/includes/menu/search.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
id="menu-search"
33
wire:submit="$refresh"
44
>
5-
<div class="input-group border border-2 rounded">
5+
<div class="input-group bg-white border border-2 rounded">
66
<div
77
class="bg-white d-inline-flex align-items-center py-1 px-2 rounded"
88
><i class="fa fa-search"></i></div>

resources/views/includes/order/items.blade.php

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

4848
<div class="cart-totals">
4949
<div class="table-responsive">
50-
<table class="table table-sm mb-0">
50+
<table class="table table-sm table-borderless mb-0">
5151
<tbody>
5252
<tr>
5353
<td class="border-top p-0" colspan="99999"></td>

resources/views/includes/order/restaurant.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<dl class="no-spacing mb-0">
1010
<dd><h2 class="h4 mb-0 fw-normal">{{ $location->location_name }}</h2></dd>
1111
<dd>
12-
<span class="text-muted text-truncate">{{ format_address($location->getAddress(), false) }}</span>
12+
<span class="text-muted">{{ format_address($location->getAddress(), false) }}</span>
1313
</dd>
1414
<dd>{{ $location->location_telephone }}</dd>
1515
<dd>

resources/views/livewire/newsletter-subscribe-form.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ class="btn btn btn-light rounded ms-2"
2121
<x-igniter-orange::forms.error field="email" class="text-danger" />
2222
</x-igniter-orange::forms.form>
2323
@else
24-
<div class="alert alert-success">
24+
<div class="alert alert-success p-0">
2525
{{ $message }}
2626
</div>
2727
@endunless

0 commit comments

Comments
 (0)