Skip to content
This repository was archived by the owner on Jul 9, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
64f2643
Remove bot settings tool bar buttons
pavolum May 4, 2021
709a795
Change settings header string and remove subtext
pavolum May 4, 2021
0eb3d43
Fix capitalization in settings tabs
pavolum May 4, 2021
7b08441
More space between pivot menu and content--should be consistent on ea…
pavolum May 4, 2021
78ca964
- Align content with pivot menu on left side
pavolum May 4, 2021
37e8b09
In all tables, headers should be semi-bold rather than bold
pavolum May 4, 2021
d663a60
nix tool tip on start command
pavolum May 4, 2021
ea47fd7
"Readme" instead of "Read Me"
pavolum May 4, 2021
200b86c
Ensure padding at bottom of page
pavolum May 4, 2021
ea482a4
Tighten up horizontal spacing between columns in tables
pavolum May 4, 2021
05fb16d
Replacing routerLink with Link for consistent styling
pavolum May 4, 2021
082c52d
Lower-case M in "Open manifest"
pavolum May 4, 2021
95752e3
- Action item sub-text too small
pavolum May 4, 2021
be68e42
Sub-titles should be semi-bold
pavolum May 4, 2021
a81dc02
- Align table with “Publish” (move to the right)
pavolum May 4, 2021
4536650
- "Publishing profile"--lowercase on profile
pavolum May 4, 2021
f2e5bf3
- Super long add button (#7491)
pavolum May 4, 2021
6736984
Table needs line under header
pavolum May 4, 2021
f132d63
Edit and delete buttons are too small, too high
pavolum May 4, 2021
36bd0aa
Align Target column content with header (move content right)
pavolum May 4, 2021
0748c03
Tighten spacing between edit and delete buttons
pavolum May 4, 2021
977bbeb
"Learn more" move to top sentence after "...Microsoft Azure is requir…
pavolum May 4, 2021
26dcdec
- Lowercase m
pavolum May 4, 2021
0cac691
- Do we need description field? Can we remove it?
pavolum May 4, 2021
e2586c2
Design iteration changes with Em
pavolum May 4, 2021
39c4b30
add line under bot settings header
pavolum May 4, 2021
3b0e764
Almost there" bubb is the wrong component, should be the blue one
pavolum May 4, 2021
ed67b90
urther Tighten spacing between edit and delete buttons in publish view
pavolum May 4, 2021
5ec00c2
DefineConversation: Button should say “Create” instead of OK
pavolum May 4, 2021
466ed40
Move json switch to right side and make text smaller size
pavolum May 4, 2021
03d964b
Fix existing resource terminology in service provision modal
pavolum May 4, 2021
46f2a10
#7578: increase width of publish profile dropdown
pavolum May 4, 2021
8585ee9
Merge branch 'main' into pavolum/fitAndFinish
pavolum May 4, 2021
9ecf206
Auto close get started pane when bot controller callout is visible
pavolum May 4, 2021
29a568f
Handle merge conflicts
pavolum May 4, 2021
a1f830e
fixing errors from merge
pavolum May 4, 2021
a0c9a4f
Fix unit test
pavolum May 5, 2021
658a0fb
removing unit test based on old link type
pavolum May 5, 2021
e736514
Merge branch 'main' into pavolum/fitAndFinish
hatpick May 5, 2021
77b10b9
updating locale strings
pavolum May 5, 2021
489f8ff
Merge branch 'main' into pavolum/fitAndFinish
cwhitten May 5, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ describe('<CreationFlowV2/>', () => {
);

navigate('create/dotnet/%40microsoft%2Fgenerator-bot-empty');
const node = await findByText('OK');
const node = await findByText('Create');

act(() => {
fireEvent.click(node);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,17 +80,6 @@ describe('ExternalAdapterSettings', () => {
setSettingsMock.mockClear();
});

it('renders a link to the package manager', () => {
const { getByText } = renderWithRecoilAndCustomDispatchers(
<ExternalAdapterSettings projectId={PROJECT_ID} />,
initRecoilState
);

const link = getByText(/from package manager/);

expect(link.attributes.getNamedItem('href')?.value).toContain('plugin/package-manager/package-manager');
});

it('brings up the modal', () => {
const { getByTestId, getByText, queryByTestId } = renderWithRecoilAndCustomDispatchers(
<ExternalAdapterSettings projectId={PROJECT_ID} />,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ export const PublishDialog: React.FC<IPublishDialogProps> = (props) => {
<br />
{Text.LUISDEPLOY}
<Link href={Links.LUIS} target="_blank">
{formatMessage('Learn more.')}
{formatMessage('Learn more')}
</Link>
</Fragment>
);
Expand All @@ -187,7 +187,7 @@ export const PublishDialog: React.FC<IPublishDialogProps> = (props) => {
<br />
{Text.QNADEPLOY}
<Link href={Links.QNA} target="_blank">
{formatMessage('Learn more.')}
{formatMessage('Learn more')}
</Link>
</Fragment>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -527,17 +527,20 @@ export const FileSelector: React.FC<FileSelectorProps> = (props) => {
label={formatMessage('Location')}
options={breadcrumbItems}
selectedKey={currentPath}
styles={{ root: { width: '420px' } }}
onChange={updatePath}
onPendingValueChanged={updatePathPending}
/>
</StackItem>
{operationMode.write && (
<StackItem align={'end'} styles={{ root: { marginBottom: 5 } }}>
<Link disabled={editMode !== EditMode.NONE} onClick={onCreateNewFolder}>
{operationMode.write && (
<Link
disabled={editMode !== EditMode.NONE}
styles={{ root: { marginTop: '5px' } }}
onClick={onCreateNewFolder}
>
{formatMessage('Create new folder')}
</Link>
</StackItem>
)}
)}
</StackItem>
</Stack>
<div css={detailListContainer} data-is-scrollable="true">
<ScrollablePane scrollbarVisibility={ScrollbarVisibility.auto}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,9 @@ const textFieldlabel = {
};

const name = {
subComponentStyles: textFieldlabel,
};

const description = {
root: {
width: '420px',
},
subComponentStyles: textFieldlabel,
};

Expand Down Expand Up @@ -367,36 +366,26 @@ const DefineConversationV2: React.FC<DefineConversationProps> = (props) => {
onChange={(_e, val) => updateField('name', val)}
/>
</StackItem>
<StackItem grow={0} styles={halfstack}>
<TextField
label={formatMessage('Description')}
resizable={false}
styles={description}
value={formData.description}
onChange={(_e, val) => updateField('description', val)}
/>
</StackItem>
</Stack>
{!isImported && (
<Stack horizontal styles={stackinput} tokens={{ childrenGap: '2rem' }}>
{!isImported && (
<StackItem grow={0} styles={halfstack}>
<Dropdown
data-testid="NewDialogRuntimeType"
label={formatMessage('Runtime type')}
options={getSupportedRuntimesForTemplate()}
selectedKey={formData.runtimeType}
styles={{ root: { width: '420px' } }}
onChange={(_e, option) => updateField('runtimeType', option?.key.toString())}
/>
</StackItem>
</Stack>
)}
)}
</Stack>
{locationSelectContent}
<DialogFooter>
<DefaultButton text={formatMessage('Cancel')} onClick={onDismiss} />
<PrimaryButton
data-testid="SubmitNewBotBtn"
disabled={hasErrors || !writable}
text={templateId === QnABotTemplateId ? formatMessage('Next') : formatMessage('OK')}
text={templateId === QnABotTemplateId ? formatMessage('Next') : formatMessage('Create')}
onClick={handleSubmit}
/>
</DialogFooter>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@ type TaskProps = {
};

const getStartedStepStyle = (disabled?: boolean) => css`
margin-bottom: 15px;
margin-bottom: 10px;
pointer-events: ${disabled ? 'none' : 'auto'};
opacity: ${disabled ? 0.4 : 1};
`;

const stepDescriptionStyle = css`
margin-left: 36px;
font-size: 12px;
font-size: 14px;
color: ${NeutralColors.gray120};
margin-top: -4px;
`;
Expand Down
4 changes: 2 additions & 2 deletions Composer/packages/client/src/components/GetStarted/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ import { FontWeights } from 'office-ui-fabric-react/lib/Styling';
export const h3Style = css`
font-size: ${FontSizes.size14};
margin-top: 24px;
font-weight: ${FontWeights.regular};
font-weight: ${FontWeights.semibold};
margin-bottom: 4px;
`;

export const topH3Style = css`
font-size: ${FontSizes.size14};
margin-top: 12px;
font-weight: ${FontWeights.regular};
font-weight: ${FontWeights.semibold};
margin-bottom: 4px;
`;

Expand Down
6 changes: 6 additions & 0 deletions Composer/packages/client/src/components/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,12 @@ export const Header = () => {
}
}, [isWebChatPanelVisible]);

useEffect(() => {
if (!hideBotController && showGetStarted) {
setShowGetStarted(false);
}
}, [hideBotController]);

const showUpdateAvailableIcon = status === AppUpdaterStatus.UPDATE_AVAILABLE && !showing;

const languageListOptions = useMemo(() => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ export const AllowedCallers: React.FC<Props> = ({ projectId }) => {
<div css={title}>{formatMessage('Allowed Callers')}</div>
<div css={subtext}>
{formatMessage.rich(
'Skills can be “called” by external bots. Allow other bots to call your skill by adding their App IDs to the list below. <a>Learn more.</a>',
'Skills can be “called” by external bots. Allow other bots to call your skill by adding their App IDs to the list below. <a>Learn more</a>',
{
a: ({ children }) => (
<Link
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ export const AppIdAndPassword: React.FC<AppIdAndPasswordProps> = (props) => {
<div css={title}>{formatMessage('Microsoft App ID')}</div>
<div css={subtext}>
{formatMessage.rich(
'An App ID is used for communication between your bot and skills, services, websites or applications. Use an existing App ID or automatically generate an App ID when creating a publishing profile for this bot. <a>Learn more.</a>',
'An App ID is used for communication between your bot and skills, services, websites or applications. Use an existing App ID or automatically generate an App ID when creating a publishing profile for this bot. <a>Learn more</a>',
{
a: ({ children }) => (
<Link key="app-id-settings-page" href={'https://aka.ms/composer-appid-learnmore'} target="_blank">
Expand Down
4 changes: 2 additions & 2 deletions Composer/packages/client/src/pages/botProject/BotLanguage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import { AddLanguageModal } from '../../components/MultiLanguage';
import { mergePropertiesManagedByRootBot } from '../../recoilModel/dispatchers/utils/project';
import { rootBotProjectIdSelector } from '../../recoilModel/selectors/project';

import { subtitle } from './styles';
import { headerText } from './styles';
// -------------------- Styles -------------------- //

const botLanguageContainerStyle = css`
Expand Down Expand Up @@ -152,7 +152,7 @@ export const BotLanguage: React.FC<BotLanguageProps> = (props) => {
return (
<Fragment>
<div css={botLanguageContainerStyle}>
<div css={subtitle}>
<div css={headerText}>
{formatMessage(
'List of languages that bot will be able to understand (User input) and respond to (Bot responses). To make this bot available in other languages, click ‘Manage languages’ to create a copy of the default language, and translate the content into the new language.'
)}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ const valueStyle = css`
const headerStyle = css`
font-size: 20px;
font-weight: 600;
margin-top: 25px;
`;

const rootTextStyle = css`
Expand Down Expand Up @@ -61,12 +62,12 @@ export const BotProjectInfo: React.FC<RouteComponentProps<{
setReadmeHidden(false);
}}
>
{formatMessage('View readme')}
{formatMessage('View Readme')}
</Link>
<DisplayMarkdownDialog
content={readme}
hidden={readmeHidden}
title={formatMessage('Project readme')}
title={formatMessage('Project Readme')}
onDismiss={() => {
setReadmeHidden(true);
}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,9 @@ import formatMessage from 'format-message';
import { RouteComponentProps } from '@reach/router';
import { JsonEditor } from '@bfc/code-editor';
import { Toggle } from 'office-ui-fabric-react/lib/Toggle';
import { DialogSetting } from '@bfc/shared';
import { defaultToolbarButtonStyles } from '@bfc/ui-shared';
import { DialogSetting } from '@botframework-composer/types';

import TelemetryClient from '../../telemetry/TelemetryClient';
import { LoadingSpinner } from '../../components/LoadingSpinner';
import { INavTreeItem } from '../../components/NavTree';
import { Page } from '../../components/Page';
Expand All @@ -21,7 +20,6 @@ import { settingsState, userSettingsState } from '../../recoilModel/atoms';
import { localBotsDataSelector, rootBotProjectIdSelector } from '../../recoilModel/selectors/project';
import { createBotSettingUrl, navigateTo } from '../../utils/navigation';
import { mergePropertiesManagedByRootBot } from '../../recoilModel/dispatchers/utils/project';
import { usePVACheck } from '../../hooks/usePVACheck';

import { openDeleteBotModal } from './DeleteBotButton';
import { BotProjectSettingsTabView } from './BotProjectsSettingsTabView';
Expand All @@ -31,10 +29,9 @@ import { BotProjectSettingsTabView } from './BotProjectsSettingsTabView';
const header = css`
padding: 5px 20px;
display: flex;
flex-direction: column;
flex-shrink: 0;
justify-content: space-between;
label: PageHeader;
border-bottom: 1px solid silver;
`;

const container = css`
Expand All @@ -54,75 +51,15 @@ const BotProjectSettings: React.FC<RouteComponentProps<{ projectId: string; skil
const currentProjectId = skillId ?? projectId;
const botProject = botProjects.find((b) => b.projectId === currentProjectId);
const { deleteBot } = useRecoilValue(dispatcherState);
const isPVABot = usePVACheck(currentProjectId);

const settings = useRecoilValue(settingsState(currentProjectId));
const mergedSettings = mergePropertiesManagedByRootBot(currentProjectId, rootBotProjectId, settings);

const [isAdvancedSettingsEnabled, setAdvancedSettingsEnabled] = useState<boolean>(false);

const { setSettings } = useRecoilValue(dispatcherState);

const buttonClick = (link) => {
TelemetryClient.track('GettingStartedLinkClicked', { method: 'button', url: link });
navigateTo(link);
};

const toolbarItems = useMemo(() => {
const linkToPackageManager = `/bot/${rootBotProjectId}/plugin/package-manager/package-manager`;
const linkToConnections = `/bot/${rootBotProjectId}/botProjectsSettings/#connections`;
const linkToLGEditor = `/bot/${rootBotProjectId}/language-generation`;
const linkToLUEditor = `/bot/${rootBotProjectId}/language-understanding`;

return [
...(!isPVABot
? [
{
text: formatMessage('Add a package'),
type: 'action',
buttonProps: {
iconProps: { iconName: 'Package' },
onClick: () => buttonClick(linkToPackageManager),
styles: defaultToolbarButtonStyles,
},
align: 'left',
},
]
: []),
{
text: formatMessage('Edit LG'),
type: 'action',
buttonProps: {
iconProps: { iconName: 'Robot' },
onClick: () => buttonClick(linkToLGEditor),
styles: defaultToolbarButtonStyles,
},
align: 'left',
},
{
text: formatMessage('Edit LU'),
type: 'action',
buttonProps: {
iconProps: { iconName: 'People' },
onClick: () => buttonClick(linkToLUEditor),
styles: defaultToolbarButtonStyles,
},
align: 'left',
},
...(!isPVABot
? [
{
text: formatMessage('Manage connections'),
type: 'action',
buttonProps: {
iconProps: { iconName: 'PlugConnected' },
onClick: () => buttonClick(linkToConnections),
styles: defaultToolbarButtonStyles,
},
align: 'left',
},
]
: []),
{
text: formatMessage('Delete bot'),
type: 'action',
Expand Down Expand Up @@ -161,9 +98,19 @@ const BotProjectSettings: React.FC<RouteComponentProps<{ projectId: string; skil
return newbotProjectLinks;
}, [botProjects]);

const onRenderHeaderContent = () => {
return formatMessage(
"Review and configure your bot's resources, and add new connections such as speech, Microsoft Teams and more."
const renderJsonToggle = (): JSX.Element => {
return (
<Toggle
inlineLabel
checked={isAdvancedSettingsEnabled}
className={'advancedSettingsView'}
defaultChecked={false}
label={formatMessage('Advanced Settings View (json)')}
styles={{ label: { fontSize: '12px', marginLeft: '8px' } }}
onChange={() => {
setAdvancedSettingsEnabled(!isAdvancedSettingsEnabled);
}}
/>
);
};

Expand Down Expand Up @@ -195,20 +142,10 @@ const BotProjectSettings: React.FC<RouteComponentProps<{ projectId: string; skil
shouldShowEditorError={false}
title={formatMessage('Configure your bot')}
toolbarItems={toolbarItems}
onRenderHeaderContent={onRenderHeaderContent}
onRenderHeaderContent={renderJsonToggle}
>
<Suspense fallback={<LoadingSpinner />}>
<div css={container}>
<Toggle
inlineLabel
checked={isAdvancedSettingsEnabled}
className={'advancedSettingsView'}
defaultChecked={false}
label={formatMessage('Advanced Settings View (json)')}
onChange={() => {
setAdvancedSettingsEnabled(!isAdvancedSettingsEnabled);
}}
/>
{isAdvancedSettingsEnabled ? (
<JsonEditor
key={'settingsjson'}
Expand Down
Loading