Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pull] main from adobe:main #1318

Open
wants to merge 62 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
62 commits
Select commit Hold shift + click to select a range
f376a65
Louisa/media component (#1557)
louisachu Jan 23, 2024
4da3d3f
Update package.json and changelog (#1558)
louisachu Jan 23, 2024
8b3cd19
Louisa/update readme (#1559)
louisachu Jan 24, 2024
fd36030
Louisa/redocly testing (#1560)
louisachu Jan 25, 2024
c05c90c
update changelog (#1561)
louisachu Jan 25, 2024
af99e1a
Louisa/redocly panel (#1562)
louisachu Jan 26, 2024
9159f34
update release build (#1563)
louisachu Jan 26, 2024
f6c2285
Update README.md (#1564)
louisachu Feb 7, 2024
1c840a1
update footer (#1565)
louisachu Feb 28, 2024
1a77a33
chore(release): publish @4.11.4
louisachu Feb 29, 2024
d71ce67
4.11.7 (#1566)
melissag-ensemble Mar 13, 2024
8cdcc61
Mini product card (#1567)
BaskarMitrah Mar 20, 2024
5fb12aa
chore(release): publish@4.11.8 (#1568)
melissag-ensemble Mar 20, 2024
e399ce8
chore(release): publish@4.11.9 (#1569)
melissag-ensemble Mar 20, 2024
bea2cb9
chore(release): publish@4.11.10 (#1570)
melissag-ensemble Mar 22, 2024
605fb23
chore(release): publish@4.11.11 (#1571)
melissag-ensemble Apr 1, 2024
9bd1a2b
docs: readme (#1572)
melissag-ensemble Apr 2, 2024
9128a8a
fix: half width hero image misaligned
timkim Apr 4, 2024
647c63b
chore(release): publish@4.11.12
timkim Apr 4, 2024
a78b072
build : Fixed the page load issues in the get credential component (#…
BaskarMitrah Apr 23, 2024
111b5af
chore(release): publish@4.11.13
timkim Apr 23, 2024
29235e0
chore(release): publish@4.11.14 (#1576)
melissag-ensemble May 15, 2024
d447efe
docs: update some info on using embedded markdown files from github
timkim May 18, 2024
2264f47
fix: Devsite 466 hero component displays scrollbar (#1582)
Elisha-Edme Jun 6, 2024
b786772
fix: increase cypress timeout time
timkim Jun 6, 2024
7ea5dc2
feat: generate code samples (#1586)
melissag-ensemble Jun 17, 2024
967ca4f
feat: request interceptor (#1588)
melissag-ensemble Jun 24, 2024
f030305
--Fixed the hamburger issue on the theme (#1587)
BaskarMitrah Jun 24, 2024
a0cbb62
fix: bump preact-render-to-string to 6.5.5
timkim Jul 8, 2024
63e5eda
chore(release): publish@4.12.0
timkim Jul 8, 2024
a2f6215
docs: update changelog
timkim Jul 8, 2024
729addf
chore(release): publish@4.13.0
timkim Jul 8, 2024
2200844
feat: get credential phase 2 (#1575)
BaskarMitrah Jul 10, 2024
de64ca0
Enable partial updates and fix algolia record size calculation (#1601)
dmitrymatio Jul 11, 2024
b880c78
chore(release): publish@4.14.2
dmitrymatio Jul 11, 2024
7e34919
fix: missing @adobe/react-spectrum in package
dmitrymatio Jul 11, 2024
2968b27
chore(release): publish@4.14.3
dmitrymatio Jul 11, 2024
41a4e1d
fix: IOC-7708 - redirect user to the signin page if API call returns …
deepessh Jul 15, 2024
4a10f91
--Fixed the next button issues on the credential card & return flow
BaskarMitrah Jul 16, 2024
e8ec4de
Fix Aloglia record objectID formula for partial index matching && fix…
dmitrymatio Jul 16, 2024
ec5f243
chore(release): publish@4.14.4
dmitrymatio Jul 16, 2024
f4882ae
--Migrated React spectrum to spectrum css
BaskarMitrah Jul 24, 2024
bf050b9
--Made product name as dynamically
BaskarMitrah Jul 24, 2024
31838dc
test: added e2e tests for get credentials (#1585)
deepessh Jul 24, 2024
133ca6f
Merge branch 'bugs/credential_design_issue'
BaskarMitrah Jul 25, 2024
9acb08a
Merge branch 'devsite-1243'
BaskarMitrah Jul 25, 2024
313c26a
Merge branch 'devsite-1245'
BaskarMitrah Jul 25, 2024
142cd28
chore(release): publish@4.14.5
timkim Jul 25, 2024
c84a757
fix: fix failing tests (#1607)
deepessh Jul 25, 2024
d0e4831
chore(release): publish@4.14.6
timkim Jul 25, 2024
4e42843
fix: maximize columns in discover block (#1608)
melissag-ensemble Aug 2, 2024
ec5969d
fix: link text not indexing (#1609)
dmitrymatio Aug 7, 2024
890dfd5
chore(release): publish@4.14.8
dmitrymatio Aug 7, 2024
8dcbc9e
feat: sticky feedback component (#1610)
melissag-ensemble Aug 9, 2024
46c3b8b
feat: Ims Org ID (#1611)
BaskarMitrah Aug 14, 2024
01390b3
feat: redocly sort configs (#1614)
melissag-ensemble Aug 15, 2024
e903adb
fix: readme for request interceptor (#1616)
melissag-ensemble Sep 10, 2024
627e88e
Bug : Update the credential card dynamically (#1618)
BaskarMitrah Sep 13, 2024
5f59612
feat: redocly scroll y offset (#1620)
melissag-ensemble Oct 1, 2024
a8f49aa
chore(release): publish@4.14.12 (#1621)
melissag-ensemble Oct 2, 2024
afa017b
Bugs : Credential component update (#1622)
BaskarMitrah Oct 10, 2024
2073d3f
chore(release): publish@4.14.13
timkim Oct 10, 2024
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
26 changes: 20 additions & 6 deletions .github/workflows/e2e-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,31 @@ on:
- "cypress/**"
jobs:
smoke_tests:
runs-on: ubuntu-latest
container:
image: cypress/browsers:node-20.14.0-chrome-126.0.6478.114-1-ff-127.0.1-edge-126.0.2592.61-1
options: --user root
runs-on: self-hosted
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: 'Create env file'
run: |
touch ./example/.env
echo GATSBY_IMS_SRC="https://auth-stg1.services.adobe.com/imslib/imslib.min.js" >> ./example/.env
echo GATSBY_IMS_CONFIG='{"client_id": "stage_adobe_io", "scope": "AdobeID,openid,unified_dev_portal,read_organizations,additional_info.projectedProductContext,additional_info.roles,gnav,read_pc.dma_bullseye,creative_sdk,adobeio_api,service_principals.read,service_principals.write,read_client_secret", "environment": "stg1"}' >> ./example/.env
cat ./example/.env

- name: Run Tests
uses: cypress-io/github-action@v5
with:
build: yarn build
start: yarn serve
wait-on: 'http://[::1]:9000'
start: yarn dev:https:ci
wait-on: 'https://localhost.corp.adobe.com:9000'
wait-on-timeout: 150
browser: chrome
config-file: cypress.config.js
spec: cypress/e2e/smoke.cy.js
spec: |
cypress/e2e/smoke.cy.js
cypress/e2e/get-credentials.cy.js
env:
NODE_TLS_REJECT_UNAUTHORIZED: '0'
243 changes: 239 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,23 @@ Using a theme, all of your default configuration lives in an npm package.
- [Writing Enhanced Markdown](#writing-enhanced-markdown)
- [Metadata with Front matter](#metadata-with-front-matter)
- [OpenAPI](#openapi)
- [Redocly API Block](#Redocly API Block)
- [Redocly API Block](#RedoclyAPIBlock)
- [On-premise license keys](#on-premise-license-keys)
- [Local development limitation and workaround](#local-development-limitation-and-workaround)
- [Full width page](#full-width-page)
- [Displaying long API response descriptions](#displaying-long-api-response-descriptions)
- [width (optional)](#width-optional)
- [typography (optional)](#typography-optional)
- [codeblock (optional)](#codeblock-optional)
- [disableSidebar (optional)](#disablesidebar-optional)
- [disableSearch (optional)](#disablesearch-optional)
- [hideTryItPanel (optional)](#hidetryitpanel-optional)
- [scrollYOffset (optional)](#scrollyoffset-optional)
- [sortOperationsAlphabetically (optional)](#sortoperationsalphabetically-optional)
- [sortTagsAlphabetically (optional)](#sorttagsalphabetically-optional)
- [jsonSampleExpandLevel (optional)](#jsonsampleexpandlevel-optional)
- [generateCodeSamples (optional)](#generatecodesamples-optional)
- [requestInterceptor (optional)](#requestinterceptor-optional)
- [JSDoc](#jsdoc)
- [MDX](#mdx)
- [Modular Content System](#modular-content-system)
Expand All @@ -121,6 +137,7 @@ Using a theme, all of your default configuration lives in an npm package.
- [Table Block](#table-block)
- [Tabs Block](#tabs-block)
- [Product Card](#product-card)
- [Mini Product Card](#product-card)
- [Product Card Grid](#product-card-grid)
- [Resource Card](#resource-card)
- [MiniResourceCard](#miniresourcecard)
Expand Down Expand Up @@ -1076,11 +1093,195 @@ We use [Redoc](https://github.com/Redocly/redoc) to render OpenAPI specs. Simply

</pre>

### Redocly API Block
### RedoclyAPIBlock

We can now host your own open api yaml files and be rendered by Redocly documents. This way can avoid to iframe in and host our own api yaml files in Redocly.
```js
<RedoclyAPIBlock src="URL pointing to your open api yaml file." />
```

We can now host your own OpenAPI YAML files and have them rendered by Redocly documents. This approach allows us to avoid using iframes and instead host our own API YAML files directly in Redocly.

#### On-premise license keys

When using RedoclyAPIBlock, ensure that GATSBY_REDOCLY_KEY: ${{ secrets.REDOCLY_LICENSE_KEY }} is added to the deploy.yml file in your repository (e.g. add to [build-dev](https://github.com/AdobeDocs/ff-services-docs/blob/24b9b522e7521d7169265871023cccfa1f03f349/.github/workflows/deploy.yml#L145) and [build-production](https://github.com/AdobeDocs/ff-services-docs/blob/24b9b522e7521d7169265871023cccfa1f03f349/.github/workflows/deploy.yml#L252)). Any public repo in the AdobeDocs organization will have access to this development environment [secret](https://github.com/organizations/AdobeDocs/settings/secrets/actions).

Dev-site team is responsible for making sure the license key is up to date, which can be found in redocly account settings -> On-premise license keys.

#### Local development limitation and workaround

Due to the way Redocly API works, it’s not possible to test RedoclyAPIBlock locally:
![redocly-api-block-on-local](docs/images/redocly-api-block-on-local.png)

To test, temporarily deploy to stage:
![redocly-api-block-on-stage](docs/images/redocly-api-block-on-stage.png)

#### Full width page

Use [custom layout](#custom-layout) to do a full width page

#### Displaying long API response descriptions

By default, Redocly displays API response descriptions as the button text (styled as one line, no-wrap). If too long, the text could get truncated, and the page widens beyond 100%:
![redocly-api-block-long-description-without-x-summary](docs/images/redocly-api-block-long-description-without-x-summary.png)
![redocly-api-block-long-description-without-x-summary-yaml](docs/images/redocly-api-block-long-description-without-x-summary-yaml.png)

For long descriptions, Redocly suggests to use the [x-summary](https://redocly.com/docs/api-reference-docs/specification-extensions/x-summary/) specification extension. If specified, it is used as the response button text, and the description is rendered under the button:
![redocly-api-block-long-description-with-x-summary](docs/images/redocly-api-block-long-description-with-x-summary.png)
![redocly-api-block-long-description-with-x-summary-yaml](docs/images/redocly-api-block-long-description-with-x-summary-yaml.png)

#### width (optional)

```js
<RedoclyAPIBlock src="URL pointing to your open api yaml file." width="600px" />
```
Sets the width (of the right panel).

Defaults to ```'500px'```

https://redocly.com/docs/api-reference-docs/configuration/theming/#path=rightPanel

#### typography (optional)

```js
<RedoclyAPIBlock src="URL pointing to your open api yaml file." typography="fontFamily: `serif`, fontSize: '16px'" />
```

Controls the appearance of text.

Defaults to ```'fontFamily: `adobe-clean, "Source Sans Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Ubuntu, "Trebuchet MS", "Lucida Grande", sans-serif`'```

https://redocly.com/docs/api-reference-docs/configuration/theming/#path=typography

#### codeblock (optional)

```js
<RedoclyAPIBlock src="URL pointing to your open api yaml file." codeBlock="tokens: { punctuation: { color: 'red ' }}" />
```

Controls the appearance of code snippets.

Defaults to ```"tokens: { punctuation: { color: 'white' }}"```

https://redocly.com/docs/api-reference-docs/configuration/theming/#path=codeBlock

#### disableSidebar (optional)

```js
<RedoclyAPIBlock src="URL pointing to your open api yaml file." disableSidebar />
```

If set to `true`, hides the navigation sidebar (the left panel). Setting this option to `false` does not disable the search feature.

Defaults to ```false```

https://redocly.com/docs/api-reference-docs/configuration/functionality/#theme-object-openapi-schema

#### disableSearch (optional)

```js
<RedoclyAPIBlock src="URL pointing to your open api yaml file." disableSearch />
```

Disables search indexing and hides the search box from the API documentation page.

Defaults to ```false```

https://redocly.com/docs/api-reference-docs/configuration/functionality/#theme-object-openapi-schema

#### hideTryItPanel (optional)

```js
<RedoclyAPIBlock src="URL pointing to your open api yaml file." hideTryItPanel />
```

Disables the Try it console in the right panel.

Defaults to ```false```

https://redocly.com/docs/api-reference-docs/configuration/functionality/#theme-object-openapi-schema

#### scrollYOffset (optional)

```js
<RedoclyAPIBlock src="URL pointing to your open api yaml file." scrollYOffset={64} />
```

Specifies a vertical scroll-offset. This is useful when there are fixed positioned elements at the top of the page, such as navbars, headers etc. You can specify the scrollYOffset value as a number - a fixed number of pixels to be used as the offset.

Defaults to ```0```

When using this block, GATSBY_REDOCLY_KEY : ${{ secrets.REDOCLY_LICENSE_KEY }} will needs to be added in deploy.yml file in the repo.
https://redocly.com/docs/api-reference-docs/configuration/functionality/#theme-object-openapi-schema


#### sortOperationsAlphabetically (optional)

```js
<RedoclyAPIBlock src="URL pointing to your open api yaml file." sortOperationsAlphabetically />
```

When set to `true`, sorts operations in the navigation sidebar and in the middle panel alphabetically.˙

Defaults to ```false```

https://redocly.com/docs/api-reference-docs/configuration/functionality/#theme-object-openapi-schema

#### sortTagsAlphabetically (optional)

```js
<RedoclyAPIBlock src="URL pointing to your open api yaml file." sortTagsAlphabetically />
```

When set to `true`, sorts tags in the navigation sidebar and in the middle panel alphabetically. Note that only tags will be sorted alphabetically in the middle panel, not the operations associated with each tag. To sort operations alphabetically as well, you must set `sortOperationsAlphabetically` to `true`.

Defaults to ```false```

https://redocly.com/docs/api-reference-docs/configuration/functionality/#theme-object-openapi-schema

#### jsonSampleExpandLevel (optional)

```js
<RedoclyAPIBlock src="URL pointing to your open api yaml file." jsonSampleExpandLevel="all" />
```

Sets the default expand level for JSON payload samples (response and request body). Takes a number >= 1, or the string 'all'.

Defaults to ```2```

https://redocly.com/docs/api-reference-docs/configuration/functionality/#theme-object-openapi-schema

#### generateCodeSamples (optional)

```js
<RedoclyAPIBlock src="URL pointing to your open api yaml file." generateCodeSamples="languages: [{ lang: 'curl' }, { lang: 'Node.js' }, { lang: 'JavaScript' }, {lang: 'Python'}]" />
```

Controls options for generating code samples, including code sample languages.

Defaults to ```languages: [], skipOptionalParameters: false```

https://redocly.com/docs/api-reference-docs/configuration/functionality#theme-object-openapi-schema

#### requestInterceptor (optional)

```js
<RedoclyAPIBlock
src="/redocly-test/openapi/openapi.yaml"
requestInterceptor="
function(req, operation) {
console.log('Args:', req, operation);
return req;
}
"
```

Configures the request interceptor for the Try it console. As a prerequisite, the Try it console must be enabled in Reference docs (hideTryItPanel must be set to false). When configured, the interceptor can capture the request object and modify it according to specified criteria. Async usage is supported.

Defaults to ``````

Limitations: Due to gatsby and markdown limitations, we can't add comments in the function string nor empty lines.

https://redocly.com/docs/api-reference-docs/configuration/functionality#theme-object-openapi-schema
https://redocly.com/docs/api-reference-docs/configuration/functionality#example-configuration-with-javascript-library

### JSDoc

Expand Down Expand Up @@ -1156,13 +1357,16 @@ Use `slots` to identify the markdown content:
- `heading` (required)
- `text` (required)
- `image` (optional)
- `videoUrl`(optional)

Use `background` to set a custom background color matching your color scheme. Defaults to `rgb( 29, 125, 238)`;

Use `theme` to match the text color to your color scheme. Defaults to `dark`.

Use `hideBreadcrumbNav` to optionaly hide the breadcrumb navigation on this variant. Defaults to false.

Use `videoUrl` to videoURL to post the video in half width /full width

**Half width variant**

![hero halfwidth](docs/images/hero-halfwidth.png)
Expand Down Expand Up @@ -2470,6 +2674,35 @@ Use `textColor` to define the color of the text. The preset is `black`.

Use `inRow` to define the number of profile cards in a row.

### Mini Product Card

Miniproductcard component is used to display the product card with little image and description

![mini_product_card](docs/images/mini-product-card.png)

```
<MiniProductCard slots="image, heading , text , buttons" repeat="4" theme="lightest" inRow="4" variantsType="primary" buttonStyle="outline" />

![Forge the path to customer success](./S_AniConvertToGIF.png)

# Firefly API

Firefly API

- [Learn more](https://developer-stage.adobe.com/)

```

Use `slots` to identify the markdown content:

- `image`(required)
- `heading`(required)
- `text`(optional)
- `buttons`(optional)

Use `repeat` to define how many code sections are part.


### Edition

The Edition component is used to display the edition of the product.
Expand Down Expand Up @@ -2534,6 +2767,8 @@ as a dependency in another site, you can run the command `npm install --save ado

Your site package will show up under `node_modules/[PACKAGE_NAME]` e.g. `node_modules/dev-site-documentation-template`.

When pointing to a github repo as a dependency and wanting to get the latest change from that dependency, you have to ensure that your package.json is pointing to latest version of that dependecy. Otherwise, if you have already pulled down that dependency and it exists in your `node_modules/`, it won't grab the latest changes. To get around this, simply delete your `node_modules/` and then `yarn install` again.

See full example below using a Variant block.

#### Filtering content with Variant Blocks
Expand Down
36 changes: 21 additions & 15 deletions cypress.config.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,21 @@
const { defineConfig } = require('cypress')

module.exports = defineConfig({
viewportHeight: 900,
viewportWidth: 1440,
e2e: {
// We've imported your old cypress plugins here.
// You may want to clean this up later by importing these.
setupNodeEvents(on, config) {
return require('./cypress/plugins/index.js')(on, config)
},
baseUrl: 'http://localhost:9000',
specPattern: 'cypress/e2e/**/*.cy.{js,jsx,ts,tsx}',
},
})
const { defineConfig } = require('cypress')

module.exports = defineConfig({
viewportHeight: 900,
viewportWidth: 1440,
e2e: {
// We've imported your old cypress plugins here.
// You may want to clean this up later by importing these.
setupNodeEvents(on, config) {
return require('./cypress/plugins/index.js')(on, config)
},
baseUrl: 'https://localhost.corp.adobe.com:9000',
specPattern: 'cypress/e2e/**/*.cy.{js,jsx,ts,tsx}',
},
pageLoadTimeout: 500000,
userEmail: 'cypress1@adobe.com',
userPassword: 'ScotchB33r&1234567',
defaultCommandTimeout: 60000,
video: false,
chromeWebSecurity: false
})
Loading