@vendure/dashboard 3.4.3-master-202509180227 → 3.4.3-master-202509200226

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 (54) hide show
  1. package/dist/vite/vite-plugin-config.js +1 -0
  2. package/package.json +11 -7
  3. package/src/app/common/duplicate-bulk-action.tsx +37 -23
  4. package/src/app/common/duplicate-entity-dialog.tsx +117 -0
  5. package/src/app/routes/_authenticated/_administrators/administrators.tsx +1 -2
  6. package/src/app/routes/_authenticated/_assets/assets.graphql.ts +39 -0
  7. package/src/app/routes/_authenticated/_assets/assets_.$id.tsx +18 -7
  8. package/src/app/routes/_authenticated/_assets/components/asset-tag-filter.tsx +206 -0
  9. package/src/app/routes/_authenticated/_assets/components/asset-tags-editor.tsx +226 -0
  10. package/src/app/routes/_authenticated/_assets/components/manage-tags-dialog.tsx +217 -0
  11. package/src/app/routes/_authenticated/_channels/channels.tsx +1 -2
  12. package/src/app/routes/_authenticated/_collections/collections.tsx +2 -16
  13. package/src/app/routes/_authenticated/_countries/countries.tsx +1 -2
  14. package/src/app/routes/_authenticated/_customer-groups/customer-groups.tsx +1 -2
  15. package/src/app/routes/_authenticated/_customers/customers.tsx +1 -2
  16. package/src/app/routes/_authenticated/_facets/facets.tsx +0 -1
  17. package/src/app/routes/_authenticated/_payment-methods/payment-methods.tsx +1 -2
  18. package/src/app/routes/_authenticated/_product-variants/product-variants.tsx +1 -2
  19. package/src/app/routes/_authenticated/_products/products.tsx +1 -2
  20. package/src/app/routes/_authenticated/_promotions/promotions.tsx +1 -2
  21. package/src/app/routes/_authenticated/_roles/roles.tsx +1 -2
  22. package/src/app/routes/_authenticated/_sellers/sellers.tsx +1 -2
  23. package/src/app/routes/_authenticated/_shipping-methods/shipping-methods.tsx +1 -2
  24. package/src/app/routes/_authenticated/_stock-locations/stock-locations.tsx +1 -2
  25. package/src/app/routes/_authenticated/_tax-categories/tax-categories.tsx +1 -2
  26. package/src/app/routes/_authenticated/_tax-rates/tax-rates.tsx +1 -2
  27. package/src/app/routes/_authenticated/_zones/zones.tsx +1 -2
  28. package/src/lib/components/data-input/rich-text-input.tsx +2 -115
  29. package/src/lib/components/data-table/data-table-bulk-actions.tsx +5 -14
  30. package/src/lib/components/data-table/use-all-bulk-actions.ts +19 -0
  31. package/src/lib/components/data-table/use-generated-columns.tsx +12 -3
  32. package/src/lib/components/layout/nav-main.tsx +50 -25
  33. package/src/lib/components/shared/asset/asset-focal-point-editor.tsx +1 -1
  34. package/src/lib/components/shared/asset/asset-gallery.tsx +83 -50
  35. package/src/lib/components/shared/paginated-list-data-table.tsx +1 -0
  36. package/src/lib/components/shared/rich-text-editor/image-dialog.tsx +223 -0
  37. package/src/lib/components/shared/rich-text-editor/link-dialog.tsx +151 -0
  38. package/src/lib/components/shared/rich-text-editor/responsive-toolbar.tsx +439 -0
  39. package/src/lib/components/shared/rich-text-editor/rich-text-editor.tsx +338 -0
  40. package/src/lib/components/shared/rich-text-editor/table-delete-menu.tsx +104 -0
  41. package/src/lib/components/shared/rich-text-editor/table-edit-icons.tsx +225 -0
  42. package/src/lib/components/shared/vendure-image.tsx +9 -1
  43. package/src/lib/framework/defaults.ts +24 -0
  44. package/src/lib/framework/extension-api/types/navigation.ts +8 -0
  45. package/src/lib/framework/nav-menu/nav-menu-extensions.ts +26 -0
  46. package/src/lib/framework/page/list-page.tsx +7 -0
  47. package/src/lib/graphql/common-operations.ts +19 -0
  48. package/src/lib/graphql/fragments.ts +23 -13
  49. package/src/lib/hooks/use-custom-field-config.ts +19 -2
  50. package/src/lib/index.ts +0 -1
  51. package/src/lib/providers/channel-provider.tsx +22 -6
  52. package/src/lib/providers/server-config.tsx +1 -0
  53. package/src/app/routes/_authenticated/_collections/components/move-single-collection.tsx +0 -33
  54. package/src/lib/components/shared/asset/focal-point-control.tsx +0 -57
@@ -0,0 +1,226 @@
1
+ import { Badge } from '@/vdb/components/ui/badge.js';
2
+ import { Button } from '@/vdb/components/ui/button.js';
3
+ import {
4
+ Command,
5
+ CommandEmpty,
6
+ CommandGroup,
7
+ CommandInput,
8
+ CommandItem,
9
+ } from '@/vdb/components/ui/command.js';
10
+ import { Label } from '@/vdb/components/ui/label.js';
11
+ import { Popover, PopoverContent, PopoverTrigger } from '@/vdb/components/ui/popover.js';
12
+ import { api } from '@/vdb/graphql/api.js';
13
+ import { Trans } from '@/vdb/lib/trans.js';
14
+ import { cn } from '@/vdb/lib/utils.js';
15
+ import { useMutation, useQuery, useQueryClient } from '@tanstack/react-query';
16
+ import { Check, ChevronsUpDown, Settings2, X } from 'lucide-react';
17
+ import { useCallback, useState } from 'react';
18
+ import { toast } from 'sonner';
19
+ import { createTagDocument, tagListDocument } from '../assets.graphql.js';
20
+ import { ManageTagsDialog } from './manage-tags-dialog.js';
21
+
22
+ interface AssetTagsEditorProps {
23
+ selectedTags: string[];
24
+ onTagsChange: (tags: string[]) => void;
25
+ disabled?: boolean;
26
+ onTagsUpdated?: () => void;
27
+ }
28
+
29
+ export function AssetTagsEditor({
30
+ selectedTags,
31
+ onTagsChange,
32
+ disabled = false,
33
+ onTagsUpdated,
34
+ }: Readonly<AssetTagsEditorProps>) {
35
+ const [open, setOpen] = useState(false);
36
+ const [searchValue, setSearchValue] = useState('');
37
+ const [manageDialogOpen, setManageDialogOpen] = useState(false);
38
+ const queryClient = useQueryClient();
39
+
40
+ // Fetch available tags
41
+ const { data: tagsData } = useQuery({
42
+ queryKey: ['tags'],
43
+ queryFn: () => api.query(tagListDocument, { options: { take: 100 } }),
44
+ staleTime: 1000 * 60 * 5, // 5 minutes
45
+ });
46
+
47
+ // Create new tag mutation
48
+ const createTagMutation = useMutation({
49
+ mutationFn: (tagValue: string) => api.mutate(createTagDocument, { input: { value: tagValue } }),
50
+ onSuccess: data => {
51
+ const newTag = data.createTag.value;
52
+ onTagsChange([...selectedTags, newTag]);
53
+ toast.success(`Created tag "${newTag}"`);
54
+ setSearchValue('');
55
+ // Invalidate and refetch tags list
56
+ queryClient.invalidateQueries({ queryKey: ['tags'] });
57
+ },
58
+ onError: error => {
59
+ toast.error('Failed to create tag', {
60
+ description: error instanceof Error ? error.message : 'Unknown error',
61
+ });
62
+ },
63
+ });
64
+
65
+ const availableTags = tagsData?.tags.items || [];
66
+
67
+ // Filter tags based on search value
68
+ const filteredTags = availableTags.filter(tag =>
69
+ tag.value.toLowerCase().includes(searchValue.toLowerCase()),
70
+ );
71
+
72
+ // Check if search value would create a new tag
73
+ const isNewTag =
74
+ searchValue.trim() &&
75
+ !availableTags.some(tag => tag.value.toLowerCase() === searchValue.toLowerCase());
76
+
77
+ const handleSelectTag = useCallback(
78
+ (tagValue: string) => {
79
+ if (!selectedTags.includes(tagValue)) {
80
+ onTagsChange([...selectedTags, tagValue]);
81
+ }
82
+ setSearchValue('');
83
+ setOpen(false);
84
+ },
85
+ [selectedTags, onTagsChange],
86
+ );
87
+
88
+ const handleRemoveTag = useCallback(
89
+ (tagToRemove: string) => {
90
+ onTagsChange(selectedTags.filter(tag => tag !== tagToRemove));
91
+ },
92
+ [selectedTags, onTagsChange],
93
+ );
94
+
95
+ const handleCreateTag = useCallback(() => {
96
+ if (isNewTag) {
97
+ createTagMutation.mutate(searchValue.trim());
98
+ }
99
+ }, [isNewTag, searchValue, createTagMutation]);
100
+
101
+ return (
102
+ <div className="space-y-3">
103
+ <Label>
104
+ <Trans>Tags</Trans>
105
+ </Label>
106
+
107
+ {/* Selected tags display */}
108
+ <div className="flex flex-wrap gap-2 min-h-[32px]">
109
+ {selectedTags.length === 0 ? (
110
+ <span className="text-sm text-muted-foreground">
111
+ <Trans>No tags selected</Trans>
112
+ </span>
113
+ ) : (
114
+ selectedTags.map(tag => (
115
+ <Badge key={tag} variant="secondary" className="flex items-center gap-1">
116
+ {tag}
117
+ {!disabled && (
118
+ <button
119
+ type="button"
120
+ onClick={() => handleRemoveTag(tag)}
121
+ className="ml-1 hover:bg-destructive/20 rounded-full p-0.5 transition-colors"
122
+ >
123
+ <X className="h-3 w-3" />
124
+ </button>
125
+ )}
126
+ </Badge>
127
+ ))
128
+ )}
129
+ </div>
130
+
131
+ {/* Tag selector */}
132
+ {!disabled && (
133
+ <Popover open={open} onOpenChange={setOpen}>
134
+ <PopoverTrigger asChild>
135
+ <Button
136
+ variant="outline"
137
+ role="combobox"
138
+ aria-expanded={open}
139
+ className="w-full justify-between"
140
+ >
141
+ <Trans>Add tags...</Trans>
142
+ <ChevronsUpDown className="ml-2 h-4 w-4 shrink-0 opacity-50" />
143
+ </Button>
144
+ </PopoverTrigger>
145
+ <PopoverContent className="w-full p-0" align="start">
146
+ <Command>
147
+ <CommandInput
148
+ placeholder="Search tags..."
149
+ value={searchValue}
150
+ onValueChange={setSearchValue}
151
+ />
152
+ <CommandEmpty>
153
+ {searchValue.trim() ? (
154
+ <div className="">
155
+ <Button
156
+ variant="ghost"
157
+ className="w-full justify-start"
158
+ onClick={handleCreateTag}
159
+ disabled={createTagMutation.isPending}
160
+ >
161
+ <Trans>Create "{searchValue.trim()}"</Trans>
162
+ </Button>
163
+ </div>
164
+ ) : (
165
+ <div className="p-2 text-sm">
166
+ <Trans>No tags found</Trans>
167
+ </div>
168
+ )}
169
+ </CommandEmpty>
170
+ <CommandGroup>
171
+ {/* Show option to create new tag if search doesn't match exactly */}
172
+ {isNewTag && (
173
+ <CommandItem
174
+ onSelect={handleCreateTag}
175
+ disabled={createTagMutation.isPending}
176
+ className="font-medium"
177
+ >
178
+ <Trans>Create "{searchValue.trim()}"</Trans>
179
+ </CommandItem>
180
+ )}
181
+
182
+ {/* Show existing tags */}
183
+ {filteredTags.map(tag => {
184
+ const isSelected = selectedTags.includes(tag.value);
185
+ return (
186
+ <CommandItem
187
+ key={tag.id}
188
+ onSelect={() => handleSelectTag(tag.value)}
189
+ disabled={isSelected}
190
+ >
191
+ <Check
192
+ className={cn(
193
+ 'mr-2 h-4 w-4',
194
+ isSelected ? 'opacity-100' : 'opacity-0',
195
+ )}
196
+ />
197
+ {tag.value}
198
+ </CommandItem>
199
+ );
200
+ })}
201
+ </CommandGroup>
202
+ </Command>
203
+ </PopoverContent>
204
+ </Popover>
205
+ )}
206
+
207
+ {!disabled && (
208
+ <Button
209
+ variant="ghost"
210
+ size="sm"
211
+ onClick={() => setManageDialogOpen(true)}
212
+ className="w-full justify-start"
213
+ >
214
+ <Settings2 className="h-4 w-4 mr-2" />
215
+ <Trans>Manage tags</Trans>
216
+ </Button>
217
+ )}
218
+ {/* Manage Tags Dialog */}
219
+ <ManageTagsDialog
220
+ open={manageDialogOpen}
221
+ onOpenChange={setManageDialogOpen}
222
+ onTagsUpdated={onTagsUpdated}
223
+ />
224
+ </div>
225
+ );
226
+ }
@@ -0,0 +1,217 @@
1
+ import { Button } from '@/vdb/components/ui/button.js';
2
+ import {
3
+ Dialog,
4
+ DialogContent,
5
+ DialogDescription,
6
+ DialogFooter,
7
+ DialogHeader,
8
+ DialogTitle,
9
+ } from '@/vdb/components/ui/dialog.js';
10
+ import { Input } from '@/vdb/components/ui/input.js';
11
+ import { api } from '@/vdb/graphql/api.js';
12
+ import { Trans } from '@/vdb/lib/trans.js';
13
+ import { cn } from '@/vdb/lib/utils.js';
14
+ import { useMutation, useQuery, useQueryClient } from '@tanstack/react-query';
15
+ import { Trash2 } from 'lucide-react';
16
+ import { useState } from 'react';
17
+ import { toast } from 'sonner';
18
+ import { deleteTagDocument, tagListDocument, updateTagDocument } from '../assets.graphql.js';
19
+
20
+ interface ManageTagsDialogProps {
21
+ open: boolean;
22
+ onOpenChange: (open: boolean) => void;
23
+ onTagsUpdated?: () => void;
24
+ }
25
+
26
+ export function ManageTagsDialog({ open, onOpenChange, onTagsUpdated }: Readonly<ManageTagsDialogProps>) {
27
+ const queryClient = useQueryClient();
28
+ const [toDelete, setToDelete] = useState<string[]>([]);
29
+ const [toUpdate, setToUpdate] = useState<Array<{ id: string; value: string }>>([]);
30
+ const [isSaving, setIsSaving] = useState(false);
31
+
32
+ // Fetch all tags
33
+ const { data: tagsData, isLoading } = useQuery({
34
+ queryKey: ['tags'],
35
+ queryFn: () => api.query(tagListDocument, { options: { take: 100 } }),
36
+ staleTime: 1000 * 60 * 5,
37
+ });
38
+
39
+ // Update tag mutation
40
+ const updateTagMutation = useMutation({
41
+ mutationFn: ({ id, value }: { id: string; value: string }) =>
42
+ api.mutate(updateTagDocument, { input: { id, value } }),
43
+ });
44
+
45
+ // Delete tag mutation
46
+ const deleteTagMutation = useMutation({
47
+ mutationFn: (id: string) => api.mutate(deleteTagDocument, { id }),
48
+ });
49
+
50
+ const allTags = tagsData?.tags.items || [];
51
+
52
+ const toggleDelete = (id: string) => {
53
+ if (toDelete.includes(id)) {
54
+ setToDelete(toDelete.filter(_id => _id !== id));
55
+ } else {
56
+ setToDelete([...toDelete, id]);
57
+ }
58
+ };
59
+
60
+ const markedAsDeleted = (id: string) => {
61
+ return toDelete.includes(id);
62
+ };
63
+
64
+ const updateTagValue = (id: string, value: string) => {
65
+ const exists = toUpdate.find(i => i.id === id);
66
+ if (exists) {
67
+ if (value === allTags.find(tag => tag.id === id)?.value) {
68
+ // If value is reverted to original, remove from update list
69
+ setToUpdate(toUpdate.filter(i => i.id !== id));
70
+ } else {
71
+ exists.value = value;
72
+ setToUpdate([...toUpdate]);
73
+ }
74
+ } else {
75
+ setToUpdate([...toUpdate, { id, value }]);
76
+ }
77
+ };
78
+
79
+ const getDisplayValue = (id: string) => {
80
+ const updateItem = toUpdate.find(i => i.id === id);
81
+ if (updateItem) {
82
+ return updateItem.value;
83
+ }
84
+ return allTags.find(tag => tag.id === id)?.value || '';
85
+ };
86
+
87
+ const renderTagsList = () => {
88
+ if (isLoading) {
89
+ return (
90
+ <div className="text-sm text-muted-foreground">
91
+ <Trans>Loading tags...</Trans>
92
+ </div>
93
+ );
94
+ }
95
+
96
+ if (allTags.length === 0) {
97
+ return (
98
+ <div className="text-sm text-muted-foreground">
99
+ <Trans>No tags found</Trans>
100
+ </div>
101
+ );
102
+ }
103
+
104
+ return allTags.map(tag => {
105
+ const isDeleted = markedAsDeleted(tag.id);
106
+ const isModified = toUpdate.some(i => i.id === tag.id);
107
+
108
+ return (
109
+ <div
110
+ key={tag.id}
111
+ className={cn(
112
+ 'flex items-center gap-2 p-2 rounded-md',
113
+ isDeleted && 'opacity-50',
114
+ )}
115
+ >
116
+ <Input
117
+ value={getDisplayValue(tag.id)}
118
+ onChange={e => updateTagValue(tag.id, e.target.value)}
119
+ disabled={isDeleted || isSaving}
120
+ className={cn('flex-1', isModified && !isDeleted && 'border-primary')}
121
+ />
122
+ <Button
123
+ variant={isDeleted ? 'default' : 'ghost'}
124
+ size="icon"
125
+ onClick={() => toggleDelete(tag.id)}
126
+ disabled={isSaving}
127
+ className={cn(isDeleted && 'bg-destructive hover:bg-destructive/90')}
128
+ >
129
+ <Trash2 className="h-4 w-4" />
130
+ </Button>
131
+ </div>
132
+ );
133
+ });
134
+ };
135
+
136
+ const hasChanges = toDelete.length > 0 || toUpdate.length > 0;
137
+
138
+ const handleCancel = () => {
139
+ setToDelete([]);
140
+ setToUpdate([]);
141
+ onOpenChange(false);
142
+ };
143
+
144
+ const handleSave = async () => {
145
+ setIsSaving(true);
146
+
147
+ try {
148
+ const operations = [];
149
+
150
+ // Delete operations
151
+ for (const id of toDelete) {
152
+ operations.push(deleteTagMutation.mutateAsync(id));
153
+ }
154
+
155
+ // Update operations (skip if marked for deletion)
156
+ for (const item of toUpdate) {
157
+ if (!toDelete.includes(item.id)) {
158
+ operations.push(updateTagMutation.mutateAsync(item));
159
+ }
160
+ }
161
+
162
+ await Promise.all(operations);
163
+
164
+ // Invalidate tags query to refresh the list
165
+ await queryClient.invalidateQueries({ queryKey: ['tags'] });
166
+
167
+ // Also invalidate asset queries to refresh any assets using these tags
168
+ await queryClient.invalidateQueries({ queryKey: ['asset'] });
169
+
170
+ toast.success('Tags updated successfully');
171
+
172
+ // Call callback to notify parent component
173
+ if (onTagsUpdated) {
174
+ onTagsUpdated();
175
+ }
176
+
177
+ // Reset state
178
+ setToDelete([]);
179
+ setToUpdate([]);
180
+ onOpenChange(false);
181
+ } catch (error) {
182
+ toast.error('Failed to update tags', {
183
+ description: error instanceof Error ? error.message : 'Unknown error',
184
+ });
185
+ } finally {
186
+ setIsSaving(false);
187
+ }
188
+ };
189
+
190
+ return (
191
+ <Dialog open={open} onOpenChange={onOpenChange}>
192
+ <DialogContent className="max-w-md">
193
+ <DialogHeader>
194
+ <DialogTitle>
195
+ <Trans>Manage Tags</Trans>
196
+ </DialogTitle>
197
+ <DialogDescription>
198
+ <Trans>Edit or delete existing tags</Trans>
199
+ </DialogDescription>
200
+ </DialogHeader>
201
+
202
+ <div className="max-h-[400px] overflow-y-auto space-y-2 py-4">
203
+ {renderTagsList()}
204
+ </div>
205
+
206
+ <DialogFooter>
207
+ <Button variant="outline" onClick={handleCancel} disabled={isSaving}>
208
+ <Trans>Cancel</Trans>
209
+ </Button>
210
+ <Button onClick={handleSave} disabled={!hasChanges || isSaving}>
211
+ {isSaving ? <Trans>Saving...</Trans> : <Trans>Save Changes</Trans>}
212
+ </Button>
213
+ </DialogFooter>
214
+ </DialogContent>
215
+ </Dialog>
216
+ );
217
+ }
@@ -8,7 +8,7 @@ import { useLocalFormat } from '@/vdb/hooks/use-local-format.js';
8
8
  import { Trans } from '@/vdb/lib/trans.js';
9
9
  import { createFileRoute, Link } from '@tanstack/react-router';
10
10
  import { PlusIcon } from 'lucide-react';
11
- import { channelListQuery, deleteChannelDocument } from './channels.graphql.js';
11
+ import { channelListQuery } from './channels.graphql.js';
12
12
  import { DeleteChannelsBulkAction } from './components/channel-bulk-actions.js';
13
13
 
14
14
  export const Route = createFileRoute('/_authenticated/_channels/channels')({
@@ -23,7 +23,6 @@ function ChannelListPage() {
23
23
  pageId="channel-list"
24
24
  title="Channels"
25
25
  listQuery={channelListQuery}
26
- deleteMutation={deleteChannelDocument}
27
26
  route={Route}
28
27
  defaultVisibility={{
29
28
  code: true,
@@ -10,11 +10,11 @@ import { createFileRoute, Link } from '@tanstack/react-router';
10
10
  import { ExpandedState, getExpandedRowModel } from '@tanstack/react-table';
11
11
  import { TableOptions } from '@tanstack/table-core';
12
12
  import { ResultOf } from 'gql.tada';
13
- import { Folder, FolderOpen, FolderTreeIcon, PlusIcon } from 'lucide-react';
13
+ import { Folder, FolderOpen, PlusIcon } from 'lucide-react';
14
14
  import { useState } from 'react';
15
15
 
16
16
  import { Badge } from '@/vdb/components/ui/badge.js';
17
- import { collectionListDocument, deleteCollectionDocument } from './collections.graphql.js';
17
+ import { collectionListDocument } from './collections.graphql.js';
18
18
  import {
19
19
  AssignCollectionsToChannelBulkAction,
20
20
  DeleteCollectionsBulkAction,
@@ -23,7 +23,6 @@ import {
23
23
  RemoveCollectionsFromChannelBulkAction,
24
24
  } from './components/collection-bulk-actions.js';
25
25
  import { CollectionContentsSheet } from './components/collection-contents-sheet.js';
26
- import { useMoveSingleCollection } from './components/move-single-collection.js';
27
26
 
28
27
  export const Route = createFileRoute('/_authenticated/_collections/collections')({
29
28
  component: CollectionListPage,
@@ -34,7 +33,6 @@ type Collection = ResultOf<typeof collectionListDocument>['collections']['items'
34
33
 
35
34
  function CollectionListPage() {
36
35
  const [expanded, setExpanded] = useState<ExpandedState>({});
37
- const { handleMoveClick, MoveDialog } = useMoveSingleCollection();
38
36
  const childrenQueries = useQueries({
39
37
  queries: Object.entries(expanded).map(([collectionId, isExpanded]) => {
40
38
  return {
@@ -96,7 +94,6 @@ function CollectionListPage() {
96
94
  },
97
95
  };
98
96
  }}
99
- deleteMutation={deleteCollectionDocument}
100
97
  customizeColumns={{
101
98
  name: {
102
99
  header: 'Collection Name',
@@ -210,16 +207,6 @@ function CollectionListPage() {
210
207
  };
211
208
  }}
212
209
  route={Route}
213
- rowActions={[
214
- {
215
- label: (
216
- <div className="flex items-center gap-2">
217
- <FolderTreeIcon className="w-4 h-4" /> <Trans>Move</Trans>
218
- </div>
219
- ),
220
- onClick: row => handleMoveClick(row.original),
221
- },
222
- ]}
223
210
  bulkActions={[
224
211
  {
225
212
  component: AssignCollectionsToChannelBulkAction,
@@ -254,7 +241,6 @@ function CollectionListPage() {
254
241
  </PermissionGuard>
255
242
  </PageActionBarRight>
256
243
  </ListPage>
257
- <MoveDialog />
258
244
  </>
259
245
  );
260
246
  }
@@ -7,7 +7,7 @@ import { Trans } from '@/vdb/lib/trans.js';
7
7
  import { createFileRoute, Link } from '@tanstack/react-router';
8
8
  import { PlusIcon } from 'lucide-react';
9
9
  import { DeleteCountriesBulkAction } from './components/country-bulk-actions.js';
10
- import { countriesListQuery, deleteCountryDocument } from './countries.graphql.js';
10
+ import { countriesListQuery } from './countries.graphql.js';
11
11
 
12
12
  export const Route = createFileRoute('/_authenticated/_countries/countries')({
13
13
  component: CountryListPage,
@@ -19,7 +19,6 @@ function CountryListPage() {
19
19
  <ListPage
20
20
  pageId="country-list"
21
21
  listQuery={countriesListQuery}
22
- deleteMutation={deleteCountryDocument}
23
22
  route={Route}
24
23
  title="Countries"
25
24
  defaultVisibility={{
@@ -8,7 +8,7 @@ import { createFileRoute, Link } from '@tanstack/react-router';
8
8
  import { PlusIcon } from 'lucide-react';
9
9
  import { DeleteCustomerGroupsBulkAction } from './components/customer-group-bulk-actions.js';
10
10
  import { CustomerGroupMembersSheet } from './components/customer-group-members-sheet.js';
11
- import { customerGroupListDocument, deleteCustomerGroupDocument } from './customer-groups.graphql.js';
11
+ import { customerGroupListDocument } from './customer-groups.graphql.js';
12
12
 
13
13
  export const Route = createFileRoute('/_authenticated/_customer-groups/customer-groups')({
14
14
  component: CustomerGroupListPage,
@@ -21,7 +21,6 @@ function CustomerGroupListPage() {
21
21
  pageId="customer-group-list"
22
22
  title="Customer Groups"
23
23
  listQuery={customerGroupListDocument}
24
- deleteMutation={deleteCustomerGroupDocument}
25
24
  route={Route}
26
25
  customizeColumns={{
27
26
  name: {
@@ -8,7 +8,7 @@ import { createFileRoute, Link } from '@tanstack/react-router';
8
8
  import { PlusIcon } from 'lucide-react';
9
9
  import { DeleteCustomersBulkAction } from './components/customer-bulk-actions.js';
10
10
  import { CustomerStatusBadge } from './components/customer-status-badge.js';
11
- import { customerListDocument, deleteCustomerDocument } from './customers.graphql.js';
11
+ import { customerListDocument } from './customers.graphql.js';
12
12
 
13
13
  export const Route = createFileRoute('/_authenticated/_customers/customers')({
14
14
  component: CustomerListPage,
@@ -21,7 +21,6 @@ function CustomerListPage() {
21
21
  title="Customers"
22
22
  pageId="customer-list"
23
23
  listQuery={customerListDocument}
24
- deleteMutation={deleteCustomerDocument}
25
24
  onSearchTermChange={searchTerm => {
26
25
  return {
27
26
  lastName: {
@@ -63,7 +63,6 @@ function FacetListPage() {
63
63
  pageId="facet-list"
64
64
  title="Facets"
65
65
  listQuery={facetListDocument}
66
- deleteMutation={deleteFacetDocument}
67
66
  defaultVisibility={{
68
67
  name: true,
69
68
  isPrivate: true,
@@ -12,7 +12,7 @@ import {
12
12
  DeletePaymentMethodsBulkAction,
13
13
  RemovePaymentMethodsFromChannelBulkAction,
14
14
  } from './components/payment-method-bulk-actions.js';
15
- import { deletePaymentMethodDocument, paymentMethodListQuery } from './payment-methods.graphql.js';
15
+ import { paymentMethodListQuery } from './payment-methods.graphql.js';
16
16
 
17
17
  export const Route = createFileRoute('/_authenticated/_payment-methods/payment-methods')({
18
18
  component: PaymentMethodListPage,
@@ -24,7 +24,6 @@ function PaymentMethodListPage() {
24
24
  <ListPage
25
25
  pageId="payment-method-list"
26
26
  listQuery={paymentMethodListQuery}
27
- deleteMutation={deletePaymentMethodDocument}
28
27
  route={Route}
29
28
  title="Payment Methods"
30
29
  defaultVisibility={{
@@ -11,7 +11,7 @@ import {
11
11
  DeleteProductVariantsBulkAction,
12
12
  RemoveProductVariantsFromChannelBulkAction,
13
13
  } from './components/product-variant-bulk-actions.js';
14
- import { deleteProductVariantDocument, productVariantListDocument } from './product-variants.graphql.js';
14
+ import { productVariantListDocument } from './product-variants.graphql.js';
15
15
 
16
16
  export const Route = createFileRoute('/_authenticated/_product-variants/product-variants')({
17
17
  component: ProductListPage,
@@ -25,7 +25,6 @@ function ProductListPage() {
25
25
  pageId="product-variant-list"
26
26
  title={<Trans>Product Variants</Trans>}
27
27
  listQuery={productVariantListDocument}
28
- deleteMutation={deleteProductVariantDocument}
29
28
  bulkActions={[
30
29
  {
31
30
  component: AssignProductVariantsToChannelBulkAction,
@@ -13,7 +13,7 @@ import {
13
13
  DuplicateProductsBulkAction,
14
14
  RemoveProductsFromChannelBulkAction,
15
15
  } from './components/product-bulk-actions.js';
16
- import { deleteProductDocument, productListDocument } from './products.graphql.js';
16
+ import { productListDocument } from './products.graphql.js';
17
17
 
18
18
  export const Route = createFileRoute('/_authenticated/_products/products')({
19
19
  component: ProductListPage,
@@ -25,7 +25,6 @@ function ProductListPage() {
25
25
  <ListPage
26
26
  pageId="product-list"
27
27
  listQuery={productListDocument}
28
- deleteMutation={deleteProductDocument}
29
28
  title="Products"
30
29
  customizeColumns={{
31
30
  name: {
@@ -13,7 +13,7 @@ import {
13
13
  DuplicatePromotionsBulkAction,
14
14
  RemovePromotionsFromChannelBulkAction,
15
15
  } from './components/promotion-bulk-actions.js';
16
- import { deletePromotionDocument, promotionListDocument } from './promotions.graphql.js';
16
+ import { promotionListDocument } from './promotions.graphql.js';
17
17
 
18
18
  export const Route = createFileRoute('/_authenticated/_promotions/promotions')({
19
19
  component: PromotionListPage,
@@ -25,7 +25,6 @@ function PromotionListPage() {
25
25
  <ListPage
26
26
  pageId="promotion-list"
27
27
  listQuery={promotionListDocument}
28
- deleteMutation={deletePromotionDocument}
29
28
  route={Route}
30
29
  title="Promotions"
31
30
  defaultVisibility={{
@@ -12,7 +12,7 @@ import { createFileRoute, Link } from '@tanstack/react-router';
12
12
  import { LayersIcon, PlusIcon } from 'lucide-react';
13
13
  import { ExpandablePermissions } from './components/expandable-permissions.js';
14
14
  import { DeleteRolesBulkAction } from './components/role-bulk-actions.js';
15
- import { deleteRoleDocument, roleListQuery } from './roles.graphql.js';
15
+ import { roleListQuery } from './roles.graphql.js';
16
16
 
17
17
  export const Route = createFileRoute('/_authenticated/_roles/roles')({
18
18
  component: RoleListPage,
@@ -27,7 +27,6 @@ function RoleListPage() {
27
27
  pageId="role-list"
28
28
  title="Roles"
29
29
  listQuery={roleListQuery}
30
- deleteMutation={deleteRoleDocument}
31
30
  route={Route}
32
31
  defaultVisibility={{
33
32
  description: true,