feat: consistently format all HTML, XML, JSON, CSS, JS, TS, SQL, TOML, YAML, and Markdown files as far as possible (#4193)

* feat: consistently format all HTML, XML, JSON, CSS, JS, TS, SQL, TOML, YAML, and Markdown files

* chore: deal with VS Code not being able to parse valid editorconfig syntax

Sometimes I'm surprised that computers even work.

* chore: get rid of IntelliJ IDE config files that should not be there

These were already added to the `.gitignore` a long time ago, and now
are being ignored by Prettier.

* fix: rename `tooling-config` `format` script to `fix` for it to run with Turbo
This commit is contained in:
Alejandro González
2025-08-16 19:40:31 +02:00
committed by GitHub
parent 6f59f4c110
commit 1454e3351e
130 changed files with 7959 additions and 7618 deletions

View File

@@ -1,7 +1,7 @@
import { defineCollection } from 'astro:content';
import { docsLoader } from '@astrojs/starlight/loaders';
import { docsSchema } from '@astrojs/starlight/schema';
import { defineCollection } from 'astro:content'
import { docsLoader } from '@astrojs/starlight/loaders'
import { docsSchema } from '@astrojs/starlight/schema'
export const collections = {
docs: defineCollection({ loader: docsLoader(), schema: docsSchema() }),
};
docs: defineCollection({ loader: docsLoader(), schema: docsSchema() }),
}

View File

@@ -8,7 +8,7 @@ Modrinth allows developers to create applications which, once authorized by a Mo
If you're familiar with OAuth 2, these are the URLs you will need:
| Name | URL |
|--------------------|--------------------------------------------------|
| ------------------ | ------------------------------------------------ |
| Authorization page | `https://modrinth.com/auth/authorize` |
| Token exchange | `https://api.modrinth.com/_internal/oauth/token` |
@@ -31,7 +31,7 @@ After you've registered your application, it is important that you take note of
Once the user is ready to authorize your application, you need to construct a URL to redirect them to. The authorization URL for Modrinth is `https://api.modrinth.com/_internal/oauth/token`. Supply the following query parameters:
| Query parameter | Description |
|-----------------|-------------------------------------------------------------------------------------------|
| --------------- | ----------------------------------------------------------------------------------------- |
| `response_type` | In Modrinth this always needs to be `code`, since only code grants are supported |
| `client_id` | The application identifier found in the settings |
| `scope` | The permissions you need access to |
@@ -45,7 +45,7 @@ The scope identifiers are currently best found in the backend source code locate
The redirect URI is the endpoint on your server that will receive the code which can eventually be used to act on the user's behalf. For security reasons the redirect URI used has to be allowlisted in your application settings. The redirect will contain the following query parameters:
| Query parameter | Description |
|-----------------|----------------------------------------------------|
| --------------- | -------------------------------------------------- |
| `code` | The code that can be exchanged for an access token |
| `client_id` | Your client id |
| `redirect_uri` | The redirect URI which was used |
@@ -58,7 +58,7 @@ If you've followed the previous section on getting authorization, you should now
In the body use these fields:
| Field | Description |
|----------------|--------------------------------------------------------------|
| -------------- | ------------------------------------------------------------ |
| `code` | The authorization code |
| `client_id` | Your client id, the same as in the authorization request |
| `redirect_uri` | The redirect URI which was redirected to after authorization |
@@ -67,7 +67,7 @@ In the body use these fields:
If the request succeeds, you should receive a JSON payload with these fields:
| Field | Description |
|----------------|------------------------------------------------------|
| -------------- | ---------------------------------------------------- |
| `access_token` | The access token you can use to access the API |
| `token_type` | Currently only `Bearer` |
| `expires_in` | The amount of seconds until the access token expires |
@@ -77,19 +77,11 @@ To use this access token, you attach it to API requests in the `Authorization` h
If you have any questions, you're welcome to ask in #api-development in the [Discord guild], or create a ticket on the [support portal].
[RFC 6749]: https://datatracker.ietf.org/doc/html/rfc6749
[register an application]: https://modrinth.com/settings/applications
[principle of least privilege]: https://en.wikipedia.org/wiki/Principle_of_least_privilege
[`apps/labrinth/src/models/v3/pats.rs`]: https://github.com/modrinth/code/blob/main/apps/labrinth/src/models/v3/pats.rs
[CSRF]: https://en.wikipedia.org/wiki/Cross-site_request_forgery
[Clickjacking]: https://en.wikipedia.org/wiki/Clickjacking
[`/user` endpoint]: https://docs.modrinth.com/api/operations/getuserfromauth/
[Discord guild]: https://discord.modrinth.com
[support portal]: https://support.modrinth.com/en/

View File

@@ -2,53 +2,53 @@
::backdrop,
:root[data-theme='light'],
[data-theme='light'] ::backdrop {
--sl-font-system: Inter, -apple-system, BlinkMacSystemFont, Segoe UI, Oxygen, Ubuntu, Roboto,
Cantarell, Fira Sans, Droid Sans, Helvetica Neue, sans-serif;
--sl-font-system: Inter, -apple-system, BlinkMacSystemFont, Segoe UI, Oxygen, Ubuntu, Roboto,
Cantarell, Fira Sans, Droid Sans, Helvetica Neue, sans-serif;
--sl-color-white: var(--color-contrast); /* “white” */
--sl-color-gray-1: var(--color-base);
--sl-color-gray-2: var(--color-base);
--sl-color-gray-3: var(--color-base);
--sl-color-gray-4: var(--color-raised-bg);
--sl-color-gray-5: var(--color-button-bg);
--sl-color-gray-6: var(--color-raised-bg);
--sl-color-black: var(--color-accent-contrast);
--sl-color-white: var(--color-contrast); /* “white” */
--sl-color-gray-1: var(--color-base);
--sl-color-gray-2: var(--color-base);
--sl-color-gray-3: var(--color-base);
--sl-color-gray-4: var(--color-raised-bg);
--sl-color-gray-5: var(--color-button-bg);
--sl-color-gray-6: var(--color-raised-bg);
--sl-color-black: var(--color-accent-contrast);
--sl-color-accent-low: var(--color-green-highlight);
--sl-color-accent: var(--color-brand);
--sl-color-accent-high: var(--color-brand-highlight);
--sl-color-accent-low: var(--color-green-highlight);
--sl-color-accent: var(--color-brand);
--sl-color-accent-high: var(--color-brand-highlight);
--sl-color-orange-low: var(--color-orange-highlight);
--sl-color-orange: var(--color-orange);
--sl-color-orange-high: var(--color-orange-highlight);
--sl-color-orange-low: var(--color-orange-highlight);
--sl-color-orange: var(--color-orange);
--sl-color-orange-high: var(--color-orange-highlight);
--sl-color-green-low: var(--color-green-highlight);
--sl-color-green: var(--color-green);
--sl-color-green-high: var(--color-green-highlight);
--sl-color-green-low: var(--color-green-highlight);
--sl-color-green: var(--color-green);
--sl-color-green-high: var(--color-green-highlight);
--sl-color-blue-low: var(--color-blue-highlight);
--sl-color-blue: var(--color-blue);
--sl-color-blue-high: var(--color-blue-highlight);
--sl-color-blue-low: var(--color-blue-highlight);
--sl-color-blue: var(--color-blue);
--sl-color-blue-high: var(--color-blue-highlight);
--sl-color-purple-low: var(--color-purple-highlight);
--sl-color-purple: var(--color-purple);
--sl-color-purple-high: var(--color-purple-highlight);
--sl-color-purple-low: var(--color-purple-highlight);
--sl-color-purple: var(--color-purple);
--sl-color-purple-high: var(--color-purple-highlight);
--sl-color-red-low: var(--color-red-highlight);
--sl-color-red: var(--color-red);
--sl-color-red-high: var(--color-red-highlight);
--sl-color-red-low: var(--color-red-highlight);
--sl-color-red: var(--color-red);
--sl-color-red-high: var(--color-red-highlight);
--sl-color-text: var(--color-base);
--sl-color-text-accent: var(--color-brand);
--sl-color-text-invert: var(--color-accent-contrast);
--sl-color-bg: var(--color-bg);
--sl-color-bg-nav: var(--color-raised-bg);
--sl-color-bg-sidebar: var(--color-raised-bg);
--sl-color-bg-inline-code: var(--color-button-bg);
--sl-color-bg-accent: var(--color-brand-highlight);
--sl-color-text: var(--color-base);
--sl-color-text-accent: var(--color-brand);
--sl-color-text-invert: var(--color-accent-contrast);
--sl-color-bg: var(--color-bg);
--sl-color-bg-nav: var(--color-raised-bg);
--sl-color-bg-sidebar: var(--color-raised-bg);
--sl-color-bg-inline-code: var(--color-button-bg);
--sl-color-bg-accent: var(--color-brand-highlight);
}
:root[data-theme='light'],
[data-theme='light'] ::backdrop {
--sl-color-bg: var(--color-raised-bg);
--sl-color-bg: var(--color-raised-bg);
}