Skip to content

Commit

Permalink
feat: 优化PureTableBar组件,title可使用插槽 (pure-admin#560)
Browse files Browse the repository at this point in the history
* feat: 优化PureTableBar组件,title可使用插槽
  • Loading branch information
mynetfan authored May 19, 2023
1 parent 79ff7c0 commit 1f21a2d
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/components/RePureTableBar/src/bar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -200,9 +200,13 @@ export default defineComponent({

return () => (
<>
<div {...attrs} class="w-[99/100] mt-4 px-2 pb-2 bg-bg_color">
<div {...attrs} class="w-[99/100] mt-2 px-2 pb-2 bg-bg_color">
<div class="flex justify-between w-full h-[60px] p-4">
<p class="font-bold truncate">{props.title}</p>
{slots?.title ? (
slots.title()
) : (
<p class="font-bold truncate">{props.title}</p>
)}
<div class="flex items-center justify-around">
{slots?.buttons ? (
<div class="flex mr-4">{slots.buttons()}</div>
Expand Down

0 comments on commit 1f21a2d

Please sign in to comment.