@salesforce/plugin-templates 56.17.7 → 56.18.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.
- package/README.md +15 -15
- package/lib/commands/template/generate/lightning/embedding.d.ts +20 -0
- package/lib/commands/template/generate/lightning/embedding.js +75 -0
- package/lib/commands/template/generate/lightning/embedding.js.map +1 -0
- package/messages/lightningEmbedding.md +55 -0
- package/oclif.manifest.json +626 -458
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -177,7 +177,7 @@ FLAG DESCRIPTIONS
|
|
|
177
177
|
directory.
|
|
178
178
|
```
|
|
179
179
|
|
|
180
|
-
_See code: [src/commands/template/generate/analytics/template.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
180
|
+
_See code: [src/commands/template/generate/analytics/template.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/analytics/template.ts)_
|
|
181
181
|
|
|
182
182
|
## `sf template generate apex class`
|
|
183
183
|
|
|
@@ -237,7 +237,7 @@ FLAG DESCRIPTIONS
|
|
|
237
237
|
Supplied parameter values or default values are filled into a copy of the template.
|
|
238
238
|
```
|
|
239
239
|
|
|
240
|
-
_See code: [src/commands/template/generate/apex/class.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
240
|
+
_See code: [src/commands/template/generate/apex/class.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/apex/class.ts)_
|
|
241
241
|
|
|
242
242
|
## `sf template generate apex trigger`
|
|
243
243
|
|
|
@@ -307,7 +307,7 @@ FLAG DESCRIPTIONS
|
|
|
307
307
|
Supplied parameter values or default values are filled into a copy of the template.
|
|
308
308
|
```
|
|
309
309
|
|
|
310
|
-
_See code: [src/commands/template/generate/apex/trigger.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
310
|
+
_See code: [src/commands/template/generate/apex/trigger.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/apex/trigger.ts)_
|
|
311
311
|
|
|
312
312
|
## `sf template generate digital-experience site`
|
|
313
313
|
|
|
@@ -361,7 +361,7 @@ FLAG DESCRIPTIONS
|
|
|
361
361
|
project, defaults to the current directory.
|
|
362
362
|
```
|
|
363
363
|
|
|
364
|
-
_See code: [src/commands/template/generate/digital-experience/site.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
364
|
+
_See code: [src/commands/template/generate/digital-experience/site.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/digital-experience/site.ts)_
|
|
365
365
|
|
|
366
366
|
## `sf template generate flexipage`
|
|
367
367
|
|
|
@@ -443,7 +443,7 @@ FLAG DESCRIPTIONS
|
|
|
443
443
|
'Custom_Object__c'. This sets the `sobjectType` field in the FlexiPage metadata.
|
|
444
444
|
```
|
|
445
445
|
|
|
446
|
-
_See code: [src/commands/template/generate/flexipage/index.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
446
|
+
_See code: [src/commands/template/generate/flexipage/index.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/flexipage/index.ts)_
|
|
447
447
|
|
|
448
448
|
## `sf template generate lightning app`
|
|
449
449
|
|
|
@@ -501,7 +501,7 @@ FLAG DESCRIPTIONS
|
|
|
501
501
|
field in the DX project's "sfdx-project.json" file.
|
|
502
502
|
```
|
|
503
503
|
|
|
504
|
-
_See code: [src/commands/template/generate/lightning/app.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
504
|
+
_See code: [src/commands/template/generate/lightning/app.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/lightning/app.ts)_
|
|
505
505
|
|
|
506
506
|
## `sf template generate lightning component`
|
|
507
507
|
|
|
@@ -578,7 +578,7 @@ FLAG DESCRIPTIONS
|
|
|
578
578
|
field in the DX project's "sfdx-project.json" file.
|
|
579
579
|
```
|
|
580
580
|
|
|
581
|
-
_See code: [src/commands/template/generate/lightning/component.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
581
|
+
_See code: [src/commands/template/generate/lightning/component.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/lightning/component.ts)_
|
|
582
582
|
|
|
583
583
|
## `sf template generate lightning event`
|
|
584
584
|
|
|
@@ -636,7 +636,7 @@ FLAG DESCRIPTIONS
|
|
|
636
636
|
field in the DX project's "sfdx-project.json" file.
|
|
637
637
|
```
|
|
638
638
|
|
|
639
|
-
_See code: [src/commands/template/generate/lightning/event.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
639
|
+
_See code: [src/commands/template/generate/lightning/event.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/lightning/event.ts)_
|
|
640
640
|
|
|
641
641
|
## `sf template generate lightning interface`
|
|
642
642
|
|
|
@@ -694,7 +694,7 @@ FLAG DESCRIPTIONS
|
|
|
694
694
|
field in the DX project's "sfdx-project.json" file.
|
|
695
695
|
```
|
|
696
696
|
|
|
697
|
-
_See code: [src/commands/template/generate/lightning/interface.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
697
|
+
_See code: [src/commands/template/generate/lightning/interface.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/lightning/interface.ts)_
|
|
698
698
|
|
|
699
699
|
## `sf template generate lightning test`
|
|
700
700
|
|
|
@@ -752,7 +752,7 @@ FLAG DESCRIPTIONS
|
|
|
752
752
|
field in the DX project's "sfdx-project.json" file.
|
|
753
753
|
```
|
|
754
754
|
|
|
755
|
-
_See code: [src/commands/template/generate/lightning/test.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
755
|
+
_See code: [src/commands/template/generate/lightning/test.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/lightning/test.ts)_
|
|
756
756
|
|
|
757
757
|
## `sf template generate project`
|
|
758
758
|
|
|
@@ -878,7 +878,7 @@ FLAG DESCRIPTIONS
|
|
|
878
878
|
server-side type stripping.
|
|
879
879
|
```
|
|
880
880
|
|
|
881
|
-
_See code: [src/commands/template/generate/project/index.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
881
|
+
_See code: [src/commands/template/generate/project/index.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/project/index.ts)_
|
|
882
882
|
|
|
883
883
|
## `sf template generate static-resource`
|
|
884
884
|
|
|
@@ -941,7 +941,7 @@ FLAG DESCRIPTIONS
|
|
|
941
941
|
etc.
|
|
942
942
|
```
|
|
943
943
|
|
|
944
|
-
_See code: [src/commands/template/generate/static-resource/index.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
944
|
+
_See code: [src/commands/template/generate/static-resource/index.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/static-resource/index.ts)_
|
|
945
945
|
|
|
946
946
|
## `sf template generate ui-bundle`
|
|
947
947
|
|
|
@@ -1025,7 +1025,7 @@ FLAG DESCRIPTIONS
|
|
|
1025
1025
|
Supplied parameter values or default values are filled into a copy of the template.
|
|
1026
1026
|
```
|
|
1027
1027
|
|
|
1028
|
-
_See code: [src/commands/template/generate/ui-bundle/index.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
1028
|
+
_See code: [src/commands/template/generate/ui-bundle/index.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/ui-bundle/index.ts)_
|
|
1029
1029
|
|
|
1030
1030
|
## `sf template generate visualforce component`
|
|
1031
1031
|
|
|
@@ -1082,7 +1082,7 @@ FLAG DESCRIPTIONS
|
|
|
1082
1082
|
Supplied parameter values or default values are filled into a copy of the template.
|
|
1083
1083
|
```
|
|
1084
1084
|
|
|
1085
|
-
_See code: [src/commands/template/generate/visualforce/component.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
1085
|
+
_See code: [src/commands/template/generate/visualforce/component.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/visualforce/component.ts)_
|
|
1086
1086
|
|
|
1087
1087
|
## `sf template generate visualforce page`
|
|
1088
1088
|
|
|
@@ -1133,6 +1133,6 @@ FLAG DESCRIPTIONS
|
|
|
1133
1133
|
The name can be up to 40 characters and must start with a letter.
|
|
1134
1134
|
```
|
|
1135
1135
|
|
|
1136
|
-
_See code: [src/commands/template/generate/visualforce/page.ts](https://github.com/salesforcecli/plugin-templates/blob/56.
|
|
1136
|
+
_See code: [src/commands/template/generate/visualforce/page.ts](https://github.com/salesforcecli/plugin-templates/blob/56.18.0/src/commands/template/generate/visualforce/page.ts)_
|
|
1137
1137
|
|
|
1138
1138
|
<!-- commandsstop -->
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { SfCommand } from '@salesforce/sf-plugins-core';
|
|
2
|
+
import { CreateOutput } from '@salesforce/templates';
|
|
3
|
+
export default class LightningEmbedding extends SfCommand<CreateOutput> {
|
|
4
|
+
static readonly summary: string;
|
|
5
|
+
static readonly description: string;
|
|
6
|
+
static readonly examples: string[];
|
|
7
|
+
static readonly state = "beta";
|
|
8
|
+
static readonly hidden = true;
|
|
9
|
+
static readonly flags: {
|
|
10
|
+
name: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
11
|
+
src: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
12
|
+
sandbox: import("@oclif/core/interfaces").OptionFlag<("allow-forms" | "allow-modals" | "allow-orientation-lock" | "allow-pointer-lock" | "allow-popups" | "allow-popups-to-escape-sandbox" | "allow-presentation" | "allow-same-origin" | "allow-scripts" | "allow-storage-access-by-user-activation" | "allow-top-navigation" | "allow-top-navigation-by-user-activation")[], import("@oclif/core/interfaces").CustomOptions>;
|
|
13
|
+
'shell-title': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
14
|
+
'output-dir': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
15
|
+
'api-version': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
16
|
+
internal: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
17
|
+
loglevel: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
18
|
+
};
|
|
19
|
+
run(): Promise<CreateOutput>;
|
|
20
|
+
}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2026, salesforce.com, inc.
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
* Licensed under the BSD 3-Clause license.
|
|
5
|
+
* For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
|
|
6
|
+
*/
|
|
7
|
+
import { Flags, loglevel, orgApiVersionFlagWithDeprecations, SfCommand, Ux } from '@salesforce/sf-plugins-core';
|
|
8
|
+
import { isAllowedLightningEmbeddingSrcUrl, LIGHTNING_EMBEDDING_SANDBOX_TOKENS, TemplateType, } from '@salesforce/templates';
|
|
9
|
+
import { Messages } from '@salesforce/core';
|
|
10
|
+
import { getCustomTemplates, runGenerator } from '../../../../utils/templateCommand.js';
|
|
11
|
+
import { internalFlag, outputDirFlagLightning } from '../../../../utils/flags.js';
|
|
12
|
+
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
|
|
13
|
+
const messages = Messages.loadMessages('@salesforce/plugin-templates', 'lightningEmbedding');
|
|
14
|
+
export default class LightningEmbedding extends SfCommand {
|
|
15
|
+
static summary = messages.getMessage('summary');
|
|
16
|
+
static description = messages.getMessage('description');
|
|
17
|
+
static examples = messages.getMessages('examples');
|
|
18
|
+
static state = 'beta';
|
|
19
|
+
static hidden = true;
|
|
20
|
+
static flags = {
|
|
21
|
+
name: Flags.string({
|
|
22
|
+
char: 'n',
|
|
23
|
+
summary: messages.getMessage('flags.name.summary'),
|
|
24
|
+
description: messages.getMessage('flags.name.description'),
|
|
25
|
+
required: true,
|
|
26
|
+
}),
|
|
27
|
+
src: Flags.string({
|
|
28
|
+
char: 's',
|
|
29
|
+
summary: messages.getMessage('flags.src.summary'),
|
|
30
|
+
description: messages.getMessage('flags.src.description'),
|
|
31
|
+
required: true,
|
|
32
|
+
parse: (input) => {
|
|
33
|
+
if (!isAllowedLightningEmbeddingSrcUrl(input)) {
|
|
34
|
+
throw new Error(messages.getMessage('flags.src.error'));
|
|
35
|
+
}
|
|
36
|
+
return Promise.resolve(input);
|
|
37
|
+
},
|
|
38
|
+
}),
|
|
39
|
+
sandbox: Flags.option({
|
|
40
|
+
summary: messages.getMessage('flags.sandbox.summary'),
|
|
41
|
+
description: messages.getMessage('flags.sandbox.description'),
|
|
42
|
+
options: LIGHTNING_EMBEDDING_SANDBOX_TOKENS,
|
|
43
|
+
multiple: true,
|
|
44
|
+
required: true,
|
|
45
|
+
})(),
|
|
46
|
+
'shell-title': Flags.string({
|
|
47
|
+
summary: messages.getMessage('flags.shell-title.summary'),
|
|
48
|
+
description: messages.getMessage('flags.shell-title.description'),
|
|
49
|
+
required: true,
|
|
50
|
+
}),
|
|
51
|
+
'output-dir': outputDirFlagLightning,
|
|
52
|
+
'api-version': orgApiVersionFlagWithDeprecations,
|
|
53
|
+
internal: internalFlag,
|
|
54
|
+
loglevel,
|
|
55
|
+
};
|
|
56
|
+
async run() {
|
|
57
|
+
const { flags } = await this.parse(LightningEmbedding);
|
|
58
|
+
const flagsAsOptions = {
|
|
59
|
+
componentname: flags.name,
|
|
60
|
+
src: flags.src,
|
|
61
|
+
sandbox: flags.sandbox.join(' '),
|
|
62
|
+
shellTitle: flags['shell-title'],
|
|
63
|
+
outputdir: flags['output-dir'],
|
|
64
|
+
apiversion: flags['api-version'],
|
|
65
|
+
internal: flags.internal,
|
|
66
|
+
};
|
|
67
|
+
return runGenerator({
|
|
68
|
+
templateType: TemplateType.LightningEmbedding,
|
|
69
|
+
opts: flagsAsOptions,
|
|
70
|
+
ux: new Ux({ jsonEnabled: this.jsonEnabled() }),
|
|
71
|
+
templates: getCustomTemplates(this.configAggregator),
|
|
72
|
+
});
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
//# sourceMappingURL=embedding.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"embedding.js","sourceRoot":"","sources":["../../../../../src/commands/template/generate/lightning/embedding.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
# examples
|
|
2
|
+
|
|
3
|
+
- Generate an embedding wrapper LWC in the current directory:
|
|
4
|
+
|
|
5
|
+
<%= config.bin %> <%= command.id %> --name MyEmbeddingWrapper --src https://app.example.com --sandbox allow-forms --shell-title "Expense Report Widget"
|
|
6
|
+
|
|
7
|
+
- Generate an embedding wrapper LWC in the "force-app/main/default/lwc" directory with multiple sandbox tokens:
|
|
8
|
+
|
|
9
|
+
<%= config.bin %> <%= command.id %> --name MyEmbeddingWrapper --src https://app.example.com --sandbox allow-forms --sandbox allow-scripts --shell-title "Expense Report Widget" --output-dir force-app/main/default/lwc
|
|
10
|
+
|
|
11
|
+
# summary
|
|
12
|
+
|
|
13
|
+
Generate a Lightning Web Component (LWC) bundle that wraps the lightning-embedding base component.
|
|
14
|
+
|
|
15
|
+
# description
|
|
16
|
+
|
|
17
|
+
The generated LWC bundle consumes the first-party <lightning-embedding> component, which is pre-wired with the three required attributes: the widget URL (src), iframe sandbox tokens, and an accessible iframe title (shell-title).
|
|
18
|
+
|
|
19
|
+
The generated LWC bundle contains four files (.html, .js, .js-meta.xml, .css) in a directory named with the camelCased component name. The bundle must live under a parent folder named "lwc".
|
|
20
|
+
|
|
21
|
+
# flags.name.summary
|
|
22
|
+
|
|
23
|
+
Name of the generated component; must be in PascalCase format.
|
|
24
|
+
|
|
25
|
+
# flags.name.description
|
|
26
|
+
|
|
27
|
+
The component name is also used (camelCased) as the LWC folder name and file stem. Must contain only alphanumeric characters and start with a letter.
|
|
28
|
+
|
|
29
|
+
# flags.src.summary
|
|
30
|
+
|
|
31
|
+
Absolute HTTPS URL that the iframe will load.
|
|
32
|
+
|
|
33
|
+
# flags.src.description
|
|
34
|
+
|
|
35
|
+
The URL is bound to the <lightning-embedding> "src" attribute as a reactive property in the generated LWC. Must use HTTPS; plain HTTP is allowed only for localhost or 127.0.0.1 (for local development).
|
|
36
|
+
|
|
37
|
+
# flags.src.error
|
|
38
|
+
|
|
39
|
+
The --src flag must be an absolute HTTPS URL, such as https://app.example.com. Plain HTTP is allowed only for localhost or 127.0.0.1.
|
|
40
|
+
|
|
41
|
+
# flags.sandbox.summary
|
|
42
|
+
|
|
43
|
+
Iframe sandbox token. Specify this flag multiple times to set more than one token.
|
|
44
|
+
|
|
45
|
+
# flags.sandbox.description
|
|
46
|
+
|
|
47
|
+
Each token is written into the space-separated "sandbox" attribute on <lightning-embedding>. Only W3C-defined sandbox tokens are accepted.
|
|
48
|
+
|
|
49
|
+
# flags.shell-title.summary
|
|
50
|
+
|
|
51
|
+
Accessible title for the embedded iframe.
|
|
52
|
+
|
|
53
|
+
# flags.shell-title.description
|
|
54
|
+
|
|
55
|
+
Written to the "shell-title" attribute on <lightning-embedding> and used as the iframe's accessible name (announced by screen readers).
|