From 8bfff7a7bf0f7590d1624e5d91ed01176582d45f Mon Sep 17 00:00:00 2001 From: Roene Date: Mon, 23 Dec 2024 14:19:53 +0100 Subject: [PATCH 1/4] Make use of new colors | Make use of new components --- README.md | 7 +++++++ composer.json | 2 +- resources/views/account/listing.blade.php | 2 +- resources/views/account/partials/buttons.blade.php | 8 ++++---- .../account/partials/details/addtocart.blade.php | 4 ++-- .../account/partials/details/back-button.blade.php | 2 +- .../account/partials/details/description.blade.php | 2 +- .../account/partials/details/edit-button.blade.php | 4 ++-- .../views/account/partials/details/edit.blade.php | 4 ++-- .../partials/details/product/name.blade.php | 4 ++-- .../partials/details/product/price.blade.php | 2 +- .../partials/details/product/quantity.blade.php | 4 ++-- .../partials/details/product/remove.blade.php | 2 +- .../views/account/partials/details/title.blade.php | 14 +++++++------- .../account/partials/details/wishlist.blade.php | 2 +- .../views/account/partials/edit-wishlist.blade.php | 4 ++-- .../account/partials/list-item-title.blade.php | 4 ++-- .../views/account/partials/list-item.blade.php | 8 ++++---- .../account/partials/shared-wishlist.blade.php | 2 +- resources/views/components/button/accent.blade.php | 3 --- resources/views/components/button/link.blade.php | 2 +- .../views/components/button/outline.blade.php | 3 --- resources/views/components/table/header.blade.php | 4 ++-- resources/views/partials/item/add.blade.php | 4 ++-- resources/views/partials/item/button.blade.php | 6 +++--- resources/views/partials/item/login.blade.php | 2 +- resources/views/partials/item/new-list.blade.php | 4 ++-- resources/views/partials/item/title.blade.php | 4 ++-- resources/views/partials/item/view.blade.php | 2 +- 29 files changed, 58 insertions(+), 57 deletions(-) delete mode 100644 resources/views/components/button/accent.blade.php delete mode 100644 resources/views/components/button/outline.blade.php diff --git a/README.md b/README.md index 5e35c9e..093e76d 100644 --- a/README.md +++ b/README.md @@ -28,3 +28,10 @@ The API uses mostly Laravel apiResource endpoints. All of the exposed endpoints | POST /wishlists/item | | Adds a new item to the given wishlist | | PATCH /wishlists/item/{id} | | Updates the data of an item | | DELETE /wishlists/item/{id} | None | Deletes an item | + +## Colors +When you install Rapidez, the colors are already configured in your `tailwind.config.js`. This ensures that your colors are consistently applied across all elements. +Alternatively, if you are using this package standalone, you can copy these variables and customize them to your liking. Colors can be found in the [Rapidez docs](https://docs.rapidez.io/3.x/theming.html#colors). + +## Components +In this package we use the [Rapidez blade-components](https://github.com/rapidez/blade-components). When you install Rapidez, the rapidez/blade-components package is already installed. If you are using this package standalone, you can install them by running `composer require rapidez/blade-components`. diff --git a/composer.json b/composer.json index bf613c1..1f2a869 100644 --- a/composer.json +++ b/composer.json @@ -20,7 +20,7 @@ "illuminate/database": "^10.0|^11.0", "illuminate/support": "^10.0|^11.0", "illuminate/view": "^10.0|^11.0", - "rapidez/core": "^2.8|^3.0", + "rapidez/core": "^3.0", "blade-ui-kit/blade-heroicons": "^2.0" }, "autoload": { diff --git a/resources/views/account/listing.blade.php b/resources/views/account/listing.blade.php index 7641fc5..d183afa 100644 --- a/resources/views/account/listing.blade.php +++ b/resources/views/account/listing.blade.php @@ -10,7 +10,7 @@
diff --git a/resources/views/account/partials/buttons.blade.php b/resources/views/account/partials/buttons.blade.php index 7612d58..ca3c3e9 100644 --- a/resources/views/account/partials/buttons.blade.php +++ b/resources/views/account/partials/buttons.blade.php @@ -1,8 +1,8 @@
- + @lang('Back to dashboard') - - + + @lang('Create new wishlist') - +
diff --git a/resources/views/account/partials/details/addtocart.blade.php b/resources/views/account/partials/details/addtocart.blade.php index c3f20ca..514485e 100644 --- a/resources/views/account/partials/details/addtocart.blade.php +++ b/resources/views/account/partials/details/addtocart.blade.php @@ -1,3 +1,3 @@ - + @lang('Add all items to cart') - + diff --git a/resources/views/account/partials/details/back-button.blade.php b/resources/views/account/partials/details/back-button.blade.php index 92f6a66..81320f8 100644 --- a/resources/views/account/partials/details/back-button.blade.php +++ b/resources/views/account/partials/details/back-button.blade.php @@ -1 +1 @@ -@lang('Back to wishlists') \ No newline at end of file +@lang('Back to wishlists') \ No newline at end of file diff --git a/resources/views/account/partials/details/description.blade.php b/resources/views/account/partials/details/description.blade.php index d77d720..f34412b 100644 --- a/resources/views/account/partials/details/description.blade.php +++ b/resources/views/account/partials/details/description.blade.php @@ -1,3 +1,3 @@ -
+

@{{ wishlist.description }}

\ No newline at end of file diff --git a/resources/views/account/partials/details/edit-button.blade.php b/resources/views/account/partials/details/edit-button.blade.php index 3778597..e52c76b 100644 --- a/resources/views/account/partials/details/edit-button.blade.php +++ b/resources/views/account/partials/details/edit-button.blade.php @@ -1,8 +1,8 @@ @if($editable)
-
@include('rapidez-mw::account.partials.details.edit') diff --git a/resources/views/account/partials/details/edit.blade.php b/resources/views/account/partials/details/edit.blade.php index fa5d509..a59dfa2 100644 --- a/resources/views/account/partials/details/edit.blade.php +++ b/resources/views/account/partials/details/edit.blade.php @@ -1,11 +1,11 @@ @lang('Change name') - +
@lang('Delete wishlist') - +
diff --git a/resources/views/account/partials/details/product/name.blade.php b/resources/views/account/partials/details/product/name.blade.php index d887fff..4b3aaa0 100644 --- a/resources/views/account/partials/details/product/name.blade.php +++ b/resources/views/account/partials/details/product/name.blade.php @@ -1,7 +1,7 @@
@{{ product.name }} - @{{ category }} - @lang('Not in stock') + @{{ category }} + @lang('Not in stock')
diff --git a/resources/views/account/partials/details/product/price.blade.php b/resources/views/account/partials/details/product/price.blade.php index 8212bf6..11c0455 100644 --- a/resources/views/account/partials/details/product/price.blade.php +++ b/resources/views/account/partials/details/product/price.blade.php @@ -1,3 +1,3 @@ - @{{ product.price | price }} + @{{ product.price | price }} \ No newline at end of file diff --git a/resources/views/account/partials/details/product/quantity.blade.php b/resources/views/account/partials/details/product/quantity.blade.php index d3720dd..ac2c77c 100644 --- a/resources/views/account/partials/details/product/quantity.blade.php +++ b/resources/views/account/partials/details/product/quantity.blade.php @@ -3,7 +3,7 @@ +
diff --git a/resources/views/account/partials/details/product/remove.blade.php b/resources/views/account/partials/details/product/remove.blade.php index 204e095..2db3429 100644 --- a/resources/views/account/partials/details/product/remove.blade.php +++ b/resources/views/account/partials/details/product/remove.blade.php @@ -1,7 +1,7 @@ @if($editable) @endif diff --git a/resources/views/account/partials/details/title.blade.php b/resources/views/account/partials/details/title.blade.php index 3194725..4e187ba 100644 --- a/resources/views/account/partials/details/title.blade.php +++ b/resources/views/account/partials/details/title.blade.php @@ -1,10 +1,10 @@
@@ -16,13 +16,13 @@
- - - + + +
- @lang('Share this wishlist') + @lang('Share this wishlist') @endif diff --git a/resources/views/account/partials/details/wishlist.blade.php b/resources/views/account/partials/details/wishlist.blade.php index a398a1c..01e8148 100644 --- a/resources/views/account/partials/details/wishlist.blade.php +++ b/resources/views/account/partials/details/wishlist.blade.php @@ -61,7 +61,7 @@ class="border-b flex flex-wrap items-center gap-y-5 py-5 *:px-2 last:border-none -
+
@include('rapidez-mw::account.partials.details.addtocart')
diff --git a/resources/views/account/partials/edit-wishlist.blade.php b/resources/views/account/partials/edit-wishlist.blade.php index f210994..702db39 100644 --- a/resources/views/account/partials/edit-wishlist.blade.php +++ b/resources/views/account/partials/edit-wishlist.blade.php @@ -1,11 +1,11 @@ @lang('Edit') - +
@lang('Delete wishlist') - +
diff --git a/resources/views/account/partials/list-item-title.blade.php b/resources/views/account/partials/list-item-title.blade.php index d775e8e..fa29a3f 100644 --- a/resources/views/account/partials/list-item-title.blade.php +++ b/resources/views/account/partials/list-item-title.blade.php @@ -1,4 +1,4 @@ -
+
@{{ wishlist.title }} @include('rapidez-mw::account.partials.shared-wishlist') @@ -6,7 +6,7 @@
@include('rapidez-mw::account.partials.edit-wishlist') diff --git a/resources/views/account/partials/list-item.blade.php b/resources/views/account/partials/list-item.blade.php index 83ca965..bfbcb6d 100644 --- a/resources/views/account/partials/list-item.blade.php +++ b/resources/views/account/partials/list-item.blade.php @@ -1,8 +1,8 @@ - +
-
@lang('Number of articles (:count)', ['count' => '@{{ wishlist.items.length }}'])
-
@lang('Latest update: :date', ['date' => '@{{ wishlist.updated_at.substring(0,10) }}'])
-
@{{ wishlist.description }}
+
@lang('Number of articles (:count)', ['count' => '@{{ wishlist.items.length }}'])
+
@lang('Latest update: :date', ['date' => '@{{ wishlist.updated_at.substring(0,10) }}'])
+
@{{ wishlist.description }}
diff --git a/resources/views/account/partials/shared-wishlist.blade.php b/resources/views/account/partials/shared-wishlist.blade.php index 253e0b2..8211a7a 100644 --- a/resources/views/account/partials/shared-wishlist.blade.php +++ b/resources/views/account/partials/shared-wishlist.blade.php @@ -1,3 +1,3 @@ - + (@lang('shared')) \ No newline at end of file diff --git a/resources/views/components/button/accent.blade.php b/resources/views/components/button/accent.blade.php deleted file mode 100644 index d034fdd..0000000 --- a/resources/views/components/button/accent.blade.php +++ /dev/null @@ -1,3 +0,0 @@ -class('rounded bg-ct-accent font-semibold text-white border-b border-black/20') }}> - {{ $slot }} - diff --git a/resources/views/components/button/link.blade.php b/resources/views/components/button/link.blade.php index 01b3121..5ae2a1f 100644 --- a/resources/views/components/button/link.blade.php +++ b/resources/views/components/button/link.blade.php @@ -1,3 +1,3 @@ -merge(['class' => 'w-full flex items-center justify-between text-base font-medium text-ct-primary !p-0 hover:opacity-75']) }}> +merge(['class' => 'w-full flex items-center justify-between text-base font-medium text-primary !p-0 hover:opacity-75']) }}> {{ $slot }} diff --git a/resources/views/components/button/outline.blade.php b/resources/views/components/button/outline.blade.php deleted file mode 100644 index a352efb..0000000 --- a/resources/views/components/button/outline.blade.php +++ /dev/null @@ -1,3 +0,0 @@ -merge(['class' => 'rounded border bg-white text-sm font-medium text-ct-primary']) }}> - {{ $slot }} - diff --git a/resources/views/components/table/header.blade.php b/resources/views/components/table/header.blade.php index b31c4b2..d067940 100644 --- a/resources/views/components/table/header.blade.php +++ b/resources/views/components/table/header.blade.php @@ -1,5 +1,5 @@ -class(['w-full rounded bg-ct-inactive-100']) }}> - +class(['w-full rounded bg-muted']) }}> + {{ $slot }} \ No newline at end of file diff --git a/resources/views/partials/item/add.blade.php b/resources/views/partials/item/add.blade.php index 639b423..40b0120 100644 --- a/resources/views/partials/item/add.blade.php +++ b/resources/views/partials/item/add.blade.php @@ -3,6 +3,6 @@ @include('rapidez-mw::partials.item.view')
\ No newline at end of file diff --git a/resources/views/partials/item/button.blade.php b/resources/views/partials/item/button.blade.php index f88188b..028bcf3 100644 --- a/resources/views/partials/item/button.blade.php +++ b/resources/views/partials/item/button.blade.php @@ -1,8 +1,8 @@ diff --git a/resources/views/partials/item/login.blade.php b/resources/views/partials/item/login.blade.php index eb11063..308e1e1 100644 --- a/resources/views/partials/item/login.blade.php +++ b/resources/views/partials/item/login.blade.php @@ -1,3 +1,3 @@ \ No newline at end of file diff --git a/resources/views/partials/item/new-list.blade.php b/resources/views/partials/item/new-list.blade.php index a1145b4..9f48f2f 100644 --- a/resources/views/partials/item/new-list.blade.php +++ b/resources/views/partials/item/new-list.blade.php @@ -1,6 +1,6 @@
-
\ No newline at end of file diff --git a/resources/views/partials/item/title.blade.php b/resources/views/partials/item/title.blade.php index 572a41d..ff7ce2a 100644 --- a/resources/views/partials/item/title.blade.php +++ b/resources/views/partials/item/title.blade.php @@ -7,7 +7,7 @@ }">
-
+
@include('rapidez-mw::account.partials.details.addtocart')
diff --git a/resources/views/account/partials/list-item-title.blade.php b/resources/views/account/partials/list-item-title.blade.php index fa29a3f..3135fa2 100644 --- a/resources/views/account/partials/list-item-title.blade.php +++ b/resources/views/account/partials/list-item-title.blade.php @@ -1,4 +1,4 @@ -
+
@{{ wishlist.title }} @include('rapidez-mw::account.partials.shared-wishlist') diff --git a/resources/views/account/partials/list-item.blade.php b/resources/views/account/partials/list-item.blade.php index bfbcb6d..7999d34 100644 --- a/resources/views/account/partials/list-item.blade.php +++ b/resources/views/account/partials/list-item.blade.php @@ -1,7 +1,7 @@
-
@lang('Number of articles (:count)', ['count' => '@{{ wishlist.items.length }}'])
+
@lang('Number of articles (:count)', ['count' => '@{{ wishlist.items.length }}'])
@lang('Latest update: :date', ['date' => '@{{ wishlist.updated_at.substring(0,10) }}'])
@{{ wishlist.description }}
diff --git a/resources/views/components/button/link.blade.php b/resources/views/components/button/link.blade.php index 5ae2a1f..259a95e 100644 --- a/resources/views/components/button/link.blade.php +++ b/resources/views/components/button/link.blade.php @@ -1,3 +1,3 @@ -merge(['class' => 'w-full flex items-center justify-between text-base font-medium text-primary !p-0 hover:opacity-75']) }}> +merge(['class' => 'w-full flex items-center justify-between font-medium text-primary !p-0 hover:opacity-75']) }}> {{ $slot }} diff --git a/resources/views/components/dropdown.blade.php b/resources/views/components/dropdown.blade.php index 2056380..0d96708 100644 --- a/resources/views/components/dropdown.blade.php +++ b/resources/views/components/dropdown.blade.php @@ -1,3 +1,3 @@ -
merge(['class' => 'z-10 bg-white border text-base drop-shadow-sm rounded']) }}> +
merge(['class' => 'z-10 bg-white border drop-shadow-sm rounded']) }}> {{ $slot }}
\ No newline at end of file diff --git a/resources/views/components/table/header.blade.php b/resources/views/components/table/header.blade.php index d067940..5ad39ad 100644 --- a/resources/views/components/table/header.blade.php +++ b/resources/views/components/table/header.blade.php @@ -1,4 +1,4 @@ -class(['w-full rounded bg-muted']) }}> +class(['w-full rounded bg']) }}> {{ $slot }} diff --git a/resources/views/partials/item/new-list.blade.php b/resources/views/partials/item/new-list.blade.php index 9f48f2f..a972622 100644 --- a/resources/views/partials/item/new-list.blade.php +++ b/resources/views/partials/item/new-list.blade.php @@ -1,5 +1,5 @@
- diff --git a/resources/views/partials/item/title.blade.php b/resources/views/partials/item/title.blade.php index ff7ce2a..169eb03 100644 --- a/resources/views/partials/item/title.blade.php +++ b/resources/views/partials/item/title.blade.php @@ -7,7 +7,7 @@ }">