Browse Source

docs: Use a relative path for docs index page logo (#1276)

* Use a relative path for docs index page logo

Changes the paths for the logo on the index page of the documentation
to use relative links instead of absolute ones.

The current absolute path is just fine as long as the site
is not hosted under another directory. When opening files locally
(without serving them in docfx) these images will fail to load.
In addition, if these files are served under a directory that is
not the root endpoint (like: `docs.com/stable/`) the images will
also break.

I tested these changes locally using these steps:

- Build & serve docs: `docfx docs/docfx.json --serve`
- Verify that logo shows up on index page using all 3 themes
- Open `docs/_site/index.html`
- Verify logo works on all 3 themes

* Minor grammar fix in DiscordSocketClient
tags/2.1.0
Chris Johnston Christopher F 6 years ago
parent
commit
b80f0e84e7
4 changed files with 5 additions and 5 deletions
  1. +1
    -1
      docs/_template/light-dark-theme/styles/dark.css
  2. +1
    -1
      docs/_template/light-dark-theme/styles/gray.css
  3. +1
    -1
      docs/_template/light-dark-theme/styles/light.css
  4. +2
    -2
      src/Discord.Net.WebSocket/DiscordSocketClient.cs

+ 1
- 1
docs/_template/light-dark-theme/styles/dark.css View File

@@ -304,5 +304,5 @@ span.arrow-r{
}

.logo-switcher {
background: url("/marketing/logo/SVG/Combinationmark White.svg") no-repeat;
background: url("../marketing/logo/SVG/Combinationmark White.svg") no-repeat;
}

+ 1
- 1
docs/_template/light-dark-theme/styles/gray.css View File

@@ -311,5 +311,5 @@ span.arrow-r{
}

.logo-switcher {
background: url("/marketing/logo/SVG/Combinationmark White.svg") no-repeat;
background: url("../marketing/logo/SVG/Combinationmark White.svg") no-repeat;
}

+ 1
- 1
docs/_template/light-dark-theme/styles/light.css View File

@@ -113,5 +113,5 @@ span.arrow-r{
}

.logo-switcher {
background: url("/marketing/logo/SVG/Combinationmark.svg") no-repeat;
background: url("../marketing/logo/SVG/Combinationmark.svg") no-repeat;
}

+ 2
- 2
src/Discord.Net.WebSocket/DiscordSocketClient.cs View File

@@ -83,7 +83,7 @@ namespace Discord.WebSocket
/// </note>
/// </remarks>
/// <returns>
/// An collection of DM channels that have been opened in this session.
/// A collection of DM channels that have been opened in this session.
/// </returns>
public IReadOnlyCollection<SocketDMChannel> DMChannels
=> State.PrivateChannels.OfType<SocketDMChannel>().ToImmutableArray();
@@ -98,7 +98,7 @@ namespace Discord.WebSocket
/// </note>
/// </remarks>
/// <returns>
/// An collection of group channels that have been opened in this session.
/// A collection of group channels that have been opened in this session.
/// </returns>
public IReadOnlyCollection<SocketGroupChannel> GroupChannels
=> State.PrivateChannels.OfType<SocketGroupChannel>().ToImmutableArray();


Loading…
Cancel
Save