fix(ui): улучшить функциональность панели данных и заменить устаревшие компоненты
Docker images / prepare-release (push) Successful in 7s
Docker images / backend-image (push) Successful in 2m1s
Docker images / frontend-image (push) Successful in 2m7s
Docker images / updater-image (push) Successful in 41s
Docker images / notify-webhook (push) Has been skipped
Docker images / publish-release (push) Successful in 8s
Docker images / prepare-release (push) Successful in 7s
Docker images / backend-image (push) Successful in 2m1s
Docker images / frontend-image (push) Successful in 2m7s
Docker images / updater-image (push) Successful in 41s
Docker images / notify-webhook (push) Has been skipped
Docker images / publish-release (push) Successful in 8s
This commit is contained in:
@@ -14,6 +14,21 @@ import {
|
||||
type FilterFieldConfig,
|
||||
} from "@/components/reui/filters"
|
||||
import { SegmentedControl } from "@/components/form-kit"
|
||||
import { DATA_PAGE_TOOLBAR_CLASS } from "@/components/data-grids/shared/data-grid-layout"
|
||||
|
||||
function DataPageToolbarFrame({
|
||||
children,
|
||||
className,
|
||||
}: {
|
||||
children: ReactNode
|
||||
className?: string
|
||||
}) {
|
||||
return (
|
||||
<div className={cn(DATA_PAGE_TOOLBAR_CLASS, className)}>
|
||||
{children}
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
interface DataPageToolbarProps<T extends string = string> {
|
||||
search?: string
|
||||
@@ -45,7 +60,7 @@ function DataPageToolbar<T extends string = string>({
|
||||
className,
|
||||
}: DataPageToolbarProps<T>) {
|
||||
return (
|
||||
<div className={cn("flex items-center gap-3 px-5 py-3 border-b flex-wrap", className)}>
|
||||
<DataPageToolbarFrame className={className}>
|
||||
{segmented && (
|
||||
<SegmentedControl
|
||||
value={segmented.value}
|
||||
@@ -77,8 +92,8 @@ function DataPageToolbar<T extends string = string>({
|
||||
<span className="text-sm text-muted-foreground ml-auto">{countLabel}</span>
|
||||
)}
|
||||
{actions}
|
||||
</div>
|
||||
</DataPageToolbarFrame>
|
||||
)
|
||||
}
|
||||
|
||||
export { DataPageToolbar, type DataPageToolbarProps }
|
||||
export { DataPageToolbar, DataPageToolbarFrame, type DataPageToolbarProps }
|
||||
|
||||
Reference in New Issue
Block a user