Skip to content

Commit

Permalink
docs/fix-urls: Updates the Terminal About URLs to match /develop (#…
Browse files Browse the repository at this point in the history
…5720)

* update Terminal about URLs and some other broken links

* ruff

* intro

* changing the heading levels

* dependency management sections

* structure

* developer guides

* structure

* contributor guides

* keywords and descriptions

* broken urls

* cool cards

* Cool cards (#5727)

* tidy up terminal/content

* some more tidy up

* fix styling for platform that was missing

* more tidy up

* improve color for dark and light mode

* create new reference card for more basic cards

* rename back to menus

* implement all index.md for terminal, except reference

* improve bot title

* more refactoring

* fix remaining index

* header styling

* more styling

* heheheheheheeh

* Revert "heheheheheheeh"

This reverts commit 7d095fc.

* Ccards (#5733)

* links

* more links

* improved styling and chevron aligned to title

* fix index.mdx urls for Terminal

* update package.json

* update index.mdx

* fix generation

* spelling

* toolkit_extensions

* update data extensions

* couple of links

* add tiingo to data extensions list

---------

Co-authored-by: hjoaquim <h.joaquim@campus.fct.unl.pt>
Co-authored-by: andrewkenreich <andrew.kenreich@gmail.com>
Co-authored-by: DidierRLopes <dro.lopes@campus.fct.unl.pt>
Co-authored-by: James Maslek <jmaslek11@gmail.com>
  • Loading branch information
5 people committed Nov 16, 2023
1 parent be7f0c3 commit 757fc57
Show file tree
Hide file tree
Showing 152 changed files with 4,937 additions and 1,278 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,7 @@
MD_FILES = ["CONTRIBUTING.md", "README.md", "openbb_terminal/SDK_README.md"]
MD_FILES.extend(glob.glob("website/content/sdk/faqs/*.md", recursive=True))
MD_FILES.extend(glob.glob("website/content/terminal/usage/*.md", recursive=True))
MD_FILES.extend(
glob.glob("website/content/terminal/data-available/*.md", recursive=True)
)
MD_FILES.extend(glob.glob("website/content/terminal/menus/*.md", recursive=True))
MD_FILES.extend(glob.glob("website/content/sdk/usage/*.md", recursive=True))
MD_FILES.extend(glob.glob("website/content/sdk/data-available/*.md", recursive=True))

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ def __init__(
self.DATA_FILES = params_helpers.load_data_files()

if session and get_current_user().preferences.USE_PROMPT_TOOLKIT:
choices: dict = self.choices_default
choices: dict = {c: {} for c in self.controller_choices}
choices["set"] = {c: None for c in self.models}
choices["set"]["--model"] = {c: None for c in self.models}
choices["set"]["-m"] = "--model"
Expand Down
80 changes: 51 additions & 29 deletions openbb_terminal/terminal_helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,70 +131,86 @@ def update_terminal():
return 0


def open_openbb_documentation(
def open_openbb_documentation( # noqa: PLR0912
path,
url="https://my.openbb.co/app/terminal",
url="https://docs.openbb.co/terminal",
command=None,
arg_type="",
):
"""Opens the documentation page based on your current location within the terminal. Make exceptions for menus
that are considered 'common' by adjusting the path accordingly."""
if path == "/" and command is None:
path = "/usage?path=/usage/structure-and-navigation"
path = "/usage/overview/structure-and-navigation"
command = ""
elif "keys" in path:
path = "/usage?path=/usage/data/api-keys"
path = "/usage/data/api-keys"
command = ""
elif "settings" in path:
path = "/usage?path=/usage/overview/customizing-the-terminal"
path = "/usage/overview/customizing-the-terminal"
command = ""
elif "featflags" in path:
path = "/usage?path=/usage/overview/customizing-the-terminal#feature-flags-menu"
path = "/usage/overview/customizing-the-terminal#feature-flags-menu"
command = ""
elif "sources" in path:
path = "/usage?path=/usage/usage/data/data-sources"
path = "/usage/usage/data/data-sources"
command = ""
elif "account" in path:
path = "/usage?path=/usage/hub"
path = "/usage/hub"
command = ""
elif arg_type == "command": # user passed a command name
if command in ["settings", "featflags"]:
path = "/usage?path=/usage/overview/customizing-the-terminal"
path = "/usage/overview/customizing-the-terminal"
command = ""
else:
path = f"/commands?path={path}"
path = f"/reference/{path}"
elif "askobb" in path:
path = "/usage/askobb-feature"
command = ""
elif arg_type == "menu": # user passed a menu name
if command in ["ta", "ba", "qa"]:
if command in ["ta", "qa"]:
menu = path.split("/")[-2]
path = f"/usage?path=/data-available/common/{menu}"
path = f"/menus/common/{menu}"
elif command == "stocks":
path = "/menus/stocks/introduction"
command = ""
elif command == "forecast":
command = ""
path = "/usage?path=/data-available/forecast"
path = "/menus/forecast"
elif command == "crypto":
path = "/menus/crypto/introduction"
command = ""

else:
path = f"/usage?path=/data-available/{path}"
path = f"/menus/{path}"
else: # user didn't pass argument and is in a menu
menu = path.split("/")[-2]
path = (
f"/usage?path=/data-available/common/{menu}"
if menu in ["ta", "ba", "qa"]
else f"/usage?path=/data-available/{path}"
)
if menu == "crypto" and not command:
path = "/crypto/introduction"
if menu == "stocks":
path = "/stocks/introduction"
path = f"/menus/common/{menu}" if menu in ["ta", "qa"] else f"/menus/{path}"

if command:
if command == "keys":
path = "/usage?path=/usage/data/api-keys"
path = "/usage/data/api-keys"
command = ""
elif "settings" in path or "featflags" in path:
path = "/usage?path=/usage/overview/customizing-the-terminal"
path = "/usage/overview/customizing-the-terminal"
command = ""
elif "sources" in path:
path = "/usage?path=/usage/data/data-sources"
path = "/usage/data/data-sources"
command = ""
elif command in ["record", "stop", "exe"]:
path = "/usage?path=/usage/routines/introduction-to-routines"
path = "/usage/routines/introduction-to-routines"
command = ""
elif command == "sources":
path = "/usage?path=/usage/data/data-sources"
path = "/usage/data/data-sources"
command = ""
elif command == "askobb":
path = "/usage/askobb-feature"
command = ""
elif command == "news":
path = "/usage/overview/commands-and-arguments#help-arguments"
command = ""
elif command in [
"intro",
Expand All @@ -203,15 +219,21 @@ def open_openbb_documentation(
"survey",
"update",
"wiki",
"news",
"account",
]:
path = "/usage"
command = ""
elif command in ["ta", "ba", "qa"]:
path = f"/usage?path=/data-available/common/{command}"
elif command in ["ta", "qa"]:
path = f"/menus/common/{command}"
command = ""
elif command == "stocks":
path = "/menus/stocks/introduction"
command = ""
elif command == "account":
path = "/usage/hub"
command = ""
elif command == "news":
path = "/usage/overview/commands-and-arguments#help-arguments"
command = ""

path += command

full_url = f"{url}{path.replace('//', '/')}"
Expand Down
50 changes: 50 additions & 0 deletions website/content/bot/changelog/index.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
---
title: Changelog
---
import NewReferenceCard from "@site/src/components/General/NewReferenceCard";
import HeadTitle from '@site/src/components/General/HeadTitle.tsx';

<HeadTitle title="Changelog | OpenBB Bot Docs" />

<ul className="grid grid-cols-1 gap-4 -ml-6">
<NewReferenceCard
title="Current - v2.0.0"
url="changelog/version2_0_0"
/>
<NewReferenceCard
title="v1.0.8"
url="changelog/version1_0_8"
/>
<NewReferenceCard
title="v1.0.7"
url="changelog/version1_0_7"
/>
<NewReferenceCard
title="v1.0.6"
url="changelog/version1_0_6"
/>
<NewReferenceCard
title="v1.0.5"
url="changelog/version1_0_5"
/>
<NewReferenceCard
title="v1.0.4"
url="changelog/version1_0_4"
/>
<NewReferenceCard
title="v1.0.3"
url="changelog/version1_0_3"
/>
<NewReferenceCard
title="v1.0.2"
url="changelog/version1_0_2"
/>
<NewReferenceCard
title="v1.0.1"
url="changelog/version1_0_1"
/>
<NewReferenceCard
title="v1.0.0"
url="changelog/version1_0_0"
/>
</ul>
2 changes: 0 additions & 2 deletions website/content/bot/faqs.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@ import HeadTitle from '@site/src/components/General/HeadTitle.tsx';

<HeadTitle title="FAQs | OpenBB Bot Docs" />

## Generic

<details><summary>How Do I Link My OpenBB Bot Account?</summary>

After you signup for an OpenBB Bot plan you can link your accounts from <a href="https://my.openbb.co/app/bot" class="_hyper-link">here</a>
Expand Down
2 changes: 1 addition & 1 deletion website/content/bot/installation/discord.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: Setting up Discord bot
title: Discord bot
sidebar_position: 2
description: This page guides you on how to add a bot to your Discord server, through
steps of login, bot authorization, and adjusting bot permissions.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: Overview
title: Installation
sidebar_position: 1
description: Learn how to use OpenBB Bot in Discord and Telegram. Understand the requirements
for individual and server uses, and explore additional features by linking your
Expand Down
2 changes: 1 addition & 1 deletion website/content/bot/installation/telegram.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: Setting up Telegram bot
title: Telegram bot
sidebar_position: 3
description: Step-by-step guide to add the OpenBB Bot to a Telegram group. From starting
a chat with the bot to verifying its permissions, follow these steps to have your
Expand Down
27 changes: 27 additions & 0 deletions website/content/bot/reference/discord/alerts/index.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# alerts

import ReferenceCard from "@site/src/components/General/ReferenceCard";

<ul className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-4 -ml-6">

<ReferenceCard
title="create"
description="This command creates an alert for a given symbol (ex. BTCUSD) that will notify the user when the price is equal..."
url="/bot/reference/discord/alerts/create"
/>
<ReferenceCard
title="delete"
description="This command allows the user to delete an active alert they have set."
url="/bot/reference/discord/alerts/delete"
/>
<ReferenceCard
title="list"
description="This command allows the user to view a list of all their active alerts. It displays each alert along with its..."
url="/bot/reference/discord/alerts/list"
/>
<ReferenceCard
title="update"
description="This command allows the user to update the condition on an active alert, such as changing the value of a price..."
url="/bot/reference/discord/alerts/update"
/>
</ul>
57 changes: 57 additions & 0 deletions website/content/bot/reference/discord/charts/index.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
# charts

import ReferenceCard from "@site/src/components/General/ReferenceCard";

<ul className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-4 -ml-6">

<ReferenceCard
title="c15m"
description="This command allows the user to retrieve a 15-minute intraday chart for a given ticker. The chart will show the..."
url="/bot/reference/discord/charts/c15m"
/>
<ReferenceCard
title="c3m"
description="This command allows users to retrieve a 3-minute intraday chart for the given ticker. This chart will display the..."
url="/bot/reference/discord/charts/c3m"
/>
<ReferenceCard
title="c5m"
description="This command allows the user to retrieve an intraday 5 minute chart for a given ticker. This chart will display..."
url="/bot/reference/discord/charts/c5m"
/>
<ReferenceCard
title="cc"
description="This command allows the user to retrieve an intraday 5 minute chart for a given ticker, /c5m also has the same..."
url="/bot/reference/discord/charts/cc"
/>
<ReferenceCard
title="cd"
description="This command allows the user to retrieve a daily candlestick chart for a particular ticker or coin. The..."
url="/bot/reference/discord/charts/cd"
/>
<ReferenceCard
title="chart"
description="This command will retrieve a candlestick chart for the ticker/interval provided, with data for the past number of..."
url="/bot/reference/discord/charts/chart"
/>
<ReferenceCard
title="chartfib"
description="This command allows the user to retrieve Fibonacci levels for a given ticker. This data can be used to identify..."
url="/bot/reference/discord/charts/chartfib"
/>
<ReferenceCard
title="chartsr"
description="This command allows the user to retrieve Displays Support and Resistance Levels for the ticker provided. It will..."
url="/bot/reference/discord/charts/chartsr"
/>
<ReferenceCard
title="cm"
description="This command allows you to view a monthly candlestick chart for a given stock or cryptocurrency. The chart..."
url="/bot/reference/discord/charts/cm"
/>
<ReferenceCard
title="cw"
description="This command allows the user to retrieve a weekly candlestick chart for the ticker/coin provided. The chart..."
url="/bot/reference/discord/charts/cw"
/>
</ul>
52 changes: 52 additions & 0 deletions website/content/bot/reference/discord/crypto/index.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# crypto

import ReferenceCard from "@site/src/components/General/ReferenceCard";

<ul className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-4 -ml-6">

<ReferenceCard
title="defi"
description="chart table"
url="/bot/reference/discord/crypto/defi"
/>
<ReferenceCard
title="bigprints"
description="This command allows the user to retrieve the last 15 large prints for a given cryptocurrency pair. The command..."
url="/bot/reference/discord/crypto/bigprints"
/>
<ReferenceCard
title="bio"
description="This command allows the user to retrieve fundamental information about a crypto, such as its current price,..."
url="/bot/reference/discord/crypto/bio"
/>
<ReferenceCard
title="compfees"
description="This command allows users to retrieve the Protocol fees over time for the given project."
url="/bot/reference/discord/crypto/compfees"
/>
<ReferenceCard
title="fees"
description="This will provide the user with the fee rate of the top crypto protocols on a specified date, allowing the user..."
url="/bot/reference/discord/crypto/fees"
/>
<ReferenceCard
title="ir"
description="This command allows the user to retrieve the issuance rate of the top crypto protocols. The issuance rate is the..."
url="/bot/reference/discord/crypto/ir"
/>
<ReferenceCard
title="prints"
description="This command allows the user to retrieve the Last 15 Crypto Prints over the last 24 hours for the specified coin...."
url="/bot/reference/discord/crypto/prints"
/>
<ReferenceCard
title="top"
description="This command will retrieve the top cryptocurrencies, ranked by market capitalization, allowing the user to..."
url="/bot/reference/discord/crypto/top"
/>
<ReferenceCard
title="tvl"
description="This command allows users to retrieve historical TVL (Total Value Locked) data for any given protocol. It..."
url="/bot/reference/discord/crypto/tvl"
/>
</ul>
Loading

0 comments on commit 757fc57

Please sign in to comment.