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

Remove references to Tabula theme and start porting essential components #11546

Draft
wants to merge 8 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
16 changes: 8 additions & 8 deletions .github/workflows/ci-docs-tests.yml
Expand Up @@ -44,10 +44,10 @@ jobs:
with:
python-version: ${{ env.DEFAULT_PYTHON_VERSION }}

- name: Set up Node 12.x 🦙
- name: Set up Node 16.x 🦙
uses: actions/setup-node@v3.4.1
with:
node-version: "12.x"
node-version: "16.x"

- name: Read Poetry Version 🔢
run: |
Expand Down Expand Up @@ -83,8 +83,8 @@ jobs:
uses: actions/cache@v3
with:
path: docs/node_modules
key: ${{ runner.os }}-yarn-12.x-${{ hashFiles('docs/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-12.x
key: ${{ runner.os }}-yarn-16.x-${{ hashFiles('docs/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-16.x

- name: Install Dependencies 📦
run: |
Expand Down Expand Up @@ -115,10 +115,10 @@ jobs:
with:
python-version: ${{ env.DEFAULT_PYTHON_VERSION }}

- name: Set up Node 12.x 🦙
- name: Set up Node 16.x 🦙
uses: actions/setup-node@v2.3.0
with:
node-version: "12.x"
node-version: "16.x"

- name: Read Poetry Version 🔢
run: |
Expand Down Expand Up @@ -154,8 +154,8 @@ jobs:
uses: actions/cache@v3
with:
path: docs/node_modules
key: ${{ runner.os }}-yarn-12.x-${{ hashFiles('docs/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-12.x
key: ${{ runner.os }}-yarn-16.x-${{ hashFiles('docs/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-16.x

- name: Install Dependencies 📦
run: |
Expand Down
24 changes: 12 additions & 12 deletions .github/workflows/documentation.yml
Expand Up @@ -108,10 +108,10 @@ jobs:
with:
python-version: 3.9

- name: Set up Node 12.x 🦙
- name: Set up Node 16.x 🦙
uses: actions/setup-node@v3.4.1
with:
node-version: "12.x"
node-version: "16.x"

- name: Read Poetry Version 🔢
run: |
Expand Down Expand Up @@ -146,8 +146,8 @@ jobs:
uses: actions/cache@v3
with:
path: docs/node_modules
key: ${{ runner.os }}-yarn-12.x-${{ hashFiles('docs/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-12.x
key: ${{ runner.os }}-yarn-16.x-${{ hashFiles('docs/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-16.x

- name: Install Dependencies 📦
run: make install install-docs
Expand Down Expand Up @@ -199,11 +199,11 @@ jobs:
with:
python-version: 3.9

- name: Set up Node 12.x 🦙
- name: Set up Node 16.x 🦙
if: needs.changes.outputs.docs == 'true'
uses: actions/setup-node@v3.4.1
with:
node-version: "12.x"
node-version: "16.x"

- name: Read Poetry Version 🔢
if: needs.changes.outputs.docs == 'true'
Expand Down Expand Up @@ -243,8 +243,8 @@ jobs:
uses: actions/cache@v3
with:
path: docs/node_modules
key: ${{ runner.os }}-yarn-12.x-${{ hashFiles('docs/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-12.x
key: ${{ runner.os }}-yarn-16.x-${{ hashFiles('docs/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-16.x

- name: Install Dependencies 📦
if: needs.changes.outputs.docs == 'true'
Expand Down Expand Up @@ -287,17 +287,17 @@ jobs:
- name: Checkout git repository 🕝
uses: actions/checkout@v3

- name: Set up Node 12.x 🦙
- name: Set up Node 16.x 🦙
uses: actions/setup-node@v3.4.1
with:
node-version: "12.x"
node-version: "16.x"

- name: Load Yarn Cached Packages ⬇
uses: actions/cache@v3
with:
path: docs/node_modules
key: ${{ runner.os }}-yarn-12.x-${{ hashFiles('docs/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-12.x
key: ${{ runner.os }}-yarn-16.x-${{ hashFiles('docs/yarn.lock') }}
restore-keys: ${{ runner.os }}-yarn-16.x

- name: Install Dependencies 📦
run: make install-docs
Expand Down
22 changes: 21 additions & 1 deletion docs/.gitignore
@@ -1,5 +1,25 @@
.netlify
# Dependencies
/node_modules

# Production
/build

# Generated files
.docusaurus
.cache-loader

# Misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local

npm-debug.log*
yarn-debug.log*
yarn-error.log*

.netlify
docs/variables.json
docs/sources
docs/reference
Expand Down
36 changes: 12 additions & 24 deletions docs/README.md
@@ -1,8 +1,6 @@
# Docs
# Website

The docs are built using [Docusaurus 2](https://v2.docusaurus.io/).

## Useful commands
This website is built using [Docusaurus 2](https://docusaurus.io/), a modern static website generator.

### Installation

Expand All @@ -16,7 +14,7 @@ $ yarn
$ yarn start
```

This command starts a local development server and open up a browser window. Most changes are reflected live without having to restart the server.
This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.

### Build

Expand All @@ -28,26 +26,16 @@ This command generates static content into the `build` directory and can be serv

### Deployment

Deployment is handled by Netlify: it is setup for listening to changes on the `documentation` branch.


## Manual steps after a new version

When a new docs version has been released, we'll need to do the following manual steps:
- Remove all the callouts from previous versions, with the exception of experimental features. You can find
those using `:::info` or `:::caution` in all the docs files.
- Update the wording of the top banner, configured in `docusaurus.config.js` in `announcementBar`: update the Rasa versions
that are mentioned and link to the now previous major version documentation.
- Update Netlify redirects in `netlify.toml`, under `# Redirects for latest version permalinks`, by adjusting the
version number to the now new major version.
Using SSH:

```
$ USE_SSH=true yarn deploy
```

## Handling deadlinks after removal of deprecated features
Not using SSH:

When removing deprecated features, it will happen that some links become dead because they now link to
parts of the docs that no longer exist. This usually happens in the CHANGELOG or migration links,
and thankfully we do have CI checks that alert for dead links.
```
$ GIT_USER=<Your GitHub username> yarn deploy
```

The trick here is to make these links point to _previous_ versions of the docs. For instance, if the feature
you removed was documented at `./policies#mapping-policy` and the current latest version for the docs is `2.x`
(this also means that the next version is `3.x`), then you can update the link to `https://rasa.com/docs/rasa/2.x/policies#mapping-policy`.
If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch.
2 changes: 1 addition & 1 deletion docs/docs/installation.mdx
Expand Up @@ -6,7 +6,7 @@ description: Install Rasa Open Source on premises to enable local and customizab
import useBaseUrl from '@docusaurus/useBaseUrl';
import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';
import { Button } from '@theme/Button';
// import { Button } from '@theme/RasaButton';

:::note Want to explore first?
You can explore Rasa Open Source online using the Rasa Playground even before you install it.
Expand Down
4 changes: 2 additions & 2 deletions docs/docs/playground.mdx
Expand Up @@ -6,8 +6,8 @@ abstract: Learn the basics of building an assistant with Rasa Open Source with t
hide_table_of_contents: true
---
import useBaseUrl from '@docusaurus/useBaseUrl';
import Prototyper, { DownloadButton, TrainButton } from '@theme/Prototyper';
import AssistantBuilder from '@theme/AssistantBuilder';
import Prototyper, { DownloadButton, TrainButton } from '../src/components/Prototyper';
import AssistantBuilder from '../src/components/AssistantBuilder';

<Prototyper
startPrototyperApi="https://trainer-service.prototyping.rasa.com/startPrototyping"
Expand Down