自定义样式

Icons

简介

图标用于整个 Filament UI 中,直观地传达用户体验的核心部分。要渲染图标,我们使用了 Blade UI 套件的 Blade 图标

他们有一个网站,你可以在那里搜索来自于各个 Blade Icon 包的所有可用的图标。每个包都包含一个不同的图标集,你可以从中进行选择。Filament 默认安装 “Heroicons” 图标集,因此如果你使用此图标集的图标,则不需要安装任何其他软件包。

在 Filament 中使用 Heroicons

Filament 默认引入了 Heroicons 图标集。你可以在 Filament 应用中使用该图标集中的任何图标,而无需安装任何其他额外的包。Heroicon 枚举类允许你使用 IDE 的自动补全功能来查找要使用的图标:

use Filament\Actions\Action;
use Filament\Forms\Components\Toggle;
use Filament\Support\Icons\Heroicon;

Action::make('star')
    ->icon(Heroicon::OutlinedStar)
    
Toggle::make('is_starred')
    ->onIcon(Heroicon::Star)

每个图标都有个 “outlined” 和 “solid” 变体,有 “outlined” 变体名的图标以 Outlined 作为前缀。比如,Heroicon::Star 图标是 solid 变体,而 Heroicon::OutlinedStar 图标则是 outlined 变体。

Heroicon 图标集包含实心(solid)图标的多个尺码(16px, 20px and 24px),当使用 Heroicon 枚举类时,Filament 将在你使用图标的地方自动使用对应的大小。

如果你想在 Blade 组件中使用图标,你可以将其作为属性传入:

@php
    use Filament\Support\Icons\Heroicon;
@endphp

<x-filament::badge :icon="Heroicon::Star">
    Star
</x-filament::badge>

在 Filament 中使用其他图标集

如果你看到了一个想使用的图标,请在 Filament 中安装你想使用的图标库(如果不是 Heroicon),你需要使用其名称。比如,你想使用 iconic-star 图标,你可以将其传入到 PHP 组件的图标方法中:

use Filament\Actions\Action;
use Filament\Forms\Components\Toggle;

Action::make('star')
    ->icon('iconic-star')
    
Toggle::make('is_starred')
    ->onIcon('iconic-check-circle')

如果你想在 Blade 组件中使用图标,你可以将其作为属性传入:

<x-filament::badge icon="iconic-star">
    Star
</x-filament::badge>

使用自定义 SVG 作为图标

Blade 图标包允许你将自定义 SVG 注册成图标。如果你想在 Filament 中使用自定义图标,这很有用。

首先,请先发布 Blade 图标配置文件:

php artisan vendor:publish --tag=blade-icons

然后,打开 config/blade-icons.php 文件,并取消 sets 数组中的 default 设置的注释。

现在配置文件中存在默认设置,你可以将任何想要使用的图标放到应用的 resources/svg 目录中。比如,你将一个名为 star.svg 的 SVG 文件放入 resources/svg 目录中,你可以在 Filment 中的任何地方使用 icon-star 引用它(如下)。icon- 前缀也可以在 config/blade-icons.php 文件中配置。你也可以使用 @svg('icon-star') 指令在 Blade 视图中渲染自定义图标。

use Filament\Actions\Action;

Action::make('star')
    ->icon('icon-star')

替换默认图标

Filament 包含了一个图标管理系统,允许你将任何 UI 默认使用的图标替换成你自己的图标。你可以在任何服务提供者的 boot() 方法中进行设置,比如 AppServiceProvider,甚至可以为图标创建一个专用的服务提供者。如果你想创建一个插件将 Heroicon 图标替换成其他图标库,你可以创建一个 Laravle 包,附上类似的服务提供者来实现。

要替换图标,请使用 FilamentIcon facade。它有一个 register() 方法,该方法接受一个要替换的图标数组。数组的键是唯一的图标别名,用以在 Filament UI 中识别图标;数组值是要替换的 Blade 图标名。此外,你可以使用 HTML 替换图标名来渲染 Blade 视图中的图标,比如:

use Filament\Support\Facades\FilamentIcon;
use Filament\View\PanelsIconAlias;

FilamentIcon::register([
    PanelsIconAlias::GLOBAL_SEARCH_FIELD => 'fas-magnifying-glass',
    PanelsIconAlias::SIDEBAR_GROUP_COLLAPSE_BUTTON => view('icons.chevron-up'),
]);

可用图标别名

Action 图标别名

Using class Filament\Actions\View\ActionsIconAlias

  • ActionsIconAlias::ACTION_GROUP - Trigger button of an action group
  • ActionsIconAlias::CREATE_ACTION_GROUPED - Trigger button of a grouped create action
  • ActionsIconAlias::DELETE_ACTION - Trigger button of a delete action
  • ActionsIconAlias::DELETE_ACTION_GROUPED - Trigger button of a grouped delete action
  • ActionsIconAlias::DELETE_ACTION_MODAL - Modal of a delete action
  • ActionsIconAlias::DETACH_ACTION - Trigger button of a detach action
  • ActionsIconAlias::DETACH_ACTION_MODAL - Modal of a detach action
  • ActionsIconAlias::DISSOCIATE_ACTION - Trigger button of a dissociate action
  • ActionsIconAlias::DISSOCIATE_ACTION_MODAL - Modal of a dissociate action
  • ActionsIconAlias::EDIT_ACTION - Trigger button of an edit action
  • ActionsIconAlias::EDIT_ACTION_GROUPED - Trigger button of a grouped edit action
  • ActionsIconAlias::EXPORT_ACTION_GROUPED - Trigger button of a grouped export action
  • ActionsIconAlias::FORCE_DELETE_ACTION - Trigger button of a force-delete action
  • ActionsIconAlias::FORCE_DELETE_ACTION_GROUPED - Trigger button of a grouped force-delete action
  • ActionsIconAlias::FORCE_DELETE_ACTION_MODAL - Modal of a force-delete action
  • ActionsIconAlias::IMPORT_ACTION_GROUPED - Trigger button of a grouped import action
  • ActionsIconAlias::MODAL_CONFIRMATION - Modal of an action that requires confirmation
  • ActionsIconAlias::REPLICATE_ACTION - Trigger button of a replicate action
  • ActionsIconAlias::REPLICATE_ACTION_GROUPED - Trigger button of a grouped replicate action
  • ActionsIconAlias::RESTORE_ACTION - Trigger button of a restore action
  • ActionsIconAlias::RESTORE_ACTION_GROUPED - Trigger button of a grouped restore action
  • ActionsIconAlias::RESTORE_ACTION_MODAL - Modal of a restore action
  • ActionsIconAlias::VIEW_ACTION - Trigger button of a view action
  • ActionsIconAlias::VIEW_ACTION_GROUPED - Trigger button of a grouped view action

表单图标别名

  • forms::components.builder.actions.clone - Trigger button of a clone action in a builder item

  • forms::components.builder.actions.collapse - Trigger button of a collapse action in a builder item

  • forms::components.builder.actions.delete - Trigger button of a delete action in a builder item

  • forms::components.builder.actions.expand - Trigger button of an expand action in a builder item

  • forms::components.builder.actions.move-down - Trigger button of a move down action in a builder item

  • forms::components.builder.actions.move-up - Trigger button of a move up action in a builder item

  • forms::components.builder.actions.reorder - Trigger button of a reorder action in a builder item

  • forms::components.checkbox-list.search-field - Search input in a checkbox list

  • forms::components.file-upload.editor.actions.drag-crop - Trigger button of a drag crop action in a file upload editor

  • forms::components.file-upload.editor.actions.drag-move - Trigger button of a drag move action in a file upload editor

  • forms::components.file-upload.editor.actions.flip-horizontal - Trigger button of a flip horizontal action in a file upload editor

  • forms::components.file-upload.editor.actions.flip-vertical - Trigger button of a flip vertical action in a file upload editor

  • forms::components.file-upload.editor.actions.move-down - Trigger button of a move down action in a file upload editor

  • forms::components.file-upload.editor.actions.move-left - Trigger button of a move left action in a file upload editor

  • forms::components.file-upload.editor.actions.move-right - Trigger button of a move right action in a file upload editor

  • forms::components.file-upload.editor.actions.move-up - Trigger button of a move up action in a file upload editor

  • forms::components.file-upload.editor.actions.rotate-left - Trigger button of a rotate left action in a file upload editor

  • forms::components.file-upload.editor.actions.rotate-right - Trigger button of a rotate right action in a file upload editor

  • forms::components.file-upload.editor.actions.zoom-100 - Trigger button of a zoom 100 action in a file upload editor

  • forms::components.file-upload.editor.actions.zoom-in - Trigger button of a zoom in action in a file upload editor

  • forms::components.file-upload.editor.actions.zoom-out - Trigger button of a zoom out action in a file upload editor

  • forms::components.key-value.actions.delete - Trigger button of a delete action in a key-value field item

  • forms::components.key-value.actions.reorder - Trigger button of a reorder action in a key-value field item

  • forms::components.repeater.actions.clone - Trigger button of a clone action in a repeater item

  • forms::components.repeater.actions.collapse - Trigger button of a collapse action in a repeater item

  • forms::components.repeater.actions.delete - Trigger button of a delete action in a repeater item

  • forms::components.repeater.actions.expand - Trigger button of an expand action in a repeater item

  • forms::components.repeater.actions.move-down - Trigger button of a move down action in a repeater item

  • forms::components.repeater.actions.move-up - Trigger button of a move up action in a repeater item

  • forms::components.repeater.actions.reorder - Trigger button of a reorder action in a repeater item

  • forms::components.select.actions.create-option - Trigger button of a create option action in a select field

  • forms::components.select.actions.edit-option - Trigger button of an edit option action in a select field

  • forms::components.text-input.actions.hide-password - Trigger button of a hide password action in a text input field

  • forms::components.text-input.actions.show-password - Trigger button of a show password action in a text input field

  • forms::components.toggle-buttons.boolean.false - “False” option of a boolean() toggle buttons field

  • forms::components.toggle-buttons.boolean.true - “True” option of a boolean() toggle buttons fieldUsing class Filament\Forms\View\FormsIconAlias

  • FormsIconAlias::COMPONENTS_BUILDER_ACTIONS_CLONE - Trigger button of a clone action in a builder item

  • FormsIconAlias::COMPONENTS_BUILDER_ACTIONS_COLLAPSE - Trigger button of a collapse action in a builder item

  • FormsIconAlias::COMPONENTS_BUILDER_ACTIONS_DELETE - Trigger button of a delete action in a builder item

  • FormsIconAlias::COMPONENTS_BUILDER_ACTIONS_EDIT - Trigger button of an edit action in a builder item, when block previews are enabled

  • FormsIconAlias::COMPONENTS_BUILDER_ACTIONS_EXPAND - Trigger button of an expand action in a builder item

  • FormsIconAlias::COMPONENTS_BUILDER_ACTIONS_MOVE_DOWN - Trigger button of a move down action in a builder item

  • FormsIconAlias::COMPONENTS_BUILDER_ACTIONS_MOVE_UP - Trigger button of a move up action in a builder item

  • FormsIconAlias::COMPONENTS_BUILDER_ACTIONS_REORDER - Trigger button of a reorder action in a builder item

  • FormsIconAlias::COMPONENTS_CHECKBOX_LIST_SEARCH_FIELD - Search input in a checkbox list

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_DRAG_CROP - Trigger button of a drag crop action in a file upload editor

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_DRAG_MOVE - Trigger button of a drag move action in a file upload editor

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_FLIP_HORIZONTAL - Trigger button of a flip horizontal action in a file upload editor

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_FLIP_VERTICAL - Trigger button of a flip vertical action in a file upload editor

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_MOVE_DOWN - Trigger button of a move down action in a file upload editor

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_MOVE_LEFT - Trigger button of a move left action in a file upload editor

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_MOVE_RIGHT - Trigger button of a move right action in a file upload editor

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_MOVE_UP - Trigger button of a move up action in a file upload editor

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_ROTATE_LEFT - Trigger button of a rotate left action in a file upload editor

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_ROTATE_RIGHT - Trigger button of a rotate right action in a file upload editor

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_ZOOM_100 - Trigger button of a zoom 100 action in a file upload editor

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_ZOOM_IN - Trigger button of a zoom in action in a file upload editor

  • FormsIconAlias::COMPONENTS_FILE_UPLOAD_EDITOR_ACTIONS_ZOOM_OUT - Trigger button of a zoom out action in a file upload editor

  • FormsIconAlias::COMPONENTS_KEY_VALUE_ACTIONS_DELETE - Trigger button of a delete action in a key-value field item

  • FormsIconAlias::COMPONENTS_KEY_VALUE_ACTIONS_REORDER - Trigger button of a reorder action in a key-value field item

  • FormsIconAlias::COMPONENTS_MODAL_TABLE_SELECT_ACTIONS_SELECT - Trigger button of the select action in a modal table select field

  • FormsIconAlias::COMPONENTS_REPEATER_ACTIONS_CLONE - Trigger button of a clone action in a repeater item

  • FormsIconAlias::COMPONENTS_REPEATER_ACTIONS_COLLAPSE - Trigger button of a collapse action in a repeater item

  • FormsIconAlias::COMPONENTS_REPEATER_ACTIONS_DELETE - Trigger button of a delete action in a repeater item

  • FormsIconAlias::COMPONENTS_REPEATER_ACTIONS_EXPAND - Trigger button of an expand action in a repeater item

  • FormsIconAlias::COMPONENTS_REPEATER_ACTIONS_MOVE_DOWN - Trigger button of a move down action in a repeater item

  • FormsIconAlias::COMPONENTS_REPEATER_ACTIONS_MOVE_UP - Trigger button of a move up action in a repeater item

  • FormsIconAlias::COMPONENTS_REPEATER_ACTIONS_REORDER - Trigger button of a reorder action in a repeater item

  • FormsIconAlias::COMPONENTS_RICH_EDITOR_PANELS_CUSTOM_BLOCKS_CLOSE_BUTTON - Close button for custom blocks panel in a rich editor

  • FormsIconAlias::COMPONENTS_RICH_EDITOR_PANELS_CUSTOM_BLOCK_DELETE_BUTTON - Delete button for a custom block in a rich editor

  • FormsIconAlias::COMPONENTS_RICH_EDITOR_PANELS_CUSTOM_BLOCK_EDIT_BUTTON - Edit button for a custom block in a rich editor

  • FormsIconAlias::COMPONENTS_RICH_EDITOR_PANELS_MERGE_TAGS_CLOSE_BUTTON - Close button for merge tags panel in a rich editor

  • FormsIconAlias::COMPONENTS_SELECT_ACTIONS_CREATE_OPTION - Trigger button of a create option action in a select field

  • FormsIconAlias::COMPONENTS_SELECT_ACTIONS_EDIT_OPTION - Trigger button of an edit option action in a select field

  • FormsIconAlias::COMPONENTS_TEXT_INPUT_ACTIONS_COPY - Trigger button of a copy action in a text input field

  • FormsIconAlias::COMPONENTS_TEXT_INPUT_ACTIONS_HIDE_PASSWORD - Trigger button of a hide password action in a text input field

  • FormsIconAlias::COMPONENTS_TEXT_INPUT_ACTIONS_SHOW_PASSWORD - Trigger button of a show password action in a text input field

  • FormsIconAlias::COMPONENTS_TOGGLE_BUTTONS_BOOLEAN_FALSE - “False” option of a boolean() toggle buttons field

  • FormsIconAlias::COMPONENTS_TOGGLE_BUTTONS_BOOLEAN_TRUE - “True” option of a boolean() toggle buttons field

信息列表图标别名

Using class Filament\Infolists\View\InfolistsIconAlias

  • InfolistsIconAlias::COMPONENTS_ICON_ENTRY_FALSE - Falsy state of an icon entry
  • InfolistsIconAlias::COMPONENTS_ICON_ENTRY_TRUE - Truthy state of an icon entry

通知图标别名

Using class Filament\Notifications\View\NotificationsIconAlias

  • NotificationsIconAlias::DATABASE_MODAL_EMPTY_STATE - Empty state of the database notifications modal
  • NotificationsIconAlias::NOTIFICATION_CLOSE_BUTTON - Button to close a notification
  • NotificationsIconAlias::NOTIFICATION_DANGER - Danger notification
  • NotificationsIconAlias::NOTIFICATION_INFO - Info notification
  • NotificationsIconAlias::NOTIFICATION_SUCCESS - Success notification
  • NotificationsIconAlias::NOTIFICATION_WARNING - Warning notification

面板图标别名

Using class Filament\View\PanelsIconAlias

  • PanelsIconAlias::AUTH_MULTI_FACTOR_APP_ACTIONS_DISABLE - Trigger button of the action to disable app authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_APP_ACTIONS_DISABLE_MODAL - Modal of the action to disable app authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_APP_ACTIONS_DISABLE_NOTIFICATION - Notification sent after disabling app authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_APP_ACTIONS_REGENERATE_RECOVERY_CODES - Trigger button of the action to regenerate the recovery codes for app authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_APP_ACTIONS_REGENERATE_RECOVERY_CODES_MODAL - Modal of the action to regenerate the recovery codes for app authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_APP_ACTIONS_REGENERATE_RECOVERY_CODES_NOTIFICATION - Notification sent after regenerating the recovery codes for app authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_APP_ACTIONS_SET_UP - Trigger button of the action to set up app authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_APP_ACTIONS_SET_UP_MODAL - Modal of the action to set up app authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_APP_ACTIONS_SET_UP_NOTIFICATION - Notification sent after setting up app authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_EMAIL_ACTIONS_DISABLE - Trigger button of the action to disable email authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_EMAIL_ACTIONS_DISABLE_MODAL - Modal of the action to disable email authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_EMAIL_ACTIONS_DISABLE_NOTIFICATION - Notification sent after disabling email authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_EMAIL_ACTIONS_SET_UP - Trigger button of the action to set up email authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_EMAIL_ACTIONS_SET_UP_MODAL - Modal of the action to set up email authentication
  • PanelsIconAlias::AUTH_MULTI_FACTOR_EMAIL_ACTIONS_SET_UP_NOTIFICATION - Notification sent after setting up email authentication
  • PanelsIconAlias::GLOBAL_SEARCH_FIELD - Global search field
  • PanelsIconAlias::PAGES_DASHBOARD_ACTIONS_FILTER - Trigger button of the dashboard filter action
  • PanelsIconAlias::PAGES_DASHBOARD_NAVIGATION_ITEM - Dashboard page navigation item
  • PanelsIconAlias::PAGES_PASSWORD_RESET_REQUEST_PASSWORD_RESET_ACTIONS_LOGIN - Trigger button of the login action on the request password reset page
  • PanelsIconAlias::PAGES_PASSWORD_RESET_REQUEST_PASSWORD_RESET_ACTIONS_LOGIN_RTL - Trigger button of the login action on the request password reset page (right-to-left direction)
  • PanelsIconAlias::RESOURCES_PAGES_EDIT_RECORD_NAVIGATION_ITEM - Resource edit record page navigation item
  • PanelsIconAlias::RESOURCES_PAGES_MANAGE_RELATED_RECORDS_NAVIGATION_ITEM - Resource manage related records page navigation item
  • PanelsIconAlias::RESOURCES_PAGES_VIEW_RECORD_NAVIGATION_ITEM - Resource view record page navigation item
  • PanelsIconAlias::SIDEBAR_COLLAPSE_BUTTON - Button to collapse the sidebar
  • PanelsIconAlias::SIDEBAR_COLLAPSE_BUTTON_RTL - Button to collapse the sidebar (right-to-left direction)
  • PanelsIconAlias::SIDEBAR_EXPAND_BUTTON - Button to expand the sidebar
  • PanelsIconAlias::SIDEBAR_EXPAND_BUTTON_RTL - Button to expand the sidebar (right-to-left direction)
  • PanelsIconAlias::SIDEBAR_GROUP_COLLAPSE_BUTTON - Collapse button for a sidebar group
  • PanelsIconAlias::SIDEBAR_OPEN_DATABASE_NOTIFICATIONS_BUTTON - Button to open the database notifications modal
  • PanelsIconAlias::SUB_NAVIGATION_MOBILE_MENU_BUTTON - Button to open the sub-navigation menu on mobile
  • PanelsIconAlias::TENANT_MENU_BILLING_BUTTON - Billing button in the tenant menu
  • PanelsIconAlias::TENANT_MENU_PROFILE_BUTTON - Profile button in the tenant menu
  • PanelsIconAlias::TENANT_MENU_REGISTRATION_BUTTON - Registration button in the tenant menu
  • PanelsIconAlias::TENANT_MENU_TOGGLE_BUTTON - Button to toggle the tenant menu
  • PanelsIconAlias::THEME_SWITCHER_LIGHT_BUTTON - Button to switch to the light theme from the theme switcher
  • PanelsIconAlias::THEME_SWITCHER_DARK_BUTTON - Button to switch to the dark theme from the theme switcher
  • PanelsIconAlias::THEME_SWITCHER_SYSTEM_BUTTON - Button to switch to the system theme from the theme switcher
  • PanelsIconAlias::TOPBAR_CLOSE_SIDEBAR_BUTTON - Button to close the sidebar
  • PanelsIconAlias::TOPBAR_OPEN_SIDEBAR_BUTTON - Button to open the sidebar
  • PanelsIconAlias::TOPBAR_GROUP_TOGGLE_BUTTON - Toggle button for a topbar group
  • PanelsIconAlias::TOPBAR_OPEN_DATABASE_NOTIFICATIONS_BUTTON - Button to open the database notifications modal
  • PanelsIconAlias::USER_MENU_PROFILE_ITEM - Profile item in the user menu
  • PanelsIconAlias::USER_MENU_LOGOUT_BUTTON - Button in the user menu to log out
  • PanelsIconAlias::USER_MENU_TOGGLE_BUTTON - Button to toggle the user menu
  • PanelsIconAlias::WIDGETS_ACCOUNT_LOGOUT_BUTTON - Button in the account widget to log out
  • PanelsIconAlias::WIDGETS_FILAMENT_INFO_OPEN_DOCUMENTATION_BUTTON - Button to open the documentation from the Filament info widget
  • PanelsIconAlias::WIDGETS_FILAMENT_INFO_OPEN_GITHUB_BUTTON - Button to open GitHub from the Filament info widget

Query builder icon aliases

Using class Filament\QueryBuilder\View\QueryBuilderIconAlias

  • QueryBuilderIconAlias::ADD_RULE_ACTION - Trigger button of the action to add a rule
  • QueryBuilderIconAlias::CONSTRAINTS_BOOLEAN - Default icon for a boolean constraint
  • QueryBuilderIconAlias::CONSTRAINTS_DATE - Default icon for a date constraint
  • QueryBuilderIconAlias::CONSTRAINTS_NUMBER - Default icon for a number constraint
  • QueryBuilderIconAlias::CONSTRAINTS_RELATIONSHIP - Default icon for a relationship constraint
  • QueryBuilderIconAlias::CONSTRAINTS_SELECT - Default icon for a select constraint
  • QueryBuilderIconAlias::CONSTRAINTS_TEXT - Default icon for a text constraint
  • QueryBuilderIconAlias::OR_GROUP_ADD_GROUP_ACTION - Trigger button of the action to add an “or” group
  • QueryBuilderIconAlias::OR_GROUP_BLOCK - Block that separates the rules in an “or” group

Schema 图标别名

Using class Filament\Schemas\View\SchemaIconAlias

  • SchemaIconAlias::COMPONENTS_CALLOUT_DANGER - Danger callout
  • SchemaIconAlias::COMPONENTS_CALLOUT_INFO - Info callout
  • SchemaIconAlias::COMPONENTS_CALLOUT_SUCCESS - Success callout
  • SchemaIconAlias::COMPONENTS_CALLOUT_WARNING - Warning callout
  • SchemaIconAlias::COMPONENTS_TABS_DROPDOWN_TRIGGER_BUTTON - Button to open the dropdown containing the tabs, when they do not fit on one line
  • SchemaIconAlias::COMPONENTS_TABS_MORE_TABS_BUTTON - Button to reveal the tabs that do not fit on one line
  • SchemaIconAlias::COMPONENTS_WIZARD_COMPLETED_STEP - Completed step in a wizard

表格图标别名

Using class Filament\Tables\View\TablesIconAlias

  • TablesIconAlias::ACTIONS_DISABLE_REORDERING - Trigger button of the disable reordering action
  • TablesIconAlias::ACTIONS_ENABLE_REORDERING - Trigger button of the enable reordering action
  • TablesIconAlias::ACTIONS_FILTER - Trigger button of the filter action
  • TablesIconAlias::ACTIONS_GROUP - Trigger button of a group records action
  • TablesIconAlias::ACTIONS_OPEN_BULK_ACTIONS - Trigger button of an open bulk actions action
  • TablesIconAlias::ACTIONS_COLUMN_MANAGER - Trigger button of the column manager action
  • TablesIconAlias::COLUMNS_COLLAPSE_BUTTON - Button to collapse a column
  • TablesIconAlias::COLUMNS_ICON_COLUMN_FALSE - Falsy state of an icon column
  • TablesIconAlias::COLUMNS_ICON_COLUMN_TRUE - Truthy state of an icon column
  • TablesIconAlias::EMPTY_STATE - Empty state icon
  • TablesIconAlias::FILTERS_QUERY_BUILDER_CONSTRAINTS_BOOLEAN - Default icon for a boolean constraint in the query builder
  • TablesIconAlias::FILTERS_QUERY_BUILDER_CONSTRAINTS_DATE - Default icon for a date constraint in the query builder
  • TablesIconAlias::FILTERS_QUERY_BUILDER_CONSTRAINTS_NUMBER - Default icon for a number constraint in the query builder
  • TablesIconAlias::FILTERS_QUERY_BUILDER_CONSTRAINTS_RELATIONSHIP - Default icon for a relationship constraint in the query builder
  • TablesIconAlias::FILTERS_QUERY_BUILDER_CONSTRAINTS_SELECT - Default icon for a select constraint in the query builder
  • TablesIconAlias::FILTERS_QUERY_BUILDER_CONSTRAINTS_TEXT - Default icon for a text constraint in the query builder
  • TablesIconAlias::FILTERS_REMOVE_ALL_BUTTON - Button to remove all filters
  • TablesIconAlias::GROUPING_COLLAPSE_BUTTON - Button to collapse a group of records
  • TablesIconAlias::HEADER_CELL_SORT_ASC_BUTTON - Sort button of a column sorted in ascending order
  • TablesIconAlias::HEADER_CELL_SORT_BUTTON - Sort button of a column when it is currently not sorted
  • TablesIconAlias::HEADER_CELL_SORT_DESC_BUTTON - Sort button of a column sorted in descending order
  • TablesIconAlias::REORDER_HANDLE - Handle to grab in order to reorder a record with drag and drop
  • TablesIconAlias::SEARCH_FIELD - Search input

UI 组件图标别名

UI components icon aliases

Using class Filament\Support\View\SupportIconAlias

  • SupportIconAlias::BREADCRUMBS_SEPARATOR - Separator between breadcrumbs
  • SupportIconAlias::BREADCRUMBS_SEPARATOR_RTL - Separator between breadcrumbs (right-to-left direction)
  • SupportIconAlias::MODAL_CLOSE_BUTTON - Button to close a modal
  • SupportIconAlias::PAGINATION_FIRST_BUTTON - Button to go to the first page
  • SupportIconAlias::PAGINATION_FIRST_BUTTON_RTL - Button to go to the first page (right-to-left direction)
  • SupportIconAlias::PAGINATION_LAST_BUTTON - Button to go to the last page
  • SupportIconAlias::PAGINATION_LAST_BUTTON_RTL - Button to go to the last page (right-to-left direction)
  • SupportIconAlias::PAGINATION_NEXT_BUTTON - Button to go to the next page
  • SupportIconAlias::PAGINATION_NEXT_BUTTON_RTL - Button to go to the next page (right-to-left direction)
  • SupportIconAlias::PAGINATION_PREVIOUS_BUTTON - Button to go to the previous page
  • SupportIconAlias::PAGINATION_PREVIOUS_BUTTON_RTL - Button to go to the previous page (right-to-left direction)
  • SupportIconAlias::SECTION_COLLAPSE_BUTTON - Button to collapse a section

Widgets icon aliases

Using class Filament\Widgets\View\WidgetsIconAlias

  • WidgetsIconAlias::CHART_WIDGET_FILTER - Button of the filter action
  • WidgetsIconAlias::CHART_WIDGET_EMPTY_STATE - Empty state icon for chart widgets
Edit on GitHub

Still need help? Join our Discord community or open a GitHub discussion

Previous
颜色