@tb-dev/vue-components 1.0.2 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,11 +1,7 @@
1
1
  import { VNode } from 'vue';
2
- import { PopoverProps } from './types';
3
- type __VLS_Props = PopoverProps;
4
- declare function open(): void;
5
- declare function close(): void;
6
2
  type __VLS_PublicProps = {
7
3
  modelValue: boolean;
8
- } & __VLS_Props;
4
+ };
9
5
  declare function __VLS_template(): {
10
6
  attrs: Partial<{}>;
11
7
  slots: Readonly<{
@@ -19,10 +15,7 @@ declare function __VLS_template(): {
19
15
  rootEl: any;
20
16
  };
21
17
  type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
22
- declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps, {
23
- close: typeof close;
24
- open: typeof open;
25
- }, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
18
+ declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
26
19
  "update:modelValue": (value: boolean) => any;
27
20
  }, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
28
21
  "onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
@@ -1,3 +1,3 @@
1
+ import { PopoverContent } from '../__base/popover';
1
2
  import { default as Popover } from './Popover.vue';
2
- export type * from './types';
3
- export { Popover };
3
+ export { Popover, PopoverContent };
package/dist/index.js CHANGED
@@ -4038,31 +4038,17 @@ const _sfc_main$1l = /* @__PURE__ */ defineComponent({
4038
4038
 
4039
4039
  const _sfc_main$1k = /* @__PURE__ */ defineComponent({
4040
4040
  __name: "Popover",
4041
- props: /* @__PURE__ */ mergeModels({
4042
- contentClass: {},
4043
- keepOpen: { type: Boolean }
4044
- }, {
4041
+ props: {
4045
4042
  "modelValue": { type: Boolean, ...{ required: true } },
4046
4043
  "modelModifiers": {}
4047
- }),
4044
+ },
4048
4045
  emits: ["update:modelValue"],
4049
- setup(__props, { expose: __expose }) {
4050
- const props = __props;
4051
- const isOpen = useModel(__props, "modelValue");
4052
- function open() {
4053
- isOpen.value = true;
4054
- }
4055
- function close() {
4056
- isOpen.value = false;
4057
- }
4058
- function onPointerDownOutside() {
4059
- if (!props.keepOpen) close();
4060
- }
4061
- __expose({ close, open });
4046
+ setup(__props) {
4047
+ const open = useModel(__props, "modelValue");
4062
4048
  return (_ctx, _cache) => {
4063
4049
  return openBlock(), createBlock(unref(_sfc_main$1n), {
4064
- open: isOpen.value,
4065
- "onUpdate:open": _cache[0] || (_cache[0] = ($event) => isOpen.value = $event)
4050
+ open: open.value,
4051
+ "onUpdate:open": _cache[0] || (_cache[0] = ($event) => open.value = $event)
4066
4052
  }, {
4067
4053
  default: withCtx(() => [
4068
4054
  createVNode(unref(_sfc_main$1l), { "as-child": "" }, {
@@ -4071,15 +4057,7 @@ const _sfc_main$1k = /* @__PURE__ */ defineComponent({
4071
4057
  ]),
4072
4058
  _: 3
4073
4059
  }),
4074
- createVNode(unref(_sfc_main$1m), {
4075
- class: normalizeClass(_ctx.contentClass),
4076
- onPointerDownOutside
4077
- }, {
4078
- default: withCtx(() => [
4079
- renderSlot(_ctx.$slots, "default")
4080
- ]),
4081
- _: 3
4082
- }, 8, ["class"])
4060
+ renderSlot(_ctx.$slots, "default")
4083
4061
  ]),
4084
4062
  _: 3
4085
4063
  }, 8, ["open"]);
@@ -6898,4 +6876,4 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
6898
6876
  }
6899
6877
  });
6900
6878
 
6901
- export { _sfc_main$3i as Accordion, _sfc_main$3h as AccordionContent, _sfc_main$3g as AccordionItem, _sfc_main$3f as AccordionTrigger, _sfc_main$3e as Alert, _sfc_main$3d as AlertDescription, _sfc_main$31 as AlertDialog, _sfc_main$3c as AlertTitle, _sfc_main$30 as Avatar, _sfc_main$2$ as AvatarFallback, _sfc_main$2_ as AvatarImage, _sfc_main$2Z as Badge, _sfc_main$3a as Button, _sfc_main$2W as ButtonIcon, _sfc_main$2X as ButtonLink, _sfc_main$2N as Card, _sfc_main$2L as Checkbox, _sfc_main$2K as Combobox, _sfc_main$2J as ComboboxAnchor, _sfc_main$2I as ComboboxEmpty, _sfc_main$2H as ComboboxGroup, _sfc_main$2G as ComboboxInput, _sfc_main$2F as ComboboxItem, _sfc_main$2E as ComboboxItemIndicator, _sfc_main$2D as ComboboxList, _sfc_main$2C as ComboboxSeparator, _sfc_main$2B as ComboboxViewport, _sfc_main$2A as ContextMenu, _sfc_main$2z as ContextMenuCheckboxItem, _sfc_main$2y as ContextMenuContent, _sfc_main$2x as ContextMenuGroup, _sfc_main$2w as ContextMenuItem, _sfc_main$2v as ContextMenuLabel, _sfc_main$2u as ContextMenuRadioGroup, _sfc_main$2t as ContextMenuRadioItem, _sfc_main$2s as ContextMenuSeparator, _sfc_main$2r as ContextMenuShortcut, _sfc_main$2q as ContextMenuSub, _sfc_main$2p as ContextMenuSubContent, _sfc_main$2o as ContextMenuSubTrigger, _sfc_main$2n as ContextMenuTrigger, _sfc_main$2d as Dialog, _sfc_main$2l as DialogClose, _sfc_main$2c as DropdownMenu, _sfc_main$2b as DropdownMenuCheckboxItem, _sfc_main$2a as DropdownMenuContent, _sfc_main$29 as DropdownMenuGroup, _sfc_main$28 as DropdownMenuItem, _sfc_main$27 as DropdownMenuLabel, _sfc_main$26 as DropdownMenuRadioGroup, _sfc_main$25 as DropdownMenuRadioItem, _sfc_main$24 as DropdownMenuSeparator, _sfc_main$23 as DropdownMenuShortcut, _sfc_main$22 as DropdownMenuSub, _sfc_main$21 as DropdownMenuSubContent, _sfc_main$20 as DropdownMenuSubTrigger, _sfc_main$1$ as DropdownMenuTrigger, _sfc_main$1X as HoverCard, _sfc_main$1V as Input, _sfc_main$1P as InputNumber, _sfc_main$1O as InputText, _sfc_main$1N as Label, _sfc_main$1M as Link, Loading, _sfc_main$1K as Menubar, _sfc_main$1J as MenubarCheckboxItem, _sfc_main$1I as MenubarContent, _sfc_main$1H as MenubarGroup, _sfc_main$1G as MenubarItem, _sfc_main$1F as MenubarLabel, _sfc_main$1E as MenubarMenu, _sfc_main$1D as MenubarRadioGroup, _sfc_main$1C as MenubarRadioItem, _sfc_main$1B as MenubarSeparator, _sfc_main$1A as MenubarShortcut, _sfc_main$1z as MenubarSub, _sfc_main$1y as MenubarSubContent, _sfc_main$1x as MenubarSubTrigger, _sfc_main$1w as MenubarTrigger, _sfc_main$1v as Pagination, _sfc_main$1u as PaginationContent, _sfc_main$1t as PaginationEllipsis, _sfc_main$1s as PaginationFirst, _sfc_main$1r as PaginationItem, _sfc_main$1q as PaginationLast, _sfc_main$1p as PaginationNext, _sfc_main$1o as PaginationPrevious, _sfc_main$1k as Popover, _sfc_main$1j as Progress, _sfc_main$1i as RadioGroup, _sfc_main$1h as RadioGroupItem, _sfc_main$1g as ResizableHandle, _sfc_main$1f as ResizablePanel, _sfc_main$1e as ResizablePanelGroup, _sfc_main$2U as ScrollArea, _sfc_main$12 as Select, _sfc_main$1b as SelectGroup, _sfc_main$1a as SelectItem, _sfc_main$19 as SelectItemText, _sfc_main$18 as SelectLabel, _sfc_main$17 as SelectScrollDownButton, _sfc_main$16 as SelectScrollUpButton, _sfc_main$15 as SelectSeparator, _sfc_main$11 as Separator, _sfc_main$10 as Sheet, _sfc_main$$ as SheetClose, _sfc_main$Z as SheetContent, _sfc_main$Y as SheetDescription, _sfc_main$X as SheetFooter, _sfc_main$W as SheetHeader, _sfc_main$V as SheetTitle, _sfc_main$U as SheetTrigger, _sfc_main$r as Sidebar, _sfc_main$Q as SidebarGroup, _sfc_main$P as SidebarGroupAction, _sfc_main$O as SidebarGroupContent, _sfc_main$N as SidebarGroupLabel, _sfc_main$K as SidebarMenu, _sfc_main$J as SidebarMenuAction, _sfc_main$I as SidebarMenuBadge, _sfc_main$C as SidebarMenuButton, _sfc_main$B as SidebarMenuItem, _sfc_main$z as SidebarMenuSkeleton, _sfc_main$y as SidebarMenuSub, _sfc_main$x as SidebarMenuSubButton, _sfc_main$w as SidebarMenuSubItem, _sfc_main$u as SidebarRail, _sfc_main$t as SidebarSeparator, _sfc_main$s as SidebarTrigger, _sfc_main$A as Skeleton, _sfc_main$q as Slider, _sfc_main$p as Sonner, _sfc_main$n as Switch, _sfc_main$e as Table, _sfc_main$k as TableCell, _sfc_main$i as TableEmpty, _sfc_main$g as TableHead, _sfc_main$d as TableLink, _sfc_main$j as TableRow, _sfc_main$c as Tabs, _sfc_main$b as TabsContent, _sfc_main$a as TabsList, _sfc_main$9 as TabsTrigger, _sfc_main$8 as TagsInput, _sfc_main$7 as TagsInputInput, _sfc_main$6 as TagsInputItem, _sfc_main$5 as TagsInputItemDelete, _sfc_main$4 as TagsInputItemText, _sfc_main$2 as Textarea, _sfc_main$1 as Toggle, _sfc_main as Tooltip, cn, toBooleanCheckboxValue, useSidebar };
6879
+ export { _sfc_main$3i as Accordion, _sfc_main$3h as AccordionContent, _sfc_main$3g as AccordionItem, _sfc_main$3f as AccordionTrigger, _sfc_main$3e as Alert, _sfc_main$3d as AlertDescription, _sfc_main$31 as AlertDialog, _sfc_main$3c as AlertTitle, _sfc_main$30 as Avatar, _sfc_main$2$ as AvatarFallback, _sfc_main$2_ as AvatarImage, _sfc_main$2Z as Badge, _sfc_main$3a as Button, _sfc_main$2W as ButtonIcon, _sfc_main$2X as ButtonLink, _sfc_main$2N as Card, _sfc_main$2L as Checkbox, _sfc_main$2K as Combobox, _sfc_main$2J as ComboboxAnchor, _sfc_main$2I as ComboboxEmpty, _sfc_main$2H as ComboboxGroup, _sfc_main$2G as ComboboxInput, _sfc_main$2F as ComboboxItem, _sfc_main$2E as ComboboxItemIndicator, _sfc_main$2D as ComboboxList, _sfc_main$2C as ComboboxSeparator, _sfc_main$2B as ComboboxViewport, _sfc_main$2A as ContextMenu, _sfc_main$2z as ContextMenuCheckboxItem, _sfc_main$2y as ContextMenuContent, _sfc_main$2x as ContextMenuGroup, _sfc_main$2w as ContextMenuItem, _sfc_main$2v as ContextMenuLabel, _sfc_main$2u as ContextMenuRadioGroup, _sfc_main$2t as ContextMenuRadioItem, _sfc_main$2s as ContextMenuSeparator, _sfc_main$2r as ContextMenuShortcut, _sfc_main$2q as ContextMenuSub, _sfc_main$2p as ContextMenuSubContent, _sfc_main$2o as ContextMenuSubTrigger, _sfc_main$2n as ContextMenuTrigger, _sfc_main$2d as Dialog, _sfc_main$2l as DialogClose, _sfc_main$2c as DropdownMenu, _sfc_main$2b as DropdownMenuCheckboxItem, _sfc_main$2a as DropdownMenuContent, _sfc_main$29 as DropdownMenuGroup, _sfc_main$28 as DropdownMenuItem, _sfc_main$27 as DropdownMenuLabel, _sfc_main$26 as DropdownMenuRadioGroup, _sfc_main$25 as DropdownMenuRadioItem, _sfc_main$24 as DropdownMenuSeparator, _sfc_main$23 as DropdownMenuShortcut, _sfc_main$22 as DropdownMenuSub, _sfc_main$21 as DropdownMenuSubContent, _sfc_main$20 as DropdownMenuSubTrigger, _sfc_main$1$ as DropdownMenuTrigger, _sfc_main$1X as HoverCard, _sfc_main$1V as Input, _sfc_main$1P as InputNumber, _sfc_main$1O as InputText, _sfc_main$1N as Label, _sfc_main$1M as Link, Loading, _sfc_main$1K as Menubar, _sfc_main$1J as MenubarCheckboxItem, _sfc_main$1I as MenubarContent, _sfc_main$1H as MenubarGroup, _sfc_main$1G as MenubarItem, _sfc_main$1F as MenubarLabel, _sfc_main$1E as MenubarMenu, _sfc_main$1D as MenubarRadioGroup, _sfc_main$1C as MenubarRadioItem, _sfc_main$1B as MenubarSeparator, _sfc_main$1A as MenubarShortcut, _sfc_main$1z as MenubarSub, _sfc_main$1y as MenubarSubContent, _sfc_main$1x as MenubarSubTrigger, _sfc_main$1w as MenubarTrigger, _sfc_main$1v as Pagination, _sfc_main$1u as PaginationContent, _sfc_main$1t as PaginationEllipsis, _sfc_main$1s as PaginationFirst, _sfc_main$1r as PaginationItem, _sfc_main$1q as PaginationLast, _sfc_main$1p as PaginationNext, _sfc_main$1o as PaginationPrevious, _sfc_main$1k as Popover, _sfc_main$1m as PopoverContent, _sfc_main$1j as Progress, _sfc_main$1i as RadioGroup, _sfc_main$1h as RadioGroupItem, _sfc_main$1g as ResizableHandle, _sfc_main$1f as ResizablePanel, _sfc_main$1e as ResizablePanelGroup, _sfc_main$2U as ScrollArea, _sfc_main$12 as Select, _sfc_main$1b as SelectGroup, _sfc_main$1a as SelectItem, _sfc_main$19 as SelectItemText, _sfc_main$18 as SelectLabel, _sfc_main$17 as SelectScrollDownButton, _sfc_main$16 as SelectScrollUpButton, _sfc_main$15 as SelectSeparator, _sfc_main$11 as Separator, _sfc_main$10 as Sheet, _sfc_main$$ as SheetClose, _sfc_main$Z as SheetContent, _sfc_main$Y as SheetDescription, _sfc_main$X as SheetFooter, _sfc_main$W as SheetHeader, _sfc_main$V as SheetTitle, _sfc_main$U as SheetTrigger, _sfc_main$r as Sidebar, _sfc_main$Q as SidebarGroup, _sfc_main$P as SidebarGroupAction, _sfc_main$O as SidebarGroupContent, _sfc_main$N as SidebarGroupLabel, _sfc_main$K as SidebarMenu, _sfc_main$J as SidebarMenuAction, _sfc_main$I as SidebarMenuBadge, _sfc_main$C as SidebarMenuButton, _sfc_main$B as SidebarMenuItem, _sfc_main$z as SidebarMenuSkeleton, _sfc_main$y as SidebarMenuSub, _sfc_main$x as SidebarMenuSubButton, _sfc_main$w as SidebarMenuSubItem, _sfc_main$u as SidebarRail, _sfc_main$t as SidebarSeparator, _sfc_main$s as SidebarTrigger, _sfc_main$A as Skeleton, _sfc_main$q as Slider, _sfc_main$p as Sonner, _sfc_main$n as Switch, _sfc_main$e as Table, _sfc_main$k as TableCell, _sfc_main$i as TableEmpty, _sfc_main$g as TableHead, _sfc_main$d as TableLink, _sfc_main$j as TableRow, _sfc_main$c as Tabs, _sfc_main$b as TabsContent, _sfc_main$a as TabsList, _sfc_main$9 as TabsTrigger, _sfc_main$8 as TagsInput, _sfc_main$7 as TagsInputInput, _sfc_main$6 as TagsInputItem, _sfc_main$5 as TagsInputItemDelete, _sfc_main$4 as TagsInputItemText, _sfc_main$2 as Textarea, _sfc_main$1 as Toggle, _sfc_main as Tooltip, cn, toBooleanCheckboxValue, useSidebar };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tb-dev/vue-components",
3
- "version": "1.0.2",
3
+ "version": "2.0.0",
4
4
  "description": "Vue components",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -1,5 +0,0 @@
1
- import { HTMLAttributes } from 'vue';
2
- export interface PopoverProps {
3
- contentClass?: HTMLAttributes['class'];
4
- keepOpen?: boolean;
5
- }