@salesforce/ui-bundle-template-app-react-template-b2e 1.117.2
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.
- package/LICENSE.txt +82 -0
- package/README.md +52 -0
- package/dist/.forceignore +15 -0
- package/dist/.husky/pre-commit +4 -0
- package/dist/.prettierignore +11 -0
- package/dist/.prettierrc +17 -0
- package/dist/AGENT.md +193 -0
- package/dist/CHANGELOG.md +2128 -0
- package/dist/README.md +52 -0
- package/dist/config/project-scratch-def.json +13 -0
- package/dist/eslint.config.js +7 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/.forceignore +15 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/.graphqlrc.yml +2 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/.prettierignore +9 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/.prettierrc +11 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/CHANGELOG.md +10 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/README.md +35 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/codegen.yml +95 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/components.json +18 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/e2e/app.spec.ts +17 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/eslint.config.js +169 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/index.html +12 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/package.json +69 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/playwright.config.ts +24 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/reactinternalapp.uibundle-meta.xml +7 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/scripts/get-graphql-schema.mjs +68 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/scripts/rewrite-e2e-assets.mjs +23 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/api/account/accountSearchService.ts +46 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/api/account/query/distinctAccountIndustries.graphql +19 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/api/account/query/distinctAccountTypes.graphql +19 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/api/account/query/getAccountDetail.graphql +121 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/api/account/query/searchAccounts.graphql +51 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/api/graphql-operations-types.ts +11260 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/api/graphqlClient.ts +25 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/app.tsx +17 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/appLayout.tsx +85 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/assets/icons/book.svg +3 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/assets/icons/copy.svg +4 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/assets/icons/rocket.svg +3 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/assets/icons/star.svg +3 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/assets/images/codey-1.png +0 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/assets/images/codey-2.png +0 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/assets/images/codey-3.png +0 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/assets/images/vibe-codey.svg +194 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/AgentforceConversationClient.tsx +168 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/__inherit_AgentforceConversationClient.tsx +3 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/alerts/status-alert.tsx +49 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/layouts/card-layout.tsx +29 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/alert.tsx +76 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/badge.tsx +48 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/breadcrumb.tsx +109 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/button.tsx +67 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/calendar.tsx +232 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/card.tsx +103 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/checkbox.tsx +32 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/collapsible.tsx +33 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/datePicker.tsx +127 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/dialog.tsx +162 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/field.tsx +237 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/index.ts +84 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/input.tsx +19 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/label.tsx +22 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/pagination.tsx +132 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/popover.tsx +89 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/select.tsx +193 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/separator.tsx +26 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/skeleton.tsx +14 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/sonner.tsx +20 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/spinner.tsx +16 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/table.tsx +114 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/components/ui/tabs.tsx +88 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/__examples__/api/accountSearchService.ts +46 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/__examples__/api/query/distinctAccountIndustries.graphql +19 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/__examples__/api/query/distinctAccountTypes.graphql +19 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/__examples__/api/query/getAccountDetail.graphql +121 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/__examples__/api/query/searchAccounts.graphql +51 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/__examples__/pages/AccountObjectDetailPage.tsx +357 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/__examples__/pages/AccountSearch.tsx +312 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/__examples__/pages/Home.tsx +34 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/api/objectSearchService.ts +84 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/ActiveFilters.tsx +89 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/FilterContext.tsx +83 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/ObjectBreadcrumb.tsx +66 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/PaginationControls.tsx +109 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/SearchBar.tsx +41 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/SortControl.tsx +143 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/filters/BooleanFilter.tsx +78 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/filters/DateFilter.tsx +128 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/filters/DateRangeFilter.tsx +70 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/filters/FilterFieldWrapper.tsx +33 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/filters/MultiSelectFilter.tsx +97 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/filters/NumericRangeFilter.tsx +163 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/filters/SearchFilter.tsx +50 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/filters/SelectFilter.tsx +97 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/components/filters/TextFilter.tsx +91 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/hooks/useAsyncData.ts +54 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/hooks/useCachedAsyncData.ts +184 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/hooks/useDebouncedCallback.ts +34 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/hooks/useObjectSearchParams.ts +252 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/utils/debounce.ts +25 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/utils/fieldUtils.ts +29 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/utils/filterUtils.ts +395 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/features/object-search/utils/sortUtils.ts +38 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/index.ts +6 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/lib/utils.ts +6 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/navigationMenu.tsx +80 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/pages/AccountObjectDetailPage.tsx +361 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/pages/AccountSearch.tsx +305 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/pages/Home.tsx +34 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/pages/NotFound.tsx +18 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/router-utils.tsx +35 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/routes.tsx +32 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/styles/global.css +135 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/src/types/conversation.ts +33 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/tsconfig.json +42 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/tsconfig.node.json +13 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/ui-bundle.json +7 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/vite-env.d.ts +1 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/vite.config.ts +106 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/vitest-env.d.ts +2 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/vitest.config.ts +11 -0
- package/dist/force-app/main/default/uiBundles/reactinternalapp/vitest.setup.ts +1 -0
- package/dist/jest.config.js +6 -0
- package/dist/package-lock.json +9995 -0
- package/dist/package.json +40 -0
- package/dist/scripts/apex/hello.apex +10 -0
- package/dist/scripts/graphql-search.sh +191 -0
- package/dist/scripts/prepare-import-unique-fields.js +122 -0
- package/dist/scripts/setup-cli.mjs +563 -0
- package/dist/scripts/sf-project-setup.mjs +66 -0
- package/dist/scripts/soql/account.soql +6 -0
- package/dist/sfdx-project.json +12 -0
- package/package.json +40 -0
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
import { cn } from '../../lib/utils';
|
|
4
|
+
|
|
5
|
+
function Table({ className, ...props }: React.ComponentProps<'table'>) {
|
|
6
|
+
return (
|
|
7
|
+
<div
|
|
8
|
+
data-slot="table-container"
|
|
9
|
+
className="relative w-full overflow-x-auto"
|
|
10
|
+
>
|
|
11
|
+
<table
|
|
12
|
+
data-slot="table"
|
|
13
|
+
className={cn('w-full caption-bottom text-sm', className)}
|
|
14
|
+
{...props}
|
|
15
|
+
/>
|
|
16
|
+
</div>
|
|
17
|
+
);
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
function TableHeader({ className, ...props }: React.ComponentProps<'thead'>) {
|
|
21
|
+
return (
|
|
22
|
+
<thead
|
|
23
|
+
data-slot="table-header"
|
|
24
|
+
className={cn('[&_tr]:border-b', className)}
|
|
25
|
+
{...props}
|
|
26
|
+
/>
|
|
27
|
+
);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
function TableBody({ className, ...props }: React.ComponentProps<'tbody'>) {
|
|
31
|
+
return (
|
|
32
|
+
<tbody
|
|
33
|
+
data-slot="table-body"
|
|
34
|
+
className={cn('[&_tr:last-child]:border-0', className)}
|
|
35
|
+
{...props}
|
|
36
|
+
/>
|
|
37
|
+
);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
function TableFooter({ className, ...props }: React.ComponentProps<'tfoot'>) {
|
|
41
|
+
return (
|
|
42
|
+
<tfoot
|
|
43
|
+
data-slot="table-footer"
|
|
44
|
+
className={cn(
|
|
45
|
+
'bg-muted/50 border-t font-medium [&>tr]:last:border-b-0',
|
|
46
|
+
className
|
|
47
|
+
)}
|
|
48
|
+
{...props}
|
|
49
|
+
/>
|
|
50
|
+
);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
function TableRow({ className, ...props }: React.ComponentProps<'tr'>) {
|
|
54
|
+
return (
|
|
55
|
+
<tr
|
|
56
|
+
data-slot="table-row"
|
|
57
|
+
className={cn(
|
|
58
|
+
'hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors',
|
|
59
|
+
className
|
|
60
|
+
)}
|
|
61
|
+
{...props}
|
|
62
|
+
/>
|
|
63
|
+
);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
function TableHead({ className, ...props }: React.ComponentProps<'th'>) {
|
|
67
|
+
return (
|
|
68
|
+
<th
|
|
69
|
+
data-slot="table-head"
|
|
70
|
+
className={cn(
|
|
71
|
+
'text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0',
|
|
72
|
+
className
|
|
73
|
+
)}
|
|
74
|
+
{...props}
|
|
75
|
+
/>
|
|
76
|
+
);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
function TableCell({ className, ...props }: React.ComponentProps<'td'>) {
|
|
80
|
+
return (
|
|
81
|
+
<td
|
|
82
|
+
data-slot="table-cell"
|
|
83
|
+
className={cn(
|
|
84
|
+
'p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0',
|
|
85
|
+
className
|
|
86
|
+
)}
|
|
87
|
+
{...props}
|
|
88
|
+
/>
|
|
89
|
+
);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
function TableCaption({
|
|
93
|
+
className,
|
|
94
|
+
...props
|
|
95
|
+
}: React.ComponentProps<'caption'>) {
|
|
96
|
+
return (
|
|
97
|
+
<caption
|
|
98
|
+
data-slot="table-caption"
|
|
99
|
+
className={cn('text-muted-foreground mt-4 text-sm', className)}
|
|
100
|
+
{...props}
|
|
101
|
+
/>
|
|
102
|
+
);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
export {
|
|
106
|
+
Table,
|
|
107
|
+
TableHeader,
|
|
108
|
+
TableBody,
|
|
109
|
+
TableFooter,
|
|
110
|
+
TableHead,
|
|
111
|
+
TableRow,
|
|
112
|
+
TableCell,
|
|
113
|
+
TableCaption,
|
|
114
|
+
};
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { cva, type VariantProps } from 'class-variance-authority';
|
|
3
|
+
import { Tabs as TabsPrimitive } from 'radix-ui';
|
|
4
|
+
|
|
5
|
+
import { cn } from '../../lib/utils';
|
|
6
|
+
|
|
7
|
+
function Tabs({
|
|
8
|
+
className,
|
|
9
|
+
orientation = 'horizontal',
|
|
10
|
+
...props
|
|
11
|
+
}: React.ComponentProps<typeof TabsPrimitive.Root>) {
|
|
12
|
+
return (
|
|
13
|
+
<TabsPrimitive.Root
|
|
14
|
+
data-slot="tabs"
|
|
15
|
+
data-orientation={orientation}
|
|
16
|
+
className={cn(
|
|
17
|
+
'gap-2 group/tabs flex data-horizontal:flex-col',
|
|
18
|
+
className
|
|
19
|
+
)}
|
|
20
|
+
{...props}
|
|
21
|
+
/>
|
|
22
|
+
);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
const tabsListVariants = cva(
|
|
26
|
+
'rounded-lg p-[3px] group-data-horizontal/tabs:h-8 data-[variant=line]:rounded-none group/tabs-list text-muted-foreground inline-flex w-fit items-center justify-center group-data-vertical/tabs:h-fit group-data-vertical/tabs:flex-col',
|
|
27
|
+
{
|
|
28
|
+
variants: {
|
|
29
|
+
variant: {
|
|
30
|
+
default: 'bg-muted',
|
|
31
|
+
line: 'gap-1 bg-transparent',
|
|
32
|
+
},
|
|
33
|
+
},
|
|
34
|
+
defaultVariants: {
|
|
35
|
+
variant: 'default',
|
|
36
|
+
},
|
|
37
|
+
}
|
|
38
|
+
);
|
|
39
|
+
|
|
40
|
+
function TabsList({
|
|
41
|
+
className,
|
|
42
|
+
variant = 'default',
|
|
43
|
+
...props
|
|
44
|
+
}: React.ComponentProps<typeof TabsPrimitive.List> &
|
|
45
|
+
VariantProps<typeof tabsListVariants>) {
|
|
46
|
+
return (
|
|
47
|
+
<TabsPrimitive.List
|
|
48
|
+
data-slot="tabs-list"
|
|
49
|
+
data-variant={variant}
|
|
50
|
+
className={cn(tabsListVariants({ variant }), className)}
|
|
51
|
+
{...props}
|
|
52
|
+
/>
|
|
53
|
+
);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
function TabsTrigger({
|
|
57
|
+
className,
|
|
58
|
+
...props
|
|
59
|
+
}: React.ComponentProps<typeof TabsPrimitive.Trigger>) {
|
|
60
|
+
return (
|
|
61
|
+
<TabsPrimitive.Trigger
|
|
62
|
+
data-slot="tabs-trigger"
|
|
63
|
+
className={cn(
|
|
64
|
+
"gap-1.5 rounded-md border border-transparent px-1.5 py-0.5 text-sm font-medium group-data-[variant=default]/tabs-list:data-active:shadow-sm group-data-[variant=line]/tabs-list:data-active:shadow-none [&_svg:not([class*='size-'])]:size-4 focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring text-foreground/60 hover:text-foreground dark:text-muted-foreground dark:hover:text-foreground relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center whitespace-nowrap transition-all group-data-vertical/tabs:w-full group-data-vertical/tabs:justify-start focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0",
|
|
65
|
+
'group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-active:bg-transparent dark:group-data-[variant=line]/tabs-list:data-active:border-transparent dark:group-data-[variant=line]/tabs-list:data-active:bg-transparent',
|
|
66
|
+
'data-active:bg-background dark:data-active:text-foreground dark:data-active:border-input dark:data-active:bg-input/30 data-active:text-foreground',
|
|
67
|
+
'after:bg-foreground after:absolute after:opacity-0 after:transition-opacity group-data-horizontal/tabs:after:inset-x-0 group-data-horizontal/tabs:after:bottom-[-5px] group-data-horizontal/tabs:after:h-0.5 group-data-vertical/tabs:after:inset-y-0 group-data-vertical/tabs:after:-right-1 group-data-vertical/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-active:after:opacity-100',
|
|
68
|
+
className
|
|
69
|
+
)}
|
|
70
|
+
{...props}
|
|
71
|
+
/>
|
|
72
|
+
);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
function TabsContent({
|
|
76
|
+
className,
|
|
77
|
+
...props
|
|
78
|
+
}: React.ComponentProps<typeof TabsPrimitive.Content>) {
|
|
79
|
+
return (
|
|
80
|
+
<TabsPrimitive.Content
|
|
81
|
+
data-slot="tabs-content"
|
|
82
|
+
className={cn('text-sm flex-1 outline-none', className)}
|
|
83
|
+
{...props}
|
|
84
|
+
/>
|
|
85
|
+
);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
export { Tabs, TabsList, TabsTrigger, TabsContent, tabsListVariants };
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import SEARCH_ACCOUNTS_QUERY from "./query/searchAccounts.graphql?raw";
|
|
2
|
+
import DISTINCT_INDUSTRIES_QUERY from "./query/distinctAccountIndustries.graphql?raw";
|
|
3
|
+
import DISTINCT_TYPES_QUERY from "./query/distinctAccountTypes.graphql?raw";
|
|
4
|
+
import {
|
|
5
|
+
searchObjects,
|
|
6
|
+
fetchDistinctValues,
|
|
7
|
+
type ObjectSearchOptions,
|
|
8
|
+
type PicklistOption,
|
|
9
|
+
} from "../../api/objectSearchService";
|
|
10
|
+
import type {
|
|
11
|
+
SearchAccountsQuery,
|
|
12
|
+
SearchAccountsQueryVariables,
|
|
13
|
+
DistinctAccountIndustriesQuery,
|
|
14
|
+
DistinctAccountTypesQuery,
|
|
15
|
+
} from "../../../../api/graphql-operations-types";
|
|
16
|
+
|
|
17
|
+
export type AccountSearchResult = NonNullable<SearchAccountsQuery["uiapi"]["query"]["Account"]>;
|
|
18
|
+
|
|
19
|
+
export type AccountSearchOptions = ObjectSearchOptions<
|
|
20
|
+
SearchAccountsQueryVariables["where"],
|
|
21
|
+
SearchAccountsQueryVariables["orderBy"]
|
|
22
|
+
>;
|
|
23
|
+
|
|
24
|
+
export type { PicklistOption };
|
|
25
|
+
|
|
26
|
+
export async function searchAccounts(
|
|
27
|
+
options: AccountSearchOptions = {},
|
|
28
|
+
): Promise<AccountSearchResult> {
|
|
29
|
+
return searchObjects<AccountSearchResult, SearchAccountsQuery, SearchAccountsQueryVariables>(
|
|
30
|
+
SEARCH_ACCOUNTS_QUERY,
|
|
31
|
+
"Account",
|
|
32
|
+
options,
|
|
33
|
+
);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export async function fetchDistinctIndustries(): Promise<PicklistOption[]> {
|
|
37
|
+
return fetchDistinctValues<DistinctAccountIndustriesQuery>(
|
|
38
|
+
DISTINCT_INDUSTRIES_QUERY,
|
|
39
|
+
"Account",
|
|
40
|
+
"Industry",
|
|
41
|
+
);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export async function fetchDistinctTypes(): Promise<PicklistOption[]> {
|
|
45
|
+
return fetchDistinctValues<DistinctAccountTypesQuery>(DISTINCT_TYPES_QUERY, "Account", "Type");
|
|
46
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
query DistinctAccountIndustries {
|
|
2
|
+
uiapi {
|
|
3
|
+
aggregate {
|
|
4
|
+
Account(groupBy: { Industry: { group: true } }) {
|
|
5
|
+
edges {
|
|
6
|
+
node {
|
|
7
|
+
aggregate @optional {
|
|
8
|
+
Industry @optional {
|
|
9
|
+
value
|
|
10
|
+
displayValue
|
|
11
|
+
label
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
query GetAccountDetail($id: ID!) {
|
|
2
|
+
uiapi {
|
|
3
|
+
query {
|
|
4
|
+
Account(where: { Id: { eq: $id } }) {
|
|
5
|
+
edges {
|
|
6
|
+
node {
|
|
7
|
+
Id
|
|
8
|
+
Name @optional {
|
|
9
|
+
value
|
|
10
|
+
displayValue
|
|
11
|
+
}
|
|
12
|
+
Owner @optional {
|
|
13
|
+
Name @optional {
|
|
14
|
+
value
|
|
15
|
+
displayValue
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
Phone @optional {
|
|
19
|
+
value
|
|
20
|
+
displayValue
|
|
21
|
+
}
|
|
22
|
+
Fax @optional {
|
|
23
|
+
value
|
|
24
|
+
displayValue
|
|
25
|
+
}
|
|
26
|
+
Parent @optional {
|
|
27
|
+
Name @optional {
|
|
28
|
+
value
|
|
29
|
+
displayValue
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
Website @optional {
|
|
33
|
+
value
|
|
34
|
+
displayValue
|
|
35
|
+
}
|
|
36
|
+
Type @optional {
|
|
37
|
+
value
|
|
38
|
+
displayValue
|
|
39
|
+
}
|
|
40
|
+
NumberOfEmployees @optional {
|
|
41
|
+
value
|
|
42
|
+
displayValue
|
|
43
|
+
}
|
|
44
|
+
Industry @optional {
|
|
45
|
+
value
|
|
46
|
+
displayValue
|
|
47
|
+
}
|
|
48
|
+
AnnualRevenue @optional {
|
|
49
|
+
value
|
|
50
|
+
displayValue
|
|
51
|
+
}
|
|
52
|
+
Description @optional {
|
|
53
|
+
value
|
|
54
|
+
displayValue
|
|
55
|
+
}
|
|
56
|
+
BillingStreet @optional {
|
|
57
|
+
value
|
|
58
|
+
displayValue
|
|
59
|
+
}
|
|
60
|
+
BillingCity @optional {
|
|
61
|
+
value
|
|
62
|
+
displayValue
|
|
63
|
+
}
|
|
64
|
+
BillingState @optional {
|
|
65
|
+
value
|
|
66
|
+
displayValue
|
|
67
|
+
}
|
|
68
|
+
BillingPostalCode @optional {
|
|
69
|
+
value
|
|
70
|
+
displayValue
|
|
71
|
+
}
|
|
72
|
+
BillingCountry @optional {
|
|
73
|
+
value
|
|
74
|
+
displayValue
|
|
75
|
+
}
|
|
76
|
+
ShippingStreet @optional {
|
|
77
|
+
value
|
|
78
|
+
displayValue
|
|
79
|
+
}
|
|
80
|
+
ShippingCity @optional {
|
|
81
|
+
value
|
|
82
|
+
displayValue
|
|
83
|
+
}
|
|
84
|
+
ShippingState @optional {
|
|
85
|
+
value
|
|
86
|
+
displayValue
|
|
87
|
+
}
|
|
88
|
+
ShippingPostalCode @optional {
|
|
89
|
+
value
|
|
90
|
+
displayValue
|
|
91
|
+
}
|
|
92
|
+
ShippingCountry @optional {
|
|
93
|
+
value
|
|
94
|
+
displayValue
|
|
95
|
+
}
|
|
96
|
+
CreatedBy @optional {
|
|
97
|
+
Name @optional {
|
|
98
|
+
value
|
|
99
|
+
displayValue
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
CreatedDate @optional {
|
|
103
|
+
value
|
|
104
|
+
displayValue
|
|
105
|
+
}
|
|
106
|
+
LastModifiedBy @optional {
|
|
107
|
+
Name @optional {
|
|
108
|
+
value
|
|
109
|
+
displayValue
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
LastModifiedDate @optional {
|
|
113
|
+
value
|
|
114
|
+
displayValue
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
query SearchAccounts(
|
|
2
|
+
$first: Int
|
|
3
|
+
$after: String
|
|
4
|
+
$where: Account_Filter
|
|
5
|
+
$orderBy: Account_OrderBy
|
|
6
|
+
) {
|
|
7
|
+
uiapi {
|
|
8
|
+
query {
|
|
9
|
+
Account(first: $first, after: $after, where: $where, orderBy: $orderBy) {
|
|
10
|
+
edges {
|
|
11
|
+
node {
|
|
12
|
+
Id
|
|
13
|
+
Name @optional {
|
|
14
|
+
value
|
|
15
|
+
displayValue
|
|
16
|
+
}
|
|
17
|
+
Industry @optional {
|
|
18
|
+
value
|
|
19
|
+
displayValue
|
|
20
|
+
}
|
|
21
|
+
Type @optional {
|
|
22
|
+
value
|
|
23
|
+
displayValue
|
|
24
|
+
}
|
|
25
|
+
Phone @optional {
|
|
26
|
+
value
|
|
27
|
+
displayValue
|
|
28
|
+
}
|
|
29
|
+
Owner @optional {
|
|
30
|
+
Name @optional {
|
|
31
|
+
value
|
|
32
|
+
displayValue
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
AnnualRevenue @optional {
|
|
36
|
+
value
|
|
37
|
+
displayValue
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
pageInfo {
|
|
42
|
+
hasNextPage
|
|
43
|
+
hasPreviousPage
|
|
44
|
+
endCursor
|
|
45
|
+
startCursor
|
|
46
|
+
}
|
|
47
|
+
totalCount
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}
|