mirror of
https://github.com/filamentphp/filament.git
synced 2026-10-24 12:04:06 +08:00
docs
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 7.1 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 6.9 KiB |
@@ -98,15 +98,6 @@ export default {
|
||||
deviceScaleFactor: 3,
|
||||
},
|
||||
},
|
||||
'actions/trigger-button/inline-icon': {
|
||||
url: 'actions',
|
||||
selector: '#inlineIconAction',
|
||||
viewport: {
|
||||
width: 1920,
|
||||
height: 640,
|
||||
deviceScaleFactor: 3,
|
||||
},
|
||||
},
|
||||
'actions/modal/confirmation': {
|
||||
url: 'actions',
|
||||
viewport: {
|
||||
|
||||
@@ -203,21 +203,6 @@ Action::make('edit')
|
||||
|
||||
<AutoScreenshot name="actions/trigger-button/outlined" alt="Outlined trigger button" version="3.x" />
|
||||
|
||||
## Inline icon button style
|
||||
|
||||
When you're using the "icon button" trigger style, you might wish to make it fit inline with other content. You can do this with the `inline()` method, which removes the background color when it the button is hovered over:
|
||||
|
||||
```php
|
||||
use Filament\Actions\Action;
|
||||
|
||||
Action::make('edit')
|
||||
->url(fn (): string => route('posts.edit', ['post' => $this->post]))
|
||||
->iconButton()
|
||||
->inline()
|
||||
```
|
||||
|
||||
<AutoScreenshot name="actions/trigger-button/inline-icon" alt="Inline icon button" version="3.x" />
|
||||
|
||||
## Adding extra HTML attributes
|
||||
|
||||
You can pass extra HTML attributes to the button which will be merged onto the outer DOM element. Pass an array of attributes to the `extraAttributes()` method, where the key is the attribute name and the value is the attribute value:
|
||||
|
||||
Reference in New Issue
Block a user