Skip to content

Commit a1aec6e

Browse files
authored
Merge pull request #1544 from AhmadiRamin/react-command-document-translation
2 parents 1986bbb + c0e9f67 commit a1aec6e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+39517
-0
lines changed
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
yarn-debug.log*
6+
yarn-error.log*
7+
lerna-debug.log*
8+
9+
# Dependency directories
10+
node_modules/
11+
jspm_packages/
12+
13+
# TypeScript cache
14+
*.tsbuildinfo
15+
16+
# Optional npm cache directory
17+
.npm
18+
19+
# Optional eslint cache
20+
.eslintcache
21+
22+
# Output of 'npm pack'
23+
*.tgz
24+
25+
# Yarn Integrity file
26+
.yarn-integrity
27+
28+
# dotenv environment variables file
29+
.env
30+
.env.test
31+
.env.local
32+
33+
# SPFx build output
34+
SPFx/dist/
35+
SPFx/lib/
36+
SPFx/temp/
37+
SPFx/coverage/
38+
SPFx/release/
39+
SPFx/sharepoint/
40+
41+
# Azure Function build output
42+
AzureFunction/**/bin/
43+
AzureFunction/**/obj/
44+
AzureFunction/**/.vs/
45+
AzureFunction/**/*.user
46+
AzureFunction/**/*.suo
47+
AzureFunction/**/.vscode/
48+
AzureFunction/**/local.settings.json
49+
50+
# OS generated files
51+
.DS_Store
52+
.DS_Store?
53+
._*
54+
.Spotlight-V100
55+
.Trashes
56+
ehthumbs.db
57+
Thumbs.db
58+
59+
# IDE
60+
.vscode/
61+
.idea/
62+
*.swp
63+
*.swo
64+
*~
65+
66+
# Azure Storage Emulator
67+
__blobstorage__/
68+
__queuestorage__/
69+
__azurite_db*__.json
138 KB
Loading
Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
[
2+
{
3+
"name": "pnp-sp-dev-spfx-extensions-react-command-document-translation",
4+
"source": "pnp",
5+
"title": "Command Document Translation",
6+
"shortDescription": "A SharePoint Framework (SPFx) List View Command Set extension that enables users to translate documents from one language to another using Azure Document Translation Service. Users can select one or more documents from a SharePoint document library and translate them into multiple target languages simultaneously.",
7+
"url": "https://github.com/pnp/sp-dev-fx-extensions/tree/main/samples/react-command-document-translation",
8+
"longDescription": [
9+
"A SharePoint Framework (SPFx) List View Command Set extension that enables users to translate documents from one language to another using Azure Document Translation Service. Users can select one or more documents from a SharePoint document library and translate them into multiple target languages simultaneously."
10+
],
11+
"creationDateTime": "2025-11-12",
12+
"updateDateTime": "2025-11-12",
13+
"products": [
14+
"SharePoint"
15+
],
16+
"metadata": [
17+
{
18+
"key": "CLIENT-SIDE-DEV",
19+
"value": "React"
20+
},
21+
{
22+
"key": "SPFX-VERSION",
23+
"value": "1.21.1"
24+
}
25+
],
26+
"tags": [],
27+
"categories": [
28+
"SPFX-APPLICATION-EXTENSION"
29+
30+
],
31+
"thumbnails": [
32+
{
33+
"type": "image",
34+
"order": 100,
35+
"url": "https://github.com/pnp/sp-dev-fx-extensions/raw/main/samples/react-command-document-translation/assets/demo.gif",
36+
"alt": "Preview"
37+
}
38+
],
39+
"authors": [
40+
{
41+
"gitHubAccount": "ramin-ahmadi",
42+
"pictureUrl": "https://github.com/ramin-ahmadi.png",
43+
"name": "Ramin Ahmadi"
44+
}
45+
],
46+
"references": [
47+
{
48+
"name": "Overview of SharePoint Framework Extensions",
49+
"description": "You can use SharePoint Framework (SPFx) Extensions to extend the SharePoint user experience. With SPFx Extensions, you can customize more facets of the SharePoint experience, including notification areas, toolbars, and list data views. SPFx Extensions are available in all Microsoft 365 subscriptions for production usage.",
50+
"url": "https://learn.microsoft.com/sharepoint/dev/spfx/extensions/overview-extensions?WT.mc_id=m365-15741-cxa"
51+
},
52+
{
53+
"name": "Use page placeholders from Application Customizer",
54+
"description": "Application Customizers provide access to well-known locations on SharePoint pages that you can modify based on your business and functional requirements. For example, you can create dynamic header and footer experiences that render across all the pages in SharePoint Online.",
55+
"url": "https://learn.microsoft.com/sharepoint/dev/spfx/extensions/get-started/using-page-placeholder-with-extensions?WT.mc_id=m365-15741-cxa"
56+
}
57+
]
58+
}
59+
]
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project Sdk="Microsoft.NET.Sdk">
3+
<PropertyGroup>
4+
<TargetFramework>net9.0</TargetFramework>
5+
<AzureFunctionsVersion>v4</AzureFunctionsVersion>
6+
<OutputType>Exe</OutputType>
7+
<ImplicitUsings>enable</ImplicitUsings>
8+
<Nullable>enable</Nullable>
9+
<UserSecretsId>8fd684cc-26c3-59e2-940e-25c29bf8bbf1</UserSecretsId>
10+
</PropertyGroup>
11+
<ItemGroup>
12+
<Content Include="host.json" />
13+
<Content Include="local.settings.json">
14+
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
15+
</Content>
16+
</ItemGroup>
17+
<ItemGroup>
18+
<FrameworkReference Include="Microsoft.AspNetCore.App" />
19+
</ItemGroup>
20+
<ItemGroup>
21+
<PackageReference Include="Azure.Data.Tables" Version="12.11.0" />
22+
<PackageReference Include="Azure.Identity" Version="1.13.2" />
23+
<PackageReference Include="Azure.Messaging.ServiceBus" Version="7.18.1" />
24+
<PackageReference Include="Azure.Storage.Blobs" Version="12.26.0-beta.1" />
25+
<PackageReference Include="FluentValidation" Version="12.0.0" />
26+
<PackageReference Include="Microsoft.ApplicationInsights.WorkerService" Version="2.23.0" />
27+
<PackageReference Include="Microsoft.Azure.Functions.Worker" Version="2.0.0" />
28+
<PackageReference Include="Microsoft.Azure.Functions.Worker.ApplicationInsights" Version="2.0.0" />
29+
<PackageReference Include="Microsoft.Azure.Functions.Worker.Extensions.Http.AspNetCore" Version="2.0.1" />
30+
<PackageReference Include="Microsoft.Azure.Functions.Worker.Extensions.ServiceBus" Version="5.23.0" />
31+
<PackageReference Include="Microsoft.Azure.Functions.Worker.Extensions.Storage.Blobs" Version="6.7.0" />
32+
<PackageReference Include="Microsoft.Azure.Functions.Worker.Sdk" Version="2.0.5" />
33+
<PackageReference Include="Microsoft.Extensions.Configuration.UserSecrets" Version="10.0.0-preview.7.25380.108" />
34+
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="9.0.8" />
35+
<PackageReference Include="Microsoft.Extensions.Http" Version="9.0.8" />
36+
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
37+
<PackageReference Include="PnP.Core" Version="1.15.122-nightly" />
38+
<PackageReference Include="PnP.Core.Auth" Version="1.15.122-nightly" />
39+
<PackageReference Include="Polly" Version="8.6.2" />
40+
<PackageReference Include="System.ComponentModel" Version="4.3.0" />
41+
</ItemGroup>
42+
<ItemGroup>
43+
<None Update="host.json">
44+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
45+
</None>
46+
</ItemGroup>
47+
<ItemGroup>
48+
<Using Include="System.Threading.ExecutionContext" Alias="ExecutionContext" />
49+
</ItemGroup>
50+
</Project>
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
2+
Microsoft Visual Studio Solution File, Format Version 12.00
3+
# Visual Studio Version 17
4+
VisualStudioVersion = 17.13.35825.156 d17.13
5+
MinimumVisualStudioVersion = 10.0.40219.1
6+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DocumentTranslationApp", "DocumentTranslationApp.csproj", "{30B344B5-EB42-B184-1746-0AC0D4B9EB7D}"
7+
EndProject
8+
Global
9+
GlobalSection(SolutionConfigurationPlatforms) = preSolution
10+
Debug|Any CPU = Debug|Any CPU
11+
Release|Any CPU = Release|Any CPU
12+
EndGlobalSection
13+
GlobalSection(ProjectConfigurationPlatforms) = postSolution
14+
{30B344B5-EB42-B184-1746-0AC0D4B9EB7D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
15+
{30B344B5-EB42-B184-1746-0AC0D4B9EB7D}.Debug|Any CPU.Build.0 = Debug|Any CPU
16+
{30B344B5-EB42-B184-1746-0AC0D4B9EB7D}.Release|Any CPU.ActiveCfg = Release|Any CPU
17+
{30B344B5-EB42-B184-1746-0AC0D4B9EB7D}.Release|Any CPU.Build.0 = Release|Any CPU
18+
EndGlobalSection
19+
GlobalSection(SolutionProperties) = preSolution
20+
HideSolutionNode = FALSE
21+
EndGlobalSection
22+
GlobalSection(ExtensibilityGlobals) = postSolution
23+
SolutionGuid = {D5EAEA8B-E51D-4ADD-B867-EB32C21D5380}
24+
EndGlobalSection
25+
EndGlobal
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
namespace DocumentTranslationApp.Models;
2+
3+
public class SpfxTranslationRequest
4+
{
5+
public required string SiteUrl { get; set; }
6+
public required List<DocumentInfo> Documents { get; set; }
7+
public required TranslationOptions Options { get; set; }
8+
public RequestContext? Context { get; set; }
9+
}

0 commit comments

Comments
 (0)