@vendure/dashboard 3.5.0-minor-202510201346 → 3.5.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.
Files changed (50) hide show
  1. package/dist/vite/types.d.ts +39 -0
  2. package/dist/vite/utils/plugin-discovery.js +15 -4
  3. package/dist/vite/vite-plugin-ui-config.d.ts +27 -0
  4. package/dist/vite/vite-plugin-vendure-dashboard.d.ts +18 -1
  5. package/dist/vite/vite-plugin-vendure-dashboard.js +19 -7
  6. package/lingui.config.js +1 -0
  7. package/package.json +172 -172
  8. package/src/app/routes/_authenticated/_collections/components/collection-contents-preview-table.tsx +88 -61
  9. package/src/app/routes/_authenticated/_collections/components/move-collections-dialog.tsx +46 -47
  10. package/src/app/routes/_authenticated/_product-variants/product-variants.tsx +12 -1
  11. package/src/app/routes/_authenticated/_product-variants/product-variants_.$id.tsx +12 -7
  12. package/src/app/routes/_authenticated/_products/products.tsx +13 -1
  13. package/src/app/routes/_authenticated/_shipping-methods/shipping-methods_.$id.tsx +8 -2
  14. package/src/app/routes/_authenticated/_tax-categories/tax-categories_.$id.tsx +1 -0
  15. package/src/i18n/locales/ar.po +214 -186
  16. package/src/i18n/locales/cs.po +214 -186
  17. package/src/i18n/locales/de.po +214 -186
  18. package/src/i18n/locales/en.po +214 -186
  19. package/src/i18n/locales/es.po +214 -186
  20. package/src/i18n/locales/fa.po +214 -186
  21. package/src/i18n/locales/fr.po +214 -186
  22. package/src/i18n/locales/he.po +214 -186
  23. package/src/i18n/locales/hr.po +214 -186
  24. package/src/i18n/locales/it.po +214 -186
  25. package/src/i18n/locales/ja.po +214 -186
  26. package/src/i18n/locales/nb.po +214 -186
  27. package/src/i18n/locales/ne.po +214 -186
  28. package/src/i18n/locales/pl.po +214 -186
  29. package/src/i18n/locales/pt_BR.po +214 -186
  30. package/src/i18n/locales/pt_PT.po +214 -186
  31. package/src/i18n/locales/ru.po +214 -186
  32. package/src/i18n/locales/sv.po +214 -186
  33. package/src/i18n/locales/tr.po +214 -186
  34. package/src/i18n/locales/uk.po +214 -186
  35. package/src/i18n/locales/zh_Hans.po +214 -186
  36. package/src/i18n/locales/zh_Hant.po +214 -186
  37. package/src/lib/components/data-table/data-table-pagination.tsx +4 -4
  38. package/src/lib/components/data-table/data-table.stories.tsx +1 -1
  39. package/src/lib/components/data-table/data-table.tsx +1 -1
  40. package/src/lib/components/data-table/use-generated-columns.tsx +5 -1
  41. package/src/lib/components/layout/app-layout.tsx +0 -2
  42. package/src/lib/components/shared/asset/asset-gallery.stories.tsx +1 -1
  43. package/src/lib/components/shared/asset/asset-picker-dialog.stories.tsx +1 -1
  44. package/src/lib/components/shared/detail-page-button.stories.tsx +1 -1
  45. package/src/lib/components/shared/facet-value-selector.stories.tsx +1 -1
  46. package/src/lib/components/shared/paginated-list-data-table.stories.tsx +1 -1
  47. package/src/lib/components/shared/permission-guard.stories.tsx +1 -1
  48. package/src/lib/components/shared/vendure-image.stories.tsx +1 -1
  49. package/src/lib/index.ts +0 -1
  50. package/src/lib/components/layout/prerelease-popup.tsx +0 -34
@@ -18,7 +18,7 @@ export function DataTablePagination<TData>({ table }: DataTablePaginationProps<T
18
18
  </div>
19
19
  <div className="flex items-center space-x-6 lg:space-x-8">
20
20
  <div className="flex items-center space-x-2">
21
- <p className="hidden md:block text-sm font-medium">
21
+ <p className="hidden @xl/table:block text-sm font-medium">
22
22
  <Trans>Rows per page</Trans>
23
23
  </p>
24
24
  <Select
@@ -40,7 +40,7 @@ export function DataTablePagination<TData>({ table }: DataTablePaginationProps<T
40
40
  </Select>
41
41
  </div>
42
42
  <div className=" flex items-center justify-center text-sm font-medium">
43
- <span className="hidden md:block w-[100px] ">
43
+ <span className="hidden @sm/table:block w-[100px] ">
44
44
  <Trans>
45
45
  Page {table.getState().pagination.pageIndex + 1} of {table.getPageCount() || 1}
46
46
  </Trans>
@@ -50,7 +50,7 @@ export function DataTablePagination<TData>({ table }: DataTablePaginationProps<T
50
50
  <Button
51
51
  variant="outline"
52
52
  type="button"
53
- className="hidden h-8 w-8 p-0 lg:flex"
53
+ className="hidden h-8 w-8 p-0 @lg:flex"
54
54
  onClick={() => table.setPageIndex(0)}
55
55
  disabled={!table.getCanPreviousPage()}
56
56
  >
@@ -71,7 +71,7 @@ export function DataTablePagination<TData>({ table }: DataTablePaginationProps<T
71
71
  </span>
72
72
  <ChevronLeft />
73
73
  </Button>
74
- <span className="md:hidden">{table.getState().pagination.pageIndex + 1}</span>
74
+ <span className="@md/table:hidden">{table.getState().pagination.pageIndex + 1}</span>
75
75
  <Button
76
76
  variant="outline"
77
77
  type="button"
@@ -30,7 +30,7 @@ const sampleData: Product[] = Array.from({ length: 100 }, (_, i) => ({
30
30
  }));
31
31
 
32
32
  const meta = {
33
- title: 'Components/DataTable',
33
+ title: 'Framework/DataTable',
34
34
  component: DataTable,
35
35
  ...withDescription(import.meta.url, './data-table.js'),
36
36
  parameters: {
@@ -236,7 +236,7 @@ export function DataTable<TData>({
236
236
  isLoading={isLoading}
237
237
  table={table}
238
238
  >
239
- <div className="space-y-2">
239
+ <div className="space-y-2 @container/table">
240
240
  <div className="flex items-center justify-between gap-2">
241
241
  <div className="flex items-center gap-2">
242
242
  {onSearchTermChange && (
@@ -252,7 +252,11 @@ function getRowActions(
252
252
  </DropdownMenuItem>
253
253
  ))}
254
254
  {bulkActions?.map((action, index) => (
255
- <action.component key={`bulk-action-${index}`} selection={[row]} table={table} />
255
+ <action.component
256
+ key={`bulk-action-${index}`}
257
+ selection={[row.original]}
258
+ table={table}
259
+ />
256
260
  ))}
257
261
  {deleteMutation && (
258
262
  <DeleteMutationRowAction deleteMutation={deleteMutation} row={row} />
@@ -1,7 +1,6 @@
1
1
  import { AppSidebar } from '@/vdb/components/layout/app-sidebar.js';
2
2
  import { DevModeIndicator } from '@/vdb/components/layout/dev-mode-indicator.js';
3
3
  import { GeneratedBreadcrumbs } from '@/vdb/components/layout/generated-breadcrumbs.js';
4
- import { PrereleasePopup } from '@/vdb/components/layout/prerelease-popup.js';
5
4
  import { Separator } from '@/vdb/components/ui/separator.js';
6
5
  import { SidebarInset, SidebarProvider, SidebarTrigger } from '@/vdb/components/ui/sidebar.js';
7
6
  import { useUserSettings } from '@/vdb/hooks/use-user-settings.js';
@@ -31,7 +30,6 @@ export function AppLayout() {
31
30
  <Outlet />
32
31
  </div>
33
32
  </SidebarInset>
34
- <PrereleasePopup />
35
33
  </SidebarProvider>
36
34
  );
37
35
  }
@@ -6,7 +6,7 @@ import { createDemoRoute } from '../../../../../.storybook/providers.js';
6
6
  import { withDescription } from '../../../../../.storybook/with-description.js';
7
7
 
8
8
  const meta = {
9
- title: 'Components/AssetGallery',
9
+ title: 'Framework/AssetGallery',
10
10
  component: AssetGallery,
11
11
  ...withDescription(import.meta.url, './asset-gallery.js'),
12
12
  parameters: {
@@ -7,7 +7,7 @@ import { withDescription } from '../../../../../.storybook/with-description.js';
7
7
  import { AssetPickerDialog } from './asset-picker-dialog.js';
8
8
 
9
9
  const meta = {
10
- title: 'Components/AssetPickerDialog',
10
+ title: 'Framework/AssetPickerDialog',
11
11
  component: AssetPickerDialog,
12
12
  ...withDescription(import.meta.url, './asset-picker-dialog.js'),
13
13
  parameters: {
@@ -5,7 +5,7 @@ import { withDescription } from '../../../../.storybook/with-description.js';
5
5
  import { DetailPageButton } from './detail-page-button.js';
6
6
 
7
7
  const meta = {
8
- title: 'Components/DetailPageButton',
8
+ title: 'Framework/DetailPageButton',
9
9
  component: DetailPageButton,
10
10
  ...withDescription(import.meta.url, './detail-page-button.js'),
11
11
  parameters: {
@@ -3,7 +3,7 @@ import { withDescription } from '../../../../.storybook/with-description.js';
3
3
  import { FacetValueSelector } from './facet-value-selector.js';
4
4
 
5
5
  const meta = {
6
- title: 'Components/FacetValueSelector',
6
+ title: 'Framework/FacetValueSelector',
7
7
  component: FacetValueSelector,
8
8
  ...withDescription(import.meta.url, './facet-value-selector.js'),
9
9
  parameters: {
@@ -39,7 +39,7 @@ const productsListDocument = graphql(`
39
39
  `);
40
40
 
41
41
  const meta = {
42
- title: 'Components/PaginatedListDataTable',
42
+ title: 'Framework/PaginatedListDataTable',
43
43
  component: PaginatedListDataTable,
44
44
  ...withDescription(import.meta.url, './paginated-list-data-table.js'),
45
45
  parameters: {
@@ -4,7 +4,7 @@ import { withDescription } from '../../../../.storybook/with-description.js';
4
4
  import { PermissionGuard } from './permission-guard.js';
5
5
 
6
6
  const meta = {
7
- title: 'Components/PermissionGuard',
7
+ title: 'Framework/PermissionGuard',
8
8
  component: PermissionGuard,
9
9
  ...withDescription(import.meta.url, './permission-guard.js'),
10
10
  parameters: {
@@ -18,7 +18,7 @@ const mockAssetWithFocalPoint: AssetLike = {
18
18
  };
19
19
 
20
20
  const meta = {
21
- title: 'Components/VendureImage',
21
+ title: 'Framework/VendureImage',
22
22
  component: VendureImage,
23
23
  ...withDescription(import.meta.url, './vendure-image.js'),
24
24
  parameters: {
package/src/lib/index.ts CHANGED
@@ -72,7 +72,6 @@ export * from './components/layout/nav-item-wrapper.js';
72
72
  export * from './components/layout/nav-main.js';
73
73
  export * from './components/layout/nav-projects.js';
74
74
  export * from './components/layout/nav-user.js';
75
- export * from './components/layout/prerelease-popup.js';
76
75
  export * from './components/login/login-form.js';
77
76
  export * from './components/shared/alerts.js';
78
77
  export * from './components/shared/animated-number.js';
@@ -1,34 +0,0 @@
1
- import { useUserSettings } from '@/vdb/hooks/use-user-settings.js';
2
- import { useState } from 'react';
3
- import { toast } from 'sonner';
4
-
5
- export function PrereleasePopup() {
6
- const { settings, setHasSeenOnboarding } = useUserSettings();
7
- const [isOpen, setIsOpen] = useState(false);
8
- if (!settings.hasSeenOnboarding && !isOpen) {
9
- setIsOpen(true);
10
- toast('Welcome to the new Dashboard!', {
11
- description: (
12
- <div className="space-y-2">
13
- <p>
14
- This is a <span className="font-bold">beta</span> version of our new Vendure
15
- Dashboard!
16
- </p>
17
- <p>
18
- This release allows you to explore the new interface and functionality, but it's not
19
- yet ready for production use.
20
- </p>
21
- </div>
22
- ),
23
- duration: 1000 * 60,
24
- action: {
25
- label: 'Got it',
26
- onClick: () => {
27
- setHasSeenOnboarding(true);
28
- setIsOpen(false);
29
- },
30
- },
31
- });
32
- }
33
- return null;
34
- }