Skip to content

Commit

Permalink
Merge branch 'wphan/sdk_docs_gen'
Browse files Browse the repository at this point in the history
  • Loading branch information
wphan committed Sep 25, 2024
2 parents fba66a7 + 1d0777a commit f76ddf0
Show file tree
Hide file tree
Showing 648 changed files with 153,640 additions and 7,911 deletions.
74 changes: 74 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
name: Deploy Typescript SDK Docs

on:
push:
branches: ["master"]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

permissions:
contents: write
pages: write
id-token: write

# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: "pages"
cancel-in-progress: false

jobs:
check-for-sdk-changes:
runs-on: ubicloud
# Set job outputs to values from filter step
outputs:
sdk: ${{ steps.filter.outputs.sdk }}
steps:
# For pull requests it's not necessary to checkout the code
- uses: actions/checkout@v2
- uses: dorny/paths-filter@v2
id: filter
with:
filters: |
sdk:
- 'sdk/**'
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}sdk
runs-on: ubicloud
needs: check-for-sdk-changes
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Generate docs
run: |
yarn
cd sdk
yarn && yarn build
cd ..
yarn generate-docs
- name: Check for changes
id: git-check
run: |
git diff --exit-code docs || echo "changes=true" >> $GITHUB_OUTPUT
- name: Commit changes
if: steps.git-check.outputs.changes == 'true'
run: |
git config user.name "GitHub Actions"
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
git add docs
git commit -m "Update SDK documentation" --no-verify
git push origin HEAD
- name: Setup Pages
if: steps.git-check.outputs.changes == 'true'
uses: actions/configure-pages@v5
- name: Upload artifact
if: steps.git-check.outputs.changes == 'true'
uses: actions/upload-pages-artifact@v3
with:
path: "docs"
- name: Deploy to GitHub Pages
if: steps.git-check.outputs.changes == 'true'
id: deployment
uses: actions/deploy-pages@v4
2 changes: 1 addition & 1 deletion docs/sdk/assets/search.js

Large diffs are not rendered by default.

6,258 changes: 5,059 additions & 1,199 deletions docs/sdk/classes/AdminClient.html

Large diffs are not rendered by default.

13 changes: 7 additions & 6 deletions docs/sdk/classes/AssetTier.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ <h4>Hierarchy</h4>
<ul class="tsd-hierarchy">
<li><span class="target">AssetTier</span></li></ul></section><aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/drift-labs/protocol-v2/blob/2d66cfe5/sdk/src/types.ts#L50">sdk/src/types.ts:50</a></li></ul></aside>
<li>Defined in <a href="https://github.com/drift-labs/protocol-v2/blob/dd47bb8/sdk/src/types.ts#L86">sdk/src/types.ts:86</a></li></ul></aside>
<section class="tsd-panel-group tsd-index-group">
<section class="tsd-panel tsd-index-panel">
<details class="tsd-index-content tsd-index-accordion" open><summary class="tsd-accordion-summary tsd-index-summary">
Expand Down Expand Up @@ -58,7 +58,7 @@ <h4>Type declaration</h4>
<h5>collateral<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">{}</span></h5>
<ul class="tsd-parameters"></ul></li></ul></div><aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/drift-labs/protocol-v2/blob/2d66cfe5/sdk/src/types.ts#L51">sdk/src/types.ts:51</a></li></ul></aside></section>
<li>Defined in <a href="https://github.com/drift-labs/protocol-v2/blob/dd47bb8/sdk/src/types.ts#L87">sdk/src/types.ts:87</a></li></ul></aside></section>
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class"><a id="CROSS" class="tsd-anchor"></a>
<h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagStatic">Static</code> <code class="tsd-tag ts-flagReadonly">Readonly</code> <span>CROSS</span><a href="#CROSS" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
<div class="tsd-signature">CROSS<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{ </span><br/><span>    </span>cross<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">{}</span><span class="tsd-signature-symbol">; </span><br/><span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol"> = ...</span></div>
Expand All @@ -69,7 +69,7 @@ <h4>Type declaration</h4>
<h5>cross<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">{}</span></h5>
<ul class="tsd-parameters"></ul></li></ul></div><aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/drift-labs/protocol-v2/blob/2d66cfe5/sdk/src/types.ts#L53">sdk/src/types.ts:53</a></li></ul></aside></section>
<li>Defined in <a href="https://github.com/drift-labs/protocol-v2/blob/dd47bb8/sdk/src/types.ts#L89">sdk/src/types.ts:89</a></li></ul></aside></section>
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class"><a id="ISOLATED" class="tsd-anchor"></a>
<h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagStatic">Static</code> <code class="tsd-tag ts-flagReadonly">Readonly</code> <span>ISOLATED</span><a href="#ISOLATED" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
<div class="tsd-signature">ISOLATED<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{ </span><br/><span>    </span>isolated<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">{}</span><span class="tsd-signature-symbol">; </span><br/><span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol"> = ...</span></div>
Expand All @@ -80,7 +80,7 @@ <h4>Type declaration</h4>
<h5>isolated<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">{}</span></h5>
<ul class="tsd-parameters"></ul></li></ul></div><aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/drift-labs/protocol-v2/blob/2d66cfe5/sdk/src/types.ts#L54">sdk/src/types.ts:54</a></li></ul></aside></section>
<li>Defined in <a href="https://github.com/drift-labs/protocol-v2/blob/dd47bb8/sdk/src/types.ts#L90">sdk/src/types.ts:90</a></li></ul></aside></section>
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class"><a id="PROTECTED" class="tsd-anchor"></a>
<h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagStatic">Static</code> <code class="tsd-tag ts-flagReadonly">Readonly</code> <span>PROTECTED</span><a href="#PROTECTED" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
<div class="tsd-signature">PROTECTED<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{ </span><br/><span>    </span>protected<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">{}</span><span class="tsd-signature-symbol">; </span><br/><span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol"> = ...</span></div>
Expand All @@ -91,7 +91,7 @@ <h4>Type declaration</h4>
<h5>protected<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">{}</span></h5>
<ul class="tsd-parameters"></ul></li></ul></div><aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/drift-labs/protocol-v2/blob/2d66cfe5/sdk/src/types.ts#L52">sdk/src/types.ts:52</a></li></ul></aside></section>
<li>Defined in <a href="https://github.com/drift-labs/protocol-v2/blob/dd47bb8/sdk/src/types.ts#L88">sdk/src/types.ts:88</a></li></ul></aside></section>
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class"><a id="UNLISTED" class="tsd-anchor"></a>
<h3 class="tsd-anchor-link"><code class="tsd-tag ts-flagStatic">Static</code> <code class="tsd-tag ts-flagReadonly">Readonly</code> <span>UNLISTED</span><a href="#UNLISTED" aria-label="Permalink" class="tsd-anchor-icon"><svg class="icon icon-tabler icon-tabler-link" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><use href="#icon-anchor-a"></use><use href="#icon-anchor-b"></use><use href="#icon-anchor-c"></use></svg></a></h3>
<div class="tsd-signature">UNLISTED<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-symbol">{ </span><br/><span>    </span>unlisted<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">{}</span><span class="tsd-signature-symbol">; </span><br/><span class="tsd-signature-symbol">}</span><span class="tsd-signature-symbol"> = ...</span></div>
Expand All @@ -102,7 +102,7 @@ <h4>Type declaration</h4>
<h5>unlisted<span class="tsd-signature-symbol">: </span><span class="tsd-signature-symbol">{}</span></h5>
<ul class="tsd-parameters"></ul></li></ul></div><aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/drift-labs/protocol-v2/blob/2d66cfe5/sdk/src/types.ts#L55">sdk/src/types.ts:55</a></li></ul></aside></section></section></div>
<li>Defined in <a href="https://github.com/drift-labs/protocol-v2/blob/dd47bb8/sdk/src/types.ts#L91">sdk/src/types.ts:91</a></li></ul></aside></section></section></div>
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
<div class="tsd-navigation settings">
<details class="tsd-index-accordion"><summary class="tsd-accordion-summary">
Expand All @@ -124,6 +124,7 @@ <h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><path d="M4.9389
<ul>
<li><a href="../modules.html">@drift-<wbr/>labs/sdk</a>
<ul></ul></li>
<li class="tsd-kind-namespace tsd-is-external"><a href="../modules/BN.html">BN</a></li>
<li class="tsd-kind-namespace tsd-is-external"><a href="../modules/pyth.html">pyth</a></li></ul></div></details></nav>
<nav class="tsd-navigation secondary menu-sticky">
<ul>
Expand Down
Loading

0 comments on commit f76ddf0

Please sign in to comment.