Skip to content

Commit

Permalink
Add example url in image discovery
Browse files Browse the repository at this point in the history
  • Loading branch information
nxtCoder19 committed Oct 10, 2024
1 parent 8f083e9 commit 4ef412a
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 1 deletion.
2 changes: 2 additions & 0 deletions gql-queries-generator/doc/queries.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -4494,6 +4494,8 @@ query consoleGetRegistryImageUrl {
core_getRegistryImageURL {
scriptUrl
url
urlExample
scriptUrlExample
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { useParams } from '@remix-run/react';
import { useState } from 'react';
import { Button } from '~/components/atoms/button';
import Banner from '~/components/molecule/banner';
import Popup from '~/components/molecule/popup';
import CodeView from '~/console/components/code-view';
import ExtendedFilledTab from '~/console/components/extended-filled-tab';
Expand Down Expand Up @@ -71,6 +72,17 @@ export const RegistryImageInstruction = ({
language="sh"
/>
))}
<Banner
type="info"
body={
<div className="flex flex-col gap-md">
<span className="bodyMd-medium">
Webhook Image Metadata Push Example:
</span>
<span className="bodyMd">{data.urlExample}</span>
</div>
}
/>
</div>
)}
{active === 'script-url' && (
Expand All @@ -85,6 +97,20 @@ export const RegistryImageInstruction = ({
language="sh"
/>
))}
<Banner
type="info"
body={
<div className="flex flex-col gap-md">
<span className="bodyMd-medium">
Shell Script Example with Image and Meta
Information:
</span>
<span className="bodyMd">
{data.scriptUrlExample}
</span>
</div>
}
/>
</div>
)}
</div>
Expand Down
2 changes: 2 additions & 0 deletions src/apps/console/server/gql/queries/registry-image-queries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,8 @@ export const registryImagesQueries = (executor: IExecutor) => ({
core_getRegistryImageURL {
scriptUrl
url
urlExample
scriptUrlExample
}
}
`,
Expand Down
7 changes: 6 additions & 1 deletion src/generated/gql/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6071,7 +6071,12 @@ export type ConsoleGetRegistryImageUrlQueryVariables = Exact<{
}>;

export type ConsoleGetRegistryImageUrlQuery = {
core_getRegistryImageURL: { scriptUrl: Array<string>; url: Array<string> };
core_getRegistryImageURL: {
scriptUrl: Array<string>;
url: Array<string>;
urlExample: string;
scriptUrlExample: string;
};
};

export type ConsoleSearchRegistryImagesQueryVariables = Exact<{
Expand Down

0 comments on commit 4ef412a

Please sign in to comment.