Skip to content

Commit 9b8a8ee

Browse files
committed
Initial commit
0 parents  commit 9b8a8ee

27 files changed

+7334
-0
lines changed

.editorconfig

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
root = true
2+
3+
[*]
4+
charset = utf-8
5+
end_of_line = lf
6+
insert_final_newline = true
7+
indent_style = space
8+
indent_size = 4
9+
trim_trailing_whitespace = true
10+
11+
[*.md]
12+
trim_trailing_whitespace = false
13+
14+
[*{.yml,.yaml,.css,.js,.json}]
15+
indent_size = 2

.gitignore

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/node_modules
2+
/vendor
3+
.idea
4+
.DS_Store
5+
composer.lock
6+
.phpunit.result.cache

LICENSE.md

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2024 Arthur Monney
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Whitespace-only changes.

composer.json

+55
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
{
2+
"name": "laravelcm/livewire-slide-overs",
3+
"description": "Livewire component that provides drawers (slide overs) that support multiple children while maintaining state.",
4+
"keywords": [
5+
"laravel",
6+
"slide-overs",
7+
"livewire"
8+
],
9+
"license": "MIT",
10+
"authors": [
11+
{
12+
"name": "Arthur Monney",
13+
"email": "[email protected]"
14+
}
15+
],
16+
"require": {
17+
"php": "^8.2",
18+
"livewire/livewire": "^3.4",
19+
"spatie/laravel-package-tools": "^1.15"
20+
},
21+
"require-dev": {
22+
"orchestra/testbench": "^8.5",
23+
"laravel/pint": "^1.1",
24+
"pestphp/pest": "^2.34",
25+
"pestphp/pest-plugin-livewire": "^2.1"
26+
},
27+
"autoload": {
28+
"psr-4": {
29+
"Laravelcm\\LivewireSlideOvers\\": "src/"
30+
}
31+
},
32+
"autoload-dev": {
33+
"psr-4": {
34+
"Laravelcm\\LivewireSlideOvers\\Tests\\": "tests/"
35+
}
36+
},
37+
"extra": {
38+
"laravel": {
39+
"providers": [
40+
"Laravelcm\\LivewireSlideOvers\\LivewireSlideOverServiceProvider"
41+
]
42+
}
43+
},
44+
"scripts": {
45+
"test": "vendor/bin/pest",
46+
"pint": "vendor/bin/pint"
47+
},
48+
"minimum-stability": "dev",
49+
"prefer-stable": true,
50+
"config": {
51+
"allow-plugins": {
52+
"pestphp/pest-plugin": true
53+
}
54+
}
55+
}

config/livewire-slide-over.php

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
return [
6+
7+
/*
8+
|--------------------------------------------------------------------------
9+
| Default Slide Over Position
10+
|--------------------------------------------------------------------------
11+
| Configure which way the slide-over will open
12+
|
13+
| Available slide overs position
14+
| Position::Right, Position::Left, Position::Bottom
15+
|
16+
*/
17+
18+
'default_position' => \Laravelcm\LivewireSlideOvers\Position::Right,
19+
20+
/*
21+
|--------------------------------------------------------------------------
22+
| Slide Over Component Defaults
23+
|--------------------------------------------------------------------------
24+
|
25+
| Configure the default properties for a slide-over component.
26+
|
27+
| Supported slide_over_max_width
28+
| 'sm', 'md', 'lg', 'xl', '2xl', '3xl', '4xl', '5xl', '6xl', '7xl'
29+
*/
30+
31+
'component_defaults' => [
32+
'slide_over_max_width' => 'xl',
33+
'close_slide_over_on_click_away' => true,
34+
'close_slide_over_on_escape' => true,
35+
'close_slide_over_on_escape_is_forceful' => true,
36+
'dispatch_close_event' => false,
37+
'destroy_on_close' => false,
38+
],
39+
40+
];

mix-manifest.json

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"/public/slide-over.js": "/public/slide-over.js",
3+
"/public/slide-over.css": "/public/slide-over.css"
4+
}

package.json

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"scripts": {
3+
"dev": "npm run development",
4+
"development": "mix",
5+
"watch": "mix watch",
6+
"watch-poll": "mix watch -- --watch-options-poll=1000",
7+
"hot": "mix watch --hot",
8+
"prod": "npm run production",
9+
"production": "mix --production"
10+
},
11+
"devDependencies": {
12+
"autoprefixer": "^10.4.19",
13+
"laravel-mix": "^6.0.49",
14+
"postcss": "^8.4.38",
15+
"tailwindcss": "^3.4.3"
16+
}
17+
}

phpunit.xml

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3+
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.3/phpunit.xsd"
4+
bootstrap="vendor/autoload.php"
5+
colors="true"
6+
>
7+
<testsuites>
8+
<testsuite name="Test Suite">
9+
<directory suffix="Test.php">./tests</directory>
10+
</testsuite>
11+
</testsuites>
12+
<source>
13+
<include>
14+
<directory suffix=".php">./src</directory>
15+
</include>
16+
</source>
17+
</phpunit>

pint.json

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"presets": "laravel",
3+
"rules": {
4+
"concat_space": {
5+
"spacing": "one"
6+
}
7+
}
8+
}

0 commit comments

Comments
 (0)