This repository was archived by the owner on Jul 9, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 374
feature: localization framework and pseudolocalization #3913
Merged
Merged
Changes from 66 commits
Commits
Show all changes
74 commits
Select commit
Hold shift + click to select a range
3afb365
create l10n-extract script
beyackle 7723743
Merge branch 'main' into beyackle/l10nExtract
beyackle 61c31c3
Merge branch 'main' into beyackle/l10nExtract
beyackle 8aeab8e
Update l10n-extract.js
beyackle ab0184b
clean up code and move files into own directory
beyackle 0c76d05
rename files
beyackle d31826d
Update l10n-extract.js
beyackle 4c36195
refactor utils and fix small bug
beyackle 28ecea9
add pseudol10n for client locales file
beyackle e253dca
add pseudolocalization
beyackle c4a1545
Update index.tsx
beyackle 22508e8
Update botProject.ts
beyackle 2026e6f
transform other files
beyackle 4d8d896
Merge branch 'main' into beyackle/l10n-mock
beyackle 0b87518
move locales into src
beyackle 4cf3b99
unify .json files
beyackle f6d96a5
move format-message and other fixes
beyackle 77cfaf8
merge in settings dropdown
beyackle 33b32df
almost-working locale serverside locale swap
beyackle 17d71c5
Update App.tsx
beyackle 438f78d
fix server silliness
beyackle dc0c4d5
move locale-loading to dispatcher
beyackle d9a903c
Update user.ts
beyackle 1a5a6f1
fix scripts
beyackle 25caeb5
remove stray files
beyackle b1c707b
Merge branch 'main' into beyackle/l10n-mock
beyackle 6a32635
make serverside schemas mostly work
beyackle d775483
Update dialogUtil.ts
beyackle da2a5a0
Merge branch 'main' into beyackle/l10n-mock
beyackle a4e3baa
use override files
beyackle 22d0e84
WIP on schema override reading
beyackle 03641e0
Merge branch 'main' into beyackle/l10n-mock
beyackle f6ec874
fix filename typo
beyackle 198d943
Update botProject.ts
beyackle 7cecdd5
Merge branch 'main' into beyackle/l10n-mock
beyackle 87a83ee
move loadLocale out and use for init
beyackle b8084af
fix l10n script
beyackle b6635b0
fix typo
beyackle 912503b
delay concept labels
beyackle 77f39fb
Update viewUtils.ts
beyackle 60311e2
Update package.json
beyackle ef20115
Merge branch 'main' into beyackle/l10n-mock
beyackle ba09759
update tests (still WIP)
beyackle 8cc8a08
Update fileUtil.test.js
beyackle 585db80
Merge branch 'main' into beyackle/l10n-mock
beyackle 18c675b
fix loadLocale tests
beyackle 8be44c3
Merge branch 'beyackle/l10n-mock' of https://github.com/microsoft/Bot…
beyackle 0f46ff5
Merge branch 'main' into beyackle/l10n-mock
beyackle 3928d6c
Update .gitignore
beyackle 915da8b
Merge branch 'beyackle/l10n-mock' of https://github.com/microsoft/Bot…
beyackle 93b8278
remove pseudo files
beyackle 8722606
Merge branch 'main' into beyackle/l10n-mock
beyackle 8d13d2a
fix design of settings
beyackle ac11d43
Update AppSettings.tsx
beyackle 704242c
Update en-US.json
beyackle 28b57cb
Merge branch 'main' into beyackle/l10n-mock
beyackle c76dea1
fix CR issues and move schema files
beyackle 5399ef6
Merge branch 'main' into beyackle/l10n-mock
beyackle 3b54ba7
add l10n to build scripts
beyackle 2950b5c
Merge branch 'main' into beyackle/l10n-mock
beyackle 06543d8
Merge branch 'main' into beyackle/l10n-mock
beyackle 4761f14
Update botProject.ts
beyackle 9a0ce8a
Merge branch 'main' into beyackle/l10n-mock
beyackle 6a07f73
resolve node-forge to 0.10 for security thing
beyackle c8cc64c
Merge branch 'beyackle/l10n-mock' of https://github.com/microsoft/Bot…
beyackle b46deea
Update LuisDeploy.spec.ts
beyackle 9248939
fixes from CR
beyackle 312bafa
Update botProject.ts
beyackle 5c72cf4
Merge branch 'main' into beyackle/l10n-mock
beyackle 7433856
Merge branch 'main' into beyackle/l10n-mock
beyackle 6e2731d
Merge branch 'main' into beyackle/l10n-mock
beyackle 1d174da
rebuild files
beyackle 90519d7
Merge branch 'main' into beyackle/l10n-mock
beyackle 68e45ca
post-merge fixes
beyackle File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
51 changes: 51 additions & 0 deletions
51
Composer/packages/client/src/pages/setting/app-settings/SettingDropdown.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,51 @@ | ||
| // Copyright (c) Microsoft Corporation. | ||
| // Licensed under the MIT License. | ||
|
|
||
| /** @jsx jsx */ | ||
| import { jsx } from '@emotion/core'; | ||
| import React from 'react'; | ||
| import { Label } from 'office-ui-fabric-react/lib/Label'; | ||
| import { useId } from '@uifabric/react-hooks'; | ||
| import kebabCase from 'lodash/kebabCase'; | ||
| import { Dropdown } from 'office-ui-fabric-react/lib/Dropdown'; | ||
|
|
||
| import * as styles from './styles'; | ||
|
|
||
| interface ISettingToggleProps { | ||
| description: React.ReactChild; | ||
| id?: string; | ||
| image: string; | ||
| onChange: (key: string) => void; | ||
| title: string; | ||
| options: { key: string; text: string }[]; | ||
| selected?: string; | ||
| } | ||
|
|
||
| const SettingDropdown: React.FC<ISettingToggleProps> = (props) => { | ||
| const { id, title, description, image, onChange, options, selected } = props; | ||
| const uniqueId = useId(kebabCase(title)); | ||
|
|
||
| return ( | ||
| <div css={styles.settingsContainer}> | ||
| <div aria-hidden="true" css={styles.image} role="presentation"> | ||
| {image && <img aria-hidden alt={''} src={image} />} | ||
| </div> | ||
| <div css={styles.settingsContent}> | ||
| <Label htmlFor={id || uniqueId} styles={{ root: { padding: 0 } }}> | ||
| {title} | ||
| </Label> | ||
| <p css={styles.settingsDescription}>{description}</p> | ||
| </div> | ||
| <div> | ||
| <Dropdown | ||
| id={id || uniqueId} | ||
| options={options} | ||
| selectedKey={selected} | ||
| onChange={(_e, option) => onChange(option?.key?.toString() ?? '')} | ||
| /> | ||
| </div> | ||
| </div> | ||
| ); | ||
| }; | ||
|
|
||
| export { SettingDropdown }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
Composer/packages/client/src/pages/setting/app-settings/images/language.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.