Skip to content

Commit

Permalink
Merge branch 'dev' into feature/sovereign-clouds
Browse files Browse the repository at this point in the history
  • Loading branch information
Onokaev authored Aug 4, 2022
2 parents ba76b4b + b06569a commit 2a4ed3e
Show file tree
Hide file tree
Showing 9 changed files with 58 additions and 55 deletions.
2 changes: 1 addition & 1 deletion config/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ module.exports = function (webpackEnv) {
maxChunks: 1
}),
new MonacoWebpackPlugin({
languages: ['json', 'javascript', 'java', 'csharp', 'html', 'powershell', 'go', 'php']
languages: ['json', 'javascript', 'java', 'csharp', 'html', 'powershell', 'go']
}),
// Generates an `index.html` file with the <script> injected.
new HtmlWebpackPlugin(
Expand Down
84 changes: 41 additions & 43 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "graph-explorer-v2",
"version": "6.1.0",
"version": "6.2.0",
"private": true,
"dependencies": {
"@augloop/types-core": "file:packages/types-core-2.16.189.tgz",
Expand Down
2 changes: 1 addition & 1 deletion src/app/services/actions/snippet-action-creator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ export function getSnippet(language: string): Function {
if (language !== 'csharp') {
snippetsUrl += `?lang=${language}`;
}
const openApiSnippets: string[] = ['go', 'powershell', 'php'];
const openApiSnippets: string[] = ['go', 'powershell'];
if (openApiSnippets.includes(language)) {
snippetsUrl += '&generation=openapi';
}
Expand Down
1 change: 0 additions & 1 deletion src/app/views/main-header/MainHeader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ export const MainHeader: React.FunctionComponent <MainHeaderProps> = (props: Mai
feedbackIconAdjustmentStyles, tenantIconStyles, moreInformationStyles,
tenantLabelStyle, tenantContainerStyle } = mainHeaderStyles(currentTheme, mobileScreen);


return (
<Stack tokens={sectionStackTokens}>
<Stack
Expand Down
4 changes: 0 additions & 4 deletions src/app/views/query-response/snippets/Snippets.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,6 @@ function GetSnippets() {
'PowerShell': {
sdkDownloadLink: 'https://aka.ms/pshellsdk',
sdkDocLink: 'https://aka.ms/pshellsdkdocs'
},
'PHP': {
sdkDownloadLink: 'https://aka.ms/graphphpsdk',
sdkDocLink: 'https://aka.ms/sdk-doc'
}
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,7 @@ export const ShareQuery = () => {

const query = { ...sampleQuery };
const sanitizedQueryUrl = sanitizeQueryUrl(query.sampleUrl);
query.sampleUrl = sanitizedQueryUrl;
const shareLink = createShareLink(query);
const shareLink = createShareLink(sampleQuery);

const toggleShareQueryDialogState = () => {
setShareQuaryDialogStatus(prevState => !prevState);
Expand All @@ -37,7 +36,7 @@ export const ShareQuery = () => {
telemetry.trackEvent(eventTypes.BUTTON_CLICK_EVENT,
{
ComponentName: componentNames.SHARE_QUERY_COPY_BUTTON,
QuerySignature: `${sampleQuery.selectedVerb} ${sanitizedQueryUrl}`
QuerySignature: `${query.selectedVerb} ${sanitizedQueryUrl}`
});
}

Expand Down
10 changes: 9 additions & 1 deletion src/modules/suggestions/suggestions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,15 @@ class Suggestions implements ISuggestions {
return localOptions;
}

return this.fetchSuggestionsFromNetwork(url, api, version);
/*
* blocks calls to the API for path segments
* uses resource explorer and cache as source of truth
*/
if (context === 'parameters') {
return this.fetchSuggestionsFromNetwork(url, api, version);
}

return null;
}

private async getSuggestionsFromResources(url: string, version: string,
Expand Down
3 changes: 3 additions & 0 deletions src/telemetry/component-names.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,9 @@ export const CODE_SNIPPET_LANGUAGES = {
},
Powershell: {
sdk: 'PowerShell snippet SDK link', doc: 'PowerShell snippet docs link'
},
PHP: {
sdk: 'PHP snippet SDK link', doc: 'PHP snippet docs link'
}
}
export const GE_DOCUMENTATION_LINK = 'GE documentation link';
Expand Down

0 comments on commit 2a4ed3e

Please sign in to comment.