@salesforce/webapp-template-app-react-sample-b2e-experimental 1.70.0 → 1.71.1

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/README.md ADDED
@@ -0,0 +1,52 @@
1
+ # appreactsampleb2e
2
+
3
+ B2E (Business-to-Employee) sample app — property management, maintenance requests, and Agentforce conversation client.
4
+
5
+ ## In this monorepo
6
+
7
+ This package is a **template app** in the webapps monorepo. It is built by applying feature patches to the base React app; the output is written to `dist/`.
8
+
9
+ ### Build
10
+
11
+ ```bash
12
+ nx run appreactsampleb2e:build
13
+ ```
14
+
15
+ Produces an SFDX project in `dist/` with the web app at `dist/force-app/main/default/webapplications/appreactsampleb2e/`.
16
+
17
+ ### Dev server
18
+
19
+ ```bash
20
+ nx run appreactsampleb2e:dev
21
+ ```
22
+
23
+ Starts the Vite dev server from the built output in `dist/`.
24
+
25
+ ### Watch
26
+
27
+ ```bash
28
+ nx run appreactsampleb2e:watch
29
+ ```
30
+
31
+ Re-applies patches automatically when source files change.
32
+
33
+ ### Test
34
+
35
+ This package has no dedicated test target. To run tests, build first, then run them from the built web app:
36
+
37
+ ```bash
38
+ nx run appreactsampleb2e:build
39
+ cd dist/force-app/main/default/webapplications/appreactsampleb2e && npm install && npm test
40
+ ```
41
+
42
+ ### Clean
43
+
44
+ ```bash
45
+ npm run clean
46
+ ```
47
+
48
+ Removes the `dist/` directory.
49
+
50
+ ---
51
+
52
+ For standalone run, deploy, and test instructions (e.g. after publishing or extracting `dist/`), see the [web app README](dist/force-app/main/default/webapplications/appreactsampleb2e/README.md).
package/dist/CHANGELOG.md CHANGED
@@ -3,6 +3,22 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [1.71.1](https://github.com/salesforce-experience-platform-emu/webapps/compare/v1.71.0...v1.71.1) (2026-03-05)
7
+
8
+ **Note:** Version bump only for package @salesforce/webapp-template-base-sfdx-project-experimental
9
+
10
+
11
+
12
+
13
+
14
+ # [1.71.0](https://github.com/salesforce-experience-platform-emu/webapps/compare/v1.70.0...v1.71.0) (2026-03-05)
15
+
16
+ **Note:** Version bump only for package @salesforce/webapp-template-base-sfdx-project-experimental
17
+
18
+
19
+
20
+
21
+
6
22
  # [1.70.0](https://github.com/salesforce-experience-platform-emu/webapps/compare/v1.69.0...v1.70.0) (2026-03-04)
7
23
 
8
24
  **Note:** Version bump only for package @salesforce/webapp-template-base-sfdx-project-experimental
@@ -0,0 +1,70 @@
1
+ # App React Sample B2E
2
+
3
+ A B2E (Business-to-Employee) sample React web app for the Salesforce platform. Demonstrates property management, maintenance requests, tenant applications, a dashboard, and an Agentforce conversation client. Built with React, Vite, TypeScript, and Tailwind/shadcn.
4
+
5
+ ## What's included
6
+
7
+ | Path | Description |
8
+ | ----------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
9
+ | `force-app/main/default/webapplications/appreactsampleb2e/` | React web app (source, config, tests) |
10
+ | `force-app/main/default/objects/` | 17 custom objects — Agent\_\_c, Application\_\_c, KPI_Snapshot\_\_c, Lease\_\_c, Maintenance_Request\_\_c, Maintenance_Worker\_\_c, Notification\_\_c, Payment\_\_c, Property\_\_c, Property_Cost\_\_c, Property_Feature\_\_c, Property_Image\_\_c, Property_Listing\_\_c, Property_Management_Company\_\_c, Property_Owner\_\_c, Property_Sale\_\_c, Tenant\_\_c |
11
+ | `force-app/main/default/layouts/` | Page layouts for each custom object |
12
+ | `force-app/main/default/permissionsets/` | `Property_Management_Access` permission set |
13
+ | `force-app/main/default/data/` | Sample data (JSON) for all objects, importable via `sf data import tree` |
14
+
15
+ ## Getting started
16
+
17
+ Navigate to the web app and install dependencies:
18
+
19
+ ```bash
20
+ cd force-app/main/default/webapplications/appreactsampleb2e
21
+ npm install
22
+ npm run dev
23
+ ```
24
+
25
+ Opens at http://localhost:5173 by default. For build and test instructions, see the [web app README](force-app/main/default/webapplications/appreactsampleb2e/README.md).
26
+
27
+ ## Deploy
28
+
29
+ ### Deploy everything (metadata + web app)
30
+
31
+ ```bash
32
+ cd force-app/main/default/webapplications/appreactsampleb2e && npm install && npm run build && cd -
33
+ sf project deploy start --source-dir force-app --target-org <alias>
34
+ ```
35
+
36
+ ### Deploy the web app only
37
+
38
+ ```bash
39
+ cd force-app/main/default/webapplications/appreactsampleb2e && npm install && npm run build && cd -
40
+ sf project deploy start --source-dir force-app/main/default/webapplications --target-org <alias>
41
+ ```
42
+
43
+ ### Deploy metadata only (objects, layouts, permission sets)
44
+
45
+ ```bash
46
+ sf project deploy start \
47
+ --source-dir force-app/main/default/objects \
48
+ --source-dir force-app/main/default/layouts \
49
+ --source-dir force-app/main/default/permissionsets \
50
+ --target-org <alias>
51
+ ```
52
+
53
+ Replace `<alias>` with your target org alias.
54
+
55
+ ## Import sample data
56
+
57
+ ```bash
58
+ sf data import tree --plan force-app/main/default/data/data-plan.json --target-org <alias>
59
+ ```
60
+
61
+ ## Configure Your Salesforce DX Project
62
+
63
+ The `sfdx-project.json` file contains useful configuration information for your project. See [Salesforce DX Project Configuration](https://developer.salesforce.com/docs/atlas.en-us.sfdx_dev.meta/sfdx_dev/sfdx_dev_ws_config.htm) in the _Salesforce DX Developer Guide_ for details about this file.
64
+
65
+ ## Read All About It
66
+
67
+ - [Salesforce Extensions Documentation](https://developer.salesforce.com/tools/vscode/)
68
+ - [Salesforce CLI Setup Guide](https://developer.salesforce.com/docs/atlas.en-us.sfdx_setup.meta/sfdx_setup/sfdx_setup_intro.htm)
69
+ - [Salesforce DX Developer Guide](https://developer.salesforce.com/docs/atlas.en-us.sfdx_dev.meta/sfdx_dev/sfdx_dev_intro.htm)
70
+ - [Salesforce CLI Command Reference](https://developer.salesforce.com/docs/atlas.en-us.sfdx_cli_reference.meta/sfdx_cli_reference/cli_reference.htm)
@@ -0,0 +1,35 @@
1
+ # App React Sample B2E
2
+
3
+ A sample B2E (Business-to-Employee) React web app on the Salesforce platform. Includes property management, maintenance requests, tenant applications, a dashboard, and an Agentforce conversation client. Built with React, Vite, TypeScript, and Tailwind/shadcn.
4
+
5
+ For project-level details (metadata, deploy, sample data), see the [project README](../../../../../../README.md).
6
+
7
+ ## Prerequisites
8
+
9
+ ```bash
10
+ npm install
11
+ ```
12
+
13
+ ## Run (development)
14
+
15
+ ```bash
16
+ npm run dev
17
+ ```
18
+
19
+ Starts the Vite dev server (default: http://localhost:5173).
20
+
21
+ ## Build
22
+
23
+ ```bash
24
+ npm run build
25
+ ```
26
+
27
+ Writes the production bundle to `dist/` inside the web app folder.
28
+
29
+ ## Test
30
+
31
+ ```bash
32
+ npm test
33
+ ```
34
+
35
+ Runs the unit test suite (Vitest).
@@ -15,9 +15,9 @@
15
15
  "graphql:schema": "node scripts/get-graphql-schema.mjs"
16
16
  },
17
17
  "dependencies": {
18
- "@salesforce/agentforce-conversation-client": "^1.70.0",
19
- "@salesforce/sdk-data": "^1.70.0",
20
- "@salesforce/webapp-experimental": "^1.70.0",
18
+ "@salesforce/agentforce-conversation-client": "^1.71.1",
19
+ "@salesforce/sdk-data": "^1.71.1",
20
+ "@salesforce/webapp-experimental": "^1.71.1",
21
21
  "@tailwindcss/vite": "^4.1.17",
22
22
  "class-variance-authority": "^0.7.1",
23
23
  "clsx": "^2.1.1",
@@ -40,7 +40,7 @@
40
40
  "@graphql-eslint/eslint-plugin": "^4.1.0",
41
41
  "@graphql-tools/utils": "^11.0.0",
42
42
  "@playwright/test": "^1.49.0",
43
- "@salesforce/vite-plugin-webapp-experimental": "^1.70.0",
43
+ "@salesforce/vite-plugin-webapp-experimental": "^1.71.1",
44
44
  "@testing-library/jest-dom": "^6.6.3",
45
45
  "@testing-library/react": "^16.1.0",
46
46
  "@testing-library/user-event": "^14.5.2",
@@ -0,0 +1,49 @@
1
+ import { cva, type VariantProps } from 'class-variance-authority';
2
+ import { AlertCircleIcon, CheckCircle2Icon } from 'lucide-react';
3
+ import { Alert, AlertDescription } from '../../components/ui/alert';
4
+ import { useId } from 'react';
5
+
6
+ const statusAlertVariants = cva('', {
7
+ variants: {
8
+ variant: {
9
+ error: '',
10
+ success: '',
11
+ },
12
+ },
13
+ defaultVariants: {
14
+ variant: 'error',
15
+ },
16
+ });
17
+
18
+ interface StatusAlertProps extends VariantProps<typeof statusAlertVariants> {
19
+ children?: React.ReactNode;
20
+ /** Alert variant type. @default "error" */
21
+ variant?: 'error' | 'success';
22
+ }
23
+
24
+ /**
25
+ * Status alert component for displaying error or success messages.
26
+ * Returns null if no children are provided.
27
+ */
28
+ export function StatusAlert({ children, variant = 'error' }: StatusAlertProps) {
29
+ if (!children) return null;
30
+
31
+ const isError = variant === 'error';
32
+ const descriptionId = useId();
33
+
34
+ return (
35
+ <Alert
36
+ variant={isError ? 'destructive' : 'default'}
37
+ className={statusAlertVariants({ variant })}
38
+ aria-describedby={descriptionId}
39
+ role={isError ? 'alert' : 'status'}
40
+ >
41
+ {isError ? (
42
+ <AlertCircleIcon aria-hidden="true" />
43
+ ) : (
44
+ <CheckCircle2Icon aria-hidden="true" />
45
+ )}
46
+ <AlertDescription id={descriptionId}>{children}</AlertDescription>
47
+ </Alert>
48
+ );
49
+ }
@@ -0,0 +1,29 @@
1
+ import {
2
+ Card,
3
+ CardContent,
4
+ CardDescription,
5
+ CardHeader,
6
+ CardTitle,
7
+ } from '../../components/ui/card';
8
+
9
+ interface CardLayoutProps {
10
+ title: string;
11
+ description?: string;
12
+ children: React.ReactNode;
13
+ }
14
+
15
+ /**
16
+ * Card layout component for authentication pages.
17
+ * Provides CardHeader with title and optional description, and CardContent.
18
+ */
19
+ export function CardLayout({ title, description, children }: CardLayoutProps) {
20
+ return (
21
+ <Card>
22
+ <CardHeader>
23
+ <CardTitle className="text-2xl">{title}</CardTitle>
24
+ {description && <CardDescription>{description}</CardDescription>}
25
+ </CardHeader>
26
+ <CardContent>{children}</CardContent>
27
+ </Card>
28
+ );
29
+ }
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforce/webapp-template-base-sfdx-project-experimental",
3
- "version": "1.70.0",
3
+ "version": "1.71.1",
4
4
  "description": "Base SFDX project template",
5
5
  "private": true,
6
6
  "files": [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforce/webapp-template-app-react-sample-b2e-experimental",
3
- "version": "1.70.0",
3
+ "version": "1.71.1",
4
4
  "description": "B2E starter app template",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "author": "",